Running as unit: rb-build-arm64_6-80307.service ==================================================================================== Sat Feb 22 12:16:34 UTC 2025 - running /srv/jenkins/bin/reproducible_build.sh (for job reproducible_builder_arm64_6) on jenkins, called using "codethink03-arm64 codethink04-arm64" as arguments. Sat Feb 22 12:16:34 UTC 2025 - actually running "reproducible_build.sh" (md5sum 68e686e434c9ab7bc3ec047d8b309cbc) as "/tmp/jenkins-script-SJg91RTW" $ git clone https://salsa.debian.org/qa/jenkins.debian.net.git ; more CONTRIBUTING Sat Feb 22 12:16:34 UTC 2025 - checking /var/lib/jenkins/offline_nodes if codethink03-arm64.debian.net is marked as down. Sat Feb 22 12:16:34 UTC 2025 - checking via ssh if codethink03-arm64.debian.net is up. removed '/tmp/read-only-fs-test-vDEOuS' Sat Feb 22 12:16:35 UTC 2025 - checking /var/lib/jenkins/offline_nodes if codethink04-arm64.debian.net is marked as down. Sat Feb 22 12:16:35 UTC 2025 - checking via ssh if codethink04-arm64.debian.net is up. removed '/tmp/read-only-fs-test-UHOyXc' ok, let's check if bison is building anywhere yet… ok, bison is not building anywhere… UPDATE 1 ============================================================================= Initialising reproducibly build of bison in trixie on arm64 on jenkins now. 1st build will be done on codethink03-arm64.debian.net. 2nd build will be done on codethink04-arm64.debian.net. ============================================================================= Sat Feb 22 12:16:51 UTC 2025 I: starting to build bison/trixie/arm64 on jenkins on '2025-02-22 12:16' Sat Feb 22 12:16:51 UTC 2025 I: The jenkins build log is/was available at https://jenkins.debian.net/userContent/reproducible/debian/build_service/arm64_6/80307/console.log 1740226611 arm64 trixie bison Sat Feb 22 12:16:51 UTC 2025 I: Downloading source for trixie/bison=2:3.8.2+dfsg-1 --2025-02-22 12:16:51-- http://deb.debian.org/debian/pool/main/b/bison/bison_3.8.2%2bdfsg-1.dsc Connecting to 46.16.76.132:3128... connected. Proxy request sent, awaiting response... 200 OK Length: 1855 (1.8K) [text/prs.lines.tag] Saving to: ‘bison_3.8.2+dfsg-1.dsc’ 0K . 100% 301M=0s 2025-02-22 12:16:51 (301 MB/s) - ‘bison_3.8.2+dfsg-1.dsc’ saved [1855/1855] --2025-02-22 12:16:51-- http://deb.debian.org/debian/pool/main/b/bison/bison_3.8.2%2bdfsg-1.dsc Connecting to 46.16.76.132:3128... connected. Proxy request sent, awaiting response... 200 OK Length: 1855 (1.8K) [text/prs.lines.tag] Saving to: ‘bison_3.8.2+dfsg-1.dsc’ 0K . 100% 301M=0s 2025-02-22 12:16:51 (301 MB/s) - ‘bison_3.8.2+dfsg-1.dsc’ saved [1855/1855] Sat Feb 22 12:16:51 UTC 2025 I: bison_3.8.2+dfsg-1.dsc -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA512 Format: 3.0 (quilt) Source: bison Binary: bison, libbison-dev Architecture: any Version: 2:3.8.2+dfsg-1 Maintainer: Chuan-kai Lin Homepage: https://www.gnu.org/software/bison/ Standards-Version: 4.6.0 Build-Depends: debhelper-compat (= 12), gettext, flex, m4 (>= 1.4-14), help2man Package-List: bison deb devel optional arch=any libbison-dev deb libdevel optional arch=any Checksums-Sha1: 138e267dd2e16ea4c6eedf0ad57d4e174764b3df 2654920 bison_3.8.2+dfsg.orig.tar.xz 1876ee15e10da593c27731e4e9098986911ff4d4 11164 bison_3.8.2+dfsg-1.debian.tar.xz Checksums-Sha256: dff8a3c96dd34121828f62a7fa49e1f7765815b89e59f564e8d2a9e71c177be5 2654920 bison_3.8.2+dfsg.orig.tar.xz e878473ddbc8601c1b9b8558fab86950ae6ae5b7c146802d587e284d5e1c9abb 11164 bison_3.8.2+dfsg-1.debian.tar.xz Files: a502bd24cdca3c17eb648b5a9132613d 2654920 bison_3.8.2+dfsg.orig.tar.xz e152dd8a66a18274d5099bb780ac75f8 11164 bison_3.8.2+dfsg-1.debian.tar.xz -----BEGIN PGP SIGNATURE----- iQJFBAEBCgAvFiEEpjo/UW6i/KKi+2ONAbOplSquRxMFAmFY+B4RHGNrbGluQGRl Ymlhbi5vcmcACgkQAbOplSquRxPyehAAxsCWKLy+Mr9nUkv0KWUEcLsS882kllvf /gTIkIbXDAptcoIkV9dWZHaMjN1Bw6w14eUvjifNahKDjwRU2hUbtyiwf6umyUbZ vrw6HOfOdiBqaZUyCkZGJAjp3kUP14ZnLe4s9JE5q1EG5LQqboKNkUaF9fq8OTOF o+z0duhskgni7zgxTcJC4+GwrR5uyXf2J4F96PVBZcmUzCx2jMGlWhVEJErRCtZH OJa2FM4enNbSBkp+uY659ynegru+sKUfmFOP8Y5vCLhPVtIZk7ZkYwtt8Sh4hc8Y aUBBZSmk4KkEv8SI2C7JB89lvElShP2HuZjVki29TlJhcvftKkyY/1YUBO7j68oO Ak5XXK4WGBSlA5QiJC1xu3ttptzRltFXOmkYAV3sUtGlwYg/UcaooJKSFdtftK9w udJiFCNKU0Ag+EDl+rrlJ6SuwWm0vCEb50dnxmp92QPoZGC84eVZFHioOgRk40K8 8YIaqVN1/5sVqueVpNuOAaN90nav4rDeQdVgwymD+dIlVyc2DAHU2/gcEDawNMaG uTEjEsBfGTMlqEfVgkY7ySQv6+J+LuPvaYXBKVWdyXHZV7IF54N2IQPTyqGRiK/p dwvH34vAUzPk/Qn9WIj68p49Kfc6d6iO8MphWnw6kBSOc/m3B1Q6aQo/0qHUHVA5 04WcX8EsdJI= =75vu -----END PGP SIGNATURE----- Sat Feb 22 12:16:51 UTC 2025 I: Checking whether the package is not for us Sat Feb 22 12:16:51 UTC 2025 I: Starting 1st build on remote node codethink03-arm64.debian.net. Sat Feb 22 12:16:51 UTC 2025 I: Preparing to do remote build '1' on codethink03-arm64.debian.net. Sat Feb 22 12:16:51 UTC 2025 - checking /var/lib/jenkins/offline_nodes if codethink03-arm64.debian.net is marked as down. Sat Feb 22 12:16:51 UTC 2025 - checking via ssh if codethink03-arm64.debian.net is up. removed '/tmp/read-only-fs-test-d2hV65' ==================================================================================== Fri Mar 27 18:39:52 UTC 2026 - running /srv/jenkins/bin/reproducible_build.sh (for job /srv/jenkins/bin/reproducible_build.sh) on codethink03-arm64, called using "1 bison trixie /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe 2:3.8.2+dfsg-1" as arguments. Fri Mar 27 18:39:52 UTC 2026 - actually running "reproducible_build.sh" (md5sum 68e686e434c9ab7bc3ec047d8b309cbc) as "/tmp/jenkins-script-AE6FSMc6" $ git clone https://salsa.debian.org/qa/jenkins.debian.net.git ; more CONTRIBUTING Fri Mar 27 18:39:52 UTC 2026 I: Downloading source for trixie/bison=2:3.8.2+dfsg-1 Reading package lists... Need to get 2668 kB of source archives. Get:1 http://deb.debian.org/debian trixie/main bison 2:3.8.2+dfsg-1 (dsc) [1855 B] Get:2 http://deb.debian.org/debian trixie/main bison 2:3.8.2+dfsg-1 (tar) [2655 kB] Get:3 http://deb.debian.org/debian trixie/main bison 2:3.8.2+dfsg-1 (diff) [11.2 kB] Fetched 2668 kB in 1s (4885 kB/s) Download complete and in download only mode Reading package lists... Need to get 2668 kB of source archives. Get:1 http://deb.debian.org/debian trixie/main bison 2:3.8.2+dfsg-1 (dsc) [1855 B] Get:2 http://deb.debian.org/debian trixie/main bison 2:3.8.2+dfsg-1 (tar) [2655 kB] Get:3 http://deb.debian.org/debian trixie/main bison 2:3.8.2+dfsg-1 (diff) [11.2 kB] Fetched 2668 kB in 1s (4885 kB/s) Download complete and in download only mode ============================================================================= Building bison in trixie on arm64 on codethink03-arm64 now. Date: Fri Mar 27 18:39:53 GMT 2026 Date UTC: Fri Mar 27 18:39:53 UTC 2026 ============================================================================= W: /root/.pbuilderrc does not exist I: Logging to b1/build.log I: pbuilder: network access will be disabled during build I: Current time: Fri Mar 27 06:39:53 -12 2026 I: pbuilder-time-stamp: 1774636793 I: Building the build Environment I: extracting base tarball [/var/cache/pbuilder/trixie-reproducible-base.tgz] I: copying local configuration W: --override-config is not set; not updating apt.conf Read the manpage for details. I: mounting /proc filesystem I: mounting /sys filesystem I: creating /{dev,run}/shm I: mounting /dev/pts filesystem I: redirecting /dev/ptmx to /dev/pts/ptmx I: policy-rc.d already exists I: Copying source file I: copying [bison_3.8.2+dfsg-1.dsc] I: copying [./bison_3.8.2+dfsg.orig.tar.xz] I: copying [./bison_3.8.2+dfsg-1.debian.tar.xz] I: Extracting source dpkg-source: warning: cannot verify inline signature for ./bison_3.8.2+dfsg-1.dsc: unsupported subcommand dpkg-source: info: extracting bison in bison-3.8.2+dfsg dpkg-source: info: unpacking bison_3.8.2+dfsg.orig.tar.xz dpkg-source: info: unpacking bison_3.8.2+dfsg-1.debian.tar.xz dpkg-source: info: using patch list from debian/patches/series dpkg-source: info: applying 01_keep_stamp_files dpkg-source: info: applying 02_parse_h_dependency I: using fakeroot in build. I: Installing the build-deps I: user script /srv/workspace/pbuilder/1898584/tmp/hooks/D02_print_environment starting I: set BUILDDIR='/build/reproducible-path' BUILDUSERGECOS='first user,first room,first work-phone,first home-phone,first other' BUILDUSERNAME='pbuilder1' BUILD_ARCH='arm64' DEBIAN_FRONTEND='noninteractive' DEB_BUILD_OPTIONS='buildinfo=+all reproducible=+all parallel=12 ' DISTRIBUTION='trixie' HOME='/root' HOST_ARCH='arm64' IFS=' ' INVOCATION_ID='d67e741296294416be8d489ee5f26057' LANG='C' LANGUAGE='en_US:en' LC_ALL='C' MAIL='/var/mail/root' OPTIND='1' PATH='/usr/sbin:/usr/bin:/sbin:/bin:/usr/games' PBCURRENTCOMMANDLINEOPERATION='build' PBUILDER_OPERATION='build' PBUILDER_PKGDATADIR='/usr/share/pbuilder' PBUILDER_PKGLIBDIR='/usr/lib/pbuilder' PBUILDER_SYSCONFDIR='/etc' PPID='1898584' PS1='# ' PS2='> ' PS4='+ ' PWD='/' SHELL='/bin/bash' SHLVL='2' SUDO_COMMAND='/usr/bin/timeout -k 18.1h 18h /usr/bin/ionice -c 3 /usr/bin/nice /usr/sbin/pbuilder --build --configfile /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/pbuilderrc_ucqW --distribution trixie --hookdir /etc/pbuilder/first-build-hooks --debbuildopts -b --basetgz /var/cache/pbuilder/trixie-reproducible-base.tgz --buildresult /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/b1 --logfile b1/build.log bison_3.8.2+dfsg-1.dsc' SUDO_GID='109' SUDO_UID='104' SUDO_USER='jenkins' TERM='unknown' TZ='/usr/share/zoneinfo/Etc/GMT+12' USER='root' _='/usr/bin/systemd-run' http_proxy='http://192.168.101.4:3128' I: uname -a Linux codethink03-arm64 6.1.0-31-cloud-arm64 #1 SMP Debian 6.1.128-1 (2025-02-07) aarch64 GNU/Linux I: ls -l /bin lrwxrwxrwx 1 root root 7 Nov 22 2024 /bin -> usr/bin I: user script /srv/workspace/pbuilder/1898584/tmp/hooks/D02_print_environment finished -> Attempting to satisfy build-dependencies -> Creating pbuilder-satisfydepends-dummy package Package: pbuilder-satisfydepends-dummy Version: 0.invalid.0 Architecture: arm64 Maintainer: Debian Pbuilder Team Description: Dummy package to satisfy dependencies with aptitude - created by pbuilder This package was created automatically by pbuilder to satisfy the build-dependencies of the package being currently built. Depends: debhelper-compat (= 12), gettext, flex, m4 (>= 1.4-14), help2man dpkg-deb: building package 'pbuilder-satisfydepends-dummy' in '/tmp/satisfydepends-aptitude/pbuilder-satisfydepends-dummy.deb'. Selecting previously unselected package pbuilder-satisfydepends-dummy. (Reading database ... 19922 files and directories currently installed.) Preparing to unpack .../pbuilder-satisfydepends-dummy.deb ... Unpacking pbuilder-satisfydepends-dummy (0.invalid.0) ... dpkg: pbuilder-satisfydepends-dummy: dependency problems, but configuring anyway as you requested: pbuilder-satisfydepends-dummy depends on debhelper-compat (= 12); however: Package debhelper-compat is not installed. pbuilder-satisfydepends-dummy depends on gettext; however: Package gettext is not installed. pbuilder-satisfydepends-dummy depends on flex; however: Package flex is not installed. pbuilder-satisfydepends-dummy depends on m4 (>= 1.4-14); however: Package m4 is not installed. pbuilder-satisfydepends-dummy depends on help2man; however: Package help2man is not installed. Setting up pbuilder-satisfydepends-dummy (0.invalid.0) ... Reading package lists... Building dependency tree... Reading state information... Initializing package states... Writing extended state information... Building tag database... pbuilder-satisfydepends-dummy is already installed at the requested version (0.invalid.0) pbuilder-satisfydepends-dummy is already installed at the requested version (0.invalid.0) The following NEW packages will be installed: autoconf{a} automake{a} autopoint{a} autotools-dev{a} bsdextrautils{a} debhelper{a} dh-autoreconf{a} dh-strip-nondeterminism{a} dwz{a} file{a} flex{a} gettext{a} gettext-base{a} groff-base{a} help2man{a} intltool-debian{a} libarchive-zip-perl{a} libdebhelper-perl{a} libelf1t64{a} libfile-stripnondeterminism-perl{a} libicu72{a} liblocale-gettext-perl{a} libmagic-mgc{a} libmagic1t64{a} libpipeline1{a} libtool{a} libuchardet0{a} libunistring5{a} libxml2{a} m4{a} man-db{a} po-debconf{a} sensible-utils{a} The following packages are RECOMMENDED but will NOT be installed: curl libarchive-cpio-perl libfl-dev libltdl-dev libmail-sendmail-perl lynx wget 0 packages upgraded, 33 newly installed, 0 to remove and 0 not upgraded. Need to get 20.7 MB of archives. After unpacking 82.3 MB will be used. Writing extended state information... Get: 1 http://deb.debian.org/debian trixie/main arm64 m4 arm64 1.4.19-5 [284 kB] Get: 2 http://deb.debian.org/debian trixie/main arm64 flex arm64 2.6.4-8.2+b4 [412 kB] Get: 3 http://deb.debian.org/debian trixie/main arm64 liblocale-gettext-perl arm64 1.07-7+b1 [15.2 kB] Get: 4 http://deb.debian.org/debian trixie/main arm64 sensible-utils all 0.0.24 [24.8 kB] Get: 5 http://deb.debian.org/debian trixie/main arm64 libmagic-mgc arm64 1:5.45-3+b1 [314 kB] Get: 6 http://deb.debian.org/debian trixie/main arm64 libmagic1t64 arm64 1:5.45-3+b1 [102 kB] Get: 7 http://deb.debian.org/debian trixie/main arm64 file arm64 1:5.45-3+b1 [43.4 kB] Get: 8 http://deb.debian.org/debian trixie/main arm64 gettext-base arm64 0.23.1-1 [241 kB] Get: 9 http://deb.debian.org/debian trixie/main arm64 libuchardet0 arm64 0.0.8-1+b2 [69.2 kB] Get: 10 http://deb.debian.org/debian trixie/main arm64 groff-base arm64 1.23.0-7 [1129 kB] Get: 11 http://deb.debian.org/debian trixie/main arm64 bsdextrautils arm64 2.40.4-3 [92.0 kB] Get: 12 http://deb.debian.org/debian trixie/main arm64 libpipeline1 arm64 1.5.8-1 [40.2 kB] Get: 13 http://deb.debian.org/debian trixie/main arm64 man-db arm64 2.13.0-1 [1404 kB] Get: 14 http://deb.debian.org/debian trixie/main arm64 autoconf all 2.72-3 [493 kB] Get: 15 http://deb.debian.org/debian trixie/main arm64 autotools-dev all 20220109.1 [51.6 kB] Get: 16 http://deb.debian.org/debian trixie/main arm64 automake all 1:1.17-3 [862 kB] Get: 17 http://deb.debian.org/debian trixie/main arm64 autopoint all 0.23.1-1 [770 kB] Get: 18 http://deb.debian.org/debian trixie/main arm64 libdebhelper-perl all 13.24.1 [90.9 kB] Get: 19 http://deb.debian.org/debian trixie/main arm64 libtool all 2.5.4-3 [539 kB] Get: 20 http://deb.debian.org/debian trixie/main arm64 dh-autoreconf all 20 [17.1 kB] Get: 21 http://deb.debian.org/debian trixie/main arm64 libarchive-zip-perl all 1.68-1 [104 kB] Get: 22 http://deb.debian.org/debian trixie/main arm64 libfile-stripnondeterminism-perl all 1.14.1-2 [19.7 kB] Get: 23 http://deb.debian.org/debian trixie/main arm64 dh-strip-nondeterminism all 1.14.1-2 [8620 B] Get: 24 http://deb.debian.org/debian trixie/main arm64 libelf1t64 arm64 0.192-4 [189 kB] Get: 25 http://deb.debian.org/debian trixie/main arm64 dwz arm64 0.15-1+b1 [102 kB] Get: 26 http://deb.debian.org/debian trixie/main arm64 libunistring5 arm64 1.3-1 [449 kB] Get: 27 http://deb.debian.org/debian trixie/main arm64 libicu72 arm64 72.1-6 [9239 kB] Get: 28 http://deb.debian.org/debian trixie/main arm64 libxml2 arm64 2.12.7+dfsg+really2.9.14-0.2+b1 [630 kB] Get: 29 http://deb.debian.org/debian trixie/main arm64 gettext arm64 0.23.1-1 [1610 kB] Get: 30 http://deb.debian.org/debian trixie/main arm64 intltool-debian all 0.35.0+20060710.6 [22.9 kB] Get: 31 http://deb.debian.org/debian trixie/main arm64 po-debconf all 1.0.21+nmu1 [248 kB] Get: 32 http://deb.debian.org/debian trixie/main arm64 debhelper all 13.24.1 [920 kB] Get: 33 http://deb.debian.org/debian trixie/main arm64 help2man arm64 1.49.3+b1 [198 kB] Fetched 20.7 MB in 0s (140 MB/s) Preconfiguring packages ... Selecting previously unselected package m4. (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 19922 files and directories currently installed.) Preparing to unpack .../00-m4_1.4.19-5_arm64.deb ... Unpacking m4 (1.4.19-5) ... Selecting previously unselected package flex. Preparing to unpack .../01-flex_2.6.4-8.2+b4_arm64.deb ... Unpacking flex (2.6.4-8.2+b4) ... Selecting previously unselected package liblocale-gettext-perl. Preparing to unpack .../02-liblocale-gettext-perl_1.07-7+b1_arm64.deb ... Unpacking liblocale-gettext-perl (1.07-7+b1) ... Selecting previously unselected package sensible-utils. Preparing to unpack .../03-sensible-utils_0.0.24_all.deb ... Unpacking sensible-utils (0.0.24) ... Selecting previously unselected package libmagic-mgc. Preparing to unpack .../04-libmagic-mgc_1%3a5.45-3+b1_arm64.deb ... Unpacking libmagic-mgc (1:5.45-3+b1) ... Selecting previously unselected package libmagic1t64:arm64. Preparing to unpack .../05-libmagic1t64_1%3a5.45-3+b1_arm64.deb ... Unpacking libmagic1t64:arm64 (1:5.45-3+b1) ... Selecting previously unselected package file. Preparing to unpack .../06-file_1%3a5.45-3+b1_arm64.deb ... Unpacking file (1:5.45-3+b1) ... Selecting previously unselected package gettext-base. Preparing to unpack .../07-gettext-base_0.23.1-1_arm64.deb ... Unpacking gettext-base (0.23.1-1) ... Selecting previously unselected package libuchardet0:arm64. Preparing to unpack .../08-libuchardet0_0.0.8-1+b2_arm64.deb ... Unpacking libuchardet0:arm64 (0.0.8-1+b2) ... Selecting previously unselected package groff-base. Preparing to unpack .../09-groff-base_1.23.0-7_arm64.deb ... Unpacking groff-base (1.23.0-7) ... Selecting previously unselected package bsdextrautils. Preparing to unpack .../10-bsdextrautils_2.40.4-3_arm64.deb ... Unpacking bsdextrautils (2.40.4-3) ... Selecting previously unselected package libpipeline1:arm64. Preparing to unpack .../11-libpipeline1_1.5.8-1_arm64.deb ... Unpacking libpipeline1:arm64 (1.5.8-1) ... Selecting previously unselected package man-db. Preparing to unpack .../12-man-db_2.13.0-1_arm64.deb ... Unpacking man-db (2.13.0-1) ... Selecting previously unselected package autoconf. Preparing to unpack .../13-autoconf_2.72-3_all.deb ... Unpacking autoconf (2.72-3) ... Selecting previously unselected package autotools-dev. Preparing to unpack .../14-autotools-dev_20220109.1_all.deb ... Unpacking autotools-dev (20220109.1) ... Selecting previously unselected package automake. Preparing to unpack .../15-automake_1%3a1.17-3_all.deb ... Unpacking automake (1:1.17-3) ... Selecting previously unselected package autopoint. Preparing to unpack .../16-autopoint_0.23.1-1_all.deb ... Unpacking autopoint (0.23.1-1) ... Selecting previously unselected package libdebhelper-perl. Preparing to unpack .../17-libdebhelper-perl_13.24.1_all.deb ... Unpacking libdebhelper-perl (13.24.1) ... Selecting previously unselected package libtool. Preparing to unpack .../18-libtool_2.5.4-3_all.deb ... Unpacking libtool (2.5.4-3) ... Selecting previously unselected package dh-autoreconf. Preparing to unpack .../19-dh-autoreconf_20_all.deb ... Unpacking dh-autoreconf (20) ... Selecting previously unselected package libarchive-zip-perl. Preparing to unpack .../20-libarchive-zip-perl_1.68-1_all.deb ... Unpacking libarchive-zip-perl (1.68-1) ... Selecting previously unselected package libfile-stripnondeterminism-perl. Preparing to unpack .../21-libfile-stripnondeterminism-perl_1.14.1-2_all.deb ... Unpacking libfile-stripnondeterminism-perl (1.14.1-2) ... Selecting previously unselected package dh-strip-nondeterminism. Preparing to unpack .../22-dh-strip-nondeterminism_1.14.1-2_all.deb ... Unpacking dh-strip-nondeterminism (1.14.1-2) ... Selecting previously unselected package libelf1t64:arm64. Preparing to unpack .../23-libelf1t64_0.192-4_arm64.deb ... Unpacking libelf1t64:arm64 (0.192-4) ... Selecting previously unselected package dwz. Preparing to unpack .../24-dwz_0.15-1+b1_arm64.deb ... Unpacking dwz (0.15-1+b1) ... Selecting previously unselected package libunistring5:arm64. Preparing to unpack .../25-libunistring5_1.3-1_arm64.deb ... Unpacking libunistring5:arm64 (1.3-1) ... Selecting previously unselected package libicu72:arm64. Preparing to unpack .../26-libicu72_72.1-6_arm64.deb ... Unpacking libicu72:arm64 (72.1-6) ... Selecting previously unselected package libxml2:arm64. Preparing to unpack .../27-libxml2_2.12.7+dfsg+really2.9.14-0.2+b1_arm64.deb ... Unpacking libxml2:arm64 (2.12.7+dfsg+really2.9.14-0.2+b1) ... Selecting previously unselected package gettext. Preparing to unpack .../28-gettext_0.23.1-1_arm64.deb ... Unpacking gettext (0.23.1-1) ... Selecting previously unselected package intltool-debian. Preparing to unpack .../29-intltool-debian_0.35.0+20060710.6_all.deb ... Unpacking intltool-debian (0.35.0+20060710.6) ... Selecting previously unselected package po-debconf. Preparing to unpack .../30-po-debconf_1.0.21+nmu1_all.deb ... Unpacking po-debconf (1.0.21+nmu1) ... Selecting previously unselected package debhelper. Preparing to unpack .../31-debhelper_13.24.1_all.deb ... Unpacking debhelper (13.24.1) ... Selecting previously unselected package help2man. Preparing to unpack .../32-help2man_1.49.3+b1_arm64.deb ... Unpacking help2man (1.49.3+b1) ... Setting up libpipeline1:arm64 (1.5.8-1) ... Setting up libicu72:arm64 (72.1-6) ... Setting up bsdextrautils (2.40.4-3) ... Setting up libmagic-mgc (1:5.45-3+b1) ... Setting up libarchive-zip-perl (1.68-1) ... Setting up libdebhelper-perl (13.24.1) ... Setting up libmagic1t64:arm64 (1:5.45-3+b1) ... Setting up gettext-base (0.23.1-1) ... Setting up m4 (1.4.19-5) ... Setting up file (1:5.45-3+b1) ... Setting up libelf1t64:arm64 (0.192-4) ... Setting up autotools-dev (20220109.1) ... Setting up libunistring5:arm64 (1.3-1) ... Setting up autopoint (0.23.1-1) ... Setting up autoconf (2.72-3) ... Setting up dwz (0.15-1+b1) ... Setting up sensible-utils (0.0.24) ... Setting up libuchardet0:arm64 (0.0.8-1+b2) ... Setting up libxml2:arm64 (2.12.7+dfsg+really2.9.14-0.2+b1) ... Setting up liblocale-gettext-perl (1.07-7+b1) ... Setting up automake (1:1.17-3) ... update-alternatives: using /usr/bin/automake-1.17 to provide /usr/bin/automake (automake) in auto mode Setting up libfile-stripnondeterminism-perl (1.14.1-2) ... Setting up flex (2.6.4-8.2+b4) ... Setting up gettext (0.23.1-1) ... Setting up libtool (2.5.4-3) ... Setting up intltool-debian (0.35.0+20060710.6) ... Setting up help2man (1.49.3+b1) ... Setting up dh-autoreconf (20) ... Setting up dh-strip-nondeterminism (1.14.1-2) ... Setting up groff-base (1.23.0-7) ... Setting up po-debconf (1.0.21+nmu1) ... Setting up man-db (2.13.0-1) ... Not building database; man-db/auto-update is not 'true'. Setting up debhelper (13.24.1) ... Processing triggers for libc-bin (2.40-7) ... Reading package lists... Building dependency tree... Reading state information... Reading extended state information... Initializing package states... Writing extended state information... Building tag database... -> Finished parsing the build-deps Reading package lists... Building dependency tree... Reading state information... fakeroot is already the newest version (1.37-1). 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. I: Building the package I: Running cd /build/reproducible-path/bison-3.8.2+dfsg/ && env PATH="/usr/sbin:/usr/bin:/sbin:/bin:/usr/games" HOME="/nonexistent/first-build" dpkg-buildpackage -us -uc -b && env PATH="/usr/sbin:/usr/bin:/sbin:/bin:/usr/games" HOME="/nonexistent/first-build" dpkg-genchanges -S > ../bison_3.8.2+dfsg-1_source.changes dpkg-buildpackage: info: source package bison dpkg-buildpackage: info: source version 2:3.8.2+dfsg-1 dpkg-buildpackage: info: source distribution unstable dpkg-buildpackage: info: source changed by Chuan-kai Lin dpkg-source --before-build . dpkg-buildpackage: info: host architecture arm64 debian/rules clean dh clean debian/rules override_dh_auto_clean make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' [ ! -f /build/reproducible-path/bison-3.8.2+dfsg/Makefile ] || dh_auto_clean make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' dh_clean debian/rules binary dh binary dh_update_autotools_config debian/rules execute_before_dh_autoreconf make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' echo '@setfilename bison.info' > /build/reproducible-path/bison-3.8.2+dfsg/doc/bison.texi make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' dh_autoreconf Copying file build-aux/config.rpath Copying file m4/extern-inline.m4 Copying file m4/glibc2.m4 Copying file m4/glibc21.m4 Copying file m4/intdiv0.m4 Copying file m4/intl.m4 Copying file m4/intldir.m4 Copying file m4/intmax.m4 Copying file m4/inttypes-pri.m4 Copying file m4/lcmessage.m4 Copying file m4/longlong.m4 Copying file m4/printf-posix.m4 Copying file m4/uintmax_t.m4 Copying file gnulib-po/Makevars.template Copying file runtime-po/Makevars.template Copying file po/Makevars.template Copying file gnulib-po/remove-potcdate.sin debian/rules override_dh_auto_configure make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' dh_auto_configure -- --disable-silent-rules ./configure --build=aarch64-linux-gnu --prefix=/usr --includedir=\${prefix}/include --mandir=\${prefix}/share/man --infodir=\${prefix}/share/info --sysconfdir=/etc --localstatedir=/var --disable-option-checking --disable-silent-rules --libdir=\${prefix}/lib/aarch64-linux-gnu --runstatedir=/run --disable-maintainer-mode --disable-dependency-tracking --disable-silent-rules checking for a BSD-compatible install... /usr/bin/install -c checking whether sleep supports fractional seconds... yes checking filesystem timestamp resolution... 0.01 checking whether build environment is sane... yes checking for a race-free mkdir -p... /usr/bin/mkdir -p checking for gawk... no checking for mawk... mawk checking whether make sets $(MAKE)... yes checking whether make supports nested variables... yes checking xargs -n works... yes checking for gcc... gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... checking whether we are cross compiling... no checking for suffix of object files... o checking whether the compiler supports GNU C... yes checking whether gcc accepts -g... yes checking for gcc option to enable C11 features... none needed checking whether gcc understands -c and -o together... yes checking whether the compiler is clang... no checking for compiler option needed when checking for declarations... none checking whether make supports the include directive... yes (GNU style) checking dependency style of gcc... none checking for g++... g++ checking whether the compiler supports GNU C++... yes checking whether g++ accepts -g... yes checking for g++ option to enable C++11 features... none needed checking dependency style of g++... none checking for stdio.h... yes checking for stdlib.h... yes checking for string.h... yes checking for inttypes.h... yes checking for stdint.h... yes checking for strings.h... yes checking for sys/stat.h... yes checking for sys/types.h... yes checking for unistd.h... yes checking for wchar.h... yes checking for minix/config.h... no checking for locale.h... yes checking for sys/param.h... yes checking for sys/socket.h... yes checking for stdio_ext.h... yes checking for features.h... yes checking for getopt.h... yes checking for sys/cdefs.h... yes checking for sys/time.h... yes checking for iconv.h... yes checking for limits.h... yes checking for crtdefs.h... no checking for wctype.h... yes checking for threads.h... yes checking for math.h... yes checking for sys/mman.h... yes checking for spawn.h... yes checking for sys/ioctl.h... yes checking for sys/resource.h... yes checking for sys/times.h... yes checking for sys/wait.h... yes checking for termios.h... yes checking for dirent.h... yes checking for xlocale.h... no checking whether it is safe to define __EXTENSIONS__... yes checking whether _XOPEN_SOURCE should be defined... no checking build system type... aarch64-unknown-linux-gnu checking host system type... aarch64-unknown-linux-gnu checking how to run the C preprocessor... gcc -E checking for egrep -e... /usr/bin/grep -E checking for Minix Amsterdam compiler... no checking for ar... ar checking for ranlib... ranlib checking for special C compiler options needed for large files... no checking for _FILE_OFFSET_BITS value needed for large files... no checking for ld used by gcc... /usr/bin/ld checking if the linker (/usr/bin/ld) is GNU ld... yes checking for shared library run path origin... done checking 32-bit host C ABI... no checking for ELF binary format... yes checking for the common suffixes of directories in the library search path... lib,lib,lib checking for libtextstyle... no checking for inline... inline checking for tcdrain... yes checking for canonicalize_file_name... yes checking for faccessat... yes checking for realpath... yes checking for lstat... yes checking for readlinkat... yes checking for _set_invalid_parameter_handler... no checking for fchdir... yes checking for fcntl... yes checking for symlink... yes checking for ffsl... yes checking for vasnprintf... no checking for snprintf... yes checking for fsync... yes checking for microuptime... no checking for nanouptime... no checking for getprogname... no checking for getexecname... no checking for getrusage... yes checking for gettimeofday... yes checking for iswcntrl... yes checking for iswblank... yes checking for mbsinit... yes checking for mbrtowc... yes checking for isascii... yes checking for mprotect... yes checking for obstack_printf... yes checking for strerror_r... yes checking for __xpg_strerror_r... yes checking for pipe... yes checking for pipe2... yes checking for posix_spawn_file_actions_addchdir_np... yes checking for posix_spawn_file_actions_addchdir... no checking for readlink... yes checking for setenv... yes checking for link... yes checking for sigaction... yes checking for sigaltstack... yes checking for siginterrupt... yes checking for stpncpy... yes checking for strndup... yes checking for wcwidth... yes checking for fdopendir... yes checking for mempcpy... yes checking for __fseterr... no checking for fstatat... yes checking for getdelim... yes checking for getdtablesize... yes checking for openat... yes checking for catgets... yes checking for setlocale... yes checking whether pragma GCC diagnostic push works... yes checking whether C++ compiler handles -Werror -Wunknown-warning-option... no checking whether C++ compiler handles -fno-exceptions... yes checking whether C++ compiler accepts -std=c++98... yes checking whether C++ compiler accepts -std=c++03... yes checking whether C++ compiler accepts -std=c++11... yes checking whether C++ compiler accepts -std=c++14... yes checking whether C++ compiler accepts -std=c++17... yes checking whether C++ compiler accepts -std=c++20... yes checking whether C++ compiler accepts -std=c++2b... yes checking whether gcc supports POSIXLY_CORRECT=1... yes checking whether g++ builds executables that work... yes checking whether g++ supports POSIXLY_CORRECT=1... yes checking for dmd... no checking for -g... no checking for Java compiler... no checking for Java virtual machine... no checking for flex... flex checking whether lex is flex... yes checking whether flex supports --header=FILE... yes checking lex output file root... lex.yy checking lex library... none needed checking whether yytext is a pointer... no checking for bison... no checking for byacc... no checking for ranlib... (cached) ranlib checking for GNU M4 that supports accurate traces... /usr/bin/m4 checking whether /usr/bin/m4 accepts --gnu... yes checking how m4 supports trace files... --debugfile checking for perl... /usr/bin/perl checking for xsltproc... no checking for inline... (cached) inline checking for size_t... yes checking for working alloca.h... yes checking for alloca... yes checking whether malloc is ptrdiff_t safe... yes checking whether malloc, realloc, calloc set errno on failure... yes checking whether lstat correctly handles trailing slash... yes checking whether // is distinct from /... no checking whether realpath works... yes checking for getcwd... yes checking for C/C++ restrict keyword... __restrict__ checking if environ is properly declared... yes checking whether the preprocessor supports include_next... yes checking whether source code line length is unlimited... yes checking for complete errno.h... yes checking for gcc options needed to detect all undeclared functions... none needed checking whether strerror_r is declared... yes checking whether strerror_r returns char *... yes checking for mode_t... yes checking for sig_atomic_t... yes checking for working fcntl.h... yes checking for pid_t... yes checking for eaccess... yes checking for stdint.h... yes checking for inttypes.h... yes checking whether printf supports size specifiers as in C99... yes checking whether printf supports 'long double' arguments... yes checking whether printf supports infinite 'double' arguments... yes checking whether byte ordering is bigendian... no checking whether long double and double are the same... no checking whether printf supports infinite 'long double' arguments... yes checking whether printf supports the 'a' and 'A' directives... yes checking whether printf supports the 'F' directive... yes checking whether printf supports the 'n' directive... no checking whether printf supports the 'ls' directive... yes checking whether printf supports POSIX/XSI format strings with positions... yes checking whether printf supports the grouping flag... yes checking whether printf supports the left-adjust flag correctly... yes checking whether printf supports the zero flag correctly... yes checking whether printf supports large precisions... yes checking whether the compiler produces multi-arch binaries... no checking whether printf survives out-of-memory conditions... yes checking for wchar_t... yes checking for wint_t... yes checking whether wint_t is large enough... yes checking for intmax_t... yes checking where to find the exponent in a 'double'... word 1 bit 20 checking whether snprintf returns a byte count as in C99... yes checking whether snprintf truncates the result as in C99... yes checking for snprintf... (cached) yes checking for strnlen... yes checking for wcslen... yes checking for wcsnlen... yes checking for mbrtowc... (cached) yes checking for wcrtomb... yes checking whether _snprintf is declared... no checking whether frexp() can be used without linking with libm... yes checking whether alarm is declared... yes checking whether getcwd (NULL, 0) allocates memory for result... yes checking for getcwd with POSIX signature... yes checking whether getcwd is declared... yes checking for d_ino member in directory struct... yes checking for arithmetic hrtime_t... no checking for getopt.h... (cached) yes checking for getopt_long_only... yes checking whether getopt is POSIX compatible... yes checking for working GNU getopt function... yes checking for working GNU getopt_long function... yes checking for struct timeval... yes checking for wide-enough struct timeval.tv_sec member... yes checking for iconv... yes checking for working iconv... yes checking whether iconv is compatible with its POSIX signature... yes checking whether limits.h has WORD_BIT, BOOL_WIDTH etc.... yes checking whether stdint.h conforms to C99... yes checking whether stdint.h works without ISO C predefines... yes checking whether stdint.h has UINTMAX_WIDTH etc.... yes checking whether INT32_MAX < INTMAX_MAX... yes checking whether INT64_MAX == LONG_MAX... yes checking whether UINT32_MAX < UINTMAX_MAX... yes checking whether UINT64_MAX == ULONG_MAX... yes checking where to find the exponent in a 'float'... word 0 bit 23 checking whether isnan(float) can be used without linking with libm... yes checking whether isnan(float) works... yes checking whether isnan(double) can be used without linking with libm... yes checking whether isnan(long double) can be used without linking with libm... yes checking whether isnanl works... yes checking whether iswcntrl works... yes checking for towlower... yes checking for wctype_t... yes checking for wctrans_t... yes checking for nl_langinfo and CODESET... yes checking for a traditional french locale... fr_FR checking for a traditional japanese locale... ja_JP.EUC-JP checking for a french Unicode locale... fr_FR.UTF-8 checking for a transitional chinese locale... zh_CN.GB18030 checking whether ldexp() can be used without linking with libm... yes checking whether imported symbols can be declared weak... yes checking for pthread.h... yes checking for pthread_kill in -lpthread... yes checking whether POSIX threads API is available... yes checking for multithread API to use... posix checking for a sed that does not truncate output... /usr/bin/sed checking for grep that handles long lines and -e... /usr/bin/grep checking whether NAN macro works... yes checking whether HUGE_VAL works... yes checking for mbstate_t... yes checking for mmap... yes checking for MAP_ANONYMOUS... yes checking whether memchr works... yes checking whether defines MIN and MAX... no checking whether defines MIN and MAX... yes checking whether obstack_printf is declared... yes checking for O_CLOEXEC... yes checking for promoted mode_t type... mode_t checking whether strerror(0) succeeds... yes checking for strerror_r with POSIX signature... no checking whether __xpg_strerror_r works... yes checking for library containing posix_spawn... none required checking for posix_spawn... yes checking whether posix_spawn is declared... yes checking whether posix_spawn works... yes checking whether posix_spawn rejects scripts without shebang... yes checking whether posix_spawnp rejects scripts without shebang... yes checking whether posix_spawnattr_setschedpolicy is supported... yes checking whether posix_spawnattr_setschedparam is supported... yes checking for ptrdiff_t... yes checking for egrep... /usr/bin/grep -E checking whether C symbols are prefixed with underscore at the linker level... no checking for sigset_t... yes checking for shared library path variable... LD_LIBRARY_PATH checking whether to activate relocatable installation... no checking whether malloc (0) returns nonnull... yes checking whether setenv is declared... yes checking for sched.h... yes checking for struct sched_param... yes checking for uid_t... yes checking for gid_t... yes checking for volatile sig_atomic_t... yes checking for sighandler_t... yes checking whether snprintf is declared... yes checking for posix_spawnattr_t... yes checking for posix_spawn_file_actions_t... yes checking whether stat file-mode macros are broken... no checking for nlink_t... yes checking for stdbool.h that conforms to C99... yes checking for _Bool... yes checking for good max_align_t... yes checking whether NULL can be used in arbitrary expressions... yes checking whether fcloseall is declared... yes checking which flavor of printf attribute matches inttypes macros... system checking whether ecvt is declared... yes checking whether fcvt is declared... yes checking whether gcvt is declared... yes checking whether stpncpy is declared... yes checking whether strdup is declared... yes checking whether strndup is declared... yes checking whether declares ioctl... yes checking for struct tms... yes checking for struct timespec in ... yes checking for TIME_UTC in ... yes checking whether execvpe is declared... yes checking whether clearerr_unlocked is declared... yes checking whether feof_unlocked is declared... yes checking whether ferror_unlocked is declared... yes checking whether fflush_unlocked is declared... yes checking whether fgets_unlocked is declared... yes checking whether fputc_unlocked is declared... yes checking whether fputs_unlocked is declared... yes checking whether fread_unlocked is declared... yes checking whether fwrite_unlocked is declared... yes checking whether getc_unlocked is declared... yes checking whether getchar_unlocked is declared... yes checking whether putc_unlocked is declared... yes checking whether putchar_unlocked is declared... yes checking whether unsetenv is declared... yes checking whether vsnprintf is declared... yes checking whether uses 'inline' correctly... yes checking whether wcsdup is declared... yes checking POSIX termios... yes checking whether use of TIOCGWINSZ requires termios.h... no checking whether fchdir is declared... yes checking whether getdelim is declared... yes checking whether getdtablesize is declared... yes checking whether getline is declared... yes checking whether setlocale (LC_ALL, NULL) is multithread-safe... yes checking whether setlocale (category, NULL) is multithread-safe... yes checking whether locale.h defines locale_t... yes checking whether locale.h conforms to POSIX:2001... yes checking whether struct lconv is properly defined... yes checking whether memrchr is declared... yes checking whether strnlen is declared... yes checking for alloca as a compiler built-in... yes checking whether to enable assertions... yes checking for __builtin_expect... yes checking whether calloc (0, n) and calloc (n, 0) return nonnull... yes checking for library containing clock_gettime... none required checking for clock_gettime... yes checking for clock_settime... yes checking whether // is distinct from /... (cached) no checking whether dup2 works... yes checking for error_at_line... yes checking whether fcntl handles F_DUPFD correctly... yes checking whether fcntl understands F_DUPFD_CLOEXEC... needs runtime check checking whether conversion from 'int' to 'long double' works... yes checking whether fopen recognizes a trailing slash... yes checking whether fopen supports the mode character 'x'... yes checking whether fopen supports the mode character 'e'... yes checking for __fpending... yes checking whether __fpending is declared... yes checking for ptrdiff_t... (cached) yes checking whether free is known to preserve errno... yes checking whether frexp works... yes checking whether frexpl is declared... yes checking whether frexpl() can be used without linking with libm... yes checking whether frexpl works... yes checking whether getcwd handles long file names properly... yes checking for getpagesize... yes checking whether getcwd succeeds when 4k < cwd_length < 16k... yes checking whether gethrtime is declared... no checking whether CLOCK_MONOTONIC or CLOCK_REALTIME is defined... yes checking whether program_invocation_name is declared... yes checking whether program_invocation_short_name is declared... yes checking whether __argv is declared... no checking for gettimeofday with POSIX signature... yes checking whether the compiler generally respects inline... yes checking whether isnan macro works... yes checking whether isnan(double) can be used without linking with libm... (cached) yes checking whether isnan(double) can be used without linking with libm... (cached) yes checking whether isnan(float) can be used without linking with libm... (cached) yes checking whether isnan(float) works... (cached) yes checking whether isnan(long double) can be used without linking with libm... (cached) yes checking whether isnanl works... (cached) yes checking whether isnan(long double) can be used without linking with libm... (cached) yes checking whether isnanl works... (cached) yes checking whether iswblank is declared... yes checking whether iswdigit is ISO C compliant... yes checking whether iswxdigit is ISO C compliant... yes checking whether ldexpl is declared... yes checking whether ldexpl() can be used without linking with libm... yes checking whether ldexpl works... yes checking whether the compiler supports the __inline keyword... yes checking for pthread_rwlock_t... yes checking whether pthread_rwlock_rdlock prefers a writer to a reader... no checking whether malloc (0) returns nonnull... (cached) yes checking whether mbrtowc handles incomplete characters... yes checking whether mbrtowc works as well as mbtowc... yes checking whether mbrtowc handles a NULL pwc argument... yes checking whether mbrtowc handles a NULL string argument... yes checking whether mbrtowc has a correct return value... yes checking whether mbrtowc returns 0 when parsing a NUL character... yes checking whether mbrtowc stores incomplete characters... no checking whether mbrtowc works on empty input... yes checking whether the C locale is free of encoding errors... no checking whether mbrtowc handles incomplete characters... (cached) yes checking whether mbrtowc works as well as mbtowc... (cached) yes checking whether mbswidth is declared in ... no checking for mbstate_t... (cached) yes checking for mempcpy... (cached) yes checking for obstacks that work with any size object... no checking whether open recognizes a trailing slash... yes checking whether perror matches strerror... yes checking whether posix_spawn_file_actions_addclose works... yes checking whether posix_spawn_file_actions_adddup2 works... yes checking whether posix_spawn_file_actions_addopen works... yes checking whether frexp works... (cached) yes checking whether ldexp can be used without linking with libm... (cached) yes checking whether frexpl() can be used without linking with libm... (cached) yes checking whether frexpl works... (cached) yes checking whether frexpl is declared... (cached) yes checking whether ldexpl() can be used without linking with libm... (cached) yes checking whether ldexpl works... (cached) yes checking whether ldexpl is declared... (cached) yes checking whether program_invocation_name is declared... (cached) yes checking whether program_invocation_short_name is declared... (cached) yes checking for raise... yes checking for sigprocmask... yes checking for rawmemchr... yes checking for readline... no checking for readline/readline.h... no checking for readline/history.h... no checking whether readlink signature is correct... yes checking whether readlink handles trailing slash correctly... yes checking whether readlink truncates results correctly... yes checking whether realloc (0, 0) returns nonnull... yes checking for reallocarray... yes checking for getcwd... (cached) yes checking whether free is known to preserve errno... (cached) yes checking for mempcpy... (cached) yes checking for rawmemchr... (cached) yes checking for search.h... yes checking for tsearch... yes checking whether rename honors trailing slash on destination... yes checking whether rename honors trailing slash on source... yes checking whether rename manages hard links correctly... yes checking whether rename manages existing destinations correctly... yes checking for struct sigaction.sa_sigaction... yes checking for signbit macro... yes checking for signbit compiler built-ins... yes checking for sigprocmask... (cached) yes checking for stdint.h... (cached) yes checking for SIZE_MAX... yes checking for snprintf... (cached) yes checking whether snprintf respects a size of 1... yes checking whether printf supports POSIX/XSI format strings with positions... (cached) yes checking for snprintf... (cached) yes checking whether snprintf fully supports the 'n' directive... no checking whether snprintf respects a size of 1... (cached) yes checking whether vsnprintf respects a zero size as in C99... yes checking for ptrdiff_t... (cached) yes checking for ptrdiff_t... (cached) yes checking for ssize_t... yes checking whether stat handles trailing slashes on files... yes checking for working stdalign.h... yes checking for stpcpy... yes checking for working stpncpy... yes checking for working strerror function... yes checking for working strndup... yes checking whether strtod obeys C99... yes checking for strverscmp... yes checking for sys/single_threaded.h... yes checking whether unlink honors trailing slashes... yes checking whether unlink of a parent directory fails as it should... guessing yes checking for unsetenv... yes checking for unsetenv() return type... int checking whether unsetenv obeys POSIX... yes checking for ptrdiff_t... (cached) yes checking for vasprintf... yes checking for vasprintf... (cached) yes checking for ptrdiff_t... (cached) yes checking for vsnprintf... yes checking whether snprintf respects a size of 1... (cached) yes checking whether printf supports POSIX/XSI format strings with positions... (cached) yes checking for vsnprintf... (cached) yes checking whether snprintf fully supports the 'n' directive... (cached) no checking whether snprintf respects a size of 1... (cached) yes checking whether vsnprintf respects a zero size as in C99... (cached) yes checking for ptrdiff_t... (cached) yes checking for ptrdiff_t... (cached) yes checking for waitid... yes checking whether wcwidth is declared... yes checking whether wcwidth works reasonably in UTF-8 locales... yes checking whether use of TIOCGWINSZ requires sys/ioctl.h... yes checking whether use of TIOCGWINSZ requires termios.h... (cached) no checking whether use of struct winsize requires sys/ptem.h... no checking for stdint.h... (cached) yes checking whether getdtablesize works... yes checking whether setlocale (LC_ALL, NULL) is multithread-safe... (cached) yes checking whether setlocale (category, NULL) is multithread-safe... (cached) yes checking for ptrdiff_t... (cached) yes checking for getline... yes checking for working getline function... yes checking whether NLS is requested... yes checking for msgfmt... /usr/bin/msgfmt checking for gmsgfmt... /usr/bin/msgfmt checking for xgettext... /usr/bin/xgettext checking for msgmerge... /usr/bin/msgmerge checking for CFPreferencesCopyAppValue... no checking for CFLocaleCopyCurrent... no checking for GNU gettext in libc... yes checking whether to use NLS... yes checking where the gettext function comes from... libc checking for valgrind... no checking Valgrind suppression file... checking that generated files are newer than configure... done configure: creating ./config.status config.status: creating src/yacc config.status: creating javacomp.sh config.status: creating javaexec.sh config.status: creating gnulib-po/Makefile.in config.status: creating runtime-po/Makefile.in config.status: creating etc/bench.pl config.status: creating tests/atlocal config.status: creating tests/bison config.status: creating Makefile config.status: creating po/Makefile.in config.status: creating doc/yacc.1 config.status: creating lib/config.h config.status: executing depfiles commands config.status: executing po-directories commands config.status: creating gnulib-po/POTFILES config.status: creating gnulib-po/Makefile config.status: creating runtime-po/POTFILES config.status: creating runtime-po/Makefile config.status: creating po/POTFILES config.status: creating po/Makefile config.status: executing tests/atconfig commands make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' debian/rules execute_before_dh_auto_build make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' # Touch all files in the dependency tree of bison.info to # inhibit makeinfo invocation in the build process. install -d /build/reproducible-path/bison-3.8.2+dfsg/doc/figs touch --date="Jan 01 2000" \ /build/reproducible-path/bison-3.8.2+dfsg/doc/bison.info \ /build/reproducible-path/bison-3.8.2+dfsg/doc/bison.help \ /build/reproducible-path/bison-3.8.2+dfsg/doc/figs/example.txt \ /build/reproducible-path/bison-3.8.2+dfsg/doc/figs/example-reduce.txt \ /build/reproducible-path/bison-3.8.2+dfsg/doc/figs/example-shift.txt \ /build/reproducible-path/bison-3.8.2+dfsg/doc/*.texi \ /build/reproducible-path/bison-3.8.2+dfsg/build-aux/cross-options.pl \ /build/reproducible-path/bison-3.8.2+dfsg/src/getargs.c make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' dh_auto_build make -j12 make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' rm -f examples/c/reccalc/scan.stamp examples/c/reccalc/scan.stamp.tmp rm -f lib/alloca.h-t lib/alloca.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''HAVE_ALLOCA_H''@|1|g' < ./lib/alloca.in.h; \ } > lib/alloca.h-t && \ mv -f lib/alloca.h-t lib/alloca.h /usr/bin/mkdir -p examples/c/reccalc rm -f lib/configmake.h-t && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ echo '#if HAVE_WINSOCK2_H'; \ echo '# include /* avoid mingw pollution on DATADIR */'; \ echo '#endif'; \ echo '#define PREFIX "/usr"'; \ echo '#define EXEC_PREFIX "/usr"'; \ echo '#define BINDIR "/usr/bin"'; \ echo '#define SBINDIR "/usr/sbin"'; \ echo '#define LIBEXECDIR "/usr/libexec"'; \ echo '#define DATAROOTDIR "/usr/share"'; \ echo '#define DATADIR "/usr/share"'; \ echo '#define SYSCONFDIR "/etc"'; \ echo '#define SHAREDSTATEDIR "/usr/com"'; \ echo '#define LOCALSTATEDIR "/var"'; \ echo '#define RUNSTATEDIR "/run"'; \ echo '#define INCLUDEDIR "/usr/include"'; \ echo '#define OLDINCLUDEDIR "/usr/include"'; \ echo '#define DOCDIR "/usr/share/doc/bison"'; \ echo '#define INFODIR "/usr/share/info"'; \ echo '#define HTMLDIR "/usr/share/doc/bison"'; \ echo '#define DVIDIR "/usr/share/doc/bison"'; \ echo '#define PDFDIR "/usr/share/doc/bison"'; \ echo '#define PSDIR "/usr/share/doc/bison"'; \ echo '#define LIBDIR "/usr/lib/aarch64-linux-gnu"'; \ echo '#define LISPDIR "/usr/share/emacs/site-lisp"'; \ echo '#define LOCALEDIR "/usr/share/locale"'; \ echo '#define MANDIR "/usr/share/man"'; \ echo '#define MANEXT ""'; \ echo '#define PKGDATADIR "/usr/share/bison"'; \ echo '#define PKGINCLUDEDIR "/usr/include/bison"'; \ echo '#define PKGLIBDIR "/usr/lib/aarch64-linux-gnu/bison"'; \ echo '#define PKGLIBEXECDIR "/usr/libexec/bison"'; \ } | sed '/""/d' > lib/configmake.h-t && \ mv -f lib/configmake.h-t lib/configmake.h touch examples/c/reccalc/scan.stamp.tmp flex -oexamples/c/reccalc/scan.c --header=examples/c/reccalc/scan.h ./examples/c/reccalc/scan.l rm -f lib/fcntl.h-t lib/fcntl.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_FCNTL_H''@||g' \ -e 's/@''GNULIB_CREAT''@/0/g' \ -e 's/@''GNULIB_FCNTL''@/1/g' \ -e 's/@''GNULIB_NONBLOCKING''@/0/g' \ -e 's/@''GNULIB_OPEN''@/1/g' \ -e 's/@''GNULIB_OPENAT''@/0/g' \ -e 's/@''GNULIB_MDA_CREAT''@/1/g' \ -e 's/@''GNULIB_MDA_OPEN''@/1/g' \ -e 's|@''HAVE_FCNTL''@|1|g' \ -e 's|@''HAVE_OPENAT''@|1|g' \ -e 's|@''REPLACE_CREAT''@|0|g' \ -e 's|@''REPLACE_FCNTL''@|1|g' \ -e 's|@''REPLACE_OPEN''@|0|g' \ -e 's|@''REPLACE_OPENAT''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/fcntl.in.h; \ } > lib/fcntl.h-t && \ mv lib/fcntl.h-t lib/fcntl.h rm -f lib/iconv.h-t lib/iconv.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_ICONV_H''@||g' \ -e 's/@''GNULIB_ICONV''@/1/g' \ -e 's|@''ICONV_CONST''@||g' \ -e 's|@''REPLACE_ICONV''@|0|g' \ -e 's|@''REPLACE_ICONV_OPEN''@|0|g' \ -e 's|@''REPLACE_ICONV_UTF''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/iconv.in.h; \ } > lib/iconv.h-t && \ mv lib/iconv.h-t lib/iconv.h rm -f lib/inttypes.h-t lib/inttypes.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's/@''HAVE_INTTYPES_H''@/1/g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_INTTYPES_H''@||g' \ -e 's/@''APPLE_UNIVERSAL_BUILD''@/0/g' \ -e 's/@''PRIPTR_PREFIX''@/"l"/g' \ -e 's/@''GNULIB_IMAXABS''@/0/g' \ -e 's/@''GNULIB_IMAXDIV''@/0/g' \ -e 's/@''GNULIB_STRTOIMAX''@/0/g' \ -e 's/@''GNULIB_STRTOUMAX''@/0/g' \ -e 's/@''HAVE_DECL_IMAXABS''@/1/g' \ -e 's/@''HAVE_DECL_IMAXDIV''@/1/g' \ -e 's/@''HAVE_DECL_STRTOIMAX''@/1/g' \ -e 's/@''HAVE_DECL_STRTOUMAX''@/1/g' \ -e 's/@''HAVE_IMAXDIV_T''@/1/g' \ -e 's/@''REPLACE_STRTOIMAX''@/0/g' \ -e 's/@''REPLACE_STRTOUMAX''@/0/g' \ -e 's/@''INT32_MAX_LT_INTMAX_MAX''@/1/g' \ -e 's/@''INT64_MAX_EQ_LONG_MAX''@/1/g' \ -e 's/@''UINT32_MAX_LT_UINTMAX_MAX''@/1/g' \ -e 's/@''UINT64_MAX_EQ_ULONG_MAX''@/1/g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/inttypes.in.h; \ } > lib/inttypes.h-t && \ mv lib/inttypes.h-t lib/inttypes.h mv examples/c/reccalc/scan.stamp.tmp examples/c/reccalc/scan.stamp rm -f lib/textstyle.h-t lib/textstyle.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ cat ./lib/textstyle.in.h; \ } > lib/textstyle.h-t && \ mv lib/textstyle.h-t lib/textstyle.h rm -f lib/limits.h-t lib/limits.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_LIMITS_H''@||g' \ < ./lib/limits.in.h; \ } > lib/limits.h-t && \ mv lib/limits.h-t lib/limits.h rm -f lib/locale.h-t lib/locale.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_LOCALE_H''@||g' \ -e 's/@''GNULIB_LOCALECONV''@/0/g' \ -e 's/@''GNULIB_SETLOCALE''@/0/g' \ -e 's/@''GNULIB_SETLOCALE_NULL''@/1/g' \ -e 's/@''GNULIB_DUPLOCALE''@/0/g' \ -e 's/@''GNULIB_LOCALENAME''@/0/g' \ -e 's|@''HAVE_NEWLOCALE''@|1|g' \ -e 's|@''HAVE_DUPLOCALE''@|1|g' \ -e 's|@''HAVE_FREELOCALE''@|1|g' \ -e 's|@''HAVE_XLOCALE_H''@|0|g' \ -e 's|@''REPLACE_LOCALECONV''@|0|g' \ -e 's|@''REPLACE_SETLOCALE''@|0|g' \ -e 's|@''REPLACE_NEWLOCALE''@|0|g' \ -e 's|@''REPLACE_DUPLOCALE''@|0|g' \ -e 's|@''REPLACE_FREELOCALE''@|0|g' \ -e 's|@''REPLACE_STRUCT_LCONV''@|0|g' \ -e 's|@''LOCALENAME_ENHANCE_LOCALE_FUNCS''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/locale.in.h; \ } > lib/locale.h-t && \ mv lib/locale.h-t lib/locale.h rm -f lib/math.h-t lib/math.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT_AS_FIRST_DIRECTIVE''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_AS_FIRST_DIRECTIVE_MATH_H''@||g' \ -e 's/@''GNULIB_ACOSF''@/0/g' \ -e 's/@''GNULIB_ACOSL''@/0/g' \ -e 's/@''GNULIB_ASINF''@/0/g' \ -e 's/@''GNULIB_ASINL''@/0/g' \ -e 's/@''GNULIB_ATANF''@/0/g' \ -e 's/@''GNULIB_ATANL''@/0/g' \ -e 's/@''GNULIB_ATAN2F''@/0/g' \ -e 's/@''GNULIB_CBRT''@/0/g' \ -e 's/@''GNULIB_CBRTF''@/0/g' \ -e 's/@''GNULIB_CBRTL''@/0/g' \ -e 's/@''GNULIB_CEIL''@/0/g' \ -e 's/@''GNULIB_CEILF''@/0/g' \ -e 's/@''GNULIB_CEILL''@/0/g' \ -e 's/@''GNULIB_COPYSIGN''@/0/g' \ -e 's/@''GNULIB_COPYSIGNF''@/0/g' \ -e 's/@''GNULIB_COPYSIGNL''@/0/g' \ -e 's/@''GNULIB_COSF''@/0/g' \ -e 's/@''GNULIB_COSL''@/0/g' \ -e 's/@''GNULIB_COSHF''@/0/g' \ -e 's/@''GNULIB_EXPF''@/0/g' \ -e 's/@''GNULIB_EXPL''@/0/g' \ -e 's/@''GNULIB_EXP2''@/0/g' \ -e 's/@''GNULIB_EXP2F''@/0/g' \ -e 's/@''GNULIB_EXP2L''@/0/g' \ -e 's/@''GNULIB_EXPM1''@/0/g' \ -e 's/@''GNULIB_EXPM1F''@/0/g' \ -e 's/@''GNULIB_EXPM1L''@/0/g' \ -e 's/@''GNULIB_FABSF''@/0/g' \ -e 's/@''GNULIB_FABSL''@/0/g' \ -e 's/@''GNULIB_FLOOR''@/0/g' \ -e 's/@''GNULIB_FLOORF''@/0/g' \ -e 's/@''GNULIB_FLOORL''@/0/g' \ -e 's/@''GNULIB_FMA''@/0/g' \ -e 's/@''GNULIB_FMAF''@/0/g' \ -e 's/@''GNULIB_FMAL''@/0/g' \ -e 's/@''GNULIB_FMOD''@/0/g' \ -e 's/@''GNULIB_FMODF''@/0/g' \ -e 's/@''GNULIB_FMODL''@/0/g' \ -e 's/@''GNULIB_FREXPF''@/0/g' \ -e 's/@''GNULIB_FREXP''@/1/g' \ -e 's/@''GNULIB_FREXPL''@/1/g' \ -e 's/@''GNULIB_HYPOT''@/0/g' \ -e 's/@''GNULIB_HYPOTF''@/0/g' \ -e 's/@''GNULIB_HYPOTL''@/0/g' \ < ./lib/math.in.h | \ sed -e 's/@''GNULIB_ILOGB''@/0/g' \ -e 's/@''GNULIB_ILOGBF''@/0/g' \ -e 's/@''GNULIB_ILOGBL''@/0/g' \ -e 's/@''GNULIB_ISFINITE''@/0/g' \ -e 's/@''GNULIB_ISINF''@/0/g' \ -e 's/@''GNULIB_ISNAN''@/1/g' \ -e 's/@''GNULIB_ISNANF''@/1/g' \ -e 's/@''GNULIB_ISNAND''@/1/g' \ -e 's/@''GNULIB_ISNANL''@/1/g' \ -e 's/@''GNULIB_LDEXPF''@/0/g' \ -e 's/@''GNULIB_LDEXPL''@/1/g' \ -e 's/@''GNULIB_LOG''@/0/g' \ -e 's/@''GNULIB_LOGF''@/0/g' \ -e 's/@''GNULIB_LOGL''@/0/g' \ -e 's/@''GNULIB_LOG10''@/0/g' \ -e 's/@''GNULIB_LOG10F''@/0/g' \ -e 's/@''GNULIB_LOG10L''@/0/g' \ -e 's/@''GNULIB_LOG1P''@/0/g' \ -e 's/@''GNULIB_LOG1PF''@/0/g' \ -e 's/@''GNULIB_LOG1PL''@/0/g' \ -e 's/@''GNULIB_LOG2''@/0/g' \ -e 's/@''GNULIB_LOG2F''@/0/g' \ -e 's/@''GNULIB_LOG2L''@/0/g' \ -e 's/@''GNULIB_LOGB''@/0/g' \ -e 's/@''GNULIB_LOGBF''@/0/g' \ -e 's/@''GNULIB_LOGBL''@/0/g' \ -e 's/@''GNULIB_MODF''@/0/g' \ -e 's/@''GNULIB_MODFF''@/0/g' \ -e 's/@''GNULIB_MODFL''@/0/g' \ -e 's/@''GNULIB_POWF''@/0/g' \ -e 's/@''GNULIB_REMAINDER''@/0/g' \ -e 's/@''GNULIB_REMAINDERF''@/0/g' \ -e 's/@''GNULIB_REMAINDERL''@/0/g' \ -e 's/@''GNULIB_RINT''@/0/g' \ -e 's/@''GNULIB_RINTF''@/0/g' \ -e 's/@''GNULIB_RINTL''@/0/g' \ -e 's/@''GNULIB_ROUND''@/0/g' \ -e 's/@''GNULIB_ROUNDF''@/0/g' \ -e 's/@''GNULIB_ROUNDL''@/0/g' \ -e 's/@''GNULIB_SIGNBIT''@/1/g' \ -e 's/@''GNULIB_SINF''@/0/g' \ -e 's/@''GNULIB_SINL''@/0/g' \ -e 's/@''GNULIB_SINHF''@/0/g' \ -e 's/@''GNULIB_SQRTF''@/0/g' \ -e 's/@''GNULIB_SQRTL''@/0/g' \ -e 's/@''GNULIB_TANF''@/0/g' \ -e 's/@''GNULIB_TANL''@/0/g' \ -e 's/@''GNULIB_TANHF''@/0/g' \ -e 's/@''GNULIB_TRUNC''@/0/g' \ -e 's/@''GNULIB_TRUNCF''@/0/g' \ -e 's/@''GNULIB_TRUNCL''@/0/g' \ -e 's/@''GNULIB_MDA_J0''@/1/g' \ -e 's/@''GNULIB_MDA_J1''@/1/g' \ -e 's/@''GNULIB_MDA_JN''@/1/g' \ -e 's/@''GNULIB_MDA_Y0''@/1/g' \ -e 's/@''GNULIB_MDA_Y1''@/1/g' \ -e 's/@''GNULIB_MDA_YN''@/1/g' \ | \ sed -e 's|@''HAVE_ACOSF''@|1|g' \ -e 's|@''HAVE_ACOSL''@|1|g' \ -e 's|@''HAVE_ASINF''@|1|g' \ -e 's|@''HAVE_ASINL''@|1|g' \ -e 's|@''HAVE_ATANF''@|1|g' \ -e 's|@''HAVE_ATANL''@|1|g' \ -e 's|@''HAVE_ATAN2F''@|1|g' \ -e 's|@''HAVE_CBRT''@|1|g' \ -e 's|@''HAVE_CBRTF''@|1|g' \ -e 's|@''HAVE_CBRTL''@|1|g' \ -e 's|@''HAVE_COPYSIGN''@|1|g' \ -e 's|@''HAVE_COPYSIGNL''@|1|g' \ -e 's|@''HAVE_COSF''@|1|g' \ -e 's|@''HAVE_COSL''@|1|g' \ -e 's|@''HAVE_COSHF''@|1|g' \ -e 's|@''HAVE_EXPF''@|1|g' \ -e 's|@''HAVE_EXPL''@|1|g' \ -e 's|@''HAVE_EXPM1''@|1|g' \ -e 's|@''HAVE_EXPM1F''@|1|g' \ -e 's|@''HAVE_FABSF''@|1|g' \ -e 's|@''HAVE_FABSL''@|1|g' \ -e 's|@''HAVE_FMA''@|1|g' \ -e 's|@''HAVE_FMAF''@|1|g' \ -e 's|@''HAVE_FMAL''@|1|g' \ -e 's|@''HAVE_FMODF''@|1|g' \ -e 's|@''HAVE_FMODL''@|1|g' \ -e 's|@''HAVE_FREXPF''@|1|g' \ -e 's|@''HAVE_HYPOTF''@|1|g' \ -e 's|@''HAVE_HYPOTL''@|1|g' \ -e 's|@''HAVE_ILOGB''@|1|g' \ -e 's|@''HAVE_ILOGBF''@|1|g' \ -e 's|@''HAVE_ILOGBL''@|1|g' \ -e 's|@''HAVE_ISNANF''@|1|g' \ -e 's|@''HAVE_ISNAND''@|1|g' \ -e 's|@''HAVE_ISNANL''@|1|g' \ -e 's|@''HAVE_LDEXPF''@|1|g' \ -e 's|@''HAVE_LOGF''@|1|g' \ -e 's|@''HAVE_LOGL''@|1|g' \ -e 's|@''HAVE_LOG10F''@|1|g' \ -e 's|@''HAVE_LOG10L''@|1|g' \ -e 's|@''HAVE_LOG1P''@|1|g' \ -e 's|@''HAVE_LOG1PF''@|1|g' \ -e 's|@''HAVE_LOG1PL''@|1|g' \ -e 's|@''HAVE_LOGBF''@|1|g' \ -e 's|@''HAVE_LOGBL''@|1|g' \ -e 's|@''HAVE_MODFF''@|1|g' \ -e 's|@''HAVE_MODFL''@|1|g' \ -e 's|@''HAVE_POWF''@|1|g' \ -e 's|@''HAVE_REMAINDER''@|1|g' \ -e 's|@''HAVE_REMAINDERF''@|1|g' \ -e 's|@''HAVE_RINT''@|1|g' \ -e 's|@''HAVE_RINTL''@|1|g' \ -e 's|@''HAVE_SINF''@|1|g' \ -e 's|@''HAVE_SINL''@|1|g' \ -e 's|@''HAVE_SINHF''@|1|g' \ -e 's|@''HAVE_SQRTF''@|1|g' \ -e 's|@''HAVE_SQRTL''@|1|g' \ -e 's|@''HAVE_TANF''@|1|g' \ -e 's|@''HAVE_TANL''@|1|g' \ -e 's|@''HAVE_TANHF''@|1|g' \ -e 's|@''HAVE_DECL_ACOSL''@|1|g' \ -e 's|@''HAVE_DECL_ASINL''@|1|g' \ -e 's|@''HAVE_DECL_ATANL''@|1|g' \ -e 's|@''HAVE_DECL_CBRTF''@|1|g' \ -e 's|@''HAVE_DECL_CBRTL''@|1|g' \ -e 's|@''HAVE_DECL_CEILF''@|1|g' \ -e 's|@''HAVE_DECL_CEILL''@|1|g' \ -e 's|@''HAVE_DECL_COPYSIGNF''@|1|g' \ -e 's|@''HAVE_DECL_COSL''@|1|g' \ -e 's|@''HAVE_DECL_EXPL''@|1|g' \ -e 's|@''HAVE_DECL_EXP2''@|1|g' \ -e 's|@''HAVE_DECL_EXP2F''@|1|g' \ -e 's|@''HAVE_DECL_EXP2L''@|1|g' \ -e 's|@''HAVE_DECL_EXPM1L''@|1|g' \ -e 's|@''HAVE_DECL_FLOORF''@|1|g' \ -e 's|@''HAVE_DECL_FLOORL''@|1|g' \ -e 's|@''HAVE_DECL_FREXPL''@|1|g' \ -e 's|@''HAVE_DECL_LDEXPL''@|1|g' \ -e 's|@''HAVE_DECL_LOGL''@|1|g' \ -e 's|@''HAVE_DECL_LOG10L''@|1|g' \ -e 's|@''HAVE_DECL_LOG2''@|1|g' \ -e 's|@''HAVE_DECL_LOG2F''@|1|g' \ -e 's|@''HAVE_DECL_LOG2L''@|1|g' \ -e 's|@''HAVE_DECL_LOGB''@|1|g' \ -e 's|@''HAVE_DECL_REMAINDER''@|1|g' \ -e 's|@''HAVE_DECL_REMAINDERL''@|1|g' \ -e 's|@''HAVE_DECL_RINTF''@|1|g' \ -e 's|@''HAVE_DECL_ROUND''@|1|g' \ -e 's|@''HAVE_DECL_ROUNDF''@|1|g' \ -e 's|@''HAVE_DECL_ROUNDL''@|1|g' \ -e 's|@''HAVE_DECL_SINL''@|1|g' \ -e 's|@''HAVE_DECL_SQRTL''@|1|g' \ -e 's|@''HAVE_DECL_TANL''@|1|g' \ -e 's|@''HAVE_DECL_TRUNC''@|1|g' \ -e 's|@''HAVE_DECL_TRUNCF''@|1|g' \ -e 's|@''HAVE_DECL_TRUNCL''@|1|g' \ | \ sed -e 's|@''REPLACE_ACOSF''@|0|g' \ -e 's|@''REPLACE_ASINF''@|0|g' \ -e 's|@''REPLACE_ATANF''@|0|g' \ -e 's|@''REPLACE_ATAN2F''@|0|g' \ -e 's|@''REPLACE_CBRTF''@|0|g' \ -e 's|@''REPLACE_CBRTL''@|0|g' \ -e 's|@''REPLACE_CEIL''@|0|g' \ -e 's|@''REPLACE_CEILF''@|0|g' \ -e 's|@''REPLACE_CEILL''@|0|g' \ -e 's|@''REPLACE_COSF''@|0|g' \ -e 's|@''REPLACE_COSHF''@|0|g' \ -e 's|@''REPLACE_EXPF''@|0|g' \ -e 's|@''REPLACE_EXPL''@|0|g' \ -e 's|@''REPLACE_EXPM1''@|0|g' \ -e 's|@''REPLACE_EXPM1F''@|0|g' \ -e 's|@''REPLACE_EXPM1L''@|0|g' \ -e 's|@''REPLACE_EXP2''@|0|g' \ -e 's|@''REPLACE_EXP2L''@|0|g' \ -e 's|@''REPLACE_FABSL''@|0|g' \ -e 's|@''REPLACE_FLOOR''@|0|g' \ -e 's|@''REPLACE_FLOORF''@|0|g' \ -e 's|@''REPLACE_FLOORL''@|0|g' \ -e 's|@''REPLACE_FMA''@|0|g' \ -e 's|@''REPLACE_FMAF''@|0|g' \ -e 's|@''REPLACE_FMAL''@|0|g' \ -e 's|@''REPLACE_FMOD''@|0|g' \ -e 's|@''REPLACE_FMODF''@|0|g' \ -e 's|@''REPLACE_FMODL''@|0|g' \ -e 's|@''REPLACE_FREXPF''@|0|g' \ -e 's|@''REPLACE_FREXP''@|0|g' \ -e 's|@''REPLACE_FREXPL''@|0|g' \ -e 's|@''REPLACE_HUGE_VAL''@|0|g' \ -e 's|@''REPLACE_HYPOT''@|0|g' \ -e 's|@''REPLACE_HYPOTF''@|0|g' \ -e 's|@''REPLACE_HYPOTL''@|0|g' \ -e 's|@''REPLACE_ILOGB''@|0|g' \ -e 's|@''REPLACE_ILOGBF''@|0|g' \ -e 's|@''REPLACE_ILOGBL''@|0|g' \ -e 's|@''REPLACE_ISFINITE''@|0|g' \ -e 's|@''REPLACE_ISINF''@|0|g' \ -e 's|@''REPLACE_ISNAN''@|0|g' \ -e 's|@''REPLACE_ITOLD''@|0|g' \ -e 's|@''REPLACE_LDEXPL''@|0|g' \ -e 's|@''REPLACE_LOG''@|0|g' \ -e 's|@''REPLACE_LOGF''@|0|g' \ -e 's|@''REPLACE_LOGL''@|0|g' \ -e 's|@''REPLACE_LOG10''@|0|g' \ -e 's|@''REPLACE_LOG10F''@|0|g' \ -e 's|@''REPLACE_LOG10L''@|0|g' \ -e 's|@''REPLACE_LOG1P''@|0|g' \ -e 's|@''REPLACE_LOG1PF''@|0|g' \ -e 's|@''REPLACE_LOG1PL''@|0|g' \ -e 's|@''REPLACE_LOG2''@|0|g' \ -e 's|@''REPLACE_LOG2F''@|0|g' \ -e 's|@''REPLACE_LOG2L''@|0|g' \ -e 's|@''REPLACE_LOGB''@|0|g' \ -e 's|@''REPLACE_LOGBF''@|0|g' \ -e 's|@''REPLACE_LOGBL''@|0|g' \ -e 's|@''REPLACE_MODF''@|0|g' \ -e 's|@''REPLACE_MODFF''@|0|g' \ -e 's|@''REPLACE_MODFL''@|0|g' \ -e 's|@''REPLACE_NAN''@|0|g' \ -e 's|@''REPLACE_REMAINDER''@|0|g' \ -e 's|@''REPLACE_REMAINDERF''@|0|g' \ -e 's|@''REPLACE_REMAINDERL''@|0|g' \ -e 's|@''REPLACE_RINTL''@|0|g' \ -e 's|@''REPLACE_ROUND''@|0|g' \ -e 's|@''REPLACE_ROUNDF''@|0|g' \ -e 's|@''REPLACE_ROUNDL''@|0|g' \ -e 's|@''REPLACE_SIGNBIT''@|0|g' \ -e 's|@''REPLACE_SIGNBIT_USING_BUILTINS''@|1|g' \ -e 's|@''REPLACE_SINF''@|0|g' \ -e 's|@''REPLACE_SINHF''@|0|g' \ -e 's|@''REPLACE_SQRTF''@|0|g' \ -e 's|@''REPLACE_SQRTL''@|0|g' \ -e 's|@''REPLACE_TANF''@|0|g' \ -e 's|@''REPLACE_TANHF''@|0|g' \ -e 's|@''REPLACE_TRUNC''@|0|g' \ -e 's|@''REPLACE_TRUNCF''@|0|g' \ -e 's|@''REPLACE_TRUNCL''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h'; \ } > lib/math.h-t && \ mv lib/math.h-t lib/math.h rm -f lib/sched.h-t lib/sched.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''HAVE_SCHED_H''@|1|g' \ -e 's|@''HAVE_SYS_CDEFS_H''@|1|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SCHED_H''@||g' \ -e 's|@''HAVE_STRUCT_SCHED_PARAM''@|1|g' \ -e 's/@''GNULIB_SCHED_YIELD''@/0/g' \ -e 's|@''HAVE_SCHED_YIELD''@|1|g' \ -e 's|@''REPLACE_SCHED_YIELD''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/sched.in.h; \ } > lib/sched.h-t && \ mv lib/sched.h-t lib/sched.h /usr/bin/mkdir -p lib/malloc rm -f lib/signal.h-t lib/signal.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SIGNAL_H''@||g' \ -e 's/@''GNULIB_PTHREAD_SIGMASK''@/0/g' \ -e 's/@''GNULIB_RAISE''@/1/g' \ -e 's/@''GNULIB_SIGNAL_H_SIGPIPE''@/0/g' \ -e 's/@''GNULIB_SIGPROCMASK''@/1/g' \ -e 's/@''GNULIB_SIGACTION''@/1/g' \ -e 's|@''HAVE_POSIX_SIGNALBLOCKING''@|1|g' \ -e 's|@''HAVE_PTHREAD_SIGMASK''@|1|g' \ -e 's|@''HAVE_RAISE''@|1|g' \ -e 's|@''HAVE_SIGSET_T''@|1|g' \ -e 's|@''HAVE_SIGINFO_T''@|1|g' \ -e 's|@''HAVE_SIGACTION''@|1|g' \ -e 's|@''HAVE_STRUCT_SIGACTION_SA_SIGACTION''@|1|g' \ -e 's|@''HAVE_TYPE_VOLATILE_SIG_ATOMIC_T''@|1|g' \ -e 's|@''HAVE_SIGHANDLER_T''@|1|g' \ -e 's|@''REPLACE_PTHREAD_SIGMASK''@|0|g' \ -e 's|@''REPLACE_RAISE''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/signal.in.h; \ } > lib/signal.h-t && \ mv lib/signal.h-t lib/signal.h rm -f lib/malloc/scratch_buffer.gl.h-t lib/malloc/scratch_buffer.gl.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|__always_inline|inline _GL_ATTRIBUTE_ALWAYS_INLINE|g' \ -e 's|__glibc_likely|_GL_LIKELY|g' \ -e 's|__glibc_unlikely|_GL_UNLIKELY|g' \ -e '/libc_hidden_proto/d' \ < ./lib/malloc/scratch_buffer.h; \ } > lib/malloc/scratch_buffer.gl.h-t && \ mv lib/malloc/scratch_buffer.gl.h-t lib/malloc/scratch_buffer.gl.h rm -f lib/spawn.h-t lib/spawn.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''HAVE_SPAWN_H''@|1|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SPAWN_H''@||g' \ -e 's/@''GNULIB_POSIX_SPAWN''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWNP''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWN_FILE_ACTIONS_INIT''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWN_FILE_ACTIONS_DESTROY''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_INIT''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_GETFLAGS''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_SETFLAGS''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_GETPGROUP''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_SETPGROUP''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_GETSCHEDPARAM''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_SETSCHEDPARAM''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_GETSCHEDPOLICY''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_SETSCHEDPOLICY''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_GETSIGDEFAULT''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_SETSIGDEFAULT''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_GETSIGMASK''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_SETSIGMASK''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_DESTROY''@/1/g' \ -e 's|@''HAVE_POSIX_SPAWN''@|1|g' \ -e 's|@''HAVE_POSIX_SPAWNATTR_T''@|1|g' \ -e 's|@''HAVE_POSIX_SPAWN_FILE_ACTIONS_T''@|1|g' \ -e 's|@''HAVE_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR''@|0|g' \ -e 's|@''HAVE_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR''@|1|g' \ -e 's|@''REPLACE_POSIX_SPAWN''@|0|g' \ -e 's|@''REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR''@|0|g' \ -e 's|@''REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE''@|0|g' \ -e 's|@''REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2''@|0|g' \ -e 's|@''REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR''@|0|g' \ -e 's|@''REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/spawn.in.h; \ } > lib/spawn.h-t && \ mv lib/spawn.h-t lib/spawn.h rm -f lib/stdio.h-t lib/stdio.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_STDIO_H''@||g' \ -e 's/@''GNULIB_DPRINTF''@/0/g' \ -e 's/@''GNULIB_FCLOSE''@/0/g' \ -e 's/@''GNULIB_FDOPEN''@/0/g' \ -e 's/@''GNULIB_FFLUSH''@/0/g' \ -e 's/@''GNULIB_FGETC''@/1/g' \ -e 's/@''GNULIB_FGETS''@/1/g' \ -e 's/@''GNULIB_FOPEN''@/1/g' \ -e 's/@''GNULIB_FPRINTF''@/1/g' \ -e 's/@''GNULIB_FPRINTF_POSIX''@/1/g' \ -e 's/@''GNULIB_FPURGE''@/0/g' \ -e 's/@''GNULIB_FPUTC''@/1/g' \ -e 's/@''GNULIB_FPUTS''@/1/g' \ -e 's/@''GNULIB_FREAD''@/1/g' \ -e 's/@''GNULIB_FREOPEN''@/0/g' \ -e 's/@''GNULIB_FSCANF''@/1/g' \ -e 's/@''GNULIB_FSEEK''@/0/g' \ -e 's/@''GNULIB_FSEEKO''@/0/g' \ -e 's/@''GNULIB_FTELL''@/0/g' \ -e 's/@''GNULIB_FTELLO''@/0/g' \ -e 's/@''GNULIB_FWRITE''@/1/g' \ -e 's/@''GNULIB_GETC''@/1/g' \ -e 's/@''GNULIB_GETCHAR''@/1/g' \ -e 's/@''GNULIB_GETDELIM''@/0/g' \ -e 's/@''GNULIB_GETLINE''@/1/g' \ -e 's/@''GNULIB_OBSTACK_PRINTF''@/1/g' \ -e 's/@''GNULIB_OBSTACK_PRINTF_POSIX''@/0/g' \ -e 's/@''GNULIB_PCLOSE''@/0/g' \ -e 's/@''GNULIB_PERROR''@/1/g' \ -e 's/@''GNULIB_POPEN''@/0/g' \ -e 's/@''GNULIB_PRINTF''@/1/g' \ -e 's/@''GNULIB_PRINTF_POSIX''@/1/g' \ -e 's/@''GNULIB_PUTC''@/1/g' \ -e 's/@''GNULIB_PUTCHAR''@/1/g' \ -e 's/@''GNULIB_PUTS''@/1/g' \ -e 's/@''GNULIB_REMOVE''@/0/g' \ -e 's/@''GNULIB_RENAME''@/1/g' \ -e 's/@''GNULIB_RENAMEAT''@/0/g' \ -e 's/@''GNULIB_SCANF''@/1/g' \ -e 's/@''GNULIB_SNPRINTF''@/1/g' \ -e 's/@''GNULIB_SPRINTF_POSIX''@/1/g' \ -e 's/@''GNULIB_STDIO_H_NONBLOCKING''@/0/g' \ -e 's/@''GNULIB_STDIO_H_SIGPIPE''@/0/g' \ -e 's/@''GNULIB_TMPFILE''@/0/g' \ -e 's/@''GNULIB_VASPRINTF''@/1/g' \ -e 's/@''GNULIB_VDPRINTF''@/0/g' \ -e 's/@''GNULIB_VFPRINTF''@/1/g' \ -e 's/@''GNULIB_VFPRINTF_POSIX''@/1/g' \ -e 's/@''GNULIB_VFSCANF''@/0/g' \ -e 's/@''GNULIB_VSCANF''@/0/g' \ -e 's/@''GNULIB_VPRINTF''@/1/g' \ -e 's/@''GNULIB_VPRINTF_POSIX''@/0/g' \ -e 's/@''GNULIB_VSNPRINTF''@/1/g' \ -e 's/@''GNULIB_VSPRINTF_POSIX''@/1/g' \ -e 's/@''GNULIB_MDA_FCLOSEALL''@/1/g' \ -e 's/@''GNULIB_MDA_FDOPEN''@/1/g' \ -e 's/@''GNULIB_MDA_FILENO''@/1/g' \ -e 's/@''GNULIB_MDA_GETW''@/1/g' \ -e 's/@''GNULIB_MDA_PUTW''@/1/g' \ -e 's/@''GNULIB_MDA_TEMPNAM''@/1/g' \ < ./lib/stdio.in.h | \ sed -e 's|@''HAVE_DECL_FCLOSEALL''@|1|g' \ -e 's|@''HAVE_DECL_FPURGE''@|1|g' \ -e 's|@''HAVE_DECL_FSEEKO''@|1|g' \ -e 's|@''HAVE_DECL_FTELLO''@|1|g' \ -e 's|@''HAVE_DECL_GETDELIM''@|1|g' \ -e 's|@''HAVE_DECL_GETLINE''@|1|g' \ -e 's|@''HAVE_DECL_OBSTACK_PRINTF''@|1|g' \ -e 's|@''HAVE_DECL_SNPRINTF''@|1|g' \ -e 's|@''HAVE_DECL_VSNPRINTF''@|1|g' \ -e 's|@''HAVE_DPRINTF''@|1|g' \ -e 's|@''HAVE_FSEEKO''@|1|g' \ -e 's|@''HAVE_FTELLO''@|1|g' \ -e 's|@''HAVE_PCLOSE''@|1|g' \ -e 's|@''HAVE_POPEN''@|1|g' \ -e 's|@''HAVE_RENAMEAT''@|1|g' \ -e 's|@''HAVE_VASPRINTF''@|1|g' \ -e 's|@''HAVE_VDPRINTF''@|1|g' \ -e 's|@''REPLACE_DPRINTF''@|0|g' \ -e 's|@''REPLACE_FCLOSE''@|0|g' \ -e 's|@''REPLACE_FDOPEN''@|0|g' \ -e 's|@''REPLACE_FFLUSH''@|0|g' \ -e 's|@''REPLACE_FOPEN''@|0|g' \ -e 's|@''REPLACE_FPRINTF''@|1|g' \ -e 's|@''REPLACE_FPURGE''@|0|g' \ -e 's|@''REPLACE_FREOPEN''@|0|g' \ -e 's|@''REPLACE_FSEEK''@|0|g' \ -e 's|@''REPLACE_FSEEKO''@|0|g' \ -e 's|@''REPLACE_FTELL''@|0|g' \ -e 's|@''REPLACE_FTELLO''@|0|g' \ -e 's|@''REPLACE_GETDELIM''@|0|g' \ -e 's|@''REPLACE_GETLINE''@|0|g' \ -e 's|@''REPLACE_OBSTACK_PRINTF''@|0|g' \ -e 's|@''REPLACE_PERROR''@|0|g' \ -e 's|@''REPLACE_POPEN''@|0|g' \ -e 's|@''REPLACE_PRINTF''@|1|g' \ -e 's|@''REPLACE_REMOVE''@|0|g' \ -e 's|@''REPLACE_RENAME''@|0|g' \ -e 's|@''REPLACE_RENAMEAT''@|0|g' \ -e 's|@''REPLACE_SNPRINTF''@|1|g' \ -e 's|@''REPLACE_SPRINTF''@|1|g' \ -e 's|@''REPLACE_STDIO_READ_FUNCS''@|0|g' \ -e 's|@''REPLACE_STDIO_WRITE_FUNCS''@|0|g' \ -e 's|@''REPLACE_TMPFILE''@|0|g' \ -e 's|@''REPLACE_VASPRINTF''@|1|g' \ -e 's|@''REPLACE_VDPRINTF''@|0|g' \ -e 's|@''REPLACE_VFPRINTF''@|1|g' \ -e 's|@''REPLACE_VPRINTF''@|0|g' \ -e 's|@''REPLACE_VSNPRINTF''@|1|g' \ -e 's|@''REPLACE_VSPRINTF''@|1|g' \ -e 's|@''ASM_SYMBOL_PREFIX''@|""|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h'; \ } > lib/stdio.h-t && \ mv lib/stdio.h-t lib/stdio.h rm -f lib/stdlib.h-t lib/stdlib.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_STDLIB_H''@||g' \ -e 's/@''GNULIB__EXIT''@/0/g' \ -e 's/@''GNULIB_ALIGNED_ALLOC''@/0/g' \ -e 's/@''GNULIB_ATOLL''@/0/g' \ -e 's/@''GNULIB_CALLOC_POSIX''@/1/g' \ -e 's/@''GNULIB_CANONICALIZE_FILE_NAME''@/1/g' \ -e 's/@''GNULIB_FREE_POSIX''@/1/g' \ -e 's/@''GNULIB_GETLOADAVG''@/0/g' \ -e 's/@''GNULIB_GETSUBOPT''@/0/g' \ -e 's/@''GNULIB_GRANTPT''@/0/g' \ -e 's/@''GNULIB_MALLOC_POSIX''@/1/g' \ -e 's/@''GNULIB_MBTOWC''@/0/g' \ -e 's/@''GNULIB_MKDTEMP''@/0/g' \ -e 's/@''GNULIB_MKOSTEMP''@/0/g' \ -e 's/@''GNULIB_MKOSTEMPS''@/0/g' \ -e 's/@''GNULIB_MKSTEMP''@/0/g' \ -e 's/@''GNULIB_MKSTEMPS''@/0/g' \ -e 's/@''GNULIB_POSIX_MEMALIGN''@/0/g' \ -e 's/@''GNULIB_POSIX_OPENPT''@/0/g' \ -e 's/@''GNULIB_PTSNAME''@/0/g' \ -e 's/@''GNULIB_PTSNAME_R''@/0/g' \ -e 's/@''GNULIB_PUTENV''@/0/g' \ -e 's/@''GNULIB_QSORT_R''@/0/g' \ -e 's/@''GNULIB_RANDOM''@/0/g' \ -e 's/@''GNULIB_RANDOM_R''@/0/g' \ -e 's/@''GNULIB_REALLOC_POSIX''@/1/g' \ -e 's/@''GNULIB_REALLOCARRAY''@/1/g' \ -e 's/@''GNULIB_REALPATH''@/1/g' \ -e 's/@''GNULIB_RPMATCH''@/0/g' \ -e 's/@''GNULIB_SECURE_GETENV''@/0/g' \ -e 's/@''GNULIB_SETENV''@/0/g' \ -e 's/@''GNULIB_STRTOD''@/1/g' \ -e 's/@''GNULIB_STRTOL''@/0/g' \ -e 's/@''GNULIB_STRTOLD''@/0/g' \ -e 's/@''GNULIB_STRTOLL''@/0/g' \ -e 's/@''GNULIB_STRTOUL''@/0/g' \ -e 's/@''GNULIB_STRTOULL''@/0/g' \ -e 's/@''GNULIB_SYSTEM_POSIX''@/0/g' \ -e 's/@''GNULIB_UNLOCKPT''@/0/g' \ -e 's/@''GNULIB_UNSETENV''@/1/g' \ -e 's/@''GNULIB_WCTOMB''@/0/g' \ -e 's/@''GNULIB_MDA_ECVT''@/1/g' \ -e 's/@''GNULIB_MDA_FCVT''@/1/g' \ -e 's/@''GNULIB_MDA_GCVT''@/1/g' \ -e 's/@''GNULIB_MDA_MKTEMP''@/1/g' \ -e 's/@''GNULIB_MDA_PUTENV''@/1/g' \ < ./lib/stdlib.in.h | \ sed -e 's|@''HAVE__EXIT''@|1|g' \ -e 's|@''HAVE_ALIGNED_ALLOC''@|1|g' \ -e 's|@''HAVE_ATOLL''@|1|g' \ -e 's|@''HAVE_CANONICALIZE_FILE_NAME''@|1|g' \ -e 's|@''HAVE_DECL_ECVT''@|1|g' \ -e 's|@''HAVE_DECL_FCVT''@|1|g' \ -e 's|@''HAVE_DECL_GCVT''@|1|g' \ -e 's|@''HAVE_DECL_GETLOADAVG''@|1|g' \ -e 's|@''HAVE_GETSUBOPT''@|1|g' \ -e 's|@''HAVE_GRANTPT''@|1|g' \ -e 's|@''HAVE_INITSTATE''@|1|g' \ -e 's|@''HAVE_DECL_INITSTATE''@|1|g' \ -e 's|@''HAVE_MBTOWC''@|1|g' \ -e 's|@''HAVE_MKDTEMP''@|1|g' \ -e 's|@''HAVE_MKOSTEMP''@|1|g' \ -e 's|@''HAVE_MKOSTEMPS''@|1|g' \ -e 's|@''HAVE_MKSTEMP''@|1|g' \ -e 's|@''HAVE_MKSTEMPS''@|1|g' \ -e 's|@''HAVE_POSIX_MEMALIGN''@|1|g' \ -e 's|@''HAVE_POSIX_OPENPT''@|1|g' \ -e 's|@''HAVE_PTSNAME''@|1|g' \ -e 's|@''HAVE_PTSNAME_R''@|1|g' \ -e 's|@''HAVE_QSORT_R''@|1|g' \ -e 's|@''HAVE_RANDOM''@|1|g' \ -e 's|@''HAVE_RANDOM_H''@|1|g' \ -e 's|@''HAVE_RANDOM_R''@|1|g' \ -e 's|@''HAVE_REALLOCARRAY''@|1|g' \ -e 's|@''HAVE_REALPATH''@|1|g' \ -e 's|@''HAVE_RPMATCH''@|1|g' \ -e 's|@''HAVE_SECURE_GETENV''@|1|g' \ -e 's|@''HAVE_DECL_SETENV''@|1|g' \ -e 's|@''HAVE_SETSTATE''@|1|g' \ -e 's|@''HAVE_DECL_SETSTATE''@|1|g' \ -e 's|@''HAVE_STRTOD''@|1|g' \ -e 's|@''HAVE_STRTOL''@|1|g' \ -e 's|@''HAVE_STRTOLD''@|1|g' \ -e 's|@''HAVE_STRTOLL''@|1|g' \ -e 's|@''HAVE_STRTOUL''@|1|g' \ -e 's|@''HAVE_STRTOULL''@|1|g' \ -e 's|@''HAVE_STRUCT_RANDOM_DATA''@|1|g' \ -e 's|@''HAVE_SYS_LOADAVG_H''@|0|g' \ -e 's|@''HAVE_UNLOCKPT''@|1|g' \ -e 's|@''HAVE_DECL_UNSETENV''@|1|g' \ -e 's|@''REPLACE_ALIGNED_ALLOC''@|0|g' \ -e 's|@''REPLACE_CALLOC''@|0|g' \ -e 's|@''REPLACE_CANONICALIZE_FILE_NAME''@|0|g' \ -e 's|@''REPLACE_FREE''@|0|g' \ -e 's|@''REPLACE_INITSTATE''@|0|g' \ -e 's|@''REPLACE_MALLOC''@|0|g' \ -e 's|@''REPLACE_MBTOWC''@|0|g' \ -e 's|@''REPLACE_MKSTEMP''@|0|g' \ -e 's|@''REPLACE_POSIX_MEMALIGN''@|0|g' \ -e 's|@''REPLACE_PTSNAME''@|0|g' \ -e 's|@''REPLACE_PTSNAME_R''@|0|g' \ -e 's|@''REPLACE_PUTENV''@|0|g' \ -e 's|@''REPLACE_QSORT_R''@|0|g' \ -e 's|@''REPLACE_RANDOM''@|0|g' \ -e 's|@''REPLACE_RANDOM_R''@|0|g' \ -e 's|@''REPLACE_REALLOC''@|0|g' \ -e 's|@''REPLACE_REALLOCARRAY''@|0|g' \ -e 's|@''REPLACE_REALPATH''@|0|g' \ -e 's|@''REPLACE_SETENV''@|0|g' \ -e 's|@''REPLACE_SETSTATE''@|0|g' \ -e 's|@''REPLACE_STRTOD''@|0|g' \ -e 's|@''REPLACE_STRTOL''@|0|g' \ -e 's|@''REPLACE_STRTOLD''@|0|g' \ -e 's|@''REPLACE_STRTOLL''@|0|g' \ -e 's|@''REPLACE_STRTOUL''@|0|g' \ -e 's|@''REPLACE_STRTOULL''@|0|g' \ -e 's|@''REPLACE_UNSETENV''@|0|g' \ -e 's|@''REPLACE_WCTOMB''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _Noreturn/r ./lib/_Noreturn.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h'; \ } > lib/stdlib.h-t && \ mv lib/stdlib.h-t lib/stdlib.h rm -f lib/string.h-t lib/string.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_STRING_H''@||g' \ -e 's/@''GNULIB_EXPLICIT_BZERO''@/0/g' \ -e 's/@''GNULIB_FFSL''@/1/g' \ -e 's/@''GNULIB_FFSLL''@/0/g' \ -e 's/@''GNULIB_MBSLEN''@/0/g' \ -e 's/@''GNULIB_MBSNLEN''@/0/g' \ -e 's/@''GNULIB_MBSCHR''@/0/g' \ -e 's/@''GNULIB_MBSRCHR''@/0/g' \ -e 's/@''GNULIB_MBSSTR''@/0/g' \ -e 's/@''GNULIB_MBSCASECMP''@/0/g' \ -e 's/@''GNULIB_MBSNCASECMP''@/0/g' \ -e 's/@''GNULIB_MBSPCASECMP''@/0/g' \ -e 's/@''GNULIB_MBSCASESTR''@/0/g' \ -e 's/@''GNULIB_MBSCSPN''@/0/g' \ -e 's/@''GNULIB_MBSPBRK''@/0/g' \ -e 's/@''GNULIB_MBSSPN''@/0/g' \ -e 's/@''GNULIB_MBSSEP''@/0/g' \ -e 's/@''GNULIB_MBSTOK_R''@/0/g' \ -e 's/@''GNULIB_MEMCHR''@/1/g' \ -e 's/@''GNULIB_MEMMEM''@/0/g' \ -e 's/@''GNULIB_MEMPCPY''@/1/g' \ -e 's/@''GNULIB_MEMRCHR''@/0/g' \ -e 's/@''GNULIB_RAWMEMCHR''@/1/g' \ -e 's/@''GNULIB_STPCPY''@/1/g' \ -e 's/@''GNULIB_STPNCPY''@/1/g' \ -e 's/@''GNULIB_STRCHRNUL''@/0/g' \ -e 's/@''GNULIB_STRDUP''@/1/g' \ -e 's/@''GNULIB_STRNCAT''@/0/g' \ -e 's/@''GNULIB_STRNDUP''@/1/g' \ -e 's/@''GNULIB_STRNLEN''@/0/g' \ -e 's/@''GNULIB_STRPBRK''@/0/g' \ -e 's/@''GNULIB_STRSEP''@/0/g' \ -e 's/@''GNULIB_STRSTR''@/0/g' \ -e 's/@''GNULIB_STRCASESTR''@/0/g' \ -e 's/@''GNULIB_STRTOK_R''@/0/g' \ -e 's/@''GNULIB_STRERROR''@/1/g' \ -e 's/@''GNULIB_STRERROR_R''@/0/g' \ -e 's/@''GNULIB_STRERRORNAME_NP''@/0/g' \ -e 's/@''GNULIB_SIGABBREV_NP''@/0/g' \ -e 's/@''GNULIB_SIGDESCR_NP''@/0/g' \ -e 's/@''GNULIB_STRSIGNAL''@/0/g' \ -e 's/@''GNULIB_STRVERSCMP''@/1/g' \ -e 's/@''GNULIB_MDA_MEMCCPY''@/1/g' \ -e 's/@''GNULIB_MDA_STRDUP''@/1/g' \ < ./lib/string.in.h | \ sed -e 's|@''HAVE_EXPLICIT_BZERO''@|1|g' \ -e 's|@''HAVE_FFSL''@|1|g' \ -e 's|@''HAVE_FFSLL''@|1|g' \ -e 's|@''HAVE_MBSLEN''@|0|g' \ -e 's|@''HAVE_DECL_MEMMEM''@|1|g' \ -e 's|@''HAVE_MEMPCPY''@|1|g' \ -e 's|@''HAVE_DECL_MEMRCHR''@|1|g' \ -e 's|@''HAVE_RAWMEMCHR''@|1|g' \ -e 's|@''HAVE_STPCPY''@|1|g' \ -e 's|@''HAVE_STPNCPY''@|1|g' \ -e 's|@''HAVE_STRCHRNUL''@|1|g' \ -e 's|@''HAVE_DECL_STRDUP''@|1|g' \ -e 's|@''HAVE_DECL_STRNDUP''@|1|g' \ -e 's|@''HAVE_DECL_STRNLEN''@|1|g' \ -e 's|@''HAVE_STRPBRK''@|1|g' \ -e 's|@''HAVE_STRSEP''@|1|g' \ -e 's|@''HAVE_STRCASESTR''@|1|g' \ -e 's|@''HAVE_DECL_STRTOK_R''@|1|g' \ -e 's|@''HAVE_DECL_STRERROR_R''@|1|g' \ -e 's|@''HAVE_STRERRORNAME_NP''@|1|g' \ -e 's|@''HAVE_SIGABBREV_NP''@|1|g' \ -e 's|@''HAVE_SIGDESCR_NP''@|1|g' \ -e 's|@''HAVE_DECL_STRSIGNAL''@|1|g' \ -e 's|@''HAVE_STRVERSCMP''@|1|g' \ -e 's|@''REPLACE_FFSLL''@|0|g' \ -e 's|@''REPLACE_MEMCHR''@|0|g' \ -e 's|@''REPLACE_MEMMEM''@|0|g' \ -e 's|@''REPLACE_FREE''@|0|g' \ -e 's|@''REPLACE_STPNCPY''@|0|g' \ -e 's|@''REPLACE_STRCHRNUL''@|0|g' \ -e 's|@''REPLACE_STRDUP''@|0|g' \ -e 's|@''REPLACE_STRNCAT''@|0|g' \ -e 's|@''REPLACE_STRNDUP''@|0|g' \ -e 's|@''REPLACE_STRNLEN''@|0|g' \ -e 's|@''REPLACE_STRSTR''@|0|g' \ -e 's|@''REPLACE_STRCASESTR''@|0|g' \ -e 's|@''REPLACE_STRTOK_R''@|0|g' \ -e 's|@''REPLACE_STRERROR''@|0|g' \ -e 's|@''REPLACE_STRERROR_R''@|1|g' \ -e 's|@''REPLACE_STRERRORNAME_NP''@|0|g' \ -e 's|@''REPLACE_STRSIGNAL''@|0|g' \ -e 's|@''UNDEFINE_STRTOK_R''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h'; \ < ./lib/string.in.h; \ } > lib/string.h-t && \ mv lib/string.h-t lib/string.h /usr/bin/mkdir -p lib/sys rm -f lib/sys/ioctl.h-t lib/sys/ioctl.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''HAVE_SYS_IOCTL_H''@|1|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SYS_IOCTL_H''@||g' \ -e 's/@''GNULIB_IOCTL''@/0/g' \ -e 's|@''SYS_IOCTL_H_HAVE_WINSOCK2_H''@|0|g' \ -e 's|@''SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS''@|0|g' \ -e 's|@''REPLACE_IOCTL''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/sys_ioctl.in.h; \ } > lib/sys/ioctl.h-t && \ mv lib/sys/ioctl.h-t lib/sys/ioctl.h /usr/bin/mkdir -p lib/sys /usr/bin/mkdir -p lib/sys rm -f lib/sys/resource.h-t lib/sys/resource.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SYS_RESOURCE_H''@||g' \ -e 's|@''HAVE_SYS_RESOURCE_H''@|1|g' \ -e 's/@''GNULIB_GETRUSAGE''@/1/g' \ -e 's/@''HAVE_GETRUSAGE''@/1/g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/sys_resource.in.h; \ } > lib/sys/resource.h-t && \ mv -f lib/sys/resource.h-t lib/sys/resource.h rm -f lib/sys/stat.h-t lib/sys/stat.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SYS_STAT_H''@||g' \ -e 's|@''WINDOWS_64_BIT_ST_SIZE''@|0|g' \ -e 's|@''WINDOWS_STAT_TIMESPEC''@|0|g' \ -e 's/@''GNULIB_FCHMODAT''@/0/g' \ -e 's/@''GNULIB_FSTAT''@/0/g' \ -e 's/@''GNULIB_FSTATAT''@/0/g' \ -e 's/@''GNULIB_FUTIMENS''@/0/g' \ -e 's/@''GNULIB_GETUMASK''@/0/g' \ -e 's/@''GNULIB_LCHMOD''@/0/g' \ -e 's/@''GNULIB_LSTAT''@/0/g' \ -e 's/@''GNULIB_MKDIR''@/0/g' \ -e 's/@''GNULIB_MKDIRAT''@/0/g' \ -e 's/@''GNULIB_MKFIFO''@/0/g' \ -e 's/@''GNULIB_MKFIFOAT''@/0/g' \ -e 's/@''GNULIB_MKNOD''@/0/g' \ -e 's/@''GNULIB_MKNODAT''@/0/g' \ -e 's/@''GNULIB_STAT''@/1/g' \ -e 's/@''GNULIB_UTIMENSAT''@/0/g' \ -e 's/@''GNULIB_OVERRIDES_STRUCT_STAT''@/0/g' \ -e 's/@''GNULIB_MDA_CHMOD''@/1/g' \ -e 's/@''GNULIB_MDA_MKDIR''@/1/g' \ -e 's/@''GNULIB_MDA_UMASK''@/1/g' \ -e 's|@''HAVE_FCHMODAT''@|1|g' \ -e 's|@''HAVE_FSTATAT''@|1|g' \ -e 's|@''HAVE_FUTIMENS''@|1|g' \ -e 's|@''HAVE_GETUMASK''@|1|g' \ -e 's|@''HAVE_LCHMOD''@|1|g' \ -e 's|@''HAVE_LSTAT''@|1|g' \ -e 's|@''HAVE_MKDIRAT''@|1|g' \ -e 's|@''HAVE_MKFIFO''@|1|g' \ -e 's|@''HAVE_MKFIFOAT''@|1|g' \ -e 's|@''HAVE_MKNOD''@|1|g' \ -e 's|@''HAVE_MKNODAT''@|1|g' \ -e 's|@''HAVE_UTIMENSAT''@|1|g' \ -e 's|@''REPLACE_FCHMODAT''@|0|g' \ -e 's|@''REPLACE_FSTAT''@|0|g' \ -e 's|@''REPLACE_FSTATAT''@|0|g' \ -e 's|@''REPLACE_FUTIMENS''@|0|g' \ -e 's|@''REPLACE_LSTAT''@|0|g' \ -e 's|@''REPLACE_MKDIR''@|0|g' \ -e 's|@''REPLACE_MKFIFO''@|0|g' \ -e 's|@''REPLACE_MKFIFOAT''@|0|g' \ -e 's|@''REPLACE_MKNOD''@|0|g' \ -e 's|@''REPLACE_MKNODAT''@|0|g' \ -e 's|@''REPLACE_STAT''@|0|g' \ -e 's|@''REPLACE_UTIMENSAT''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/sys_stat.in.h; \ } > lib/sys/stat.h-t && \ mv lib/sys/stat.h-t lib/sys/stat.h /usr/bin/mkdir -p lib/sys /usr/bin/mkdir -p lib/sys rm -f lib/sys/time.h-t lib/sys/time.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's/@''HAVE_SYS_TIME_H''@/1/g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SYS_TIME_H''@||g' \ -e 's/@''GNULIB_GETTIMEOFDAY''@/1/g' \ -e 's|@''HAVE_WINSOCK2_H''@|0|g' \ -e 's/@''HAVE_GETTIMEOFDAY''@/1/g' \ -e 's/@''HAVE_STRUCT_TIMEVAL''@/1/g' \ -e 's/@''REPLACE_GETTIMEOFDAY''@/0/g' \ -e 's/@''REPLACE_STRUCT_TIMEVAL''@/0/g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/sys_time.in.h; \ } > lib/sys/time.h-t && \ mv lib/sys/time.h-t lib/sys/time.h rm -f lib/sys/times.h-t lib/sys/times.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's/@''HAVE_SYS_TIMES_H''@/1/g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SYS_TIMES_H''@||g' \ -e 's/@''GNULIB_TIMES''@/0/g' \ -e 's|@''HAVE_STRUCT_TMS''@|1|g' \ -e 's|@''HAVE_TIMES''@|1|g' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/sys_times.in.h; \ } > lib/sys/times.h-t && \ mv lib/sys/times.h-t lib/sys/times.h /usr/bin/mkdir -p lib/sys rm -f lib/sys/types.h-t lib/sys/types.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SYS_TYPES_H''@||g' \ -e 's|@''WINDOWS_64_BIT_OFF_T''@|0|g' \ -e 's|@''WINDOWS_STAT_INODES''@|0|g' \ < ./lib/sys_types.in.h; \ } > lib/sys/types.h-t && \ mv lib/sys/types.h-t lib/sys/types.h /usr/bin/mkdir -p lib/sys rm -f lib/termios.h-t lib/termios.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_TERMIOS_H''@||g' \ -e 's/@''GNULIB_TCGETSID''@/0/g' \ -e 's|@''HAVE_DECL_TCGETSID''@|1|g' \ -e 's|@''HAVE_TERMIOS_H''@|1|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/termios.in.h; \ } > lib/termios.h-t && \ mv lib/termios.h-t lib/termios.h rm -f lib/sys/wait.h-t lib/sys/wait.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SYS_WAIT_H''@||g' \ -e 's/@''GNULIB_WAITPID''@/1/g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/sys_wait.in.h; \ } > lib/sys/wait.h-t && \ mv lib/sys/wait.h-t lib/sys/wait.h rm -f lib/time.h-t lib/time.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_TIME_H''@||g' \ -e 's/@''GNULIB_CTIME''@/0/g' \ -e 's/@''GNULIB_LOCALTIME''@/0/g' \ -e 's/@''GNULIB_MKTIME''@/0/g' \ -e 's/@''GNULIB_NANOSLEEP''@/0/g' \ -e 's/@''GNULIB_STRFTIME''@/0/g' \ -e 's/@''GNULIB_STRPTIME''@/0/g' \ -e 's/@''GNULIB_TIMEGM''@/0/g' \ -e 's/@''GNULIB_TIMESPEC_GET''@/0/g' \ -e 's/@''GNULIB_TIME_R''@/0/g' \ -e 's/@''GNULIB_TIME_RZ''@/0/g' \ -e 's/@''GNULIB_TZSET''@/0/g' \ -e 's/@''GNULIB_MDA_TZSET''@/1/g' \ -e 's|@''HAVE_DECL_LOCALTIME_R''@|1|g' \ -e 's|@''HAVE_NANOSLEEP''@|1|g' \ -e 's|@''HAVE_STRPTIME''@|1|g' \ -e 's|@''HAVE_TIMEGM''@|1|g' \ -e 's|@''HAVE_TIMESPEC_GET''@|1|g' \ -e 's|@''HAVE_TIMEZONE_T''@|0|g' \ -e 's|@''REPLACE_CTIME''@|GNULIB_PORTCHECK|g' \ -e 's|@''REPLACE_GMTIME''@|0|g' \ -e 's|@''REPLACE_LOCALTIME''@|0|g' \ -e 's|@''REPLACE_LOCALTIME_R''@|GNULIB_PORTCHECK|g' \ -e 's|@''REPLACE_MKTIME''@|GNULIB_PORTCHECK|g' \ -e 's|@''REPLACE_NANOSLEEP''@|GNULIB_PORTCHECK|g' \ -e 's|@''REPLACE_STRFTIME''@|GNULIB_PORTCHECK|g' \ -e 's|@''REPLACE_TIMEGM''@|GNULIB_PORTCHECK|g' \ -e 's|@''REPLACE_TZSET''@|GNULIB_PORTCHECK|g' \ -e 's|@''PTHREAD_H_DEFINES_STRUCT_TIMESPEC''@|0|g' \ -e 's|@''SYS_TIME_H_DEFINES_STRUCT_TIMESPEC''@|0|g' \ -e 's|@''TIME_H_DEFINES_STRUCT_TIMESPEC''@|1|g' \ -e 's|@''UNISTD_H_DEFINES_STRUCT_TIMESPEC''@|0|g' \ -e 's|@''TIME_H_DEFINES_TIME_UTC''@|1|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/time.in.h; \ } > lib/time.h-t && \ mv lib/time.h-t lib/time.h rm -f lib/unistd.h-t lib/unistd.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''HAVE_UNISTD_H''@|1|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_UNISTD_H''@||g' \ -e 's|@''WINDOWS_64_BIT_OFF_T''@|0|g' \ -e 's/@''GNULIB_ACCESS''@/1/g' \ -e 's/@''GNULIB_CHDIR''@/0/g' \ -e 's/@''GNULIB_CHOWN''@/0/g' \ -e 's/@''GNULIB_CLOSE''@/1/g' \ -e 's/@''GNULIB_COPY_FILE_RANGE''@/0/g' \ -e 's/@''GNULIB_DUP''@/0/g' \ -e 's/@''GNULIB_DUP2''@/1/g' \ -e 's/@''GNULIB_DUP3''@/0/g' \ -e 's/@''GNULIB_ENVIRON''@/1/g' \ -e 's/@''GNULIB_EUIDACCESS''@/0/g' \ -e 's/@''GNULIB_EXECL''@/0/g' \ -e 's/@''GNULIB_EXECLE''@/0/g' \ -e 's/@''GNULIB_EXECLP''@/0/g' \ -e 's/@''GNULIB_EXECV''@/0/g' \ -e 's/@''GNULIB_EXECVE''@/0/g' \ -e 's/@''GNULIB_EXECVP''@/0/g' \ -e 's/@''GNULIB_EXECVPE''@/0/g' \ -e 's/@''GNULIB_FACCESSAT''@/0/g' \ -e 's/@''GNULIB_FCHDIR''@/0/g' \ -e 's/@''GNULIB_FCHOWNAT''@/0/g' \ -e 's/@''GNULIB_FDATASYNC''@/0/g' \ -e 's/@''GNULIB_FSYNC''@/1/g' \ -e 's/@''GNULIB_FTRUNCATE''@/0/g' \ -e 's/@''GNULIB_GETCWD''@/1/g' \ -e 's/@''GNULIB_GETDOMAINNAME''@/0/g' \ -e 's/@''GNULIB_GETDTABLESIZE''@/1/g' \ -e 's/@''GNULIB_GETENTROPY''@/0/g' \ -e 's/@''GNULIB_GETGROUPS''@/0/g' \ -e 's/@''GNULIB_GETHOSTNAME''@/0/g' \ -e 's/@''GNULIB_GETLOGIN''@/0/g' \ -e 's/@''GNULIB_GETLOGIN_R''@/0/g' \ -e 's/@''GNULIB_GETOPT_POSIX''@/1/g' \ -e 's/@''GNULIB_GETPAGESIZE''@/0/g' \ -e 's/@''GNULIB_GETPASS''@/0/g' \ -e 's/@''GNULIB_GETUSERSHELL''@/0/g' \ -e 's/@''GNULIB_GROUP_MEMBER''@/0/g' \ -e 's/@''GNULIB_ISATTY''@/0/g' \ -e 's/@''GNULIB_LCHOWN''@/0/g' \ -e 's/@''GNULIB_LINK''@/0/g' \ -e 's/@''GNULIB_LINKAT''@/0/g' \ -e 's/@''GNULIB_LSEEK''@/0/g' \ -e 's/@''GNULIB_PIPE''@/1/g' \ -e 's/@''GNULIB_PIPE2''@/1/g' \ -e 's/@''GNULIB_PREAD''@/0/g' \ -e 's/@''GNULIB_PWRITE''@/0/g' \ -e 's/@''GNULIB_READ''@/0/g' \ -e 's/@''GNULIB_READLINK''@/1/g' \ -e 's/@''GNULIB_READLINKAT''@/0/g' \ -e 's/@''GNULIB_RMDIR''@/0/g' \ -e 's/@''GNULIB_SETHOSTNAME''@/0/g' \ -e 's/@''GNULIB_SLEEP''@/0/g' \ -e 's/@''GNULIB_SYMLINK''@/0/g' \ -e 's/@''GNULIB_SYMLINKAT''@/0/g' \ -e 's/@''GNULIB_TRUNCATE''@/0/g' \ -e 's/@''GNULIB_TTYNAME_R''@/0/g' \ -e 's/@''GNULIB_UNISTD_H_GETOPT''@/00/g' \ -e 's/@''GNULIB_UNISTD_H_NONBLOCKING''@/0/g' \ -e 's/@''GNULIB_UNISTD_H_SIGPIPE''@/0/g' \ -e 's/@''GNULIB_UNLINK''@/1/g' \ -e 's/@''GNULIB_UNLINKAT''@/0/g' \ -e 's/@''GNULIB_USLEEP''@/0/g' \ -e 's/@''GNULIB_WRITE''@/0/g' \ -e 's/@''GNULIB_MDA_ACCESS''@/1/g' \ -e 's/@''GNULIB_MDA_CHDIR''@/1/g' \ -e 's/@''GNULIB_MDA_CLOSE''@/1/g' \ -e 's/@''GNULIB_MDA_DUP''@/1/g' \ -e 's/@''GNULIB_MDA_DUP2''@/1/g' \ -e 's/@''GNULIB_MDA_EXECL''@/1/g' \ -e 's/@''GNULIB_MDA_EXECLE''@/1/g' \ -e 's/@''GNULIB_MDA_EXECLP''@/1/g' \ -e 's/@''GNULIB_MDA_EXECV''@/1/g' \ -e 's/@''GNULIB_MDA_EXECVE''@/1/g' \ -e 's/@''GNULIB_MDA_EXECVP''@/1/g' \ -e 's/@''GNULIB_MDA_EXECVPE''@/1/g' \ -e 's/@''GNULIB_MDA_GETCWD''@/1/g' \ -e 's/@''GNULIB_MDA_GETPID''@/1/g' \ -e 's/@''GNULIB_MDA_ISATTY''@/1/g' \ -e 's/@''GNULIB_MDA_LSEEK''@/1/g' \ -e 's/@''GNULIB_MDA_READ''@/1/g' \ -e 's/@''GNULIB_MDA_RMDIR''@/1/g' \ -e 's/@''GNULIB_MDA_SWAB''@/1/g' \ -e 's/@''GNULIB_MDA_UNLINK''@/1/g' \ -e 's/@''GNULIB_MDA_WRITE''@/1/g' \ < ./lib/unistd.in.h | \ sed -e 's|@''HAVE_CHOWN''@|1|g' \ -e 's|@''HAVE_COPY_FILE_RANGE''@|1|g' \ -e 's|@''HAVE_DUP3''@|1|g' \ -e 's|@''HAVE_EUIDACCESS''@|1|g' \ -e 's|@''HAVE_EXECVPE''@|1|g' \ -e 's|@''HAVE_FACCESSAT''@|1|g' \ -e 's|@''HAVE_FCHDIR''@|1|g' \ -e 's|@''HAVE_FCHOWNAT''@|1|g' \ -e 's|@''HAVE_FDATASYNC''@|1|g' \ -e 's|@''HAVE_FSYNC''@|1|g' \ -e 's|@''HAVE_FTRUNCATE''@|1|g' \ -e 's|@''HAVE_GETDTABLESIZE''@|1|g' \ -e 's|@''HAVE_GETENTROPY''@|1|g' \ -e 's|@''HAVE_GETGROUPS''@|1|g' \ -e 's|@''HAVE_GETHOSTNAME''@|1|g' \ -e 's|@''HAVE_GETPAGESIZE''@|1|g' \ -e 's|@''HAVE_GETPASS''@|1|g' \ -e 's|@''HAVE_GROUP_MEMBER''@|1|g' \ -e 's|@''HAVE_LCHOWN''@|1|g' \ -e 's|@''HAVE_LINK''@|1|g' \ -e 's|@''HAVE_LINKAT''@|1|g' \ -e 's|@''HAVE_PIPE''@|1|g' \ -e 's|@''HAVE_PIPE2''@|1|g' \ -e 's|@''HAVE_PREAD''@|1|g' \ -e 's|@''HAVE_PWRITE''@|1|g' \ -e 's|@''HAVE_READLINK''@|1|g' \ -e 's|@''HAVE_READLINKAT''@|1|g' \ -e 's|@''HAVE_SETHOSTNAME''@|1|g' \ -e 's|@''HAVE_SLEEP''@|1|g' \ -e 's|@''HAVE_SYMLINK''@|1|g' \ -e 's|@''HAVE_SYMLINKAT''@|1|g' \ -e 's|@''HAVE_UNLINKAT''@|1|g' \ -e 's|@''HAVE_USLEEP''@|1|g' \ -e 's|@''HAVE_DECL_ENVIRON''@|1|g' \ -e 's|@''HAVE_DECL_EXECVPE''@|1|g' \ -e 's|@''HAVE_DECL_FCHDIR''@|1|g' \ -e 's|@''HAVE_DECL_FDATASYNC''@|1|g' \ -e 's|@''HAVE_DECL_GETDOMAINNAME''@|1|g' \ -e 's|@''HAVE_DECL_GETLOGIN''@|1|g' \ -e 's|@''HAVE_DECL_GETLOGIN_R''@|1|g' \ -e 's|@''HAVE_DECL_GETPAGESIZE''@|1|g' \ -e 's|@''HAVE_DECL_GETUSERSHELL''@|1|g' \ -e 's|@''HAVE_DECL_SETHOSTNAME''@|1|g' \ -e 's|@''HAVE_DECL_TRUNCATE''@|1|g' \ -e 's|@''HAVE_DECL_TTYNAME_R''@|1|g' \ -e 's|@''HAVE_OS_H''@|0|g' \ -e 's|@''HAVE_SYS_PARAM_H''@|0|g' \ | \ sed -e 's|@''REPLACE_ACCESS''@|0|g' \ -e 's|@''REPLACE_CHOWN''@|0|g' \ -e 's|@''REPLACE_CLOSE''@|0|g' \ -e 's|@''REPLACE_DUP''@|0|g' \ -e 's|@''REPLACE_DUP2''@|0|g' \ -e 's|@''REPLACE_EXECL''@|0|g' \ -e 's|@''REPLACE_EXECLE''@|0|g' \ -e 's|@''REPLACE_EXECLP''@|0|g' \ -e 's|@''REPLACE_EXECV''@|0|g' \ -e 's|@''REPLACE_EXECVE''@|0|g' \ -e 's|@''REPLACE_EXECVP''@|0|g' \ -e 's|@''REPLACE_EXECVPE''@|0|g' \ -e 's|@''REPLACE_FACCESSAT''@|0|g' \ -e 's|@''REPLACE_FCHOWNAT''@|0|g' \ -e 's|@''REPLACE_FTRUNCATE''@|0|g' \ -e 's|@''REPLACE_GETCWD''@|0|g' \ -e 's|@''REPLACE_GETDOMAINNAME''@|0|g' \ -e 's|@''REPLACE_GETDTABLESIZE''@|0|g' \ -e 's|@''REPLACE_GETLOGIN_R''@|0|g' \ -e 's|@''REPLACE_GETGROUPS''@|0|g' \ -e 's|@''REPLACE_GETPAGESIZE''@|0|g' \ -e 's|@''REPLACE_GETPASS''@|0|g' \ -e 's|@''REPLACE_ISATTY''@|0|g' \ -e 's|@''REPLACE_LCHOWN''@|0|g' \ -e 's|@''REPLACE_LINK''@|0|g' \ -e 's|@''REPLACE_LINKAT''@|0|g' \ -e 's|@''REPLACE_LSEEK''@|0|g' \ -e 's|@''REPLACE_PREAD''@|0|g' \ -e 's|@''REPLACE_PWRITE''@|0|g' \ -e 's|@''REPLACE_READ''@|0|g' \ -e 's|@''REPLACE_READLINK''@|0|g' \ -e 's|@''REPLACE_READLINKAT''@|0|g' \ -e 's|@''REPLACE_RMDIR''@|0|g' \ -e 's|@''REPLACE_SLEEP''@|0|g' \ -e 's|@''REPLACE_SYMLINK''@|0|g' \ -e 's|@''REPLACE_SYMLINKAT''@|0|g' \ -e 's|@''REPLACE_TRUNCATE''@|0|g' \ -e 's|@''REPLACE_TTYNAME_R''@|0|g' \ -e 's|@''REPLACE_UNLINK''@|0|g' \ -e 's|@''REPLACE_UNLINKAT''@|0|g' \ -e 's|@''REPLACE_USLEEP''@|0|g' \ -e 's|@''REPLACE_WRITE''@|0|g' \ -e 's|@''UNISTD_H_HAVE_SYS_RANDOM_H''@|0|g' \ -e 's|@''UNISTD_H_HAVE_WINSOCK2_H''@|0|g' \ -e 's|@''UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h'; \ } > lib/unistd.h-t && \ mv lib/unistd.h-t lib/unistd.h rm -f lib/unistr.h-t lib/unistr.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ cat ./lib/unistr.in.h; \ } > lib/unistr.h-t && \ mv -f lib/unistr.h-t lib/unistr.h rm -f lib/unitypes.h-t lib/unitypes.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ cat ./lib/unitypes.in.h; \ } > lib/unitypes.h-t && \ mv -f lib/unitypes.h-t lib/unitypes.h rm -f lib/uniwidth.h-t lib/uniwidth.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ cat ./lib/uniwidth.in.h; \ } > lib/uniwidth.h-t && \ mv -f lib/uniwidth.h-t lib/uniwidth.h rm -f lib/wchar.h-t lib/wchar.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''HAVE_FEATURES_H''@|1|g' \ -e 's|@''NEXT_WCHAR_H''@||g' \ -e 's|@''HAVE_WCHAR_H''@|1|g' \ -e 's/@''HAVE_CRTDEFS_H''@/0/g' \ -e 's/@''GNULIBHEADERS_OVERRIDE_WINT_T''@/0/g' \ -e 's/@''GNULIB_BTOWC''@/0/g' \ -e 's/@''GNULIB_WCTOB''@/0/g' \ -e 's/@''GNULIB_MBSINIT''@/1/g' \ -e 's/@''GNULIB_MBRTOWC''@/1/g' \ -e 's/@''GNULIB_MBRLEN''@/0/g' \ -e 's/@''GNULIB_MBSRTOWCS''@/0/g' \ -e 's/@''GNULIB_MBSNRTOWCS''@/0/g' \ -e 's/@''GNULIB_WCRTOMB''@/0/g' \ -e 's/@''GNULIB_WCSRTOMBS''@/0/g' \ -e 's/@''GNULIB_WCSNRTOMBS''@/0/g' \ -e 's/@''GNULIB_WCWIDTH''@/1/g' \ -e 's/@''GNULIB_WMEMCHR''@/0/g' \ -e 's/@''GNULIB_WMEMCMP''@/0/g' \ -e 's/@''GNULIB_WMEMCPY''@/0/g' \ -e 's/@''GNULIB_WMEMMOVE''@/0/g' \ -e 's/@''GNULIB_WMEMPCPY''@/0/g' \ -e 's/@''GNULIB_WMEMSET''@/0/g' \ -e 's/@''GNULIB_WCSLEN''@/0/g' \ -e 's/@''GNULIB_WCSNLEN''@/0/g' \ -e 's/@''GNULIB_WCSCPY''@/0/g' \ -e 's/@''GNULIB_WCPCPY''@/0/g' \ -e 's/@''GNULIB_WCSNCPY''@/0/g' \ -e 's/@''GNULIB_WCPNCPY''@/0/g' \ -e 's/@''GNULIB_WCSCAT''@/0/g' \ -e 's/@''GNULIB_WCSNCAT''@/0/g' \ -e 's/@''GNULIB_WCSCMP''@/0/g' \ -e 's/@''GNULIB_WCSNCMP''@/0/g' \ -e 's/@''GNULIB_WCSCASECMP''@/0/g' \ -e 's/@''GNULIB_WCSNCASECMP''@/0/g' \ -e 's/@''GNULIB_WCSCOLL''@/0/g' \ -e 's/@''GNULIB_WCSXFRM''@/0/g' \ -e 's/@''GNULIB_WCSDUP''@/0/g' \ -e 's/@''GNULIB_WCSCHR''@/0/g' \ -e 's/@''GNULIB_WCSRCHR''@/0/g' \ -e 's/@''GNULIB_WCSCSPN''@/0/g' \ -e 's/@''GNULIB_WCSSPN''@/0/g' \ -e 's/@''GNULIB_WCSPBRK''@/0/g' \ -e 's/@''GNULIB_WCSSTR''@/0/g' \ -e 's/@''GNULIB_WCSTOK''@/0/g' \ -e 's/@''GNULIB_WCSWIDTH''@/0/g' \ -e 's/@''GNULIB_WCSFTIME''@/0/g' \ -e 's/@''GNULIB_MDA_WCSDUP''@/1/g' \ < ./lib/wchar.in.h | \ sed -e 's|@''HAVE_WINT_T''@|1|g' \ -e 's|@''HAVE_BTOWC''@|1|g' \ -e 's|@''HAVE_MBSINIT''@|1|g' \ -e 's|@''HAVE_MBRTOWC''@|1|g' \ -e 's|@''HAVE_MBRLEN''@|1|g' \ -e 's|@''HAVE_MBSRTOWCS''@|1|g' \ -e 's|@''HAVE_MBSNRTOWCS''@|1|g' \ -e 's|@''HAVE_WCRTOMB''@|1|g' \ -e 's|@''HAVE_WCSRTOMBS''@|1|g' \ -e 's|@''HAVE_WCSNRTOMBS''@|1|g' \ -e 's|@''HAVE_WMEMCHR''@|1|g' \ -e 's|@''HAVE_WMEMCMP''@|1|g' \ -e 's|@''HAVE_WMEMCPY''@|1|g' \ -e 's|@''HAVE_WMEMMOVE''@|1|g' \ -e 's|@''HAVE_WMEMPCPY''@|1|g' \ -e 's|@''HAVE_WMEMSET''@|1|g' \ -e 's|@''HAVE_WCSLEN''@|1|g' \ -e 's|@''HAVE_WCSNLEN''@|1|g' \ -e 's|@''HAVE_WCSCPY''@|1|g' \ -e 's|@''HAVE_WCPCPY''@|1|g' \ -e 's|@''HAVE_WCSNCPY''@|1|g' \ -e 's|@''HAVE_WCPNCPY''@|1|g' \ -e 's|@''HAVE_WCSCAT''@|1|g' \ -e 's|@''HAVE_WCSNCAT''@|1|g' \ -e 's|@''HAVE_WCSCMP''@|1|g' \ -e 's|@''HAVE_WCSNCMP''@|1|g' \ -e 's|@''HAVE_WCSCASECMP''@|1|g' \ -e 's|@''HAVE_WCSNCASECMP''@|1|g' \ -e 's|@''HAVE_WCSCOLL''@|1|g' \ -e 's|@''HAVE_WCSXFRM''@|1|g' \ -e 's|@''HAVE_WCSDUP''@|1|g' \ -e 's|@''HAVE_WCSCHR''@|1|g' \ -e 's|@''HAVE_WCSRCHR''@|1|g' \ -e 's|@''HAVE_WCSCSPN''@|1|g' \ -e 's|@''HAVE_WCSSPN''@|1|g' \ -e 's|@''HAVE_WCSPBRK''@|1|g' \ -e 's|@''HAVE_WCSSTR''@|1|g' \ -e 's|@''HAVE_WCSTOK''@|1|g' \ -e 's|@''HAVE_WCSWIDTH''@|1|g' \ -e 's|@''HAVE_WCSFTIME''@|1|g' \ -e 's|@''HAVE_DECL_WCTOB''@|1|g' \ -e 's|@''HAVE_DECL_WCSDUP''@|1|g' \ -e 's|@''HAVE_DECL_WCWIDTH''@|1|g' \ | \ sed -e 's|@''REPLACE_MBSTATE_T''@|0|g' \ -e 's|@''REPLACE_BTOWC''@|0|g' \ -e 's|@''REPLACE_WCTOB''@|0|g' \ -e 's|@''REPLACE_FREE''@|0|g' \ -e 's|@''REPLACE_MBSINIT''@|0|g' \ -e 's|@''REPLACE_MBRTOWC''@|1|g' \ -e 's|@''REPLACE_MBRLEN''@|0|g' \ -e 's|@''REPLACE_MBSRTOWCS''@|0|g' \ -e 's|@''REPLACE_MBSNRTOWCS''@|0|g' \ -e 's|@''REPLACE_WCRTOMB''@|0|g' \ -e 's|@''REPLACE_WCSRTOMBS''@|0|g' \ -e 's|@''REPLACE_WCSNRTOMBS''@|0|g' \ -e 's|@''REPLACE_WCWIDTH''@|0|g' \ -e 's|@''REPLACE_WCSWIDTH''@|0|g' \ -e 's|@''REPLACE_WCSFTIME''@|0|g' \ -e 's|@''REPLACE_WCSTOK''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h'; \ } > lib/wchar.h-t && \ mv lib/wchar.h-t lib/wchar.h rm -f lib/wctype.h-t lib/wctype.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's/@''HAVE_WCTYPE_H''@/1/g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_WCTYPE_H''@||g' \ -e 's/@''HAVE_CRTDEFS_H''@/0/g' \ -e 's/@''GNULIBHEADERS_OVERRIDE_WINT_T''@/0/g' \ -e 's/@''GNULIB_ISWBLANK''@/1/g' \ -e 's/@''GNULIB_ISWDIGIT''@/1/g' \ -e 's/@''GNULIB_ISWXDIGIT''@/1/g' \ -e 's/@''GNULIB_WCTYPE''@/0/g' \ -e 's/@''GNULIB_ISWCTYPE''@/0/g' \ -e 's/@''GNULIB_WCTRANS''@/0/g' \ -e 's/@''GNULIB_TOWCTRANS''@/0/g' \ -e 's/@''HAVE_ISWBLANK''@/1/g' \ -e 's/@''HAVE_ISWCNTRL''@/1/g' \ -e 's/@''HAVE_WCTYPE_T''@/1/g' \ -e 's/@''HAVE_WCTRANS_T''@/1/g' \ -e 's/@''HAVE_WINT_T''@/1/g' \ -e 's/@''REPLACE_ISWBLANK''@/0/g' \ -e 's/@''REPLACE_ISWDIGIT''@/0/g' \ -e 's/@''REPLACE_ISWXDIGIT''@/0/g' \ -e 's/@''REPLACE_ISWCNTRL''@/0/g' \ -e 's/@''REPLACE_TOWLOWER''@/0/g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/wctype.in.h; \ } > lib/wctype.h-t && \ mv lib/wctype.h-t lib/wctype.h echo 3.8.2 > .version-t && mv .version-t .version make all-recursive make[2]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' Making all in po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/po' make[3]: Nothing to be done for 'all'. make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/po' Making all in runtime-po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' make[3]: Nothing to be done for 'all'. make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' Making all in gnulib-po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' make[3]: Nothing to be done for 'all'. make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' Making all in . make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-bitsetv.o `test -f 'lib/bitsetv.c' || echo './'`lib/bitsetv.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-c-ctype.o `test -f 'lib/c-ctype.c' || echo './'`lib/c-ctype.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-c-strcasecmp.o `test -f 'lib/c-strcasecmp.c' || echo './'`lib/c-strcasecmp.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-c-strncasecmp.o `test -f 'lib/c-strncasecmp.c' || echo './'`lib/c-strncasecmp.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-canonicalize.o `test -f 'lib/canonicalize.c' || echo './'`lib/canonicalize.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-careadlinkat.o `test -f 'lib/careadlinkat.c' || echo './'`lib/careadlinkat.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-cloexec.o `test -f 'lib/cloexec.c' || echo './'`lib/cloexec.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-close-stream.o `test -f 'lib/close-stream.c' || echo './'`lib/close-stream.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-closeout.o `test -f 'lib/closeout.c' || echo './'`lib/closeout.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-concat-filename.o `test -f 'lib/concat-filename.c' || echo './'`lib/concat-filename.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-dirname.o `test -f 'lib/dirname.c' || echo './'`lib/dirname.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-basename.o `test -f 'lib/basename.c' || echo './'`lib/basename.c lib/careadlinkat.c: In function 'careadlinkat': lib/careadlinkat.c:178:5: warning: #warning "GCC might issue a bogus -Wreturn-local-addr warning here." [-Wcpp] 178 | #warning "GCC might issue a bogus -Wreturn-local-addr warning here." | ^~~~~~~ lib/careadlinkat.c:179:5: warning: #warning "See ." [-Wcpp] 179 | #warning "See ." | ^~~~~~~ gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-dirname-lgpl.o `test -f 'lib/dirname-lgpl.c' || echo './'`lib/dirname-lgpl.c lib/canonicalize.c: In function 'canonicalize_filename_mode': lib/careadlinkat.c:182:10: warning: function may return address of local variable [-Wreturn-local-addr] 182 | return readlink_stk (fd, filename, buffer, buffer_size, alloc, | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 183 | preadlinkat, stack_buf); | ~~~~~~~~~~~~~~~~~~~~~~~ lib/canonicalize.c:484:5: warning: #warning "GCC might issue a bogus -Wreturn-local-addr warning here." [-Wcpp] 484 | #warning "GCC might issue a bogus -Wreturn-local-addr warning here." | ^~~~~~~ lib/canonicalize.c:485:5: warning: #warning "See ." [-Wcpp] 485 | #warning "See ." | ^~~~~~~ lib/careadlinkat.c:181:8: note: declared here 181 | char stack_buf[STACK_BUF_SIZE]; | ^~~~~~~~~ gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-stripslash.o `test -f 'lib/stripslash.c' || echo './'`lib/stripslash.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-execute.o `test -f 'lib/execute.c' || echo './'`lib/execute.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-exitfail.o `test -f 'lib/exitfail.c' || echo './'`lib/exitfail.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fatal-signal.o `test -f 'lib/fatal-signal.c' || echo './'`lib/fatal-signal.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fd-safer-flag.o `test -f 'lib/fd-safer-flag.c' || echo './'`lib/fd-safer-flag.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-dup-safer-flag.o `test -f 'lib/dup-safer-flag.c' || echo './'`lib/dup-safer-flag.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-file-set.o `test -f 'lib/file-set.c' || echo './'`lib/file-set.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-findprog-in.o `test -f 'lib/findprog-in.c' || echo './'`lib/findprog-in.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fopen-safer.o `test -f 'lib/fopen-safer.c' || echo './'`lib/fopen-safer.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fstrcmp.o `test -f 'lib/fstrcmp.c' || echo './'`lib/fstrcmp.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gethrxtime.o `test -f 'lib/gethrxtime.c' || echo './'`lib/gethrxtime.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xtime.o `test -f 'lib/xtime.c' || echo './'`lib/xtime.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-getprogname.o `test -f 'lib/getprogname.c' || echo './'`lib/getprogname.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gettime.o `test -f 'lib/gettime.c' || echo './'`lib/gettime.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-hard-locale.o `test -f 'lib/hard-locale.c' || echo './'`lib/hard-locale.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-hash.o `test -f 'lib/hash.c' || echo './'`lib/hash.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_hash_map.o `test -f 'lib/gl_hash_map.c' || echo './'`lib/gl_hash_map.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-hash-pjw.o `test -f 'lib/hash-pjw.c' || echo './'`lib/hash-pjw.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-hash-triple-simple.o `test -f 'lib/hash-triple-simple.c' || echo './'`lib/hash-triple-simple.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-ialloc.o `test -f 'lib/ialloc.c' || echo './'`lib/ialloc.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-integer_length.o `test -f 'lib/integer_length.c' || echo './'`lib/integer_length.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-integer_length_l.o `test -f 'lib/integer_length_l.c' || echo './'`lib/integer_length_l.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_linked_list.o `test -f 'lib/gl_linked_list.c' || echo './'`lib/gl_linked_list.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_list.o `test -f 'lib/gl_list.c' || echo './'`lib/gl_list.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-localcharset.o `test -f 'lib/localcharset.c' || echo './'`lib/localcharset.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_map.o `test -f 'lib/gl_map.c' || echo './'`lib/gl_map.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-math.o `test -f 'lib/math.c' || echo './'`lib/math.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-mbchar.o `test -f 'lib/mbchar.c' || echo './'`lib/mbchar.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-mbfile.o `test -f 'lib/mbfile.c' || echo './'`lib/mbfile.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-mbswidth.o `test -f 'lib/mbswidth.c' || echo './'`lib/mbswidth.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_oset.o `test -f 'lib/gl_oset.c' || echo './'`lib/gl_oset.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-pipe2.o `test -f 'lib/pipe2.c' || echo './'`lib/pipe2.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-pipe2-safer.o `test -f 'lib/pipe2-safer.c' || echo './'`lib/pipe2-safer.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-printf-frexp.o `test -f 'lib/printf-frexp.c' || echo './'`lib/printf-frexp.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-printf-frexpl.o `test -f 'lib/printf-frexpl.c' || echo './'`lib/printf-frexpl.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-progname.o `test -f 'lib/progname.c' || echo './'`lib/progname.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-quotearg.o `test -f 'lib/quotearg.c' || echo './'`lib/quotearg.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_rbtree_oset.o `test -f 'lib/gl_rbtree_oset.c' || echo './'`lib/gl_rbtree_oset.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_rbtreehash_list.o `test -f 'lib/gl_rbtreehash_list.c' || echo './'`lib/gl_rbtreehash_list.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-setlocale_null.o `test -f 'lib/setlocale_null.c' || echo './'`lib/setlocale_null.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-sig-handler.o `test -f 'lib/sig-handler.c' || echo './'`lib/sig-handler.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-spawn-pipe.o `test -f 'lib/spawn-pipe.c' || echo './'`lib/spawn-pipe.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/glthread/libbison_a-threadlib.o `test -f 'lib/glthread/threadlib.c' || echo './'`lib/glthread/threadlib.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-timespec.o `test -f 'lib/timespec.c' || echo './'`lib/timespec.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-timevar.o `test -f 'lib/timevar.c' || echo './'`lib/timevar.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/glthread/libbison_a-tls.o `test -f 'lib/glthread/tls.c' || echo './'`lib/glthread/tls.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-unicodeio.o `test -f 'lib/unicodeio.c' || echo './'`lib/unicodeio.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-unistd.o `test -f 'lib/unistd.c' || echo './'`lib/unistd.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-dup-safer.o `test -f 'lib/dup-safer.c' || echo './'`lib/dup-safer.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fd-safer.o `test -f 'lib/fd-safer.c' || echo './'`lib/fd-safer.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-pipe-safer.o `test -f 'lib/pipe-safer.c' || echo './'`lib/pipe-safer.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-wait-process.o `test -f 'lib/wait-process.c' || echo './'`lib/wait-process.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-wctype-h.o `test -f 'lib/wctype-h.c' || echo './'`lib/wctype-h.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xmalloc.o `test -f 'lib/xmalloc.c' || echo './'`lib/xmalloc.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xalloc-die.o `test -f 'lib/xalloc-die.c' || echo './'`lib/xalloc-die.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xconcat-filename.o `test -f 'lib/xconcat-filename.c' || echo './'`lib/xconcat-filename.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xhash.o `test -f 'lib/xhash.c' || echo './'`lib/xhash.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_xlist.o `test -f 'lib/gl_xlist.c' || echo './'`lib/gl_xlist.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_xmap.o `test -f 'lib/gl_xmap.c' || echo './'`lib/gl_xmap.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xmemdup0.o `test -f 'lib/xmemdup0.c' || echo './'`lib/xmemdup0.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xreadlink.o `test -f 'lib/xreadlink.c' || echo './'`lib/xreadlink.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xsize.o `test -f 'lib/xsize.c' || echo './'`lib/xsize.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xstrndup.o `test -f 'lib/xstrndup.c' || echo './'`lib/xstrndup.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-get-errno.o `test -f 'lib/get-errno.c' || echo './'`lib/get-errno.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-path-join.o `test -f 'lib/path-join.c' || echo './'`lib/path-join.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-asnprintf.o `test -f 'lib/asnprintf.c' || echo './'`lib/asnprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-asprintf.o `test -f 'lib/asprintf.c' || echo './'`lib/asprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fcntl.o `test -f 'lib/fcntl.c' || echo './'`lib/fcntl.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fprintf.o `test -f 'lib/fprintf.c' || echo './'`lib/fprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fseterr.o `test -f 'lib/fseterr.c' || echo './'`lib/fseterr.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-mbrtowc.o `test -f 'lib/mbrtowc.c' || echo './'`lib/mbrtowc.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-obstack.o `test -f 'lib/obstack.c' || echo './'`lib/obstack.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-printf.o `test -f 'lib/printf.c' || echo './'`lib/printf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-printf-args.o `test -f 'lib/printf-args.c' || echo './'`lib/printf-args.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-printf-parse.o `test -f 'lib/printf-parse.c' || echo './'`lib/printf-parse.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-readline.o `test -f 'lib/readline.c' || echo './'`lib/readline.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-snprintf.o `test -f 'lib/snprintf.c' || echo './'`lib/snprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-spawn_faction_addchdir.o `test -f 'lib/spawn_faction_addchdir.c' || echo './'`lib/spawn_faction_addchdir.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-sprintf.o `test -f 'lib/sprintf.c' || echo './'`lib/sprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-vasnprintf.o `test -f 'lib/vasnprintf.c' || echo './'`lib/vasnprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-vasprintf.o `test -f 'lib/vasprintf.c' || echo './'`lib/vasprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-vfprintf.o `test -f 'lib/vfprintf.c' || echo './'`lib/vfprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-vsnprintf.o `test -f 'lib/vsnprintf.c' || echo './'`lib/vsnprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-vsprintf.o `test -f 'lib/vsprintf.c' || echo './'`lib/vsprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/main.o lib/main.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/yyerror.o lib/yyerror.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-AnnotationList.o `test -f 'src/AnnotationList.c' || echo './'`src/AnnotationList.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-InadequacyList.o `test -f 'src/InadequacyList.c' || echo './'`src/InadequacyList.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-Sbitset.o `test -f 'src/Sbitset.c' || echo './'`src/Sbitset.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-assoc.o `test -f 'src/assoc.c' || echo './'`src/assoc.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-closure.o `test -f 'src/closure.c' || echo './'`src/closure.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-complain.o `test -f 'src/complain.c' || echo './'`src/complain.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-conflicts.o `test -f 'src/conflicts.c' || echo './'`src/conflicts.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-counterexample.o `test -f 'src/counterexample.c' || echo './'`src/counterexample.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-derivation.o `test -f 'src/derivation.c' || echo './'`src/derivation.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-derives.o `test -f 'src/derives.c' || echo './'`src/derives.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-files.o `test -f 'src/files.c' || echo './'`src/files.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-fixits.o `test -f 'src/fixits.c' || echo './'`src/fixits.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-getargs.o `test -f 'src/getargs.c' || echo './'`src/getargs.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-glyphs.o `test -f 'src/glyphs.c' || echo './'`src/glyphs.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-gram.o `test -f 'src/gram.c' || echo './'`src/gram.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-graphviz.o `test -f 'src/graphviz.c' || echo './'`src/graphviz.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-ielr.o `test -f 'src/ielr.c' || echo './'`src/ielr.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-lalr.o `test -f 'src/lalr.c' || echo './'`src/lalr.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-location.o `test -f 'src/location.c' || echo './'`src/location.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-lr0.o `test -f 'src/lr0.c' || echo './'`src/lr0.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-lssi.o `test -f 'src/lssi.c' || echo './'`src/lssi.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-main.o `test -f 'src/main.c' || echo './'`src/main.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-muscle-tab.o `test -f 'src/muscle-tab.c' || echo './'`src/muscle-tab.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-named-ref.o `test -f 'src/named-ref.c' || echo './'`src/named-ref.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-nullable.o `test -f 'src/nullable.c' || echo './'`src/nullable.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-output.o `test -f 'src/output.c' || echo './'`src/output.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-parse-gram.o `test -f 'src/parse-gram.c' || echo './'`src/parse-gram.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-parse-simulation.o `test -f 'src/parse-simulation.c' || echo './'`src/parse-simulation.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-print-graph.o `test -f 'src/print-graph.c' || echo './'`src/print-graph.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-print-xml.o `test -f 'src/print-xml.c' || echo './'`src/print-xml.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-print.o `test -f 'src/print.c' || echo './'`src/print.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-reader.o `test -f 'src/reader.c' || echo './'`src/reader.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-reduce.o `test -f 'src/reduce.c' || echo './'`src/reduce.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-relation.o `test -f 'src/relation.c' || echo './'`src/relation.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-scan-code-c.o `test -f 'src/scan-code-c.c' || echo './'`src/scan-code-c.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-scan-gram-c.o `test -f 'src/scan-gram-c.c' || echo './'`src/scan-gram-c.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-scan-skel-c.o `test -f 'src/scan-skel-c.c' || echo './'`src/scan-skel-c.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-state.o `test -f 'src/state.c' || echo './'`src/state.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-state-item.o `test -f 'src/state-item.c' || echo './'`src/state-item.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-strversion.o `test -f 'src/strversion.c' || echo './'`src/strversion.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-symlist.o `test -f 'src/symlist.c' || echo './'`src/symlist.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-symtab.o `test -f 'src/symtab.c' || echo './'`src/symtab.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-tables.o `test -f 'src/tables.c' || echo './'`src/tables.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-uniqstr.o `test -f 'src/uniqstr.c' || echo './'`src/uniqstr.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-allocator.o `test -f 'lib/allocator.c' || echo './'`lib/allocator.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-areadlink.o `test -f 'lib/areadlink.c' || echo './'`lib/areadlink.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-argmatch.o `test -f 'lib/argmatch.c' || echo './'`lib/argmatch.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_array_list.o `test -f 'lib/gl_array_list.c' || echo './'`lib/gl_array_list.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-basename-lgpl.o `test -f 'lib/basename-lgpl.c' || echo './'`lib/basename-lgpl.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-binary-io.o `test -f 'lib/binary-io.c' || echo './'`lib/binary-io.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-bitrotate.o `test -f 'lib/bitrotate.c' || echo './'`lib/bitrotate.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-bitset.o `test -f 'lib/bitset.c' || echo './'`lib/bitset.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/bitset/libbison_a-array.o `test -f 'lib/bitset/array.c' || echo './'`lib/bitset/array.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/bitset/libbison_a-stats.o `test -f 'lib/bitset/stats.c' || echo './'`lib/bitset/stats.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/bitset/libbison_a-table.o `test -f 'lib/bitset/table.c' || echo './'`lib/bitset/table.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/bitset/libbison_a-list.o `test -f 'lib/bitset/list.c' || echo './'`lib/bitset/list.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/bitset/libbison_a-vector.o `test -f 'lib/bitset/vector.c' || echo './'`lib/bitset/vector.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/glthread/libbison_a-lock.o `test -f 'lib/glthread/lock.c' || echo './'`lib/glthread/lock.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/malloc/libbison_a-scratch_buffer_dupfree.o `test -f 'lib/malloc/scratch_buffer_dupfree.c' || echo './'`lib/malloc/scratch_buffer_dupfree.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/malloc/libbison_a-scratch_buffer_grow.o `test -f 'lib/malloc/scratch_buffer_grow.c' || echo './'`lib/malloc/scratch_buffer_grow.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/malloc/libbison_a-scratch_buffer_grow_preserve.o `test -f 'lib/malloc/scratch_buffer_grow_preserve.c' || echo './'`lib/malloc/scratch_buffer_grow_preserve.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/malloc/libbison_a-scratch_buffer_set_array_size.o `test -f 'lib/malloc/scratch_buffer_set_array_size.c' || echo './'`lib/malloc/scratch_buffer_set_array_size.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/unistr/libbison_a-u8-mbtoucr.o `test -f 'lib/unistr/u8-mbtoucr.c' || echo './'`lib/unistr/u8-mbtoucr.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/unistr/libbison_a-u8-uctomb.o `test -f 'lib/unistr/u8-uctomb.c' || echo './'`lib/unistr/u8-uctomb.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/unistr/libbison_a-u8-uctomb-aux.o `test -f 'lib/unistr/u8-uctomb-aux.c' || echo './'`lib/unistr/u8-uctomb-aux.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/uniwidth/libbison_a-width.o `test -f 'lib/uniwidth/width.c' || echo './'`lib/uniwidth/width.c rm -f lib/liby.a ar cr lib/liby.a lib/main.o lib/yyerror.o ranlib lib/liby.a rm -f lib/libbison.a ar cr lib/libbison.a lib/libbison_a-allocator.o lib/libbison_a-areadlink.o lib/libbison_a-argmatch.o lib/libbison_a-gl_array_list.o lib/libbison_a-basename-lgpl.o lib/libbison_a-binary-io.o lib/libbison_a-bitrotate.o lib/libbison_a-bitset.o lib/bitset/libbison_a-array.o lib/bitset/libbison_a-stats.o lib/bitset/libbison_a-table.o lib/bitset/libbison_a-list.o lib/bitset/libbison_a-vector.o lib/libbison_a-bitsetv.o lib/libbison_a-c-ctype.o lib/libbison_a-c-strcasecmp.o lib/libbison_a-c-strncasecmp.o lib/libbison_a-canonicalize.o lib/libbison_a-careadlinkat.o lib/libbison_a-cloexec.o lib/libbison_a-close-stream.o lib/libbison_a-closeout.o lib/libbison_a-concat-filename.o lib/libbison_a-dirname.o lib/libbison_a-basename.o lib/libbison_a-dirname-lgpl.o lib/libbison_a-stripslash.o lib/libbison_a-execute.o lib/libbison_a-exitfail.o lib/libbison_a-fatal-signal.o lib/libbison_a-fd-safer-flag.o lib/libbison_a-dup-safer-flag.o lib/libbison_a-file-set.o lib/libbison_a-findprog-in.o lib/libbison_a-fopen-safer.o lib/libbison_a-fstrcmp.o lib/libbison_a-gethrxtime.o lib/libbison_a-xtime.o lib/libbison_a-getprogname.o lib/libbison_a-gettime.o lib/libbison_a-hard-locale.o lib/libbison_a-hash.o lib/libbison_a-gl_hash_map.o lib/libbison_a-hash-pjw.o lib/libbison_a-hash-triple-simple.o lib/libbison_a-ialloc.o lib/libbison_a-integer_length.o lib/libbison_a-integer_length_l.o lib/libbison_a-gl_linked_list.o lib/libbison_a-gl_list.o lib/libbison_a-localcharset.o lib/glthread/libbison_a-lock.o lib/libbison_a-gl_map.o lib/libbison_a-math.o lib/libbison_a-mbchar.o lib/libbison_a-mbfile.o lib/libbison_a-mbswidth.o lib/libbison_a-gl_oset.o lib/libbison_a-pipe2.o lib/libbison_a-pipe2-safer.o lib/libbison_a-printf-frexp.o lib/libbison_a-printf-frexpl.o lib/libbison_a-progname.o lib/libbison_a-quotearg.o lib/libbison_a-gl_rbtree_oset.o lib/libbison_a-gl_rbtreehash_list.o lib/malloc/libbison_a-scratch_buffer_dupfree.o lib/malloc/libbison_a-scratch_buffer_grow.o lib/malloc/libbison_a-scratch_buffer_grow_preserve.o lib/malloc/libbison_a-scratch_buffer_set_array_size.o lib/libbison_a-setlocale_null.o lib/libbison_a-sig-handler.o lib/libbison_a-spawn-pipe.o lib/glthread/libbison_a-threadlib.o lib/libbison_a-timespec.o lib/libbison_a-timevar.o lib/glthread/libbison_a-tls.o lib/libbison_a-unicodeio.o lib/libbison_a-unistd.o lib/libbison_a-dup-safer.o lib/libbison_a-fd-safer.o lib/libbison_a-pipe-safer.o lib/unistr/libbison_a-u8-mbtoucr.o lib/unistr/libbison_a-u8-uctomb.o lib/unistr/libbison_a-u8-uctomb-aux.o lib/uniwidth/libbison_a-width.o lib/libbison_a-wait-process.o lib/libbison_a-wctype-h.o lib/libbison_a-xmalloc.o lib/libbison_a-xalloc-die.o lib/libbison_a-xconcat-filename.o lib/libbison_a-xhash.o lib/libbison_a-gl_xlist.o lib/libbison_a-gl_xmap.o lib/libbison_a-xmemdup0.o lib/libbison_a-xreadlink.o lib/libbison_a-xsize.o lib/libbison_a-xstrndup.o lib/libbison_a-get-errno.o lib/libbison_a-path-join.o lib/libbison_a-asnprintf.o lib/libbison_a-asprintf.o lib/libbison_a-fcntl.o lib/libbison_a-fprintf.o lib/libbison_a-fseterr.o lib/libbison_a-mbrtowc.o lib/libbison_a-obstack.o lib/libbison_a-printf.o lib/libbison_a-printf-args.o lib/libbison_a-printf-parse.o lib/libbison_a-readline.o lib/libbison_a-snprintf.o lib/libbison_a-spawn_faction_addchdir.o lib/libbison_a-sprintf.o lib/libbison_a-vasnprintf.o lib/libbison_a-vasprintf.o lib/libbison_a-vfprintf.o lib/libbison_a-vsnprintf.o lib/libbison_a-vsprintf.o ranlib lib/libbison.a gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o src/bison src/bison-AnnotationList.o src/bison-InadequacyList.o src/bison-Sbitset.o src/bison-assoc.o src/bison-closure.o src/bison-complain.o src/bison-conflicts.o src/bison-counterexample.o src/bison-derivation.o src/bison-derives.o src/bison-files.o src/bison-fixits.o src/bison-getargs.o src/bison-glyphs.o src/bison-gram.o src/bison-graphviz.o src/bison-ielr.o src/bison-lalr.o src/bison-location.o src/bison-lr0.o src/bison-lssi.o src/bison-main.o src/bison-muscle-tab.o src/bison-named-ref.o src/bison-nullable.o src/bison-output.o src/bison-parse-gram.o src/bison-parse-simulation.o src/bison-print-graph.o src/bison-print-xml.o src/bison-print.o src/bison-reader.o src/bison-reduce.o src/bison-relation.o src/bison-scan-code-c.o src/bison-scan-gram-c.o src/bison-scan-skel-c.o src/bison-state.o src/bison-state-item.o src/bison-strversion.o src/bison-symlist.o src/bison-symtab.o src/bison-tables.o src/bison-uniqstr.o lib/libbison.a /usr/bin/mkdir -p doc LC_ALL=C tests/bison --version >doc/bison.help.tmp LC_ALL=C tests/bison --help | \ sed -e 's,^Usage: .*/bison \[OPTION\],Usage: bison [OPTION],g' \ -e '/translation bugs/d' >>doc/bison.help.tmp ./build-aux/move-if-change doc/bison.help.tmp doc/bison.help if /bin/bash '/build/reproducible-path/bison-3.8.2+dfsg/build-aux/missing' help2man --version >/dev/null 2>&1; then \ /bin/bash '/build/reproducible-path/bison-3.8.2+dfsg/build-aux/missing' help2man \ --include=./doc/bison.x \ --output=doc/bison.1.tmp tests/bison && \ { sed 's/^\(\.TH[^"]*"[^"]*"[^"]*\)"[^"]*"/\1/' doc/bison.1 >doc/bison.1a.tmp || true; } && \ sed 's/^\(\.TH[^"]*"[^"]*"[^"]*\)"[^"]*"/\1/' doc/bison.1.tmp >doc/bison.1b.tmp && \ if diff doc/bison.1a.tmp doc/bison.1b.tmp >/dev/null 2>&1; then \ touch doc/bison.1; \ else \ mv doc/bison.1.tmp doc/bison.1; \ fi && \ rm -f doc/bison.1*.tmp; \ elif test -d ./.git; then \ echo >&2 "ERROR: doc/bison.1: help2man is needed"; \ exit 1; \ else \ touch doc/bison.1; \ fi /usr/bin/perl -pi.bak -0777 \ -e 's{(^ --.*\n(?: {10}.*\n)*)}' \ -e '{' \ -e ' $def = $1;' \ -e ' $def =~ s/‘|’//g;' \ -e ' $def;' \ -e '}gem;' ./doc/bison.info make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[2]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' dh_auto_test make -j12 check "TESTSUITEFLAGS=-j12 --verbose" VERBOSE=1 make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' if test -d ./.git \ && git --version >/dev/null 2>&1; then \ cd . && \ git submodule --quiet foreach \ 'test "$(git rev-parse "$sha1")" \ = "$(git merge-base origin "$sha1")"' \ || { echo 'maint.mk: found non-public submodule commit' >&2; \ exit 1; }; \ else \ : ; \ fi make check-recursive make[2]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' Making check in po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/po' make[3]: Nothing to be done for 'check'. make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/po' Making check in runtime-po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' make[3]: Nothing to be done for 'check'. make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' Making check in gnulib-po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' make[3]: Nothing to be done for 'check'. make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' Making check in . make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' /usr/bin/mkdir -p doc LC_ALL=C tests/bison --version >doc/bison.help.tmp LC_ALL=C tests/bison --help | \ sed -e 's,^Usage: .*/bison \[OPTION\],Usage: bison [OPTION],g' \ -e '/translation bugs/d' >>doc/bison.help.tmp ./build-aux/move-if-change doc/bison.help.tmp doc/bison.help make examples/c/calc/calc examples/c/glr/c++-types examples/c/lexcalc/lexcalc examples/c/mfcalc/mfcalc examples/c/pushcalc/calc examples/c/reccalc/reccalc examples/c/rpcalc/rpcalc examples/c++/calc++/calc++ examples/c++/glr/c++-types examples/c++/simple examples/c++/variant examples/c++/variant-11 ./tests/bison tests/atconfig tests/atlocal make[4]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' /bin/bash ./build-aux/ylwrap examples/c/calc/calc.y y.tab.c examples/c/calc/calc.c y.tab.h `echo examples/c/calc/calc.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/calc/calc.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines /bin/bash ./build-aux/ylwrap examples/c/glr/c++-types.y y.tab.c examples/c/glr/c++-types.c y.tab.h `echo examples/c/glr/c++-types.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/glr/c++-types.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines /bin/bash ./build-aux/ylwrap examples/c/lexcalc/parse.y y.tab.c examples/c/lexcalc/parse.c y.tab.h `echo examples/c/lexcalc/parse.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/lexcalc/parse.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines \ /bin/bash ./build-aux/ylwrap `test -f 'examples/c/lexcalc/scan.l' || echo './'`examples/c/lexcalc/scan.l lex.yy.c examples/c/lexcalc/scan.c -- flex /bin/bash ./build-aux/ylwrap examples/c/mfcalc/mfcalc.y y.tab.c examples/c/mfcalc/mfcalc.c y.tab.h `echo examples/c/mfcalc/mfcalc.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/mfcalc/mfcalc.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines /bin/bash ./build-aux/ylwrap examples/c/pushcalc/calc.y y.tab.c examples/c/pushcalc/calc.c y.tab.h `echo examples/c/pushcalc/calc.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/pushcalc/calc.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines /bin/bash ./build-aux/ylwrap examples/c/reccalc/parse.y y.tab.c examples/c/reccalc/parse.c y.tab.h `echo examples/c/reccalc/parse.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/reccalc/parse.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines /bin/bash ./build-aux/ylwrap examples/c/rpcalc/rpcalc.y y.tab.c examples/c/rpcalc/rpcalc.c y.tab.h `echo examples/c/rpcalc/rpcalc.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/rpcalc/rpcalc.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines rm -f examples/c++/calc++/parser.stamp touch examples/c++/calc++/parser.stamp.tmp ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines -o examples/c++/calc++/parser.cc examples/c++/calc++/parser.yy \ /bin/bash ./build-aux/ylwrap `test -f 'examples/c++/calc++/scanner.ll' || echo './'`examples/c++/calc++/scanner.ll lex.yy.c examples/c++/calc++/scanner.cc -- flex rm -f examples/c++/glr/c++-types.stamp touch examples/c++/glr/c++-types.stamp.tmp ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines -o examples/c++/glr/c++-types.cc examples/c++/glr/c++-types.yy \ /bin/bash ./build-aux/ylwrap `test -f 'examples/c++/simple.yy' || echo './'`examples/c++/simple.yy y.tab.c examples/c++/simple.cc y.tab.h `echo examples/c++/simple.cc | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c++/simple.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines updating examples/c/lexcalc/parse.output updating examples/c/calc/calc.output updating examples/c/mfcalc/mfcalc.output mv -f examples/c++/glr/c++-types.stamp.tmp examples/c++/glr/c++-types.stamp updating examples/c/glr/c++-types.output mv -f examples/c++/calc++/parser.stamp.tmp examples/c++/calc++/parser.stamp \ /bin/bash ./build-aux/ylwrap `test -f 'examples/c++/variant.yy' || echo './'`examples/c++/variant.yy y.tab.c examples/c++/variant.cc y.tab.h `echo examples/c++/variant.cc | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c++/variant.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines \ /bin/bash ./build-aux/ylwrap `test -f 'examples/c++/variant-11.yy' || echo './'`examples/c++/variant-11.yy y.tab.c examples/c++/variant-11.cc y.tab.h `echo examples/c++/variant-11.cc | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c++/variant-11.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines make[4]: 'tests/bison' is up to date. make[4]: Nothing to be done for 'tests/atconfig'. make[4]: 'tests/atlocal' is up to date. updating examples/c/calc/calc.h updating examples/c/lexcalc/parse.h updating examples/c/glr/c++-types.h updating examples/c/mfcalc/mfcalc.h gcc -DEXEEXT=\"\" -I./examples/c/calc -I./examples/c/calc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/calc/examples_c_calc_calc-calc.o `test -f 'examples/c/calc/calc.c' || echo './'`examples/c/calc/calc.c gcc -DEXEEXT=\"\" -I./examples/c/glr -I./examples/c/glr -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/glr/examples_c_glr_c___types-c++-types.o `test -f 'examples/c/glr/c++-types.c' || echo './'`examples/c/glr/c++-types.c gcc -DEXEEXT=\"\" -I./examples/c/lexcalc -I./examples/c/lexcalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/lexcalc/examples_c_lexcalc_lexcalc-parse.o `test -f 'examples/c/lexcalc/parse.c' || echo './'`examples/c/lexcalc/parse.c updating examples/c/pushcalc/calc.output gcc -DEXEEXT=\"\" -I./examples/c/lexcalc -I./examples/c/lexcalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/lexcalc/examples_c_lexcalc_lexcalc-scan.o `test -f 'examples/c/lexcalc/scan.c' || echo './'`examples/c/lexcalc/scan.c gcc -DEXEEXT=\"\" -I./examples/c/mfcalc -I./examples/c/mfcalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/mfcalc/examples_c_mfcalc_mfcalc-mfcalc.o `test -f 'examples/c/mfcalc/mfcalc.c' || echo './'`examples/c/mfcalc/mfcalc.c g++ -DEXEEXT=\"\" -I./examples/c++/calc++ -I./examples/c++/calc++ -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/calc++/calc__-driver.o `test -f 'examples/c++/calc++/driver.cc' || echo './'`examples/c++/calc++/driver.cc updating examples/c/reccalc/parse.output updating examples/c/pushcalc/calc.h g++ -DEXEEXT=\"\" -I./examples/c++/calc++ -I./examples/c++/calc++ -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/calc++/calc__-scanner.o `test -f 'examples/c++/calc++/scanner.cc' || echo './'`examples/c++/calc++/scanner.cc updating examples/c/rpcalc/rpcalc.output updating examples/c/reccalc/parse.h g++ -DEXEEXT=\"\" -I./examples/c++/calc++ -I./examples/c++/calc++ -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/calc++/calc__-calc++.o `test -f 'examples/c++/calc++/calc++.cc' || echo './'`examples/c++/calc++/calc++.cc updating examples/c/rpcalc/rpcalc.h g++ -DEXEEXT=\"\" -I./examples/c++/calc++ -I./examples/c++/calc++ -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/calc++/calc__-parser.o `test -f 'examples/c++/calc++/parser.cc' || echo './'`examples/c++/calc++/parser.cc updating examples/c++/simple.output updating examples/c++/simple.hh updating examples/c++/variant.output g++ -DEXEEXT=\"\" -I./examples/c++/glr -I./examples/c++/glr -Wdate-time -D_FORTIFY_SOURCE=2 -std=c++14 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/glr/examples_c___glr_c___types-c++-types.o `test -f 'examples/c++/glr/c++-types.cc' || echo './'`examples/c++/glr/c++-types.cc updating examples/c++/variant-11.output g++ -DEXEEXT=\"\" -I. -Wdate-time -D_FORTIFY_SOURCE=2 -std=c++11 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/simple-simple.o `test -f 'examples/c++/simple.cc' || echo './'`examples/c++/simple.cc updating examples/c++/variant.hh gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/calc/calc examples/c/calc/examples_c_calc_calc-calc.o gcc -DEXEEXT=\"\" -I./examples/c/pushcalc -I./examples/c/pushcalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/pushcalc/examples_c_pushcalc_calc-calc.o `test -f 'examples/c/pushcalc/calc.c' || echo './'`examples/c/pushcalc/calc.c gcc -DEXEEXT=\"\" -I./examples/c/reccalc -I./examples/c/reccalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/reccalc/examples_c_reccalc_reccalc-parse.o `test -f 'examples/c/reccalc/parse.c' || echo './'`examples/c/reccalc/parse.c gcc -DEXEEXT=\"\" -I./examples/c/reccalc -I./examples/c/reccalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/reccalc/examples_c_reccalc_reccalc-scan.o `test -f 'examples/c/reccalc/scan.c' || echo './'`examples/c/reccalc/scan.c updating examples/c++/variant-11.hh gcc -DEXEEXT=\"\" -I./examples/c/rpcalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/rpcalc/examples_c_rpcalc_rpcalc-rpcalc.o `test -f 'examples/c/rpcalc/rpcalc.c' || echo './'`examples/c/rpcalc/rpcalc.c g++ -DEXEEXT=\"\" -I. -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/variant-variant.o `test -f 'examples/c++/variant.cc' || echo './'`examples/c++/variant.cc g++ -DEXEEXT=\"\" -I. -Wdate-time -D_FORTIFY_SOURCE=2 -std=c++11 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/variant_11-variant-11.o `test -f 'examples/c++/variant-11.cc' || echo './'`examples/c++/variant-11.cc gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/lexcalc/lexcalc examples/c/lexcalc/examples_c_lexcalc_lexcalc-parse.o examples/c/lexcalc/examples_c_lexcalc_lexcalc-scan.o gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/mfcalc/mfcalc examples/c/mfcalc/examples_c_mfcalc_mfcalc-mfcalc.o -lm gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/reccalc/reccalc examples/c/reccalc/examples_c_reccalc_reccalc-parse.o examples/c/reccalc/examples_c_reccalc_reccalc-scan.o gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/rpcalc/rpcalc examples/c/rpcalc/examples_c_rpcalc_rpcalc-rpcalc.o -lm gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/pushcalc/calc examples/c/pushcalc/examples_c_pushcalc_calc-calc.o gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/glr/c++-types examples/c/glr/examples_c_glr_c___types-c++-types.o g++ -std=c++11 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c++/simple examples/c++/simple-simple.o g++ -std=c++11 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c++/variant-11 examples/c++/variant_11-variant-11.o g++ -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c++/calc++/calc++ examples/c++/calc++/calc__-driver.o examples/c++/calc++/calc__-scanner.o examples/c++/calc++/calc__-calc++.o examples/c++/calc++/calc__-parser.o g++ -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c++/variant examples/c++/variant-variant.o g++ -std=c++14 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c++/glr/c++-types examples/c++/glr/examples_c___glr_c___types-c++-types.o make[4]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make check-TESTS check-local make[4]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' make all-recursive make[5]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' rm -f tests/package.m4 tests/package.m4.tmp { \ echo '# Signature of the current package.'; \ echo 'm4_define([AT_PACKAGE_NAME], [GNU Bison])'; \ echo 'm4_define([AT_PACKAGE_TARNAME], [bison])'; \ echo 'm4_define([AT_PACKAGE_VERSION], [3.8.2])'; \ echo 'm4_define([AT_PACKAGE_STRING], [GNU Bison 3.8.2])'; \ echo 'm4_define([AT_PACKAGE_BUGREPORT], [bug-bison@gnu.org])'; \ } >tests/package.m4.tmp mv tests/package.m4.tmp tests/package.m4 \ /bin/bash '/build/reproducible-path/bison-3.8.2+dfsg/build-aux/missing' autom4te --language=autotest -I ./tests ./tests/testsuite.at -o tests/testsuite.tmp make[5]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' Making all in po make[6]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/po' make[6]: Nothing to be done for 'all'. make[6]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/po' Making all in runtime-po make[6]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' make[6]: Nothing to be done for 'all'. make[6]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' Making all in gnulib-po make[6]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' make[6]: Nothing to be done for 'all'. make[6]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' Making all in . make[6]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' /usr/bin/mkdir -p doc LC_ALL=C tests/bison --version >doc/bison.help.tmp LC_ALL=C tests/bison --help | \ sed -e 's,^Usage: .*/bison \[OPTION\],Usage: bison [OPTION],g' \ -e '/translation bugs/d' >>doc/bison.help.tmp ./build-aux/move-if-change doc/bison.help.tmp doc/bison.help make[6]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[5]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' PASS: examples/c/glr/c++-types.test PASS: examples/c++/simple.test PASS: examples/c++/glr/c++-types.test PASS: examples/c++/variant.test PASS: examples/c++/variant-11.test PASS: examples/c/mfcalc/mfcalc.test PASS: examples/c/rpcalc/rpcalc.test PASS: examples/c/calc/calc.test PASS: examples/c/lexcalc/lexcalc.test PASS: examples/c/pushcalc/calc.test PASS: examples/c++/calc++/calc++.test PASS: examples/c/reccalc/reccalc.test ============================================================================ Testsuite summary for GNU Bison 3.8.2 ============================================================================ # TOTAL: 12 # PASS: 12 # SKIP: 0 # XFAIL: 0 # FAIL: 0 # XPASS: 0 # ERROR: 0 ============================================================================ make[5]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' "/usr/bin/perl" -pi -e 's/\@tb\@/\t/g' tests/testsuite.tmp mv tests/testsuite.tmp tests/testsuite /bin/bash ./tests/testsuite -C tests -j12 --verbose ## --------------------------- ## ## GNU Bison 3.8.2 test suite. ## ## --------------------------- ## 1. m4.at:21: testing Generating Comments ... 2. input.at:27: testing Invalid number of arguments ... ./input.at:29: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 6. input.at:173: testing Yacc warnings on symbols ... 9. input.at:287: testing Invalid symbol declarations ... ./input.at:34: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y 2.y ./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wyacc input.y ./m4.at:53: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -S ./input.m4 input.y ./input.at:304: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y 12. input.at:427: testing Symbol declarations ... 7. input.at:204: testing Yacc warnings ... 5. input.at:147: testing Invalid inputs with {} ... ./input.at:162: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 3. input.at:58: testing Invalid options ... ./input.at:67: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -ferror=caret input.y 10. input.at:341: testing Redefining the error token ... ./input.at:354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:467: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S./dump-symbols.m4 input.y ./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wyacc input.y 4. input.at:83: testing Invalid inputs ... ./input.at:97: "$PERL" -pi -e 's/\\(\d{3})/chr(oct($1))/ge' input.y || exit 77 11. input.at:401: testing Dangling aliases ... ./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wdangling input.y stderr: 9. input.at:287: ok ./input.at:390: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 8. input.at:238: testing Yacc's %type ... 5. input.at:147: ok ./input.at:42: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --skeleton bison: invalid argument 'error=caret' for '--feature' Valid arguments are: - 'none' - 'caret', 'diagnostics-show-caret' - 'fixit', 'diagnostics-parseable-fixits' - 'syntax-only' - 'all' ./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wyacc input.y ./input.at:99: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:68: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=error=itemsets input.y ./m4.at:55: cat output.txt stderr: bison: option '--skeleton' requires an argument Try 'bison --help' for more information. ./input.at:43: sed -e \ "s/requires an argument -- skeleton/'--skeleton' requires an argument/" \ stderr ./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wdangling input.y -Werror stderr: bison: invalid argument 'error=itemsets' for '--report' Valid arguments are: - 'none' - 'states' - 'itemsets' - 'lookaheads' - 'solved' - 'counterexamples', 'cex' - 'all' 1. m4.at:21: ./input.at:72: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror?all input.y ok stderr: stderr: bison: invalid argument 'error?all' for '--warning' Valid arguments are: - 'all' - 'conflicts-rr' - 'conflicts-sr' - 'counterexamples', 'cex' - 'dangling-alias' - 'deprecated' - 'empty-rule' - 'everything' - 'midrule-values' - 'none' - 'other' - 'precedence' - 'yacc' input.y:1.11: error: invalid null character 1 | %header "ð€ˆ" | ^ input.y:2.1-2: error: invalid characters: '\0\001\002\377?' 2 | ÿ? | ^~ input.y:3.2: error: invalid null character 3 | "" | ^ input.y:5.1: error: invalid character: '?' 5 | ? | ^ input.y:6.14: error: invalid character: '}' 6 | default: 'a' } | ^ input.y:7.1: error: invalid character: '%' 7 | %& | ^ input.y:7.2: error: invalid character: '&' 7 | %& | ^ input.y:8.1-17: error: invalid directive: '%a-does-not-exist' 8 | %a-does-not-exist | ^~~~~~~~~~~~~~~~~ input.y:9.1: error: invalid character: '%' 9 | %- | ^ input.y:9.2: error: invalid character: '-' 9 | %- | ^ input.y:10.1-11.0: error: missing '%}' at end of file 10 | %{ | ^~ ./input.at:104: "$PERL" -p -e 's{([\0\200\210\360\377])}{sprintf "\\x%02x", ord($1)}ge' stderr ./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Werror 3. input.at:58: ok ./input.at:468: cat symbols.csv ./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Werror 2. input.at:27: ok ./input.at:390: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 13. input.at:528: testing Invalid $n and @n ... 14. input.at:552: testing Type Clashes ... ./input.at:565: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:536: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y 12. input.at:427: stderr: ok input.y:2.13-17: error: string literal "bar" not attached to a symbol [-Werror=dangling-alias] 2 | %type "bar" | ^~~~~ input.y:4.19-23: error: string literal "baz" not attached to a symbol [-Werror=dangling-alias] 4 | expr: "foo" "bar" "baz" | ^~~~~ 14. input.at:552: ok 4. input.at:83: ok 15. input.at:774: testing Unused values ... 13. input.at:528: ok stderr: input.y:1.1-11: error: POSIX Yacc does not support %destructor [-Werror=yacc] 1 | %destructor {} | ^~~~~~~~~~~ input.y:2.1-8: error: POSIX Yacc does not support %printer [-Werror=yacc] 2 | %printer {} | ^~~~~~~~ input.y:6.9-20: error: POSIX Yacc does not support typed midrule actions [-Werror=yacc] 6 | a: { $$ = 42; } { $$ = $1; }; | ^~~~~~~~~~~~ input.y:7.4-9: error: POSIX Yacc does not support %empty [-Werror=yacc] 7 | b: %empty { $$ = 42; }; | ^~~~~~ ./input.at:410: sed 's,.*/$,,' stderr 1>&2 stderr: ./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y input.y:1.1-6: error: POSIX Yacc does not support %nterm [-Werror=yacc] 1 | %nterm exp | ^~~~~~ input.y:2.12-15: error: POSIX Yacc does not support hexadecimal literals [-Werror=yacc] 2 | %token NUM 0x40 "number" | ^~~~ input.y:2.17-24: error: POSIX Yacc does not support string literals [-Werror=yacc] 2 | %token NUM 0x40 "number" | ^~~~~~~~ input.y:4.6-13: error: POSIX Yacc does not support string literals [-Werror=yacc] 4 | exp: "number"; | ^~~~~~~~ ./input.at:216: sed 's,.*/$,,' stderr 1>&2 ./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Werror ./input.at:182: sed 's,.*/$,,' stderr 1>&2 16. input.at:784: testing Unused values before symbol declarations ... 17. input.at:794: testing Symbol redeclared ... ./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=error 18. input.at:832: testing EOF redeclared ... ./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y 19. input.at:859: testing Symbol class redefinition ... stderr: ./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wdangling input.y --warnings=error ./input.at:871: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y input.y:2.1-6: error: POSIX Yacc does not support %nterm [-Werror=yacc] 2 | %nterm nterm1 | ^~~~~~ input.y:3.14-19: error: POSIX yacc reserves %type to nonterminals [-Werror=yacc] 3 | %type TOKEN1 TOKEN2 "TOKEN3" nterm1 nterm2 nterm3 '+' | ^~~~~~ input.y:3.28-35: error: POSIX Yacc does not support string literals [-Werror=yacc] 3 | %type TOKEN1 TOKEN2 "TOKEN3" nterm1 nterm2 nterm3 '+' | ^~~~~~~~ input.y:3.28-35: error: POSIX yacc reserves %type to nonterminals [-Werror=yacc] 3 | %type TOKEN1 TOKEN2 "TOKEN3" nterm1 nterm2 nterm3 '+' | ^~~~~~~~ input.y:3.58-60: error: POSIX yacc reserves %type to nonterminals [-Werror=yacc] 3 | %type TOKEN1 TOKEN2 "TOKEN3" nterm1 nterm2 nterm3 '+' | ^~~ input.y:5.1-6: error: POSIX Yacc does not support %nterm [-Werror=yacc] 5 | %nterm nterm2 | ^~~~~~ input.y:3.21-26: error: POSIX yacc reserves %type to nonterminals [-Werror=yacc] 3 | %type TOKEN1 TOKEN2 "TOKEN3" nterm1 nterm2 nterm3 '+' | ^~~~~~ input.y:10.9-16: error: POSIX Yacc does not support string literals [-Werror=yacc] 10 | nterm3: "TOKEN3" | ^~~~~~~~ 20. input.at:899: testing Default %printer and %destructor redeclared ... ./input.at:959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=error ./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror ./input.at:253: sed 's,.*/$,,' stderr 1>&2 21. input.at:970: testing Per-type %printer and %destructor redeclared ... ./input.at:987: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:960: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror 19. input.at:859: ok ./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror stderr: stdout: ./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Wnone,none -Werror --trace=none ./input.at:391: $PREPARSER ./input ./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Wnone,none -Werror --trace=none 21. input.at:970: ok ./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wdangling input.y -Wnone,none -Werror --trace=none stderr: 20. input.at:899: stderr: ok ./input.at:391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror input.y:1.12-14: error: symbol FOO redeclared [-Werror=other] 1 | %token FOO FOO | ^~~ input.y:1.8-10: note: previous declaration 1 | %token FOO FOO | ^~~ input.y:2.15-17: error: symbol BAR redeclared [-Werror=other] 2 | %token BAR 12 BAR 12 | ^~~ input.y:2.8-10: note: previous declaration 2 | %token BAR 12 BAR 12 | ^~~ input.y:3.14-16: error: symbol EOF redeclared [-Werror=other] 3 | %token EOF 0 EOF 0 | ^~~ input.y:3.8-10: note: previous declaration 3 | %token EOF 0 EOF 0 | ^~~ ./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=error stderr: ./input.at:804: sed 's,.*/$,,' stderr 1>&2 ./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=none -Werror --trace=none input.y:1.16-18: error: symbol FOO redeclared [-Werror=other] 1 | %token FOO BAR FOO 0 | ^~~ input.y:1.8-10: note: previous declaration 1 | %token FOO BAR FOO 0 | ^~~ 10. input.at:341: ok ./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wdangling input.y --warnings=none -Werror --trace=none ./input.at:843: sed 's,.*/$,,' stderr 1>&2 23. input.at:1045: testing Unassociated types used for a printer or destructor ... ./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y 22. input.at:1013: testing Undefined symbols ... ./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=none -Werror --trace=none stderr: input.y:12.10-32: error: unset value: $$ [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~ input.y:12.10-12: error: unused value: $1 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.18-20: error: unused value: $3 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.26-28: error: unused value: $5 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:13.10-15: error: empty rule for typed nonterminal, and no action [-Werror=other] 13 | b: INT | %empty; | ^~~~~~ input.y:14.10-62: error: unset value: $$ [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:14.22-24: error: unused value: $3 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:14.43-45: error: unused value: $5 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:15.10-49: error: unset value: $$ [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:15.18-20: error: unused value: $3 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:15.30-32: error: unused value: $5 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:16.10-37: error: unset value: $$ [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:16.18-20: error: unused value: $3 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:16.27-29: error: unused value: $5 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:18.10-58: error: unset value: $$ [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:18.10-12: error: unused value: $1 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.31-33: error: unused value: $3 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.52-54: error: unused value: $5 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:19.10-72: error: unset value: $$ [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:19.10-12: error: unused value: $1 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.31-33: error: unused value: $3 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.66-68: error: unused value: $5 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:22.10-68: error: unset value: $$ [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:22.10-12: error: unused value: $1 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:22.14-16: error: unused value: $2 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:25.23-25: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.10-50: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:25.10-12: error: unused value: $1 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.23-25: error: unused value: $2 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.27-29: error: unused value: $3 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unused value: $4 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.44-46: error: unused value: $5 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:26.23-25: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ input.y:26.40-42: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ ./input.at:1023: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error 11. input.at:401: ./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Wnone,none -Werror --trace=none ok ./input.at:775: sed 's,.*/$,,' stderr 1>&2 24. input.at:1074: testing Useless printers or destructors ... ./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y 22. input.at:1013: ok ./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error 25. input.at:1139: testing Unused values with default %destructor ... ./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror stderr: 6. input.at:173: ok input.y:12.10-32: error: unset value: $$ [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~ input.y:12.10-12: error: unused value: $1 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.18-20: error: unused value: $3 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.26-28: error: unused value: $5 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:13.10-15: error: empty rule for typed nonterminal, and no action [-Werror=other] 13 | b: INT | %empty; | ^~~~~~ input.y:14.10-62: error: unset value: $$ [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:14.22-24: error: unused value: $3 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:14.43-45: error: unused value: $5 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:15.10-49: error: unset value: $$ [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:15.18-20: error: unused value: $3 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:15.30-32: error: unused value: $5 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:16.10-37: error: unset value: $$ [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:16.18-20: error: unused value: $3 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:16.27-29: error: unused value: $5 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:18.10-58: error: unset value: $$ [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:18.10-12: error: unused value: $1 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.31-33: error: unused value: $3 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.52-54: error: unused value: $5 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:19.10-72: error: unset value: $$ [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:19.10-12: error: unused value: $1 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.31-33: error: unused value: $3 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.66-68: error: unused value: $5 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:22.10-68: error: unset value: $$ [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:22.10-12: error: unused value: $1 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:22.14-16: error: unused value: $2 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:25.23-25: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.10-50: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:25.10-12: error: unused value: $1 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.23-25: error: unused value: $2 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.27-29: error: unused value: $3 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unused value: $4 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.44-46: error: unused value: $5 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:26.23-25: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ input.y:26.40-42: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ ./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=none -Werror --trace=none ./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none 7. input.at:204: ok ./input.at:785: sed 's,.*/$,,' stderr 1>&2 ./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror ./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror stderr: 26. input.at:1187: testing Unused values with per-type %destructor ... ./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y 27. input.at:1219: testing Duplicate string ... ./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y input.y:4.22-28: error: type is used, but is not associated to any symbol [-Werror=other] input.y:5.25-31: error: type is used, but is not associated to any symbol [-Werror=other] 28. input.at:1247: testing Token collisions ... ./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error 8. input.at:238: ok ./input.at:1256: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:1062: sed 's,.*/$,,' stderr 1>&2 ./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror stderr: ./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none input.y:6.8-45: error: unset value: $$ [-Werror=other] 6 | start: end end tagged tagged { $1; $3; } ; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:6.12-14: error: unused value: $2 [-Werror=other] 6 | start: end end tagged tagged { $1; $3; } ; | ^~~ input.y:7.6-8: error: unset value: $$ [-Werror=other] 7 | end: { } ; | ^~~ stderr: 28. input.at:1247: ./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ok ./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error input.y:16.13-19: error: useless %printer for type [-Werror=other] input.y:17.16-22: error: useless %destructor for type [-Werror=other] ./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -o input.c input.y -Werror ./input.at:1152: sed 's,.*/$,,' stderr 1>&2 29. input.at:1275: testing Incompatible Aliases ... ./input.at:1285: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y stderr: input.y:6.8-22: error: unset value: $$ [-Werror=other] 6 | start: end end { $1; } ; | ^~~~~~~~~~~~~~~ input.y:6.12-14: error: unused value: $2 [-Werror=other] 6 | start: end end { $1; } ; | ^~~ input.y:7.6-8: error: unset value: $$ [-Werror=other] 7 | end: { } ; | ^~~ 30. input.at:1400: testing Torturing the Scanner ... ./input.at:1407: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1085: sed 's,.*/$,,' stderr 1>&2 18. input.at:832: ok ./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none ./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error ./input.at:1299: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1199: sed 's,.*/$,,' stderr 1>&2 ./input.at:1554: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -v -o input.c input.y 17. input.at:794: ok stderr: input.y:6.11-14: error: symbol "<=" used more than once as a literal string [-Werror=other] ./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none 32. input.at:1609: testing Require 1.0 ... ./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none ./input.at:1609: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./input.at:1313: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y 31. input.at:1569: testing Typed symbol aliases ... ./input.at:1586: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./input.at:1236: sed 's,.*/$,,' stderr 1>&2 ./input.at:1327: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:1555: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none 33. input.at:1610: testing Require 3.8.2 ... stderr: ./input.at:1610: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -o input.c input.y --warnings=error 32. input.at:1609: ok stderr: 23. input.at:1045: ok 31. input.at:1569: ok ./input.at:1344: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none 33. input.at:1610: ok ./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y ./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./input.at:1359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y ./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -o input.c input.y -Wnone,none -Werror --trace=none stderr: 34. input.at:1612: testing Require 100.0 ... ./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror ./input.at:1612: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y ./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y stdout: 35. input.at:1619: testing String aliases for character tokens ... ./input.at:1632: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./input.at:1374: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1556: $CC $CFLAGS $CPPFLAGS -c -o main.o main.c 26. input.at:1187: ok 36. input.at:1642: testing Symbols ... ./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --yacc input.y ./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -o input.c input.y --warnings=none -Werror --trace=none 37. input.at:1708: testing Numbered tokens ... stderr: input.y:3.13-14: error: useless %printer for type <> [-Werror=other] 29. input.at:1275: stderr: ok ./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror ./input.at:1720: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret redecl.y input.y:9.10-16: error: require bison 100.0, but have 3.8.2 34. input.at:1612: 35. input.at:1619: ok ./input.at:1116: sed 's,.*/$,,' stderr 1>&2 ok stderr: stdout: ./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error ./input.at:1735: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret too-large.y ./input.at:1557: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.o main.o $LIBS ./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y ./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --yacc input.y -Werror stderr: input.y:6.23-28: error: unused value: $4 [-Werror=other] input.y:8.9-11: error: unset value: $$ [-Werror=other] 37. input.at:1708: ok stderr: stdout: 39. input.at:1805: testing %start after first rule ... ./input.at:1817: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./input.at:1558: $PREPARSER ./input 41. input.at:1895: testing %prec takes a token ... ./input.at:1905: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: 27. input.at:1219: ok ./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none 41. input.at:1895: ./input.at:1175: sed 's,.*/$,,' stderr 1>&2 ok stderr: 40. input.at:1826: testing Duplicate %start symbol ... ./input.at:1558: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input.y:1.1-5: error: POSIX Yacc does not support %code [-Werror=yacc] input.y:9.8-16: error: POSIX Yacc forbids dashes in symbol names: WITH-DASH [-Werror=yacc] input.y:10.21-34: error: POSIX Yacc does not support string literals [-Werror=yacc] input.y:12.23-38: error: POSIX Yacc does not support string literals [-Werror=yacc] input.y:13.1-5: error: POSIX Yacc does not support %code [-Werror=yacc] input.y:20.8-16: error: POSIX Yacc forbids dashes in symbol names: with-dash [-Werror=yacc] input.y:22.15-28: error: POSIX Yacc does not support string literals [-Werror=yacc] input.y:24.17-32: error: POSIX Yacc does not support string literals [-Werror=yacc] 38. input.at:1750: testing Unclosed constructs ... ./input.at:1779: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y ./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error 30. input.at:1400: ok 39. input.at:1805: ok ./input.at:1666: sed 's,.*/$,,' stderr 1>&2 ./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -Werror 38. input.at:1750: ok 43. input.at:1936: testing Reject unused %code qualifiers ... ./input.at:1946: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-c.y ./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror ./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --yacc input.y --warnings=error 42. input.at:1916: testing %prec's token must be defined ... ./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none stderr: ./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y 45. input.at:2065: testing errors ... ./input.at:2077: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-redefined.y ./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -Werror ./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none input.y:1.12-14: error: duplicate directive [-Werror=other] 1 | %start exp exp exp | ^~~ input.y:1.8-10: note: previous declaration 1 | %start exp exp exp | ^~~ input.y:1.16-18: error: duplicate directive [-Werror=other] 1 | %start exp exp exp | ^~~ input.y:1.8-10: note: previous declaration 1 | %start exp exp exp | ^~~ input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] 44. input.at:2025: testing Multiple %code ... ./input.at:2054: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 46. input.at:2102: testing %define, --define, --force-define ... ./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --yacc input.y -Wnone,none -Werror --trace=none ./input.at:1960: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-c-glr.y ./input.at:2091: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-unused.y ./input.at:2118: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dvar-dd=cmd-d1 -Dvar-dd=cmd-d2 \ -Fvar-ff=cmd-f1 -Fvar-ff=cmd-f2 \ -Dvar-dfg=cmd-d -Fvar-dfg=cmd-f \ -Fvar-fd=cmd-f -Dvar-fd=cmd-d \ --skeleton ./skel.c input.y ./input.at:1836: sed 's,.*/$,,' stderr 1>&2 ./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror ./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none 47. input.at:2170: testing "%define" Boolean variables ... ./input.at:2054: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./input.at:2180: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret Input.y ./input.at:2123: cat input.tab.c ./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y stderr: 45. input.at:2065: ok input.y:12.10-32: error: unset value: $$ [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~ input.y:12.10-12: error: unused value: $1 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.18-20: error: unused value: $3 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.26-28: error: unused value: $5 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:13.10-15: error: empty rule for typed nonterminal, and no action [-Werror=other] 13 | b: INT | %empty; | ^~~~~~ input.y:14.14-20: error: unset value: $$ [-Werror=midrule-values] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~ input.y:14.26-41: error: unset value: $$ [-Werror=midrule-values] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~~~~~~~~~~ input.y:14.10-62: error: unset value: $$ [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:14.22-24: error: unused value: $3 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:14.43-45: error: unused value: $5 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:15.14-16: error: unset value: $$ [-Werror=midrule-values] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:15.10-49: error: unset value: $$ [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:15.18-20: error: unused value: $3 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:15.30-32: error: unused value: $5 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:16.10-37: error: unset value: $$ [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:16.18-20: error: unused value: $3 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:16.27-29: error: unused value: $5 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:18.10-58: error: unset value: $$ [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:18.10-12: error: unused value: $1 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.14-29: error: unused value: $2 [-Werror=midrule-values] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~ input.y:18.31-33: error: unused value: $3 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.35-50: error: unused value: $4 [-Werror=midrule-values] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~ input.y:18.52-54: error: unused value: $5 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:19.10-72: error: unset value: $$ [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:19.10-12: error: unused value: $1 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.31-33: error: unused value: $3 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.35-64: error: unused value: $4 [-Werror=midrule-values] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:19.66-68: error: unused value: $5 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:21.18-37: error: unused value: $3 [-Werror=midrule-values] 21 | j: INT | INT INT { $$ = 1; } { $$ = $1 + $2; }; | ^~~~~~~~~~~~~~~~~~~~ input.y:22.10-68: error: unset value: $$ [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:22.10-12: error: unused value: $1 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:22.14-16: error: unused value: $2 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:22.35-64: error: unused value: $4 [-Werror=midrule-values] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:25.23-25: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.10-50: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:25.10-12: error: unused value: $1 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.23-25: error: unused value: $2 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.27-29: error: unused value: $3 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unused value: $4 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.44-46: error: unused value: $5 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:26.23-25: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ input.y:26.40-42: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ ./input.at:2135: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dvar=cmd-d input-dg.y ./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./input.at:2146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Dvar=cmd-d input-dg.y ./input.at:776: sed 's,.*/$,,' stderr 1>&2 stderr: input.y:12.10-32: error: unset value: $$ [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~ input.y:12.10-12: error: unused value: $1 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.18-20: error: unused value: $3 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.26-28: error: unused value: $5 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:13.10-15: error: empty rule for typed nonterminal, and no action [-Werror=other] 13 | b: INT | %empty; | ^~~~~~ input.y:14.14-20: error: unset value: $$ [-Werror=midrule-values] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~ input.y:14.26-41: error: unset value: $$ [-Werror=midrule-values] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~~~~~~~~~~ input.y:14.10-62: error: unset value: $$ [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:14.22-24: error: unused value: $3 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:14.43-45: error: unused value: $5 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:15.14-16: error: unset value: $$ [-Werror=midrule-values] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:15.10-49: error: unset value: $$ [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:15.18-20: error: unused value: $3 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:15.30-32: error: unused value: $5 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:16.10-37: error: unset value: $$ [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:16.18-20: error: unused value: $3 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:16.27-29: error: unused value: $5 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:18.10-58: error: unset value: $$ [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:18.10-12: error: unused value: $1 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.14-29: error: unused value: $2 [-Werror=midrule-values] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~ input.y:18.31-33: error: unused value: $3 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.35-50: error: unused value: $4 [-Werror=midrule-values] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~ input.y:18.52-54: error: unused value: $5 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:19.10-72: error: unset value: $$ [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:19.10-12: error: unused value: $1 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.31-33: error: unused value: $3 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.35-64: error: unused value: $4 [-Werror=midrule-values] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:19.66-68: error: unused value: $5 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:21.18-37: error: unused value: $3 [-Werror=midrule-values] 21 | j: INT | INT INT { $$ = 1; } { $$ = $1 + $2; }; | ^~~~~~~~~~~~~~~~~~~~ input.y:22.10-68: error: unset value: $$ [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:22.10-12: error: unused value: $1 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:22.14-16: error: unused value: $2 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:22.35-64: error: unused value: $4 [-Werror=midrule-values] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:25.23-25: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.10-50: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:25.10-12: error: unused value: $1 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.23-25: error: unused value: $2 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.27-29: error: unused value: $3 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unused value: $4 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.44-46: error: unused value: $5 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:26.23-25: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ input.y:26.40-42: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ ./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --yacc input.y --warnings=none -Werror --trace=none 25. input.at:1139: ok stderr: input.y:2.8-17: error: token for %prec is not defined: PREC [-Werror=other] ./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y --warnings=error ./input.at:2158: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dunused-d -Funused-f input-unused.y ./input.at:786: sed 's,.*/$,,' stderr 1>&2 ./input.at:1925: sed 's,.*/$,,' stderr 1>&2 ./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror 47. input.at:2170: ok ./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y --warnings=error 48. input.at:2191: testing "%define" code variables ... ./input.at:1973: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-c++.y ./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error ./input.at:1678: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.yy 49. input.at:2224: testing "%define" keyword variables ... stderr: ./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y 46. input.at:2102: ok input.y:2.16-18: error: useless %printer for type <*> [-Werror=other] ./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none 50. input.at:2257: testing "%define" enum variables ... ./input.at:2269: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1681: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./input.at:2284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y stderr: ./input.at:1124: sed 's,.*/$,,' stderr 1>&2 ./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./input.at:2303: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y stdout: ./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./input.at:2055: $PREPARSER ./input stderr: ./input.at:1986: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-c++-glr.y ./input.at:2055: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror ./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy -Werror ./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error 44. input.at:2025: ok stderr: 51. input.at:2320: testing "%define" file variables ... ./input.at:2329: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y stdout: 42. input.at:1916: ok ./input.at:1694: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y ./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y --warnings=none -Werror --trace=none stderr: ./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -Wnone,none -Werror --trace=none input.y:5.1-40: error: %define variable 'lr.type' requires keyword values [-Werror=deprecated] input.y:3.1-40: error: %define variable 'lr.default-reduction' requires keyword values [-Werror=deprecated] input.y:4.1-40: error: %define variable 'lr.keep-unreachable-state' requires keyword values [-Werror=deprecated] input.y:1.1-38: error: %define variable 'api.pure' requires keyword values [-Werror=deprecated] input.y:2.1-40: error: %define variable 'api.push-pull' requires keyword values [-Werror=deprecated] 36. input.at:1642: 50. input.at:2257: ok ok ./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror ./input.at:2246: sed 's,.*/$,,' stderr 1>&2 51. input.at:2320: ./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none ok 52. input.at:2342: testing "%define" backward compatibility ... stderr: input.y:1.16-18: error: duplicate directive [-Werror=other] 1 | %start exp foo exp | ^~~ input.y:1.8-10: note: previous declaration 1 | %start exp foo exp | ^~~ input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ./input.at:2355: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1999: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret special-char-@@.y ./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error 53. input.at:2393: testing Unused api.pure ... 54. input.at:2429: testing C++ namespace reference errors ... ./input.at:2450: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 55. input.at:2482: testing Bad character literals ... ./input.at:2484: set x `LC_ALL=C ls -l 'empty.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='empty.y'; } || exit 77 ./input.at:1859: sed 's,.*/$,,' stderr 1>&2 ./input.at:2413: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: 0+0 records in 0+0 records out 0 bytes copied, 2.724e-05 s, 0.0 kB/s ./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y --warnings=none -Werror --trace=none stdout: 52. input.at:2342: ok ./input.at:2490: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret empty.y ./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error 56. input.at:2543: testing Bad escapes in literals ... stderr: input.yy:2.1-30: error: %define variable 'api.location.type' requires '{...}' values [-Werror=deprecated] input.yy:4.1-30: error: %define variable 'api.prefix' requires '{...}' values [-Werror=deprecated] input.yy:5.1-30: error: %define variable 'api.token.prefix' requires '{...}' values [-Werror=deprecated] input.yy:3.1-30: error: %define variable 'api.namespace' requires '{...}' values [-Werror=deprecated] ./input.at:2508: set x `LC_ALL=C ls -l 'two.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='two.y'; } || exit 77 ./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none 15. input.at:774: ok ./input.at:2556: "$PERL" -e 'print "start: \"\\\t\\\f\\\0\\\1\" ;";' >> input.y || exit 77 ./input.at:2452: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2558: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:2414: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2213: sed 's,.*/$,,' stderr 1>&2 56. input.at:2543: ok stderr: 57. input.at:2582: testing Unexpected end of file ... ./input.at:2586: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y 24. input.at:1074: ok ./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy --warnings=error 0+0 records in 0+0 records out 0 bytes copied, 2.388e-05 s, 0.0 kB/s ./input.at:2012: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret special-char-].y stdout: ./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./input.at:2514: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret two.y ./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none 58. input.at:2675: testing LAC: Errors for %define ... ./input.at:2591: set x `LC_ALL=C ls -l 'char.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='char.y'; } || exit 77 ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Syacc.c -Dparse.lac=none input.y ./input.at:2415: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2522: set x `LC_ALL=C ls -l 'three.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='three.y'; } || exit 77 ./input.at:2454: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Syacc.c -Dparse.lac=full input.y 59. input.at:2719: testing -Werror combinations ... 60. input.at:2764: testing %name-prefix and api.prefix are incompatible ... ./input.at:2779: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-deprecated input.y 0+0 records in 0+0 records out 0 bytes copied, 2.848e-05 s, 0.0 kB/s stdout: ./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y ./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall input.y stderr: 16. input.at:784: ./input.at:2594: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret char.y 0+0 records in 0+0 records out 0 bytes copied, 2.512e-05 s, 0.0 kB/s ok stdout: ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Syacc.c -Dparse.lac=unsupported input.y ./input.at:2528: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret three.y ./input.at:2416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2780: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dapi.prefix={foo} -p bar -Wno-deprecated input.y 43. input.at:1936: ok ./input.at:2604: set x `LC_ALL=C ls -l 'escape-in-char.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='escape-in-char.y'; } || exit 77 ./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./input.at:2456: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 55. input.at:2482: ok ./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y -Werror ./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy -Wnone,none -Werror --trace=none stderr: 0+0 records in 0+0 records out 0 bytes copied, 2.648e-05 s, 0.0 kB/s stdout: ./input.at:2781: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dapi.prefix={foo} -Wno-deprecated input.y ./input.at:2607: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret escape-in-char.y 61. input.at:2793: testing Redefined %union name ... ./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y stderr: input.y:2.15: error: stray '$' [-Werror=other] 62. input.at:2840: testing Stray $ or @ ... ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.cc -Dparse.lac=none input.y ./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall input.y ./input.at:2617: set x `LC_ALL=C ls -l 'string.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='string.y'; } || exit 77 ./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror ./input.at:2458: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror ./input.at:2782: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -p bar -Wno-deprecated input.y ./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.cc -Dparse.lac=full input.y ./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy --warnings=none -Werror --trace=none ./input.at:2727: sed 's,.*/$,,' stderr 1>&2 stderr: 63. input.at:2883: testing Code injection ... ./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S yacc.c -d input.y stderr: ./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y -Werror 0+0 records in 0+0 records out 0 bytes copied, 2.448e-05 s, 0.0 kB/s input.y:2.8-10: error: duplicate directive [-Werror=other] 2 | %start exp | ^~~ input.y:1.8-10: note: previous declaration 1 | %start exp foo | ^~~ input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] stdout: ./input.at:2620: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret string.y ./input.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y --warnings=error ./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr.c -d input.y ./input.at:2460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: input.y:3.8-10: error: %define variable 'api.value.union.name' redefined [-Werror=other] input.y:1.8-10: note: previous definition input.y:4.1-32: error: %define variable 'api.value.union.name' redefined [-Werror=other] input.y:3.8-10: note: previous definition input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ./input.at:2630: set x `LC_ALL=C ls -l 'escape-in-string.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='escape-in-string.y'; } || exit 77 60. input.at:2764: ok ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.cc -Dparse.lac=unsupported input.y ./input.at:1877: sed 's,.*/$,,' stderr 1>&2 stderr: stderr: input.y:11.19: error: stray '$' [-Werror=other] input.y:11.23: error: stray '@' [-Werror=other] input.y:12.19: error: stray '$' [-Werror=other] input.y:12.23: error: stray '@' [-Werror=other] input.y:13.19: error: stray '$' [-Werror=other] input.y:13.23: error: stray '@' [-Werror=other] input.y:16.19: error: stray '$' [-Werror=other] input.y:16.23: error: stray '@' [-Werror=other] input.y:17.19: error: stray '$' [-Werror=other] stderr: input.y:5.1-40: error: %define variable 'lr.type' requires keyword values [-Werror=deprecated] input.y:3.1-40: error: %define variable 'lr.default-reduction' requires keyword values [-Werror=deprecated] input.y:4.1-40: error: %define variable 'lr.keep-unreachable-state' requires keyword values [-Werror=deprecated] input.y:1.1-38: error: %define variable 'api.pure' requires keyword values [-Werror=deprecated] input.y:2.1-40: error: %define variable 'api.push-pull' requires keyword values [-Werror=deprecated] ./input.at:2808: sed 's,.*/$,,' stderr 1>&2 ./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.cc -d input.y 0+0 records in 0+0 records out 0 bytes copied, 2.452e-05 s, 0.0 kB/s stdout: ./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.yy ./input.at:2861: sed 's,.*/$,,' stderr 1>&2 ./input.at:2633: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret escape-in-string.y ./input.at:2247: sed 's,.*/$,,' stderr 1>&2 ./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error ./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y --warnings=error ./input.at:2643: set x `LC_ALL=C ls -l 'tstring.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='tstring.y'; } || exit 77 53. input.at:2393: ok ./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr.cc -d input.y ./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error ./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y -Wnone,none -Werror --trace=none ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.d -Dparse.lac=none input.y 64. input.at:2946: testing Deprecated directives ... stderr: 0+0 records in 0+0 records out 0 bytes copied, 2.688e-05 s, 0.0 kB/s stdout: ./input.at:3019: cp errors-all experr ./input.at:3020: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -ffixit input.y ./input.at:2462: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2646: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret tstring.y ./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none ./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y -Wnone,none -Werror --trace=none ./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr2.cc -d input.y ./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y --warnings=none -Werror --trace=none ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.d -Dparse.lac=full input.y ./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y --warnings=none -Werror --trace=none ./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./input.at:2656: set x `LC_ALL=C ls -l 'escape-in-tstring.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='escape-in-tstring.y'; } || exit 77 ./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy -Werror ./input.at:2465: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none 65. input.at:3077: testing Unput's effect on locations ... ./input.at:3092: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 62. input.at:2840: ok ./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -W input.y ./input.at:3022: sed -e '/^fix-it:/d' errors-all >experr 65. input.at:3077: ok ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.d -Dparse.lac=unsupported input.y ./input.at:2820: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: ./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.d input.y ./input.at:3023: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y 0+0 records in 0+0 records out 0 bytes copied, 2.488e-05 s, 0.0 kB/s stdout: ./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./input.at:2659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret escape-in-tstring.y ./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.java input.y ./input.at:2467: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 57. input.at:2582: ok 66. input.at:3113: testing Non-deprecated directives ... ./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y ./input.at:3027: rm -f output.c ./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S yacc.c -d input.y ./input.at:2469: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -W input.y -Werror ./input.at:3028: cp input.y input.y.orig stderr: ./input.at:3029: sed -e '/fix-it/d' experr input.yy:2.1-32: error: %define variable 'api.location.type' requires '{...}' values [-Werror=deprecated] input.yy:4.1-32: error: %define variable 'api.prefix' requires '{...}' values [-Werror=deprecated] input.yy:5.1-32: error: %define variable 'api.token.prefix' requires '{...}' values [-Werror=deprecated] input.yy:3.1-32: error: %define variable 'api.namespace' requires '{...}' values [-Werror=deprecated] ./input.at:3030: echo "bison: file 'input.y' was updated (backup: 'input.y~')" >>experr 40. input.at:1826: ./input.at:3031: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --update input.y ./input.at:2825: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ok ./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror 67. input.at:3148: testing Cannot type action ... ./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y stderr: ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.java -Dparse.lac=none input.y input.y:2.15: error: stray '$' [-Werror=other] ./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr.c -d input.y ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.java -Dparse.lac=full input.y ./input.at:2214: sed 's,.*/$,,' stderr 1>&2 ./input.at:3034: diff input.y.orig input.y~ ./input.at:3037: test ! -f output.c 68. input.at:3171: testing Character literals and api.token.raw ... ./input.at:3181: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:2730: sed 's,.*/$,,' stderr 1>&2 54. input.at:2429: ./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy --warnings=error ok ./input.at:3040: sed -e '1,8d' input.y ./input.at:3062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.java -Dparse.lac=unsupported input.y ./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.cc -d input.y ./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -W input.y --warnings=error 69. input.at:3205: testing %token-table and parse.error ... stderr: input.y:14.1-15.5: error: duplicate directive: '%file-prefix' [-Werror=other] input.y:13.1-18: note: previous declaration input.y: error: %expect-rr applies only to GLR parsers [-Werror=other] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] 49. input.at:2224: ok ./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror ./input.at:3220: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 68. input.at:3171: ok 61. input.at:2793: ok ./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr.cc -d input.y 64. input.at:2946: ok ./input.at:3133: sed 's,.*/$,,' stderr 1>&2 70. input.at:3231: testing Invalid file prefix mapping arguments ... ./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -W input.y -Wnone,none -Werror --trace=none ./input.at:3246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -M foo input.y stderr: ./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr2.cc -d input.y ./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error ./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy -Wnone,none -Werror --trace=none input.y:10.6-13: error: only midrule actions can be typed: int [-Werror=other] 10 | exp: {} | ^~~~~~~~ ./input.at:2697: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dparse.lac.es-capacity-initial=1 -Dparse.lac.memory-trace=full input.y ./input.at:3247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --file-prefix-map foo input.y 74. named-refs.at:316: testing Many kinds of errors ... ./named-refs.at:384: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y ./input.at:3156: sed 's,.*/$,,' stderr 1>&2 72. named-refs.at:196: testing Undefined and ambiguous references ... ./named-refs.at:254: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o test.c test.y ./named-refs.at:426: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o test.c test.y ./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.d input.y 72. named-refs.at:196: ok ./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none 71. named-refs.at:22: testing Tutorial calculator ... ./named-refs.at:184: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y 74. named-refs.at:316: ok 73. named-refs.at:297: testing Misleading references ... ./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -W input.y --warnings=none -Werror --trace=none ./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./input.at:3221: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.java input.y ./input.at:3248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -M foo=bar -M baz input.y ./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./input.at:2704: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.cc -Dparse.lac=full -Dparse.lac.es-capacity-initial=1 -Dparse.lac.memory-trace=full input.y ./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy --warnings=none -Werror --trace=none ./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./named-refs.at:184: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 63. input.at:2883: ok 75. named-refs.at:551: testing Missing identifiers in brackets ... ./named-refs.at:559: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y ./input.at:3249: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -M foo= -M baz input.y 75. named-refs.at:551: ok 69. input.at:3205: ok 70. input.at:3231: ok ./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y -Werror ./input.at:2704: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.java -Dparse.lac=full -Dparse.lac.es-capacity-initial=1 -Dparse.lac.memory-trace=full input.y 76. named-refs.at:567: testing Redundant words in brackets ... ./named-refs.at:575: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y 66. input.at:3113: ok ./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-none input.y 78. named-refs.at:599: testing Stray symbols in brackets ... stderr: test.y:11.22-29: error: misleading reference: '$foo.bar' [-Werror=other] test.y:11.8-10: note: refers to: $foo at $1 test.y:11.12-18: note: possibly meant: $[foo.bar] at $2 ./named-refs.at:607: "$PERL" -pi -e 's/\\(\d{3})/chr(oct($1))/ge' test.y || exit 77 ./named-refs.at:608: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y ./named-refs.at:306: sed 's,.*/$,,' stderr 1>&2 76. named-refs.at:567: ok 77. named-refs.at:583: testing Comments in brackets ... ./named-refs.at:591: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y 78. named-refs.at:599: ok ./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y --warnings=error ./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none 77. named-refs.at:583: ok 79. named-refs.at:618: testing Redundant words in LHS brackets ... ./named-refs.at:625: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y 81. named-refs.at:648: testing Unresolved references ... ./named-refs.at:676: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y 58. input.at:2675: ok 48. input.at:2191: ok 80. named-refs.at:635: testing Factored LHS ... ./named-refs.at:642: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-none input.y -Werror 81. named-refs.at:648: ok ./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y -Wnone,none -Werror --trace=none 79. named-refs.at:618: ok stderr: 67. input.at:3148: ok input.y:2.15: error: stray '$' [-Werror=other] 82. named-refs.at:715: testing $ or @ followed by . or - ... 80. named-refs.at:635: ok ./named-refs.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y ./input.at:2733: sed 's,.*/$,,' stderr 1>&2 83. output.at:68: testing Output files: -dv ... ./output.at:68: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv foo.y 85. output.at:81: testing Output files: -dv -o foo.c ... ./output.at:81: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -o foo.c foo.y ./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y --warnings=none -Werror --trace=none 87. output.at:87: testing Output files: api.header.include={"./foo.h"} -dv -y ... 84. output.at:74: testing Output files: -dv >&- ... ./output.at:74: case "$PREBISON" in *valgrind*) exit 77;; esac stderr: 89. output.at:95: testing Output files: --fixed-output-files -dv -g --html ... ./output.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv >&- foo.y ./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret test.y stdout: 89. output.at:95: 88. output.at:92: testing Output files: -dv -o foo.tab.c ... ./output.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -o foo.tab.c foo.y ./named-refs.at:185: $PREPARSER ./test input.txt stderr: skipped (output.at:95) 86. output.at:84: testing Output files: -dv -y ... ./output.at:84: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -y foo.y ./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-none input.y --warnings=error ./named-refs.at:185: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./output.at:87: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -y foo.y stderr: stderr: ./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y -Werror ./output.at:81: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 90. output.at:97: testing Output files: -Hfoo.header -v -gfoo.gv --html=foo.html ... stderr: 71. named-refs.at:22: ok 90. output.at:97: skipped (output.at:97) ./output.at:68: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: stderr: ./output.at:84: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: ./output.at:74: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:81: grep '#include "foo.h"' foo.c stdout: 91. output.at:100: testing Output files: -dv -g --xml --fixed-output-files ... #include "foo.h" ./output.at:92: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: 73. named-refs.at:297: ok 85. output.at:81: ok ./output.at:100: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g --xml --fixed-output-files foo.y test.y:4.9: error: stray '$' [-Werror=other] test.y:5.9: error: stray '@' [-Werror=other] 83. output.at:68: ok ./output.at:84: grep '#include "y.tab.h"' y.tab.c ./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-none input.y -Wnone,none -Werror --trace=none stdout: 93. output.at:104: testing Output files: %require "3.4" -dv -g --xml -y ... stderr: 84. output.at:74: ok ./named-refs.at:740: sed 's,.*/$,,' stderr 1>&2 :6: warning: deprecated option: '--fixed-output-files', use '-o y.tab.c' [-Wdeprecated] ./output.at:100: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:104: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g --xml -y foo.y stderr: foo.y:1.1-7: warning: POSIX Yacc does not support %define [-Wyacc] ./output.at:87: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 86. output.at:84: ok 92. output.at:102: testing Output files: -dv -g --xml -y ... ./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-none input.y --warnings=none -Werror --trace=none 88. output.at:92: ok 94. output.at:107: testing Output files: -dv -g --xml -o y.tab.c ... ./output.at:107: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g --xml -o y.tab.c foo.y 91. output.at:100: ok ./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y --warnings=error ./output.at:102: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g --xml -y foo.y 95. output.at:110: testing Output files: -dv -b bar ... ./output.at:110: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -b bar foo.y stderr: ./output.at:87: grep '#include "./foo.h"' y.tab.c foo.y:1.1-8: warning: POSIX Yacc does not support %require [-Wyacc] foo.y:1.10-14: warning: POSIX Yacc does not support string literals [-Wyacc] ./output.at:104: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./input.at:2738: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror,none,other input.y stderr: ./output.at:107: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: stdout: #include "./foo.h" 96. output.at:112: testing Output files: -dv -g -o foo.c ... ./output.at:110: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 87. output.at:87: ok 94. output.at:107: ok 97. output.at:116: testing Output files: %header %verbose ... ./output.at:116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y stderr: ./output.at:102: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:112: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g -o foo.c foo.y 99. output.at:121: testing Output files: %header %verbose %yacc ... ./input.at:2741: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror,no-all,other input.y ./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y -Wnone,none -Werror --trace=none 98. output.at:118: testing Output files: %header %verbose %yacc ... ./output.at:121: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy 100. output.at:125: testing Output files: %file-prefix "bar" %header %verbose ... ./output.at:118: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y 93. output.at:104: ok 95. output.at:110: ok ./output.at:125: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y 92. output.at:102: ok ./input.at:2746: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror -Wno-error=other input.y stderr: stderr: 102. output.at:129: testing Output files: %file-prefix "baz" %output "bar.c" %header %verbose %yacc ... ./output.at:121: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y --warnings=none -Werror --trace=none stderr: ./output.at:129: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y ./output.at:112: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:116: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 101. output.at:127: testing Output files: %output "bar.c" %header %verbose %yacc ... stderr: stderr: 97. output.at:116: ok 103. output.at:136: testing Output files: %header %verbose ... 99. output.at:121: ok ./output.at:125: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:118: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 82. named-refs.at:715: ok ./output.at:127: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y 96. output.at:112: ok stderr: ./output.at:136: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy ./output.at:129: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./input.at:2750: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-error=other -Werror input.y 100. output.at:125: ok 104. output.at:139: testing Output files: %header %verbose -o foo.c ... 105. output.at:142: testing Output files: --header=foo.hpp -o foo.c++ ... stderr: ./output.at:136: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 102. output.at:129: ok 98. output.at:118: ok ./output.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c foo.yy ./output.at:142: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --header=foo.hpp -o foo.c++ foo.yy 106. output.at:146: testing Output files: --header=foo.hpp -o foo.c++ ... ./output.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --header=foo.hpp -o foo.c++ foo.yy ./input.at:2754: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror=other -Wno-other input.y stderr: 103. output.at:136: ok 107. output.at:150: testing Output files: %header "foo.hpp" -o foo.c++ ... ./output.at:150: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c++ foo.yy ./output.at:127: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: 108. output.at:154: testing Output files: -o foo.c++ --graph=foo.gph ... ./output.at:154: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c++ --graph=foo.gph foo.yy stderr: ./output.at:142: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:139: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 109. output.at:160: testing Output files: %type useless --header --graph --xml --report=all -Wall -Werror ... 101. output.at:127: ok ./output.at:160: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header --graph --xml --report=all -Wall -Werror foo.y stderr: 59. input.at:2719: ok ./output.at:154: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 110. output.at:167: testing Output files: useless=--header --graph --xml --report=all -Wall -Werror ... ./output.at:167: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header --graph --xml --report=all -Wall -Werror foo.y stderr: stderr: ./output.at:146: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 108. output.at:154: ok 111. output.at:173: testing Output files: %defines -o foo.c++ ... ./output.at:150: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 104. output.at:139: ok ./output.at:173: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c++ foo.yy 113. output.at:191: testing Output files: lalr1.cc ... 112. output.at:176: testing Output files: %defines "foo.hpp" -o foo.c++ ... 107. output.at:150: ok 106. output.at:146: ok ./output.at:191: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy ./output.at:176: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c++ foo.yy 105. output.at:142: ok stderr: foo.y:1.13-19: error: symbol 'useless' is used, but is not defined as a token and has no rules [-Werror=other] foo.y: error: 1 nonterminal useless in grammar [-Werror=other] foo.y:1.13-19: error: nonterminal useless in grammar: useless [-Werror=other] ./output.at:160: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: ./output.at:191: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 114. output.at:194: testing Output files: lalr1.cc %verbose ... ./output.at:194: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy stderr: ./output.at:176: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 109. output.at:160: ok stderr: stderr: 118. output.at:206: testing Output files: lalr1.cc %header %verbose ... 115. output.at:197: testing Output files: lalr1.cc %header %verbose ... ./output.at:197: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy foo.y:1.1-15: error: %define variable 'useless' is not used ./output.at:167: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 117. output.at:203: testing Output files: lalr1.cc %header %verbose %locations ... 116. output.at:200: testing Output files: lalr1.cc %verbose %locations ... ./output.at:203: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy ./output.at:173: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: ./output.at:194: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:200: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy 112. output.at:176: ok ./output.at:206: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret subdir/foo.yy 114. output.at:194: ok 110. output.at:167: ok 113. output.at:191: ok 119. output.at:210: testing Output files: lalr1.cc %header %verbose %locations -o subdir/foo.cc ... stderr: ./output.at:203: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: ./output.at:197: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 111. output.at:173: ok 121. output.at:220: testing Output files: lalr1.cc %header %locations %verbose %file-prefix "output_dir/foo" ... stderr: 117. output.at:203: ok 120. output.at:215: testing Output files: lalr1.cc %header %verbose %file-prefix "output_dir/foo" ... stderr: ./output.at:200: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:206: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(subdir/foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 115. output.at:197: ok 122. output.at:226: testing Output files: lalr1.cc %header %locations api.location.file=none %require "3.2" ... ./output.at:226: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy 124. output.at:237: testing Output files: lalr1.cc %header %locations api.location.file="$at_dir/foo.loc.hh" %require "3.2" ... ./output.at:237: "$PERL" -pi -e 's{\$at_dir}'"{$at_group_dir}g" foo.yy || exit 77 ./output.at:237: rm -f foo.yy.bak 123. output.at:231: testing Output files: lalr1.cc %header %locations api.location.file="foo.loc.hh" %require "3.2" ... ./output.at:231: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy 126. output.at:272: testing Conflicting output files: %header "foo.output" -v ... 116. output.at:200: ok ./output.at:237: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy ./output.at:206: grep 'include .subdir/' foo.tab.cc 125. output.at:267: testing Conflicting output files: --graph="foo.tab.c" ... ./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y ./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v foo.y stderr: ./output.at:206: grep 'include .subdir/' foo.tab.hh ./output.at:226: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: ./output.at:231: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 127. output.at:277: testing Conflicting output files: lalr1.cc %header %locations --graph="location.hh" ... ./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --graph="location.hh" foo.y 122. output.at:226: 118. output.at:206: ok ok ./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y -Werror ./output.at:210: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o subdir/foo.cc subdir/foo.yy 128. output.at:282: testing Conflicting output files: -o foo.y ... stderr: ./output.at:237: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:282: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o foo.y foo.y ./output.at:215: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret gram_dir/foo.yy stderr: 123. output.at:231: ok stderr: ./output.at:210: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(subdir/foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 foo.y: error: conflicting outputs to file 'foo.tab.c' [-Werror=other] ./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v foo.y -Werror 129. output.at:328: testing Output file name: `~!@#$%^&*()-=_+{}[]|\:;<>, .' ... ./output.at:328: touch "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.tmp" || exit 77 ./output.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.c" --header="\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.h" glr.y 124. output.at:237: ok ./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="location.hh" foo.y -Werror stderr: ./output.at:267: sed 's,.*/$,,' stderr 1>&2 ./output.at:215: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(gram_dir/foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:210: grep 'include .subdir/' subdir/foo.cc ./output.at:282: cat foo.y ./output.at:328: ls "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.c" "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.h" stderr: ./output.at:210: grep 'include .subdir/' subdir/foo.hh foo.y: error: conflicting outputs to file 'foo.output' [-Werror=other] ./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y --warnings=error stdout: 130. output.at:335: testing Output file name: ( ... ./output.at:335: touch "(.tmp" || exit 77 131. output.at:336: testing Output file name: ) ... ./output.at:336: touch ").tmp" || exit 77 `~!@#$%^&*()-=_+{}[]|\:;<>, .'.c `~!@#$%^&*()-=_+{}[]|\:;<>, .'.h ./output.at:328: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.c" 132. output.at:337: testing Output file name: # ... ./output.at:337: touch "#.tmp" || exit 77 119. output.at:210: ok stderr: foo.y: error: conflicting outputs to file 'location.hh' [-Werror=other] ./output.at:335: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "(.c" --header="(.h" glr.y 128. output.at:282: ok ./output.at:337: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "#.c" --header="#.h" glr.y ./output.at:220: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret gram_dir/foo.yy 120. output.at:215: ok ./output.at:272: sed 's,.*/$,,' stderr 1>&2 ./output.at:277: sed 's,.*/$,,' stderr 1>&2 ./output.at:336: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o ").c" --header=").h" glr.y 133. output.at:338: testing Output file name: @@ ... ./output.at:338: touch "@@.tmp" || exit 77 ./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v foo.y --warnings=error ./output.at:337: ls "#.c" "#.h" ./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y -Wnone,none -Werror --trace=none stdout: stderr: ./output.at:338: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@@.c" --header="@@.h" glr.y #.c #.h ./output.at:220: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(gram_dir/foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:337: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "#.c" ./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="location.hh" foo.y --warnings=error ./output.at:335: ls "(.c" "(.h" ./output.at:336: ls ").c" ").h" 121. output.at:220: stdout: ok stdout: (.c (.h ./output.at:335: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "(.c" ).c ).h ./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="location.hh" foo.y -Wnone,none -Werror --trace=none ./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v foo.y -Wnone,none -Werror --trace=none ./output.at:336: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c ").c" 134. output.at:339: testing Output file name: @{ ... ./output.at:339: touch "@{.tmp" || exit 77 135. output.at:340: testing Output file name: @} ... ./output.at:340: touch "@}.tmp" || exit 77 ./output.at:339: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@{.c" --header="@{.h" glr.y 136. output.at:341: testing Output file name: [ ... ./output.at:341: touch "[.tmp" || exit 77 ./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y --warnings=none -Werror --trace=none ./output.at:338: ls "@@.c" "@@.h" stdout: @@.c @@.h ./output.at:340: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@}.c" --header="@}.h" glr.y ./output.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "[.c" --header="[.h" glr.y ./output.at:338: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "@@.c" ./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v foo.y --warnings=none -Werror --trace=none ./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="location.hh" foo.y --warnings=none -Werror --trace=none ./output.at:339: ls "@{.c" "@{.h" 137. output.at:342: testing Output file name: ] ... ./output.at:342: touch "].tmp" || exit 77 stdout: @{.c @{.h ./output.at:339: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "@{.c" ./output.at:340: ls "@}.c" "@}.h" ./output.at:342: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "].c" --header="].h" glr.y ./output.at:267: cat foo.y ./output.at:341: ls "[.c" "[.h" stdout: @}.c @}.h stdout: 125. output.at:267: ok ./output.at:272: cat foo.y ./output.at:340: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "@}.c" [.c [.h ./output.at:277: cat foo.y ./output.at:341: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "[.c" 126. output.at:272: ok 127. output.at:277: ok ./output.at:342: ls "].c" "].h" stdout: ].c ].h ./output.at:342: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "].c" 138. output.at:363: testing Graph with no conflicts ... ./output.at:363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y 139. output.at:403: testing Graph with unsolved S/R ... ./output.at:403: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y 140. output.at:473: testing Graph with solved S/R ... ./output.at:473: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y stderr: ./output.at:363: grep -v // input.gv stderr: 138. output.at:363: ok input.y: warning: 3 shift/reduce conflicts [-Wconflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:10.10-18: warning: rule useless in parser due to conflicts [-Wother] input.y:11.10-18: warning: rule useless in parser due to conflicts [-Wother] input.y:12.10-18: warning: rule useless in parser due to conflicts [-Wother] ./output.at:403: grep -v // input.gv stderr: input.y:6.5-7: warning: rule useless in parser due to conflicts [-Wother] input.y:14.10-18: warning: rule useless in parser due to conflicts [-Wother] input.y:15.10-18: warning: rule useless in parser due to conflicts [-Wother] ./output.at:473: grep -v // input.gv 139. output.at:403: ok 140. output.at:473: ok stderr: stdout: stderr: stderr: stdout: stdout: ./output.at:335: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "(.cc" --header="(.hh" cxx.y ./output.at:336: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o ").cc" --header=").hh" cxx.y ./output.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.cc" --header="\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.hh" cxx.y 141. output.at:538: testing Graph with R/R ... ./output.at:538: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y ./output.at:328: ls "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.cc" "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.hh" 143. output.at:641: testing Graph with a reduction rule both enabled and disabled ... stdout: `~!@#$%^&*()-=_+{}[]|\:;<>, .'.cc `~!@#$%^&*()-=_+{}[]|\:;<>, .'.hh ./output.at:328: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.cc" 142. output.at:576: testing Graph with reductions with multiple LAT ... ./output.at:576: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y ./output.at:641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y ./output.at:335: ls "(.cc" "(.hh" ./output.at:336: ls ").cc" ").hh" stdout: stdout: stderr: ).cc ).hh stderr: (.cc (.hh stderr: ./output.at:336: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c ").cc" stdout: input.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:4.3: warning: rule useless in parser due to conflicts [-Wother] stdout: ./output.at:335: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "(.cc" ./output.at:538: grep -v // input.gv stderr: ./output.at:338: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@@.cc" --header="@@.hh" cxx.y ./output.at:337: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "#.cc" --header="#.hh" cxx.y input.y: warning: 3 reduce/reduce conflicts [-Wconflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:2.14-18: warning: rule useless in parser due to conflicts [-Wother] input.y:5.3: warning: rule useless in parser due to conflicts [-Wother] ./output.at:576: grep -v // input.gv 141. output.at:538: ok 142. output.at:576: ok ./output.at:338: ls "@@.cc" "@@.hh" ./output.at:337: ls "#.cc" "#.hh" stdout: stdout: stderr: @@.cc @@.hh #.cc #.hh stdout: ./output.at:337: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "#.cc" ./output.at:338: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "@@.cc" ./output.at:339: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@{.cc" --header="@{.hh" cxx.y 144. output.at:744: testing C++ Output File Prefix Mapping ... stderr: stderr: stderr: stdout: ./output.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o out/x1.cc -M out/=bar/ x1.yy input.y: warning: 4 shift/reduce conflicts [-Wconflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stdout: ./output.at:641: grep -v // input.gv ./output.at:339: ls "@{.cc" "@{.hh" ./output.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "[.cc" --header="[.hh" cxx.y ./output.at:340: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@}.cc" --header="@}.hh" cxx.y 145. diagnostics.at:84: testing Warnings ... stdout: 143. output.at:641: ok @{.cc @{.hh ./diagnostics.at:84: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./output.at:339: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "@{.cc" ./output.at:775: $CXX $CPPFLAGS $CXXFLAGS -Iout/include -c -o out/x1.o out/x1.cc ./output.at:341: ls "[.cc" "[.hh" ./output.at:340: ls "@}.cc" "@}.hh" stdout: 146. diagnostics.at:133: testing Single point locations ... stdout: [.cc [.hh @}.cc @}.hh ./output.at:341: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "[.cc" ./output.at:340: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "@}.cc" ./diagnostics.at:84: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:84: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y ./diagnostics.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y stderr: stdout: 145. diagnostics.at:84: ok ./output.at:342: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "].cc" --header="].hh" cxx.y ./diagnostics.at:133: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./output.at:342: ls "].cc" "].hh" stdout: ].cc ].hh ./diagnostics.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y ./output.at:342: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "].cc" 147. diagnostics.at:182: testing Line is too short, and then you die ... 146. diagnostics.at:133: ok ./diagnostics.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:182: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 148. diagnostics.at:217: testing Zero-width characters ... ./diagnostics.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y 147. diagnostics.at:182: ok ./diagnostics.at:217: "$PERL" -pi -e 's{\^M}{\r}g;s{\\(\d{3}|.)}{$v = $1; $v =~ /\A\d+\z/ ? chr($v) : $v}ge' input.y experr || exit 77 ./diagnostics.at:217: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:217: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:217: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y 148. diagnostics.at:217: ok 149. diagnostics.at:235: testing Tabulations and multibyte characters ... stderr: stdout: 129. output.at:328: ok stderr: stdout: 131. output.at:336: ok ./diagnostics.at:235: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y 151. diagnostics.at:303: testing Special files ... 150. diagnostics.at:282: testing Tabulations and multibyte characters ... ./diagnostics.at:303: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:235: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:235: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y ./diagnostics.at:303: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:303: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y ./diagnostics.at:282: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y 152. diagnostics.at:328: testing Complaints from M4 ... ./diagnostics.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y 151. diagnostics.at:303: ok 149. diagnostics.at:235: ok ./diagnostics.at:282: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:282: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y ./diagnostics.at:328: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y 153. diagnostics.at:351: testing Carriage return ... 154. diagnostics.at:372: testing CR NL ... stderr: stdout: 150. diagnostics.at:282: ok 133. output.at:338: ok ./diagnostics.at:351: "$PERL" -pi -e 's{\^M}{\r}g;s{\\(\d{3}|.)}{$v = $1; $v =~ /\A\d+\z/ ? chr($v) : $v}ge' input.y experr || exit 77 ./diagnostics.at:351: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:372: "$PERL" -pi -e 's{\^M}{\r}g;s{\\(\d{3}|.)}{$v = $1; $v =~ /\A\d+\z/ ? chr($v) : $v}ge' input.y experr || exit 77 ./diagnostics.at:351: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 155. diagnostics.at:399: testing Screen width: 200 columns ... ./diagnostics.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y 152. diagnostics.at:328: ok ./diagnostics.at:351: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y 156. diagnostics.at:432: testing Screen width: 80 columns ... stderr: stdout: 153. diagnostics.at:351: 130. output.at:335: ok ok ./diagnostics.at:399: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=200 bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:372: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 stderr: ./diagnostics.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y stdout: ./diagnostics.at:432: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=80 bison -fcaret --color=debug -Wall,cex input.y 137. output.at:342: ok 159. diagnostics.at:527: testing Counterexamples ... 157. diagnostics.at:465: testing Screen width: 60 columns ... 158. diagnostics.at:504: testing Suggestions ... ./diagnostics.at:399: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 154. diagnostics.at:372: ok ./diagnostics.at:399: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=200 bison -fcaret -Wall,cex input.y ./diagnostics.at:465: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=60 bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:527: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:432: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 160. diagnostics.at:645: testing Deep Counterexamples ... ./diagnostics.at:504: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:432: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=80 bison -fcaret -Wall,cex input.y ./diagnostics.at:504: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 155. diagnostics.at:399: ok ./diagnostics.at:465: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:504: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y ./diagnostics.at:527: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 stderr: stdout: ./diagnostics.at:645: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y 161. diagnostics.at:713: testing Indentation with message suppression ... ./diagnostics.at:465: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=60 bison -fcaret -Wall,cex input.y ./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wno-other input.y 132. output.at:337: ok 156. diagnostics.at:432: ok ./diagnostics.at:527: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y 158. diagnostics.at:504: ok ./diagnostics.at:645: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 stderr: stdout: ./output.at:782: sed -ne 's/#line [0-9][0-9]* "/#line "/p;/INCLUDED/p;/\\file/{p;n;p;}' out/include/ast/loc.hh ./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wno-other input.y -Werror 157. diagnostics.at:465: ok ./diagnostics.at:645: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y ./output.at:794: sed -ne 's/^#line [0-9][0-9]* "/#line "/p;/INCLUDED/p;/\\file/{p;n;p;}' out/x1.hh ./output.at:806: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o out/x2.cc -M out/=bar/ x2.yy 162. skeletons.at:25: testing Relative skeleton file names ... ./skeletons.at:27: mkdir tmp 165. skeletons.at:166: testing Complaining during macro argument expansion ... ./skeletons.at:189: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input1.y stderr: 160. diagnostics.at:645: 159. diagnostics.at:527: ok ok input.y:2.1-12: error: deprecated directive: '%pure-parser', use '%define api.pure' [-Werror=deprecated] 2 | %pure-parser | ^~~~~~~~~~~~ | %define api.pure input.y:3.1-14: error: deprecated directive: '%error-verbose', use '%define parse.error verbose' [-Werror=deprecated] 3 | %error-verbose | ^~~~~~~~~~~~~~ | %define parse.error verbose ./output.at:806: $CXX $CPPFLAGS $CXXFLAGS -Iout/include -c -o out/x2.o out/x2.cc 164. skeletons.at:142: testing Boolean=variables: invalid skeleton defaults ... 163. skeletons.at:85: testing Installed skeleton file names ... ./skeletons.at:155: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./diagnostics.at:725: sed 's,.*/$,,' stderr 1>&2 166. skeletons.at:248: testing Fatal errors make M4 exit immediately ... ./skeletons.at:262: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input1.y ./skeletons.at:120: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --skeleton=yacc.c -o input-cmd-line.c input-cmd-line.y ./skeletons.at:63: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret tmp/input-gram.y ./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wno-other input.y --warnings=error ./skeletons.at:121: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input-cmd-line input-cmd-line.c $LIBS ./skeletons.at:64: cat input-gram.tab.c 167. skeletons.at:302: testing Fatal errors but M4 continues producing output ... ./skeletons.at:314: "$PERL" gen-skel.pl > skel.c || exit 77 168. sets.at:27: testing Nullable ... ./sets.at:42: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=sets input.y stderr: bison (GNU Bison) 3.8.2 RITEM 0: e $end (rule 0) 3: 'e' (rule 1) 5: (rule 2) DERIVES $accept derives 0 e $end e derives 1 'e' 2 %empty NULLABLE $accept: no e: yes RTC: Firsts Input BEGIN 01 .--. 0| 1| 1| | `--' RTC: Firsts Input END RTC: Firsts Output BEGIN 01 .--. 0|11| 1| 1| `--' RTC: Firsts Output END FIRSTS $accept firsts $accept e e firsts e FDERIVES $accept derives 0 e $end 1 'e' 2 %empty e derives 1 'e' 2 %empty relation_transpose: relation_transpose: output: follows after includes: FOLLOWS[goto[0] = (0, e, 2)] = $end Lookaheads: State 0: rule 2: $end State 1: rule 1: State 3: rule 0: ./skeletons.at:68: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input-gram.y ./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wno-other input.y -Wnone,none -Werror --trace=none ./sets.at:43: sed -f extract.sed stderr 164. skeletons.at:142: ok ./skeletons.at:322: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./skeletons.at:279: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input2.y ./skeletons.at:209: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input2.y 168. sets.at:27: ok ./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wno-other input.y --warnings=none -Werror --trace=none stderr: ./skeletons.at:69: cat input-gram.tab.c stdout: stderr: 134. output.at:339: ok stdout: ./skeletons.at:73: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --skeleton=tmp/skel.c tmp/input-cmd-line.y ./skeletons.at:223: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input3.y 135. output.at:340: ok 167. skeletons.at:302: ok 161. diagnostics.at:713: ok 169. sets.at:111: testing Broken Closure ... ./skeletons.at:74: cat input-cmd-line.tab.c stderr: 171. sets.at:228: testing Accept ... ./sets.at:240: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y ./sets.at:125: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=sets input.y 162. skeletons.at:25: ok 166. skeletons.at:248: ok stdout: 170. sets.at:153: testing Firsts ... ./sets.at:171: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=sets input.y ./skeletons.at:237: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input4.y 136. output.at:341: ok 172. sets.at:269: testing Build relations ... ./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./sets.at:243: sed -n 's/.*define YYFINAL *\([0-9][0-9]*\)/final state \1/p' input.c 173. sets.at:315: testing Reduced Grammar ... ./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=grammar -o input.c input.y stdout: ./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror stderr: 175. reduce.at:26: testing Useless Terminals ... stdout: final state 6 stderr: ./reduce.at:47: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y ./skeletons.at:122: $PREPARSER ./input-cmd-line stderr: bison (GNU Bison) 3.8.2 RITEM 0: exp $end (rule 0) 3: exp '<' exp (rule 1) 7: exp '>' exp (rule 2) 11: exp '+' exp (rule 3) 15: exp '-' exp (rule 4) 19: exp '^' exp (rule 5) 23: exp '=' exp (rule 6) 27: "exp" (rule 7) DERIVES $accept derives 0 exp $end exp derives 1 exp '<' exp 2 exp '>' exp 3 exp '+' exp 4 exp '-' exp 5 exp '^' exp 6 exp '=' exp 7 "exp" NULLABLE $accept: no exp: no RTC: Firsts Input BEGIN 01 .--. 0| 1| 1| 1| `--' RTC: Firsts Input END RTC: Firsts Output BEGIN 01 .--. 0|11| 1| 1| `--' RTC: Firsts Output END FIRSTS $accept firsts $accept exp exp firsts exp FDERIVES $accept derives 0 exp $end 1 exp '<' exp 2 exp '>' exp 3 exp '+' exp 4 exp '-' exp 5 exp '^' exp 6 exp '=' exp 7 "exp" exp derives 1 exp '<' exp 2 exp '>' exp 3 exp '+' exp 4 exp '-' exp 5 exp '^' exp 6 exp '=' exp 7 "exp" relation_transpose: 0: 1 2 3 4 5 6 1: 1 2 3 4 5 6 2: 1 2 3 4 5 6 3: 1 2 3 4 5 6 4: 1 2 3 4 5 6 5: 1 2 3 4 5 6 6: 1 2 3 4 5 6 relation_transpose: output: 1: 0 1 2 3 4 5 6 2: 0 1 2 3 4 5 6 3: 0 1 2 3 4 5 6 4: 0 1 2 3 4 5 6 5: 0 1 2 3 4 5 6 6: 0 1 2 3 4 5 6 follows after includes: FOLLOWS[goto[0] = (0, exp, 2)] = $end '<' '>' '+' '-' '^' '=' FOLLOWS[goto[1] = (4, exp, 10)] = $end '<' '>' '+' '-' '^' '=' FOLLOWS[goto[2] = (5, exp, 11)] = $end '<' '>' '+' '-' '^' '=' FOLLOWS[goto[3] = (6, exp, 12)] = $end '<' '>' '+' '-' '^' '=' FOLLOWS[goto[4] = (7, exp, 13)] = $end '<' '>' '+' '-' '^' '=' FOLLOWS[goto[5] = (8, exp, 14)] = $end '<' '>' '+' '-' '^' '=' FOLLOWS[goto[6] = (9, exp, 15)] = $end '<' '>' '+' '-' '^' '=' Lookaheads: State 1: rule 7: State 3: rule 0: State 10: rule 1: $end '<' '>' '+' '-' '^' '=' State 11: rule 2: $end '<' '>' '+' '-' '^' '=' State 12: rule 3: $end '<' '>' '+' '-' '^' '=' State 13: rule 4: $end '<' '>' '+' '-' '^' '=' State 14: rule 5: $end '<' '>' '+' '-' '^' '=' State 15: rule 6: $end '<' '>' '+' '-' '^' '=' stderr: ./sets.at:248: sed -n ' /^State \(.*\)/{ s//final state \1/ x } / accept/{ x p q } ' input.output 174. sets.at:394: testing Reduced Grammar with prec and assoc ... syntax error, unexpected 'a', expecting end of file bison (GNU Bison) 3.8.2 RITEM 0: a $end (rule 0) 3: b (rule 1) 5: c (rule 2) 7: d (rule 3) 9: e (rule 4) 11: f (rule 5) 13: g (rule 6) 15: h (rule 7) 17: 'h' (rule 8) DERIVES $accept derives 0 a $end a derives 1 b b derives 2 c c derives 3 d d derives 4 e e derives 5 f f derives 6 g g derives 7 h h derives 8 'h' NULLABLE $accept: no a: no b: no c: no d: no e: no f: no g: no h: no RTC: Firsts Input BEGIN 012345678 .---------. 0| 1 | 1| 1 | 2| 1 | 3| 1 | 4| 1 | 5| 1 | 6| 1 | 7| 1| 8| | `---------' RTC: Firsts Input END RTC: Firsts Output BEGIN 012345678 .---------. 0|111111111| 1| 11111111| 2| 1111111| 3| 111111| 4| 11111| 5| 1111| 6| 111| 7| 11| 8| 1| `---------' RTC: Firsts Output END FIRSTS $accept firsts $accept a b c d e f g h a firsts a b c d e f g h b firsts b c d e f g h c firsts c d e f g h d firsts d e f g h e firsts e f g h f firsts f g h g firsts g h h firsts h FDERIVES $accept derives 0 a $end 1 b 2 c 3 d 4 e 5 f 6 g 7 h 8 'h' a derives 1 b 2 c 3 d 4 e 5 f 6 g 7 h 8 'h' b derives 2 c 3 d 4 e 5 f 6 g 7 h 8 'h' c derives 3 d 4 e 5 f 6 g 7 h 8 'h' d derives 4 e 5 f 6 g 7 h 8 'h' e derives 5 f 6 g 7 h 8 'h' f derives 6 g 7 h 8 'h' g derives 7 h 8 'h' h derives 8 'h' relation_transpose: 0: 1 1: 2 2: 3 3: 4 4: 5 5: 6 6: 7 relation_transpose: output: 1: 0 2: 1 3: 2 4: 3 5: 4 6: 5 7: 6 follows after includes: FOLLOWS[goto[0] = (0, a, 2)] = $end FOLLOWS[goto[1] = (0, b, 3)] = $end FOLLOWS[goto[2] = (0, c, 4)] = $end FOLLOWS[goto[3] = (0, d, 5)] = $end FOLLOWS[goto[4] = (0, e, 6)] = $end FOLLOWS[goto[5] = (0, f, 7)] = $end FOLLOWS[goto[6] = (0, g, 8)] = $end FOLLOWS[goto[7] = (0, h, 9)] = $end Lookaheads: State 1: rule 8: State 3: rule 1: State 4: rule 2: State 5: rule 3: State 6: rule 4: State 7: rule 5: State 8: rule 6: State 9: rule 7: State 10: rule 0: ./sets.at:127: sed -n 's/[ ]*$//;/^RTC: Firsts Output BEGIN/,/^RTC: Firsts Output END/p' stderr ./skeletons.at:122: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./sets.at:412: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=grammar -o input.c input.y stderr: input.y: error: 5 reduce/reduce conflicts [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:2.14-17: error: rule useless in parser due to conflicts [-Werror=other] 2 | expr: term | term | term | term | term | term | ^~~~ input.y:2.21-24: error: rule useless in parser due to conflicts [-Werror=other] 2 | expr: term | term | term | term | term | term | ^~~~ input.y:2.28-31: error: rule useless in parser due to conflicts [-Werror=other] 2 | expr: term | term | term | term | term | term | ^~~~ input.y:2.35-38: error: rule useless in parser due to conflicts [-Werror=other] 2 | expr: term | term | term | term | term | term | ^~~~ input.y:2.42-45: error: rule useless in parser due to conflicts [-Werror=other] 2 | expr: term | term | term | term | term | term | ^~~~ ./sets.at:172: sed -f extract.sed stderr 165. skeletons.at:166: ok ./sets.at:286: sed 's,.*/$,,' stderr 1>&2 176. reduce.at:70: testing Useless Nonterminals ... 170. sets.at:153: ok ./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y 171. sets.at:228: ok 177. reduce.at:120: testing Useless Rules ... ./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./skeletons.at:126: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input-gram.c input-gram.y ./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=grammar -o input.c input.y -Werror 169. sets.at:111: ok ./reduce.at:49: sed -n '/^Grammar/q;/^$/!p' input.output 175. reduce.at:26: ok ./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror 179. reduce.at:312: testing Reduced Automaton ... 174. sets.at:394: ok 180. reduce.at:406: testing Underivable Rules ... ./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror ./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret not-reduced.y 178. reduce.at:224: testing Useless Parts ... ./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y ./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./skeletons.at:127: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input-gram input-gram.c $LIBS stderr: stderr: bison (GNU Bison) 3.8.2 input.y: error: 1 nonterminal useless in grammar [-Werror=other] input.y: error: 1 rule useless in grammar [-Werror=other] input.y:4.1-7: error: nonterminal useless in grammar: useless [-Werror=other] Reduced Grammar ntokens = 7, nnterms = 4, nsyms = 11, nrules = 6, nritems = 17 Tokens ------ Value Sprec Sassoc Tag 0 0 0 $end 1 0 0 error 2 0 0 $undefined 3 0 0 "+" 4 0 0 "*" 5 0 0 "useless" 6 0 0 "num" Nonterminals ------------ Value Tag 7 $accept 8 expr 9 term 10 fact Rules ----- Num (Prec, Assoc, Useful, UselessChain) Lhs -> (Ritem Range) Rhs 0 ( 0, 0, t, f) 7 -> ( 0- 1) 8 0 1 ( 0, 0, t, f) 8 -> ( 3- 5) 8 3 9 2 ( 0, 0, t, t) 8 -> ( 7- 7) 9 3 ( 0, 0, t, f) 9 -> ( 9-11) 9 4 10 4 ( 0, 0, t, t) 9 -> (13-13) 10 5 ( 0, 0, t, t) 10 -> (17-17) 6 6 ( 0, 0, f, t) 11 -> (15-15) 5 Rules interpreted ----------------- 0 $accept: expr $end 1 expr: expr "+" term 2 expr: term 3 term: term "*" fact 4 term: fact 5 fact: "num" 6 useless: "useless" reduced input.y defines 7 terminals, 4 nonterminals, and 6 productions. input.y: error: 3 nonterminals useless in grammar [-Werror=other] input.y: error: 3 rules useless in grammar [-Werror=other] input.y:11.1-8: error: nonterminal useless in grammar: useless1 [-Werror=other] input.y:12.1-8: error: nonterminal useless in grammar: useless2 [-Werror=other] input.y:13.1-8: error: nonterminal useless in grammar: useless3 [-Werror=other] 181. reduce.at:452: testing Bad start symbols ... ./reduce.at:467: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./sets.at:325: sed 's,.*/$,,' stderr 1>&2 ./reduce.at:89: sed 's,.*/$,,' stderr 1>&2 182. reduce.at:550: testing no lr.type: Single State Split ... ./reduce.at:550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret not-reduced.y -Werror ./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror ./reduce.at:550: sed -n '/^State 0$/,$p' input.output ./reduce.at:473: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y -Werror stderr: 172. sets.at:269: ./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=grammar -o input.c input.y --warnings=error ok input.y: error: 9 nonterminals useless in grammar [-Werror=other] input.y: error: 9 rules useless in grammar [-Werror=other] input.y:10.1-8: error: nonterminal useless in grammar: useless1 [-Werror=other] 10 | useless1: '1'; | ^~~~~~~~ input.y:11.1-8: error: nonterminal useless in grammar: useless2 [-Werror=other] 11 | useless2: '2'; | ^~~~~~~~ input.y:12.1-8: error: nonterminal useless in grammar: useless3 [-Werror=other] 12 | useless3: '3'; | ^~~~~~~~ input.y:13.1-8: error: nonterminal useless in grammar: useless4 [-Werror=other] 13 | useless4: '4'; | ^~~~~~~~ input.y:14.1-8: error: nonterminal useless in grammar: useless5 [-Werror=other] 14 | useless5: '5'; | ^~~~~~~~ input.y:15.1-8: error: nonterminal useless in grammar: useless6 [-Werror=other] 15 | useless6: '6'; | ^~~~~~~~ input.y:16.1-8: error: nonterminal useless in grammar: useless7 [-Werror=other] 16 | useless7: '7'; | ^~~~~~~~ input.y:17.1-8: error: nonterminal useless in grammar: useless8 [-Werror=other] 17 | useless8: '8'; | ^~~~~~~~ input.y:18.1-8: error: nonterminal useless in grammar: useless9 [-Werror=other] 18 | useless9: '9'; | ^~~~~~~~ ./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error stderr: ./reduce.at:550: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS not-reduced.y: error: 2 nonterminals useless in grammar [-Werror=other] not-reduced.y: error: 3 rules useless in grammar [-Werror=other] not-reduced.y:14.1-13: error: nonterminal useless in grammar: not_reachable [-Werror=other] 14 | not_reachable: useful { /* A not reachable action. */ } | ^~~~~~~~~~~~~ not-reduced.y:17.1-14: error: nonterminal useless in grammar: non_productive [-Werror=other] 17 | non_productive: non_productive useless_token | ^~~~~~~~~~~~~~ not-reduced.y:11.6-57: error: rule useless in grammar [-Werror=other] 11 | | non_productive { /* A non productive action. */ } | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ./reduce.at:480: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: ./reduce.at:146: sed 's,.*/$,,' stderr 1>&2 183. reduce.at:550: testing lr.type=lalr: Single State Split ... input.y: error: 2 nonterminals useless in grammar [-Werror=other] input.y: error: 3 rules useless in grammar [-Werror=other] input.y:6.1-11: error: nonterminal useless in grammar: underivable [-Werror=other] 6 | underivable: indirection; | ^~~~~~~~~~~ input.y:7.1-11: error: nonterminal useless in grammar: indirection [-Werror=other] 7 | indirection: underivable; | ^~~~~~~~~~~ input.y:5.15-25: error: rule useless in grammar [-Werror=other] 5 | exp: useful | underivable; | ^~~~~~~~~~~ stderr: ./reduce.at:550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y input.y: error: 1 nonterminal useless in grammar [-Werror=other] input.y: error: 1 rule useless in grammar [-Werror=other] input.y:18.1-6: error: nonterminal useless in grammar: unused [-Werror=other] 18 | unused | ^~~~~~ ./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=grammar -o input.c input.y -Wnone,none -Werror --trace=none ./reduce.at:341: sed 's,.*/$,,' stderr 1>&2 ./reduce.at:420: sed 's,.*/$,,' stderr 1>&2 ./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none ./reduce.at:488: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./reduce.at:261: sed 's,.*/$,,' stderr 1>&2 ./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret not-reduced.y --warnings=error ./reduce.at:550: sed -n '/^State 0$/,$p' input.output ./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./reduce.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y --warnings=error 184. reduce.at:550: testing lr.type=ielr: Single State Split ... ./reduce.at:550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:550: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=grammar -o input.c input.y --warnings=none -Werror --trace=none ./reduce.at:505: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret not-reduced.y -Wnone,none -Werror --trace=none stderr: ./reduce.at:550: sed -n '/^State 0$/,$p' input.output stdout: 181. reduce.at:452: ok ./skeletons.at:128: $PREPARSER ./input-gram ./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y -Wnone,none -Werror --trace=none ./reduce.at:97: sed -n '/^Grammar/q;/^$/!p' input.output ./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none stderr: ./reduce.at:550: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS syntax error, unexpected 'a', expecting end of file ./skeletons.at:128: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none stdout: ./reduce.at:109: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c 173. sets.at:315: ok ./reduce.at:550: $PREPARSER ./input ./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret not-reduced.y --warnings=none -Werror --trace=none ./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y --warnings=none -Werror --trace=none stderr: 163. skeletons.at:85: ok syntax error ./reduce.at:550: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./reduce.at:550: $PREPARSER ./input stderr: ./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none syntax error ./reduce.at:179: sed -n '/^Grammar/q;/^$/!p' input.output 182. reduce.at:550: ok ./reduce.at:550: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./reduce.at:355: sed -n '/^Grammar/q;/^$/!p' not-reduced.output 185. reduce.at:550: testing lr.type=canonical-lr: Single State Split ... ./reduce.at:270: sed -n '/^State 0/q;/^$/!p' input.output ./reduce.at:550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:213: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c 186. reduce.at:783: testing no lr.type: Lane Split ... ./reduce.at:783: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:392: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret reduced.y 183. reduce.at:550: ok ./reduce.at:298: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./reduce.at:434: sed -n '/^Grammar/q;/^$/!p' input.output stderr: ./reduce.at:550: sed -n '/^State 0$/,$p' input.output 187. reduce.at:783: testing lr.type=lalr: Lane Split ... ./reduce.at:783: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:396: sed 's/not-reduced/reduced/g' not-reduced.c stdout: 179. reduce.at:312: ok 176. reduce.at:70: ok 180. reduce.at:406: ok ./reduce.at:783: sed -n '/^State 0$/,$p' input.output ./reduce.at:783: sed -n '/^State 0$/,$p' input.output 188. reduce.at:783: testing lr.type=ielr: Lane Split ... ./reduce.at:783: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./reduce.at:783: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:550: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: ./reduce.at:783: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:550: $PREPARSER ./input 189. reduce.at:783: testing lr.type=canonical-lr: Lane Split ... ./reduce.at:783: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stderr: ./reduce.at:550: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 190. reduce.at:1027: testing no lr.type: Complex Lane Split ... stderr: stderr: ./reduce.at:783: sed -n '/^State 0$/,$p' input.output 184. reduce.at:550: ok stdout: ./reduce.at:1027: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stdout: 192. reduce.at:1027: testing lr.type=ielr: Complex Lane Split ... 191. reduce.at:1027: testing lr.type=lalr: Complex Lane Split ... 177. reduce.at:120: ok ./reduce.at:1027: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y 178. reduce.at:224: ok ./reduce.at:1027: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:783: sed -n '/^State 0$/,$p' input.output ./reduce.at:783: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:783: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:1027: sed -n '/^State 0$/,$p' input.output ./reduce.at:1027: sed -n '/^State 0$/,$p' input.output ./reduce.at:1027: sed -n '/^State 0$/,$p' input.output stderr: stdout: ./reduce.at:1027: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./reduce.at:1027: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: 194. reduce.at:1296: testing no lr.type: Split During Added Lookahead Propagation ... ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y 193. reduce.at:1027: testing lr.type=canonical-lr: Complex Lane Split ... ./output.at:835: $CXX $CPPFLAGS $CXXFLAGS -Iout/ $LDFLAGS -o parser out/x[12].o main.cc $LIBS ./reduce.at:1027: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 195. reduce.at:1296: testing lr.type=lalr: Split During Added Lookahead Propagation ... ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:783: $PREPARSER ./input ./reduce.at:1027: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stderr: syntax error ./reduce.at:783: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./reduce.at:550: $PREPARSER ./input stderr: ./reduce.at:550: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./reduce.at:1027: sed -n '/^State 0$/,$p' input.output ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror 186. reduce.at:783: ok stderr: ./reduce.at:1027: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: ./reduce.at:783: $PREPARSER ./input 185. reduce.at:550: ok stderr: ./reduce.at:783: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: 188. reduce.at:783: ok ./reduce.at:783: $PREPARSER ./input stderr: stdout: ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror stderr: ./reduce.at:783: $PREPARSER ./input syntax error stderr: ./reduce.at:783: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./reduce.at:783: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 189. reduce.at:783: ok 196. reduce.at:1296: testing lr.type=ielr: Split During Added Lookahead Propagation ... ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y 187. reduce.at:783: ok 197. reduce.at:1296: testing lr.type=canonical-lr: Split During Added Lookahead Propagation ... stderr: input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stderr: ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./reduce.at:1296: sed -n '/^State 0$/,$p' input.output ./reduce.at:1296: sed 's,.*/$,,' stderr 1>&2 198. reduce.at:1627: testing no lr.default-reduction ... ./reduce.at:1627: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:1296: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:1296: sed 's,.*/$,,' stderr 1>&2 ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error 199. reduce.at:1627: testing lr.default-reduction=most ... ./reduce.at:1296: sed -n '/^State 0$/,$p' input.output ./reduce.at:1627: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stderr: stdout: 200. reduce.at:1627: testing lr.default-reduction=consistent ... stderr: ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error stderr: ./reduce.at:1296: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:1027: $PREPARSER ./input stderr: stderr: ./reduce.at:1627: sed -n '/^State 0$/,$p' input.output stdout: stdout: ./reduce.at:1627: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:1027: $PREPARSER ./input stdout: ./reduce.at:1027: $PREPARSER ./input stderr: syntax error syntax error ./reduce.at:1027: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./reduce.at:1027: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./reduce.at:1027: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./reduce.at:1627: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:1027: $PREPARSER ./input ./reduce.at:1627: sed -n '/^State 0$/,$p' input.output 193. reduce.at:1027: ok stderr: ./reduce.at:1027: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./reduce.at:1627: sed -n '/^State 0$/,$p' input.output ./reduce.at:1627: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 191. reduce.at:1027: ok 192. reduce.at:1027: ok 190. reduce.at:1027: ok ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./reduce.at:1627: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./reduce.at:1296: $PREPARSER ./input stderr: ./reduce.at:1296: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./reduce.at:1296: sed -n '/^State 0$/,$p' input.output ./reduce.at:1296: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 202. report.at:37: testing Reports ... 201. reduce.at:1627: testing lr.default-reduction=accepting ... ./reduce.at:1627: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y 196. reduce.at:1296: ok 203. report.at:3123: testing Reports with conflicts ... ./reduce.at:1296: sed -n '/^State 0$/,$p' input.output stderr: 202. report.at:37: ./reduce.at:1627: sed -n '/^State 0$/,$p' input.output stdout: skipped (report.at:75) ./reduce.at:1296: $PREPARSER ./input stderr: ./reduce.at:1627: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:1296: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 197. reduce.at:1296: 204. conflicts.at:28: testing Token declaration order ... ./conflicts.at:81: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ok stdout: ./reduce.at:1296: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 203. report.at:3123: ./reduce.at:1627: $PREPARSER ./input skipped (report.at:3132) stderr: ./reduce.at:1627: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:82: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 205. conflicts.at:101: testing Token declaration order: literals vs. identifiers ... ./conflicts.at:130: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all -o input.c input.y 198. reduce.at:1627: 206. conflicts.at:183: testing Useless associativity warning ... ./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wprecedence input.y ok 207. conflicts.at:218: testing Useless precedence warning ... ./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y stderr: stdout: ./reduce.at:1627: $PREPARSER ./input stderr: ./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence input.y -Werror ./reduce.at:1627: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 208. conflicts.at:275: testing S/R in initial ... ./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: stdout: ./reduce.at:1627: $PREPARSER ./input 200. reduce.at:1627: ok ./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y -Werror ./reduce.at:1627: $PREPARSER ./input stderr: stderr: ./reduce.at:1627: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./reduce.at:1627: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stderr: 201. reduce.at:1627: ok 199. reduce.at:1627: ok stdout: ./conflicts.at:84: $PREPARSER ./input ./conflicts.at:131: cat input.output | sed -n '/^State 0$/,/^State 1$/p' stderr: stderr: 209. conflicts.at:301: testing %nonassoc and eof ... ./conflicts.at:368: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:84: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input.y:2.1-9: error: useless precedence and associativity for "=" [-Werror=precedence] input.y:4.1-5: error: useless associativity for "*", use %precedence [-Werror=precedence] input.y:5.1-11: error: useless precedence for "(" [-Werror=precedence] ./reduce.at:1296: $PREPARSER ./input ./conflicts.at:205: sed 's,.*/$,,' stderr 1>&2 stderr: 205. conflicts.at:101: stderr: ok input.y:7.1-9: error: useless precedence and associativity for U [-Werror=precedence] 7 | %nonassoc U | ^~~~~~~~~ input.y:6.1-6: error: useless precedence and associativity for V [-Werror=precedence] 6 | %right V | ^~~~~~ input.y:5.1-5: error: useless precedence and associativity for W [-Werror=precedence] 5 | %left W | ^~~~~ input.y:2.1-11: error: useless precedence for Z [-Werror=precedence] 2 | %precedence Z | ^~~~~~~~~~~ 204. conflicts.at:28: ok stderr: ./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence input.y --warnings=error ./conflicts.at:368: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: ./conflicts.at:248: sed 's,.*/$,,' stderr 1>&2 211. conflicts.at:513: testing parse.error=verbose and consistent errors: lr.type=ielr %glr-parser ... ./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror 210. conflicts.at:509: testing parse.error=verbose and consistent errors: lr.type=ielr ... ./conflicts.at:513: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y syntax error ./reduce.at:1296: $PREPARSER ./input ./reduce.at:1296: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./conflicts.at:509: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y --warnings=error syntax error ./reduce.at:1296: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 195. reduce.at:1296: ok stderr: 194. reduce.at:1296: ok input.y:4.10-15: error: rule useless in parser due to conflicts [-Werror=other] ./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence input.y -Wnone,none -Werror --trace=none 212. conflicts.at:518: testing parse.error=verbose and consistent errors: lr.type=ielr c++ ... ./conflicts.at:509: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:518: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 214. conflicts.at:530: testing parse.error=verbose and consistent errors: lr.type=ielr lr.default-reduction=consistent ... ./conflicts.at:530: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 213. conflicts.at:523: testing parse.error=verbose and consistent errors: lr.type=ielr java ... ./conflicts.at:284: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:523: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.java input.y ./conflicts.at:513: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y -Wnone,none -Werror --trace=none ./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence input.y --warnings=none -Werror --trace=none ./conflicts.at:530: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 215. conflicts.at:535: testing parse.error=verbose and consistent errors: lr.type=ielr lr.default-reduction=accepting ... ./conflicts.at:535: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:518: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 216. conflicts.at:540: testing parse.error=verbose and consistent errors: lr.type=canonical-lr ... ./conflicts.at:540: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error ./conflicts.at:535: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 213. conflicts.at:523: 206. conflicts.at:183: skipped (conflicts.at:523) ok ./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y --warnings=none -Werror --trace=none ./conflicts.at:540: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none 217. conflicts.at:546: testing parse.error=verbose and consistent errors: lr.type=canonical-lr parse.lac=full ... ./conflicts.at:546: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 207. conflicts.at:218: ok ./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none 218. conflicts.at:551: testing parse.error=verbose and consistent errors: lr.type=ielr parse.lac=full ... ./conflicts.at:551: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: ./conflicts.at:368: $PREPARSER ./input '0<0' stderr: ./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:368: $PREPARSER ./input '0<0<0' stderr: syntax error, unexpected '<' ./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:546: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:368: $PREPARSER ./input '0>0' ./conflicts.at:551: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o input.c input.y 219. conflicts.at:558: testing parse.error=verbose and consistent errors: c++ lr.type=canonical-lr parse.lac=full ... ./conflicts.at:558: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: ./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:368: $PREPARSER ./input '0>0>0' stderr: syntax error, unexpected '>' ./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:558: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./conflicts.at:368: $PREPARSER ./input '0<0>0' stderr: stderr: stdout: syntax error, unexpected '>' ./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:509: $PREPARSER ./input stderr: ./conflicts.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.default-reduction=consistent -o input.c input.y ./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Werror syntax error, unexpected end of file ./conflicts.at:509: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 210. conflicts.at:509: ok stdout: ./conflicts.at:530: $PREPARSER ./input stderr: syntax error, unexpected end of file, expecting 'a' or 'b' ./conflicts.at:530: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 214. conflicts.at:530: ok input.y:4.10-15: error: rule useless in parser due to conflicts [-Werror=other] 4 | e: 'e' | %empty; | ^~~~~~ ./conflicts.at:372: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:288: sed 's,.*/$,,' stderr 1>&2 stderr: ./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=error 220. conflicts.at:564: testing parse.error=verbose and consistent errors: c++ lr.type=ielr parse.lac=full ... stderr: stdout: ./conflicts.at:540: $PREPARSER ./input stdout: 221. conflicts.at:622: testing parse.error=verbose and consistent errors: ... ./conflicts.at:622: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: ./conflicts.at:535: $PREPARSER ./input syntax error, unexpected end of file, expecting 'a' or 'b' ./conflicts.at:540: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:564: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stderr: stdout: stderr: syntax error, unexpected end of file, expecting 'a' or 'b' ./conflicts.at:535: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./output.at:836: $PREPARSER ./parser ./conflicts.at:546: $PREPARSER ./input stderr: stderr: syntax error, unexpected end of file, expecting 'b' 216. conflicts.at:540: ok ./conflicts.at:546: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:622: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./output.at:836: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Wnone,none -Werror --trace=none 215. conflicts.at:535: ok 144. output.at:744: ok 217. conflicts.at:546: ok ./conflicts.at:564: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=none -Werror --trace=none 222. conflicts.at:626: testing parse.error=verbose and consistent errors: %glr-parser ... ./conflicts.at:626: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: 224. conflicts.at:638: testing parse.error=verbose and consistent errors: lr.default-reduction=accepting ... ./conflicts.at:638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:551: $PREPARSER ./input 223. conflicts.at:632: testing parse.error=verbose and consistent errors: lr.default-reduction=consistent ... stderr: stderr: syntax error, unexpected end of file, expecting 'b' ./conflicts.at:551: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:632: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stdout: stderr: ./conflicts.at:513: $PREPARSER ./input stdout: ./conflicts.at:626: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:372: $PREPARSER ./input '0<0' stderr: stderr: 225. conflicts.at:642: testing parse.error=verbose and consistent errors: lr.type=canonical-lr ... syntax error, unexpected end of file ./conflicts.at:513: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:642: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:638: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 208. conflicts.at:275: ok ./conflicts.at:372: $PREPARSER ./input '0<0<0' stderr: syntax error, unexpected '<', expecting end of file ./conflicts.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 218. conflicts.at:551: ok 211. conflicts.at:513: ok ./conflicts.at:632: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:372: $PREPARSER ./input '0>0' stderr: ./conflicts.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:642: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:372: $PREPARSER ./input '0>0>0' stderr: syntax error, unexpected '>', expecting end of file ./conflicts.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 226. conflicts.at:647: testing parse.error=verbose and consistent errors: parse.lac=full ... ./conflicts.at:647: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:372: $PREPARSER ./input '0<0>0' 227. conflicts.at:651: testing parse.error=verbose and consistent errors: parse.lac=full lr.default-reduction=accepting ... ./conflicts.at:651: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: 228. conflicts.at:676: testing LAC: %nonassoc requires splitting canonical LR states ... syntax error, unexpected '>', expecting end of file ./conflicts.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y ./conflicts.at:647: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:381: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y ./conflicts.at:651: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y -Werror ./conflicts.at:381: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: input.y: error: 2 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./conflicts.at:726: sed 's,.*/$,,' stderr 1>&2 stderr: stdout: ./conflicts.at:622: $PREPARSER ./input stderr: ./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y --warnings=error syntax error, unexpected 'b' ./conflicts.at:622: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 221. conflicts.at:622: ok stderr: ./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y -Wnone,none -Werror --trace=none stdout: ./conflicts.at:638: $PREPARSER ./input stderr: syntax error, unexpected end of file, expecting 'a' ./conflicts.at:638: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 229. conflicts.at:764: testing Unresolved SR Conflicts ... ./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c --report=all input.y stderr: ./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y --warnings=none -Werror --trace=none stdout: 224. conflicts.at:638: ok ./conflicts.at:632: $PREPARSER ./input stderr: stderr: stdout: syntax error, unexpected 'b' ./conflicts.at:632: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:381: $PREPARSER ./input '0<0' stderr: ./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 223. conflicts.at:632: ok ./conflicts.at:381: $PREPARSER ./input '0<0<0' ./conflicts.at:731: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y -Werror syntax error, unexpected '<', expecting end of file ./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 230. conflicts.at:887: testing Resolved SR Conflicts ... ./conflicts.at:898: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c --report=all input.y ./conflicts.at:381: $PREPARSER ./input '0>0' stdout: stderr: ./conflicts.at:642: $PREPARSER ./input ./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected end of file, expecting 'a' ./conflicts.at:642: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./conflicts.at:381: $PREPARSER ./input '0>0>0' input.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples 225. conflicts.at:642: ok stderr: ./conflicts.at:901: cat input.output syntax error, unexpected '>', expecting end of file ./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:774: sed 's,.*/$,,' stderr 1>&2 231. conflicts.at:989: testing %precedence suffices ... ./conflicts.at:1006: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 230. conflicts.at:887: ok ./conflicts.at:381: $PREPARSER ./input '0<0>0' ./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y --warnings=error stderr: syntax error, unexpected '>', expecting end of file ./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 231. conflicts.at:989: ok stderr: ./conflicts.at:388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -o input.c input.y 232. conflicts.at:1015: testing %precedence does not suffice ... ./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stdout: stderr: ./conflicts.at:647: $PREPARSER ./input stderr: stdout: ./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y -Wnone,none -Werror --trace=none stderr: syntax error, unexpected 'b' ./conflicts.at:647: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:518: $PREPARSER ./input stdout: ./conflicts.at:651: $PREPARSER ./input stderr: 233. conflicts.at:1096: testing Syntax error in consistent error state: yacc.c ... ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: syntax error, unexpected end of file ./conflicts.at:388: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:518: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected end of file ./conflicts.at:651: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 226. conflicts.at:647: ok ./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror 234. conflicts.at:1096: testing Syntax error in consistent error state: glr.c ... 212. conflicts.at:518: ok ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 227. conflicts.at:651: ok ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror ./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y --warnings=none -Werror --trace=none stderr: input.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:12.3-18: error: rule useless in parser due to conflicts [-Werror=other] ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror 235. conflicts.at:1096: testing Syntax error in consistent error state: lalr1.cc ... ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./conflicts.at:780: cat input.output ./conflicts.at:1033: sed 's,.*/$,,' stderr 1>&2 stderr: 236. conflicts.at:1096: testing Syntax error in consistent error state: glr.cc ... ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y input.y:17.5-25: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.5-29: error: rule useless in parser due to conflicts [-Werror=other] 229. conflicts.at:764: ok 237. conflicts.at:1096: testing Syntax error in consistent error state: glr2.cc ... ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Werror ./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error stderr: input.y:17.5-25: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.5-29: error: rule useless in parser due to conflicts [-Werror=other] stderr: stderr: ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Werror ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error input.y:17.5-25: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.5-29: error: rule useless in parser due to conflicts [-Werror=other] stderr: stdout: ./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 stdout: ./conflicts.at:558: $PREPARSER ./input ./conflicts.at:626: $PREPARSER ./input stderr: stderr: stderr: stdout: syntax error, unexpected end of file, expecting 'b' ./conflicts.at:558: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:732: $PREPARSER ./input syntax error, unexpected 'b' ./conflicts.at:626: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error stderr: syntax error, unexpected 'a', expecting 'b' ./conflicts.at:732: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 238. conflicts.at:1127: testing Defaulted Conflicted Reduction ... ./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c --report=all input.y stderr: ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Werror ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none stdout: ./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none ./conflicts.at:388: $PREPARSER ./input '0<0' 219. conflicts.at:558: ok stderr: 222. conflicts.at:626: ok ./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ -o input.c input.y ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=error stderr: input.y:17.5-25: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.5-29: error: rule useless in parser due to conflicts [-Werror=other] ./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:388: $PREPARSER ./input '0<0<0' ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none stderr: stderr: syntax error, unexpected '<', expecting end of file ./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input.y:17.5-25: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.5-29: error: rule useless in parser due to conflicts [-Werror=other] ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none ./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y -Werror ./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none ./conflicts.at:388: $PREPARSER ./input '0>0' ./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=error stderr: ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none ./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 239. conflicts.at:1264: testing %expect not enough ... ./conflicts.at:1273: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Wnone,none -Werror --trace=none 240. conflicts.at:1284: testing %expect right ... ./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ -o input.c input.y -Werror ./conflicts.at:1293: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: ./conflicts.at:388: $PREPARSER ./input '0>0>0' 239. conflicts.at:1264: ok input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:4.6-8: error: rule useless in parser due to conflicts [-Werror=other] ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=error stderr: syntax error, unexpected '>', expecting end of file ./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 232. conflicts.at:1015: ok ./conflicts.at:1138: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:1096: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:388: $PREPARSER ./input '0<0>0' ./conflicts.at:1096: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y --warnings=error stderr: ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=none -Werror --trace=none syntax error, unexpected '>', expecting end of file ./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 240. conflicts.at:1284: ok stderr: ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Wnone,none -Werror --trace=none input.y: error: 2 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples 209. conflicts.at:301: ok ./conflicts.at:737: sed 's,.*/$,,' stderr 1>&2 241. conflicts.at:1301: testing %expect too much ... ./conflicts.at:1310: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Wnone,none -Werror --trace=none ./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y -Wnone,none -Werror --trace=none 242. conflicts.at:1321: testing %expect with reduce conflicts ... ./conflicts.at:1330: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=none -Werror --trace=none ./conflicts.at:1096: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ -o input.c input.y --warnings=error 241. conflicts.at:1301: ok 242. conflicts.at:1321: ok 243. conflicts.at:1341: testing %expect in grammar rule not enough ... ./conflicts.at:1350: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=none -Werror --trace=none ./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y --warnings=none -Werror --trace=none 244. conflicts.at:1360: testing %expect in grammar rule right ... ./conflicts.at:1369: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 243. conflicts.at:1341: ok ./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ -o input.c input.y -Wnone,none -Werror --trace=none ./conflicts.at:1096: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./conflicts.at:1096: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 244. conflicts.at:1360: ok ./conflicts.at:1145: cat input.output 245. conflicts.at:1377: testing %expect in grammar rules ... ./conflicts.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -rall input.y ./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ -o input.c input.y --warnings=none -Werror --trace=none 238. conflicts.at:1127: ok 246. conflicts.at:1396: testing %expect in grammar rule too much ... ./conflicts.at:1405: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y 247. conflicts.at:1415: testing %expect-rr in grammar rule ... ./conflicts.at:1432: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 246. conflicts.at:1396: ok 248. conflicts.at:1440: testing %expect-rr too much in grammar rule ... 245. conflicts.at:1377: ok ./conflicts.at:1457: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y 247. conflicts.at:1415: ok 249. conflicts.at:1469: testing %expect-rr not enough in grammar rule ... 248. conflicts.at:1440: ok ./conflicts.at:1486: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y ./conflicts.at:742: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 249. conflicts.at:1469: ok stderr: 250. conflicts.at:1498: testing %prec with user string ... ./conflicts.at:1507: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stdout: ./conflicts.at:1096: $PREPARSER ./input stderr: 251. conflicts.at:1515: testing %no-default-prec without %prec ... ./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall -o input.c input.y syntax error ./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 250. conflicts.at:1498: ok 252. conflicts.at:1544: testing %no-default-prec with %prec ... ./conflicts.at:1560: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 233. conflicts.at:1096: ok 253. conflicts.at:1568: testing %default-prec ... ./conflicts.at:1584: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y -Werror 254. conflicts.at:1592: testing Unreachable States After Conflict Resolution ... ./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all input.y 252. conflicts.at:1544: ok 253. conflicts.at:1568: ok 255. conflicts.at:1855: testing Solved conflicts report for multiple reductions in a state ... ./conflicts.at:1881: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all -o input.c input.y ./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=all input.y -Werror stderr: 256. conflicts.at:1935: testing %nonassoc error actions for multiple reductions in a state ... ./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y input.y: error: 4 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:1.1-5: error: useless precedence and associativity for '+' [-Werror=precedence] input.y:2.1-5: error: useless precedence and associativity for '*' [-Werror=precedence] stderr: ./conflicts.at:1531: sed 's,.*/$,,' stderr 1>&2 stdout: stderr: input.y:7.5-7: warning: rule useless in parser due to conflicts [-Wother] input.y:11.5-7: warning: rule useless in parser due to conflicts [-Wother] input.y:17.11-26: warning: rule useless in parser due to conflicts [-Wother] input.y:18.11-26: warning: rule useless in parser due to conflicts [-Wother] input.y:19.11-26: warning: rule useless in parser due to conflicts [-Wother] ./conflicts.at:1882: cat input.output | sed -n '/^State 0$/,/^State 1$/p' ./conflicts.at:564: $PREPARSER ./input stderr: stderr: syntax error, unexpected end of file, expecting 'b' input.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:12.5-20: error: rule useless in parser due to conflicts [-Werror=other] input.y:20.5-20: error: rule useless in parser due to conflicts [-Werror=other] input.y:21.4: error: rule useless in parser due to conflicts [-Werror=other] input.y:25.14: error: rule useless in parser due to conflicts [-Werror=other] input.y:25.16: error: rule useless in parser due to conflicts [-Werror=other] input.y:31.5-7: error: rule useless in parser due to conflicts [-Werror=other] input.y:32.4: error: rule useless in parser due to conflicts [-Werror=other] ./conflicts.at:564: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 255. conflicts.at:1855: ok ./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y --warnings=error 220. conflicts.at:564: ok ./conflicts.at:1638: sed 's,.*/$,,' stderr 1>&2 257. conflicts.at:2299: testing %expect-rr non GLR ... ./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret 1.y 258. conflicts.at:2331: testing -W versus %expect and %expect-rr ... ./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y -Werror ./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret sr-rr.y ./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=all input.y --warnings=error ./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y -Wnone,none -Werror --trace=none ./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y -Werror stderr: bison (GNU Bison) 3.8.2 init: 0.000000 # state items: 26 State 0: 0 $accept: . start $end -> 0 $accept: start . $end => 2 start: . empty_a 'a' => 4 start: . empty_b 'b' => 6 start: . empty_c1 'c' => 7 start: . empty_c2 'c' => 8 start: . empty_c3 'c' 1 start: . 'a' DISABLED 2 start: . empty_a 'a' -> 2 start: empty_a . 'a' => 9 empty_a: %empty . <- 0 $accept: . start $end 3 start: . 'b' DISABLED 4 start: . empty_b 'b' -> 4 start: empty_b . 'b' => 10 empty_b: %empty . <- 0 $accept: . start $end 5 start: . 'c' DISABLED 6 start: . empty_c1 'c' -> 6 start: empty_c1 . 'c' => 11 empty_c1: %empty . <- 0 $accept: . start $end 7 start: . empty_c2 'c' -> 7 start: empty_c2 . 'c' => 12 empty_c2: %empty . <- 0 $accept: . start $end 8 start: . empty_c3 'c' -> 8 start: empty_c3 . 'c' => 13 empty_c3: %empty . <- 0 $accept: . start $end 9 empty_a: %empty . <- 2 start: . empty_a 'a' 10 empty_b: %empty . <- 4 start: . empty_b 'b' 11 empty_c1: %empty . <- 6 start: . empty_c1 'c' 12 empty_c2: %empty . <- 7 start: . empty_c2 'c' 13 empty_c3: %empty . <- 8 start: . empty_c3 'c' State 1: 0 $accept: start . $end -> 0 $accept: start $end . <- 0 $accept: . start $end State 2: 2 start: empty_a . 'a' -> 2 start: empty_a 'a' . <- 2 start: . empty_a 'a' State 3: 4 start: empty_b . 'b' -> 4 start: empty_b 'b' . <- 4 start: . empty_b 'b' State 4: 6 start: empty_c1 . 'c' -> 6 start: empty_c1 'c' . <- 6 start: . empty_c1 'c' State 5: 7 start: empty_c2 . 'c' -> 7 start: empty_c2 'c' . <- 7 start: . empty_c2 'c' State 6: 8 start: empty_c3 . 'c' -> 8 start: empty_c3 'c' . <- 8 start: . empty_c3 'c' State 7: 0 $accept: start $end . <- 0 $accept: start . $end State 8: 2 start: empty_a 'a' . <- 2 start: empty_a . 'a' State 9: 4 start: empty_b 'b' . <- 4 start: empty_b . 'b' State 10: 6 start: empty_c1 'c' . <- 6 start: empty_c1 . 'c' State 11: 7 start: empty_c2 'c' . <- 7 start: empty_c2 . 'c' State 12: 8 start: empty_c3 'c' . <- 8 start: empty_c3 . 'c' FIRSTS $accept firsts 'a' 'b' 'c' start firsts 'a' 'b' 'c' empty_a firsts empty_b firsts empty_c1 firsts empty_c2 firsts empty_c3 firsts input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:4.5-7: error: rule useless in parser due to conflicts [-Werror=other] 4 | 'a' | ^~~ input.y:6.5-7: error: rule useless in parser due to conflicts [-Werror=other] 6 | | 'b' | ^~~ input.y:8.5-7: error: rule useless in parser due to conflicts [-Werror=other] 8 | | 'c' | ^~~ input.y:13.10-18: error: rule useless in parser due to conflicts [-Werror=other] 13 | empty_a: %prec 'a' ; | ^~~~~~~~~ input.y:14.10-18: error: rule useless in parser due to conflicts [-Werror=other] 14 | empty_b: %prec 'b' ; | ^~~~~~~~~ input.y:15.11-19: error: rule useless in parser due to conflicts [-Werror=other] 15 | empty_c1: %prec 'c' ; | ^~~~~~~~~ input.y:16.11-19: error: rule useless in parser due to conflicts [-Werror=other] 16 | empty_c2: %prec 'c' ; | ^~~~~~~~~ input.y:17.11-19: error: rule useless in parser due to conflicts [-Werror=other] 17 | empty_c3: %prec 'c' ; | ^~~~~~~~~ REDUCE ITEM PATH: 0 $accept: . start $end 7 start: . empty_c2 'c' 12 empty_c2: %empty . CONFLICT 1 (size 1 depth 0 rc 2) 12 empty_c2: %empty . 12 empty_c2: %empty . . CONFLICT 2 (size 1 depth 0 rc 2) 13 empty_c3: %empty . 13 empty_c3: %empty . . CONFLICT 1 (size 2 depth -1 rc 4) 7 start: . empty_c2 'c' 7 start: empty_c2 . 'c' empty_c2 `-> 12: %empty . CONFLICT 2 (size 1 depth 0 rc 3) 13 empty_c3: %empty . 13 empty_c3: %empty . . CONFLICT 1 (size 1 depth 0 rc 3) 12 empty_c2: %empty . 12 empty_c2: %empty . . CONFLICT 2 (size 2 depth -1 rc 2) 8 start: . empty_c3 'c' 8 start: empty_c3 . 'c' empty_c3 `-> 13: %empty . CONFLICT 1 (size 2 depth -1 rc 3) 7 start: . empty_c2 'c' 7 start: empty_c2 . 'c' empty_c2 `-> 12: %empty . CONFLICT 2 (size 2 depth -1 rc 2) 8 start: . empty_c3 'c' 8 start: empty_c3 . 'c' empty_c3 `-> 13: %empty . CONFLICT 1 (size 3 depth -1 rc 2) 7 start: . empty_c2 'c' 7 start: empty_c2 'c' . empty_c2 `-> 12: %empty . CONFLICT 2 (size 3 depth -1 rc 2) 8 start: . empty_c3 'c' 8 start: empty_c3 'c' . empty_c3 `-> 13: %empty . CONFLICT 1 (size 2 depth -1 rc 4) 0 $accept: . start $end 0 $accept: start . $end start `-> 7: empty_c2 'c' `-> 12: %empty . CONFLICT 2 (size 3 depth -1 rc 3) 8 start: . empty_c3 'c' 8 start: empty_c3 'c' . empty_c3 `-> 13: %empty . CONFLICT 1 (size 3 depth -1 rc 3) 7 start: . empty_c2 'c' 7 start: empty_c2 'c' . empty_c2 `-> 12: %empty . CONFLICT 2 (size 2 depth -1 rc 2) 0 $accept: . start $end 0 $accept: start . $end start `-> 8: empty_c3 'c' `-> 13: %empty . CONFLICT 1 (size 2 depth -1 rc 3) 0 $accept: . start $end 0 $accept: start . $end start `-> 7: empty_c2 'c' `-> 12: %empty . CONFLICT 2 (size 2 depth -1 rc 2) 0 $accept: . start $end 0 $accept: start . $end start `-> 8: empty_c3 'c' `-> 13: %empty . ./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret sr-rr.y -Werror 259. counterexample.at:43: testing Unifying S/R ... 260. counterexample.at:83: testing Deep Unifying S/R ... ./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=all input.y -Wnone,none -Werror --trace=none ./counterexample.at:55: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: ./counterexample.at:95: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 1.y: error: %expect-rr applies only to GLR parsers [-Werror=other] ./conflicts.at:1959: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:2307: sed 's,.*/$,,' stderr 1>&2 stderr: ./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y --warnings=none -Werror --trace=none stderr: ./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y --warnings=error sr-rr.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] sr-rr.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] sr-rr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=all input.y --warnings=none -Werror --trace=none input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: A . B C Shift derivation s `-> 2: y c `-> 8: A . B `-> 4: C Reduce derivation s `-> 1: a x `-> 3: A . `-> 6: B C input.y:4.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:55: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y --warnings=error stderr: ./conflicts.at:2354: sed 's,.*/$,,' stderr 1>&2 ./counterexample.at:55: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: A . B C Shift derivation s `-> 1: ac `-> 3: A ac C `-> 4: b `-> 5: . B Reduce derivation s `-> 2: a bc `-> 7: A . `-> 10: B C input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: A A . B B C C Shift derivation s `-> 1: ac `-> 3: A ac C `-> 3: A ac C `-> 4: b `-> 6: . b `-> 5: B B Reduce derivation s `-> 2: a bc `-> 8: A a `-> 9: B bc C `-> 7: A . `-> 10: B C input.y:6.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:95: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./counterexample.at:95: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:1651: cat input.output ./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y -Wnone,none -Werror --trace=none ./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret sr-rr.y --warnings=error stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example A . B C Shift derivation s -> [ y -> [ A . B ] c -> [ C ] ] Reduce derivation s -> [ a -> [ A . ] x -> [ B C ] ] input.y:4.4: warning: rule useless in parser due to conflicts [-Wother] ./conflicts.at:1836: cat input.y >> input-keep.y 251. conflicts.at:1515: ok ./counterexample.at:55: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr ./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y -Wnone,none -Werror --trace=none ./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input-keep.y stderr: 259. counterexample.at:43: ok input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example A . B C Shift derivation s -> [ ac -> [ A ac -> [ b -> [ . B ] ] C ] ] Reduce derivation s -> [ a -> [ A . ] bc -> [ B C ] ] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example A A . B B C C Shift derivation s -> [ ac -> [ A ac -> [ A ac -> [ b -> [ . b -> [ B B ] ] ] C ] C ] ] Reduce derivation s -> [ a -> [ A a -> [ A . ] ] bc -> [ B bc -> [ B C ] C ] ] input.y:6.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:95: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr stderr: ./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y --warnings=none -Werror --trace=none ./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret sr-rr.y -Wnone,none -Werror --trace=none stdout: 260. counterexample.at:83: ok ./conflicts.at:743: $PREPARSER ./input ./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y --warnings=none -Werror --trace=none stderr: syntax error, unexpected 'a', expecting 'b' or 'c' ./conflicts.at:743: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret sr-rr.y --warnings=none -Werror --trace=none 261. counterexample.at:144: testing S/R Conflict with Nullable Symbols ... ./counterexample.at:157: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:2239: cat input.output | sed -n '/^State 0$/,/^State 1$/p' ./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y ./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-keep.y -Werror 256. conflicts.at:1935: ok 262. counterexample.at:207: testing Non-unifying Ambiguous S/R ... ./counterexample.at:220: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret 2.y ./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y 263. counterexample.at:254: testing Non-unifying Unambiguous S/R ... ./counterexample.at:265: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: stderr: input.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: A . B Shift derivation s `-> 2: A xby `-> 9: . B Reduce derivation s `-> 1: ax by `-> 3: A x `-> 6: B y `-> 4: %empty . `-> 6: %empty input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] First example: A X . B Y $end Shift derivation $accept `-> 0: s $end `-> 2: A xby `-> 10: X xby Y `-> 9: . B Second example: A X . B y $end Reduce derivation $accept `-> 0: s $end `-> 1: ax by `-> 3: A x `-> 6: B y `-> 5: X x `-> 4: %empty . input.y:5.4-9: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:157: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr input-keep.y: error: 2 shift/reduce conflicts [-Werror=conflicts-sr] input-keep.y: error: 2 reduce/reduce conflicts [-Werror=conflicts-rr] input-keep.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input-keep.y:22.4: error: rule useless in parser due to conflicts [-Werror=other] input-keep.y:26.16: error: rule useless in parser due to conflicts [-Werror=other] input-keep.y:32.5-7: error: rule useless in parser due to conflicts [-Werror=other] input-keep.y:33.4: error: rule useless in parser due to conflicts [-Werror=other] ./counterexample.at:157: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token C [-Wcounterexamples] First example: B . C $end Shift derivation $accept `-> 0: g $end `-> 2: x `-> 6: bc `-> 9: B . C Second example: B . C D $end Reduce derivation $accept `-> 0: g $end `-> 2: x `-> 5: b cd `-> 7: B . `-> 8: C D input.y:6.4: warning: rule useless in parser due to conflicts [-Wother] ./conflicts.at:1838: sed 's,.*/$,,' stderr 1>&2 ./counterexample.at:220: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] First example: A . A B $end Shift derivation $accept `-> 0: s $end `-> 1: t `-> 4: y `-> 6: A . A B Second example: A . A $end Reduce derivation $accept `-> 0: s $end `-> 2: s t `-> 1: t `-> 3: x `-> 3: x `-> 5: A `-> 5: A . ./counterexample.at:265: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr 264. counterexample.at:298: testing S/R after first token ... ./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y -Werror ./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y -Werror ./counterexample.at:220: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: input.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example A . B Shift derivation s -> [ A xby -> [ . B ] ] Reduce derivation s -> [ ax -> [ A x -> [ . ] ] by -> [ B y -> [ ] ] ] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] First example A X . B Y $end Shift derivation $accept -> [ s -> [ A xby -> [ X xby -> [ . B ] Y ] ] $end ] Second example A X . B y $end Reduce derivation $accept -> [ s -> [ ax -> [ A x -> [ X x -> [ . ] ] ] by -> [ B y ] ] $end ] input.y:5.4-9: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:157: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr ./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-keep.y --warnings=error ./counterexample.at:265: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 2.y -Werror ./counterexample.at:314: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 261. counterexample.at:144: ok stderr: stderr: stderr: sr-rr.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] sr-rr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token C [-Wcounterexamples] First example B . C $end Shift derivation $accept -> [ g -> [ x -> [ bc -> [ B . C ] ] ] $end ] Second example B . C D $end Reduce derivation $accept -> [ g -> [ x -> [ b -> [ B . ] cd -> [ C D ] ] ] $end ] input.y:6.4: warning: rule useless in parser due to conflicts [-Wother] input.y: error: 2 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./counterexample.at:220: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr stderr: stderr: 2.y: error: %expect-rr applies only to GLR parsers [-Werror=other] 2.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] 2.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples 2.y:3.12-14: error: rule useless in parser due to conflicts [-Werror=other] input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] First example A . A B $end Shift derivation $accept -> [ s -> [ t -> [ y -> [ A . A B ] ] ] $end ] Second example A . A $end Reduce derivation $accept -> [ s -> [ s -> [ t -> [ x -> [ A . ] ] ] t -> [ x -> [ A ] ] ] $end ] stderr: ./counterexample.at:265: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr input.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] Example: b . A X X Y Shift derivation a `-> 2: s `-> 7: b . xx y `-> 9: A X X `-> 11: Y Reduce derivation a `-> 1: r t `-> 3: b . `-> 6: A x xy `-> 8: X `-> 10: X Y input.y: warning: shift/reduce conflict on token X [-Wcounterexamples] First example: A X . X Shift derivation a `-> 1: t `-> 5: A xx `-> 9: X . X Second example: X . X xy Reduce derivation a `-> 1: x t `-> 8: X . `-> 6: X xy input.y:4.4: warning: rule useless in parser due to conflicts [-Wother] input.y:8.4: warning: rule useless in parser due to conflicts [-Wother] ./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-keep.y -Wnone,none -Werror --trace=none ./counterexample.at:314: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr 262. counterexample.at:207: ok ./conflicts.at:748: sed 's,.*/$,,' stderr 1>&2 ./counterexample.at:314: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:2359: sed 's,.*/$,,' stderr 1>&2 stderr: 263. counterexample.at:254: ./conflicts.at:2317: sed 's,.*/$,,' stderr 1>&2 ok stdout: ./conflicts.at:1096: $PREPARSER ./input 265. counterexample.at:363: testing Unifying R/R counterexample ... stderr: ./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y --warnings=error ./counterexample.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y syntax error ./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y --warnings=error ./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 2.y --warnings=error ./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-keep.y --warnings=none -Werror --trace=none 234. conflicts.at:1096: ok stderr: stderr: input.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] Example: A b . First reduce derivation a `-> 1: A b . Second reduce derivation a `-> 1: A b `-> 3: b . input.y:4.9: warning: rule useless in parser due to conflicts [-Wother] input.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] Example b . A X X Y Shift derivation a -> [ s -> [ b . xx -> [ A X X ] y -> [ Y ] ] ] Reduce derivation a -> [ r -> [ b . ] t -> [ A x -> [ X ] xy -> [ X Y ] ] ] input.y: warning: shift/reduce conflict on token X [-Wcounterexamples] First example A X . X Shift derivation a -> [ t -> [ A xx -> [ X . X ] ] ] Second example X . X xy Reduce derivation a -> [ x -> [ X . ] t -> [ X xy ] ] input.y:4.4: warning: rule useless in parser due to conflicts [-Wother] input.y:8.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:314: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr ./counterexample.at:372: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y -Wnone,none -Werror --trace=none ./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 2.y -Wnone,none -Werror --trace=none 267. counterexample.at:441: testing Non-unifying R/R LR(2) conflict ... ./counterexample.at:451: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 266. counterexample.at:399: testing Non-unifying R/R LR(1) conflict ... ./counterexample.at:372: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 264. counterexample.at:298: ok ./counterexample.at:409: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y -Wnone,none -Werror --trace=none 254. conflicts.at:1592: ok ./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 2.y --warnings=none -Werror --trace=none ./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y --warnings=none -Werror --trace=none stderr: 268. counterexample.at:488: testing Cex Search Prepend ... input.y: warning: 2 reduce/reduce conflicts [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on tokens A, C [-Wcounterexamples] First example: D . A $end First reduce derivation $accept `-> 0: s $end `-> 1: a A `-> 5: D . Second example: B D . A $end Second reduce derivation $accept `-> 0: s $end `-> 4: B b A `-> 6: D . input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:409: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./counterexample.at:499: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: input.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] Example A b . First reduce derivation a -> [ A b . ] Second reduce derivation a -> [ A b -> [ b . ] ] input.y:4.9: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:372: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr ./counterexample.at:409: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 265. counterexample.at:363: ok ./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y --warnings=none -Werror --trace=none 257. conflicts.at:2299: ok 269. counterexample.at:550: testing R/R cex with prec ... stderr: stderr: ./counterexample.at:562: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 270. counterexample.at:610: testing Null nonterminals ... input.y: warning: 2 reduce/reduce conflicts [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on tokens A, C [-Wcounterexamples] First example D . A $end First reduce derivation $accept -> [ s -> [ a -> [ D . ] A ] $end ] Second example B D . A $end Second reduce derivation $accept -> [ s -> [ B b -> [ D . ] A ] $end ] input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:409: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr ./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: N A . B C Shift derivation s `-> 1: n `-> 6: N b `-> 8: A . B C Reduce derivation s `-> 2: n C `-> 5: N a B `-> 7: A . input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: N N A . B D C Shift derivation s `-> 1: n `-> 4: N n C `-> 6: N b `-> 9: A . B D Reduce derivation s `-> 2: n C `-> 3: N n D `-> 5: N a B `-> 7: A . input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:499: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./counterexample.at:621: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 266. counterexample.at:399: ok ./counterexample.at:499: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 271. counterexample.at:797: testing Non-unifying Prefix Share ... ./counterexample.at:810: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: stderr: 272. counterexample.at:842: testing Deep Null Unifying ... ./counterexample.at:854: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y input.y: warning: 4 reduce/reduce conflicts [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on tokens b, c [-Wcounterexamples] Example: B . b c First reduce derivation S `-> 1: B C `-> 6: A b A `-> 7: A c A `-> 3: B . `-> 6: %empty `-> 7: %empty `-> 7: %empty Second reduce derivation S `-> 1: B C `-> 7: A c A `-> 3: B `-> 7: %empty `-> 6: A b A `-> 5: %empty . `-> 6: %empty input.y: warning: reduce/reduce conflict on tokens b, c [-Wcounterexamples] Example: C . c b First reduce derivation S `-> 2: C B `-> 7: A c A `-> 6: A b A `-> 4: C . `-> 7: %empty `-> 6: %empty `-> 6: %empty Second reduce derivation S `-> 2: C B `-> 6: A b A `-> 4: C `-> 6: %empty `-> 7: A c A `-> 5: %empty . `-> 7: %empty ./conflicts.at:753: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./counterexample.at:562: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example N A . B C Shift derivation s -> [ n -> [ N b -> [ A . B C ] ] ] Reduce derivation s -> [ n -> [ N a -> [ A . ] B ] C ] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example N N A . B D C Shift derivation s -> [ n -> [ N n -> [ N b -> [ A . B D ] ] C ] ] Reduce derivation s -> [ n -> [ N n -> [ N a -> [ A . ] B ] D ] C ] input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:499: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr 268. counterexample.at:488: ok ./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y -Werror ./counterexample.at:562: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token J [-Wcounterexamples] Example: H i J . J J Shift derivation s `-> 2: a J `-> 3: H i J . J Reduce derivation s `-> 1: a `-> 3: H i J J `-> 5: i J . input.y:5.13-15: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:810: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./counterexample.at:810: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 273. counterexample.at:884: testing Deep Null Non-unifying ... ./counterexample.at:896: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token D [-Wcounterexamples] Example: A a . D Shift derivation s `-> 1: A a d `-> 6: . D Reduce derivation s `-> 2: A a a d `-> 3: b `-> 6: D `-> 4: c `-> 5: %empty . ./counterexample.at:854: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr stderr: sr-rr.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] stderr: ./counterexample.at:854: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token D [-Wcounterexamples] First example: A a . D $end Shift derivation $accept `-> 0: s $end `-> 1: A a d `-> 6: . D Second example: A a . D E $end Reduce derivation $accept `-> 0: s $end `-> 2: A a a d E `-> 3: b `-> 6: D `-> 4: c `-> 5: %empty . ./counterexample.at:896: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr stderr: stderr: ./conflicts.at:2363: sed 's,.*/$,,' stderr 1>&2 input.y: warning: 4 reduce/reduce conflicts [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on tokens b, c [-Wcounterexamples] Example B . b c First reduce derivation S -> [ B -> [ A -> [ B . ] b A -> [ ] ] C -> [ A -> [ ] c A -> [ ] ] ] Second reduce derivation S -> [ B C -> [ A -> [ B -> [ A -> [ . ] b A -> [ ] ] ] c A -> [ ] ] ] input.y: warning: reduce/reduce conflict on tokens b, c [-Wcounterexamples] Example C . c b First reduce derivation S -> [ C -> [ A -> [ C . ] c A -> [ ] ] B -> [ A -> [ ] b A -> [ ] ] ] Second reduce derivation S -> [ C B -> [ A -> [ C -> [ A -> [ . ] c A -> [ ] ] ] b A -> [ ] ] ] input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token J [-Wcounterexamples] Example H i J . J J Shift derivation s -> [ a -> [ H i J . J ] J ] Reduce derivation s -> [ a -> [ H i -> [ i J . ] J J ] ] input.y:5.13-15: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:562: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr ./counterexample.at:896: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./counterexample.at:810: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr 274. synclines.at:194: testing Prologue syncline ... ./synclines.at:194: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 271. counterexample.at:797: ok 269. counterexample.at:550: ok ./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y --warnings=error stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token D [-Wcounterexamples] Example A a . D Shift derivation s -> [ A a d -> [ . D ] ] Reduce derivation s -> [ A a a -> [ b -> [ c -> [ . ] ] ] d -> [ D ] ] ./counterexample.at:854: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token D [-Wcounterexamples] First example A a . D $end Shift derivation $accept -> [ s -> [ A a d -> [ . D ] ] $end ] Second example A a . D E $end Reduce derivation $accept -> [ s -> [ A a a -> [ b -> [ c -> [ . ] ] ] d -> [ D ] E ] $end ] ./counterexample.at:896: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr 272. counterexample.at:842: ok ./synclines.at:194: $CC $CFLAGS $CPPFLAGS -c syncline.c 273. counterexample.at:884: ok ./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y -Wnone,none -Werror --trace=none stderr: 275. synclines.at:214: testing %union syncline ... syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:194: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF ./synclines.at:214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 276. synclines.at:237: testing %union name syncline ... stdout: syncline.c:4: #error "4" ./synclines.at:194: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 ./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y --warnings=none -Werror --trace=none ./synclines.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: ./synclines.at:194: $CC $CFLAGS $CPPFLAGS -c input.c ./conflicts.at:754: $PREPARSER ./input stderr: 277. synclines.at:264: testing Postprologue syncline ... syntax error, unexpected 'a', expecting 'b' or 'c' ./synclines.at:264: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:754: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./synclines.at:214: $CC $CFLAGS $CPPFLAGS -c syncline.c input.y:2:2: error: #error "2" 2 | #error "2" | ^~~~~ ./synclines.at:194: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF 278. synclines.at:291: testing Action syncline ... ./synclines.at:254: $CC $CFLAGS $CPPFLAGS -c syncline.c ./synclines.at:291: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stdout: stderr: 228. conflicts.at:676: ok input.y:2: #error "2" ./synclines.at:194: cat stdout syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:214: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./synclines.at:264: $CC $CFLAGS $CPPFLAGS -c syncline.c stderr: syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:254: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF 274. synclines.at:194: ok stdout: stderr: syncline.c:4: #error "4" syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:264: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stdout: ./synclines.at:254: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 syncline.c:4: #error "4" ./synclines.at:214: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 ./synclines.at:291: $CC $CFLAGS $CPPFLAGS -c syncline.c stdout: syncline.c:4: #error "4" ./synclines.at:254: $CC $CFLAGS $CPPFLAGS -c input.c ./synclines.at:264: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 ./synclines.at:214: $CC $CFLAGS $CPPFLAGS -c input.c ./synclines.at:264: $CC $CFLAGS $CPPFLAGS -c input.c stderr: syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ stderr: ./synclines.at:291: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF input.y:2:2: error: #error "2" 2 | #error "2" | ^~~~~ ./synclines.at:214: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF stdout: 279. synclines.at:310: testing Epilogue syncline ... ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 280. synclines.at:327: testing %code top syncline ... syncline.c:4: #error "4" ./synclines.at:327: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stdout: ./synclines.at:291: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 stderr: ./synclines.at:310: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y input.y:2: #error "2" stderr: ./synclines.at:214: cat stdout ./synclines.at:291: $CC $CFLAGS $CPPFLAGS -c input.c input.y:13:2: error: #error "13" 13 | #error "13" | ^~~~~ input.y:1:7: error: expected '{' before 'break' 1 | %union break | ^~~~~ input.y:1:15: error: expected '{' before 'break' 1 | %union break | ^ input.y:7:8: error: unknown type name 'YYSTYPE' 7 | int yylex (void); | ^~~~~~~ input.y:8:1: error: expected identifier or '(' before '%' token 8 | %} | ^ input.c:273:9: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 273 | typedef yytype_int8 yy_state_t; | ^~~~~~~~~~~ | yytype_uint8 input.c:429:3: error: unknown type name 'YYSTYPE' 429 | YYSTYPE yyvs_alloc; | ^~~~~~~ input.c:508:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 508 | static const yytype_int8 yytranslate[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:581:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 581 | static const yytype_int8 yypact[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:589:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 589 | static const yytype_int8 yydefact[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:595:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 595 | static const yytype_int8 yypgoto[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:601:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 601 | static const yytype_int8 yydefgoto[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:609:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 609 | static const yytype_int8 yytable[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:614:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 614 | static const yytype_int8 yycheck[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:621:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 621 | static const yytype_int8 yystos[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:627:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 627 | static const yytype_int8 yyr1[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:633:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 633 | static const yytype_int8 yyr2[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:828:37: error: unknown type name 'YYSTYPE' 828 | yysymbol_kind_t yykind, YYSTYPE *yyvaluep) | ^~~~~~~ input.c:322:5: error: expected end of line before 'push' 322 | _Pragma ("GCC diagnostic push") \ | ^~~~~~~ input.c:835:3: note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN' 835 | YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:323:5: error: expected end of line before 'ignored' 323 | _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"") \ | ^~~~~~~ input.c:835:3: note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN' 835 | YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:324:5: error: expected end of line before 'ignored' 324 | _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"") | ^~~~~~~ input.c:835:3: note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN' 835 | YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:327:5: error: expected end of line before 'pop' 327 | _Pragma ("GCC diagnostic pop") | ^~~~~~~ input.c:837:3: note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_END' 837 | YY_IGNORE_MAYBE_UNINITIALIZED_END | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:845:1: error: unknown type name 'YYSTYPE' 845 | YYSTYPE yylval; | ^~~~~~~ input.c: In function 'yyparse': input.c:875:5: error: unknown type name 'YYSTYPE' 875 | YYSTYPE yyvsa[YYINITDEPTH]; | ^~~~~~~ input.c:876:5: error: unknown type name 'YYSTYPE' 876 | YYSTYPE *yyvs = yyvsa; | ^~~~~~~ input.c:877:5: error: unknown type name 'YYSTYPE' 877 | YYSTYPE *yyvsp = yyvs; | ^~~~~~~ input.c:886:3: error: unknown type name 'YYSTYPE' 886 | YYSTYPE yyval; | ^~~~~~~ input.c:438:48: error: 'YYSTYPE' undeclared (first use in this function) 438 | ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ | ^~~~~~~ input.c:75:40: note: in definition of macro 'YY_CAST' 75 | # define YY_CAST(Type, Val) ((Type) (Val)) | ^~~ input.c:962:35: note: in expansion of macro 'YY_CAST' 962 | YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); | ^~~~~~~ input.c:269:21: note: in expansion of macro 'YY_CAST' 269 | #define YYSIZEOF(X) YY_CAST (YYPTRDIFF_T, sizeof (X)) | ^~~~~~~ input.c:438:38: note: in expansion of macro 'YYSIZEOF' 438 | ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ | ^~~~~~~~ input.c:962:54: note: in expansion of macro 'YYSTACK_BYTES' 962 | YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); | ^~~~~~~~~~~~~ input.c:438:48: note: each undeclared identifier is reported only once for each function it appears in 438 | ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ | ^~~~~~~ input.c:75:40: note: in definition of macro 'YY_CAST' 75 | # define YY_CAST(Type, Val) ((Type) (Val)) | ^~~ input.c:962:35: note: in expansion of macro 'YY_CAST' 962 | YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); | ^~~~~~~ input.c:269:21: note: in expansion of macro 'YY_CAST' 269 | #define YYSIZEOF(X) YY_CAST (YYPTRDIFF_T, sizeof (X)) | ^~~~~~~ input.c:438:38: note: in expansion of macro 'YYSIZEOF' 438 | ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ | ^~~~~~~~ input.c:962:54: note: in expansion of macro 'YYSTACK_BYTES' 962 | YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); | ^~~~~~~~~~~~~ input.c:1162:11: error: implicit declaration of function 'yydestruct' [-Wimplicit-function-declaration] 1162 | yydestruct ("Error: discarding", | ^~~~~~~~~~ ./synclines.at:264: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF ./synclines.at:254: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stdout: stdout: 275. synclines.at:214: ok input.y:13: #error "13" ./synclines.at:264: cat stdout input.y:1: #error expected '{' before 'break' %union break ^~~~~ input.y:1: #error expected '{' before 'break' %union break ^ input.y:7: #error unknown type name 'YYSTYPE' int yylex (void); ^~~~~~~ input.y:8: #error expected identifier or '(' before '%' token %} ^ input.c:273: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? typedef yytype_int8 yy_state_t; ^~~~~~~~~~~ yytype_uint8 input.c:429: #error unknown type name 'YYSTYPE' YYSTYPE yyvs_alloc; ^~~~~~~ input.c:508: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yytranslate[] = ^~~~~~~~~~~ yytype_uint8 input.c:581: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yypact[] = ^~~~~~~~~~~ yytype_uint8 input.c:589: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yydefact[] = ^~~~~~~~~~~ yytype_uint8 input.c:595: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yypgoto[] = ^~~~~~~~~~~ yytype_uint8 input.c:601: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yydefgoto[] = ^~~~~~~~~~~ yytype_uint8 input.c:609: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yytable[] = ^~~~~~~~~~~ yytype_uint8 input.c:614: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yycheck[] = ^~~~~~~~~~~ yytype_uint8 input.c:621: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yystos[] = ^~~~~~~~~~~ yytype_uint8 input.c:627: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yyr1[] = ^~~~~~~~~~~ yytype_uint8 input.c:633: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yyr2[] = ^~~~~~~~~~~ yytype_uint8 input.c:828: #error unknown type name 'YYSTYPE' yysymbol_kind_t yykind, YYSTYPE *yyvaluep) ^~~~~~~ input.c:322: #error expected end of line before 'push' _Pragma ("GCC diagnostic push") \ ^~~~~~~ input.c:835: #error note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN' YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:323: #error expected end of line before 'ignored' _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"") \ ^~~~~~~ input.c:835: #error note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN' YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:324: #error expected end of line before 'ignored' _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"") ^~~~~~~ input.c:835: #error note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN' YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:327: #error expected end of line before 'pop' _Pragma ("GCC diagnostic pop") ^~~~~~~ input.c:837: #error note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_END' YY_IGNORE_MAYBE_UNINITIALIZED_END ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:845: #error unknown type name 'YYSTYPE' input.c:875: #error unknown type name 'YYSTYPE' YYSTYPE yyvsa[YYINITDEPTH]; ^~~~~~~ input.c:876: #error unknown type name 'YYSTYPE' YYSTYPE *yyvs = yyvsa; ^~~~~~~ input.c:877: #error unknown type name 'YYSTYPE' YYSTYPE *yyvsp = yyvs; ^~~~~~~ input.c:886: #error unknown type name 'YYSTYPE' YYSTYPE yyval; ^~~~~~~ input.c:438: #error 'YYSTYPE' undeclared (first use in this function) ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ ^~~~~~~ input.c:75: #error note: in definition of macro 'YY_CAST' # define YY_CAST(Type, Val) ((Type) (Val)) ^~~ input.c:962: #error note: in expansion of macro 'YY_CAST' YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); ^~~~~~~ input.c:269: #error note: in expansion of macro 'YY_CAST' #define YYSIZEOF(X) YY_CAST (YYPTRDIFF_T, sizeof (X)) ^~~~~~~ input.c:438: #error note: in expansion of macro 'YYSIZEOF' ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ ^~~~~~~~ input.c:962: #error note: in expansion of macro 'YYSTACK_BYTES' YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); ^~~~~~~~~~~~~ input.c:438: #error note: each undeclared identifier is reported only once for each function it appears in ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ ^~~~~~~ input.c:75: #error note: in definition of macro 'YY_CAST' # define YY_CAST(Type, Val) ((Type) (Val)) ^~~ input.c:962: #error note: in expansion of macro 'YY_CAST' YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); ^~~~~~~ input.c:269: #error note: in expansion of macro 'YY_CAST' #define YYSIZEOF(X) YY_CAST (YYPTRDIFF_T, sizeof (X)) ^~~~~~~ input.c:438: #error note: in expansion of macro 'YYSIZEOF' ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ ^~~~~~~~ input.c:962: #error note: in expansion of macro 'YYSTACK_BYTES' YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); ^~~~~~~~~~~~~ input.c:1162: #error implicit declaration of function 'yydestruct' [-Wimplicit-function-declaration] yydestruct ("Error: discarding", ^~~~~~~~~~ ./synclines.at:255: grep '^input.y:1' stdout stderr: input.y: In function 'yyparse': input.y:8:2: error: #error "8" 8 | #error "8" | ^~~~~ stderr: stdout: ./synclines.at:291: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF 277. synclines.at:264: ok ./synclines.at:327: $CC $CFLAGS $CPPFLAGS -c syncline.c input.y:1: #error expected '{' before 'break' input.y:1: #error expected '{' before 'break' 276. synclines.at:237: ok ./synclines.at:310: $CC $CFLAGS $CPPFLAGS -c syncline.c stdout: stdout: ./conflicts.at:1096: $PREPARSER ./input stderr: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file input.y:8: #error "8" ./synclines.at:291: cat stdout stderr: syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:327: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF syntax error stderr: ./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 278. synclines.at:291: ok syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:310: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF stdout: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file syncline.c:4: #error "4" ./synclines.at:327: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 stdout: 236. conflicts.at:1096: ok syncline.c:4: #error "4" ./synclines.at:310: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./synclines.at:327: $CC $CFLAGS $CPPFLAGS -c input.c 282. synclines.at:370: testing %printer syncline ... ./synclines.at:370: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 283. synclines.at:440: testing syncline escapes: yacc.c ... ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 281. synclines.at:346: testing %destructor syncline ... ./synclines.at:346: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./synclines.at:310: $CC $CFLAGS $CPPFLAGS -c input.c ./synclines.at:440: $CC $CFLAGS $CPPFLAGS \"\\\"\".c -o \"\\\"\" || exit 77 stderr: input.y:2:2: error: #error "2" 2 | #error "2" | ^~~~~ ./synclines.at:327: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF stderr: 284. synclines.at:440: testing syncline escapes: glr.c ... input.y:8:2: error: #error "8" 8 | #error "8" | ^~~~~ ./synclines.at:310: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF stdout: input.y:8: #error "8" ./synclines.at:310: cat stdout stdout: input.y:2: #error "2" ./synclines.at:327: cat stdout ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./synclines.at:440: $CC $CFLAGS $CPPFLAGS \"\\\"\".c -o \"\\\"\" || exit 77 ./synclines.at:346: $CC $CFLAGS $CPPFLAGS -c syncline.c ./synclines.at:370: $CC $CFLAGS $CPPFLAGS -c syncline.c 279. synclines.at:310: ok 285. synclines.at:440: testing syncline escapes: lalr1.cc ... ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: 280. synclines.at:327: ok ./synclines.at:440: $CXX $CXXFLAGS $CPPFLAGS \"\\\"\".cc -o \"\\\"\" || exit 77 syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:346: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF stdout: stderr: syncline.c:4: #error "4" syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:346: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 ./synclines.at:370: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF ./synclines.at:346: $CC $CFLAGS $CPPFLAGS -c input.c stdout: syncline.c:4: #error "4" ./synclines.at:370: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stderr: stderr: input.y: In function 'yydestruct': input.y:2:2: error: #error "2" 2 | #error "2" | ^~~~~ ./synclines.at:346: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF stdout: ./synclines.at:370: $CC $CFLAGS $CPPFLAGS -c input.c stdout: input.y:2: #error "2" ./synclines.at:346: cat stdout ./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".c \"\\\"\".y stderr: 286. synclines.at:440: testing syncline escapes: glr.cc ... 287. synclines.at:440: testing syncline escapes: glr2.cc ... ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: stderr: ./synclines.at:440: $CXX $CXXFLAGS $CPPFLAGS \"\\\"\".cc -o \"\\\"\" || exit 77 input.y: In function 'yy_symbol_value_print': input.y:2:2: error: #error "2" 2 | #error "2" | ^~~~~ ./synclines.at:440: $CXX $CXXFLAGS $CPPFLAGS \"\\\"\".cc -o \"\\\"\" || exit 77 stdout: ./synclines.at:370: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF stdout: 281. synclines.at:346: ok ./conflicts.at:1096: $PREPARSER ./input stdout: input.y:2: #error "2" ./synclines.at:370: cat stdout ./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".c \"\\\"\".y stderr: syntax error ./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./synclines.at:440: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".c $LIBS 282. synclines.at:370: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: 235. conflicts.at:1096: ok 288. synclines.at:497: testing %no-lines: yacc.c ... stderr: stderr: stdout: ./synclines.at:440: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".c $LIBS stdout: ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.c -d input.y stdout: ./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".cc \"\\\"\".y ./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".cc \"\\\"\".y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".cc \"\\\"\".y 289. synclines.at:497: testing %no-lines: glr.c ... ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.c -d input.y ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./synclines.at:497: mv input.c without.c ./synclines.at:497: mv input.h without.h ./synclines.at:497: grep '#line' *.c *.h 290. synclines.at:497: testing %no-lines: lalr1.cc ... ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.cc -d input.y ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -d input.y ./synclines.at:440: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".cc $LIBS stderr: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stdout: ./synclines.at:440: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".cc $LIBS ./synclines.at:440: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".cc $LIBS 283. synclines.at:440: ok ./synclines.at:497: mv input.c without.c ./synclines.at:497: mv input.c with.c ./synclines.at:497: mv input.h with.h ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./synclines.at:497: mv input.h without.h ./synclines.at:497: mv input.cc without.cc ./synclines.at:497: grep -v '#line' with.c >expout ./synclines.at:497: grep '#line' *.c *.h ./synclines.at:497: mv input.hh without.hh ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -d input.y ./synclines.at:497: grep '#line' *.cc *.hh ./synclines.at:497: cat without.c ./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc -d input.y ./synclines.at:497: grep -v '#line' with.h >expout ./synclines.at:497: cat without.h ./synclines.at:497: mv input.c with.c 288. synclines.at:497: ok ./synclines.at:497: mv input.h with.h 291. synclines.at:497: testing %no-lines: glr.cc ... ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.cc -d input.y ./synclines.at:497: mv input.cc with.cc ./synclines.at:497: grep -v '#line' with.c >expout ./synclines.at:497: mv input.hh with.hh ./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file ./synclines.at:497: grep -v '#line' with.cc >expout ./synclines.at:497: cat without.c ./synclines.at:497: cat without.cc ./synclines.at:497: grep -v '#line' with.h >expout ./synclines.at:497: grep -v '#line' with.hh >expout ./synclines.at:497: mv input.cc without.cc ./synclines.at:497: cat without.h ./synclines.at:497: mv input.hh without.hh ./synclines.at:497: cat without.hh ./synclines.at:497: grep '#line' *.cc *.hh 292. synclines.at:497: testing %no-lines: glr2.cc ... ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.cc -d input.y 289. synclines.at:497: ok ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc -d input.y 290. synclines.at:497: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./synclines.at:497: mv input.cc with.cc ./synclines.at:497: mv input.hh with.hh ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./synclines.at:497: mv input.cc without.cc 293. synclines.at:507: testing Output columns ... ./synclines.at:540: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./synclines.at:497: grep -v '#line' with.cc >expout ./synclines.at:497: mv input.hh without.hh ./synclines.at:497: grep '#line' *.cc *.hh ./synclines.at:497: cat without.cc ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc -d input.y 294. headers.at:56: testing Invalid CPP guards: --defines=input/input.h ... ./synclines.at:497: grep -v '#line' with.hh >expout ./synclines.at:541: sed -ne '/--BEGIN/,/--END/{' \ -e '/input.c/s/ [0-9]* / LINE /;' \ -e 'p;}' \ input.c ./synclines.at:497: cat without.hh ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:56: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --defines=input/input.h --output=input/input.c input/input.y 291. synclines.at:497: ok ./synclines.at:497: mv input.cc with.cc ./synclines.at:497: mv input.hh with.hh 293. synclines.at:507: ok ./synclines.at:497: grep -v '#line' with.cc >expout ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./synclines.at:497: cat without.cc stderr: stdout: ./headers.at:56: $CC $CFLAGS $CPPFLAGS -c -o input/input.o -I. -c input/input.c ./synclines.at:497: grep -v '#line' with.hh >expout 284. synclines.at:440: ok ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./synclines.at:497: cat without.hh 295. headers.at:57: testing Invalid CPP guards: --defines=9foo.h ... 292. synclines.at:497: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 296. headers.at:58: testing Invalid CPP guards: %glr-parser --defines=input/input.h ... ./headers.at:57: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --defines=9foo.h --output=9foo.c 9foo.y ./headers.at:58: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --defines=input/input.h --output=input/input.c input/input.y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 297. headers.at:59: testing Invalid CPP guards: %glr-parser --defines=9foo.h ... stderr: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:57: $CC $CFLAGS $CPPFLAGS -c -o 9foo.o -I. -c 9foo.c stdout: ./headers.at:59: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --defines=9foo.h --output=9foo.c 9foo.y 298. headers.at:67: testing export YYLTYPE ... ./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --header -o input.c input.y 294. headers.at:56: ok ./headers.at:58: $CC $CFLAGS $CPPFLAGS -c -o input/input.o -I. -c input/input.c ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:59: $CC $CFLAGS $CPPFLAGS -c -o 9foo.o -I. -c 9foo.c ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header -o input.c input.y -Werror 299. headers.at:177: testing Sane headers: ... ./headers.at:177: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y stderr: stdout: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stderr: 295. headers.at:57: input.y:11.1-18: error: deprecated directive: '%name-prefix "my_"', use '%define api.prefix {my_}' [-Werror=deprecated] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:177: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./headers.at:85: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header -o input.c input.y --warnings=error ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 300. headers.at:178: testing Sane headers: %locations %debug ... ./headers.at:178: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y ./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header -o input.c input.y -Wnone,none -Werror --trace=none ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:178: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header -o input.c input.y --warnings=none -Werror --trace=none stderr: stdout: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:177: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:102: $CC $CFLAGS $CPPFLAGS -c -o caller.o caller.c stderr: stdout: 299. headers.at:177: ok stderr: stdout: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 296. headers.at:58: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: stderr: stdout: stderr: stdout: 286. synclines.at:440: ok stdout: ./headers.at:103: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c 301. headers.at:180: testing Sane headers: %glr-parser ... ./headers.at:180: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y ./conflicts.at:1096: $PREPARSER ./input stderr: syntax error ./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:180: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c 302. headers.at:181: testing Sane headers: %locations %debug %glr-parser ... ./headers.at:181: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y stderr: stdout: 237. conflicts.at:1096: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 297. headers.at:59: ok stderr: 303. headers.at:183: testing Sane headers: api.pure ... stdout: ./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file ./headers.at:181: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c 285. synclines.at:440: ok ./headers.at:183: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y ./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file ./headers.at:183: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c 304. headers.at:184: testing Sane headers: api.push-pull=both ... ./headers.at:184: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y 305. headers.at:185: testing Sane headers: api.pure api.push-pull=both ... ./headers.at:185: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y ./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file stderr: 306. headers.at:187: testing Sane headers: c++ ... stdout: ./headers.at:187: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.cc input.y ./headers.at:104: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o caller caller.o input.o $LIBS stderr: ./headers.at:184: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c stdout: ./headers.at:185: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file ./headers.at:178: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c ./headers.at:187: $CXX $CPPFLAGS $CXXFLAGS -c -o input.o input.cc stderr: stdout: ./headers.at:105: $PREPARSER ./caller stderr: stderr: ./headers.at:105: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 300. headers.at:178: ok 298. headers.at:67: ok stderr: stdout: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:183: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c stderr: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stderr: stdout: stdout: 308. headers.at:189: testing Sane headers: c++ api.value.type=variant parse.assert ... 303. headers.at:183: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ok 307. headers.at:188: testing Sane headers: %locations %debug c++ ... ./headers.at:189: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.cc input.y ./headers.at:188: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.cc input.y ./headers.at:184: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stderr: stdout: ./headers.at:189: $CXX $CPPFLAGS $CXXFLAGS -c -o input.o input.cc stderr: ./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o input.o input.cc stdout: 304. headers.at:184: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:185: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c 309. headers.at:191: testing Sane headers: %locations c++ %glr-parser ... ./headers.at:191: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.cc input.y stderr: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stdout: 305. headers.at:185: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:191: $CXX $CPPFLAGS $CXXFLAGS -c -o input.o input.cc 310. headers.at:199: testing Several parsers ... ./headers.at:320: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x1.c x1.y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 311. actions.at:24: testing Midrule actions ... ./actions.at:59: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -v -o input.c input.y ./headers.at:320: $CC $CFLAGS $CPPFLAGS -c -o x1.o x1.c ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stderr: ./actions.at:60: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stdout: ./headers.at:180: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stderr: stdout: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: stdout: ./headers.at:181: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c ./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file 301. headers.at:180: ok stderr: stdout: ./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file 302. headers.at:181: ok 312. actions.at:72: testing Typed midrule actions ... ./actions.at:109: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -v -o input.c input.y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: 313. actions.at:122: testing Implicitly empty rule ... stdout: ./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y stderr: ./actions.at:110: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: ./headers.at:320: echo "x1" >>expout 287. synclines.at:440: ok ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:321: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x2.c x2.y ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y -Werror stderr: stdout: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./actions.at:61: $PREPARSER ./input ./headers.at:321: $CC $CFLAGS $CPPFLAGS -c -o x2.o x2.c stderr: stderr: 1.y:11.17-18: error: empty rule without %empty [-Werror=empty-rule] 11 | a: /* empty. */ {}; | ^~ | %empty 1.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ./actions.at:61: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./actions.at:133: sed 's,.*/$,,' stderr 1>&2 314. actions.at:172: testing Invalid uses of %empty ... ./actions.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret one.y ./actions.at:192: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -u one.y 311. actions.at:24: ok ./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file ./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y --warnings=error ./actions.at:202: sed -e '1,8d' one.y ./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file ./actions.at:219: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret two.y ./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y -Wnone,none -Werror --trace=none ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 315. actions.at:240: testing Valid uses of %empty ... ./actions.at:259: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 314. actions.at:172: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: stdout: ./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y --warnings=none -Werror --trace=none ./headers.at:187: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc ./actions.at:259: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 316. actions.at:270: testing Add missing %empty ... ./actions.at:285: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --update -Wall input.y ./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret 2.y ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: input.y:3.4-5: warning: empty rule without %empty [-Wempty-rule] input.y:4.3-5.1: warning: empty rule without %empty [-Wempty-rule] input.y:6.3: warning: empty rule without %empty [-Wempty-rule] input.y:8.2: warning: empty rule without %empty [-Wempty-rule] input.y:9.3: warning: empty rule without %empty [-Wempty-rule] bison: file 'input.y' was updated (backup: 'input.y~') ./actions.at:286: cat input.y ./actions.at:300: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall input.y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret 2.y -Werror stderr: stdout: ./actions.at:111: $PREPARSER ./input stderr: ./actions.at:111: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: stdout: ./headers.at:189: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc 312. actions.at:72: ok 316. actions.at:270: ok ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stderr: 2.y:11.17-18: error: empty rule without %empty [-Werror=empty-rule] 11 | a: /* empty. */ {}; | ^~ | %empty 2.y:13.17-18: error: empty rule without %empty [-Werror=empty-rule] 13 | c: /* empty. */ {}; | ^~ | %empty 2.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./actions.at:149: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 318. actions.at:366: testing Initial location: yacc.c api.pure=full ... ./actions.at:366: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 317. actions.at:365: testing Initial location: yacc.c ... ./actions.at:365: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret 2.y --warnings=error ./actions.at:365: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret 2.y -Wnone,none -Werror --trace=none ./actions.at:366: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: stderr: ./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret 2.y --warnings=none -Werror --trace=none stdout: ./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:321: echo "x2" >>expout ./headers.at:322: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x3.c x3.y stderr: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stdout: ./actions.at:260: $PREPARSER ./input stderr: ./actions.at:161: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wno-empty-rule 2.y ./actions.at:260: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 315. actions.at:240: ok stderr: stdout: stderr: stdout: ./headers.at:322: $CC $CFLAGS $CPPFLAGS -c -o x3.o x3.c ./actions.at:365: $PREPARSER ./input stderr: 1.1 1.1: syntax error ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./actions.at:365: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 313. actions.at:122: ok ./headers.at:187: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc stderr: 319. actions.at:367: testing Initial location: yacc.c api.pure %parse-param { int x } ... ./actions.at:367: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stderr: stdout: 317. actions.at:365: ok stdout: stderr: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./actions.at:366: $PREPARSER ./input stdout: stderr: ./actions.at:367: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 1.1 1.1: syntax error ./actions.at:366: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 306. headers.at:187: ok ./headers.at:189: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc 318. actions.at:366: ok stderr: stdout: 308. headers.at:189: ok ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 320. actions.at:368: testing Initial location: yacc.c api.push-pull=both ... ./actions.at:368: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 321. actions.at:369: testing Initial location: yacc.c api.push-pull=both api.pure=full ... ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./actions.at:368: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 322. actions.at:370: testing Initial location: glr.c ... ./actions.at:370: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:369: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 323. actions.at:371: testing Initial location: glr.c api.pure ... 258. conflicts.at:2331: ok ./actions.at:369: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:371: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:370: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 324. actions.at:372: testing Initial location: lalr1.cc ... ./actions.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:371: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 325. actions.at:373: testing Initial location: glr.cc ... ./actions.at:373: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:372: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./actions.at:367: $PREPARSER ./input stderr: 1.1 1.1: syntax error ./actions.at:367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 319. actions.at:367: ok ./actions.at:373: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc stderr: 326. actions.at:374: testing Initial location: glr2.cc ... ./actions.at:374: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stdout: ./actions.at:369: $PREPARSER ./input stderr: 1.1 1.1: syntax error ./actions.at:369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: 321. actions.at:369: ok ./actions.at:368: $PREPARSER ./input ./actions.at:374: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: 1.1 1.1: syntax error ./actions.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: 320. actions.at:368: ok ./headers.at:191: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc stdout: ./headers.at:322: echo "x3" >>expout 327. actions.at:383: testing Initial location: yacc.c api.pure=full ... ./actions.at:383: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./headers.at:323: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x4.c x4.y ./actions.at:383: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 328. actions.at:394: testing Initial location: yacc.c api.pure=full ... ./actions.at:394: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./headers.at:323: $CC $CFLAGS $CPPFLAGS -c -o x4.o x4.c ./actions.at:394: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc stderr: stdout: ./actions.at:371: $PREPARSER ./input stderr: 1.1 1.1: syntax error ./actions.at:371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./actions.at:383: $PREPARSER ./input stderr: : syntax error ./actions.at:383: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 323. actions.at:371: ok stderr: stdout: ./actions.at:370: $PREPARSER ./input stderr: 1.1 1.1: syntax error ./actions.at:370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 327. actions.at:383: ok 322. actions.at:370: ok 329. actions.at:478: testing Location print: yacc.c ... ./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: ./actions.at:394: $PREPARSER ./input stderr: ./actions.at:478: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 0 0: syntax error ./actions.at:394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 330. actions.at:478: testing Location print: glr.c ... ./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: ./headers.at:191: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc 328. actions.at:394: ok ./actions.at:478: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 331. actions.at:478: testing Location print: lalr1.cc ... ./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:478: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 332. actions.at:478: testing Location print: glr.cc ... ./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc ./actions.at:478: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stderr: stdout: stdout: ./actions.at:478: $PREPARSER ./input 307. headers.at:188: ok stderr: stderr: stdout: ./actions.at:372: $PREPARSER ./input ./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1 1.1: syntax error ./actions.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 324. actions.at:372: ok stdout: 329. actions.at:478: ok ./actions.at:373: $PREPARSER ./input stderr: 1.1 1.1: syntax error ./actions.at:373: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 333. actions.at:478: testing Location print: glr2.cc ... ./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 325. actions.at:373: ok 334. actions.at:488: testing Exotic Dollars ... ./actions.at:532: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -v -o input.c input.y 335. actions.at:1047: testing Printers and Destructors ... ./actions.at:1047: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:478: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./actions.at:533: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 336. actions.at:1048: testing Printers and Destructors with union ... ./actions.at:1048: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1047: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./headers.at:191: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc ./actions.at:1048: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./headers.at:323: echo "x4" >>expout ./headers.at:324: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x5.cc x5.y stderr: stdout: ./actions.at:478: $PREPARSER ./input stderr: ./headers.at:324: $CXX $CPPFLAGS $CXXFLAGS -c -o x5.o x5.cc ./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./actions.at:534: $PREPARSER ./input 330. actions.at:478: ok stderr: stderr: stdout: ./actions.at:1047: $PREPARSER ./input '(x)' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:534: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1047: $PREPARSER ./input '!' stderr: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1047: $PREPARSER ./input '!!!' stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:562: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 337. actions.at:1050: testing Printers and Destructors: %glr-parser ... ./actions.at:1047: $PREPARSER ./input '(y)' stderr: sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1050: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1047: $PREPARSER ./input '(xxxxx)(x)(x)y' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:562: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1047: $PREPARSER ./input '(x)(x)x' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1050: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./actions.at:1047: $PREPARSER ./input '(x)(x)(x)(x)(x)(x)(x)' ./actions.at:1048: $PREPARSER ./input '(x)' stderr: stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: '(' (6@60-69) sending: 'x' (7@70-79) thing (7@70-79): 'x' (7@70-79) sending: ')' (8@80-89) line (6@60-89): '(' (6@60-69) thing (7@70-79) ')' (8@80-89) sending: '(' (9@90-99) sending: 'x' (10@100-109) thing (10@100-109): 'x' (10@100-109) sending: ')' (11@110-119) line (9@90-119): '(' (9@90-99) thing (10@100-109) ')' (11@110-119) sending: '(' (12@120-129) sending: 'x' (13@130-139) thing (13@130-139): 'x' (13@130-139) sending: ')' (14@140-149) line (12@120-149): '(' (12@120-129) thing (13@130-139) ')' (14@140-149) sending: '(' (15@150-159) sending: 'x' (16@160-169) thing (16@160-169): 'x' (16@160-169) sending: ')' (17@170-179) line (15@150-179): '(' (15@150-159) thing (16@160-169) ')' (17@170-179) sending: '(' (18@180-189) sending: 'x' (19@190-199) thing (19@190-199): 'x' (19@190-199) sending: ')' (20@200-209) 200.200-209.208: memory exhausted Freeing nterm thing (19@190-199) Freeing nterm line (15@150-179) Freeing nterm line (12@120-149) Freeing nterm line (9@90-119) Freeing nterm line (6@60-89) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Parsing FAILED (status 2). ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1048: $PREPARSER ./input '!' 335. actions.at:1047: ok stderr: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 338. actions.at:1051: testing Printers and Destructors with union: %glr-parser ... ./actions.at:1051: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1048: $PREPARSER ./input '!!!' stderr: stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token J [-Wcounterexamples] time limit exceeded: 6.000000 First example: H i . J K $end Shift derivation $accept `-> 0: a $end `-> 2: H i `-> 4: i . J K Second example: H i . J $end Reduce derivation $accept `-> 0: s $end `-> 1: a J `-> 2: H i . input.y:4.4-6: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:451: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1048: $PREPARSER ./input '(y)' stderr: stderr: ./counterexample.at:451: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stderr: ./actions.at:563: $PREPARSER ./input stderr: stdout: ./actions.at:1051: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:563: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:478: $PREPARSER ./input stderr: ./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 334. actions.at:488: ok ./actions.at:1048: $PREPARSER ./input '(xxxxx)(x)(x)y' 331. actions.at:478: ok stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./actions.at:1048: $PREPARSER ./input '(x)(x)x' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 309. headers.at:191: ok 339. actions.at:1053: testing Printers and Destructors: %header lalr1.cc ... ./actions.at:1053: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:1048: $PREPARSER ./input '(x)(x)(x)(x)(x)(x)(x)' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: '(' (6@60-69) sending: 'x' (7@70-79) thing (7@70-79): 'x' (7@70-79) sending: ')' (8@80-89) line (6@60-89): '(' (6@60-69) thing (7@70-79) ')' (8@80-89) sending: '(' (9@90-99) sending: 'x' (10@100-109) thing (10@100-109): 'x' (10@100-109) sending: ')' (11@110-119) line (9@90-119): '(' (9@90-99) thing (10@100-109) ')' (11@110-119) sending: '(' (12@120-129) sending: 'x' (13@130-139) thing (13@130-139): 'x' (13@130-139) sending: ')' (14@140-149) line (12@120-149): '(' (12@120-129) thing (13@130-139) ')' (14@140-149) sending: '(' (15@150-159) sending: 'x' (16@160-169) thing (16@160-169): 'x' (16@160-169) sending: ')' (17@170-179) line (15@150-179): '(' (15@150-159) thing (16@160-169) ')' (17@170-179) sending: '(' (18@180-189) sending: 'x' (19@190-199) thing (19@190-199): 'x' (19@190-199) sending: ')' (20@200-209) 200.200-209.208: memory exhausted Freeing nterm thing (19@190-199) Freeing nterm line (15@150-179) Freeing nterm line (12@120-149) Freeing nterm line (9@90-119) Freeing nterm line (6@60-89) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Parsing FAILED (status 2). ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 336. actions.at:1048: ok 340. actions.at:1054: testing Printers and Destructors with union: %header lalr1.cc ... stderr: ./actions.at:1054: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stdout: ./actions.at:478: $PREPARSER ./input stderr: ./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1053: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 332. actions.at:478: ok 341. actions.at:1056: testing Printers and Destructors: %header glr.cc ... ./actions.at:1056: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:1054: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 342. actions.at:1057: testing Printers and Destructors with union: %header glr.cc ... ./actions.at:1057: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:1056: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 343. actions.at:1059: testing Printers and Destructors: %header glr2.cc ... ./actions.at:1059: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:1057: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./actions.at:1059: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./headers.at:324: echo "x5" >>expout ./headers.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x6.c x6.y stderr: stdout: ./actions.at:374: $PREPARSER ./input stderr: 1.1 1.1: syntax error ./actions.at:374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./actions.at:1050: $PREPARSER ./input '(x)' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 326. actions.at:374: ok ./headers.at:325: $CC $CFLAGS $CPPFLAGS -c -o x6.o x6.c ./actions.at:1050: $PREPARSER ./input '!' stderr: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1050: $PREPARSER ./input '!!!' stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 344. actions.at:1060: testing Printers and Destructors with union: %header glr2.cc ... ./actions.at:1060: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:1050: $PREPARSER ./input '(y)' stderr: sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1050: $PREPARSER ./input '(xxxxx)(x)(x)y' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./headers.at:325: echo "x6" >>expout ./headers.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x7.c x7.y ./actions.at:1050: $PREPARSER ./input '(x)(x)x' ./actions.at:1060: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./headers.at:326: $CC $CFLAGS $CPPFLAGS -c -o x7.o x7.c 337. actions.at:1050: ok stderr: stdout: ./actions.at:1051: $PREPARSER ./input '(x)' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1051: $PREPARSER ./input '!' stderr: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 345. actions.at:1071: testing Default tagless %printer and %destructor ... ./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1051: $PREPARSER ./input '!!!' stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1051: $PREPARSER ./input '(y)' stderr: sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./headers.at:326: echo "x7" >>expout ./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror ./actions.at:1051: $PREPARSER ./input '(xxxxx)(x)(x)y' ./headers.at:327: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x8.c x8.y stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./headers.at:327: $CC $CFLAGS $CPPFLAGS -c -o x8.o x8.c ./actions.at:1051: $PREPARSER ./input '(x)(x)x' stderr: input.y:30.3-5: error: useless %destructor for type <*> [-Werror=other] input.y:30.3-5: error: useless %printer for type <*> [-Werror=other] stderr: stderr: stdout: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1053: $PREPARSER ./input '(x)' stderr: ./actions.at:1116: sed 's,.*/$,,' stderr 1>&2 sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error ./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1053: $PREPARSER ./input '!' stderr: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 338. actions.at:1051: ok ./actions.at:1053: $PREPARSER ./input '!!!' stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none stderr: stdout: ./actions.at:1053: $PREPARSER ./input '(y)' ./actions.at:478: $PREPARSER ./input stderr: stderr: sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1053: $PREPARSER ./input '(xxxxx)(x)(x)y' stderr: stdout: ./actions.at:1054: $PREPARSER ./input '(x)' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 333. actions.at:478: ok ./actions.at:1053: $PREPARSER ./input '(x)(x)x' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 346. actions.at:1174: testing Default tagged and per-type %printer and %destructor ... ./actions.at:1054: $PREPARSER ./input '!' 339. actions.at:1053: ok ./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stderr: stdout: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./headers.at:327: echo "x8" >>expout ./actions.at:1120: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./headers.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x9.cc x9.y ./actions.at:1054: $PREPARSER ./input '!!!' stderr: stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. stdout: ./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1054: $PREPARSER ./input '(y)' ./actions.at:1057: $PREPARSER ./input '(x)' stderr: sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 348. actions.at:1429: testing Default %printer and %destructor are not for error or $undefined ... stderr: ./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 347. actions.at:1307: testing Default %printer and %destructor for user-defined end token ... ./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input0.c input0.y ./actions.at:1054: $PREPARSER ./input '(xxxxx)(x)(x)y' ./headers.at:328: $CXX $CPPFLAGS $CXXFLAGS -c -o x9.o x9.cc stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror ./actions.at:1057: $PREPARSER ./input '!' ./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror stderr: ./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input0.c input0.y -Werror sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1054: $PREPARSER ./input '(x)(x)x' stderr: input.y:22.3-4: error: useless %destructor for type <> [-Werror=other] input.y:22.3-4: error: useless %printer for type <> [-Werror=other] stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input0.y:30.3-5: error: useless %destructor for type <*> [-Werror=other] input0.y:30.3-5: error: useless %printer for type <*> [-Werror=other] ./actions.at:1057: $PREPARSER ./input '!!!' ./actions.at:1233: sed 's,.*/$,,' stderr 1>&2 stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1416: sed 's,.*/$,,' stderr 1>&2 340. actions.at:1054: ok ./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input0.c input0.y --warnings=error stderr: ./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error input.y:23.6-8: error: useless %destructor for type <*> [-Werror=other] input.y:23.6-8: error: useless %printer for type <*> [-Werror=other] ./actions.at:1057: $PREPARSER ./input '(y)' stderr: ./actions.at:1474: sed 's,.*/$,,' stderr 1>&2 sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none ./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error ./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input0.c input0.y -Wnone,none -Werror --trace=none ./actions.at:1057: $PREPARSER ./input '(xxxxx)(x)(x)y' 349. actions.at:1532: testing Default %printer and %destructor are not for $accept ... ./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input0.c input0.y --warnings=none -Werror --trace=none ./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none ./actions.at:1416: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input0 input0.c $LIBS ./actions.at:1057: $PREPARSER ./input '(x)(x)x' ./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror ./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1237: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input.y:24.3-4: error: useless %destructor for type <> [-Werror=other] input.y:24.3-4: error: useless %printer for type <> [-Werror=other] stderr: 342. actions.at:1057: ok stdout: ./actions.at:1582: sed 's,.*/$,,' stderr 1>&2 ./actions.at:1121: $PREPARSER ./input --debug ./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none ./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token 'a' (1.1: <> printer for 'a' @ 1) Shifting token 'a' (1.1: <> printer for 'a' @ 1) Entering state 1 Stack now 0 1 Reading a token Next token is token 'b' (1.2: 'b'/'c' printer for 'b' @ 2) Shifting token 'b' (1.2: 'b'/'c' printer for 'b' @ 2) Entering state 3 Stack now 0 1 3 Reading a token Next token is token 'c' (1.3: 'b'/'c' printer for 'c' @ 3) Shifting token 'c' (1.3: 'b'/'c' printer for 'c' @ 3) Entering state 5 Stack now 0 1 3 5 Reading a token Next token is token 'd' (1.4: <> printer for 'd' @ 4) Shifting token 'd' (1.4: <> printer for 'd' @ 4) Entering state 6 Stack now 0 1 3 5 6 Reading a token Now at end of input. 1.5: syntax error, unexpected end of file, expecting 'e' Error: popping token 'd' (1.4: <> printer for 'd' @ 4) Stack now 0 1 3 5 Error: popping token 'c' (1.3: 'b'/'c' printer for 'c' @ 3) Stack now 0 1 3 Error: popping token 'b' (1.2: 'b'/'c' printer for 'b' @ 2) Stack now 0 1 Error: popping token 'a' (1.1: <> printer for 'a' @ 1) Stack now 0 Cleanup: discarding lookahead token "end of file" (1.5: ) Stack now 0 ./actions.at:1121: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 345. actions.at:1071: ok ./actions.at:1478: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none stdout: ./actions.at:1056: $PREPARSER ./input '(x)' stderr: 350. actions.at:1596: testing Default %printer and %destructor for midrule values ... ./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 351. actions.at:1743: testing @$ in %initial-action implies %locations ... ./actions.at:1743: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none ./actions.at:1056: $PREPARSER ./input '!' stderr: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1743: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror ./actions.at:1586: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./actions.at:1416: $PREPARSER ./input0 --debug ./actions.at:1056: $PREPARSER ./input '!!!' stderr: Starting parse Entering state 0 Stack now 0 Reducing stack by rule 1 (line 49): -> $$ = nterm start (1.1: <> for 'S' @ 1) Entering state 1 Stack now 0 1 Reading a token Now at end of input. Shifting token END (1.1: <> for 'E' @ 1) Entering state 2 Stack now 0 1 2 Stack now 0 1 2 Cleanup: popping token END (1.1: <> for 'E' @ 1) Cleanup: popping nterm start (1.1: <> for 'S' @ 1) ./actions.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input.y:24.57-59: error: useless %destructor for type <*> [-Werror=other] input.y:24.57-59: error: useless %printer for type <*> [-Werror=other] input.y:33.3-23: error: unset value: $$ [-Werror=other] input.y:32.3-23: error: unused value: $3 [-Werror=other] ./actions.at:1056: $PREPARSER ./input '(y)' ./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input1.c input1.y stderr: stderr: sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./actions.at:1634: sed 's,.*/$,,' stderr 1>&2 ./actions.at:1238: $PREPARSER ./input --debug stderr: ./actions.at:1056: $PREPARSER ./input '(xxxxx)(x)(x)y' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token 'a' (<*>//e printer) Shifting token 'a' (<*>//e printer) Entering state 1 Stack now 0 1 Reading a token Next token is token 'b' ( printer) Shifting token 'b' ( printer) Entering state 3 Stack now 0 1 3 Reading a token Next token is token 'c' ('c' printer) Shifting token 'c' ('c' printer) Entering state 5 Stack now 0 1 3 5 Reading a token Next token is token 'd' ('d' printer) Shifting token 'd' ('d' printer) Entering state 6 Stack now 0 1 3 5 6 Reading a token Next token is token 'e' (<*>//e printer) Shifting token 'e' (<*>//e printer) Entering state 7 Stack now 0 1 3 5 6 7 Reading a token Next token is token 'f' (<*>//e printer) Shifting token 'f' (<*>//e printer) Entering state 8 Stack now 0 1 3 5 6 7 8 Reading a token Now at end of input. syntax error, unexpected end of file, expecting 'g' Error: popping token 'f' (<*>//e printer) Stack now 0 1 3 5 6 7 Error: popping token 'e' (<*>//e printer) Stack now 0 1 3 5 6 Error: popping token 'd' ('d' printer) Stack now 0 1 3 5 Error: popping token 'c' ('c' printer) Stack now 0 1 3 Error: popping token 'b' ( printer) Stack now 0 1 Error: popping token 'a' (<*>//e printer) Stack now 0 Cleanup: discarding lookahead token "end of file" () Stack now 0 stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1056: $PREPARSER ./input '(x)(x)x' ./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1238: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none stderr: stdout: ./actions.at:1479: $PREPARSER ./input --debug stderr: 341. actions.at:1056: ok Starting parse Entering state 0 Stack now 0 Reading a token Next token is token 'a' ('a') Shifting token 'a' ('a') Entering state 1 Stack now 0 1 Reading a token Next token is token 'b' ('b') syntax error Shifting token error () Entering state 3 Stack now 0 1 3 Next token is token 'b' ('b') Shifting token 'b' ('b') Entering state 5 Stack now 0 1 3 5 Reading a token Next token is token "invalid token" () Error: popping token 'b' ('b') DESTROY 'b' Stack now 0 1 3 Error: popping token error () Stack now 0 1 Shifting token error () Entering state 3 Stack now 0 1 3 Next token is token "invalid token" () Error: discarding token "invalid token" () Error: popping token error () Stack now 0 1 Shifting token error () Entering state 3 Stack now 0 1 3 Reading a token Now at end of input. Cleanup: discarding lookahead token "end of file" () Stack now 0 1 3 Cleanup: popping token error () Cleanup: popping token 'a' ('a') DESTROY 'a' ./actions.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 346. actions.at:1174: ok ./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input1.c input1.y -Werror ./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none 348. actions.at:1429: ok stderr: input1.y:30.3-4: error: useless %destructor for type <> [-Werror=other] input1.y:30.3-4: error: useless %printer for type <> [-Werror=other] ./actions.at:1417: sed 's,.*/$,,' stderr 1>&2 ./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o input.c input.y stderr: stderr: stdout: 351. actions.at:1743: ok stdout: 352. actions.at:1744: testing @$ in %destructor implies %locations ... ./actions.at:1744: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input1.c input1.y --warnings=error 349. actions.at:1532: ok 353. actions.at:1745: testing @$ in %printer implies %locations ... ./actions.at:1745: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1744: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 354. actions.at:1856: testing Qualified $$ in actions: yacc.c ... ./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Werror ./actions.at:1745: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1856: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input1.c input1.y -Wnone,none -Werror --trace=none 355. actions.at:1856: testing Qualified $$ in actions: glr.c ... 356. actions.at:1856: testing Qualified $$ in actions: lalr1.cc ... ./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: input.y:24.57-59: error: useless %destructor for type <*> [-Werror=other] 24 | %printer { #error "<*> printer should not be used" } <*> | ^~~ input.y:24.57-59: error: useless %printer for type <*> [-Werror=other] 24 | %printer { #error "<*> printer should not be used" } <*> | ^~~ input.y:33.3-23: error: unset value: $$ [-Werror=other] 33 | { @$ = 4; } // Only used. | ^~~~~~~~~~~~~~~~~~~~~ input.y:32.3-23: error: unused value: $3 [-Werror=other] 32 | { USE ($$); @$ = 3; } // Only set. | ^~~~~~~~~~~~~~~~~~~~~ ./actions.at:1641: sed 's,.*/$,,' stderr 1>&2 ./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input1.c input1.y --warnings=none -Werror --trace=none ./actions.at:1856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=error ./actions.at:1856: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./headers.at:328: echo "x9" >>expout ./actions.at:1417: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input1 input1.c $LIBS ./headers.at:329: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o xa.cc xa.y ./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Wnone,none -Werror --trace=none stderr: stdout: ./headers.at:329: $CXX $CPPFLAGS $CXXFLAGS -c -o xa.o xa.cc stderr: stdout: 352. actions.at:1744: ok ./actions.at:1856: $PREPARSER ./input --debug stderr: ./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=none -Werror --trace=none Starting parse Entering state 0 Stack now 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Stack now 0 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Stack now 0 1 3 Reducing stack by rule 1 (line 53): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Stack now 0 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Stack now 0 2 4 Stack now 0 2 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Stack now 0 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Stack now 0 1 3 Reducing stack by rule 1 (line 53): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Stack now 0 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Stack now 0 2 4 Stack now 0 2 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed -ne '/ival:/p' stderr stdout: 353. actions.at:1745: ok 354. actions.at:1856: ok 357. actions.at:1856: testing Qualified $$ in actions: glr.cc ... ./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:1656: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 358. actions.at:1856: testing Qualified $$ in actions: glr2.cc ... ./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 359. actions.at:1863: testing Destroying lookahead assigned by semantic action ... ./actions.at:1905: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1856: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./actions.at:1906: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./actions.at:1417: $PREPARSER ./input1 --debug stderr: Starting parse Entering state 0 Stack now 0 Reducing stack by rule 1 (line 49): -> $$ = nterm start (1.1: <*> for 'S' @ 1) Entering state 1 Stack now 0 1 Reading a token Now at end of input. Shifting token END (1.1: <*> for 'E' @ 1) Entering state 2 Stack now 0 1 2 Stack now 0 1 2 Cleanup: popping token END (1.1: <*> for 'E' @ 1) Cleanup: popping nterm start (1.1: <*> for 'S' @ 1) ./actions.at:1417: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 347. actions.at:1307: ok stderr: stdout: ./actions.at:1907: $PREPARSER ./input stderr: 'b' destructor 'a' destructor ./actions.at:1907: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 359. actions.at:1863: ok 360. actions.at:1918: testing YYBACKUP ... ./actions.at:1953: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: ./actions.at:1657: $PREPARSER ./input --debug stderr: Starting parse Entering state 0 Stack now 0 Reducing stack by rule 1 (line 30): -> $$ = nterm $@1 (: ) Entering state 2 Stack now 0 2 Reducing stack by rule 2 (line 31): -> $$ = nterm @2 (: 2) Entering state 4 Stack now 0 2 4 Reducing stack by rule 3 (line 32): -> $$ = nterm @3 (: 3) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 4 (line 33): -> $$ = nterm @4 (: 4) Entering state 6 Stack now 0 2 4 5 6 Reading a token Now at end of input. syntax error Error: popping nterm @4 (: 4) DESTROY 4 Stack now 0 2 4 5 Error: popping nterm @3 (: 3) DESTROY 3 Stack now 0 2 4 Error: popping nterm @2 (: 2) DESTROY 2 Stack now 0 2 Error: popping nterm $@1 (: ) Stack now 0 Cleanup: discarding lookahead token "end of file" (: ) Stack now 0 ./actions.at:1954: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1657: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 350. actions.at:1596: ok 361. types.at:25: testing %union vs. api.value.type ... ./types.at:34: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 361. types.at:25: ok 362. types.at:44: testing %yacc vs. api.value.type=union ... ./types.at:53: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 363. types.at:139: testing yacc.c api.value.type={double} ... 362. types.at:44: ok ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: stdout: ./actions.at:1856: $PREPARSER ./input --debug 364. types.at:139: testing yacc.c api.value.type={double} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: Starting parse Entering state 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Reducing stack 0 by rule 1 (line 53): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Reducing stack 0 by rule 1 (line 53): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed -ne '/ival:/p' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 355. actions.at:1856: ok 365. types.at:139: testing yacc.c api.value.type={variant} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: stdout: stderr: stdout: ./actions.at:1955: $PREPARSER ./input stderr: ./types.at:139: $PREPARSER ./test stderr: ./actions.at:1955: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./headers.at:329: echo "xa" >>expout 360. actions.at:1918: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ok ./headers.at:330: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o xb.cc xb.y 363. types.at:139: ok stderr: stdout: ./actions.at:1856: $PREPARSER ./input --debug 366. types.at:139: testing yacc.c api.value.type={variant} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Stack now 0 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Stack now 0 1 3 Reducing stack by rule 1 (line 55): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Stack now 0 2 Reading a token Next token is token "end of file" () Shifting token "end of file" () Entering state 4 Stack now 0 2 4 Stack now 0 2 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./headers.at:330: $CXX $CPPFLAGS $CXXFLAGS -c -o xb.o xb.cc Starting parse Entering state 0 Stack now 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Stack now 0 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Stack now 0 1 3 Reducing stack by rule 1 (line 55): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Stack now 0 2 Reading a token Next token is token "end of file" () Shifting token "end of file" () Entering state 4 Stack now 0 2 4 Stack now 0 2 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed -ne '/ival:/p' stderr 367. types.at:139: testing yacc.c api.value.type={struct foo} ... stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y 356. actions.at:1856: ok stdout: ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./actions.at:1059: $PREPARSER ./input '(x)' ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: 364. types.at:139: ok sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1059: $PREPARSER ./input '!' stderr: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1059: $PREPARSER ./input '!!!' stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 368. types.at:139: testing yacc.c api.value.type={struct foo} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./actions.at:1059: $PREPARSER ./input '(y)' stderr: sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./actions.at:1059: $PREPARSER ./input '(xxxxx)(x)(x)y' ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: 369. types.at:139: testing yacc.c api.value.type={struct bar} ... sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: ./actions.at:1059: $PREPARSER ./input '(x)(x)x' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 343. actions.at:1059: ok ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 365. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 371. types.at:139: testing yacc.c api.value.type={union foo} ... ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y 370. types.at:139: testing yacc.c api.value.type={struct bar} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: 367. types.at:139: ok stdout: ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 366. types.at:139: ok 372. types.at:139: testing yacc.c api.value.type={union foo} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: stdout: ./actions.at:1856: $PREPARSER ./input --debug stderr: Starting parse Entering state 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Reducing stack 0 by rule 1 (line 55): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Reducing stack 0 by rule 1 (line 55): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed -ne '/ival:/p' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: 357. actions.at:1856: ok stdout: ./types.at:139: $PREPARSER ./test stderr: 373. types.at:139: testing yacc.c %union { float fval; int ival; }; ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 374. types.at:139: testing yacc.c %union { float fval; int ival; }; %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: stdout: 368. types.at:139: ok ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 369. types.at:139: ok ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 375. types.at:139: testing yacc.c %union foo { float fval; int ival; }; ... ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: 376. types.at:139: testing yacc.c %union foo { float fval; int ival; }; %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stdout: 371. types.at:139: ok ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 370. types.at:139: ok 377. types.at:139: testing yacc.c api.value.union.name=foo; %union { float fval; int ival; }; ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 372. types.at:139: ok ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: 378. types.at:139: testing yacc.c api.value.union.name=foo; %union { float fval; int ival; }; %header ... stdout: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $PREPARSER ./test stderr: stderr: stderr: stdout: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1060: $PREPARSER ./input '(x)' ./types.at:139: $PREPARSER ./test stderr: 373. types.at:139: ok sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./actions.at:1060: $PREPARSER ./input '!' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. 374. types.at:139: ok ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 379. types.at:139: testing yacc.c api.value.type=union ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./actions.at:1060: $PREPARSER ./input '!!!' stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./actions.at:1060: $PREPARSER ./input '(y)' stderr: sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test ./actions.at:1060: $PREPARSER ./input '(xxxxx)(x)(x)y' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./actions.at:1060: $PREPARSER ./input '(x)(x)x' stderr: 380. types.at:139: testing yacc.c api.value.type=union %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 381. types.at:139: testing glr.c api.value.type={double} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stdout: 375. types.at:139: ok ./types.at:139: $PREPARSER ./test stderr: 344. actions.at:1060: ok stderr: stdout: ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./headers.at:330: echo "xb" >>expout ./headers.at:331: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o xc.cc xc.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 376. types.at:139: ok 382. types.at:139: testing glr.c api.value.type={double} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./headers.at:331: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS -c -o xc.o xc.cc 383. types.at:139: testing glr.c api.value.type={variant} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 384. types.at:139: testing glr.c api.value.type={variant} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 377. types.at:139: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 378. types.at:139: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ok 385. types.at:139: testing glr.c api.value.type={struct foo} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: stdout: 379. types.at:139: ok 386. types.at:139: testing glr.c api.value.type={struct foo} %header ... ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 380. types.at:139: ok ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 387. types.at:139: testing glr.c api.value.type={struct bar} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: stdout: ./actions.at:1856: $PREPARSER ./input --debug stderr: Starting parse Entering state 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Reducing stack 0 by rule 1 (line 55): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 388. types.at:139: testing glr.c api.value.type={struct bar} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: Starting parse Entering state 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Reducing stack 0 by rule 1 (line 55): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed -ne '/ival:/p' stderr 358. actions.at:1856: ok ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 389. types.at:139: testing glr.c api.value.type={union foo} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 381. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 382. types.at:139: ok 390. types.at:139: testing glr.c api.value.type={union foo} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 391. types.at:139: testing glr.c %union { float fval; int ival; }; ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stdout: 383. types.at:139: ok ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 384. types.at:139: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 385. types.at:139: ok 392. types.at:139: testing glr.c %union { float fval; int ival; }; %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: 393. types.at:139: testing glr.c %union foo { float fval; int ival; }; ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stdout: ./types.at:139: $PREPARSER ./test stderr: 394. types.at:139: testing glr.c %union foo { float fval; int ival; }; %header ... ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 386. types.at:139: ok stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token J [-Wcounterexamples] time limit exceeded: 6.000000 First example H i . J K $end Shift derivation $accept -> [ a -> [ H i -> [ i . J K ] ] $end ] Second example H i . J $end Reduce derivation $accept -> [ s -> [ a -> [ H i . ] J ] $end ] input.y:4.4-6: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:451: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr 267. counterexample.at:441: ok ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 387. types.at:139: ok 396. types.at:139: testing glr.c api.value.union.name=foo; %union { float fval; int ival; }; %header ... 395. types.at:139: testing glr.c api.value.union.name=foo; %union { float fval; int ival; }; ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: 397. types.at:139: testing glr.c api.value.type=union ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stdout: ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 388. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 389. types.at:139: ok 398. types.at:139: testing glr.c api.value.type=union %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test 390. types.at:139: ok 399. types.at:139: testing lalr1.cc api.value.type={double} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 391. types.at:139: ok 400. types.at:139: testing lalr1.cc api.value.type={double} %header ... ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 401. types.at:139: testing lalr1.cc api.value.type={variant} ... stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 392. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 393. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 402. types.at:139: testing lalr1.cc api.value.type={variant} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 403. types.at:139: testing lalr1.cc api.value.type={struct foo} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 394. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 404. types.at:139: testing lalr1.cc api.value.type={struct foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 397. types.at:139: ok stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: 396. types.at:139: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 395. types.at:139: ok 405. types.at:139: testing lalr1.cc api.value.type={struct bar} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 406. types.at:139: testing lalr1.cc api.value.type={struct bar} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: 407. types.at:139: testing lalr1.cc api.value.type={union foo} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./headers.at:331: echo "xc" >>expout ./headers.at:332: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o xd.cc xd.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test ./headers.at:332: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS -c -o xd.o xd.cc stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 398. types.at:139: ok 408. types.at:139: testing lalr1.cc api.value.type={union foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./headers.at:332: echo "xd" >>expout ./headers.at:342: "$PERL" -n -0777 -e ' # Ignore comments. s{/\*.*?\*/}{}gs; s{//.*}{}g; # Ignore warnings. s{# *pragma .* message ".*"}{}g; s{\b((defined|if)\ YYDEBUG |YYChar # Template parameter. |YYNTOKENS # This is actually scoped in a C++ class. |YYPUSH_MORE(?:_DEFINED)? |S_(YY(ACCEPT|EMPTY|EOF|error|UNDEF)) # These guys are scoped. |YY(?:_REINTERPRET)?_CAST |YY_ATTRIBUTE(?:_PURE|_UNUSED) |YY_CONSTEXPR |YY_COPY |YY_CPLUSPLUS |YY_IGNORE_(?:MAYBE_UNINITIALIZED|USELESS_CAST)_(?:BEGIN|END) |YY_INITIAL_VALUE |YY_MOVE |YY_MOVE_OR_COPY |YY_MOVE_REF |YY_NOEXCEPT |YY_NOTHROW |YY_NULLPTR |YY_RVREF |YY_USE |YY_\w+_INCLUDED # Header guards. |FILE\ \*yyo # Function argument. |const\ yylocp # Function argument. )\b}{}gx; while (/^(.*YY.*)$/gm) { print "$ARGV: invalid exported YY: $1\n"; } if ($ARGV =~ /\.h$/) { while (/^(.*yy.*)$/gm) { print "$ARGV: invalid exported yy: $1\n"; } } ' -- *.hh *.h ./headers.at:387: $CC $CFLAGS $CPPFLAGS -c -o c-only.o c-only.c stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./headers.at:387: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx-only.o cxx-only.cc ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test ./headers.at:387: $CXX $CXXFLAGS $CPPFLAGS $LDFLAGS c-only.o cxx-only.o -o c-and-cxx || exit 77 stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./headers.at:387: $PREPARSER ./c-and-cxx stderr: ./headers.at:387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./headers.at:392: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o parser x[1-9a-d].o -DCC_IS_CXX=$CC_IS_CXX main.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: stdout: ./headers.at:394: $PREPARSER ./parser stderr: ./headers.at:394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 310. headers.at:199: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 409. types.at:139: testing lalr1.cc %union { float fval; int ival; }; ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: 6 reduce/reduce conflicts [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] First example: . c A A $end First reduce derivation $accept `-> 0: a $end `-> 1: b d `-> 3: %empty . `-> 6: c A A Second example: . c A A $end Second reduce derivation $accept `-> 0: a $end `-> 2: c d `-> 4: %empty . `-> 6: c A A input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] time limit exceeded: 6.000000 First example: b . c A A $end First reduce derivation $accept `-> 0: a $end `-> 1: b d `-> 5: a `-> 1: b d `-> 3: %empty . `-> 6: c A A Second example: b . A $end Second reduce derivation $accept `-> 0: a $end `-> 1: b d `-> 6: c A `-> 4: %empty . input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] time limit exceeded: 6.000000 First example: c . c A A $end First reduce derivation $accept `-> 0: a $end `-> 2: c d `-> 5: a `-> 1: b d `-> 3: %empty . `-> 6: c A A Second example: c . A $end Second reduce derivation $accept `-> 0: a $end `-> 2: c d `-> 6: c A `-> 4: %empty . input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] time limit exceeded: 6.000000 First example: b c . A Shift derivation a `-> 1: b d `-> 6: c . A Second example: b c . c A A $end Reduce derivation $accept `-> 0: a $end `-> 1: b d `-> 5: a `-> 2: c d `-> 5: a `-> 1: b d `-> 3: %empty . `-> 6: c A A input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] First example: b c . c A A $end First reduce derivation $accept `-> 0: a $end `-> 1: b d `-> 5: a `-> 2: c d `-> 5: a `-> 1: b d `-> 3: %empty . `-> 6: c A A Second example: b c . A $end Second reduce derivation $accept `-> 0: a $end `-> 1: b d `-> 5: a `-> 2: c d `-> 6: c A `-> 4: %empty . input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] First example: b c . A Shift derivation a `-> 1: b d `-> 6: c . A Second example: b c . A $end Reduce derivation $accept `-> 0: a $end `-> 1: b d `-> 5: a `-> 2: c d `-> 6: c A `-> 4: %empty . input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] Example: b d . First reduce derivation a `-> 1: b d . Second reduce derivation a `-> 1: b d `-> 7: d . input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] Example: c d . First reduce derivation a `-> 2: c d . Second reduce derivation a `-> 2: c d `-> 7: d . input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] input.y:6.15: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:621: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./counterexample.at:621: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 405. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 401. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 410. types.at:139: testing lalr1.cc %union { float fval; int ival; }; %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 403. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 411. types.at:139: testing lalr1.cc api.value.type=union ... 412. types.at:139: testing lalr1.cc api.value.type=union %header ... ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test 399. types.at:139: ok stderr: 404. types.at:139: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 402. types.at:139: ok 413. types.at:139: testing lalr1.cc api.value.type=variant ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 414. types.at:139: testing lalr1.cc api.value.type=variant %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 415. types.at:139: testing lalr1.cc api.value.type=variant ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 400. types.at:139: ok 416. types.at:139: testing lalr1.cc api.value.type=variant %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 406. types.at:139: ok 417. types.at:139: testing lalr1.cc api.value.type=variant api.token.constructor ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 408. types.at:139: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 418. types.at:139: testing lalr1.cc api.value.type=variant api.token.constructor %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 407. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 419. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 409. types.at:139: ok stderr: stderr: stdout: stdout: 420. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant %header ... ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++11 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $PREPARSER ./test stdout: ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stderr: stdout: stdout: ./types.at:139: ./check ./types.at:139: $PREPARSER ./test -std=c++11 not supported ======== Testing with C++ standard flags: '' stderr: stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 411. types.at:139: ok ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 421. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant api.token.constructor ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 412. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 422. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant api.token.constructor %header ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 410. types.at:139: ok stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 423. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant api.token.constructor ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 417. types.at:139: ok stderr: 424. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant api.token.constructor %header ... ======== Testing with C++ standard flags: '' stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 413. types.at:139: ok stderr: stdout: ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 425. types.at:139: testing glr.cc api.value.type={double} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 418. types.at:139: ok ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: ./types.at:139: ./check ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 419. types.at:139: ok 426. types.at:139: testing glr.cc api.value.type={double} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 414. types.at:139: ok 427. types.at:139: testing glr.cc api.value.type={variant} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check -std=c++11 not supported ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 428. types.at:139: testing glr.cc api.value.type={variant} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: ./check ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++11 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++11 not supported ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 420. types.at:139: ok stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: ./check 429. types.at:139: testing glr.cc api.value.type={struct foo} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++11 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 415. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 430. types.at:139: testing glr.cc api.value.type={struct foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' 416. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test 431. types.at:139: testing glr.cc api.value.type={struct bar} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: ./check ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $PREPARSER ./test stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: 6 reduce/reduce conflicts [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] First example . c A A $end First reduce derivation $accept -> [ a -> [ b -> [ . ] d -> [ c A A ] ] $end ] Second example . c A A $end Second reduce derivation $accept -> [ a -> [ c -> [ . ] d -> [ c A A ] ] $end ] input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] time limit exceeded: 6.000000 First example b . c A A $end First reduce derivation $accept -> [ a -> [ b d -> [ a -> [ b -> [ . ] d -> [ c A A ] ] ] ] $end ] Second example b . A $end Second reduce derivation $accept -> [ a -> [ b d -> [ c -> [ . ] A ] ] $end ] input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] time limit exceeded: 6.000000 First example c . c A A $end First reduce derivation $accept -> [ a -> [ c d -> [ a -> [ b -> [ . ] d -> [ c A A ] ] ] ] $end ] Second example c . A $end Second reduce derivation $accept -> [ a -> [ c d -> [ c -> [ . ] A ] ] $end ] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] time limit exceeded: 6.000000 First example b c . A Shift derivation a -> [ b d -> [ c . A ] ] Second example b c . c A A $end Reduce derivation $accept -> [ a -> [ b d -> [ a -> [ c d -> [ a -> [ b -> [ . ] d -> [ c A A ] ] ] ] ] ] $end ] input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] First example b c . c A A $end First reduce derivation $accept -> [ a -> [ b d -> [ a -> [ c d -> [ a -> [ b -> [ . ] d -> [ c A A ] ] ] ] ] ] $end ] Second example b c . A $end Second reduce derivation $accept -> [ a -> [ b d -> [ a -> [ c d -> [ c -> [ . ] A ] ] ] ] $end ] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] First example b c . A Shift derivation a -> [ b d -> [ c . A ] ] Second example b c . A $end Reduce derivation $accept -> [ a -> [ b d -> [ a -> [ c d -> [ c -> [ . ] A ] ] ] ] $end ] input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] Example b d . First reduce derivation a -> [ b d . ] Second reduce derivation a -> [ b d -> [ d . ] ] input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] Example c d . First reduce derivation a -> [ c d . ] Second reduce derivation a -> [ c d -> [ d . ] ] input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] input.y:6.15: warning: rule useless in parser due to conflicts [-Wother] ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./counterexample.at:621: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' 270. counterexample.at:610: ok ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 432. types.at:139: testing glr.cc api.value.type={struct bar} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 421. types.at:139: ok stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 433. types.at:139: testing glr.cc api.value.type={union foo} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 422. types.at:139: ok 434. types.at:139: testing glr.cc api.value.type={union foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stdout: stderr: stderr: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 423. types.at:139: ok ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 435. types.at:139: testing glr.cc %union { float fval; int ival; }; ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 424. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 436. types.at:139: testing glr.cc %union { float fval; int ival; }; %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 426. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 427. types.at:139: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test 437. types.at:139: testing glr.cc api.value.type=union ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 438. types.at:139: testing glr.cc api.value.type=union %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 425. types.at:139: ok 439. types.at:139: testing glr2.cc api.value.type={double} ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 429. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 428. types.at:139: ok 440. types.at:139: testing glr2.cc api.value.type={double} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 441. types.at:139: testing glr2.cc api.value.type={variant} ... ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 430. types.at:139: ok stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: 442. types.at:139: testing glr2.cc api.value.type={variant} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: ./check stderr: -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 431. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 443. types.at:139: testing glr2.cc api.value.type={struct foo} ... ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: ./check stdout: ./types.at:139: ./check ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' stderr: stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: stderr: ./types.at:139: ./check ./types.at:139: $PREPARSER ./test stdout: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: stdout: stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: ./check ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 432. types.at:139: ok 444. types.at:139: testing glr2.cc api.value.type={struct foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 433. types.at:139: ok stdout: ./types.at:139: ./check stderr: stdout: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 445. types.at:139: testing glr2.cc api.value.type={struct bar} ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 434. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: 446. types.at:139: testing glr2.cc api.value.type={struct bar} %header ... ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 435. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 447. types.at:139: testing glr2.cc api.value.type={union foo} ... ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: 436. types.at:139: stderr: ok stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 448. types.at:139: testing glr2.cc api.value.type={union foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 437. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 449. types.at:139: testing glr2.cc %union { float fval; int ival; }; ... stdout: ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: ./check ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check stderr: -std=c++03 not supported ======== Testing with C++ standard flags: '' stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' 438. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 450. types.at:139: testing glr2.cc %union { float fval; int ival; }; %header ... ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: ./check ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stderr: stdout: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: ./check ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: ./check ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 439. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 451. types.at:139: testing glr2.cc api.value.type=union ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: ./check ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 440. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: ./check ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 452. types.at:139: testing glr2.cc api.value.type=union %header ... ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 441. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 453. types.at:377: testing lalr1.cc: Named %union ... ./types.at:377: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 453. types.at:377: ok 454. types.at:377: testing glr.cc: Named %union ... ./types.at:377: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 454. types.at:377: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 455. scanner.at:326: testing Token numbers: yacc.c ... ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./scanner.at:326: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' stderr: stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.c ./types.at:139: $PREPARSER ./test stderr: ./scanner.at:326: $PREPARSER ./input ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stdout: ======== Testing with C++ standard flags: '' ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: 455. scanner.at:326: stderr: ok stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: ./check ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 456. scanner.at:326: testing Token numbers: yacc.c api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./scanner.at:326: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.c ./scanner.at:326: $PREPARSER ./input stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 456. scanner.at:326: ok 442. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 457. scanner.at:326: testing Token numbers: glr.c ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ======== Testing with C++ standard flags: '' 458. scanner.at:326: testing Token numbers: glr.c api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./scanner.at:326: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./scanner.at:326: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: ./check stderr: -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 443. types.at:139: ok stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' 459. scanner.at:326: testing Token numbers: lalr1.cc ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./scanner.at:326: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.c ./scanner.at:326: $PREPARSER ./input stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 458. scanner.at:326: ok stderr: stdout: stderr: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.c stdout: ./types.at:139: $PREPARSER ./test ./scanner.at:326: $PREPARSER ./input stderr: stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' 457. scanner.at:326: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: 460. scanner.at:326: testing Token numbers: lalr1.cc api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./types.at:139: $PREPARSER ./test stderr: ./scanner.at:326: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: ./check ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 461. scanner.at:326: testing Token numbers: glr.cc ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./scanner.at:326: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc ./scanner.at:326: $PREPARSER ./input stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 459. scanner.at:326: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 462. scanner.at:326: testing Token numbers: glr.cc api.token.raw ... ======== Testing with C++ standard flags: '' ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./scanner.at:326: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc ./scanner.at:326: $PREPARSER ./input ======== Testing with C++ standard flags: '' stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 460. scanner.at:326: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 463. scanner.at:326: testing Token numbers: glr2.cc ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: stderr: stdout: ./types.at:139: ./check ./types.at:139: $PREPARSER ./test ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./scanner.at:326: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc ./scanner.at:326: $PREPARSER ./input ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 461. scanner.at:326: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 464. scanner.at:326: testing Token numbers: glr2.cc api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./scanner.at:326: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc ./scanner.at:326: $PREPARSER ./input stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 462. scanner.at:326: ok 465. scanner.at:326: testing Token numbers: lalr1.d ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.d input.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 465. scanner.at:326: skipped (scanner.at:326) stderr: stderr: stdout: stdout: 466. scanner.at:326: testing Token numbers: lalr1.d api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.d input.y ./types.at:139: $PREPARSER ./test ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 444. types.at:139: ok 466. scanner.at:326: skipped (scanner.at:326) ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 467. scanner.at:326: testing Token numbers: lalr1.java ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.java input.y 468. scanner.at:326: testing Token numbers: lalr1.java api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.java input.y 467. scanner.at:326: skipped (scanner.at:326) 468. scanner.at:326: skipped (scanner.at:326) 469. scanner.at:330: testing Token numbers: lalr1.cc api.token.raw api.value.type=variant api.token.constructor ... ./scanner.at:330: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 470. calc.at:1334: testing Calculator parse.trace ... ./calc.at:1334: mv calc.y.tmp calc.y ./calc.at:1334: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./scanner.at:330: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./calc.at:1334: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: stdout: ./calc.at:1334: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./calc.at:1334: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1334: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 7) Shifting token "number" (1.1: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 7) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 7) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: -3) -> $$ = nterm exp (1.1: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: -6) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 5) Shifting token "number" (1.1: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 5) -> $$ = nterm exp (1.1: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 5) -> $$ = nterm exp (1.1: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -5) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -5) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -5) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: -1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: -1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 4) Shifting token "number" (1.1: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 4) -> $$ = nterm exp (1.1: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 4) -> $$ = nterm exp (1.1: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -4) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -4) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -4) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 2) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 8) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 256) Shifting token "number" (1.1: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 256) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 256) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 4) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 4) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 64) Shifting token "number" (1.1: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 64) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 64) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 7) Shifting token "number" (1.1: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 7) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 7) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: -3) -> $$ = nterm exp (1.1: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: -6) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 5) Shifting token "number" (1.1: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 5) -> $$ = nterm exp (1.1: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 5) -> $$ = nterm exp (1.1: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -5) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -5) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -5) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: -1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: -1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 4) Shifting token "number" (1.1: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 4) -> $$ = nterm exp (1.1: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 4) -> $$ = nterm exp (1.1: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -4) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -4) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -4) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 2) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 8) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 256) Shifting token "number" (1.1: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 256) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 256) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 4) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 4) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 64) Shifting token "number" (1.1: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 64) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 64) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: stdout: input: | 1 2 ./calc.at:1334: $PREPARSER ./calc input ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.1: 2) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.1: 2) Stack now 0 ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./calc.at:1334: cat stderr stderr: input: stdout: ./types.at:139: $PREPARSER ./test | 1//2 ./calc.at:1334: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.1: ) syntax error Error: popping token '/' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.1: ) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.1: ) syntax error Error: popping token '/' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.1: ) Stack now 0 ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 445. types.at:139: ok ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./calc.at:1334: cat stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS input: 471. calc.at:1336: testing Calculator %header ... ./calc.at:1336: mv calc.y.tmp calc.y | error ./calc.at:1334: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1336: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: stdout: stderr: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 ./calc.at:1336: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./calc.at:1334: cat stderr input: | 1 = 2 = 3 ./calc.at:1334: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.1: ) syntax error Error: popping nterm exp (1.1: 2) Stack now 0 8 19 Error: popping token '=' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.1: ) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.1: ) syntax error Error: popping nterm exp (1.1: 2) Stack now 0 8 19 Error: popping token '=' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.1: ) Stack now 0 ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1334: cat stderr input: | | +1 ./calc.at:1334: $PREPARSER ./calc input stderr: stderr: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc ./scanner.at:326: $PREPARSER ./input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (1.1: ) syntax error Error: popping nterm input (1.1: ) Stack now 0 Cleanup: discarding lookahead token '+' (1.1: ) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 464. scanner.at:326: ok stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (1.1: ) syntax error Error: popping nterm input (1.1: ) Stack now 0 Cleanup: discarding lookahead token '+' (1.1: ) Stack now 0 stdout: ./calc.at:1336: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' 472. calc.at:1337: testing Calculator %debug %locations ... ./calc.at:1337: mv calc.y.tmp calc.y ./calc.at:1337: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1334: cat stderr ./calc.at:1336: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1334: $PREPARSER ./calc /dev/null stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1336: $PREPARSER ./calc input ./calc.at:1337: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1336: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: | 1 2 ./calc.at:1336: $PREPARSER ./calc input ./calc.at:1334: cat stderr stderr: stderr: syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc input: stderr: syntax error stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stdout: ./calc.at:1334: $PREPARSER ./calc input ./scanner.at:326: $PREPARSER ./input stderr: ./scanner.at:330: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc stderr: ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.1: ) syntax error Error: popping token '+' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 3) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 1) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.1: ) syntax error Error: popping token '*' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 2) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 3333) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 4444) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 4444 != 1 -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 4444) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1336: cat stderr stderr: 463. scanner.at:326: ok ./scanner.at:330: $PREPARSER ./input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.1: ) syntax error Error: popping token '+' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 3) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 1) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.1: ) syntax error Error: popping token '*' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 2) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 3333) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 4444) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 4444 != 1 -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 4444) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: input: | 1//2 ./calc.at:1336: $PREPARSER ./calc input ./scanner.at:330: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 469. scanner.at:330: ok syntax error 473. calc.at:1338: testing Calculator %locations api.location.type={Span} ... ./calc.at:1338: mv calc.y.tmp calc.y ./calc.at:1338: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1334: cat stderr input: ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1338: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1334: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 121): $1 = token '!' (1.1: ) $2 = token '!' (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: ./calc.at:1336: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 121): $1 = token '!' (1.1: ) $2 = token '!' (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./types.at:139: $PREPARSER ./test stderr: input: | error ./calc.at:1336: $PREPARSER ./calc input ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 446. types.at:139: ok 474. calc.at:1340: testing Calculator %name-prefix "calc" ... ./calc.at:1340: mv calc.y.tmp calc.y stderr: ./calc.at:1340: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: stdout: ./calc.at:1337: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error ./calc.at:1337: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1334: cat stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1337: $PREPARSER ./calc input ./calc.at:1336: cat stderr stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 123): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 123): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1334: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 120): $1 = token '-' (1.1: ) $2 = token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 475. calc.at:1341: testing Calculator %verbose ... ./calc.at:1340: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: ./calc.at:1341: mv calc.y.tmp calc.y Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 123): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 123): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: ./calc.at:1337: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 120): $1 = token '-' (1.1: ) $2 = token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | 1 = 2 = 3 ./calc.at:1336: $PREPARSER ./calc input stderr: input: syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 ./calc.at:1337: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1341: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 syntax error ./calc.at:1334: cat stderr ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1337: cat stderr input: ./calc.at:1336: cat stderr | 1//2 ./calc.at:1337: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (* *) + (*) + (*) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1334: $PREPARSER ./calc input stderr: input: | | +1 ./calc.at:1336: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 3333) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error stderr: stdout: ./calc.at:1337: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 3333) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: | error ./calc.at:1338: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1337: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1338: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1337: cat stderr input: input: | 1 = 2 = 3 ./calc.at:1337: $PREPARSER ./calc input ./calc.at:1336: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1336: $PREPARSER ./calc /dev/null | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1338: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 stderr: stdout: syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: ./calc.at:1334: cat stderr syntax error ./types.at:139: $PREPARSER ./test ./calc.at:1340: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !+ ++ ./calc.at:1334: $PREPARSER ./calc input ./calc.at:1337: cat stderr 449. types.at:139: ok ./calc.at:1340: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c stderr: stderr: ./calc.at:1338: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 122): $1 = token '!' (1.1: ) $2 = token '+' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) input: ./calc.at:1340: $PREPARSER ./calc input ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1336: cat stderr ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | | +1 ./calc.at:1337: $PREPARSER ./calc input | 1 2 ./calc.at:1338: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1336: $PREPARSER ./calc input stderr: stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.3: syntax error stderr: stderr: ./calc.at:1340: $EGREP -c -v 'Return for a new token:|LAC:' stderr syntax error syntax error syntax error syntax error error: 4444 != 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 122): $1 = token '!' (1.1: ) $2 = token '+' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1334: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1337: cat stderr ./calc.at:1337: $PREPARSER ./calc /dev/null ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | 1 2 ./calc.at:1340: $PREPARSER ./calc input stderr: syntax error Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1336: cat stderr 476. calc.at:1342: testing Calculator %yacc ... ./calc.at:1342: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi ./calc.at:1342: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | 1 + 2 * 3 + !- ++ ./calc.at:1334: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 123): $1 = token '!' (1.1: ) $2 = token '-' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) syntax error ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stdout: ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (!!) + (1 2) = 1 ./calc.at:1336: $PREPARSER ./calc input ./calc.at:1341: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: ./calc.at:1338: cat stderr syntax error error: 2222 != 1 ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1341: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c stderr: syntax error error: 2222 != 1 ./calc.at:1337: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 123): $1 = token '!' (1.1: ) $2 = token '-' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1337: $PREPARSER ./calc input ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: | 1//2 ./calc.at:1341: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1340: cat stderr ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1338: $PREPARSER ./calc input ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1342: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS 1.3: syntax error input: | 1 2 ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1337: cat stderr syntax error stderr: | 1//2 ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error ./calc.at:1340: $PREPARSER ./calc input stderr: stderr: syntax error ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error input: ./calc.at:1336: cat stderr stderr: | (!!) + (1 2) = 1 input: ./calc.at:1337: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 128): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1334: cat stderr ./calc.at:1336: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 128): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) syntax error syntax error error: 2222 != 1 ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: syntax error | 1 + 2 * 3 + !* ++ stderr: ./calc.at:1334: $PREPARSER ./calc input syntax error syntax error error: 2222 != 1 ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 124): $1 = token '!' (1.1: ) $2 = token '*' (1.1: ) memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1340: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 124): $1 = token '!' (1.1: ) $2 = token '*' (1.1: ) memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1338: cat stderr input: | error ./calc.at:1340: $PREPARSER ./calc input stderr: syntax error ./calc.at:1341: cat stderr ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: cat stderr ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error input: | error ./calc.at:1336: cat stderr ./calc.at:1338: $PREPARSER ./calc input input: stderr: 1.1: syntax error ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1337: $PREPARSER ./calc input stderr: ./calc.at:1334: cat stderr 1.1: syntax error stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 127): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: input: ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 | (* *) + (*) + (*) ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1336: $PREPARSER ./calc input ./calc.at:1341: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 127): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) syntax error syntax error syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1338: cat stderr stderr: syntax error syntax error syntax error ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: syntax error ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1334: $PREPARSER ./calc input stderr: stderr: syntax error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2222) Shifting token "number" (1.1: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1337: cat stderr stderr: ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2222) Shifting token "number" (1.1: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: | 1 = 2 = 3 stderr: stdout: ./calc.at:1338: $PREPARSER ./calc input ./types.at:139: $PREPARSER ./test stderr: input: stderr: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.7: syntax error | (* *) + (*) + (*) ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: $PREPARSER ./calc input ./calc.at:1336: cat stderr stderr: 1.7: syntax error stderr: ./calc.at:1340: cat stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 = 2 = 3 input: ./calc.at:1340: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1341: cat stderr ./calc.at:1336: $PREPARSER ./calc input 447. types.at:139: ok stderr: stderr: ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | error stderr: ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1338: cat stderr syntax error stderr: syntax error ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1336: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: input: syntax error ./calc.at:1334: cat stderr ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1338: $PREPARSER ./calc input stderr: 2.1: syntax error input: ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1340: cat stderr input: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (1 + #) = 1111 | 1 + 2 * 3 + !- ++ stdout: stderr: ./calc.at:1336: $PREPARSER ./calc input ./calc.at:1337: cat stderr ./calc.at:1334: $PREPARSER ./calc input 2.1: syntax error ./types.at:139: $PREPARSER ./test input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1337: $PREPARSER ./calc input | | +1 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1340: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 129): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 129): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1337: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1341: cat stderr stderr: ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error input: 477. calc.at:1343: testing Calculator parse.error=detailed ... input: ./calc.at:1343: mv calc.y.tmp calc.y | 1 + 2 * 3 + !- ++ ./calc.at:1337: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1343: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ======== Testing with C++ standard flags: '' ./calc.at:1334: cat stderr stderr: ./calc.at:1338: cat stderr stderr: ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 130): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1338: $PREPARSER ./calc /dev/null input: ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: | (# + 1) = 1111 syntax error ./calc.at:1334: $PREPARSER ./calc input 1.1: syntax error ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 130): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) 1.1: syntax error stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1336: cat stderr stderr: ./calc.at:1340: cat stderr ./calc.at:1341: cat stderr ./calc.at:1340: $PREPARSER ./calc /dev/null input: | 1 + 2 * 3 + !* ++ stdout: ./calc.at:1336: $PREPARSER ./calc input stderr: ./calc.at:1342: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: syntax error memory exhausted input: ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1343: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1342: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1338: cat stderr memory exhausted | | +1 input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 input: ./calc.at:1342: $PREPARSER ./calc input ./calc.at:1341: $PREPARSER ./calc input stderr: syntax error ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1338: $PREPARSER ./calc input syntax error stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1336: cat stderr ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1334: cat stderr stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 stderr: ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error stderr: ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1342: $EGREP -c -v 'Return for a new token:|LAC:' stderr | (#) + (#) = 2222 ./calc.at:1337: cat stderr ./calc.at:1336: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1341: cat stderr input: stderr: input: input: | 1 2 syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1342: $PREPARSER ./calc input ./calc.at:1341: $PREPARSER ./calc /dev/null stderr: | (1 + # + 1) = 1111 stderr: stderr: ./calc.at:1338: cat stderr stdout: | 1 + 2 * 3 + !* ++ ./calc.at:1337: $PREPARSER ./calc input syntax error syntax error ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: ./check ./calc.at:1334: $PREPARSER ./calc input ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 131): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 131): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) syntax error | (!!) + (1 2) = 1 stderr: ./calc.at:1338: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1340: cat stderr ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1340: $PREPARSER ./calc input ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1341: cat stderr ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1342: cat stderr syntax error syntax error syntax error syntax error error: 4444 != 1 input: ./calc.at:1336: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1337: cat stderr stderr: ./calc.at:1338: cat stderr input: ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 stderr: ./calc.at:1342: $PREPARSER ./calc input syntax error syntax error syntax error syntax error error: 4444 != 1 input: stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS syntax error syntax error syntax error syntax error error: 4444 != 1 | (1 + #) = 1111 syntax error ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1336: $PREPARSER ./calc input input: ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1337: $PREPARSER ./calc input stderr: stderr: syntax error | (- *) + (1 2) = 1 ./calc.at:1338: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.8: ) Error: discarding token "invalid token" (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 syntax error: invalid character: '#' syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.8: ) Error: discarding token "invalid token" (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 stderr: ./calc.at:1334: cat stderr ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1340: cat stderr syntax error: invalid character: '#' ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1340: $PREPARSER ./calc input ./calc.at:1337: cat stderr stderr: input: ./calc.at:1342: cat stderr syntax error error: 2222 != 1 ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + #) = 1111 ./calc.at:1337: $PREPARSER ./calc input stderr: ./calc.at:1338: cat stderr syntax error error: 2222 != 1 | (1 + 1) / (1 - 1) stderr: ./calc.at:1334: $PREPARSER ./calc input input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1342: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 2) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 0) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 10 (line 101): $1 = nterm exp (1.1: 2) $2 = token '/' (1.1: ) $3 = nterm exp (1.1: 0) error: null divisor -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) syntax error input: ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) ./calc.at:1338: $PREPARSER ./calc input ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1341: cat stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1337: cat stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 2) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 0) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 10 (line 101): $1 = nterm exp (1.1: 2) $2 = token '/' (1.1: ) $3 = nterm exp (1.1: 0) error: null divisor -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1340: cat stderr ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1336: cat stderr | (!!) + (1 2) = 1 ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (# + 1) = 1111 stderr: ./calc.at:1337: $PREPARSER ./calc input syntax error error: 2222 != 1 stderr: ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1342: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1338: cat stderr stderr: syntax error error: 2222 != 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (- *) + (1 2) = 1 ./calc.at:1340: $PREPARSER ./calc input stderr: input: ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: syntax error syntax error error: 2222 != 1 input: | (# + 1) = 1111 ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1338: $PREPARSER ./calc input ./calc.at:1336: $PREPARSER ./calc input ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 stderr: ./calc.at:1342: $PREPARSER ./calc input stderr: stderr: syntax error: invalid character: '#' ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error error: 2222 != 1 syntax error ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1337: cat stderr ./calc.at:1338: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: ./calc.at:1334: cat stderr stderr: syntax error syntax error: invalid character: '#' input: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + # + 1) = 1111 ./calc.at:1337: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ ./calc.at:1338: $PREPARSER ./calc input stderr: stderr: ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 470. calc.at:1334: ok stderr: ./calc.at:1341: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: ./types.at:139: $PREPARSER ./test ./calc.at:1342: cat stderr stderr: ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: | (- *) + (1 2) = 1 ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1337: cat stderr ./calc.at:1340: cat stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: syntax error syntax error error: 2222 != 1 | | +1 ./calc.at:1342: $PREPARSER ./calc input input: 448. types.at:139: ok ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1340: $PREPARSER ./calc input input: stderr: stderr: | (1 + 1) / (1 - 1) ./calc.at:1337: $PREPARSER ./calc input syntax error syntax error error: 2222 != 1 stderr: syntax error syntax error syntax error stderr: ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 108): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 108): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: syntax error 478. calc.at:1344: testing Calculator parse.error=verbose ... ./calc.at:1344: mv calc.y.tmp calc.y ./calc.at:1336: cat stderr ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1344: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y syntax error syntax error syntax error ./calc.at:1338: cat stderr input: | (1 + # + 1) = 1111 ./calc.at:1336: $PREPARSER ./calc input ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: 479. calc.at:1346: testing Calculator api.pure=full %locations ... ./calc.at:1341: cat stderr syntax error: invalid character: '#' | 1 + 2 * 3 + !* ++ ./calc.at:1346: mv calc.y.tmp calc.y ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1338: $PREPARSER ./calc input ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1346: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y 1.14: memory exhausted ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error: invalid character: '#' ./calc.at:1340: cat stderr stdout: ./calc.at:1343: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: 1.14: memory exhausted ./calc.at:1337: cat stderr input: | (* *) + (*) + (*) ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1342: cat stderr stderr: syntax error syntax error syntax error | 1 + 2 * 3 + !+ ++ ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 472. calc.at:1337: ok ./calc.at:1340: $PREPARSER ./calc input ./calc.at:1342: $PREPARSER ./calc /dev/null stderr: stderr: ./calc.at:1343: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c syntax error syntax error syntax error ./calc.at:1344: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1338: cat stderr input: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1343: $PREPARSER ./calc input stderr: ./calc.at:1340: $EGREP -c -v 'Return for a new token:|LAC:' stderr syntax error input: stderr: | (#) + (#) = 2222 ./calc.at:1338: $PREPARSER ./calc input ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1336: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1346: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1341: cat stderr input: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1343: $EGREP -c -v 'Return for a new token:|LAC:' stderr | 1 + 2 * 3 + !- ++ ./calc.at:1340: $PREPARSER ./calc input ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (1 + 1) / (1 - 1) ./calc.at:1336: $PREPARSER ./calc input input: 480. calc.at:1347: testing Calculator api.push-pull=both api.pure=full %locations ... ./calc.at:1347: mv calc.y.tmp calc.y ./calc.at:1338: cat stderr ./calc.at:1342: cat stderr stderr: error: null divisor ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1341: $PREPARSER ./calc input stderr: | 1 2 error: null divisor input: ./calc.at:1343: $PREPARSER ./calc input ./calc.at:1347: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | (1 + #) = 1111 stderr: ./calc.at:1338: $PREPARSER ./calc input syntax error, unexpected number ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 1.6: syntax error: invalid character: '#' ./calc.at:1342: $PREPARSER ./calc input stderr: ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected number stderr: ./calc.at:1340: cat stderr ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' stderr: stderr: ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error syntax error syntax error syntax error error: 4444 != 1 input: | 1 + 2 * 3 + !* ++ ./calc.at:1341: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1340: $PREPARSER ./calc input ./calc.at:1343: cat stderr stderr: memory exhausted ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: memory exhausted input: | 1//2 ./calc.at:1343: $PREPARSER ./calc input stderr: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1336: cat stderr ./calc.at:1338: cat stderr input: stderr: ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !- ++ input: ./calc.at:1341: $PREPARSER ./calc input | (# + 1) = 1111 ./calc.at:1342: cat stderr ./calc.at:1338: $PREPARSER ./calc input syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1347: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: 471. calc.at:1336: ok stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1340: cat stderr ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 ./calc.at:1342: $PREPARSER ./calc input stderr: stderr: input: stderr: 1.2: syntax error: invalid character: '#' | (#) + (#) = 2222 ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1340: $PREPARSER ./calc input syntax error error: 2222 != 1 ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1343: cat stderr stderr: stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' syntax error error: 2222 != 1 ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | error ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: $PREPARSER ./calc input ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error, unexpected invalid token ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1338: cat stderr ./calc.at:1340: cat stderr stderr: syntax error, unexpected invalid token ./calc.at:1342: cat stderr input: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 ./calc.at:1340: $PREPARSER ./calc input stderr: input: input: syntax error: invalid character: '#' ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 | (1 + # + 1) = 1111 ./calc.at:1342: $PREPARSER ./calc input ./calc.at:1338: $PREPARSER ./calc input stderr: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error error: 2222 != 1 syntax error: invalid character: '#' ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error syntax error error: 2222 != 1 ./calc.at:1343: cat stderr input: ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1341: cat stderr | 1 = 2 = 3 ./calc.at:1343: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' stderr: syntax error, unexpected '=' ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error, unexpected '=' 481. calc.at:1348: testing Calculator parse.error=detailed %locations ... input: ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !* ++ ./calc.at:1340: cat stderr ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1348: mv calc.y.tmp calc.y input: | (# + 1) = 1111 ./calc.at:1348: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1340: $PREPARSER ./calc input ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: memory exhausted ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1342: cat stderr memory exhausted ./calc.at:1343: cat stderr syntax error: invalid character: '#' ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' input: input: ./calc.at:1338: cat stderr | | +1 ./calc.at:1343: $PREPARSER ./calc input stderr: | (* *) + (*) + (*) ./calc.at:1342: $PREPARSER ./calc input syntax error, unexpected '+' stderr: ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error syntax error ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + 1) / (1 - 1) ./calc.at:1338: $PREPARSER ./calc input stderr: stderr: 1.11-17: error: null divisor ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected '+' stderr: ./calc.at:1348: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS 1.11-17: error: null divisor ./calc.at:1340: cat stderr input: | (1 + # + 1) = 1111 ./calc.at:1340: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1341: cat stderr stderr: ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error syntax error ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (#) + (#) = 2222 ./calc.at:1341: $PREPARSER ./calc input stderr: stderr: stdout: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1346: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' syntax error: invalid character: '#' stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1346: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1338: cat stderr ./calc.at:1343: cat stderr stderr: input: stdout: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1344: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1346: $PREPARSER ./calc input 473. calc.at:1338: ok stderr: ./calc.at:1344: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1343: $PREPARSER ./calc /dev/null ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1346: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: input: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected end of file | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1340: cat stderr stderr: ./calc.at:1344: $PREPARSER ./calc input input: syntax error, unexpected end of file stderr: ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1346: $PREPARSER ./calc input input: ./calc.at:1341: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1342: cat stderr ./calc.at:1340: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1344: $EGREP -c -v 'Return for a new token:|LAC:' stderr error: null divisor ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | (1 + #) = 1111 ./calc.at:1341: $PREPARSER ./calc input stderr: 1.3: syntax error ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: null divisor input: stderr: | 1 + 2 * 3 + !+ ++ syntax error: invalid character: '#' ./calc.at:1342: $PREPARSER ./calc input ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1344: $PREPARSER ./calc input stderr: syntax error, unexpected number ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.3: syntax error syntax error, unexpected number ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' stderr: ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: cat stderr 482. calc.at:1350: testing Calculator parse.error=detailed %locations %header api.prefix={calc} %verbose %yacc ... ./calc.at:1350: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1342: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: ./calc.at:1346: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1343: $PREPARSER ./calc input ./calc.at:1344: cat stderr ./calc.at:1350: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1340: cat stderr | 1 + 2 * 3 + !- ++ ./calc.at:1342: $PREPARSER ./calc input input: stderr: stderr: input: ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 474. calc.at:1340: ok | 1//2 ./calc.at:1346: $PREPARSER ./calc input stderr: ./calc.at:1341: cat stderr stderr: 1.3: syntax error | 1//2 ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: $PREPARSER ./calc input stderr: stderr: stdout: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: ./calc.at:1347: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c syntax error, unexpected '/', expecting number or '-' or '(' or '!' stderr: syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 input: ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.3: syntax error input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1342: cat stderr ./calc.at:1347: $PREPARSER ./calc input stderr: | (# + 1) = 1111 ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1343: cat stderr stderr: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' input: | 1 + 2 * 3 + !* ++ | (!!) + (1 2) = 1 ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1343: $PREPARSER ./calc input ./calc.at:1344: cat stderr ./calc.at:1342: $PREPARSER ./calc input ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected number error: 2222 != 1 ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: memory exhausted ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1346: cat stderr syntax error, unexpected number error: 2222 != 1 483. calc.at:1351: testing Calculator parse.error=detailed %locations %header %name-prefix "calc" api.token.prefix={TOK_} %verbose %yacc ... ./calc.at:1351: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi stderr: memory exhausted stderr: syntax error: invalid character: '#' ./calc.at:1350: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1351: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y input: | error ./calc.at:1344: $PREPARSER ./calc input stderr: stderr: ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected invalid token ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1347: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error ./calc.at:1346: $PREPARSER ./calc input ./calc.at:1342: cat stderr ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: cat stderr stderr: 1.1: syntax error input: ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 stderr: ./calc.at:1343: $PREPARSER ./calc input stderr: input: syntax error, unexpected invalid token | (#) + (#) = 2222 ./calc.at:1342: $PREPARSER ./calc input input: stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.1: syntax error ./calc.at:1341: cat stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: $PREPARSER ./calc input stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: ./calc.at:1351: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS 1.3: syntax error ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: 1.3: syntax error | (1 + # + 1) = 1111 ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1344: cat stderr ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' ./calc.at:1346: cat stderr input: input: ./calc.at:1342: cat stderr | 1 = 2 = 3 ./calc.at:1346: $PREPARSER ./calc input | 1 = 2 = 3 stderr: ./calc.at:1344: $PREPARSER ./calc input ./calc.at:1347: cat stderr ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.7: syntax error ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (1 + #) = 1111 ./calc.at:1343: cat stderr ./calc.at:1342: $PREPARSER ./calc input stderr: 1.7: syntax error stderr: syntax error: invalid character: '#' syntax error, unexpected '=' ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' | 1//2 ./calc.at:1347: $PREPARSER ./calc input ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.3: syntax error ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: 1.3: syntax error stdout: ./calc.at:1346: cat stderr stderr: ./calc.at:1348: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (* *) + (*) + (*) ./calc.at:1343: $PREPARSER ./calc input | | +1 ./calc.at:1346: $PREPARSER ./calc input ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c syntax error, unexpected '=' stderr: stderr: 2.1: syntax error ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1342: cat stderr ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 2.1: syntax error ./calc.at:1341: cat stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1348: $PREPARSER ./calc input ./calc.at:1347: cat stderr stderr: stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 input: ./calc.at:1342: $PREPARSER ./calc input | error stderr: ./calc.at:1347: $PREPARSER ./calc input syntax error: invalid character: '#' stderr: ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error stderr: ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1348: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: ./calc.at:1346: cat stderr stderr: stderr: ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + 1) / (1 - 1) ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1344: cat stderr 1.1: syntax error syntax error: invalid character: '#' ./calc.at:1343: cat stderr stderr: ./calc.at:1346: $PREPARSER ./calc /dev/null input: error: null divisor input: ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1348: $PREPARSER ./calc input stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1343: $PREPARSER ./calc input 1.1: syntax error ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error, unexpected number ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1344: $PREPARSER ./calc input stderr: stderr: ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 error: null divisor stderr: 1.1: syntax error stderr: ./calc.at:1343: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: syntax error, unexpected '+' ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error, unexpected number input: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: cat stderr | 1 + 2 * 3 + !- ++ ./calc.at:1343: $PREPARSER ./calc input ./calc.at:1342: cat stderr stderr: ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1341: cat stderr stderr: ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected '+' ./calc.at:1346: cat stderr input: 475. calc.at:1341: ok | (1 + # + 1) = 1111 ./calc.at:1342: $PREPARSER ./calc input input: stderr: ./calc.at:1348: cat stderr | 1 = 2 = 3 ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: $PREPARSER ./calc input input: ./calc.at:1343: cat stderr stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' stderr: ./calc.at:1346: $PREPARSER ./calc input 1.7: syntax error ./calc.at:1344: cat stderr input: stderr: ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !* ++ ./calc.at:1343: $PREPARSER ./calc input 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 stderr: ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: memory exhausted ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1//2 ./calc.at:1344: $PREPARSER ./calc /dev/null ./calc.at:1348: $PREPARSER ./calc input stderr: stderr: syntax error, unexpected end of input memory exhausted stderr: ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' stderr: ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.7: syntax error 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 stderr: stderr: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1342: cat stderr syntax error, unexpected end of input ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1346: cat stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1343: cat stderr | (1 + 1) / (1 - 1) | (!!) + (1 2) = 1 ./calc.at:1347: cat stderr ./calc.at:1342: $PREPARSER ./calc input ./calc.at:1346: $PREPARSER ./calc input ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 484. calc.at:1353: testing Calculator %debug ... stderr: ./calc.at:1353: mv calc.y.tmp calc.y 1.11: syntax error 1.1-16: error: 2222 != 1 stderr: ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: null divisor stderr: ./calc.at:1353: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11: syntax error 1.1-16: error: 2222 != 1 input: | | +1 ./calc.at:1344: cat stderr ./calc.at:1347: $PREPARSER ./calc input stderr: 2.1: syntax error ./calc.at:1348: cat stderr ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: error: null divisor | (#) + (#) = 2222 input: ./calc.at:1343: $PREPARSER ./calc input input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: $PREPARSER ./calc input | error ./calc.at:1348: $PREPARSER ./calc input stderr: stderr: 1.1: syntax error, unexpected invalid token stderr: ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1346: cat stderr syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 2.1: syntax error syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 input: syntax error: invalid character: '#' syntax error: invalid character: '#' | (- *) + (1 2) = 1 ./calc.at:1346: $PREPARSER ./calc input stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1353: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1347: cat stderr ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1342: cat stderr ./calc.at:1347: $PREPARSER ./calc /dev/null 1.1: syntax error, unexpected invalid token stderr: 1.1: syntax error ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 476. calc.at:1342: ok stderr: 1.1: syntax error stderr: stdout: ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1344: cat stderr ./calc.at:1350: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1350: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1347: cat stderr | (!!) + (1 2) = 1 ./calc.at:1344: $PREPARSER ./calc input stderr: ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected number error: 2222 != 1 input: ./calc.at:1343: cat stderr ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1350: $PREPARSER ./calc input stderr: ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1347: $PREPARSER ./calc input stderr: ./calc.at:1348: cat stderr syntax error, unexpected number error: 2222 != 1 ./calc.at:1350: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 | (1 + #) = 1111 ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1343: $PREPARSER ./calc input stderr: stderr: syntax error: invalid character: '#' ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1346: cat stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 2 ./calc.at:1344: cat stderr ./calc.at:1350: $PREPARSER ./calc input stderr: stderr: 485. calc.at:1354: testing Calculator parse.error=detailed %debug %locations %header %name-prefix "calc" %verbose %yacc ... 1.3: syntax error, unexpected number ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 = 2 = 3 input: ./calc.at:1348: $PREPARSER ./calc input | (* *) + (*) + (*) input: stderr: | (- *) + (1 2) = 1 ./calc.at:1344: $PREPARSER ./calc input 1.3: syntax error, unexpected number ./calc.at:1346: $PREPARSER ./calc input stderr: ./calc.at:1354: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi 1.7: syntax error, unexpected '=' ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y 1.7: syntax error, unexpected '=' stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1350: cat stderr stderr: stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 input: stderr: ./calc.at:1347: cat stderr | 1//2 stdout: ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1350: $PREPARSER ./calc input ./types.at:139: $PREPARSER ./test stderr: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1348: cat stderr ./calc.at:1343: cat stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ======== Testing with C++ standard flags: '' input: ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1346: cat stderr | (!!) + (1 2) = 1 ./calc.at:1347: $PREPARSER ./calc input input: ./calc.at:1350: cat stderr | | +1 ./calc.at:1348: $PREPARSER ./calc input stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: 2.1: syntax error, unexpected '+' ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: cat stderr ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: input: stdout: | (* *) + (*) + (*) ./calc.at:1344: $PREPARSER ./calc input ./calc.at:1351: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' | error input: ./calc.at:1350: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1346: $PREPARSER ./calc input stderr: ./calc.at:1354: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 2.1: syntax error, unexpected '+' stderr: 1.1: syntax error, unexpected invalid token ./calc.at:1346: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: stderr: | (# + 1) = 1111 ./calc.at:1343: $PREPARSER ./calc input ./calc.at:1351: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h stderr: stderr: ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 input: ./calc.at:1351: $PREPARSER ./calc input ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1346: $PREPARSER ./calc input stderr: ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' stderr: stderr: ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1348: cat stderr 1.1: syntax error, unexpected invalid token ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: $PREPARSER ./calc /dev/null stderr: ./calc.at:1343: cat stderr stderr: 1.1: syntax error, unexpected end of file ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 2 ./calc.at:1351: $PREPARSER ./calc input ./calc.at:1350: cat stderr ./calc.at:1347: cat stderr stderr: ./calc.at:1346: cat stderr input: | (1 + # + 1) = 1111 ./calc.at:1343: $PREPARSER ./calc input ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1344: cat stderr input: input: 1.3: syntax error, unexpected number ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 | 1 + 2 * 3 + !* ++ ./calc.at:1346: $PREPARSER ./calc input input: ./calc.at:1350: $PREPARSER ./calc input 1.1: syntax error, unexpected end of file | (- *) + (1 2) = 1 input: ./calc.at:1347: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1344: $PREPARSER ./calc input stderr: stderr: 1.7: syntax error, unexpected '=' syntax error: invalid character: '#' stderr: stderr: 1.14: memory exhausted ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: ./types.at:139: ./check 1.3: syntax error, unexpected number stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 1.7: syntax error, unexpected '=' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./calc.at:1344: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.14: memory exhausted ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: cat stderr ./calc.at:1348: cat stderr ./calc.at:1351: cat stderr input: ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !- ++ ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1344: $PREPARSER ./calc input input: input: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1348: $PREPARSER ./calc input input: ./calc.at:1350: cat stderr | (1 + 1) / (1 - 1) | 1//2 stderr: ./calc.at:1343: $PREPARSER ./calc input stderr: ./calc.at:1351: $PREPARSER ./calc input 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1346: cat stderr stderr: stderr: ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: null divisor ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: cat stderr stderr: stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1348: cat stderr input: ./calc.at:1351: cat stderr input: | (#) + (#) = 2222 ./calc.at:1346: $PREPARSER ./calc input ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | (* *) + (*) + (*) error: null divisor ./calc.at:1347: $PREPARSER ./calc input stderr: stderr: | error | | +1 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1351: $PREPARSER ./calc input ./calc.at:1350: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (!!) + (1 2) = 1 ./calc.at:1348: $PREPARSER ./calc input stderr: stderr: stderr: 1.1: syntax error, unexpected invalid token 2.1: syntax error, unexpected '+' stderr: ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1344: cat stderr 1.1: syntax error, unexpected invalid token stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 stderr: stderr: 2.1: syntax error, unexpected '+' input: ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' | 1 + 2 * 3 + !* ++ ./calc.at:1344: $PREPARSER ./calc input ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: memory exhausted ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: cat stderr ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: cat stderr stderr: memory exhausted input: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 ./calc.at:1351: $PREPARSER ./calc input ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.7: syntax error, unexpected '=' ./calc.at:1350: cat stderr ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1343: cat stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1350: $PREPARSER ./calc /dev/null 1.7: syntax error, unexpected '=' ./calc.at:1347: cat stderr ./calc.at:1346: cat stderr stderr: ./calc.at:1344: cat stderr | (- *) + (1 2) = 1 1.1: syntax error, unexpected end of file ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1348: $PREPARSER ./calc input input: stderr: 1.1: syntax error, unexpected end of file | 1 + 2 * 3 + !+ ++ ./calc.at:1347: $PREPARSER ./calc input stderr: stderr: stderr: input: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 | (#) + (#) = 2222 ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1344: $PREPARSER ./calc input ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 ./calc.at:1346: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1353: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1347: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' 477. calc.at:1343: ok ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: cat stderr ./calc.at:1351: cat stderr stderr: ./calc.at:1353: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: input: input: input: 1.6: syntax error: invalid character: '#' | | +1 | 1 + 2 * 3 + !- ++ ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: $PREPARSER ./calc input ./calc.at:1351: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: stderr: ./calc.at:1350: $PREPARSER ./calc input stderr: input: ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: cat stderr 2.1: syntax error, unexpected '+' 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 input: stderr: stderr: ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 2.1: syntax error, unexpected '+' 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 | (* *) + (*) + (*) ./calc.at:1353: $PREPARSER ./calc input ./calc.at:1348: $PREPARSER ./calc input ./calc.at:1346: cat stderr stderr: ./calc.at:1344: cat stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' input: ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 ./calc.at:1346: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 7) Shifting token "number" (1.1: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 7) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 7) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: -3) -> $$ = nterm exp (1.1: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: -6) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 5) Shifting token "number" (1.1: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 5) -> $$ = nterm exp (1.1: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 5) -> $$ = nterm exp (1.1: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -5) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -5) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -5) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: -1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: -1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 4) Shifting token "number" (1.1: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 4) -> $$ = nterm exp (1.1: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 4) -> $$ = nterm exp (1.1: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -4) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -4) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -4) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 2) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 8) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 256) Shifting token "number" (1.1: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 256) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 256) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 4) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 4) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 64) Shifting token "number" (1.1: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 64) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 64) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: cat stderr ./calc.at:1351: cat stderr stderr: stderr: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 7) Shifting token "number" (1.1: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 7) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 7) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: -3) -> $$ = nterm exp (1.1: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: -6) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 5) Shifting token "number" (1.1: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 5) -> $$ = nterm exp (1.1: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 5) -> $$ = nterm exp (1.1: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -5) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -5) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -5) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: -1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: -1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 4) Shifting token "number" (1.1: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 4) -> $$ = nterm exp (1.1: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 4) -> $$ = nterm exp (1.1: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -4) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -4) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -4) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 2) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 8) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 256) Shifting token "number" (1.1: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 256) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 256) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 4) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 4) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 64) Shifting token "number" (1.1: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 64) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 64) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: ./calc.at:1353: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 1.2: syntax error: invalid character: '#' ./calc.at:1350: $PREPARSER ./calc input ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' stderr: input: input: | (1 + #) = 1111 | 1 2 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: cat stderr ./calc.at:1353: $PREPARSER ./calc input 486. calc.at:1355: testing Calculator parse.error=detailed %debug %locations %header api.prefix={calc} %verbose %yacc ... ./calc.at:1344: $PREPARSER ./calc input ./calc.at:1351: $PREPARSER ./calc /dev/null ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1355: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.1: 2) Stack now 0 ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 stderr: syntax error: invalid character: '#' ./calc.at:1355: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.1: 2) Stack now 0 syntax error: invalid character: '#' ./calc.at:1346: cat stderr ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: cat stderr input: input: 1.1: syntax error, unexpected end of file | 1 + 2 * 3 + !* ++ ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: $PREPARSER ./calc input stderr: ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.1: syntax error, unexpected end of file 1.14: memory exhausted | 1 + 2 * 3 + !+ ++ ./calc.at:1350: cat stderr input: ./calc.at:1348: $PREPARSER ./calc input ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + # + 1) = 1111 ./calc.at:1346: $PREPARSER ./calc input stderr: stderr: ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1348: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.6: syntax error: invalid character: '#' ./calc.at:1351: cat stderr ./calc.at:1353: cat stderr ./calc.at:1344: cat stderr stderr: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !- ++ ./calc.at:1348: $PREPARSER ./calc input stderr: ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (# + 1) = 1111 ./calc.at:1344: $PREPARSER ./calc input input: 1.14: memory exhausted input: | (- *) + (1 2) = 1 stderr: | 1//2 ./calc.at:1353: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.1: ) syntax error Error: popping token '/' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.1: ) Stack now 0 ./calc.at:1350: $PREPARSER ./calc input ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 syntax error: invalid character: '#' input: stderr: ./calc.at:1355: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.1: ) syntax error Error: popping token '/' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.1: ) Stack now 0 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: $PREPARSER ./calc input stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1346: cat stderr input: stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (1 + 1) / (1 - 1) ./calc.at:1346: $PREPARSER ./calc input 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1347: cat stderr ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: cat stderr ./calc.at:1351: cat stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: 1.11-17: error: null divisor ./calc.at:1344: cat stderr input: | (#) + (#) = 2222 ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 ./calc.at:1350: cat stderr ./calc.at:1351: $PREPARSER ./calc input ./calc.at:1347: $PREPARSER ./calc input ./calc.at:1353: cat stderr stderr: input: 1.11-17: error: null divisor input: stderr: | (1 + # + 1) = 1111 stderr: ./calc.at:1344: $PREPARSER ./calc input 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 | 1 + 2 * 3 + !* ++ ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1348: $PREPARSER ./calc input input: stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' | (* *) + (*) + (*) ./calc.at:1350: $PREPARSER ./calc input ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.14: memory exhausted 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 stderr: ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error ./calc.at:1353: $PREPARSER ./calc input stderr: stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.14: memory exhausted stderr: stderr: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' stderr: syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 ./calc.at:1351: cat stderr ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 | (- *) + (1 2) = 1 ./calc.at:1351: $PREPARSER ./calc input ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1348: cat stderr ./calc.at:1346: cat stderr ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1344: cat stderr ./calc.at:1350: cat stderr 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 479. calc.at:1346: ok input: | (1 + 1) / (1 - 1) ./calc.at:1344: $PREPARSER ./calc input ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 input: input: stderr: | (#) + (#) = 2222 ./calc.at:1348: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1350: $PREPARSER ./calc input error: null divisor ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: null divisor ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1351: cat stderr ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (* *) + (*) + (*) ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: cat stderr ./calc.at:1351: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1353: cat stderr ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: cat stderr stderr: ./calc.at:1350: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: input: ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 478. calc.at:1344: ok ./calc.at:1348: cat stderr | 1 = 2 = 3 input: ./calc.at:1353: $PREPARSER ./calc input 487. calc.at:1357: testing Calculator api.pure=full parse.error=detailed %debug %locations %header %name-prefix "calc" %verbose %yacc ... | (1 + #) = 1111 ./calc.at:1357: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi ./calc.at:1347: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.1: ) syntax error Error: popping nterm exp (1.1: 2) Stack now 0 8 19 Error: popping token '=' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.1: ) Stack now 0 1.6: syntax error: invalid character: '#' ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1351: cat stderr stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.1: ) syntax error Error: popping nterm exp (1.1: 2) Stack now 0 8 19 Error: popping token '=' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.1: ) Stack now 0 | (1 + #) = 1111 ./calc.at:1348: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' | 1 + 2 * 3 + !- ++ ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: $PREPARSER ./calc input ./calc.at:1357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !+ ++ ./calc.at:1351: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1351: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1353: cat stderr stderr: 1.6: syntax error: invalid character: '#' 1.6: syntax error: invalid character: '#' input: | | +1 ./calc.at:1353: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (1.1: ) syntax error Error: popping nterm input (1.1: ) Stack now 0 Cleanup: discarding lookahead token '+' (1.1: ) Stack now 0 ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (1.1: ) syntax error Error: popping nterm input (1.1: ) Stack now 0 Cleanup: discarding lookahead token '+' (1.1: ) Stack now 0 stderr: ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1350: cat stderr | 1 + 2 * 3 + !- ++ ./calc.at:1351: $PREPARSER ./calc input stderr: ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./calc.at:1347: cat stderr ./calc.at:1357: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: ./calc.at:1354: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1354: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h 488. calc.at:1358: testing Calculator api.push-pull=both api.pure=full parse.error=detailed %debug %locations %header api.prefix={calc} %verbose %yacc ... ./calc.at:1358: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: cat stderr input: input: | (# + 1) = 1111 | 1 + 2 * 3 + !* ++ ./calc.at:1347: $PREPARSER ./calc input ./calc.at:1350: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' input: ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1354: $PREPARSER ./calc input ./calc.at:1353: cat stderr input: stderr: ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 stderr: ./calc.at:1353: $PREPARSER ./calc /dev/null 1.2: syntax error: invalid character: '#' ./calc.at:1348: $PREPARSER ./calc input ./calc.at:1358: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: 1.14: memory exhausted Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 ./calc.at:1351: cat stderr ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 136): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 1.2: syntax error: invalid character: '#' | 1 + 2 * 3 + !* ++ ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: $PREPARSER ./calc input stderr: 1.14: memory exhausted stderr: ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 stderr: stderr: 1.14: memory exhausted Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 136): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) input: | (1 + # + 1) = 1111 ./calc.at:1347: $PREPARSER ./calc input ./calc.at:1354: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.14: memory exhausted stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 2 ./calc.at:1350: cat stderr ./calc.at:1354: $PREPARSER ./calc input ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1358: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1351: cat stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 | (#) + (#) = 2222 ./calc.at:1351: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1353: cat stderr ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1348: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1354: cat stderr ./calc.at:1347: cat stderr input: ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (#) + (#) = 2222 ./calc.at:1350: $PREPARSER ./calc input input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1351: cat stderr stderr: ./calc.at:1353: $PREPARSER ./calc input input: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + # + 1) = 1111 ./calc.at:1348: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.1: ) syntax error Error: popping token '+' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 3) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 1) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.1: ) syntax error Error: popping token '*' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 2) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 3333) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 4444) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 4444 != 1 -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 4444) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) 1.6: syntax error: invalid character: '#' input: ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1351: $PREPARSER ./calc input ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | 1//2 ./calc.at:1354: $PREPARSER ./calc input | (1 + 1) / (1 - 1) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.1: ) syntax error Error: popping token '+' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 3) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 1) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.1: ) syntax error Error: popping token '*' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 2) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 3333) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 4444) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 4444 != 1 -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 4444) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: ./calc.at:1347: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 stderr: 1.11-17: error: null divisor ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1351: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (# + 1) = 1111 stderr: stderr: ./calc.at:1351: $PREPARSER ./calc input stderr: ./calc.at:1350: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor 1.6: syntax error: invalid character: '#' 1.2: syntax error: invalid character: '#' ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + #) = 1111 ./calc.at:1350: $PREPARSER ./calc input ./calc.at:1353: cat stderr ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1354: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: 1.6: syntax error: invalid character: '#' ./calc.at:1347: cat stderr ./calc.at:1351: cat stderr ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 480. calc.at:1347: ok | error ./calc.at:1354: $PREPARSER ./calc input | (!!) + (1 2) = 1 stderr: ./calc.at:1353: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 121): $1 = token '!' (1.1: ) $2 = token '!' (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: cat stderr input: ./calc.at:1348: cat stderr | (1 + # + 1) = 1111 stderr: ./calc.at:1351: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 121): $1 = token '!' (1.1: ) $2 = token '!' (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: | (# + 1) = 1111 ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1350: $PREPARSER ./calc input input: | (1 + 1) / (1 - 1) stderr: ./calc.at:1348: $PREPARSER ./calc input ./calc.at:1354: cat stderr stderr: stderr: 1.2: syntax error: invalid character: '#' 1.6: syntax error: invalid character: '#' ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11-17: error: null divisor ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.2: syntax error: invalid character: '#' 1.6: syntax error: invalid character: '#' ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 = 2 = 3 ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1354: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1350: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 489. calc.at:1360: testing Calculator api.pure parse.error=detailed %debug %locations %header api.prefix={calc} %verbose %yacc %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1360: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi stderr: ./calc.at:1351: cat stderr ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 1.11-17: error: null divisor input: | (1 + 1) / (1 - 1) ./calc.at:1351: $PREPARSER ./calc input | (1 + # + 1) = 1111 ./calc.at:1350: $PREPARSER ./calc input stderr: ./calc.at:1353: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1354: cat stderr 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1350: cat stderr ./calc.at:1360: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11-17: error: null divisor ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1348: cat stderr | | +1 ./calc.at:1354: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor 481. calc.at:1348: ok input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 input: ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (- *) + (1 2) = 1 ./calc.at:1353: $PREPARSER ./calc input | (1 + 1) / (1 - 1) ./calc.at:1351: cat stderr ./calc.at:1350: $PREPARSER ./calc input ./calc.at:1360: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 120): $1 = token '-' (1.1: ) $2 = token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1354: cat stderr stderr: ./calc.at:1354: $PREPARSER ./calc /dev/null 483. calc.at:1351: ok stdout: stderr: 1.11-17: error: null divisor ./calc.at:1355: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 stderr: ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 120): $1 = token '-' (1.1: ) $2 = token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1355: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1355: $PREPARSER ./calc input 490. calc.at:1362: testing Calculator %no-lines api.pure parse.error=detailed %debug %locations %header api.prefix={calc} %verbose %yacc %parse-param {semantic_value *result}{int *count}{int *nerrs} ... stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 136): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: cat stderr ./calc.at:1362: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1353: cat stderr 491. calc.at:1363: testing Calculator %no-lines api.pure parse.error=verbose %debug %locations %header api.prefix={calc} %verbose %yacc %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1363: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1354: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 136): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1355: $EGREP -c -v 'Return for a new token:|LAC:' stderr 482. calc.at:1350: ok ./calc.at:1362: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y input: ./calc.at:1363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | (* *) + (*) + (*) ./calc.at:1353: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1354: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 3333) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1355: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 3333) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1354: cat stderr stderr: ./calc.at:1363: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS input: stdout: | (!!) + (1 2) = 1 ./calc.at:1354: $PREPARSER ./calc input ./types.at:139: $PREPARSER ./test stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 141): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 141): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1353: cat stderr ./calc.at:1362: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS 492. calc.at:1364: testing Calculator %no-lines api.pure parse.error=verbose %debug %locations %defines api.prefix={calc} %verbose %yacc %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1364: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi ./calc.at:1364: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 450. types.at:139: ok ./calc.at:1354: cat stderr input: input: | (- *) + (1 2) = 1 ./calc.at:1354: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 140): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1353: $PREPARSER ./calc input ./calc.at:1355: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 140): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 122): $1 = token '!' (1.1: ) $2 = token '+' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1364: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1355: $PREPARSER ./calc input ./calc.at:1354: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (* *) + (*) + (*) ./calc.at:1354: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 122): $1 = token '!' (1.1: ) $2 = token '+' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) stderr: stdout: ./calc.at:1353: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1357: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1354: cat stderr ./calc.at:1355: cat stderr input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1357: $PREPARSER ./calc input input: input: | 1 + 2 * 3 + !- ++ | 1 + 2 * 3 + !+ ++ input: ./calc.at:1353: $PREPARSER ./calc input ./calc.at:1354: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 123): $1 = token '!' (1.1: ) $2 = token '-' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 493. calc.at:1367: testing Calculator parse.error=custom ... stderr: stderr: stderr: ./calc.at:1367: mv calc.y.tmp calc.y Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 123): $1 = token '!' (1.1: ) $2 = token '-' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1367: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1355: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 142): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 | 1 2 ./calc.at:1357: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 142): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1354: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1353: cat stderr ./calc.at:1355: cat stderr input: | 1 + 2 * 3 + !* ++ ./calc.at:1353: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 124): $1 = token '!' (1.1: ) $2 = token '*' (1.1: ) memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 124): $1 = token '!' (1.1: ) $2 = token '*' (1.1: ) memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) input: ./calc.at:1357: cat stderr | 1 + 2 * 3 + !- ++ input: ./calc.at:1354: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1355: $PREPARSER ./calc input stderr: ./calc.at:1367: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 143): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 | 1//2 ./calc.at:1357: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 143): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1354: cat stderr ./calc.at:1355: cat stderr ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !* ++ ./calc.at:1354: $PREPARSER ./calc input ./calc.at:1357: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 144): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1355: $PREPARSER ./calc input input: ./calc.at:1353: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 144): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | error ./calc.at:1357: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (#) + (#) = 2222 ./calc.at:1353: $PREPARSER ./calc input stderr: stderr: ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2222) Shifting token "number" (1.1: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1354: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2222) Shifting token "number" (1.1: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 input: | (#) + (#) = 2222 ./calc.at:1354: $PREPARSER ./calc input ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: cat stderr ./calc.at:1355: cat stderr ./calc.at:1353: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1355: $PREPARSER ./calc /dev/null stderr: input: | (1 + #) = 1111 ./calc.at:1353: $PREPARSER ./calc input ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: ./calc.at:1367: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' input: | 1 = 2 = 3 ./calc.at:1357: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1354: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1367: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1367: $PREPARSER ./calc input ./calc.at:1355: cat stderr stdout: stderr: input: ./calc.at:1357: cat stderr ./calc.at:1360: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1353: cat stderr | (1 + #) = 1111 ./calc.at:1354: $PREPARSER ./calc input ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: input: stderr: input: ./calc.at:1360: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h | (# + 1) = 1111 ./calc.at:1367: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1353: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | | +1 ./calc.at:1357: $PREPARSER ./calc input ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1355: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1360: $PREPARSER ./calc input ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | 1 2 stdout: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1367: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1360: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: stderr: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1358: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1357: cat stderr ./calc.at:1354: cat stderr ./calc.at:1358: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h stderr: input: input: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) | 1 2 | (# + 1) = 1111 ./calc.at:1354: $PREPARSER ./calc input ./calc.at:1353: cat stderr ./calc.at:1360: $PREPARSER ./calc input input: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: ./calc.at:1358: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1355: cat stderr ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: $PREPARSER ./calc /dev/null stderr: ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Return for a new token: Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Return for a new token: Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Return for a new token: Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Return for a new token: Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Return for a new token: Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Return for a new token: Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Return for a new token: Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Return for a new token: Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Return for a new token: Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Return for a new token: Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Return for a new token: Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Return for a new token: Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Return for a new token: Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Return for a new token: Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Return for a new token: Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Return for a new token: Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Return for a new token: Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Return for a new token: Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Return for a new token: Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Return for a new token: Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Return for a new token: Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Return for a new token: Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Return for a new token: Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Return for a new token: Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Return for a new token: Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Return for a new token: Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Return for a new token: Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Return for a new token: Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Return for a new token: Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Return for a new token: Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Return for a new token: Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Return for a new token: Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Return for a new token: Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Return for a new token: Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Return for a new token: Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Return for a new token: Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Return for a new token: Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Return for a new token: Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 stderr: ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (!!) + (1 2) = 1 ./calc.at:1355: $PREPARSER ./calc input input: | (1 + # + 1) = 1111 ./calc.at:1353: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 141): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stderr: stderr: ./calc.at:1363: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Return for a new token: Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Return for a new token: Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Return for a new token: Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Return for a new token: Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Return for a new token: Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Return for a new token: Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Return for a new token: Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Return for a new token: Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Return for a new token: Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Return for a new token: Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Return for a new token: Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Return for a new token: Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Return for a new token: Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Return for a new token: Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Return for a new token: Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Return for a new token: Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Return for a new token: Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Return for a new token: Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Return for a new token: Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Return for a new token: Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Return for a new token: Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Return for a new token: Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Return for a new token: Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Return for a new token: Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Return for a new token: Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Return for a new token: Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Return for a new token: Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Return for a new token: Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Return for a new token: Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Return for a new token: Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Return for a new token: Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Return for a new token: Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Return for a new token: Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Return for a new token: Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Return for a new token: Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Return for a new token: Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Return for a new token: Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Return for a new token: Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1358: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1363: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 141): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1367: cat stderr ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1367: $PREPARSER ./calc input ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1355: cat stderr syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) input: ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1358: $PREPARSER ./calc input ./calc.at:1354: cat stderr stderr: ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: stdout: | (- *) + (1 2) = 1 stderr: ./calc.at:1355: $PREPARSER ./calc input input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1363: $PREPARSER ./calc input syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) input: stderr: stderr: | (1 + # + 1) = 1111 ./calc.at:1354: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 140): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1360: cat stderr ./calc.at:1362: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1353: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 140): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (1 + 1) / (1 - 1) ./calc.at:1367: cat stderr ./calc.at:1353: $PREPARSER ./calc input stderr: stderr: ./calc.at:1362: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1357: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 2) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 0) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 10 (line 101): $1 = nterm exp (1.1: 2) $2 = token '/' (1.1: ) $3 = nterm exp (1.1: 0) error: null divisor -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: stdout: ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1363: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1362: $PREPARSER ./calc input | error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 2) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 0) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 10 (line 101): $1 = nterm exp (1.1: 2) $2 = token '/' (1.1: ) $3 = nterm exp (1.1: 0) error: null divisor -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1367: $PREPARSER ./calc input input: input: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1357: $PREPARSER ./calc input ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./types.at:139: $PREPARSER ./test | 1 2 ./calc.at:1363: $PREPARSER ./calc input ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 stderr: ./calc.at:1360: $PREPARSER ./calc input stderr: ./calc.at:1354: cat stderr syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1358: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1355: cat stderr ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: ./calc.at:1362: $EGREP -c -v 'Return for a new token:|LAC:' stderr stdout: ./calc.at:1367: cat stderr stderr: ./calc.at:1364: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1353: cat stderr ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 input: ./calc.at:1362: $PREPARSER ./calc input stderr: input: stderr: | 1//2 stderr: ======== Testing with C++ standard flags: '' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: $PREPARSER ./calc input ./calc.at:1364: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 | 1 = 2 = 3 ./calc.at:1367: $PREPARSER ./calc input 484. calc.at:1353: ok ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: stderr: | (1 + 1) / (1 - 1) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Return for a new token: Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 stderr: ./calc.at:1354: $PREPARSER ./calc input ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) input: ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1355: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1364: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 121): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: cat stderr stderr: ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Return for a new token: Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 121): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1363: $PREPARSER ./calc input stderr: ./calc.at:1358: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1357: cat stderr ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1360: cat stderr ./calc.at:1354: cat stderr stderr: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) input: | error ./calc.at:1358: $PREPARSER ./calc input ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1355: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1364: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 | 1 + 2 * 3 + !+ ++ ./calc.at:1355: $PREPARSER ./calc input ./calc.at:1367: cat stderr input: | (!!) + (1 2) = 1 stderr: ./calc.at:1357: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 142): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 input: input: 485. calc.at:1354: ok Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1367: $PREPARSER ./calc input | error ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 494. calc.at:1368: testing Calculator parse.error=custom %locations api.prefix={calc} ... Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 142): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: input: ./calc.at:1355: $EGREP -c -v 'Return for a new token:|LAC:' stderr syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1368: mv calc.y.tmp calc.y ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1360: $PREPARSER ./calc input | 1 2 ./calc.at:1364: $PREPARSER ./calc input ./calc.at:1363: cat stderr ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1368: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: stderr: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 input: ./calc.at:1362: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 | 1 + 2 * 3 + !- ++ ./calc.at:1355: $PREPARSER ./calc input input: | error ./calc.at:1363: $PREPARSER ./calc input ./calc.at:1358: cat stderr stderr: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 143): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1//2 ./calc.at:1362: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 stderr: stderr: ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1367: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 stderr: | 1 = 2 = 3 ./calc.at:1357: cat stderr stderr: ./calc.at:1358: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 143): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 stdout: ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./types.at:139: ./check ./calc.at:1367: $PREPARSER ./calc /dev/null ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./calc.at:1360: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (- *) + (1 2) = 1 ./calc.at:1357: $PREPARSER ./calc input stderr: input: stderr: | 1 = 2 = 3 ./calc.at:1364: cat stderr 495. calc.at:1369: testing Calculator parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1369: mv calc.y.tmp calc.y ./calc.at:1360: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1355: cat stderr ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1368: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS input: ./calc.at:1369: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: | 1 + 2 * 3 + !* ++ Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1355: $PREPARSER ./calc input ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1363: cat stderr ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1362: cat stderr | 1//2 ./calc.at:1364: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 stderr: input: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 = 2 = 3 ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1363: $PREPARSER ./calc input ./calc.at:1367: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 144): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1358: cat stderr input: ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1360: cat stderr stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 144): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1367: $PREPARSER ./calc input stderr: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) error: 4444 != 1 ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) error: 4444 != 1 | error ./calc.at:1362: $PREPARSER ./calc input ./calc.at:1355: cat stderr input: ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1358: $PREPARSER ./calc input stderr: ./calc.at:1357: cat stderr ./calc.at:1369: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 input: ./calc.at:1363: cat stderr | | +1 input: ./calc.at:1360: $PREPARSER ./calc input | (* *) + (*) + (*) ./calc.at:1367: cat stderr ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1357: $PREPARSER ./calc input | | +1 ./calc.at:1363: $PREPARSER ./calc input ./calc.at:1358: cat stderr ./calc.at:1364: cat stderr stderr: stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1358: $PREPARSER ./calc /dev/null ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1355: $PREPARSER ./calc input input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 stderr: | error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1364: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 stderr: ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 ./calc.at:1367: $PREPARSER ./calc input ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 stderr: ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1360: cat stderr stderr: ./calc.at:1360: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 stderr: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1363: cat stderr ./calc.at:1357: cat stderr ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1363: $PREPARSER ./calc /dev/null ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1367: cat stderr stderr: ./calc.at:1358: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1362: cat stderr ./calc.at:1364: cat stderr input: ./calc.at:1355: cat stderr | 1 + 2 * 3 + !+ ++ Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 input: ./calc.at:1357: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1367: $PREPARSER ./calc input ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: stderr: stderr: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1358: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1360: cat stderr ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 = 2 = 3 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Return for a new token: Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Return for a new token: Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Return for a new token: Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Return for a new token: Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Return for a new token: Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Return for a new token: Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Return for a new token: Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Return for a new token: Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 = 2 = 3 ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1364: $PREPARSER ./calc input ./calc.at:1355: $PREPARSER ./calc input ./calc.at:1362: $PREPARSER ./calc input syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 stderr: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 ./calc.at:1360: $PREPARSER ./calc input ./calc.at:1357: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Return for a new token: Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Return for a new token: Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Return for a new token: Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Return for a new token: Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Return for a new token: Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Return for a new token: Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Return for a new token: Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Return for a new token: Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1363: cat stderr ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1367: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 + !- ++ ./calc.at:1357: $PREPARSER ./calc input ./calc.at:1364: cat stderr ./calc.at:1360: cat stderr input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1363: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: stderr: ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (* *) + (*) + (*) ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1367: $PREPARSER ./calc input input: stderr: ./calc.at:1358: cat stderr ./calc.at:1360: $PREPARSER ./calc input | | +1 stderr: ./calc.at:1364: $PREPARSER ./calc input syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1355: cat stderr stderr: ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (!!) + (1 2) = 1 ./calc.at:1358: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Return for a new token: Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1367: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Return for a new token: Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1363: cat stderr | (# + 1) = 1111 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1355: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: ./calc.at:1357: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (!!) + (1 2) = 1 ./calc.at:1363: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1367: $PREPARSER ./calc input ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1362: cat stderr ./calc.at:1358: cat stderr ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (- *) + (1 2) = 1 ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1358: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1364: cat stderr ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1360: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Return for a new token: Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 + !* ++ ./calc.at:1357: $PREPARSER ./calc input ./calc.at:1363: cat stderr ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1367: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1355: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | | +1 ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: $PREPARSER ./calc /dev/null ./calc.at:1362: $PREPARSER ./calc input input: stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 | 1 + 2 * 3 + !- ++ ./calc.at:1367: $PREPARSER ./calc input | (1 + # + 1) = 1111 ./calc.at:1355: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Return for a new token: Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 | (- *) + (1 2) = 1 ./calc.at:1363: $PREPARSER ./calc input ./calc.at:1360: $PREPARSER ./calc input ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1355: cat stderr ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + 1) / (1 - 1) ./calc.at:1358: cat stderr stderr: ./calc.at:1355: $PREPARSER ./calc input ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1367: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 121): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1357: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 121): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1362: cat stderr input: | (* *) + (*) + (*) ./calc.at:1358: $PREPARSER ./calc input input: ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (#) + (#) = 2222 stderr: ./calc.at:1357: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1362: $PREPARSER ./calc /dev/null ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: | 1 + 2 * 3 + !* ++ stderr: ./calc.at:1367: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1363: cat stderr ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1360: cat stderr stderr: memory exhausted ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stdout: stderr: ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr memory exhausted input: ./calc.at:1368: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: | (* *) + (*) + (*) input: ./calc.at:1364: cat stderr ./calc.at:1363: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 | (* *) + (*) + (*) ./calc.at:1360: $PREPARSER ./calc input ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1368: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1358: cat stderr input: ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1367: cat stderr stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1368: $PREPARSER ./calc input stderr: ./calc.at:1364: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1357: cat stderr ./calc.at:1355: cat stderr stderr: ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: stderr: | (1 + #) = 1111 stderr: ./calc.at:1357: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 486. calc.at:1355: ok stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stdout: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1368: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1358: $PREPARSER ./calc input stderr: ./calc.at:1362: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: | (#) + (#) = 2222 ./calc.at:1369: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1367: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Return for a new token: Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1362: $PREPARSER ./calc input ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 2 ./calc.at:1368: $PREPARSER ./calc input ./calc.at:1360: cat stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Return for a new token: Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1358: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1364: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1357: cat stderr ./calc.at:1369: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c stderr: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) | 1 + 2 * 3 + !+ ++ ./calc.at:1360: $PREPARSER ./calc input input: | (# + 1) = 1111 stderr: ./calc.at:1357: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 | (!!) + (1 2) = 1 ./calc.at:1369: $PREPARSER ./calc input ./calc.at:1364: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1363: cat stderr ./calc.at:1368: cat stderr ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1367: cat stderr input: stderr: stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1358: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1369: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: ./calc.at:1362: cat stderr | 1 + 2 * 3 + !+ ++ stderr: ./calc.at:1363: $PREPARSER ./calc input ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (!!) + (1 2) = 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1360: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1362: $PREPARSER ./calc input input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Return for a new token: Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1357: cat stderr | 1//2 input: ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1368: $PREPARSER ./calc input | 1 2 ./calc.at:1369: $PREPARSER ./calc input stderr: | (1 + #) = 1111 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1367: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Return for a new token: Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: stderr: 496. calc.at:1370: testing Calculator parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} api.push-pull=both api.pure=full ... 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: ./calc.at:1370: mv calc.y.tmp calc.y ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + # + 1) = 1111 syntax error: invalid character: '#' stderr: ./calc.at:1370: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1357: $PREPARSER ./calc input ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: cat stderr 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1363: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 + !- ++ ./calc.at:1360: $PREPARSER ./calc input ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1369: cat stderr input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' input: | 1 + 2 * 3 + !- ++ | (- *) + (1 2) = 1 ./calc.at:1363: $PREPARSER ./calc input ./calc.at:1358: cat stderr ./calc.at:1364: $PREPARSER ./calc input ./calc.at:1357: cat stderr stderr: input: | 1//2 ./calc.at:1367: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1369: $PREPARSER ./calc input stderr: stderr: ./calc.at:1368: cat stderr stderr: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: input: | (1 + 1) / (1 - 1) ./calc.at:1357: $PREPARSER ./calc input ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 stderr: ./calc.at:1367: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 + 2 * 3 + !* ++ ./calc.at:1358: $PREPARSER ./calc input 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1370: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error: invalid character: '#' stderr: ./calc.at:1362: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Return for a new token: Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | error ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1368: $PREPARSER ./calc input ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1369: cat stderr ./calc.at:1364: cat stderr 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1367: cat stderr stderr: ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: input: ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Return for a new token: Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: | error | (* *) + (*) + (*) ./calc.at:1369: $PREPARSER ./calc input ./calc.at:1364: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1357: cat stderr input: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1362: $PREPARSER ./calc input stderr: | (1 + # + 1) = 1111 ./calc.at:1367: $PREPARSER ./calc input stderr: ./calc.at:1360: cat stderr 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: syntax error: invalid character: '#' ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: stderr: ./calc.at:1358: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) syntax error: invalid character: '#' ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: input: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (#) + (#) = 2222 | 1 + 2 * 3 + !* ++ ./calc.at:1358: $PREPARSER ./calc input 487. calc.at:1357: ok ./calc.at:1369: cat stderr ./calc.at:1360: $PREPARSER ./calc input stderr: ./calc.at:1368: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: 1.2: syntax error: invalid character: '#' Reading a token Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: 1.8: syntax error: invalid character: '#' Reading a token Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: 1.2: syntax error: invalid character: '#' Reading a token Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: 1.8: syntax error: invalid character: '#' Reading a token Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: input: | 1 = 2 = 3 ./calc.at:1364: cat stderr ./calc.at:1369: $PREPARSER ./calc input ./calc.at:1363: cat stderr | 1 = 2 = 3 ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1368: $PREPARSER ./calc input ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) stderr: ./calc.at:1362: cat stderr ./calc.at:1367: cat stderr stderr: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | 1 + 2 * 3 + !* ++ ./calc.at:1363: $PREPARSER ./calc input stderr: | (* *) + (*) + (*) stderr: ./calc.at:1362: $PREPARSER ./calc input stderr: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1358: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) input: input: stderr: | (1 + #) = 1111 ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !+ ++ ./calc.at:1364: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1369: cat stderr input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1360: cat stderr ./calc.at:1358: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 497. calc.at:1371: testing Calculator parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} api.push-pull=both api.pure=full parse.lac=full ... | (1 + 1) / (1 - 1) ./calc.at:1367: $PREPARSER ./calc input ./calc.at:1371: mv calc.y.tmp calc.y stderr: error: null divisor ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1368: cat stderr ./calc.at:1371: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y input: | (#) + (#) = 2222 ./calc.at:1360: $PREPARSER ./calc input ./calc.at:1362: cat stderr ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | | +1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Return for a new token: 1.6: syntax error: invalid character: '#' Reading a token Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1369: $PREPARSER ./calc input stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: null divisor ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: cat stderr input: input: | 1 + 2 * 3 + !+ ++ stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | | +1 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Return for a new token: 1.6: syntax error: invalid character: '#' Reading a token Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1362: $PREPARSER ./calc input stderr: ./calc.at:1364: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1368: $PREPARSER ./calc input 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1369: cat stderr 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1360: cat stderr input: ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1369: $PREPARSER ./calc /dev/null ./calc.at:1367: cat stderr stderr: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1371: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1363: $PREPARSER ./calc input input: stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) | (1 + #) = 1111 ./calc.at:1360: $PREPARSER ./calc input stderr: ./calc.at:1358: cat stderr input: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 493. calc.at:1367: ok Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.8: ) Error: discarding token "invalid token" (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 + !- ++ ./calc.at:1364: $PREPARSER ./calc input ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1362: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.8: ) Error: discarding token "invalid token" (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1369: cat stderr input: ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1360: cat stderr ./calc.at:1358: $PREPARSER ./calc input input: | 1 + 2 * 3 + !- ++ ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1362: $PREPARSER ./calc input input: stderr: | (# + 1) = 1111 ./calc.at:1368: cat stderr ./calc.at:1364: cat stderr ./calc.at:1360: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: 1.2: syntax error: invalid character: '#' Reading a token Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1369: $PREPARSER ./calc input input: ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !* ++ stderr: ./calc.at:1364: $PREPARSER ./calc input ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 stderr: ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1368: $PREPARSER ./calc /dev/null stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1363: cat stderr 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: 1.2: syntax error: invalid character: '#' Reading a token Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1360: cat stderr ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1364: cat stderr input: | (#) + (#) = 2222 ./calc.at:1364: $PREPARSER ./calc input ./calc.at:1369: cat stderr ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 ./calc.at:1363: $PREPARSER ./calc input stderr: stderr: ./calc.at:1362: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1368: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.8: ) Error: discarding token "invalid token" (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 498. calc.at:1374: testing Calculator %start input exp NUM api.value.type=union ... ./calc.at:1358: cat stderr stderr: stderr: ./calc.at:1374: mv calc.y.tmp calc.y input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (1 + # + 1) = 1111 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.8: ) Error: discarding token "invalid token" (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1374: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1360: $PREPARSER ./calc input input: | (!!) + (1 2) = 1 ./calc.at:1369: $PREPARSER ./calc input ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: stderr: input: | 1 + 2 * 3 + !* ++ ./calc.at:1364: cat stderr ./calc.at:1362: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 | (1 + # + 1) = 1111 stderr: ./calc.at:1363: cat stderr 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 ./calc.at:1368: $PREPARSER ./calc input stderr: ./calc.at:1358: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Return for a new token: 1.6: syntax error: invalid character: '#' Reading a token Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: stderr: ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 ./calc.at:1363: $PREPARSER ./calc input 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Return for a new token: 1.6: syntax error: invalid character: '#' Reading a token Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1368: cat stderr | (1 + #) = 1111 ./calc.at:1374: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1369: cat stderr ./calc.at:1364: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (!!) + (1 2) = 1 ./calc.at:1368: $PREPARSER ./calc input | (- *) + (1 2) = 1 stderr: ./calc.at:1369: $PREPARSER ./calc input 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 ./calc.at:1358: cat stderr ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1360: cat stderr stderr: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1362: cat stderr stderr: stderr: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 input: input: stderr: input: | (1 + 1) / (1 - 1) | (1 + 1) / (1 - 1) 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 ./calc.at:1360: $PREPARSER ./calc input ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1358: $PREPARSER ./calc input stderr: ./calc.at:1368: cat stderr ./calc.at:1369: cat stderr ./calc.at:1363: cat stderr ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Return for a new token: Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Return for a new token: Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Return for a new token: Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Return for a new token: Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Return for a new token: Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Return for a new token: Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Return for a new token: Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: cat stderr ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1362: $PREPARSER ./calc input input: stderr: | (- *) + (1 2) = 1 stderr: ./calc.at:1368: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 input: ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Return for a new token: Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Return for a new token: Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Return for a new token: Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Return for a new token: Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Return for a new token: Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Return for a new token: Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Return for a new token: Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (1 + # + 1) = 1111 ./calc.at:1363: $PREPARSER ./calc input input: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (* *) + (*) + (*) ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1369: $PREPARSER ./calc input 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1360: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1368: cat stderr | (# + 1) = 1111 ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1364: $PREPARSER ./calc input ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 489. calc.at:1360: ok ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: cat stderr input: stderr: input: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) | (1 + 1) / (1 - 1) ./calc.at:1363: $PREPARSER ./calc input stderr: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: | (* *) + (*) + (*) stdout: ./calc.at:1368: $PREPARSER ./calc input ./calc.at:1370: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 488. calc.at:1358: ok ./calc.at:1362: cat stderr ./calc.at:1370: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c stderr: input: | (1 + #) = 1111 ./calc.at:1362: $PREPARSER ./calc input stderr: ./calc.at:1369: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) stderr: ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1370: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 + !+ ++ ./calc.at:1369: $PREPARSER ./calc input 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1364: cat stderr 499. calc.at:1375: testing Calculator %start input exp NUM api.value.type=union %locations parse.error=detailed ... ./calc.at:1375: mv calc.y.tmp calc.y ./calc.at:1375: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1370: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1368: cat stderr ./calc.at:1363: cat stderr ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 491. calc.at:1363: ok | (1 + # + 1) = 1111 input: input: ./calc.at:1364: $PREPARSER ./calc input | 1 2 ./calc.at:1370: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1369: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 + !+ ++ ./calc.at:1368: $PREPARSER ./calc input stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1375: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS 500. calc.at:1387: testing Calculator %glr-parser ... ./calc.at:1387: mv calc.y.tmp calc.y ./calc.at:1387: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1362: cat stderr ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: | (# + 1) = 1111 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1362: $PREPARSER ./calc input stderr: stderr: input: ./calc.at:1368: $EGREP -c -v 'Return for a new token:|LAC:' stderr | 1 + 2 * 3 + !- ++ 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1369: $PREPARSER ./calc input ./calc.at:1387: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: stderr: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./calc.at:1374: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1364: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1370: cat stderr ./calc.at:1374: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1371: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !- ++ ./calc.at:1368: $PREPARSER ./calc input stderr: ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (1 + 1) / (1 - 1) stderr: 501. calc.at:1389: testing Calculator %glr-parser %header ... ./calc.at:1389: mv calc.y.tmp calc.y ./calc.at:1364: $PREPARSER ./calc input | 1//2 ./calc.at:1370: $PREPARSER ./calc input stderr: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1389: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: ./calc.at:1371: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1374: $PREPARSER ./calc input ./calc.at:1362: cat stderr 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1369: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1368: cat stderr input: | (1 + # + 1) = 1111 ./calc.at:1362: $PREPARSER ./calc input ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1371: $PREPARSER ./calc input ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) input: stderr: | 1 + 2 * 3 + !* ++ ./calc.at:1368: $PREPARSER ./calc input ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !* ++ stderr: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1369: $PREPARSER ./calc input 1.14: memory exhausted stderr: ./calc.at:1389: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1371: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.14: memory exhausted input: | 1 2 ./calc.at:1374: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1371: $PREPARSER ./calc input stderr: stderr: ./calc.at:1364: cat stderr 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1370: cat stderr ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.14: memory exhausted 1.14: memory exhausted input: | 1 2 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./calc.at:1374: $PREPARSER ./calc input 492. calc.at:1364: ok ./calc.at:1369: cat stderr stderr: ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1368: cat stderr input: input: | error syntax error ./calc.at:1370: $PREPARSER ./calc input ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1371: cat stderr | (#) + (#) = 2222 ./calc.at:1369: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1362: cat stderr 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) input: | (#) + (#) = 2222 ./calc.at:1368: $PREPARSER ./calc input input: stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' input: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1370: cat stderr | 1//2 ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1371: $PREPARSER ./calc input | (1 + 1) / (1 - 1) ./calc.at:1362: $PREPARSER ./calc input stderr: 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) input: ./calc.at:1374: cat stderr | 1 = 2 = 3 ./calc.at:1370: $PREPARSER ./calc input 502. calc.at:1390: testing Calculator %glr-parser %locations ... ./calc.at:1390: mv calc.y.tmp calc.y ./calc.at:1390: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1371: cat stderr ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1368: cat stderr ./calc.at:1369: cat stderr stderr: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | error ./calc.at:1371: $PREPARSER ./calc input input: | 1//2 ./calc.at:1374: $PREPARSER ./calc input ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) input: ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 stderr: ./calc.at:1362: cat stderr syntax error input: | (1 + #) = 1111 ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1368: $PREPARSER ./calc input stderr: ./calc.at:1369: $PREPARSER ./calc input stderr: 490. calc.at:1362: ok 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: stderr: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) stderr: 1.6: syntax error: invalid character: '#' syntax error stderr: stdout: 1.6: syntax error: invalid character: '#' ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test ./calc.at:1390: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: stderr: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1371: cat stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1370: cat stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1368: cat stderr ======== Testing with C++ standard flags: '' input: | 1 = 2 = 3 ./calc.at:1371: $PREPARSER ./calc input stderr: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS input: ./calc.at:1369: cat stderr ./calc.at:1371: cat stderr | | +1 ./calc.at:1370: $PREPARSER ./calc input input: | | +1 ./calc.at:1371: $PREPARSER ./calc input stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 stderr: ./calc.at:1368: $PREPARSER ./calc input 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1374: cat stderr stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: stdout: ./calc.at:1371: cat stderr 1.2: syntax error: invalid character: '#' ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1375: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' input: input: ./calc.at:1371: $PREPARSER ./calc /dev/null | (# + 1) = 1111 stderr: stderr: ./calc.at:1369: $PREPARSER ./calc input 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) 1.2: syntax error: invalid character: '#' | error ./calc.at:1374: $PREPARSER ./calc input stderr: ./calc.at:1375: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: syntax error ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 1.2: syntax error: invalid character: '#' 503. calc.at:1391: testing Calculator %glr-parser %locations api.location.type={Span} ... ./calc.at:1391: mv calc.y.tmp calc.y stderr: syntax error stderr: input: ./calc.at:1368: cat stderr ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1391: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1375: $PREPARSER ./calc input stderr: ./calc.at:1371: cat stderr ./calc.at:1370: cat stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' input: ./calc.at:1374: cat stderr ./calc.at:1370: $PREPARSER ./calc /dev/null | (1 + # + 1) = 1111 ./calc.at:1368: $PREPARSER ./calc input input: | 1 = 2 = 3 ./calc.at:1374: $PREPARSER ./calc input stderr: stderr: syntax error ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: syntax error ./calc.at:1375: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: stderr: ./calc.at:1371: $PREPARSER ./calc input ./calc.at:1391: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1369: cat stderr ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: 1.6: syntax error: invalid character: '#' stderr: input: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 | 1 2 ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1370: cat stderr ./calc.at:1368: cat stderr input: stderr: 1.3: syntax error, unexpected number ./calc.at:1374: cat stderr | (1 + # + 1) = 1111 ./calc.at:1369: $PREPARSER ./calc input ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1371: cat stderr input: 1.6: syntax error: invalid character: '#' input: stderr: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 | (1 + 1) / (1 - 1) ./calc.at:1370: $PREPARSER ./calc input ./calc.at:1368: $PREPARSER ./calc input | | +1 ./calc.at:1374: $PREPARSER ./calc input ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error, unexpected number stderr: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.11-17: error: null divisor ./calc.at:1375: cat stderr ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: syntax error ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (!!) + (1 2) = 1 | 1//2 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1371: $PREPARSER ./calc input stderr: syntax error stderr: stderr: stderr: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 1.11-17: error: null divisor 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1369: cat stderr ./calc.at:1368: cat stderr 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + 1) / (1 - 1) ./calc.at:1369: $PREPARSER ./calc input stderr: stderr: 1.11-17: error: null divisor 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1370: cat stderr ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 494. calc.at:1368: ok ./calc.at:1374: cat stderr stdout: ./calc.at:1374: $PREPARSER ./calc /dev/null stderr: ./calc.at:1387: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1371: cat stderr ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: | (!!) + (1 2) = 1 1.11-17: error: null divisor input: ./calc.at:1370: $PREPARSER ./calc input syntax error ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1387: $PREPARSER ./calc input stderr: ./calc.at:1369: cat stderr stderr: input: ./calc.at:1375: cat stderr 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 | (- *) + (1 2) = 1 ./calc.at:1371: $PREPARSER ./calc input stderr: ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error 495. calc.at:1369: ok ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 input: ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: | error ./calc.at:1375: $PREPARSER ./calc input stderr: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 stderr: input: ./calc.at:1370: cat stderr input: | (- *) + (1 2) = 1 ./calc.at:1370: $PREPARSER ./calc input 1.1: syntax error, unexpected invalid token ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: $PREPARSER ./calc input stderr: 1.1: syntax error, unexpected invalid token stderr: stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 504. calc.at:1392: testing Calculator %glr-parser %name-prefix "calc" ... ./calc.at:1392: mv calc.y.tmp calc.y ./calc.at:1392: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y syntax error stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1371: cat stderr syntax error ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1374: cat stderr ./calc.at:1375: cat stderr | (* *) + (*) + (*) ./calc.at:1371: $PREPARSER ./calc input ./calc.at:1370: cat stderr stderr: input: input: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) stderr: 505. calc.at:1393: testing Calculator %glr-parser api.prefix={calc} ... ./calc.at:1393: mv calc.y.tmp calc.y | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1374: $PREPARSER ./calc input stderr: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) | 1 = 2 = 3 stdout: ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1387: cat stderr ./calc.at:1389: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1393: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1371: cat stderr input: ./calc.at:1392: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS input: stderr: | 1//2 ./calc.at:1387: $PREPARSER ./calc input input: stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1371: $PREPARSER ./calc input syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: stderr: syntax error ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.7: syntax error, unexpected '=' | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: $PREPARSER ./calc input syntax error syntax error syntax error syntax error error: 4444 != 1 stderr: | (* *) + (*) + (*) ./calc.at:1370: $PREPARSER ./calc input ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error stderr: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) stderr: 1.7: syntax error, unexpected '=' stderr: ./calc.at:1371: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) | 1 2 input: ./calc.at:1389: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1371: $PREPARSER ./calc input stderr: stderr: syntax error ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1374: cat stderr stderr: ./calc.at:1375: cat stderr ./calc.at:1370: cat stderr stdout: ./calc.at:1390: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: input: | 1 + 2 * 3 + !+ ++ ./calc.at:1370: $PREPARSER ./calc input syntax error input: stderr: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1390: $PREPARSER ./calc input stderr: | (!!) + (1 2) = 1 | | +1 ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: cat stderr stderr: ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1374: $PREPARSER ./calc input stderr: stderr: 2.1: syntax error, unexpected '+' input: ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1390: $PREPARSER ./calc input stderr: stderr: 1.3: syntax error ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error error: 2222 != 1 ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.3: syntax error ./calc.at:1370: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 2.1: syntax error, unexpected '+' stderr: syntax error error: 2222 != 1 ./calc.at:1371: cat stderr input: | error ./calc.at:1387: $PREPARSER ./calc input input: | 1 + 2 * 3 + !* ++ ./calc.at:1371: $PREPARSER ./calc input stderr: ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.14: memory exhausted stderr: syntax error ./calc.at:1389: cat stderr ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !- ++ ./calc.at:1370: $PREPARSER ./calc input ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1375: cat stderr stderr: 1.14: memory exhausted input: syntax error ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: cat stderr stderr: input: ./calc.at:1371: cat stderr | 1//2 ./calc.at:1390: $PREPARSER ./calc input ./calc.at:1374: cat stderr ./calc.at:1375: $PREPARSER ./calc /dev/null | 1//2 stderr: ./calc.at:1389: $PREPARSER ./calc input stderr: input: 1.3: syntax error | (#) + (#) = 2222 ./calc.at:1371: $PREPARSER ./calc input ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error, unexpected end of file stderr: ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error input: ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error, unexpected end of file stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1370: cat stderr | (- *) + (1 2) = 1 ./calc.at:1374: $PREPARSER ./calc input stderr: 1.3: syntax error stderr: ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1387: cat stderr syntax error ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1375: cat stderr ./calc.at:1371: cat stderr syntax error syntax error error: 2222 != 1 ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: input: stdout: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: input: ./calc.at:1375: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1391: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1387: $PREPARSER ./calc input syntax error syntax error error: 2222 != 1 | 1 + 2 * 3 + !* ++ ./calc.at:1370: $PREPARSER ./calc input stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 input: syntax error ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: ./calc.at:1391: $PREPARSER ./calc input stderr: syntax error stderr: | (1 + #) = 1111 1.14: memory exhausted ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1371: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: cat stderr stderr: ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.14: memory exhausted stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1371: cat stderr ./calc.at:1375: cat stderr input: input: input: ./calc.at:1389: cat stderr | (# + 1) = 1111 ./calc.at:1371: $PREPARSER ./calc input | 1 2 ./calc.at:1391: $PREPARSER ./calc input stderr: ./calc.at:1370: cat stderr 1.3: syntax error | error ./calc.at:1390: $PREPARSER ./calc input ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error: invalid character: '#' stderr: input: | (!!) + (1 2) = 1 ./calc.at:1387: cat stderr ./calc.at:1375: $PREPARSER ./calc input 1.3: syntax error 1.1: syntax error input: input: input: ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1387: $PREPARSER ./calc input ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1374: cat stderr stderr: | (#) + (#) = 2222 stderr: syntax error ./calc.at:1370: $PREPARSER ./calc input ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: $PREPARSER ./calc input stderr: stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: 1.1: syntax error syntax error 1.2: syntax error: invalid character: '#' ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (* *) + (*) + (*) ./calc.at:1374: $PREPARSER ./calc input stderr: ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1391: cat stderr ./calc.at:1375: cat stderr syntax error syntax error syntax error ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1371: cat stderr input: | 1//2 ./calc.at:1391: $PREPARSER ./calc input stderr: 1.3: syntax error ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | (1 + # + 1) = 1111 ./calc.at:1371: $PREPARSER ./calc input stderr: | (- *) + (1 2) = 1 ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1370: cat stderr stderr: syntax error syntax error syntax error 1.6: syntax error: invalid character: '#' ./calc.at:1390: cat stderr ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error stderr: ./calc.at:1389: cat stderr ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: cat stderr 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 = 2 = 3 ./calc.at:1390: $PREPARSER ./calc input stderr: 1.7: syntax error ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1387: $PREPARSER ./calc /dev/null stderr: stderr: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1371: cat stderr syntax error input: | 1 = 2 = 3 ./calc.at:1389: $PREPARSER ./calc input ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 stderr: stderr: 1.7: syntax error ./calc.at:1391: cat stderr ./calc.at:1370: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' syntax error ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | error stderr: ./calc.at:1391: $PREPARSER ./calc input stderr: ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error stderr: 1.1: syntax error syntax error ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1374: cat stderr ./calc.at:1375: cat stderr | (1 + 1) / (1 - 1) stderr: ./calc.at:1371: $PREPARSER ./calc input ./calc.at:1390: cat stderr stderr: stderr: 1.6: syntax error: invalid character: '#' input: | | +1 input: ./calc.at:1390: $PREPARSER ./calc input input: 1.1: syntax error ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 2.1: syntax error ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) 1.11-17: error: null divisor | 1 + 2 * 3 + !+ ++ ./calc.at:1374: $PREPARSER ./calc input ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1375: $PREPARSER ./calc input stderr: stderr: 2.1: syntax error ./calc.at:1389: cat stderr ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1370: cat stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1374: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.11-17: error: null divisor ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: cat stderr input: input: ./calc.at:1387: cat stderr | | +1 stderr: ./calc.at:1389: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ ./calc.at:1374: $PREPARSER ./calc input input: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1371: cat stderr stderr: | (# + 1) = 1111 input: ./calc.at:1370: $PREPARSER ./calc input stderr: ./calc.at:1391: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1387: $PREPARSER ./calc input syntax error stderr: ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: ./calc.at:1390: $PREPARSER ./calc /dev/null syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error stderr: stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 1.1: syntax error 1.2: syntax error: invalid character: '#' ./calc.at:1392: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 497. calc.at:1371: ok ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error | 1 = 2 = 3 ./calc.at:1391: $PREPARSER ./calc input stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1392: $PREPARSER ./calc input stderr: ./calc.at:1375: cat stderr 1.7: syntax error 1.2: syntax error: invalid character: '#' ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: 1.7: syntax error ./calc.at:1387: cat stderr stderr: input: | 1 2 ./calc.at:1392: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ stderr: ./calc.at:1370: cat stderr ./calc.at:1390: cat stderr ./calc.at:1375: $PREPARSER ./calc input 506. calc.at:1394: testing Calculator %glr-parser %verbose ... ./calc.at:1394: mv calc.y.tmp calc.y ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: syntax error ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1390: $PREPARSER ./calc input stderr: ./calc.at:1389: cat stderr stderr: input: ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1394: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error input: | (1 + # + 1) = 1111 ./calc.at:1374: cat stderr | (!!) + (1 2) = 1 ./calc.at:1370: $PREPARSER ./calc input ./calc.at:1389: $PREPARSER ./calc /dev/null ./calc.at:1387: $PREPARSER ./calc input stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error error: 2222 != 1 stderr: ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1391: cat stderr syntax error ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | | +1 ./calc.at:1391: $PREPARSER ./calc input input: ./calc.at:1375: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: 2.1: syntax error ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !* ++ ./calc.at:1374: $PREPARSER ./calc input syntax error error: 2222 != 1 ./calc.at:1392: cat stderr stderr: stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 stderr: stdout: ./calc.at:1393: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c input: stderr: | 1//2 ./calc.at:1392: $PREPARSER ./calc input memory exhausted ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1394: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS 2.1: syntax error stderr: input: 1.6: syntax error: invalid character: '#' input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: $PREPARSER ./calc input stderr: syntax error stderr: memory exhausted | 1 + 2 * 3 + !- ++ ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1370: cat stderr syntax error ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: | (1 + 1) / (1 - 1) stderr: ./calc.at:1370: $PREPARSER ./calc input ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error stderr: ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11-17: error: null divisor ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: cat stderr ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.11-17: error: null divisor ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: cat stderr ./calc.at:1374: cat stderr stderr: ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (!!) + (1 2) = 1 ./calc.at:1390: $PREPARSER ./calc input input: | 1 2 input: ./calc.at:1393: $PREPARSER ./calc input stderr: | (#) + (#) = 2222 stderr: ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1374: $PREPARSER ./calc input syntax error ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1389: cat stderr ./calc.at:1375: cat stderr input: ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1370: cat stderr input: | (- *) + (1 2) = 1 ./calc.at:1387: $PREPARSER ./calc input stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1389: $PREPARSER ./calc input syntax error syntax error error: 2222 != 1 ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1391: cat stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' syntax error syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error error: 2222 != 1 stderr: ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1392: cat stderr stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 | 1 + 2 * 3 + !* ++ ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1391: $PREPARSER ./calc /dev/null stderr: stderr: ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error syntax error syntax error syntax error error: 4444 != 1 stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.14: memory exhausted ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 496. calc.at:1370: ok 1.1: syntax error ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: 1.1: syntax error stderr: | error ./calc.at:1392: $PREPARSER ./calc input ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: cat stderr stderr: syntax error ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: cat stderr input: | (* *) + (*) + (*) ./calc.at:1387: $PREPARSER ./calc input 1.14: memory exhausted stderr: stderr: ./calc.at:1391: cat stderr syntax error syntax error syntax error ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: cat stderr syntax error ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1374: cat stderr syntax error syntax error syntax error 507. calc.at:1395: testing Calculator %glr-parser parse.error=verbose ... input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1391: $PREPARSER ./calc input input: | (1 + #) = 1111 ./calc.at:1374: $PREPARSER ./calc input ./calc.at:1389: cat stderr stderr: input: syntax error: invalid character: '#' ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1395: mv calc.y.tmp calc.y syntax error: invalid character: '#' ./calc.at:1375: cat stderr | (- *) + (1 2) = 1 ./calc.at:1390: $PREPARSER ./calc input input: ./calc.at:1395: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y input: | (#) + (#) = 2222 ./calc.at:1375: $PREPARSER ./calc input stderr: | 1//2 ./calc.at:1393: $PREPARSER ./calc input stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error stderr: ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1389: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1387: cat stderr ./calc.at:1392: cat stderr stderr: stderr: syntax error ./calc.at:1374: cat stderr ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error error: 2222 != 1 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1391: cat stderr ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stdout: ./types.at:139: $PREPARSER ./test ./calc.at:1375: cat stderr stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1387: $PREPARSER ./calc input input: input: stderr: input: ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 | (!!) + (1 2) = 1 ./calc.at:1391: $PREPARSER ./calc input | (# + 1) = 1111 ./calc.at:1392: $PREPARSER ./calc input ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1374: $PREPARSER ./calc input ./calc.at:1393: cat stderr input: | (1 + #) = 1111 ./calc.at:1375: $PREPARSER ./calc input ======== Testing with C++ standard flags: '' ./calc.at:1390: cat stderr stderr: stderr: 1.6: syntax error: invalid character: '#' syntax error ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error error: 2222 != 1 ./calc.at:1395: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: syntax error: invalid character: '#' input: stderr: ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' | 1 + 2 * 3 + !- ++ ./calc.at:1387: $PREPARSER ./calc input stderr: input: ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: syntax error ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error ./calc.at:1393: $PREPARSER ./calc input 1.11: syntax error 1.1-16: error: 2222 != 1 | (* *) + (*) + (*) ./calc.at:1390: $PREPARSER ./calc input stderr: stderr: syntax error: invalid character: '#' stderr: syntax error ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error ./calc.at:1375: cat stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 ./calc.at:1375: $PREPARSER ./calc input stderr: ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1393: cat stderr stdout: ./types.at:139: ./check stderr: input: 1.2: syntax error: invalid character: '#' ./calc.at:1389: cat stderr ./calc.at:1374: cat stderr | 1 = 2 = 3 ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: $PREPARSER ./calc input stderr: syntax error ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: input: ./calc.at:1391: cat stderr ./calc.at:1392: cat stderr | (1 + # + 1) = 1111 1.2: syntax error: invalid character: '#' ./calc.at:1374: $PREPARSER ./calc input stderr: stderr: syntax error input: input: syntax error: invalid character: '#' ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1391: $PREPARSER ./calc input ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (- *) + (1 2) = 1 ./calc.at:1389: $PREPARSER ./calc input 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1387: cat stderr ./calc.at:1375: cat stderr stderr: syntax error: invalid character: '#' syntax error syntax error error: 2222 != 1 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 stderr: syntax error syntax error error: 2222 != 1 input: | | +1 input: ./calc.at:1392: $PREPARSER ./calc input ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !* ++ ./calc.at:1387: $PREPARSER ./calc input ./calc.at:1390: cat stderr ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: input: ./calc.at:1393: cat stderr syntax error memory exhausted ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1391: cat stderr | (1 + # + 1) = 1111 input: ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: memory exhausted stderr: input: | 1 + 2 * 3 + !+ ++ | | +1 syntax error ./calc.at:1393: $PREPARSER ./calc input ./calc.at:1390: $PREPARSER ./calc input | (* *) + (*) + (*) ./calc.at:1391: $PREPARSER ./calc input ./calc.at:1374: cat stderr stderr: stderr: stderr: syntax error ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1389: cat stderr ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error input: input: | (1 + 1) / (1 - 1) ./calc.at:1374: $PREPARSER ./calc input | (* *) + (*) + (*) ./calc.at:1389: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: syntax error syntax error syntax error ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 error: null divisor 1.6: syntax error: invalid character: '#' ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ ./calc.at:1390: $PREPARSER ./calc input ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1393: cat stderr ./calc.at:1391: cat stderr syntax error syntax error syntax error stderr: ./calc.at:1387: cat stderr ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: error: null divisor input: | (#) + (#) = 2222 ./calc.at:1387: $PREPARSER ./calc input stderr: ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: $PREPARSER ./calc /dev/null ./calc.at:1375: cat stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: syntax error ./calc.at:1392: cat stderr ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: stderr: ./calc.at:1392: $PREPARSER ./calc /dev/null | 1 + 2 * 3 + !+ ++ | (1 + 1) / (1 - 1) ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1391: $PREPARSER ./calc input stderr: stderr: ./calc.at:1389: cat stderr ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: input: stderr: | 1 + 2 * 3 + !+ ++ 1.11-17: error: null divisor | 1 + 2 * 3 + !- ++ ./calc.at:1389: $PREPARSER ./calc input ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1391: $PREPARSER ./calc input syntax error stderr: ./calc.at:1374: cat stderr ./calc.at:1387: cat stderr stderr: ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: cat stderr stderr: stderr: ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11-17: error: null divisor stderr: input: | 123 input: input: ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1374: $PREPARSER ./calc --num input ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !* ++ | (1 + #) = 1111 ./calc.at:1387: $PREPARSER ./calc input ./calc.at:1392: cat stderr ./calc.at:1390: $PREPARSER ./calc input input: input: ./calc.at:1375: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1392: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ stderr: stderr: ./calc.at:1389: $PREPARSER ./calc input stderr: ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.14: memory exhausted stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1374: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1393: cat stderr syntax error: invalid character: '#' ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' input: stderr: stderr: | 123 ./calc.at:1391: cat stderr ./calc.at:1375: $PREPARSER ./calc --num input stderr: input: 1.14: memory exhausted | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1393: $PREPARSER ./calc input input: ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 ./calc.at:1374: $PREPARSER ./calc --num input stderr: ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error syntax error syntax error syntax error error: 4444 != 1 stderr: stderr: ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !* ++ syntax error ./calc.at:1391: $PREPARSER ./calc input stderr: ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1390: cat stderr syntax error syntax error syntax error syntax error error: 4444 != 1 stderr: stdout: ./calc.at:1392: cat stderr ./calc.at:1394: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c 1.14: memory exhausted ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1375: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: input: | (!!) + (1 2) = 1 1.14: memory exhausted ./calc.at:1392: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1394: $PREPARSER ./calc input input: stderr: ./calc.at:1387: cat stderr stderr: stderr: syntax error input: ./calc.at:1389: cat stderr ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 syntax error error: 2222 != 1 ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1390: $PREPARSER ./calc input ./calc.at:1375: $PREPARSER ./calc --num input ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error error: 2222 != 1 stderr: ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: input: ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 + 2 * 3 + !* ++ 1.3: syntax error, unexpected '+', expecting end of file input: ./calc.at:1389: $PREPARSER ./calc input stderr: stderr: memory exhausted ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: $PREPARSER ./calc input ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' input: ./calc.at:1391: cat stderr ./calc.at:1393: cat stderr | 1 2 ./calc.at:1394: $PREPARSER ./calc input stderr: ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error: invalid character: '#' stderr: ./calc.at:1392: cat stderr ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr memory exhausted stderr: input: stderr: syntax error: invalid character: '#' 1.3: syntax error, unexpected '+', expecting end of file ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: syntax error | (#) + (#) = 2222 | (- *) + (1 2) = 1 ./calc.at:1391: $PREPARSER ./calc input ./calc.at:1392: $PREPARSER ./calc input stderr: stderr: syntax error syntax error error: 2222 != 1 ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: syntax error syntax error error: 2222 != 1 ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1374: cat stderr ./calc.at:1393: $PREPARSER ./calc input ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1390: cat stderr stderr: ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error error: 2222 != 1 input: ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1375: cat stderr ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: cat stderr | 1 + 2 * 3 ./calc.at:1374: $PREPARSER ./calc --exp input stderr: stderr: input: stderr: | (1 + #) = 1111 syntax error error: 2222 != 1 ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1389: cat stderr ./calc.at:1390: $PREPARSER ./calc input input: ./calc.at:1394: cat stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 ./calc.at:1375: $PREPARSER ./calc --exp input | (1 + # + 1) = 1111 ./calc.at:1387: $PREPARSER ./calc input stderr: ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error: invalid character: '#' ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1374: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: | (#) + (#) = 2222 syntax error: invalid character: '#' ./calc.at:1389: $PREPARSER ./calc input ./calc.at:1392: cat stderr stderr: ./calc.at:1391: cat stderr syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: input: | (* *) + (*) + (*) ./calc.at:1392: $PREPARSER ./calc input | 1//2 ./calc.at:1394: $PREPARSER ./calc input stderr: syntax error syntax error syntax error stderr: ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error syntax error ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 1.6: syntax error: invalid character: '#' ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 498. calc.at:1374: ok ./calc.at:1375: $EGREP -c -v 'Return for a new token:|LAC:' stderr syntax error ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 ./calc.at:1391: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1387: cat stderr stderr: ./calc.at:1392: cat stderr 499. calc.at:1375: ok ./calc.at:1393: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (1 + 1) / (1 - 1) ./calc.at:1387: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' input: error: null divisor ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1393: $PREPARSER ./calc input ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: stderr: error: null divisor | 1 + 2 * 3 + !+ ++ ./calc.at:1392: $PREPARSER ./calc input ./calc.at:1394: cat stderr syntax error syntax error error: 2222 != 1 ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: cat stderr stderr: input: ./calc.at:1390: cat stderr | (1 + #) = 1111 ./calc.at:1389: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' syntax error syntax error error: 2222 != 1 input: input: | 1 + 2 * 3 + !- ++ ./calc.at:1392: $PREPARSER ./calc input ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error ./calc.at:1394: $PREPARSER ./calc input stderr: input: ./calc.at:1391: cat stderr stderr: 508. calc.at:1397: testing Calculator %glr-parser api.pure %locations ... ./calc.at:1397: mv calc.y.tmp calc.y ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 ./calc.at:1390: $PREPARSER ./calc input stderr: stderr: ./calc.at:1397: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y syntax error ./calc.at:1387: cat stderr ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (# + 1) = 1111 ./calc.at:1391: $PREPARSER ./calc input stderr: syntax error 500. calc.at:1387: ok 1.2: syntax error: invalid character: '#' ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1389: cat stderr stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (# + 1) = 1111 ./calc.at:1389: $PREPARSER ./calc input ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error: invalid character: '#' ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 509. calc.at:1398: testing Calculator %glr-parser parse.error=verbose %locations ... ./calc.at:1398: mv calc.y.tmp calc.y ./calc.at:1398: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1393: cat stderr input: stderr: ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1390: cat stderr | (* *) + (*) + (*) ./calc.at:1393: $PREPARSER ./calc input ./calc.at:1392: cat stderr stderr: syntax error syntax error syntax error ./calc.at:1398: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1394: cat stderr stderr: syntax error syntax error syntax error ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | 1 = 2 = 3 ./calc.at:1394: $PREPARSER ./calc input | 1 + 2 * 3 + !* ++ ./calc.at:1392: $PREPARSER ./calc input stderr: stderr: syntax error ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr memory exhausted ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error input: | (1 + # + 1) = 1111 ./calc.at:1390: $PREPARSER ./calc input stderr: memory exhausted stderr: ./calc.at:1397: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS 1.6: syntax error: invalid character: '#' ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1391: cat stderr ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 510. calc.at:1400: testing Calculator %glr-parser parse.error=custom %locations %header %name-prefix "calc" %verbose ... ./calc.at:1400: mv calc.y.tmp calc.y ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stdout: input: | (1 + # + 1) = 1111 ./calc.at:1391: $PREPARSER ./calc input ./calc.at:1395: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: cat stderr stderr: ./calc.at:1392: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1389: cat stderr ./calc.at:1393: cat stderr input: | (1 + 1) / (1 - 1) ./calc.at:1390: $PREPARSER ./calc input input: stderr: input: ./calc.at:1400: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | (#) + (#) = 2222 ./calc.at:1392: $PREPARSER ./calc input 1.11-17: error: null divisor | 1 + 2 * 3 + !+ ++ ./calc.at:1393: $PREPARSER ./calc input ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1394: cat stderr input: ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | | +1 ./calc.at:1394: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: input: stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1393: $PREPARSER ./calc input input: ./calc.at:1395: $PREPARSER ./calc input syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: | (1 + # + 1) = 1111 ./calc.at:1389: $PREPARSER ./calc input stderr: ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error syntax error: invalid character: '#' ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: cat stderr ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error: invalid character: '#' ./calc.at:1400: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1391: cat stderr 502. calc.at:1390: ok stderr: stderr: syntax error input: input: | 1 2 ./calc.at:1395: $PREPARSER ./calc input ./calc.at:1392: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1391: $PREPARSER ./calc input stderr: ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.11-17: error: null divisor ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: syntax error, unexpected number | (1 + #) = 1111 ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: $PREPARSER ./calc input stderr: syntax error, unexpected number ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error: invalid character: '#' ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' 1.11-17: error: null divisor 511. calc.at:1401: testing Calculator %glr-parser parse.error=custom %locations %header %name-prefix "calc" %verbose api.pure ... ./calc.at:1389: cat stderr ./calc.at:1401: mv calc.y.tmp calc.y ./calc.at:1394: cat stderr ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1394: $PREPARSER ./calc /dev/null ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1401: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1395: cat stderr ./calc.at:1393: cat stderr input: stderr: | (1 + 1) / (1 - 1) syntax error ./calc.at:1389: $PREPARSER ./calc input ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: cat stderr input: stderr: | 1//2 ./calc.at:1395: $PREPARSER ./calc input error: null divisor input: ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1391: cat stderr | 1 + 2 * 3 + !* ++ stderr: ./calc.at:1393: $PREPARSER ./calc input error: null divisor stderr: input: memory exhausted ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 stderr: stderr: ./calc.at:1392: $PREPARSER ./calc input memory exhausted syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected '/', expecting number or '-' or '(' or '!' syntax error 503. calc.at:1391: ok ./calc.at:1401: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1395: cat stderr ./calc.at:1389: cat stderr ./calc.at:1393: cat stderr stderr: 501. calc.at:1389: ok syntax error: invalid character: '#' input: | error ./calc.at:1395: $PREPARSER ./calc input input: stderr: | (#) + (#) = 2222 ./calc.at:1393: $PREPARSER ./calc input syntax error, unexpected invalid token ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 512. calc.at:1402: testing Calculator %glr-parser parse.error=detailed %locations %header %name-prefix "calc" %verbose ... ./calc.at:1392: cat stderr ./calc.at:1394: cat stderr stderr: ./calc.at:1402: mv calc.y.tmp calc.y stderr: input: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1394: $PREPARSER ./calc input ./calc.at:1402: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: syntax error, unexpected invalid token input: | (1 + # + 1) = 1111 ./calc.at:1392: $PREPARSER ./calc input syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' stderr: ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 stderr: syntax error: invalid character: '#' ./calc.at:1395: cat stderr input: | 1 = 2 = 3 513. calc.at:1403: testing Calculator %glr-parser parse.error=verbose %locations %header %name-prefix "calc" %verbose ... ./calc.at:1403: mv calc.y.tmp calc.y ./calc.at:1395: $PREPARSER ./calc input stderr: syntax error, unexpected '=' ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1403: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected '=' ./calc.at:1394: cat stderr ./calc.at:1392: cat stderr ./calc.at:1393: cat stderr ./calc.at:1403: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS input: ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 input: ./calc.at:1394: $PREPARSER ./calc input input: stderr: ./calc.at:1395: cat stderr | (1 + #) = 1111 ./calc.at:1393: $PREPARSER ./calc input syntax error error: 2222 != 1 | (1 + 1) / (1 - 1) stderr: ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: $PREPARSER ./calc input syntax error: invalid character: '#' stderr: ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error error: 2222 != 1 error: null divisor ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | | +1 stderr: stderr: ./calc.at:1395: $PREPARSER ./calc input syntax error: invalid character: '#' stderr: error: null divisor syntax error, unexpected '+' ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error, unexpected '+' ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1394: cat stderr ./calc.at:1392: cat stderr ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: cat stderr 504. calc.at:1392: ok ./calc.at:1395: cat stderr input: input: | (# + 1) = 1111 | (- *) + (1 2) = 1 ./calc.at:1393: $PREPARSER ./calc input ./calc.at:1395: $PREPARSER ./calc /dev/null ./calc.at:1394: $PREPARSER ./calc input stderr: stdout: stderr: stderr: syntax error syntax error error: 2222 != 1 ./calc.at:1398: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1398: $PREPARSER ./calc input syntax error, unexpected end of input stderr: ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error error: 2222 != 1 stderr: stderr: syntax error, unexpected end of input syntax error: invalid character: '#' stderr: 514. calc.at:1405: testing Calculator %glr-parser parse.error=custom %locations %header %name-prefix "calc" %verbose ... input: | 1 2 ./calc.at:1398: $PREPARSER ./calc input ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1405: mv calc.y.tmp calc.y stderr: 1.3: syntax error, unexpected number ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1405: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1395: cat stderr ./calc.at:1394: cat stderr stderr: 1.3: syntax error, unexpected number input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1395: $PREPARSER ./calc input | (* *) + (*) + (*) ./calc.at:1394: $PREPARSER ./calc input stderr: syntax error syntax error syntax error ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: cat stderr stderr: syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1398: cat stderr stderr: stderr: syntax error syntax error syntax error syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 input: ./calc.at:1405: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS | 1//2 ./calc.at:1398: $PREPARSER ./calc input input: stderr: | (1 + # + 1) = 1111 ./calc.at:1393: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1394: cat stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' syntax error: invalid character: '#' ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1395: cat stderr ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1398: cat stderr input: stderr: input: | 1 + 2 * 3 + !+ ++ ./calc.at:1394: $PREPARSER ./calc input | error ./calc.at:1398: $PREPARSER ./calc input stderr: stdout: stderr: input: ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: cat stderr ./calc.at:1397: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c | (!!) + (1 2) = 1 ./calc.at:1395: $PREPARSER ./calc input stderr: 1.1: syntax error, unexpected invalid token ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected number error: 2222 != 1 input: ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 | 1 + 2 * 3 + !- ++ ./calc.at:1397: $PREPARSER ./calc input syntax error, unexpected number error: 2222 != 1 ./calc.at:1394: $PREPARSER ./calc input stderr: stdout: input: stderr: ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1400: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h stderr: ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (1 + 1) / (1 - 1) ./calc.at:1393: $PREPARSER ./calc input stderr: error: null divisor 1.1: syntax error, unexpected invalid token ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1400: $PREPARSER ./calc input input: stderr: ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1397: $PREPARSER ./calc input stderr: stderr: input: stderr: ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 ./calc.at:1400: $PREPARSER ./calc input error: null divisor stderr: 1.3: syntax error ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./calc.at:1394: cat stderr ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) stderr: ./calc.at:1398: cat stderr stdout: stderr: input: 1.3: syntax error | 1 + 2 * 3 + !* ++ ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1394: $PREPARSER ./calc input ./calc.at:1400: cat stderr ./calc.at:1401: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1395: cat stderr ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: memory exhausted input: ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 ./calc.at:1398: $PREPARSER ./calc input input: stderr: stderr: | (- *) + (1 2) = 1 1.7: syntax error, unexpected '=' ./calc.at:1395: $PREPARSER ./calc input ./calc.at:1393: cat stderr ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr memory exhausted stderr: 1.7: syntax error, unexpected '=' input: stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 | 1//2 ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1400: $PREPARSER ./calc input ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1401: $PREPARSER ./calc input ./calc.at:1398: cat stderr 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: 505. calc.at:1393: ok 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 stderr: | | +1 ./calc.at:1398: $PREPARSER ./calc input stderr: 2.1: syntax error, unexpected '+' ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1400: cat stderr ./calc.at:1397: cat stderr input: ./calc.at:1394: cat stderr | 1 2 ./calc.at:1401: $PREPARSER ./calc input input: stderr: stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: | (#) + (#) = 2222 ./calc.at:1394: $PREPARSER ./calc input ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 2.1: syntax error, unexpected '+' input: stderr: | 1//2 syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1397: $PREPARSER ./calc input ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | error ./calc.at:1400: $PREPARSER ./calc input stderr: ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1398: cat stderr 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./calc.at:1398: $PREPARSER ./calc /dev/null ./calc.at:1395: cat stderr stderr: ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error, unexpected end of input ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error, unexpected end of input ./calc.at:1401: cat stderr input: ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) stderr: ./calc.at:1395: $PREPARSER ./calc input 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1398: cat stderr ./calc.at:1400: cat stderr ./calc.at:1394: cat stderr ./calc.at:1397: cat stderr input: 515. calc.at:1407: testing Calculator %glr-parser %debug ... ./calc.at:1407: mv calc.y.tmp calc.y ./calc.at:1407: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | 1//2 input: ./calc.at:1401: $PREPARSER ./calc input stderr: input: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' input: | (1 + #) = 1111 | error ./calc.at:1397: $PREPARSER ./calc input ./calc.at:1394: $PREPARSER ./calc input stderr: | 1 = 2 = 3 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1400: $PREPARSER ./calc input input: stderr: ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1398: $PREPARSER ./calc input 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) stderr: ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) stderr: 1.1: syntax error stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) stderr: stderr: stdout: ./calc.at:1400: cat stderr syntax error: invalid character: '#' ./calc.at:1402: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1401: cat stderr input: ./calc.at:1397: cat stderr ./calc.at:1407: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS | | +1 input: ./calc.at:1400: $PREPARSER ./calc input ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1402: $PREPARSER ./calc input ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: input: ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1395: cat stderr input: | 1 = 2 = 3 | error ./calc.at:1397: $PREPARSER ./calc input ./calc.at:1401: $PREPARSER ./calc input 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1398: cat stderr stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) 1.7: syntax error stderr: ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) input: ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: 1.7: syntax error | (!!) + (1 2) = 1 ./calc.at:1398: $PREPARSER ./calc input | 1 2 stderr: ./calc.at:1400: cat stderr stderr: ./calc.at:1402: $PREPARSER ./calc input stderr: input: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) stdout: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1395: $PREPARSER ./calc input ./calc.at:1403: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h 1.3: syntax error, unexpected number ./calc.at:1400: $PREPARSER ./calc /dev/null ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1401: cat stderr stderr: stderr: ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1403: $PREPARSER ./calc input 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error, unexpected number 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 input: ./calc.at:1400: cat stderr | 1 = 2 = 3 ./calc.at:1401: $PREPARSER ./calc input ./calc.at:1394: cat stderr ./calc.at:1397: cat stderr stderr: input: ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1400: $PREPARSER ./calc input stderr: input: stderr: stderr: ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) | (# + 1) = 1111 ./calc.at:1394: $PREPARSER ./calc input stderr: input: syntax error: invalid character: '#' input: ./calc.at:1402: cat stderr input: ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1403: $PREPARSER ./calc input ./calc.at:1398: cat stderr stderr: stderr: | | +1 1.3: syntax error, unexpected number ./calc.at:1397: $PREPARSER ./calc input input: ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 | 1 + 2 * 3 + !- ++ ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1398: $PREPARSER ./calc input ./calc.at:1401: cat stderr ./calc.at:1395: $PREPARSER ./calc input stderr: input: stderr: stderr: 1.3: syntax error, unexpected number stderr: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 stderr: ./calc.at:1402: $PREPARSER ./calc input 2.1: syntax error ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | | +1 ./calc.at:1401: $PREPARSER ./calc input stderr: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' stderr: 2.1: syntax error ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1400: cat stderr stderr: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 stderr: ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: input: ./calc.at:1403: cat stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' stderr: | (!!) + (1 2) = 1 ./calc.at:1400: $PREPARSER ./calc input input: | 1//2 ./calc.at:1403: $PREPARSER ./calc input stderr: stderr: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1401: cat stderr ./calc.at:1394: cat stderr ./calc.at:1395: cat stderr ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1401: $PREPARSER ./calc /dev/null ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !* ++ ./calc.at:1395: $PREPARSER ./calc input input: ./calc.at:1398: cat stderr ./calc.at:1402: cat stderr stderr: stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1403: cat stderr ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 | (1 + # + 1) = 1111 stderr: ./calc.at:1394: $PREPARSER ./calc input stderr: stderr: memory exhausted 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stdout: stderr: input: syntax error: invalid character: '#' ./calc.at:1401: cat stderr | error ./calc.at:1402: $PREPARSER ./calc input | error ./calc.at:1403: $PREPARSER ./calc input ./types.at:139: $PREPARSER ./test input: ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr memory exhausted stderr: stderr: | (* *) + (*) + (*) ./calc.at:1398: $PREPARSER ./calc input ./calc.at:1397: cat stderr input: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 1.1: syntax error, unexpected invalid token stderr: stderr: ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1401: $PREPARSER ./calc input ./calc.at:1400: cat stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error: invalid character: '#' ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: $PREPARSER ./calc /dev/null stderr: 1.1: syntax error, unexpected invalid token 1.1: syntax error, unexpected invalid token ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 | (- *) + (1 2) = 1 ./calc.at:1400: $PREPARSER ./calc input ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 stderr: ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1395: cat stderr ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1403: cat stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 451. types.at:139: ok stderr: stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 1.1: syntax error 1.1: syntax error, unexpected invalid token input: | 1 = 2 = 3 ./calc.at:1403: $PREPARSER ./calc input input: ./calc.at:1394: cat stderr ./calc.at:1400: cat stderr stderr: ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.7: syntax error, unexpected '=' ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (#) + (#) = 2222 ./calc.at:1395: $PREPARSER ./calc input ./calc.at:1401: cat stderr input: stderr: ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) ./calc.at:1400: $PREPARSER ./calc input 1.7: syntax error, unexpected '=' ./calc.at:1402: cat stderr input: stderr: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (!!) + (1 2) = 1 stderr: ./calc.at:1401: $PREPARSER ./calc input stderr: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: ./calc.at:1397: cat stderr 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 ./calc.at:1398: cat stderr ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + 1) / (1 - 1) ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1400: cat stderr ./calc.at:1394: $PREPARSER ./calc input ./calc.at:1397: $PREPARSER ./calc input stderr: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 stderr: ./calc.at:1403: cat stderr 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: input: | 1 = 2 = 3 stderr: | 1 + 2 * 3 + !+ ++ 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1398: $PREPARSER ./calc input error: null divisor input: ./calc.at:1401: cat stderr ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: $PREPARSER ./calc input | | +1 stderr: ./calc.at:1403: $PREPARSER ./calc input ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.7: syntax error, unexpected '=' error: null divisor ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !+ ++ ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1400: $PREPARSER ./calc input stderr: stderr: 2.1: syntax error, unexpected '+' stderr: stderr: ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.7: syntax error, unexpected '=' ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 516. calc.at:1408: testing Calculator %glr-parser parse.error=verbose %debug %locations %header %name-prefix "calc" %verbose ... ./calc.at:1408: mv calc.y.tmp calc.y stderr: input: 2.1: syntax error, unexpected '+' ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !- ++ ./calc.at:1397: cat stderr ./calc.at:1398: $PREPARSER ./calc input input: ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: | 1 + 2 * 3 + !- ++ ./calc.at:1400: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1395: cat stderr ./calc.at:1402: cat stderr ./calc.at:1401: $PREPARSER ./calc input ./calc.at:1394: cat stderr ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | (!!) + (1 2) = 1 input: ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: $PREPARSER ./calc input | | +1 ./calc.at:1402: $PREPARSER ./calc input ./calc.at:1403: cat stderr input: ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 506. calc.at:1394: ok 1.11: syntax error 1.1-16: error: 2222 != 1 2.1: syntax error, unexpected '+' ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1408: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: stderr: stderr: | (1 + #) = 1111 ./calc.at:1395: $PREPARSER ./calc input 2.1: syntax error, unexpected '+' ./calc.at:1403: $PREPARSER ./calc /dev/null stderr: syntax error: invalid character: '#' 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error, unexpected end of input 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1400: cat stderr ./calc.at:1398: cat stderr stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 stderr: ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' ./calc.at:1397: cat stderr input: stderr: 1.1: syntax error, unexpected end of input | 1 + 2 * 3 + !* ++ ./calc.at:1398: $PREPARSER ./calc input ./calc.at:1401: cat stderr stderr: input: 1.14: memory exhausted ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1397: $PREPARSER ./calc input ./calc.at:1402: cat stderr stderr: input: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) ./calc.at:1401: $PREPARSER ./calc input stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 stderr: input: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) | 1 + 2 * 3 + !* ++ ./calc.at:1400: $PREPARSER ./calc input ./calc.at:1402: $PREPARSER ./calc /dev/null 517. calc.at:1409: testing Calculator %glr-parser parse.error=verbose %debug %locations %header api.prefix={calc} api.token.prefix={TOK_} %verbose ... stderr: ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: mv calc.y.tmp calc.y ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.14: memory exhausted ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1401: cat stderr ./calc.at:1403: cat stderr stderr: ./calc.at:1395: cat stderr 1.14: memory exhausted 1.14: memory exhausted ./calc.at:1409: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1408: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1403: $PREPARSER ./calc input 1.1: syntax error, unexpected end of file ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | 1 + 2 * 3 + !+ ++ 1.1: syntax error, unexpected end of file ./calc.at:1401: $PREPARSER ./calc input stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: | (# + 1) = 1111 ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1395: $PREPARSER ./calc input stderr: ./calc.at:1400: cat stderr stderr: syntax error: invalid character: '#' ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: cat stderr ./calc.at:1398: cat stderr stderr: syntax error: invalid character: '#' ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1403: cat stderr input: ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1402: cat stderr input: | 1 + 2 * 3 + !- ++ | (#) + (#) = 2222 ./calc.at:1395: cat stderr input: ./calc.at:1401: $PREPARSER ./calc input ./calc.at:1400: $PREPARSER ./calc input input: stderr: stderr: | (!!) + (1 2) = 1 ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1403: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 input: stderr: | (#) + (#) = 2222 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 input: ./calc.at:1398: $PREPARSER ./calc input | (1 + # + 1) = 1111 ./calc.at:1395: $PREPARSER ./calc input | (* *) + (*) + (*) stderr: ./calc.at:1402: $PREPARSER ./calc input stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1409: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 1.2: syntax error 1.10: syntax error 1.16: syntax error stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1401: cat stderr ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1395: cat stderr stdout: ./calc.at:1403: cat stderr ./calc.at:1405: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1402: cat stderr | (- *) + (1 2) = 1 stderr: input: ./calc.at:1403: $PREPARSER ./calc input 1.2: syntax error 1.10: syntax error 1.16: syntax error input: | (1 + 1) / (1 - 1) | 1 + 2 * 3 + !* ++ ./calc.at:1395: $PREPARSER ./calc input stderr: ./calc.at:1401: $PREPARSER ./calc input 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: null divisor ./calc.at:1400: cat stderr stderr: ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 input: | (!!) + (1 2) = 1 ./calc.at:1402: $PREPARSER ./calc input stderr: ./calc.at:1398: cat stderr stderr: ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.14: memory exhausted error: null divisor ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: ./calc.at:1403: cat stderr input: | (1 + #) = 1111 stderr: ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1400: $PREPARSER ./calc input | (* *) + (*) + (*) ./calc.at:1403: $PREPARSER ./calc input stderr: ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 1.14: memory exhausted | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1405: $PREPARSER ./calc input ./calc.at:1395: cat stderr stderr: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: cat stderr stderr: ./calc.at:1401: cat stderr 1.6: syntax error: invalid character: '#' stderr: | (1 + #) = 1111 507. calc.at:1395: ok ./calc.at:1398: $PREPARSER ./calc input ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: cat stderr ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (#) + (#) = 2222 ./calc.at:1401: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' stderr: input: stderr: | 1 2 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1405: $PREPARSER ./calc input ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' input: stderr: 1.6: syntax error: invalid character: '#' input: | 1 + 2 * 3 + !+ ++ ./calc.at:1400: cat stderr ./calc.at:1397: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1402: $PREPARSER ./calc input stderr: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1403: cat stderr ./calc.at:1405: cat stderr | (# + 1) = 1111 ./calc.at:1400: $PREPARSER ./calc input stderr: ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error: invalid character: '#' 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 518. calc.at:1411: testing Calculator %glr-parser api.pure parse.error=verbose %debug %locations %header %name-prefix "calc" %verbose ... input: ./calc.at:1411: mv calc.y.tmp calc.y | 1//2 ./calc.at:1405: $PREPARSER ./calc input ./calc.at:1401: cat stderr stderr: ./calc.at:1411: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y input: input: 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !+ ++ input: stderr: ./calc.at:1403: $PREPARSER ./calc input ./calc.at:1398: cat stderr | (1 + #) = 1111 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1401: $PREPARSER ./calc input stderr: stderr: ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' | 1 + 2 * 3 + !- ++ stderr: ./calc.at:1397: $PREPARSER ./calc input ./calc.at:1405: cat stderr ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1400: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: input: | (# + 1) = 1111 | error input: | (1 + # + 1) = 1111 ./calc.at:1405: $PREPARSER ./calc input ./calc.at:1400: $PREPARSER ./calc input ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1398: $PREPARSER ./calc input stderr: stderr: stderr: stderr: 1.6: syntax error: invalid character: '#' 1.2: syntax error: invalid character: '#' ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1402: cat stderr input: | 1 + 2 * 3 + !- ++ ./calc.at:1403: $PREPARSER ./calc input stderr: ./calc.at:1401: cat stderr stderr: ./calc.at:1411: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 stderr: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1401: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' stderr: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) input: | (* *) + (*) + (*) ./calc.at:1402: $PREPARSER ./calc input ./calc.at:1397: cat stderr stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1398: cat stderr ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' input: | (1 + # + 1) = 1111 ./calc.at:1398: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' input: ./calc.at:1405: cat stderr | 1 + 2 * 3 + !* ++ ./calc.at:1403: cat stderr ./calc.at:1397: $PREPARSER ./calc input ./calc.at:1400: cat stderr stderr: 1.14: memory exhausted ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' input: stderr: ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.14: memory exhausted input: stderr: | 1 = 2 = 3 ./calc.at:1405: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' | 1 + 2 * 3 + !* ++ ./calc.at:1403: $PREPARSER ./calc input input: stderr: stderr: 1.14: memory exhausted ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1401: cat stderr stderr: | (1 + 1) / (1 - 1) ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1400: $PREPARSER ./calc input 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.14: memory exhausted stderr: stderr: ./calc.at:1398: cat stderr 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) 1.11-17: error: null divisor ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (1 + # + 1) = 1111 ./calc.at:1402: cat stderr ./calc.at:1401: $PREPARSER ./calc input 1.11-17: error: null divisor stderr: ./calc.at:1405: cat stderr ./calc.at:1397: cat stderr input: ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.6: syntax error: invalid character: '#' | 1 + 2 * 3 + !+ ++ input: ./calc.at:1402: $PREPARSER ./calc input | (#) + (#) = 2222 ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: $PREPARSER ./calc input stderr: input: | (1 + 1) / (1 - 1) ./calc.at:1398: $PREPARSER ./calc input ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor input: ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | | +1 ./calc.at:1405: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: stderr: ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11-17: error: null divisor 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) 1.6: syntax error: invalid character: '#' ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1400: cat stderr ./calc.at:1403: cat stderr stderr: ./calc.at:1405: cat stderr ./calc.at:1405: $PREPARSER ./calc /dev/null stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1401: cat stderr 510. calc.at:1400: ok ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1397: cat stderr stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1402: $PREPARSER ./calc input | (#) + (#) = 2222 ./calc.at:1403: $PREPARSER ./calc input 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1398: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1401: $PREPARSER ./calc input ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + #) = 1111 ./calc.at:1397: $PREPARSER ./calc input stderr: stderr: 509. calc.at:1398: ok stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1405: cat stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' 1.11-17: error: null divisor ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1402: cat stderr stderr: 1.6: syntax error: invalid character: '#' input: ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1401: cat stderr ./calc.at:1405: $PREPARSER ./calc input 519. calc.at:1413: testing Calculator %glr-parser api.pure parse.error=verbose %debug %locations %header %name-prefix "calc" %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1413: mv calc.y.tmp calc.y ./calc.at:1403: cat stderr stderr: input: ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1413: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | 1 + 2 * 3 + !* ++ 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: $PREPARSER ./calc input 511. calc.at:1401: ok ./calc.at:1397: cat stderr input: stderr: 1.14: memory exhausted ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1403: $PREPARSER ./calc input stderr: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 input: | (# + 1) = 1111 ./calc.at:1397: $PREPARSER ./calc input stderr: 520. calc.at:1414: testing Calculator %glr-parser api.pure parse.error=verbose %debug %locations %header api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... stderr: stderr: 1.14: memory exhausted stderr: stdout: 1.2: syntax error: invalid character: '#' 1.6: syntax error: invalid character: '#' ./calc.at:1405: cat stderr ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1414: mv calc.y.tmp calc.y ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1407: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1402: cat stderr input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1407: $PREPARSER ./calc input input: input: ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 521. calc.at:1416: testing Calculator %glr-parser %no-lines api.pure parse.error=verbose %debug %locations %header api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1416: mv calc.y.tmp calc.y | (!!) + (1 2) = 1 stderr: ./calc.at:1405: $PREPARSER ./calc input | (#) + (#) = 2222 ./calc.at:1402: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 7) Shifting token "number" (1.1: 7) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 7) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 7) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 10 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -3) Entering state 31 Next token is token '=' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: -3) -> $$ = nterm exp (1.1: -6) Entering state 30 Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: -6) -> $$ = nterm exp (1.1: -5) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 5) Shifting token "number" (1.1: 5) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 5) -> $$ = nterm exp (1.1: 5) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 5) -> $$ = nterm exp (1.1: -5) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -5) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -5) -> $$ = nterm exp (1.1: -5) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -5) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 10 Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: -1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 10 Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 1) Entering state 10 Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 29 Reading a token Next token is token '-' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: -1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -4) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 4) Shifting token "number" (1.1: 4) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 4) -> $$ = nterm exp (1.1: 4) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 4) -> $$ = nterm exp (1.1: -4) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -4) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -4) -> $$ = nterm exp (1.1: -4) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -4) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 2) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -1) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 29 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 2) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 8) Entering state 33 Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 8) -> $$ = nterm exp (1.1: 256) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 256) Shifting token "number" (1.1: 256) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 256) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 256) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 4) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 4) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 4) Entering state 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 4) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 64) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 64) Shifting token "number" (1.1: 64) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 64) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 64) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: cat stderr stderr: ./calc.at:1403: cat stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1414: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1413: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + # + 1) = 1111 ./calc.at:1397: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 7) Shifting token "number" (1.1: 7) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 7) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 7) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 10 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -3) Entering state 31 Next token is token '=' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: -3) -> $$ = nterm exp (1.1: -6) Entering state 30 Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: -6) -> $$ = nterm exp (1.1: -5) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 5) Shifting token "number" (1.1: 5) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 5) -> $$ = nterm exp (1.1: 5) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 5) -> $$ = nterm exp (1.1: -5) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -5) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -5) -> $$ = nterm exp (1.1: -5) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -5) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 10 Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: -1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 10 Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 1) Entering state 10 Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 29 Reading a token Next token is token '-' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: -1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -4) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 4) Shifting token "number" (1.1: 4) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 4) -> $$ = nterm exp (1.1: 4) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 4) -> $$ = nterm exp (1.1: -4) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -4) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -4) -> $$ = nterm exp (1.1: -4) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -4) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 2) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -1) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 29 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 2) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 8) Entering state 33 Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 8) -> $$ = nterm exp (1.1: 256) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 256) Shifting token "number" (1.1: 256) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 256) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 256) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 4) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 4) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 4) Entering state 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 4) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 64) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 64) Shifting token "number" (1.1: 64) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 64) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 64) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' input: 1.6: syntax error: invalid character: '#' ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 1.6: syntax error: invalid character: '#' | (# + 1) = 1111 ./calc.at:1403: $PREPARSER ./calc input | 1 2 ./calc.at:1407: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.1: 2) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1405: cat stderr ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.1: 2) ./calc.at:1402: cat stderr stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1397: cat stderr ./calc.at:1414: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS input: | (- *) + (1 2) = 1 ./calc.at:1405: $PREPARSER ./calc input input: stderr: | (1 + #) = 1111 ./calc.at:1402: $PREPARSER ./calc input 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + 1) / (1 - 1) ./calc.at:1397: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.11-17: error: null divisor ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 1.6: syntax error: invalid character: '#' ./calc.at:1403: cat stderr ./calc.at:1407: cat stderr stderr: 1.11-17: error: null divisor input: | (1 + # + 1) = 1111 ./calc.at:1403: $PREPARSER ./calc input ./calc.at:1405: cat stderr input: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: $PREPARSER ./calc input stderr: ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Reading a token Next token is token '/' (1.1: ) syntax error Error: popping token '/' (1.1: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1402: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Reading a token Next token is token '/' (1.1: ) syntax error Error: popping token '/' (1.1: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.1: ) input: | (# + 1) = 1111 input: ./calc.at:1402: $PREPARSER ./calc input | (* *) + (*) + (*) ./calc.at:1405: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' stderr: stderr: ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' stderr: stderr: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1397: cat stderr ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' ./calc.at:1403: cat stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1405: cat stderr ./calc.at:1407: cat stderr ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 508. calc.at:1397: ok input: | (1 + 1) / (1 - 1) ./calc.at:1403: $PREPARSER ./calc input stderr: input: ./calc.at:1402: cat stderr 1.11-17: error: null divisor ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !+ ++ | error input: ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1405: $PREPARSER ./calc input | (1 + # + 1) = 1111 ./calc.at:1402: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.11-17: error: null divisor Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1402: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) input: ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1403: cat stderr | 1 + 2 * 3 + !- ++ input: | (1 + 1) / (1 - 1) ./calc.at:1402: $PREPARSER ./calc input ./calc.at:1405: $PREPARSER ./calc input stderr: 513. calc.at:1403: ok ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11-17: error: null divisor ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor stderr: stdout: 522. calc.at:1426: testing Calculator lalr1.cc %header ... ./calc.at:1426: mv calc.y.tmp calc.y ./calc.at:1408: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h stderr: ./calc.at:1426: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1407: cat stderr ./calc.at:1402: cat stderr input: 512. calc.at:1402: ok | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1405: cat stderr stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) | 1 = 2 = 3 ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1426: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Reading a token Next token is token '=' (1.1: ) syntax error Error: popping nterm exp (1.1: 2) Error: popping token '=' (1.1: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 523. calc.at:1431: testing Calculator C++ ... input: stderr: ./calc.at:1431: mv calc.y.tmp calc.y stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) | 1 + 2 * 3 + !* ++ ./calc.at:1405: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Reading a token Next token is token '=' (1.1: ) syntax error Error: popping nterm exp (1.1: 2) Error: popping token '=' (1.1: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.1: ) ./calc.at:1431: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: stderr: | 1 2 stderr: 1.14: memory exhausted ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stderr: ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1409: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h 1.14: memory exhausted stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 524. calc.at:1432: testing Calculator C++ %locations ... ./calc.at:1432: mv calc.y.tmp calc.y ./calc.at:1432: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1409: $PREPARSER ./calc input ./calc.at:1405: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1431: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1407: cat stderr | (#) + (#) = 2222 ./calc.at:1405: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) input: input: | 1 2 | | +1 ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1409: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '+' (1.1: ) syntax error Error: popping nterm input (1.1: ) Cleanup: discarding lookahead token '+' (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) stdout: ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: cat stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1411: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h input: | 1//2 ./calc.at:1408: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '+' (1.1: ) syntax error Error: popping nterm input (1.1: ) Cleanup: discarding lookahead token '+' (1.1: ) stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1405: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1432: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1411: $PREPARSER ./calc input stderr: ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) | (1 + #) = 1111 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1405: $PREPARSER ./calc input ./calc.at:1409: cat stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 2 1.6: syntax error: invalid character: '#' ./calc.at:1411: $PREPARSER ./calc input ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: cat stderr stderr: 1.6: syntax error: invalid character: '#' stderr: input: | 1//2 ./calc.at:1407: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1409: $PREPARSER ./calc input input: ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1407: $PREPARSER ./calc /dev/null ./calc.at:1405: cat stderr stderr: Starting parse Entering state 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: Starting parse Entering state 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) | (# + 1) = 1111 ./calc.at:1405: $PREPARSER ./calc input ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1411: cat stderr 1.2: syntax error: invalid character: '#' ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1409: cat stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1405: cat stderr input: | 1//2 ./calc.at:1411: $PREPARSER ./calc input stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1409: $PREPARSER ./calc input ./calc.at:1407: cat stderr ./calc.at:1408: cat stderr stderr: stderr: stderr: input: | (1 + # + 1) = 1111 ./calc.at:1405: $PREPARSER ./calc input stdout: stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./types.at:139: $PREPARSER ./test 1.6: syntax error: invalid character: '#' ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' stderr: stderr: input: input: ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1411: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1407: $PREPARSER ./calc input stderr: ./calc.at:1405: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 2) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 3) Entering state 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token ')' (1.1: ) syntax error Error: popping token '+' (1.1: ) Error: popping nterm exp (1.1: 3) Shifting token error (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 31 Reading a token Next token is token '*' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 1) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token '*' (1.1: ) syntax error Error: popping token '*' (1.1: ) Error: popping nterm exp (1.1: 2) Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 3333) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 4444) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 4444) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 4444 != 1 -> $$ = nterm exp (1.1: 4444) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 4444) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + 1) / (1 - 1) ./calc.at:1405: $PREPARSER ./calc input stderr: 1.11-17: error: null divisor ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 2) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 3) Entering state 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token ')' (1.1: ) syntax error Error: popping token '+' (1.1: ) Error: popping nterm exp (1.1: 3) Shifting token error (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 31 Reading a token Next token is token '*' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 1) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token '*' (1.1: ) syntax error Error: popping token '*' (1.1: ) Error: popping nterm exp (1.1: 2) Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 3333) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 4444) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 4444) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 4444 != 1 -> $$ = nterm exp (1.1: 4444) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 4444) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) 452. types.at:139: ok | error stderr: ./calc.at:1411: $PREPARSER ./calc input 1.11-17: error: null divisor ./calc.at:1409: cat stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1405: cat stderr Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 514. calc.at:1405: ok ./calc.at:1407: cat stderr ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | (!!) + (1 2) = 1 ./calc.at:1407: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1409: $PREPARSER ./calc input stderr: ./calc.at:1408: cat stderr Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 16 Reducing stack 0 by rule 16 (line 121): $1 = token '!' (1.1: ) $2 = token '!' (1.1: ) Shifting token error (1.1: ) Entering state 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 16 Reducing stack 0 by rule 16 (line 121): $1 = token '!' (1.1: ) $2 = token '!' (1.1: ) Shifting token error (1.1: ) Entering state 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1408: $PREPARSER ./calc input stderr: ./calc.at:1411: cat stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 525. calc.at:1433: testing Calculator C++ %locations $NO_EXCEPTIONS_CXXFLAGS ... ./calc.at:1433: mv calc.y.tmp calc.y ./calc.at:1433: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: cat stderr stderr: input: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 526. calc.at:1434: testing Calculator C++ %locations api.location.type={Span} ... ./calc.at:1434: mv calc.y.tmp calc.y ./calc.at:1434: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y | 1 = 2 = 3 ./calc.at:1411: $PREPARSER ./calc input input: ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: stdout: ./calc.at:1413: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1408: cat stderr | (- *) + (1 2) = 1 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1409: cat stderr stderr: ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1433: $CXX $CPPFLAGS $CXXFLAGS $NO_EXCEPTIONS_CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1408: $PREPARSER ./calc /dev/null stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 9 Reducing stack 0 by rule 15 (line 120): $1 = token '-' (1.1: ) $2 = token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1411: cat stderr ./calc.at:1413: $PREPARSER ./calc input | | +1 stderr: ./calc.at:1409: $PREPARSER ./calc input input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) | | +1 ./calc.at:1411: $PREPARSER ./calc input ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 9 Reducing stack 0 by rule 15 (line 120): $1 = token '-' (1.1: ) $2 = token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1434: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS input: | 1 2 ./calc.at:1413: $PREPARSER ./calc input stderr: ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: cat stderr ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1408: cat stderr stderr: ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1411: cat stderr ./calc.at:1409: $PREPARSER ./calc /dev/null stdout: stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1416: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1411: $PREPARSER ./calc /dev/null stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) stderr: ./calc.at:1407: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1413: cat stderr input: ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1416: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1409: cat stderr input: ./calc.at:1408: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: input: stdout: | 1//2 ./calc.at:1413: $PREPARSER ./calc input ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) input: | (* *) + (*) + (*) ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1411: cat stderr stderr: | (!!) + (1 2) = 1 ./calc.at:1408: $PREPARSER ./calc input stderr: ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1414: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1409: $PREPARSER ./calc input input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 3333) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) | 1 2 ./calc.at:1416: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 128): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 128): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) input: stderr: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1414: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 3333) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1411: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: cat stderr ./calc.at:1409: cat stderr stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) | error ./calc.at:1413: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 2 ./calc.at:1414: $PREPARSER ./calc input stderr: ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) | (!!) + (1 2) = 1 ./calc.at:1409: $PREPARSER ./calc input ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 128): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: cat stderr ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 128): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | (- *) + (1 2) = 1 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1416: cat stderr ./calc.at:1408: $PREPARSER ./calc input stderr: stderr: ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1407: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 127): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) input: | (!!) + (1 2) = 1 ./calc.at:1411: $PREPARSER ./calc input input: ./calc.at:1409: cat stderr stderr: input: | 1//2 ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 14 Reducing stack 0 by rule 17 (line 122): $1 = token '!' (1.1: ) $2 = token '+' (1.1: ) Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1409: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 14 Reducing stack 0 by rule 17 (line 122): $1 = token '!' (1.1: ) $2 = token '+' (1.1: ) Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1414: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 127): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 127): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) | 1 + 2 * 3 + !- ++ ./calc.at:1407: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 127): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 13 Reducing stack 0 by rule 18 (line 123): $1 = token '!' (1.1: ) $2 = token '-' (1.1: ) Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | 1 = 2 = 3 ./calc.at:1408: cat stderr ./calc.at:1413: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 13 Reducing stack 0 by rule 18 (line 123): $1 = token '!' (1.1: ) $2 = token '-' (1.1: ) Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) stderr: | 1//2 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1414: $PREPARSER ./calc input ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (* *) + (*) + (*) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: cat stderr stderr: ./calc.at:1411: cat stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) stderr: ./calc.at:1416: cat stderr | (* *) + (*) + (*) ./calc.at:1409: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1407: cat stderr input: | 1 + 2 * 3 + !* ++ ./calc.at:1407: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 15 Reducing stack 0 by rule 19 (line 124): $1 = token '!' (1.1: ) $2 = token '*' (1.1: ) memory exhausted Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: input: ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error ./calc.at:1416: $PREPARSER ./calc input ./calc.at:1408: cat stderr ./calc.at:1413: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (- *) + (1 2) = 1 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 15 Reducing stack 0 by rule 19 (line 124): $1 = token '!' (1.1: ) $2 = token '*' (1.1: ) memory exhausted Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1411: $PREPARSER ./calc input ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) stderr: input: ./calc.at:1414: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 + 2 * 3 + !+ ++ Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | | +1 ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1413: $PREPARSER ./calc input ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 129): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) stderr: ./calc.at:1411: cat stderr ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1409: cat stderr input: | (* *) + (*) + (*) ./calc.at:1411: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1414: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 129): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: input: ./calc.at:1411: cat stderr Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !+ ++ ./calc.at:1409: $PREPARSER ./calc input input: | 1 + 2 * 3 + !+ ++ ./calc.at:1411: $PREPARSER ./calc input stderr: stderr: ./calc.at:1407: cat stderr | 1 + 2 * 3 + !- ++ stderr: ./calc.at:1408: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1416: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 129): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 130): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: | 1 = 2 = 3 input: ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1416: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 129): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (#) + (#) = 2222 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) input: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | 1 + 2 * 3 + !- ++ ./calc.at:1409: $PREPARSER ./calc input input: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) stderr: ./calc.at:1407: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ stderr: ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 130): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 130): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1414: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 130): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 2222) Shifting token "number" (1.1: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1413: cat stderr input: ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1413: $PREPARSER ./calc /dev/null | 1 = 2 = 3 stderr: ./calc.at:1414: $PREPARSER ./calc input stderr: ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 2222) Shifting token "number" (1.1: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1408: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: cat stderr input: | 1 + 2 * 3 + !* ++ ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 131): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 131): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: cat stderr | 1 + 2 * 3 + !* ++ ./calc.at:1409: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 131): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1407: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1411: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 131): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1408: cat stderr | | +1 ./calc.at:1416: $PREPARSER ./calc input input: | (1 + #) = 1111 ./calc.at:1407: $PREPARSER ./calc input stderr: stderr: ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Error: popping token '+' (1.1: ) Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1413: cat stderr input: ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1409: cat stderr | (#) + (#) = 2222 ./calc.at:1408: $PREPARSER ./calc input | 1 + 2 * 3 + !* ++ stderr: ./calc.at:1414: cat stderr ./calc.at:1411: $PREPARSER ./calc input stderr: stderr: ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Error: popping token '+' (1.1: ) Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1413: $PREPARSER ./calc input input: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | | +1 ./calc.at:1414: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) stderr: stderr: ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (#) + (#) = 2222 ./calc.at:1409: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1411: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: cat stderr ./calc.at:1408: cat stderr input: | (#) + (#) = 2222 ./calc.at:1411: $PREPARSER ./calc input ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1416: cat stderr ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) stderr: ./calc.at:1413: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: input: | (1 + #) = 1111 ./calc.at:1408: $PREPARSER ./calc input | (# + 1) = 1111 ./calc.at:1416: $PREPARSER ./calc /dev/null ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (!!) + (1 2) = 1 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: $PREPARSER ./calc input ./calc.at:1411: cat stderr Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1414: cat stderr stderr: ./calc.at:1409: cat stderr stderr: input: | (1 + #) = 1111 ./calc.at:1411: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: cat stderr ./calc.at:1414: $PREPARSER ./calc /dev/null ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + #) = 1111 stderr: stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1409: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (# + 1) = 1111 ./calc.at:1408: $PREPARSER ./calc input stderr: ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./calc.at:1432: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1411: cat stderr ./calc.at:1416: cat stderr ./calc.at:1407: cat stderr stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) input: | (# + 1) = 1111 input: ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1411: $PREPARSER ./calc input stderr: stderr: | (1 + # + 1) = 1111 ./calc.at:1407: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Error: popping token '+' (1.1: ) Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1409: cat stderr input: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1432: $PREPARSER ./calc input input: input: ./calc.at:1413: cat stderr stderr: ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: $PREPARSER ./calc input ./calc.at:1411: cat stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Error: popping token '+' (1.1: ) Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1432: $EGREP -c -v 'Return for a new token:|LAC:' stderr | (# + 1) = 1111 ./calc.at:1409: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1408: cat stderr input: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (- *) + (1 2) = 1 ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1414: cat stderr ./calc.at:1413: $PREPARSER ./calc input input: | (1 + # + 1) = 1111 ./calc.at:1411: $PREPARSER ./calc input | 1 2 ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1432: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.3: syntax error stderr: ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (1 + # + 1) = 1111 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: cat stderr ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: cat stderr stderr: input: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.3: syntax error input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1414: $PREPARSER ./calc input ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + 1) / (1 - 1) ./calc.at:1407: $PREPARSER ./calc input | (1 + # + 1) = 1111 ./calc.at:1409: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 2) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 2) Entering state 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 29 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 0) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 0) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 0) Entering state 32 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 10 (line 101): $1 = nterm exp (1.1: 2) $2 = token '/' (1.1: ) $3 = nterm exp (1.1: 0) error: null divisor -> $$ = nterm exp (1.1: 2) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 2) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 2) Entering state 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 29 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 0) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 0) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 0) Entering state 32 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 10 (line 101): $1 = nterm exp (1.1: 2) $2 = token '/' (1.1: ) $3 = nterm exp (1.1: 0) error: null divisor -> $$ = nterm exp (1.1: 2) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: ./calc.at:1432: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1411: $PREPARSER ./calc input stderr: ./calc.at:1413: cat stderr ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1416: cat stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1432: $PREPARSER ./calc input ./calc.at:1409: cat stderr ./calc.at:1414: cat stderr ./calc.at:1408: cat stderr | (* *) + (*) + (*) ./calc.at:1407: cat stderr stderr: ./calc.at:1413: $PREPARSER ./calc input stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + 1) / (1 - 1) ./calc.at:1409: $PREPARSER ./calc input input: stderr: stderr: 515. calc.at:1407: ok 1.3: syntax error | (!!) + (1 2) = 1 input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 108): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1416: $PREPARSER ./calc input ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + 1) / (1 - 1) ./calc.at:1408: $PREPARSER ./calc input stderr: input: ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 108): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (!!) + (1 2) = 1 ./calc.at:1414: $PREPARSER ./calc input ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 108): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 108): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1432: cat stderr ./calc.at:1413: cat stderr ./calc.at:1411: cat stderr ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !+ ++ ./calc.at:1413: $PREPARSER ./calc input input: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 518. calc.at:1411: ok | error ./calc.at:1432: $PREPARSER ./calc input ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1408: cat stderr stderr: ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: cat stderr ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 516. calc.at:1408: ok 1.1: syntax error ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1413: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) 517. calc.at:1409: 1.1: syntax error ok Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 527. calc.at:1435: testing Calculator C++ %header %locations parse.error=verbose %name-prefix "calc" %verbose ... ./calc.at:1435: mv calc.y.tmp calc.y ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1416: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1435: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y 528. calc.at:1437: testing Calculator C++ %locations parse.error=verbose api.prefix={calc} %verbose ... ./calc.at:1437: mv calc.y.tmp calc.y ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1413: cat stderr stderr: stdout: ./calc.at:1433: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1414: cat stderr | (- *) + (1 2) = 1 input: ./calc.at:1416: $PREPARSER ./calc input input: | 1 + 2 * 3 + !* ++ ./calc.at:1432: cat stderr stderr: ./calc.at:1413: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1433: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1433: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: | 1 2 ./calc.at:1433: $PREPARSER ./calc input ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1435: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS | 1 = 2 = 3 ./calc.at:1432: $PREPARSER ./calc input 1.3: syntax error ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.3: syntax error 1.7: syntax error input: ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (- *) + (1 2) = 1 stderr: ./calc.at:1414: $PREPARSER ./calc input 529. calc.at:1438: testing Calculator C++ %locations parse.error=verbose %debug %name-prefix "calc" %verbose ... 1.7: syntax error stderr: ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: mv calc.y.tmp calc.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1437: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS 530. calc.at:1440: testing Calculator C++ %locations parse.error=verbose %debug api.prefix={calc} %verbose ... ./calc.at:1440: mv calc.y.tmp calc.y ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1413: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: cat stderr ./calc.at:1416: cat stderr ./calc.at:1433: cat stderr ./calc.at:1414: cat stderr input: | (#) + (#) = 2222 ./calc.at:1413: $PREPARSER ./calc input input: | (* *) + (*) + (*) ./calc.at:1414: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | (* *) + (*) + (*) ./calc.at:1416: $PREPARSER ./calc input input: input: ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1//2 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1433: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | | +1 ./calc.at:1432: $PREPARSER ./calc input stderr: stderr: 1.3: syntax error ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1440: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 2.1: syntax error ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.3: syntax error Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1438: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS 2.1: syntax error ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stdout: ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1431: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1414: cat stderr input: ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !+ ++ ./calc.at:1414: $PREPARSER ./calc input input: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1413: cat stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1431: $PREPARSER ./calc input ./calc.at:1433: cat stderr ./calc.at:1416: cat stderr ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1432: cat stderr | error ./calc.at:1433: $PREPARSER ./calc input ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1432: $PREPARSER ./calc /dev/null stderr: 1.1: syntax error ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (1 + #) = 1111 ./calc.at:1413: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: | 1 + 2 * 3 + !+ ++ ./calc.at:1416: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: input: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | 1 + 2 * 3 + !- ++ ./calc.at:1414: $PREPARSER ./calc input ./calc.at:1431: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error stderr: ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: | 1 + 2 * 3 + !- ++ ./calc.at:1416: $PREPARSER ./calc input stderr: ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1432: cat stderr stdout: ./calc.at:1434: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc input: stderr: ./calc.at:1413: cat stderr ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1432: $PREPARSER ./calc input | 1 2 ./calc.at:1431: $PREPARSER ./calc input 1.1: syntax error stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1434: $PREPARSER ./calc input 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1416: cat stderr stderr: stderr: ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 input: stderr: ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error input: | 1 + 2 * 3 + !* ++ ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: $PREPARSER ./calc input ./calc.at:1434: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: | (# + 1) = 1111 ./calc.at:1413: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: syntax error stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: cat stderr input: ./calc.at:1414: cat stderr ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1434: $PREPARSER ./calc input stderr: ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1433: cat stderr input: | 1 + 2 * 3 + !* ++ ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: $PREPARSER ./calc input ./calc.at:1416: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.3: syntax error | (!!) + (1 2) = 1 input: ./calc.at:1432: $PREPARSER ./calc input stderr: ./calc.at:1431: cat stderr | (#) + (#) = 2222 ./calc.at:1416: $PREPARSER ./calc input ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: stderr: ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 = 2 = 3 ./calc.at:1433: $PREPARSER ./calc input 1.11: syntax error 1.1-16: error: 2222 != 1 stderr: 1.3: syntax error ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1//2 ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1413: cat stderr ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: $PREPARSER ./calc input 1.7: syntax error ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: ./calc.at:1414: cat stderr ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11: syntax error 1.1-16: error: 2222 != 1 stderr: 1.7: syntax error | (1 + # + 1) = 1111 syntax error ./calc.at:1413: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1434: cat stderr ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: stderr: | (#) + (#) = 2222 ./calc.at:1414: $PREPARSER ./calc input | 1//2 ./calc.at:1434: $PREPARSER ./calc input stdout: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1416: cat stderr ./calc.at:1426: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1433: cat stderr ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 stderr: ./calc.at:1416: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: cat stderr input: 1.3: syntax error | | +1 input: ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1433: $PREPARSER ./calc input ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1426: $PREPARSER ./calc input stderr: stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1431: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1432: cat stderr ./calc.at:1413: $PREPARSER ./calc input 1.3: syntax error ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1426: $EGREP -c -v 'Return for a new token:|LAC:' stderr 2.1: syntax error ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: | (- *) + (1 2) = 1 2.1: syntax error ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: $PREPARSER ./calc input ./calc.at:1434: cat stderr input: input: ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error | 1 2 ./calc.at:1426: $PREPARSER ./calc input ./calc.at:1431: $PREPARSER ./calc input ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: cat stderr stderr: stderr: stderr: ./calc.at:1413: cat stderr 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 input: syntax error ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1414: cat stderr ./calc.at:1434: $PREPARSER ./calc input ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 519. calc.at:1413: ok syntax error ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error stderr: 1.1: syntax error | (# + 1) = 1111 ./calc.at:1416: $PREPARSER ./calc input ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error input: stderr: | (1 + #) = 1111 ./calc.at:1433: cat stderr ./calc.at:1414: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1433: $PREPARSER ./calc /dev/null stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error ./calc.at:1416: cat stderr 1.1: syntax error ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + # + 1) = 1111 ./calc.at:1416: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.1: syntax error ./calc.at:1432: cat stderr ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1426: cat stderr stderr: ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: cat stderr 531. calc.at:1441: testing Calculator C++ %locations parse.error=verbose %debug api.prefix={calc} api.token.prefix={TOK_} %verbose ... ./calc.at:1441: mv calc.y.tmp calc.y ./calc.at:1441: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (# + 1) = 1111 ./calc.at:1414: $PREPARSER ./calc input stderr: ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1426: $PREPARSER ./calc input stderr: input: ./calc.at:1433: cat stderr | (* *) + (*) + (*) syntax error ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1432: $PREPARSER ./calc input stderr: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1433: $PREPARSER ./calc input 1.2: syntax error 1.10: syntax error 1.16: syntax error Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: cat stderr stderr: ./calc.at:1434: cat stderr 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error syntax error ./calc.at:1414: cat stderr ./calc.at:1441: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + # + 1) = 1111 ./calc.at:1414: $PREPARSER ./calc input stderr: ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: cat stderr | 1 = 2 = 3 input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1434: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1416: cat stderr 1.7: syntax error ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1426: cat stderr stderr: syntax error 1.7: syntax error ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | (1 + 1) / (1 - 1) ./calc.at:1416: $PREPARSER ./calc input ./calc.at:1433: cat stderr stderr: ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: | 1 + 2 * 3 + !+ ++ ./calc.at:1432: $PREPARSER ./calc input syntax error | error ./calc.at:1414: cat stderr input: ./calc.at:1426: $PREPARSER ./calc input stderr: ./calc.at:1434: cat stderr | (!!) + (1 2) = 1 ./calc.at:1433: $PREPARSER ./calc input stderr: ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1432: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: 1.11: syntax error 1.1-16: error: 2222 != 1 | | +1 ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: $PREPARSER ./calc input | (1 + 1) / (1 - 1) ./calc.at:1414: $PREPARSER ./calc input stderr: syntax error ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 2.1: syntax error stderr: ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1416: cat stderr input: | 1 + 2 * 3 + !- ++ ./calc.at:1432: $PREPARSER ./calc input ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 2.1: syntax error 521. calc.at:1416: ok ./calc.at:1431: cat stderr ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1426: cat stderr ./calc.at:1433: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: input: | | +1 | (- *) + (1 2) = 1 ./calc.at:1433: $PREPARSER ./calc input input: ./calc.at:1431: $PREPARSER ./calc input | 1 = 2 = 3 stderr: ./calc.at:1426: $PREPARSER ./calc input ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: ./calc.at:1414: cat stderr 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 syntax error ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error syntax error ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 520. calc.at:1414: ok stderr: ./calc.at:1434: cat stderr ./calc.at:1433: cat stderr syntax error ./calc.at:1432: cat stderr ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1434: $PREPARSER ./calc /dev/null input: | (* *) + (*) + (*) ./calc.at:1433: $PREPARSER ./calc input input: 532. calc.at:1443: testing Calculator C++ %header %locations parse.error=verbose %debug %name-prefix "calc" %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1443: mv calc.y.tmp calc.y ./calc.at:1443: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y | (#) + (#) = 2222 stderr: stderr: ./calc.at:1432: $PREPARSER ./calc input 1.1: syntax error 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.1: syntax error ./calc.at:1431: cat stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1426: cat stderr stderr: ./calc.at:1443: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' 533. calc.at:1445: testing Calculator C++ parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1445: mv calc.y.tmp calc.y ./calc.at:1445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1431: $PREPARSER ./calc /dev/null stderr: ./calc.at:1434: cat stderr syntax error input: ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | | +1 stderr: ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1434: $PREPARSER ./calc input syntax error ./calc.at:1426: $PREPARSER ./calc input stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1433: cat stderr ./calc.at:1432: cat stderr ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !+ ++ ./calc.at:1433: $PREPARSER ./calc input ./calc.at:1445: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS input: ./calc.at:1426: cat stderr stderr: | (1 + #) = 1111 ./calc.at:1432: $PREPARSER ./calc input ./calc.at:1431: cat stderr ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: cat stderr ./calc.at:1426: $PREPARSER ./calc /dev/null stderr: ./calc.at:1433: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: input: stderr: 1.6: syntax error: invalid character: '#' | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1431: $PREPARSER ./calc input syntax error ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (!!) + (1 2) = 1 stderr: ./calc.at:1434: $PREPARSER ./calc input syntax error syntax error syntax error syntax error error: 4444 != 1 stderr: ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error input: stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1433: $PREPARSER ./calc input 1.11: syntax error 1.1-16: error: 2222 != 1 stderr: ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11: syntax error 1.1-16: error: 2222 != 1 stderr: ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error syntax error syntax error syntax error error: 4444 != 1 stderr: ./calc.at:1432: cat stderr ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1426: cat stderr ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (# + 1) = 1111 ./calc.at:1432: $PREPARSER ./calc input stderr: ./calc.at:1434: cat stderr 1.2: syntax error: invalid character: '#' ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1433: cat stderr ./calc.at:1431: cat stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1426: $PREPARSER ./calc input input: | (- *) + (1 2) = 1 ./calc.at:1434: $PREPARSER ./calc input stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (#) + (#) = 2222 input: ./calc.at:1433: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' stderr: | (!!) + (1 2) = 1 ./calc.at:1431: $PREPARSER ./calc input 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 stderr: stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error error: 2222 != 1 ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error error: 2222 != 1 ./calc.at:1432: cat stderr stderr: ./calc.at:1434: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + # + 1) = 1111 ./calc.at:1432: $PREPARSER ./calc input input: | (* *) + (*) + (*) stderr: ./calc.at:1434: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' ./calc.at:1431: cat stderr ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1426: cat stderr ./calc.at:1433: cat stderr input: stderr: 1.6: syntax error: invalid character: '#' 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 ./calc.at:1426: $PREPARSER ./calc input input: | (- *) + (1 2) = 1 ./calc.at:1431: $PREPARSER ./calc input stderr: stderr: syntax error syntax error error: 2222 != 1 stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error syntax error error: 2222 != 1 ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error error: 2222 != 1 input: | (1 + #) = 1111 ./calc.at:1433: $PREPARSER ./calc input ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.6: syntax error: invalid character: '#' ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error error: 2222 != 1 ./calc.at:1434: cat stderr stderr: 1.6: syntax error: invalid character: '#' input: ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !+ ++ ./calc.at:1434: $PREPARSER ./calc input ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1432: cat stderr stderr: ./calc.at:1434: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1433: cat stderr input: | (1 + 1) / (1 - 1) ./calc.at:1432: $PREPARSER ./calc input ./calc.at:1431: cat stderr ./calc.at:1426: cat stderr input: | 1 + 2 * 3 + !- ++ ./calc.at:1434: $PREPARSER ./calc input input: input: input: | (* *) + (*) + (*) | (- *) + (1 2) = 1 stderr: ./calc.at:1431: $PREPARSER ./calc input stderr: | (# + 1) = 1111 ./calc.at:1426: $PREPARSER ./calc input ./calc.at:1433: $PREPARSER ./calc input stderr: stderr: ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error error: 2222 != 1 ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error syntax error ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor stderr: stderr: ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error syntax error 1.2: syntax error: invalid character: '#' ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error error: 2222 != 1 1.11-17: error: null divisor stderr: ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1431: cat stderr ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: cat stderr ./calc.at:1426: cat stderr ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | 1 + 2 * 3 + !+ ++ ./calc.at:1434: cat stderr ./calc.at:1431: $PREPARSER ./calc input | (* *) + (*) + (*) ./calc.at:1426: $PREPARSER ./calc input stderr: stderr: syntax error syntax error syntax error 524. calc.at:1432: ok ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1433: cat stderr stderr: syntax error syntax error syntax error stderr: ./calc.at:1431: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: input: | (#) + (#) = 2222 ./calc.at:1434: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ ./calc.at:1431: $PREPARSER ./calc input stderr: stderr: ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1426: cat stderr stderr: input: input: | (1 + # + 1) = 1111 ./calc.at:1433: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1426: $PREPARSER ./calc input ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1431: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1426: $EGREP -c -v 'Return for a new token:|LAC:' stderr 534. calc.at:1446: testing Calculator C++ %header %locations parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1446: mv calc.y.tmp calc.y input: | (#) + (#) = 2222 ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1431: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' input: ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1426: $PREPARSER ./calc input ./calc.at:1434: cat stderr stderr: ./calc.at:1446: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1433: cat stderr input: stderr: | (1 + 1) / (1 - 1) ./calc.at:1433: $PREPARSER ./calc input stderr: stdout: ./calc.at:1437: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: input: 1.11-17: error: null divisor ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1437: $PREPARSER ./calc input | (1 + #) = 1111 ./calc.at:1434: $PREPARSER ./calc input stderr: ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: ./calc.at:1437: $EGREP -c -v 'Return for a new token:|LAC:' stderr 1.11-17: error: null divisor ./calc.at:1446: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS input: 1.6: syntax error: invalid character: '#' ./calc.at:1431: cat stderr | 1 2 ./calc.at:1437: $PREPARSER ./calc input ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.6: syntax error: invalid character: '#' 1.3: syntax error, unexpected number ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error, unexpected number ./calc.at:1426: cat stderr ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | (1 + #) = 1111 ./calc.at:1431: $PREPARSER ./calc input ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (#) + (#) = 2222 syntax error: invalid character: '#' ./calc.at:1426: $PREPARSER ./calc input stderr: ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: cat stderr ./calc.at:1433: cat stderr ./calc.at:1437: cat stderr stderr: stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' syntax error: invalid character: '#' input: | (# + 1) = 1111 ./calc.at:1434: $PREPARSER ./calc input 525. calc.at:1433: ok stderr: input: 1.2: syntax error: invalid character: '#' ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' stderr: ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1426: cat stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: cat stderr 535. calc.at:1448: testing Calculator C++ %header %locations api.location.file=none ... ./calc.at:1448: mv calc.y.tmp calc.y input: ./calc.at:1431: cat stderr | (1 + #) = 1111 ./calc.at:1426: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1448: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: ./calc.at:1434: cat stderr input: syntax error: invalid character: '#' ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error input: | (# + 1) = 1111 input: ./calc.at:1426: cat stderr | (1 + # + 1) = 1111 ./calc.at:1434: $PREPARSER ./calc input ./calc.at:1437: $PREPARSER ./calc input ./calc.at:1431: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error, unexpected invalid token ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stdout: ./calc.at:1440: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc syntax error: invalid character: '#' ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' stderr: | (# + 1) = 1111 ./calc.at:1426: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1448: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS 1.1: syntax error, unexpected invalid token input: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1440: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1437: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1440: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1434: cat stderr input: | 1 = 2 = 3 ./calc.at:1437: $PREPARSER ./calc input input: | 1 2 ./calc.at:1440: $PREPARSER ./calc input stderr: ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: cat stderr stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1426: cat stderr | (1 + # + 1) = 1111 ./calc.at:1431: $PREPARSER ./calc input stderr: stderr: 1.7: syntax error, unexpected '=' input: ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1440: cat stderr syntax error: invalid character: '#' ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (1 + # + 1) = 1111 ./calc.at:1426: $PREPARSER ./calc input | (1 + 1) / (1 - 1) 1.7: syntax error, unexpected '=' ./calc.at:1434: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' stderr: ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.11-17: error: null divisor ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' | 1//2 stderr: ./calc.at:1440: $PREPARSER ./calc input syntax error: invalid character: '#' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1431: cat stderr stderr: ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11-17: error: null divisor input: ./calc.at:1440: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1431: $PREPARSER ./calc input stderr: error: null divisor ./calc.at:1437: cat stderr ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: error: null divisor ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | error ./calc.at:1426: cat stderr ./calc.at:1440: $PREPARSER ./calc input ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: cat stderr | | +1 stderr: ./calc.at:1437: $PREPARSER ./calc input stderr: ./calc.at:1434: cat stderr stdout: ./calc.at:1438: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc 523. calc.at:1431: ok input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 | (1 + 1) / (1 - 1) ./calc.at:1426: $PREPARSER ./calc input input: 2.1: syntax error, unexpected '+' ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 526. calc.at:1434: ok error: null divisor ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: null divisor | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1438: $PREPARSER ./calc input ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 2.1: syntax error, unexpected '+' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1438: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1440: cat stderr ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1426: cat stderr ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: input: ./calc.at:1437: cat stderr | 1 = 2 = 3 ./calc.at:1441: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1440: $PREPARSER ./calc input input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 | 1 2 ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1441: $PREPARSER ./calc input stderr: 522. calc.at:1426: ok ./calc.at:1438: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1437: $PREPARSER ./calc /dev/null 536. calc.at:1449: testing Calculator C++ %header %locations api.location.file="my-location.hh" ... stderr: 1.1: syntax error, unexpected end of input ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 stderr: ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error, unexpected end of input ./calc.at:1449: mv calc.y.tmp calc.y stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 stderr: ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1449: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1441: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1437: cat stderr 537. calc.at:1451: testing Calculator C++ %no-lines %header %locations api.location.file="my-location.hh" ... ./calc.at:1440: cat stderr ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1451: mv calc.y.tmp calc.y | 1 2 ./calc.at:1441: $PREPARSER ./calc input input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 538. calc.at:1453: testing Calculator C++ %locations parse.lac=full parse.error=verbose ... ./calc.at:1453: mv calc.y.tmp calc.y ./calc.at:1437: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 input: ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1438: cat stderr | | +1 ./calc.at:1440: $PREPARSER ./calc input ./calc.at:1453: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1451: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1//2 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1438: $PREPARSER ./calc input ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1449: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 stdout: ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1435: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: cat stderr ./calc.at:1441: cat stderr input: ./calc.at:1438: cat stderr ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1435: $PREPARSER ./calc input input: | 1//2 ./calc.at:1441: $PREPARSER ./calc input stderr: input: ./calc.at:1451: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS ./calc.at:1453: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1440: cat stderr | (!!) + (1 2) = 1 ./calc.at:1437: $PREPARSER ./calc input input: | error stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1438: $PREPARSER ./calc input stderr: stderr: ./calc.at:1440: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 stderr: ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1441: cat stderr stderr: ./calc.at:1435: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 | error ./calc.at:1441: $PREPARSER ./calc input input: stderr: ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 ./calc.at:1435: $PREPARSER ./calc input ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1438: cat stderr stderr: 1.3: syntax error, unexpected number ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1437: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 input: stderr: ./calc.at:1440: cat stderr | 1 = 2 = 3 ./calc.at:1438: $PREPARSER ./calc input 1.3: syntax error, unexpected number stderr: input: ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1441: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1437: $PREPARSER ./calc input stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 stderr: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1440: $PREPARSER ./calc input input: ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 ./calc.at:1441: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1435: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of inpStarting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ut (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1438: cat stderr 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 input: ./calc.at:1438: $PREPARSER ./calc input | 1//2 ./calc.at:1435: $PREPARSER ./calc input stderr: ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1441: cat stderr ./calc.at:1437: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1440: cat stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (* *) + (*) + (*) ./calc.at:1437: $PREPARSER ./calc input stderr: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: ./calc.at:1437: cat stderr input: | | +1 ./calc.at:1441: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1437: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 ./calc.at:1440: $PREPARSER ./calc input ./calc.at:1438: cat stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' stderr: ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1437: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: ./calc.at:1438: $PREPARSER ./calc /dev/null ./calc.at:1445: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 input: | 1 + 2 * 3 + !- ++ ./calc.at:1437: $PREPARSER ./calc input stderr: ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1435: cat stderr input: | error ./calc.at:1435: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1440: cat stderr ./calc.at:1445: $PREPARSER ./calc input ./calc.at:1441: cat stderr stderr: 1.1: syntax error, unexpected invalid token stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' () Reducing stack by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' () Reducing stack by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' () Reducing stack by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' () Reducing stack by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' () Reducing stack by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 ./calc.at:1441: $PREPARSER ./calc /dev/null ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 input: stderr: ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1440: $PREPARSER ./calc input 1.1: syntax error, unexpected invalid token ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1437: cat stderr ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1435: cat stderr ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 = 2 = 3 ./calc.at:1435: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' () Reducing stack by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' () Reducing stack by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' () Reducing stack by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' () Reducing stack by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' () Reducing stack by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: 1.7: syntax error, unexpected '=' ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: stderr: | (#) + (#) = 2222 ./calc.at:1437: $PREPARSER ./calc input stderr: 1.7: syntax error, unexpected '=' 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1441: cat stderr ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: cat stderr input: ./calc.at:1440: cat stderr ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1437: cat stderr | 1 2 ./calc.at:1445: $PREPARSER ./calc input ./calc.at:1435: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1438: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Stack now 0 Cleanup: discarding lookahead token number (2) Stack now 0 ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: stderr: stderr: | | +1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1435: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Stack now 0 Cleanup: discarding lookahead token number (2) Stack now 0 ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (* *) + (*) + (*) 2.1: syntax error, unexpected '+' ./calc.at:1440: $PREPARSER ./calc input input: ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1441: $PREPARSER ./calc input | (1 + #) = 1111 ./calc.at:1437: $PREPARSER ./calc input stderr: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 2.1: syntax error, unexpected '+' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.6: syntax error: invalid character: '#' ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1440: cat stderr input: | 1 + 2 * 3 + !+ ++ ./calc.at:1440: $PREPARSER ./calc input ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: cat stderr ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1441: cat stderr input: ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1438: cat stderr | 1//2 ./calc.at:1445: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Stack now 0 8 Error: popping nterm exp (1) Stack now 0 Cleanup: discarding lookahead token '/' () Stack now 0 ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Stack now 0 8 Error: popping nterm exp (1) Stack now 0 Cleanup: discarding lookahead token '/' () Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1440: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1435: $PREPARSER ./calc /dev/null ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: cat stderr stderr: 1.1: syntax error, unexpected end of input ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !- ++ ./calc.at:1440: $PREPARSER ./calc input input: stderr: stderr: 1.1: syntax error, unexpected end of input ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (!!) + (1 2) = 1 ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1438: $PREPARSER ./calc input | (!!) + (1 2) = 1 stderr: ./calc.at:1445: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1441: $PREPARSER ./calc input ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1440: cat stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 stderr: ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1437: $PREPARSER ./calc input | (#) + (#) = 2222 ./calc.at:1440: $PREPARSER ./calc input input: | error stderr: ./calc.at:1445: $PREPARSER ./calc input ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1435: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: 1.2: syntax error: invalid character: '#' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () Stack now 0 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1441: cat stderr ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' ./calc.at:1435: cat stderr ./calc.at:1438: cat stderr ./calc.at:1440: cat stderr ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | (- *) + (1 2) = 1 ./calc.at:1441: $PREPARSER ./calc input | (!!) + (1 2) = 1 ./calc.at:1435: $PREPARSER ./calc input stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (- *) + (1 2) = 1 ./calc.at:1438: $PREPARSER ./calc input input: ./calc.at:1445: cat stderr | (1 + #) = 1111 stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1440: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1437: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 ./calc.at:1445: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1441: cat stderr input: ./calc.at:1435: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Stack now 0 8 18 Error: popping token '=' () Stack now 0 8 Error: popping nterm exp (1) Stack now 0 Cleanup: discarding lookahead token '=' () Stack now 0 ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: cat stderr ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + # + 1) = 1111 ./calc.at:1437: $PREPARSER ./calc input ./calc.at:1440: cat stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | (* *) + (*) + (*) | (* *) + (*) + (*) ./calc.at:1441: $PREPARSER ./calc input ./calc.at:1438: $PREPARSER ./calc input stderr: | (- *) + (1 2) = 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1435: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: | (# + 1) = 1111 stderr: ./calc.at:1440: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.6: syntax error: invalid character: '#' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Stack now 0 8 18 Error: popping token '=' () Stack now 0 8 Error: popping nterm exp (1) Stack now 0 Cleanup: discarding lookahead token '=' () Stack now 0 stderr: ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: cat stderr 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1445: cat stderr ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1437: cat stderr input: | | +1 ./calc.at:1445: $PREPARSER ./calc input input: ./calc.at:1441: cat stderr stderr: | 1 + 2 * 3 + !+ ++ Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Stack now 0 Cleanup: discarding lookahead token '+' () Stack now 0 ./calc.at:1438: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + 1) / (1 - 1) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1437: $PREPARSER ./calc input input: ./calc.at:1438: $EGREP -c -v 'Return for a new token:|LAC:' stderr | 1 + 2 * 3 + !+ ++ stderr: ./calc.at:1441: $PREPARSER ./calc input 1.11-17: error: null divisor ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: cat stderr stderr: 1.11-17: error: null divisor stderr: input: stderr: | 1 + 2 * 3 + !- ++ Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1438: $PREPARSER ./calc input ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Stack now 0 Cleanup: discarding lookahead token '+' () Stack now 0 stderr: stderr: | (* *) + (*) + (*) ./calc.at:1435: $PREPARSER ./calc input stderr: ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1441: $EGREP -c -v 'Return for a new token:|LAC:' stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1440: cat stderr ./calc.at:1437: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1445: cat stderr input: | (1 + # + 1) = 1111 ./calc.at:1440: $PREPARSER ./calc input ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 528. calc.at:1437: ok ./calc.at:1438: cat stderr ./calc.at:1435: cat stderr | 1 + 2 * 3 + !- ++ ./calc.at:1441: $PREPARSER ./calc input ./calc.at:1445: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input () syntax error, unexpected end of input Cleanup: discarding lookahead token end of input () Stack now 0 stderr: input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | 1 + 2 * 3 + !+ ++ ./calc.at:1435: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1438: $PREPARSER ./calc input stderr: stderr: stderr: stdout: ./calc.at:1443: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1443: $PREPARSER ./calc input ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1435: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input () syntax error, unexpected end of input Cleanup: discarding lookahead token end of input () Stack now 0 ./calc.at:1440: cat stderr stderr: ./calc.at:1441: cat stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1443: $EGREP -c -v 'Return for a new token:|LAC:' stderr | 1 + 2 * 3 + !- ++ ./calc.at:1435: $PREPARSER ./calc input ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 539. calc.at:1454: testing Calculator C++ %locations parse.lac=full parse.error=detailed ... ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1438: cat stderr | (1 + 1) / (1 - 1) stderr: ./calc.at:1440: $PREPARSER ./calc input input: input: input: | (#) + (#) = 2222 ./calc.at:1441: $PREPARSER ./calc input | 1 2 ./calc.at:1443: $PREPARSER ./calc input stderr: ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 ./calc.at:1454: mv calc.y.tmp calc.y ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1454: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: cat stderr stderr: stderr: ./calc.at:1445: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 input: ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: $PREPARSER ./calc input ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1454: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: ./calc.at:1440: cat stderr ./calc.at:1441: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Stack now 0 8 20 4 12 Error: popping nterm exp (3) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' () Reducing stack by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Stack now 0 8 20 4 12 Error: popping nterm exp (2) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () input: ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (#) + (#) = 2222 ./calc.at:1435: $PREPARSER ./calc input ./calc.at:1443: cat stderr stderr: ./calc.at:1438: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' input: ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 530. calc.at:1440: ok | (1 + #) = 1111 ./calc.at:1441: $PREPARSER ./calc input stderr: stderr: | 1//2 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1443: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' input: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 | (# + 1) = 1111 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Stack now 0 8 20 4 12 Error: popping nterm exp (3) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' () Reducing stack by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Stack now 0 8 20 4 12 Error: popping nterm exp (2) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1438: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1435: cat stderr stderr: ./calc.at:1441: cat stderr ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1443: cat stderr ./calc.at:1445: cat stderr input: | error ./calc.at:1443: $PREPARSER ./calc input 540. calc.at:1455: testing Calculator C++ %locations parse.lac=full parse.error=detailed parse.trace ... ./calc.at:1455: mv calc.y.tmp calc.y stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1455: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1435: $PREPARSER ./calc input stderr: input: 1.6: syntax error: invalid character: '#' ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1438: cat stderr | (# + 1) = 1111 ./calc.at:1441: $PREPARSER ./calc input | (!!) + (1 2) = 1 stderr: ./calc.at:1445: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token number (2) Error: discarding token number (2) Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1435: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token number (2) Error: discarding token number (2) Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () | (1 + # + 1) = 1111 ./calc.at:1455: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1438: $PREPARSER ./calc input stderr: ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1441: cat stderr input: ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (# + 1) = 1111 ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1435: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1443: cat stderr input: | (1 + # + 1) = 1111 ./calc.at:1441: $PREPARSER ./calc input ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1445: cat stderr ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1438: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | 1 = 2 = 3 ./calc.at:1443: $PREPARSER ./calc input input: | (1 + 1) / (1 - 1) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1438: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (- *) + (1 2) = 1 ./calc.at:1438: cat stderr ./calc.at:1445: $PREPARSER ./calc input stderr: ./calc.at:1441: cat stderr 529. calc.at:1438: ok Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' () $2 = token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token number (2) Error: discarding token number (2) Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1435: cat stderr stderr: | (1 + 1) / (1 - 1) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' () $2 = token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token number (2) Error: discarding token number (2) Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1441: $PREPARSER ./calc input stderr: stderr: ./calc.at:1443: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | (1 + # + 1) = 1111 ./calc.at:1435: $PREPARSER ./calc input stdout: ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1453: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc 1.6: syntax error: invalid character: '#' ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 1.6: syntax error: invalid character: '#' | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1453: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | | +1 ./calc.at:1443: $PREPARSER ./calc input ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 stderr: ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1445: cat stderr ./calc.at:1435: cat stderr stderr: ./calc.at:1453: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + 1) / (1 - 1) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1435: $PREPARSER ./calc input 541. calc.at:1457: testing Calculator C++ parse.error=custom ... ./calc.at:1457: mv calc.y.tmp calc.y ./calc.at:1457: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1441: cat stderr stderr: input: 531. calc.at:1441: ok 1.11-17: error: null divisor ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) ./calc.at:1445: $PREPARSER ./calc input input: ./calc.at:1457: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS | 1 2 ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.11-17: error: null divisor ./calc.at:1453: $PREPARSER ./calc input stderr: ./calc.at:1443: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' () Reducing stack by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1443: $PREPARSER ./calc /dev/null stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 1.3: syntax error, unexpected number ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1435: cat stderr stderr: ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: cat stderr 1.3: syntax error, unexpected number Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' () Reducing stack by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1443: $PREPARSER ./calc input stderr: 527. calc.at:1435: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ok ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1453: cat stderr 542. calc.at:1458: testing Calculator C++ parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1458: mv calc.y.tmp calc.y ./calc.at:1458: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: cat stderr input: | 1//2 ./calc.at:1453: $PREPARSER ./calc input ./calc.at:1445: cat stderr stderr: input: | (!!) + (1 2) = 1 ./calc.at:1443: $PREPARSER ./calc input stderr: stdout: stderr: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1448: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh stderr: input: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' | 1 + 2 * 3 + !+ ++ ./calc.at:1445: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Stack now 0 8 20 Cleanup: popping token '+' () Cleanup: popping nterm exp (7) | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1448: $PREPARSER ./calc input ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stdout: ./calc.at:1458: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: 543. calc.at:1459: testing Calculator C++ parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} parse.lac=full ... ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1459: mv calc.y.tmp calc.y stderr: ./calc.at:1448: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1459: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Stack now 0 8 20 Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1445: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1453: cat stderr ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | 1 2 ./calc.at:1448: $PREPARSER ./calc input input: ./calc.at:1443: cat stderr | error ./calc.at:1453: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1446: $PREPARSER ./calc input stderr: stderr: 1.1: syntax error, unexpected invalid token 1.3: syntax error ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (- *) + (1 2) = 1 ./calc.at:1443: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ ./calc.at:1445: $PREPARSER ./calc input stderr: stderr: 1.3: syntax error stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Stack now 0 8 20 Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1459: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS 1.1: syntax error, unexpected invalid token ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1446: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: ./calc.at:1448: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Stack now 0 8 20 Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1453: cat stderr ./calc.at:1443: cat stderr input: | 1 2 ./calc.at:1446: $PREPARSER ./calc input stderr: | 1//2 ./calc.at:1448: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 input: input: | (* *) + (*) + (*) | 1 = 2 = 3 ./calc.at:1443: $PREPARSER ./calc input ./calc.at:1453: $PREPARSER ./calc input stderr: ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.7: syntax error, unexpected '=' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.7: syntax error, unexpected '=' stderr: ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1445: cat stderr ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1453: cat stderr | (#) + (#) = 2222 ./calc.at:1445: $PREPARSER ./calc input ./calc.at:1448: cat stderr ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1443: cat stderr input: stdout: ./calc.at:1449: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1446: cat stderr input: stderr: input: | error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1448: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1449: $PREPARSER ./calc input input: | 1//2 ./calc.at:1446: $PREPARSER ./calc input ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: | | +1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error stderr: ./calc.at:1453: $PREPARSER ./calc input ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1449: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 stderr: input: | 1 + 2 * 3 + !+ ++ ./calc.at:1443: $PREPARSER ./calc input stderr: 1.1: syntax error 2.1: syntax error, unexpected '+' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 2.1: syntax error, unexpected '+' stderr: ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | 1 2 ./calc.at:1449: $PREPARSER ./calc input ./calc.at:1448: cat stderr stderr: ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) 1.3: syntax error ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 = 2 = 3 ./calc.at:1448: $PREPARSER ./calc input ./calc.at:1443: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: stderr: 1.3: syntax error 1.7: syntax error ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.7: syntax error ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: cat stderr input: ./calc.at:1446: cat stderr ./calc.at:1453: cat stderr ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !- ++ ./calc.at:1443: $PREPARSER ./calc input | error ./calc.at:1446: $PREPARSER ./calc input ./calc.at:1453: $PREPARSER ./calc /dev/null stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1449: cat stderr input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (1 + #) = 1111 ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error, unexpected end of input ./calc.at:1445: $PREPARSER ./calc input ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1//2 ./calc.at:1449: $PREPARSER ./calc input stderr: stderr: ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.1: syntax error, unexpected end of input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 1.3: syntax error ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.3: syntax error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 4 12 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Stack now 0 4 12 Error: popping nterm exp (1) Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: cat stderr ./calc.at:1446: cat stderr ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 4 12 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Stack now 0 4 12 Error: popping nterm exp (1) Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () input: input: ./calc.at:1453: cat stderr ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 ./calc.at:1446: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 | | +1 ./calc.at:1448: $PREPARSER ./calc input input: ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 2.1: syntax error ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1443: $PREPARSER ./calc input stderr: ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1453: $PREPARSER ./calc input 2.1: syntax error ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1445: cat stderr ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1449: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (# + 1) = 1111 ./calc.at:1445: $PREPARSER ./calc input stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' () Error: discarding token '+' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1) Error: discarding token number (1) Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: ./calc.at:1448: cat stderr ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: input: ./calc.at:1448: $PREPARSER ./calc /dev/null ./calc.at:1446: cat stderr | error stderr: ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1449: $PREPARSER ./calc input ./calc.at:1443: cat stderr input: | | +1 ./calc.at:1451: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1446: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 input: stderr: ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' () Error: discarding token '+' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1) Error: discarding token number (1) Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1443: $PREPARSER ./calc input stderr: input: 1.1: syntax error | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1451: $PREPARSER ./calc input stderr: ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 1.1: syntax error ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1451: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error ./calc.at:1446: cat stderr input: | (!!) + (1 2) = 1 ./calc.at:1445: cat stderr input: ./calc.at:1453: $PREPARSER ./calc input ./calc.at:1448: cat stderr ./calc.at:1446: $PREPARSER ./calc /dev/null ./calc.at:1443: cat stderr | 1 2 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 stderr: ./calc.at:1451: $PREPARSER ./calc input input: ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 | (1 + # + 1) = 1111 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1448: $PREPARSER ./calc input ./calc.at:1445: $PREPARSER ./calc input | (# + 1) = 1111 stderr: ./calc.at:1443: $PREPARSER ./calc input 1.3: syntax error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 4 12 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Stack now 0 4 12 Error: popping nterm exp (1) Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' () Error: discarding token '+' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1) Error: discarding token number (1) Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.3: syntax error ./calc.at:1446: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 4 12 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Stack now 0 4 12 Error: popping nterm exp (1) Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' () Error: discarding token '+' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1) Error: discarding token number (1) Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1449: cat stderr ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | 1 = 2 = 3 ./calc.at:1449: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1448: cat stderr ./calc.at:1446: $PREPARSER ./calc input stderr: 1.7: syntax error ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of inpstderr: ut (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1453: cat stderr ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (!!) + (1 2) = 1 ./calc.at:1445: cat stderr ./calc.at:1448: $PREPARSER ./calc input ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.7: syntax error stderr: input: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1446: cat stderr ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + 1) / (1 - 1) stderr: input: ./calc.at:1445: $PREPARSER ./calc input 1.11: syntax error 1.1-16: error: 2222 != 1 | (1 + # + 1) = 1111 input: ./calc.at:1443: $PREPARSER ./calc input | (- *) + (1 2) = 1 | (!!) + (1 2) = 1 ./calc.at:1446: $PREPARSER ./calc input ./calc.at:1453: $PREPARSER ./calc input ./calc.at:1451: cat stderr ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1449: cat stderr 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Stack now 0 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' () Reducing stack by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' () Reducing stack by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 input: ./calc.at:1448: cat stderr ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1449: $PREPARSER ./calc input stderr: ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1451: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: stderr: 2.1: syntax error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Stack now 0 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' () Reducing stack by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' () Reducing stack by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | (- *) + (1 2) = 1 ./calc.at:1448: $PREPARSER ./calc input stderr: 2.1: syntax error stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error ./calc.at:1443: cat stderr input: ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) ./calc.at:1453: $PREPARSER ./calc input stderr: ./calc.at:1446: cat stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: cat stderr input: ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + 1) / (1 - 1) ./calc.at:1443: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: 533. calc.at:1445: ok ./calc.at:1449: cat stderr ./calc.at:1448: cat stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' input: ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 stderr: ./calc.at:1446: $PREPARSER ./calc input ./calc.at:1451: cat stderr ./calc.at:1449: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: 1.1: syntax error stderr: | (* *) + (*) + (*) ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: $PREPARSER ./calc input ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: cat stderr stderr: | error stderr: ./calc.at:1451: $PREPARSER ./calc input 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1443: cat stderr 1.1: syntax error stderr: 1.1: syntax error ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.1: syntax error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 532. calc.at:1443: input: ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ok | 1 + 2 * 3 + !+ ++ ./calc.at:1453: $PREPARSER ./calc input stderr: ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 544. calc.at:1468: testing Calculator glr.cc ... ./calc.at:1449: cat stderr ./calc.at:1468: mv calc.y.tmp calc.y ./calc.at:1468: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1453: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: cat stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1449: $PREPARSER ./calc input ./calc.at:1446: cat stderr input: | 1 + 2 * 3 + !- ++ input: ./calc.at:1453: $PREPARSER ./calc input ./calc.at:1451: cat stderr stderr: | 1 + 2 * 3 + !+ ++ stderr: ./calc.at:1448: $PREPARSER ./calc input 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 = 2 = 3 ./calc.at:1451: $PREPARSER ./calc input stderr: input: stderr: stderr: stderr: 1.7: syntax error | (* *) + (*) + (*) ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1446: $PREPARSER ./calc input stderr: 1.7: syntax error stderr: ./calc.at:1448: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1451: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1468: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS | 1 + 2 * 3 + !- ++ ./calc.at:1448: $PREPARSER ./calc input input: ./calc.at:1453: cat stderr stderr: | | +1 ./calc.at:1451: $PREPARSER ./calc input ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: input: ./calc.at:1449: cat stderr | (#) + (#) = 2222 2.1: syntax error ./calc.at:1453: $PREPARSER ./calc input ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./calc.at:1446: cat stderr ./calc.at:1454: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc input: stderr: ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1449: $PREPARSER ./calc input 2.1: syntax error stderr: input: stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1454: $PREPARSER ./calc input stderr: ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 545. calc.at:1469: testing Calculator glr2.cc ... ./calc.at:1469: mv calc.y.tmp calc.y ./calc.at:1469: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' | 1 + 2 * 3 + !+ ++ ./calc.at:1446: $PREPARSER ./calc input ./calc.at:1454: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: cat stderr stderr: stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1451: cat stderr ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 2 stderr: ./calc.at:1454: $PREPARSER ./calc input input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1453: cat stderr ./calc.at:1446: $EGREP -c -v 'Return for a new token:|LAC:' stderr | (#) + (#) = 2222 ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: $PREPARSER ./calc input stderr: stderr: ./calc.at:1451: $PREPARSER ./calc /dev/null ./calc.at:1469: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS input: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ 1.3: syntax error, unexpected number 1.1: syntax error ./calc.at:1446: $PREPARSER ./calc input input: ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1449: cat stderr | (1 + #) = 1111 ./calc.at:1453: $PREPARSER ./calc input stderr: ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: 1.6: syntax error: invalid character: '#' 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 1.3: syntax error, unexpected number stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (- *) + (1 2) = 1 ./calc.at:1449: $PREPARSER ./calc input ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error stderr: ./calc.at:1446: cat stderr 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (#) + (#) = 2222 ./calc.at:1446: $PREPARSER ./calc input 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 stderr: ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: cat stderr ./calc.at:1454: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1451: cat stderr stderr: ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | (1 + #) = 1111 input: ./calc.at:1448: $PREPARSER ./calc input ./calc.at:1453: cat stderr | 1//2 input: ./calc.at:1454: $PREPARSER ./calc input stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1451: $PREPARSER ./calc input ./calc.at:1449: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (# + 1) = 1111 stderr: ./calc.at:1453: $PREPARSER ./calc input 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: cat stderr input: stderr: | (* *) + (*) + (*) ./calc.at:1449: $PREPARSER ./calc input 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 stderr: ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error 1.6: syntax error: invalid character: '#' ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' stderr: ./calc.at:1454: cat stderr 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1453: cat stderr input: | error | (1 + #) = 1111 ./calc.at:1454: $PREPARSER ./calc input stderr: 1.1: syntax error, unexpected invalid token ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: $PREPARSER ./calc input stderr: stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + # + 1) = 1111 ./calc.at:1453: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error, unexpected invalid token ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1448: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1451: cat stderr ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (# + 1) = 1111 ./calc.at:1448: $PREPARSER ./calc input ./calc.at:1454: cat stderr stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1449: cat stderr input: stderr: input: 1.2: syntax error: invalid character: '#' | (!!) + (1 2) = 1 ./calc.at:1451: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1454: $PREPARSER ./calc input stderr: stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1453: cat stderr 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.7: syntax error, unexpected '=' input: ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: input: ./calc.at:1457: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc | 1 + 2 * 3 + !+ ++ ./calc.at:1449: $PREPARSER ./calc input stderr: ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1457: $PREPARSER ./calc input ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (1 + 1) / (1 - 1) ./calc.at:1453: $PREPARSER ./calc input ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1446: cat stderr stderr: stderr: 1.7: syntax error, unexpected '=' ./calc.at:1449: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor ./calc.at:1451: cat stderr | (# + 1) = 1111 ./calc.at:1446: $PREPARSER ./calc input ./calc.at:1448: cat stderr stderr: ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1457: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: 1.11-17: error: null divisor stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + # + 1) = 1111 ./calc.at:1448: $PREPARSER ./calc input input: stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1449: $PREPARSER ./calc input input: | 1 2 input: stderr: ./calc.at:1457: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1451: $PREPARSER ./calc input stderr: ./calc.at:1454: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 input: ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1454: $PREPARSER ./calc input stderr: stderr: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) stderr: ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: cat stderr ./calc.at:1453: cat stderr 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1448: cat stderr 2.1: syntax error, unexpected '+' stderr: ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + 1) / (1 - 1) ./calc.at:1448: $PREPARSER ./calc input stderr: 2.1: syntax error, unexpected '+' stderr: 538. calc.at:1453: ok stderr: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) 1.11-17: error: null divisor ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + # + 1) = 1111 stderr: ./calc.at:1446: $PREPARSER ./calc input stdout: stderr: ./calc.at:1457: cat stderr stderr: ./calc.at:1458: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11-17: error: null divisor ./calc.at:1454: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1451: cat stderr input: | 1//2 ./calc.at:1457: $PREPARSER ./calc input ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1454: $PREPARSER ./calc /dev/null stderr: stderr: stderr: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1449: cat stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error, unexpected end of file ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1458: $PREPARSER ./calc input 546. calc.at:1476: testing Calculator C++ %glr-parser ... ./calc.at:1451: $PREPARSER ./calc input ./calc.at:1476: mv calc.y.tmp calc.y stderr: ./calc.at:1476: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: stderr: 1.1: syntax error, unexpected end of file stderr: stderr: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) input: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stdout: ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1448: cat stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (#) + (#) = 2222 stderr: ./calc.at:1446: cat stderr ./calc.at:1449: $PREPARSER ./calc input ./calc.at:1455: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc 535. calc.at:1448: ok ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: ./calc.at:1458: $EGREP -c -v 'Return for a new token:|LAC:' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1455: $PREPARSER ./calc input stderr: stderr: | (1 + 1) / (1 - 1) ./calc.at:1454: cat stderr ./calc.at:1457: cat stderr ./calc.at:1446: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) LAC: initial context established for '=' LAC: checking lookahead '=': R9 G29 R7 G8 S18 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 92): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) LAC: initial context established for '=' LAC: checking lookahead '=': R11 G30 R9 G29 R7 G8 S18 Reducing stack by rule 11 (line 115): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 105): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 92): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 92): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G10 R11 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 115): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 92): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) LAC: initial context established for ')' LAC: checking lookahead ')': R11 G12 S26 Reducing stack by rule 11 (line 115): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 92): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 92): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) LAC: initial context established for '=' LAC: checking lookahead '=': R11 G10 R11 G10 R11 G8 S18 Reducing stack by rule 11 (line 115): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 115): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 115): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 92): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) LAC: initial context established for '-' LAC: checking lookahead '-': R8 G8 S19 Reducing stack by rule 8 (line 104): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) LAC: initial context discarded due to shift Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 92): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) LAC: initial context established for '=' LAC: checking lookahead '=': R8 G8 S18 Reducing stack by rule 8 (line 104): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 92): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 92): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) LAC: initial context established for ')' LAC: checking lookahead ')': R8 G12 S26 Reducing stack by rule 8 (line 104): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) LAC: initial context established for '=' LAC: checking lookahead '=': R8 G8 S18 Reducing stack by rule 8 (line 104): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 92): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 92): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G32 R12 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 116): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 92): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 92): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) LAC: initial context established for ')' LAC: checking lookahead ')': R12 G12 S26 Reducing stack by rule 12 (line 116): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 92): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (14.1: ) Shifting token end of file (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 2 ./calc.at:1458: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1451: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) LAC: initial context established for '=' LAC: checking lookahead '=': R9 G29 R7 G8 S18 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 92): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) LAC: initial context established for '=' LAC: checking lookahead '=': R11 G30 R9 G29 R7 G8 S18 Reducing stack by rule 11 (line 115): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 105): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 92): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 92): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G10 R11 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 115): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 92): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) LAC: initial context established for ')' LAC: checking lookahead ')': R11 G12 S26 Reducing stack by rule 11 (line 115): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 92): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 92): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) LAC: initial context established for '=' LAC: checking lookahead '=': R11 G10 R11 G10 R11 G8 S18 Reducing stack by rule 11 (line 115): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 115): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 115): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 92): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) LAC: initial context established for '-' LAC: checking lookahead '-': R8 G8 S19 Reducing stack by rule 8 (line 104): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) LAC: initial context discarded due to shift Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 92): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) LAC: initial context established for '=' LAC: checking lookahead '=': R8 G8 S18 Reducing stack by rule 8 (line 104): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 92): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 92): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) LAC: initial context established for ')' LAC: checking lookahead ')': R8 G12 S26 Reducing stack by rule 8 (line 104): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) LAC: initial context established for '=' LAC: checking lookahead '=': R8 G8 S18 Reducing stack by rule 8 (line 104): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 92): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 92): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G32 R12 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 116): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 92): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 92): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) LAC: initial context established for ')' LAC: checking lookahead ')': R12 G12 S26 Reducing stack by rule 12 (line 116): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 92): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (14.1: ) Shifting token end of file (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1455: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: input: ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1457: $PREPARSER ./calc input stderr: ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1476: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS input: stderr: ./calc.at:1454: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1451: $PREPARSER ./calc input ./calc.at:1449: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: stderr: | 1 2 ./calc.at:1455: $PREPARSER ./calc input syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: stderr: ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1458: cat stderr ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) LAC: initial context established for number LAC: checking lookahead number: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: Err LAC: checking lookahead '=': S18 LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: ./calc.at:1446: cat stderr | (1 + #) = 1111 ./calc.at:1449: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) LAC: initial context established for number LAC: checking lookahead number: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: Err LAC: checking lookahead '=': S18 LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) 547. calc.at:1476: testing Calculator glr2.cc ... input: stderr: | 1//2 1.6: syntax error: invalid character: '#' ./calc.at:1451: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1458: $PREPARSER ./calc input ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: mv calc.y.tmp calc.y stderr: 534. calc.at:1446: ok ./calc.at:1455: cat stderr ./calc.at:1454: cat stderr input: 1.6: syntax error: invalid character: '#' | 1//2 ./calc.at:1455: $PREPARSER ./calc input stderr: 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) stderr: ./calc.at:1476: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) LAC: initial context established for '/' LAC: checking lookahead '/': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) LAC: initial context established for '/' LAC: checking lookahead '/': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !- ++ ./calc.at:1451: $PREPARSER ./calc input stderr: ./calc.at:1457: cat stderr ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) stderr: stderr: input: | (!!) + (1 2) = 1 ./calc.at:1454: $PREPARSER ./calc input input: ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stdout: ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1459: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc | 1 = 2 = 3 ./calc.at:1457: $PREPARSER ./calc input ./calc.at:1455: cat stderr 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: ./calc.at:1451: cat stderr 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1458: cat stderr ./calc.at:1449: cat stderr syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 | error ./calc.at:1459: $PREPARSER ./calc input ./calc.at:1455: $PREPARSER ./calc input ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': S3 LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 548. calc.at:1477: testing Calculator C++ %glr-parser %locations ... Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': S3 LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 input: input: stderr: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) ./calc.at:1476: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS input: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1458: $PREPARSER ./calc input | (#) + (#) = 2222 ./calc.at:1451: $PREPARSER ./calc input ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: mv calc.y.tmp calc.y stderr: ./calc.at:1455: cat stderr stderr: stderr: | (# + 1) = 1111 ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1477: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 = 2 = 3 ./calc.at:1455: $PREPARSER ./calc input ./calc.at:1449: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1454: cat stderr ./calc.at:1459: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: stderr: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) LAC: checking lookahead '=': Err LAC: checking lookahead end of file: R6 G8 Err LAC: checking lookahead number: R6 G8 Err LAC: checking lookahead '=': Err LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 LAC: checking lookahead NEG: R6 G8 Err LAC: checking lookahead '^': S23 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: 1.2: syntax error: invalid character: '#' 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1457: cat stderr | (- *) + (1 2) = 1 ./calc.at:1454: $PREPARSER ./calc input input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) LAC: checking lookahead '=': Err LAC: checking lookahead end of file: R6 G8 Err LAC: checking lookahead number: R6 G8 Err LAC: checking lookahead '=': Err LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 LAC: checking lookahead NEG: R6 G8 Err LAC: checking lookahead '^': S23 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1458: cat stderr stderr: | 1 2 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1459: $PREPARSER ./calc input ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1451: cat stderr stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: | (1 + #) = 1111 ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1449: cat stderr ./calc.at:1451: $PREPARSER ./calc input stderr: stderr: input: 1.6: syntax error: invalid character: '#' input: ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1457: $PREPARSER ./calc input input: | (1 + # + 1) = 1111 ./calc.at:1449: $PREPARSER ./calc input 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 stderr: stderr: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) | 1 = 2 = 3 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./calc.at:1458: $PREPARSER ./calc input stderr: ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1455: cat stderr ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1459: cat stderr input: ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1455: $PREPARSER ./calc input 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) ./calc.at:1477: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS input: ./calc.at:1454: cat stderr | 1//2 ./calc.at:1459: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) LAC: initial context established for '+' LAC: checking lookahead '+': Err LAC: checking lookahead end of file: S16 LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': S3 LAC: checking lookahead '(': S4 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1449: cat stderr ./calc.at:1457: cat stderr ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1451: cat stderr stderr: 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) stderr: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1457: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) LAC: initial context established for '+' LAC: checking lookahead '+': Err LAC: checking lookahead end of file: S16 LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': S3 LAC: checking lookahead '(': S4 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 input: stderr: | (* *) + (*) + (*) syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1454: $PREPARSER ./calc input input: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) stderr: stderr: input: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: | (# + 1) = 1111 ./calc.at:1451: $PREPARSER ./calc input 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) stderr: ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + 1) / (1 - 1) ./calc.at:1449: $PREPARSER ./calc input stderr: 1.11-17: error: null divisor ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' ./calc.at:1457: cat stderr ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1458: cat stderr stderr: 1.2: syntax error: invalid character: '#' 1.11-17: error: null divisor ./calc.at:1455: cat stderr stderr: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' input: ./calc.at:1459: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1455: $PREPARSER ./calc /dev/null stderr: ./calc.at:1457: $PREPARSER ./calc input ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of file (1.1: ) LAC: initial context established for end of file LAC: checking lookahead end of file: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': S3 LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1459: $PREPARSER ./calc input ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: stderr: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) error: 4444 != 1 ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of file (1.1: ) LAC: initial context established for end of file LAC: checking lookahead end of file: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': S3 LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1454: cat stderr 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) | | +1 stderr: ./calc.at:1458: $PREPARSER ./calc input stderr: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) error: 4444 != 1 ./calc.at:1449: cat stderr ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1451: cat stderr ./calc.at:1455: cat stderr stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) input: stderr: | 1 + 2 * 3 + !+ ++ 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1454: $PREPARSER ./calc input 536. calc.at:1449: ok input: ./calc.at:1458: cat stderr stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1455: $PREPARSER ./calc input input: ./calc.at:1457: cat stderr ./calc.at:1458: $PREPARSER ./calc /dev/null ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1459: cat stderr stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) | (1 + # + 1) = 1111 ./calc.at:1451: $PREPARSER ./calc input ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) LAC: initial context established for ')' LAC: checking lookahead ')': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G12 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G12 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) LAC: initial context established for ')' LAC: checking lookahead ')': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G8 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G8 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) LAC: initial context established for '*' LAC: checking lookahead '*': R9 G12 S21 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) LAC: initial context discarded due to shift Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1454: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: stderr: | 1 = 2 = 3 ./calc.at:1459: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) LAC: initial context established for ')' LAC: checking lookahead ')': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G12 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G12 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) LAC: initial context established for ')' LAC: checking lookahead ')': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G8 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G8 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) LAC: initial context established for '*' LAC: checking lookahead '*': R9 G12 S21 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) LAC: initial context discarded due to shift Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (!!) + (1 2) = 1 ./calc.at:1457: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) 549. calc.at:1477: testing Calculator glr2.cc %locations ... stderr: stderr: ./calc.at:1477: mv calc.y.tmp calc.y ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 1.6: syntax error: invalid character: '#' ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ ./calc.at:1454: $PREPARSER ./calc input ./calc.at:1477: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 stderr: ./calc.at:1458: cat stderr ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1455: cat stderr stderr: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: | (!!) + (1 2) = 1 ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1455: $PREPARSER ./calc input input: ./calc.at:1457: cat stderr ./calc.at:1459: cat stderr ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 | | +1 ./calc.at:1459: $PREPARSER ./calc input stderr: stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1458: $PREPARSER ./calc input stderr: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 120): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) LAC: initial context established for number LAC: checking lookahead number: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: Err LAC: checking lookahead '=': S18 LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 ./calc.at:1454: cat stderr ./calc.at:1459: cat stderr ./calc.at:1459: $PREPARSER ./calc /dev/null stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) input: ./calc.at:1451: cat stderr ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (- *) + (1 2) = 1 ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1457: $PREPARSER ./calc input ./calc.at:1477: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: stderr: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 120): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) LAC: initial context established for number LAC: checking lookahead number: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: Err LAC: checking lookahead '=': S18 LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 input: stderr: | (#) + (#) = 2222 | (1 + 1) / (1 - 1) ./calc.at:1451: $PREPARSER ./calc input ./calc.at:1454: $PREPARSER ./calc input stderr: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1459: cat stderr 1.11-17: error: null divisor ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1458: cat stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1455: cat stderr stderr: ./calc.at:1457: cat stderr input: | (- *) + (1 2) = 1 ./calc.at:1455: $PREPARSER ./calc input 1.11-17: error: null divisor input: input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1459: $PREPARSER ./calc input ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (!!) + (1 2) = 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 119): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) LAC: initial context established for number LAC: checking lookahead number: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: Err LAC: checking lookahead '=': S18 LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1458: $PREPARSER ./calc input ./calc.at:1454: cat stderr stderr: | (* *) + (*) + (*) 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 ./calc.at:1457: $PREPARSER ./calc input 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 stderr: ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 119): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) LAC: initial context established for number LAC: checking lookahead number: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: Err LAC: checking lookahead '=': S18 LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: stdout: ./calc.at:1468: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1451: cat stderr stderr: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 | (1 + #) = 1111 ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1454: $PREPARSER ./calc input 537. calc.at:1451: ok stderr: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1468: $PREPARSER ./calc input ./calc.at:1455: cat stderr stderr: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1459: cat stderr ./calc.at:1457: cat stderr stderr: ./calc.at:1458: cat stderr stderr: input: 1.6: syntax error: invalid character: '#' input: | (!!) + (1 2) = 1 ./calc.at:1459: $PREPARSER ./calc input | (* *) + (*) + (*) stderr: ./calc.at:1455: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G8 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R7 G8 S24 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G8 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R7 G8 S24 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 input: ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 input: ./calc.at:1468: $PREPARSER ./calc input ./calc.at:1455: cat stderr stderr: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error | 1 + 2 * 3 + !+ ++ ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1457: $PREPARSER ./calc input | (- *) + (1 2) = 1 stderr: ./calc.at:1458: $PREPARSER ./calc input ./calc.at:1454: cat stderr stderr: stderr: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 syntax error 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 stderr: input: | 1 + 2 * 3 + !+ ++ ./calc.at:1455: $PREPARSER ./calc input ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1459: cat stderr stderr: ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 550. calc.at:1478: testing Calculator C++ %glr-parser %locations api.location.type={Span} ... ./calc.at:1478: mv calc.y.tmp calc.y ./calc.at:1478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: ./calc.at:1457: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) LAC: initial context established for '+' LAC: checking lookahead '+': R9 G29 R7 G8 S20 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 121): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1454: $PREPARSER ./calc input stderr: | (- *) + (1 2) = 1 ./calc.at:1459: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.2: syntax error: invalid character: '#' input: stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 | 1 + 2 * 3 + !- ++ ./calc.at:1468: cat stderr ./calc.at:1457: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) LAC: initial context established for '+' LAC: checking lookahead '+': R9 G29 R7 G8 S20 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 121): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1458: cat stderr ./calc.at:1455: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | 1 + 2 * 3 + !- ++ ./calc.at:1455: $PREPARSER ./calc input ./calc.at:1454: cat stderr | (* *) + (*) + (*) ./calc.at:1458: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) LAC: initial context established for '+' LAC: checking lookahead '+': R9 G29 R7 G8 S20 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 122): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1468: $PREPARSER ./calc input stderr: stderr: stderr: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) stderr: ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 input: stderr: syntax error stderr: | (1 + # + 1) = 1111 ./calc.at:1454: $PREPARSER ./calc input stderr: stderr: ./calc.at:1457: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) LAC: initial context established for '+' LAC: checking lookahead '+': R9 G29 R7 G8 S20 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 122): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.6: syntax error: invalid character: '#' ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1459: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1458: cat stderr input: input: | (#) + (#) = 2222 ./calc.at:1457: $PREPARSER ./calc input input: ./calc.at:1468: cat stderr ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1459: $PREPARSER ./calc input stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1458: $PREPARSER ./calc input stderr: ./calc.at:1454: cat stderr input: syntax error: invalid character: '#' syntax error: invalid character: '#' 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1455: cat stderr | error ./calc.at:1468: $PREPARSER ./calc input stderr: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' syntax error: invalid character: '#' syntax error ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + 1) / (1 - 1) ./calc.at:1454: $PREPARSER ./calc input stderr: input: stderr: ./calc.at:1458: $EGREP -c -v 'Return for a new token:|LAC:' stderr | (#) + (#) = 2222 ./calc.at:1455: $PREPARSER ./calc input stderr: stderr: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.11-17: error: null divisor stderr: ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) syntax error ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1457: cat stderr ./calc.at:1459: cat stderr stderr: input: stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1458: $PREPARSER ./calc input stderr: ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1468: cat stderr 1.11-17: error: null divisor input: | (1 + #) = 1111 ./calc.at:1457: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' stderr: | 1 + 2 * 3 + !+ ++ input: ./calc.at:1459: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1468: $PREPARSER ./calc input ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error ./calc.at:1454: cat stderr ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1458: cat stderr stderr: ./calc.at:1455: cat stderr syntax error 539. calc.at:1454: ok ./calc.at:1457: cat stderr ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (#) + (#) = 2222 ./calc.at:1458: $PREPARSER ./calc input input: stderr: stderr: | (# + 1) = 1111 ./calc.at:1459: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1457: $PREPARSER ./calc input input: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 ./calc.at:1455: $PREPARSER ./calc input input: | 1 + 2 * 3 + !- ++ stderr: ./calc.at:1459: $PREPARSER ./calc input stderr: stderr: syntax error: invalid character: '#' ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' ./calc.at:1468: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: stdout: ./calc.at:1476: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 551. calc.at:1478: testing Calculator glr2.cc %locations api.location.type={Span} ... ./calc.at:1455: cat stderr ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: mv calc.y.tmp calc.y ./calc.at:1478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: | | +1 stderr: ./calc.at:1468: $PREPARSER ./calc input input: ./calc.at:1458: cat stderr | (# + 1) = 1111 ./calc.at:1455: $PREPARSER ./calc input stderr: ./calc.at:1459: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) LAC: initial context established for '+' LAC: checking lookahead '+': Err Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: syntax error input: | 1 2 ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1457: cat stderr stderr: ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1458: $PREPARSER ./calc input input: stderr: stderr: syntax error 1.6: syntax error: invalid character: '#' stderr: | (#) + (#) = 2222 ./calc.at:1459: $PREPARSER ./calc input ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) LAC: initial context established for '+' LAC: checking lookahead '+': Err Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: syntax error | (1 + # + 1) = 1111 ./calc.at:1457: $PREPARSER ./calc input ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error: invalid character: '#' ./calc.at:1455: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1458: cat stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1459: cat stderr input: ./calc.at:1468: cat stderr | (# + 1) = 1111 ./calc.at:1458: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' input: ./calc.at:1468: $PREPARSER ./calc /dev/null | (1 + # + 1) = 1111 ./calc.at:1455: $PREPARSER ./calc input ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1457: cat stderr stderr: input: | (1 + 1) / (1 - 1) ./calc.at:1457: $PREPARSER ./calc input | (1 + #) = 1111 ./calc.at:1476: cat stderr ./calc.at:1459: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) LAC: initial context established for '+' LAC: checking lookahead '+': Err Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: error: null divisor ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: error: null divisor 1.6: syntax error: invalid character: '#' 1.2: syntax error: invalid character: '#' syntax error input: stderr: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) LAC: initial context established for '+' LAC: checking lookahead '+': Err Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1//2 ./calc.at:1476: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1458: cat stderr ./calc.at:1455: cat stderr ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1457: cat stderr input: ./calc.at:1459: cat stderr input: | (1 + # + 1) = 1111 stderr: ./calc.at:1468: cat stderr syntax error ./calc.at:1458: $PREPARSER ./calc input | (1 + 1) / (1 - 1) 541. calc.at:1457: ok ./calc.at:1455: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' stderr: input: | (# + 1) = 1111 stderr: input: ./calc.at:1459: $PREPARSER ./calc input stderr: stdout: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) LAC: initial context established for ')' LAC: checking lookahead ')': R7 G12 S26 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 92): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) LAC: initial context established for ')' LAC: checking lookahead ')': R8 G12 S26 Reducing stack by rule 8 (line 104): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R10 G8 S24 Reducing stack by rule 10 (line 106): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 1.2: syntax error: invalid character: '#' ./calc.at:1468: $PREPARSER ./calc input ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1477: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: ./calc.at:1458: cat stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + 1) / (1 - 1) ./calc.at:1458: $PREPARSER ./calc input syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor input: stderr: 1.2: syntax error: invalid character: '#' stderr: stderr: ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1477: $PREPARSER ./calc input syntax error syntax error syntax error syntax error error: 4444 != 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) LAC: initial context established for ')' LAC: checking lookahead ')': R7 G12 S26 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 92): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) LAC: initial context established for ')' LAC: checking lookahead ')': R8 G12 S26 Reducing stack by rule 8 (line 104): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R10 G8 S24 Reducing stack by rule 10 (line 106): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1476: cat stderr stderr: ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1459: cat stderr stderr: stderr: | error input: | 1 2 ./calc.at:1476: $PREPARSER ./calc input stderr: ./calc.at:1477: $PREPARSER ./calc input 1.11-17: error: null divisor stderr: syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error ./calc.at:1458: cat stderr | (1 + # + 1) = 1111 ./calc.at:1459: $PREPARSER ./calc input stderr: 1.3: syntax error ./calc.at:1455: cat stderr stderr: 1.6: syntax error: invalid character: '#' 552. calc.at:1479: testing Calculator C++ %glr-parser %header parse.error=verbose %name-prefix "calc" %verbose ... ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 542. calc.at:1458: ok ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: mv calc.y.tmp calc.y stderr: ./calc.at:1468: cat stderr 1.6: syntax error: invalid character: '#' 540. calc.at:1455: ok ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: cat stderr ./calc.at:1479: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: input: ./calc.at:1459: cat stderr | 1 = 2 = 3 ./calc.at:1476: $PREPARSER ./calc input | (!!) + (1 2) = 1 ./calc.at:1468: $PREPARSER ./calc input stderr: syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1477: cat stderr stderr: syntax error syntax error error: 2222 != 1 ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + 1) / (1 - 1) stderr: ./calc.at:1459: $PREPARSER ./calc input stderr: syntax error error: 2222 != 1 input: 1.11-17: error: null divisor | 1//2 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 553. calc.at:1479: testing Calculator glr2.cc %header parse.error=verbose %name-prefix "calc" %verbose ... ./calc.at:1479: mv calc.y.tmp calc.y 1.3: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error ./calc.at:1479: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS stderr: 1.11-17: error: null divisor ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1476: cat stderr ./calc.at:1459: cat stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1468: cat stderr input: | | +1 ./calc.at:1476: $PREPARSER ./calc input 543. calc.at:1459: ok stderr: 554. calc.at:1480: testing Calculator C++ %glr-parser parse.error=verbose api.prefix={calc} %verbose ... input: ./calc.at:1480: mv calc.y.tmp calc.y syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y | (- *) + (1 2) = 1 ./calc.at:1468: $PREPARSER ./calc input ./calc.at:1477: cat stderr ./calc.at:1479: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS stderr: stderr: syntax error syntax error error: 2222 != 1 ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error input: ./calc.at:1480: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: | error syntax error syntax error error: 2222 != 1 ./calc.at:1477: $PREPARSER ./calc input stderr: 1.1: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 555. calc.at:1480: testing Calculator glr2.cc parse.error=verbose api.prefix={calc} %verbose ... ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: mv calc.y.tmp calc.y ./calc.at:1476: cat stderr ./calc.at:1480: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1476: $PREPARSER ./calc /dev/null ./calc.at:1477: cat stderr ./calc.at:1468: cat stderr stderr: syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error input: input: | 1 = 2 = 3 | (* *) + (*) + (*) ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1468: $PREPARSER ./calc input stderr: 1.7: syntax error stderr: ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error syntax error ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1476: cat stderr stderr: syntax error syntax error syntax error 1.7: syntax error input: ./calc.at:1480: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1477: cat stderr syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1468: cat stderr stderr: input: | 1 + 2 * 3 + !+ ++ stdout: ./calc.at:1468: $PREPARSER ./calc input input: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1469: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc | | +1 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: 2.1: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1469: $PREPARSER ./calc input stderr: input: ./calc.at:1476: cat stderr | 1 + 2 * 3 + !- ++ stderr: ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1468: $PREPARSER ./calc input 2.1: syntax error stderr: ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 input: ./calc.at:1476: $PREPARSER ./calc input | 1 2 ./calc.at:1469: $PREPARSER ./calc input stderr: stderr: syntax error error: 2222 != 1 syntax error ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: cat stderr stderr: stderr: stderr: ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error error: 2222 != 1 ./calc.at:1477: $PREPARSER ./calc /dev/null stdout: syntax error ./calc.at:1478: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: 1.1: syntax error input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1468: cat stderr stderr: input: | 1 2 ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error stderr: input: ./calc.at:1476: cat stderr 1.3: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1468: $PREPARSER ./calc input ./calc.at:1469: cat stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1477: cat stderr syntax error: invalid character: '#' syntax error: invalid character: '#' 1.3: syntax error input: ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1477: $PREPARSER ./calc input | 1//2 ./calc.at:1469: $PREPARSER ./calc input stderr: | (- *) + (1 2) = 1 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: $PREPARSER ./calc input stderr: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error stderr: ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error error: 2222 != 1 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: syntax error ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error syntax error error: 2222 != 1 ./calc.at:1478: cat stderr input: ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1468: cat stderr ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.3: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: cat stderr stderr: ./calc.at:1477: cat stderr 1.3: syntax error input: input: | (1 + #) = 1111 | (* *) + (*) + (*) ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1468: $PREPARSER ./calc input input: ./calc.at:1469: cat stderr stderr: syntax error: invalid character: '#' | (!!) + (1 2) = 1 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error syntax error syntax error 1.11: syntax error 1.1-16: error: 2222 != 1 stderr: ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | error ./calc.at:1478: cat stderr ./calc.at:1469: $PREPARSER ./calc input stderr: input: | error ./calc.at:1478: $PREPARSER ./calc input stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 syntax error: invalid character: '#' stderr: stdout: stderr: 1.1: syntax error ./calc.at:1476: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error syntax error ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1476: $PREPARSER ./calc input 1.1: syntax error ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: cat stderr stderr: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1468: cat stderr input: ./calc.at:1478: cat stderr | 1 2 ./calc.at:1476: $PREPARSER ./calc input input: | (- *) + (1 2) = 1 ./calc.at:1477: $PREPARSER ./calc input stderr: syntax error input: ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (# + 1) = 1111 ./calc.at:1468: $PREPARSER ./calc input input: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error | 1 = 2 = 3 ./calc.at:1478: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.7: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.7: syntax error stderr: ./calc.at:1469: cat stderr ./calc.at:1476: cat stderr 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 stderr: syntax error: invalid character: '#' ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 = 2 = 3 ./calc.at:1469: $PREPARSER ./calc input stderr: syntax error input: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !+ ++ ./calc.at:1476: cat stderr ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | 1//2 ./calc.at:1476: $PREPARSER ./calc input stderr: syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error stderr: ./calc.at:1478: cat stderr ./calc.at:1468: cat stderr ./calc.at:1477: cat stderr syntax error input: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 input: ./calc.at:1478: $PREPARSER ./calc input input: ./calc.at:1476: cat stderr | (* *) + (*) + (*) ./calc.at:1477: $PREPARSER ./calc input stderr: input: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (1 + # + 1) = 1111 ./calc.at:1468: $PREPARSER ./calc input | error ./calc.at:1476: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ ./calc.at:1476: $PREPARSER ./calc input 2.1: syntax error ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error stderr: stderr: 2.1: syntax error syntax error: invalid character: '#' ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error ./calc.at:1469: cat stderr stderr: ./calc.at:1477: cat stderr input: | 1 + 2 * 3 + !+ ++ ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error: invalid character: '#' ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: | | +1 input: ./calc.at:1469: $PREPARSER ./calc input ./calc.at:1476: cat stderr | 1 + 2 * 3 + !- ++ ./calc.at:1477: $PREPARSER ./calc input stderr: stderr: syntax error ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 stderr: ./calc.at:1476: $PREPARSER ./calc input syntax error stderr: ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: cat stderr ./calc.at:1478: $PREPARSER ./calc /dev/null stderr: stderr: ./calc.at:1468: cat stderr ./calc.at:1476: cat stderr 1.1: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error 1.1: syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | (1 + 1) / (1 - 1) ./calc.at:1468: $PREPARSER ./calc input ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (#) + (#) = 2222 ./calc.at:1476: $PREPARSER ./calc input stderr: stderr: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: cat stderr error: null divisor ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: syntax error stderr: | (#) + (#) = 2222 stderr: ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1469: cat stderr error: null divisor stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1469: $PREPARSER ./calc /dev/null 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1478: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1476: cat stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1478: $PREPARSER ./calc input syntax error input: stderr: | (1 + #) = 1111 ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1476: cat stderr stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: cat stderr syntax error: invalid character: '#' ./calc.at:1468: cat stderr ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: syntax error: invalid character: '#' | | +1 ./calc.at:1476: $PREPARSER ./calc input stderr: stderr: 544. calc.at:1468: ok syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: cat stderr input: stderr: syntax error ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1469: cat stderr | (1 + #) = 1111 ./calc.at:1477: $PREPARSER ./calc input stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (# + 1) = 1111 1.6: syntax error: invalid character: '#' ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' ./calc.at:1478: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1469: $PREPARSER ./calc input stderr: stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: cat stderr syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1476: $PREPARSER ./calc /dev/null input: stderr: | (!!) + (1 2) = 1 syntax error ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1477: cat stderr syntax error syntax error syntax error syntax error error: 4444 != 1 556. calc.at:1482: testing Calculator C++ %glr-parser %debug ... ./calc.at:1482: mv calc.y.tmp calc.y syntax error ./calc.at:1482: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (# + 1) = 1111 ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: cat stderr ./calc.at:1482: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1469: cat stderr ./calc.at:1476: cat stderr stderr: input: ./calc.at:1478: cat stderr input: stderr: stdout: | (!!) + (1 2) = 1 ./calc.at:1469: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1476: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' ./calc.at:1480: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: syntax error error: 2222 != 1 stderr: ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + # + 1) = 1111 ./calc.at:1476: $PREPARSER ./calc input stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error error: 2222 != 1 input: input: stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1480: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1478: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: cat stderr ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1476: cat stderr ./calc.at:1469: cat stderr stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 input: | (!!) + (1 2) = 1 ./calc.at:1476: $PREPARSER ./calc input stderr: syntax error error: 2222 != 1 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (- *) + (1 2) = 1 ./calc.at:1469: $PREPARSER ./calc input ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: syntax error syntax error error: 2222 != 1 ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1480: $PREPARSER ./calc input input: stderr: syntax error syntax error error: 2222 != 1 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + # + 1) = 1111 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1476: cat stderr stderr: stderr: syntax error error: 2222 != 1 input: | (1 + 1) / (1 - 1) ./calc.at:1476: $PREPARSER ./calc input stderr: syntax error, unexpected number ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: ./calc.at:1477: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc syntax error, unexpected number ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1478: cat stderr input: error: null divisor ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1477: $PREPARSER ./calc input stderr: stderr: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (* *) + (*) + (*) ./calc.at:1478: $PREPARSER ./calc input stderr: error: null divisor stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 2 ./calc.at:1480: cat stderr ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1469: cat stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error input: | 1//2 ./calc.at:1480: $PREPARSER ./calc input stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (* *) + (*) + (*) ./calc.at:1469: $PREPARSER ./calc input stderr: stderr: 1.3: syntax error ./calc.at:1477: cat stderr syntax error syntax error syntax error ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: cat stderr stderr: stderr: input: syntax error, unexpected '/', expecting number or '-' or '(' or '!' syntax error syntax error syntax error input: | 1 + 2 * 3 + !+ ++ | (1 + 1) / (1 - 1) ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1477: $PREPARSER ./calc input stderr: stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11-17: error: null divisor ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: cat stderr stderr: stderr: ./calc.at:1477: cat stderr input: 1.11-17: error: null divisor ./calc.at:1476: cat stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !- ++ ./calc.at:1478: $PREPARSER ./calc input stderr: ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: ./calc.at:1480: cat stderr | 1//2 ./calc.at:1477: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 546. calc.at:1476: ok stderr: input: stderr: 1.3: syntax error | error ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1469: cat stderr syntax error syntax error error: 2222 != 1 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: cat stderr stderr: stderr: syntax error, unexpected invalid token syntax error syntax error error: 2222 != 1 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 548. calc.at:1477: ok stderr: input: 1.3: syntax error | 1 + 2 * 3 + !+ ++ ./calc.at:1469: $PREPARSER ./calc input stderr: ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected invalid token input: 557. calc.at:1482: testing Calculator glr2.cc %debug ... | 1 + 2 * 3 + !- ++ ./calc.at:1469: $PREPARSER ./calc input ./calc.at:1482: mv calc.y.tmp calc.y ./calc.at:1482: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1478: cat stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: cat stderr stderr: input: input: | (#) + (#) = 2222 ./calc.at:1476: cat stderr ./calc.at:1478: $PREPARSER ./calc input | error ./calc.at:1477: $PREPARSER ./calc input stderr: 1.1: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) ./calc.at:1476: $PREPARSER ./calc input stderr: ./calc.at:1482: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: stderr: ./calc.at:1480: cat stderr syntax error syntax error syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 558. calc.at:1485: testing Calculator C++ %glr-parser parse.error=detailed %debug %name-prefix "calc" %verbose ... ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1469: cat stderr input: input: syntax error syntax error syntax error | 1 = 2 = 3 ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1485: mv calc.y.tmp calc.y | (#) + (#) = 2222 ./calc.at:1469: $PREPARSER ./calc input stderr: ./calc.at:1478: cat stderr stderr: ./calc.at:1485: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y syntax error, unexpected '=' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1477: cat stderr ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + #) = 1111 stderr: ./calc.at:1478: $PREPARSER ./calc input stderr: syntax error, unexpected '=' stderr: input: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' syntax error: invalid character: '#' | 1 = 2 = 3 ./calc.at:1477: $PREPARSER ./calc input stderr: 1.7: syntax error 1.6: syntax error: invalid character: '#' ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.7: syntax error stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1485: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1476: cat stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !+ ++ ./calc.at:1476: $PREPARSER ./calc input input: | | +1 ./calc.at:1480: $PREPARSER ./calc input stderr: stderr: syntax error, unexpected '+' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: cat stderr ./calc.at:1469: cat stderr ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected '+' ./calc.at:1478: cat stderr input: stderr: | (1 + #) = 1111 ./calc.at:1469: $PREPARSER ./calc input input: stderr: syntax error: invalid character: '#' ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | | +1 ./calc.at:1477: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ ./calc.at:1476: $PREPARSER ./calc input input: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: | (# + 1) = 1111 ./calc.at:1478: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1480: cat stderr stderr: 2.1: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./calc.at:1480: $PREPARSER ./calc /dev/null ./calc.at:1479: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh stderr: stderr: stderr: syntax error, unexpected end of input 1.2: syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 2.1: syntax error input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1479: $PREPARSER ./calc input stderr: ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected end of input stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1478: cat stderr ./calc.at:1469: cat stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stdout: | 1 2 ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1477: cat stderr ./calc.at:1478: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1480: cat stderr input: | (# + 1) = 1111 ./calc.at:1469: $PREPARSER ./calc input stderr: ./calc.at:1476: cat stderr stderr: syntax error, unexpected number input: ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: $PREPARSER ./calc /dev/null | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1480: $PREPARSER ./calc input syntax error: invalid character: '#' input: ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: | (1 + # + 1) = 1111 1.1: syntax error ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: 1.6: syntax error: invalid character: '#' | (#) + (#) = 2222 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: $PREPARSER ./calc input input: stderr: syntax error: invalid character: '#' stderr: stderr: syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' syntax error, unexpected number | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1478: $PREPARSER ./calc input stderr: stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' 1.1: syntax error stderr: ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: cat stderr ./calc.at:1469: cat stderr ./calc.at:1480: cat stderr input: stderr: | 1//2 ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1478: cat stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + # + 1) = 1111 ./calc.at:1469: $PREPARSER ./calc input input: | 1 2 | (!!) + (1 2) = 1 ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1480: $PREPARSER ./calc input stderr: ./calc.at:1477: cat stderr stderr: stderr: stderr: syntax error: invalid character: '#' input: ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: cat stderr stderr: stderr: 1.3: syntax error syntax error, unexpected number error: 2222 != 1 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected number error: 2222 != 1 | (1 + 1) / (1 - 1) syntax error: invalid character: '#' ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 1.11-17: error: null divisor ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: cat stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1480: cat stderr stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1//2 | (1 + #) = 1111 ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1479: cat stderr ./calc.at:1476: $PREPARSER ./calc input stderr: stderr: input: stderr: 1.3: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11-17: error: null divisor syntax error: invalid character: '#' ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (- *) + (1 2) = 1 ./calc.at:1480: $PREPARSER ./calc input stderr: input: | error syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: cat stderr ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1479: $PREPARSER ./calc input syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 stderr: ./calc.at:1469: cat stderr ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' stderr: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected invalid token ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1478: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1469: $PREPARSER ./calc input stderr: error: null divisor ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1480: cat stderr stderr: stderr: stderr: syntax error, unexpected invalid token error: null divisor 1.11: syntax error 1.1-16: error: 2222 != 1 input: ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1478: $PREPARSER ./calc input input: ./calc.at:1478: cat stderr stderr: | (* *) + (*) + (*) 1.1: syntax error ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: cat stderr stderr: stderr: stderr: 1.1: syntax error 550. calc.at:1478: ok ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: cat stderr 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' | (# + 1) = 1111 ./calc.at:1476: $PREPARSER ./calc input stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 = 2 = 3 ./calc.at:1479: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1469: cat stderr ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: cat stderr stderr: syntax error, unexpected '=' ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 545. calc.at:1469: stderr: ok ./calc.at:1480: cat stderr syntax error: invalid character: '#' input: ./calc.at:1477: cat stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1480: $PREPARSER ./calc input stderr: syntax error, unexpected '=' 559. calc.at:1485: testing Calculator glr2.cc parse.error=detailed %debug %name-prefix "calc" %verbose ... ./calc.at:1485: mv calc.y.tmp calc.y input: | 1 = 2 = 3 ./calc.at:1478: $PREPARSER ./calc input stderr: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1485: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1480: $PREPARSER ./calc input 1.7: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (- *) + (1 2) = 1 1.7: syntax error ./calc.at:1477: $PREPARSER ./calc input stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: cat stderr ./calc.at:1476: cat stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: 560. calc.at:1486: testing Calculator C++ %glr-parser parse.error=verbose %debug %name-prefix "calc" %verbose ... ./calc.at:1486: mv calc.y.tmp calc.y input: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 | (1 + # + 1) = 1111 ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1486: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y syntax error: invalid character: '#' | | +1 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr ./calc.at:1479: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1478: cat stderr input: ./calc.at:1477: cat stderr stderr: | (#) + (#) = 2222 ./calc.at:1480: $PREPARSER ./calc input syntax error, unexpected '+' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (* *) + (*) + (*) ./calc.at:1477: $PREPARSER ./calc input syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' syntax error, unexpected '+' input: stderr: | | +1 ./calc.at:1478: $PREPARSER ./calc input 1.2: syntax error 1.10: syntax error 1.16: syntax error stderr: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 2.1: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: cat stderr ./calc.at:1486: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS input: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 ./calc.at:1480: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error 1.10: syntax error 1.16: syntax error stderr: ./calc.at:1476: cat stderr ./calc.at:1479: cat stderr 2.1: syntax error ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: $PREPARSER ./calc /dev/null stderr: syntax error, unexpected end of input ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + 1) / (1 - 1) ./calc.at:1476: $PREPARSER ./calc input stderr: ./calc.at:1480: cat stderr stderr: syntax error, unexpected end of input ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: cat stderr error: null divisor input: | (# + 1) = 1111 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: $PREPARSER ./calc input stderr: stdout: stderr: ./calc.at:1482: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc syntax error: invalid character: '#' stderr: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: null divisor input: ./calc.at:1478: cat stderr | 1 + 2 * 3 + !+ ++ input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1477: $PREPARSER ./calc input stderr: stdout: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1478: $PREPARSER ./calc /dev/null stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1479: cat stderr stderr: ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.1: syntax error stderr: | 1 2 ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: stderr: input: | 1 + 2 * 3 + !- ++ ./calc.at:1477: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) input: ./calc.at:1479: $PREPARSER ./calc input stderr: stderr: stderr: 1.1: syntax error syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 | 1 2 ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: cat stderr ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected number stderr: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 stderr: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 547. calc.at:1476: ok ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error, unexpected number ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: cat stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: ./calc.at:1482: cat stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1479: cat stderr | (1 + # + 1) = 1111 stderr: ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1480: cat stderr 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: cat stderr stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 stderr: input: input: 561. calc.at:1486: testing Calculator glr2.cc parse.error=verbose %debug %name-prefix "calc" %verbose ... syntax error: invalid character: '#' | (#) + (#) = 2222 ./calc.at:1486: mv calc.y.tmp calc.y ./calc.at:1477: $PREPARSER ./calc input | 1//2 input: input: ./calc.at:1480: $PREPARSER ./calc input | 1//2 ./calc.at:1482: $PREPARSER ./calc input stderr: stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1486: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (!!) + (1 2) = 1 stderr: ./calc.at:1479: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error, unexpected number error: 2222 != 1 stderr: ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () stderr: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected number error: 2222 != 1 ./calc.at:1478: cat stderr ./calc.at:1477: cat stderr ./calc.at:1480: cat stderr ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS input: | (1 + #) = 1111 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (!!) + (1 2) = 1 ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1482: cat stderr input: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr stderr: stderr: ./calc.at:1479: cat stderr input: | (1 + 1) / (1 - 1) ./calc.at:1480: $PREPARSER ./calc input | error 1.6: syntax error: invalid character: '#' 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: $PREPARSER ./calc input stderr: stderr: stderr: syntax error, unexpected invalid token input: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error error: null divisor ./calc.at:1482: $PREPARSER ./calc input stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 input: Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error Cleanup: discarding lookahead token "invalid token" () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1479: $PREPARSER ./calc input syntax error, unexpected invalid token stderr: stderr: error: null divisor syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: cat stderr stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error Cleanup: discarding lookahead token "invalid token" () ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (# + 1) = 1111 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1479: cat stderr stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (* *) + (*) + (*) ./calc.at:1479: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' stderr: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr ./calc.at:1482: cat stderr ./calc.at:1480: cat stderr 554. calc.at:1480: ok ./calc.at:1478: cat stderr ./calc.at:1477: cat stderr input: input: | (- *) + (1 2) = 1 ./calc.at:1478: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1480: $PREPARSER ./calc input stderr: input: input: | 1 = 2 = 3 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 | (1 + # + 1) = 1111 stderr: ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: $PREPARSER ./calc input syntax error, unexpected '=' ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.6: syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1479: cat stderr stderr: 1.6: syntax error: invalid character: '#' syntax error, unexpected '=' ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 562. calc.at:1487: testing Calculator glr2.cc parse.error=custom %debug %name-prefix "calc" %verbose ... | 1 + 2 * 3 + !+ ++ ./calc.at:1479: $PREPARSER ./calc input stderr: ./calc.at:1487: mv calc.y.tmp calc.y ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: cat stderr ./calc.at:1477: cat stderr ./calc.at:1487: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + 1) / (1 - 1) ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1480: cat stderr input: input: | (* *) + (*) + (*) ./calc.at:1478: $PREPARSER ./calc input stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1479: $PREPARSER ./calc input 1.11-17: error: null divisor stderr: ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1482: cat stderr ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | | +1 ./calc.at:1480: $PREPARSER ./calc input stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error stderr: stderr: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected '+' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.11-17: error: null divisor ./calc.at:1479: cat stderr ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1482: $PREPARSER ./calc input input: | (#) + (#) = 2222 ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1487: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error, unexpected '+' syntax error: invalid character: '#' syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: cat stderr ./calc.at:1477: cat stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error Error: popping nterm input () Cleanup: discarding lookahead token '+' () input: 549. calc.at:1477: ok | 1 + 2 * 3 + !+ ++ ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !- ++ ./calc.at:1478: $PREPARSER ./calc input stderr: ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1480: cat stderr ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: cat stderr ./calc.at:1478: cat stderr ./calc.at:1480: $PREPARSER ./calc /dev/null ./calc.at:1482: cat stderr stderr: syntax error, unexpected end of input input: input: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1479: $PREPARSER ./calc input stderr: | (#) + (#) = 2222 syntax error: invalid character: '#' ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: $PREPARSER ./calc /dev/null stderr: stderr: stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' syntax error, unexpected end of input ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" () 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 563. calc.at:1489: testing Calculator C++ %glr-parser parse.error=verbose %debug %name-prefix "calc" api.token.prefix={TOK_} %verbose ... ./calc.at:1489: mv calc.y.tmp calc.y ./calc.at:1489: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: cat stderr ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr stderr: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: stdout: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 | (# + 1) = 1111 ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1478: cat stderr ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1485: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: syntax error: invalid character: '#' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: cat stderr stderr: stderr: syntax error: invalid character: '#' input: syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 input: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1485: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1482: $PREPARSER ./calc input | (1 + #) = 1111 stderr: ./calc.at:1478: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () input: input: stderr: | (!!) + (1 2) = 1 | 1 2 ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1485: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: cat stderr syntax error, unexpected number error: 2222 != 1 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) input: | (1 + # + 1) = 1111 ./calc.at:1479: $PREPARSER ./calc input stderr: stderr: syntax error: invalid character: '#' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected number error: 2222 != 1 stderr: ./calc.at:1478: cat stderr syntax error: invalid character: '#' ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr ./calc.at:1485: cat stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | (- *) + (1 2) = 1 ./calc.at:1480: $PREPARSER ./calc input input: stderr: input: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 | (!!) + (1 2) = 1 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: $PREPARSER ./calc input | 1//2 | (# + 1) = 1111 ./calc.at:1485: $PREPARSER ./calc input stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1479: cat stderr ./calc.at:1478: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: cat stderr input: 1.2: syntax error: invalid character: '#' ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (* *) + (*) + (*) ./calc.at:1480: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' | (1 + 1) / (1 - 1) ./calc.at:1479: $PREPARSER ./calc input stderr: stderr: stderr: error: null divisor Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' stderr: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 error: null divisor ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr input: ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (- *) + (1 2) = 1 ./calc.at:1482: $PREPARSER ./calc input stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1478: cat stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1480: $PREPARSER ./calc input stderr: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1485: cat stderr stderr: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !- ++ ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1479: cat stderr stderr: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (1 + # + 1) = 1111 ./calc.at:1478: $PREPARSER ./calc input 552. calc.at:1479: ok ./calc.at:1482: cat stderr input: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1480: cat stderr stderr: 1.6: syntax error: invalid character: '#' input: | (#) + (#) = 2222 ./calc.at:1480: $PREPARSER ./calc input input: stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' | (* *) + (*) + (*) ./calc.at:1482: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () stderr: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () ./calc.at:1478: cat stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: input: ./calc.at:1480: cat stderr ./calc.at:1479: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh input: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1479: $PREPARSER ./calc input stderr: | (1 + 1) / (1 - 1) ./calc.at:1478: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: 1.11-17: error: null divisor ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1480: $PREPARSER ./calc input stderr: 564. calc.at:1489: testing Calculator glr2.cc parse.error=verbose %debug %name-prefix "calc" api.token.prefix={TOK_} %verbose ... stderr: ./calc.at:1489: mv calc.y.tmp calc.y input: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1489: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: 1.11-17: error: null divisor stderr: ./calc.at:1482: cat stderr syntax error: invalid character: '#' ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected number ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1485: cat stderr stderr: stderr: syntax error, unexpected number Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1478: cat stderr input: input: | 1 = 2 = 3 ./calc.at:1485: $PREPARSER ./calc input 551. calc.at:1478: | 1 + 2 * 3 + !- ++ ok ./calc.at:1482: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1489: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1480: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) input: | 1//2 ./calc.at:1479: $PREPARSER ./calc input stderr: input: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 ./calc.at:1480: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 565. calc.at:1491: testing Calculator C++ %glr-parser %locations %header parse.error=verbose %debug %name-prefix "calc" %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1485: cat stderr ./calc.at:1491: mv calc.y.tmp calc.y stderr: syntax error: invalid character: '#' ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr input: ./calc.at:1479: cat stderr | | +1 ./calc.at:1485: $PREPARSER ./calc input stderr: ./calc.at:1491: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () input: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (#) + (#) = 2222 ./calc.at:1482: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | error ./calc.at:1480: cat stderr ./calc.at:1479: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: stderr: | (1 + # + 1) = 1111 ./calc.at:1480: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected invalid token ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected invalid token stderr: syntax error: invalid character: '#' ./calc.at:1485: cat stderr ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr ./calc.at:1485: $PREPARSER ./calc /dev/null ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr stderr: Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of file Cleanup: discarding lookahead token end of file () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + 1) / (1 - 1) ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1479: cat stderr stderr: stderr: error: null divisor stderr: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of file Cleanup: discarding lookahead token end of file () input: stdout: stderr: | (1 + #) = 1111 ./calc.at:1482: $PREPARSER ./calc input error: null divisor ./calc.at:1486: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: cat stderr input: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 | 1 = 2 = 3 ./calc.at:1486: $PREPARSER ./calc input ./calc.at:1479: $PREPARSER ./calc input stderr: stderr: syntax error, unexpected '=' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected '=' stderr: 555. calc.at:1480: ok stderr: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: ./calc.at:1479: cat stderr | 1 2 input: ./calc.at:1486: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1485: $PREPARSER ./calc input input: | | +1 ./calc.at:1479: $PREPARSER ./calc input stderr: syntax error, unexpected '+' stderr: ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error, unexpected '+' Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: cat stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1479: $PREPARSER ./calc /dev/null stderr: syntax error, unexpected end of input ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 566. calc.at:1491: testing Calculator glr2.cc %locations %header parse.error=verbose %debug %name-prefix "calc" %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1491: mv calc.y.tmp calc.y ./calc.at:1491: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1482: cat stderr stderr: syntax error, unexpected end of input ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1485: cat stderr ./calc.at:1486: cat stderr ./calc.at:1491: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS | (# + 1) = 1111 ./calc.at:1482: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1479: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: input: input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 120): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1479: $PREPARSER ./calc input stderr: syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 120): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr ./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () input: | (- *) + (1 2) = 1 ./calc.at:1485: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 119): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 119): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1479: cat stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + # + 1) = 1111 ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1485: cat stderr stderr: input: input: | (* *) + (*) + (*) ./calc.at:1485: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: cat stderr ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () | (!!) + (1 2) = 1 ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: $PREPARSER ./calc input input: stderr: | error ./calc.at:1486: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: stderr: syntax error, unexpected number error: 2222 != 1 ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected number error: 2222 != 1 stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" () ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: cat stderr input: | 1 + 2 * 3 + !+ ++ ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr stderr: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 121): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: cat stderr input: ./calc.at:1479: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1482: $PREPARSER ./calc input input: stderr: | 1 = 2 = 3 ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 121): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () input: | 1 + 2 * 3 + !- ++ stderr: ./calc.at:1485: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 122): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 122): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) input: | (- *) + (1 2) = 1 ./calc.at:1479: $PREPARSER ./calc input stdout: stderr: ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1485: cat stderr stderr: ./calc.at:1482: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (#) + (#) = 2222 syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1485: $PREPARSER ./calc input stderr: input: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: cat stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | | +1 ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1482: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1479: cat stderr input: | 1 2 ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 556. calc.at:1482: ok ./calc.at:1485: cat stderr input: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1486: cat stderr stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) | (1 + #) = 1111 ./calc.at:1485: $PREPARSER ./calc input syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: $PREPARSER ./calc /dev/null stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" () ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: cat stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1486: $PREPARSER ./calc input stderr: ./calc.at:1482: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 567. calc.at:1492: testing Calculator C++ %glr-parser %locations %header parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: ./calc.at:1492: mv calc.y.tmp calc.y | 1//2 ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: cat stderr ./calc.at:1485: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 ./calc.at:1485: $PREPARSER ./calc input stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1492: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: ./calc.at:1486: cat stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1479: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (!!) + (1 2) = 1 ./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: ./calc.at:1482: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: | error ./calc.at:1482: $PREPARSER ./calc input input: stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error Cleanup: discarding lookahead token "invalid token" () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: | 1 + 2 * 3 + !- ++ Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error Cleanup: discarding lookahead token "invalid token" () ./calc.at:1479: $PREPARSER ./calc input stderr: ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: ./calc.at:1489: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS input: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1489: $PREPARSER ./calc input ./calc.at:1485: cat stderr ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: | (1 + # + 1) = 1111 ./calc.at:1485: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr | 1 2 ./calc.at:1489: $PREPARSER ./calc input input: stderr: | (- *) + (1 2) = 1 ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) ./calc.at:1486: $PREPARSER ./calc input ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1479: cat stderr ./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | 1 = 2 = 3 stderr: ./calc.at:1482: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: | (1 + 1) / (1 - 1) ./calc.at:1485: $PREPARSER ./calc input input: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () | (#) + (#) = 2222 ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 106): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 106): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: cat stderr ./calc.at:1489: cat stderr ./calc.at:1486: cat stderr ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | (1 + #) = 1111 input: ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1485: cat stderr | 1//2 ./calc.at:1489: $PREPARSER ./calc input | (* *) + (*) + (*) ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: stderr: syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: cat stderr ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 558. calc.at:1485: ok stderr: stderr: stderr: syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: | | +1 ./calc.at:1482: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: cat stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error Error: popping nterm input () Cleanup: discarding lookahead token '+' () 568. calc.at:1492: testing Calculator glr2.cc %locations %header parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1492: mv calc.y.tmp calc.y ./calc.at:1489: cat stderr input: ./calc.at:1492: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y | (# + 1) = 1111 ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1486: cat stderr stderr: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: syntax error: invalid character: '#' input: ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1489: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: stderr: syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: cat stderr Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" () ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: $PREPARSER ./calc /dev/null stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1492: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS ./calc.at:1479: cat stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" () input: ./calc.at:1489: cat stderr ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: input: | 1 = 2 = 3 input: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" () stderr: | (1 + # + 1) = 1111 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) stderr: stderr: syntax error: invalid character: '#' ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: cat stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr ./calc.at:1489: cat stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1482: $PREPARSER ./calc input | (#) + (#) = 2222 ./calc.at:1479: cat stderr ./calc.at:1486: $PREPARSER ./calc input input: stderr: | | +1 ./calc.at:1489: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + 1) / (1 - 1) stderr: ./calc.at:1479: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stdout: stderr: ./calc.at:1485: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () stderr: stderr: error: null divisor ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1489: cat stderr ./calc.at:1489: $PREPARSER ./calc /dev/null stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" () error: null divisor ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () input: | 1 2 ./calc.at:1485: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" () ./calc.at:1482: cat stderr ./calc.at:1486: cat stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + #) = 1111 ./calc.at:1485: cat stderr | (!!) + (1 2) = 1 ./calc.at:1486: $PREPARSER ./calc input ./calc.at:1482: $PREPARSER ./calc input stderr: ./calc.at:1479: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: 553. calc.at:1479: | 1//2 ok ./calc.at:1485: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: cat stderr input: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1489: $PREPARSER ./calc input input: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | error ./calc.at:1486: cat stderr ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1482: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (- *) + (1 2) = 1 ./calc.at:1482: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () | (# + 1) = 1111 ./calc.at:1486: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () 569. calc.at:1494: testing Calculator C++ %glr-parser %no-lines %locations %header parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1494: mv calc.y.tmp calc.y ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1494: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stdout: ./calc.at:1485: cat stderr ./calc.at:1486: cat stderr ./calc.at:1489: cat stderr ./calc.at:1486: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc input: input: input: input: ./calc.at:1482: cat stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1486: $PREPARSER ./calc input | (1 + # + 1) = 1111 | 1 = 2 = 3 ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1486: $PREPARSER ./calc input | (!!) + (1 2) = 1 ./calc.at:1489: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () | (* *) + (*) + (*) ./calc.at:1494: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS ./calc.at:1482: $PREPARSER ./calc input stderr: input: stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: cat stderr stderr: ./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: cat stderr input: input: | (1 + 1) / (1 - 1) input: ./calc.at:1486: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1489: $PREPARSER ./calc input | | +1 stderr: ./calc.at:1485: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1486: cat stderr input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1482: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) input: ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: cat stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1485: cat stderr | 1 + 2 * 3 + !- ++ ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1486: cat stderr stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1485: $PREPARSER ./calc /dev/null | (* *) + (*) + (*) ./calc.at:1489: $PREPARSER ./calc input ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of file Cleanup: discarding lookahead token end of file () stderr: ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 560. calc.at:1486: ok Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of file Cleanup: discarding lookahead token end of file () ./calc.at:1486: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | error ./calc.at:1486: $PREPARSER ./calc input ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: cat stderr ./calc.at:1485: cat stderr ./calc.at:1489: cat stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () input: input: stdout: | (#) + (#) = 2222 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1491: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh input: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1489: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stdout: 570. calc.at:1494: testing Calculator glr2.cc %no-lines %locations %header parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) input: ./calc.at:1494: mv calc.y.tmp calc.y ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1487: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1486: cat stderr ./calc.at:1494: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 input: ./calc.at:1487: $PREPARSER ./calc input ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: $PREPARSER ./calc input stderr: input: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1482: cat stderr ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () | 1 2 ./calc.at:1485: cat stderr ./calc.at:1491: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) | 1 2 Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () input: ./calc.at:1487: $PREPARSER ./calc input | (1 + #) = 1111 ./calc.at:1482: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1494: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS stderr: | (!!) + (1 2) = 1 ./calc.at:1485: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 120): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1489: cat stderr ./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 120): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: cat stderr input: ./calc.at:1491: cat stderr | (#) + (#) = 2222 input: ./calc.at:1489: $PREPARSER ./calc input | | +1 stderr: ./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: input: ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stdout: ./calc.at:1487: $PREPARSER ./calc input stderr: input: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1489: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () stderr: ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1491: $PREPARSER ./calc input input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1489: $PREPARSER ./calc input stderr: stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) stderr: ./calc.at:1482: cat stderr | (- *) + (1 2) = 1 ./calc.at:1485: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (# + 1) = 1111 ./calc.at:1482: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 119): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: input: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 119): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: cat stderr ./calc.at:1489: cat stderr | 1 2 stderr: ./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: ./calc.at:1491: cat stderr ./calc.at:1486: $PREPARSER ./calc /dev/null stderr: | error stderr: | (1 + #) = 1111 ./calc.at:1487: $PREPARSER ./calc input ./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token end of input () stderr: stderr: ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) Cleanup: discarding lookahead token invalid token () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1491: $PREPARSER ./calc input stderr: ./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token end of input () stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) Cleanup: discarding lookahead token invalid token () Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: cat stderr | (* *) + (*) + (*) ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1489: cat stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1487: cat stderr | (1 + # + 1) = 1111 ./calc.at:1482: $PREPARSER ./calc input input: stderr: ./calc.at:1486: cat stderr ./calc.at:1489: cat stderr stderr: | 1//2 ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 input: stderr: ./calc.at:1487: $PREPARSER ./calc input input: | (# + 1) = 1111 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: $PREPARSER ./calc input stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () | 1 = 2 = 3 ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !+ ++ stderr: ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) stderr: ./calc.at:1487: cat stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 121): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: cat stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: input: stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 121): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) | (1 + 1) / (1 - 1) | error ./calc.at:1489: $PREPARSER ./calc input | | +1 ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1487: $PREPARSER ./calc input ./calc.at:1486: cat stderr stderr: input: input: | (1 + # + 1) = 1111 stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1489: $PREPARSER ./calc input stderr: ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 122): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: | (!!) + (1 2) = 1 Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () ./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) Error: popping nterm input () Cleanup: discarding lookahead token '+' () stderr: input: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 122): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () | | +1 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1487: cat stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1482: cat stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1487: $PREPARSER ./calc /dev/null ./calc.at:1489: cat stderr ./calc.at:1485: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) Starting parse Entering state 0 Reading a token Now at end of input. syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) Cleanup: discarding lookahead token end of file () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: cat stderr 557. calc.at:1482: ok stderr: input: input: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Now at end of input. syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) Cleanup: discarding lookahead token end of file () | 1 = 2 = 3 | (#) + (#) = 2222 ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1489: $PREPARSER ./calc input stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: stdout: | (1 + 1) / (1 - 1) stderr: ./calc.at:1486: cat stderr ./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1492: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1491: cat stderr ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: input: | (- *) + (1 2) = 1 ./calc.at:1486: $PREPARSER ./calc input ./calc.at:1487: cat stderr ./calc.at:1491: $PREPARSER ./calc /dev/null | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: ./calc.at:1492: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: input: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1487: $PREPARSER ./calc input ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 571. calc.at:1504: testing Calculator lalr1.d ... stderr: stderr: stderr: ./calc.at:1504: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1485: cat stderr input: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 ./calc.at:1492: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: ./calc.at:1489: cat stderr ./calc.at:1489: cat stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 ./calc.at:1485: $PREPARSER ./calc input 571. calc.at:1504: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: skipped (calc.at:1504) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () 563. calc.at:1489: ok ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1486: cat stderr | | +1 ./calc.at:1489: $PREPARSER ./calc input ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1487: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 input: stderr: ./calc.at:1491: $PREPARSER ./calc input stderr: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () | (!!) + (1 2) = 1 ./calc.at:1487: $PREPARSER ./calc input stderr: ./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 120): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 120): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1492: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 572. calc.at:1509: testing Calculator D ... ./calc.at:1509: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y | 1//2 ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: $PREPARSER ./calc input ./calc.at:1485: cat stderr ./calc.at:1491: cat stderr stderr: ./calc.at:1487: cat stderr ./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 573. calc.at:1510: testing Calculator D %locations ... ./calc.at:1510: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y ./calc.at:1489: $PREPARSER ./calc /dev/null | (!!) + (1 2) = 1 ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: | (# + 1) = 1111 ./calc.at:1486: cat stderr ./calc.at:1485: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token end of input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: stderr: | (- *) + (1 2) = 1 ./calc.at:1487: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 572. calc.at:1509: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 119): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) skipped (calc.at:1509) stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 119): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 573. calc.at:1510: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token end of input () | 1 + 2 * 3 + !+ ++ ./calc.at:1486: $PREPARSER ./calc input skipped (calc.at:1510) stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1487: cat stderr ./calc.at:1492: cat stderr stderr: input: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1491: cat stderr input: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !- ++ | (* *) + (*) + (*) ./calc.at:1487: $PREPARSER ./calc input ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) input: ./calc.at:1485: cat stderr ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () | error stderr: ./calc.at:1492: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) input: input: | (- *) + (1 2) = 1 input: ./calc.at:1491: $PREPARSER ./calc input | (1 + # + 1) = 1111 ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1485: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1487: cat stderr stderr: ./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: stderr: 575. calc.at:1514: testing Calculator D %debug ... Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 574. calc.at:1512: testing Calculator D parse.error=detailed api.prefix={calc} %verbose ... Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1512: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y | 1 + 2 * 3 + !+ ++ ./calc.at:1487: $PREPARSER ./calc input ./calc.at:1514: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y stderr: stderr: ./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 121): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1485: cat stderr input: ./calc.at:1492: cat stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 121): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 574. calc.at:1512: | 1 = 2 = 3 ./calc.at:1492: $PREPARSER ./calc input input: | (#) + (#) = 2222 | 1 + 2 * 3 + !- ++ stderr: skipped (calc.at:1512) ./calc.at:1486: $PREPARSER ./calc input 575. calc.at:1514: ./calc.at:1487: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1491: cat stderr input: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr skipped (calc.at:1514) stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 122): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (1 + 1) / (1 - 1) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (* *) + (*) + (*) ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 122): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1491: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 106): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: cat stderr ./calc.at:1489: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | | +1 ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: | (!!) + (1 2) = 1 ./calc.at:1489: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 106): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1487: cat stderr ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 577. calc.at:1517: testing Calculator D %locations parse.error=custom ... ./calc.at:1491: cat stderr ./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: ./calc.at:1517: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y 576. calc.at:1516: testing Calculator D parse.error=custom ... ./calc.at:1516: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) input: input: | (#) + (#) = 2222 ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !+ ++ ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1487: $PREPARSER ./calc input stderr: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 ./calc.at:1486: $PREPARSER ./calc input ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: cat stderr ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1492: $PREPARSER ./calc /dev/null 576. calc.at:1516: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) input: | (- *) + (1 2) = 1 577. calc.at:1517: ./calc.at:1489: $PREPARSER ./calc input 559. calc.at:1485: ok stderr: skipped (calc.at:1517) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () skipped (calc.at:1516) ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1486: cat stderr input: | 1 + 2 * 3 + !- ++ ./calc.at:1491: $PREPARSER ./calc input stderr: ./calc.at:1487: cat stderr stderr: input: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) | (# + 1) = 1111 ./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: cat stderr stderr: input: | (1 + #) = 1111 ./calc.at:1487: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () 578. calc.at:1518: testing Calculator D %locations parse.error=detailed ... ./calc.at:1518: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) ./calc.at:1492: cat stderr ./calc.at:1489: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 578. calc.at:1518: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: cat stderr skipped (calc.at:1518) ./calc.at:1486: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1487: cat stderr 579. calc.at:1519: testing Calculator D %locations parse.error=simple ... input: ./calc.at:1519: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y | (1 + # + 1) = 1111 ./calc.at:1486: $PREPARSER ./calc input input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1492: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | (#) + (#) = 2222 ./calc.at:1491: $PREPARSER ./calc input | (# + 1) = 1111 stderr: 580. calc.at:1520: testing Calculator D parse.error=detailed %debug %verbose ... ./calc.at:1520: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1489: cat stderr ./calc.at:1487: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 581. calc.at:1521: testing Calculator D parse.error=detailed %debug api.symbol.prefix={SYMB_} api.token.prefix={TOK_} %verbose ... Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) input: | 1 + 2 * 3 + !- ++ ./calc.at:1489: $PREPARSER ./calc input ./calc.at:1521: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1486: cat stderr 579. calc.at:1519: skipped (calc.at:1519) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1487: cat stderr input: ./calc.at:1492: cat stderr input: | (1 + # + 1) = 1111 ./calc.at:1487: $PREPARSER ./calc input stderr: | (1 + 1) / (1 - 1) stderr: ./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) 581. calc.at:1521: 580. calc.at:1520: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1491: cat stderr stderr: skipped (calc.at:1521) skipped (calc.at:1520) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 ./calc.at:1492: $PREPARSER ./calc input stderr: input: | (1 + #) = 1111 ./calc.at:1491: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () 582. calc.at:1523: testing Calculator D %locations parse.lac=full parse.error=detailed ... ./calc.at:1523: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stderr: ./calc.at:1494: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1487: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stdout: ./calc.at:1491: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1489: cat stderr 582. calc.at:1523: stderr: input: skipped (calc.at:1523) ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1491: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 583. calc.at:1524: testing Calculator D %locations parse.lac=full parse.error=custom ... | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1486: cat stderr ./calc.at:1492: cat stderr ./calc.at:1524: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y ./calc.at:1494: $PREPARSER ./calc input input: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (14.1: ) Entering state 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: | (1 + 1) / (1 - 1) ./calc.at:1487: $PREPARSER ./calc input 561. calc.at:1486: ok Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (#) + (#) = 2222 ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1489: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () | (- *) + (1 2) = 1 ./calc.at:1492: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (14.1: ) Entering state 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 106): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 584. calc.at:1525: testing Calculator D %locations parse.lac=full parse.error=detailed parse.trace ... ./calc.at:1525: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y stderr: input: ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (stderr: 5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) | 1 2 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: 585. calc.at:1530: testing Calculator D api.token.constructor %locations parse.error=custom api.value.type=union ... Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 106): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1491: $PREPARSER ./calc input stderr: input: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token number (1.3: 2) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1530: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 stderr: ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token number (1.3: 2) stderr: 584. calc.at:1525: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 583. calc.at:1524: stderr: input: ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) skipped (calc.at:1525) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) skipped (calc.at:1524) | (# + 1) = 1111 ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: ./calc.at:1487: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) 586. calc.at:1531: testing Calculator D api.token.constructor %locations parse.error=detailed ... ./calc.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1//2 ./calc.at:1491: $PREPARSER ./calc input stderr: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 585. calc.at:1530: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) 562. calc.at:1487: ok ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) skipped (calc.at:1530) ./calc.at:1494: cat stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: cat stderr ./calc.at:1492: cat stderr stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 588. calc.at:1533: testing Calculator D parse.trace parse.error=custom %locations api.push-pull=both parse.lac=full ... ./calc.at:1533: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y input: input: 586. calc.at:1531: | (* *) + (*) + (*) Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1492: $PREPARSER ./calc input | 1//2 ./calc.at:1494: $PREPARSER ./calc input skipped (calc.at:1531) input: | (1 + #) = 1111 ./calc.at:1489: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 587. calc.at:1532: testing Calculator D api.push-pull=both ... ./calc.at:1532: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () 588. calc.at:1533: skipped (calc.at:1533) input: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 589. calc.at:1544: testing Calculator Java ... | (1 + # + 1) = 1111 ./calc.at:1491: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 590. calc.at:1545: testing Calculator Java parse.error=custom ... ./calc.at:1545: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y ./calc.at:1491: cat stderr ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1544: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1494: cat stderr 587. calc.at:1532: stderr: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | error ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1492: cat stderr skipped (calc.at:1532) 591. calc.at:1546: testing Calculator Java parse.error=detailed ... ./calc.at:1546: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) ./calc.at:1489: cat stderr ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 590. calc.at:1545: input: | error ./calc.at:1494: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1492: $PREPARSER ./calc input 589. calc.at:1544: skipped (calc.at:1545) stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) input: | (# + 1) = 1111 ./calc.at:1489: $PREPARSER ./calc input 591. calc.at:1546: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1491: cat stderr stderr: skipped (calc.at:1544) skipped (calc.at:1546) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) input: 592. calc.at:1547: testing Calculator Java parse.error=verbose ... ./calc.at:1547: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y stderr: ./calc.at:1491: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1491: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () input: 593. calc.at:1548: testing Calculator Java %locations parse.error=custom ... ./calc.at:1548: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 + !- ++ ./calc.at:1492: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: cat stderr stderr: stderr: 595. calc.at:1550: testing Calculator Java %locations parse.error=verbose ... ./calc.at:1550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 592. calc.at:1547: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 594. calc.at:1549: testing Calculator Java %locations parse.error=detailed ... 596. calc.at:1551: testing Calculator Java parse.trace parse.error=verbose ... ./calc.at:1551: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y ./calc.at:1549: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y ./calc.at:1489: cat stderr skipped (calc.at:1547) input: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | 1 = 2 = 3 ./calc.at:1494: $PREPARSER ./calc input 593. calc.at:1548: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) skipped (calc.at:1548) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + # + 1) = 1111 ./calc.at:1489: $PREPARSER ./calc input ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 596. calc.at:1551: 595. calc.at:1550: 594. calc.at:1549: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr skipped (calc.at:1549) skipped (calc.at:1551) ./calc.at:1492: cat stderr ./calc.at:1491: cat stderr stderr: skipped (calc.at:1550) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1491: cat stderr 565. calc.at:1491: ok 597. calc.at:1552: testing Calculator Java parse.trace parse.error=verbose %locations %lex-param {InputStream is} ... input: ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1552: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y | (#) + (#) = 2222 input: ./calc.at:1494: cat stderr ./calc.at:1492: $PREPARSER ./calc input stderr: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1491: $PREPARSER ./calc input 598. calc.at:1554: testing Calculator Java api.push-pull=both ... ./calc.at:1554: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) | | +1 ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 599. calc.at:1555: testing Calculator Java api.push-pull=both parse.error=detailed %locations ... ./calc.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y 602. calc.at:1560: testing Calculator Java parse.trace parse.error=custom %locations parse.lac=full ... Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) stderr: input: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1560: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) | (1 + 1) / (1 - 1) ./calc.at:1489: $PREPARSER ./calc input 597. calc.at:1552: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 601. calc.at:1557: testing Calculator Java parse.trace parse.error=verbose %locations %lex-param {InputStream is} api.push-pull=both ... 599. calc.at:1555: 600. calc.at:1556: testing Calculator Java parse.trace parse.error=custom %locations %lex-param {InputStream is} api.push-pull=both ... ./calc.at:1556: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y skipped (calc.at:1555) ./calc.at:1492: cat stderr ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1557: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y skipped (calc.at:1552) 598. calc.at:1554: stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 skipped (calc.at:1554) ./calc.at:1494: cat stderr ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () input: | (1 + #) = 1111 ./calc.at:1492: $PREPARSER ./calc input ./calc.at:1491: $PREPARSER ./calc /dev/null stderr: ./calc.at:1494: $PREPARSER ./calc /dev/null stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: 602. calc.at:1560: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) skipped (calc.at:1560) Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 600. calc.at:1556: stderr: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) skipped (calc.at:1556) 601. calc.at:1557: ./calc.at:1489: cat stderr stderr: stderr: skipped (calc.at:1557) Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 605. torture.at:216: testing Big horizontal ... ./torture.at:230: "$PERL" -w ./gengram.pl 1000 || exit 77 604. torture.at:132: testing Big triangle ... ./torture.at:138: "$PERL" -w ./gengram.pl 200 || exit 77 564. calc.at:1489: ok stderr: stdout: %code top { /* -*- c -*- */ /* Adjust to the compiler. We used to do it here, but each time we add a new line, we have to adjust all the line numbers in error messages. It's simpler to use a constant include to a varying file. */ #include } %define parse.error verbose %debug %{ #include #include #define MAX 1000 static int yylex (void); #include /* !POSIX */ static void yyerror (const char *msg); %} %token t1 1 "1" t2 2 "2" t3 3 "3" t4 4 "4" t5 5 "5" t6 6 "6" t7 7 "7" t8 8 "8" t9 9 "9" t10 10 "10" t11 11 "11" t12 12 "12" t13 13 "13" t14 14 "14" t15 15 "15" t16 16 "16" t17 17 "17" t18 18 "18" t19 19 "19" t20 20 "20" t21 21 "21" t22 22 "22" t23 23 "23" t24 24 "24" t25 25 "25" t26 26 "26" t27 27 "27" t28 28 "28" t29 29 "29" t30 30 "30" t31 31 "31" t32 32 "32" t33 33 "33" t34 34 "34" t35 35 "35" t36 36 "36" t37 37 "37" t38 38 "38" t39 39 "39" t40 40 "40" t41 41 "41" t42 42 "42" t43 43 "43" t44 44 "44" t45 45 "45" t46 46 "46" t47 47 "47" t48 48 "48" t49 49 "49" t50 50 "50" t51 51 "51" t52 52 "52" t53 53 "53" t54 54 "54" t55 55 "55" t56 56 "56" t57 57 "57" t58 58 "58" t59 59 "59" t60 60 "60" t61 61 "61" t62 62 "62" t63 63 "63" t64 64 "64" t65 65 "65" t66 66 "66" t67 67 "67" t68 68 "68" t69 69 "69" t70 70 "70" t71 71 "71" t72 72 "72" t73 73 "73" t74 74 "74" t75 75 "75" t76 76 "76" t77 77 "77" t78 78 "78" t79 79 "79" t80 80 "80" t81 81 "81" t82 82 "82" t83 83 "83" t84 84 "84" t85 85 "85" t86 86 "86" t87 87 "87" t88 88 "88" t89 89 "89" t90 90 "90" t91 91 "91" t92 92 "92" t93 93 "93" t94 94 "94" t95 95 "95" t96 96 "96" t97 97 "97" t98 98 "98" t99 99 "99" t100 100 "100" t101 101 "101" t102 102 "102" t103 103 "103" t104 104 "104" t105 105 "105" t106 106 "106" t107 107 "107" t108 108 "108" t109 109 "109" t110 110 "110" t111 111 "111" t112 112 "112" t113 113 "113" t114 114 "114" t115 115 "115" t116 116 "116" t117 117 "117" t118 118 "118" t119 119 "119" t120 120 "120" t121 121 "121" t122 122 "122" t123 123 "123" t124 124 "124" t125 125 "125" t126 126 "126" t127 127 "127" t128 128 "128" t129 129 "129" t130 130 "130" t131 131 "131" t132 132 "132" t133 133 "133" t134 134 "134" t135 135 "135" t136 136 "136" t137 137 "137" t138 138 "138" t139 139 "139" t140 140 "140" t141 141 "141" t142 142 "142" t143 143 "143" t144 144 "144" t145 145 "145" t146 146 "146" t147 147 "147" t148 148 "148" t149 149 "149" t150 150 "150" t151 151 "151" t152 152 "152" t153 153 "153" t154 154 "154" t155 155 "155" t156 156 "156" t157 157 "157" t158 158 "158" t159 159 "159" t160 160 "160" t161 161 "161" t162 162 "162" t163 163 "163" t164 164 "164" t165 165 "165" t166 166 "166" t167 167 "167" t168 168 "168" t169 169 "169" t170 170 "170" t171 171 "171" t172 172 "172" t173 173 "173" t174 174 "174" t175 175 "175" t176 176 "176" t177 177 "177" t178 178 "178" t179 179 "179" t180 180 "180" t181 181 "181" t182 182 "182" t183 183 "183" t184 184 "184" t185 185 "185" t186 186 "186" t187 187 "187" t188 188 "188" t189 189 "189" t190 190 "190" t191 191 "191" t192 192 "192" t193 193 "193" t194 194 "194" t195 195 "195" t196 196 "196" t197 197 "197" t198 198 "198" t199 199 "199" t200 200 "200" t201 201 "201" t202 202 "202" t203 203 "203" t204 204 "204" t205 205 "205" t206 206 "206" t207 207 "207" t208 208 "208" t209 209 "209" t210 210 "210" t211 211 "211" t212 212 "212" t213 213 "213" t214 214 "214" t215 215 "215" t216 216 "216" t217 217 "217" t218 218 "218" t219 219 "219" t220 220 "220" t221 221 "221" t222 222 "222" t223 223 "223" t224 224 "224" t225 225 "225" t226 226 "226" t227 227 "227" t228 228 "228" t229 229 "229" t230 230 "230" t231 231 "231" t232 232 "232" t233 233 "233" t234 234 "234" t235 235 "235" t236 236 "236" t237 237 "237" t238 238 "238" t239 239 "239" t240 240 "240" t241 241 "241" t242 242 "242" t243 243 "243" t244 244 "244" t245 245 "245" t246 246 "246" t247 247 "247" t248 248 "248" t249 249 "249" t250 250 "250" t251 251 "251" t252 252 "252" t253 253 "253" t254 254 "254" t255 255 "255" t256 256 "256" t257 257 "257" t258 258 "258" t259 259 "259" t260 260 "260" t261 261 "261" t262 262 "262" t263 263 "263" t264 264 "264" t265 265 "265" t266 266 "266" t267 267 "267" t268 268 "268" t269 269 "269" t270 270 "270" t271 271 "271" t272 272 "272" t273 273 "273" t274 274 "274" t275 275 "275" t276 276 "276" t277 277 "277" t278 278 "278" t279 279 "279" t280 280 "280" t281 281 "281" t282 282 "282" t283 283 "283" t284 284 "284" t285 285 "285" t286 286 "286" t287 287 "287" t288 288 "288" t289 289 "289" t290 290 "290" t291 291 "291" t292 292 "292" t293 293 "293" t294 294 "294" t295 295 "295" t296 296 "296" t297 297 "297" t298 298 "298" t299 299 "299" t300 300 "300" t301 301 "301" t302 302 "302" t303 303 "303" t304 304 "304" t305 305 "305" t306 306 "306" t307 307 "307" t308 308 "308" t309 309 "309" t310 310 "310" t311 311 "311" t312 312 "312" t313 313 "313" t314 314 "314" t315 315 "315" t316 316 "316" t317 317 "317" t318 318 "318" t319 319 "319" t320 320 "320" t321 321 "321" t322 322 "322" t323 323 "323" t324 324 "324" t325 325 "325" t326 326 "326" t327 327 "327" t328 328 "328" t329 329 "329" t330 330 "330" t331 331 "331" t332 332 "332" t333 333 "333" t334 334 "334" t335 335 "335" t336 336 "336" t337 337 "337" t338 338 "338" t339 339 "339" t340 340 "340" t341 341 "341" t342 342 "342" t343 343 "343" t344 344 "344" t345 345 "345" t346 346 "346" t347 347 "347" t348 348 "348" t349 349 "349" t350 350 "350" t351 351 "351" t352 352 "352" t353 353 "353" t354 354 "354" t355 355 "355" t356 356 "356" t357 357 "357" t358 358 "358" t359 359 "359" t360 360 "360" t361 361 "361" t362 362 "362" t363 363 "363" t364 364 "364" t365 365 "365" t366 366 "366" t367 367 "367" t368 368 "368" t369 369 "369" t370 370 "370" t371 371 "371" t372 372 "372" t373 373 "373" t374 374 "374" t375 375 "375" t376 376 "376" t377 377 "377" t378 378 "378" t379 379 "379" t380 380 "380" t381 381 "381" t382 382 "382" t383 383 "383" t384 384 "384" t385 385 "385" t386 386 "386" t387 387 "387" t388 388 "388" t389 389 "389" t390 390 "390" t391 391 "391" t392 392 "392" t393 393 "393" t394 394 "394" t395 395 "395" t396 396 "396" t397 397 "397" t398 398 "398" t399 399 "399" t400 400 "400" t401 401 "401" t402 402 "402" t403 403 "403" t404 404 "404" t405 405 "405" t406 406 "406" t407 407 "407" t408 408 "408" t409 409 "409" t410 410 "410" t411 411 "411" t412 412 "412" t413 413 "413" t414 414 "414" t415 415 "415" t416 416 "416" t417 417 "417" t418 418 "418" t419 419 "419" t420 420 "420" t421 421 "421" t422 422 "422" t423 423 "423" t424 424 "424" t425 425 "425" t426 426 "426" t427 427 "427" t428 428 "428" t429 429 "429" t430 430 "430" t431 431 "431" t432 432 "432" t433 433 "433" t434 434 "434" t435 435 "435" t436 436 "436" t437 437 "437" t438 438 "438" t439 439 "439" t440 440 "440" t441 441 "441" t442 442 "442" t443 443 "443" t444 444 "444" t445 445 "445" t446 446 "446" t447 447 "447" t448 448 "448" t449 449 "449" t450 450 "450" t451 451 "451" t452 452 "452" t453 453 "453" t454 454 "454" t455 455 "455" t456 456 "456" t457 457 "457" t458 458 "458" t459 459 "459" t460 460 "460" t461 461 "461" t462 462 "462" t463 463 "463" t464 464 "464" t465 465 "465" t466 466 "466" t467 467 "467" t468 468 "468" t469 469 "469" t470 470 "470" t471 471 "471" t472 472 "472" t473 473 "473" t474 474 "474" t475 475 "475" t476 476 "476" t477 477 "477" t478 478 "478" t479 479 "479" t480 480 "480" t481 481 "481" t482 482 "482" t483 483 "483" t484 484 "484" t485 485 "485" t486 486 "486" t487 487 "487" t488 488 "488" t489 489 "489" t490 490 "490" t491 491 "491" t492 492 "492" t493 493 "493" t494 494 "494" t495 495 "495" t496 496 "496" t497 497 "497" t498 498 "498" t499 499 "499" t500 500 "500" t501 501 "501" t502 502 "502" t503 503 "503" t504 504 "504" t505 505 "505" t506 506 "506" t507 507 "507" t508 508 "508" t509 509 "509" t510 510 "510" t511 511 "511" t512 512 "512" t513 513 "513" t514 514 "514" t515 515 "515" t516 516 "516" t517 517 "517" t518 518 "518" t519 519 "519" t520 520 "520" t521 521 "521" t522 522 "522" t523 523 "523" t524 524 "524" t525 525 "525" t526 526 "526" t527 527 "527" t528 528 "528" t529 529 "529" t530 530 "530" t531 531 "531" t532 532 "532" t533 533 "533" t534 534 "534" t535 535 "535" t536 536 "536" t537 537 "537" t538 538 "538" t539 539 "539" t540 540 "540" t541 541 "541" t542 542 "542" t543 543 "543" t544 544 "544" t545 545 "545" t546 546 "546" t547 547 "547" t548 548 "548" t549 549 "549" t550 550 "550" t551 551 "551" t552 552 "552" t553 553 "553" t554 554 "554" t555 555 "555" t556 556 "556" t557 557 "557" t558 558 "558" t559 559 "559" t560 560 "560" t561 561 "561" t562 562 "562" t563 563 "563" t564 564 "564" t565 565 "565" t566 566 "566" t567 567 "567" t568 568 "568" t569 569 "569" t570 570 "570" t571 571 "571" t572 572 "572" t573 573 "573" t574 574 "574" t575 575 "575" t576 576 "576" t577 577 "577" t578 578 "578" t579 579 "579" t580 580 "580" t581 581 "581" t582 582 "582" t583 583 "583" t584 584 "584" t585 585 "585" t586 586 "586" t587 587 "587" t588 588 "588" t589 589 "589" t590 590 "590" t591 591 "591" t592 592 "592" t593 593 "593" t594 594 "594" t595 595 "595" t596 596 "596" t597 597 "597" t598 598 "598" t599 599 "599" t600 600 "600" t601 601 "601" t602 602 "602" t603 603 "603" t604 604 "604" t605 605 "605" t606 606 "606" t607 607 "607" t608 608 "608" t609 609 "609" t610 610 "610" t611 611 "611" t612 612 "612" t613 613 "613" t614 614 "614" t615 615 "615" t616 616 "616" t617 617 "617" t618 618 "618" t619 619 "619" t620 620 "620" t621 621 "621" t622 622 "622" t623 623 "623" t624 624 "624" t625 625 "625" t626 626 "626" t627 627 "627" t628 628 "628" t629 629 "629" t630 630 "630" t631 631 "631" t632 632 "632" t633 633 "633" t634 634 "634" t635 635 "635" t636 636 "636" t637 637 "637" t638 638 "638" t639 639 "639" t640 640 "640" t641 641 "641" t642 642 "642" t643 643 "643" t644 644 "644" t645 645 "645" t646 646 "646" t647 647 "647" t648 648 "648" t649 649 "649" t650 650 "650" t651 651 "651" t652 652 "652" t653 653 "653" t654 654 "654" t655 655 "655" t656 656 "656" t657 657 "657" t658 658 "658" t659 659 "659" t660 660 "660" t661 661 "661" t662 662 "662" t663 663 "663" t664 664 "664" t665 665 "665" t666 666 "666" t667 667 "667" t668 668 "668" t669 669 "669" t670 670 "670" t671 671 "671" t672 672 "672" t673 673 "673" t674 674 "674" t675 675 "675" t676 676 "676" t677 677 "677" t678 678 "678" t679 679 "679" t680 680 "680" t681 681 "681" t682 682 "682" t683 683 "683" t684 684 "684" t685 685 "685" t686 686 "686" t687 687 "687" t688 688 "688" t689 689 "689" t690 690 "690" t691 691 "691" t692 692 "692" t693 693 "693" t694 694 "694" t695 695 "695" t696 696 "696" t697 697 "697" t698 698 "698" t699 699 "699" t700 700 "700" t701 701 "701" t702 702 "702" t703 703 "703" t704 704 "704" t705 705 "705" t706 706 "706" t707 707 "707" t708 708 "708" t709 709 "709" t710 710 "710" t711 711 "711" t712 712 "712" t713 713 "713" t714 714 "714" t715 715 "715" t716 716 "716" t717 717 "717" t718 718 "718" t719 719 "719" t720 720 "720" t721 721 "721" t722 722 "722" t723 723 "723" t724 724 "724" t725 725 "725" t726 726 "726" t727 727 "727" t728 728 "728" t729 729 "729" t730 730 "730" t731 731 "731" t732 732 "732" t733 733 "733" t734 734 "734" t735 735 "735" t736 736 "736" t737 737 "737" t738 738 "738" t739 739 "739" t740 740 "740" t741 741 "741" t742 742 "742" t743 743 "743" t744 744 "744" t745 745 "745" t746 746 "746" t747 747 "747" t748 748 "748" t749 749 "749" t750 750 "750" t751 751 "751" t752 752 "752" t753 753 "753" t754 754 "754" t755 755 "755" t756 756 "756" t757 757 "757" t758 758 "758" t759 759 "759" t760 760 "760" t761 761 "761" t762 762 "762" t763 763 "763" t764 764 "764" t765 765 "765" t766 766 "766" t767 767 "767" t768 768 "768" t769 769 "769" t770 770 "770" t771 771 "771" t772 772 "772" t773 773 "773" t774 774 "774" t775 775 "775" t776 776 "776" t777 777 "777" t778 778 "778" t779 779 "779" t780 780 "780" t781 781 "781" t782 782 "782" t783 783 "783" t784 784 "784" t785 785 "785" t786 786 "786" t787 787 "787" t788 788 "788" t789 789 "789" t790 790 "790" t791 791 "791" t792 792 "792" t793 793 "793" t794 794 "794" t795 795 "795" t796 796 "796" t797 797 "797" t798 798 "798" t799 799 "799" t800 800 "800" t801 801 "801" t802 802 "802" t803 803 "803" t804 804 "804" t805 805 "805" t806 806 "806" t807 807 "807" t808 808 "808" t809 809 "809" t810 810 "810" t811 811 "811" t812 812 "812" t813 813 "813" t814 814 "814" t815 815 "815" t816 816 "816" t817 817 "817" t818 818 "818" t819 819 "819" t820 820 "820" t821 821 "821" t822 822 "822" t823 823 "823" t824 824 "824" t825 825 "825" t826 826 "826" t827 827 "827" t828 828 "828" t829 829 "829" t830 830 "830" t831 831 "831" t832 832 "832" t833 833 "833" t834 834 "834" t835 835 "835" t836 836 "836" t837 837 "837" t838 838 "838" t839 839 "839" t840 840 "840" t841 841 "841" t842 842 "842" t843 843 "843" t844 844 "844" t845 845 "845" t846 846 "846" t847 847 "847" t848 848 "848" t849 849 "849" t850 850 "850" t851 851 "851" t852 852 "852" t853 853 "853" t854 854 "854" t855 855 "855" t856 856 "856" t857 857 "857" t858 858 "858" t859 859 "859" t860 860 "860" t861 861 "861" t862 862 "862" t863 863 "863" t864 864 "864" t865 865 "865" t866 866 "866" t867 867 "867" t868 868 "868" t869 869 "869" t870 870 "870" t871 871 "871" t872 872 "872" t873 873 "873" t874 874 "874" t875 875 "875" t876 876 "876" t877 877 "877" t878 878 "878" t879 879 "879" t880 880 "880" t881 881 "881" t882 882 "882" t883 883 "883" t884 884 "884" t885 885 "885" t886 886 "886" t887 887 "887" t888 888 "888" t889 889 "889" t890 890 "890" t891 891 "891" t892 892 "892" t893 893 "893" t894 894 "894" t895 895 "895" t896 896 "896" t897 897 "897" t898 898 "898" t899 899 "899" t900 900 "900" t901 901 "901" t902 902 "902" t903 903 "903" t904 904 "904" t905 905 "905" t906 906 "906" t907 907 "907" t908 908 "908" t909 909 "909" t910 910 "910" t911 911 "911" t912 912 "912" t913 913 "913" t914 914 "914" t915 915 "915" t916 916 "916" t917 917 "917" t918 918 "918" t919 919 "919" t920 920 "920" t921 921 "921" t922 922 "922" t923 923 "923" t924 924 "924" t925 925 "925" t926 926 "926" t927 927 "927" t928 928 "928" t929 929 "929" t930 930 "930" t931 931 "931" t932 932 "932" t933 933 "933" t934 934 "934" t935 935 "935" t936 936 "936" t937 937 "937" t938 938 "938" t939 939 "939" t940 940 "940" t941 941 "941" t942 942 "942" t943 943 "943" t944 944 "944" t945 945 "945" t946 946 "946" t947 947 "947" t948 948 "948" t949 949 "949" t950 950 "950" t951 951 "951" t952 952 "952" t953 953 "953" t954 954 "954" t955 955 "955" t956 956 "956" t957 957 "957" t958 958 "958" t959 959 "959" t960 960 "960" t961 961 "961" t962 962 "962" t963 963 "963" t964 964 "964" t965 965 "965" t966 966 "966" t967 967 "967" t968 968 "968" t969 969 "969" t970 970 "970" t971 971 "971" t972 972 "972" t973 973 "973" t974 974 "974" t975 975 "975" t976 976 "976" t977 977 "977" t978 978 "978" t979 979 "979" t980 980 "980" t981 981 "981" t982 982 "982" t983 983 "983" t984 984 "984" t985 985 "985" t986 986 "986" t987 987 "987" t988 988 "988" t989 989 "989" t990 990 "990" t991 991 "991" t992 992 "992" t993 993 "993" t994 994 "994" t995 995 "995" t996 996 "996" t997 997 "997" t998 998 "998" t999 999 "999" t1000 1000 "1000" %% exp: "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" "196" "197" "198" "199" "200" "201" "202" "203" "204" "205" "206" "207" "208" "209" "210" "211" "212" "213" "214" "215" "216" "217" "218" "219" "220" "221" "222" "223" "224" "225" "226" "227" "228" "229" "230" "231" "232" "233" "234" "235" "236" "237" "238" "239" "240" "241" "242" "243" "244" "245" "246" "247" "248" "249" "250" "251" "252" "253" "254" "255" "256" "257" "258" "259" "260" "261" "262" "263" "264" "265" "266" "267" "268" "269" "270" "271" "272" "273" "274" "275" "276" "277" "278" "279" "280" "281" "282" "283" "284" "285" "286" "287" "288" "289" "290" "291" "292" "293" "294" "295" "296" "297" "298" "299" "300" "301" "302" "303" "304" "305" "306" "307" "308" "309" "310" "311" "312" "313" "314" "315" "316" "317" "318" "319" "320" "321" "322" "323" "324" "325" "326" "327" "328" "329" "330" "331" "332" "333" "334" "335" "336" "337" "338" "339" "340" "341" "342" "343" "344" "345" "346" "347" "348" "349" "350" "351" "352" "353" "354" "355" "356" "357" "358" "359" "360" "361" "362" "363" "364" "365" "366" "367" "368" "369" "370" "371" "372" "373" "374" "375" "376" "377" "378" "379" "380" "381" "382" "383" "384" "385" "386" "387" "388" "389" "390" "391" "392" "393" "394" "395" "396" "397" "398" "399" "400" "401" "402" "403" "404" "405" "406" "407" "408" "409" "410" "411" "412" "413" "414" "415" "416" "417" "418" "419" "420" "421" "422" "423" "424" "425" "426" "427" "428" "429" "430" "431" "432" "433" "434" "435" "436" "437" "438" "439" "440" "441" "442" "443" "444" "445" "446" "447" "448" "449" "450" "451" "452" "453" "454" "455" "456" "457" "458" "459" "460" "461" "462" "463" "464" "465" "466" "467" "468" "469" "470" "471" "472" "473" "474" "475" "476" "477" "478" "479" "480" "481" "482" "483" "484" "485" "486" "487" "488" "489" "490" "491" "492" "493" "494" "495" "496" "497" "498" "499" "500" "501" "502" "503" "504" "505" "506" "507" "508" "509" "510" "511" "512" "513" "514" "515" "516" "517" "518" "519" "520" "521" "522" "523" "524" "525" "526" "527" "528" "529" "530" "531" "532" "533" "534" "535" "536" "537" "538" "539" "540" "541" "542" "543" "544" "545" "546" "547" "548" "549" "550" "551" "552" "553" "554" "555" "556" "557" "558" "559" "560" "561" "562" "563" "564" "565" "566" "567" "568" "569" "570" "571" "572" "573" "574" "575" "576" "577" "578" "579" "580" "581" "582" "583" "584" "585" "586" "587" "588" "589" "590" "591" "592" "593" "594" "595" "596" "597" "598" "599" "600" "601" "602" "603" "604" "605" "606" "607" "608" "609" "610" "611" "612" "613" "614" "615" "616" "617" "618" "619" "620" "621" "622" "623" "624" "625" "626" "627" "628" "629" "630" "631" "632" "633" "634" "635" "636" "637" "638" "639" "640" "641" "642" "643" "644" "645" "646" "647" "648" "649" "650" "651" "652" "653" "654" "655" "656" "657" "658" "659" "660" "661" "662" "663" "664" "665" "666" "667" "668" "669" "670" "671" "672" "673" "674" "675" "676" "677" "678" "679" "680" "681" "682" "683" "684" "685" "686" "687" "688" "689" "690" "691" "692" "693" "694" "695" "696" "697" "698" "699" "700" "701" "702" "703" "704" "705" "706" "707" "708" "709" "710" "711" "712" "713" "714" "715" "716" "717" "718" "719" "720" "721" "722" "723" "724" "725" "726" "727" "728" "729" "730" "731" "732" "733" "734" "735" "736" "737" "738" "739" "740" "741" "742" "743" "744" "745" "746" "747" "748" "749" "750" "751" "752" "753" "754" "755" "756" "757" "758" "759" "760" "761" "762" "763" "764" "765" "766" "767" "768" "769" "770" "771" "772" "773" "774" "775" "776" "777" "778" "779" "780" "781" "782" "783" "784" "785" "786" "787" "788" "789" "790" "791" "792" "793" "794" "795" "796" "797" "798" "799" "800" "801" "802" "803" "804" "805" "806" "807" "808" "809" "810" "811" "812" "813" "814" "815" "816" "817" "818" "819" "820" "821" "822" "823" "824" "825" "826" "827" "828" "829" "830" "831" "832" "833" "834" "835" "836" "837" "838" "839" "840" "841" "842" "843" "844" "845" "846" "847" "848" "849" "850" "851" "852" "853" "854" "855" "856" "857" "858" "859" "860" "861" "862" "863" "864" "865" "866" "867" "868" "869" "870" "871" "872" "873" "874" "875" "876" "877" "878" "879" "880" "881" "882" "883" "884" "885" "886" "887" "888" "889" "890" "891" "892" "893" "894" "895" "896" "897" "898" "899" "900" "901" "902" "903" "904" "905" "906" "907" "908" "909" "910" "911" "912" "913" "914" "915" "916" "917" "918" "919" "920" "921" "922" "923" "924" "925" "926" "927" "928" "929" "930" "931" "932" "933" "934" "935" "936" "937" "938" "939" "940" "941" "942" "943" "944" "945" "946" "947" "948" "949" "950" "951" "952" "953" "954" "955" "956" "957" "958" "959" "960" "961" "962" "963" "964" "965" "966" "967" "968" "969" "970" "971" "972" "973" "974" "975" "976" "977" "978" "979" "980" "981" "982" "983" "984" "985" "986" "987" "988" "989" "990" "991" "992" "993" "994" "995" "996" "997" "998" "999" "1000" ; %% #include /* A C error reporting function. */ /* !POSIX */ static void yyerror (const char *msg) { fprintf (stderr, "%s\n", msg); } static int yylex (void) { static int counter = 1; if (counter <= MAX) return counter++; assert (counter++ == MAX + 1); return 0; } #include /* getenv. */ #include /* strcmp. */ int main (int argc, char const* argv[]) { (void) argc; (void) argv; return yyparse (); } ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./torture.at:236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./calc.at:1492: cat stderr stdout: 603. calc.at:1561: testing Calculator Java parse.trace parse.error=custom %locations api.push-pull=both parse.lac=full ... ./calc.at:1561: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: cat stderr ./calc.at:1492: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh input: ./calc.at:1491: cat stderr | (# + 1) = 1111 ./calc.at:1492: $PREPARSER ./calc input input: input: stderr: 603. calc.at:1561: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1494: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1492: $PREPARSER ./calc input 608. torture.at:272: testing State number type: 256 states ... ./torture.at:272: ruby $abs_top_srcdir/tests/linear 256 >input.y || exit 77 skipped (calc.at:1561) stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1491: $PREPARSER ./calc input stderr: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 606. torture.at:270: testing State number type: 128 states ... ./torture.at:270: ruby $abs_top_srcdir/tests/linear 128 >input.y || exit 77 Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (14.1: ) Entering state 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 607. torture.at:271: testing State number type: 129 states ... ./torture.at:271: ruby $abs_top_srcdir/tests/linear 129 >input.y || exit 77 stderr: --- /dev/null 2026-03-27 17:47:36.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/608/stderr 2026-03-27 18:45:14.157669377 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/608/test-source: line 14: ruby: command not found ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 608. torture.at:272: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) --- /dev/null 2026-03-27 17:47:36.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/606/stderr 2026-03-27 18:45:14.173669377 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/606/test-source: line 14: ruby: command not found stderr: 606. torture.at:270: skipped (torture.at:270) --- /dev/null 2026-03-27 17:47:36.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/607/stderr 2026-03-27 18:45:14.181669377 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/607/test-source: line 14: ruby: command not found skipped (torture.at:272) 607. torture.at:271: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (14.1: ) Entering state 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) skipped (torture.at:271) ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stdout: | 1 2 ./calc.at:1492: $PREPARSER ./calc input %code top { /* -*- c -*- */ /* Adjust to the compiler. We used to do it here, but each time we add a new line, we have to adjust all the line numbers in error messages. It's simpler to use a constant include to a varying file. */ #include } %define parse.error verbose %debug %{ #include #include #include #define MAX 200 static int yylex (void); #include /* !POSIX */ static void yyerror (const char *msg); %} %union { int val; }; %token END "end" %type exp input %token t1 1 "1" %token t2 2 "2" %token t3 3 "3" %token t4 4 "4" %token t5 5 "5" %token t6 6 "6" %token t7 7 "7" %token t8 8 "8" %token t9 9 "9" %token t10 10 "10" %token t11 11 "11" %token t12 12 "12" %token t13 13 "13" %token t14 14 "14" %token t15 15 "15" %token t16 16 "16" %token t17 17 "17" %token t18 18 "18" %token t19 19 "19" %token t20 20 "20" %token t21 21 "21" %token t22 22 "22" %token t23 23 "23" %token t24 24 "24" %token t25 25 "25" %token t26 26 "26" %token t27 27 "27" %token t28 28 "28" %token t29 29 "29" %token t30 30 "30" %token t31 31 "31" %token t32 32 "32" %token t33 33 "33" %token t34 34 "34" %token t35 35 "35" %token t36 36 "36" %token t37 37 "37" %token t38 38 "38" %token t39 39 "39" %token t40 40 "40" %token t41 41 "41" %token t42 42 "42" %token t43 43 "43" %token t44 44 "44" %token t45 45 "45" %token t46 46 "46" %token t47 47 "47" %token t48 48 "48" %token t49 49 "49" %token t50 50 "50" %token t51 51 "51" %token t52 52 "52" %token t53 53 "53" %token t54 54 "54" %token t55 55 "55" %token t56 56 "56" %token t57 57 "57" %token t58 58 "58" %token t59 59 "59" %token t60 60 "60" %token t61 61 "61" %token t62 62 "62" %token t63 63 "63" %token t64 64 "64" %token t65 65 "65" %token t66 66 "66" %token t67 67 "67" %token t68 68 "68" %token t69 69 "69" %token t70 70 "70" %token t71 71 "71" %token t72 72 "72" %token t73 73 "73" %token t74 74 "74" %token t75 75 "75" %token t76 76 "76" %token t77 77 "77" %token t78 78 "78" %token t79 79 "79" %token t80 80 "80" %token t81 81 "81" %token t82 82 "82" %token t83 83 "83" %token t84 84 "84" %token t85 85 "85" %token t86 86 "86" %token t87 87 "87" %token t88 88 "88" %token t89 89 "89" %token t90 90 "90" %token t91 91 "91" %token t92 92 "92" %token t93 93 "93" %token t94 94 "94" %token t95 95 "95" %token t96 96 "96" %token t97 97 "97" %token t98 98 "98" %token t99 99 "99" %token t100 100 "100" %token t101 101 "101" %token t102 102 "102" %token t103 103 "103" %token t104 104 "104" %token t105 105 "105" %token t106 106 "106" %token t107 107 "107" %token t108 108 "108" %token t109 109 "109" %token t110 110 "110" %token t111 111 "111" %token t112 112 "112" %token t113 113 "113" %token t114 114 "114" %token t115 115 "115" %token t116 116 "116" %token t117 117 "117" %token t118 118 "118" %token t119 119 "119" %token t120 120 "120" %token t121 121 "121" %token t122 122 "122" %token t123 123 "123" %token t124 124 "124" %token t125 125 "125" %token t126 126 "126" %token t127 127 "127" %token t128 128 "128" %token t129 129 "129" %token t130 130 "130" %token t131 131 "131" %token t132 132 "132" %token t133 133 "133" %token t134 134 "134" %token t135 135 "135" %token t136 136 "136" %token t137 137 "137" %token t138 138 "138" %token t139 139 "139" %token t140 140 "140" %token t141 141 "141" %token t142 142 "142" %token t143 143 "143" %token t144 144 "144" %token t145 145 "145" %token t146 146 "146" %token t147 147 "147" %token t148 148 "148" %token t149 149 "149" %token t150 150 "150" %token t151 151 "151" %token t152 152 "152" %token t153 153 "153" %token t154 154 "154" %token t155 155 "155" %token t156 156 "156" %token t157 157 "157" %token t158 158 "158" %token t159 159 "159" %token t160 160 "160" %token t161 161 "161" %token t162 162 "162" %token t163 163 "163" %token t164 164 "164" %token t165 165 "165" %token t166 166 "166" %token t167 167 "167" %token t168 168 "168" %token t169 169 "169" %token t170 170 "170" %token t171 171 "171" %token t172 172 "172" %token t173 173 "173" %token t174 174 "174" %token t175 175 "175" %token t176 176 "176" %token t177 177 "177" %token t178 178 "178" %token t179 179 "179" %token t180 180 "180" %token t181 181 "181" %token t182 182 "182" %token t183 183 "183" %token t184 184 "184" %token t185 185 "185" %token t186 186 "186" %token t187 187 "187" %token t188 188 "188" %token t189 189 "189" %token t190 190 "190" %token t191 191 "191" %token t192 192 "192" %token t193 193 "193" %token t194 194 "194" %token t195 195 "195" %token t196 196 "196" %token t197 197 "197" %token t198 198 "198" %token t199 199 "199" %token t200 200 "200" %% input: exp { assert ($1 == 0); $$ = $1; } | input exp { assert ($2 == $1 + 1); $$ = $2; } ; exp: END { $$ = 0; } | "1" END { $$ = 1; } | "1" "2" END { $$ = 2; } | "1" "2" "3" END { $$ = 3; } | "1" "2" "3" "4" END { $$ = 4; } | "1" "2" "3" "4" "5" END { $$ = 5; } | "1" "2" "3" "4" "5" "6" END { $$ = 6; } | "1" "2" "3" "4" "5" "6" "7" END { $$ = 7; } | "1" "2" "3" "4" "5" "6" "7" "8" END { $$ = 8; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" END { $$ = 9; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" END { $$ = 10; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" END { $$ = 11; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" END { $$ = 12; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" END { $$ = 13; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" END { $$ = 14; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" END { $$ = 15; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" END { $$ = 16; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" END { $$ = 17; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" END { $$ = 18; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" END { $$ = 19; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" END { $$ = 20; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" END { $$ = 21; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" END { $$ = 22; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" END { $$ = 23; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" END { $$ = 24; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" END { $$ = 25; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" END { $$ = 26; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" END { $$ = 27; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" END { $$ = 28; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" END { $$ = 29; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" END { $$ = 30; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" END { $$ = 31; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" END { $$ = 32; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" END { $$ = 33; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" END { $$ = 34; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" END { $$ = 35; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" END { $$ = 36; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" END { $$ = 37; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" END { $$ = 38; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" END { $$ = 39; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" END { $$ = 40; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" END { $$ = 41; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" END { $$ = 42; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" END { $$ = 43; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" END { $$ = 44; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" END { $$ = 45; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" END { $$ = 46; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" END { $$ = 47; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" END { $$ = 48; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" END { $$ = 49; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" END { $$ = 50; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" END { $$ = 51; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" END { $$ = 52; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" END { $$ = 53; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" END { $$ = 54; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" END { $$ = 55; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" END { $$ = 56; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" END { $$ = 57; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" END { $$ = 58; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" END { $$ = 59; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" END { $$ = 60; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" END { $$ = 61; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" END { $$ = 62; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" END { $$ = 63; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" END { $$ = 64; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" END { $$ = 65; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" END { $$ = 66; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" END { $$ = 67; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" END { $$ = 68; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" END { $$ = 69; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" END { $$ = 70; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" END { $$ = 71; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" END { $$ = 72; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" END { $$ = 73; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" END { $$ = 74; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" END { $$ = 75; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" END { $$ = 76; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" END { $$ = 77; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" END { $$ = 78; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" END { $$ = 79; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" END { $$ = 80; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" END { $$ = 81; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" END { $$ = 82; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" END { $$ = 83; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" END { $$ = 84; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" END { $$ = 85; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" END { $$ = 86; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" END { $$ = 87; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" END { $$ = 88; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" END { $$ = 89; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" END { $$ = 90; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" END { $$ = 91; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" END { $$ = 92; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" END { $$ = 93; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" END { $$ = 94; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" END { $$ = 95; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" END { $$ = 96; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" END { $$ = 97; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" END { $$ = 98; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" END { $$ = 99; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" END { $$ = 100; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" END { $$ = 101; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" END { $$ = 102; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" END { $$ = 103; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" END { $$ = 104; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" END { $$ = 105; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" END { $$ = 106; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" END { $$ = 107; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" END { $$ = 108; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" END { $$ = 109; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" END { $$ = 110; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" END { $$ = 111; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" END { $$ = 112; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" END { $$ = 113; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" END { $$ = 114; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" END { $$ = 115; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" END { $$ = 116; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" END { $$ = 117; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" END { $$ = 118; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" END { $$ = 119; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" END { $$ = 120; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" END { $$ = 121; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" END { $$ = 122; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" END { $$ = 123; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" END { $$ = 124; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" END { $$ = 125; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" END { $$ = 126; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" END { $$ = 127; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" END { $$ = 128; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" END { $$ = 129; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" END { $$ = 130; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" END { $$ = 131; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" END { $$ = 132; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" END { $$ = 133; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" END { $$ = 134; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" END { $$ = 135; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" END { $$ = 136; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" END { $$ = 137; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" END { $$ = 138; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" END { $$ = 139; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" END { $$ = 140; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" END { $$ = 141; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" END { $$ = 142; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" END { $$ = 143; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" END { $$ = 144; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" END { $$ = 145; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" END { $$ = 146; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" END { $$ = 147; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" END { $$ = 148; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" END { $$ = 149; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" END { $$ = 150; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" END { $$ = 151; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" END { $$ = 152; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" END { $$ = 153; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" END { $$ = 154; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" END { $$ = 155; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" END { $$ = 156; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" END { $$ = 157; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" END { $$ = 158; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" END { $$ = 159; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" END { $$ = 160; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" END { $$ = 161; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" END { $$ = 162; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" END { $$ = 163; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" END { $$ = 164; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" END { $$ = 165; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" END { $$ = 166; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24"stderr: "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" END { $$ = 167; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" END { $$ = 168; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" END { $$ = 169; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" END { $$ = 170; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" END { $$ = 171; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" END { $$ = 172; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" END { $$ = 173; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" END { $$ = 174; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" END { $$ = 175; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" END { $$ = 176; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" END { $$ = 177; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" END { $$ = 178; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" END { $$ = 179; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" END { $$ = 180; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" END { $$ = 181; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" END { $$ = 182; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" END { $$ = 183; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" END { $$ = 184; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" END { $$ = 185; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" END { $$ = 186; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" END { $$ = 187; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" END { $$ = 188; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" END { $$ = 189; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" END { $$ = 190; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" END { $$ = 191; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" END { $$ = 192; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" END { $$ = 193; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" END { $$ = 194; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" END { $$ = 195; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" "196" END { $$ = 196; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" "196" "197" END { $$ = 197; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" "196" "197" "198" END { $$ = 198; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" "196" "197" "198" "199" END { $$ = 199; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" "196" "197" "198" "199" "200" END { $$ = 200; } ; %% /* A C error reporting function. */ /* !POSIX */ static void yyerror (const char *msg) { fprintf (stderr, "%s\n", msg); } static int yylex (void) { static int inner = 1; static int outer = 0; if (outer > MAX) return 0; else if (inner > outer) { inner = 1; ++outer; return END; } return inner++; } #include /* getenv. */ #include /* strcmp. */ int main (int argc, char const* argv[]) { (void) argc; (void) argv; return yyparse (); } ./calc.at:1492: cat stderr 609. torture.at:273: testing State number type: 257 states ... ./torture.at:273: ruby $abs_top_srcdir/tests/linear 257 >input.y || exit 77 ./torture.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token number (1.3: 2) ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 610. torture.at:274: testing State number type: 32768 states ... ./torture.at:274: ruby $abs_top_srcdir/tests/linear 32768 >input.y || exit 77 --- /dev/null 2026-03-27 17:47:36.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/610/stderr 2026-03-27 18:45:14.273669377 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/610/test-source: line 14: ruby: command not found | (1 + # + 1) = 1111 ./calc.at:1492: $PREPARSER ./calc input ./calc.at:1491: cat stderr --- /dev/null 2026-03-27 17:47:36.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/609/stderr 2026-03-27 18:45:14.265669377 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/609/test-source: line 14: ruby: command not found 610. torture.at:274: stderr: ./calc.at:1494: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 609. torture.at:273: 611. torture.at:275: testing State number type: 65536 states ... ./torture.at:275: ruby $abs_top_srcdir/tests/linear 65536 >input.y || exit 77 --- /dev/null 2026-03-27 17:47:36.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/611/stderr 2026-03-27 18:45:14.277669377 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/611/test-source: line 14: ruby: command not found skipped (torture.at:274) 611. torture.at:275: stderr: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr skipped (torture.at:273) skipped (torture.at:275) Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token number (1.3: 2) input: | (!!) + (1 2) = 1 input: ./calc.at:1491: $PREPARSER ./calc input | (!!) + (1 2) = 1 ./calc.at:1494: $PREPARSER ./calc input stderr: stderr: stderr: 613. torture.at:385: testing Many lookahead tokens ... ./torture.at:387: "$PERL" -w ./gengram.pl 1000 || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 612. torture.at:276: testing State number type: 65537 states ... ./torture.at:276: ruby $abs_top_srcdir/tests/linear 65537 >input.y || exit 77 --- /dev/null 2026-03-27 17:47:36.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/612/stderr 2026-03-27 18:45:14.329669377 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/612/test-source: line 14: ruby: command not found ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 612. torture.at:276: skipped (torture.at:276) ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: cat stderr %define parse.error verbose %debug %{ /* Adjust to the compiler. We used to do it here, but each time we add a new line, we have to adjust all the line numbers in error messages. It's simpler to use a constant include to a varying file. */ #include # include # include # include # define MAX 1000 static int yylex (void); #include /* !POSIX */ static void yyerror (const char *msg); %} %union { int val; }; %type input exp %token token %type n1 n2 n3 n4 n5 n6 n7 n8 n9 n10 n11 n12 n13 n14 n15 n16 n17 n18 n19 n20 n21 n22 n23 n24 n25 n26 n27 n28 n29 n30 n31 n32 n33 n34 n35 n36 n37 n38 n39 n40 n41 n42 n43 n44 n45 n46 n47 n48 n49 n50 n51 n52 n53 n54 n55 n56 n57 n58 n59 n60 n61 n62 n63 n64 n65 n66 n67 n68 n69 n70 n71 n72 n73 n74 n75 n76 n77 n78 n79 n80 n81 n82 n83 n84 n85 n86 n87 n88 n89 n90 n91 n92 n93 n94 n95 n96 n97 n98 n99 n100 n101 n102 n103 n104 n105 n106 n107 n108 n109 n110 n111 n112 n113 n114 n115 n116 n117 n118 n119 n120 n121 n122 n123 n124 n125 n126 n127 n128 n129 n130 n131 n132 n133 n134 n135 n136 n137 n138 n139 n140 n141 n142 n143 n144 n145 n146 n147 n148 n149 n150 n151 n152 n153 n154 n155 n156 n157 n158 n159 n160 n161 n162 n163 n164 n165 n166 n167 n168 n169 n170 n171 n172 n173 n174 n175 n176 n177 n178 n179 n180 n181 n182 n183 n184 n185 n186 n187 n188 n189 n190 n191 n192 n193 n194 n195 n196 n197 n198 n199 n200 n201 n202 n203 n204 n205 n206 n207 n208 n209 n210 n211 n212 n213 n214 n215 n216 n217 n218 n219 n220 n221 n222 n223 n224 n225 n226 n227 n228 n229 n230 n231 n232 n233 n234 n235 n236 n237 n238 n239 n240 n241 n242 n243 n244 n245 n246 n247 n248 n249 n250 n251 n252 n253 n254 n255 n256 n257 n258 n259 n260 n261 n262 n263 n264 n265 n266 n267 n268 n269 n270 n271 n272 n273 n274 n275 n276 n277 n278 n279 n280 n281 n282 n283 n284 n285 n286 n287 n288 n289 n290 n291 n292 n293 n294 n295 n296 n297 n298 n299 n300 n301 n302 n303 n304 n305 n306 n307 n308 n309 n310 n311 n312 n313 n314 n315 n316 n317 n318 n319 n320 n321 n322 n323 n324 n325 n326 n327 n328 n329 n330 n331 n332 n333 n334 n335 n336 n337 n338 n339 n340 n341 n342 n343 n344 n345 n346 n347 n348 n349 n350 n351 n352 n353 n354 n355 n356 n357 n358 n359 n360 n361 n362 n363 n364 n365 n366 n367 n368 n369 n370 n371 n372 n373 n374 n375 n376 n377 n378 n379 n380 n381 n382 n383 n384 n385 n386 n387 n388 n389 n390 n391 n392 n393 n394 n395 n396 n397 n398 n399 n400 n401 n402 n403 n404 n405 n406 n407 n408 n409 n410 n411 n412 n413 n414 n415 n416 n417 n418 n419 n420 n421 n422 n423 n424 n425 n426 n427 n428 n429 n430 n431 n432 n433 n434 n435 n436 n437 n438 n439 n440 n441 n442 n443 n444 n445 n446 n447 n448 n449 n450 n451 n452 n453 n454 n455 n456 n457 n458 n459 n460 n461 n462 n463 n464 n465 n466 n467 n468 n469 n470 n471 n472 n473 n474 n475 n476 n477 n478 n479 n480 n481 n482 n483 n484 n485 n486 n487 n488 n489 n490 n491 n492 n493 n494 n495 n496 n497 n498 n499 n500 n501 n502 n503 n504 n505 n506 n507 n508 n509 n510 n511 n512 n513 n514 n515 n516 n517 n518 n519 n520 n521 n522 n523 n524 n525 n526 n527 n528 n529 n530 n531 n532 n533 n534 n535 n536 n537 n538 n539 n540 n541 n542 n543 n544 n545 n546 n547 n548 n549 n550 n551 n552 n553 n554 n555 n556 n557 n558 n559 n560 n561 n562 n563 n564 n565 n566 n567 n568 n569 n570 n571 n572 n573 n574 n575 n576 n577 n578 n579 n580 n581 n582 n583 n584 n585 n586 n587 n588 n589 n590 n591 n592 n593 n594 n595 n596 n597 n598 n599 n600 n601 n602 n603 n604 n605 n606 n607 n608 n609 n610 n611 n612 n613 n614 n615 n616 n617 n618 n619 n620 n621 n622 n623 n624 n625 n626 n627 n628 n629 n630 n631 n632 n633 n634 n635 n636 n637 n638 n639 n640 n641 n642 n643 n644 n645 n646 n647 n648 n649 n650 n651 n652 n653 n654 n655 n656 n657 n658 n659 n660 n661 n662 n663 n664 n665 n666 n667 n668 n669 n670 n671 n672 n673 n674 n675 n676 n677 n678 n679 n680 n681 n682 n683 n684 n685 n686 n687 n688 n689 n690 n691 n692 n693 n694 n695 n696 n697 n698 n699 n700 n701 n702 n703 n704 n705 n706 n707 n708 n709 n710 n711 n712 n713 n714 n715 n716 n717 n718 n719 n720 n721 n722 n723 n724 n725 n726 n727 n728 n729 n730 n731 n732 n733 n734 n735 n736 n737 n738 n739 n740 n741 n742 n743 n744 n745 n746 n747 n748 n749 n750 n751 n752 n753 n754 n755 n756 n757 n758 n759 n760 n761 n762 n763 n764 n765 n766 n767 n768 n769 n770 n771 n772 n773 n774 n775 n776 n777 n778 n779 n780 n781 n782 n783 n784 n785 n786 n787 n788 n789 n790 n791 n792 n793 n794 n795 n796 n797 n798 n799 n800 n801 n802 n803 n804 n805 n806 n807 n808 n809 n810 n811 n812 n813 n814 n815 n816 n817 n818 n819 n820 n821 n822 n823 n824 n825 n826 n827 n828 n829 n830 n831 n832 n833 n834 n835 n836 n837 n838 n839 n840 n841 n842 n843 n844 n845 n846 n847 n848 n849 n850 n851 n852 n853 n854 n855 n856 n857 n858 n859 n860 n861 n862 n863 n864 n865 n866 n867 n868 n869 n870 n871 n872 n873 n874 n875 n876 n877 n878 n879 n880 n881 n882 n883 n884 n885 n886 n887 n888 n889 n890 n891 n892 n893 n894 n895 n896 n897 n898 n899 n900 n901 n902 n903 n904 n905 n906 n907 n908 n909 n910 n911 n912 n913 n914 n915 n916 n917 n918 n919 n920 n921 n922 n923 n924 n925 n926 n927 n928 n929 n930 n931 n932 n933 n934 n935 n936 n937 n938 n939 n940 n941 n942 n943 n944 n945 n946 n947 n948 n949 n950 n951 n952 n953 n954 n955 n956 n957 n958 n959 n960 n961 n962 n963 n964 n965 n966 n967 n968 n969 n970 n971 n972 n973 n974 n975 n976 n977 n978 n979 n980 n981 n982 n983 n984 n985 n986 n987 n988 n989 n990 n991 n992 n993 n994 n995 n996 n997 n998 n999 n1000 %token t1 1 "1" t2 2 "2" t3 3 "3" t4 4 "4" t5 5 "5" t6 6 "6" t7 7 "7" t8 8 "8" t9 9 "9" t10 10 "10" t11 11 "11" t12 12 "12" t13 13 "13" t14 14 "14" t15 15 "15" t16 16 "16" t17 17 "17" t18 18 "18" t19 19 "19" t20 20 "20" t21 21 "21" t22 22 "22" t23 23 "23" t24 24 "24" t25 25 "25" t26 26 "26" t27 27 "27" t28 28 "28" t29 29 "29" t30 30 "30" t31 31 "31" t32 32 "32" t33 33 "33" t34 34 "34" t35 35 "35" t36 36 "36" t37 37 "37" t38 38 "38" t39 39 "39" t40 40 "40" t41 41 "41" t42 42 "42" t43 43 "43" t44 44 "44" t45 45 "45" t46 46 "46" t47 47 "47" t48 48 "48" t49 49 "49" t50 50 "50" t51 51 "51" t52 52 "52" t53 53 "53" t54 54 "54" t55 55 "55" t56 56 "56" t57 57 "57" t58 58 "58" t59 59 "59" t60 60 "60" t61 61 "61" t62 62 "62" t63 63 "63" t64 64 "64" t65 65 "65" t66 66 "66" t67 67 "67" t68 68 "68" t69 69 "69" t70 70 "70" t71 71 "71" t72 72 "72" t73 73 "73" t74 74 "74" t75 75 "75" t76 76 "76" t77 77 "77" t78 78 "78" t79 79 "79" t80 80 "80" t81 81 "81" t82 82 "82" t83 83 "83" t84 84 "84" t85 85 "85" t86 86 "86" t87 87 "87" t88 88 "88" t89 89 "89" t90 90 "90" t91 91 "91" t92 92 "92" t93 93 "93" t94 94 "94" t95 95 "95" t96 96 "96" t97 97 "97" t98 98 "98" t99 99 "99" t100 100 "100" t101 101 "101" t102 102 "102" t103 103 "103" t104 104 "104" t105 105 "105" t106 106 "106" t107 107 "107" t108 108 "108" t109 109 "109" t110 110 "110" t111 111 "111" t112 112 "112" t113 113 "113" t114 114 "114" t115 115 "115" t116 116 "116" t117 117 "117" t118 118 "118" t119 119 "119" t120 120 "120" t121 121 "121" t122 122 "122" t123 123 "123" t124 124 "124" t125 125 "125" t126 126 "126" t127 127 "127" t128 128 "128" t129 129 "129" t130 130 "130" t131 131 "131" t132 132 "132" t133 133 "133" t134 134 "134" t135 135 "135" t136 136 "136" t137 137 "137" t138 138 "138" t139 139 "139" t140 140 "140" t141 141 "141" t142 142 "142" t143 143 "143" t144 144 "144" t145 145 "145" t146 146 "146" t147 147 "147" t148 148 "148" t149 149 "149" t150 150 "150" t151 151 "151" t152 152 "152" t153 153 "153" t154 154 "154" t155 155 "155" t156 156 "156" t157 157 "157" t158 158 "158" t159 159 "159" t160 160 "160" t161 161 "161" t162 162 "162" t163 163 "163" t164 164 "164" t165 165 "165" t166 166 "166" t167 167 "167" t168 168 "168" t169 169 "169" t170 170 "170" t171 171 "171" t172 172 "172" t173 173 "173" t174 174 "174" t175 175 "175" t176 176 "176" t177 177 "177" t178 178 "178" t179 179 "179" t180 180 "180" t181 181 "181" t182 182 "182" t183 183 "183" t184 184 "184" t185 185 "185" t186 186 "186" t187 187 "187" t188 188 "188" t189 189 "189" t190 190 "190" t191 191 "191" t192 192 "192" t193 193 "193" t194 194 "194" t195 195 "195" t196 196 "196" t197 197 "197" t198 198 "198" t199 199 "199" t200 200 "200" t201 201 "201" t202 202 "202" t203 203 "203" t204 204 "204" t205 205 "205" t206 206 "206" t207 207 "207" t208 208 "208" t209 209 "209" t210 210 "210" t211 211 "211" t212 212 "212" t213 213 "213" t214 214 "214" t215 215 "215" t216 216 "216" t217 217 "217" t218 218 "218" t219 219 "219" t220 220 "220" t221 221 "221" t222 222 "222" t223 223 "223" t224 224 "224" t225 225 "225" t226 226 "226" t227 227 "227" t228 228 "228" t229 229 "229" t230 230 "230" t231 231 "231" t232 232 "232" t233 233 "233" t234 234 "234" t235 235 "235" t236 236 "236" t237 237 "237" t238 238 "238" t239 239 "239" t240 240 "240" t241 241 "241" t242 242 "242" t243 243 "243" t244 244 "244" t245 245 "245" t246 246 "246" t247 247 "247" t248 248 "248" t249 249 "249" t250 250 "250" t251 251 "251" t252 252 "252" t253 253 "253" t254 254 "254" t255 255 "255" t256 256 "256" t257 257 "257" t258 258 "258" t259 259 "259" t260 260 "260" t261 261 "261" t262 262 "262" t263 263 "263" t264 264 "264" t265 265 "265" t266 266 "266" t267 267 "267" t268 268 "268" t269 269 "269" t270 270 "270" t271 271 "271" t272 272 "272" t273 273 "273" t274 274 "274" t275 275 "275" t276 276 "276" t277 277 "277" t278 278 "278" t279 279 "279" t280 280 "280" t281 281 "281" t282 282 "282" t283 283 "283" t284 284 "284" t285 285 "285" t286 286 "286" t287 287 "287" t288 288 "288" t289 289 "289" t290 290 "290" t291 291 "291" t292 292 "292" t293 293 "293" t294 294 "294" t295 295 "295" t296 296 "296" t297 297 "297" t298 298 "298" t299 299 "299" t300 300 "300" t301 301 "301" t302 302 "302" t303 303 "303" t304 304 "304" t305 305 "305" t306 306 "306" t307 307 "307" t308 308 "308" t309 309 "309" t310 310 "310" t311 311 "311" t312 312 "312" t313 313 "313" t314 314 "314" t315 315 "315" t316 316 "316" t317 317 "317" t318 318 "318" t319 319 "319" t320 320 "320" t321 321 "321" t322 322 "322" t323 323 "323" t324 324 "324" t325 325 "325" t326 326 "326" t327 327 "327" t328 328 "328" t329 329 "329" t330 330 "330" t331 331 "331" t332 332 "332" t333 333 "333" t334 334 "334" t335 335 "335" t336 336 "336" t337 337 "337" t338 338 "338" t339 339 "339" t340 340 "340" t341 341 "341" t342 342 "342" t343 343 "343" t344 344 "344" t345 345 "345" t346 346 "346" t347 347 "347" t348 348 "348" t349 349 "349" t350 350 "350" t351 351 "351" t352 352 "352" t353 353 "353" t354 354 "354" t355 355 "355" t356 356 "356" t357 357 "357" t358 358 "358" t359 359 "359" t360 360 "360" t361 361 "361" t362 362 "362" t363 363 "363" t364 364 "364" t365 365 "365" t366 366 "366" t367 367 "367" t368 368 "368" t369 369 "369" t370 370 "370" t371 371 "371" t372 372 "372" t373 373 "373" t374 374 "374" t375 375 "375" t376 376 "376" t377 377 "377" t378 378 "378" t379 379 "379" t380 380 "380" t381 381 "381" t382 382 "382" t383 383 "383" t384 384 "384" t385 385 "385" t386 386 "386" t387 387 "387" t388 388 "388" t389 389 "389" t390 390 "390" t391 391 "391" t392 392 "392" t393 393 "393" t394 394 "394" t395 395 "395" t396 396 "396" t397 397 "397" t398 398 "398" t399 399 "399" t400 400 "400" t401 401 "401" t402 402 "402" t403 403 "403" t404 404 "404" t405 405 "405" t406 406 "406" t407 407 "407" t408 408 "408" t409 409 "409" t410 410 "410" t411 411 "411" t412 412 "412" t413 413 "413" t414 414 "414" t415 415 "415" t416 416 "416" t417 417 "417" t418 418 "418" t419 419 "419" t420 420 "420" t421 421 "421" t422 422 "422" t423 423 "423" t424 424 "424" t425 425 "425" t426 426 "426" t427 427 "427" t428 428 "428" t429 429 "429" t430 430 "430" t431 431 "431" t432 432 "432" t433 433 "433" t434 434 "434" t435 435 "435" t436 436 "436" t437 437 "437" t438 438 "438" t439 439 "439" t440 440 "440" t441 441 "441" t442 442 "442" t443 443 "443" t444 444 "444" t445 445 "445" t446 446 "446" t447 447 "447" t448 448 "448" t449 449 "449" t450 450 "450" t451 451 "451" t452 452 "452" t453 453 "453" t454 454 "454" t455 455 "455" t456 456 "456" t457 457 "457" t458 458 "458" t459 459 "459" t460 460 "460" t461 461 "461" t462 462 "462" t463 463 "463" t464 464 "464" t465 465 "465" t466 466 "466" t467 467 "467" t468 468 "468" t469 469 "469" t470 470 "470" t471 471 "471" t472 472 "472" t473 473 "473" t474 474 "474" t475 475 "475" t476 476 "476" t477 477 "477" t478 478 "478" t479 479 "479" t480 480 "480" t481 481 "481" t482 482 "482" t483 483 "483" t484 484 "484" t485 485 "485" t486 486 "486" t487 487 "487" t488 488 "488" t489 489 "489" t490 490 "490" t491 491 "491" t492 492 "492" t493 493 "493" t494 494 "494" t495 495 "495" t496 496 "496" t497 497 "497" t498 498 "498" t499 499 "499" t500 500 "500" t501 501 "501" t502 502 "502" t503 503 "503" t504 504 "504" t505 505 "505" t506 506 "506" t507 507 "507" t508 508 "508" t509 509 "509" t510 510 "510" t511 511 "511" t512 512 "512" t513 513 "513" t514 514 "514" t515 515 "515" t516 516 "516" t517 517 "517" t518 518 "518" t519 519 "519" t520 520 "520" t521 521 "521" t522 522 "522" t523 523 "523" t524 524 "524" t525 525 "525" t526 526 "526" t527 527 "527" t528 528 "528" t529 529 "529" t530 530 "530" t531 531 "531" t532 532 "532" t533 533 "533" t534 534 "534" t535 535 "535" t536 536 "536" t537 537 "537" t538 538 "538" t539 539 "539" t540 540 "540" t541 541 "541" t542 542 "542" t543 543 "543" t544 544 "544" t545 545 "545" t546 546 "546" t547 547 "547" t548 548 "548" t549 549 "549" t550 550 "550" t551 551 "551" t552 552 "552" t553 553 "553" t554 554 "554" t555 555 "555" t556 556 "556" t557 557 "557" t558 558 "558" t559 559 "559" t560 560 "560" t561 561 "561" t562 562 "562" t563 563 "563" t564 564 "564" t565 565 "565" t566 566 "566" t567 567 "567" t568 568 "568" t569 569 "569" t570 570 "570" t571 571 "571" t572 572 "572" t573 573 "573" t574 574 "574" t575 575 "575" t576 576 "576" t577 577 "577" t578 578 "578" t579 579 "579" t580 580 "580" t581 581 "581" t582 582 "582" t583 583 "583" t584 584 "584" t585 585 "585" t586 586 "586" t587 587 "587" t588 588 "588" t589 589 "589" t590 590 "590" t591 591 "591" t592 592 "592" t593 593 "593" t594 594 "594" t595 595 "595" t596 596 "596" t597 597 "597" t598 598 "598" t599 599 "599" t600 600 "600" t601 601 "601" t602 602 "602" t603 603 "603" t604 604 "604" t605 605 "605" t606 606 "606" t607 607 "607" t608 608 "608" t609 609 "609" t610 610 "610" t611 611 "611" t612 612 "612" t613 613 "613" t614 614 "614" t615 615 "615" t616 616 "616" t617 617 "617" t618 618 "618" t619 619 "619" t620 620 "620" t621 621 "621" t622 622 "622" t623 623 "623" t624 624 "624" t625 625 "625" t626 626 "626" t627 627 "627" t628 628 "628" t629 629 "629" t630 630 "630" t631 631 "631" t632 632 "632" t633 633 "633" t634 634 "634" t635 635 "635" t636 636 "636" t637 637 "637" t638 638 "638" t639 639 "639" t640 640 "640" t641 641 "641" t642 642 "642" t643 643 "643" t644 644 "644" t645 645 "645" t646 646 "646" t647 647 "647" t648 648 "648" t649 649 "649" t650 650 "650" t651 651 "651" t652 652 "652" t653 653 "653" t654 654 "654" t655 655 "655" t656 656 "656" t657 657 "657" t658 658 "658" t659 659 "659" t660 660 "660" t661 661 "661" t662 662 "662" t663 663 "663" t664 664 "664" t665 665 "665" t666 666 "666" t667 667 "667" t668 668 "668" t669 669 "669" t670 670 "670" t671 671 "671" t672 672 "672" t673 673 "673" t674 674 "674" t675 675 "675" t676 676 "676" t677 677 "677" t678 678 "678" t679 679 "679" t680 680 "680" t681 681 "681" t682 682 "682" t683 683 "683" t684 684 "684" t685 685 "685" t686 686 "686" t687 687 "687" t688 688 "688" t689 689 "689" t690 690 "690" t691 691 "691" t692 692 "692" t693 693 "693" t694 694 "694" t695 695 "695" t696 696 "696" t697 697 "697" t698 698 "698" t699 699 "699" t700 700 "700" t701 701 "701" t702 702 "702" t703 703 "703" t704 704 "704" t705 705 "705" t706 706 "706" t707 707 "707" t708 708 "708" t709 709 "709" t710 710 "710" t711 711 "711" t712 712 "712" t713 713 "713" t714 714 "714" t715 715 "715" t716 716 "716" t717 717 "717" t718 718 "718" t719 719 "719" t720 720 "720" t721 721 "721" t722 722 "722" t723 723 "723" t724 724 "724" t725 725 "725" t726 726 "726" t727 727 "727" t728 728 "728" t729 729 "729" t730 730 "730" t731 731 "731" t732 732 "732" t733 733 "733" t734 734 "734" t735 735 "735" t736 736 "736" t737 737 "737" t738 738 "738" t739 739 "739" t740 740 "740" t741 741 "741" t742 742 "742" t743 743 "743" t744 744 "744" t745 745 "745" t746 746 "746" t747 747 "747" t748 748 "748" t749 749 "749" t750 750 "750" t751 751 "751" t752 752 "752" t753 753 "753" t754 754 "754" t755 755 "755" t756 756 "756" t757 757 "757" t758 758 "758" t759 759 "759" t760 760 "760" t761 761 "761" t762 762 "762" t763 763 "763" t764 764 "764" t765 765 "765" t766 766 "766" t767 767 "767" t768 768 "768" t769 769 "769" t770 770 "770" t771 771 "771" t772 772 "772" t773 773 "773" t774 774 "774" t775 775 "775" t776 776 "776" t777 777 "777" t778 778 "778" t779 779 "779" t780 780 "780" t781 781 "781" t782 782 "782" t783 783 "783" t784 784 "784" t785 785 "785" t786 786 "786" t787 787 "787" t788 788 "788" t789 789 "789" t790 790 "790" t791 791 "791" t792 792 "792" t793 793 "793" t794 794 "794" t795 795 "795" t796 796 "796" t797 797 "797" t798 798 "798" t799 799 "799" t800 800 "800" t801 801 "801" t802 802 "802" t803 803 "803" t804 804 "804" t805 805 "805" t806 806 "806" t807 807 "807" t808 808 "808" t809 809 "809" t810 810 "810" t811 811 "811" t812 812 "812" t813 813 "813" t814 814 "814" t815 815 "815" t816 816 "816" t817 817 "817" t818 818 "818" t819 819 "819" t820 820 "820" t821 821 "821" t822 822 "822" t823 823 "823" t824 824 "824" t825 825 "825" t826 826 "826" t827 827 "827" t828 828 "828" t829 829 "829" t830 830 "830" t831 831 "831" t832 832 "832" t833 833 "833" t834 834 "834" t835 835 "835" t836 836 "836" t837 837 "837" t838 838 "838" t839 839 "839" t840 840 "840" t841 841 "841" t842 842 "842" t843 843 "843" t844 844 "844" t845 845 "845" t846 846 "846" t847 847 "847" t848 848 "848" t849 849 "849" t850 850 "850" t851 851 "851" t852 852 "852" t853 853 "853" t854 854 "854" t855 855 "855" t856 856 "856" t857 857 "857" t858 858 "858" t859 859 "859" t860 860 "860" t861 861 "861" t862 862 "862" t863 863 "863" t864 864 "864" t865 865 "865" t866 866 "866" t867 867 "867" t868 868 "868" t869 869 "869" t870 870 "870" t871 871 "871" t872 872 "872" t873 873 "873" t874 874 "874" t875 875 "875" t876 876 "876" t877 877 "877" t878 878 "878" t879 879 "879" t880 880 "880" t881 881 "881" t882 882 "882" t883 883 "883" t884 884 "884" t885 885 "885" t886 886 "886" t887 887 "887" t888 888 "888" t889 889 "889" t890 890 "890" t891 891 "891" t892 892 "892" t893 893 "893" t894 894 "894" t895 895 "895" t896 896 "896" t897 897 "897" t898 898 "898" t899 899 "899" t900 900 "900" t901 901 "901" t902 902 "902" t903 903 "903" t904 904 "904" t905 905 "905" t906 906 "906" t907 907 "907" t908 908 "908" t909 909 "909" t910 910 "910" t911 911 "911" t912 912 "912" t913 913 "913" t914 914 "914" t915 915 "915" t916 916 "916" t917 917 "917" t918 918 "918" t919 919 "919" t920 920 "920" t921 921 "921" t922 922 "922" t923 923 "923" t924 924 "924" t925 925 "925" t926 926 "926" t927 927 "927" t928 928 "928" t929 929 "929" t930 930 "930" t931 931 "931" t932 932 "932" t933 933 "933" t934 934 "934" t935 935 "935" t936 936 "936" t937 937 "937" t938 938 "938" t939 939 "939" t940 940 "940" t941 941 "941" t942 942 "942" t943 943 "943" t944 944 "944" t945 945 "945" t946 946 "946" t947 947 "947" t948 948 "948" t949 949 "949" t950 950 "950" t951 951 "951" t952 952 "952" t953 953 "953" t954 954 "954" t955 955 "955" t956 956 "956" t957 957 "957" t958 958 "958" t959 959 "959" t960 960 "960" t961 961 "961" t962 962 "962" t963 963 "963" t964 964 "964" t965 965 "965" t966 966 "966" t967 967 "967" t968 968 "968" t969 969 "969" t970 970 "970" t971 971 "971" t972 972 "972" t973 973 "973" t974 974 "974" t975 975 "975" t976 976 "976" t977 977 "977" t978 978 "978" t979 979 "979" t980 980 "980" t981 981 "981" t982 982 "982" t983 983 "983" t984 984 "984" t985 985 "985" t986 986 "986" t987 987 "987" t988 988 "988" t989 989 "989" t990 990 "990" t991 991 "991" t992 992 "992" t993 993 "993" t994 994 "994" t995 995 "995" t996 996 "996" t997 997 "997" t998 998 "998" t999 999 "999" t1000 1000 "1000" %% input: exp { assert ($1 == 1); $$ = $1; } | input exp { assert ($2 == $1 + 1); $$ = $2; } ; exp: n1 "1" { assert ($1 == 1); $$ = $1; } | n2 "2" { assert ($1 == 2); $$ = $1; } | n3 "3" { assert ($1 == 3); $$ = $1; } | n4 "4" { assert ($1 == 4); $$ = $1; } | n5 "5" { assert ($1 == 5); $$ = $1; } | n6 "6" { assert ($1 == 6); $$ = $1; } | n7 "7" { assert ($1 == 7); $$ = $1; } | n8 "8" { assert ($1 == 8); $$ = $1; } | n9 "9" { assert ($1 == 9); $$ = $1; } | n10 "10" { assert ($1 == 10); $$ = $1; } | n11 "11" { assert ($1 == 11); $$ = $1; } | n12 "12" { assert ($1 == 12); $$ = $1; } | n13 "13" { assert ($1 == 13); $$ = $1; } | n14 "14" { assert ($1 == 14); $$ = $1; } | n15 "15" { assert ($1 == 15); $$ = $1; } | n16 "16" { assert ($1 == 16); $$ = $1; } | n17 "17" { assert ($1 == 17); $$ = $1; } | n18 "18" { assert ($1 == 18); $$ = $1; } | n19 "19" { assert ($1 == 19); $$ = $1; } | n20 "20" { assert ($1 == 20); $$ = $1; } | n21 "21" { assert ($1 == 21); $$ = $1; } | n22 "22" { assert ($1 == 22); $$ = $1; } | n23 "23" { assert ($1 == 23); $$ = $1; } | n24 "24" { assert ($1 == 24); $$ = $1; } | n25 "25" { assert ($1 == 25); $$ = $1; } | n26 "26" { assert ($1 == 26); $$ = $1; } | n27 "27" { assert ($1 == 27); $$ = $1; } | n28 "28" { assert ($1 == 28); $$ = $1; } | n29 "29" { assert ($1 == 29); $$ = $1; } | n30 "30" { assert ($1 == 30); $$ = $1; } | n31 "31" { assert ($1 == 31); $$ = $1; } | n32 "32" { assert ($1 == 32); $$ = $1; } | n33 "33" { assert ($1 == 33); $$ = $1; } | n34 "34" { assert ($1 == 34); $$ = $1; } | n35 "35" { assert ($1 == 35); $$ = $1; } | n36 "36" { assert ($1 == 36); $$ = $1; } | n37 "37" { assert ($1 == 37); $$ = $1; } | n38 "38" { assert ($1 == 38); $$ = $1; } | n39 "39" { assert ($1 == 39); $$ = $1; } | n40 "40" { assert ($1 == 40); $$ = $1; } | n41 "41" { assert ($1 == 41); $$ = $1; } | n42 "42" { assert ($1 == 42); $$ = $1; } | n43 "43" { assert ($1 == 43); $$ = $1; } | n44 "44" { assert ($1 == 44); $$ = $1; } | n45 "45" { assert ($1 == 45); $$ = $1; } | n46 "46" { assert ($1 == 46); $$ = $1; } | n47 "47" { assert ($1 == 47); $$ = $1; } | n48 "48" { assert ($1 == 48); $$ = $1; } | n49 "49" { assert ($1 == 49); $$ = $1; } | n50 "50" { assert ($1 == 50); $$ = $1; } | n51 "51" { assert ($1 == 51); $$ = $1; } | n52 "52" { assert ($1 == 52); $$ = $1; } | n53 "53" { assert ($1 == 53); $$ = $1; } | n54 "54" { assert ($1 == 54); $$ = $1; } | n55 "55" { assert ($1 == 55); $$ = $1; } | n56 "56" { assert ($1 == 56); $$ = $1; } | n57 "57" { assert ($1 == 57); $$ = $1; } | n58 "58" { assert ($1 == 58); $$ = $1; } | n59 "59" { assert ($1 == 59); $$ = $1; } | n60 "60" { assert ($1 == 60); $$ = $1; } | n61 "61" { assert ($1 == 61); $$ = $1; } | n62 "62" { assert ($1 == 62); $$ = $1; } | n63 "63" { assert ($1 == 63); $$ = $1; } | n64 "64" { assert ($1 == 64); $$ = $1; } | n65 "65" { assert ($1 == 65); $$ = $1; } | n66 "66" { assert ($1 == 66); $$ = $1; } | n67 "67" { assert ($1 == 67); $$ = $1; } | n68 "68" { assert ($1 == 68); $$ = $1; } | n69 "69" { assert ($1 == 69); $$ = $1; } | n70 "70" { assert ($1 == 70); $$ = $1; } | n71 "71" { assert ($1 == 71); $$ = $1; } | n72 "72" { assert ($1 == 72); $$ = $1; } | n73 "73" { assert ($1 == 73); $$ = $1; } | n74 "74" { assert ($1 == 74); $$ = $1; } | n75 "75" { assert ($1 == 75); $$ = $1; } | n76 "76" { assert ($1 == 76); $$ = $1; } | n77 "77" { assert ($1 == 77); $$ = $1; } | n78 "78" { assert ($1 == 78); $$ = $1; } | n79 "79" { assert ($1 == 79); $$ = $1; } | n80 "80" { assert ($1 == 80); $$ = $1; } | n81 "81" { assert ($1 == 81); $$ = $1; } | n82 "82" { assert ($1 == 82); $$ = $1; } | n83 "83" { assert ($1 == 83); $$ = $1; } | n84 "84" { assert ($1 == 84); $$ = $1; } | n85 "85" { assert ($1 == 85); $$ = $1; } | n86 "86" { assert ($1 == 86); $$ = $1; } | n87 "87" { assert ($1 == 87); $$ = $1; } | n88 "88" { assert ($1 == 88); $$ = $1; } | n89 "89" { assert ($1 == 89); $$ = $1; } | n90 "90" { assert ($1 == 90); $$ = $1; } | n91 "91" { assert ($1 == 91); $$ = $1; } | n92 "92" { assert ($1 == 92); $$ = $1; } | n93 "93" { assert ($1 == 93); $$ = $1; } | n94 "94" { assert ($1 == 94); $$ = $1; } | n95 "95" { assert ($1 == 95); $$ = $1; } | n96 "96" { assert ($1 == 96); $$ = $1; } | n97 "97" { assert ($1 == 97); $$ = $1; } | n98 "98" { assert ($1 == 98); $$ = $1; } | n99 "99" { assert ($1 == 99); $$ = $1; } | n100 "100" { assert ($1 == 100); $$ = $1; } | n101 "101" { assert ($1 == 101); $$ = $1; } | n102 "102" { assert ($1 == 102); $$ = $1; } | n103 "103" { assert ($1 == 103); $$ = $1; } | n104 "104" { assert ($1 == 104); $$ = $1; } | n105 "105" { assert ($1 == 105); $$ = $1; } | n106 "106" { assert ($1 == 106); $$ = $1; } | n107 "107" { assert ($1 == 107); $$ = $1; } | n108 "108" { assert ($1 == 108); $$ = $1; } | n109 "109" { assert ($1 == 109); $$ = $1; } | n110 "110" { assert ($1 == 110); $$ = $1; } | n111 "111" { assert ($1 == 111); $$ = $1; } | n112 "112" { assert ($1 == 112); $$ = $1; } | n113 "113" { assert ($1 == 113); $$ = $1; } | n114 "114" { assert ($1 == 114); $$ = $1; } | n115 "115" { assert ($1 == 115); $$ = $1; } | n116 "116" { assert ($1 == 116); $$ = $1; } | n117 "117" { assert ($1 == 117); $$ = $1; } | n118 "118" { assert ($1 == 118); $$ = $1; } | n119 "119" { assert ($1 == 119); $$ = $1; } | n120 "120" { assert ($1 == 120); $$ = $1; } | n121 "121" { assert ($1 == 121); $$ = $1; } | n122 "122" { assert ($1 == 122); $$ = $1; } | n123 "123" { assert ($1 == 123); $$ = $1; } | n124 "124" { assert ($1 == 124); $$ = $1; } | n125 "125" { assert ($1 == 125); $$ = $1; } | n126 "126" { assert ($1 == 126); $$ = $1; } | n127 "127" { assert ($1 == 127); $$ = $1; } | n128 "128" { assert ($1 == 128); $$ = $1; } | n129 "129" { assert ($1 == 129); $$ = $1; } | n130 "130" { assert ($1 == 130); $$ = $1; } | n131 "131" { assert ($1 == 131); $$ = $1; } | n132 "132" { assert ($1 == 132); $$ = $1; } | n133 "133" { assert ($1 == 133); $$ = $1; } | n134 "134" { assert ($1 == 134); $$ = $1; } | n135 "135" { assert ($1 == 135); $$ = $1; } | n136 "136" { assert ($1 == 136); $$ = $1; } | n137 "137" { assert ($1 == 137); $$ = $1; } | n138 "138" { assert ($1 == 138); $$ = $1; } | n139 "139" { assert ($1 == 139); $$ = $1; } | n140 "140" { assert ($1 == 140); $$ = $1; } | n141 "141" { assert ($1 == 141); $$ = $1; } | n142 "142" { assert ($1 == 142); $$ = $1; } | n143 "143" { assert ($1 == 143); $$ = $1; } | n144 "144" { assert ($1 == 144); $$ = $1; } | n145 "145" { assert ($1 == 145); $$ = $1; } | n146 "146" { assert ($1 == 146); $$ = $1; } | n147 "147" { assert ($1 == 147); $$ = $1; } | n148 "148" { assert ($1 == 148); $$ = $1; } | n149 "149" { assert ($1 == 149); $$ = $1; } | n150 "150" { assert ($1 == 150); $$ = $1; } | n151 "151" { assert ($1 == 151); $$ = $1; } | n152 "152" { assert ($1 == 152); $$ = $1; } | n153 "153" { assert ($1 == 153); $$ = $1; } | n154 "154" { assert ($1 == 154); $$ = $1; } | n155 "155" { assert ($1 == 155); $$ = $1; } | n156 "156" { assert ($1 == 156); $$ = $1; } | n157 "157" { assert ($1 == 157); $$ = $1; } | n158 "158" { assert ($1 == 158); $$ = $1; } | n159 "159" { assert ($1 == 159); $$ = $1; } | n160 "160" { assert ($1 == 160); $$ = $1; } | n161 "161" { assert ($1 == 161); $$ = $1; } | n162 "162" { assert ($1 == 162); $$ = $1; } | n163 "163" { assert ($1 == 163); $$ = $1; } | n164 "164" { assert ($1 == 164); $$ = $1; } | n165 "165" { assert ($1 == 165); $$ = $1; } | n166 "166" { assert ($1 == 166); $$ = $1; } | n167 "167" { assert ($1 == 167); $$ = $1; } | n168 "168" { assert ($1 == 168); $$ = $1; } | n169 "169" { assert ($1 == 169); $$ = $1; } | n170 "170" { assert ($1 == 170); $$ = $1; } | n171 "171" { assert ($1 == 171); $$ = $1; } | n172 "172" { assert ($1 == 172); $$ = $1; } | n173 "173" { assert ($1 == 173); $$ = $1; } | n174 "174" { assert ($1 == 174); $$ = $1; } | n175 "175" { assert ($1 == 175); $$ = $1; } | n176 "176" { assert ($1 == 176); $$ = $1; } | n177 "177" { assert ($1 == 177); $$ = $1; } | n178 "178" { assert ($1 == 178); $$ = $1; } | n179 "179" { assert ($1 == 179); $$ = $1; } | n180 "180" { assert ($1 == 180); $$ = $1; } | n181 "181" { assert ($1 == 181); $$ = $1; } | n182 "182" { assert ($1 == 182); $$ = $1; } | n183 "183" { assert ($1 == 183); $$ = $1; } | n184 "184" { assert ($1 == 184); $$ = $1; } | n185 "185" { assert ($1 == 185); $$ = $1; } | n186 "186" { assert ($1 == 186); $$ = $1; } | n187 "187" { assert ($1 == 187); $$ = $1; } | n188 "188" { assert ($1 == 188); $$ = $1; } | n189 "189" { assert ($1 == 189); $$ = $1; } | n190 "190" { assert ($1 == 190); $$ = $1; } | n191 "191" { assert ($1 == 191); $$ = $1; } | n192 "192" { assert ($1 == 192); $$ = $1; } | n193 "193" { assert ($1 == 193); $$ = $1; } | n194 "194" { assert ($1 == 194); $$ = $1; } | n195 "195" { assert ($1 == 195); $$ = $1; } | n196 "196" { assert ($1 == 196); $$ = $1; } | n197 "197" { assert ($1 == 197); $$ = $1; } | n198 "198" { assert ($1 == 198); $$ = $1; } | n199 "199" { assert ($1 == 199); $$ = $1; } | n200 "200" { assert ($1 == 200); $$ = $1; } | n201 "201" { assert ($1 == 201); $$ = $1; } | n202 "202" { assert ($1 == 202); $$ = $1; } | n203 "203" { assert ($1 == 203); $$ = $1; } | n204 "204" { assert ($1 == 204); $$ = $1; } | n205 "205" { assert ($1 == 205); $$ = $1; } | n206 "206" { assert ($1 == 206); $$ = $1; } | n207 "207" { assert ($1 == 207); $$ = $1; } | n208 "208" { assert ($1 == 208); $$ = $1; } | n209 "209" { assert ($1 == 209); $$ = $1; } | n210 "210" { assert ($1 == 210); $$ = $1; } | n211 "211" { assert ($1 == 211); $$ = $1; } | n212 "212" { assert ($1 == 212); $$ = $1; } | n213 "213" { assert ($1 == 213); $$ = $1; } | n214 "214" { assert ($1 == 214); $$ = $1; } | n215 "215" { assert ($1 == 215); $$ = $1; } | n216 "216" { assert ($1 == 216); $$ = $1; } | n217 "217" { assert ($1 == 217); $$ = $1; } | n218 "218" { assert ($1 == 218); $$ = $1; } | n219 "219" { assert ($1 == 219); $$ = $1; } | n220 "220" { assert ($1 == 220); $$ = $1; } | n221 "221" { assert ($1 == 221); $$ = $1; } | n222 "222" { assert ($1 == 222); $$ = $1; } | n223 "223" { assert ($1 == 223); $$ = $1; } | n224 "224" { assert ($1 == 224); $$ = $1; } | n225 "225" { assert ($1 == 225); $$ = $1; } | n226 "226" { assert ($1 == 226); $$ = $1; } | n227 "227" { assert ($1 == 227); $$ = $1; } | n228 "228" { assert ($1 == 228); $$ = $1; } | n229 "229" { assert ($1 == 229); $$ = $1; } | n230 "230" { assert ($1 == 230); $$ = $1; } | n231 "231" { assert ($1 == 231); $$ = $1; } | n232 "232" { assert ($1 == 232); $$ = $1; } | n233 "233" { assert ($1 == 233); $$ = $1; } | n234 "234" { assert ($1 == 234); $$ = $1; } | n235 "235" { assert ($1 == 235); $$ = $1; } | n236 "236" { assert ($1 == 236); $$ = $1; } | n237 "237" { assert ($1 == 237); $$ = $1; } | n238 "238" { assert ($1 == 238); $$ = $1; } | n239 "239" { assert ($1 == 239); $$ = $1; } | n240 "240" { assert ($1 == 240); $$ = $1; } | n241 "241" { assert ($1 == 241); $$ = $1; } | n242 "242" { assert ($1 == 242); $$ = $1; } | n243 "243" { assert ($1 == 243); $$ = $1; } | n244 "244" { assert ($1 == 244); $$ = $1; } | n245 "245" { assert ($1 == 245); $$ = $1; } | n246 "246" { assert ($1 == 246); $$ = $1; } | n247 "247" { assert ($1 == 247); $$ = $1; } | n248 "248" { assert ($1 == 248); $$ = $1; } | n249 "249" { assert ($1 == 249); $$ = $1; } | n250 "250" { assert ($1 == 250); $$ = $1; } | n251 "251" { assert ($1 == 251); $$ = $1; } | n252 "252" { assert ($1 == 252); $$ = $1; } | n253 "253" { assert ($1 == 253); $$ = $1; } | n254 "254" { assert ($1 == 254); $$ = $1; } | n255 "255" { assert ($1 == 255); $$ = $1; } | n256 "256" { assert ($1 == 256); $$ = $1; } | n257 "257" { assert ($1 == 257); $$ = $1; } | n258 "258" { assert ($1 == 258); $$ = $1; } | n259 "259" { assert ($1 == 259); $$ = $1; } | n260 "260" { assert ($1 == 260); $$ = $1; } | n261 "261" { assert ($1 == 261); $$ = $1; } | n262 "262" { assert ($1 == 262); $$ = $1; } | n263 "263" { assert ($1 == 263); $$ = $1; } | n264 "264" { assert ($1 == 264); $$ = $1; } | n265 "265" { assert ($1 == 265); $$ = $1; } | n266 "266" { assert ($1 == 266); $$ = $1; } | n267 "267" { assert ($1 == 267); $$ = $1; } | n268 "268" { assert ($1 == 268); $$ = $1; } | n269 "269" { assert ($1 == 269); $$ = $1; } | n270 "270" { assert ($1 == 270); $$ = $1; } | n271 "271" { assert ($1 == 271); $$ = $1; } | n272 "272" { assert ($1 == 272); $$ = $1; } | n273 "273" { assert ($1 == 273); $$ = $1; } | n274 "274" { assert ($1 == 274); $$ = $1; } | n275 "275" { assert ($1 == 275); $$ = $1; } | n276 "276" { assert ($1 == 276); $$ = $1; } | n277 "277" { assert ($1 == 277); $$ = $1; } | n278 "278" { assert ($1 == 278); $$ = $1; } | n279 "279" { assert ($1 == 279); $$ = $1; } | n280 "280" { assert ($1 == 280); $$ = $1; } | n281 "281" { assert ($1 == 281); $$ = $1; } | n282 "282" { assert ($1 == 282); $$ = $1; } | n283 "283" { assert ($1 == 283); $$ = $1; } | n284 "284" { assert ($1 == 284); $$ = $1; } | n285 "285" { assert ($1 == 285); $$ = $1; } | n286 "286" { assert ($1 == 286); $$ = $1; } | n287 "287" { assert ($1 == 287); $$ = $1; } | n288 "288" { assert ($1 == 288); $$ = $1; } | n289 "289" { assert ($1 == 289); $$ = $1; } | n290 "290" { assert ($1 == 290); $$ = $1; } | n291 "291" { assert ($1 == 291); $$ = $1; } | n292 "292" { assert ($1 == 292); $$ = $1; } | n293 "293" { assert ($1 == 293); $$ = $1; } | n294 "294" { assert ($1 == 294); $$ = $1; } | n295 "295" { assert ($1 == 295); $$ = $1; } | n296 "296" { assert ($1 == 296); $$ = $1; } | n297 "297" { assert ($1 == 297); $$ = $1; } | n298 "298" { assert ($1 == 298); $$ = $1; } | n299 "299" { assert ($1 == 299); $$ = $1; } | n300 "300" { assert ($1 == 300); $$ = $1; } | n301 "301" { assert ($1 == 301); $$ = $1; } | n302 "302" { assert ($1 == 302); $$ = $1; } | n303 "303" { assert ($1 == 303); $$ = $1; } | n304 "304" { assert ($1 == 304); $$ = $1; } | n305 "305" { assert ($1 == 305); $$ = $1; } | n306 "306" { assert ($1 == 306); $$ = $1; } | n307 "307" { assert ($1 == 307); $$ = $1; } | n308 "308" { assert ($1 == 308); $$ = $1; } | n309 "309" { assert ($1 == 309); $$ = $1; } | n310 "310" { assert ($1 == 310); $$ = $1; } | n311 "311" { assert ($1 == 311); $$ = $1; } | n312 "312" { assert ($1 == 312); $$ = $1; } | n313 "313" { assert ($1 == 313); $$ = $1; } | n314 "314" { assert ($1 == 314); $$ = $1; } | n315 "315" { assert ($1 == 315); $$ = $1; } | n316 "316" { assert ($1 == 316); $$ = $1; } | n317 "317" { assert ($1 == 317); $$ = $1; } | n318 "318" { assert ($1 == 318); $$ = $1; } | n319 "319" { assert ($1 == 319); $$ = $1; } | n320 "320" { assert ($1 == 320); $$ = $1; } | n321 "321" { assert ($1 == 321); $$ = $1; } | n322 "322" { assert ($1 == 322); $$ = $1; } | n323 "323" { assert ($1 == 323); $$ = $1; } | n324 "324" { assert ($1 == 324); $$ = $1; } | n325 "325" { assert ($1 == 325); $$ = $1; } | n326 "326" { assert ($1 == 326); $$ = $1; } | n327 "327" { assert ($1 == 327); $$ = $1; } | n328 "328" { assert ($1 == 328); $$ = $1; } | n329 "329" { assert ($1 == 329); $$ = $1; } | n330 "330" { assert ($1 == 330); $$ = $1; } | n331 "331" { assert ($1 == 331); $$ = $1; } | n332 "332" { assert ($1 == 332); $$ = $1; } | n333 "333" { assert ($1 == 333); $$ = $1; } | n334 "334" { assert ($1 == 334); $$ = $1; } | n335 "335" { assert ($1 == 335); $$ = $1; } | n336 "336" { assert ($1 == 336); $$ = $1; } | n337 "337" { assert ($1 == 337); $$ = $1; } | n338 "338" { assert ($1 == 338); $$ = $1; } | n339 "339" { assert ($1 == 339); $$ = $1; } | n340 "340" { assert ($1 == 340); $$ = $1; } | n341 "341" { assert ($1 == 341); $$ = $1; } | n342 "342" { assert ($1 == 342); $$ = $1; } | n343 "343" { assert ($1 == 343); $$ = $1; } | n344 "344" { assert ($1 == 344); $$ = $1; } | n345 "345" { assert ($1 == 345); $$ = $1; } | n346 "346" { assert ($1 == 346); $$ = $1; } | n347 "347" { assert ($1 == 347); $$ = $1; } | n348 "348" { assert ($1 == 348); $$ = $1; } | n349 "349" { assert ($1 == 349); $$ = $1; } | n350 "350" { assert ($1 == 350); $$ = $1; } | n351 "351" { assert ($1 == 351); $$ = $1; } | n352 "352" { assert ($1 == 352); $$ = $1; } | n353 "353" { assert ($1 == 353); $$ = $1; } | n354 "354" { assert ($1 == 354); $$ = $1; } | n355 "355" { assert ($1 == 355); $$ = $1; } | n356 "356" { assert ($1 == 356); $$ = $1; } | n357 "357" { assert ($1 == 357); $$ = $1; } | n358 "358" { assert ($1 == 358); $$ = $1; } | n359 "359" { assert ($1 == 359); $$ = $1; } | n360 "360" { assert ($1 == 360); $$ = $1; } | n361 "361" { assert ($1 == 361); $$ = $1; } | n362 "362" { assert ($1 == 362); $$ = $1; } | n363 "363" { assert ($1 == 363); $$ = $1; } | n364 "364" { assert ($1 == 364); $$ = $1; } | n365 "365" { assert ($1 == 365); $$ = $1; } | n366 "366" { assert ($1 == 366); $$ = $1; } | n367 "367" { assert ($1 == 367); $$ = $1; } | n368 "368" { assert ($1 == 368); $$ = $1; } | n369 "369" { assert ($1 == 369); $$ = $1; } | n370 "370" { assert ($1 == 370); $$ = $1; } | n371 "371" { assert ($1 == 371); $$ = $1; } | n372 "372" { assert ($1 == 372); $$ = $1; } | n373 "373" { assert ($1 == 373); $$ = $1; } | n374 "374" { assert ($1 == 374); $$ = $1; } | n375 "375" { assert ($1 == 375); $$ = $1; } | n376 "376" { assert ($1 == 376); $$ = $1; } | n377 "377" { assert ($1 == 377); $$ = $1; } | n378 "378" { assert ($1 == 378); $$ = $1; } | n379 "379" { assert ($1 == 379); $$ = $1; } | n380 "380" { assert ($1 == 380); $$ = $1; } | n381 "381" { assert ($1 == 381); $$ = $1; } | n382 "382" { assert ($1 == 382); $$ = $1; } | n383 "383" { assert ($1 == 383); $$ = $1; } | n384 "384" { assert ($1 == 384); $$ = $1; } | n385 "385" { assert ($1 == 385); $$ = $1; } | n386 "386" { assert ($1 == 386); $$ = $1; } | n387 "387" { assert ($1 == 387); $$ = $1; } | n388 "388" { assert ($1 == 388); $$ = $1; } | n389 "389" { assert ($1 == 389); $$ = $1; } | n390 "390" { assert ($1 == 390); $$ = $1; } | n391 "391" { assert ($1 == 391); $$ = $1; } | n392 "392" { assert ($1 == 392); $$ = $1; } | n393 "393" { assert ($1 == 393); $$ = $1; } | n394 "394" { assert ($1 == 394); $$ = $1; } | n395 "395" { assert ($1 == 395); $$ = $1; } | n396 "396" { assert ($1 == 396); $$ = $1; } | n397 "397" { assert ($1 == 397); $$ = $1; } | n398 "398" { assert ($1 == 398); $$ = $1; } | n399 "399" { assert ($1 == 399); $$ = $1; } | n400 "400" { assert ($1 == 400); $$ = $1; } | n401 "401" { assert ($1 == 401); $$ = $1; } | n402 "402" { assert ($1 == 402); $$ = $1; } | n403 "403" { assert ($1 == 403); $$ = $1; } | n404 "404" { assert ($1 == 404); $$ = $1; } | n405 "405" { assert ($1 == 405); $$ = $1; } | n406 "406" { assert ($1 == 406); $$ = $1; } | n407 "407" { assert ($1 == 407); $$ = $1; } | n408 "408" { assert ($1 == 408); $$ = $1; } | n409 "409" { assert ($1 == 409); $$ = $1; } | n410 "410" { assert ($1 == 410); $$ = $1; } | n411 "411" { assert ($1 == 411); $$ = $1; } | n412 "412" { assert ($1 == 412); $$ = $1; } | n413 "413" { assert ($1 == 413); $$ = $1; } | n414 "414" { assert ($1 == 414); $$ = $1; } | n415 "415" { assert ($1 == 415); $$ = $1; } | n416 "416" { assert ($1 == 416); $$ = $1; } | n417 "417" { assert ($1 == 417); $$ = $1; } | n418 "418" { assert ($1 == 418); $$ = $1; } | n419 "419" { assert ($1 == 419); $$ = $1; } | n420 "420" { assert ($1 == 420); $$ = $1; } | n421 "421" { assert ($1 == 421); $$ = $1; } | n422 "422" { assert ($1 == 422); $$ = $1; } | n423 "423" { assert ($1 == 423); $$ = $1; } | n424 "424" { assert ($1 == 424); $$ = $1; } | n425 "425" { assert ($1 == 425); $$ = $1; } | n426 "426" { assert ($1 == 426); $$ = $1; } | n427 "427" { assert ($1 == 427); $$ = $1; } | n428 "428" { assert ($1 == 428); $$ = $1; } | n429 "429" { assert ($1 == 429); $$ = $1; } | n430 "430" { assert ($1 == 430); $$ = $1; } | n431 "431" { assert ($1 == 431); $$ = $1; } | n432 "432" { assert ($1 == 432); $$ = $1; } | n433 "433" { assert ($1 == 433); $$ = $1; } | n434 "434" { assert ($1 == 434); $$ = $1; } | n435 "435" { assert ($1 == 435); $$ = $1; } | n436 "436" { assert ($1 == 436); $$ = $1; } | n437 "437" { assert ($1 == 437); $$ = $1; } | n438 "438" { assert ($1 == 438); $$ = $1; } | n439 "439" { assert ($1 == 439); $$ = $1; } | n440 "440" { assert ($1 == 440); $$ = $1; } | n441 "441" { assert ($1 == 441); $$ = $1; } | n442 "442" { assert ($1 == 442); $$ = $1; } | n443 "443" { assert ($1 == 443); $$ = $1; } | n444 "444" { assert ($1 == 444); $$ = $1; } | n445 "445" { assert ($1 == 445); $$ = $1; } | n446 "446" { assert ($1 == 446); $$ = $1; } | n447 "447" { assert ($1 == 447); $$ = $1; } | n448 "448" { assert ($1 == 448); $$ = $1; } | n449 "449" { assert ($1 == 449); $$ = $1; } | n450 "450" { assert ($1 == 450); $$ = $1; } | n451 "451" { assert ($1 == 451); $$ = $1; } | n452 "452" { assert ($1 == 452); $$ = $1; } | n453 "453" { assert ($1 == 453); $$ = $1; } | n454 "454" { assert ($1 == 454); $$ = $1; } | n455 "455" { assert ($1 == 455); $$ = $1; } | n456 "456" { assert ($1 == 456); $$ = $1; } | n457 "457" { assert ($1 == 457); $$ = $1; } | n458 "458" { assert ($1 == 458); $$ = $1; } | n459 "459" { assert ($1 == 459); $$ = $1; } | n460 "460" { assert ($1 == 460); $$ = $1; } | n461 "461" { assert ($1 == 461); $$ = $1; } | n462 "462" { assert ($1 == 462); $$ = $1; } | n463 "463" { assert ($1 == 463); $$ = $1; } | n464 "464" { assert ($1 == 464); $$ = $1; } | n465 "465" { assert ($1 == 465); $$ = $1; } | n466 "466" { assert ($1 == 466); $$ = $1; } | n467 "467" { assert ($1 == 467); $$ = $1; } | n468 "468" { assert ($1 == 468); $$ = $1; } | n469 "469" { assert ($1 == 469); $$ = $1; } | n470 "470" { assert ($1 == 470); $$ = $1; } | n471 "471" { assert ($1 == 471); $$ = $1; } | n472 "472" { assert ($1 == 472); $$ = $1; } | n473 "473" { assert ($1 == 473); $$ = $1; } | n474 "474" { assert ($1 == 474); $$ = $1; } | n475 "475" { assert ($1 == 475); $$ = $1; } | n476 "476" { assert ($1 == 476); $$ = $1; } | n477 "477" { assert ($1 == 477); $$ = $1; } | n478 "478" { assert ($1 == 478); $$ = $1; } | n479 "479" { assert ($1 == 479); $$ = $1; } | n480 "480" { assert ($1 == 480); $$ = $1; } | n481 "481" { assert ($1 == 481); $$ = $1; } | n482 "482" { assert ($1 == 482); $$ = $1; } | n483 "483" { assert ($1 == 483); $$ = $1; } | n484 "484" { assert ($1 == 484); $$ = $1; } | n485 "485" { assert ($1 == 485); $$ = $1; } | n486 "486" { assert ($1 == 486); $$ = $1; } | n487 "487" { assert ($1 == 487); $$ = $1; } | n488 "488" { assert ($1 == 488); $$ = $1; } | n489 "489" { assert ($1 == 489); $$ = $1; } | n490 "490" { assert ($1 == 490); $$ = $1; } | n491 "491" { assert ($1 == 491); $$ = $1; } | n492 "492" { assert ($1 == 492); $$ = $1; } | n493 "493" { assert ($1 == 493); $$ = $1; } | n494 "494" { assert ($1 == 494); $$ = $1; } | n495 "495" { assert ($1 == 495); $$ = $1; } | n496 "496" { assert ($1 == 496); $$ = $1; } | n497 "497" { assert ($1 == 497); $$ = $1; } | n498 "498" { assert ($1 == 498); $$ = $1; } | n499 "499" { assert ($1 == 499); $$ = $1; } | n500 "500" { assert ($1 == 500); $$ = $1; } | n501 "501" { assert ($1 == 501); $$ = $1; } | n502 "502" { assert ($1 == 502); $$ = $1; } | n503 "503" { assert ($1 == 503); $$ = $1; } | n504 "504" { assert ($1 == 504); $$ = $1; } | n505 "505" { assert ($1 == 505); $$ = $1; } | n506 "506" { assert ($1 == 506); $$ = $1; } | n507 "507" { assert ($1 == 507); $$ = $1; } | n508 "508" { assert ($1 == 508); $$ = $1; } | n509 "509" { assert ($1 == 509); $$ = $1; } | n510 "510" { assert ($1 == 510); $$ = $1; } | n511 "511" { assert ($1 == 511); $$ = $1; } | n512 "512" { assert ($1 == 512); $$ = $1; } | n513 "513" { assert ($1 == 513); $$ = $1; } | n514 "514" { assert ($1 == 514); $$ = $1; } | n515 "515" { assert ($1 == 515); $$ = $1; } | n516 "516" { assert ($1 == 516); $$ = $1; } | n517 "517" { assert ($1 == 517); $$ = $1; } | n518 "518" { assert ($1 == 518); $$ = $1; } | n519 "519" { assert ($1 == 519); $$ = $1; } | n520 "520" { assert ($1 == 520); $$ = $1; } | n521 "521" { assert ($1 == 521); $$ = $1; } | n522 "522" { assert ($1 == 522); $$ = $1; } | n523 "523" { assert ($1 == 523); $$ = $1; } | n524 "524" { assert ($1 == 524); $$ = $1; } | n525 "525" { assert ($1 == 525); $$ = $1; } | n526 "526" { assert ($1 == 526); $$ = $1; } | n527 "527" { assert ($1 == 527); $$ = $1; } | n528 "528" { assert ($1 == 528); $$ = $1; } | n529 "529" { assert ($1 == 529); $$ = $1; } | n530 "530" { assert ($1 == 530); $$ = $1; } | n531 "531" { assert ($1 == 531); $$ = $1; } | n532 "532" { assert ($1 == 532); $$ = $1; } | n533 "533" { assert ($1 == 533); $$ = $1; } | n534 "534" { assert ($1 == 534); $$ = $1; } | n535 "535" { assert ($1 == 535); $$ = $1; } | n536 "536" { assert ($1 == 536); $$ = $1; } | n537 "537" { assert ($1 == 537); $$ = $1; } | n538 "538" { assert ($1 == 538); $$ = $1; } | n539 "539" { assert ($1 == 539); $$ = $1; } | n540 "540" { assert ($1 == 540); $$ = $1; } | n541 "541" { assert ($1 == 541); $$ = $1; } | n542 "542" { assert ($1 == 542); $$ = $1; } | n543 "543" { assert ($1 == 543); $$ = $1; } | n544 "544" { assert ($1 == 544); $$ = $1; } | n545 "545" { assert ($1 == 545); $$ = $1; } | n546 "546" { assert ($1 == 546); $$ = $1; } | n547 "547" { assert ($1 == 547); $$ = $1; } | n548 "548" { assert ($1 == 548); $$ = $1; } | n549 "549" { assert ($1 == 549); $$ = $1; } | n550 "550" { assert ($1 == 550); $$ = $1; } | n551 "551" { assert ($1 == 551); $$ = $1; } | n552 "552" { assert ($1 == 552); $$ = $1; } | n553 "553" { assert ($1 == 553); $$ = $1; } | n554 "554" { assert ($1 == 554); $$ = $1; } | n555 "555" { assert ($1 == 555); $$ = $1; } | n556 "556" { assert ($1 == 556); $$ = $1; } | n557 "557" { assert ($1 == 557); $$ = $1; } | n558 "558" { assert ($1 == 558); $$ = $1; } | n559 "559" { assert ($1 == 559); $$ = $1; } | n560 "560" { assert ($1 == 560); $$ = $1; } | n561 "561" { assert ($1 == 561); $$ = $1; } | n562 "562" { assert ($1 == 562); $$ = $1; } | n563 "563" { assert ($1 == 563); $$ = $1; } | n564 "564" { assert ($1 == 564); $$ = $1; } | n565 "565" { assert ($1 == 565); $$ = $1; } | n566 "566" { assert ($1 == 566); $$ = $1; } | n567 "567" { assert ($1 == 567); $$ = $1; } | n568 "568" { assert ($1 == 568); $$ = $1; } | n569 "569" { assert ($1 == 569); $$ = $1; } | n570 "570" { assert ($1 == 570); $$ = $1; } | n571 "571" { assert ($1 == 571); $$ = $1; } | n572 "572" { assert ($1 == 572); $$ = $1; } | n573 "573" { assert ($1 == 573); $$ = $1; } | n574 "574" { assert ($1 == 574); $$ = $1; } | n575 "575" { assert ($1 == 575); $$ = $1; } | n576 "576" { assert ($1 == 576); $$ = $1; } | n577 "577" { assert ($1 == 577); $$ = $1; } | n578 "578" { assert ($1 == 578); $$ = $1; } | n579 "579" { assert ($1 == 579); $$ = $1; } | n580 "580" { assert ($1 == 580); $$ = $1; } | n581 "581" { assert ($1 == 581); $$ = $1; } | n582 "582" { assert ($1 == 582); $$ = $1; } | n583 "583" { assert ($1 == 583); $$ = $1; } | n584 "584" { assert ($1 == 584); $$ = $1; } | n585 "585" { assert ($1 == 585); $$ = $1; } | n586 "586" { assert ($1 == 586); $$ = $1; } | n587 "587" { assert ($1 == 587); $$ = $1; } | n588 "588" { assert ($1 == 588); $$ = $1; } | n589 "589" { assert ($1 == 589); $$ = $1; } | n590 "590" { assert ($1 == 590); $$ = $1; } | n591 "591" { assert ($1 == 591); $$ = $1; } | n592 "592" { assert ($1 == 592); $$ = $1; } | n593 "593" { assert ($1 == 593); $$ = $1; } | n594 "594" { assert ($1 == 594); $$ = $1; } | n595 "595" { assert ($1 == 595); $$ = $1; } | n596 "596" { assert ($1 == 596); $$ = $1; } | n597 "597" { assert ($1 == 597); $$ = $1; } | n598 "598" { assert ($1 == 598); $$ = $1; } | n599 "599" { assert ($1 == 599); $$ = $1; } | n600 "600" { assert ($1 == 600); $$ = $1; } | n601 "601" { assert ($1 == 601); $$ = $1; } | n602 "602" { assert ($1 == 602); $$ = $1; } | n603 "603" { assert ($1 == 603); $$ = $1; } | n604 "604" { assert ($1 == 604); $$ = $1; } | n605 "605" { assert ($1 == 605); $$ = $1; } | n606 "606" { assert ($1 == 606); $$ = $1; } | n607 "607" { assert ($1 == 607); $$ = $1; } | n608 "608" { assert ($1 == 608); $$ = $1; } | n609 "609" { assert ($1 == 609); $$ = $1; } | n610 "610" { assert ($1 == 610); $$ = $1; } | n611 "611" { assert ($1 == 611); $$ = $1; } | n612 "612" { assert ($1 == 612); $$ = $1; } | n613 "613" { assert ($1 == 613); $$ = $1; } | n614 "614" { assert ($1 == 614); $$ = $1; } | n615 "615" { assert ($1 == 615); $$ = $1; } | n616 "616" { assert ($1 == 616); $$ = $1; } | n617 "617" { assert ($1 == 617); $$ = $1; } | n618 "618" { assert ($1 == 618); $$ = $1; } | n619 "619" { assert ($1 == 619); $$ = $1; } | n620 "620" { assert ($1 == 620); $$ = $1; } | n621 "621" { assert ($1 == 621); $$ = $1; } | n622 "622" { assert ($1 == 622); $$ = $1; } | n623 "623" { assert ($1 == 623); $$ = $1; } | n624 "624" { assert ($1 == 624); $$ = $1; } | n625 "625" { assert ($1 == 625); $$ = $1; } | n626 "626" { assert ($1 == 626); $$ = $1; } | n627 "627" { assert ($1 == 627); $$ = $1; } | n628 "628" { assert ($1 == 628); $$ = $1; } | n629 "629" { assert ($1 == 629); $$ = $1; } | n630 "630" { assert ($1 == 630); $$ = $1; } | n631 "631" { assert ($1 == 631); $$ = $1; } | n632 "632" { assert ($1 == 632); $$ = $1; } | n633 "633" { assert ($1 == 633); $$ = $1; } | n634 "634" { assert ($1 == 634); $$ = $1; } | n635 "635" { assert ($1 == 635); $$ = $1; } | n636 "636" { assert ($1 == 636); $$ = $1; } | n637 "637" { assert ($1 == 637); $$ = $1; } | n638 "638" { assert ($1 == 638); $$ = $1; } | n639 "639" { assert ($1 == 639); $$ = $1; } | n640 "640" { assert ($1 == 640); $$ = $1; } | n641 "641" { assert ($1 == 641); $$ = $1; } | n642 "642" { assert ($1 == 642); $$ = $1; } | n643 "643" { assert ($1 == 643); $$ = $1; } | n644 "644" { assert ($1 == 644); $$ = $1; } | n645 "645" { assert ($1 == 645); $$ = $1; } | n646 "646" { assert ($1 == 646); $$ = $1; } | n647 "647" { assert ($1 == 647); $$ = $1; } | n648 "648" { assert ($1 == 648); $$ = $1; } | n649 "649" { assert ($1 == 649); $$ = $1; } | n650 "650" { assert ($1 == 650); $$ = $1; } | n651 "651" { assert ($1 == 651); $$ = $1; } | n652 "652" { assert ($1 == 652); $$ = $1; } | n653 "653" { assert ($1 == 653); $$ = $1; } | n654 "654" { assert ($1 == 654); $$ = $1; } | n655 "655" { assert ($1 == 655); $$ = $1; } | n656 "656" { assert ($1 == 656); $$ = $1; } | n657 "657" { assert ($1 == 657); $$ = $1; } | n658 "658" { assert ($1 == 658); $$ = $1; } | n659 "659" { assert ($1 == 659); $$ = $1; } | n660 "660" { assert ($1 == 660); $$ = $1; } | n661 "661" { assert ($1 == 661); $$ = $1; } | n662 "662" { assert ($1 == 662); $$ = $1; } | n663 "663" { assert ($1 == 663); $$ = $1; } | n664 "664" { assert ($1 == 664); $$ = $1; } | n665 "665" { assert ($1 == 665); $$ = $1; } | n666 "666" { assert ($1 == 666); $$ = $1; } | n667 "667" { assert ($1 == 667); $$ = $1; } | n668 "668" { assert ($1 == 668); $$ = $1; } | n669 "669" { assert ($1 == 669); $$ = $1; } | n670 "670" { assert ($1 == 670); $$ = $1; } | n671 "671" { assert ($1 == 671); $$ = $1; } | n672 "672" { assert ($1 == 672); $$ = $1; } | n673 "673" { assert ($1 == 673); $$ = $1; } | n674 "674" { assert ($1 == 674); $$ = $1; } | n675 "675" { assert ($1 == 675); $$ = $1; } | n676 "676" { assert ($1 == 676); $$ = $1; } | n677 "677" { assert ($1 == 677); $$ = $1; } | n678 "678" { assert ($1 == 678); $$ = $1; } | n679 "679" { assert ($1 == 679); $$ = $1; } | n680 "680" { assert ($1 == 680); $$ = $1; } | n681 "681" { assert ($1 == 681); $$ = $1; } | n682 "682" { assert ($1 == 682); $$ = $1; } | n683 "683" { assert ($1 == 683); $$ = $1; } | n684 "684" { assert ($1 == 684); $$ = $1; } | n685 "685" { assert ($1 == 685); $$ = $1; } | n686 "686" { assert ($1 == 686); $$ = $1; } | n687 "687" { assert ($1 == 687); $$ = $1; } | n688 "688" { assert ($1 == 688); $$ = $1; } | n689 "689" { assert ($1 == 689); $$ = $1; } | n690 "690" { assert ($1 == 690); $$ = $1; } | n691 "691" { assert ($1 == 691); $$ = $1; } | n692 "692" { assert ($1 == 692); $$ = $1; } | n693 "693" { assert ($1 == 693); $$ = $1; } | n694 "694" { assert ($1 == 694); $$ = $1; } | n695 "695" { assert ($1 == 695); $$ = $1; } | n696 "696" { assert ($1 == 696); $$ = $1; } | n697 "697" { assert ($1 == 697); $$ = $1; } | n698 "698" { assert ($1 == 698); $$ = $1; } | n699 "699" { assert ($1 == 699); $$ = $1; } | n700 "700" { assert ($1 == 700); $$ = $1; } | n701 "701" { assert ($1 == 701); $$ = $1; } | n702 "702" { assert ($1 == 702); $$ = $1; } | n703 "703" { assert ($1 == 703); $$ = $1; } | n704 "704" { assert ($1 == 704); $$ = $1; } | n705 "705" { assert ($1 == 705); $$ = $1; } | n706 "706" { assert ($1 == 706); $$ = $1; } | n707 "707" { assert ($1 == 707); $$ = $1; } | n708 "708" { assert ($1 == 708); $$ = $1; } | n709 "709" { assert ($1 == 709); $$ = $1; } | n710 "710" { assert ($1 == 710); $$ = $1; } | n711 "711" { assert ($1 == 711); $$ = $1; } | n712 "712" { assert ($1 == 712); $$ = $1; } | n713 "713" { assert ($1 == 713); $$ = $1; } | n714 "714" { assert ($1 == 714); $$ = $1; } | n715 "715" { assert ($1 == 715); $$ = $1; } | n716 "716" { assert ($1 == 716); $$ = $1; } | n717 "717" { assert ($1 == 717); $$ = $1; } | n718 "718" { assert ($1 == 718); $$ = $1; } | n719 "719" { assert ($1 == 719); $$ = $1; } | n720 "720" { assert ($1 == 720); $$ = $1; } | n721 "721" { assert ($1 == 721); $$ = $1; } | n722 "722" { assert ($1 == 722); $$ = $1; } | n723 "723" { assert ($1 == 723); $$ = $1; } | n724 "724" { assert ($1 == 724); $$ = $1; } | n725 "725" { assert ($1 == 725); $$ = $1; } | n726 "726" { assert ($1 == 726); $$ = $1; } | n727 "727" { assert ($1 == 727); $$ = $1; } | n728 "728" { assert ($1 == 728); $$ = $1; } | n729 "729" { assert ($1 == 729); $$ = $1; } | n730 "730" { assert ($1 == 730); $$ = $1; } | n731 "731" { assert ($1 == 731); $$ = $1; } | n732 "732" { assert ($1 == 732); $$ = $1; } | n733 "733" { assert ($1 == 733); $$ = $1; } | n734 "734" { assert ($1 == 734); $$ = $1; } | n735 "735" { assert ($1 == 735); $$ = $1; } | n736 "736" { assert ($1 == 736); $$ = $1; } | n737 "737" { assert ($1 == 737); $$ = $1; } | n738 "738" { assert ($1 == 738); $$ = $1; } | n739 "739" { assert ($1 == 739); $$ = $1; } | n740 "740" { assert ($1 == 740); $$ = $1; } | n741 "741" { assert ($1 == 741); $$ = $1; } | n742 "742" { assert ($1 == 742); $$ = $1; } | n743 "743" { assert ($1 == 743); $$ = $1; } | n744 "744" { assert ($1 == 744); $$ = $1; } | n745 "745" { assert ($1 == 745); $$ = $1; } | n746 "746" { assert ($1 == 746); $$ = $1; } | n747 "747" { assert ($1 == 747); $$ = $1; } | n748 "748" { assert ($1 == 748); $$ = $1; } | n749 "749" { assert ($1 == 749); $$ = $1; } | n750 "750" { assert ($1 == 750); $$ = $1; } | n751 "751" { assert ($1 == 751); $$ = $1; } | n752 "752" { assert ($1 == 752); $$ = $1; } | n753 "753" { assert ($1 == 753); $$ = $1; } | n754 "754" { assert ($1 == 754); $$ = $1; } | n755 "755" { assert ($1 == 755); $$ = $1; } | n756 "756" { assert ($1 == 756); $$ = $1; } | n757 "757" { assert ($1 == 757); $$ = $1; } | n758 "758" { assert ($1 == 758); $$ = $1; } | n759 "759" { assert ($1 == 759); $$ = $1; } | n760 "760" { assert ($1 == 760); $$ = $1; } | n761 "761" { assert ($1 == 761); $$ = $1; } | n762 "762" { assert ($1 == 762); $$ = $1; } | n763 "763" { assert ($1 == 763); $$ = $1; } | n764 "764" { assert ($1 == 764); $$ = $1; } | n765 "765" { assert ($1 == 765); $$ = $1; } | n766 "766" { assert ($1 == 766); $$ = $1; } | n767 "767" { assert ($1 == 767); $$ = $1; } | n768 "768" { assert ($1 == 768); $$ = $1; } | n769 "769" { assert ($1 == 769); $$ = $1; } | n770 "770" { assert ($1 == 770); $$ = $1; } | n771 "771" { assert ($1 == 771); $$ = $1; } | n772 "772" { assert ($1 == 772); $$ = $1; } | n773 "773" { assert ($1 == 773); $$ = $1; } | n774 "774" { assert ($1 == 774); $$ = $1; } | n775 "775" { assert ($1 == 775); $$ = $1; } | n776 "776" { assert ($1 == 776); $$ = $1; } | n777 "777" { assert ($1 == 777); $$ = $1; } | n778 "778" { assert ($1 == 778); $$ = $1; } | n779 "779" { assert ($1 == 779); $$ = $1; } | n780 "780" { assert ($1 == 780); $$ = $1; } | n781 "781" { assert ($1 == 781); $$ = $1; } | n782 "782" { assert ($1 == 782); $$ = $1; } | n783 "783" { assert ($1 == 783); $$ = $1; } | n784 "784" { assert ($1 == 784); $$ = $1; } | n785 "785" { assert ($1 == 785); $$ = $1; } | n786 "786" { assert ($1 == 786); $$ = $1; } | n787 "787" { assert ($1 == 787); $$ = $1; } | n788 "788" { assert ($1 == 788); $$ = $1; } | n789 "789" { assert ($1 == 789); $$ = $1; } | n790 "790" { assert ($1 == 790); $$ = $1; } | n791 "791" { assert ($1 == 791); $$ = $1; } | n792 "792" { assert ($1 == 792); $$ = $1; } | n793 "793" { assert ($1 == 793); $$ = $1; } | n794 "794" { assert ($1 == 794); $$ = $1; } | n795 "795" { assert ($1 == 795); $$ = $1; } | n796 "796" { assert ($1 == 796); $$ = $1; } | n797 "797" { assert ($1 == 797); $$ = $1; } | n798 "798" { assert ($1 == 798); $$ = $1; } | n799 "799" { assert ($1 == 799); $$ = $1; } | n800 "800" { assert ($1 == 800); $$ = $1; } | n801 "801" { assert ($1 == 801); $$ = $1; } | n802 "802" { assert ($1 == 802); $$ = $1; } | n803 "803" { assert ($1 == 803); $$ = $1; } | n804 "804" { assert ($1 == 804); $$ = $1; } | n805 "805" { assert ($1 == 805); $$ = $1; } | n806 "806" { assert ($1 == 806); $$ = $1; } | n807 "807" { assert ($1 == 807); $$ = $1; } | n808 "808" { assert ($1 == 808); $$ = $1; } | n809 "809" { assert ($1 == 809); $$ = $1; } | n810 "810" { assert ($1 == 810); $$ = $1; } | n811 "811" { assert ($1 == 811); $$ = $1; } | n812 "812" { assert ($1 == 812); $$ = $1; } | n813 "813" { assert ($1 == 813); $$ = $1; } | n814 "814" { assert ($1 == 814); $$ = $1; } | n815 "815" { assert ($1 == 815); $$ = $1; } | n816 "816" { assert ($1 == 816); $$ = $1; } | n817 "817" { assert ($1 == 817); $$ = $1; } | n818 "818" { assert ($1 == 818); $$ = $1; } | n819 "819" { assert ($1 == 819); $$ = $1; } | n820 "820" { assert ($1 == 820); $$ = $1; } | n821 "821" { assert ($1 == 821); $$ = $1; } | n822 "822" { assert ($1 == 822); $$ = $1; } | n823 "823" { assert ($1 == 823); $$ = $1; } | n824 "824" { assert ($1 == 824); $$ = $1; } | n825 "825" { assert ($1 == 825); $$ = $1; } | n826 "826" { assert ($1 == 826); $$ = $1; } | n827 "827" { assert ($1 == 827); $$ = $1; } | n828 "828" { assert ($1 == 828); $$ = $1; } | n829 "829" { assert ($1 == 829); $$ = $1; } | n830 "830" { assert ($1 == 830); $$ = $1; } | n831 "831" { assert ($1 == 831); $$ = $1; } | n832 "832" { assert ($1 == 832); $$ = $1; } | n833 "833" { assert ($1 == 833); $$ = $1; } | n834 "834" { assert ($1 == 834); $$ = $1; } | n835 "835" { assert ($1 == 835); $$ = $1; } | n836 "836" { assert ($1 == 836); $$ = $1; } | n837 "837" { assert ($1 == 837); $$ = $1; } | n838 "838" { assert ($1 == 838); $$ = $1; } | n839 "839" { assert ($1 == 839); $$ = $1; } | n840 "840" { assert ($1 == 840); $$ = $1; } | n841 "841" { assert ($1 == 841); $$ = $1; } | n842 "842" { assert ($1 == 842); $$ = $1; } | n843 "843" { assert ($1 == 843); $$ = $1; } | n844 "844" { assert ($1 == 844); $$ = $1; } | n845 "845" { assert ($1 == 845); $$ = $1; } | n846 "846" { assert ($1 == 846); $$ = $1; } | n847 "847" { assert ($1 == 847); $$ = $1; } | n848 "848" { assert ($1 == 848); $$ = $1; } | n849 "849" { assert ($1 == 849); $$ = $1; } | n850 "850" { assert ($1 == 850); $$ = $1; } | n851 "851" { assert ($1 == 851); $$ = $1; } | n852 "852" { assert ($1 == 852); $$ = $1; } | n853 "853" { assert ($1 == 853); $$ = $1; } | n854 "854" { assert ($1 == 854); $$ = $1; } | n855 "855" { assert ($1 == 855); $$ = $1; } | n856 "856" { assert ($1 == 856); $$ = $1; } | n857 "857" { assert ($1 == 857); $$ = $1; } | n858 "858" { assert ($1 == 858); $$ = $1; } | n859 "859" { assert ($1 == 859); $$ = $1; } | n860 "860" { assert ($1 == 860); $$ = $1; } | n861 "861" { assert ($1 == 861); $$ = $1; } | n862 "862" { assert ($1 == 862); $$ = $1; } | n863 "863" { assert ($1 == 863); $$ = $1; } | n864 "864" { assert ($1 == 864); $$ = $1; } | n865 "865" { assert ($1 == 865); $$ = $1; } | n866 "866" { assert ($1 == 866); $$ = $1; } | n867 "867" { assert ($1 == 867); $$ = $1; } | n868 "868" { assert ($1 == 868); $$ = $1; } | n869 "869" { assert ($1 == 869); $$ = $1; } | n870 "870" { assert ($1 == 870); $$ = $1; } | n871 "871" { assert ($1 == 871); $$ = $1; } | n872 "872" { assert ($1 == 872); $$ = $1; } | n873 "873" { assert ($1 == 873); $$ = $1; } | n874 "874" { assert ($1 == 874); $$ = $1; } | n875 "875" { assert ($1 == 875); $$ = $1; } | n876 "876" { assert ($1 == 876); $$ = $1; } | n877 "877" { assert ($1 == 877); $$ = $1; } | n878 "878" { assert ($1 == 878); $$ = $1; } | n879 "879" { assert ($1 == 879); $$ = $1; } | n880 "880" { assert ($1 == 880); $$ = $1; } | n881 "881" { assert ($1 == 881); $$ = $1; } | n882 "882" { assert ($1 == 882); $$ = $1; } | n883 "883" { assert ($1 == 883); $$ = $1; } | n884 "884" { assert ($1 == 884); $$ = $1; } | n885 "885" { assert ($1 == 885); $$ = $1; } | n886 "886" { assert ($1 == 886); $$ = $1; } | n887 "887" { assert ($1 == 887); $$ = $1; } | n888 "888" { assert ($1 == 888); $$ = $1; } | n889 "889" { assert ($1 == 889); $$ = $1; } | n890 "890" { assert ($1 == 890); $$ = $1; } | n891 "891" { assert ($1 == 891); $$ = $1; } | n892 "892" { assert ($1 == 892); $$ = $1; } | n893 "893" { assert ($1 == 893); $$ = $1; } | n894 "894" { assert ($1 == 894); $$ = $1; } | n895 "895" { assert ($1 == 895); $$ = $1; } | n896 "896" { assert ($1 == 896); $$ = $1; } | n897 "897" { assert ($1 =./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 = 897); $$ = $1; } | n898 "898" { assert ($1 == 898); $$ = $1; } | n899 "899" { assert ($1 == 899); $$ = $1; } | n900 "900" { assert ($1 == 900); $$ = $1; } | n901 "901" { assert ($1 == 901); $$ = $1; } | n902 "902" { assert ($1 == 902); $$ = $1; } | n903 "903" { assert ($1 == 903); $$ = $1; } | n904 "904" { assert ($1 == 904); $$ = $1; } | n905 "905" { assert ($1 == 905); $$ = $1; } | n906 "906" { assert ($1 == 906); $$ = $1; } | n907 "907" { assert ($1 == 907); $$ = $1; } | n908 "908" { assert ($1 == 908); $$ = $1; } | n909 "909" { assert ($1 == 909); $$ = $1; } | n910 "910" { assert ($1 == 910); $$ = $1; } | n911 "911" { assert ($1 == 911); $$ = $1; } | n912 "912" { assert ($1 == 912); $$ = $1; } | n913 "913" { assert ($1 == 913); $$ = $1; } | n914 "914" { assert ($1 == 914); $$ = $1; } | n915 "915" { assert ($1 == 915); $$ = $1; } | n916 "916" { assert ($1 == 916); $$ = $1; } | n917 "917" { assert ($1 == 917); $$ = $1; } | n918 "918" { assert ($1 == 918); $$ = $1; } | n919 "919" { assert ($1 == 919); $$ = $1; } | n920 "920" { assert ($1 == 920); $$ = $1; } | n921 "921" { assert ($1 == 921); $$ = $1; } | n922 "922" { assert ($1 == 922); $$ = $1; } | n923 "923" { assert ($1 == 923); $$ = $1; } | n924 "924" { assert ($1 == 924); $$ = $1; } | n925 "925" { assert ($1 == 925); $$ = $1; } | n926 "926" { assert ($1 == 926); $$ = $1; } | n927 "927" { assert ($1 == 927); $$ = $1; } | n928 "928" { assert ($1 == 928); $$ = $1; } | n929 "929" { assert ($1 == 929); $$ = $1; } | n930 "930" { assert ($1 == 930); $$ = $1; } | n931 "931" { assert ($1 == 931); $$ = $1; } | n932 "932" { assert ($1 == 932); $$ = $1; } | n933 "933" { assert ($1 == 933); $$ = $1; } | n934 "934" { assert ($1 == 934); $$ = $1; } | n935 "935" { assert ($1 == 935); $$ = $1; } | n936 "936" { assert ($1 == 936); $$ = $1; } | n937 "937" { assert ($1 == 937); $$ = $1; } | n938 "938" { assert ($1 == 938); $$ = $1; } | n939 "939" { assert ($1 == 939); $$ = $1; } | n940 "940" { assert ($1 == 940); $$ = $1; } | n941 "941" { assert ($1 == 941); $$ = $1; } | n942 "942" { assert ($1 == 942); $$ = $1; } | n943 "943" { assert ($1 == 943); $$ = $1; } | n944 "944" { assert ($1 == 944); $$ = $1; } | n945 "945" { assert ($1 == 945); $$ = $1; } | n946 "946" { assert ($1 == 946); $$ = $1; } | n947 "947" { assert ($1 == 947); $$ = $1; } | n948 "948" { assert ($1 == 948); $$ = $1; } | n949 "949" { assert ($1 == 949); $$ = $1; } | n950 "950" { assert ($1 == 950); $$ = $1; } | n951 "951" { assert ($1 == 951); $$ = $1; } | n952 "952" { assert ($1 == 952); $$ = $1; } | n953 "953" { assert ($1 == 953); $$ = $1; } | n954 "954" { assert ($1 == 954); $$ = $1; } | n955 "955" { assert ($1 == 955); $$ = $1; } | n956 "956" { assert ($1 == 956); $$ = $1; } | n957 "957" { assert ($1 == 957); $$ = $1; } | n958 "958" { assert ($1 == 958); $$ = $1; } | n959 "959" { assert ($1 == 959); $$ = $1; } | n960 "960" { assert ($1 == 960); $$ = $1; } | n961 "961" { assert ($1 == 961); $$ = $1; } | n962 "962" { assert ($1 == 962); $$ = $1; } | n963 "963" { assert ($1 == 963); $$ = $1; } | n964 "964" { assert ($1 == 964); $$ = $1; } | n965 "965" { assert ($1 == 965); $$ = $1; } | n966 "966" { assert ($1 == 966); $$ = $1; } | n967 "967" { assert ($1 == 967); $$ = $1; } | n968 "968" { assert ($1 == 968); $$ = $1; } | n969 "969" { assert ($1 == 969); $$ = $1; } | n970 "970" { assert ($1 == 970); $$ = $1; } | n971 "971" { assert ($1 == 971); $$ = $1; } | n972 "972" { assert ($1 == 972); $$ = $1; } | n973 "973" { assert ($1 == 973); $$ = $1; } | n974 "974" { assert ($1 == 974); $$ = $1; } | n975 "975" { assert ($1 == 975); $$ = $1; } | n976 "976" { assert ($1 == 976); $$ = $1; } | n977 "977" { assert ($1 == 977); $$ = $1; } | n978 "978" { assert ($1 == 978); $$ = $1; } | n979 "979" { assert ($1 == 979); $$ = $1; } | n980 "980" { assert ($1 == 980); $$ = $1; } | n981 "981" { assert ($1 == 981); $$ = $1; } | n982 "982" { assert ($1 == 982); $$ = $1; } | n983 "983" { assert ($1 == 983); $$ = $1; } | n984 "984" { assert ($1 == 984); $$ = $1; } | n985 "985" { assert ($1 == 985); $$ = $1; } | n986 "986" { assert ($1 == 986); $$ = $1; } | n987 "987" { assert ($1 == 987); $$ = $1; } | n988 "988" { assert ($1 == 988); $$ = $1; } | n989 "989" { assert ($1 == 989); $$ = $1; } | n990 "990" { assert ($1 == 990); $$ = $1; } | n991 "991" { assert ($1 == 991); $$ = $1; } | n992 "992" { assert ($1 == 992); $$ = $1; } | n993 "993" { assert ($1 == 993); $$ = $1; } | n994 "994" { assert ($1 == 994); $$ = $1; } | n995 "995" { assert ($1 == 995); $$ = $1; } | n996 "996" { assert ($1 == 996); $$ = $1; } | n997 "997" { assert ($1 == 997); $$ = $1; } | n998 "998" { assert ($1 == 998); $$ = $1; } | n999 "999" { assert ($1 == 999); $$ = $1; } | n1000 "1000" { assert ($1 == 1000); $$ = $1; } ; n1: token { $$ = 1; }; n2: token { $$ = 2; }; n3: token { $$ = 3; }; n4: token { $$ = 4; }; n5: token { $$ = 5; }; n6: token { $$ = 6; }; n7: token { $$ = 7; }; n8: token { $$ = 8; }; n9: token { $$ = 9; }; n10: token { $$ = 10; }; n11: token { $$ = 11; }; n12: token { $$ = 12; }; n13: token { $$ = 13; }; n14: token { $$ = 14; }; n15: token { $$ = 15; }; n16: token { $$ = 16; }; n17: token { $$ = 17; }; n18: token { $$ = 18; }; n19: token { $$ = 19; }; n20: token { $$ = 20; }; n21: token { $$ = 21; }; n22: token { $$ = 22; }; n23: token { $$ = 23; }; n24: token { $$ = 24; }; n25: token { $$ = 25; }; n26: token { $$ = 26; }; n27: token { $$ = 27; }; n28: token { $$ = 28; }; n29: token { $$ = 29; }; n30: token { $$ = 30; }; n31: token { $$ = 31; }; n32: token { $$ = 32; }; n33: token { $$ = 33; }; n34: token { $$ = 34; }; n35: token { $$ = 35; }; n36: token { $$ = 36; }; n37: token { $$ = 37; }; n38: token { $$ = 38; }; n39: token { $$ = 39; }; n40: token { $$ = 40; }; n41: token { $$ = 41; }; n42: token { $$ = 42; }; n43: token { $$ = 43; }; n44: token { $$ = 44; }; n45: token { $$ = 45; }; n46: token { $$ = 46; }; n47: token { $$ = 47; }; n48: token { $$ = 48; }; n49: token { $$ = 49; }; n50: token { $$ = 50; }; n51: token { $$ = 51; }; n52: token { $$ = 52; }; n53: token { $$ = 53; }; n54: token { $$ = 54; }; n55: token { $$ = 55; }; n56: token { $$ = 56; }; n57: token { $$ = 57; }; n58: token { $$ = 58; }; n59: token { $$ = 59; }; n60: token { $$ = 60; }; n61: token { $$ = 61; }; n62: token { $$ = 62; }; n63: token { $$ = 63; }; n64: token { $$ = 64; }; n65: token { $$ = 65; }; n66: token { $$ = 66; }; n67: token { $$ = 67; }; n68: token { $$ = 68; }; n69: token { $$ = 69; }; n70: token { $$ = 70; }; n71: token { $$ = 71; }; n72: token { $$ = 72; }; n73: token { $$ = 73; }; n74: token { $$ = 74; }; n75: token { $$ = 75; }; n76: token { $$ = 76; }; n77: token { $$ = 77; }; n78: token { $$ = 78; }; n79: token { $$ = 79; }; n80: token { $$ = 80; }; n81: token { $$ = 81; }; n82: token { $$ = 82; }; n83: token { $$ = 83; }; n84: token { $$ = 84; }; n85: token { $$ = 85; }; n86: token { $$ = 86; }; n87: token { $$ = 87; }; n88: token { $$ = 88; }; n89: token { $$ = 89; }; n90: token { $$ = 90; }; n91: token { $$ = 91; }; n92: token { $$ = 92; }; n93: token { $$ = 93; }; n94: token { $$ = 94; }; n95: token { $$ = 95; }; n96: token { $$ = 96; }; n97: token { $$ = 97; }; n98: token { $$ = 98; }; n99: token { $$ = 99; }; n100: token { $$ = 100; }; n101: token { $$ = 101; }; n102: token { $$ = 102; }; n103: token { $$ = 103; }; n104: token { $$ = 104; }; n105: token { $$ = 105; }; n106: token { $$ = 106; }; n107: token { $$ = 107; }; n108: token { $$ = 108; }; n109: token { $$ = 109; }; n110: token { $$ = 110; }; n111: token { $$ = 111; }; n112: token { $$ = 112; }; n113: token { $$ = 113; }; n114: token { $$ = 114; }; n115: token { $$ = 115; }; n116: token { $$ = 116; }; n117: token { $$ = 117; }; n118: token { $$ = 118; }; n119: token { $$ = 119; }; n120: token { $$ = 120; }; n121: token { $$ = 121; }; n122: token { $$ = 122; }; n123: token { $$ = 123; }; n124: token { $$ = 124; }; n125: token { $$ = 125; }; n126: token { $$ = 126; }; n127: token { $$ = 127; }; n128: token { $$ = 128; }; n129: token { $$ = 129; }; n130: token { $$ = 130; }; n131: token { $$ = 131; }; n132: token { $$ = 132; }; n133: token { $$ = 133; }; n134: token { $$ = 134; }; n135: token { $$ = 135; }; n136: token { $$ = 136; }; n137: token { $$ = 137; }; n138: token { $$ = 138; }; n139: token { $$ = 139; }; n140: token { $$ = 140; }; n141: token { $$ = 141; }; n142: token { $$ = 142; }; n143: token { $$ = 143; }; n144: token { $$ = 144; }; n145: token { $$ = 145; }; n146: token { $$ = 146; }; n147: token { $$ = 147; }; n148: token { $$ = 148; }; n149: token { $$ = 149; }; n150: token { $$ = 150; }; n151: token { $$ = 151; }; n152: token { $$ = 152; }; n153: token { $$ = 153; }; n154: token { $$ = 154; }; n155: token { $$ = 155; }; n156: token { $$ = 156; }; n157: token { $$ = 157; }; n158: token { $$ = 158; }; n159: token { $$ = 159; }; n160: token { $$ = 160; }; n161: token { $$ = 161; }; n162: token { $$ = 162; }; n163: token { $$ = 163; }; n164: token { $$ = 164; }; n165: token { $$ = 165; }; n166: token { $$ = 166; }; n167: token { $$ = 167; }; n168: token { $$ = 168; }; n169: token { $$ = 169; }; n170: token { $$ = 170; }; n171: token { $$ = 171; }; n172: token { $$ = 172; }; n173: token { $$ = 173; }; n174: token { $$ = 174; }; n175: token { $$ = 175; }; n176: token { $$ = 176; }; n177: token { $$ = 177; }; n178: token { $$ = 178; }; n179: token { $$ = 179; }; n180: token { $$ = 180; }; n181: token { $$ = 181; }; n182: token { $$ = 182; }; n183: token { $$ = 183; }; n184: token { $$ = 184; }; n185: token { $$ = 185; }; n186: token { $$ = 186; }; n187: token { $$ = 187; }; n188: token { $$ = 188; }; n189: token { $$ = 189; }; n190: token { $$ = 190; }; n191: token { $$ = 191; }; n192: token { $$ = 192; }; n193: token { $$ = 193; }; n194: token { $$ = 194; }; n195: token { $$ = 195; }; n196: token { $$ = 196; }; n197: token { $$ = 197; }; n198: token { $$ = 198; }; n199: token { $$ = 199; }; n200: token { $$ = 200; }; n201: token { $$ = 201; }; n202: token { $$ = 202; }; n203: token { $$ = 203; }; n204: token { $$ = 204; }; n205: token { $$ = 205; }; n206: token { $$ = 206; }; n207: token { $$ = 207; }; n208: token { $$ = 208; }; n209: token { $$ = 209; }; n210: token { $$ = 210; }; n211: token { $$ = 211; }; n212: token { $$ = 212; }; n213: token { $$ = 213; }; n214: token { $$ = 214; }; n215: token { $$ = 215; }; n216: token { $$ = 216; }; n217: token { $$ = 217; }; n218: token { $$ = 218; }; n219: token { $$ = 219; }; n220: token { $$ = 220; }; n221: token { $$ = 221; }; n222: token { $$ = 222; }; n223: token { $$ = 223; }; n224: token { $$ = 224; }; n225: token { $$ = 225; }; n226: token { $$ = 226; }; n227: token { $$ = 227; }; n228: token { $$ = 228; }; n229: token { $$ = 229; }; n230: token { $$ = 230; }; n231: token { $$ = 231; }; n232: token { $$ = 232; }; n233: token { $$ = 233; }; n234: token { $$ = 234; }; n235: token { $$ = 235; }; n236: token { $$ = 236; }; n237: token { $$ = 237; }; n238: token { $$ = 238; }; n239: token { $$ = 239; }; n240: token { $$ = 240; }; n241: token { $$ = 241; }; n242: token { $$ = 242; }; n243: token { $$ = 243; }; n244: token { $$ = 244; }; n245: token { $$ = 245; }; n246: token { $$ = 246; }; n247: token { $$ = 247; }; n248: token { $$ = 248; }; n249: token { $$ = 249; }; n250: token { $$ = 250; }; n251: token { $$ = 251; }; n252: token { $$ = 252; }; n253: token { $$ = 253; }; n254: token { $$ = 254; }; n255: token { $$ = 255; }; n256: token { $$ = 256; }; n257: token { $$ = 257; }; n258: token { $$ = 258; }; n259: token { $$ = 259; }; n260: token { $$ = 260; }; n261: token { $$ = 261; }; n262: token { $$ = 262; }; n263: token { $$ = 263; }; n264: token { $$ = 264; }; n265: token { $$ = 265; }; n266: token { $$ = 266; }; n267: token { $$ = 267; }; n268: token { $$ = 268; }; n269: token { $$ = 269; }; n270: token { $$ = 270; }; n271: token { $$ = 271; }; n272: token { $$ = 272; }; n273: token { $$ = 273; }; n274: token { $$ = 274; }; n275: token { $$ = 275; }; n276: token { $$ = 276; }; n277: token { $$ = 277; }; n278: token { $$ = 278; }; n279: token { $$ = 279; }; n280: token { $$ = 280; }; n281: token { $$ = 281; }; n282: token { $$ = 282; }; n283: token { $$ = 283; }; n284: token { $$ = 284; }; n285: token { $$ = 285; }; n286: token { $$ = 286; }; n287: token { $$ = 287; }; n288: token { $$ = 288; }; n289: token { $$ = 289; }; n290: token { $$ = 290; }; n291: token { $$ = 291; }; n292: token { $$ = 292; }; n293: token { $$ = 293; }; n294: token { $$ = 294; }; n295: token { $$ = 295; }; n296: token { $$ = 296; }; n297: token { $$ = 297; }; n298: token { $$ = 298; }; n299: token { $$ = 299; }; n300: token { $$ = 300; }; n301: token { $$ = 301; }; n302: token { $$ = 302; }; n303: token { $$ = 303; }; n304: token { $$ = 304; }; n305: token { $$ = 305; }; n306: token { $$ = 306; }; n307: token { $$ = 307; }; n308: token { $$ = 308; }; n309: token { $$ = 309; }; n310: token { $$ = 310; }; n311: token { $$ = 311; }; n312: token { $$ = 312; }; n313: token { $$ = 313; }; n314: token { $$ = 314; }; n315: token { $$ = 315; }; n316: token { $$ = 316; }; n317: token { $$ = 317; }; n318: token { $$ = 318; }; n319: token { $$ = 319; }; n320: token { $$ = 320; }; n321: token { $$ = 321; }; n322: token { $$ = 322; }; n323: token { $$ = 323; }; n324: token { $$ = 324; }; n325: token { $$ = 325; }; n326: token { $$ = 326; }; n327: token { $$ = 327; }; n328: token { $$ = 328; }; n329: token { $$ = 329; }; n330: token { $$ = 330; }; n331: token { $$ = 331; }; n332: token { $$ = 332; }; n333: token { $$ = 333; }; n334: token { $$ = 334; }; n335: token { $$ = 335; }; n336: token { $$ = 336; }; n337: token { $$ = 337; }; n338: token { $$ = 338; }; n339: token { $$ = 339; }; n340: token { $$ = 340; }; n341: token { $$ = 341; }; n342: token { $$ = 342; }; n343: token { $$ = 343; }; n344: token { $$ = 344; }; n345: token { $$ = 345; }; n346: token { $$ = 346; }; n347: token { $$ = 347; }; n348: token { $$ = 348; }; n349: token { $$ = 349; }; n350: token { $$ = 350; }; n351: token { $$ = 351; }; n352: token { $$ = 352; }; n353: token { $$ = 353; }; n354: token { $$ = 354; }; n355: token { $$ = 355; }; n356: token { $$ = 356; }; n357: token { $$ = 357; }; n358: token { $$ = 358; }; n359: token { $$ = 359; }; n360: token { $$ = 360; }; n361: token { $$ = 361; }; n362: token { $$ = 362; }; n363: token { $$ = 363; }; n364: token { $$ = 364; }; n365: token { $$ = 365; }; n366: token { $$ = 366; }; n367: token { $$ = 367; }; n368: token { $$ = 368; }; n369: token { $$ = 369; }; n370: token { $$ = 370; }; n371: token { $$ = 371; }; n372: token { $$ = 372; }; n373: token { $$ = 373; }; n374: token { $$ = 374; }; n375: token { $$ = 375; }; n376: token { $$ = 376; }; n377: token { $$ = 377; }; n378: token { $$ = 378; }; n379: token { $$ = 379; }; n380: token { $$ = 380; }; n381: token { $$ = 381; }; n382: token { $$ = 382; }; n383: token { $$ = 383; }; n384: token { $$ = 384; }; n385: token { $$ = 385; }; n386: token { $$ = 386; }; n387: token { $$ = 387; }; n388: token { $$ = 388; }; n389: token { $$ = 389; }; n390: token { $$ = 390; }; n391: token { $$ = 391; }; n392: token { $$ = 392; }; n393: token { $$ = 393; }; n394: token { $$ = 394; }; n395: token { $$ = 395; }; n396: token { $$ = 396; }; n397: token { $$ = 397; }; n398: token { $$ = 398; }; n399: token { $$ = 399; }; n400: token { $$ = 400; }; n401: token { $$ = 401; }; n402: token { $$ = 402; }; n403: token { $$ = 403; }; n404: token { $$ = 404; }; n405: token { $$ = 405; }; n406: token { $$ = 406; }; n407: token { $$ = 407; }; n408: token { $$ = 408; }; n409: token { $$ = 409; }; n410: token { $$ = 410; }; n411: token { $$ = 411; }; n412: token { $$ = 412; }; n413: token { $$ = 413; }; n414: token { $$ = 414; }; n415: token { $$ = 415; }; n416: token { $$ = 416; }; n417: token { $$ = 417; }; n418: token { $$ = 418; }; n419: token { $$ = 419; }; n420: token { $$ = 420; }; n421: token { $$ = 421; }; n422: token { $$ = 422; }; n423: token { $$ = 423; }; n424: token { $$ = 424; }; n425: token { $$ = 425; }; n426: token { $$ = 426; }; n427: token { $$ = 427; }; n428: token { $$ = 428; }; n429: token { $$ = 429; }; n430: token { $$ = 430; }; n431: token { $$ = 431; }; n432: token { $$ = 432; }; n433: token { $$ = 433; }; n434: token { $$ = 434; }; n435: token { $$ = 435; }; n436: token { $$ = 436; }; n437: token { $$ = 437; }; n438: token { $$ = 438; }; n439: token { $$ = 439; }; n440: token { $$ = 440; }; n441: token { $$ = 441; }; n442: token { $$ = 442; }; n443: token { $$ = 443; }; n444: token { $$ = 444; }; n445: token { $$ = 445; }; n446: token { $$ = 446; }; n447: token { $$ = 447; }; n448: token { $$ = 448; }; n449: token { $$ = 449; }; n450: token { $$ = 450; }; n451: token { $$ = 451; }; n452: token { $$ = 452; }; n453: token { $$ = 453; }; n454: token { $$ = 454; }; n455: token { $$ = 455; }; n456: token { $$ = 456; }; n457: token { $$ = 457; }; n458: token { $$ = 458; }; n459: token { $$ = 459; }; n460: token { $$ = 460; }; n461: token { $$ = 461; }; n462: token { $$ = 462; }; n463: token { $$ = 463; }; n464: token { $$ = 464; }; n465: token { $$ = 465; }; n466: token { $$ = 466; }; n467: token { $$ = 467; }; n468: token { $$ = 468; }; n469: token { $$ = 469; }; n470: token { $$ = 470; }; n471: token { $$ = 471; }; n472: token { $$ = 472; }; n473: token { $$ = 473; }; n474: token { $$ = 474; }; n475: token { $$ = 475; }; n476: token { $$ = 476; }; n477: token { $$ = 477; }; n478: token { $$ = 478; }; n479: token { $$ = 479; }; n480: token { $$ = 480; }; n481: token { $$ = 481; }; n482: token { $$ = 482; }; n483: token { $$ = 483; }; n484: token { $$ = 484; }; n485: token { $$ = 485; }; n486: token { $$ = 486; }; n487: token { $$ = 487; }; n488: token { $$ = 488; }; n489: token { $$ = 489; }; n490: token { $$ = 490; }; n491: token { $$ = 491; }; n492: token { $$ = 492; }; n493: token { $$ = 493; }; n494: token { $$ = 494; }; n495: token { $$ = 495; }; n496: token { $$ = 496; }; n497: token { $$ = 497; }; n498: token { $$ = 498; }; n499: token { $$ = 499; }; n500: token { $$ = 500; }; n501: token { $$ = 501; }; n502: token { $$ = 502; }; n503: token { $$ = 503; }; n504: token { $$ = 504; }; n505: token { $$ = 505; }; n506: token { $$ = 506; }; n507: token { $$ = 507; }; n508: token { $$ = 508; }; n509: token { $$ = 509; }; n510: token { $$ = 510; }; n511: token { $$ = 511; }; n512: token { $$ = 512; }; n513: token { $$ = 513; }; n514: token { $$ = 514; }; n515: token { $$ = 515; }; n516: token { $$ = 516; }; n517: token { $$ = 517; }; n518: token { $$ = 518; }; n519: token { $$ = 519; }; n520: token { $$ = 520; }; n521: token { $$ = 521; }; n522: token { $$ = 522; }; n523: token { $$ = 523; }; n524: token { $$ = 524; }; n525: token { $$ = 525; }; n526: token { $$ = 526; }; n527: token { $$ = 527; }; n528: token { $$ = 528; }; n529: token { $$ = 529; }; n530: token { $$ = 530; }; n531: token { $$ = 531; }; n532: token { $$ = 532; }; n533: token { $$ = 533; }; n534: token { $$ = 534; }; n535: token { $$ = 535; }; n536: token { $$ = 536; }; n537: token { $$ = 537; }; n538: token { $$ = 538; }; n539: token { $$ = 539; }; n540: token { $$ = 540; }; n541: token { $$ = 541; }; n542: token { $$ = 542; }; n543: token { $$ = 543; }; n544: token { $$ = 544; }; n545: token { $$ = 545; }; n546: token { $$ = 546; }; n547: token { $$ = 547; }; n548: token { $$ = 548; }; n549: token { $$ = 549; }; n550: token { $$ = 550; }; n551: token { $$ = 551; }; n552: token { $$ = 552; }; n553: token { $$ = 553; }; n554: token { $$ = 554; }; n555: token { $$ = 555; }; n556: token { $$ = 556; }; n557: token { $$ = 557; }; n558: token { $$ = 558; }; n559: token { $$ = 559; }; n560: token { $$ = 560; }; n561: token { $$ = 561; }; n562: token { $$ = 562; }; n563: token { $$ = 563; }; n564: token { $$ = 564; }; n565: token { $$ = 565; }; n566: token { $$ = 566; }; n567: token { $$ = 567; }; n568: token { $$ = 568; }; n569: token { $$ = 569; }; n570: token { $$ = 570; }; n571: token { $$ = 571; }; n572: token { $$ = 572; }; n573: token { $$ = 573; }; n574: token { $$ = 574; }; n575: token { $$ = 575; }; n576: token { $$ = 576; }; n577: token { $$ = 577; }; n578: token { $$ = 578; }; n579: token { $$ = 579; }; n580: token { $$ = 580; }; n581: token { $$ = 581; }; n582: token { $$ = 582; }; n583: token { $$ = 583; }; n584: token { $$ = 584; }; n585: token { $$ = 585; }; n586: token { $$ = 586; }; n587: token { $$ = 587; }; n588: token { $$ = 588; }; n589: token { $$ = 589; }; n590: token { $$ = 590; }; n591: token { $$ = 591; }; n592: token { $$ = 592; }; n593: token { $$ = 593; }; n594: token { $$ = 594; }; n595: token { $$ = 595; }; n596: token { $$ = 596; }; n597: token { $$ = 597; }; n598: token { $$ = 598; }; n599: token { $$ = 599; }; n600: token { $$ = 600; }; n601: token { $$ = 601; }; n602: token { $$ = 602; }; n603: token { $$ = 603; }; n604: token { $$ = 604; }; n605: token { $$ = 605; }; n606: token { $$ = 606; }; n607: token { $$ = 607; }; n608: token { $$ = 608; }; n609: token { $$ = 609; }; n610: token { $$ = 610; }; n611: token { $$ = 611; }; n612: token { $$ = 612; }; n613: token { $$ = 613; }; n614: token { $$ = 614; }; n615: token { $$ = 615; }; n616: token { $$ = 616; }; n617: token { $$ = 617; }; n618: token { $$ = 618; }; n619: token { $$ = 619; }; n620: token { $$ = 620; }; n621: token { $$ = 621; }; n622: token { $$ = 622; }; n623: token { $$ = 623; }; n624: token { $$ = 624; }; n625: token { $$ = 625; }; n626: token { $$ = 626; }; n627: token { $$ = 627; }; n628: token { $$ = 628; }; n629: token { $$ = 629; }; n630: token { $$ = 630; }; n631: token { $$ = 631; }; n632: token { $$ = 632; }; n633: token { $$ = 633; }; n634: token { $$ = 634; }; n635: token { $$ = 635; }; n636: token { $$ = 636; }; n637: token { $$ = 637; }; n638: token { $$ = 638; }; n639: token { $$ = 639; }; n640: token { $$ = 640; }; n641: token { $$ = 641; }; n642: token { $$ = 642; }; n643: token { $$ = 643; }; n644: token { $$ = 644; }; n645: token { $$ = 645; }; n646: token { $$ = 646; }; n647: token { $$ = 647; }; n648: token { $$ = 648; }; n649: token { $$ = 649; }; n650: token { $$ = 650; }; n651: token { $$ = 651; }; n652: token { $$ = 652; }; n653: token { $$ = 653; }; n654: token { $$ = 654; }; n655: token { $$ = 655; }; n656: token { $$ = 656; }; n657: token { $$ = 657; }; n658: token { $$ = 658; }; n659: token { $$ = 659; }; n660: token { $$ = 660; }; n661: token { $$ = 661; }; n662: token { $$ = 662; }; n663: token { $$ = 663; }; n664: token { $$ = 664; }; n665: token { $$ = 665; }; n666: token { $$ = 666; }; n667: token { $$ = 667; }; n668: token { $$ = 668; }; n669: token { $$ = 669; }; n670: token { $$ = 670; }; n671: token { $$ = 671; }; n672: token { $$ = 672; }; n673: token { $$ = 673; }; n674: token { $$ = 674; }; n675: token { $$ = 675; }; n676: token { $$ = 676; }; n677: token { $$ = 677; }; n678: token { $$ = 678; }; n679: token { $$ = 679; }; n680: token { $$ = 680; }; n681: token { $$ = 681; }; n682: token { $$ = 682; }; n683: token { $$ = 683; }; n684: token { $$ = 684; }; n685: token { $$ = 685; }; n686: token { $$ = 686; }; n687: token { $$ = 687; }; n688: token { $$ = 688; }; n689: token { $$ = 689; }; n690: token { $$ = 690; }; n691: token { $$ = 691; }; n692: token { $$ = 692; }; n693: token { $$ = 693; }; n694: token { $$ = 694; }; n695: token { $$ = 695; }; n696: token { $$ = 696; }; n697: token { $$ = 697; }; n698: token { $$ = 698; }; n699: token { $$ = 699; }; n700: token { $$ = 700; }; n701: token { $$ = 701; }; n702: token { $$ = 702; }; n703: token { $$ = 703; }; n704: token { $$ = 704; }; n705: token { $$ = 705; }; n706: token { $$ = 706; }; n707: token { $$ = 707; }; n708: token { $$ = 708; }; n709: token { $$ = 709; }; n710: token { $$ = 710; }; n711: token { $$ = 711; }; n712: token { $$ = 712; }; n713: token { $$ = 713; }; n714: token { $$ = 714; }; n715: token { $$ = 715; }; n716: token { $$ = 716; }; n717: token { $$ = 717; }; n718: token { $$ = 718; }; n719: token { $$ = 719; }; n720: token { $$ = 720; }; n721: token { $$ = 721; }; n722: token { $$ = 722; }; n723: token { $$ = 723; }; n724: token { $$ = 724; }; n725: token { $$ = 725; }; n726: token { $$ = 726; }; n727: token { $$ = 727; }; n728: token { $$ = 728; }; n729: token { $$ = 729; }; n730: token { $$ = 730; }; n731: token { $$ = 731; }; n732: token { $$ = 732; }; n733: token { $$ = 733; }; n734: token { $$ = 734; }; n735: token { $$ = 735; }; n736: token { $$ = 736; }; n737: token { $$ = 737; }; n738: token { $$ = 738; }; n739: token { $$ = 739; }; n740: token { $$ = 740; }; n741: token { $$ = 741; }; n742: token { $$ = 742; }; n743: token { $$ = 743; }; n744: token { $$ = 744; }; n745: token { $$ = 745; }; n746: token { $$ = 746; }; n747: token { $$ = 747; }; n748: token { $$ = 748; }; n749: token { $$ = 749; }; n750: token { $$ = 750; }; n751: token { $$ = 751; }; n752: token { $$ = 752; }; n753: token { $$ = 753; }; n754: token { $$ = 754; }; n755: token { $$ = 755; }; n756: token { $$ = 756; }; n757: token { $$ = 757; }; n758: token { $$ = 758; }; n759: token { $$ = 759; }; n760: token { $$ = 760; }; n761: token { $$ = 761; }; n762: token { $$ = 762; }; n763: token { $$ = 763; }; n764: token { $$ = 764; }; n765: token { $$ = 765; }; n766: token { $$ = 766; }; n767: token { $$ = 767; }; n768: token { $$ = 768; }; n769: token { $$ = 769; }; n770: token { $$ = 770; }; n771: token { $$ = 771; }; n772: token { $$ = 772; }; n773: token { $$ = 773; }; n774: token { $$ = 774; }; n775: token { $$ = 775; }; n776: token { $$ = 776; }; n777: token { $$ = 777; }; n778: token { $$ = 778; }; n779: token { $$ = 779; }; n780: token { $$ = 780; }; n781: token { $$ = 781; }; n782: token { $$ = 782; }; n783: token { $$ = 783; }; n784: token { $$ = 784; }; n785: token { $$ = 785; }; n786: token { $$ = 786; }; n787: token { $$ = 787; }; n788: token { $$ = 788; }; n789: token { $$ = 789; }; n790: token { $$ = 790; }; n791: token { $$ = 791; }; n792: token { $$ = 792; }; n793: token { $$ = 793; }; n794: token { $$ = 794; }; n795: token { $$ = 795; }; n796: token { $$ = 796; }; n797: token { $$ = 797; }; n798: token { $$ = 798; }; n799: token { $$ = 799; }; n800: token { $$ = 800; }; n801: token { $$ = 801; }; n802: token { $$ = 802; }; n803: token { $$ = 803; }; n804: token { $$ = 804; }; n805: token { $$ = 805; }; n806: token { $$ = 806; }; n807: token { $$ = 807; }; n808: token { $$ = 808; }; n809: token { $$ = 809; }; n810: token { $$ = 810; }; n811: token { $$ = 811; }; n812: token { $$ = 812; }; n813: token { $$ = 813; }; n814: token { $$ = 814; }; n815: token { $$ = 815; }; n816: token { $$ = 816; }; n817: token { $$ = 817; }; n818: token { $$ = 818; }; n819: token { $$ = 819; }; n820: token { $$ = 820; }; n821: token { $$ = 821; }; n822: token { $$ = 822; }; n823: token { $$ = 823; }; n824: token { $$ = 824; }; n825: token { $$ = 825; }; n826: token { $$ = 826; }; n827: token { $$ = 827; }; n828: token { $$ = 828; }; n829: token { $$ = 829; }; n830: token { $$ = 830; }; n831: token { $$ = 831; }; n832: token { $$ = 832; }; n833: token { $$ = 833; }; n834: token { $$ = 834; }; n835: token { $$ = 835; }; n836: token { $$ = 836; }; n837: token { $$ = 837; }; n838: token { $$ = 838; }; n839: token { $$ = 839; }; n840: token { $$ = 840; }; n841: token { $$ = 841; }; n842: token { $$ = 842; }; n843: token { $$ = 843; }; n844: token { $$ = 844; }; n845: token { $$ = 845; }; n846: token { $$ = 846; }; n847: token { $$ = 847; }; n848: token { $$ = 848; }; n849: token { $$ = 849; }; n850: token { $$ = 850; }; n851: token { $$ = 851; }; n852: token { $$ = 852; }; n853: token { $$ = 853; }; n854: token { $$ = 854; }; n855: token { $$ = 855; }; n856: token { $$ = 856; }; n857: token { $$ = 857; }; n858: token { $$ = 858; }; n859: token { $$ = 859; }; n860: token { $$ = 860; }; n861: token { $$ = 861; }; n862: token { $$ = 862; }; n863: token { $$ = 863; }; n864: token { $$ = 864; }; n865: token { $$ = 865; }; n866: token { $$ = 866; }; n867: token { $$ = 867; }; n868: token { $$ = 868; }; n869: token { $$ = 869; }; n870: token { $$ = 870; }; n871: token { $$ = 871; }; n872: token { $$ = 872; }; n873: token { $$ = 873; }; n874: token { $$ = 874; }; n875: token { $$ = 875; }; n876: token { $$ = 876; }; n877: token { $$ = 877; }; n878: token { $$ = 878; }; n879: token { $$ = 879; }; n880: token { $$ = 880; }; n881: token { $$ = 881; }; n882: token { $$ = 882; }; n883: token { $$ = 883; }; n884: token { $$ = 884; }; n885: token { $$ = 885; }; n886: token { $$ = 886; }; n887: token { $$ = 887; }; n888: token { $$ = 888; }; n889: token { $$ = 889; }; n890: token { $$ = 890; }; n891: token { $$ = 891; }; n892: token { $$ = 892; }; n893: token { $$ = 893; }; n894: token { $$ = 894; }; n895: token { $$ = 895; }; n896: token { $$ = 896; }; n897: token { $$ = 897; }; n898: token { $$ = 898; }; n899: token { $$ = 899; }; n900: token { $$ = 900; }; n901: token { $$ = 901; }; n902: token { $$ = 902; }; n903: token { $$ = 903; }; n904: token { $$ = 904; }; n905: token { $$ = 905; }; n906: token { $$ = 906; }; n907: token { $$ = 907; }; n908: token { $$ = 908; }; n909: token { $$ = 909; }; n910: token { $$ = 910; }; n911: token { $$ = 911; }; n912: token { $$ = 912; }; n913: token { $$ = 913; }; n914: token { $$ = 914; }; n915: token { $$ = 915; }; n916: token { $$ = 916; }; n917: token { $$ = 917; }; n918: token { $$ = 918; }; n919: token { $$ = 919; }; n920: token { $$ = 920; }; n921: token { $$ = 921; }; n922: token { $$ = 922; }; n923: token { $$ = 923; }; n924: token { $$ = 924; }; n925: token { $$ = 925; }; n926: token { $$ = 926; }; n927: token { $$ = 927; }; n928: token { $$ = 928; }; n929: token { $$ = 929; }; n930: token { $$ = 930; }; n931: token { $$ = 931; }; n932: token { $$ = 932; }; n933: token { $$ = 933; }; n934: token { $$ = 934; }; n935: token { $$ = 935; }; n936: token { $$ = 936; }; n937: token { $$ = 937; }; n938: token { $$ = 938; }; n939: token { $$ = 939; }; n940: token { $$ = 940; }; n941: token { $$ = 941; }; n942: token { $$ = 942; }; n943: token { $$ = 943; }; n944: token { $$ = 944; }; n945: token { $$ = 945; }; n946: token { $$ = 946; }; n947: token { $$ = 947; }; n948: token { $$ = 948; }; n949: token { $$ = 949; }; n950: token { $$ = 950; }; n951: token { $$ = 951; }; n952: token { $$ = 952; }; n953: token { $$ = 953; }; n954: token { $$ = 954; }; n955: token { $$ = 955; }; n956: token { $$ = 956; }; n957: token { $$ = 957; }; n958: token { $$ = 958; }; n959: token { $$ = 959; }; n960: token { $$ = 960; }; n961: token { $$ = 961; }; n962: token { $$ = 962; }; n963: token { $$ = 963; }; n964: token { $$ = 964; }; n965: token { $$ = 965; }; n966: token { $$ = 966; }; n967: token { $$ = 967; }; n968: token { $$ = 968; }; n969: token { $$ = 969; }; n970: token { $$ = 970; }; n971: token { $$ = 971; }; n972: token { $$ = 972; }; n973: token { $$ = 973; }; n974: token { $$ = 974; }; n975: token { $$ = 975; }; n976: token { $$ = 976; }; n977: token { $$ = 977; }; n978: token { $$ = 978; }; n979: token { $$ = 979; }; n980: token { $$ = 980; }; n981: token { $$ = 981; }; n982: token { $$ = 982; }; n983: token { $$ = 983; }; n984: token { $$ = 984; }; n985: token { $$ = 985; }; n986: token { $$ = 986; }; n987: token { $$ = 987; }; n988: token { $$ = 988; }; n989: token { $$ = 989; }; n990: token { $$ = 990; }; n991: token { $$ = 991; }; n992: token { $$ = 992; }; n993: token { $$ = 993; }; n994: token { $$ = 994; }; n995: token { $$ = 995; }; n996: token { $$ = 996; }; n997: token { $$ = 997; }; n998: token { $$ = 998; }; n999: token { $$ = 999; }; n1000: token { $$ = 1000; }; %% /* A C error reporting function. */ /* !POSIX */ static void yyerror (const char *msg) { fprintf (stderr, "%s\n", msg); } static int yylex (void) { static int return_token = 1; static int counter = 1; if (counter > MAX) { assert (counter++ == MAX + 1); return 0; } if (return_token) { return_token = 0; return token; } return_token = 1; return counter++; } #include /* getenv. */ #include /* strcmp. */ int main (int argc, char const* argv[]) { (void) argc; (void) argv; return yyparse (); } stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 614. torture.at:485: testing Exploding the Stack Size with Alloca ... ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./torture.at:494: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./calc.at:1492: cat stderr 615. torture.at:531: testing Exploding the Stack Size with Malloc ... ./torture.at:535: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y input: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1492: $PREPARSER ./calc input ./torture.at:494: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./torture.at:393: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y ./calc.at:1494: cat stderr stderr: input: | (1 + 1) / (1 - 1) ./calc.at:1492: $PREPARSER ./calc input stderr: ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 617. existing.at:74: testing GNU AWK 3.1.0 Grammar: IELR(1) ... ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y input: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 616. existing.at:74: testing GNU AWK 3.1.0 Grammar: LALR(1) ... ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./torture.at:535: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS | (- *) + (1 2) = 1 ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (- *) + (1 2) = 1 ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: cat stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: cat stderr stderr: 567. calc.at:1492: ok input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | error ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: $PREPARSER ./calc input ./calc.at:1494: cat stderr stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror Starting parse Entering state 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) input: input: | (* *) + (*) + (*) ./calc.at:1491: $PREPARSER ./calc input | (* *) + (*) + (*) stderr: ./calc.at:1494: $PREPARSER ./calc input ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./torture.at:497: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 20 stderr: ./calc.at:1492: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./torture.at:538: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 20 stderr: ./torture.at:497: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./torture.at:538: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: 618. existing.at:74: testing GNU AWK 3.1.0 Grammar: Canonical LR(1) ... ./torture.at:541: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 900 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 = 2 = 3 ./calc.at:1492: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: ./torture.at:541: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./torture.at:500: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 900 ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y input.y:66.10: error: empty rule without %empty [-Werror=empty-rule] input.y:170.10: error: empty rule without %empty [-Werror=empty-rule] input.y:175.10: error: empty rule without %empty [-Werror=empty-rule] input.y:180.10: error: empty rule without %empty [-Werror=empty-rule] input.y:188.10: error: empty rule without %empty [-Werror=empty-rule] input.y:202.10: error: empty rule without %empty [-Werror=empty-rule] input.y:207.10: error: empty rule without %empty [-Werror=empty-rule] input.y:221.10: error: empty rule without %empty [-Werror=empty-rule] input.y:300.10: error: empty rule without %empty [-Werror=empty-rule] input.y:323.10: error: empty rule without %empty [-Werror=empty-rule] input.y: error: 65 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:39.1-5: error: useless associativity for FUNC_CALL, use %precedence [-Werror=precedence] input.y:44.1-5: error: useless associativity for YNUMBER, use %precedence [-Werror=precedence] input.y:44.1-5: error: useless associativity for YSTRING, use %precedence [-Werror=precedence] input.y:42.1-9: error: useless precedence and associativity for APPEND_OP [-Werror=precedence] input.y:33.1-6: error: useless associativity for ASSIGNOP, use %precedence [-Werror=precedence] input.y:43.1-5: error: useless associativity for CONCAT_OP, use %precedence [-Werror=precedence] input.y:37.1-5: error: useless precedence and associativity for LEX_GETLINE [-Werror=precedence] input.y:38.1-9: error: useless associativity for LEX_IN, use %precedence [-Werror=precedence] input.y:49.1-5: error: useless associativity for INCREMENT, use %precedence [-Werror=precedence] input.y:49.1-5: error: useless associativity for DECREMENT, use %precedence [-Werror=precedence] input.y:39.1-5: error: useless associativity for LEX_BUILTIN, use %precedence [-Werror=precedence] input.y:39.1-5: error: useless associativity for LEX_LENGTH, use %precedence [-Werror=precedence] input.y:40.1-9: error: useless precedence and associativity for ',' [-Werror=precedence] input.y:47.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] input.y:47.1-6: error: useless associativity for UNARY, use %precedence [-Werror=precedence] input.y:50.1-5: error: useless associativity for '$', use %precedence [-Werror=precedence] input.y:51.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] input.y:51.1-5: error: useless precedence and associativity for ')' [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) stderr: ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./torture.at:500: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./torture.at:545: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 10000 ./calc.at:1491: cat stderr stderr: stderr: ./existing.at:74: sed 's,.*/$,,' stderr 1>&2 ./calc.at:1494: cat stderr stderr: memory exhausted memory exhausted ./torture.at:545: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./torture.at:504: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 10000 stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) input.y:66.10: error: empty rule without %empty [-Werror=empty-rule] input.y:170.10: error: empty rule without %empty [-Werror=empty-rule] input.y:175.10: error: empty rule without %empty [-Werror=empty-rule] input.y:180.10: error: empty rule without %empty [-Werror=empty-rule] input.y:188.10: error: empty rule without %empty [-Werror=empty-rule] input.y:202.10: error: empty rule without %empty [-Werror=empty-rule] input.y:207.10: error: empty rule without %empty [-Werror=empty-rule] input.y:221.10: error: empty rule without %empty [-Werror=empty-rule] input.y:300.10: error: empty rule without %empty [-Werror=empty-rule] input.y:323.10: error: empty rule without %empty [-Werror=empty-rule] input.y: error: 65 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:39.1-5: error: useless associativity for FUNC_CALL, use %precedence [-Werror=precedence] input.y:44.1-5: error: useless associativity for YNUMBER, use %precedence [-Werror=precedence] input.y:44.1-5: error: useless associativity for YSTRING, use %precedence [-Werror=precedence] input.y:42.1-9: error: useless precedence and associativity for APPEND_OP [-Werror=precedence] input.y:33.1-6: error: useless associativity for ASSIGNOP, use %precedence [-Werror=precedence] input.y:43.1-5: error: useless associativity for CONCAT_OP, use %precedence [-Werror=precedence] input.y:37.1-5: error: useless precedence and associativity for LEX_GETLINE [-Werror=precedence] input.y:38.1-9: error: useless associativity for LEX_IN, use %precedence [-Werror=precedence] input.y:49.1-5: error: useless associativity for INCREMENT, use %precedence [-Werror=precedence] input.y:49.1-5: error: useless associativity for DECREMENT, use %precedence [-Werror=precedence] input.y:39.1-5: error: useless associativity for LEX_BUILTIN, use %precedence [-Werror=precedence] input.y:39.1-5: error: useless associativity for LEX_LENGTH, use %precedence [-Werror=precedence] input.y:40.1-9: error: useless precedence and associativity for ',' [-Werror=precedence] input.y:47.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] input.y:47.1-6: error: useless associativity for UNARY, use %precedence [-Werror=precedence] input.y:50.1-5: error: useless associativity for '$', use %precedence [-Werror=precedence] input.y:51.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] input.y:51.1-5: error: useless precedence and associativity for ')' [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] stderr: ./existing.at:74: sed 's,.*/$,,' stderr 1>&2 input: memory exhausted memory exhausted ./torture.at:504: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !+ ++ ./calc.at:1491: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error stderr: ./calc.at:1494: $PREPARSER ./calc input ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error memory exhausted memory exhausted stderr: stderr: stderr: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 memory exhausted memory exhausted Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./torture.at:548: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./torture.at:510: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./calc.at:1492: cat stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: input: input: | 1 + 2 * 3 + !- ++ ./calc.at:1494: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ | | +1 ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1492: $PREPARSER ./calc input stderr: ./torture.at:548: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./torture.at:510: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: cat stderr ./calc.at:1491: cat stderr ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (#) + (#) = 2222 ./calc.at:1494: $PREPARSER ./calc input ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: cat stderr input: ./torture.at:237: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1492: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (#) + (#) = 2222 ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) stderr: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: cat stderr ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./torture.at:140: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./calc.at:1492: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: cat stderr input: ./calc.at:1494: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1492: $PREPARSER ./calc input input: input: stderr: | (# + 1) = 1111 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (1 + #) = 1111 ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1494: $PREPARSER ./calc input stderr: stderr: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./existing.at:74: sed -n 's/^State //p' input.output | tail -1 ./existing.at:74: sed 's/^%define lr.type .*$//' input.y > input-lalr.y ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: cat stderr stderr: ./calc.at:1491: cat stderr input: | (!!) + (1 2) = 1 ./calc.at:1492: $PREPARSER ./calc input ./calc.at:1494: cat stderr ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror stdout: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./torture.at:513: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 20 input-lalr.y: warning: 65 shift/reduce conflicts [-Wconflicts-sr] input-lalr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stdout: ./existing.at:74: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: | (1 + # + 1) = 1111 stdout: input: ./calc.at:1494: $PREPARSER ./calc input ./torture.at:551: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 20 ./torture.at:513: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./torture.at:551: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 ./calc.at:1491: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./existing.at:74: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./torture.at:553: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 900 ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./torture.at:515: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 900 stderr: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./existing.at:74: sed -n 's/^State //p' input.output | tail -1 ./torture.at:553: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./torture.at:515: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:74: sed 's/^%define lr.type .*$//' input.y > input-lalr.y ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./torture.at:555: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 10000 ./calc.at:1491: cat stderr stderr: ./torture.at:517: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 10000 stderr: memory exhausted memory exhausted input: ./torture.at:555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: memory exhausted memory exhausted stdout: input: ./calc.at:1492: $PREPARSER ./calc input ./torture.at:517: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./torture.at:238: $PREPARSER ./input ./calc.at:1494: cat stderr | (1 + # + 1) = 1111 ./calc.at:1491: $PREPARSER ./calc input stderr: stderr: stderr: memory exhausted memory exhausted stderr: 615. torture.at:531: ok Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./torture.at:238: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: memory exhausted memory exhausted 605. torture.at:216: ok Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: 614. torture.at:485: ok | (1 + 1) / (1 - 1) ./calc.at:1494: $PREPARSER ./calc input ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input-lalr.y: warning: 65 shift/reduce conflicts [-Wconflicts-sr] input-lalr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stderr: stdout: ./existing.at:74: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:74: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stdout: ./calc.at:1494: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: cat stderr input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1494: $PREPARSER ./calc input ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: cat stderr 619. existing.at:808: testing GNU Cim Grammar: LALR(1) ... stderr: ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (14.1: ) Entering state 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 620. existing.at:808: testing GNU Cim Grammar: IELR(1) ... ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (14.1: ) Entering state 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) input: input: ./calc.at:1494: cat stderr input: stderr: | (* *) + (*) + (*) ./calc.at:1492: $PREPARSER ./calc input | (1 + 1) / (1 - 1) ./calc.at:1491: $PREPARSER ./calc input | 1 2 ./calc.at:1494: $PREPARSER ./calc input 621. existing.at:808: testing GNU Cim Grammar: Canonical LR(1) ... ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stdout: stderr: ./torture.at:141: $PREPARSER ./input stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token number (1.3: 2) stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./torture.at:141: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 569. calc.at:1494: ok ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 604. torture.at:132: ok ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token number (1.3: 2) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: cat stderr ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: cat stderr 622. existing.at:1460: testing GNU pic (Groff 1.18.1) Grammar: LALR(1) ... ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stderr: ./calc.at:1492: cat stderr 566. calc.at:1491: ok stdout: input: | 1//2 ./existing.at:74: $PREPARSER ./input ./calc.at:1494: $PREPARSER ./calc input stderr: input: ./existing.at:74: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) | 1 + 2 * 3 + !+ ++ ./calc.at:1492: $PREPARSER ./calc input ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror stderr: stdout: ./existing.at:74: $PREPARSER ./input 617. existing.at:74: ok stderr: syntax error, unexpected '*', expecting NEWLINE or '{' or ';' ./existing.at:74: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 623. existing.at:1460: testing GNU pic (Groff 1.18.1) Grammar: IELR(1) ... Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) 616. existing.at:74: ok ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stderr: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input.y:66.10: error: empty rule without %empty [-Werror=empty-rule] input.y:170.10: error: empty rule without %empty [-Werror=empty-rule] input.y:175.10: error: empty rule without %empty [-Werror=empty-rule] input.y:180.10: error: empty rule without %empty [-Werror=empty-rule] input.y:188.10: error: empty rule without %empty [-Werror=empty-rule] input.y:202.10: error: empty rule without %empty [-Werror=empty-rule] input.y:207.10: error: empty rule without %empty [-Werror=empty-rule] input.y:221.10: error: empty rule without %empty [-Werror=empty-rule] input.y:300.10: error: empty rule without %empty [-Werror=empty-rule] input.y:323.10: error: empty rule without %empty [-Werror=empty-rule] input.y: error: 265 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:39.1-5: error: useless associativity for FUNC_CALL, use %precedence [-Werror=precedence] input.y:44.1-5: error: useless associativity for YNUMBER, use %precedence [-Werror=precedence] input.y:44.1-5: error: useless associativity for YSTRING, use %precedence [-Werror=precedence] input.y:42.1-9: error: useless precedence and associativity for APPEND_OP [-Werror=precedence] input.y:33.1-6: error: useless associativity for ASSIGNOP, use %precedence [-Werror=precedence] input.y:43.1-5: error: useless associativity for CONCAT_OP, use %precedence [-Werror=precedence] input.y:37.1-5: error: useless precedence and associativity for LEX_GETLINE [-Werror=precedence] input.y:38.1-9: error: useless associativity for LEX_IN, use %precedence [-Werror=precedence] input.y:49.1-5: error: useless associativity for INCREMENT, use %precedence [-Werror=precedence] input.y:49.1-5: error: useless associativity for DECREMENT, use %precedence [-Werror=precedence] input.y:39.1-5: error: useless associativity for LEX_BUILTIN, use %precedence [-Werror=precedence] input.y:39.1-5: error: useless associativity for LEX_LENGTH, use %precedence [-Werror=precedence] input.y:40.1-9: error: useless precedence and associativity for ',' [-Werror=precedence] input.y:47.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] input.y:47.1-6: error: useless associativity for UNARY, use %precedence [-Werror=precedence] input.y:50.1-5: error: useless associativity for '$', use %precedence [-Werror=precedence] input.y:51.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] input.y:51.1-5: error: useless precedence and associativity for ')' [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] stderr: ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) 624. existing.at:1460: testing GNU pic (Groff 1.18.1) Grammar: Canonical LR(1) ... ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./calc.at:1494: cat stderr input: | 1 + 2 * 3 + !- ++ ./existing.at:74: sed 's,.*/$,,' stderr 1>&2 ./calc.at:1492: $PREPARSER ./calc input input: stderr: | error ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 625. regression.at:25: testing Trivial grammars ... ./regression.at:43: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error Starting parse Entering state 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./regression.at:44: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c 626. regression.at:55: testing YYSTYPE typedef ... ./regression.at:73: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./calc.at:1494: cat stderr ./calc.at:1492: cat stderr stderr: input.y:128.18: error: empty rule without %empty [-Werror=empty-rule] input.y:137.18: error: empty rule without %empty [-Werror=empty-rule] input.y:142.18: error: empty rule without %empty [-Werror=empty-rule] input.y:161.18: error: empty rule without %empty [-Werror=empty-rule] input.y:179.18: error: empty rule without %empty [-Werror=empty-rule] input.y:205.18: error: empty rule without %empty [-Werror=empty-rule] input.y:213.18: error: empty rule without %empty [-Werror=empty-rule] input.y:225.18: error: empty rule without %empty [-Werror=empty-rule] input.y:292.18: error: empty rule without %empty [-Werror=empty-rule] input.y:294.20: error: empty rule without %empty [-Werror=empty-rule] input.y:367.18: error: empty rule without %empty [-Werror=empty-rule] input.y:373.18: error: empty rule without %empty [-Werror=empty-rule] input.y:387.18: error: empty rule without %empty [-Werror=empty-rule] input.y:401.18: error: empty rule without %empty [-Werror=empty-rule] input.y:413.18: error: empty rule without %empty [-Werror=empty-rule] input.y:443.18: error: empty rule without %empty [-Werror=empty-rule] input.y:471.18: error: empty rule without %empty [-Werror=empty-rule] input.y:474.18: error: empty rule without %empty [-Werror=empty-rule] input.y:489.18: error: empty rule without %empty [-Werror=empty-rule] input.y:506.18: error: empty rule without %empty [-Werror=empty-rule] input.y:587.18: error: empty rule without %empty [-Werror=empty-rule] input.y:591.18: error: empty rule without %empty [-Werror=empty-rule] input.y: error: 78 shift/reduce conflicts [-Werror=conflicts-sr] input.y: error: 10 reduce/reduce conflicts [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:72.1-5: error: useless associativity for HQUA, use %precedence [-Werror=precedence] input.y:53.1-6: error: useless associativity for HASSIGN, use %precedence [-Werror=precedence] input.y:54.1-5: error: useless associativity for HORELSE, use %precedence [-Werror=precedence] input.y:55.1-5: error: useless associativity for HANDTHEN, use %precedence [-Werror=precedence] input.y:61.1-5: error: useless associativity for HNOT, use %precedence [-Werror=precedence] input.y:68.1-5: error: useless associativity for UNEAR, use %precedence [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] input: ./existing.at:808: sed 's,.*/$,,' stderr 1>&2 input: ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error | 1 = 2 = 3 | (#) + (#) = 2222 ./calc.at:1494: $PREPARSER ./calc input ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror ./calc.at:1492: $PREPARSER ./calc input ./regression.at:74: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: cat stderr ./calc.at:1494: cat stderr stderr: input.y:128.18: error: empty rule without %empty [-Werror=empty-rule] input.y:137.18: error: empty rule without %empty [-Werror=empty-rule] input.y:142.18: error: empty rule without %empty [-Werror=empty-rule] input.y:161.18: error: empty rule without %empty [-Werror=empty-rule] input.y:179.18: error: empty rule without %empty [-Werror=empty-rule] input.y:205.18: error: empty rule without %empty [-Werror=empty-rule] input.y:213.18: error: empty rule without %empty [-Werror=empty-rule] input.y:225.18: error: empty rule without %empty [-Werror=empty-rule] input.y:292.18: error: empty rule without %empty [-Werror=empty-rule] input.y:294.20: error: empty rule without %empty [-Werror=empty-rule] input.y:367.18: error: empty rule without %empty [-Werror=empty-rule] input.y:373.18: error: empty rule without %empty [-Werror=empty-rule] input.y:387.18: error: empty rule without %empty [-Werror=empty-rule] input.y:401.18: error: empty rule without %empty [-Werror=empty-rule] input.y:413.18: error: empty rule without %empty [-Werror=empty-rule] input.y:443.18: error: empty rule without %empty [-Werror=empty-rule] input.y:471.18: error: empty rule without %empty [-Werror=empty-rule] input.y:474.18: error: empty rule without %empty [-Werror=empty-rule] input.y:489.18: error: empty rule without %empty [-Werror=empty-rule] input.y:506.18: error: empty rule without %empty [-Werror=empty-rule] input.y:587.18: error: empty rule without %empty [-Werror=empty-rule] input.y:591.18: error: empty rule without %empty [-Werror=empty-rule] input.y: error: 78 shift/reduce conflicts [-Werror=conflicts-sr] input.y: error: 10 reduce/reduce conflicts [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:72.1-5: error: useless associativity for HQUA, use %precedence [-Werror=precedence] input.y:53.1-6: error: useless associativity for HASSIGN, use %precedence [-Werror=precedence] input.y:54.1-5: error: useless associativity for HORELSE, use %precedence [-Werror=precedence] input.y:55.1-5: error: useless associativity for HANDTHEN, use %precedence [-Werror=precedence] input.y:61.1-5: error: useless associativity for HNOT, use %precedence [-Werror=precedence] input.y:68.1-5: error: useless associativity for UNEAR, use %precedence [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] stderr: stdout: 626. regression.at:55: ok ./existing.at:808: sed 's,.*/$,,' stderr 1>&2 input: input: stderr: | (1 + #) = 1111 | | +1 ./calc.at:1494: $PREPARSER ./calc input ./calc.at:1492: $PREPARSER ./calc input ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) stdout: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:45: $CC $CFLAGS $CPPFLAGS -c -o input.o -DYYDEBUG -c input.c stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: cat stderr stderr: input.y:202.20: error: empty rule without %empty [-Werror=empty-rule] input.y:270.7: error: empty rule without %empty [-Werror=empty-rule] input.y:292.13: error: empty rule without %empty [-Werror=empty-rule] input.y:309.18: error: empty rule without %empty [-Werror=empty-rule] input.y:382.14: error: empty rule without %empty [-Werror=empty-rule] input.y:471.11-48: error: rule useless in parser due to conflicts [-Werror=other] input.y:154.1-5: error: useless associativity for LABEL, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for VARIABLE, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for NUMBER, use %precedence [-Werror=precedence] input.y:141.1-5: error: useless associativity for TEXT, use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for ORDINAL, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for LAST, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for UP, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for DOWN, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for BOX, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for CIRCLE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ELLIPSE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ARC, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for LINE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ARROW, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for SPLINE, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for HEIGHT, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for RADIUS, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for WIDTH, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for DIAMETER, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for FROM, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for TO, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for AT, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for SOLID [-Werror=precedence] input.y:153.1-5: error: useless associativity for DOTTED, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for DASHED, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for CHOP, use %precedence [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for LJUST [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for RJUST [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for ABOVE [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for BELOW [-Werror=precedence] input.y:176.1-5: error: useless associativity for OF, use %precedence [-Werror=precedence] input.y:176.1-5: error: useless associativity for BETWEEN, use %precedence [-Werror=precedence] input.y:177.1-5: error: useless associativity for AND, use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for HERE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_N, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_E, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_W, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_S, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_NE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_SE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_NW, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_SW, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_C, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for DOT_START, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for DOT_END, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SIN, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for COS, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for ATAN2, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for LOG, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for EXP, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SQRT, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for K_MAX, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for K_MIN, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for INT, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for RAND, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SRAND, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for TOP, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for BOTTOM, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for UPPER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for LOWER, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for LEFT_CORNER, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for RIGHT_CORNER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for NORTH, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for SOUTH, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for EAST, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for WEST, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for CENTER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for END, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for START, use %precedence [-Werror=precedence] input.y:140.1-5: error: useless associativity for PLOT, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for THICKNESS, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for FILL, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for COLORED [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for OUTLINED [-Werror=precedence] input.y:141.1-5: error: useless associativity for SPRINTF, use %precedence [-Werror=precedence] input.y:137.1-5: error: useless associativity for '.', use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for '`', use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for '[', use %precedence [-Werror=precedence] input.y:170.1-5: error: useless associativity for ',', use %precedence [-Werror=precedence] input.y:181.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ./calc.at:1494: $PREPARSER ./calc /dev/null stderr: stderr: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) input.y:202.20: error: empty rule without %empty [-Werror=empty-rule] input.y:270.7: error: empty rule without %empty [-Werror=empty-rule] input.y:292.13: error: empty rule without %empty [-Werror=empty-rule] input.y:309.18: error: empty rule without %empty [-Werror=empty-rule] input.y:382.14: error: empty rule without %empty [-Werror=empty-rule] input.y:471.11-48: error: rule useless in parser due to conflicts [-Werror=other] input.y:154.1-5: error: useless associativity for LABEL, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for VARIABLE, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for NUMBER, use %precedence [-Werror=precedence] input.y:141.1-5: error: useless associativity for TEXT, use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for ORDINAL, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for LAST, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for UP, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for DOWN, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for BOX, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for CIRCLE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ELLIPSE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ARC, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for LINE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ARROW, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for SPLINE, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for HEIGHT, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for RADIUS, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for WIDTH, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for DIAMETER, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for FROM, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for TO, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for AT, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for SOLID [-Werror=precedence] input.y:153.1-5: error: useless associativity for DOTTED, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for DASHED, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for CHOP, use %precedence [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for LJUST [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for RJUST [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for ABOVE [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for BELOW [-Werror=precedence] input.y:176.1-5: error: useless associativity for OF, use %precedence [-Werror=precedence] input.y:176.1-5: error: useless associativity for BETWEEN, use %precedence [-Werror=precedence] input.y:177.1-5: error: useless associativity for AND, use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for HERE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_N, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_E, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_W, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_S, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_NE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_SE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_NW, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_SW, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_C, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for DOT_START, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for DOT_END, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SIN, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for COS, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for ATAN2, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for LOG, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for EXP, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SQRT, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for K_MAX, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for K_MIN, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for INT, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for RAND, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SRAND, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for TOP, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for BOTTOM, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for UPPER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for LOWER, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for LEFT_CORNER, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for RIGHT_CORNER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for NORTH, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for SOUTH, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for EAST, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for WEST, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for CENTER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for END, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for START, use %precedence [-Werror=precedence] input.y:140.1-5: error: useless associativity for PLOT, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for THICKNESS, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for FILL, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for COLORED [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for OUTLINED [-Werror=precedence] input.y:141.1-5: error: useless associativity for SPRINTF, use %precedence [-Werror=precedence] input.y:137.1-5: error: useless associativity for '.', use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for '`', use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for '[', use %precedence [-Werror=precedence] input.y:170.1-5: error: useless associativity for ',', use %precedence [-Werror=precedence] input.y:181.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ./existing.at:1460: sed 's,.*/$,,' stderr 1>&2 ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: cat stderr stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) ./existing.at:1460: sed 's,.*/$,,' stderr 1>&2 627. regression.at:85: testing Early token definitions with --yacc ... ./regression.at:115: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --yacc -o input.c input.y ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error input: | (# + 1) = 1111 ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: $PREPARSER ./calc input stderr: ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./calc.at:1494: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./regression.at:116: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: cat stderr ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./torture.at:394: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./calc.at:1494: cat stderr stdout: input: | (1 + # + 1) = 1111 ./calc.at:1492: $PREPARSER ./calc input 625. regression.at:25: ok ./existing.at:808: sed -n 's/^State //p' input.output | tail -1 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: ./existing.at:808: sed 's/^%define lr.type .*$//' input.y > input-lalr.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 627. regression.at:85: ok ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: cat stderr 628. regression.at:127: testing Early token definitions without --yacc ... ./regression.at:161: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./calc.at:1494: cat stderr input: ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none | (1 + 1) / (1 - 1) input: ./calc.at:1492: $PREPARSER ./calc input stderr: | (- *) + (1 2) = 1 ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: cat stderr ./regression.at:162: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 629. regression.at:173: testing Braces parsing ... stderr: ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./regression.at:185: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: | (* *) + (*) + (*) ./calc.at:1494: $PREPARSER ./calc input input-lalr.y: warning: 78 shift/reduce conflicts [-Wconflicts-sr] input-lalr.y: warning: 10 reduce/reduce conflicts [-Wconflicts-rr] input-lalr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stdout: ./existing.at:808: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./regression.at:187: grep 'tests = {{{{{{{{{{}}}}}}}}}};' input.c stderr: stdout: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) { tests = {{{{{{{{{{}}}}}}}}}}; } 629. regression.at:173: ./calc.at:1492: cat stderr ok ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./existing.at:808: grep '^State.*conflicts:' input.output ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 568. calc.at:1492: ok ./existing.at:808: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./calc.at:1494: cat stderr ./existing.at:808: sed -n 's/^State //p' input.output | tail -1 ./existing.at:808: sed 's/^%define lr.type .*$//' input.y > input-lalr.y ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y stderr: 630. regression.at:196: testing Rule Line Numbers ... input: ./regression.at:232: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -v input.y stdout: | 1 + 2 * 3 + !+ ++ ./calc.at:1494: $PREPARSER ./calc input ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none 628. regression.at:127: ok stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./regression.at:235: cat input.output ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 630. regression.at:196: ok stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none input: 631. regression.at:345: testing Mixing %token styles ... ./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -Wall -o input.c input.y | 1 + 2 * 3 + !- ++ ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -Wall -o input.c input.y -Werror stderr: stdout: stderr: ./existing.at:808: $PREPARSER ./input Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: stderr: ./existing.at:808: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input-lalr.y: warning: 78 shift/reduce conflicts [-Wconflicts-sr] input-lalr.y: warning: 10 reduce/reduce conflicts [-Wconflicts-rr] input-lalr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stdout: ./existing.at:1460: sed -n 's/^State //p' input.output | tail -1 ./existing.at:808: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' 632. regression.at:437: testing Token definitions: parse.error=detailed ... ./existing.at:1460: sed 's/^%define lr.type .*$//' input.y > input-lalr.y ./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o input.c input.y ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y stderr: 619. existing.at:808: ok input.y:3.1-5: error: useless precedence and associativity for "||" [-Werror=precedence] input.y:3.1-5: error: useless precedence and associativity for "<=" [-Werror=precedence] ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./existing.at:808: grep '^State.*conflicts:' input.output ./regression.at:357: sed 's,.*/$,,' stderr 1>&2 633. regression.at:438: testing Token definitions: parse.error=verbose ... ./calc.at:1494: cat stderr ./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o input.c input.y ./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Werror ./existing.at:808: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS input: ./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -Wall -o input.c input.y --warnings=error | (#) + (#) = 2222 ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Werror input.y:26.8-14: error: symbol SPECIAL redeclared [-Werror=other] 26 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" | ^~~~~~~ input.y:25.8-14: note: previous declaration 25 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" | ^~~~~~~ input.y:26.16-63: error: symbol "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" used more than once as a literal string [-Werror=other] 26 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:1460: sed -n 's/^State //p' input.output | tail -1 ./existing.at:1460: sed 's/^%define lr.type .*$//' input.y > input-lalr.y ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y ./regression.at:437: sed 's,.*/$,,' stderr 1>&2 634. regression.at:447: testing Characters Escapes ... stderr: ./regression.at:465: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -Wall -o input.c input.y -Wnone,none -Werror --trace=none stderr: ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: cat stderr ./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=error input.y:26.8-14: error: symbol SPECIAL redeclared [-Werror=other] 26 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" | ^~~~~~~ input.y:25.8-14: note: previous declaration 25 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" | ^~~~~~~ input.y:26.16-63: error: symbol "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" used more than once as a literal string [-Werror=other] 26 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ stderr: input-lalr.y:471.11-48: warning: rule useless in parser due to conflicts [-Wother] stdout: ./existing.at:1460: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' input: | (1 + #) = 1111 ./calc.at:1494: $PREPARSER ./calc input ./regression.at:438: sed 's,.*/$,,' stderr 1>&2 ./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=error ./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -Wall -o input.c input.y --warnings=none -Werror --trace=none ./existing.at:1460: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./regression.at:466: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Wnone,none -Werror --trace=none ./existing.at:808: $PREPARSER ./input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./existing.at:808: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input-lalr.y:471.11-48: warning: rule useless in parser due to conflicts [-Wother] stdout: ./existing.at:1460: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' 631. regression.at:345: ok ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 620. existing.at:808: ok ./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Wnone,none -Werror --trace=none ./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=none -Werror --trace=none ./calc.at:1494: cat stderr stderr: ./existing.at:74: sed -n 's/^State //p' input.output | tail -1 ./existing.at:1460: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: ./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=none -Werror --trace=none input: | (# + 1) = 1111 ./calc.at:1494: $PREPARSER ./calc input 634. regression.at:447: ok stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./regression.at:437: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 635. regression.at:480: testing Web2c Report ... ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:505: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v input.y stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./regression.at:438: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 636. regression.at:661: testing Web2c Actions ... ./regression.at:674: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./existing.at:74: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./regression.at:506: cat input.output stderr: stdout: ./calc.at:1494: cat stderr ./existing.at:1460: $PREPARSER ./input 635. regression.at:480: ok stderr: syntax error, unexpected LEFT ./existing.at:1460: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 622. existing.at:1460: ok 637. regression.at:812: testing Useless Tokens ... ./regression.at:912: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -o input.c input.y input: | (1 + # + 1) = 1111 ./regression.at:679: cat tables.c ./calc.at:1494: $PREPARSER ./calc input stderr: 636. regression.at:661: ok Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./regression.at:917: cat tables.c stderr: stdout: ./regression.at:437: $PREPARSER ./input stderr: 640. regression.at:1145: testing Dancer lalr1.cc ... ./calc.at:1494: cat stderr ./regression.at:1145: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o dancer.cc dancer.y 637. regression.at:812: ok syntax error, unexpected a, expecting ∃¬∩∪∀ ./regression.at:437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 638. regression.at:1143: testing Dancer ... ./regression.at:1143: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o dancer.c dancer.y input: 639. regression.at:1144: testing Dancer %glr-parser ... | (1 + 1) / (1 - 1) ./calc.at:1494: $PREPARSER ./calc input ./regression.at:1144: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o dancer.c dancer.y stderr: 632. regression.at:437: ok Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./regression.at:1145: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o dancer dancer.cc $LIBS ./regression.at:1143: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o dancer dancer.c $LIBS Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./regression.at:1144: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o dancer dancer.c $LIBS ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: cat stderr stderr: stderr: stdout: 641. regression.at:1220: testing Expecting two tokens ... ./regression.at:1220: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o expect2.c expect2.y stdout: ./existing.at:1460: $PREPARSER ./input stderr: ./regression.at:438: $PREPARSER ./input 570. calc.at:1494: ok stderr: 642. regression.at:1221: testing Expecting two tokens %glr-parser ... ./regression.at:1221: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o expect2.c expect2.y ./existing.at:1460: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected a, expecting "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" ./regression.at:438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 623. existing.at:1460: ok 633. regression.at:438: ok ./regression.at:1220: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o expect2 expect2.c $LIBS ./regression.at:1221: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o expect2 expect2.c $LIBS stderr: ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror stdout: ./existing.at:74: $PREPARSER ./input stderr: ./existing.at:74: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 643. regression.at:1222: testing Expecting two tokens lalr1.cc ... ./regression.at:1222: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o expect2.cc expect2.y stderr: stdout: 618. existing.at:74: ok 644. regression.at:1230: testing Braced code in declaration in rules section ... ./regression.at:1143: $PREPARSER ./dancer ./regression.at:1261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: syntax error, unexpected ':' ./regression.at:1143: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 645. regression.at:1291: testing String alias declared after use ... ./regression.at:1304: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./regression.at:1222: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o expect2 expect2.cc $LIBS 638. regression.at:1143: ok ./regression.at:1262: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 645. regression.at:1291: ok stderr: stdout: ./regression.at:1220: $PREPARSER ./expect2 stderr: syntax error, unexpected '+', expecting A or B ./regression.at:1220: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 646. regression.at:1314: testing Extra lookahead sets in report ... ./regression.at:1329: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all input.y 647. regression.at:1355: testing Token number in precedence declaration ... ./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall -o input.c input.y ./regression.at:1330: sed -n '/^State 1$/,/^State 2$/p' input.output 641. regression.at:1220: ok 646. regression.at:1314: ok 648. regression.at:1408: testing parse-gram.y: LALR = IELR ... ./regression.at:1414: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -Dlr.type=lalr input.y ./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y -Werror stderr: input.y:24.5-19: error: rule useless in parser due to conflicts [-Werror=other] input.y:28.5-19: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.1-5: error: useless precedence and associativity for TK1 [-Werror=precedence] stderr: stdout: ./regression.at:1144: $PREPARSER ./dancer ./regression.at:1388: sed 's,.*/$,,' stderr 1>&2 stderr: 649. regression.at:1430: testing parse.error=verbose and YYSTACK_USE_ALLOCA ... syntax error, unexpected ':' ./regression.at:1144: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1481: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 639. regression.at:1144: ok 650. regression.at:1504: testing parse.error=verbose overflow ... ./regression.at:1604: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y --warnings=error ./regression.at:1482: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./regression.at:1611: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y -Wnone,none -Werror --trace=none ./regression.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -Dlr.type=ielr input.y ./regression.at:1221: $PREPARSER ./expect2 stderr: syntax error, unexpected '+', expecting A or B 651. regression.at:1628: testing LAC: Exploratory stack ... ./regression.at:1713: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full \ -Dparse.lac.es-capacity-initial=1 \ -Dparse.lac.memory-trace=full -o input.c input.y ./regression.at:1221: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y --warnings=none -Werror --trace=none ./regression.at:1713: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: 642. regression.at:1221: ok stdout: ./regression.at:1263: $PREPARSER ./input --debug ./regression.at:1393: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reducing stack by rule 1 (line 20): -> $$ = nterm start () Entering state 1 Stack now 0 1 Reading a token Next token is token 'a' (PRINTER) syntax error, unexpected 'a', expecting end of file Error: popping nterm start () Stack now 0 Cleanup: discarding lookahead token 'a' (PRINTER) DESTRUCTOR Stack now 0 ./regression.at:1263: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 644. regression.at:1230: ok stderr: input.y: In function 'yyparse': input.y:59:24: warning: format '%d' expects argument of type 'int', but argument 3 has type 'long int' [-Wformat=] 59 | fprintf (stderr, " yymsg_alloc = %d\n", yymsg_alloc); | ^~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~ | | | long int input.y:60:24: warning: format '%d' expects argument of type 'int', but argument 3 has type 'long int' [-Wformat=] 60 | fprintf (stderr, " YYSTACK_ALLOC_MAXIMUM = %d\n", | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:62:24: warning: format '%d' expects argument of type 'int', but argument 3 has type 'long int' [-Wformat=] 62 | fprintf (stderr, " YYSIZE_MAXIMUM = %d\n", YYSIZE_MAXIMUM); | ^~~~~~~~~~~~~~~~~~~~~~~~~ stdout: ./regression.at:1613: $PREPARSER ./input stderr: syntax error, unexpected 'a', expecting 123456789112345678921234567893123456789412345678951234567896123A or 123456789112345678921234567893123456789412345678951234567896123B or 123456789112345678921234567893123456789412345678951234567896123C syntax error, unexpected 'd' syntax error memory exhausted ./regression.at:1613: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 650. regression.at:1504: ok ./regression.at:1420: diff lalr.c ielr.c 648. regression.at:1408: ok 652. regression.at:1739: testing LAC: Memory exhaustion ... ./regression.at:1771: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -Dparse.lac.es-capacity-initial=1 -o input.c input.y 653. regression.at:1874: testing Lex and parse params: yacc.c ... ./regression.at:1874: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: ./regression.at:1771: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./regression.at:1145: $PREPARSER ./dancer stdout: ./regression.at:1483: $PREPARSER ./input 654. regression.at:1875: testing Lex and parse params: glr.c ... stderr: stderr: syntax error, unexpected 'a', expecting 123456789112345678921234567893123456789412345678951234567896123A or 123456789112345678921234567893123456789412345678951234567896123B syntax error, unexpected end of file, expecting 123456789112345678921234567893123456789412345678951234567896123A or 123456789112345678921234567893123456789412345678951234567896123B ./regression.at:1483: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected ':' ./regression.at:1875: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./regression.at:1145: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1874: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 655. regression.at:1876: testing Lex and parse params: lalr1.cc ... ./regression.at:1876: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 649. regression.at:1430: ok 640. regression.at:1145: ok stderr: ./regression.at:1875: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: ./regression.at:1876: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./regression.at:1394: $PREPARSER ./input stderr: ./regression.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 647. regression.at:1355: ok stderr: stdout: stderr: stdout: ./regression.at:1874: $PREPARSER ./input stderr: ./regression.at:1713: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt ./regression.at:1874: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 653. regression.at:1874: ok stderr: 656. regression.at:1877: testing Lex and parse params: glr.cc ... ./regression.at:1713: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 657. regression.at:1878: testing Lex and parse params: glr2.cc ... ./regression.at:1878: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./regression.at:1713: grep 'syntax error,' stderr.txt 658. regression.at:1889: testing stdio.h is not needed ... ./regression.at:1713: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt ./regression.at:1906: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./regression.at:1877: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./regression.at:1878: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror ./regression.at:1713: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt ./regression.at:1906: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./regression.at:1713: "$PERL" -0777 -ne 'print s/\(realloc//g;' < stderr.txt 659. push.at:25: testing Memory Leak for Early Deletion ... ./push.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: ./regression.at:1222: $PREPARSER ./expect2 stderr: ./regression.at:1714: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full \ -Dparse.lac.es-capacity-initial=1 \ -Dparse.lac.memory-trace=full -o input.c input.y stderr: stdout: ./regression.at:1771: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS syntax error, unexpected '+', expecting A or B ./regression.at:1222: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./push.at:75: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 643. regression.at:1222: ok ./regression.at:1714: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: 658. regression.at:1889: ok 660. push.at:84: testing Multiple impure instances ... ./push.at:134: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./push.at:134: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 661. push.at:145: testing Unsupported Skeletons ... ./push.at:156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: stdout: stderr: input.y:202.20: error: empty rule without %empty [-Werror=empty-rule] input.y:270.7: error: empty rule without %empty [-Werror=empty-rule] input.y:292.13: error: empty rule without %empty [-Werror=empty-rule] input.y:309.18: error: empty rule without %empty [-Werror=empty-rule] input.y:382.14: error: empty rule without %empty [-Werror=empty-rule] input.y:471.11-48: error: rule useless in parser due to conflicts [-Werror=other] input.y:154.1-5: error: useless associativity for LABEL, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for VARIABLE, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for NUMBER, use %precedence [-Werror=precedence] input.y:141.1-5: error: useless associativity for TEXT, use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for ORDINAL, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for LAST, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for UP, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for DOWN, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for BOX, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for CIRCLE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ELLIPSE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ARC, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for LINE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ARROW, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for SPLINE, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for HEIGHT, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for RADIUS, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for WIDTH, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for DIAMETER, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for FROM, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for TO, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for AT, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for SOLID [-Werror=precedence] input.y:153.1-5: error: useless associativity for DOTTED, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for DASHED, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for CHOP, use %precedence [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for LJUST [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for RJUST [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for ABOVE [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for BELOW [-Werror=precedence] input.y:176.1-5: error: useless associativity for OF, use %precedence [-Werror=precedence] input.y:176.1-5: error: useless associativity for BETWEEN, use %precedence [-Werror=precedence] input.y:177.1-5: error: useless associativity for AND, use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for HERE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_N, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_E, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_W, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_S, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_NE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_SE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_NW, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_SW, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_C, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for DOT_START, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for DOT_END, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SIN, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for COS, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for ATAN2, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for LOG, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for EXP, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SQRT, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for K_MAX, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for K_MIN, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for INT, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for RAND, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SRAND, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for TOP, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for BOTTOM, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for UPPER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for LOWER, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for LEFT_CORNER, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for RIGHT_CORNER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for NORTH, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for SOUTH, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for EAST, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for WEST, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for CENTER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for END, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for START, use %precedence [-Werror=precedence] input.y:140.1-5: error: useless associativity for PLOT, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for THICKNESS, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for FILL, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for COLORED [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for OUTLINED [-Werror=precedence] input.y:141.1-5: error: useless associativity for SPRINTF, use %precedence [-Werror=precedence] input.y:137.1-5: error: useless associativity for '.', use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for '`', use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for '[', use %precedence [-Werror=precedence] input.y:170.1-5: error: useless associativity for ',', use %precedence [-Werror=precedence] input.y:181.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ./push.at:76: $PREPARSER ./input stderr: stderr: ./push.at:76: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./regression.at:1875: $PREPARSER ./input stderr: 661. push.at:145: ok ./existing.at:1460: sed 's,.*/$,,' stderr 1>&2 659. push.at:25: ok ./regression.at:1875: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error stderr: stdout: ./regression.at:1772: $PREPARSER ./input --debug stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. LAC: initial context established for "end of file" LAC: checking lookahead "end of file": R2 G3 R2 G5 R2 G6 R2 G7 R2 G8 R2 G9 R2 G10 R2 G11 R2 (max size exceeded) memory exhausted Cleanup: discarding lookahead token "end of file" () Stack now 0 ./regression.at:1772: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 654. regression.at:1875: ok stderr: stdout: ./push.at:134: $PREPARSER ./input stderr: ./push.at:134: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1787: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -Dparse.lac.es-capacity-initial=1 -o input.c input.y ./push.at:135: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 662. push.at:167: testing Pstate reuse ... 663. c++.at:26: testing C++ Locations Unit Tests ... ./push.at:276: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./regression.at:1787: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./regression.at:1714: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./push.at:135: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./regression.at:1714: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1714: grep 'syntax error,' stderr.txt ./push.at:276: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 664. c++.at:107: testing C++ Variant-based Symbols Unit Tests ... ./c++.at:234: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.yy ./regression.at:1714: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./regression.at:1714: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt ======== Testing with C++ standard flags: '' ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./regression.at:1714: "$PERL" -0777 -ne 'print s/\(realloc//g;' < stderr.txt stderr: stdout: ./regression.at:1876: $PREPARSER ./input ./regression.at:1715: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full \ -Dparse.lac.es-capacity-initial=1 \ -Dparse.lac.memory-trace=full -o input.c input.y stderr: stderr: ./regression.at:1876: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./regression.at:1715: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./push.at:135: $PREPARSER ./input stderr: 655. regression.at:1876: ok ./push.at:135: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 660. push.at:84: ok stderr: stdout: 666. c++.at:566: testing Variants lalr1.cc ... ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./push.at:277: ./input stderr: stdout: ./regression.at:1787: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 665. c++.at:247: testing Multiple occurrences of $n and api.value.automove ... ./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.yy 662. push.at:167: ok ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.yy -Werror 667. c++.at:567: testing Variants lalr1.cc parse.assert ... ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: input.yy:16.33-34: error: multiple occurrences of $2 with api.value.automove [-Werror=other] 16 | | "twice" exp { $$ = $2 + $2; } | ^~ input.yy:17.33-36: error: multiple occurrences of $2 with api.value.automove [-Werror=other] 17 | | "thrice" exp[val] { $$ = $2 + $val + $2; } | ^~~~ input.yy:17.40-41: error: multiple occurrences of $2 with api.value.automove [-Werror=other] 17 | | "thrice" exp[val] { $$ = $2 + $val + $2; } | ^~ stderr: ./c++.at:263: sed 's,.*/$,,' stderr 1>&2 stdout: ./regression.at:1877: $PREPARSER ./input stderr: stdout: ./regression.at:1715: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt stderr: stderr: ./regression.at:1715: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1715: grep 'syntax error,' stderr.txt ./regression.at:1715: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt ./regression.at:1715: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt ./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.yy --warnings=error ./regression.at:1877: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1715: "$PERL" -0777 -ne 'print s/\(realloc//g;' < stderr.txt ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS 656. regression.at:1877: ok ./regression.at:1716: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full \ -Dparse.lac.es-capacity-initial=1 \ -Dparse.lac.memory-trace=full -o input.c input.y ./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.yy -Wnone,none -Werror --trace=none stderr: stdout: ./regression.at:1788: $PREPARSER ./input --debug ./regression.at:1716: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" () LAC: initial context established for "invalid token" LAC: checking lookahead "invalid token": Always Err Constructing syntax error message LAC: checking lookahead "end of file": R2 G3 R2 G5 R2 G6 R2 G7 R2 G8 R2 G9 R2 G10 R2 G11 R2 (max size exceeded) syntax error memory exhausted Cleanup: discarding lookahead token "invalid token" () Stack now 0 ./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.yy --warnings=none -Werror --trace=none ./regression.at:1788: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 668. c++.at:568: testing Variants lalr1.cc parse.assert api.value.automove ... ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y 652. regression.at:1739: ok 665. c++.at:247: ok ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS 670. c++.at:570: testing Variants lalr1.cc parse.assert %code {\n#define TWO_STAGE_BUILD\n} ... 669. c++.at:569: testing Variants lalr1.cc parse.assert %locations ... ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./regression.at:1716: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt stderr: ./regression.at:1716: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1716: grep 'syntax error,' stderr.txt ./regression.at:1716: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt ./regression.at:1716: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt ./regression.at:1716: "$PERL" -0777 -ne 'print s/\(realloc//g;' < stderr.txt ./regression.at:1719: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -o input.cc input.y stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./regression.at:1719: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./regression.at:1878: $PREPARSER ./input stderr: ./regression.at:1878: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 657. regression.at:1878: ok stderr: stdout: ./c++.at:235: $PREPARSER ./list stderr: ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS 671. c++.at:571: testing Variants lalr1.cc parse.assert api.token.constructor ... ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: input.y:128.18: error: empty rule without %empty [-Werror=empty-rule] input.y:137.18: error: empty rule without %empty [-Werror=empty-rule] input.y:142.18: error: empty rule without %empty [-Werror=empty-rule] input.y:161.18: error: empty rule without %empty [-Werror=empty-rule] input.y:179.18: error: empty rule without %empty [-Werror=empty-rule] input.y:205.18: error: empty rule without %empty [-Werror=empty-rule] input.y:213.18: error: empty rule without %empty [-Werror=empty-rule] input.y:225.18: error: empty rule without %empty [-Werror=empty-rule] input.y:292.18: error: empty rule without %empty [-Werror=empty-rule] input.y:294.20: error: empty rule without %empty [-Werror=empty-rule] input.y:367.18: error: empty rule without %empty [-Werror=empty-rule] input.y:373.18: error: empty rule without %empty [-Werror=empty-rule] input.y:387.18: error: empty rule without %empty [-Werror=empty-rule] input.y:401.18: error: empty rule without %empty [-Werror=empty-rule] input.y:413.18: error: empty rule without %empty [-Werror=empty-rule] input.y:443.18: error: empty rule without %empty [-Werror=empty-rule] input.y:471.18: error: empty rule without %empty [-Werror=empty-rule] input.y:474.18: error: empty rule without %empty [-Werror=empty-rule] input.y:489.18: error: empty rule without %empty [-Werror=empty-rule] input.y:506.18: error: empty rule without %empty [-Werror=empty-rule] input.y:587.18: error: empty rule without %empty [-Werror=empty-rule] input.y:591.18: error: empty rule without %empty [-Werror=empty-rule] input.y: error: 1876 shift/reduce conflicts [-Werror=conflicts-sr] input.y: error: 144 reduce/reduce conflicts [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:72.1-5: error: useless associativity for HQUA, use %precedence [-Werror=precedence] input.y:53.1-6: error: useless associativity for HASSIGN, use %precedence [-Werror=precedence] input.y:54.1-5: error: useless associativity for HORELSE, use %precedence [-Werror=precedence] input.y:55.1-5: error: useless associativity for HANDTHEN, use %precedence [-Werror=precedence] input.y:61.1-5: error: useless associativity for HNOT, use %precedence [-Werror=precedence] input.y:68.1-5: error: useless associativity for UNEAR, use %precedence [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] stderr: ./existing.at:808: sed 's,.*/$,,' stderr 1>&2 stderr: stdout: ./c++.at:567: $here/modern stdout: Modern C++: 201703 ./c++.at:567: $PREPARSER ./list stderr: stdout: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./regression.at:1719: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error stderr: ./regression.at:1719: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./regression.at:1719: grep 'syntax error,' stderr.txt ./regression.at:1719: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt ./regression.at:1719: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt stderr: ./regression.at:1727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -o input.java input.y stdout: ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none stdout: ./torture.at:395: $PREPARSER ./input stderr: ./torture.at:395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 613. torture.at:385: ok 651. regression.at:1628: skipped (regression.at:1727) 673. c++.at:573: testing Variants lalr1.cc parse.assert api.token.constructor api.token.prefix={TOK_} %locations ... stderr: 672. c++.at:572: testing Variants lalr1.cc parse.assert api.token.constructor api.token.prefix={TOK_} ... ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stdout: stderr: stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:568: $here/modern stdout: Modern C++: 201703 ./c++.at:568: $PREPARSER ./list ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:235: $PREPARSER ./list stderr: ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:566: $here/modern stdout: Modern C++: 201703 ./c++.at:566: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:569: $here/modern stdout: Modern C++: 201703 stderr: ./c++.at:569: $PREPARSER ./list stdout: ./c++.at:570: $here/modern stdout: stderr: Modern C++: 201703 ./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./existing.at:1460: sed -n 's/^State //p' input.output | tail -1 ./existing.at:1460: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./c++.at:571: $here/modern stdout: Modern C++: 201703 ./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:567: $here/modern stdout: Legac++ ./c++.at:567: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:235: $PREPARSER ./list stderr: ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./existing.at:1460: $PREPARSER ./input ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stderr: ./existing.at:1460: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 624. existing.at:1460: ok stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS 674. c++.at:574: testing Variants lalr1.cc parse.assert api.token.constructor api.token.prefix={TOK_} %locations api.value.automove ... stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:566: $here/modern stdout: Legac++ ./c++.at:566: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:573: $here/modern stdout: stderr: Modern C++: 201703 ./c++.at:573: $PREPARSER ./list stderr: stdout: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:572: $here/modern ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stdout: Modern C++: 201703 ./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:568: $here/modern stdout: ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y Legac++ ./c++.at:568: $PREPARSER ./list stderr: ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:570: $here/modern ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stdout: Legac++ ./c++.at:570: $PREPARSER ./list stderr: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:235: $PREPARSER ./list stderr: stderr: ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:569: $here/modern ======== Testing with C++ standard flags: '' stdout: ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS Legac++ ./c++.at:569: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:571: $here/modern stdout: Legac++ ./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:567: $here/modern stdout: Legac++ ./c++.at:567: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:566: $here/modern stdout: Legac++ ./c++.at:566: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stderr: stdout: stdout: ./c++.at:574: $here/modern stdout: stderr: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS Modern C++: 201703 ./c++.at:574: $PREPARSER ./list stdout: stderr: ./c++.at:573: $here/modern Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) stdout: Legac++ ./c++.at:573: $PREPARSER ./list stderr: stderr: stdout: ./c++.at:568: $here/modern ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) Legac++ ./c++.at:568: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:570: $here/modern ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stdout: Legac++ ./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:572: $here/modern stdout: Legac++ ./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:235: $PREPARSER ./list stderr: ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none stderr: stdout: stderr: ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:571: $here/modern stdout: Legac++ ./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) stderr: stdout: ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:566: $here/modern stdout: Modern C++: 201103 ./c++.at:566: $PREPARSER ./list stderr: ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:569: $here/modern stdout: Legac++ ./c++.at:569: $PREPARSER ./list stderr: stderr: stdout: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:567: $here/modern ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: Modern C++: 201103 ./c++.at:567: $PREPARSER ./list ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stderr: stdout: stdout: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:235: $PREPARSER ./list stderr: ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:573: $here/modern stdout: Legac++ ./c++.at:573: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:572: $here/modern stdout: Legac++ ./c++.at:572: $PREPARSER ./list stderr: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: ./c++.at:574: $here/modern stdout: Legac++ ./c++.at:574: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:570: $here/modern stdout: Modern C++: 201103 ./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:568: $here/modern ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stdout: Modern C++: 201103 ./c++.at:568: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 663. c++.at:26: ok 675. c++.at:584: testing Variants and Typed Midrule Actions ... ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:571: $here/modern stdout: Modern C++: 201103 ./c++.at:571: $PREPARSER ./list stderr: ./existing.at:808: sed -n 's/^State //p' input.output | tail -1 Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:235: $PREPARSER ./list stderr: ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:808: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ======== Testing with C++ standard flags: '' ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: stderr: stdout: ./c++.at:567: $here/modern stdout: ./c++.at:566: $here/modern Modern C++: 201402 ./c++.at:567: $PREPARSER ./list stderr: stdout: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) Modern C++: 201402 ./c++.at:566: $PREPARSER ./list ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:569: $here/modern stdout: Modern C++: 201103 ./c++.at:569: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./existing.at:808: $PREPARSER ./input stderr: ./existing.at:808: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 621. existing.at:808: ok stderr: stdout: ./c++.at:572: $here/modern stdout: Modern C++: 201103 ./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y 676. c++.at:794: testing Doxygen Public Documentation ... stderr: ./c++.at:794: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stdout: ./c++.at:573: $here/modern ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: Modern C++: 201103 ./c++.at:573: $PREPARSER ./list stderr: stderr: stdout: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:659: $PREPARSER ./input stderr: ./c++.at:794: doxygen --version || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y --- /dev/null 2026-03-27 17:47:36.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/676/stderr 2026-03-27 18:45:36.501669377 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/676/test-source: line 180: doxygen: command not found stdout: 676. c++.at:794: skipped (c++.at:794) ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:570: $here/modern stdout: Modern C++: 201402 ./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) stderr: stdout: ./c++.at:574: $here/modern ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: 677. c++.at:795: testing Doxygen Private Documentation ... Legac++ ./c++.at:574: $PREPARSER ./list stderr: ./c++.at:795: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:795: doxygen --version || exit 77 ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y --- /dev/null 2026-03-27 17:47:36.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/677/stderr 2026-03-27 18:45:36.757669377 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/677/test-source: line 180: doxygen: command not found stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS 677. c++.at:795: skipped (c++.at:795) stderr: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: ./c++.at:568: $here/modern stdout: Modern C++: 201402 ./c++.at:568: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y 678. c++.at:848: testing Relative namespace references ... ./c++.at:849: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:571: $here/modern stderr: stdout: stdout: Modern C++: 201402 ./c++.at:566: $here/modern ./c++.at:571: $PREPARSER ./list stdout: Modern C++: 201703 ./c++.at:566: $PREPARSER ./list stderr: stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:235: $PREPARSER ./list stderr: ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS 664. c++.at:107: ok stderr: stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 679. c++.at:854: testing Absolute namespace references ... ./c++.at:855: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stderr: stdout: ./c++.at:567: $here/modern stdout: Modern C++: 201703 ./c++.at:567: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:569: $here/modern stdout: Modern C++: 201402 ./c++.at:569: $PREPARSER ./list ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: stderr: ./c++.at:659: $PREPARSER ./input stdout: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:572: $here/modern stdout: Modern C++: 201402 ./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stderr: stdout: ./c++.at:849: $PREPARSER ./input stdout: stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:573: $here/modern stdout: Modern C++: 201402 stderr: ./c++.at:573: $PREPARSER ./list stdout: stderr: ./c++.at:855: $PREPARSER ./input Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) stderr: ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:570: $here/modern stdout: Modern C++: 201703 ./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:574: $here/modern stdout: Modern C++: 201103 ./c++.at:574: $PREPARSER ./list stderr: stderr: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) stdout: ./c++.at:568: $here/modern ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: Modern C++: 201703 ./c++.at:568: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: stderr: stdout: ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:659: $PREPARSER ./input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./c++.at:855: $PREPARSER ./input stderr: ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:571: $here/modern stdout: Modern C++: 201703 ./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:855: $PREPARSER ./input stderr: ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:569: $here/modern stdout: stderr: Modern C++: 201703 ./c++.at:569: $PREPARSER ./list stdout: ./c++.at:567: $here/modern stdout: stderr: Modern C++: 202002 ./c++.at:567: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:566: $here/modern stdout: ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS Modern C++: 202002 ./c++.at:566: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:572: $here/modern stdout: Modern C++: 201703 ./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:659: $PREPARSER ./input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 stderr: ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:573: $here/modern stdout: Modern C++: 201703 ./c++.at:573: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:855: $PREPARSER ./input stderr: ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:574: $here/modern stdout: Modern C++: 201402 ./c++.at:574: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:855: $PREPARSER ./input stderr: ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:570: $here/modern stdout: Modern C++: 202002 ./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:659: $PREPARSER ./input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:571: $here/modern stdout: Modern C++: 202002 ./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:568: $here/modern stdout: Modern C++: 202002 ./c++.at:568: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:855: $PREPARSER ./input stderr: ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:569: $here/modern stdout: Modern C++: 202002 ./c++.at:569: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:855: $PREPARSER ./input stderr: ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:574: $here/modern ======== Testing with C++ standard flags: '' stdout: ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS Modern C++: 201703 ./c++.at:574: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: stderr: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stdout: ./c++.at:659: $PREPARSER ./input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:573: $here/modern stdout: Modern C++: 202002 ./c++.at:573: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:850: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ======== Testing with C++ standard flags: '' ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:567: $here/modern stdout: Modern C++: 202302 ./c++.at:567: $PREPARSER ./list stderr: stderr: stdout: ./c++.at:572: $here/modern stdout: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) Modern C++: 202002 ./c++.at:572: $PREPARSER ./list stderr: ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 667. c++.at:567: ok ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS 680. c++.at:863: testing Syntactically invalid namespace references ... ./c++.at:864: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ./c++.at:865: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ./c++.at:868: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stderr: stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:869: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ./c++.at:870: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stderr: stdout: ./c++.at:855: $PREPARSER ./input stderr: stderr: ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: 680. c++.at:863: ok stderr: ./c++.at:856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 681. c++.at:884: testing Syntax error discarding no lookahead ... ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:566: $here/modern stdout: Modern C++: 202302 ./c++.at:566: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 666. c++.at:566: ok stderr: stdout: ./c++.at:850: $PREPARSER ./input stderr: ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:659: $PREPARSER ./input 682. c++.at:1064: testing Syntax error as exception: lalr1.cc ... ./c++.at:1064: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ======== Testing with C++ standard flags: '' ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:856: $PREPARSER ./input stderr: ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:850: $PREPARSER ./input stderr: ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:570: $here/modern stdout: Modern C++: 202302 ./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 670. c++.at:570: ok stderr: stdout: ./c++.at:571: $here/modern stderr: stdout: Modern C++: 202302 stdout: ./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:568: $here/modern stdout: ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Modern C++: 202302 ./c++.at:568: $PREPARSER ./list 671. c++.at:571: ok stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 683. c++.at:1065: testing Syntax error as exception: glr.cc ... ./c++.at:1065: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy 668. c++.at:568: ok 684. c++.at:1066: testing Syntax error as exception: glr2.cc ... ./c++.at:1066: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ======== Testing with C++ standard flags: '' ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS 685. c++.at:1360: testing Exception safety with error recovery ... ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o exceptions exceptions.cc $LIBS stderr: stdout: ./c++.at:574: $here/modern stdout: Modern C++: 202002 ./c++.at:574: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ======== Testing with C++ standard flags: '' ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:1066: ./check ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: ./c++.at:856: $PREPARSER ./input stderr: ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:941: $PREPARSER ./input stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:850: $PREPARSER ./input stderr: ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: ./c++.at:1360: ./exceptions || exit 77 stderr: Inner caught Outer caught ./c++.at:1360: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc --report=all input.yy ======== Testing with C++ standard flags: '' ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: ./c++.at:856: $PREPARSER ./input stderr: ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:659: $PREPARSER ./input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:573: $here/modern stdout: Modern C++: 202302 ./c++.at:573: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 673. c++.at:573: ok 675. c++.at:584: ok 686. c++.at:1361: testing Exception safety without error recovery ... ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o exceptions exceptions.cc $LIBS 687. c++.at:1362: testing Exception safety with error recovery api.value.type=variant ... ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o exceptions exceptions.cc $LIBS stderr: stdout: ./c++.at:850: $PREPARSER ./input stderr: ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:856: $PREPARSER ./input stderr: ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stderr: stdout: ./c++.at:941: $PREPARSER ./input stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:569: $here/modern stdout: ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS Modern C++: 202302 ./c++.at:569: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 669. c++.at:569: ok stderr: stdout: ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in 688. c++.at:1363: testing Exception safety without error recovery api.value.type=variant ... stderr: error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o exceptions exceptions.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: ./c++.at:1362: ./exceptions || exit 77 stderr: Inner caught Outer caught ./c++.at:1362: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc --report=all input.yy stderr: stdout: ./c++.at:1361: ./exceptions || exit 77 stderr: Inner caught Outer caught ./c++.at:1361: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc --report=all input.yy ======== Testing with C++ standard flags: '' ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:850: $PREPARSER ./input stderr: ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in ======== Testing with C++ standard flags: '' ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: ./c++.at:941: $PREPARSER ./input stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:572: $here/modern stdout: Modern C++: 202302 ./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1363: ./exceptions || exit 77 stderr: Inner caught Outer caught ./c++.at:1363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc --report=all input.yy stderr: stdout: ./c++.at:1360: $PREPARSER ./input aaaas stderr: 672. c++.at:572: ok exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 689. c++.at:1371: testing C++ GLR parser identifier shadowing ... ./c++.at:1410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ./c++.at:1360: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:856: $PREPARSER ./input ./c++.at:1360: $PREPARSER ./input aaaap ======== Testing with C++ standard flags: '' stderr: ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1360: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaf2a7af40->Object::Object { } Next token is token 'a' (0xaaaaf2a7af40 'a') Shifting token 'a' (0xaaaaf2a7af40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf2a7af40 'a') -> $$ = nterm item (0xaaaaf2a7af40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaaf2a7af90->Object::Object { 0xaaaaf2a7af40 } Next token is token 'a' (0xaaaaf2a7af90 'a') Shifting token 'a' (0xaaaaf2a7af90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf2a7af90 'a') -> $$ = nterm item (0xaaaaf2a7af90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaaf2a7afe0->Object::Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90 } Next token is token 'a' (0xaaaaf2a7afe0 'a') Shifting token 'a' (0xaaaaf2a7afe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf2a7afe0 'a') -> $$ = nterm item (0xaaaaf2a7afe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaaf2a7b030->Object::Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0 } Next token is token 'a' (0xaaaaf2a7b030 'a') Shifting token 'a' (0xaaaaf2a7b030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf2a7b030 'a') -> $$ = nterm item (0xaaaaf2a7b030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaaf2a7b080->Object::Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0, 0xaaaaf2a7b030 } Next token is token 'p' (0xaaaaf2a7b080 'p'Exception caught: cleaning lookahead and stack 0xaaaaf2a7b080->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0, 0xaaaaf2a7b030, 0xaaaaf2a7b080 } 0xaaaaf2a7b030->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0, 0xaaaaf2a7b030 } 0xaaaaf2a7afe0->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0 } 0xaaaaf2a7af90->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90 } 0xaaaaf2a7af40->Object::~Object { 0xaaaaf2a7af40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaf2a7af40->Object::Object { } Next token is token 'a' (0xaaaaf2a7af40 'a') Shifting token 'a' (0xaaaaf2a7af40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf2a7af40 'a') -> $$ = nterm item (0xaaaaf2a7af40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaaf2a7af90->Object::Object { 0xaaaaf2a7af40 } Next token is token 'a' (0xaaaaf2a7af90 'a') Shifting token 'a' (0xaaaaf2a7af90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf2a7af90 'a') -> $$ = nterm item (0xaaaaf2a7af90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaaf2a7afe0->Object::Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90 } Next token is token 'a' (0xaaaaf2a7afe0 'a') Shifting token 'a' (0xaaaaf2a7afe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf2a7afe0 'a') -> $$ = nterm item (0xaaaaf2a7afe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaaf2a7b030->Object::Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0 } Next token is token 'a' (0xaaaaf2a7b030 'a') Shifting token 'a' (0xaaaaf2a7b030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf2a7b030 'a') -> $$ = nterm item (0xaaaaf2a7b030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaaf2a7b080->Object::Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0, 0xaaaaf2a7b030 } Next token is token 'p' (0xaaaaf2a7b080 'p'Exception caught: cleaning lookahead and stack 0xaaaaf2a7b080->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0, 0xaaaaf2a7b030, 0xaaaaf2a7b080 } 0xaaaaf2a7b030->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0, 0xaaaaf2a7b030 } 0xaaaaf2a7afe0->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0 } 0xaaaaf2a7af90->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90 } 0xaaaaf2a7af40->Object::~Object { 0xaaaaf2a7af40 } exception caught: printer end { } ./c++.at:1360: grep '^exception caught: printer$' stderr stdout: stdout: exception caught: printer ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:1360: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaT ./c++.at:1064: $PREPARSER ./input < in stderr: stderr: error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: ./c++.at:1360: $PREPARSER ./input aaaaR stdout: ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ./c++.at:850: $PREPARSER ./input stderr: stderr: ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stderr: stdout: ./c++.at:1361: $PREPARSER ./input aaaas stderr: stderr: exception caught: reduction ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stdout: ./c++.at:1065: $PREPARSER ./input < in ./c++.at:1361: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: ./check ./c++.at:1361: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -std=c++98 not supported ======== Testing with C++ standard flags: '' ./c++.at:1361: $PREPARSER ./input aaaap stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae906cf40->Object::Object { } Next token is token 'a' (0xaaaae906cf40 'a') Shifting token 'a' (0xaaaae906cf40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae906cf40 'a') -> $$ = nterm item (0xaaaae906cf40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaae906cf90->Object::Object { 0xaaaae906cf40 } Next token is token 'a' (0xaaaae906cf90 'a') Shifting token 'a' (0xaaaae906cf90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae906cf90 'a') -> $$ = nterm item (0xaaaae906cf90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaae906cfe0->Object::Object { 0xaaaae906cf40, 0xaaaae906cf90 } Next token is token 'a' (0xaaaae906cfe0 'a') Shifting token 'a' (0xaaaae906cfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae906cfe0 'a') -> $$ = nterm item (0xaaaae906cfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaae906d030->Object::Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0 } Next token is token 'a' (0xaaaae906d030 'a') Shifting token 'a' (0xaaaae906d030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae906d030 'a') -> $$ = nterm item (0xaaaae906d030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaae906d080->Object::Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0, 0xaaaae906d030 } Next token is token 'p' (0xaaaae906d080 'p'Exception caught: cleaning lookahead and stack 0xaaaae906d080->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0, 0xaaaae906d030, 0xaaaae906d080 } 0xaaaae906d030->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0, 0xaaaae906d030 } 0xaaaae906cfe0->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0 } 0xaaaae906cf90->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90 } 0xaaaae906cf40->Object::~Object { 0xaaaae906cf40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae906cf40->Object::Object { } Next token is token 'a' (0xaaaae906cf40 'a') Shifting token 'a' (0xaaaae906cf40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae906cf40 'a') -> $$ = nterm item (0xaaaae906cf40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaae906cf90->Object::Object { 0xaaaae906cf40 } Next token is token 'a' (0xaaaae906cf90 'a') Shifting token 'a' (0xaaaae906cf90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae906cf90 'a') -> $$ = nterm item (0xaaaae906cf90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaae906cfe0->Object::Object { 0xaaaae906cf40, 0xaaaae906cf90 } Next token is token 'a' (0xaaaae906cfe0 'a') Shifting token 'a' (0xaaaae906cfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae906cfe0 'a') -> $$ = nterm item (0xaaaae906cfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaae906d030->Object::Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0 } Next token is token 'a' (0xaaaae906d030 'a') Shifting token 'a' (0xaaaae906d030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae906d030 'a') -> $$ = nterm item (0xaaaae906d030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaae906d080->Object::Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0, 0xaaaae906d030 } Next token is token 'p' (0xaaaae906d080 'p'Exception caught: cleaning lookahead and stack 0xaaaae906d080->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0, 0xaaaae906d030, 0xaaaae906d080 } 0xaaaae906d030->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0, 0xaaaae906d030 } 0xaaaae906cfe0->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0 } 0xaaaae906cf90->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90 } 0xaaaae906cf40->Object::~Object { 0xaaaae906cf40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1361: $PREPARSER ./input aaaae ./c++.at:1065: $PREPARSER ./input < in stderr: exception caught: syntax error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS error: invalid expression ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in stderr: ./c++.at:1361: $PREPARSER ./input aaaaT error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1361: $PREPARSER ./input aaaaR ./c++.at:1066: ./check stderr: -std=c++03 not supported ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:856: $PREPARSER ./input stderr: stdout: ./c++.at:1362: $PREPARSER ./input aaaas stderr: ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1362: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1362: $PREPARSER ./input i stdout: stderr: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: ./check stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ./c++.at:1362: $PREPARSER ./input aaaap stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffea093d10->Object::Object { } 0xffffea093e10->Object::Object { 0xffffea093d10 } 0xffffea093d10->Object::~Object { 0xffffea093d10, 0xffffea093e10 } Next token is token 'a' (0xffffea093e10 'a') 0xffffea093d50->Object::Object { 0xffffea093e10 } 0xffffea093e10->Object::~Object { 0xffffea093d50, 0xffffea093e10 } Shifting token 'a' (0xffffea093d50 'a') 0xaaab0a89d2e0->Object::Object { 0xffffea093d50 } 0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xffffea093d50 } Entering state 2 Stack now 0 2 0xffffea093e30->Object::Object { 0xaaab0a89d2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0a89d2e0 'a') -> $$ = nterm item (0xffffea093e30 'a') 0xaaab0a89d2e0->Object::~Object { 0xaaab0a89d2e0, 0xffffea093e30 } 0xaaab0a89d2e0->Object::Object { 0xffffea093e30 } 0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xffffea093e30 } Entering state 11 Stack now 0 11 Reading a token 0xffffea093d10->Object::Object { 0xaaab0a89d2e0 } 0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xffffea093d10 } 0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xffffea093d10, 0xffffea093e10 } Next token is token 'a' (0xffffea093e10 'a') 0xffffea093d50->Object::Object { 0xaaab0a89d2e0, 0xffffea093e10 } 0xffffea093e10->Object::~Object { 0xaaab0a89d2e0, 0xffffea093d50, 0xffffea093e10 } Shifting token 'a' (0xffffea093d50 'a') 0xaaab0a89d300->Object::Object { 0xaaab0a89d2e0, 0xffffea093d50 } 0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d50 } Entering state 2 Stack now 0 11 2 0xffffea093e30->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0a89d300 'a') -> $$ = nterm item (0xffffea093e30 'a') 0xaaab0a89d300->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e30 } 0xaaab0a89d300->Object::Object { 0xaaab0a89d2e0, 0xffffea093e30 } 0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e30 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffea093d10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300 } 0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d10 } 0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d10, 0xffffea093e10 } Next token is token 'a' (0xffffea093e10 'a') 0xffffea093d50->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e10 } 0xffffea093e10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d50, 0xffffea093e10 } Shifting token 'a' (0xffffea093d50 'a') 0xaaab0a89d320->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d50 } 0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d50 } Entering state 2 Stack now 0 11 11 2 0xffffea093e30->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0a89d320 'a') -> $$ = nterm item (0xffffea093e30 'a') 0xaaab0a89d320->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e30 } 0xaaab0a89d320->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e30 } 0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e30 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffea093d10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320 } 0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d10 } 0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d10, 0xffffea093e10 } Next token is token 'a' (0xffffea093e10 'a') 0xffffea093d50->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e10 } 0xffffea093e10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d50, 0xffffea093e10 } Shifting token 'a' (0xffffea093d50 'a') 0xaaab0a89d340->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d50 } 0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093d50 } Entering state 2 Stack now 0 11 11 11 2 0xffffea093e30->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0a89d340 'a') -> $$ = nterm item (0xffffea093e30 'a') 0xaaab0a89d340->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093e30 } 0xaaab0a89d340->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e30 } 0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093e30 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffea093d10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340 } 0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093d10 } 0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093d10, 0xffffea093e10 } Next token is token 'p' (0xffffea093e10 'p'Exception caught: cleaning lookahead and stack 0xaaab0a89d340->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093e10 } 0xaaab0a89d320->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e10 } 0xaaab0a89d300->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e10 } 0xaaab0a89d2e0->Object::~Object { 0xaaab0a89d2e0, 0xffffea093e10 } 0xffffea093e10->Object::~Object { 0xffffea093e10 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffea093d10->Object::Object { } 0xffffea093e10->Object::Object { 0xffffea093d10 } 0xffffea093d10->Object::~Object { 0xffffea093d10, 0xffffea093e10 } Next token is token 'a' (0xffffea093e10 'a') 0xffffea093d50->Object::Object { 0xffffea093e10 } 0xffffea093e10->Object::~Object { 0xffffea093d50, 0xffffea093e10 } Shifting token 'a' (0xffffea093d50 'a') 0xaaab0a89d2e0->Object::Object { 0xffffea093d50 } 0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xffffea093d50 } Entering state 2 Stack now 0 2 0xffffea093e30->Object::Object { 0xaaab0a89d2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0a89d2e0 'a') -> $$ = nterm item (0xffffea093e30 'a') 0xaaab0a89d2e0->Object::~Object { 0xaaab0a89d2e0, 0xffffea093e30 } 0xaaab0a89d2e0->Object::Object { 0xffffea093e30 } 0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xffffea093e30 } Entering state 11 Stack now 0 11 Reading a token 0xffffea093d10->Object::Object { 0xaaab0a89d2e0 } 0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xffffea093d10 } 0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xffffea093d10, 0xffffea093e10 } Next token is token 'a' (0xffffea093e10 'a') 0xffffea093d50->Object::Object { 0xaaab0a89d2e0, 0xffffea093e10 } 0xffffea093e10->Object::~Object { 0xaaab0a89d2e0, 0xffffea093d50, 0xffffea093e10 } Shifting token 'a' (0xffffea093d50 'a') 0xaaab0a89d300->Object::Object { 0xaaab0a89d2e0, 0xffffea093d50 } 0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d50 } Entering state 2 Stack now 0 11 2 0xffffea093e30->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0a89d300 'a') -> $$ = nterm item (0xffffea093e30 'a') 0xaaab0a89d300->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e30 } 0xaaab0a89d300->Object::Object { 0xaaab0a89d2e0, 0xffffea093e30 } 0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e30 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffea093d10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300 } 0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d10 } 0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d10, 0xffffea093e10 } Next token is token 'a' (0xffffea093e10 'a') 0xffffea093d50->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e10 } 0xffffea093e10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d50, 0xffffea093e10 } Shifting token 'a' (0xffffea093d50 'a') 0xaaab0a89d320->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d50 } 0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d50 } Entering state 2 Stack now 0 11 11 2 0xffffea093e30->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0a89d320 'a') -> $$ = nterm item (0xffffea093e30 'a') 0xaaab0a89d320->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e30 } 0xaaab0a89d320->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e30 } 0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e30 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffea093d10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320 } 0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d10 } 0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d10, 0xffffea093e10 } Next token is token 'a' (0xffffea093e10 'a') 0xffffea093d50->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e10 } 0xffffea093e10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d50, 0xffffea093e10 } Shifting token 'a' (0xffffea093d50 'a') 0xaaab0a89d340->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d50 } 0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093d50 } Entering state 2 Stack now 0 11 11 11 2 0xffffea093e30->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0a89d340 'a') -> $$ = nterm item (0xffffea093e30 'a') 0xaaab0a89d340->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093e30 } 0xaaab0a89d340->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e30 } 0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093e30 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffea093d10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340 } 0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093d10 } 0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093d10, 0xffffea093e10 } Next token is token 'p' (0xffffea093e10 'p'Exception caught: cleaning lookahead and stack 0xaaab0a89d340->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093e10 } 0xaaab0a89d320->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e10 } 0xaaab0a89d300->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e10 } 0xaaab0a89d2e0->Object::~Object { 0xaaab0a89d2e0, 0xffffea093e10 } 0xffffea093e10->Object::~Object { 0xffffea093e10 } exception caught: printer end { } ./c++.at:1362: grep '^exception caught: printer$' stderr stderr: stdout: exception caught: printer stdout: ./c++.at:1362: $PREPARSER ./input aaaae ./c++.at:941: $PREPARSER ./input stderr: stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:1362: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:574: $here/modern stdout: Modern C++: 202302 ./c++.at:574: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) stderr: ./c++.at:1362: $PREPARSER ./input aaaaT stdout: ./c++.at:850: $PREPARSER ./input stderr: ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 674. c++.at:574: ok ./c++.at:1362: $PREPARSER ./input aaaaR stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 690. c++.at:1422: testing Shared locations ... ./c++.at:1456: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o x1.cc x1.yy stderr: ./c++.at:1456: $CXX $CPPFLAGS $CXXFLAGS -Iinclude -c -o x1.o x1.cc stdout: ./c++.at:1363: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaap stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffffe9d2010->Object::Object { } 0xfffffe9d2110->Object::Object { 0xfffffe9d2010 } 0xfffffe9d2010->Object::~Object { 0xfffffe9d2010, 0xfffffe9d2110 } Next token is token 'a' (0xfffffe9d2110 'a') 0xfffffe9d2050->Object::Object { 0xfffffe9d2110 } 0xfffffe9d2110->Object::~Object { 0xfffffe9d2050, 0xfffffe9d2110 } Shifting token 'a' (0xfffffe9d2050 'a') 0xaaab0764b2e0->Object::Object { 0xfffffe9d2050 } 0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2050 } Entering state 1 Stack now 0 1 0xfffffe9d2130->Object::Object { 0xaaab0764b2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0764b2e0 'a') -> $$ = nterm item (0xfffffe9d2130 'a') 0xaaab0764b2e0->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2130 } 0xaaab0764b2e0->Object::Object { 0xfffffe9d2130 } 0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2130 } Entering state 10 Stack now 0 10 Reading a token 0xfffffe9d2010->Object::Object { 0xaaab0764b2e0 } 0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2010 } 0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2010, 0xfffffe9d2110 } Next token is token 'a' (0xfffffe9d2110 'a') 0xfffffe9d2050->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2110 } 0xfffffe9d2110->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2050, 0xfffffe9d2110 } Shifting token 'a' (0xfffffe9d2050 'a') 0xaaab0764b300->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2050 } 0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2050 } Entering state 1 Stack now 0 10 1 0xfffffe9d2130->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0764b300 'a') -> $$ = nterm item (0xfffffe9d2130 'a') 0xaaab0764b300->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2130 } 0xaaab0764b300->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2130 } 0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2130 } Entering state 10 Stack now 0 10 10 Reading a token 0xfffffe9d2010->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300 } 0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2010 } 0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2010, 0xfffffe9d2110 } Next token is token 'a' (0xfffffe9d2110 'a') 0xfffffe9d2050->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2110 } 0xfffffe9d2110->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2050, 0xfffffe9d2110 } Shifting token 'a' (0xfffffe9d2050 'a') 0xaaab0764b320->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2050 } 0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2050 } Entering state 1 Stack now 0 10 10 1 0xfffffe9d2130->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0764b320 'a') -> $$ = nterm item (0xfffffe9d2130 'a') 0xaaab0764b320->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2130 } 0xaaab0764b320->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2130 } 0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2130 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xfffffe9d2010->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320 } 0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2010 } 0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2010, 0xfffffe9d2110 } Next token is token 'a' (0xfffffe9d2110 'a') 0xfffffe9d2050->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2110 } 0xfffffe9d2110->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2050, 0xfffffe9d2110 } Shifting token 'a' (0xfffffe9d2050 'a') 0xaaab0764b340->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2050 } 0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2050 } Entering state 1 Stack now 0 10 10 10 1 0xfffffe9d2130->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0764b340 'a') -> $$ = nterm item (0xfffffe9d2130 'a') 0xaaab0764b340->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2130 } 0xaaab0764b340->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2130 } 0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2130 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xfffffe9d2010->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340 } 0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2010 } 0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2010, 0xfffffe9d2110 } Next token is token 'p' (0xfffffe9d2110 'p'Exception caught: cleaning lookahead and stack 0xaaab0764b340->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2110 } 0xaaab0764b320->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2110 } 0xaaab0764b300->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2110 } 0xaaab0764b2e0->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2110 } 0xfffffe9d2110->Object::~Object { 0xfffffe9d2110 } exception caught: printer end { } ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffffe9d2010->Object::Object { } 0xfffffe9d2110->Object::Object { 0xfffffe9d2010 } 0xfffffe9d2010->Object::~Object { 0xfffffe9d2010, 0xfffffe9d2110 } Next token is token 'a' (0xfffffe9d2110 'a') 0xfffffe9d2050->Object::Object { 0xfffffe9d2110 } 0xfffffe9d2110->Object::~Object { 0xfffffe9d2050, 0xfffffe9d2110 } Shifting token 'a' (0xfffffe9d2050 'a') 0xaaab0764b2e0->Object::Object { 0xfffffe9d2050 } 0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2050 } Entering state 1 Stack now 0 1 0xfffffe9d2130->Object::Object { 0xaaab0764b2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0764b2e0 'a') -> $$ = nterm item (0xfffffe9d2130 'a') 0xaaab0764b2e0->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2130 } 0xaaab0764b2e0->Object::Object { 0xfffffe9d2130 } 0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2130 } Entering state 10 Stack now 0 10 Reading a token 0xfffffe9d2010->Object::Object { 0xaaab0764b2e0 } 0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2010 } 0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2010, 0xfffffe9d2110 } Next token is token 'a' (0xfffffe9d2110 'a') 0xfffffe9d2050->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2110 } 0xfffffe9d2110->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2050, 0xfffffe9d2110 } Shifting token 'a' (0xfffffe9d2050 'a') 0xaaab0764b300->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2050 } 0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2050 } Entering state 1 Stack now 0 10 1 0xfffffe9d2130->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0764b300 'a') -> $$ = nterm item (0xfffffe9d2130 'a') 0xaaab0764b300->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2130 } 0xaaab0764b300->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2130 } 0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2130 } Entering state 10 Stack now 0 10 10 Reading a token 0xfffffe9d2010->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300 } 0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2010 } 0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2010, 0xfffffe9d2110 } Next token is token 'a' (0xfffffe9d2110 'a') 0xfffffe9d2050->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2110 } 0xfffffe9d2110->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2050, 0xfffffe9d2110 } Shifting token 'a' (0xfffffe9d2050 'a') 0xaaab0764b320->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2050 } 0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2050 } Entering state 1 Stack now 0 10 10 1 0xfffffe9d2130->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0764b320 'a') -> $$ = nterm item (0xfffffe9d2130 'a') 0xaaab0764b320->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2130 } 0xaaab0764b320->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2130 } 0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2130 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xfffffe9d2010->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320 } 0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2010 } 0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2010, 0xfffffe9d2110 } Next token is token 'a' (0xfffffe9d2110 'a') 0xfffffe9d2050->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2110 } 0xfffffe9d2110->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2050, 0xfffffe9d2110 } Shifting token 'a' (0xfffffe9d2050 'a') 0xaaab0764b340->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2050 } 0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2050 } Entering state 1 Stack now 0 10 10 10 1 0xfffffe9d2130->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0764b340 'a') -> $$ = nterm item (0xfffffe9d2130 'a') 0xaaab0764b340->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2130 } 0xaaab0764b340->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2130 } 0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2130 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xfffffe9d2010->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340 } 0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2010 } 0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2010, 0xfffffe9d2110 } Next token is token 'p' (0xfffffe9d2110 'p'Exception caught: cleaning lookahead and stack 0xaaab0764b340->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2110 } 0xaaab0764b320->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2110 } 0xaaab0764b300->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2110 } 0xaaab0764b2e0->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2110 } 0xfffffe9d2110->Object::~Object { 0xfffffe9d2110 } exception caught: printer end { } ./c++.at:1363: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1363: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: $PREPARSER ./input aaaaE stderr: stdout: stderr: exception caught: syntax error, unexpected end of file, expecting 'a' stdout: ./c++.at:1064: $PREPARSER ./input < in ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaas stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: stderr: error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1363: $PREPARSER ./input aaaaT ======== Testing with C++ standard flags: '' ./c++.at:1064: $PREPARSER ./input < in stderr: ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaal ======== Testing with C++ standard flags: '' ./c++.at:1363: $PREPARSER ./input aaaaR ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stderr: exception caught: yylex ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1360: $PREPARSER ./input i ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: exception caught: initial-action ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaap stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaab0a588f40->Object::Object { } Next token is token 'a' (0xaaab0a588f40 'a') Shifting token 'a' (0xaaab0a588f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab0a588f40 'a') -> $$ = nterm item (0xaaab0a588f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaab0a588f90->Object::Object { 0xaaab0a588f40 } Next token is token 'a' (0xaaab0a588f90 'a') Shifting token 'a' (0xaaab0a588f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab0a588f90 'a') -> $$ = nterm item (0xaaab0a588f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaab0a588fe0->Object::Object { 0xaaab0a588f40, 0xaaab0a588f90 } Next token is token 'a' (0xaaab0a588fe0 'a') Shifting token 'a' (0xaaab0a588fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab0a588fe0 'a') -> $$ = nterm item (0xaaab0a588fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaab0a589030->Object::Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0 } Next token is token 'a' (0xaaab0a589030 'a') Shifting token 'a' (0xaaab0a589030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab0a589030 'a') -> $$ = nterm item (0xaaab0a589030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaab0a589080->Object::Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0, 0xaaab0a589030 } Next token is token 'p' (0xaaab0a589080 'p'Exception caught: cleaning lookahead and stack 0xaaab0a589080->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0, 0xaaab0a589030, 0xaaab0a589080 } 0xaaab0a589030->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0, 0xaaab0a589030 } 0xaaab0a588fe0->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0 } 0xaaab0a588f90->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90 } 0xaaab0a588f40->Object::~Object { 0xaaab0a588f40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stdout: ./c++.at:856: $PREPARSER ./input stderr: ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' Starting parse Entering state 0 Stack now 0 Reading a token 0xaaab0a588f40->Object::Object { } Next token is token 'a' (0xaaab0a588f40 'a') Shifting token 'a' (0xaaab0a588f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab0a588f40 'a') -> $$ = nterm item (0xaaab0a588f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaab0a588f90->Object::Object { 0xaaab0a588f40 } Next token is token 'a' (0xaaab0a588f90 'a') Shifting token 'a' (0xaaab0a588f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab0a588f90 'a') -> $$ = nterm item (0xaaab0a588f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaab0a588fe0->Object::Object { 0xaaab0a588f40, 0xaaab0a588f90 } Next token is token 'a' (0xaaab0a588fe0 'a') Shifting token 'a' (0xaaab0a588fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab0a588fe0 'a') -> $$ = nterm item (0xaaab0a588fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaab0a589030->Object::Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0 } Next token is token 'a' (0xaaab0a589030 'a') Shifting token 'a' (0xaaab0a589030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab0a589030 'a') -> $$ = nterm item (0xaaab0a589030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaab0a589080->Object::Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0, 0xaaab0a589030 } Next token is token 'p' (0xaaab0a589080 'p'Exception caught: cleaning lookahead and stack 0xaaab0a589080->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0, 0xaaab0a589030, 0xaaab0a589080 } 0xaaab0a589030->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0, 0xaaab0a589030 } 0xaaab0a588fe0->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0 } 0xaaab0a588f90->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90 } 0xaaab0a588f40->Object::~Object { 0xaaab0a588f40 } exception caught: printer end { } ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1360: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaT stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaR stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:941: $PREPARSER ./input stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1361: $PREPARSER ./input aaaas ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stderr: exception caught: reduction ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1361: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1463: sed -ne '/INCLUDED/p;/\\file/{p;n;p;}' include/ast/loc.hh ./c++.at:1361: $PREPARSER ./input i ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:1471: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o x2.cc x2.yy exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaap stderr: ./c++.at:1471: $CXX $CPPFLAGS $CXXFLAGS -Iinclude -c -o x2.o x2.cc ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaec95df40->Object::Object { } Next token is token 'a' (0xaaaaec95df40 'a') Shifting token 'a' (0xaaaaec95df40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaec95df40 'a') -> $$ = nterm item (0xaaaaec95df40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaaec95df90->Object::Object { 0xaaaaec95df40 } Next token is token 'a' (0xaaaaec95df90 'a') Shifting token 'a' (0xaaaaec95df90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaec95df90 'a') -> $$ = nterm item (0xaaaaec95df90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaaec95dfe0->Object::Object { 0xaaaaec95df40, 0xaaaaec95df90 } Next token is token 'a' (0xaaaaec95dfe0 'a') Shifting token 'a' (0xaaaaec95dfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaec95dfe0 'a') -> $$ = nterm item (0xaaaaec95dfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaaec95e030->Object::Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0 } Next token is token 'a' (0xaaaaec95e030 'a') Shifting token 'a' (0xaaaaec95e030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaec95e030 'a') -> $$ = nterm item (0xaaaaec95e030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaaec95e080->Object::Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0, 0xaaaaec95e030 } Next token is token 'p' (0xaaaaec95e080 'p'Exception caught: cleaning lookahead and stack 0xaaaaec95e080->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0, 0xaaaaec95e030, 0xaaaaec95e080 } 0xaaaaec95e030->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0, 0xaaaaec95e030 } 0xaaaaec95dfe0->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0 } 0xaaaaec95df90->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90 } 0xaaaaec95df40->Object::~Object { 0xaaaaec95df40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1065: $PREPARSER ./input < in stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaec95df40->Object::Object { } Next token is token 'a' (0xaaaaec95df40 'a') Shifting token 'a' (0xaaaaec95df40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaec95df40 'a') -> $$ = nterm item (0xaaaaec95df40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaaec95df90->Object::Object { 0xaaaaec95df40 } Next token is token 'a' (0xaaaaec95df90 'a') Shifting token 'a' (0xaaaaec95df90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaec95df90 'a') -> $$ = nterm item (0xaaaaec95df90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaaec95dfe0->Object::Object { 0xaaaaec95df40, 0xaaaaec95df90 } Next token is token 'a' (0xaaaaec95dfe0 'a') Shifting token 'a' (0xaaaaec95dfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaec95dfe0 'a') -> $$ = nterm item (0xaaaaec95dfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaaec95e030->Object::Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0 } Next token is token 'a' (0xaaaaec95e030 'a') Shifting token 'a' (0xaaaaec95e030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaec95e030 'a') -> $$ = nterm item (0xaaaaec95e030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaaec95e080->Object::Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0, 0xaaaaec95e030 } Next token is token 'p' (0xaaaaec95e080 'p'Exception caught: cleaning lookahead and stack 0xaaaaec95e080->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0, 0xaaaaec95e030, 0xaaaaec95e080 } 0xaaaaec95e030->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0, 0xaaaaec95e030 } 0xaaaaec95dfe0->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0 } 0xaaaaec95df90->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90 } 0xaaaaec95df40->Object::~Object { 0xaaaaec95df40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: exception caught: printer ./c++.at:1361: $PREPARSER ./input aaaae stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:1065: $PREPARSER ./input < in exception caught: syntax error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: invalid expression ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in ./c++.at:1361: $PREPARSER ./input aaaaT stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaR stderr: ======== Testing with C++ standard flags: '' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:850: $PREPARSER ./input stderr: ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:851: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ======== Testing with C++ standard flags: '' ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: stderr: stdout: stderr: ./c++.at:1501: $CXX $CPPFLAGS $CXXFLAGS -Iinclude $LDFLAGS -o parser x[12].o main.cc $LIBS stdout: error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in ./c++.at:1362: $PREPARSER ./input aaaal stderr: stderr: stderr: stdout: exception caught: yylex ======== Testing with C++ standard flags: '' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: ./c++.at:1362: $PREPARSER ./input aaaap stdout: ./c++.at:941: $PREPARSER ./input stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffffcd63500->Object::Object { } 0xfffffcd635e0->Object::Object { 0xfffffcd63500 } 0xfffffcd63500->Object::~Object { 0xfffffcd63500, 0xfffffcd635e0 } Next token is token 'a' (0xfffffcd635e0 'a') 0xfffffcd63540->Object::Object { 0xfffffcd635e0 } 0xfffffcd634f0->Object::Object { 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd634f0->Object::~Object { 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd635e0->Object::~Object { 0xfffffcd63540, 0xfffffcd635e0 } Shifting token 'a' (0xfffffcd63540 'a') 0xaaaae725b2e0->Object::Object { 0xfffffcd63540 } 0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xfffffcd63540 } 0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xfffffcd634c8, 0xfffffcd63540 } 0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63540 } Entering state 2 Stack now 0 2 0xfffffcd63600->Object::Object { 0xaaaae725b2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae725b2e0 'a') -> $$ = nterm item (0xfffffcd63600 'a') 0xaaaae725b2e0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63600 } 0xaaaae725b2e0->Object::Object { 0xfffffcd63600 } 0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xfffffcd63600 } 0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd635b0, 0xfffffcd63600 } 0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63600 } Entering state 11 Stack now 0 11 Reading a token 0xfffffcd63500->Object::Object { 0xaaaae725b2e0 } 0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xfffffcd63500 } 0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63500, 0xfffffcd635e0 } Next token is token 'a' (0xfffffcd635e0 'a') 0xfffffcd63540->Object::Object { 0xaaaae725b2e0, 0xfffffcd635e0 } 0xfffffcd634f0->Object::Object { 0xaaaae725b2e0, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd634f0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd635e0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63540, 0xfffffcd635e0 } Shifting token 'a' (0xfffffcd63540 'a') 0xaaaae725b300->Object::Object { 0xaaaae725b2e0, 0xfffffcd63540 } 0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540 } 0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd634c8, 0xfffffcd63540 } 0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540 } Entering state 2 Stack now 0 11 2 0xfffffcd63600->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae725b300 'a') -> $$ = nterm item (0xfffffcd63600 'a') 0xaaaae725b300->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } 0xaaaae725b300->Object::Object { 0xaaaae725b2e0, 0xfffffcd63600 } 0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } 0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd635b0, 0xfffffcd63600 } 0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } Entering state 11 Stack now 0 11 11 Reading a token 0xfffffcd63500->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300 } 0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63500 } 0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63500, 0xfffffcd635e0 } Next token is token 'a' (0xfffffcd635e0 'a') 0xfffffcd63540->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd635e0 } 0xfffffcd634f0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd634f0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd635e0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540, 0xfffffcd635e0 } Shifting token 'a' (0xfffffcd63540 'a') 0xaaaae725b320->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540 } 0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540 } 0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd634c8, 0xfffffcd63540 } 0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540 } Entering state 2 Stack now 0 11 11 2 0xfffffcd63600->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae725b320 'a') -> $$ = nterm item (0xfffffcd63600 'a') 0xaaaae725b320->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } 0xaaaae725b320->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } 0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } 0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd635b0, 0xfffffcd63600 } 0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xfffffcd63500->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320 } 0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63500 } 0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63500, 0xfffffcd635e0 } Next token is token 'a' (0xfffffcd635e0 'a') 0xfffffcd63540->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd635e0 } 0xfffffcd634f0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd634f0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd635e0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540, 0xfffffcd635e0 } Shifting token 'a' (0xfffffcd63540 'a') 0xaaaae725b340->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540 } 0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63540 } 0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd634c8, 0xfffffcd63540 } 0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63540 } Entering state 2 Stack now 0 11 11 11 2 0xfffffcd63600->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae725b340 'a') -> $$ = nterm item (0xfffffcd63600 'a') 0xaaaae725b340->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63600 } 0xaaaae725b340->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } 0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63600 } 0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd635b0, 0xfffffcd63600 } 0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63600 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xfffffcd63500->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340 } 0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63500 } 0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63500, 0xfffffcd635e0 } Next token is token 'p' (0xfffffcd635e0 'p'Exception caught: cleaning lookahead and stack 0xaaaae725b340->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd635e0 } 0xaaaae725b320->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd635e0 } 0xaaaae725b300->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd635e0 } 0xaaaae725b2e0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd635e0 } 0xfffffcd635e0->Object::~Object { 0xfffffcd635e0 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffffcd63500->Object::Object { } 0xfffffcd635e0->Object::Object { 0xfffffcd63500 } 0xfffffcd63500->Object::~Object { 0xfffffcd63500, 0xfffffcd635e0 } Next token is token 'a' (0xfffffcd635e0 'a') 0xfffffcd63540->Object::Object { 0xfffffcd635e0 } 0xfffffcd634f0->Object::Object { 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd634f0->Object::~Object { 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd635e0->Object::~Object { 0xfffffcd63540, 0xfffffcd635e0 } Shifting token 'a' (0xfffffcd63540 'a') 0xaaaae725b2e0->Object::Object { 0xfffffcd63540 } 0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xfffffcd63540 } 0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xfffffcd634c8, 0xfffffcd63540 } 0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63540 } Entering state 2 Stack now 0 2 0xfffffcd63600->Object::Object { 0xaaaae725b2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae725b2e0 'a') -> $$ = nterm item (0xfffffcd63600 'a') 0xaaaae725b2e0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63600 } 0xaaaae725b2e0->Object::Object { 0xfffffcd63600 } 0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xfffffcd63600 } 0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd635b0, 0xfffffcd63600 } 0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63600 } Entering state 11 Stack now 0 11 Reading a token 0xfffffcd63500->Object::Object { 0xaaaae725b2e0 } 0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xfffffcd63500 } 0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63500, 0xfffffcd635e0 } Next token is token 'a' (0xfffffcd635e0 'a') 0xfffffcd63540->Object::Object { 0xaaaae725b2e0, 0xfffffcd635e0 } 0xfffffcd634f0->Object::Object { 0xaaaae725b2e0, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd634f0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd635e0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63540, 0xfffffcd635e0 } Shifting token 'a' (0xfffffcd63540 'a') 0xaaaae725b300->Object::Object { 0xaaaae725b2e0, 0xfffffcd63540 } 0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540 } 0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd634c8, 0xfffffcd63540 } 0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540 } Entering state 2 Stack now 0 11 2 0xfffffcd63600->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae725b300 'a') -> $$ = nterm item (0xfffffcd63600 'a') 0xaaaae725b300->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } 0xaaaae725b300->Object::Object { 0xaaaae725b2e0, 0xfffffcd63600 } 0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } 0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd635b0, 0xfffffcd63600 } 0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } Entering state 11 Stack now 0 11 11 Reading a token 0xfffffcd63500->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300 } 0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63500 } 0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63500, 0xfffffcd635e0 } Next token is token 'a' (0xfffffcd635e0 'a') 0xfffffcd63540->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd635e0 } 0xfffffcd634f0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd634f0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd635e0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540, 0xfffffcd635e0 } Shifting token 'a' (0xfffffcd63540 'a') 0xaaaae725b320->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540 } 0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540 } 0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd634c8, 0xfffffcd63540 } 0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540 } Entering state 2 Stack now 0 11 11 2 0xfffffcd63600->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae725b320 'a') -> $$ = nterm item (0xfffffcd63600 'a') 0xaaaae725b320->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } 0xaaaae725b320->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } 0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } 0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd635b0, 0xfffffcd63600 } 0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xfffffcd63500->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320 } 0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63500 } 0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63500, 0xfffffcd635e0 } Next token is token 'a' (0xfffffcd635e0 'a') 0xfffffcd63540->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd635e0 } 0xfffffcd634f0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd634f0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd635e0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540, 0xfffffcd635e0 } Shifting token 'a' (0xfffffcd63540 'a') 0xaaaae725b340->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540 } 0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63540 } 0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd634c8, 0xfffffcd63540 } 0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63540 } Entering state 2 Stack now 0 11 11 11 2 0xfffffcd63600->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae725b340 'a') -> $$ = nterm item (0xfffffcd63600 'a') 0xaaaae725b340->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63600 } 0xaaaae725b340->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } 0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63600 } 0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd635b0, 0xfffffcd63600 } 0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63600 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xfffffcd63500->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340 } 0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63500 } 0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63500, 0xfffffcd635e0 } Next token is token 'p' (0xfffffcd635e0 'p'Exception caught: cleaning lookahead and stack 0xaaaae725b340->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd635e0 } 0xaaaae725b320->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd635e0 } 0xaaaae725b300->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd635e0 } 0xaaaae725b2e0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd635e0 } 0xfffffcd635e0->Object::~Object { 0xfffffcd635e0 } exception caught: printer end { } ./c++.at:1362: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1363: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaT stderr: ./c++.at:1363: $PREPARSER ./input aaaal ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaR stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input i stderr: exception caught: initial-action ======== Testing with C++ standard flags: '' ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1363: $PREPARSER ./input aaaap stderr: stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1360: $PREPARSER ./input aaaas ./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: stderr: exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffcb68b7a0->Object::Object { } 0xffffcb68b880->Object::Object { 0xffffcb68b7a0 } 0xffffcb68b7a0->Object::~Object { 0xffffcb68b7a0, 0xffffcb68b880 } Next token is token 'a' (0xffffcb68b880 'a') 0xffffcb68b7e0->Object::Object { 0xffffcb68b880 } 0xffffcb68b790->Object::Object { 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b790->Object::~Object { 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b880->Object::~Object { 0xffffcb68b7e0, 0xffffcb68b880 } Shifting token 'a' (0xffffcb68b7e0 'a') 0xaaaaf501a2e0->Object::Object { 0xffffcb68b7e0 } 0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7e0 } 0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b768, 0xffffcb68b7e0 } 0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b7e0 } Entering state 1 Stack now 0 1 0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf501a2e0 'a') -> $$ = nterm item (0xffffcb68b8a0 'a') 0xaaaaf501a2e0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } 0xaaaaf501a2e0->Object::Object { 0xffffcb68b8a0 } 0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } 0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b850, 0xffffcb68b8a0 } 0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } Entering state 10 Stack now 0 10 Reading a token 0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0 } 0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7a0 } 0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b7a0, 0xffffcb68b880 } Next token is token 'a' (0xffffcb68b880 'a') 0xffffcb68b7e0->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b880 } 0xffffcb68b790->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b790->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b880->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b7e0, 0xffffcb68b880 } Shifting token 'a' (0xffffcb68b7e0 'a') 0xaaaaf501a300->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7e0 } 0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0 } 0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b768, 0xffffcb68b7e0 } 0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0 } Entering state 1 Stack now 0 10 1 0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf501a300 'a') -> $$ = nterm item (0xffffcb68b8a0 'a') 0xaaaaf501a300->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } 0xaaaaf501a300->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } 0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } 0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b850, 0xffffcb68b8a0 } 0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300 } 0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7a0 } 0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7a0, 0xffffcb68b880 } Next token is token 'a' (0xffffcb68b880 'a') 0xffffcb68b7e0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b880 } 0xffffcb68b790->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b790->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b880->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0, 0xffffcb68b880 } Shifting token 'a' (0xffffcb68b7e0 'a') 0xaaaaf501a320->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0 } 0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0 } 0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b768, 0xffffcb68b7e0 } 0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0 } Entering state 1 Stack now 0 10 10 1 0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf501a320 'a') -> $$ = nterm item (0xffffcb68b8a0 'a') 0xaaaaf501a320->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } 0xaaaaf501a320->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } 0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } 0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b850, 0xffffcb68b8a0 } 0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320 } 0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7a0 } 0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7a0, 0xffffcb68b880 } Next token is token 'a' (0xffffcb68b880 'a') 0xffffcb68b7e0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b880 } 0xffffcb68b790->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b790->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b880->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0, 0xffffcb68b880 } Shifting token 'a' (0xffffcb68b7e0 'a') 0xaaaaf501a340->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0 } 0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7e0 } 0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b768, 0xffffcb68b7e0 } 0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7e0 } Entering state 1 Stack now 0 10 10 10 1 0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf501a340 'a') -> $$ = nterm item (0xffffcb68b8a0 'a') 0xaaaaf501a340->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b8a0 } 0xaaaaf501a340->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } 0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b8a0 } 0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b850, 0xffffcb68b8a0 } 0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b8a0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340 } 0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7a0 } 0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7a0, 0xffffcb68b880 } Next token is token 'p' (0xffffcb68b880 'p'Exception caught: cleaning lookahead and stack 0xaaaaf501a340->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b880 } 0xaaaaf501a320->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b880 } 0xaaaaf501a300->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b880 } 0xaaaaf501a2e0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b880 } 0xffffcb68b880->Object::~Object { 0xffffcb68b880 } exception caught: printer end { } stdout: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1502: $PREPARSER ./parser ./c++.at:1360: $PREPARSER ./input aaaal stderr: stderr: stderr: ./c++.at:1502: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: yylex ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 690. c++.at:1422: ok stdout: ./c++.at:1066: $PREPARSER ./input < in stderr: stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token 0xffffcb68b7a0->Object::Object { } 0xffffcb68b880->Object::Object { 0xffffcb68b7a0 } 0xffffcb68b7a0->Object::~Object { 0xffffcb68b7a0, 0xffffcb68b880 } Next token is token 'a' (0xffffcb68b880 'a') 0xffffcb68b7e0->Object::Object { 0xffffcb68b880 } 0xffffcb68b790->Object::Object { 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b790->Object::~Object { 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b880->Object::~Object { 0xffffcb68b7e0, 0xffffcb68b880 } Shifting token 'a' (0xffffcb68b7e0 'a') 0xaaaaf501a2e0->Object::Object { 0xffffcb68b7e0 } 0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7e0 } 0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b768, 0xffffcb68b7e0 } 0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b7e0 } Entering state 1 Stack now 0 1 0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf501a2e0 'a') -> $$ = nterm item (0xffffcb68b8a0 'a') 0xaaaaf501a2e0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } 0xaaaaf501a2e0->Object::Object { 0xffffcb68b8a0 } 0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } 0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b850, 0xffffcb68b8a0 } 0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } Entering state 10 Stack now 0 10 Reading a token 0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0 } 0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7a0 } 0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b7a0, 0xffffcb68b880 } Next token is token 'a' (0xffffcb68b880 'a') 0xffffcb68b7e0->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b880 } 0xffffcb68b790->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b790->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b880->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b7e0, 0xffffcb68b880 } Shifting token 'a' (0xffffcb68b7e0 'a') 0xaaaaf501a300->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7e0 } 0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0 } 0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b768, 0xffffcb68b7e0 } 0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0 } Entering state 1 Stack now 0 10 1 0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf501a300 'a') -> $$ = nterm item (0xffffcb68b8a0 'a') 0xaaaaf501a300->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } 0xaaaaf501a300->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } 0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } 0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b850, 0xffffcb68b8a0 } 0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300 } 0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7a0 } 0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7a0, 0xffffcb68b880 } Next token is token 'a' (0xffffcb68b880 'a') 0xffffcb68b7e0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b880 } 0xffffcb68b790->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b790->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b880->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0, 0xffffcb68b880 } Shifting token 'a' (0xffffcb68b7e0 'a') 0xaaaaf501a320->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0 } 0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0 } 0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b768, 0xffffcb68b7e0 } 0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0 } Entering state 1 Stack now 0 10 10 1 0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf501a320 'a') -> $$ = nterm item (0xffffcb68b8a0 'a') 0xaaaaf501a320->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } 0xaaaaf501a320->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } 0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } 0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b850, 0xffffcb68b8a0 } 0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320 } 0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7a0 } 0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7a0, 0xffffcb68b880 } Next token is token 'a' (0xffffcb68b880 'a') 0xffffcb68b7e0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b880 } 0xffffcb68b790->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b790->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b880->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0, 0xffffcb68b880 } Shifting token 'a' (0xffffcb68b7e0 'a') 0xaaaaf501a340->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0 } 0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7e0 } 0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b768, 0xffffcb68b7e0 } 0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7e0 } Entering state 1 Stack now 0 10 10 10 1 0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf501a340 'a') -> $$ = nterm item (0xffffcb68b8a0 'a') 0xaaaaf501a340->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b8a0 } 0xaaaaf501a340->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } 0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b8a0 } 0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b850, 0xffffcb68b8a0 } 0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b8a0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340 } 0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7a0 } 0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7a0, 0xffffcb68b880 } Next token is token 'p' (0xffffcb68b880 'p'Exception caught: cleaning lookahead and stack 0xaaaaf501a340->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b880 } 0xaaaaf501a320->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b880 } 0xaaaaf501a300->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b880 } 0xaaaaf501a2e0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b880 } 0xffffcb68b880->Object::~Object { 0xffffcb68b880 } exception caught: printer end { } ./c++.at:1363: grep '^exception caught: printer$' stderr ./c++.at:1066: $PREPARSER ./input < in ./c++.at:1360: $PREPARSER ./input i stderr: stdout: stderr: exception caught: initial-action exception caught: printer error: invalid expression ./c++.at:1363: $PREPARSER ./input aaaae ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $PREPARSER ./input < in ./c++.at:1363: $PREPARSER ./input aaaaE ./c++.at:1360: $PREPARSER ./input aaaap stderr: stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: invalid character ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 691. c++.at:1517: testing Default action ... stderr: ======== Testing with C++ standard flags: '' ./c++.at:1363: $PREPARSER ./input aaaaT ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input --debug aaaap stderr: ./c++.at:1363: $PREPARSER ./input aaaaR stdout: stderr: ./c++.at:856: $PREPARSER ./input ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaadffc9f40->Object::Object { } Next token is token 'a' (0xaaaadffc9f40 'a') Shifting token 'a' (0xaaaadffc9f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadffc9f40 'a') -> $$ = nterm item (0xaaaadffc9f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaadffc9f90->Object::Object { 0xaaaadffc9f40 } Next token is token 'a' (0xaaaadffc9f90 'a') Shifting token 'a' (0xaaaadffc9f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadffc9f90 'a') -> $$ = nterm item (0xaaaadffc9f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaadffc9fe0->Object::Object { 0xaaaadffc9f40, 0xaaaadffc9f90 } Next token is token 'a' (0xaaaadffc9fe0 'a') Shifting token 'a' (0xaaaadffc9fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadffc9fe0 'a') -> $$ = nterm item (0xaaaadffc9fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaadffca030->Object::Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0 } Next token is token 'a' (0xaaaadffca030 'a') Shifting token 'a' (0xaaaadffca030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadffca030 'a') -> $$ = nterm item (0xaaaadffca030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaadffca080->Object::Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0, 0xaaaadffca030 } Next token is token 'p' (0xaaaadffca080 'p'Exception caught: cleaning lookahead and stack 0xaaaadffca080->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0, 0xaaaadffca030, 0xaaaadffca080 } 0xaaaadffca030->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0, 0xaaaadffca030 } 0xaaaadffc9fe0->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0 } 0xaaaadffc9f90->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90 } 0xaaaadffc9f40->Object::~Object { 0xaaaadffc9f40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:857: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaadffc9f40->Object::Object { } Next token is token 'a' (0xaaaadffc9f40 'a') Shifting token 'a' (0xaaaadffc9f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadffc9f40 'a') -> $$ = nterm item (0xaaaadffc9f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaadffc9f90->Object::Object { 0xaaaadffc9f40 } Next token is token 'a' (0xaaaadffc9f90 'a') Shifting token 'a' (0xaaaadffc9f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadffc9f90 'a') -> $$ = nterm item (0xaaaadffc9f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaadffc9fe0->Object::Object { 0xaaaadffc9f40, 0xaaaadffc9f90 } Next token is token 'a' (0xaaaadffc9fe0 'a') Shifting token 'a' (0xaaaadffc9fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadffc9fe0 'a') -> $$ = nterm item (0xaaaadffc9fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaadffca030->Object::Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0 } Next token is token 'a' (0xaaaadffca030 'a') Shifting token 'a' (0xaaaadffca030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadffca030 'a') -> $$ = nterm item (0xaaaadffca030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaadffca080->Object::Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0, 0xaaaadffca030 } Next token is token 'p' (0xaaaadffca080 'p'Exception caught: cleaning lookahead and stack 0xaaaadffca080->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0, 0xaaaadffca030, 0xaaaadffca080 } 0xaaaadffca030->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0, 0xaaaadffca030 } 0xaaaadffc9fe0->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0 } 0xaaaadffc9f90->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90 } 0xaaaadffc9f40->Object::~Object { 0xaaaadffc9f40 } exception caught: printer end { } ./c++.at:1360: grep '^exception caught: printer$' stderr stdout: ======== Testing with C++ standard flags: '' ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae stderr: stdout: ./c++.at:1066: ./check ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1555: ./check ./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y ./c++.at:1360: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaT ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: ./c++.at:851: $PREPARSER ./input ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1360: $PREPARSER ./input aaaaR ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1361: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input i stderr: stderr: exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1065: $PREPARSER ./input < in ./c++.at:1361: $PREPARSER ./input aaaap stderr: stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaf6b83f40->Object::Object { } Next token is token 'a' (0xaaaaf6b83f40 'a') Shifting token 'a' (0xaaaaf6b83f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf6b83f40 'a') -> $$ = nterm item (0xaaaaf6b83f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaaf6b83f90->Object::Object { 0xaaaaf6b83f40 } Next token is token 'a' (0xaaaaf6b83f90 'a') Shifting token 'a' (0xaaaaf6b83f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf6b83f90 'a') -> $$ = nterm item (0xaaaaf6b83f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaaf6b83fe0->Object::Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90 } Next token is token 'a' (0xaaaaf6b83fe0 'a') Shifting token 'a' (0xaaaaf6b83fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf6b83fe0 'a') -> $$ = nterm item (0xaaaaf6b83fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaaf6b84030->Object::Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0 } Next token is token 'a' (0xaaaaf6b84030 'a') Shifting token 'a' (0xaaaaf6b84030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf6b84030 'a') -> $$ = nterm item (0xaaaaf6b84030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaaf6b84080->Object::Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0, 0xaaaaf6b84030 } Next token is token 'p' (0xaaaaf6b84080 'p'Exception caught: cleaning lookahead and stack 0xaaaaf6b84080->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0, 0xaaaaf6b84030, 0xaaaaf6b84080 } 0xaaaaf6b84030->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0, 0xaaaaf6b84030 } 0xaaaaf6b83fe0->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0 } 0xaaaaf6b83f90->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90 } 0xaaaaf6b83f40->Object::~Object { 0xaaaaf6b83f40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaf6b83f40->Object::Object { } Next token is token 'a' (0xaaaaf6b83f40 'a') Shifting token 'a' (0xaaaaf6b83f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf6b83f40 'a') -> $$ = nterm item (0xaaaaf6b83f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaaf6b83f90->Object::Object { 0xaaaaf6b83f40 } Next token is token 'a' (0xaaaaf6b83f90 'a') Shifting token 'a' (0xaaaaf6b83f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf6b83f90 'a') -> $$ = nterm item (0xaaaaf6b83f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaaf6b83fe0->Object::Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90 } Next token is token 'a' (0xaaaaf6b83fe0 'a') Shifting token 'a' (0xaaaaf6b83fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf6b83fe0 'a') -> $$ = nterm item (0xaaaaf6b83fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaaf6b84030->Object::Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0 } Next token is token 'a' (0xaaaaf6b84030 'a') Shifting token 'a' (0xaaaaf6b84030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf6b84030 'a') -> $$ = nterm item (0xaaaaf6b84030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaaf6b84080->Object::Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0, 0xaaaaf6b84030 } Next token is token 'p' (0xaaaaf6b84080 'p'Exception caught: cleaning lookahead and stack 0xaaaaf6b84080->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0, 0xaaaaf6b84030, 0xaaaaf6b84080 } 0xaaaaf6b84030->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0, 0xaaaaf6b84030 } 0xaaaaf6b83fe0->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0 } 0xaaaaf6b83f90->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90 } 0xaaaaf6b83f40->Object::~Object { 0xaaaaf6b83f40 } exception caught: printer end { } error: invalid expression ./c++.at:1361: grep '^exception caught: printer$' stderr ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: exception caught: printer ./c++.at:1361: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ./c++.at:1361: $PREPARSER ./input aaaaT stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaR stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:857: $PREPARSER ./input stderr: ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:851: $PREPARSER ./input stderr: ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:941: $PREPARSER ./input stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1555: $PREPARSER ./test stderr: ./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./c++.at:1362: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaap stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffff6539bc0->Object::Object { } 0xfffff6539ca0->Object::Object { 0xfffff6539bc0 } 0xfffff6539bc0->Object::~Object { 0xfffff6539bc0, 0xfffff6539ca0 } Next token is token 'a' (0xfffff6539ca0 'a') 0xfffff6539c00->Object::Object { 0xfffff6539ca0 } 0xfffff6539bb0->Object::Object { 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539bb0->Object::~Object { 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539ca0->Object::~Object { 0xfffff6539c00, 0xfffff6539ca0 } Shifting token 'a' (0xfffff6539c00 'a') 0xaaaaf4b662e0->Object::Object { 0xfffff6539c00 } 0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xfffff6539c00 } 0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539b88, 0xfffff6539c00 } 0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539c00 } Entering state 2 Stack now 0 2 0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf4b662e0 'a') -> $$ = nterm item (0xfffff6539cc0 'a') 0xaaaaf4b662e0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } 0xaaaaf4b662e0->Object::Object { 0xfffff6539cc0 } 0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } 0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539c70, 0xfffff6539cc0 } 0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } Entering state 11 Stack now 0 11 Reading a token 0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0 } 0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xfffff6539bc0 } 0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539bc0, 0xfffff6539ca0 } Next token is token 'a' (0xfffff6539ca0 'a') 0xfffff6539c00->Object::Object { 0xaaaaf4b662e0, 0xfffff6539ca0 } 0xfffff6539bb0->Object::Object { 0xaaaaf4b662e0, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539bb0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539ca0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539c00, 0xfffff6539ca0 } Shifting token 'a' (0xfffff6539c00 'a') 0xaaaaf4b66300->Object::Object { 0xaaaaf4b662e0, 0xfffff6539c00 } 0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00 } 0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539b88, 0xfffff6539c00 } 0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00 } Entering state 2 Stack now 0 11 2 0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf4b66300 'a') -> $$ = nterm item (0xfffff6539cc0 'a') 0xaaaaf4b66300->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } 0xaaaaf4b66300->Object::Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } 0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } 0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c70, 0xfffff6539cc0 } 0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } Entering state 11 Stack now 0 11 11 Reading a token 0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300 } 0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539bc0 } 0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539bc0, 0xfffff6539ca0 } Next token is token 'a' (0xfffff6539ca0 'a') 0xfffff6539c00->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539ca0 } 0xfffff6539bb0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539bb0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539ca0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00, 0xfffff6539ca0 } Shifting token 'a' (0xfffff6539c00 'a') 0xaaaaf4b66320->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00 } 0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00 } 0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539b88, 0xfffff6539c00 } 0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00 } Entering state 2 Stack now 0 11 11 2 0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf4b66320 'a') -> $$ = nterm item (0xfffff6539cc0 'a') 0xaaaaf4b66320->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } 0xaaaaf4b66320->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } 0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } 0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c70, 0xfffff6539cc0 } 0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320 } 0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539bc0 } 0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539bc0, 0xfffff6539ca0 } Next token is token 'a' (0xfffff6539ca0 'a') 0xfffff6539c00->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539ca0 } 0xfffff6539bb0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539bb0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539ca0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00, 0xfffff6539ca0 } Shifting token 'a' (0xfffff6539c00 'a') 0xaaaaf4b66340->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00 } 0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539c00 } 0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539b88, 0xfffff6539c00 } 0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539c00 } Entering state 2 Stack now 0 11 11 11 2 0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf4b66340 'a') -> $$ = nterm item (0xfffff6539cc0 'a') 0xaaaaf4b66340->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539cc0 } 0xaaaaf4b66340->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } 0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539cc0 } 0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539c70, 0xfffff6539cc0 } 0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539cc0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340 } 0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539bc0 } 0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539bc0, 0xfffff6539ca0 } Next token is token 'p' (0xfffff6539ca0 'p'Exception caught: cleaning lookahead and stack 0xaaaaf4b66340->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539ca0 } 0xaaaaf4b66320->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539ca0 } 0xaaaaf4b66300->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539ca0 } 0xaaaaf4b662e0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539ca0 } 0xfffff6539ca0->Object::~Object { 0xfffff6539ca0 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffff6539bc0->Object::Object { } 0xfffff6539ca0->Object::Object { 0xfffff6539bc0 } 0xfffff6539bc0->Object::~Object { 0xfffff6539bc0, 0xfffff6539ca0 } Next token is token 'a' (0xfffff6539ca0 'a') 0xfffff6539c00->Object::Object { 0xfffff6539ca0 } 0xfffff6539bb0->Object::Object { 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539bb0->Object::~Object { 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539ca0->Object::~Object { 0xfffff6539c00, 0xfffff6539ca0 } Shifting token 'a' (0xfffff6539c00 'a') 0xaaaaf4b662e0->Object::Object { 0xfffff6539c00 } 0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xfffff6539c00 } 0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539b88, 0xfffff6539c00 } 0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539c00 } Entering state 2 Stack now 0 2 0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf4b662e0 'a') -> $$ = nterm item (0xfffff6539cc0 'a') 0xaaaaf4b662e0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } 0xaaaaf4b662e0->Object::Object { 0xfffff6539cc0 } 0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } 0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539c70, 0xfffff6539cc0 } 0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } Entering state 11 Stack now 0 11 Reading a token 0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0 } 0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xfffff6539bc0 } 0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539bc0, 0xfffff6539ca0 } Next token is token 'a' (0xfffff6539ca0 'a') 0xfffff6539c00->Object::Object { 0xaaaaf4b662e0, 0xfffff6539ca0 } 0xfffff6539bb0->Object::Object { 0xaaaaf4b662e0, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539bb0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539ca0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539c00, 0xfffff6539ca0 } Shifting token 'a' (0xfffff6539c00 'a') 0xaaaaf4b66300->Object::Object { 0xaaaaf4b662e0, 0xfffff6539c00 } 0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00 } 0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539b88, 0xfffff6539c00 } 0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00 } Entering state 2 Stack now 0 11 2 0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf4b66300 'a') -> $$ = nterm item (0xfffff6539cc0 'a') 0xaaaaf4b66300->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } 0xaaaaf4b66300->Object::Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } 0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } 0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c70, 0xfffff6539cc0 } 0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } Entering state 11 Stack now 0 11 11 Reading a token 0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300 } 0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539bc0 } 0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539bc0, 0xfffff6539ca0 } Next token is token 'a' (0xfffff6539ca0 'a') 0xfffff6539c00->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539ca0 } 0xfffff6539bb0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539bb0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539ca0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00, 0xfffff6539ca0 } Shifting token 'a' (0xfffff6539c00 'a') 0xaaaaf4b66320->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00 } 0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00 } 0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539b88, 0xfffff6539c00 } 0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00 } Entering state 2 Stack now 0 11 11 2 0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf4b66320 'a') -> $$ = nterm item (0xfffff6539cc0 'a') 0xaaaaf4b66320->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } 0xaaaaf4b66320->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } 0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } 0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c70, 0xfffff6539cc0 } 0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320 } 0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539bc0 } 0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539bc0, 0xfffff6539ca0 } Next token is token 'a' (0xfffff6539ca0 'a') 0xfffff6539c00->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539ca0 } 0xfffff6539bb0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539bb0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539ca0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00, 0xfffff6539ca0 } Shifting token 'a' (0xfffff6539c00 'a') 0xaaaaf4b66340->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00 } 0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539c00 } 0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539b88, 0xfffff6539c00 } 0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539c00 } Entering state 2 Stack now 0 11 11 11 2 0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf4b66340 'a') -> $$ = nterm item (0xfffff6539cc0 'a') 0xaaaaf4b66340->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539cc0 } 0xaaaaf4b66340->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } 0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539cc0 } 0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539c70, 0xfffff6539cc0 } 0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539cc0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340 } 0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539bc0 } 0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539bc0, 0xfffff6539ca0 } Next token is token 'p' (0xfffff6539ca0 'p'Exception caught: cleaning lookahead and stack 0xaaaaf4b66340->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539ca0 } 0xaaaaf4b66320->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539ca0 } 0xaaaaf4b66300->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539ca0 } 0xaaaaf4b662e0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539ca0 } 0xfffff6539ca0->Object::~Object { 0xfffff6539ca0 } exception caught: printer end { } ./c++.at:1362: grep '^exception caught: printer$' stderr stdout: stdout: exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae stderr: ./c++.at:1555: ./check exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -std=c++98 not supported ======== Testing with C++ standard flags: '' ./c++.at:1362: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaT ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaR stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1363: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaap stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1363: $PREPARSER ./input --debug aaaap ./c++.at:1360: $PREPARSER ./input aaaas stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc989b1b0->Object::Object { } 0xffffc989b290->Object::Object { 0xffffc989b1b0 } 0xffffc989b1b0->Object::~Object { 0xffffc989b1b0, 0xffffc989b290 } Next token is token 'a' (0xffffc989b290 'a') 0xffffc989b1f0->Object::Object { 0xffffc989b290 } 0xffffc989b1a0->Object::Object { 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b1a0->Object::~Object { 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b290->Object::~Object { 0xffffc989b1f0, 0xffffc989b290 } Shifting token 'a' (0xffffc989b1f0 'a') 0xaaab093cb2e0->Object::Object { 0xffffc989b1f0 } 0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xffffc989b1f0 } 0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xffffc989b178, 0xffffc989b1f0 } 0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1f0 } Entering state 1 Stack now 0 1 0xffffc989b2b0->Object::Object { 0xaaab093cb2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab093cb2e0 'a') -> $$ = nterm item (0xffffc989b2b0 'a') 0xaaab093cb2e0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b2b0 } 0xaaab093cb2e0->Object::Object { 0xffffc989b2b0 } 0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xffffc989b2b0 } 0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xffffc989b260, 0xffffc989b2b0 } 0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b2b0 } Entering state 10 Stack now 0 10 Reading a token 0xffffc989b1b0->Object::Object { 0xaaab093cb2e0 } 0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xffffc989b1b0 } 0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1b0, 0xffffc989b290 } Next token is token 'a' (0xffffc989b290 'a') 0xffffc989b1f0->Object::Object { 0xaaab093cb2e0, 0xffffc989b290 } 0xffffc989b1a0->Object::Object { 0xaaab093cb2e0, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b1a0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b290->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1f0, 0xffffc989b290 } Shifting token 'a' (0xffffc989b1f0 'a') 0xaaab093cb300->Object::Object { 0xaaab093cb2e0, 0xffffc989b1f0 } 0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0 } 0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b178, 0xffffc989b1f0 } 0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0 } Entering state 1 Stack now 0 10 1 0xffffc989b2b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab093cb300 'a') -> $$ = nterm item (0xffffc989b2b0 'a') 0xaaab093cb300->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } 0xaaab093cb300->Object::Object { 0xaaab093cb2e0, 0xffffc989b2b0 } 0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } 0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b260, 0xffffc989b2b0 } 0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffc989b1b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300 } 0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1b0 } 0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1b0, 0xffffc989b290 } Next token is token 'a' (0xffffc989b290 'a') 0xffffc989b1f0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b290 } 0xffffc989b1a0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b1a0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b290->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0, 0xffffc989b290 } Shifting token 'a' (0xffffc989b1f0 'a') 0xaaab093cb320->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0 } 0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0 } 0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b178, 0xffffc989b1f0 } 0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0 } Entering state 1 Stack now 0 10 10 1 0xffffc989b2b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab093cb320 'a') -> $$ = nterm item (0xffffc989b2b0 'a') 0xaaab093cb320->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } 0xaaab093cb320->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } 0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } 0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b260, 0xffffc989b2b0 } 0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffc989b1b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320 } 0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1b0 } 0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1b0, 0xffffc989b290 } Next token is token 'a' (0xffffc989b290 'a') 0xffffc989b1f0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b290 } 0xffffc989b1a0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b1a0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b290->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0, 0xffffc989b290 } Shifting token 'a' (0xffffc989b1f0 'a') 0xaaab093cb340->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0 } 0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1f0 } 0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b178, 0xffffc989b1f0 } 0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1f0 } Entering state 1 Stack now 0 10 10 10 1 0xffffc989b2b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab093cb340 'a') -> $$ = nterm item (0xffffc989b2b0 'a') 0xaaab093cb340->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b2b0 } 0xaaab093cb340->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } 0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b2b0 } 0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b260, 0xffffc989b2b0 } 0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b2b0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffc989b1b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340 } 0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1b0 } 0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1b0, 0xffffc989b290 } Next token is token 'p' (0xffffc989b290 'p'Exception caught: cleaning lookahead and stack 0xaaab093cb340->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b290 } 0xaaab093cb320->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b290 } 0xaaab093cb300->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b290 } 0xaaab093cb2e0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b290 } 0xffffc989b290->Object::~Object { 0xffffc989b290 } exception caught: printer end { } ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc989b1b0->Object::Object { } 0xffffc989b290->Object::Object { 0xffffc989b1b0 } 0xffffc989b1b0->Object::~Object { 0xffffc989b1b0, 0xffffc989b290 } Next token is token 'a' (0xffffc989b290 'a') 0xffffc989b1f0->Object::Object { 0xffffc989b290 } 0xffffc989b1a0->Object::Object { 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b1a0->Object::~Object { 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b290->Object::~Object { 0xffffc989b1f0, 0xffffc989b290 } Shifting token 'a' (0xffffc989b1f0 'a') 0xaaab093cb2e0->Object::Object { 0xffffc989b1f0 } 0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xffffc989b1f0 } 0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xffffc989b178, 0xffffc989b1f0 } 0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1f0 } Entering state 1 Stack now 0 1 0xffffc989b2b0->Object::Object { 0xaaab093cb2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab093cb2e0 'a') -> $$ = nterm item (0xffffc989b2b0 'a') 0xaaab093cb2e0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b2b0 } 0xaaab093cb2e0->Object::Object { 0xffffc989b2b0 } 0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xffffc989b2b0 } 0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xffffc989b260, 0xffffc989b2b0 } 0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b2b0 } Entering state 10 Stack now 0 10 Reading a token 0xffffc989b1b0->Object::Object { 0xaaab093cb2e0 } 0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xffffc989b1b0 } 0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1b0, 0xffffc989b290 } Next token is token 'a' (0xffffc989b290 'a') 0xffffc989b1f0->Object::Object { 0xaaab093cb2e0, 0xffffc989b290 } 0xffffc989b1a0->Object::Object { 0xaaab093cb2e0, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b1a0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b290->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1f0, 0xffffc989b290 } Shifting token 'a' (0xffffc989b1f0 'a') 0xaaab093cb300->Object::Object { 0xaaab093cb2e0, 0xffffc989b1f0 } 0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0 } 0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b178, 0xffffc989b1f0 } 0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0 } Entering state 1 Stack now 0 10 1 0xffffc989b2b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab093cb300 'a') -> $$ = nterm item (0xffffc989b2b0 'a') 0xaaab093cb300->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } 0xaaab093cb300->Object::Object { 0xaaab093cb2e0, 0xffffc989b2b0 } 0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } 0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b260, 0xffffc989b2b0 } 0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffc989b1b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300 } 0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1b0 } 0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1b0, 0xffffc989b290 } Next token is token 'a' (0xffffc989b290 'a') 0xffffc989b1f0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b290 } 0xffffc989b1a0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b1a0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b290->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0, 0xffffc989b290 } Shifting token 'a' (0xffffc989b1f0 'a') 0xaaab093cb320->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0 } 0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0 } 0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b178, 0xffffc989b1f0 } 0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0 } Entering state 1 Stack now 0 10 10 1 0xffffc989b2b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab093cb320 'a') -> $$ = nterm item (0xffffc989b2b0 'a') 0xaaab093cb320->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } 0xaaab093cb320->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } 0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } 0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b260, 0xffffc989b2b0 } 0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffc989b1b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320 } 0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1b0 } 0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1b0, 0xffffc989b290 } Next token is token 'a' (0xffffc989b290 'a') 0xffffc989b1f0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b290 } 0xffffc989b1a0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b1a0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b290->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0, 0xffffc989b290 } Shifting token 'a' (0xffffc989b1f0 'a') 0xaaab093cb340->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0 } 0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1f0 } 0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b178, 0xffffc989b1f0 } 0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1f0 } Entering state 1 Stack now 0 10 10 10 1 0xffffc989b2b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab093cb340 'a') -> $$ = nterm item (0xffffc989b2b0 'a') 0xaaab093cb340->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b2b0 } 0xaaab093cb340->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } 0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b2b0 } 0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b260, 0xffffc989b2b0 } 0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b2b0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffc989b1b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340 } 0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1b0 } 0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1b0, 0xffffc989b290 } Next token is token 'p' (0xffffc989b290 'p'Exception caught: cleaning lookahead and stack 0xaaab093cb340->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b290 } 0xaaab093cb320->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b290 } 0xaaab093cb300->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b290 } 0xaaab093cb2e0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b290 } 0xffffc989b290->Object::~Object { 0xffffc989b290 } exception caught: printer end { } ./c++.at:1363: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1363: $PREPARSER ./input aaaae ./c++.at:1360: $PREPARSER ./input aaaal stderr: stderr: stderr: exception caught: yylex ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaE stdout: stderr: ./c++.at:1360: $PREPARSER ./input i exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: initial-action ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaT ./c++.at:1555: ./check stderr: ./c++.at:1360: $PREPARSER ./input aaaap ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: $PREPARSER ./input aaaaR ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -std=c++03 not supported ======== Testing with C++ standard flags: '' ./c++.at:1360: $PREPARSER ./input --debug aaaap ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae5ef1f40->Object::Object { } Next token is token 'a' (0xaaaae5ef1f40 'a') Shifting token 'a' (0xaaaae5ef1f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae5ef1f40 'a') -> $$ = nterm item (0xaaaae5ef1f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaae5ef1f90->Object::Object { 0xaaaae5ef1f40 } Next token is token 'a' (0xaaaae5ef1f90 'a') Shifting token 'a' (0xaaaae5ef1f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae5ef1f90 'a') -> $$ = nterm item (0xaaaae5ef1f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaae5ef1fe0->Object::Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90 } Next token is token 'a' (0xaaaae5ef1fe0 'a') Shifting token 'a' (0xaaaae5ef1fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae5ef1fe0 'a') -> $$ = nterm item (0xaaaae5ef1fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaae5ef2030->Object::Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0 } Next token is token 'a' (0xaaaae5ef2030 'a') Shifting token 'a' (0xaaaae5ef2030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae5ef2030 'a') -> $$ = nterm item (0xaaaae5ef2030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaae5ef2080->Object::Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0, 0xaaaae5ef2030 } Next token is token 'p' (0xaaaae5ef2080 'p'Exception caught: cleaning lookahead and stack 0xaaaae5ef2080->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0, 0xaaaae5ef2030, 0xaaaae5ef2080 } 0xaaaae5ef2030->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0, 0xaaaae5ef2030 } 0xaaaae5ef1fe0->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0 } 0xaaaae5ef1f90->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90 } 0xaaaae5ef1f40->Object::~Object { 0xaaaae5ef1f40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae5ef1f40->Object::Object { } Next token is token 'a' (0xaaaae5ef1f40 'a') Shifting token 'a' (0xaaaae5ef1f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae5ef1f40 'a') -> $$ = nterm item (0xaaaae5ef1f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaae5ef1f90->Object::Object { 0xaaaae5ef1f40 } Next token is token 'a' (0xaaaae5ef1f90 'a') Shifting token 'a' (0xaaaae5ef1f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae5ef1f90 'a') -> $$ = nterm item (0xaaaae5ef1f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaae5ef1fe0->Object::Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90 } Next token is token 'a' (0xaaaae5ef1fe0 'a') Shifting token 'a' (0xaaaae5ef1fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae5ef1fe0 'a') -> $$ = nterm item (0xaaaae5ef1fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaae5ef2030->Object::Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0 } Next token is token 'a' (0xaaaae5ef2030 'a') Shifting token 'a' (0xaaaae5ef2030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae5ef2030 'a') -> $$ = nterm item (0xaaaae5ef2030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaae5ef2080->Object::Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0, 0xaaaae5ef2030 } Next token is token 'p' (0xaaaae5ef2080 'p'Exception caught: cleaning lookahead and stack 0xaaaae5ef2080->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0, 0xaaaae5ef2030, 0xaaaae5ef2080 } 0xaaaae5ef2030->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0, 0xaaaae5ef2030 } 0xaaaae5ef1fe0->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0 } 0xaaaae5ef1f90->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90 } 0xaaaae5ef1f40->Object::~Object { 0xaaaae5ef1f40 } exception caught: printer end { } ./c++.at:1360: grep '^exception caught: printer$' stderr ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaT stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaR stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ======== Testing with C++ standard flags: '' stdout: ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: ./c++.at:851: $PREPARSER ./input ./c++.at:1555: ./check stderr: -std=c++11 not supported ======== Testing with C++ standard flags: '' ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1555: ./check ./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y stderr: stdout: ./c++.at:857: $PREPARSER ./input stderr: ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1361: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaap stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaadaf72f40->Object::Object { } Next token is token 'a' (0xaaaadaf72f40 'a') Shifting token 'a' (0xaaaadaf72f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadaf72f40 'a') -> $$ = nterm item (0xaaaadaf72f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaadaf72f90->Object::Object { 0xaaaadaf72f40 } Next token is token 'a' (0xaaaadaf72f90 'a') Shifting token 'a' (0xaaaadaf72f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadaf72f90 'a') -> $$ = nterm item (0xaaaadaf72f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaadaf72fe0->Object::Object { 0xaaaadaf72f40, 0xaaaadaf72f90 } Next token is token 'a' (0xaaaadaf72fe0 'a') Shifting token 'a' (0xaaaadaf72fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadaf72fe0 'a') -> $$ = nterm item (0xaaaadaf72fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaadaf73030->Object::Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0 } Next token is token 'a' (0xaaaadaf73030 'a') Shifting token 'a' (0xaaaadaf73030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadaf73030 'a') -> $$ = nterm item (0xaaaadaf73030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaadaf73080->Object::Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0, 0xaaaadaf73030 } Next token is token 'p' (0xaaaadaf73080 'p'Exception caught: cleaning lookahead and stack 0xaaaadaf73080->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0, 0xaaaadaf73030, 0xaaaadaf73080 } 0xaaaadaf73030->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0, 0xaaaadaf73030 } 0xaaaadaf72fe0->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0 } 0xaaaadaf72f90->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90 } 0xaaaadaf72f40->Object::~Object { 0xaaaadaf72f40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaadaf72f40->Object::Object { } Next token is token 'a' (0xaaaadaf72f40 'a') Shifting token 'a' (0xaaaadaf72f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadaf72f40 'a') -> $$ = nterm item (0xaaaadaf72f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaadaf72f90->Object::Object { 0xaaaadaf72f40 } Next token is token 'a' (0xaaaadaf72f90 'a') Shifting token 'a' (0xaaaadaf72f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadaf72f90 'a') -> $$ = nterm item (0xaaaadaf72f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaadaf72fe0->Object::Object { 0xaaaadaf72f40, 0xaaaadaf72f90 } Next token is token 'a' (0xaaaadaf72fe0 'a') Shifting token 'a' (0xaaaadaf72fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadaf72fe0 'a') -> $$ = nterm item (0xaaaadaf72fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaadaf73030->Object::Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0 } Next token is token 'a' (0xaaaadaf73030 'a') Shifting token 'a' (0xaaaadaf73030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadaf73030 'a') -> $$ = nterm item (0xaaaadaf73030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaadaf73080->Object::Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0, 0xaaaadaf73030 } Next token is token 'p' (0xaaaadaf73080 'p'Exception caught: cleaning lookahead and stack 0xaaaadaf73080->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0, 0xaaaadaf73030, 0xaaaadaf73080 } 0xaaaadaf73030->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0, 0xaaaadaf73030 } 0xaaaadaf72fe0->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0 } 0xaaaadaf72f90->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90 } 0xaaaadaf72f40->Object::~Object { 0xaaaadaf72f40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1361: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaE stderr: stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaT stderr: stdout: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaR ./c++.at:1065: $PREPARSER ./input < in stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1065: $PREPARSER ./input < in ======== Testing with C++ standard flags: '' ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: error: invalid expression ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:941: $PREPARSER ./input stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' 681. c++.at:884: ok ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 692. java.at:25: testing Java invalid directives ... ./java.at:35: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret YYParser.y stderr: stdout: stderr: stdout: ./c++.at:1066: ./check ./java.at:50: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret YYParser.y ./c++.at:851: $PREPARSER ./input stderr: ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 692. java.at:25: ok stderr: stdout: ./c++.at:1362: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input i stderr: stdout: stderr: stderr: ./c++.at:857: $PREPARSER ./input exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: 693. java.at:186: testing Java parser class and package names ... stderr: ./java.at:188: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y stderr: ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1555: $PREPARSER ./test ./c++.at:1360: $PREPARSER ./input aaaas stderr: ./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1362: $PREPARSER ./input aaaap stderr: stderr: exception caught: reduction ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1362: $PREPARSER ./input --debug aaaap ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./c++.at:1360: $PREPARSER ./input aaaal ./java.at:188: grep '[mb]4_' YYParser.y stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffcf641fd0->Object::Object { } 0xffffcf642080->Object::Object { 0xffffcf641fd0 } 0xffffcf641fd0->Object::~Object { 0xffffcf641fd0, 0xffffcf642080 } Next token is token 'a' (0xffffcf642080 'a') 0xffffcf641fc0->Object::Object { 0xffffcf642080 } 0xffffcf642080->Object::~Object { 0xffffcf641fc0, 0xffffcf642080 } Shifting token 'a' (0xffffcf641fc0 'a') 0xaaab09e922e0->Object::Object { 0xffffcf641fc0 } 0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xffffcf641fc0 } Entering state 2 Stack now 0 2 0xffffcf6420a0->Object::Object { 0xaaab09e922e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab09e922e0 'a') -> $$ = nterm item (0xffffcf6420a0 'a') 0xaaab09e922e0->Object::~Object { 0xaaab09e922e0, 0xffffcf6420a0 } 0xaaab09e922e0->Object::Object { 0xffffcf6420a0 } 0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xffffcf6420a0 } Entering state 11 Stack now 0 11 Reading a token 0xffffcf641fd0->Object::Object { 0xaaab09e922e0 } 0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xffffcf641fd0 } 0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xffffcf641fd0, 0xffffcf642080 } Next token is token 'a' (0xffffcf642080 'a') 0xffffcf641fc0->Object::Object { 0xaaab09e922e0, 0xffffcf642080 } 0xffffcf642080->Object::~Object { 0xaaab09e922e0, 0xffffcf641fc0, 0xffffcf642080 } Shifting token 'a' (0xffffcf641fc0 'a') 0xaaab09e92300->Object::Object { 0xaaab09e922e0, 0xffffcf641fc0 } 0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fc0 } Entering state 2 Stack now 0 11 2 0xffffcf6420a0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab09e92300 'a') -> $$ = nterm item (0xffffcf6420a0 'a') 0xaaab09e92300->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf6420a0 } 0xaaab09e92300->Object::Object { 0xaaab09e922e0, 0xffffcf6420a0 } 0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf6420a0 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffcf641fd0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300 } 0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fd0 } 0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fd0, 0xffffcf642080 } Next token is token 'a' (0xffffcf642080 'a') 0xffffcf641fc0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf642080 } 0xffffcf642080->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fc0, 0xffffcf642080 } Shifting token 'a' (0xffffcf641fc0 'a') 0xaaab09e92320->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fc0 } 0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fc0 } Entering state 2 Stack now 0 11 11 2 0xffffcf6420a0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab09e92320 'a') -> $$ = nterm item (0xffffcf6420a0 'a') 0xaaab09e92320->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf6420a0 } 0xaaab09e92320->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf6420a0 } 0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf6420a0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffcf641fd0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320 } 0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fd0 } 0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fd0, 0xffffcf642080 } Next token is token 'a' (0xffffcf642080 'a') 0xffffcf641fc0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf642080 } 0xffffcf642080->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fc0, 0xffffcf642080 } Shifting token 'a' (0xffffcf641fc0 'a') 0xaaab09e92340->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fc0 } 0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf641fc0 } Entering state 2 Stack now 0 11 11 11 2 0xffffcf6420a0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab09e92340 'a') -> $$ = nterm item (0xffffcf6420a0 'a') 0xaaab09e92340->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf6420a0 } 0xaaab09e92340->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf6420a0 } 0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf6420a0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffcf641fd0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340 } 0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf641fd0 } 0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf641fd0, 0xffffcf642080 } Next token is token 'p' (0xffffcf642080 'p'Exception caught: cleaning lookahead and stack 0xaaab09e92340->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf642080 } 0xaaab09e92320->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf642080 } 0xaaab09e92300->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf642080 } 0xaaab09e922e0->Object::~Object { 0xaaab09e922e0, 0xffffcf642080 } 0xffffcf642080->Object::~Object { 0xffffcf642080 } exception caught: printer end { } stdout: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 693. java.at:186: ./c++.at:1360: $PREPARSER ./input i stderr: skipped (java.at:188) Starting parse Entering state 0 Stack now 0 Reading a token 0xffffcf641fd0->Object::Object { } 0xffffcf642080->Object::Object { 0xffffcf641fd0 } 0xffffcf641fd0->Object::~Object { 0xffffcf641fd0, 0xffffcf642080 } Next token is token 'a' (0xffffcf642080 'a') 0xffffcf641fc0->Object::Object { 0xffffcf642080 } 0xffffcf642080->Object::~Object { 0xffffcf641fc0, 0xffffcf642080 } Shifting token 'a' (0xffffcf641fc0 'a') 0xaaab09e922e0->Object::Object { 0xffffcf641fc0 } 0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xffffcf641fc0 } Entering state 2 Stack now 0 2 0xffffcf6420a0->Object::Object { 0xaaab09e922e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab09e922e0 'a') -> $$ = nterm item (0xffffcf6420a0 'a') 0xaaab09e922e0->Object::~Object { 0xaaab09e922e0, 0xffffcf6420a0 } 0xaaab09e922e0->Object::Object { 0xffffcf6420a0 } 0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xffffcf6420a0 } Entering state 11 Stack now 0 11 Reading a token 0xffffcf641fd0->Object::Object { 0xaaab09e922e0 } 0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xffffcf641fd0 } 0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xffffcf641fd0, 0xffffcf642080 } Next token is token 'a' (0xffffcf642080 'a') 0xffffcf641fc0->Object::Object { 0xaaab09e922e0, 0xffffcf642080 } 0xffffcf642080->Object::~Object { 0xaaab09e922e0, 0xffffcf641fc0, 0xffffcf642080 } Shifting token 'a' (0xffffcf641fc0 'a') 0xaaab09e92300->Object::Object { 0xaaab09e922e0, 0xffffcf641fc0 } 0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fc0 } Entering state 2 Stack now 0 11 2 0xffffcf6420a0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab09e92300 'a') -> $$ = nterm item (0xffffcf6420a0 'a') 0xaaab09e92300->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf6420a0 } 0xaaab09e92300->Object::Object { 0xaaab09e922e0, 0xffffcf6420a0 } 0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf6420a0 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffcf641fd0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300 } 0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fd0 } 0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fd0, 0xffffcf642080 } Next token is token 'a' (0xffffcf642080 'a') 0xffffcf641fc0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf642080 } 0xffffcf642080->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fc0, 0xffffcf642080 } Shifting token 'a' (0xffffcf641fc0 'a') 0xaaab09e92320->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fc0 } 0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fc0 } Entering state 2 Stack now 0 11 11 2 0xffffcf6420a0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab09e92320 'a') -> $$ = nterm item (0xffffcf6420a0 'a') 0xaaab09e92320->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf6420a0 } 0xaaab09e92320->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf6420a0 } 0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf6420a0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffcf641fd0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320 } 0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fd0 } 0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fd0, 0xffffcf642080 } Next token is token 'a' (0xffffcf642080 'a') 0xffffcf641fc0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf642080 } 0xffffcf642080->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fc0, 0xffffcf642080 } Shifting token 'a' (0xffffcf641fc0 'a') 0xaaab09e92340->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fc0 } 0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf641fc0 } Entering state 2 Stack now 0 11 11 11 2 0xffffcf6420a0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab09e92340 'a') -> $$ = nterm item (0xffffcf6420a0 'a') 0xaaab09e92340->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf6420a0 } 0xaaab09e92340->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf6420a0 } 0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf6420a0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffcf641fd0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340 } 0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf641fd0 } 0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf641fd0, 0xffffcf642080 } Next token is token 'p' (0xffffcf642080 'p'Exception caught: cleaning lookahead and stack 0xaaab09e92340->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf642080 } 0xaaab09e92320->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf642080 } 0xaaab09e92300->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf642080 } 0xaaab09e922e0->Object::~Object { 0xaaab09e922e0, 0xffffcf642080 } 0xffffcf642080->Object::~Object { 0xffffcf642080 } exception caught: printer end { } ./c++.at:1362: grep '^exception caught: printer$' stderr stderr: exception caught: initial-action ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1360: $PREPARSER ./input aaaap stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1360: $PREPARSER ./input --debug aaaap stderr: ./c++.at:1555: ./check ./c++.at:1362: $PREPARSER ./input aaaaE Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae734ef40->Object::Object { } Next token is token 'a' (0xaaaae734ef40 'a') Shifting token 'a' (0xaaaae734ef40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae734ef40 'a') -> $$ = nterm item (0xaaaae734ef40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaae734ef90->Object::Object { 0xaaaae734ef40 } Next token is token 'a' (0xaaaae734ef90 'a') Shifting token 'a' (0xaaaae734ef90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae734ef90 'a') -> $$ = nterm item (0xaaaae734ef90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaae734efe0->Object::Object { 0xaaaae734ef40, 0xaaaae734ef90 } Next token is token 'a' (0xaaaae734efe0 'a') Shifting token 'a' (0xaaaae734efe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae734efe0 'a') -> $$ = nterm item (0xaaaae734efe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaae734f030->Object::Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0 } Next token is token 'a' (0xaaaae734f030 'a') Shifting token 'a' (0xaaaae734f030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae734f030 'a') -> $$ = nterm item (0xaaaae734f030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaae734f080->Object::Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0, 0xaaaae734f030 } Next token is token 'p' (0xaaaae734f080 'p'Exception caught: cleaning lookahead and stack 0xaaaae734f080->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0, 0xaaaae734f030, 0xaaaae734f080 } 0xaaaae734f030->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0, 0xaaaae734f030 } 0xaaaae734efe0->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0 } 0xaaaae734ef90->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90 } 0xaaaae734ef40->Object::~Object { 0xaaaae734ef40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae734ef40->Object::Object { } Next token is token 'a' (0xaaaae734ef40 'a') Shifting token 'a' (0xaaaae734ef40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae734ef40 'a') -> $$ = nterm item (0xaaaae734ef40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaae734ef90->Object::Object { 0xaaaae734ef40 } Next token is token 'a' (0xaaaae734ef90 'a') Shifting token 'a' (0xaaaae734ef90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae734ef90 'a') -> $$ = nterm item (0xaaaae734ef90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaae734efe0->Object::Object { 0xaaaae734ef40, 0xaaaae734ef90 } Next token is token 'a' (0xaaaae734efe0 'a') Shifting token 'a' (0xaaaae734efe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae734efe0 'a') -> $$ = nterm item (0xaaaae734efe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaae734f030->Object::Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0 } Next token is token 'a' (0xaaaae734f030 'a') Shifting token 'a' (0xaaaae734f030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae734f030 'a') -> $$ = nterm item (0xaaaae734f030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaae734f080->Object::Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0, 0xaaaae734f030 } Next token is token 'p' (0xaaaae734f080 'p'Exception caught: cleaning lookahead and stack 0xaaaae734f080->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0, 0xaaaae734f030, 0xaaaae734f080 } 0xaaaae734f030->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0, 0xaaaae734f030 } 0xaaaae734efe0->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0 } 0xaaaae734ef90->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90 } 0xaaaae734ef40->Object::~Object { 0xaaaae734ef40 } exception caught: printer end { } ./c++.at:1360: grep '^exception caught: printer$' stderr ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae ./c++.at:1362: $PREPARSER ./input aaaaT stderr: 694. java.at:217: testing Java parser class modifiers ... ./java.at:219: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./java.at:219: grep '[mb]4_' YYParser.y stdout: 694. java.at:217: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr skipped (java.at:219) ./c++.at:1362: $PREPARSER ./input aaaaR stderr: ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./c++.at:1360: $PREPARSER ./input aaaaE ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 695. java.at:287: testing Java parser class extends and implements ... ======== Testing with C++ standard flags: '' ./java.at:289: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:1360: $PREPARSER ./input aaaaT stdout: ./c++.at:1064: $PREPARSER ./input < in stderr: stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./java.at:289: grep '[mb]4_' YYParser.y ./c++.at:1360: $PREPARSER ./input aaaaR error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: stdout: ./c++.at:1363: $PREPARSER ./input aaaas ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1064: $PREPARSER ./input < in exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 695. java.at:287: ======== Testing with C++ standard flags: '' skipped (java.at:289) stderr: ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1363: $PREPARSER ./input aaaal error: invalid character stderr: ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: exception caught: yylex ./c++.at:1361: $PREPARSER ./input aaaas ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' exception caught: reduction ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ./c++.at:1363: $PREPARSER ./input i ./c++.at:1361: $PREPARSER ./input aaaal stderr: stderr: exception caught: initial-action exception caught: yylex ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input i stderr: 696. java.at:307: testing Java %parse-param and %lex-param ... ./java.at:309: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y ./c++.at:1363: $PREPARSER ./input aaaap exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaap stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: ./java.at:309: grep '[mb]4_' YYParser.y ./c++.at:1361: $PREPARSER ./input --debug aaaap stdout: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffdb7dd660->Object::Object { } 0xffffdb7dd760->Object::Object { 0xffffdb7dd660 } 0xffffdb7dd660->Object::~Object { 0xffffdb7dd660, 0xffffdb7dd760 } Next token is token 'a' (0xffffdb7dd760 'a') 0xffffdb7dd6a0->Object::Object { 0xffffdb7dd760 } 0xffffdb7dd760->Object::~Object { 0xffffdb7dd6a0, 0xffffdb7dd760 } Shifting token 'a' (0xffffdb7dd6a0 'a') 0xaaab151902e0->Object::Object { 0xffffdb7dd6a0 } 0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xffffdb7dd6a0 } Entering state 1 Stack now 0 1 0xffffdb7dd780->Object::Object { 0xaaab151902e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab151902e0 'a') -> $$ = nterm item (0xffffdb7dd780 'a') 0xaaab151902e0->Object::~Object { 0xaaab151902e0, 0xffffdb7dd780 } 0xaaab151902e0->Object::Object { 0xffffdb7dd780 } 0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xffffdb7dd780 } Entering state 10 Stack now 0 10 Reading a token 0xffffdb7dd660->Object::Object { 0xaaab151902e0 } 0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xffffdb7dd660 } 0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xffffdb7dd660, 0xffffdb7dd760 } Next token is token 'a' (0xffffdb7dd760 'a') 0xffffdb7dd6a0->Object::Object { 0xaaab151902e0, 0xffffdb7dd760 } 0xffffdb7dd760->Object::~Object { 0xaaab151902e0, 0xffffdb7dd6a0, 0xffffdb7dd760 } Shifting token 'a' (0xffffdb7dd6a0 'a') 0xaaab15190300->Object::Object { 0xaaab151902e0, 0xffffdb7dd6a0 } 0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd6a0 } Entering state 1 Stack now 0 10 1 0xffffdb7dd780->Object::Object { 0xaaab151902e0, 0xaaab15190300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab15190300 'a') -> $$ = nterm item (0xffffdb7dd780 'a') 0xaaab15190300->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd780 } 0xaaab15190300->Object::Object { 0xaaab151902e0, 0xffffdb7dd780 } 0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd780 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffdb7dd660->Object::Object { 0xaaab151902e0, 0xaaab15190300 } 0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd660 } 0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd660, 0xffffdb7dd760 } Next token is token 'a' (0xffffdb7dd760 'a') 0xffffdb7dd6a0->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd760 } 0xffffdb7dd760->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd6a0, 0xffffdb7dd760 } Shifting token 'a' (0xffffdb7dd6a0 'a') 0xaaab15190320->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd6a0 } 0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd6a0 } Entering state 1 Stack now 0 10 10 1 0xffffdb7dd780->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab15190320 'a') -> $$ = nterm item (0xffffdb7dd780 'a') 0xaaab15190320->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd780 } 0xaaab15190320->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd780 } 0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd780 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffdb7dd660->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320 } 0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd660 } 0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd660, 0xffffdb7dd760 } Next token is token 'a' (0xffffdb7dd760 'a') 0xffffdb7dd6a0->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd760 } 0xffffdb7dd760->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd6a0, 0xffffdb7dd760 } Shifting token 'a' (0xffffdb7dd6a0 'a') 0xaaab15190340->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd6a0 } 0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd6a0 } Entering state 1 Stack now 0 10 10 10 1 0xffffdb7dd780->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab15190340 'a') -> $$ = nterm item (0xffffdb7dd780 'a') 0xaaab15190340->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd780 } 0xaaab15190340->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd780 } 0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd780 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffdb7dd660->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340 } 0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd660 } 0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd660, 0xffffdb7dd760 } Next token is token 'p' (0xffffdb7dd760 'p'Exception caught: cleaning lookahead and stack 0xaaab15190340->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd760 } 0xaaab15190320->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd760 } 0xaaab15190300->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd760 } 0xaaab151902e0->Object::~Object { 0xaaab151902e0, 0xffffdb7dd760 } 0xffffdb7dd760->Object::~Object { 0xffffdb7dd760 } exception caught: printer end { } stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaadd188f40->Object::Object { } Next token is token 'a' (0xaaaadd188f40 'a') Shifting token 'a' (0xaaaadd188f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadd188f40 'a') -> $$ = nterm item (0xaaaadd188f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaadd188f90->Object::Object { 0xaaaadd188f40 } Next token is token 'a' (0xaaaadd188f90 'a') Shifting token 'a' (0xaaaadd188f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadd188f90 'a') -> $$ = nterm item (0xaaaadd188f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaadd188fe0->Object::Object { 0xaaaadd188f40, 0xaaaadd188f90 } Next token is token 'a' (0xaaaadd188fe0 'a') Shifting token 'a' (0xaaaadd188fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadd188fe0 'a') -> $$ = nterm item (0xaaaadd188fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaadd189030->Object::Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0 } Next token is token 'a' (0xaaaadd189030 'a') Shifting token 'a' (0xaaaadd189030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadd189030 'a') -> $$ = nterm item (0xaaaadd189030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaadd189080->Object::Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0, 0xaaaadd189030 } Next token is token 'p' (0xaaaadd189080 'p'Exception caught: cleaning lookahead and stack 0xaaaadd189080->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0, 0xaaaadd189030, 0xaaaadd189080 } 0xaaaadd189030->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0, 0xaaaadd189030 } 0xaaaadd188fe0->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0 } 0xaaaadd188f90->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90 } 0xaaaadd188f40->Object::~Object { 0xaaaadd188f40 } exception caught: printer end { } ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 696. java.at:307: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffdb7dd660->Object::Object { } 0xffffdb7dd760->Object::Object { 0xffffdb7dd660 } 0xffffdb7dd660->Object::~Object { 0xffffdb7dd660, 0xffffdb7dd760 } Next token is token 'a' (0xffffdb7dd760 'a') 0xffffdb7dd6a0->Object::Object { 0xffffdb7dd760 } 0xffffdb7dd760->Object::~Object { 0xffffdb7dd6a0, 0xffffdb7dd760 } Shifting token 'a' (0xffffdb7dd6a0 'a') 0xaaab151902e0->Object::Object { 0xffffdb7dd6a0 } 0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xffffdb7dd6a0 } Entering state 1 Stack now 0 1 0xffffdb7dd780->Object::Object { 0xaaab151902e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab151902e0 'a') -> $$ = nterm item (0xffffdb7dd780 'a') 0xaaab151902e0->Object::~Object { 0xaaab151902e0, 0xffffdb7dd780 } 0xaaab151902e0->Object::Object { 0xffffdb7dd780 } 0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xffffdb7dd780 } Entering state 10 Stack now 0 10 Reading a token 0xffffdb7dd660->Object::Object { 0xaaab151902e0 } 0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xffffdb7dd660 } 0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xffffdb7dd660, 0xffffdb7dd760 } Next token is token 'a' (0xffffdb7dd760 'a') 0xffffdb7dd6a0->Object::Object { 0xaaab151902e0, 0xffffdb7dd760 } 0xffffdb7dd760->Object::~Object { 0xaaab151902e0, 0xffffdb7dd6a0, 0xffffdb7dd760 } Shifting token 'a' (0xffffdb7dd6a0 'a') 0xaaab15190300->Object::Object { 0xaaab151902e0, 0xffffdb7dd6a0 } 0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd6a0 } Entering state 1 Stack now 0 10 1 0xffffdb7dd780->Object::Object { 0xaaab151902e0, 0xaaab15190300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab15190300 'a') -> $$ = nterm item (0xffffdb7dd780 'a') 0xaaab15190300->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd780 } 0xaaab15190300->Object::Object { 0xaaab151902e0, 0xffffdb7dd780 } 0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd780 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffdb7dd660->Object::Object { 0xaaab151902e0, 0xaaab15190300 } 0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd660 } 0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd660, 0xffffdb7dd760 } Next token is token 'a' (0xffffdb7dd760 'a') 0xffffdb7dd6a0->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd760 } 0xffffdb7dd760->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd6a0, 0xffffdb7dd760 } Shifting token 'a' (0xffffdb7dd6a0 'a') 0xaaab15190320->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd6a0 } 0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd6a0 } Entering state 1 Stack now 0 10 10 1 0xffffdb7dd780->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab15190320 'a') -> $$ = nterm item (0xffffdb7dd780 'a') 0xaaab15190320->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd780 } 0xaaab15190320->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd780 } 0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd780 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffdb7dd660->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320 } 0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd660 } 0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd660, 0xffffdb7dd760 } Next token is token 'a' (0xffffdb7dd760 'a') 0xffffdb7dd6a0->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd760 } 0xffffdb7dd760->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd6a0, 0xffffdb7dd760 } Shifting token 'a' (0xffffdb7dd6a0 'a') 0xaaab15190340->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd6a0 } 0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd6a0 } Entering state 1 Stack now 0 10 10 10 1 0xffffdb7dd780->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab15190340 'a') -> $$ = nterm item (0xffffdb7dd780 'a') 0xaaab15190340->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd780 } 0xaaab15190340->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd780 } 0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd780 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffdb7dd660->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340 } 0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd660 } 0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd660, 0xffffdb7dd760 } Next token is token 'p' (0xffffdb7dd760 'p'Exception caught: cleaning lookahead and stack 0xaaab15190340->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd760 } 0xaaab15190320->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd760 } 0xaaab15190300->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd760 } 0xaaab151902e0->Object::~Object { 0xaaab151902e0, 0xffffdb7dd760 } 0xffffdb7dd760->Object::~Object { 0xffffdb7dd760 } exception caught: printer end { } skipped (java.at:309) ./c++.at:1363: grep '^exception caught: printer$' stderr stdout: stderr: exception caught: printer ./c++.at:1363: $PREPARSER ./input aaaae Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaadd188f40->Object::Object { } Next token is token 'a' (0xaaaadd188f40 'a') Shifting token 'a' (0xaaaadd188f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadd188f40 'a') -> $$ = nterm item (0xaaaadd188f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaadd188f90->Object::Object { 0xaaaadd188f40 } Next token is token 'a' (0xaaaadd188f90 'a') Shifting token 'a' (0xaaaadd188f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadd188f90 'a') -> $$ = nterm item (0xaaaadd188f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaadd188fe0->Object::Object { 0xaaaadd188f40, 0xaaaadd188f90 } Next token is token 'a' (0xaaaadd188fe0 'a') Shifting token 'a' (0xaaaadd188fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadd188fe0 'a') -> $$ = nterm item (0xaaaadd188fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaadd189030->Object::Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0 } Next token is token 'a' (0xaaaadd189030 'a') Shifting token 'a' (0xaaaadd189030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadd189030 'a') -> $$ = nterm item (0xaaaadd189030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaadd189080->Object::Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0, 0xaaaadd189030 } Next token is token 'p' (0xaaaadd189080 'p'Exception caught: cleaning lookahead and stack 0xaaaadd189080->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0, 0xaaaadd189030, 0xaaaadd189080 } 0xaaaadd189030->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0, 0xaaaadd189030 } 0xaaaadd188fe0->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0 } 0xaaaadd188f90->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90 } 0xaaaadd188f40->Object::~Object { 0xaaaadd188f40 } exception caught: printer end { } stderr: stdout: ./c++.at:1361: grep '^exception caught: printer$' stderr ./c++.at:851: $PREPARSER ./input stderr: stdout: exception caught: printer ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaae stderr: ======== Testing with C++ standard flags: '' ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: exception caught: syntax error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaE ./c++.at:1361: $PREPARSER ./input aaaaE stderr: 697. java.at:381: testing Java throws specifications ... ./java.at:441: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./java.at:441: grep '[mb]4_' YYParser.y stdout: ./c++.at:1361: $PREPARSER ./input aaaaT stderr: 697. java.at:381: ./c++.at:1363: $PREPARSER ./input aaaaT ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: skipped (java.at:441) ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaR ./c++.at:1363: $PREPARSER ./input aaaaR stderr: stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:857: $PREPARSER ./input stderr: ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 698. java.at:470: testing Java constructor init and init_throws ... ./java.at:475: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y stderr: stdout: 689. c++.at:1371: ok ./java.at:475: grep '[mb]4_' YYParser.y stdout: 698. java.at:470: skipped (java.at:475) 699. java.at:497: testing Java value, position, and location types ... ./java.at:499: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y ./java.at:499: grep '[mb]4_' YYParser.y stdout: 700. java.at:528: testing Java syntax error handling without error token ... ./java.at:579: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret YYParser.y 699. java.at:497: skipped (java.at:499) stderr: stdout: ./c++.at:1065: $PREPARSER ./input < in 700. java.at:528: stderr: skipped (java.at:580) error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 701. javapush.at:172: testing Trivial Push Parser with api.push-pull verification ... ./javapush.at:181: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dapi.push-pull=pull -o Main.java input.y ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in ./javapush.at:182: grep -c '^.*public boolean parse().*$' Main.java 702. javapush.at:217: testing Trivial Push Parser with %initial-action ... stderr: error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./javapush.at:227: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dapi.push-pull=push -o Main.java input.y ./javapush.at:187: grep -c '^.*public int push_parse(int yylextoken, Object yylexval).*$' Main.java ======== Testing with C++ standard flags: '' ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ./javapush.at:191: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dapi.push-pull=both -o Main.java input.y ./javapush.at:228: grep -c '^System.err.println("Initial action invoked");$' Main.java ./javapush.at:192: grep -c '^.*public boolean parse().*$' Main.java 702. javapush.at:217: skipped (javapush.at:230) ./javapush.at:195: grep -c '^.*public int push_parse(int yylextoken, Object yylexval).*$' Main.java stderr: stdout: ./c++.at:851: $PREPARSER ./input stderr: stderr: ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1555: $PREPARSER ./test ./javapush.at:199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dapi.push-pull=push -o Main.java input.y ======== Testing with C++ standard flags: '' stderr: ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./javapush.at:200: grep -c '^.*public boolean parse().*$' Main.java ./javapush.at:203: grep -c '^.*public int push_parse(int yylextoken, Object yylexval).*$' Main.java stderr: stdout: ./c++.at:1555: ./check 703. d.at:103: testing D parser class extends and implements ... ./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y ./d.at:106: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y 701. javapush.at:172: ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS skipped (javapush.at:207) ./d.at:106: grep '[mb]4_' YYParser.y stdout: 703. d.at:103: skipped (d.at:106) 704. d.at:138: testing D parser class api.token.raw true by default ... ./d.at:141: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y ./d.at:141: grep '[mb]4_' YYParser.y stdout: 705. cxx-type.at:409: testing GLR: Resolve ambiguity, impure, no locations ... 704. d.at:138: skipped (d.at:141) ./cxx-type.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y stderr: stdout: ./c++.at:857: $PREPARSER ./input stderr: types.y:77.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stderr: ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:410: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS ======== Testing with C++ standard flags: '' ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 706. cxx-type.at:415: testing GLR: Resolve ambiguity, impure, locations ... ./cxx-type.at:416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y stderr: stderr: types.y:87.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stdout: ./c++.at:1362: $PREPARSER ./input aaaas ./cxx-type.at:416: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS stderr: exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1362: $PREPARSER ./input aaaal stdout: stderr: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaal stderr: ./c++.at:1362: $PREPARSER ./input aaaap exception caught: yylex ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input i ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: exception caught: initial-action stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token 0xffffde9c34f0->Object::Object { } 0xffffde9c35a0->Object::Object { 0xffffde9c34f0 } 0xffffde9c34f0->Object::~Object { 0xffffde9c34f0, 0xffffde9c35a0 } Next token is token 'a' (0xffffde9c35a0 'a') 0xffffde9c34e0->Object::Object { 0xffffde9c35a0 } 0xffffde9c35a0->Object::~Object { 0xffffde9c34e0, 0xffffde9c35a0 } Shifting token 'a' (0xffffde9c34e0 'a') 0xaaaafb6772e0->Object::Object { 0xffffde9c34e0 } 0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c34e0 } Entering state 2 Stack now 0 2 0xffffde9c35c0->Object::Object { 0xaaaafb6772e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafb6772e0 'a') -> $$ = nterm item (0xffffde9c35c0 'a') 0xaaaafb6772e0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c35c0 } 0xaaaafb6772e0->Object::Object { 0xffffde9c35c0 } 0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c35c0 } Entering state 11 Stack now 0 11 Reading a token 0xffffde9c34f0->Object::Object { 0xaaaafb6772e0 } 0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xffffde9c34f0 } 0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c34f0, 0xffffde9c35a0 } Next token is token 'a' (0xffffde9c35a0 'a') 0xffffde9c34e0->Object::Object { 0xaaaafb6772e0, 0xffffde9c35a0 } 0xffffde9c35a0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c34e0, 0xffffde9c35a0 } Shifting token 'a' (0xffffde9c34e0 'a') 0xaaaafb677300->Object::Object { 0xaaaafb6772e0, 0xffffde9c34e0 } 0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34e0 } Entering state 2 Stack now 0 11 2 0xffffde9c35c0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafb677300 'a') -> $$ = nterm item (0xffffde9c35c0 'a') 0xaaaafb677300->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35c0 } 0xaaaafb677300->Object::Object { 0xaaaafb6772e0, 0xffffde9c35c0 } 0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35c0 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffde9c34f0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300 } 0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34f0 } 0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34f0, 0xffffde9c35a0 } Next token is token 'a' (0xffffde9c35a0 'a') 0xffffde9c34e0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35a0 } 0xffffde9c35a0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34e0, 0xffffde9c35a0 } Shifting token 'a' (0xffffde9c34e0 'a') 0xaaaafb677320->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34e0 } 0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34e0 } Entering state 2 Stack now 0 11 11 2 0xffffde9c35c0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafb677320 'a') -> $$ = nterm item (0xffffde9c35c0 'a') 0xaaaafb677320->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35c0 } 0xaaaafb677320->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35c0 } 0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35c0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffde9c34f0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320 } 0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34f0 } 0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34f0, 0xffffde9c35a0 } Next token is token 'a' (0xffffde9c35a0 'a') 0xffffde9c34e0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35a0 } 0xffffde9c35a0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34e0, 0xffffde9c35a0 } Shifting token 'a' (0xffffde9c34e0 'a') 0xaaaafb677340->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34e0 } 0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c34e0 } Entering state 2 Stack now 0 11 11 11 2 0xffffde9c35c0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafb677340 'a') -> $$ = nterm item (0xffffde9c35c0 'a') 0xaaaafb677340->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c35c0 } 0xaaaafb677340->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35c0 } 0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c35c0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffde9c34f0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340 } 0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c34f0 } 0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c34f0, 0xffffde9c35a0 } Next token is token 'p' (0xffffde9c35a0 'p'Exception caught: cleaning lookahead and stack 0xaaaafb677340->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c35a0 } 0xaaaafb677320->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35a0 } 0xaaaafb677300->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35a0 } 0xaaaafb6772e0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c35a0 } 0xffffde9c35a0->Object::~Object { 0xffffde9c35a0 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaap stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffde9c34f0->Object::Object { } 0xffffde9c35a0->Object::Object { 0xffffde9c34f0 } 0xffffde9c34f0->Object::~Object { 0xffffde9c34f0, 0xffffde9c35a0 } Next token is token 'a' (0xffffde9c35a0 'a') 0xffffde9c34e0->Object::Object { 0xffffde9c35a0 } 0xffffde9c35a0->Object::~Object { 0xffffde9c34e0, 0xffffde9c35a0 } Shifting token 'a' (0xffffde9c34e0 'a') 0xaaaafb6772e0->Object::Object { 0xffffde9c34e0 } 0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c34e0 } Entering state 2 Stack now 0 2 0xffffde9c35c0->Object::Object { 0xaaaafb6772e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafb6772e0 'a') -> $$ = nterm item (0xffffde9c35c0 'a') 0xaaaafb6772e0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c35c0 } 0xaaaafb6772e0->Object::Object { 0xffffde9c35c0 } 0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c35c0 } Entering state 11 Stack now 0 11 Reading a token 0xffffde9c34f0->Object::Object { 0xaaaafb6772e0 } 0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xffffde9c34f0 } 0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c34f0, 0xffffde9c35a0 } Next token is token 'a' (0xffffde9c35a0 'a') 0xffffde9c34e0->Object::Object { 0xaaaafb6772e0, 0xffffde9c35a0 } 0xffffde9c35a0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c34e0, 0xffffde9c35a0 } Shifting token 'a' (0xffffde9c34e0 'a') 0xaaaafb677300->Object::Object { 0xaaaafb6772e0, 0xffffde9c34e0 } 0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34e0 } Entering state 2 Stack now 0 11 2 0xffffde9c35c0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafb677300 'a') -> $$ = nterm item (0xffffde9c35c0 'a') 0xaaaafb677300->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35c0 } 0xaaaafb677300->Object::Object { 0xaaaafb6772e0, 0xffffde9c35c0 } 0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35c0 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffde9c34f0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300 } 0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34f0 } 0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34f0, 0xffffde9c35a0 } Next token is token 'a' (0xffffde9c35a0 'a') 0xffffde9c34e0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35a0 } 0xffffde9c35a0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34e0, 0xffffde9c35a0 } Shifting token 'a' (0xffffde9c34e0 'a') 0xaaaafb677320->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34e0 } 0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34e0 } Entering state 2 Stack now 0 11 11 2 0xffffde9c35c0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafb677320 'a') -> $$ = nterm item (0xffffde9c35c0 'a') 0xaaaafb677320->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35c0 } 0xaaaafb677320->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35c0 } 0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35c0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffde9c34f0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320 } 0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34f0 } 0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34f0, 0xffffde9c35a0 } Next token is token 'a' (0xffffde9c35a0 'a') 0xffffde9c34e0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35a0 } 0xffffde9c35a0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34e0, 0xffffde9c35a0 } Shifting token 'a' (0xffffde9c34e0 'a') 0xaaaafb677340->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34e0 } 0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c34e0 } Entering state 2 Stack now 0 11 11 11 2 0xffffde9c35c0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafb677340 'a') -> $$ = nterm item (0xffffde9c35c0 'a') 0xaaaafb677340->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c35c0 } 0xaaaafb677340->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35c0 } 0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c35c0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffde9c34f0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340 } 0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c34f0 } 0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c34f0, 0xffffde9c35a0 } Next token is token 'p' (0xffffde9c35a0 'p'Exception caught: cleaning lookahead and stack 0xaaaafb677340->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c35a0 } 0xaaaafb677320->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35a0 } 0xaaaafb677300->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35a0 } 0xaaaafb6772e0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c35a0 } 0xffffde9c35a0->Object::~Object { 0xffffde9c35a0 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae ./c++.at:1360: $PREPARSER ./input --debug aaaap stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaab051e6f40->Object::Object { } Next token is token 'a' (0xaaab051e6f40 'a') Shifting token 'a' (0xaaab051e6f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab051e6f40 'a') -> $$ = nterm item (0xaaab051e6f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaab051e6f90->Object::Object { 0xaaab051e6f40 } Next token is token 'a' (0xaaab051e6f90 'a') Shifting token 'a' (0xaaab051e6f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab051e6f90 'a') -> $$ = nterm item (0xaaab051e6f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaab051e6fe0->Object::Object { 0xaaab051e6f40, 0xaaab051e6f90 } Next token is token 'a' (0xaaab051e6fe0 'a') Shifting token 'a' (0xaaab051e6fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab051e6fe0 'a') -> $$ = nterm item (0xaaab051e6fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaab051e7030->Object::Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0 } Next token is token 'a' (0xaaab051e7030 'a') Shifting token 'a' (0xaaab051e7030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab051e7030 'a') -> $$ = nterm item (0xaaab051e7030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaab051e7080->Object::Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0, 0xaaab051e7030 } Next token is token 'p' (0xaaab051e7080 'p'Exception caught: cleaning lookahead and stack 0xaaab051e7080->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0, 0xaaab051e7030, 0xaaab051e7080 } 0xaaab051e7030->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0, 0xaaab051e7030 } 0xaaab051e6fe0->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0 } 0xaaab051e6f90->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90 } 0xaaab051e6f40->Object::~Object { 0xaaab051e6f40 } exception caught: printer end { } stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: syntax error stdout: ./c++.at:1361: $PREPARSER ./input aaaas stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaab051e6f40->Object::Object { } Next token is token 'a' (0xaaab051e6f40 'a') Shifting token 'a' (0xaaab051e6f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab051e6f40 'a') -> $$ = nterm item (0xaaab051e6f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaab051e6f90->Object::Object { 0xaaab051e6f40 } Next token is token 'a' (0xaaab051e6f90 'a') Shifting token 'a' (0xaaab051e6f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab051e6f90 'a') -> $$ = nterm item (0xaaab051e6f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaab051e6fe0->Object::Object { 0xaaab051e6f40, 0xaaab051e6f90 } Next token is token 'a' (0xaaab051e6fe0 'a') Shifting token 'a' (0xaaab051e6fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab051e6fe0 'a') -> $$ = nterm item (0xaaab051e6fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaab051e7030->Object::Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0 } Next token is token 'a' (0xaaab051e7030 'a') Shifting token 'a' (0xaaab051e7030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab051e7030 'a') -> $$ = nterm item (0xaaab051e7030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaab051e7080->Object::Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0, 0xaaab051e7030 } Next token is token 'p' (0xaaab051e7080 'p'Exception caught: cleaning lookahead and stack 0xaaab051e7080->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0, 0xaaab051e7030, 0xaaab051e7080 } 0xaaab051e7030->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0, 0xaaab051e7030 } 0xaaab051e6fe0->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0 } 0xaaab051e6f90->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90 } 0xaaab051e6f40->Object::~Object { 0xaaab051e6f40 } exception caught: printer end { } ./c++.at:1360: grep '^exception caught: printer$' stderr exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1362: $PREPARSER ./input aaaaE exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae stderr: exception caught: syntax error, unexpected end of file, expecting 'a' stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaal ./c++.at:1360: $PREPARSER ./input aaaaE stderr: exception caught: yylex ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaT stderr: stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1362: $PREPARSER ./input aaaaR stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1361: $PREPARSER ./input i ======== Testing with C++ standard flags: '' ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:851: $PREPARSER ./input stderr: stderr: ./c++.at:1360: $PREPARSER ./input aaaaT exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1360: $PREPARSER ./input aaaaR ./c++.at:1361: $PREPARSER ./input aaaap stderr: stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaad4bb8f40->Object::Object { } Next token is token 'a' (0xaaaad4bb8f40 'a') Shifting token 'a' (0xaaaad4bb8f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaad4bb8f40 'a') -> $$ = nterm item (0xaaaad4bb8f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaad4bb8f90->Object::Object { 0xaaaad4bb8f40 } Next token is token 'a' (0xaaaad4bb8f90 'a') Shifting token 'a' (0xaaaad4bb8f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaad4bb8f90 'a') -> $$ = nterm item (0xaaaad4bb8f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaad4bb8fe0->Object::Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90 } Next token is token 'a' (0xaaaad4bb8fe0 'a') Shifting token 'a' (0xaaaad4bb8fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaad4bb8fe0 'a') -> $$ = nterm item (0xaaaad4bb8fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaad4bb9030->Object::Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0 } Next token is token 'a' (0xaaaad4bb9030 'a') Shifting token 'a' (0xaaaad4bb9030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaad4bb9030 'a') -> $$ = nterm item (0xaaaad4bb9030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaad4bb9080->Object::Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0, 0xaaaad4bb9030 } Next token is token 'p' (0xaaaad4bb9080 'p'Exception caught: cleaning lookahead and stack 0xaaaad4bb9080->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0, 0xaaaad4bb9030, 0xaaaad4bb9080 } 0xaaaad4bb9030->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0, 0xaaaad4bb9030 } 0xaaaad4bb8fe0->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0 } 0xaaaad4bb8f90->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90 } 0xaaaad4bb8f40->Object::~Object { 0xaaaad4bb8f40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaad4bb8f40->Object::Object { } Next token is token 'a' (0xaaaad4bb8f40 'a') Shifting token 'a' (0xaaaad4bb8f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaad4bb8f40 'a') -> $$ = nterm item (0xaaaad4bb8f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaad4bb8f90->Object::Object { 0xaaaad4bb8f40 } Next token is token 'a' (0xaaaad4bb8f90 'a') Shifting token 'a' (0xaaaad4bb8f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaad4bb8f90 'a') -> $$ = nterm item (0xaaaad4bb8f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaad4bb8fe0->Object::Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90 } Next token is token 'a' (0xaaaad4bb8fe0 'a') Shifting token 'a' (0xaaaad4bb8fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaad4bb8fe0 'a') -> $$ = nterm item (0xaaaad4bb8fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaad4bb9030->Object::Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0 } Next token is token 'a' (0xaaaad4bb9030 'a') Shifting token 'a' (0xaaaad4bb9030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaad4bb9030 'a') -> $$ = nterm item (0xaaaad4bb9030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaad4bb9080->Object::Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0, 0xaaaad4bb9030 } Next token is token 'p' (0xaaaad4bb9080 'p'Exception caught: cleaning lookahead and stack 0xaaaad4bb9080->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0, 0xaaaad4bb9030, 0xaaaad4bb9080 } 0xaaaad4bb9030->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0, 0xaaaad4bb9030 } 0xaaaad4bb8fe0->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0 } 0xaaaad4bb8f90->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90 } 0xaaaad4bb8f40->Object::~Object { 0xaaaad4bb8f40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1361: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stdout: stdout: ./cxx-type.at:412: $PREPARSER ./types test-input stderr: syntax error ./cxx-type.at:412: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:412: $PREPARSER ./types -p test-input ./c++.at:1363: $PREPARSER ./input aaaas stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -stderr: > $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () ./cxx-type.at:412: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaE stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () 705. cxx-type.at:409: ok stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaal stderr: ./c++.at:1361: $PREPARSER ./input aaaaT exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stdout: ./c++.at:1066: $PREPARSER ./input < in ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaR stderr: stderr: stderr: stderr: stdout: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1555: $PREPARSER ./test ./c++.at:857: $PREPARSER ./input stderr: stderr: ./c++.at:1363: $PREPARSER ./input i error: invalid expression caught error error: invalid character caught error ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' 707. cxx-type.at:420: testing GLR: Resolve ambiguity, pure, no locations ... ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ======== Testing with C++ standard flags: '' ./cxx-type.at:421: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./c++.at:1363: $PREPARSER ./input aaaap ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1066: $PREPARSER ./input < in ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: types.y:77.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stderr: ./cxx-type.at:421: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS stderr: error: invalid character stdout: ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:417: $PREPARSER ./types test-input stderr: ./c++.at:1363: $PREPARSER ./input --debug aaaap 17.5: syntax error ./cxx-type.at:417: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:417: $PREPARSER ./types -p test-input stderr: stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) ./cxx-type.at:417: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc0c137e0->Object::Object { } 0xffffc0c138e0->Object::Object { 0xffffc0c137e0 } 0xffffc0c137e0->Object::~Object { 0xffffc0c137e0, 0xffffc0c138e0 } Next token is token 'a' (0xffffc0c138e0 'a') 0xffffc0c13820->Object::Object { 0xffffc0c138e0 } 0xffffc0c138e0->Object::~Object { 0xffffc0c13820, 0xffffc0c138e0 } Shifting token 'a' (0xffffc0c13820 'a') 0xaaaadf0782e0->Object::Object { 0xffffc0c13820 } 0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13820 } Entering state 1 Stack now 0 1 0xffffc0c13900->Object::Object { 0xaaaadf0782e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadf0782e0 'a') -> $$ = nterm item (0xffffc0c13900 'a') 0xaaaadf0782e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13900 } 0xaaaadf0782e0->Object::Object { 0xffffc0c13900 } 0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13900 } Entering state 10 Stack now 0 10 Reading a token 0xffffc0c137e0->Object::Object { 0xaaaadf0782e0 } 0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xffffc0c137e0 } 0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c137e0, 0xffffc0c138e0 } Next token is token 'a' (0xffffc0c138e0 'a') 0xffffc0c13820->Object::Object { 0xaaaadf0782e0, 0xffffc0c138e0 } 0xffffc0c138e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13820, 0xffffc0c138e0 } Shifting token 'a' (0xffffc0c13820 'a') 0xaaaadf078300->Object::Object { 0xaaaadf0782e0, 0xffffc0c13820 } 0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13820 } Entering state 1 Stack now 0 10 1 0xffffc0c13900->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadf078300 'a') -> $$ = nterm item (0xffffc0c13900 'a') 0xaaaadf078300->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13900 } 0xaaaadf078300->Object::Object { 0xaaaadf0782e0, 0xffffc0c13900 } 0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13900 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffc0c137e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300 } 0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c137e0 } 0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c137e0, 0xffffc0c138e0 } Next token is token 'a' (0xffffc0c138e0 'a') 0xffffc0c13820->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c138e0 } 0xffffc0c138e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13820, 0xffffc0c138e0 } Shifting token 'a' (0xffffc0c13820 'a') 0xaaaadf078320->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13820 } 0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13820 } Entering state 1 Stack now 0 10 10 1 0xffffc0c13900->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadf078320 'a') -> $$ = nterm item (0xffffc0c13900 'a') 0xaaaadf078320->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13900 } 0xaaaadf078320->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13900 } 0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13900 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffc0c137e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320 } 0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c137e0 } 0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c137e0, 0xffffc0c138e0 } Next token is token 'a' (0xffffc0c138e0 'a') 0xffffc0c13820->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c138e0 } 0xffffc0c138e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13820, 0xffffc0c138e0 } Shifting token 'a' (0xffffc0c13820 'a') 0xaaaadf078340->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13820 } 0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c13820 } Entering state 1 Stack now 0 10 10 10 1 0xffffc0c13900->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadf078340 'a') -> $$ = nterm item (0xffffc0c13900 'a') 0xaaaadf078340->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c13900 } 0xaaaadf078340->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13900 } 0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c13900 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffc0c137e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340 } 0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c137e0 } 0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c137e0, 0xffffc0c138e0 } Next token is token 'p' (0xffffc0c138e0 'p'Exception caught: cleaning lookahead and stack 0xaaaadf078340->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c138e0 } 0xaaaadf078320->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c138e0 } 0xaaaadf078300->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c138e0 } 0xaaaadf0782e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c138e0 } 0xffffc0c138e0->Object::~Object { 0xffffc0c138e0 } exception caught: printer end { } ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) stdout: 706. cxx-type.at:415: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc0c137e0->Object::Object { } 0xffffc0c138e0->Object::Object { 0xffffc0c137e0 } 0xffffc0c137e0->Object::~Object { 0xffffc0c137e0, 0xffffc0c138e0 } Next token is token 'a' (0xffffc0c138e0 'a') 0xffffc0c13820->Object::Object { 0xffffc0c138e0 } 0xffffc0c138e0->Object::~Object { 0xffffc0c13820, 0xffffc0c138e0 } Shifting token 'a' (0xffffc0c13820 'a') 0xaaaadf0782e0->Object::Object { 0xffffc0c13820 } 0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13820 } Entering state 1 Stack now 0 1 0xffffc0c13900->Object::Object { 0xaaaadf0782e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadf0782e0 'a') -> $$ = nterm item (0xffffc0c13900 'a') 0xaaaadf0782e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13900 } 0xaaaadf0782e0->Object::Object { 0xffffc0c13900 } 0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13900 } Entering state 10 Stack now 0 10 Reading a token 0xffffc0c137e0->Object::Object { 0xaaaadf0782e0 } 0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xffffc0c137e0 } 0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c137e0, 0xffffc0c138e0 } Next token is token 'a' (0xffffc0c138e0 'a') 0xffffc0c13820->Object::Object { 0xaaaadf0782e0, 0xffffc0c138e0 } 0xffffc0c138e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13820, 0xffffc0c138e0 } Shifting token 'a' (0xffffc0c13820 'a') 0xaaaadf078300->Object::Object { 0xaaaadf0782e0, 0xffffc0c13820 } 0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13820 } Entering state 1 Stack now 0 10 1 0xffffc0c13900->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadf078300 'a') -> $$ = nterm item (0xffffc0c13900 'a') 0xaaaadf078300->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13900 } 0xaaaadf078300->Object::Object { 0xaaaadf0782e0, 0xffffc0c13900 } 0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13900 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffc0c137e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300 } 0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c137e0 } 0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c137e0, 0xffffc0c138e0 } Next token is token 'a' (0xffffc0c138e0 'a') 0xffffc0c13820->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c138e0 } 0xffffc0c138e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13820, 0xffffc0c138e0 } Shifting token 'a' (0xffffc0c13820 'a') 0xaaaadf078320->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13820 } 0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13820 } Entering state 1 Stack now 0 10 10 1 0xffffc0c13900->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadf078320 'a') -> $$ = nterm item (0xffffc0c13900 'a') 0xaaaadf078320->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13900 } 0xaaaadf078320->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13900 } 0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13900 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffc0c137e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320 } 0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c137e0 } 0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c137e0, 0xffffc0c138e0 } Next token is token 'a' (0xffffc0c138e0 'a') 0xffffc0c13820->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c138e0 } 0xffffc0c138e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13820, 0xffffc0c138e0 } Shifting token 'a' (0xffffc0c13820 'a') 0xaaaadf078340->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13820 } 0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c13820 } Entering state 1 Stack now 0 10 10 10 1 0xffffc0c13900->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadf078340 'a') -> $$ = nterm item (0xffffc0c13900 'a') 0xaaaadf078340->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c13900 } 0xaaaadf078340->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13900 } 0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c13900 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffc0c137e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340 } 0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c137e0 } 0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c137e0, 0xffffc0c138e0 } Next token is token 'p' (0xffffc0c138e0 'p'Exception caught: cleaning lookahead and stack 0xaaaadf078340->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c138e0 } 0xaaaadf078320->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c138e0 } 0xaaaadf078300->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c138e0 } 0xaaaadf0782e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c138e0 } 0xffffc0c138e0->Object::~Object { 0xffffc0c138e0 } exception caught: printer end { } ok ./c++.at:1555: ./check ./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y ./c++.at:1363: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1363: $PREPARSER ./input aaaae ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1066: ./check ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS 708. cxx-type.at:426: testing GLR: Resolve ambiguity, pure, locations ... ./cxx-type.at:427: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y ./c++.at:1363: $PREPARSER ./input aaaaT stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaR stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: types.y:87.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./cxx-type.at:427: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS stderr: stdout: ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./cxx-type.at:423: $PREPARSER ./types test-input ./c++.at:1065: $PREPARSER ./input < in stderr: stderr: syntax error error: invalid expression ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:423: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:423: $PREPARSER ./types -p test-input ./c++.at:1065: $PREPARSER ./input < in stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () stderr: ./cxx-type.at:423: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () 707. cxx-type.at:420: ok ======== Testing with C++ standard flags: '' ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in 709. cxx-type.at:432: testing GLR: Merge conflicting parses, impure, no locations ... stderr: error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 682. c++.at:1064: ok ./cxx-type.at:433: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y stderr: types.y:77.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./cxx-type.at:433: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS stderr: stdout: ./c++.at:857: $PREPARSER ./input stderr: 710. cxx-type.at:438: testing GLR: Merge conflicting parses, impure, locations ... ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:439: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y ======== Testing with C++ standard flags: '' ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: types.y:87.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./cxx-type.at:439: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS stderr: stderr: stdout: stdout: ./cxx-type.at:429: $PREPARSER ./types test-input ./c++.at:851: $PREPARSER ./input stderr: stderr: 17.5: syntax error ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:429: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 678. c++.at:848: ok ./cxx-type.at:429: $PREPARSER ./types -p test-input stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) ./cxx-type.at:429: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) 708. cxx-type.at:426: ok 711. cxx-type.at:444: testing GLR: Merge conflicting parses, pure, no locations ... ./cxx-type.at:445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y stderr: types.y:77.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./cxx-type.at:445: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS 712. cxx-type.at:449: testing GLR: Merge conflicting parses, pure, locations ... ./cxx-type.at:450: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y stderr: stdout: stderr: types.y:87.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./c++.at:1362: $PREPARSER ./input aaaas stderr: ./cxx-type.at:450: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1360: $PREPARSER ./input aaaas stderr: ./c++.at:1362: $PREPARSER ./input aaaal exception caught: reduction stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaal stderr: ./c++.at:1362: $PREPARSER ./input i exception caught: yylex ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input i stderr: ./c++.at:1362: $PREPARSER ./input aaaap stderr: exception caught: initial-action ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: stdout: ./c++.at:1360: $PREPARSER ./input aaaap stderr: stderr: ./c++.at:1361: $PREPARSER ./input aaaas ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc1017cf0->Object::Object { } 0xffffc1017df0->Object::Object { 0xffffc1017cf0 } 0xffffc1017cf0->Object::~Object { 0xffffc1017cf0, 0xffffc1017df0 } Next token is token 'a' (0xffffc1017df0 'a') 0xffffc1017d30->Object::Object { 0xffffc1017df0 } 0xffffc1017df0->Object::~Object { 0xffffc1017d30, 0xffffc1017df0 } Shifting token 'a' (0xffffc1017d30 'a') 0xaaaadfe9c2e0->Object::Object { 0xffffc1017d30 } 0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017d30 } Entering state 2 Stack now 0 2 0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadfe9c2e0 'a') -> $$ = nterm item (0xffffc1017e10 'a') 0xaaaadfe9c2e0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017e10 } 0xaaaadfe9c2e0->Object::Object { 0xffffc1017e10 } 0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017e10 } Entering state 11 Stack now 0 11 Reading a token 0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0 } 0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017cf0 } 0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017cf0, 0xffffc1017df0 } Next token is token 'a' (0xffffc1017df0 'a') 0xffffc1017d30->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017df0 } 0xffffc1017df0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017d30, 0xffffc1017df0 } Shifting token 'a' (0xffffc1017d30 'a') 0xaaaadfe9c300->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017d30 } 0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017d30 } Entering state 2 Stack now 0 11 2 0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadfe9c300 'a') -> $$ = nterm item (0xffffc1017e10 'a') 0xaaaadfe9c300->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017e10 } 0xaaaadfe9c300->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017e10 } 0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017e10 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300 } 0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017cf0 } 0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017cf0, 0xffffc1017df0 } Next token is token 'a' (0xffffc1017df0 'a') 0xffffc1017d30->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017df0 } 0xffffc1017df0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017d30, 0xffffc1017df0 } Shifting token 'a' (0xffffc1017d30 'a') 0xaaaadfe9c320->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017d30 } 0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017d30 } Entering state 2 Stack now 0 11 11 2 0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadfe9c320 'a') -> $$ = nterm item (0xffffc1017e10 'a') 0xaaaadfe9c320->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017e10 } 0xaaaadfe9c320->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017e10 } 0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017e10 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320 } 0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017cf0 } 0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017cf0, 0xffffc1017df0 } Next token is token 'a' (0xffffc1017df0 'a') 0xffffc1017d30->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017df0 } 0xffffc1017df0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017d30, 0xffffc1017df0 } Shifting token 'a' (0xffffc1017d30 'a') 0xaaaadfe9c340->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017d30 } 0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017d30 } Entering state 2 Stack now 0 11 11 11 2 0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadfe9c340 'a') -> $$ = nterm item (0xffffc1017e10 'a') 0xaaaadfe9c340->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017e10 } 0xaaaadfe9c340->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017e10 } 0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017e10 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340 } 0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017cf0 } 0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017cf0, 0xffffc1017df0 } Next token is token 'p' (0xffffc1017df0 'p'Exception caught: cleaning lookahead and stack 0xaaaadfe9c340->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017df0 } 0xaaaadfe9c320->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017df0 } 0xaaaadfe9c300->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017df0 } 0xaaaadfe9c2e0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017df0 } 0xffffc1017df0->Object::~Object { 0xffffc1017df0 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: reduction ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:435: $PREPARSER ./types test-input ./c++.at:1360: $PREPARSER ./input --debug aaaap stderr: stderr: ./c++.at:1361: $PREPARSER ./input aaaal syntax error Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc1017cf0->Object::Object { } 0xffffc1017df0->Object::Object { 0xffffc1017cf0 } 0xffffc1017cf0->Object::~Object { 0xffffc1017cf0, 0xffffc1017df0 } Next token is token 'a' (0xffffc1017df0 'a') 0xffffc1017d30->Object::Object { 0xffffc1017df0 } 0xffffc1017df0->Object::~Object { 0xffffc1017d30, 0xffffc1017df0 } Shifting token 'a' (0xffffc1017d30 'a') 0xaaaadfe9c2e0->Object::Object { 0xffffc1017d30 } 0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017d30 } Entering state 2 Stack now 0 2 0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadfe9c2e0 'a') -> $$ = nterm item (0xffffc1017e10 'a') 0xaaaadfe9c2e0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017e10 } 0xaaaadfe9c2e0->Object::Object { 0xffffc1017e10 } 0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017e10 } Entering state 11 Stack now 0 11 Reading a token 0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0 } 0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017cf0 } 0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017cf0, 0xffffc1017df0 } Next token is token 'a' (0xffffc1017df0 'a') 0xffffc1017d30->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017df0 } 0xffffc1017df0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017d30, 0xffffc1017df0 } Shifting token 'a' (0xffffc1017d30 'a') 0xaaaadfe9c300->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017d30 } 0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017d30 } Entering state 2 Stack now 0 11 2 0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadfe9c300 'a') -> $$ = nterm item (0xffffc1017e10 'a') 0xaaaadfe9c300->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017e10 } 0xaaaadfe9c300->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017e10 } 0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017e10 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300 } 0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017cf0 } 0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017cf0, 0xffffc1017df0 } Next token is token 'a' (0xffffc1017df0 'a') 0xffffc1017d30->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017df0 } 0xffffc1017df0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017d30, 0xffffc1017df0 } Shifting token 'a' (0xffffc1017d30 'a') 0xaaaadfe9c320->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017d30 } 0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017d30 } Entering state 2 Stack now 0 11 11 2 0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadfe9c320 'a') -> $$ = nterm item (0xffffc1017e10 'a') 0xaaaadfe9c320->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017e10 } 0xaaaadfe9c320->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017e10 } 0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017e10 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320 } 0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017cf0 } 0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017cf0, 0xffffc1017df0 } Next token is token 'a' (0xffffc1017df0 'a') 0xffffc1017d30->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017df0 } 0xffffc1017df0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017d30, 0xffffc1017df0 } Shifting token 'a' (0xffffc1017d30 'a') 0xaaaadfe9c340->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017d30 } 0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017d30 } Entering state 2 Stack now 0 11 11 11 2 0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadfe9c340 'a') -> $$ = nterm item (0xffffc1017e10 'a') 0xaaaadfe9c340->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017e10 } 0xaaaadfe9c340->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017e10 } 0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017e10 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340 } 0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017cf0 } 0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017cf0, 0xffffc1017df0 } Next token is token 'p' (0xffffc1017df0 'p'Exception caught: cleaning lookahead and stack 0xaaaadfe9c340->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017df0 } 0xaaaadfe9c320->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017df0 } 0xaaaadfe9c300->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017df0 } 0xaaaadfe9c2e0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017df0 } 0xffffc1017df0->Object::~Object { 0xffffc1017df0 } exception caught: printer end { } ./c++.at:1362: grep '^exception caught: printer$' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae43d8f40->Object::Object { } Next token is token 'a' (0xaaaae43d8f40 'a') Shifting token 'a' (0xaaaae43d8f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae43d8f40 'a') -> $$ = nterm item (0xaaaae43d8f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaae43d8f90->Object::Object { 0xaaaae43d8f40 } Next token is token 'a' (0xaaaae43d8f90 'a') Shifting token 'a' (0xaaaae43d8f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae43d8f90 'a') -> $$ = nterm item (0xaaaae43d8f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaae43d8fe0->Object::Object { 0xaaaae43d8f40, 0xaaaae43d8f90 } Next token is token 'a' (0xaaaae43d8fe0 'a') Shifting token 'a' (0xaaaae43d8fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae43d8fe0 'a') -> $$ = nterm item (0xaaaae43d8fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaae43d9030->Object::Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0 } Next token is token 'a' (0xaaaae43d9030 'a') Shifting token 'a' (0xaaaae43d9030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae43d9030 'a') -> $$ = nterm item (0xaaaae43d9030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaae43d9080->Object::Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0, 0xaaaae43d9030 } Next token is token 'p' (0xaaaae43d9080 'p'Exception caught: cleaning lookahead and stack 0xaaaae43d9080->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0, 0xaaaae43d9030, 0xaaaae43d9080 } 0xaaaae43d9030->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0, 0xaaaae43d9030 } 0xaaaae43d8fe0->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0 } 0xaaaae43d8f90->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90 } 0xaaaae43d8f40->Object::~Object { 0xaaaae43d8f40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: yylex ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae43d8f40->Object::Object { } Next token is token 'a' (0xaaaae43d8f40 'a') Shifting token 'a' (0xaaaae43d8f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae43d8f40 'a') -> $$ = nterm item (0xaaaae43d8f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaae43d8f90->Object::Object { 0xaaaae43d8f40 } Next token is token 'a' (0xaaaae43d8f90 'a') Shifting token 'a' (0xaaaae43d8f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae43d8f90 'a') -> $$ = nterm item (0xaaaae43d8f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaae43d8fe0->Object::Object { 0xaaaae43d8f40, 0xaaaae43d8f90 } Next token is token 'a' (0xaaaae43d8fe0 'a') Shifting token 'a' (0xaaaae43d8fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae43d8fe0 'a') -> $$ = nterm item (0xaaaae43d8fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaae43d9030->Object::Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0 } Next token is token 'a' (0xaaaae43d9030 'a') Shifting token 'a' (0xaaaae43d9030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae43d9030 'a') -> $$ = nterm item (0xaaaae43d9030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaae43d9080->Object::Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0, 0xaaaae43d9030 } Next token is token 'p' (0xaaaae43d9080 'p'Exception caught: cleaning lookahead and stack 0xaaaae43d9080->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0, 0xaaaae43d9030, 0xaaaae43d9080 } 0xaaaae43d9030->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0, 0xaaaae43d9030 } 0xaaaae43d8fe0->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0 } 0xaaaae43d8f90->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90 } 0xaaaae43d8f40->Object::~Object { 0xaaaae43d8f40 } exception caught: printer end { } ./c++.at:1360: grep '^exception caught: printer$' stderr exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae stdout: stderr: exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaE stderr: ./cxx-type.at:435: $PREPARSER ./types -p test-input exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () ./c++.at:1362: $PREPARSER ./input aaaaT ./cxx-type.at:435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input i stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () stderr: stderr: ./c++.at:1360: $PREPARSER ./input aaaaE 709. cxx-type.at:432: ok ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: $PREPARSER ./input aaaap ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaR ./c++.at:1361: $PREPARSER ./input --debug aaaap ./c++.at:1360: $PREPARSER ./input aaaaT stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae3ef4f40->Object::Object { } Next token is token 'a' (0xaaaae3ef4f40 'a') Shifting token 'a' (0xaaaae3ef4f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae3ef4f40 'a') -> $$ = nterm item (0xaaaae3ef4f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaae3ef4f90->Object::Object { 0xaaaae3ef4f40 } Next token is token 'a' (0xaaaae3ef4f90 'a') Shifting token 'a' (0xaaaae3ef4f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae3ef4f90 'a') -> $$ = nterm item (0xaaaae3ef4f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaae3ef4fe0->Object::Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90 } Next token is token 'a' (0xaaaae3ef4fe0 'a') Shifting token 'a' (0xaaaae3ef4fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae3ef4fe0 'a') -> $$ = nterm item (0xaaaae3ef4fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaae3ef5030->Object::Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0 } Next token is token 'a' (0xaaaae3ef5030 'a') Shifting token 'a' (0xaaaae3ef5030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae3ef5030 'a') -> $$ = nterm item (0xaaaae3ef5030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaae3ef5080->Object::Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0, 0xaaaae3ef5030 } Next token is token 'p' (0xaaaae3ef5080 'p'Exception caught: cleaning lookahead and stack 0xaaaae3ef5080->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0, 0xaaaae3ef5030, 0xaaaae3ef5080 } 0xaaaae3ef5030->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0, 0xaaaae3ef5030 } 0xaaaae3ef4fe0->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0 } 0xaaaae3ef4f90->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90 } 0xaaaae3ef4f40->Object::~Object { 0xaaaae3ef4f40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae3ef4f40->Object::Object { } Next token is token 'a' (0xaaaae3ef4f40 'a') Shifting token 'a' (0xaaaae3ef4f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae3ef4f40 'a') -> $$ = nterm item (0xaaaae3ef4f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaae3ef4f90->Object::Object { 0xaaaae3ef4f40 } Next token is token 'a' (0xaaaae3ef4f90 'a') Shifting token 'a' (0xaaaae3ef4f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae3ef4f90 'a') -> $$ = nterm item (0xaaaae3ef4f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaae3ef4fe0->Object::Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90 } Next token is token 'a' (0xaaaae3ef4fe0 'a') Shifting token 'a' (0xaaaae3ef4fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae3ef4fe0 'a') -> $$ = nterm item (0xaaaae3ef4fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaae3ef5030->Object::Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0 } Next token is token 'a' (0xaaaae3ef5030 'a') Shifting token 'a' (0xaaaae3ef5030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae3ef5030 'a') -> $$ = nterm item (0xaaaae3ef5030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaae3ef5080->Object::Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0, 0xaaaae3ef5030 } Next token is token 'p' (0xaaaae3ef5080 'p'Exception caught: cleaning lookahead and stack 0xaaaae3ef5080->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0, 0xaaaae3ef5030, 0xaaaae3ef5080 } 0xaaaae3ef5030->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0, 0xaaaae3ef5030 } 0xaaaae3ef4fe0->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0 } 0xaaaae3ef4f90->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90 } 0xaaaae3ef4f40->Object::~Object { 0xaaaae3ef4f40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1361: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1361: $PREPARSER ./input aaaaE ./c++.at:1360: $PREPARSER ./input aaaaR stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaT ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaR stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' 713. cxx-type.at:455: testing GLR: Verbose messages, resolve ambiguity, impure, no locations ... ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ======== Testing with C++ standard flags: '' ./cxx-type.at:456: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: types.y:77.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./cxx-type.at:456: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS stderr: stdout: ./cxx-type.at:441: $PREPARSER ./types test-input stderr: 17.5: syntax error stderr: stdout: ./c++.at:1555: $PREPARSER ./test ./cxx-type.at:441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 691. c++.at:1517: ok ./cxx-type.at:441: $PREPARSER ./types -p test-input stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (13.3: ) -> $$ = nterm expr (13.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (13.0: ) $2 = token '(' (13.2: ) $3 = nterm expr (13.3: ) $4 = token ')' (13.4: ) -> $$ = nterm expr (13.0-4: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (13.0-4: ) $2 = token ';' (13.5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.3: ) -> $$ = nterm expr (15.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (15.0: ) $2 = token '(' (15.2: ) $3 = nterm expr (15.3: ) $4 = token ')' (15.4: ) -> $$ = nterm expr (15.0-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 10 (line 94): $1 = nterm expr (15.0-4: ) $2 = token '=' (15.6: ) $3 = nterm expr (15.8-12: ) -> $$ = nterm expr (15.0-12: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (15.0-12: ) $2 = token ';' (15.13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) ./cxx-type.at:441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: 714. glr-regression.at:205: testing Badly Collapsed GLR States: glr.c ... Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (13.3: ) -> $$ = nterm expr (13.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (13.0: ) $2 = token '(' (13.2: ) $3 = nterm expr (13.3: ) $4 = token ')' (13.4: ) -> $$ = nterm expr (13.0-4: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (13.0-4: ) $2 = token ';' (13.5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.3: ) -> $$ = nterm expr (15.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (15.0: ) $2 = token '(' (15.2: ) $3 = nterm expr (15.3: ) $4 = token ')' (15.4: ) -> $$ = nterm expr (15.0-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 10 (line 94): $1 = nterm expr (15.0-4: ) $2 = token '=' (15.6: ) $3 = nterm expr (15.8-12: ) -> $$ = nterm expr (15.0-12: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (15.0-12: ) $2 = token ';' (15.13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) ./cxx-type.at:447: $PREPARSER ./types test-input ./glr-regression.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o glr-regr1.c glr-regr1.y stderr: 710. cxx-type.at:438: ok stdout: stderr: syntax error ./c++.at:1363: $PREPARSER ./input aaaas stderr: ./cxx-type.at:447: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:447: $PREPARSER ./types -p test-input ./c++.at:1363: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input i stderr: stderr: exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -./glr-regression.at:205: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr1 glr-regr1.c $LIBS > $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () ./c++.at:1363: $PREPARSER ./input aaaap ./cxx-type.at:447: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc7383f50->Object::Object { } 0xffffc7384050->Object::Object { 0xffffc7383f50 } 0xffffc7383f50->Object::~Object { 0xffffc7383f50, 0xffffc7384050 } Next token is token 'a' (0xffffc7384050 'a') 0xffffc7383f90->Object::Object { 0xffffc7384050 } 0xffffc7384050->Object::~Object { 0xffffc7383f90, 0xffffc7384050 } Shifting token 'a' (0xffffc7383f90 'a') 0xaaaaddfd62e0->Object::Object { 0xffffc7383f90 } 0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xffffc7383f90 } Entering state 1 Stack now 0 1 0xffffc7384070->Object::Object { 0xaaaaddfd62e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaddfd62e0 'a') -> $$ = nterm item (0xffffc7384070 'a') 0xaaaaddfd62e0->Object::~Object { 0xaaaaddfd62e0, 0xffffc7384070 } 0xaaaaddfd62e0->Object::Object { 0xffffc7384070 } 0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xffffc7384070 } Entering state 10 Stack now 0 10 Reading a token 0xffffc7383f50->Object::Object { 0xaaaaddfd62e0 } 0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xffffc7383f50 } 0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xffffc7383f50, 0xffffc7384050 } Next token is token 'a' (0xffffc7384050 'a') 0xffffc7383f90->Object::Object { 0xaaaaddfd62e0, 0xffffc7384050 } 0xffffc7384050->Object::~Object { 0xaaaaddfd62e0, 0xffffc7383f90, 0xffffc7384050 } Shifting token 'a' (0xffffc7383f90 'a') 0xaaaaddfd6300->Object::Object { 0xaaaaddfd62e0, 0xffffc7383f90 } 0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f90 } Entering state 1 Stack now 0 10 1 0xffffc7384070->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaddfd6300 'a') -> $$ = nterm item (0xffffc7384070 'a') 0xaaaaddfd6300->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384070 } 0xaaaaddfd6300->Object::Object { 0xaaaaddfd62e0, 0xffffc7384070 } 0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384070 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffc7383f50->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300 } 0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f50 } 0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f50, 0xffffc7384050 } Next token is token 'a' (0xffffc7384050 'a') 0xffffc7383f90->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384050 } 0xffffc7384050->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f90, 0xffffc7384050 } Shifting token 'a' (0xffffc7383f90 'a') 0xaaaaddfd6320->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f90 } 0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f90 } Entering state 1 Stack now 0 10 10 1 0xffffc7384070->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaddfd6320 'a') -> $$ = nterm item (0xffffc7384070 'a') 0xaaaaddfd6320->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384070 } 0xaaaaddfd6320->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384070 } 0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384070 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffc7383f50->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320 } 0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f50 } 0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f50, 0xffffc7384050 } Next token is token 'a' (0xffffc7384050 'a') 0xffffc7383f90->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384050 } 0xffffc7384050->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f90, 0xffffc7384050 } Shifting token 'a' (0xffffc7383f90 'a') 0xaaaaddfd6340->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f90 } 0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7383f90 } Entering state 1 Stack now 0 10 10 10 1 0xffffc7384070->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaddfd6340 'a') -> $$ = nterm item (0xffffc7384070 'a') 0xaaaaddfd6340->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7384070 } 0xaaaaddfd6340->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384070 } 0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7384070 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffc7383f50->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340 } 0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7383f50 } 0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7383f50, 0xffffc7384050 } Next token is token 'p' (0xffffc7384050 'p'Exception caught: cleaning lookahead and stack 0xaaaaddfd6340->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7384050 } 0xaaaaddfd6320->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384050 } 0xaaaaddfd6300->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384050 } 0xaaaaddfd62e0->Object::~Object { 0xaaaaddfd62e0, 0xffffc7384050 } 0xffffc7384050->Object::~Object { 0xffffc7384050 } exception caught: printer end { } ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc7383f50->Object::Object { } 0xffffc7384050->Object::Object { 0xffffc7383f50 } 0xffffc7383f50->Object::~Object { 0xffffc7383f50, 0xffffc7384050 } Next token is token 'a' (0xffffc7384050 'a') 0xffffc7383f90->Object::Object { 0xffffc7384050 } 0xffffc7384050->Object::~Object { 0xffffc7383f90, 0xffffc7384050 } Shifting token 'a' (0xffffc7383f90 'a') 0xaaaaddfd62e0->Object::Object { 0xffffc7383f90 } 0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xffffc7383f90 } Entering state 1 Stack now 0 1 0xffffc7384070->Object::Object { 0xaaaaddfd62e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaddfd62e0 'a') -> $$ = nterm item (0xffffc7384070 'a') 0xaaaaddfd62e0->Object::~Object { 0xaaaaddfd62e0, 0xffffc7384070 } 0xaaaaddfd62e0->Object::Object { 0xffffc7384070 } 0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xffffc7384070 } Entering state 10 Stack now 0 10 Reading a token 0xffffc7383f50->Object::Object { 0xaaaaddfd62e0 } 0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xffffc7383f50 } 0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xffffc7383f50, 0xffffc7384050 } Next token is token 'a' (0xffffc7384050 'a') 0xffffc7383f90->Object::Object { 0xaaaaddfd62e0, 0xffffc7384050 } 0xffffc7384050->Object::~Object { 0xaaaaddfd62e0, 0xffffc7383f90, 0xffffc7384050 } Shifting token 'a' (0xffffc7383f90 'a') 0xaaaaddfd6300->Object::Object { 0xaaaaddfd62e0, 0xffffc7383f90 } 0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f90 } Entering state 1 Stack now 0 10 1 0xffffc7384070->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaddfd6300 'a') -> $$ = nterm item (0xffffc7384070 'a') 0xaaaaddfd6300->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384070 } 0xaaaaddfd6300->Object::Object { 0xaaaaddfd62e0, 0xffffc7384070 } 0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384070 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffc7383f50->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300 } 0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f50 } 0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f50, 0xffffc7384050 } Next token is token 'a' (0xffffc7384050 'a') 0xffffc7383f90->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384050 } 0xffffc7384050->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f90, 0xffffc7384050 } Shifting token 'a' (0xffffc7383f90 'a') 0xaaaaddfd6320->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f90 } 0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f90 } Entering state 1 Stack now 0 10 10 1 0xffffc7384070->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaddfd6320 'a') -> $$ = nterm item (0xffffc7384070 'a') 0xaaaaddfd6320->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384070 } 0xaaaaddfd6320->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384070 } 0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384070 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffc7383f50->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320 } 0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f50 } 0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f50, 0xffffc7384050 } Next token is token 'a' (0xffffc7384050 'a') 0xffffc7383f90->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384050 } 0xffffc7384050->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f90, 0xffffc7384050 } Shifting token 'a' (0xffffc7383f90 'a') 0xaaaaddfd6340->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f90 } 0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7383f90 } Entering state 1 Stack now 0 10 10 10 1 0xffffc7384070->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaddfd6340 'a') -> $$ = nterm item (0xffffc7384070 'a') 0xaaaaddfd6340->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7384070 } 0xaaaaddfd6340->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384070 } 0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7384070 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffc7383f50->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340 } 0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7383f50 } 0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7383f50, 0xffffc7384050 } Next token is token 'p' (0xffffc7384050 'p'Exception caught: cleaning lookahead and stack 0xaaaaddfd6340->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7384050 } 0xaaaaddfd6320->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384050 } 0xaaaaddfd6300->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384050 } 0xaaaaddfd62e0->Object::~Object { 0xaaaaddfd62e0, 0xffffc7384050 } 0xffffc7384050->Object::~Object { 0xffffc7384050 } exception caught: printer end { } ./c++.at:1363: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1363: $PREPARSER ./input aaaae stderr: stderr: exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () 711. cxx-type.at:444: ok 715. glr-regression.at:206: testing Badly Collapsed GLR States: glr.cc ... ./glr-regression.at:206: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o glr-regr1.cc glr-regr1.y ./c++.at:1363: $PREPARSER ./input aaaaE ./glr-regression.at:206: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr1 glr-regr1.cc $LIBS stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaT stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaR stderr: 716. glr-regression.at:207: testing Badly Collapsed GLR States: glr2.cc ... ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:207: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o glr-regr1.cc glr-regr1.y ======== Testing with C++ standard flags: '' ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./glr-regression.at:207: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr1 glr-regr1.cc $LIBS stderr: stdout: ./cxx-type.at:452: $PREPARSER ./types test-input stderr: 17.5: syntax error ./cxx-type.at:452: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:452: $PREPARSER ./types -p test-input stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (13.3: ) -> $$ = nterm expr (13.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (13.0: ) $2 = token '(' (13.2: ) $3 = nterm expr (13.3: ) $4 = token ')' (13.4: ) -> $$ = nterm expr (13.0-4: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (13.0-4: ) $2 = token ';' (13.5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.3: ) -> $$ = nterm expr (15.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (15.0: ) $2 = token '(' (15.2: ) $3 = nterm expr (15.3: ) $4 = token ')' (15.4: ) -> $$ = nterm expr (15.0-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 10 (line 94): $1 = nterm expr (15.0-4: ) $2 = token '=' (15.6: ) $3 = nterm expr (15.8-12: ) -> $$ = nterm expr (15.0-12: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (15.0-12: ) $2 = token ';' (15.13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) ./cxx-type.at:452: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (13.3: ) -> $$ = nterm expr (13.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (13.0: ) $2 = token '(' (13.2: ) $3 = nterm expr (13.3: ) $4 = token ')' (13.4: ) -> $$ = nterm expr (13.0-4: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (13.0-4: ) $2 = token ';' (13.5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.3: ) -> $$ = nterm expr (15.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (15.0: ) $2 = token '(' (15.2: ) $3 = nterm expr (15.3: ) $4 = token ')' (15.4: ) -> $$ = nterm expr (15.0-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 10 (line 94): $1 = nterm expr (15.0-4: ) $2 = token '=' (15.6: ) $3 = nterm expr (15.8-12: ) -> $$ = nterm expr (15.0-12: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (15.0-12: ) $2 = token ';' (15.13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) 712. cxx-type.at:449: ok stderr: stdout: 717. glr-regression.at:354: testing Improper handling of embedded actions and dollar(-N) in GLR parsers: glr.c ... ./cxx-type.at:458: $PREPARSER ./types test-input stderr: stdout: stderr: ./glr-regression.at:354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr2a.c glr-regr2a.y ./glr-regression.at:205: $PREPARSER ./glr-regr1 BPBPB stderr: syntax error, unexpected ID, expecting '=' or '+' or ')' ./cxx-type.at:458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:205: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:354: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr2a glr-regr2a.c $LIBS 714. glr-regression.at:205: ok stderr: stdout: ./c++.at:857: $PREPARSER ./input stderr: ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:858: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ./cxx-type.at:458: $PREPARSER ./types -p test-input stderr: ======== Testing with C++ standard flags: '' ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error, unexpected ID, expecting '=' or '+' or ')' Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () ./cxx-type.at:458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 718. glr-regression.at:355: testing Improper handling of embedded actions and dollar(-N) in GLR parsers: glr.cc ... ./glr-regression.at:355: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr2a.cc glr-regr2a.y Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error, unexpected ID, expecting '=' or '+' or ')' Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () 713. cxx-type.at:455: ok ./glr-regression.at:355: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr2a glr-regr2a.cc $LIBS 719. glr-regression.at:356: testing Improper handling of embedded actions and dollar(-N) in GLR parsers: glr2.cc ... ./glr-regression.at:356: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr2a.cc glr-regr2a.y ./glr-regression.at:356: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr2a glr-regr2a.cc $LIBS stderr: stdout: ./glr-regression.at:206: $PREPARSER ./glr-regr1 BPBPB stderr: ./glr-regression.at:206: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 715. glr-regression.at:206: ok stderr: stdout: ./c++.at:858: $PREPARSER ./input stderr: ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 720. glr-regression.at:488: testing Improper merging of GLR delayed action sets: glr.c ... ./glr-regression.at:488: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr3.c glr-regr3.y ======== Testing with C++ standard flags: '' ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: stderr: stdout: ./glr-regression.at:354: $PREPARSER ./glr-regr2a input1.txt stderr: ./c++.at:1066: $PREPARSER ./input < in stderr: ./glr-regression.at:354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:488: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr3 glr-regr3.c $LIBS error: invalid expression caught error error: invalid character caught error ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:354: $PREPARSER ./glr-regr2a input2.txt stderr: ./c++.at:1066: $PREPARSER ./input < in ./glr-regression.at:354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: invalid expression ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:354: $PREPARSER ./glr-regr2a input3.txt stderr: ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 717. glr-regression.at:354: ok stderr: stdout: ./c++.at:1362: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 721. glr-regression.at:489: testing Improper merging of GLR delayed action sets: glr.cc ... ./glr-regression.at:489: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr3.cc glr-regr3.y stderr: stdout: ./c++.at:1362: $PREPARSER ./input aaaap stderr: ./c++.at:1066: ./check ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffd43f7710->Object::Object { } 0xffffd43f7810->Object::Object { 0xffffd43f7710 } 0xffffd43f7710->Object::~Object { 0xffffd43f7710, 0xffffd43f7810 } Next token is token 'a' (0xffffd43f7810 'a') 0xffffd43f7750->Object::Object { 0xffffd43f7810 } 0xffffd43f7810->Object::~Object { 0xffffd43f7750, 0xffffd43f7810 } Shifting token 'a' (0xffffd43f7750 'a') 0xaaaaba1992e0->Object::Object { 0xffffd43f7750 } 0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7750 } Entering state 2 Stack now 0 2 0xffffd43f7830->Object::Object { 0xaaaaba1992e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaba1992e0 'a') -> $$ = nterm item (0xffffd43f7830 'a') 0xaaaaba1992e0->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7830 } 0xaaaaba1992e0->Object::Object { 0xffffd43f7830 } 0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7830 } Entering state 11 Stack now 0 11 Reading a token 0xffffd43f7710->Object::Object { 0xaaaaba1992e0 } 0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xffffd43f7710 } 0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7710, 0xffffd43f7810 } Next token is token 'a' (0xffffd43f7810 'a') 0xffffd43f7750->Object::Object { 0xaaaaba1992e0, 0xffffd43f7810 } 0xffffd43f7810->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7750, 0xffffd43f7810 } Shifting token 'a' (0xffffd43f7750 'a') 0xaaaaba199300->Object::Object { 0xaaaaba1992e0, 0xffffd43f7750 } 0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7750 } Entering state 2 Stack now 0 11 2 0xffffd43f7830->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaba199300 'a') -> $$ = nterm item (0xffffd43f7830 'a') 0xaaaaba199300->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7830 } 0xaaaaba199300->Object::Object { 0xaaaaba1992e0, 0xffffd43f7830 } 0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7830 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffd43f7710->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300 } 0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7710 } 0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7710, 0xffffd43f7810 } Next token is token 'a' (0xffffd43f7810 'a') 0xffffd43f7750->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7810 } 0xffffd43f7810->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7750, 0xffffd43f7810 } Shifting token 'a' (0xffffd43f7750 'a') 0xaaaaba199320->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7750 } 0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7750 } Entering state 2 Stack now 0 11 11 2 0xffffd43f7830->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaba199320 'a') -> $$ = nterm item (0xffffd43f7830 'a') 0xaaaaba199320->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7830 } 0xaaaaba199320->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7830 } 0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7830 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffd43f7710->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320 } 0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7710 } 0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7710, 0xffffd43f7810 } Next token is token 'a' (0xffffd43f7810 'a') 0xffffd43f7750->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7810 } 0xffffd43f7810->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7750, 0xffffd43f7810 } Shifting token 'a' (0xffffd43f7750 'a') 0xaaaaba199340->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7750 } 0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7750 } Entering state 2 Stack now 0 11 11 11 2 0xffffd43f7830->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaba199340 'a') -> $$ = nterm item (0xffffd43f7830 'a') 0xaaaaba199340->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7830 } 0xaaaaba199340->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7830 } 0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7830 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffd43f7710->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340 } 0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7710 } 0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7710, 0xffffd43f7810 } Next token is token 'p' (0xffffd43f7810 'p'Exception caught: cleaning lookahead and stack 0xaaaaba199340->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7810 } 0xaaaaba199320->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7810 } 0xaaaaba199300->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7810 } 0xaaaaba1992e0->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7810 } 0xffffd43f7810->Object::~Object { 0xffffd43f7810 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: ./glr-regression.at:489: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr3 glr-regr3.cc $LIBS Starting parse Entering state 0 Stack now 0 Reading a token 0xffffd43f7710->Object::Object { } 0xffffd43f7810->Object::Object { 0xffffd43f7710 } 0xffffd43f7710->Object::~Object { 0xffffd43f7710, 0xffffd43f7810 } Next token is token 'a' (0xffffd43f7810 'a') 0xffffd43f7750->Object::Object { 0xffffd43f7810 } 0xffffd43f7810->Object::~Object { 0xffffd43f7750, 0xffffd43f7810 } Shifting token 'a' (0xffffd43f7750 'a') 0xaaaaba1992e0->Object::Object { 0xffffd43f7750 } 0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7750 } Entering state 2 Stack now 0 2 0xffffd43f7830->Object::Object { 0xaaaaba1992e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaba1992e0 'a') -> $$ = nterm item (0xffffd43f7830 'a') 0xaaaaba1992e0->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7830 } 0xaaaaba1992e0->Object::Object { 0xffffd43f7830 } 0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7830 } Entering state 11 Stack now 0 11 Reading a token 0xffffd43f7710->Object::Object { 0xaaaaba1992e0 } 0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xffffd43f7710 } 0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7710, 0xffffd43f7810 } Next token is token 'a' (0xffffd43f7810 'a') 0xffffd43f7750->Object::Object { 0xaaaaba1992e0, 0xffffd43f7810 } 0xffffd43f7810->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7750, 0xffffd43f7810 } Shifting token 'a' (0xffffd43f7750 'a') 0xaaaaba199300->Object::Object { 0xaaaaba1992e0, 0xffffd43f7750 } 0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7750 } Entering state 2 Stack now 0 11 2 0xffffd43f7830->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaba199300 'a') -> $$ = nterm item (0xffffd43f7830 'a') 0xaaaaba199300->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7830 } 0xaaaaba199300->Object::Object { 0xaaaaba1992e0, 0xffffd43f7830 } 0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7830 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffd43f7710->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300 } 0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7710 } 0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7710, 0xffffd43f7810 } Next token is token 'a' (0xffffd43f7810 'a') 0xffffd43f7750->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7810 } 0xffffd43f7810->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7750, 0xffffd43f7810 } Shifting token 'a' (0xffffd43f7750 'a') 0xaaaaba199320->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7750 } 0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7750 } Entering state 2 Stack now 0 11 11 2 0xffffd43f7830->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaba199320 'a') -> $$ = nterm item (0xffffd43f7830 'a') 0xaaaaba199320->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7830 } 0xaaaaba199320->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7830 } 0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7830 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffd43f7710->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320 } 0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7710 } 0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7710, 0xffffd43f7810 } Next token is token 'a' (0xffffd43f7810 'a') 0xffffd43f7750->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7810 } 0xffffd43f7810->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7750, 0xffffd43f7810 } Shifting token 'a' (0xffffd43f7750 'a') 0xaaaaba199340->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7750 } 0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7750 } Entering state 2 Stack now 0 11 11 11 2 0xffffd43f7830->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaba199340 'a') -> $$ = nterm item (0xffffd43f7830 'a') 0xaaaaba199340->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7830 } 0xaaaaba199340->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7830 } 0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7830 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffd43f7710->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340 } 0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7710 } 0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7710, 0xffffd43f7810 } Next token is token 'p' (0xffffd43f7810 'p'Exception caught: cleaning lookahead and stack 0xaaaaba199340->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7810 } 0xaaaaba199320->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7810 } 0xaaaaba199300->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7810 } 0xaaaaba1992e0->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7810 } 0xffffd43f7810->Object::~Object { 0xffffd43f7810 } exception caught: printer end { } ./c++.at:1362: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./glr-regression.at:355: $PREPARSER ./glr-regr2a input1.txt stderr: ./glr-regression.at:355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:355: $PREPARSER ./glr-regr2a input2.txt stderr: ./glr-regression.at:355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./glr-regression.at:355: $PREPARSER ./glr-regr2a input3.txt stderr: ./c++.at:1362: $PREPARSER ./input aaaaE stdout: ./glr-regression.at:355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1065: $PREPARSER ./input < in 718. glr-regression.at:355: ok ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in ./c++.at:1362: $PREPARSER ./input aaaaT stderr: stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaR stderr: stdout: stderr: ./c++.at:1363: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 683. c++.at:1065: ok ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 722. glr-regression.at:490: testing Improper merging of GLR delayed action sets: glr2.cc ... ======== Testing with C++ standard flags: '' ./glr-regression.at:490: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr3.cc glr-regr3.y ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1363: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaap stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:490: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr3 glr-regr3.cc $LIBS 723. glr-regression.at:592: testing Duplicate representation of merged trees: %union { char *ptr; } glr.c ... ./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: ./glr-regression.at:592: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.c glr-regr4.y stdout: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffe877f390->Object::Object { } 0xffffe877f490->Object::Object { 0xffffe877f390 } 0xffffe877f390->Object::~Object { 0xffffe877f390, 0xffffe877f490 } Next token is token 'a' (0xffffe877f490 'a') 0xffffe877f3d0->Object::Object { 0xffffe877f490 } 0xffffe877f490->Object::~Object { 0xffffe877f3d0, 0xffffe877f490 } Shifting token 'a' (0xffffe877f3d0 'a') 0xaaaae3a232e0->Object::Object { 0xffffe877f3d0 } 0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f3d0 } Entering state 1 Stack now 0 1 0xffffe877f4b0->Object::Object { 0xaaaae3a232e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae3a232e0 'a') -> $$ = nterm item (0xffffe877f4b0 'a') 0xaaaae3a232e0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f4b0 } 0xaaaae3a232e0->Object::Object { 0xffffe877f4b0 } 0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f4b0 } Entering state 10 Stack now 0 10 Reading a token 0xffffe877f390->Object::Object { 0xaaaae3a232e0 } 0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xffffe877f390 } 0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xffffe877f390, 0xffffe877f490 } Next token is token 'a' (0xffffe877f490 'a') 0xffffe877f3d0->Object::Object { 0xaaaae3a232e0, 0xffffe877f490 } 0xffffe877f490->Object::~Object { 0xaaaae3a232e0, 0xffffe877f3d0, 0xffffe877f490 } Shifting token 'a' (0xffffe877f3d0 'a') 0xaaaae3a23300->Object::Object { 0xaaaae3a232e0, 0xffffe877f3d0 } 0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f3d0 } Entering state 1 Stack now 0 10 1 0xffffe877f4b0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae3a23300 'a') -> $$ = nterm item (0xffffe877f4b0 'a') 0xaaaae3a23300->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f4b0 } 0xaaaae3a23300->Object::Object { 0xaaaae3a232e0, 0xffffe877f4b0 } 0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f4b0 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffe877f390->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300 } 0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f390 } 0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f390, 0xffffe877f490 } Next token is token 'a' (0xffffe877f490 'a') 0xffffe877f3d0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f490 } 0xffffe877f490->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f3d0, 0xffffe877f490 } Shifting token 'a' (0xffffe877f3d0 'a') 0xaaaae3a23320->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f3d0 } 0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f3d0 } Entering state 1 Stack now 0 10 10 1 0xffffe877f4b0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae3a23320 'a') -> $$ = nterm item (0xffffe877f4b0 'a') 0xaaaae3a23320->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f4b0 } 0xaaaae3a23320->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f4b0 } 0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f4b0 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffe877f390->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320 } 0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f390 } 0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f390, 0xffffe877f490 } Next token is token 'a' (0xffffe877f490 'a') 0xffffe877f3d0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f490 } 0xffffe877f490->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f3d0, 0xffffe877f490 } Shifting token 'a' (0xffffe877f3d0 'a') 0xaaaae3a23340->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f3d0 } 0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f3d0 } Entering state 1 Stack now 0 10 10 10 1 0xffffe877f4b0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae3a23340 'a') -> $$ = nterm item (0xffffe877f4b0 'a') 0xaaaae3a23340->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f4b0 } 0xaaaae3a23340->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f4b0 } 0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f4b0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffe877f390->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340 } 0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f390 } 0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f390, 0xffffe877f490 } Next token is token 'p' (0xffffe877f490 'p'Exception caught: cleaning lookahead and stack 0xaaaae3a23340->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f490 } 0xaaaae3a23320->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f490 } 0xaaaae3a23300->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f490 } 0xaaaae3a232e0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f490 } 0xffffe877f490->Object::~Object { 0xffffe877f490 } exception caught: printer end { } ./c++.at:1360: $PREPARSER ./input aaaas stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1360: $PREPARSER ./input aaaal Starting parse Entering state 0 Stack now 0 Reading a token 0xffffe877f390->Object::Object { } 0xffffe877f490->Object::Object { 0xffffe877f390 } 0xffffe877f390->Object::~Object { 0xffffe877f390, 0xffffe877f490 } Next token is token 'a' (0xffffe877f490 'a') 0xffffe877f3d0->Object::Object { 0xffffe877f490 } 0xffffe877f490->Object::~Object { 0xffffe877f3d0, 0xffffe877f490 } Shifting token 'a' (0xffffe877f3d0 'a') 0xaaaae3a232e0->Object::Object { 0xffffe877f3d0 } 0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f3d0 } Entering state 1 Stack now 0 1 0xffffe877f4b0->Object::Object { 0xaaaae3a232e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae3a232e0 'a') -> $$ = nterm item (0xffffe877f4b0 'a') 0xaaaae3a232e0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f4b0 } 0xaaaae3a232e0->Object::Object { 0xffffe877f4b0 } 0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f4b0 } Entering state 10 Stack now 0 10 Reading a token 0xffffe877f390->Object::Object { 0xaaaae3a232e0 } 0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xffffe877f390 } 0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xffffe877f390, 0xffffe877f490 } Next token is token 'a' (0xffffe877f490 'a') 0xffffe877f3d0->Object::Object { 0xaaaae3a232e0, 0xffffe877f490 } 0xffffe877f490->Object::~Object { 0xaaaae3a232e0, 0xffffe877f3d0, 0xffffe877f490 } Shifting token 'a' (0xffffe877f3d0 'a') 0xaaaae3a23300->Object::Object { 0xaaaae3a232e0, 0xffffe877f3d0 } 0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f3d0 } Entering state 1 Stack now 0 10 1 0xffffe877f4b0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae3a23300 'a') -> $$ = nterm item (0xffffe877f4b0 'a') 0xaaaae3a23300->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f4b0 } 0xaaaae3a23300->Object::Object { 0xaaaae3a232e0, 0xffffe877f4b0 } 0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f4b0 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffe877f390->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300 } 0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f390 } 0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f390, 0xffffe877f490 } Next token is token 'a' (0xffffe877f490 'a') 0xffffe877f3d0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f490 } 0xffffe877f490->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f3d0, 0xffffe877f490 } Shifting token 'a' (0xffffe877f3d0 'a') 0xaaaae3a23320->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f3d0 } 0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f3d0 } Entering state 1 Stack now 0 10 10 1 0xffffe877f4b0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae3a23320 'a') -> $$ = nterm item (0xffffe877f4b0 'a') 0xaaaae3a23320->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f4b0 } 0xaaaae3a23320->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f4b0 } 0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f4b0 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffe877f390->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320 } 0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f390 } 0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f390, 0xffffe877f490 } Next token is token 'a' (0xffffe877f490 'a') 0xffffe877f3d0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f490 } 0xffffe877f490->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f3d0, 0xffffe877f490 } Shifting token 'a' (0xffffe877f3d0 'a') 0xaaaae3a23340->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f3d0 } 0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f3d0 } Entering state 1 Stack now 0 10 10 10 1 0xffffe877f4b0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae3a23340 'a') -> $$ = nterm item (0xffffe877f4b0 'a') 0xaaaae3a23340->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f4b0 } 0xaaaae3a23340->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f4b0 } 0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f4b0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffe877f390->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340 } 0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f390 } 0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f390, 0xffffe877f490 } Next token is token 'p' (0xffffe877f490 'p'Exception caught: cleaning lookahead and stack 0xaaaae3a23340->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f490 } 0xaaaae3a23320->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f490 } 0xaaaae3a23300->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f490 } 0xaaaae3a232e0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f490 } 0xffffe877f490->Object::~Object { 0xffffe877f490 } exception caught: printer end { } ./c++.at:1363: grep '^exception caught: printer$' stderr stderr: stdout: exception caught: yylex exception caught: printer ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: $PREPARSER ./input aaaae stderr: stdout: ./glr-regression.at:592: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr4 glr-regr4.c $LIBS exception caught: syntax error ./c++.at:1361: $PREPARSER ./input aaaas ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./c++.at:1360: $PREPARSER ./input i stdout: stderr: exception caught: reduction exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./glr-regression.at:488: $PREPARSER ./glr-regr3 input.txt ./c++.at:1363: $PREPARSER ./input aaaaE stdout: stderr: ./c++.at:858: $PREPARSER ./input stderr: stderr: ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1360: $PREPARSER ./input aaaap ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./glr-regression.at:488: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaal ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1360: $PREPARSER ./input --debug aaaap ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae011ff40->Object::Object { } Next token is token 'a' (0xaaaae011ff40 'a') Shifting token 'a' (0xaaaae011ff40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae011ff40 'a') -> $$ = nterm item (0xaaaae011ff40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaae011ff90->Object::Object { 0xaaaae011ff40 } Next token is token 'a' (0xaaaae011ff90 'a') Shifting token 'a' (0xaaaae011ff90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae011ff90 'a') -> $$ = nterm item (0xaaaae011ff90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaae011ffe0->Object::Object { 0xaaaae011ff40, 0xaaaae011ff90 } Next token is token 'a' (0xaaaae011ffe0 'a') Shifting token 'a' (0xaaaae011ffe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae011ffe0 'a') -> $$ = nterm item (0xaaaae011ffe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaae0120030->Object::Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0 } Next token is token 'a' (0xaaaae0120030 'a') Shifting token 'a' (0xaaaae0120030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae0120030 'a') -> $$ = nterm item (0xaaaae0120030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaae0120080->Object::Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0, 0xaaaae0120030 } Next token is token 'p' (0xaaaae0120080 'p'Exception caught: cleaning lookahead and stack 0xaaaae0120080->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0, 0xaaaae0120030, 0xaaaae0120080 } 0xaaaae0120030->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0, 0xaaaae0120030 } 0xaaaae011ffe0->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0 } 0xaaaae011ff90->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90 } 0xaaaae011ff40->Object::~Object { 0xaaaae011ff40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: $PREPARSER ./input aaaaT exception caught: yylex 720. glr-regression.at:488: ok ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae011ff40->Object::Object { } Next token is token 'a' (0xaaaae011ff40 'a') Shifting token 'a' (0xaaaae011ff40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae011ff40 'a') -> $$ = nterm item (0xaaaae011ff40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaae011ff90->Object::Object { 0xaaaae011ff40 } Next token is token 'a' (0xaaaae011ff90 'a') Shifting token 'a' (0xaaaae011ff90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae011ff90 'a') -> $$ = nterm item (0xaaaae011ff90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaae011ffe0->Object::Object { 0xaaaae011ff40, 0xaaaae011ff90 } Next token is token 'a' (0xaaaae011ffe0 'a') Shifting token 'a' (0xaaaae011ffe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae011ffe0 'a') -> $$ = nterm item (0xaaaae011ffe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaae0120030->Object::Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0 } Next token is token 'a' (0xaaaae0120030 'a') Shifting token 'a' (0xaaaae0120030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae0120030 'a') -> $$ = nterm item (0xaaaae0120030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaae0120080->Object::Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0, 0xaaaae0120030 } Next token is token 'p' (0xaaaae0120080 'p'Exception caught: cleaning lookahead and stack 0xaaaae0120080->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0, 0xaaaae0120030, 0xaaaae0120080 } 0xaaaae0120030->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0, 0xaaaae0120030 } 0xaaaae011ffe0->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0 } 0xaaaae011ff90->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90 } 0xaaaae011ff40->Object::~Object { 0xaaaae011ff40 } exception caught: printer end { } ./c++.at:1360: grep '^exception caught: printer$' stderr ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae ./c++.at:1363: $PREPARSER ./input aaaaR ./c++.at:1361: $PREPARSER ./input i stderr: stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' 724. glr-regression.at:593: testing Duplicate representation of merged trees: %union { char *ptr; } glr.cc ... ./glr-regression.at:593: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.cc glr-regr4.y ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaap stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaT ./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaf835cf40->Object::Object { } Next token is token 'a' (0xaaaaf835cf40 'a') Shifting token 'a' (0xaaaaf835cf40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf835cf40 'a') -> $$ = nterm item (0xaaaaf835cf40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaaf835cf90->Object::Object { 0xaaaaf835cf40 } Next token is token 'a' (0xaaaaf835cf90 'a') Shifting token 'a' (0xaaaaf835cf90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf835cf90 'a') -> $$ = nterm item (0xaaaaf835cf90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaaf835cfe0->Object::Object { 0xaaaaf835cf40, 0xaaaaf835cf90 } Next token is token 'a' (0xaaaaf835cfe0 'a') Shifting token 'a' (0xaaaaf835cfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf835cfe0 'a') -> $$ = nterm item (0xaaaaf835cfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaaf835d030->Object::Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0 } Next token is token 'a' (0xaaaaf835d030 'a') Shifting token 'a' (0xaaaaf835d030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf835d030 'a') -> $$ = nterm item (0xaaaaf835d030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaaf835d080->Object::Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0, 0xaaaaf835d030 } Next token is token 'p' (0xaaaaf835d080 'p'Exception caught: cleaning lookahead and stack 0xaaaaf835d080->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0, 0xaaaaf835d030, 0xaaaaf835d080 } 0xaaaaf835d030->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0, 0xaaaaf835d030 } 0xaaaaf835cfe0->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0 } 0xaaaaf835cf90->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90 } 0xaaaaf835cf40->Object::~Object { 0xaaaaf835cf40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaR stderr: ./glr-regression.at:593: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr4 glr-regr4.cc $LIBS stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaf835cf40->Object::Object { } Next token is token 'a' (0xaaaaf835cf40 'a') Shifting token 'a' (0xaaaaf835cf40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf835cf40 'a') -> $$ = nterm item (0xaaaaf835cf40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaaf835cf90->Object::Object { 0xaaaaf835cf40 } Next token is token 'a' (0xaaaaf835cf90 'a') Shifting token 'a' (0xaaaaf835cf90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf835cf90 'a') -> $$ = nterm item (0xaaaaf835cf90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaaf835cfe0->Object::Object { 0xaaaaf835cf40, 0xaaaaf835cf90 } Next token is token 'a' (0xaaaaf835cfe0 'a') Shifting token 'a' (0xaaaaf835cfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf835cfe0 'a') -> $$ = nterm item (0xaaaaf835cfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaaf835d030->Object::Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0 } Next token is token 'a' (0xaaaaf835d030 'a') Shifting token 'a' (0xaaaaf835d030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf835d030 'a') -> $$ = nterm item (0xaaaaf835d030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaaf835d080->Object::Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0, 0xaaaaf835d030 } Next token is token 'p' (0xaaaaf835d080 'p'Exception caught: cleaning lookahead and stack 0xaaaaf835d080->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0, 0xaaaaf835d030, 0xaaaaf835d080 } 0xaaaaf835d030->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0, 0xaaaaf835d030 } 0xaaaaf835cfe0->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0 } 0xaaaaf835cf90->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90 } 0xaaaaf835cf40->Object::~Object { 0xaaaaf835cf40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr stderr: stdout: ./glr-regression.at:207: $PREPARSER ./glr-regr1 BPBPB stderr: ./glr-regression.at:207: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: exception caught: printer ./c++.at:1361: $PREPARSER ./input aaaae 685. c++.at:1360: ok stderr: exception caught: syntax error 716. glr-regression.at:207: ok ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 725. glr-regression.at:594: testing Duplicate representation of merged trees: %union { char *ptr; } glr2.cc ... ./c++.at:1361: $PREPARSER ./input aaaaT ./glr-regression.at:594: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.cc glr-regr4.y stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 726. glr-regression.at:596: testing Duplicate representation of merged trees: api.value.type=union glr.c ... ./c++.at:1361: $PREPARSER ./input aaaaR stderr: ./glr-regression.at:596: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.c glr-regr4.y ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 686. c++.at:1361: ok ./glr-regression.at:594: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr4 glr-regr4.cc $LIBS ./glr-regression.at:596: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr4 glr-regr4.c $LIBS 727. glr-regression.at:597: testing Duplicate representation of merged trees: api.value.type=union glr.cc ... ./glr-regression.at:597: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.cc glr-regr4.y stderr: stdout: ./glr-regression.at:592: $PREPARSER ./glr-regr4 stderr: ./glr-regression.at:592: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:597: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr4 glr-regr4.cc $LIBS 723. glr-regression.at:592: ok stderr: stdout: ./glr-regression.at:489: $PREPARSER ./glr-regr3 input.txt stderr: stdout: stderr: ./c++.at:858: $PREPARSER ./input stderr: ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./glr-regression.at:489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 721. glr-regression.at:489: ok 728. glr-regression.at:598: testing Duplicate representation of merged trees: api.value.type=union glr2.cc ... ./glr-regression.at:598: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.cc glr-regr4.y ./glr-regression.at:598: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr4 glr-regr4.cc $LIBS 729. glr-regression.at:670: testing User destructor for unresolved GLR semantic value: glr.c ... ./glr-regression.at:670: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr5.c glr-regr5.y ./glr-regression.at:670: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr5 glr-regr5.c $LIBS stderr: stdout: ./glr-regression.at:596: $PREPARSER ./glr-regr4 stderr: ./glr-regression.at:596: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 726. glr-regression.at:596: ok stderr: stdout: ./glr-regression.at:356: $PREPARSER ./glr-regr2a input1.txt stderr: ./glr-regression.at:356: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 730. glr-regression.at:671: testing User destructor for unresolved GLR semantic value: glr.cc ... ./glr-regression.at:671: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr5.cc glr-regr5.y ./glr-regression.at:356: $PREPARSER ./glr-regr2a input2.txt stderr: ./glr-regression.at:356: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:356: $PREPARSER ./glr-regr2a input3.txt stderr: ./glr-regression.at:356: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 719. glr-regression.at:356: ok ./glr-regression.at:671: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr5 glr-regr5.cc $LIBS 731. glr-regression.at:672: testing User destructor for unresolved GLR semantic value: glr2.cc ... ./glr-regression.at:672: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr5.cc glr-regr5.y stderr: stdout: ./glr-regression.at:593: $PREPARSER ./glr-regr4 stderr: ./glr-regression.at:593: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:858: $PREPARSER ./input 724. glr-regression.at:593: ok stderr: ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:672: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr5 glr-regr5.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 732. glr-regression.at:738: testing User destructor after an error during a split parse: glr.c ... ./glr-regression.at:738: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr6.c glr-regr6.y stderr: stdout: ./glr-regression.at:670: $PREPARSER ./glr-regr5 stderr: Ambiguity detected. Option 1, start -> 'a' Option 2, start -> 'a' syntax is ambiguous stderr: stdout: ./glr-regression.at:738: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr6 glr-regr6.c $LIBS ./glr-regression.at:670: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:597: $PREPARSER ./glr-regr4 stderr: ./glr-regression.at:597: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 727. glr-regression.at:597: ok 729. glr-regression.at:670: ok 733. glr-regression.at:739: testing User destructor after an error during a split parse: glr.cc ... 734. glr-regression.at:740: testing User destructor after an error during a split parse: glr2.cc ... ./glr-regression.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr6.cc glr-regr6.y ./glr-regression.at:739: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr6.cc glr-regr6.y ./glr-regression.at:739: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr6 glr-regr6.cc $LIBS ./glr-regression.at:740: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr6 glr-regr6.cc $LIBS stderr: stdout: ./glr-regression.at:738: $PREPARSER ./glr-regr6 stderr: Ambiguity detected. Option 1, start -> 'a' Option 2, start -> 'a' syntax is ambiguous ./glr-regression.at:738: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 732. glr-regression.at:738: ok stderr: stdout: stderr: ./glr-regression.at:490: $PREPARSER ./glr-regr3 input.txt stdout: stderr: ./c++.at:858: $PREPARSER ./input stderr: ./glr-regression.at:490: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 722. glr-regression.at:490: ok ======== Testing with C++ standard flags: '' ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 735. glr-regression.at:843: testing Duplicated user destructor for lookahead: glr.c ... ./glr-regression.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr7.c glr-regr7.y stderr: stdout: ./glr-regression.at:671: $PREPARSER ./glr-regr5 stderr: ./glr-regression.at:843: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr7 glr-regr7.c $LIBS Ambiguity detected. Option 1, start -> 'a' Option 2, start -> 'a' syntax is ambiguous ./glr-regression.at:671: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1362: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaal 730. glr-regression.at:671: stderr: ok exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaap stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffffa294ce0->Object::Object { } 0xfffffa294de0->Object::Object { 0xfffffa294ce0 } 0xfffffa294ce0->Object::~Object { 0xfffffa294ce0, 0xfffffa294de0 } Next token is token 'a' (0xfffffa294de0 'a') 0xfffffa294d20->Object::Object { 0xfffffa294de0 } 0xfffffa294de0->Object::~Object { 0xfffffa294d20, 0xfffffa294de0 } Shifting token 'a' (0xfffffa294d20 'a') 0xaaaacf2732e0->Object::Object { 0xfffffa294d20 } 0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xfffffa294d20 } Entering state 2 Stack now 0 2 0xfffffa294e00->Object::Object { 0xaaaacf2732e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacf2732e0 'a') -> $$ = nterm item (0xfffffa294e00 'a') 0xaaaacf2732e0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294e00 } 0xaaaacf2732e0->Object::Object { 0xfffffa294e00 } 0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xfffffa294e00 } Entering state 11 Stack now 0 11 Reading a token 0xfffffa294ce0->Object::Object { 0xaaaacf2732e0 } 0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xfffffa294ce0 } 0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294ce0, 0xfffffa294de0 } Next token is token 'a' (0xfffffa294de0 'a') 0xfffffa294d20->Object::Object { 0xaaaacf2732e0, 0xfffffa294de0 } 0xfffffa294de0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294d20, 0xfffffa294de0 } Shifting token 'a' (0xfffffa294d20 'a') 0xaaaacf273300->Object::Object { 0xaaaacf2732e0, 0xfffffa294d20 } 0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294d20 } Entering state 2 Stack now 0 11 2 0xfffffa294e00->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacf273300 'a') -> $$ = nterm item (0xfffffa294e00 'a') 0xaaaacf273300->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294e00 } 0xaaaacf273300->Object::Object { 0xaaaacf2732e0, 0xfffffa294e00 } 0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294e00 } Entering state 11 Stack now 0 11 11 Reading a token 0xfffffa294ce0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300 } 0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294ce0 } 0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294ce0, 0xfffffa294de0 } Next token is token 'a' (0xfffffa294de0 'a') 0xfffffa294d20->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294de0 } 0xfffffa294de0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294d20, 0xfffffa294de0 } Shifting token 'a' (0xfffffa294d20 'a') 0xaaaacf273320->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294d20 } 0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294d20 } Entering state 2 Stack now 0 11 11 2 0xfffffa294e00->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacf273320 'a') -> $$ = nterm item (0xfffffa294e00 'a') 0xaaaacf273320->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294e00 } 0xaaaacf273320->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294e00 } 0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294e00 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xfffffa294ce0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320 } 0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294ce0 } 0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294ce0, 0xfffffa294de0 } Next token is token 'a' (0xfffffa294de0 'a') 0xfffffa294d20->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294de0 } 0xfffffa294de0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294d20, 0xfffffa294de0 } Shifting token 'a' (0xfffffa294d20 'a') 0xaaaacf273340->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294d20 } 0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294d20 } Entering state 2 Stack now 0 11 11 11 2 0xfffffa294e00->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacf273340 'a') -> $$ = nterm item (0xfffffa294e00 'a') 0xaaaacf273340->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294e00 } 0xaaaacf273340->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294e00 } 0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294e00 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xfffffa294ce0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340 } 0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294ce0 } 0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294ce0, 0xfffffa294de0 } Next token is token 'p' (0xfffffa294de0 'p'Exception caught: cleaning lookahead and stack 0xaaaacf273340->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294de0 } 0xaaaacf273320->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294de0 } 0xaaaacf273300->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294de0 } 0xaaaacf2732e0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294de0 } 0xfffffa294de0->Object::~Object { 0xfffffa294de0 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 736. glr-regression.at:844: testing Duplicated user destructor for lookahead: glr.cc ... ./glr-regression.at:844: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr7.cc glr-regr7.y Starting parse Entering state 0 Stack now 0 Reading a token 0xfffffa294ce0->Object::Object { } 0xfffffa294de0->Object::Object { 0xfffffa294ce0 } 0xfffffa294ce0->Object::~Object { 0xfffffa294ce0, 0xfffffa294de0 } Next token is token 'a' (0xfffffa294de0 'a') 0xfffffa294d20->Object::Object { 0xfffffa294de0 } 0xfffffa294de0->Object::~Object { 0xfffffa294d20, 0xfffffa294de0 } Shifting token 'a' (0xfffffa294d20 'a') 0xaaaacf2732e0->Object::Object { 0xfffffa294d20 } 0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xfffffa294d20 } Entering state 2 Stack now 0 2 0xfffffa294e00->Object::Object { 0xaaaacf2732e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacf2732e0 'a') -> $$ = nterm item (0xfffffa294e00 'a') 0xaaaacf2732e0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294e00 } 0xaaaacf2732e0->Object::Object { 0xfffffa294e00 } 0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xfffffa294e00 } Entering state 11 Stack now 0 11 Reading a token 0xfffffa294ce0->Object::Object { 0xaaaacf2732e0 } 0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xfffffa294ce0 } 0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294ce0, 0xfffffa294de0 } Next token is token 'a' (0xfffffa294de0 'a') 0xfffffa294d20->Object::Object { 0xaaaacf2732e0, 0xfffffa294de0 } 0xfffffa294de0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294d20, 0xfffffa294de0 } Shifting token 'a' (0xfffffa294d20 'a') 0xaaaacf273300->Object::Object { 0xaaaacf2732e0, 0xfffffa294d20 } 0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294d20 } Entering state 2 Stack now 0 11 2 0xfffffa294e00->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacf273300 'a') -> $$ = nterm item (0xfffffa294e00 'a') 0xaaaacf273300->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294e00 } 0xaaaacf273300->Object::Object { 0xaaaacf2732e0, 0xfffffa294e00 } 0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294e00 } Entering state 11 Stack now 0 11 11 Reading a token 0xfffffa294ce0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300 } 0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294ce0 } 0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294ce0, 0xfffffa294de0 } Next token is token 'a' (0xfffffa294de0 'a') 0xfffffa294d20->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294de0 } 0xfffffa294de0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294d20, 0xfffffa294de0 } Shifting token 'a' (0xfffffa294d20 'a') 0xaaaacf273320->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294d20 } 0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294d20 } Entering state 2 Stack now 0 11 11 2 0xfffffa294e00->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacf273320 'a') -> $$ = nterm item (0xfffffa294e00 'a') 0xaaaacf273320->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294e00 } 0xaaaacf273320->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294e00 } 0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294e00 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xfffffa294ce0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320 } 0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294ce0 } 0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294ce0, 0xfffffa294de0 } Next token is token 'a' (0xfffffa294de0 'a') 0xfffffa294d20->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294de0 } 0xfffffa294de0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294d20, 0xfffffa294de0 } Shifting token 'a' (0xfffffa294d20 'a') 0xaaaacf273340->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294d20 } 0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294d20 } Entering state 2 Stack now 0 11 11 11 2 0xfffffa294e00->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacf273340 'a') -> $$ = nterm item (0xfffffa294e00 'a') 0xaaaacf273340->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294e00 } 0xaaaacf273340->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294e00 } 0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294e00 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xfffffa294ce0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340 } 0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294ce0 } 0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294ce0, 0xfffffa294de0 } Next token is token 'p' (0xfffffa294de0 'p'Exception caught: cleaning lookahead and stack 0xaaaacf273340->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294de0 } 0xaaaacf273320->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294de0 } 0xaaaacf273300->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294de0 } 0xaaaacf2732e0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294de0 } 0xfffffa294de0->Object::~Object { 0xfffffa294de0 } exception caught: printer end { } ./c++.at:1362: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 737. glr-regression.at:845: testing Duplicated user destructor for lookahead: glr2.cc ... ./glr-regression.at:845: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr7.cc glr-regr7.y ./glr-regression.at:844: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr7 glr-regr7.cc $LIBS ./c++.at:1362: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:845: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr7 glr-regr7.cc $LIBS ./c++.at:1362: $PREPARSER ./input aaaaT stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaR stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 687. c++.at:1362: ok stdout: ./c++.at:1363: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 738. glr-regression.at:944: testing Incorrectly initialized location for empty right-hand side in GLR: glr.c ... ./glr-regression.at:944: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr8.c glr-regr8.y ./c++.at:1363: $PREPARSER ./input aaaap stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./glr-regression.at:598: $PREPARSER ./glr-regr4 ./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: ./glr-regression.at:598: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffeb822140->Object::Object { } 0xffffeb822240->Object::Object { 0xffffeb822140 } 0xffffeb822140->Object::~Object { 0xffffeb822140, 0xffffeb822240 } Next token is token 'a' (0xffffeb822240 'a') 0xffffeb822180->Object::Object { 0xffffeb822240 } 0xffffeb822240->Object::~Object { 0xffffeb822180, 0xffffeb822240 } Shifting token 'a' (0xffffeb822180 'a') 0xaaaab82d12e0->Object::Object { 0xffffeb822180 } 0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xffffeb822180 } Entering state 1 Stack now 0 1 0xffffeb822260->Object::Object { 0xaaaab82d12e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab82d12e0 'a') -> $$ = nterm item (0xffffeb822260 'a') 0xaaaab82d12e0->Object::~Object { 0xaaaab82d12e0, 0xffffeb822260 } 0xaaaab82d12e0->Object::Object { 0xffffeb822260 } 0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xffffeb822260 } Entering state 10 Stack now 0 10 Reading a token 0xffffeb822140->Object::Object { 0xaaaab82d12e0 } 0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xffffeb822140 } 0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xffffeb822140, 0xffffeb822240 } Next token is token 'a' (0xffffeb822240 'a') 0xffffeb822180->Object::Object { 0xaaaab82d12e0, 0xffffeb822240 } 0xffffeb822240->Object::~Object { 0xaaaab82d12e0, 0xffffeb822180, 0xffffeb822240 } Shifting token 'a' (0xffffeb822180 'a') 0xaaaab82d1300->Object::Object { 0xaaaab82d12e0, 0xffffeb822180 } 0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822180 } Entering state 1 Stack now 0 10 1 0xffffeb822260->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab82d1300 'a') -> $$ = nterm item (0xffffeb822260 'a') 0xaaaab82d1300->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822260 } 0xaaaab82d1300->Object::Object { 0xaaaab82d12e0, 0xffffeb822260 } 0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822260 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffeb822140->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300 } 0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822140 } 0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822140, 0xffffeb822240 } Next token is token 'a' (0xffffeb822240 'a') 0xffffeb822180->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822240 } 0xffffeb822240->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822180, 0xffffeb822240 } Shifting token 'a' (0xffffeb822180 'a') 0xaaaab82d1320->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822180 } 0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822180 } Entering state 1 Stack now 0 10 10 1 0xffffeb822260->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab82d1320 'a') -> $$ = nterm item (0xffffeb822260 'a') 0xaaaab82d1320->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822260 } 0xaaaab82d1320->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822260 } 0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822260 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffeb822140->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320 } 0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822140 } 0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822140, 0xffffeb822240 } Next token is token 'a' (0xffffeb822240 'a') 0xffffeb822180->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822240 } 0xffffeb822240->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822180, 0xffffeb822240 } Shifting token 'a' (0xffffeb822180 'a') 0xaaaab82d1340->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822180 } 0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822180 } Entering state 1 Stack now 0 10 10 10 1 0xffffeb822260->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab82d1340 'a') -> $$ = nterm item (0xffffeb822260 'a') 0xaaaab82d1340->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822260 } 0xaaaab82d1340->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822260 } 0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822260 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffeb822140->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340 } 0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822140 } 0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822140, 0xffffeb822240 } Next token is token 'p' (0xffffeb822240 'p'Exception caught: cleaning lookahead and stack 0xaaaab82d1340->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822240 } 0xaaaab82d1320->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822240 } 0xaaaab82d1300->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822240 } 0xaaaab82d12e0->Object::~Object { 0xaaaab82d12e0, 0xffffeb822240 } 0xffffeb822240->Object::~Object { 0xffffeb822240 } exception caught: printer end { } stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:944: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr8 glr-regr8.c $LIBS 728. glr-regression.at:598: ok stdout: stderr: ./glr-regression.at:843: $PREPARSER ./glr-regr7 stderr: memory exhausted Starting parse Entering state 0 Stack now 0 Reading a token 0xffffeb822140->Object::Object { } 0xffffeb822240->Object::Object { 0xffffeb822140 } 0xffffeb822140->Object::~Object { 0xffffeb822140, 0xffffeb822240 } Next token is token 'a' (0xffffeb822240 'a') 0xffffeb822180->Object::Object { 0xffffeb822240 } 0xffffeb822240->Object::~Object { 0xffffeb822180, 0xffffeb822240 } Shifting token 'a' (0xffffeb822180 'a') 0xaaaab82d12e0->Object::Object { 0xffffeb822180 } 0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xffffeb822180 } Entering state 1 Stack now 0 1 0xffffeb822260->Object::Object { 0xaaaab82d12e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab82d12e0 'a') -> $$ = nterm item (0xffffeb822260 'a') 0xaaaab82d12e0->Object::~Object { 0xaaaab82d12e0, 0xffffeb822260 } 0xaaaab82d12e0->Object::Object { 0xffffeb822260 } 0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xffffeb822260 } Entering state 10 Stack now 0 10 Reading a token 0xffffeb822140->Object::Object { 0xaaaab82d12e0 } 0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xffffeb822140 } 0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xffffeb822140, 0xffffeb822240 } Next token is token 'a' (0xffffeb822240 'a') 0xffffeb822180->Object::Object { 0xaaaab82d12e0, 0xffffeb822240 } 0xffffeb822240->Object::~Object { 0xaaaab82d12e0, 0xffffeb822180, 0xffffeb822240 } Shifting token 'a' (0xffffeb822180 'a') 0xaaaab82d1300->Object::Object { 0xaaaab82d12e0, 0xffffeb822180 } 0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822180 } Entering state 1 Stack now 0 10 1 0xffffeb822260->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab82d1300 'a') -> $$ = nterm item (0xffffeb822260 'a') 0xaaaab82d1300->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822260 } 0xaaaab82d1300->Object::Object { 0xaaaab82d12e0, 0xffffeb822260 } 0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822260 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffeb822140->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300 } 0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822140 } 0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822140, 0xffffeb822240 } Next token is token 'a' (0xffffeb822240 'a') 0xffffeb822180->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822240 } 0xffffeb822240->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822180, 0xffffeb822240 } Shifting token 'a' (0xffffeb822180 'a') 0xaaaab82d1320->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822180 } 0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822180 } Entering state 1 Stack now 0 10 10 1 0xffffeb822260->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab82d1320 'a') -> $$ = nterm item (0xffffeb822260 'a') 0xaaaab82d1320->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822260 } 0xaaaab82d1320->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822260 } 0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822260 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffeb822140->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320 } 0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822140 } 0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822140, 0xffffeb822240 } Next token is token 'a' (0xffffeb822240 'a') 0xffffeb822180->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822240 } 0xffffeb822240->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822180, 0xffffeb822240 } Shifting token 'a' (0xffffeb822180 'a') 0xaaaab82d1340->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822180 } 0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822180 } Entering state 1 Stack now 0 10 10 10 1 0xffffeb822260->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab82d1340 'a') -> $$ = nterm item (0xffffeb822260 'a') 0xaaaab82d1340->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822260 } 0xaaaab82d1340->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822260 } 0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822260 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffeb822140->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340 } 0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822140 } 0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822140, 0xffffeb822240 } Next token is token 'p' (0xffffeb822240 'p'Exception caught: cleaning lookahead and stack 0xaaaab82d1340->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822240 } 0xaaaab82d1320->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822240 } 0xaaaab82d1300->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822240 } 0xaaaab82d12e0->Object::~Object { 0xaaaab82d12e0, 0xffffeb822240 } 0xffffeb822240->Object::~Object { 0xffffeb822240 } exception caught: printer end { } ./glr-regression.at:843: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1363: $PREPARSER ./input aaaae stderr: 735. glr-regression.at:843: ok exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaT stderr: stderr: stdout: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:739: $PREPARSER ./glr-regr6 stderr: Ambiguity detected. Option 1, start -> 'a' Option 2, start -> 'a' syntax is ambiguous ./glr-regression.at:739: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaR 733. glr-regression.at:739: ok stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 739. glr-regression.at:945: testing Incorrectly initialized location for empty right-hand side in GLR: glr.cc ... 740. glr-regression.at:946: testing Incorrectly initialized location for empty right-hand side in GLR: glr2.cc ... ./glr-regression.at:946: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr8.cc glr-regr8.y 688. c++.at:1363: ok ./glr-regression.at:945: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr8.cc glr-regr8.y ./glr-regression.at:946: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr8 glr-regr8.cc $LIBS ./glr-regression.at:945: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr8 glr-regr8.cc $LIBS 741. glr-regression.at:1036: testing No users destructors if stack 0 deleted: glr.c ... stderr: ./glr-regression.at:1036: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr9.c glr-regr9.y stdout: ./c++.at:858: $PREPARSER ./input stderr: ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 742. glr-regression.at:1037: testing No users destructors if stack 0 deleted: glr.cc ... ======== Testing with C++ standard flags: '' stderr: ./glr-regression.at:1037: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr9.cc glr-regr9.y ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: ./glr-regression.at:594: $PREPARSER ./glr-regr4 stderr: ./glr-regression.at:1036: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr9 glr-regr9.c $LIBS ./glr-regression.at:594: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1037: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr9 glr-regr9.cc $LIBS 725. glr-regression.at:594: ok 743. glr-regression.at:1038: testing No users destructors if stack 0 deleted: glr2.cc ... ./glr-regression.at:1038: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr9.cc glr-regr9.y ./glr-regression.at:1038: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr9 glr-regr9.cc $LIBS stderr: stdout: ./glr-regression.at:944: $PREPARSER ./glr-regr8 stderr: ./glr-regression.at:944: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 738. glr-regression.at:944: ok 744. glr-regression.at:1102: testing Corrupted semantic options if user action cuts parse: glr.c ... ./glr-regression.at:1102: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr10.c glr-regr10.y stderr: stdout: ./glr-regression.at:844: $PREPARSER ./glr-regr7 stderr: memory exhausted ./glr-regression.at:1102: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr10 glr-regr10.c $LIBS ./glr-regression.at:844: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 736. glr-regression.at:844: ok stderr: stdout: ./glr-regression.at:672: $PREPARSER ./glr-regr5 stderr: Ambiguity detected. Option 1, start -> 'a' Option 2, start -> 'a' syntax is ambiguous ./glr-regression.at:672: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 745. glr-regression.at:1103: testing Corrupted semantic options if user action cuts parse: glr.cc ... ./glr-regression.at:1103: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr10.cc glr-regr10.y 731. glr-regression.at:672: ok ./glr-regression.at:1103: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr10 glr-regr10.cc $LIBS stderr: stdout: ./glr-regression.at:1036: $PREPARSER ./glr-regr9 stderr: memory exhausted ./glr-regression.at:1036: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 741. glr-regression.at:1036: ok stderr: stdout: ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $PREPARSER ./input < in stderr: 746. glr-regression.at:1104: testing Corrupted semantic options if user action cuts parse: glr2.cc ... error: invalid expression ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid character ./glr-regression.at:1104: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr10.cc glr-regr10.y ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 684. c++.at:1066: ok ./glr-regression.at:1104: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr10 glr-regr10.cc $LIBS stderr: stdout: 747. glr-regression.at:1174: testing Undesirable destructors if user action cuts parse: glr.c ... ./glr-regression.at:1174: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr11.c glr-regr11.y ./c++.at:858: $PREPARSER ./input stderr: ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 748. glr-regression.at:1175: testing Undesirable destructors if user action cuts parse: glr.cc ... ./glr-regression.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr11.cc glr-regr11.y ======== Testing with C++ standard flags: '' ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./glr-regression.at:1174: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr11 glr-regr11.c $LIBS ./glr-regression.at:1175: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr11 glr-regr11.cc $LIBS stdout: ./glr-regression.at:945: $PREPARSER ./glr-regr8 stderr: stderr: stderr: stdout: stdout: ./glr-regression.at:945: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1102: $PREPARSER ./glr-regr10 ./glr-regression.at:1037: $PREPARSER ./glr-regr9 739. glr-regression.at:945: ok stderr: stderr: memory exhausted ./glr-regression.at:1037: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1102: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 742. glr-regression.at:1037: ok stdout: 744. glr-regression.at:1102: ok ./glr-regression.at:740: $PREPARSER ./glr-regr6 stderr: Ambiguity detected. Option 1, start -> 'a' Option 2, start -> 'a' syntax is ambiguous ./glr-regression.at:740: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 749. glr-regression.at:1176: testing Undesirable destructors if user action cuts parse: glr2.cc ... ./glr-regression.at:1176: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr11.cc glr-regr11.y 734. glr-regression.at:740: ok 750. glr-regression.at:1310: testing Leaked semantic values if user action cuts parse: glr.c ... ./glr-regression.at:1310: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr12.c glr-regr12.y ./glr-regression.at:1310: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr12 glr-regr12.c $LIBS 751. glr-regression.at:1311: testing Leaked semantic values if user action cuts parse: glr.cc ... ./glr-regression.at:1311: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr12.cc glr-regr12.y ./glr-regression.at:1176: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr11 glr-regr11.cc $LIBS ./glr-regression.at:1311: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr12 glr-regr12.cc $LIBS 752. glr-regression.at:1312: testing Leaked semantic values if user action cuts parse: glr2.cc ... ./glr-regression.at:1312: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr12.cc glr-regr12.y ./glr-regression.at:1312: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr12 glr-regr12.cc $LIBS stderr: stdout: ./glr-regression.at:1174: $PREPARSER ./glr-regr11 stderr: ./glr-regression.at:1174: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 747. glr-regression.at:1174: ok stderr: stdout: stderr: stdout: ./glr-regression.at:845: $PREPARSER ./glr-regr7 ./glr-regression.at:1103: $PREPARSER ./glr-regr10 stderr: stderr: memory exhausted ./glr-regression.at:845: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 753. glr-regression.at:1445: testing Incorrect lookahead during deterministic GLR: glr.c ... stdout: ./glr-regression.at:1310: $PREPARSER ./glr-regr12 stderr: ./glr-regression.at:1445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr13.c glr-regr13.y stderr: ./glr-regression.at:1310: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 737. glr-regression.at:845: ok ./glr-regression.at:1103: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 745. glr-regression.at:1103: ok 750. glr-regression.at:1310: ok ./glr-regression.at:1445: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr13 glr-regr13.c $LIBS 754. glr-regression.at:1446: testing Incorrect lookahead during deterministic GLR: glr.cc ... ./glr-regression.at:1446: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr13.cc glr-regr13.y 756. glr-regression.at:1678: testing Incorrect lookahead during nondeterministic GLR: glr.c ... ./glr-regression.at:1678: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr14.c glr-regr14.y 755. glr-regression.at:1447: testing Incorrect lookahead during deterministic GLR: glr2.cc ... ./glr-regression.at:1447: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr13.cc glr-regr13.y ./glr-regression.at:1446: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr13 glr-regr13.cc $LIBS ./glr-regression.at:1678: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr14 glr-regr14.c $LIBS ./glr-regression.at:1447: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr13 glr-regr13.cc $LIBS stderr: stdout: ./glr-regression.at:1175: $PREPARSER ./glr-regr11 stderr: ./glr-regression.at:1175: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 748. glr-regression.at:1175: ok 757. glr-regression.at:1679: testing Incorrect lookahead during nondeterministic GLR: glr.cc ... ./glr-regression.at:1679: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr14.cc glr-regr14.y ./glr-regression.at:1679: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr14 glr-regr14.cc $LIBS stderr: stdout: ./glr-regression.at:1311: $PREPARSER ./glr-regr12 stderr: ./glr-regression.at:1311: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 751. glr-regression.at:1311: ok stderr: stdout: ./glr-regression.at:946: $PREPARSER ./glr-regr8 stderr: ./glr-regression.at:946: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./glr-regression.at:1445: $PREPARSER ./glr-regr13 758. glr-regression.at:1680: testing Incorrect lookahead during nondeterministic GLR: glr2.cc ... ./glr-regression.at:1680: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr14.cc glr-regr14.y stderr: 740. glr-regression.at:946: ok ./glr-regression.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1680: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr14 glr-regr14.cc $LIBS 753. glr-regression.at:1445: ok stderr: stdout: ./c++.at:858: $PREPARSER ./input stderr: ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy 759. glr-regression.at:1785: testing Leaked semantic values when reporting ambiguity: glr.c ... ./glr-regression.at:1785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr15.c glr-regr15.y ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 760. glr-regression.at:1786: testing Leaked semantic values when reporting ambiguity: glr.cc ... ./glr-regression.at:1786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr15.cc glr-regr15.y ./glr-regression.at:1785: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr15 glr-regr15.c $LIBS stderr: stdout: ./glr-regression.at:1038: $PREPARSER ./glr-regr9 stderr: memory exhausted ./glr-regression.at:1038: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1786: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr15 glr-regr15.cc $LIBS 743. glr-regression.at:1038: ok 761. glr-regression.at:1787: testing Leaked semantic values when reporting ambiguity: glr2.cc ... stderr: stdout: ./glr-regression.at:1787: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr15.cc glr-regr15.y ./glr-regression.at:1678: $PREPARSER ./glr-regr14 stderr: ./glr-regression.at:1678: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 756. glr-regression.at:1678: ok ./glr-regression.at:1787: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr15 glr-regr15.cc $LIBS 762. glr-regression.at:1860: testing Leaked lookahead after nondeterministic parse syntax error: glr.c ... ./glr-regression.at:1860: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr16.c glr-regr16.y stderr: stdout: ./glr-regression.at:1446: $PREPARSER ./glr-regr13 ./glr-regression.at:1860: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr16 glr-regr16.c $LIBS stderr: ./glr-regression.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 754. glr-regression.at:1446: ok stderr: stdout: ./glr-regression.at:1785: $PREPARSER ./glr-regr15 stderr: Ambiguity detected. Option 1, ambiguity -> ambiguity1 -> Option 2, ambiguity -> ambiguity2 -> syntax is ambiguous ./glr-regression.at:1785: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 759. glr-regression.at:1785: ok 763. glr-regression.at:1861: testing Leaked lookahead after nondeterministic parse syntax error: glr.cc ... ./glr-regression.at:1861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr16.cc glr-regr16.y stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./glr-regression.at:1861: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr16 glr-regr16.cc $LIBS 764. glr-regression.at:1862: testing Leaked lookahead after nondeterministic parse syntax error: glr2.cc ... ./glr-regression.at:1862: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr16.cc glr-regr16.y stderr: stdout: ./glr-regression.at:1176: $PREPARSER ./glr-regr11 stderr: ./glr-regression.at:1176: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 749. glr-regression.at:1176: ok ./glr-regression.at:1862: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr16 glr-regr16.cc $LIBS stderr: stdout: ./glr-regression.at:1312: $PREPARSER ./glr-regr12 stderr: ./glr-regression.at:1312: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: 752. glr-regression.at:1312: ok ./glr-regression.at:1104: $PREPARSER ./glr-regr10 stderr: ./glr-regression.at:1104: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 746. glr-regression.at:1104: ok 765. glr-regression.at:1964: testing Uninitialized location when reporting ambiguity: glr.c api.pure ... ./glr-regression.at:1964: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr17.c glr-regr17.y stderr: 766. glr-regression.at:1965: testing Uninitialized location when reporting ambiguity: glr.cc ... ./glr-regression.at:1965: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr17.cc glr-regr17.y stdout: ./glr-regression.at:1679: $PREPARSER ./glr-regr14 stderr: stderr: stdout: ./glr-regression.at:1860: $PREPARSER ./glr-regr16 stderr: syntax error ./glr-regression.at:1860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1679: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1964: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr17 glr-regr17.c $LIBS ./glr-regression.at:1965: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr17 glr-regr17.cc $LIBS 757. glr-regression.at:1679: ok 762. glr-regression.at:1860: ok 767. glr-regression.at:1966: testing Uninitialized location when reporting ambiguity: glr2.cc ... ./glr-regression.at:1966: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr17.cc glr-regr17.y stderr: stdout: ./glr-regression.at:1786: $PREPARSER ./glr-regr15 stderr: Ambiguity detected. Option 1, ambiguity -> ambiguity1 -> Option 2, ambiguity -> ambiguity2 -> syntax is ambiguous ./glr-regression.at:1786: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 768. glr-regression.at:2035: testing Missed %merge type warnings when LHS type is declared later: glr.c ... ./glr-regression.at:1966: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr17 glr-regr17.cc $LIBS ./glr-regression.at:2035: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o glr-regr18.c -rall -fcaret glr-regr18.y 760. glr-regression.at:1786: ok 768. glr-regression.at:2035: ok 769. glr-regression.at:2036: testing Missed %merge type warnings when LHS type is declared later: glr.cc ... ./glr-regression.at:2036: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o glr-regr18.c -rall -fcaret glr-regr18.y 769. glr-regression.at:2036: ok 770. glr-regression.at:2037: testing Missed %merge type warnings when LHS type is declared later: glr2.cc ... ./glr-regression.at:2037: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o glr-regr18.c -rall -fcaret glr-regr18.y 770. glr-regression.at:2037: ok 771. glr-regression.at:2149: testing Ambiguity reports: glr.c ... ./glr-regression.at:2149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./glr-regression.at:2149: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 773. glr-regression.at:2151: testing Ambiguity reports: glr2.cc ... ./glr-regression.at:2151: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 772. glr-regression.at:2150: testing Ambiguity reports: glr.cc ... ./glr-regression.at:2150: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./c++.at:859: $PREPARSER ./input ./glr-regression.at:2151: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2150: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./glr-regression.at:1861: $PREPARSER ./glr-regr16 stderr: syntax error ./glr-regression.at:1861: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 763. glr-regression.at:1861: ok stderr: stdout: ./glr-regression.at:1964: $PREPARSER ./glr-regr17 stderr: 774. glr-regression.at:2229: testing Predicates: glr.c ... Ambiguity detected. Option 1, start -> ambig1 -> sub_ambig2 -> empty2 -> 'a' 'b' empty1 -> Option 2, start -> ambig2 -> sub_ambig2 -> empty2 -> 'a' 'b' empty2 -> 1.1-2.2: syntax is ambiguous ./glr-regression.at:1964: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2229: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 765. glr-regression.at:1964: ok ./glr-regression.at:2229: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./glr-regression.at:2149: $PREPARSER ./input --debug 775. glr-regression.at:2230: testing Predicates: glr.cc ... stderr: Starting parse Entering state 0 Reading a token Next token is token 'a' () Shifting token 'a' () Entering state 1 Reading a token Next token is token 'b' () Shifting token 'b' () Entering state 3 Reducing stack 0 by rule 3 (line 30): $1 = token 'b' () -> $$ = nterm b () Entering state 4 Reading a token Next token is token 'c' () Shifting token 'c' () Entering state 6 Reducing stack 0 by rule 4 (line 31): -> $$ = nterm d () Entering state 7 Reading a token Now at end of input. Stack 0 Entering state 7 Now at end of input. Splitting off stack 1 from 0. Reduced stack 1 by rule 2 (line 28); action deferred. Now in state 2. Stack 1 Entering state 2 Now at end of input. Reduced stack 0 by rule 1 (line 27); action deferred. Now in state 2. Merging stack 0 into stack 1. Stack 1 Entering state 2 Now at end of input. Removing dead stacks. Rename stack 1 -> 0. On stack 0, shifting token "end of file" () Stack 0 now in state 5 Ambiguity detected. Option 1, start -> 'a' b 'c' d Option 2, start -> 'a' b 'c' d syntax is ambiguous Cleanup: popping token "end of file" () Cleanup: popping unresolved nterm start () Cleanup: popping nterm d () Cleanup: popping token 'c' () Cleanup: popping nterm b () Cleanup: popping token 'a' () ./glr-regression.at:2149: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2230: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 771. glr-regression.at:2149: ok stderr: stdout: ./glr-regression.at:1447: $PREPARSER ./glr-regr13 stderr: ./glr-regression.at:1447: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 755. glr-regression.at:1447: ok ./glr-regression.at:2230: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 776. glr-regression.at:2231: testing Predicates: glr2.cc ... ./glr-regression.at:2231: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./glr-regression.at:2231: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./glr-regression.at:1680: $PREPARSER ./glr-regr14 stderr: ./glr-regression.at:1680: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./glr-regression.at:1965: $PREPARSER ./glr-regr17 758. glr-regression.at:1680: ok stderr: Ambiguity detected. Option 1, start -> ambig1 -> sub_ambig2 -> empty2 -> 'a' 'b' empty1 -> Option 2, start -> ambig2 -> sub_ambig2 -> empty2 -> 'a' 'b' empty2 -> 1.1-2.2: syntax is ambiguous ./glr-regression.at:1965: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 766. glr-regression.at:1965: ok stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./glr-regression.at:2229: $PREPARSER ./input Nwin stderr: ./glr-regression.at:2229: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2229: $PREPARSER ./input Owin stderr: stderr: stdout: syntax error, unexpected 'n', expecting 'o' ./glr-regression.at:1787: $PREPARSER ./glr-regr15 ./glr-regression.at:2229: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Ambiguity detected. Option 1, ambiguity -> ambiguity1 -> Option 2, ambiguity -> ambiguity2 -> syntax is ambiguous ./glr-regression.at:1787: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 761. glr-regression.at:1787: ok ./glr-regression.at:2229: $PREPARSER ./input Owio stderr: ./glr-regression.at:2229: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2229: $PREPARSER ./input Nwio stderr: syntax error, unexpected 'o', expecting 'n' ./glr-regression.at:2229: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 774. glr-regression.at:2229: ok stderr: stdout: ./glr-regression.at:2150: $PREPARSER ./input --debug stderr: Starting parse Entering state 0 Reading a token Next token is token 'a' () Shifting token 'a' () Entering state 1 Reading a token Next token is token 'b' () Shifting token 'b' () Entering state 3 Reducing stack 0 by rule 3 (line 30): $1 = token 'b' () -> $$ = nterm b () Entering state 4 Reading a token Next token is token 'c' () Shifting token 'c' () Entering state 6 Reducing stack 0 by rule 4 (line 31): -> $$ = nterm d () Entering state 7 Reading a token Now at end of input. Stack 0 Entering state 7 Now at end of input. Splitting off stack 1 from 0. Reduced stack 1 by rule 2 (line 28); action deferred. Now in state 2. Stack 1 Entering state 2 Now at end of input. Reduced stack 0 by rule 1 (line 27); action deferred. Now in state 2. Merging stack 0 into stack 1. Stack 1 Entering state 2 Now at end of input. Removing dead stacks. Rename stack 1 -> 0. On stack 0, shifting token "end of file" () Stack 0 now in state 5 Ambiguity detected. Option 1, start -> 'a' b 'c' d Option 2, start -> 'a' b 'c' d syntax is ambiguous Cleanup: popping token "end of file" () Cleanup: popping unresolved nterm start () Cleanup: popping nterm d () Cleanup: popping token 'c' () Cleanup: popping nterm b () Cleanup: popping token 'a' () ./glr-regression.at:2150: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 772. glr-regression.at:2150: ok stderr: stdout: ./glr-regression.at:2230: $PREPARSER ./input Nwin stderr: ./glr-regression.at:2230: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2230: $PREPARSER ./input Owin stderr: syntax error, unexpected 'n', expecting 'o' ./glr-regression.at:2230: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2230: $PREPARSER ./input Owio stderr: ./glr-regression.at:2230: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2230: $PREPARSER ./input Nwio stderr: syntax error, unexpected 'o', expecting 'n' ./glr-regression.at:2230: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 775. glr-regression.at:2230: ok stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./glr-regression.at:1862: $PREPARSER ./glr-regr16 stderr: syntax error ./glr-regression.at:1862: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 764. glr-regression.at:1862: ok stderr: stdout: ./glr-regression.at:1966: $PREPARSER ./glr-regr17 stderr: Ambiguity detected. Option 1, start -> ambig1 -> sub_ambig2 -> empty2 -> 'a' 'b' empty1 -> Option 2, start -> ambig2 -> sub_ambig2 -> empty2 -> 'a' 'b' empty2 -> 1.1-2.2: syntax is ambiguous ./glr-regression.at:1966: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 767. glr-regression.at:1966: ok stderr: stdout: ./glr-regression.at:2151: $PREPARSER ./input --debug stderr: Starting parse Entering state 0 Reading a token Next token is token 'a' () Shifting token 'a' () Entering state 1 Reading a token Next token is token 'b' () Shifting token 'b' () Entering state 3 Reducing stack 0 by rule 3 (line 30): $1 = token 'b' () -> $$ = nterm b () Entering state 4 Reading a token Next token is token 'c' () Shifting token 'c' () Entering state 6 Reducing stack 0 by rule 4 (line 31): -> $$ = nterm d () Entering state 7 Reading a token Now at end of input. Stack 0 Entering state 7 Now at end of input. Splitting off stack 1 from 0. Reduced stack 1 by rule 2 (line 28); action deferred. Now in state 2. Stack 1 Entering state 2 Now at end of input. Reduced stack 0 by rule 1 (line 27); action deferred. Now in state 2. Merging stack 0 into stack 1. Stack 1 Entering state 2 Now at end of input. Removing dead stacks. Rename stack 1 -> 0. On stack 0, shifting token "end of file" () Stack 0 now in state 5 Ambiguity detected. Option 1, start -> 'a' b 'c' d Option 2, start -> 'a' b 'c' d syntax is ambiguous Cleanup: popping token "end of file" () Cleanup: popping unresolved nterm start () Cleanup: popping nterm d () Cleanup: popping token 'c' () Cleanup: popping nterm b () Cleanup: popping token 'a' () ./glr-regression.at:2151: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 773. glr-regression.at:2151: ok stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./glr-regression.at:2231: $PREPARSER ./input Nwin stderr: ./glr-regression.at:2231: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2231: $PREPARSER ./input Owin stderr: syntax error, unexpected 'n', expecting 'o' ./glr-regression.at:2231: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2231: $PREPARSER ./input Owio stderr: ./glr-regression.at:2231: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2231: $PREPARSER ./input Nwio stderr: syntax error, unexpected 'o', expecting 'n' ./glr-regression.at:2231: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 776. glr-regression.at:2231: ok stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:860: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 679. c++.at:854: ok ## ------------- ## ## Test results. ## ## ------------- ## 712 tests were successful. 64 tests were skipped. make[4]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[2]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' create-stamp debian/debhelper-build-stamp dh_prep dh_auto_install make -j12 install DESTDIR=/build/reproducible-path/bison-3.8.2\+dfsg/debian/tmp AM_UPDATE_INFO_DIR=no make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' make install-recursive make[2]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' Making install in po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/po' installing bg.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/bg/LC_MESSAGES/bison.mo installing ca.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ca/LC_MESSAGES/bison.mo installing da.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/da/LC_MESSAGES/bison.mo installing de.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/de/LC_MESSAGES/bison.mo installing el.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/el/LC_MESSAGES/bison.mo installing eo.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/eo/LC_MESSAGES/bison.mo installing es.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/es/LC_MESSAGES/bison.mo installing et.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/et/LC_MESSAGES/bison.mo installing fi.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/fi/LC_MESSAGES/bison.mo installing fr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/fr/LC_MESSAGES/bison.mo installing ga.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ga/LC_MESSAGES/bison.mo installing hr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/hr/LC_MESSAGES/bison.mo installing id.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/id/LC_MESSAGES/bison.mo installing it.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/it/LC_MESSAGES/bison.mo installing ja.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ja/LC_MESSAGES/bison.mo installing ms.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ms/LC_MESSAGES/bison.mo installing nb.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/nb/LC_MESSAGES/bison.mo installing nl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/nl/LC_MESSAGES/bison.mo installing pl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pl/LC_MESSAGES/bison.mo installing pt.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pt/LC_MESSAGES/bison.mo installing pt_BR.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pt_BR/LC_MESSAGES/bison.mo installing ro.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ro/LC_MESSAGES/bison.mo installing ru.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ru/LC_MESSAGES/bison.mo installing sr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sr/LC_MESSAGES/bison.mo installing sv.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sv/LC_MESSAGES/bison.mo installing tr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/tr/LC_MESSAGES/bison.mo installing uk.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/uk/LC_MESSAGES/bison.mo installing vi.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/vi/LC_MESSAGES/bison.mo installing zh_CN.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/zh_CN/LC_MESSAGES/bison.mo installing zh_TW.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/zh_TW/LC_MESSAGES/bison.mo if test "bison" = "gettext-tools"; then \ /usr/bin/mkdir -p /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po; \ for file in Makefile.in.in remove-potcdate.sin quot.sed boldquot.sed en@quot.header en@boldquot.header insert-header.sin Rules-quot Makevars.template; do \ /usr/bin/install -c -m 644 ./$file \ /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po/$file; \ done; \ for file in Makevars; do \ rm -f /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po/$file; \ done; \ else \ : ; \ fi make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/po' Making install in runtime-po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' installing ast.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ast/LC_MESSAGES/bison-runtime.mo installing bg.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/bg/LC_MESSAGES/bison-runtime.mo installing ca.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ca/LC_MESSAGES/bison-runtime.mo installing da.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/da/LC_MESSAGES/bison-runtime.mo installing de.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/de/LC_MESSAGES/bison-runtime.mo installing el.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/el/LC_MESSAGES/bison-runtime.mo installing eo.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/eo/LC_MESSAGES/bison-runtime.mo installing es.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/es/LC_MESSAGES/bison-runtime.mo installing et.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/et/LC_MESSAGES/bison-runtime.mo installing fi.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/fi/LC_MESSAGES/bison-runtime.mo installing fr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/fr/LC_MESSAGES/bison-runtime.mo installing ga.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ga/LC_MESSAGES/bison-runtime.mo installing gl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/gl/LC_MESSAGES/bison-runtime.mo installing hr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/hr/LC_MESSAGES/bison-runtime.mo installing hu.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/hu/LC_MESSAGES/bison-runtime.mo installing ia.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ia/LC_MESSAGES/bison-runtime.mo installing id.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/id/LC_MESSAGES/bison-runtime.mo installing it.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/it/LC_MESSAGES/bison-runtime.mo installing ja.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ja/LC_MESSAGES/bison-runtime.mo installing ky.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ky/LC_MESSAGES/bison-runtime.mo installing lt.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/lt/LC_MESSAGES/bison-runtime.mo installing lv.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/lv/LC_MESSAGES/bison-runtime.mo installing ms.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ms/LC_MESSAGES/bison-runtime.mo installing nb.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/nb/LC_MESSAGES/bison-runtime.mo installing nl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/nl/LC_MESSAGES/bison-runtime.mo installing pl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pl/LC_MESSAGES/bison-runtime.mo installing pt.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pt/LC_MESSAGES/bison-runtime.mo installing pt_BR.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pt_BR/LC_MESSAGES/bison-runtime.mo installing ro.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ro/LC_MESSAGES/bison-runtime.mo installing ru.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ru/LC_MESSAGES/bison-runtime.mo installing sl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sl/LC_MESSAGES/bison-runtime.mo installing sq.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sq/LC_MESSAGES/bison-runtime.mo installing sr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sr/LC_MESSAGES/bison-runtime.mo installing sv.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sv/LC_MESSAGES/bison-runtime.mo installing ta.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ta/LC_MESSAGES/bison-runtime.mo installing th.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/th/LC_MESSAGES/bison-runtime.mo installing tr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/tr/LC_MESSAGES/bison-runtime.mo installing uk.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/uk/LC_MESSAGES/bison-runtime.mo installing vi.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/vi/LC_MESSAGES/bison-runtime.mo installing zh_CN.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/zh_CN/LC_MESSAGES/bison-runtime.mo installing zh_TW.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/zh_TW/LC_MESSAGES/bison-runtime.mo if test "bison" = "gettext-tools"; then \ /usr/bin/mkdir -p /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po; \ for file in Makefile.in.in remove-potcdate.sin quot.sed boldquot.sed en@quot.header en@boldquot.header insert-header.sin Rules-quot Makevars.template; do \ /usr/bin/install -c -m 644 ./$file \ /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po/$file; \ done; \ for file in Makevars; do \ rm -f /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po/$file; \ done; \ else \ : ; \ fi make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' Making install in gnulib-po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' installing af.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/af/LC_MESSAGES/bison-gnulib.mo installing be.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/be/LC_MESSAGES/bison-gnulib.mo installing bg.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/bg/LC_MESSAGES/bison-gnulib.mo installing ca.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ca/LC_MESSAGES/bison-gnulib.mo installing cs.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/cs/LC_MESSAGES/bison-gnulib.mo installing da.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/da/LC_MESSAGES/bison-gnulib.mo installing de.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/de/LC_MESSAGES/bison-gnulib.mo installing el.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/el/LC_MESSAGES/bison-gnulib.mo installing eo.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/eo/LC_MESSAGES/bison-gnulib.mo installing es.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/es/LC_MESSAGES/bison-gnulib.mo installing et.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/et/LC_MESSAGES/bison-gnulib.mo installing eu.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/eu/LC_MESSAGES/bison-gnulib.mo installing fi.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/fi/LC_MESSAGES/bison-gnulib.mo installing fr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/fr/LC_MESSAGES/bison-gnulib.mo installing ga.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ga/LC_MESSAGES/bison-gnulib.mo installing gl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/gl/LC_MESSAGES/bison-gnulib.mo installing hu.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/hu/LC_MESSAGES/bison-gnulib.mo installing it.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/it/LC_MESSAGES/bison-gnulib.mo installing ja.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ja/LC_MESSAGES/bison-gnulib.mo installing ko.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ko/LC_MESSAGES/bison-gnulib.mo installing ms.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ms/LC_MESSAGES/bison-gnulib.mo installing nb.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/nb/LC_MESSAGES/bison-gnulib.mo installing nl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/nl/LC_MESSAGES/bison-gnulib.mo installing pl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pl/LC_MESSAGES/bison-gnulib.mo installing pt.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pt/LC_MESSAGES/bison-gnulib.mo installing pt_BR.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pt_BR/LC_MESSAGES/bison-gnulib.mo installing ro.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ro/LC_MESSAGES/bison-gnulib.mo installing ru.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ru/LC_MESSAGES/bison-gnulib.mo installing rw.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/rw/LC_MESSAGES/bison-gnulib.mo installing sk.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sk/LC_MESSAGES/bison-gnulib.mo installing sl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sl/LC_MESSAGES/bison-gnulib.mo installing sr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sr/LC_MESSAGES/bison-gnulib.mo installing sv.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sv/LC_MESSAGES/bison-gnulib.mo installing tr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/tr/LC_MESSAGES/bison-gnulib.mo installing uk.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/uk/LC_MESSAGES/bison-gnulib.mo installing vi.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/vi/LC_MESSAGES/bison-gnulib.mo installing zh_CN.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/zh_CN/LC_MESSAGES/bison-gnulib.mo installing zh_TW.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/zh_TW/LC_MESSAGES/bison-gnulib.mo if test "bison" = "gettext-tools"; then \ /usr/bin/mkdir -p /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po; \ for file in Makefile.in.in remove-potcdate.sin quot.sed boldquot.sed en@quot.header en@boldquot.header insert-header.sin Rules-quot Makevars.template; do \ /usr/bin/install -c -m 644 ./$file \ /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po/$file; \ done; \ for file in Makevars; do \ rm -f /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po/$file; \ done; \ else \ : ; \ fi make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' Making install in . make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' /usr/bin/mkdir -p doc LC_ALL=C tests/bison --version >doc/bison.help.tmp LC_ALL=C tests/bison --help | \ sed -e 's,^Usage: .*/bison \[OPTION\],Usage: bison [OPTION],g' \ -e '/translation bugs/d' >>doc/bison.help.tmp ./build-aux/move-if-change doc/bison.help.tmp doc/bison.help make[4]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/lib/aarch64-linux-gnu' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin' /usr/bin/install -c -m 644 lib/liby.a '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/lib/aarch64-linux-gnu' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/aclocal' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++/calc++' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++' /usr/bin/install -c src/yacc '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin' /usr/bin/install -c -m 644 m4/bison-i18n.m4 '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/aclocal' /usr/bin/install -c src/bison '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin' ( cd '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/lib/aarch64-linux-gnu' && ranlib liby.a ) /usr/bin/install -c -m 644 examples/c++/calc++/driver.cc examples/c++/calc++/driver.hh examples/c++/calc++/scanner.ll examples/c++/calc++/calc++.cc examples/c++/calc++/parser.yy '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++/calc++' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/bistromathic' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/calc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d/calc' /usr/bin/install -c -m 644 examples/c/bistromathic/parse.y examples/c/bistromathic/Makefile examples/c/bistromathic/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/bistromathic' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++/calc++' /usr/bin/install -c -m 644 examples/c++/simple.yy '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++' /usr/bin/install -c -m 644 examples/c/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c' /usr/bin/install -c -m 644 examples/d/calc/calc.y examples/d/calc/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d/calc' /usr/bin/install -c -m 644 examples/c/calc/calc.y examples/c/calc/Makefile examples/c/calc/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/calc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d' /usr/bin/install -c -m 644 examples/c++/README.md examples/c++/Makefile examples/c++/variant.yy examples/c++/variant-11.yy '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples' /usr/bin/install -c -m 644 examples/c++/calc++/README.md examples/c++/calc++/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++/calc++' /usr/bin/install -c -m 644 examples/d/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/glr' /usr/bin/install -c -m 644 AUTHORS COPYING NEWS README THANKS TODO '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java' /usr/bin/install -c -m 644 examples/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java/calc' /usr/bin/install -c -m 644 examples/c/glr/c++-types.y examples/c/glr/Makefile examples/c/glr/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/glr' /usr/bin/install -c -m 644 examples/java/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java/simple' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/lexcalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/m4sugar' /usr/bin/install -c -m 644 examples/java/calc/Calc.y examples/java/calc/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java/calc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/mfcalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison' /usr/bin/install -c -m 644 examples/java/simple/Calc.y examples/java/simple/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java/simple' /usr/bin/install -c -m 644 examples/c/lexcalc/parse.y examples/c/lexcalc/scan.l examples/c/lexcalc/Makefile examples/c/lexcalc/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/lexcalc' /usr/bin/install -c -m 644 examples/c/mfcalc/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/mfcalc' /usr/bin/install -c -m 644 data/README.md data/bison-default.css '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/pushcalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/reccalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/rpcalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d/simple' /usr/bin/install -c -m 644 data/m4sugar/foreach.m4 data/m4sugar/m4sugar.m4 '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/m4sugar' /usr/bin/install -c -m 644 examples/c/pushcalc/calc.y examples/c/pushcalc/Makefile examples/c/pushcalc/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/pushcalc' /usr/bin/install -c -m 644 examples/c/reccalc/parse.y examples/c/reccalc/scan.l examples/c/reccalc/Makefile examples/c/reccalc/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/reccalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/skeletons' /usr/bin/mkdir -p doc /usr/bin/install -c -m 644 examples/c/rpcalc/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/rpcalc' /usr/bin/install -c -m 644 examples/d/simple/calc.y examples/d/simple/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d/simple' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/xslt' LC_ALL=C tests/bison --version >doc/bison.help.tmp /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/mfcalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/rpcalc' /usr/bin/install -c -m 644 data/xslt/bison.xsl data/xslt/xml2dot.xsl data/xslt/xml2text.xsl data/xslt/xml2xhtml.xsl '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/xslt' /usr/bin/install -c -m 644 data/skeletons/bison.m4 data/skeletons/c++-skel.m4 data/skeletons/c++.m4 data/skeletons/c-like.m4 data/skeletons/c-skel.m4 data/skeletons/c.m4 data/skeletons/glr.c data/skeletons/glr.cc data/skeletons/glr2.cc data/skeletons/java-skel.m4 data/skeletons/java.m4 data/skeletons/lalr1.cc data/skeletons/lalr1.java data/skeletons/location.cc data/skeletons/stack.hh data/skeletons/traceon.m4 data/skeletons/variant.hh data/skeletons/yacc.c data/skeletons/d-skel.m4 data/skeletons/d.m4 data/skeletons/lalr1.d '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/skeletons' /usr/bin/install -c -m 644 examples/c/mfcalc/calc.h examples/c/mfcalc/mfcalc.y '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/mfcalc' LC_ALL=C tests/bison --help | \ sed -e 's,^Usage: .*/bison \[OPTION\],Usage: bison [OPTION],g' \ -e '/translation bugs/d' >>doc/bison.help.tmp /usr/bin/install -c -m 644 examples/c/rpcalc/rpcalc.y '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/rpcalc' ./build-aux/move-if-change doc/bison.help.tmp doc/bison.help /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/man/man1' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/info' /usr/bin/install -c -m 644 ./doc/bison.1 doc/yacc.1 '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/man/man1' /usr/bin/install -c -m 644 ./doc/bison.info '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/info' make[4]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[2]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' debian/rules execute_after_dh_auto_install make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' rm -f -R /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/info/ mv /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin/yacc /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin/bison.yacc mv /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/man/man1/yacc.1 \ /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/man/man1/bison.yacc.1 make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' dh_install dh_installdocs dh_installchangelogs dh_installexamples dh_installman dh_lintian dh_perl dh_link dh_strip_nondeterminism Normalized debian/bison/usr/share/locale/uk/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/uk/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/tr/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/tr/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/tr/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/th/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ta/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/sv/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/sv/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/sv/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/it/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/it/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/id/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/id/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/ia/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/hu/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/hu/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/hr/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/hr/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/gl/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/eu/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/et/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/et/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/et/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/es/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/es/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/es/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/eo/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/eo/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/eo/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/ru/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/ro/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ro/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ro/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/pt_BR/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/pt_BR/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/pt_BR/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/pt/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/pt/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/pt/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/zh_TW/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/zh_TW/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/zh_TW/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/zh_CN/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/zh_CN/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/zh_CN/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/vi/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/vi/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/vi/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/uk/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ms/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ms/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/lv/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/lt/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ky/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ko/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ja/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ja/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ja/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/it/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/gl/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ga/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ga/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ga/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/fr/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/fr/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/fr/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/fi/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/fi/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/fi/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/ca/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ca/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ca/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/bg/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/bg/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/bg/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/be/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ast/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/af/LC_MESSAGES/bison-gnulib.mo Garbage at end of string in strptime: +02:00 at /usr/lib/aarch64-linux-gnu/perl/5.40/Time/Piece.pm line 598. Perhaps a format flag did not match the actual input? at /usr/lib/aarch64-linux-gnu/perl/5.40/Time/Piece.pm line 598. Normalized debian/bison/usr/share/locale/sr/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/sr/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/sr/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/sq/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/sl/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/sl/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/sk/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/rw/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ru/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ru/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/el/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/el/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/el/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/de/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/de/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/de/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/da/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/da/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/da/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/cs/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/pl/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/pl/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/pl/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/nl/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/nl/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/nl/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/nb/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/nb/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/nb/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/ms/LC_MESSAGES/bison-gnulib.mo dh_compress dh_fixperms dh_missing dh_dwz dh_strip dh_makeshlibs dh_shlibdeps dpkg-shlibdeps: warning: diversions involved - output may be incorrect diversion by libc6 from: /lib/ld-linux-aarch64.so.1 dpkg-shlibdeps: warning: diversions involved - output may be incorrect diversion by libc6 to: /lib/ld-linux-aarch64.so.1.usr-is-merged dh_installdeb dh_gencontrol dh_md5sums dh_builddeb dpkg-deb: building package 'bison' in '../bison_3.8.2+dfsg-1_arm64.deb'. dpkg-deb: building package 'bison-dbgsym' in '../bison-dbgsym_3.8.2+dfsg-1_arm64.deb'. dpkg-deb: building package 'libbison-dev' in '../libbison-dev_3.8.2+dfsg-1_arm64.deb'. dpkg-genbuildinfo --build=binary -O../bison_3.8.2+dfsg-1_arm64.buildinfo dpkg-genchanges --build=binary -O../bison_3.8.2+dfsg-1_arm64.changes dpkg-genchanges: info: binary-only upload (no source code included) dpkg-source --after-build . dpkg-buildpackage: info: binary-only upload (no source included) dpkg-genchanges: info: including full source code in upload I: copying local configuration I: unmounting dev/ptmx filesystem I: unmounting dev/pts filesystem I: unmounting dev/shm filesystem I: unmounting proc filesystem I: unmounting sys filesystem I: cleaning the build env I: removing directory /srv/workspace/pbuilder/1898584 and its subdirectories I: Current time: Fri Mar 27 06:46:44 -12 2026 I: pbuilder-time-stamp: 1774637204 Fri Mar 27 18:46:44 UTC 2026 I: Signing ./b1/bison_3.8.2+dfsg-1_arm64.buildinfo as bison_3.8.2+dfsg-1_arm64.buildinfo.asc Fri Mar 27 18:46:44 UTC 2026 I: Signed ./b1/bison_3.8.2+dfsg-1_arm64.buildinfo as ./b1/bison_3.8.2+dfsg-1_arm64.buildinfo.asc Fri Mar 27 18:46:44 UTC 2026 - build #1 for bison/trixie/arm64 on codethink03-arm64 done. Starting cleanup. All cleanup done. Fri Mar 27 18:46:44 UTC 2026 - reproducible_build.sh stopped running as /tmp/jenkins-script-AE6FSMc6, removing. /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe: total 16 drwxr-xr-x 2 jenkins jenkins 4096 Feb 22 12:23 b1 drwxr-xr-x 2 jenkins jenkins 4096 Feb 22 12:16 b2 -rw-r--r-- 1 jenkins jenkins 1855 Oct 3 2021 bison_3.8.2+dfsg-1.dsc -rw------- 1 jenkins jenkins 2975 Feb 22 12:16 rbuildlog.DsrGmeZ /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/b1: total 13024 -rw-r--r-- 1 jenkins jenkins 753140 Feb 22 12:23 bison-dbgsym_3.8.2+dfsg-1_arm64.deb -rw-r--r-- 1 jenkins jenkins 11164 Feb 22 12:23 bison_3.8.2+dfsg-1.debian.tar.xz -rw-r--r-- 1 jenkins jenkins 1855 Feb 22 12:23 bison_3.8.2+dfsg-1.dsc -rw-r--r-- 1 jenkins jenkins 5238 Feb 22 12:23 bison_3.8.2+dfsg-1_arm64.buildinfo -rw-r--r-- 1 jenkins jenkins 6120 Feb 22 12:23 bison_3.8.2+dfsg-1_arm64.buildinfo.asc -rw-r--r-- 1 jenkins jenkins 1667 Feb 22 12:23 bison_3.8.2+dfsg-1_arm64.changes -rw-r--r-- 1 jenkins jenkins 1150004 Feb 22 12:23 bison_3.8.2+dfsg-1_arm64.deb -rw-r--r-- 1 jenkins jenkins 1437 Feb 22 12:23 bison_3.8.2+dfsg-1_source.changes -rw-r--r-- 1 jenkins jenkins 2654920 Feb 22 12:23 bison_3.8.2+dfsg.orig.tar.xz -rw-r--r-- 1 jenkins jenkins 8054565 Feb 22 12:23 build.log -rw-r--r-- 1 jenkins jenkins 671932 Feb 22 12:23 libbison-dev_3.8.2+dfsg-1_arm64.deb /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/b2: total 0 Sat Feb 22 12:23:46 UTC 2025 I: Deleting $TMPDIR on codethink03-arm64.debian.net. I: pbuilder: network access will be disabled during build I: Current time: Fri Mar 27 06:39:53 -12 2026 I: pbuilder-time-stamp: 1774636793 I: Building the build Environment I: extracting base tarball [/var/cache/pbuilder/trixie-reproducible-base.tgz] I: copying local configuration W: --override-config is not set; not updating apt.conf Read the manpage for details. I: mounting /proc filesystem I: mounting /sys filesystem I: creating /{dev,run}/shm I: mounting /dev/pts filesystem I: redirecting /dev/ptmx to /dev/pts/ptmx I: policy-rc.d already exists I: Copying source file I: copying [bison_3.8.2+dfsg-1.dsc] I: copying [./bison_3.8.2+dfsg.orig.tar.xz] I: copying [./bison_3.8.2+dfsg-1.debian.tar.xz] I: Extracting source dpkg-source: warning: cannot verify inline signature for ./bison_3.8.2+dfsg-1.dsc: unsupported subcommand dpkg-source: info: extracting bison in bison-3.8.2+dfsg dpkg-source: info: unpacking bison_3.8.2+dfsg.orig.tar.xz dpkg-source: info: unpacking bison_3.8.2+dfsg-1.debian.tar.xz dpkg-source: info: using patch list from debian/patches/series dpkg-source: info: applying 01_keep_stamp_files dpkg-source: info: applying 02_parse_h_dependency I: using fakeroot in build. I: Installing the build-deps I: user script /srv/workspace/pbuilder/1898584/tmp/hooks/D02_print_environment starting I: set BUILDDIR='/build/reproducible-path' BUILDUSERGECOS='first user,first room,first work-phone,first home-phone,first other' BUILDUSERNAME='pbuilder1' BUILD_ARCH='arm64' DEBIAN_FRONTEND='noninteractive' DEB_BUILD_OPTIONS='buildinfo=+all reproducible=+all parallel=12 ' DISTRIBUTION='trixie' HOME='/root' HOST_ARCH='arm64' IFS=' ' INVOCATION_ID='d67e741296294416be8d489ee5f26057' LANG='C' LANGUAGE='en_US:en' LC_ALL='C' MAIL='/var/mail/root' OPTIND='1' PATH='/usr/sbin:/usr/bin:/sbin:/bin:/usr/games' PBCURRENTCOMMANDLINEOPERATION='build' PBUILDER_OPERATION='build' PBUILDER_PKGDATADIR='/usr/share/pbuilder' PBUILDER_PKGLIBDIR='/usr/lib/pbuilder' PBUILDER_SYSCONFDIR='/etc' PPID='1898584' PS1='# ' PS2='> ' PS4='+ ' PWD='/' SHELL='/bin/bash' SHLVL='2' SUDO_COMMAND='/usr/bin/timeout -k 18.1h 18h /usr/bin/ionice -c 3 /usr/bin/nice /usr/sbin/pbuilder --build --configfile /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/pbuilderrc_ucqW --distribution trixie --hookdir /etc/pbuilder/first-build-hooks --debbuildopts -b --basetgz /var/cache/pbuilder/trixie-reproducible-base.tgz --buildresult /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/b1 --logfile b1/build.log bison_3.8.2+dfsg-1.dsc' SUDO_GID='109' SUDO_UID='104' SUDO_USER='jenkins' TERM='unknown' TZ='/usr/share/zoneinfo/Etc/GMT+12' USER='root' _='/usr/bin/systemd-run' http_proxy='http://192.168.101.4:3128' I: uname -a Linux codethink03-arm64 6.1.0-31-cloud-arm64 #1 SMP Debian 6.1.128-1 (2025-02-07) aarch64 GNU/Linux I: ls -l /bin lrwxrwxrwx 1 root root 7 Nov 22 2024 /bin -> usr/bin I: user script /srv/workspace/pbuilder/1898584/tmp/hooks/D02_print_environment finished -> Attempting to satisfy build-dependencies -> Creating pbuilder-satisfydepends-dummy package Package: pbuilder-satisfydepends-dummy Version: 0.invalid.0 Architecture: arm64 Maintainer: Debian Pbuilder Team Description: Dummy package to satisfy dependencies with aptitude - created by pbuilder This package was created automatically by pbuilder to satisfy the build-dependencies of the package being currently built. Depends: debhelper-compat (= 12), gettext, flex, m4 (>= 1.4-14), help2man dpkg-deb: building package 'pbuilder-satisfydepends-dummy' in '/tmp/satisfydepends-aptitude/pbuilder-satisfydepends-dummy.deb'. Selecting previously unselected package pbuilder-satisfydepends-dummy. (Reading database ... 19922 files and directories currently installed.) Preparing to unpack .../pbuilder-satisfydepends-dummy.deb ... Unpacking pbuilder-satisfydepends-dummy (0.invalid.0) ... dpkg: pbuilder-satisfydepends-dummy: dependency problems, but configuring anyway as you requested: pbuilder-satisfydepends-dummy depends on debhelper-compat (= 12); however: Package debhelper-compat is not installed. pbuilder-satisfydepends-dummy depends on gettext; however: Package gettext is not installed. pbuilder-satisfydepends-dummy depends on flex; however: Package flex is not installed. pbuilder-satisfydepends-dummy depends on m4 (>= 1.4-14); however: Package m4 is not installed. pbuilder-satisfydepends-dummy depends on help2man; however: Package help2man is not installed. Setting up pbuilder-satisfydepends-dummy (0.invalid.0) ... Reading package lists... Building dependency tree... Reading state information... Initializing package states... Writing extended state information... Building tag database... pbuilder-satisfydepends-dummy is already installed at the requested version (0.invalid.0) pbuilder-satisfydepends-dummy is already installed at the requested version (0.invalid.0) The following NEW packages will be installed: autoconf{a} automake{a} autopoint{a} autotools-dev{a} bsdextrautils{a} debhelper{a} dh-autoreconf{a} dh-strip-nondeterminism{a} dwz{a} file{a} flex{a} gettext{a} gettext-base{a} groff-base{a} help2man{a} intltool-debian{a} libarchive-zip-perl{a} libdebhelper-perl{a} libelf1t64{a} libfile-stripnondeterminism-perl{a} libicu72{a} liblocale-gettext-perl{a} libmagic-mgc{a} libmagic1t64{a} libpipeline1{a} libtool{a} libuchardet0{a} libunistring5{a} libxml2{a} m4{a} man-db{a} po-debconf{a} sensible-utils{a} The following packages are RECOMMENDED but will NOT be installed: curl libarchive-cpio-perl libfl-dev libltdl-dev libmail-sendmail-perl lynx wget 0 packages upgraded, 33 newly installed, 0 to remove and 0 not upgraded. Need to get 20.7 MB of archives. After unpacking 82.3 MB will be used. Writing extended state information... Get: 1 http://deb.debian.org/debian trixie/main arm64 m4 arm64 1.4.19-5 [284 kB] Get: 2 http://deb.debian.org/debian trixie/main arm64 flex arm64 2.6.4-8.2+b4 [412 kB] Get: 3 http://deb.debian.org/debian trixie/main arm64 liblocale-gettext-perl arm64 1.07-7+b1 [15.2 kB] Get: 4 http://deb.debian.org/debian trixie/main arm64 sensible-utils all 0.0.24 [24.8 kB] Get: 5 http://deb.debian.org/debian trixie/main arm64 libmagic-mgc arm64 1:5.45-3+b1 [314 kB] Get: 6 http://deb.debian.org/debian trixie/main arm64 libmagic1t64 arm64 1:5.45-3+b1 [102 kB] Get: 7 http://deb.debian.org/debian trixie/main arm64 file arm64 1:5.45-3+b1 [43.4 kB] Get: 8 http://deb.debian.org/debian trixie/main arm64 gettext-base arm64 0.23.1-1 [241 kB] Get: 9 http://deb.debian.org/debian trixie/main arm64 libuchardet0 arm64 0.0.8-1+b2 [69.2 kB] Get: 10 http://deb.debian.org/debian trixie/main arm64 groff-base arm64 1.23.0-7 [1129 kB] Get: 11 http://deb.debian.org/debian trixie/main arm64 bsdextrautils arm64 2.40.4-3 [92.0 kB] Get: 12 http://deb.debian.org/debian trixie/main arm64 libpipeline1 arm64 1.5.8-1 [40.2 kB] Get: 13 http://deb.debian.org/debian trixie/main arm64 man-db arm64 2.13.0-1 [1404 kB] Get: 14 http://deb.debian.org/debian trixie/main arm64 autoconf all 2.72-3 [493 kB] Get: 15 http://deb.debian.org/debian trixie/main arm64 autotools-dev all 20220109.1 [51.6 kB] Get: 16 http://deb.debian.org/debian trixie/main arm64 automake all 1:1.17-3 [862 kB] Get: 17 http://deb.debian.org/debian trixie/main arm64 autopoint all 0.23.1-1 [770 kB] Get: 18 http://deb.debian.org/debian trixie/main arm64 libdebhelper-perl all 13.24.1 [90.9 kB] Get: 19 http://deb.debian.org/debian trixie/main arm64 libtool all 2.5.4-3 [539 kB] Get: 20 http://deb.debian.org/debian trixie/main arm64 dh-autoreconf all 20 [17.1 kB] Get: 21 http://deb.debian.org/debian trixie/main arm64 libarchive-zip-perl all 1.68-1 [104 kB] Get: 22 http://deb.debian.org/debian trixie/main arm64 libfile-stripnondeterminism-perl all 1.14.1-2 [19.7 kB] Get: 23 http://deb.debian.org/debian trixie/main arm64 dh-strip-nondeterminism all 1.14.1-2 [8620 B] Get: 24 http://deb.debian.org/debian trixie/main arm64 libelf1t64 arm64 0.192-4 [189 kB] Get: 25 http://deb.debian.org/debian trixie/main arm64 dwz arm64 0.15-1+b1 [102 kB] Get: 26 http://deb.debian.org/debian trixie/main arm64 libunistring5 arm64 1.3-1 [449 kB] Get: 27 http://deb.debian.org/debian trixie/main arm64 libicu72 arm64 72.1-6 [9239 kB] Get: 28 http://deb.debian.org/debian trixie/main arm64 libxml2 arm64 2.12.7+dfsg+really2.9.14-0.2+b1 [630 kB] Get: 29 http://deb.debian.org/debian trixie/main arm64 gettext arm64 0.23.1-1 [1610 kB] Get: 30 http://deb.debian.org/debian trixie/main arm64 intltool-debian all 0.35.0+20060710.6 [22.9 kB] Get: 31 http://deb.debian.org/debian trixie/main arm64 po-debconf all 1.0.21+nmu1 [248 kB] Get: 32 http://deb.debian.org/debian trixie/main arm64 debhelper all 13.24.1 [920 kB] Get: 33 http://deb.debian.org/debian trixie/main arm64 help2man arm64 1.49.3+b1 [198 kB] Fetched 20.7 MB in 0s (140 MB/s) Preconfiguring packages ... Selecting previously unselected package m4. (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 19922 files and directories currently installed.) Preparing to unpack .../00-m4_1.4.19-5_arm64.deb ... Unpacking m4 (1.4.19-5) ... Selecting previously unselected package flex. Preparing to unpack .../01-flex_2.6.4-8.2+b4_arm64.deb ... Unpacking flex (2.6.4-8.2+b4) ... Selecting previously unselected package liblocale-gettext-perl. Preparing to unpack .../02-liblocale-gettext-perl_1.07-7+b1_arm64.deb ... Unpacking liblocale-gettext-perl (1.07-7+b1) ... Selecting previously unselected package sensible-utils. Preparing to unpack .../03-sensible-utils_0.0.24_all.deb ... Unpacking sensible-utils (0.0.24) ... Selecting previously unselected package libmagic-mgc. Preparing to unpack .../04-libmagic-mgc_1%3a5.45-3+b1_arm64.deb ... Unpacking libmagic-mgc (1:5.45-3+b1) ... Selecting previously unselected package libmagic1t64:arm64. Preparing to unpack .../05-libmagic1t64_1%3a5.45-3+b1_arm64.deb ... Unpacking libmagic1t64:arm64 (1:5.45-3+b1) ... Selecting previously unselected package file. Preparing to unpack .../06-file_1%3a5.45-3+b1_arm64.deb ... Unpacking file (1:5.45-3+b1) ... Selecting previously unselected package gettext-base. Preparing to unpack .../07-gettext-base_0.23.1-1_arm64.deb ... Unpacking gettext-base (0.23.1-1) ... Selecting previously unselected package libuchardet0:arm64. Preparing to unpack .../08-libuchardet0_0.0.8-1+b2_arm64.deb ... Unpacking libuchardet0:arm64 (0.0.8-1+b2) ... Selecting previously unselected package groff-base. Preparing to unpack .../09-groff-base_1.23.0-7_arm64.deb ... Unpacking groff-base (1.23.0-7) ... Selecting previously unselected package bsdextrautils. Preparing to unpack .../10-bsdextrautils_2.40.4-3_arm64.deb ... Unpacking bsdextrautils (2.40.4-3) ... Selecting previously unselected package libpipeline1:arm64. Preparing to unpack .../11-libpipeline1_1.5.8-1_arm64.deb ... Unpacking libpipeline1:arm64 (1.5.8-1) ... Selecting previously unselected package man-db. Preparing to unpack .../12-man-db_2.13.0-1_arm64.deb ... Unpacking man-db (2.13.0-1) ... Selecting previously unselected package autoconf. Preparing to unpack .../13-autoconf_2.72-3_all.deb ... Unpacking autoconf (2.72-3) ... Selecting previously unselected package autotools-dev. Preparing to unpack .../14-autotools-dev_20220109.1_all.deb ... Unpacking autotools-dev (20220109.1) ... Selecting previously unselected package automake. Preparing to unpack .../15-automake_1%3a1.17-3_all.deb ... Unpacking automake (1:1.17-3) ... Selecting previously unselected package autopoint. Preparing to unpack .../16-autopoint_0.23.1-1_all.deb ... Unpacking autopoint (0.23.1-1) ... Selecting previously unselected package libdebhelper-perl. Preparing to unpack .../17-libdebhelper-perl_13.24.1_all.deb ... Unpacking libdebhelper-perl (13.24.1) ... Selecting previously unselected package libtool. Preparing to unpack .../18-libtool_2.5.4-3_all.deb ... Unpacking libtool (2.5.4-3) ... Selecting previously unselected package dh-autoreconf. Preparing to unpack .../19-dh-autoreconf_20_all.deb ... Unpacking dh-autoreconf (20) ... Selecting previously unselected package libarchive-zip-perl. Preparing to unpack .../20-libarchive-zip-perl_1.68-1_all.deb ... Unpacking libarchive-zip-perl (1.68-1) ... Selecting previously unselected package libfile-stripnondeterminism-perl. Preparing to unpack .../21-libfile-stripnondeterminism-perl_1.14.1-2_all.deb ... Unpacking libfile-stripnondeterminism-perl (1.14.1-2) ... Selecting previously unselected package dh-strip-nondeterminism. Preparing to unpack .../22-dh-strip-nondeterminism_1.14.1-2_all.deb ... Unpacking dh-strip-nondeterminism (1.14.1-2) ... Selecting previously unselected package libelf1t64:arm64. Preparing to unpack .../23-libelf1t64_0.192-4_arm64.deb ... Unpacking libelf1t64:arm64 (0.192-4) ... Selecting previously unselected package dwz. Preparing to unpack .../24-dwz_0.15-1+b1_arm64.deb ... Unpacking dwz (0.15-1+b1) ... Selecting previously unselected package libunistring5:arm64. Preparing to unpack .../25-libunistring5_1.3-1_arm64.deb ... Unpacking libunistring5:arm64 (1.3-1) ... Selecting previously unselected package libicu72:arm64. Preparing to unpack .../26-libicu72_72.1-6_arm64.deb ... Unpacking libicu72:arm64 (72.1-6) ... Selecting previously unselected package libxml2:arm64. Preparing to unpack .../27-libxml2_2.12.7+dfsg+really2.9.14-0.2+b1_arm64.deb ... Unpacking libxml2:arm64 (2.12.7+dfsg+really2.9.14-0.2+b1) ... Selecting previously unselected package gettext. Preparing to unpack .../28-gettext_0.23.1-1_arm64.deb ... Unpacking gettext (0.23.1-1) ... Selecting previously unselected package intltool-debian. Preparing to unpack .../29-intltool-debian_0.35.0+20060710.6_all.deb ... Unpacking intltool-debian (0.35.0+20060710.6) ... Selecting previously unselected package po-debconf. Preparing to unpack .../30-po-debconf_1.0.21+nmu1_all.deb ... Unpacking po-debconf (1.0.21+nmu1) ... Selecting previously unselected package debhelper. Preparing to unpack .../31-debhelper_13.24.1_all.deb ... Unpacking debhelper (13.24.1) ... Selecting previously unselected package help2man. Preparing to unpack .../32-help2man_1.49.3+b1_arm64.deb ... Unpacking help2man (1.49.3+b1) ... Setting up libpipeline1:arm64 (1.5.8-1) ... Setting up libicu72:arm64 (72.1-6) ... Setting up bsdextrautils (2.40.4-3) ... Setting up libmagic-mgc (1:5.45-3+b1) ... Setting up libarchive-zip-perl (1.68-1) ... Setting up libdebhelper-perl (13.24.1) ... Setting up libmagic1t64:arm64 (1:5.45-3+b1) ... Setting up gettext-base (0.23.1-1) ... Setting up m4 (1.4.19-5) ... Setting up file (1:5.45-3+b1) ... Setting up libelf1t64:arm64 (0.192-4) ... Setting up autotools-dev (20220109.1) ... Setting up libunistring5:arm64 (1.3-1) ... Setting up autopoint (0.23.1-1) ... Setting up autoconf (2.72-3) ... Setting up dwz (0.15-1+b1) ... Setting up sensible-utils (0.0.24) ... Setting up libuchardet0:arm64 (0.0.8-1+b2) ... Setting up libxml2:arm64 (2.12.7+dfsg+really2.9.14-0.2+b1) ... Setting up liblocale-gettext-perl (1.07-7+b1) ... Setting up automake (1:1.17-3) ... update-alternatives: using /usr/bin/automake-1.17 to provide /usr/bin/automake (automake) in auto mode Setting up libfile-stripnondeterminism-perl (1.14.1-2) ... Setting up flex (2.6.4-8.2+b4) ... Setting up gettext (0.23.1-1) ... Setting up libtool (2.5.4-3) ... Setting up intltool-debian (0.35.0+20060710.6) ... Setting up help2man (1.49.3+b1) ... Setting up dh-autoreconf (20) ... Setting up dh-strip-nondeterminism (1.14.1-2) ... Setting up groff-base (1.23.0-7) ... Setting up po-debconf (1.0.21+nmu1) ... Setting up man-db (2.13.0-1) ... Not building database; man-db/auto-update is not 'true'. Setting up debhelper (13.24.1) ... Processing triggers for libc-bin (2.40-7) ... Reading package lists... Building dependency tree... Reading state information... Reading extended state information... Initializing package states... Writing extended state information... Building tag database... -> Finished parsing the build-deps Reading package lists... Building dependency tree... Reading state information... fakeroot is already the newest version (1.37-1). 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. I: Building the package I: Running cd /build/reproducible-path/bison-3.8.2+dfsg/ && env PATH="/usr/sbin:/usr/bin:/sbin:/bin:/usr/games" HOME="/nonexistent/first-build" dpkg-buildpackage -us -uc -b && env PATH="/usr/sbin:/usr/bin:/sbin:/bin:/usr/games" HOME="/nonexistent/first-build" dpkg-genchanges -S > ../bison_3.8.2+dfsg-1_source.changes dpkg-buildpackage: info: source package bison dpkg-buildpackage: info: source version 2:3.8.2+dfsg-1 dpkg-buildpackage: info: source distribution unstable dpkg-buildpackage: info: source changed by Chuan-kai Lin dpkg-source --before-build . dpkg-buildpackage: info: host architecture arm64 debian/rules clean dh clean debian/rules override_dh_auto_clean make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' [ ! -f /build/reproducible-path/bison-3.8.2+dfsg/Makefile ] || dh_auto_clean make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' dh_clean debian/rules binary dh binary dh_update_autotools_config debian/rules execute_before_dh_autoreconf make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' echo '@setfilename bison.info' > /build/reproducible-path/bison-3.8.2+dfsg/doc/bison.texi make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' dh_autoreconf Copying file build-aux/config.rpath Copying file m4/extern-inline.m4 Copying file m4/glibc2.m4 Copying file m4/glibc21.m4 Copying file m4/intdiv0.m4 Copying file m4/intl.m4 Copying file m4/intldir.m4 Copying file m4/intmax.m4 Copying file m4/inttypes-pri.m4 Copying file m4/lcmessage.m4 Copying file m4/longlong.m4 Copying file m4/printf-posix.m4 Copying file m4/uintmax_t.m4 Copying file gnulib-po/Makevars.template Copying file runtime-po/Makevars.template Copying file po/Makevars.template Copying file gnulib-po/remove-potcdate.sin debian/rules override_dh_auto_configure make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' dh_auto_configure -- --disable-silent-rules ./configure --build=aarch64-linux-gnu --prefix=/usr --includedir=\${prefix}/include --mandir=\${prefix}/share/man --infodir=\${prefix}/share/info --sysconfdir=/etc --localstatedir=/var --disable-option-checking --disable-silent-rules --libdir=\${prefix}/lib/aarch64-linux-gnu --runstatedir=/run --disable-maintainer-mode --disable-dependency-tracking --disable-silent-rules checking for a BSD-compatible install... /usr/bin/install -c checking whether sleep supports fractional seconds... yes checking filesystem timestamp resolution... 0.01 checking whether build environment is sane... yes checking for a race-free mkdir -p... /usr/bin/mkdir -p checking for gawk... no checking for mawk... mawk checking whether make sets $(MAKE)... yes checking whether make supports nested variables... yes checking xargs -n works... yes checking for gcc... gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... checking whether we are cross compiling... no checking for suffix of object files... o checking whether the compiler supports GNU C... yes checking whether gcc accepts -g... yes checking for gcc option to enable C11 features... none needed checking whether gcc understands -c and -o together... yes checking whether the compiler is clang... no checking for compiler option needed when checking for declarations... none checking whether make supports the include directive... yes (GNU style) checking dependency style of gcc... none checking for g++... g++ checking whether the compiler supports GNU C++... yes checking whether g++ accepts -g... yes checking for g++ option to enable C++11 features... none needed checking dependency style of g++... none checking for stdio.h... yes checking for stdlib.h... yes checking for string.h... yes checking for inttypes.h... yes checking for stdint.h... yes checking for strings.h... yes checking for sys/stat.h... yes checking for sys/types.h... yes checking for unistd.h... yes checking for wchar.h... yes checking for minix/config.h... no checking for locale.h... yes checking for sys/param.h... yes checking for sys/socket.h... yes checking for stdio_ext.h... yes checking for features.h... yes checking for getopt.h... yes checking for sys/cdefs.h... yes checking for sys/time.h... yes checking for iconv.h... yes checking for limits.h... yes checking for crtdefs.h... no checking for wctype.h... yes checking for threads.h... yes checking for math.h... yes checking for sys/mman.h... yes checking for spawn.h... yes checking for sys/ioctl.h... yes checking for sys/resource.h... yes checking for sys/times.h... yes checking for sys/wait.h... yes checking for termios.h... yes checking for dirent.h... yes checking for xlocale.h... no checking whether it is safe to define __EXTENSIONS__... yes checking whether _XOPEN_SOURCE should be defined... no checking build system type... aarch64-unknown-linux-gnu checking host system type... aarch64-unknown-linux-gnu checking how to run the C preprocessor... gcc -E checking for egrep -e... /usr/bin/grep -E checking for Minix Amsterdam compiler... no checking for ar... ar checking for ranlib... ranlib checking for special C compiler options needed for large files... no checking for _FILE_OFFSET_BITS value needed for large files... no checking for ld used by gcc... /usr/bin/ld checking if the linker (/usr/bin/ld) is GNU ld... yes checking for shared library run path origin... done checking 32-bit host C ABI... no checking for ELF binary format... yes checking for the common suffixes of directories in the library search path... lib,lib,lib checking for libtextstyle... no checking for inline... inline checking for tcdrain... yes checking for canonicalize_file_name... yes checking for faccessat... yes checking for realpath... yes checking for lstat... yes checking for readlinkat... yes checking for _set_invalid_parameter_handler... no checking for fchdir... yes checking for fcntl... yes checking for symlink... yes checking for ffsl... yes checking for vasnprintf... no checking for snprintf... yes checking for fsync... yes checking for microuptime... no checking for nanouptime... no checking for getprogname... no checking for getexecname... no checking for getrusage... yes checking for gettimeofday... yes checking for iswcntrl... yes checking for iswblank... yes checking for mbsinit... yes checking for mbrtowc... yes checking for isascii... yes checking for mprotect... yes checking for obstack_printf... yes checking for strerror_r... yes checking for __xpg_strerror_r... yes checking for pipe... yes checking for pipe2... yes checking for posix_spawn_file_actions_addchdir_np... yes checking for posix_spawn_file_actions_addchdir... no checking for readlink... yes checking for setenv... yes checking for link... yes checking for sigaction... yes checking for sigaltstack... yes checking for siginterrupt... yes checking for stpncpy... yes checking for strndup... yes checking for wcwidth... yes checking for fdopendir... yes checking for mempcpy... yes checking for __fseterr... no checking for fstatat... yes checking for getdelim... yes checking for getdtablesize... yes checking for openat... yes checking for catgets... yes checking for setlocale... yes checking whether pragma GCC diagnostic push works... yes checking whether C++ compiler handles -Werror -Wunknown-warning-option... no checking whether C++ compiler handles -fno-exceptions... yes checking whether C++ compiler accepts -std=c++98... yes checking whether C++ compiler accepts -std=c++03... yes checking whether C++ compiler accepts -std=c++11... yes checking whether C++ compiler accepts -std=c++14... yes checking whether C++ compiler accepts -std=c++17... yes checking whether C++ compiler accepts -std=c++20... yes checking whether C++ compiler accepts -std=c++2b... yes checking whether gcc supports POSIXLY_CORRECT=1... yes checking whether g++ builds executables that work... yes checking whether g++ supports POSIXLY_CORRECT=1... yes checking for dmd... no checking for -g... no checking for Java compiler... no checking for Java virtual machine... no checking for flex... flex checking whether lex is flex... yes checking whether flex supports --header=FILE... yes checking lex output file root... lex.yy checking lex library... none needed checking whether yytext is a pointer... no checking for bison... no checking for byacc... no checking for ranlib... (cached) ranlib checking for GNU M4 that supports accurate traces... /usr/bin/m4 checking whether /usr/bin/m4 accepts --gnu... yes checking how m4 supports trace files... --debugfile checking for perl... /usr/bin/perl checking for xsltproc... no checking for inline... (cached) inline checking for size_t... yes checking for working alloca.h... yes checking for alloca... yes checking whether malloc is ptrdiff_t safe... yes checking whether malloc, realloc, calloc set errno on failure... yes checking whether lstat correctly handles trailing slash... yes checking whether // is distinct from /... no checking whether realpath works... yes checking for getcwd... yes checking for C/C++ restrict keyword... __restrict__ checking if environ is properly declared... yes checking whether the preprocessor supports include_next... yes checking whether source code line length is unlimited... yes checking for complete errno.h... yes checking for gcc options needed to detect all undeclared functions... none needed checking whether strerror_r is declared... yes checking whether strerror_r returns char *... yes checking for mode_t... yes checking for sig_atomic_t... yes checking for working fcntl.h... yes checking for pid_t... yes checking for eaccess... yes checking for stdint.h... yes checking for inttypes.h... yes checking whether printf supports size specifiers as in C99... yes checking whether printf supports 'long double' arguments... yes checking whether printf supports infinite 'double' arguments... yes checking whether byte ordering is bigendian... no checking whether long double and double are the same... no checking whether printf supports infinite 'long double' arguments... yes checking whether printf supports the 'a' and 'A' directives... yes checking whether printf supports the 'F' directive... yes checking whether printf supports the 'n' directive... no checking whether printf supports the 'ls' directive... yes checking whether printf supports POSIX/XSI format strings with positions... yes checking whether printf supports the grouping flag... yes checking whether printf supports the left-adjust flag correctly... yes checking whether printf supports the zero flag correctly... yes checking whether printf supports large precisions... yes checking whether the compiler produces multi-arch binaries... no checking whether printf survives out-of-memory conditions... yes checking for wchar_t... yes checking for wint_t... yes checking whether wint_t is large enough... yes checking for intmax_t... yes checking where to find the exponent in a 'double'... word 1 bit 20 checking whether snprintf returns a byte count as in C99... yes checking whether snprintf truncates the result as in C99... yes checking for snprintf... (cached) yes checking for strnlen... yes checking for wcslen... yes checking for wcsnlen... yes checking for mbrtowc... (cached) yes checking for wcrtomb... yes checking whether _snprintf is declared... no checking whether frexp() can be used without linking with libm... yes checking whether alarm is declared... yes checking whether getcwd (NULL, 0) allocates memory for result... yes checking for getcwd with POSIX signature... yes checking whether getcwd is declared... yes checking for d_ino member in directory struct... yes checking for arithmetic hrtime_t... no checking for getopt.h... (cached) yes checking for getopt_long_only... yes checking whether getopt is POSIX compatible... yes checking for working GNU getopt function... yes checking for working GNU getopt_long function... yes checking for struct timeval... yes checking for wide-enough struct timeval.tv_sec member... yes checking for iconv... yes checking for working iconv... yes checking whether iconv is compatible with its POSIX signature... yes checking whether limits.h has WORD_BIT, BOOL_WIDTH etc.... yes checking whether stdint.h conforms to C99... yes checking whether stdint.h works without ISO C predefines... yes checking whether stdint.h has UINTMAX_WIDTH etc.... yes checking whether INT32_MAX < INTMAX_MAX... yes checking whether INT64_MAX == LONG_MAX... yes checking whether UINT32_MAX < UINTMAX_MAX... yes checking whether UINT64_MAX == ULONG_MAX... yes checking where to find the exponent in a 'float'... word 0 bit 23 checking whether isnan(float) can be used without linking with libm... yes checking whether isnan(float) works... yes checking whether isnan(double) can be used without linking with libm... yes checking whether isnan(long double) can be used without linking with libm... yes checking whether isnanl works... yes checking whether iswcntrl works... yes checking for towlower... yes checking for wctype_t... yes checking for wctrans_t... yes checking for nl_langinfo and CODESET... yes checking for a traditional french locale... fr_FR checking for a traditional japanese locale... ja_JP.EUC-JP checking for a french Unicode locale... fr_FR.UTF-8 checking for a transitional chinese locale... zh_CN.GB18030 checking whether ldexp() can be used without linking with libm... yes checking whether imported symbols can be declared weak... yes checking for pthread.h... yes checking for pthread_kill in -lpthread... yes checking whether POSIX threads API is available... yes checking for multithread API to use... posix checking for a sed that does not truncate output... /usr/bin/sed checking for grep that handles long lines and -e... /usr/bin/grep checking whether NAN macro works... yes checking whether HUGE_VAL works... yes checking for mbstate_t... yes checking for mmap... yes checking for MAP_ANONYMOUS... yes checking whether memchr works... yes checking whether defines MIN and MAX... no checking whether defines MIN and MAX... yes checking whether obstack_printf is declared... yes checking for O_CLOEXEC... yes checking for promoted mode_t type... mode_t checking whether strerror(0) succeeds... yes checking for strerror_r with POSIX signature... no checking whether __xpg_strerror_r works... yes checking for library containing posix_spawn... none required checking for posix_spawn... yes checking whether posix_spawn is declared... yes checking whether posix_spawn works... yes checking whether posix_spawn rejects scripts without shebang... yes checking whether posix_spawnp rejects scripts without shebang... yes checking whether posix_spawnattr_setschedpolicy is supported... yes checking whether posix_spawnattr_setschedparam is supported... yes checking for ptrdiff_t... yes checking for egrep... /usr/bin/grep -E checking whether C symbols are prefixed with underscore at the linker level... no checking for sigset_t... yes checking for shared library path variable... LD_LIBRARY_PATH checking whether to activate relocatable installation... no checking whether malloc (0) returns nonnull... yes checking whether setenv is declared... yes checking for sched.h... yes checking for struct sched_param... yes checking for uid_t... yes checking for gid_t... yes checking for volatile sig_atomic_t... yes checking for sighandler_t... yes checking whether snprintf is declared... yes checking for posix_spawnattr_t... yes checking for posix_spawn_file_actions_t... yes checking whether stat file-mode macros are broken... no checking for nlink_t... yes checking for stdbool.h that conforms to C99... yes checking for _Bool... yes checking for good max_align_t... yes checking whether NULL can be used in arbitrary expressions... yes checking whether fcloseall is declared... yes checking which flavor of printf attribute matches inttypes macros... system checking whether ecvt is declared... yes checking whether fcvt is declared... yes checking whether gcvt is declared... yes checking whether stpncpy is declared... yes checking whether strdup is declared... yes checking whether strndup is declared... yes checking whether declares ioctl... yes checking for struct tms... yes checking for struct timespec in ... yes checking for TIME_UTC in ... yes checking whether execvpe is declared... yes checking whether clearerr_unlocked is declared... yes checking whether feof_unlocked is declared... yes checking whether ferror_unlocked is declared... yes checking whether fflush_unlocked is declared... yes checking whether fgets_unlocked is declared... yes checking whether fputc_unlocked is declared... yes checking whether fputs_unlocked is declared... yes checking whether fread_unlocked is declared... yes checking whether fwrite_unlocked is declared... yes checking whether getc_unlocked is declared... yes checking whether getchar_unlocked is declared... yes checking whether putc_unlocked is declared... yes checking whether putchar_unlocked is declared... yes checking whether unsetenv is declared... yes checking whether vsnprintf is declared... yes checking whether uses 'inline' correctly... yes checking whether wcsdup is declared... yes checking POSIX termios... yes checking whether use of TIOCGWINSZ requires termios.h... no checking whether fchdir is declared... yes checking whether getdelim is declared... yes checking whether getdtablesize is declared... yes checking whether getline is declared... yes checking whether setlocale (LC_ALL, NULL) is multithread-safe... yes checking whether setlocale (category, NULL) is multithread-safe... yes checking whether locale.h defines locale_t... yes checking whether locale.h conforms to POSIX:2001... yes checking whether struct lconv is properly defined... yes checking whether memrchr is declared... yes checking whether strnlen is declared... yes checking for alloca as a compiler built-in... yes checking whether to enable assertions... yes checking for __builtin_expect... yes checking whether calloc (0, n) and calloc (n, 0) return nonnull... yes checking for library containing clock_gettime... none required checking for clock_gettime... yes checking for clock_settime... yes checking whether // is distinct from /... (cached) no checking whether dup2 works... yes checking for error_at_line... yes checking whether fcntl handles F_DUPFD correctly... yes checking whether fcntl understands F_DUPFD_CLOEXEC... needs runtime check checking whether conversion from 'int' to 'long double' works... yes checking whether fopen recognizes a trailing slash... yes checking whether fopen supports the mode character 'x'... yes checking whether fopen supports the mode character 'e'... yes checking for __fpending... yes checking whether __fpending is declared... yes checking for ptrdiff_t... (cached) yes checking whether free is known to preserve errno... yes checking whether frexp works... yes checking whether frexpl is declared... yes checking whether frexpl() can be used without linking with libm... yes checking whether frexpl works... yes checking whether getcwd handles long file names properly... yes checking for getpagesize... yes checking whether getcwd succeeds when 4k < cwd_length < 16k... yes checking whether gethrtime is declared... no checking whether CLOCK_MONOTONIC or CLOCK_REALTIME is defined... yes checking whether program_invocation_name is declared... yes checking whether program_invocation_short_name is declared... yes checking whether __argv is declared... no checking for gettimeofday with POSIX signature... yes checking whether the compiler generally respects inline... yes checking whether isnan macro works... yes checking whether isnan(double) can be used without linking with libm... (cached) yes checking whether isnan(double) can be used without linking with libm... (cached) yes checking whether isnan(float) can be used without linking with libm... (cached) yes checking whether isnan(float) works... (cached) yes checking whether isnan(long double) can be used without linking with libm... (cached) yes checking whether isnanl works... (cached) yes checking whether isnan(long double) can be used without linking with libm... (cached) yes checking whether isnanl works... (cached) yes checking whether iswblank is declared... yes checking whether iswdigit is ISO C compliant... yes checking whether iswxdigit is ISO C compliant... yes checking whether ldexpl is declared... yes checking whether ldexpl() can be used without linking with libm... yes checking whether ldexpl works... yes checking whether the compiler supports the __inline keyword... yes checking for pthread_rwlock_t... yes checking whether pthread_rwlock_rdlock prefers a writer to a reader... no checking whether malloc (0) returns nonnull... (cached) yes checking whether mbrtowc handles incomplete characters... yes checking whether mbrtowc works as well as mbtowc... yes checking whether mbrtowc handles a NULL pwc argument... yes checking whether mbrtowc handles a NULL string argument... yes checking whether mbrtowc has a correct return value... yes checking whether mbrtowc returns 0 when parsing a NUL character... yes checking whether mbrtowc stores incomplete characters... no checking whether mbrtowc works on empty input... yes checking whether the C locale is free of encoding errors... no checking whether mbrtowc handles incomplete characters... (cached) yes checking whether mbrtowc works as well as mbtowc... (cached) yes checking whether mbswidth is declared in ... no checking for mbstate_t... (cached) yes checking for mempcpy... (cached) yes checking for obstacks that work with any size object... no checking whether open recognizes a trailing slash... yes checking whether perror matches strerror... yes checking whether posix_spawn_file_actions_addclose works... yes checking whether posix_spawn_file_actions_adddup2 works... yes checking whether posix_spawn_file_actions_addopen works... yes checking whether frexp works... (cached) yes checking whether ldexp can be used without linking with libm... (cached) yes checking whether frexpl() can be used without linking with libm... (cached) yes checking whether frexpl works... (cached) yes checking whether frexpl is declared... (cached) yes checking whether ldexpl() can be used without linking with libm... (cached) yes checking whether ldexpl works... (cached) yes checking whether ldexpl is declared... (cached) yes checking whether program_invocation_name is declared... (cached) yes checking whether program_invocation_short_name is declared... (cached) yes checking for raise... yes checking for sigprocmask... yes checking for rawmemchr... yes checking for readline... no checking for readline/readline.h... no checking for readline/history.h... no checking whether readlink signature is correct... yes checking whether readlink handles trailing slash correctly... yes checking whether readlink truncates results correctly... yes checking whether realloc (0, 0) returns nonnull... yes checking for reallocarray... yes checking for getcwd... (cached) yes checking whether free is known to preserve errno... (cached) yes checking for mempcpy... (cached) yes checking for rawmemchr... (cached) yes checking for search.h... yes checking for tsearch... yes checking whether rename honors trailing slash on destination... yes checking whether rename honors trailing slash on source... yes checking whether rename manages hard links correctly... yes checking whether rename manages existing destinations correctly... yes checking for struct sigaction.sa_sigaction... yes checking for signbit macro... yes checking for signbit compiler built-ins... yes checking for sigprocmask... (cached) yes checking for stdint.h... (cached) yes checking for SIZE_MAX... yes checking for snprintf... (cached) yes checking whether snprintf respects a size of 1... yes checking whether printf supports POSIX/XSI format strings with positions... (cached) yes checking for snprintf... (cached) yes checking whether snprintf fully supports the 'n' directive... no checking whether snprintf respects a size of 1... (cached) yes checking whether vsnprintf respects a zero size as in C99... yes checking for ptrdiff_t... (cached) yes checking for ptrdiff_t... (cached) yes checking for ssize_t... yes checking whether stat handles trailing slashes on files... yes checking for working stdalign.h... yes checking for stpcpy... yes checking for working stpncpy... yes checking for working strerror function... yes checking for working strndup... yes checking whether strtod obeys C99... yes checking for strverscmp... yes checking for sys/single_threaded.h... yes checking whether unlink honors trailing slashes... yes checking whether unlink of a parent directory fails as it should... guessing yes checking for unsetenv... yes checking for unsetenv() return type... int checking whether unsetenv obeys POSIX... yes checking for ptrdiff_t... (cached) yes checking for vasprintf... yes checking for vasprintf... (cached) yes checking for ptrdiff_t... (cached) yes checking for vsnprintf... yes checking whether snprintf respects a size of 1... (cached) yes checking whether printf supports POSIX/XSI format strings with positions... (cached) yes checking for vsnprintf... (cached) yes checking whether snprintf fully supports the 'n' directive... (cached) no checking whether snprintf respects a size of 1... (cached) yes checking whether vsnprintf respects a zero size as in C99... (cached) yes checking for ptrdiff_t... (cached) yes checking for ptrdiff_t... (cached) yes checking for waitid... yes checking whether wcwidth is declared... yes checking whether wcwidth works reasonably in UTF-8 locales... yes checking whether use of TIOCGWINSZ requires sys/ioctl.h... yes checking whether use of TIOCGWINSZ requires termios.h... (cached) no checking whether use of struct winsize requires sys/ptem.h... no checking for stdint.h... (cached) yes checking whether getdtablesize works... yes checking whether setlocale (LC_ALL, NULL) is multithread-safe... (cached) yes checking whether setlocale (category, NULL) is multithread-safe... (cached) yes checking for ptrdiff_t... (cached) yes checking for getline... yes checking for working getline function... yes checking whether NLS is requested... yes checking for msgfmt... /usr/bin/msgfmt checking for gmsgfmt... /usr/bin/msgfmt checking for xgettext... /usr/bin/xgettext checking for msgmerge... /usr/bin/msgmerge checking for CFPreferencesCopyAppValue... no checking for CFLocaleCopyCurrent... no checking for GNU gettext in libc... yes checking whether to use NLS... yes checking where the gettext function comes from... libc checking for valgrind... no checking Valgrind suppression file... checking that generated files are newer than configure... done configure: creating ./config.status config.status: creating src/yacc config.status: creating javacomp.sh config.status: creating javaexec.sh config.status: creating gnulib-po/Makefile.in config.status: creating runtime-po/Makefile.in config.status: creating etc/bench.pl config.status: creating tests/atlocal config.status: creating tests/bison config.status: creating Makefile config.status: creating po/Makefile.in config.status: creating doc/yacc.1 config.status: creating lib/config.h config.status: executing depfiles commands config.status: executing po-directories commands config.status: creating gnulib-po/POTFILES config.status: creating gnulib-po/Makefile config.status: creating runtime-po/POTFILES config.status: creating runtime-po/Makefile config.status: creating po/POTFILES config.status: creating po/Makefile config.status: executing tests/atconfig commands make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' debian/rules execute_before_dh_auto_build make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' # Touch all files in the dependency tree of bison.info to # inhibit makeinfo invocation in the build process. install -d /build/reproducible-path/bison-3.8.2+dfsg/doc/figs touch --date="Jan 01 2000" \ /build/reproducible-path/bison-3.8.2+dfsg/doc/bison.info \ /build/reproducible-path/bison-3.8.2+dfsg/doc/bison.help \ /build/reproducible-path/bison-3.8.2+dfsg/doc/figs/example.txt \ /build/reproducible-path/bison-3.8.2+dfsg/doc/figs/example-reduce.txt \ /build/reproducible-path/bison-3.8.2+dfsg/doc/figs/example-shift.txt \ /build/reproducible-path/bison-3.8.2+dfsg/doc/*.texi \ /build/reproducible-path/bison-3.8.2+dfsg/build-aux/cross-options.pl \ /build/reproducible-path/bison-3.8.2+dfsg/src/getargs.c make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' dh_auto_build make -j12 make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' rm -f examples/c/reccalc/scan.stamp examples/c/reccalc/scan.stamp.tmp rm -f lib/alloca.h-t lib/alloca.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''HAVE_ALLOCA_H''@|1|g' < ./lib/alloca.in.h; \ } > lib/alloca.h-t && \ mv -f lib/alloca.h-t lib/alloca.h /usr/bin/mkdir -p examples/c/reccalc rm -f lib/configmake.h-t && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ echo '#if HAVE_WINSOCK2_H'; \ echo '# include /* avoid mingw pollution on DATADIR */'; \ echo '#endif'; \ echo '#define PREFIX "/usr"'; \ echo '#define EXEC_PREFIX "/usr"'; \ echo '#define BINDIR "/usr/bin"'; \ echo '#define SBINDIR "/usr/sbin"'; \ echo '#define LIBEXECDIR "/usr/libexec"'; \ echo '#define DATAROOTDIR "/usr/share"'; \ echo '#define DATADIR "/usr/share"'; \ echo '#define SYSCONFDIR "/etc"'; \ echo '#define SHAREDSTATEDIR "/usr/com"'; \ echo '#define LOCALSTATEDIR "/var"'; \ echo '#define RUNSTATEDIR "/run"'; \ echo '#define INCLUDEDIR "/usr/include"'; \ echo '#define OLDINCLUDEDIR "/usr/include"'; \ echo '#define DOCDIR "/usr/share/doc/bison"'; \ echo '#define INFODIR "/usr/share/info"'; \ echo '#define HTMLDIR "/usr/share/doc/bison"'; \ echo '#define DVIDIR "/usr/share/doc/bison"'; \ echo '#define PDFDIR "/usr/share/doc/bison"'; \ echo '#define PSDIR "/usr/share/doc/bison"'; \ echo '#define LIBDIR "/usr/lib/aarch64-linux-gnu"'; \ echo '#define LISPDIR "/usr/share/emacs/site-lisp"'; \ echo '#define LOCALEDIR "/usr/share/locale"'; \ echo '#define MANDIR "/usr/share/man"'; \ echo '#define MANEXT ""'; \ echo '#define PKGDATADIR "/usr/share/bison"'; \ echo '#define PKGINCLUDEDIR "/usr/include/bison"'; \ echo '#define PKGLIBDIR "/usr/lib/aarch64-linux-gnu/bison"'; \ echo '#define PKGLIBEXECDIR "/usr/libexec/bison"'; \ } | sed '/""/d' > lib/configmake.h-t && \ mv -f lib/configmake.h-t lib/configmake.h touch examples/c/reccalc/scan.stamp.tmp flex -oexamples/c/reccalc/scan.c --header=examples/c/reccalc/scan.h ./examples/c/reccalc/scan.l rm -f lib/fcntl.h-t lib/fcntl.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_FCNTL_H''@||g' \ -e 's/@''GNULIB_CREAT''@/0/g' \ -e 's/@''GNULIB_FCNTL''@/1/g' \ -e 's/@''GNULIB_NONBLOCKING''@/0/g' \ -e 's/@''GNULIB_OPEN''@/1/g' \ -e 's/@''GNULIB_OPENAT''@/0/g' \ -e 's/@''GNULIB_MDA_CREAT''@/1/g' \ -e 's/@''GNULIB_MDA_OPEN''@/1/g' \ -e 's|@''HAVE_FCNTL''@|1|g' \ -e 's|@''HAVE_OPENAT''@|1|g' \ -e 's|@''REPLACE_CREAT''@|0|g' \ -e 's|@''REPLACE_FCNTL''@|1|g' \ -e 's|@''REPLACE_OPEN''@|0|g' \ -e 's|@''REPLACE_OPENAT''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/fcntl.in.h; \ } > lib/fcntl.h-t && \ mv lib/fcntl.h-t lib/fcntl.h rm -f lib/iconv.h-t lib/iconv.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_ICONV_H''@||g' \ -e 's/@''GNULIB_ICONV''@/1/g' \ -e 's|@''ICONV_CONST''@||g' \ -e 's|@''REPLACE_ICONV''@|0|g' \ -e 's|@''REPLACE_ICONV_OPEN''@|0|g' \ -e 's|@''REPLACE_ICONV_UTF''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/iconv.in.h; \ } > lib/iconv.h-t && \ mv lib/iconv.h-t lib/iconv.h rm -f lib/inttypes.h-t lib/inttypes.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's/@''HAVE_INTTYPES_H''@/1/g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_INTTYPES_H''@||g' \ -e 's/@''APPLE_UNIVERSAL_BUILD''@/0/g' \ -e 's/@''PRIPTR_PREFIX''@/"l"/g' \ -e 's/@''GNULIB_IMAXABS''@/0/g' \ -e 's/@''GNULIB_IMAXDIV''@/0/g' \ -e 's/@''GNULIB_STRTOIMAX''@/0/g' \ -e 's/@''GNULIB_STRTOUMAX''@/0/g' \ -e 's/@''HAVE_DECL_IMAXABS''@/1/g' \ -e 's/@''HAVE_DECL_IMAXDIV''@/1/g' \ -e 's/@''HAVE_DECL_STRTOIMAX''@/1/g' \ -e 's/@''HAVE_DECL_STRTOUMAX''@/1/g' \ -e 's/@''HAVE_IMAXDIV_T''@/1/g' \ -e 's/@''REPLACE_STRTOIMAX''@/0/g' \ -e 's/@''REPLACE_STRTOUMAX''@/0/g' \ -e 's/@''INT32_MAX_LT_INTMAX_MAX''@/1/g' \ -e 's/@''INT64_MAX_EQ_LONG_MAX''@/1/g' \ -e 's/@''UINT32_MAX_LT_UINTMAX_MAX''@/1/g' \ -e 's/@''UINT64_MAX_EQ_ULONG_MAX''@/1/g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/inttypes.in.h; \ } > lib/inttypes.h-t && \ mv lib/inttypes.h-t lib/inttypes.h mv examples/c/reccalc/scan.stamp.tmp examples/c/reccalc/scan.stamp rm -f lib/textstyle.h-t lib/textstyle.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ cat ./lib/textstyle.in.h; \ } > lib/textstyle.h-t && \ mv lib/textstyle.h-t lib/textstyle.h rm -f lib/limits.h-t lib/limits.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_LIMITS_H''@||g' \ < ./lib/limits.in.h; \ } > lib/limits.h-t && \ mv lib/limits.h-t lib/limits.h rm -f lib/locale.h-t lib/locale.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_LOCALE_H''@||g' \ -e 's/@''GNULIB_LOCALECONV''@/0/g' \ -e 's/@''GNULIB_SETLOCALE''@/0/g' \ -e 's/@''GNULIB_SETLOCALE_NULL''@/1/g' \ -e 's/@''GNULIB_DUPLOCALE''@/0/g' \ -e 's/@''GNULIB_LOCALENAME''@/0/g' \ -e 's|@''HAVE_NEWLOCALE''@|1|g' \ -e 's|@''HAVE_DUPLOCALE''@|1|g' \ -e 's|@''HAVE_FREELOCALE''@|1|g' \ -e 's|@''HAVE_XLOCALE_H''@|0|g' \ -e 's|@''REPLACE_LOCALECONV''@|0|g' \ -e 's|@''REPLACE_SETLOCALE''@|0|g' \ -e 's|@''REPLACE_NEWLOCALE''@|0|g' \ -e 's|@''REPLACE_DUPLOCALE''@|0|g' \ -e 's|@''REPLACE_FREELOCALE''@|0|g' \ -e 's|@''REPLACE_STRUCT_LCONV''@|0|g' \ -e 's|@''LOCALENAME_ENHANCE_LOCALE_FUNCS''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/locale.in.h; \ } > lib/locale.h-t && \ mv lib/locale.h-t lib/locale.h rm -f lib/math.h-t lib/math.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT_AS_FIRST_DIRECTIVE''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_AS_FIRST_DIRECTIVE_MATH_H''@||g' \ -e 's/@''GNULIB_ACOSF''@/0/g' \ -e 's/@''GNULIB_ACOSL''@/0/g' \ -e 's/@''GNULIB_ASINF''@/0/g' \ -e 's/@''GNULIB_ASINL''@/0/g' \ -e 's/@''GNULIB_ATANF''@/0/g' \ -e 's/@''GNULIB_ATANL''@/0/g' \ -e 's/@''GNULIB_ATAN2F''@/0/g' \ -e 's/@''GNULIB_CBRT''@/0/g' \ -e 's/@''GNULIB_CBRTF''@/0/g' \ -e 's/@''GNULIB_CBRTL''@/0/g' \ -e 's/@''GNULIB_CEIL''@/0/g' \ -e 's/@''GNULIB_CEILF''@/0/g' \ -e 's/@''GNULIB_CEILL''@/0/g' \ -e 's/@''GNULIB_COPYSIGN''@/0/g' \ -e 's/@''GNULIB_COPYSIGNF''@/0/g' \ -e 's/@''GNULIB_COPYSIGNL''@/0/g' \ -e 's/@''GNULIB_COSF''@/0/g' \ -e 's/@''GNULIB_COSL''@/0/g' \ -e 's/@''GNULIB_COSHF''@/0/g' \ -e 's/@''GNULIB_EXPF''@/0/g' \ -e 's/@''GNULIB_EXPL''@/0/g' \ -e 's/@''GNULIB_EXP2''@/0/g' \ -e 's/@''GNULIB_EXP2F''@/0/g' \ -e 's/@''GNULIB_EXP2L''@/0/g' \ -e 's/@''GNULIB_EXPM1''@/0/g' \ -e 's/@''GNULIB_EXPM1F''@/0/g' \ -e 's/@''GNULIB_EXPM1L''@/0/g' \ -e 's/@''GNULIB_FABSF''@/0/g' \ -e 's/@''GNULIB_FABSL''@/0/g' \ -e 's/@''GNULIB_FLOOR''@/0/g' \ -e 's/@''GNULIB_FLOORF''@/0/g' \ -e 's/@''GNULIB_FLOORL''@/0/g' \ -e 's/@''GNULIB_FMA''@/0/g' \ -e 's/@''GNULIB_FMAF''@/0/g' \ -e 's/@''GNULIB_FMAL''@/0/g' \ -e 's/@''GNULIB_FMOD''@/0/g' \ -e 's/@''GNULIB_FMODF''@/0/g' \ -e 's/@''GNULIB_FMODL''@/0/g' \ -e 's/@''GNULIB_FREXPF''@/0/g' \ -e 's/@''GNULIB_FREXP''@/1/g' \ -e 's/@''GNULIB_FREXPL''@/1/g' \ -e 's/@''GNULIB_HYPOT''@/0/g' \ -e 's/@''GNULIB_HYPOTF''@/0/g' \ -e 's/@''GNULIB_HYPOTL''@/0/g' \ < ./lib/math.in.h | \ sed -e 's/@''GNULIB_ILOGB''@/0/g' \ -e 's/@''GNULIB_ILOGBF''@/0/g' \ -e 's/@''GNULIB_ILOGBL''@/0/g' \ -e 's/@''GNULIB_ISFINITE''@/0/g' \ -e 's/@''GNULIB_ISINF''@/0/g' \ -e 's/@''GNULIB_ISNAN''@/1/g' \ -e 's/@''GNULIB_ISNANF''@/1/g' \ -e 's/@''GNULIB_ISNAND''@/1/g' \ -e 's/@''GNULIB_ISNANL''@/1/g' \ -e 's/@''GNULIB_LDEXPF''@/0/g' \ -e 's/@''GNULIB_LDEXPL''@/1/g' \ -e 's/@''GNULIB_LOG''@/0/g' \ -e 's/@''GNULIB_LOGF''@/0/g' \ -e 's/@''GNULIB_LOGL''@/0/g' \ -e 's/@''GNULIB_LOG10''@/0/g' \ -e 's/@''GNULIB_LOG10F''@/0/g' \ -e 's/@''GNULIB_LOG10L''@/0/g' \ -e 's/@''GNULIB_LOG1P''@/0/g' \ -e 's/@''GNULIB_LOG1PF''@/0/g' \ -e 's/@''GNULIB_LOG1PL''@/0/g' \ -e 's/@''GNULIB_LOG2''@/0/g' \ -e 's/@''GNULIB_LOG2F''@/0/g' \ -e 's/@''GNULIB_LOG2L''@/0/g' \ -e 's/@''GNULIB_LOGB''@/0/g' \ -e 's/@''GNULIB_LOGBF''@/0/g' \ -e 's/@''GNULIB_LOGBL''@/0/g' \ -e 's/@''GNULIB_MODF''@/0/g' \ -e 's/@''GNULIB_MODFF''@/0/g' \ -e 's/@''GNULIB_MODFL''@/0/g' \ -e 's/@''GNULIB_POWF''@/0/g' \ -e 's/@''GNULIB_REMAINDER''@/0/g' \ -e 's/@''GNULIB_REMAINDERF''@/0/g' \ -e 's/@''GNULIB_REMAINDERL''@/0/g' \ -e 's/@''GNULIB_RINT''@/0/g' \ -e 's/@''GNULIB_RINTF''@/0/g' \ -e 's/@''GNULIB_RINTL''@/0/g' \ -e 's/@''GNULIB_ROUND''@/0/g' \ -e 's/@''GNULIB_ROUNDF''@/0/g' \ -e 's/@''GNULIB_ROUNDL''@/0/g' \ -e 's/@''GNULIB_SIGNBIT''@/1/g' \ -e 's/@''GNULIB_SINF''@/0/g' \ -e 's/@''GNULIB_SINL''@/0/g' \ -e 's/@''GNULIB_SINHF''@/0/g' \ -e 's/@''GNULIB_SQRTF''@/0/g' \ -e 's/@''GNULIB_SQRTL''@/0/g' \ -e 's/@''GNULIB_TANF''@/0/g' \ -e 's/@''GNULIB_TANL''@/0/g' \ -e 's/@''GNULIB_TANHF''@/0/g' \ -e 's/@''GNULIB_TRUNC''@/0/g' \ -e 's/@''GNULIB_TRUNCF''@/0/g' \ -e 's/@''GNULIB_TRUNCL''@/0/g' \ -e 's/@''GNULIB_MDA_J0''@/1/g' \ -e 's/@''GNULIB_MDA_J1''@/1/g' \ -e 's/@''GNULIB_MDA_JN''@/1/g' \ -e 's/@''GNULIB_MDA_Y0''@/1/g' \ -e 's/@''GNULIB_MDA_Y1''@/1/g' \ -e 's/@''GNULIB_MDA_YN''@/1/g' \ | \ sed -e 's|@''HAVE_ACOSF''@|1|g' \ -e 's|@''HAVE_ACOSL''@|1|g' \ -e 's|@''HAVE_ASINF''@|1|g' \ -e 's|@''HAVE_ASINL''@|1|g' \ -e 's|@''HAVE_ATANF''@|1|g' \ -e 's|@''HAVE_ATANL''@|1|g' \ -e 's|@''HAVE_ATAN2F''@|1|g' \ -e 's|@''HAVE_CBRT''@|1|g' \ -e 's|@''HAVE_CBRTF''@|1|g' \ -e 's|@''HAVE_CBRTL''@|1|g' \ -e 's|@''HAVE_COPYSIGN''@|1|g' \ -e 's|@''HAVE_COPYSIGNL''@|1|g' \ -e 's|@''HAVE_COSF''@|1|g' \ -e 's|@''HAVE_COSL''@|1|g' \ -e 's|@''HAVE_COSHF''@|1|g' \ -e 's|@''HAVE_EXPF''@|1|g' \ -e 's|@''HAVE_EXPL''@|1|g' \ -e 's|@''HAVE_EXPM1''@|1|g' \ -e 's|@''HAVE_EXPM1F''@|1|g' \ -e 's|@''HAVE_FABSF''@|1|g' \ -e 's|@''HAVE_FABSL''@|1|g' \ -e 's|@''HAVE_FMA''@|1|g' \ -e 's|@''HAVE_FMAF''@|1|g' \ -e 's|@''HAVE_FMAL''@|1|g' \ -e 's|@''HAVE_FMODF''@|1|g' \ -e 's|@''HAVE_FMODL''@|1|g' \ -e 's|@''HAVE_FREXPF''@|1|g' \ -e 's|@''HAVE_HYPOTF''@|1|g' \ -e 's|@''HAVE_HYPOTL''@|1|g' \ -e 's|@''HAVE_ILOGB''@|1|g' \ -e 's|@''HAVE_ILOGBF''@|1|g' \ -e 's|@''HAVE_ILOGBL''@|1|g' \ -e 's|@''HAVE_ISNANF''@|1|g' \ -e 's|@''HAVE_ISNAND''@|1|g' \ -e 's|@''HAVE_ISNANL''@|1|g' \ -e 's|@''HAVE_LDEXPF''@|1|g' \ -e 's|@''HAVE_LOGF''@|1|g' \ -e 's|@''HAVE_LOGL''@|1|g' \ -e 's|@''HAVE_LOG10F''@|1|g' \ -e 's|@''HAVE_LOG10L''@|1|g' \ -e 's|@''HAVE_LOG1P''@|1|g' \ -e 's|@''HAVE_LOG1PF''@|1|g' \ -e 's|@''HAVE_LOG1PL''@|1|g' \ -e 's|@''HAVE_LOGBF''@|1|g' \ -e 's|@''HAVE_LOGBL''@|1|g' \ -e 's|@''HAVE_MODFF''@|1|g' \ -e 's|@''HAVE_MODFL''@|1|g' \ -e 's|@''HAVE_POWF''@|1|g' \ -e 's|@''HAVE_REMAINDER''@|1|g' \ -e 's|@''HAVE_REMAINDERF''@|1|g' \ -e 's|@''HAVE_RINT''@|1|g' \ -e 's|@''HAVE_RINTL''@|1|g' \ -e 's|@''HAVE_SINF''@|1|g' \ -e 's|@''HAVE_SINL''@|1|g' \ -e 's|@''HAVE_SINHF''@|1|g' \ -e 's|@''HAVE_SQRTF''@|1|g' \ -e 's|@''HAVE_SQRTL''@|1|g' \ -e 's|@''HAVE_TANF''@|1|g' \ -e 's|@''HAVE_TANL''@|1|g' \ -e 's|@''HAVE_TANHF''@|1|g' \ -e 's|@''HAVE_DECL_ACOSL''@|1|g' \ -e 's|@''HAVE_DECL_ASINL''@|1|g' \ -e 's|@''HAVE_DECL_ATANL''@|1|g' \ -e 's|@''HAVE_DECL_CBRTF''@|1|g' \ -e 's|@''HAVE_DECL_CBRTL''@|1|g' \ -e 's|@''HAVE_DECL_CEILF''@|1|g' \ -e 's|@''HAVE_DECL_CEILL''@|1|g' \ -e 's|@''HAVE_DECL_COPYSIGNF''@|1|g' \ -e 's|@''HAVE_DECL_COSL''@|1|g' \ -e 's|@''HAVE_DECL_EXPL''@|1|g' \ -e 's|@''HAVE_DECL_EXP2''@|1|g' \ -e 's|@''HAVE_DECL_EXP2F''@|1|g' \ -e 's|@''HAVE_DECL_EXP2L''@|1|g' \ -e 's|@''HAVE_DECL_EXPM1L''@|1|g' \ -e 's|@''HAVE_DECL_FLOORF''@|1|g' \ -e 's|@''HAVE_DECL_FLOORL''@|1|g' \ -e 's|@''HAVE_DECL_FREXPL''@|1|g' \ -e 's|@''HAVE_DECL_LDEXPL''@|1|g' \ -e 's|@''HAVE_DECL_LOGL''@|1|g' \ -e 's|@''HAVE_DECL_LOG10L''@|1|g' \ -e 's|@''HAVE_DECL_LOG2''@|1|g' \ -e 's|@''HAVE_DECL_LOG2F''@|1|g' \ -e 's|@''HAVE_DECL_LOG2L''@|1|g' \ -e 's|@''HAVE_DECL_LOGB''@|1|g' \ -e 's|@''HAVE_DECL_REMAINDER''@|1|g' \ -e 's|@''HAVE_DECL_REMAINDERL''@|1|g' \ -e 's|@''HAVE_DECL_RINTF''@|1|g' \ -e 's|@''HAVE_DECL_ROUND''@|1|g' \ -e 's|@''HAVE_DECL_ROUNDF''@|1|g' \ -e 's|@''HAVE_DECL_ROUNDL''@|1|g' \ -e 's|@''HAVE_DECL_SINL''@|1|g' \ -e 's|@''HAVE_DECL_SQRTL''@|1|g' \ -e 's|@''HAVE_DECL_TANL''@|1|g' \ -e 's|@''HAVE_DECL_TRUNC''@|1|g' \ -e 's|@''HAVE_DECL_TRUNCF''@|1|g' \ -e 's|@''HAVE_DECL_TRUNCL''@|1|g' \ | \ sed -e 's|@''REPLACE_ACOSF''@|0|g' \ -e 's|@''REPLACE_ASINF''@|0|g' \ -e 's|@''REPLACE_ATANF''@|0|g' \ -e 's|@''REPLACE_ATAN2F''@|0|g' \ -e 's|@''REPLACE_CBRTF''@|0|g' \ -e 's|@''REPLACE_CBRTL''@|0|g' \ -e 's|@''REPLACE_CEIL''@|0|g' \ -e 's|@''REPLACE_CEILF''@|0|g' \ -e 's|@''REPLACE_CEILL''@|0|g' \ -e 's|@''REPLACE_COSF''@|0|g' \ -e 's|@''REPLACE_COSHF''@|0|g' \ -e 's|@''REPLACE_EXPF''@|0|g' \ -e 's|@''REPLACE_EXPL''@|0|g' \ -e 's|@''REPLACE_EXPM1''@|0|g' \ -e 's|@''REPLACE_EXPM1F''@|0|g' \ -e 's|@''REPLACE_EXPM1L''@|0|g' \ -e 's|@''REPLACE_EXP2''@|0|g' \ -e 's|@''REPLACE_EXP2L''@|0|g' \ -e 's|@''REPLACE_FABSL''@|0|g' \ -e 's|@''REPLACE_FLOOR''@|0|g' \ -e 's|@''REPLACE_FLOORF''@|0|g' \ -e 's|@''REPLACE_FLOORL''@|0|g' \ -e 's|@''REPLACE_FMA''@|0|g' \ -e 's|@''REPLACE_FMAF''@|0|g' \ -e 's|@''REPLACE_FMAL''@|0|g' \ -e 's|@''REPLACE_FMOD''@|0|g' \ -e 's|@''REPLACE_FMODF''@|0|g' \ -e 's|@''REPLACE_FMODL''@|0|g' \ -e 's|@''REPLACE_FREXPF''@|0|g' \ -e 's|@''REPLACE_FREXP''@|0|g' \ -e 's|@''REPLACE_FREXPL''@|0|g' \ -e 's|@''REPLACE_HUGE_VAL''@|0|g' \ -e 's|@''REPLACE_HYPOT''@|0|g' \ -e 's|@''REPLACE_HYPOTF''@|0|g' \ -e 's|@''REPLACE_HYPOTL''@|0|g' \ -e 's|@''REPLACE_ILOGB''@|0|g' \ -e 's|@''REPLACE_ILOGBF''@|0|g' \ -e 's|@''REPLACE_ILOGBL''@|0|g' \ -e 's|@''REPLACE_ISFINITE''@|0|g' \ -e 's|@''REPLACE_ISINF''@|0|g' \ -e 's|@''REPLACE_ISNAN''@|0|g' \ -e 's|@''REPLACE_ITOLD''@|0|g' \ -e 's|@''REPLACE_LDEXPL''@|0|g' \ -e 's|@''REPLACE_LOG''@|0|g' \ -e 's|@''REPLACE_LOGF''@|0|g' \ -e 's|@''REPLACE_LOGL''@|0|g' \ -e 's|@''REPLACE_LOG10''@|0|g' \ -e 's|@''REPLACE_LOG10F''@|0|g' \ -e 's|@''REPLACE_LOG10L''@|0|g' \ -e 's|@''REPLACE_LOG1P''@|0|g' \ -e 's|@''REPLACE_LOG1PF''@|0|g' \ -e 's|@''REPLACE_LOG1PL''@|0|g' \ -e 's|@''REPLACE_LOG2''@|0|g' \ -e 's|@''REPLACE_LOG2F''@|0|g' \ -e 's|@''REPLACE_LOG2L''@|0|g' \ -e 's|@''REPLACE_LOGB''@|0|g' \ -e 's|@''REPLACE_LOGBF''@|0|g' \ -e 's|@''REPLACE_LOGBL''@|0|g' \ -e 's|@''REPLACE_MODF''@|0|g' \ -e 's|@''REPLACE_MODFF''@|0|g' \ -e 's|@''REPLACE_MODFL''@|0|g' \ -e 's|@''REPLACE_NAN''@|0|g' \ -e 's|@''REPLACE_REMAINDER''@|0|g' \ -e 's|@''REPLACE_REMAINDERF''@|0|g' \ -e 's|@''REPLACE_REMAINDERL''@|0|g' \ -e 's|@''REPLACE_RINTL''@|0|g' \ -e 's|@''REPLACE_ROUND''@|0|g' \ -e 's|@''REPLACE_ROUNDF''@|0|g' \ -e 's|@''REPLACE_ROUNDL''@|0|g' \ -e 's|@''REPLACE_SIGNBIT''@|0|g' \ -e 's|@''REPLACE_SIGNBIT_USING_BUILTINS''@|1|g' \ -e 's|@''REPLACE_SINF''@|0|g' \ -e 's|@''REPLACE_SINHF''@|0|g' \ -e 's|@''REPLACE_SQRTF''@|0|g' \ -e 's|@''REPLACE_SQRTL''@|0|g' \ -e 's|@''REPLACE_TANF''@|0|g' \ -e 's|@''REPLACE_TANHF''@|0|g' \ -e 's|@''REPLACE_TRUNC''@|0|g' \ -e 's|@''REPLACE_TRUNCF''@|0|g' \ -e 's|@''REPLACE_TRUNCL''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h'; \ } > lib/math.h-t && \ mv lib/math.h-t lib/math.h rm -f lib/sched.h-t lib/sched.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''HAVE_SCHED_H''@|1|g' \ -e 's|@''HAVE_SYS_CDEFS_H''@|1|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SCHED_H''@||g' \ -e 's|@''HAVE_STRUCT_SCHED_PARAM''@|1|g' \ -e 's/@''GNULIB_SCHED_YIELD''@/0/g' \ -e 's|@''HAVE_SCHED_YIELD''@|1|g' \ -e 's|@''REPLACE_SCHED_YIELD''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/sched.in.h; \ } > lib/sched.h-t && \ mv lib/sched.h-t lib/sched.h /usr/bin/mkdir -p lib/malloc rm -f lib/signal.h-t lib/signal.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SIGNAL_H''@||g' \ -e 's/@''GNULIB_PTHREAD_SIGMASK''@/0/g' \ -e 's/@''GNULIB_RAISE''@/1/g' \ -e 's/@''GNULIB_SIGNAL_H_SIGPIPE''@/0/g' \ -e 's/@''GNULIB_SIGPROCMASK''@/1/g' \ -e 's/@''GNULIB_SIGACTION''@/1/g' \ -e 's|@''HAVE_POSIX_SIGNALBLOCKING''@|1|g' \ -e 's|@''HAVE_PTHREAD_SIGMASK''@|1|g' \ -e 's|@''HAVE_RAISE''@|1|g' \ -e 's|@''HAVE_SIGSET_T''@|1|g' \ -e 's|@''HAVE_SIGINFO_T''@|1|g' \ -e 's|@''HAVE_SIGACTION''@|1|g' \ -e 's|@''HAVE_STRUCT_SIGACTION_SA_SIGACTION''@|1|g' \ -e 's|@''HAVE_TYPE_VOLATILE_SIG_ATOMIC_T''@|1|g' \ -e 's|@''HAVE_SIGHANDLER_T''@|1|g' \ -e 's|@''REPLACE_PTHREAD_SIGMASK''@|0|g' \ -e 's|@''REPLACE_RAISE''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/signal.in.h; \ } > lib/signal.h-t && \ mv lib/signal.h-t lib/signal.h rm -f lib/malloc/scratch_buffer.gl.h-t lib/malloc/scratch_buffer.gl.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|__always_inline|inline _GL_ATTRIBUTE_ALWAYS_INLINE|g' \ -e 's|__glibc_likely|_GL_LIKELY|g' \ -e 's|__glibc_unlikely|_GL_UNLIKELY|g' \ -e '/libc_hidden_proto/d' \ < ./lib/malloc/scratch_buffer.h; \ } > lib/malloc/scratch_buffer.gl.h-t && \ mv lib/malloc/scratch_buffer.gl.h-t lib/malloc/scratch_buffer.gl.h rm -f lib/spawn.h-t lib/spawn.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''HAVE_SPAWN_H''@|1|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SPAWN_H''@||g' \ -e 's/@''GNULIB_POSIX_SPAWN''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWNP''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWN_FILE_ACTIONS_INIT''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWN_FILE_ACTIONS_DESTROY''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_INIT''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_GETFLAGS''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_SETFLAGS''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_GETPGROUP''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_SETPGROUP''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_GETSCHEDPARAM''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_SETSCHEDPARAM''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_GETSCHEDPOLICY''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_SETSCHEDPOLICY''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_GETSIGDEFAULT''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_SETSIGDEFAULT''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_GETSIGMASK''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_SETSIGMASK''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_DESTROY''@/1/g' \ -e 's|@''HAVE_POSIX_SPAWN''@|1|g' \ -e 's|@''HAVE_POSIX_SPAWNATTR_T''@|1|g' \ -e 's|@''HAVE_POSIX_SPAWN_FILE_ACTIONS_T''@|1|g' \ -e 's|@''HAVE_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR''@|0|g' \ -e 's|@''HAVE_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR''@|1|g' \ -e 's|@''REPLACE_POSIX_SPAWN''@|0|g' \ -e 's|@''REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR''@|0|g' \ -e 's|@''REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE''@|0|g' \ -e 's|@''REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2''@|0|g' \ -e 's|@''REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR''@|0|g' \ -e 's|@''REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/spawn.in.h; \ } > lib/spawn.h-t && \ mv lib/spawn.h-t lib/spawn.h rm -f lib/stdio.h-t lib/stdio.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_STDIO_H''@||g' \ -e 's/@''GNULIB_DPRINTF''@/0/g' \ -e 's/@''GNULIB_FCLOSE''@/0/g' \ -e 's/@''GNULIB_FDOPEN''@/0/g' \ -e 's/@''GNULIB_FFLUSH''@/0/g' \ -e 's/@''GNULIB_FGETC''@/1/g' \ -e 's/@''GNULIB_FGETS''@/1/g' \ -e 's/@''GNULIB_FOPEN''@/1/g' \ -e 's/@''GNULIB_FPRINTF''@/1/g' \ -e 's/@''GNULIB_FPRINTF_POSIX''@/1/g' \ -e 's/@''GNULIB_FPURGE''@/0/g' \ -e 's/@''GNULIB_FPUTC''@/1/g' \ -e 's/@''GNULIB_FPUTS''@/1/g' \ -e 's/@''GNULIB_FREAD''@/1/g' \ -e 's/@''GNULIB_FREOPEN''@/0/g' \ -e 's/@''GNULIB_FSCANF''@/1/g' \ -e 's/@''GNULIB_FSEEK''@/0/g' \ -e 's/@''GNULIB_FSEEKO''@/0/g' \ -e 's/@''GNULIB_FTELL''@/0/g' \ -e 's/@''GNULIB_FTELLO''@/0/g' \ -e 's/@''GNULIB_FWRITE''@/1/g' \ -e 's/@''GNULIB_GETC''@/1/g' \ -e 's/@''GNULIB_GETCHAR''@/1/g' \ -e 's/@''GNULIB_GETDELIM''@/0/g' \ -e 's/@''GNULIB_GETLINE''@/1/g' \ -e 's/@''GNULIB_OBSTACK_PRINTF''@/1/g' \ -e 's/@''GNULIB_OBSTACK_PRINTF_POSIX''@/0/g' \ -e 's/@''GNULIB_PCLOSE''@/0/g' \ -e 's/@''GNULIB_PERROR''@/1/g' \ -e 's/@''GNULIB_POPEN''@/0/g' \ -e 's/@''GNULIB_PRINTF''@/1/g' \ -e 's/@''GNULIB_PRINTF_POSIX''@/1/g' \ -e 's/@''GNULIB_PUTC''@/1/g' \ -e 's/@''GNULIB_PUTCHAR''@/1/g' \ -e 's/@''GNULIB_PUTS''@/1/g' \ -e 's/@''GNULIB_REMOVE''@/0/g' \ -e 's/@''GNULIB_RENAME''@/1/g' \ -e 's/@''GNULIB_RENAMEAT''@/0/g' \ -e 's/@''GNULIB_SCANF''@/1/g' \ -e 's/@''GNULIB_SNPRINTF''@/1/g' \ -e 's/@''GNULIB_SPRINTF_POSIX''@/1/g' \ -e 's/@''GNULIB_STDIO_H_NONBLOCKING''@/0/g' \ -e 's/@''GNULIB_STDIO_H_SIGPIPE''@/0/g' \ -e 's/@''GNULIB_TMPFILE''@/0/g' \ -e 's/@''GNULIB_VASPRINTF''@/1/g' \ -e 's/@''GNULIB_VDPRINTF''@/0/g' \ -e 's/@''GNULIB_VFPRINTF''@/1/g' \ -e 's/@''GNULIB_VFPRINTF_POSIX''@/1/g' \ -e 's/@''GNULIB_VFSCANF''@/0/g' \ -e 's/@''GNULIB_VSCANF''@/0/g' \ -e 's/@''GNULIB_VPRINTF''@/1/g' \ -e 's/@''GNULIB_VPRINTF_POSIX''@/0/g' \ -e 's/@''GNULIB_VSNPRINTF''@/1/g' \ -e 's/@''GNULIB_VSPRINTF_POSIX''@/1/g' \ -e 's/@''GNULIB_MDA_FCLOSEALL''@/1/g' \ -e 's/@''GNULIB_MDA_FDOPEN''@/1/g' \ -e 's/@''GNULIB_MDA_FILENO''@/1/g' \ -e 's/@''GNULIB_MDA_GETW''@/1/g' \ -e 's/@''GNULIB_MDA_PUTW''@/1/g' \ -e 's/@''GNULIB_MDA_TEMPNAM''@/1/g' \ < ./lib/stdio.in.h | \ sed -e 's|@''HAVE_DECL_FCLOSEALL''@|1|g' \ -e 's|@''HAVE_DECL_FPURGE''@|1|g' \ -e 's|@''HAVE_DECL_FSEEKO''@|1|g' \ -e 's|@''HAVE_DECL_FTELLO''@|1|g' \ -e 's|@''HAVE_DECL_GETDELIM''@|1|g' \ -e 's|@''HAVE_DECL_GETLINE''@|1|g' \ -e 's|@''HAVE_DECL_OBSTACK_PRINTF''@|1|g' \ -e 's|@''HAVE_DECL_SNPRINTF''@|1|g' \ -e 's|@''HAVE_DECL_VSNPRINTF''@|1|g' \ -e 's|@''HAVE_DPRINTF''@|1|g' \ -e 's|@''HAVE_FSEEKO''@|1|g' \ -e 's|@''HAVE_FTELLO''@|1|g' \ -e 's|@''HAVE_PCLOSE''@|1|g' \ -e 's|@''HAVE_POPEN''@|1|g' \ -e 's|@''HAVE_RENAMEAT''@|1|g' \ -e 's|@''HAVE_VASPRINTF''@|1|g' \ -e 's|@''HAVE_VDPRINTF''@|1|g' \ -e 's|@''REPLACE_DPRINTF''@|0|g' \ -e 's|@''REPLACE_FCLOSE''@|0|g' \ -e 's|@''REPLACE_FDOPEN''@|0|g' \ -e 's|@''REPLACE_FFLUSH''@|0|g' \ -e 's|@''REPLACE_FOPEN''@|0|g' \ -e 's|@''REPLACE_FPRINTF''@|1|g' \ -e 's|@''REPLACE_FPURGE''@|0|g' \ -e 's|@''REPLACE_FREOPEN''@|0|g' \ -e 's|@''REPLACE_FSEEK''@|0|g' \ -e 's|@''REPLACE_FSEEKO''@|0|g' \ -e 's|@''REPLACE_FTELL''@|0|g' \ -e 's|@''REPLACE_FTELLO''@|0|g' \ -e 's|@''REPLACE_GETDELIM''@|0|g' \ -e 's|@''REPLACE_GETLINE''@|0|g' \ -e 's|@''REPLACE_OBSTACK_PRINTF''@|0|g' \ -e 's|@''REPLACE_PERROR''@|0|g' \ -e 's|@''REPLACE_POPEN''@|0|g' \ -e 's|@''REPLACE_PRINTF''@|1|g' \ -e 's|@''REPLACE_REMOVE''@|0|g' \ -e 's|@''REPLACE_RENAME''@|0|g' \ -e 's|@''REPLACE_RENAMEAT''@|0|g' \ -e 's|@''REPLACE_SNPRINTF''@|1|g' \ -e 's|@''REPLACE_SPRINTF''@|1|g' \ -e 's|@''REPLACE_STDIO_READ_FUNCS''@|0|g' \ -e 's|@''REPLACE_STDIO_WRITE_FUNCS''@|0|g' \ -e 's|@''REPLACE_TMPFILE''@|0|g' \ -e 's|@''REPLACE_VASPRINTF''@|1|g' \ -e 's|@''REPLACE_VDPRINTF''@|0|g' \ -e 's|@''REPLACE_VFPRINTF''@|1|g' \ -e 's|@''REPLACE_VPRINTF''@|0|g' \ -e 's|@''REPLACE_VSNPRINTF''@|1|g' \ -e 's|@''REPLACE_VSPRINTF''@|1|g' \ -e 's|@''ASM_SYMBOL_PREFIX''@|""|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h'; \ } > lib/stdio.h-t && \ mv lib/stdio.h-t lib/stdio.h rm -f lib/stdlib.h-t lib/stdlib.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_STDLIB_H''@||g' \ -e 's/@''GNULIB__EXIT''@/0/g' \ -e 's/@''GNULIB_ALIGNED_ALLOC''@/0/g' \ -e 's/@''GNULIB_ATOLL''@/0/g' \ -e 's/@''GNULIB_CALLOC_POSIX''@/1/g' \ -e 's/@''GNULIB_CANONICALIZE_FILE_NAME''@/1/g' \ -e 's/@''GNULIB_FREE_POSIX''@/1/g' \ -e 's/@''GNULIB_GETLOADAVG''@/0/g' \ -e 's/@''GNULIB_GETSUBOPT''@/0/g' \ -e 's/@''GNULIB_GRANTPT''@/0/g' \ -e 's/@''GNULIB_MALLOC_POSIX''@/1/g' \ -e 's/@''GNULIB_MBTOWC''@/0/g' \ -e 's/@''GNULIB_MKDTEMP''@/0/g' \ -e 's/@''GNULIB_MKOSTEMP''@/0/g' \ -e 's/@''GNULIB_MKOSTEMPS''@/0/g' \ -e 's/@''GNULIB_MKSTEMP''@/0/g' \ -e 's/@''GNULIB_MKSTEMPS''@/0/g' \ -e 's/@''GNULIB_POSIX_MEMALIGN''@/0/g' \ -e 's/@''GNULIB_POSIX_OPENPT''@/0/g' \ -e 's/@''GNULIB_PTSNAME''@/0/g' \ -e 's/@''GNULIB_PTSNAME_R''@/0/g' \ -e 's/@''GNULIB_PUTENV''@/0/g' \ -e 's/@''GNULIB_QSORT_R''@/0/g' \ -e 's/@''GNULIB_RANDOM''@/0/g' \ -e 's/@''GNULIB_RANDOM_R''@/0/g' \ -e 's/@''GNULIB_REALLOC_POSIX''@/1/g' \ -e 's/@''GNULIB_REALLOCARRAY''@/1/g' \ -e 's/@''GNULIB_REALPATH''@/1/g' \ -e 's/@''GNULIB_RPMATCH''@/0/g' \ -e 's/@''GNULIB_SECURE_GETENV''@/0/g' \ -e 's/@''GNULIB_SETENV''@/0/g' \ -e 's/@''GNULIB_STRTOD''@/1/g' \ -e 's/@''GNULIB_STRTOL''@/0/g' \ -e 's/@''GNULIB_STRTOLD''@/0/g' \ -e 's/@''GNULIB_STRTOLL''@/0/g' \ -e 's/@''GNULIB_STRTOUL''@/0/g' \ -e 's/@''GNULIB_STRTOULL''@/0/g' \ -e 's/@''GNULIB_SYSTEM_POSIX''@/0/g' \ -e 's/@''GNULIB_UNLOCKPT''@/0/g' \ -e 's/@''GNULIB_UNSETENV''@/1/g' \ -e 's/@''GNULIB_WCTOMB''@/0/g' \ -e 's/@''GNULIB_MDA_ECVT''@/1/g' \ -e 's/@''GNULIB_MDA_FCVT''@/1/g' \ -e 's/@''GNULIB_MDA_GCVT''@/1/g' \ -e 's/@''GNULIB_MDA_MKTEMP''@/1/g' \ -e 's/@''GNULIB_MDA_PUTENV''@/1/g' \ < ./lib/stdlib.in.h | \ sed -e 's|@''HAVE__EXIT''@|1|g' \ -e 's|@''HAVE_ALIGNED_ALLOC''@|1|g' \ -e 's|@''HAVE_ATOLL''@|1|g' \ -e 's|@''HAVE_CANONICALIZE_FILE_NAME''@|1|g' \ -e 's|@''HAVE_DECL_ECVT''@|1|g' \ -e 's|@''HAVE_DECL_FCVT''@|1|g' \ -e 's|@''HAVE_DECL_GCVT''@|1|g' \ -e 's|@''HAVE_DECL_GETLOADAVG''@|1|g' \ -e 's|@''HAVE_GETSUBOPT''@|1|g' \ -e 's|@''HAVE_GRANTPT''@|1|g' \ -e 's|@''HAVE_INITSTATE''@|1|g' \ -e 's|@''HAVE_DECL_INITSTATE''@|1|g' \ -e 's|@''HAVE_MBTOWC''@|1|g' \ -e 's|@''HAVE_MKDTEMP''@|1|g' \ -e 's|@''HAVE_MKOSTEMP''@|1|g' \ -e 's|@''HAVE_MKOSTEMPS''@|1|g' \ -e 's|@''HAVE_MKSTEMP''@|1|g' \ -e 's|@''HAVE_MKSTEMPS''@|1|g' \ -e 's|@''HAVE_POSIX_MEMALIGN''@|1|g' \ -e 's|@''HAVE_POSIX_OPENPT''@|1|g' \ -e 's|@''HAVE_PTSNAME''@|1|g' \ -e 's|@''HAVE_PTSNAME_R''@|1|g' \ -e 's|@''HAVE_QSORT_R''@|1|g' \ -e 's|@''HAVE_RANDOM''@|1|g' \ -e 's|@''HAVE_RANDOM_H''@|1|g' \ -e 's|@''HAVE_RANDOM_R''@|1|g' \ -e 's|@''HAVE_REALLOCARRAY''@|1|g' \ -e 's|@''HAVE_REALPATH''@|1|g' \ -e 's|@''HAVE_RPMATCH''@|1|g' \ -e 's|@''HAVE_SECURE_GETENV''@|1|g' \ -e 's|@''HAVE_DECL_SETENV''@|1|g' \ -e 's|@''HAVE_SETSTATE''@|1|g' \ -e 's|@''HAVE_DECL_SETSTATE''@|1|g' \ -e 's|@''HAVE_STRTOD''@|1|g' \ -e 's|@''HAVE_STRTOL''@|1|g' \ -e 's|@''HAVE_STRTOLD''@|1|g' \ -e 's|@''HAVE_STRTOLL''@|1|g' \ -e 's|@''HAVE_STRTOUL''@|1|g' \ -e 's|@''HAVE_STRTOULL''@|1|g' \ -e 's|@''HAVE_STRUCT_RANDOM_DATA''@|1|g' \ -e 's|@''HAVE_SYS_LOADAVG_H''@|0|g' \ -e 's|@''HAVE_UNLOCKPT''@|1|g' \ -e 's|@''HAVE_DECL_UNSETENV''@|1|g' \ -e 's|@''REPLACE_ALIGNED_ALLOC''@|0|g' \ -e 's|@''REPLACE_CALLOC''@|0|g' \ -e 's|@''REPLACE_CANONICALIZE_FILE_NAME''@|0|g' \ -e 's|@''REPLACE_FREE''@|0|g' \ -e 's|@''REPLACE_INITSTATE''@|0|g' \ -e 's|@''REPLACE_MALLOC''@|0|g' \ -e 's|@''REPLACE_MBTOWC''@|0|g' \ -e 's|@''REPLACE_MKSTEMP''@|0|g' \ -e 's|@''REPLACE_POSIX_MEMALIGN''@|0|g' \ -e 's|@''REPLACE_PTSNAME''@|0|g' \ -e 's|@''REPLACE_PTSNAME_R''@|0|g' \ -e 's|@''REPLACE_PUTENV''@|0|g' \ -e 's|@''REPLACE_QSORT_R''@|0|g' \ -e 's|@''REPLACE_RANDOM''@|0|g' \ -e 's|@''REPLACE_RANDOM_R''@|0|g' \ -e 's|@''REPLACE_REALLOC''@|0|g' \ -e 's|@''REPLACE_REALLOCARRAY''@|0|g' \ -e 's|@''REPLACE_REALPATH''@|0|g' \ -e 's|@''REPLACE_SETENV''@|0|g' \ -e 's|@''REPLACE_SETSTATE''@|0|g' \ -e 's|@''REPLACE_STRTOD''@|0|g' \ -e 's|@''REPLACE_STRTOL''@|0|g' \ -e 's|@''REPLACE_STRTOLD''@|0|g' \ -e 's|@''REPLACE_STRTOLL''@|0|g' \ -e 's|@''REPLACE_STRTOUL''@|0|g' \ -e 's|@''REPLACE_STRTOULL''@|0|g' \ -e 's|@''REPLACE_UNSETENV''@|0|g' \ -e 's|@''REPLACE_WCTOMB''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _Noreturn/r ./lib/_Noreturn.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h'; \ } > lib/stdlib.h-t && \ mv lib/stdlib.h-t lib/stdlib.h rm -f lib/string.h-t lib/string.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_STRING_H''@||g' \ -e 's/@''GNULIB_EXPLICIT_BZERO''@/0/g' \ -e 's/@''GNULIB_FFSL''@/1/g' \ -e 's/@''GNULIB_FFSLL''@/0/g' \ -e 's/@''GNULIB_MBSLEN''@/0/g' \ -e 's/@''GNULIB_MBSNLEN''@/0/g' \ -e 's/@''GNULIB_MBSCHR''@/0/g' \ -e 's/@''GNULIB_MBSRCHR''@/0/g' \ -e 's/@''GNULIB_MBSSTR''@/0/g' \ -e 's/@''GNULIB_MBSCASECMP''@/0/g' \ -e 's/@''GNULIB_MBSNCASECMP''@/0/g' \ -e 's/@''GNULIB_MBSPCASECMP''@/0/g' \ -e 's/@''GNULIB_MBSCASESTR''@/0/g' \ -e 's/@''GNULIB_MBSCSPN''@/0/g' \ -e 's/@''GNULIB_MBSPBRK''@/0/g' \ -e 's/@''GNULIB_MBSSPN''@/0/g' \ -e 's/@''GNULIB_MBSSEP''@/0/g' \ -e 's/@''GNULIB_MBSTOK_R''@/0/g' \ -e 's/@''GNULIB_MEMCHR''@/1/g' \ -e 's/@''GNULIB_MEMMEM''@/0/g' \ -e 's/@''GNULIB_MEMPCPY''@/1/g' \ -e 's/@''GNULIB_MEMRCHR''@/0/g' \ -e 's/@''GNULIB_RAWMEMCHR''@/1/g' \ -e 's/@''GNULIB_STPCPY''@/1/g' \ -e 's/@''GNULIB_STPNCPY''@/1/g' \ -e 's/@''GNULIB_STRCHRNUL''@/0/g' \ -e 's/@''GNULIB_STRDUP''@/1/g' \ -e 's/@''GNULIB_STRNCAT''@/0/g' \ -e 's/@''GNULIB_STRNDUP''@/1/g' \ -e 's/@''GNULIB_STRNLEN''@/0/g' \ -e 's/@''GNULIB_STRPBRK''@/0/g' \ -e 's/@''GNULIB_STRSEP''@/0/g' \ -e 's/@''GNULIB_STRSTR''@/0/g' \ -e 's/@''GNULIB_STRCASESTR''@/0/g' \ -e 's/@''GNULIB_STRTOK_R''@/0/g' \ -e 's/@''GNULIB_STRERROR''@/1/g' \ -e 's/@''GNULIB_STRERROR_R''@/0/g' \ -e 's/@''GNULIB_STRERRORNAME_NP''@/0/g' \ -e 's/@''GNULIB_SIGABBREV_NP''@/0/g' \ -e 's/@''GNULIB_SIGDESCR_NP''@/0/g' \ -e 's/@''GNULIB_STRSIGNAL''@/0/g' \ -e 's/@''GNULIB_STRVERSCMP''@/1/g' \ -e 's/@''GNULIB_MDA_MEMCCPY''@/1/g' \ -e 's/@''GNULIB_MDA_STRDUP''@/1/g' \ < ./lib/string.in.h | \ sed -e 's|@''HAVE_EXPLICIT_BZERO''@|1|g' \ -e 's|@''HAVE_FFSL''@|1|g' \ -e 's|@''HAVE_FFSLL''@|1|g' \ -e 's|@''HAVE_MBSLEN''@|0|g' \ -e 's|@''HAVE_DECL_MEMMEM''@|1|g' \ -e 's|@''HAVE_MEMPCPY''@|1|g' \ -e 's|@''HAVE_DECL_MEMRCHR''@|1|g' \ -e 's|@''HAVE_RAWMEMCHR''@|1|g' \ -e 's|@''HAVE_STPCPY''@|1|g' \ -e 's|@''HAVE_STPNCPY''@|1|g' \ -e 's|@''HAVE_STRCHRNUL''@|1|g' \ -e 's|@''HAVE_DECL_STRDUP''@|1|g' \ -e 's|@''HAVE_DECL_STRNDUP''@|1|g' \ -e 's|@''HAVE_DECL_STRNLEN''@|1|g' \ -e 's|@''HAVE_STRPBRK''@|1|g' \ -e 's|@''HAVE_STRSEP''@|1|g' \ -e 's|@''HAVE_STRCASESTR''@|1|g' \ -e 's|@''HAVE_DECL_STRTOK_R''@|1|g' \ -e 's|@''HAVE_DECL_STRERROR_R''@|1|g' \ -e 's|@''HAVE_STRERRORNAME_NP''@|1|g' \ -e 's|@''HAVE_SIGABBREV_NP''@|1|g' \ -e 's|@''HAVE_SIGDESCR_NP''@|1|g' \ -e 's|@''HAVE_DECL_STRSIGNAL''@|1|g' \ -e 's|@''HAVE_STRVERSCMP''@|1|g' \ -e 's|@''REPLACE_FFSLL''@|0|g' \ -e 's|@''REPLACE_MEMCHR''@|0|g' \ -e 's|@''REPLACE_MEMMEM''@|0|g' \ -e 's|@''REPLACE_FREE''@|0|g' \ -e 's|@''REPLACE_STPNCPY''@|0|g' \ -e 's|@''REPLACE_STRCHRNUL''@|0|g' \ -e 's|@''REPLACE_STRDUP''@|0|g' \ -e 's|@''REPLACE_STRNCAT''@|0|g' \ -e 's|@''REPLACE_STRNDUP''@|0|g' \ -e 's|@''REPLACE_STRNLEN''@|0|g' \ -e 's|@''REPLACE_STRSTR''@|0|g' \ -e 's|@''REPLACE_STRCASESTR''@|0|g' \ -e 's|@''REPLACE_STRTOK_R''@|0|g' \ -e 's|@''REPLACE_STRERROR''@|0|g' \ -e 's|@''REPLACE_STRERROR_R''@|1|g' \ -e 's|@''REPLACE_STRERRORNAME_NP''@|0|g' \ -e 's|@''REPLACE_STRSIGNAL''@|0|g' \ -e 's|@''UNDEFINE_STRTOK_R''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h'; \ < ./lib/string.in.h; \ } > lib/string.h-t && \ mv lib/string.h-t lib/string.h /usr/bin/mkdir -p lib/sys rm -f lib/sys/ioctl.h-t lib/sys/ioctl.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''HAVE_SYS_IOCTL_H''@|1|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SYS_IOCTL_H''@||g' \ -e 's/@''GNULIB_IOCTL''@/0/g' \ -e 's|@''SYS_IOCTL_H_HAVE_WINSOCK2_H''@|0|g' \ -e 's|@''SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS''@|0|g' \ -e 's|@''REPLACE_IOCTL''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/sys_ioctl.in.h; \ } > lib/sys/ioctl.h-t && \ mv lib/sys/ioctl.h-t lib/sys/ioctl.h /usr/bin/mkdir -p lib/sys /usr/bin/mkdir -p lib/sys rm -f lib/sys/resource.h-t lib/sys/resource.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SYS_RESOURCE_H''@||g' \ -e 's|@''HAVE_SYS_RESOURCE_H''@|1|g' \ -e 's/@''GNULIB_GETRUSAGE''@/1/g' \ -e 's/@''HAVE_GETRUSAGE''@/1/g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/sys_resource.in.h; \ } > lib/sys/resource.h-t && \ mv -f lib/sys/resource.h-t lib/sys/resource.h rm -f lib/sys/stat.h-t lib/sys/stat.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SYS_STAT_H''@||g' \ -e 's|@''WINDOWS_64_BIT_ST_SIZE''@|0|g' \ -e 's|@''WINDOWS_STAT_TIMESPEC''@|0|g' \ -e 's/@''GNULIB_FCHMODAT''@/0/g' \ -e 's/@''GNULIB_FSTAT''@/0/g' \ -e 's/@''GNULIB_FSTATAT''@/0/g' \ -e 's/@''GNULIB_FUTIMENS''@/0/g' \ -e 's/@''GNULIB_GETUMASK''@/0/g' \ -e 's/@''GNULIB_LCHMOD''@/0/g' \ -e 's/@''GNULIB_LSTAT''@/0/g' \ -e 's/@''GNULIB_MKDIR''@/0/g' \ -e 's/@''GNULIB_MKDIRAT''@/0/g' \ -e 's/@''GNULIB_MKFIFO''@/0/g' \ -e 's/@''GNULIB_MKFIFOAT''@/0/g' \ -e 's/@''GNULIB_MKNOD''@/0/g' \ -e 's/@''GNULIB_MKNODAT''@/0/g' \ -e 's/@''GNULIB_STAT''@/1/g' \ -e 's/@''GNULIB_UTIMENSAT''@/0/g' \ -e 's/@''GNULIB_OVERRIDES_STRUCT_STAT''@/0/g' \ -e 's/@''GNULIB_MDA_CHMOD''@/1/g' \ -e 's/@''GNULIB_MDA_MKDIR''@/1/g' \ -e 's/@''GNULIB_MDA_UMASK''@/1/g' \ -e 's|@''HAVE_FCHMODAT''@|1|g' \ -e 's|@''HAVE_FSTATAT''@|1|g' \ -e 's|@''HAVE_FUTIMENS''@|1|g' \ -e 's|@''HAVE_GETUMASK''@|1|g' \ -e 's|@''HAVE_LCHMOD''@|1|g' \ -e 's|@''HAVE_LSTAT''@|1|g' \ -e 's|@''HAVE_MKDIRAT''@|1|g' \ -e 's|@''HAVE_MKFIFO''@|1|g' \ -e 's|@''HAVE_MKFIFOAT''@|1|g' \ -e 's|@''HAVE_MKNOD''@|1|g' \ -e 's|@''HAVE_MKNODAT''@|1|g' \ -e 's|@''HAVE_UTIMENSAT''@|1|g' \ -e 's|@''REPLACE_FCHMODAT''@|0|g' \ -e 's|@''REPLACE_FSTAT''@|0|g' \ -e 's|@''REPLACE_FSTATAT''@|0|g' \ -e 's|@''REPLACE_FUTIMENS''@|0|g' \ -e 's|@''REPLACE_LSTAT''@|0|g' \ -e 's|@''REPLACE_MKDIR''@|0|g' \ -e 's|@''REPLACE_MKFIFO''@|0|g' \ -e 's|@''REPLACE_MKFIFOAT''@|0|g' \ -e 's|@''REPLACE_MKNOD''@|0|g' \ -e 's|@''REPLACE_MKNODAT''@|0|g' \ -e 's|@''REPLACE_STAT''@|0|g' \ -e 's|@''REPLACE_UTIMENSAT''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/sys_stat.in.h; \ } > lib/sys/stat.h-t && \ mv lib/sys/stat.h-t lib/sys/stat.h /usr/bin/mkdir -p lib/sys /usr/bin/mkdir -p lib/sys rm -f lib/sys/time.h-t lib/sys/time.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's/@''HAVE_SYS_TIME_H''@/1/g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SYS_TIME_H''@||g' \ -e 's/@''GNULIB_GETTIMEOFDAY''@/1/g' \ -e 's|@''HAVE_WINSOCK2_H''@|0|g' \ -e 's/@''HAVE_GETTIMEOFDAY''@/1/g' \ -e 's/@''HAVE_STRUCT_TIMEVAL''@/1/g' \ -e 's/@''REPLACE_GETTIMEOFDAY''@/0/g' \ -e 's/@''REPLACE_STRUCT_TIMEVAL''@/0/g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/sys_time.in.h; \ } > lib/sys/time.h-t && \ mv lib/sys/time.h-t lib/sys/time.h rm -f lib/sys/times.h-t lib/sys/times.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's/@''HAVE_SYS_TIMES_H''@/1/g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SYS_TIMES_H''@||g' \ -e 's/@''GNULIB_TIMES''@/0/g' \ -e 's|@''HAVE_STRUCT_TMS''@|1|g' \ -e 's|@''HAVE_TIMES''@|1|g' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/sys_times.in.h; \ } > lib/sys/times.h-t && \ mv lib/sys/times.h-t lib/sys/times.h /usr/bin/mkdir -p lib/sys rm -f lib/sys/types.h-t lib/sys/types.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SYS_TYPES_H''@||g' \ -e 's|@''WINDOWS_64_BIT_OFF_T''@|0|g' \ -e 's|@''WINDOWS_STAT_INODES''@|0|g' \ < ./lib/sys_types.in.h; \ } > lib/sys/types.h-t && \ mv lib/sys/types.h-t lib/sys/types.h /usr/bin/mkdir -p lib/sys rm -f lib/termios.h-t lib/termios.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_TERMIOS_H''@||g' \ -e 's/@''GNULIB_TCGETSID''@/0/g' \ -e 's|@''HAVE_DECL_TCGETSID''@|1|g' \ -e 's|@''HAVE_TERMIOS_H''@|1|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/termios.in.h; \ } > lib/termios.h-t && \ mv lib/termios.h-t lib/termios.h rm -f lib/sys/wait.h-t lib/sys/wait.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SYS_WAIT_H''@||g' \ -e 's/@''GNULIB_WAITPID''@/1/g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/sys_wait.in.h; \ } > lib/sys/wait.h-t && \ mv lib/sys/wait.h-t lib/sys/wait.h rm -f lib/time.h-t lib/time.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_TIME_H''@||g' \ -e 's/@''GNULIB_CTIME''@/0/g' \ -e 's/@''GNULIB_LOCALTIME''@/0/g' \ -e 's/@''GNULIB_MKTIME''@/0/g' \ -e 's/@''GNULIB_NANOSLEEP''@/0/g' \ -e 's/@''GNULIB_STRFTIME''@/0/g' \ -e 's/@''GNULIB_STRPTIME''@/0/g' \ -e 's/@''GNULIB_TIMEGM''@/0/g' \ -e 's/@''GNULIB_TIMESPEC_GET''@/0/g' \ -e 's/@''GNULIB_TIME_R''@/0/g' \ -e 's/@''GNULIB_TIME_RZ''@/0/g' \ -e 's/@''GNULIB_TZSET''@/0/g' \ -e 's/@''GNULIB_MDA_TZSET''@/1/g' \ -e 's|@''HAVE_DECL_LOCALTIME_R''@|1|g' \ -e 's|@''HAVE_NANOSLEEP''@|1|g' \ -e 's|@''HAVE_STRPTIME''@|1|g' \ -e 's|@''HAVE_TIMEGM''@|1|g' \ -e 's|@''HAVE_TIMESPEC_GET''@|1|g' \ -e 's|@''HAVE_TIMEZONE_T''@|0|g' \ -e 's|@''REPLACE_CTIME''@|GNULIB_PORTCHECK|g' \ -e 's|@''REPLACE_GMTIME''@|0|g' \ -e 's|@''REPLACE_LOCALTIME''@|0|g' \ -e 's|@''REPLACE_LOCALTIME_R''@|GNULIB_PORTCHECK|g' \ -e 's|@''REPLACE_MKTIME''@|GNULIB_PORTCHECK|g' \ -e 's|@''REPLACE_NANOSLEEP''@|GNULIB_PORTCHECK|g' \ -e 's|@''REPLACE_STRFTIME''@|GNULIB_PORTCHECK|g' \ -e 's|@''REPLACE_TIMEGM''@|GNULIB_PORTCHECK|g' \ -e 's|@''REPLACE_TZSET''@|GNULIB_PORTCHECK|g' \ -e 's|@''PTHREAD_H_DEFINES_STRUCT_TIMESPEC''@|0|g' \ -e 's|@''SYS_TIME_H_DEFINES_STRUCT_TIMESPEC''@|0|g' \ -e 's|@''TIME_H_DEFINES_STRUCT_TIMESPEC''@|1|g' \ -e 's|@''UNISTD_H_DEFINES_STRUCT_TIMESPEC''@|0|g' \ -e 's|@''TIME_H_DEFINES_TIME_UTC''@|1|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/time.in.h; \ } > lib/time.h-t && \ mv lib/time.h-t lib/time.h rm -f lib/unistd.h-t lib/unistd.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''HAVE_UNISTD_H''@|1|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_UNISTD_H''@||g' \ -e 's|@''WINDOWS_64_BIT_OFF_T''@|0|g' \ -e 's/@''GNULIB_ACCESS''@/1/g' \ -e 's/@''GNULIB_CHDIR''@/0/g' \ -e 's/@''GNULIB_CHOWN''@/0/g' \ -e 's/@''GNULIB_CLOSE''@/1/g' \ -e 's/@''GNULIB_COPY_FILE_RANGE''@/0/g' \ -e 's/@''GNULIB_DUP''@/0/g' \ -e 's/@''GNULIB_DUP2''@/1/g' \ -e 's/@''GNULIB_DUP3''@/0/g' \ -e 's/@''GNULIB_ENVIRON''@/1/g' \ -e 's/@''GNULIB_EUIDACCESS''@/0/g' \ -e 's/@''GNULIB_EXECL''@/0/g' \ -e 's/@''GNULIB_EXECLE''@/0/g' \ -e 's/@''GNULIB_EXECLP''@/0/g' \ -e 's/@''GNULIB_EXECV''@/0/g' \ -e 's/@''GNULIB_EXECVE''@/0/g' \ -e 's/@''GNULIB_EXECVP''@/0/g' \ -e 's/@''GNULIB_EXECVPE''@/0/g' \ -e 's/@''GNULIB_FACCESSAT''@/0/g' \ -e 's/@''GNULIB_FCHDIR''@/0/g' \ -e 's/@''GNULIB_FCHOWNAT''@/0/g' \ -e 's/@''GNULIB_FDATASYNC''@/0/g' \ -e 's/@''GNULIB_FSYNC''@/1/g' \ -e 's/@''GNULIB_FTRUNCATE''@/0/g' \ -e 's/@''GNULIB_GETCWD''@/1/g' \ -e 's/@''GNULIB_GETDOMAINNAME''@/0/g' \ -e 's/@''GNULIB_GETDTABLESIZE''@/1/g' \ -e 's/@''GNULIB_GETENTROPY''@/0/g' \ -e 's/@''GNULIB_GETGROUPS''@/0/g' \ -e 's/@''GNULIB_GETHOSTNAME''@/0/g' \ -e 's/@''GNULIB_GETLOGIN''@/0/g' \ -e 's/@''GNULIB_GETLOGIN_R''@/0/g' \ -e 's/@''GNULIB_GETOPT_POSIX''@/1/g' \ -e 's/@''GNULIB_GETPAGESIZE''@/0/g' \ -e 's/@''GNULIB_GETPASS''@/0/g' \ -e 's/@''GNULIB_GETUSERSHELL''@/0/g' \ -e 's/@''GNULIB_GROUP_MEMBER''@/0/g' \ -e 's/@''GNULIB_ISATTY''@/0/g' \ -e 's/@''GNULIB_LCHOWN''@/0/g' \ -e 's/@''GNULIB_LINK''@/0/g' \ -e 's/@''GNULIB_LINKAT''@/0/g' \ -e 's/@''GNULIB_LSEEK''@/0/g' \ -e 's/@''GNULIB_PIPE''@/1/g' \ -e 's/@''GNULIB_PIPE2''@/1/g' \ -e 's/@''GNULIB_PREAD''@/0/g' \ -e 's/@''GNULIB_PWRITE''@/0/g' \ -e 's/@''GNULIB_READ''@/0/g' \ -e 's/@''GNULIB_READLINK''@/1/g' \ -e 's/@''GNULIB_READLINKAT''@/0/g' \ -e 's/@''GNULIB_RMDIR''@/0/g' \ -e 's/@''GNULIB_SETHOSTNAME''@/0/g' \ -e 's/@''GNULIB_SLEEP''@/0/g' \ -e 's/@''GNULIB_SYMLINK''@/0/g' \ -e 's/@''GNULIB_SYMLINKAT''@/0/g' \ -e 's/@''GNULIB_TRUNCATE''@/0/g' \ -e 's/@''GNULIB_TTYNAME_R''@/0/g' \ -e 's/@''GNULIB_UNISTD_H_GETOPT''@/00/g' \ -e 's/@''GNULIB_UNISTD_H_NONBLOCKING''@/0/g' \ -e 's/@''GNULIB_UNISTD_H_SIGPIPE''@/0/g' \ -e 's/@''GNULIB_UNLINK''@/1/g' \ -e 's/@''GNULIB_UNLINKAT''@/0/g' \ -e 's/@''GNULIB_USLEEP''@/0/g' \ -e 's/@''GNULIB_WRITE''@/0/g' \ -e 's/@''GNULIB_MDA_ACCESS''@/1/g' \ -e 's/@''GNULIB_MDA_CHDIR''@/1/g' \ -e 's/@''GNULIB_MDA_CLOSE''@/1/g' \ -e 's/@''GNULIB_MDA_DUP''@/1/g' \ -e 's/@''GNULIB_MDA_DUP2''@/1/g' \ -e 's/@''GNULIB_MDA_EXECL''@/1/g' \ -e 's/@''GNULIB_MDA_EXECLE''@/1/g' \ -e 's/@''GNULIB_MDA_EXECLP''@/1/g' \ -e 's/@''GNULIB_MDA_EXECV''@/1/g' \ -e 's/@''GNULIB_MDA_EXECVE''@/1/g' \ -e 's/@''GNULIB_MDA_EXECVP''@/1/g' \ -e 's/@''GNULIB_MDA_EXECVPE''@/1/g' \ -e 's/@''GNULIB_MDA_GETCWD''@/1/g' \ -e 's/@''GNULIB_MDA_GETPID''@/1/g' \ -e 's/@''GNULIB_MDA_ISATTY''@/1/g' \ -e 's/@''GNULIB_MDA_LSEEK''@/1/g' \ -e 's/@''GNULIB_MDA_READ''@/1/g' \ -e 's/@''GNULIB_MDA_RMDIR''@/1/g' \ -e 's/@''GNULIB_MDA_SWAB''@/1/g' \ -e 's/@''GNULIB_MDA_UNLINK''@/1/g' \ -e 's/@''GNULIB_MDA_WRITE''@/1/g' \ < ./lib/unistd.in.h | \ sed -e 's|@''HAVE_CHOWN''@|1|g' \ -e 's|@''HAVE_COPY_FILE_RANGE''@|1|g' \ -e 's|@''HAVE_DUP3''@|1|g' \ -e 's|@''HAVE_EUIDACCESS''@|1|g' \ -e 's|@''HAVE_EXECVPE''@|1|g' \ -e 's|@''HAVE_FACCESSAT''@|1|g' \ -e 's|@''HAVE_FCHDIR''@|1|g' \ -e 's|@''HAVE_FCHOWNAT''@|1|g' \ -e 's|@''HAVE_FDATASYNC''@|1|g' \ -e 's|@''HAVE_FSYNC''@|1|g' \ -e 's|@''HAVE_FTRUNCATE''@|1|g' \ -e 's|@''HAVE_GETDTABLESIZE''@|1|g' \ -e 's|@''HAVE_GETENTROPY''@|1|g' \ -e 's|@''HAVE_GETGROUPS''@|1|g' \ -e 's|@''HAVE_GETHOSTNAME''@|1|g' \ -e 's|@''HAVE_GETPAGESIZE''@|1|g' \ -e 's|@''HAVE_GETPASS''@|1|g' \ -e 's|@''HAVE_GROUP_MEMBER''@|1|g' \ -e 's|@''HAVE_LCHOWN''@|1|g' \ -e 's|@''HAVE_LINK''@|1|g' \ -e 's|@''HAVE_LINKAT''@|1|g' \ -e 's|@''HAVE_PIPE''@|1|g' \ -e 's|@''HAVE_PIPE2''@|1|g' \ -e 's|@''HAVE_PREAD''@|1|g' \ -e 's|@''HAVE_PWRITE''@|1|g' \ -e 's|@''HAVE_READLINK''@|1|g' \ -e 's|@''HAVE_READLINKAT''@|1|g' \ -e 's|@''HAVE_SETHOSTNAME''@|1|g' \ -e 's|@''HAVE_SLEEP''@|1|g' \ -e 's|@''HAVE_SYMLINK''@|1|g' \ -e 's|@''HAVE_SYMLINKAT''@|1|g' \ -e 's|@''HAVE_UNLINKAT''@|1|g' \ -e 's|@''HAVE_USLEEP''@|1|g' \ -e 's|@''HAVE_DECL_ENVIRON''@|1|g' \ -e 's|@''HAVE_DECL_EXECVPE''@|1|g' \ -e 's|@''HAVE_DECL_FCHDIR''@|1|g' \ -e 's|@''HAVE_DECL_FDATASYNC''@|1|g' \ -e 's|@''HAVE_DECL_GETDOMAINNAME''@|1|g' \ -e 's|@''HAVE_DECL_GETLOGIN''@|1|g' \ -e 's|@''HAVE_DECL_GETLOGIN_R''@|1|g' \ -e 's|@''HAVE_DECL_GETPAGESIZE''@|1|g' \ -e 's|@''HAVE_DECL_GETUSERSHELL''@|1|g' \ -e 's|@''HAVE_DECL_SETHOSTNAME''@|1|g' \ -e 's|@''HAVE_DECL_TRUNCATE''@|1|g' \ -e 's|@''HAVE_DECL_TTYNAME_R''@|1|g' \ -e 's|@''HAVE_OS_H''@|0|g' \ -e 's|@''HAVE_SYS_PARAM_H''@|0|g' \ | \ sed -e 's|@''REPLACE_ACCESS''@|0|g' \ -e 's|@''REPLACE_CHOWN''@|0|g' \ -e 's|@''REPLACE_CLOSE''@|0|g' \ -e 's|@''REPLACE_DUP''@|0|g' \ -e 's|@''REPLACE_DUP2''@|0|g' \ -e 's|@''REPLACE_EXECL''@|0|g' \ -e 's|@''REPLACE_EXECLE''@|0|g' \ -e 's|@''REPLACE_EXECLP''@|0|g' \ -e 's|@''REPLACE_EXECV''@|0|g' \ -e 's|@''REPLACE_EXECVE''@|0|g' \ -e 's|@''REPLACE_EXECVP''@|0|g' \ -e 's|@''REPLACE_EXECVPE''@|0|g' \ -e 's|@''REPLACE_FACCESSAT''@|0|g' \ -e 's|@''REPLACE_FCHOWNAT''@|0|g' \ -e 's|@''REPLACE_FTRUNCATE''@|0|g' \ -e 's|@''REPLACE_GETCWD''@|0|g' \ -e 's|@''REPLACE_GETDOMAINNAME''@|0|g' \ -e 's|@''REPLACE_GETDTABLESIZE''@|0|g' \ -e 's|@''REPLACE_GETLOGIN_R''@|0|g' \ -e 's|@''REPLACE_GETGROUPS''@|0|g' \ -e 's|@''REPLACE_GETPAGESIZE''@|0|g' \ -e 's|@''REPLACE_GETPASS''@|0|g' \ -e 's|@''REPLACE_ISATTY''@|0|g' \ -e 's|@''REPLACE_LCHOWN''@|0|g' \ -e 's|@''REPLACE_LINK''@|0|g' \ -e 's|@''REPLACE_LINKAT''@|0|g' \ -e 's|@''REPLACE_LSEEK''@|0|g' \ -e 's|@''REPLACE_PREAD''@|0|g' \ -e 's|@''REPLACE_PWRITE''@|0|g' \ -e 's|@''REPLACE_READ''@|0|g' \ -e 's|@''REPLACE_READLINK''@|0|g' \ -e 's|@''REPLACE_READLINKAT''@|0|g' \ -e 's|@''REPLACE_RMDIR''@|0|g' \ -e 's|@''REPLACE_SLEEP''@|0|g' \ -e 's|@''REPLACE_SYMLINK''@|0|g' \ -e 's|@''REPLACE_SYMLINKAT''@|0|g' \ -e 's|@''REPLACE_TRUNCATE''@|0|g' \ -e 's|@''REPLACE_TTYNAME_R''@|0|g' \ -e 's|@''REPLACE_UNLINK''@|0|g' \ -e 's|@''REPLACE_UNLINKAT''@|0|g' \ -e 's|@''REPLACE_USLEEP''@|0|g' \ -e 's|@''REPLACE_WRITE''@|0|g' \ -e 's|@''UNISTD_H_HAVE_SYS_RANDOM_H''@|0|g' \ -e 's|@''UNISTD_H_HAVE_WINSOCK2_H''@|0|g' \ -e 's|@''UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h'; \ } > lib/unistd.h-t && \ mv lib/unistd.h-t lib/unistd.h rm -f lib/unistr.h-t lib/unistr.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ cat ./lib/unistr.in.h; \ } > lib/unistr.h-t && \ mv -f lib/unistr.h-t lib/unistr.h rm -f lib/unitypes.h-t lib/unitypes.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ cat ./lib/unitypes.in.h; \ } > lib/unitypes.h-t && \ mv -f lib/unitypes.h-t lib/unitypes.h rm -f lib/uniwidth.h-t lib/uniwidth.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ cat ./lib/uniwidth.in.h; \ } > lib/uniwidth.h-t && \ mv -f lib/uniwidth.h-t lib/uniwidth.h rm -f lib/wchar.h-t lib/wchar.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''HAVE_FEATURES_H''@|1|g' \ -e 's|@''NEXT_WCHAR_H''@||g' \ -e 's|@''HAVE_WCHAR_H''@|1|g' \ -e 's/@''HAVE_CRTDEFS_H''@/0/g' \ -e 's/@''GNULIBHEADERS_OVERRIDE_WINT_T''@/0/g' \ -e 's/@''GNULIB_BTOWC''@/0/g' \ -e 's/@''GNULIB_WCTOB''@/0/g' \ -e 's/@''GNULIB_MBSINIT''@/1/g' \ -e 's/@''GNULIB_MBRTOWC''@/1/g' \ -e 's/@''GNULIB_MBRLEN''@/0/g' \ -e 's/@''GNULIB_MBSRTOWCS''@/0/g' \ -e 's/@''GNULIB_MBSNRTOWCS''@/0/g' \ -e 's/@''GNULIB_WCRTOMB''@/0/g' \ -e 's/@''GNULIB_WCSRTOMBS''@/0/g' \ -e 's/@''GNULIB_WCSNRTOMBS''@/0/g' \ -e 's/@''GNULIB_WCWIDTH''@/1/g' \ -e 's/@''GNULIB_WMEMCHR''@/0/g' \ -e 's/@''GNULIB_WMEMCMP''@/0/g' \ -e 's/@''GNULIB_WMEMCPY''@/0/g' \ -e 's/@''GNULIB_WMEMMOVE''@/0/g' \ -e 's/@''GNULIB_WMEMPCPY''@/0/g' \ -e 's/@''GNULIB_WMEMSET''@/0/g' \ -e 's/@''GNULIB_WCSLEN''@/0/g' \ -e 's/@''GNULIB_WCSNLEN''@/0/g' \ -e 's/@''GNULIB_WCSCPY''@/0/g' \ -e 's/@''GNULIB_WCPCPY''@/0/g' \ -e 's/@''GNULIB_WCSNCPY''@/0/g' \ -e 's/@''GNULIB_WCPNCPY''@/0/g' \ -e 's/@''GNULIB_WCSCAT''@/0/g' \ -e 's/@''GNULIB_WCSNCAT''@/0/g' \ -e 's/@''GNULIB_WCSCMP''@/0/g' \ -e 's/@''GNULIB_WCSNCMP''@/0/g' \ -e 's/@''GNULIB_WCSCASECMP''@/0/g' \ -e 's/@''GNULIB_WCSNCASECMP''@/0/g' \ -e 's/@''GNULIB_WCSCOLL''@/0/g' \ -e 's/@''GNULIB_WCSXFRM''@/0/g' \ -e 's/@''GNULIB_WCSDUP''@/0/g' \ -e 's/@''GNULIB_WCSCHR''@/0/g' \ -e 's/@''GNULIB_WCSRCHR''@/0/g' \ -e 's/@''GNULIB_WCSCSPN''@/0/g' \ -e 's/@''GNULIB_WCSSPN''@/0/g' \ -e 's/@''GNULIB_WCSPBRK''@/0/g' \ -e 's/@''GNULIB_WCSSTR''@/0/g' \ -e 's/@''GNULIB_WCSTOK''@/0/g' \ -e 's/@''GNULIB_WCSWIDTH''@/0/g' \ -e 's/@''GNULIB_WCSFTIME''@/0/g' \ -e 's/@''GNULIB_MDA_WCSDUP''@/1/g' \ < ./lib/wchar.in.h | \ sed -e 's|@''HAVE_WINT_T''@|1|g' \ -e 's|@''HAVE_BTOWC''@|1|g' \ -e 's|@''HAVE_MBSINIT''@|1|g' \ -e 's|@''HAVE_MBRTOWC''@|1|g' \ -e 's|@''HAVE_MBRLEN''@|1|g' \ -e 's|@''HAVE_MBSRTOWCS''@|1|g' \ -e 's|@''HAVE_MBSNRTOWCS''@|1|g' \ -e 's|@''HAVE_WCRTOMB''@|1|g' \ -e 's|@''HAVE_WCSRTOMBS''@|1|g' \ -e 's|@''HAVE_WCSNRTOMBS''@|1|g' \ -e 's|@''HAVE_WMEMCHR''@|1|g' \ -e 's|@''HAVE_WMEMCMP''@|1|g' \ -e 's|@''HAVE_WMEMCPY''@|1|g' \ -e 's|@''HAVE_WMEMMOVE''@|1|g' \ -e 's|@''HAVE_WMEMPCPY''@|1|g' \ -e 's|@''HAVE_WMEMSET''@|1|g' \ -e 's|@''HAVE_WCSLEN''@|1|g' \ -e 's|@''HAVE_WCSNLEN''@|1|g' \ -e 's|@''HAVE_WCSCPY''@|1|g' \ -e 's|@''HAVE_WCPCPY''@|1|g' \ -e 's|@''HAVE_WCSNCPY''@|1|g' \ -e 's|@''HAVE_WCPNCPY''@|1|g' \ -e 's|@''HAVE_WCSCAT''@|1|g' \ -e 's|@''HAVE_WCSNCAT''@|1|g' \ -e 's|@''HAVE_WCSCMP''@|1|g' \ -e 's|@''HAVE_WCSNCMP''@|1|g' \ -e 's|@''HAVE_WCSCASECMP''@|1|g' \ -e 's|@''HAVE_WCSNCASECMP''@|1|g' \ -e 's|@''HAVE_WCSCOLL''@|1|g' \ -e 's|@''HAVE_WCSXFRM''@|1|g' \ -e 's|@''HAVE_WCSDUP''@|1|g' \ -e 's|@''HAVE_WCSCHR''@|1|g' \ -e 's|@''HAVE_WCSRCHR''@|1|g' \ -e 's|@''HAVE_WCSCSPN''@|1|g' \ -e 's|@''HAVE_WCSSPN''@|1|g' \ -e 's|@''HAVE_WCSPBRK''@|1|g' \ -e 's|@''HAVE_WCSSTR''@|1|g' \ -e 's|@''HAVE_WCSTOK''@|1|g' \ -e 's|@''HAVE_WCSWIDTH''@|1|g' \ -e 's|@''HAVE_WCSFTIME''@|1|g' \ -e 's|@''HAVE_DECL_WCTOB''@|1|g' \ -e 's|@''HAVE_DECL_WCSDUP''@|1|g' \ -e 's|@''HAVE_DECL_WCWIDTH''@|1|g' \ | \ sed -e 's|@''REPLACE_MBSTATE_T''@|0|g' \ -e 's|@''REPLACE_BTOWC''@|0|g' \ -e 's|@''REPLACE_WCTOB''@|0|g' \ -e 's|@''REPLACE_FREE''@|0|g' \ -e 's|@''REPLACE_MBSINIT''@|0|g' \ -e 's|@''REPLACE_MBRTOWC''@|1|g' \ -e 's|@''REPLACE_MBRLEN''@|0|g' \ -e 's|@''REPLACE_MBSRTOWCS''@|0|g' \ -e 's|@''REPLACE_MBSNRTOWCS''@|0|g' \ -e 's|@''REPLACE_WCRTOMB''@|0|g' \ -e 's|@''REPLACE_WCSRTOMBS''@|0|g' \ -e 's|@''REPLACE_WCSNRTOMBS''@|0|g' \ -e 's|@''REPLACE_WCWIDTH''@|0|g' \ -e 's|@''REPLACE_WCSWIDTH''@|0|g' \ -e 's|@''REPLACE_WCSFTIME''@|0|g' \ -e 's|@''REPLACE_WCSTOK''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h'; \ } > lib/wchar.h-t && \ mv lib/wchar.h-t lib/wchar.h rm -f lib/wctype.h-t lib/wctype.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's/@''HAVE_WCTYPE_H''@/1/g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_WCTYPE_H''@||g' \ -e 's/@''HAVE_CRTDEFS_H''@/0/g' \ -e 's/@''GNULIBHEADERS_OVERRIDE_WINT_T''@/0/g' \ -e 's/@''GNULIB_ISWBLANK''@/1/g' \ -e 's/@''GNULIB_ISWDIGIT''@/1/g' \ -e 's/@''GNULIB_ISWXDIGIT''@/1/g' \ -e 's/@''GNULIB_WCTYPE''@/0/g' \ -e 's/@''GNULIB_ISWCTYPE''@/0/g' \ -e 's/@''GNULIB_WCTRANS''@/0/g' \ -e 's/@''GNULIB_TOWCTRANS''@/0/g' \ -e 's/@''HAVE_ISWBLANK''@/1/g' \ -e 's/@''HAVE_ISWCNTRL''@/1/g' \ -e 's/@''HAVE_WCTYPE_T''@/1/g' \ -e 's/@''HAVE_WCTRANS_T''@/1/g' \ -e 's/@''HAVE_WINT_T''@/1/g' \ -e 's/@''REPLACE_ISWBLANK''@/0/g' \ -e 's/@''REPLACE_ISWDIGIT''@/0/g' \ -e 's/@''REPLACE_ISWXDIGIT''@/0/g' \ -e 's/@''REPLACE_ISWCNTRL''@/0/g' \ -e 's/@''REPLACE_TOWLOWER''@/0/g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/wctype.in.h; \ } > lib/wctype.h-t && \ mv lib/wctype.h-t lib/wctype.h echo 3.8.2 > .version-t && mv .version-t .version make all-recursive make[2]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' Making all in po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/po' make[3]: Nothing to be done for 'all'. make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/po' Making all in runtime-po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' make[3]: Nothing to be done for 'all'. make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' Making all in gnulib-po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' make[3]: Nothing to be done for 'all'. make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' Making all in . make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-bitsetv.o `test -f 'lib/bitsetv.c' || echo './'`lib/bitsetv.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-c-ctype.o `test -f 'lib/c-ctype.c' || echo './'`lib/c-ctype.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-c-strcasecmp.o `test -f 'lib/c-strcasecmp.c' || echo './'`lib/c-strcasecmp.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-c-strncasecmp.o `test -f 'lib/c-strncasecmp.c' || echo './'`lib/c-strncasecmp.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-canonicalize.o `test -f 'lib/canonicalize.c' || echo './'`lib/canonicalize.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-careadlinkat.o `test -f 'lib/careadlinkat.c' || echo './'`lib/careadlinkat.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-cloexec.o `test -f 'lib/cloexec.c' || echo './'`lib/cloexec.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-close-stream.o `test -f 'lib/close-stream.c' || echo './'`lib/close-stream.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-closeout.o `test -f 'lib/closeout.c' || echo './'`lib/closeout.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-concat-filename.o `test -f 'lib/concat-filename.c' || echo './'`lib/concat-filename.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-dirname.o `test -f 'lib/dirname.c' || echo './'`lib/dirname.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-basename.o `test -f 'lib/basename.c' || echo './'`lib/basename.c lib/careadlinkat.c: In function 'careadlinkat': lib/careadlinkat.c:178:5: warning: #warning "GCC might issue a bogus -Wreturn-local-addr warning here." [-Wcpp] 178 | #warning "GCC might issue a bogus -Wreturn-local-addr warning here." | ^~~~~~~ lib/careadlinkat.c:179:5: warning: #warning "See ." [-Wcpp] 179 | #warning "See ." | ^~~~~~~ gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-dirname-lgpl.o `test -f 'lib/dirname-lgpl.c' || echo './'`lib/dirname-lgpl.c lib/canonicalize.c: In function 'canonicalize_filename_mode': lib/careadlinkat.c:182:10: warning: function may return address of local variable [-Wreturn-local-addr] 182 | return readlink_stk (fd, filename, buffer, buffer_size, alloc, | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 183 | preadlinkat, stack_buf); | ~~~~~~~~~~~~~~~~~~~~~~~ lib/canonicalize.c:484:5: warning: #warning "GCC might issue a bogus -Wreturn-local-addr warning here." [-Wcpp] 484 | #warning "GCC might issue a bogus -Wreturn-local-addr warning here." | ^~~~~~~ lib/canonicalize.c:485:5: warning: #warning "See ." [-Wcpp] 485 | #warning "See ." | ^~~~~~~ lib/careadlinkat.c:181:8: note: declared here 181 | char stack_buf[STACK_BUF_SIZE]; | ^~~~~~~~~ gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-stripslash.o `test -f 'lib/stripslash.c' || echo './'`lib/stripslash.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-execute.o `test -f 'lib/execute.c' || echo './'`lib/execute.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-exitfail.o `test -f 'lib/exitfail.c' || echo './'`lib/exitfail.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fatal-signal.o `test -f 'lib/fatal-signal.c' || echo './'`lib/fatal-signal.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fd-safer-flag.o `test -f 'lib/fd-safer-flag.c' || echo './'`lib/fd-safer-flag.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-dup-safer-flag.o `test -f 'lib/dup-safer-flag.c' || echo './'`lib/dup-safer-flag.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-file-set.o `test -f 'lib/file-set.c' || echo './'`lib/file-set.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-findprog-in.o `test -f 'lib/findprog-in.c' || echo './'`lib/findprog-in.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fopen-safer.o `test -f 'lib/fopen-safer.c' || echo './'`lib/fopen-safer.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fstrcmp.o `test -f 'lib/fstrcmp.c' || echo './'`lib/fstrcmp.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gethrxtime.o `test -f 'lib/gethrxtime.c' || echo './'`lib/gethrxtime.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xtime.o `test -f 'lib/xtime.c' || echo './'`lib/xtime.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-getprogname.o `test -f 'lib/getprogname.c' || echo './'`lib/getprogname.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gettime.o `test -f 'lib/gettime.c' || echo './'`lib/gettime.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-hard-locale.o `test -f 'lib/hard-locale.c' || echo './'`lib/hard-locale.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-hash.o `test -f 'lib/hash.c' || echo './'`lib/hash.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_hash_map.o `test -f 'lib/gl_hash_map.c' || echo './'`lib/gl_hash_map.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-hash-pjw.o `test -f 'lib/hash-pjw.c' || echo './'`lib/hash-pjw.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-hash-triple-simple.o `test -f 'lib/hash-triple-simple.c' || echo './'`lib/hash-triple-simple.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-ialloc.o `test -f 'lib/ialloc.c' || echo './'`lib/ialloc.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-integer_length.o `test -f 'lib/integer_length.c' || echo './'`lib/integer_length.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-integer_length_l.o `test -f 'lib/integer_length_l.c' || echo './'`lib/integer_length_l.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_linked_list.o `test -f 'lib/gl_linked_list.c' || echo './'`lib/gl_linked_list.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_list.o `test -f 'lib/gl_list.c' || echo './'`lib/gl_list.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-localcharset.o `test -f 'lib/localcharset.c' || echo './'`lib/localcharset.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_map.o `test -f 'lib/gl_map.c' || echo './'`lib/gl_map.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-math.o `test -f 'lib/math.c' || echo './'`lib/math.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-mbchar.o `test -f 'lib/mbchar.c' || echo './'`lib/mbchar.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-mbfile.o `test -f 'lib/mbfile.c' || echo './'`lib/mbfile.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-mbswidth.o `test -f 'lib/mbswidth.c' || echo './'`lib/mbswidth.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_oset.o `test -f 'lib/gl_oset.c' || echo './'`lib/gl_oset.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-pipe2.o `test -f 'lib/pipe2.c' || echo './'`lib/pipe2.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-pipe2-safer.o `test -f 'lib/pipe2-safer.c' || echo './'`lib/pipe2-safer.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-printf-frexp.o `test -f 'lib/printf-frexp.c' || echo './'`lib/printf-frexp.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-printf-frexpl.o `test -f 'lib/printf-frexpl.c' || echo './'`lib/printf-frexpl.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-progname.o `test -f 'lib/progname.c' || echo './'`lib/progname.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-quotearg.o `test -f 'lib/quotearg.c' || echo './'`lib/quotearg.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_rbtree_oset.o `test -f 'lib/gl_rbtree_oset.c' || echo './'`lib/gl_rbtree_oset.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_rbtreehash_list.o `test -f 'lib/gl_rbtreehash_list.c' || echo './'`lib/gl_rbtreehash_list.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-setlocale_null.o `test -f 'lib/setlocale_null.c' || echo './'`lib/setlocale_null.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-sig-handler.o `test -f 'lib/sig-handler.c' || echo './'`lib/sig-handler.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-spawn-pipe.o `test -f 'lib/spawn-pipe.c' || echo './'`lib/spawn-pipe.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/glthread/libbison_a-threadlib.o `test -f 'lib/glthread/threadlib.c' || echo './'`lib/glthread/threadlib.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-timespec.o `test -f 'lib/timespec.c' || echo './'`lib/timespec.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-timevar.o `test -f 'lib/timevar.c' || echo './'`lib/timevar.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/glthread/libbison_a-tls.o `test -f 'lib/glthread/tls.c' || echo './'`lib/glthread/tls.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-unicodeio.o `test -f 'lib/unicodeio.c' || echo './'`lib/unicodeio.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-unistd.o `test -f 'lib/unistd.c' || echo './'`lib/unistd.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-dup-safer.o `test -f 'lib/dup-safer.c' || echo './'`lib/dup-safer.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fd-safer.o `test -f 'lib/fd-safer.c' || echo './'`lib/fd-safer.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-pipe-safer.o `test -f 'lib/pipe-safer.c' || echo './'`lib/pipe-safer.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-wait-process.o `test -f 'lib/wait-process.c' || echo './'`lib/wait-process.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-wctype-h.o `test -f 'lib/wctype-h.c' || echo './'`lib/wctype-h.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xmalloc.o `test -f 'lib/xmalloc.c' || echo './'`lib/xmalloc.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xalloc-die.o `test -f 'lib/xalloc-die.c' || echo './'`lib/xalloc-die.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xconcat-filename.o `test -f 'lib/xconcat-filename.c' || echo './'`lib/xconcat-filename.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xhash.o `test -f 'lib/xhash.c' || echo './'`lib/xhash.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_xlist.o `test -f 'lib/gl_xlist.c' || echo './'`lib/gl_xlist.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_xmap.o `test -f 'lib/gl_xmap.c' || echo './'`lib/gl_xmap.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xmemdup0.o `test -f 'lib/xmemdup0.c' || echo './'`lib/xmemdup0.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xreadlink.o `test -f 'lib/xreadlink.c' || echo './'`lib/xreadlink.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xsize.o `test -f 'lib/xsize.c' || echo './'`lib/xsize.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xstrndup.o `test -f 'lib/xstrndup.c' || echo './'`lib/xstrndup.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-get-errno.o `test -f 'lib/get-errno.c' || echo './'`lib/get-errno.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-path-join.o `test -f 'lib/path-join.c' || echo './'`lib/path-join.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-asnprintf.o `test -f 'lib/asnprintf.c' || echo './'`lib/asnprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-asprintf.o `test -f 'lib/asprintf.c' || echo './'`lib/asprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fcntl.o `test -f 'lib/fcntl.c' || echo './'`lib/fcntl.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fprintf.o `test -f 'lib/fprintf.c' || echo './'`lib/fprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fseterr.o `test -f 'lib/fseterr.c' || echo './'`lib/fseterr.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-mbrtowc.o `test -f 'lib/mbrtowc.c' || echo './'`lib/mbrtowc.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-obstack.o `test -f 'lib/obstack.c' || echo './'`lib/obstack.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-printf.o `test -f 'lib/printf.c' || echo './'`lib/printf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-printf-args.o `test -f 'lib/printf-args.c' || echo './'`lib/printf-args.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-printf-parse.o `test -f 'lib/printf-parse.c' || echo './'`lib/printf-parse.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-readline.o `test -f 'lib/readline.c' || echo './'`lib/readline.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-snprintf.o `test -f 'lib/snprintf.c' || echo './'`lib/snprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-spawn_faction_addchdir.o `test -f 'lib/spawn_faction_addchdir.c' || echo './'`lib/spawn_faction_addchdir.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-sprintf.o `test -f 'lib/sprintf.c' || echo './'`lib/sprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-vasnprintf.o `test -f 'lib/vasnprintf.c' || echo './'`lib/vasnprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-vasprintf.o `test -f 'lib/vasprintf.c' || echo './'`lib/vasprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-vfprintf.o `test -f 'lib/vfprintf.c' || echo './'`lib/vfprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-vsnprintf.o `test -f 'lib/vsnprintf.c' || echo './'`lib/vsnprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-vsprintf.o `test -f 'lib/vsprintf.c' || echo './'`lib/vsprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/main.o lib/main.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/yyerror.o lib/yyerror.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-AnnotationList.o `test -f 'src/AnnotationList.c' || echo './'`src/AnnotationList.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-InadequacyList.o `test -f 'src/InadequacyList.c' || echo './'`src/InadequacyList.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-Sbitset.o `test -f 'src/Sbitset.c' || echo './'`src/Sbitset.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-assoc.o `test -f 'src/assoc.c' || echo './'`src/assoc.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-closure.o `test -f 'src/closure.c' || echo './'`src/closure.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-complain.o `test -f 'src/complain.c' || echo './'`src/complain.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-conflicts.o `test -f 'src/conflicts.c' || echo './'`src/conflicts.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-counterexample.o `test -f 'src/counterexample.c' || echo './'`src/counterexample.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-derivation.o `test -f 'src/derivation.c' || echo './'`src/derivation.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-derives.o `test -f 'src/derives.c' || echo './'`src/derives.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-files.o `test -f 'src/files.c' || echo './'`src/files.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-fixits.o `test -f 'src/fixits.c' || echo './'`src/fixits.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-getargs.o `test -f 'src/getargs.c' || echo './'`src/getargs.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-glyphs.o `test -f 'src/glyphs.c' || echo './'`src/glyphs.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-gram.o `test -f 'src/gram.c' || echo './'`src/gram.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-graphviz.o `test -f 'src/graphviz.c' || echo './'`src/graphviz.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-ielr.o `test -f 'src/ielr.c' || echo './'`src/ielr.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-lalr.o `test -f 'src/lalr.c' || echo './'`src/lalr.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-location.o `test -f 'src/location.c' || echo './'`src/location.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-lr0.o `test -f 'src/lr0.c' || echo './'`src/lr0.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-lssi.o `test -f 'src/lssi.c' || echo './'`src/lssi.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-main.o `test -f 'src/main.c' || echo './'`src/main.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-muscle-tab.o `test -f 'src/muscle-tab.c' || echo './'`src/muscle-tab.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-named-ref.o `test -f 'src/named-ref.c' || echo './'`src/named-ref.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-nullable.o `test -f 'src/nullable.c' || echo './'`src/nullable.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-output.o `test -f 'src/output.c' || echo './'`src/output.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-parse-gram.o `test -f 'src/parse-gram.c' || echo './'`src/parse-gram.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-parse-simulation.o `test -f 'src/parse-simulation.c' || echo './'`src/parse-simulation.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-print-graph.o `test -f 'src/print-graph.c' || echo './'`src/print-graph.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-print-xml.o `test -f 'src/print-xml.c' || echo './'`src/print-xml.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-print.o `test -f 'src/print.c' || echo './'`src/print.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-reader.o `test -f 'src/reader.c' || echo './'`src/reader.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-reduce.o `test -f 'src/reduce.c' || echo './'`src/reduce.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-relation.o `test -f 'src/relation.c' || echo './'`src/relation.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-scan-code-c.o `test -f 'src/scan-code-c.c' || echo './'`src/scan-code-c.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-scan-gram-c.o `test -f 'src/scan-gram-c.c' || echo './'`src/scan-gram-c.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-scan-skel-c.o `test -f 'src/scan-skel-c.c' || echo './'`src/scan-skel-c.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-state.o `test -f 'src/state.c' || echo './'`src/state.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-state-item.o `test -f 'src/state-item.c' || echo './'`src/state-item.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-strversion.o `test -f 'src/strversion.c' || echo './'`src/strversion.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-symlist.o `test -f 'src/symlist.c' || echo './'`src/symlist.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-symtab.o `test -f 'src/symtab.c' || echo './'`src/symtab.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-tables.o `test -f 'src/tables.c' || echo './'`src/tables.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-uniqstr.o `test -f 'src/uniqstr.c' || echo './'`src/uniqstr.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-allocator.o `test -f 'lib/allocator.c' || echo './'`lib/allocator.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-areadlink.o `test -f 'lib/areadlink.c' || echo './'`lib/areadlink.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-argmatch.o `test -f 'lib/argmatch.c' || echo './'`lib/argmatch.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_array_list.o `test -f 'lib/gl_array_list.c' || echo './'`lib/gl_array_list.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-basename-lgpl.o `test -f 'lib/basename-lgpl.c' || echo './'`lib/basename-lgpl.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-binary-io.o `test -f 'lib/binary-io.c' || echo './'`lib/binary-io.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-bitrotate.o `test -f 'lib/bitrotate.c' || echo './'`lib/bitrotate.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-bitset.o `test -f 'lib/bitset.c' || echo './'`lib/bitset.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/bitset/libbison_a-array.o `test -f 'lib/bitset/array.c' || echo './'`lib/bitset/array.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/bitset/libbison_a-stats.o `test -f 'lib/bitset/stats.c' || echo './'`lib/bitset/stats.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/bitset/libbison_a-table.o `test -f 'lib/bitset/table.c' || echo './'`lib/bitset/table.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/bitset/libbison_a-list.o `test -f 'lib/bitset/list.c' || echo './'`lib/bitset/list.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/bitset/libbison_a-vector.o `test -f 'lib/bitset/vector.c' || echo './'`lib/bitset/vector.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/glthread/libbison_a-lock.o `test -f 'lib/glthread/lock.c' || echo './'`lib/glthread/lock.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/malloc/libbison_a-scratch_buffer_dupfree.o `test -f 'lib/malloc/scratch_buffer_dupfree.c' || echo './'`lib/malloc/scratch_buffer_dupfree.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/malloc/libbison_a-scratch_buffer_grow.o `test -f 'lib/malloc/scratch_buffer_grow.c' || echo './'`lib/malloc/scratch_buffer_grow.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/malloc/libbison_a-scratch_buffer_grow_preserve.o `test -f 'lib/malloc/scratch_buffer_grow_preserve.c' || echo './'`lib/malloc/scratch_buffer_grow_preserve.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/malloc/libbison_a-scratch_buffer_set_array_size.o `test -f 'lib/malloc/scratch_buffer_set_array_size.c' || echo './'`lib/malloc/scratch_buffer_set_array_size.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/unistr/libbison_a-u8-mbtoucr.o `test -f 'lib/unistr/u8-mbtoucr.c' || echo './'`lib/unistr/u8-mbtoucr.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/unistr/libbison_a-u8-uctomb.o `test -f 'lib/unistr/u8-uctomb.c' || echo './'`lib/unistr/u8-uctomb.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/unistr/libbison_a-u8-uctomb-aux.o `test -f 'lib/unistr/u8-uctomb-aux.c' || echo './'`lib/unistr/u8-uctomb-aux.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/uniwidth/libbison_a-width.o `test -f 'lib/uniwidth/width.c' || echo './'`lib/uniwidth/width.c rm -f lib/liby.a ar cr lib/liby.a lib/main.o lib/yyerror.o ranlib lib/liby.a rm -f lib/libbison.a ar cr lib/libbison.a lib/libbison_a-allocator.o lib/libbison_a-areadlink.o lib/libbison_a-argmatch.o lib/libbison_a-gl_array_list.o lib/libbison_a-basename-lgpl.o lib/libbison_a-binary-io.o lib/libbison_a-bitrotate.o lib/libbison_a-bitset.o lib/bitset/libbison_a-array.o lib/bitset/libbison_a-stats.o lib/bitset/libbison_a-table.o lib/bitset/libbison_a-list.o lib/bitset/libbison_a-vector.o lib/libbison_a-bitsetv.o lib/libbison_a-c-ctype.o lib/libbison_a-c-strcasecmp.o lib/libbison_a-c-strncasecmp.o lib/libbison_a-canonicalize.o lib/libbison_a-careadlinkat.o lib/libbison_a-cloexec.o lib/libbison_a-close-stream.o lib/libbison_a-closeout.o lib/libbison_a-concat-filename.o lib/libbison_a-dirname.o lib/libbison_a-basename.o lib/libbison_a-dirname-lgpl.o lib/libbison_a-stripslash.o lib/libbison_a-execute.o lib/libbison_a-exitfail.o lib/libbison_a-fatal-signal.o lib/libbison_a-fd-safer-flag.o lib/libbison_a-dup-safer-flag.o lib/libbison_a-file-set.o lib/libbison_a-findprog-in.o lib/libbison_a-fopen-safer.o lib/libbison_a-fstrcmp.o lib/libbison_a-gethrxtime.o lib/libbison_a-xtime.o lib/libbison_a-getprogname.o lib/libbison_a-gettime.o lib/libbison_a-hard-locale.o lib/libbison_a-hash.o lib/libbison_a-gl_hash_map.o lib/libbison_a-hash-pjw.o lib/libbison_a-hash-triple-simple.o lib/libbison_a-ialloc.o lib/libbison_a-integer_length.o lib/libbison_a-integer_length_l.o lib/libbison_a-gl_linked_list.o lib/libbison_a-gl_list.o lib/libbison_a-localcharset.o lib/glthread/libbison_a-lock.o lib/libbison_a-gl_map.o lib/libbison_a-math.o lib/libbison_a-mbchar.o lib/libbison_a-mbfile.o lib/libbison_a-mbswidth.o lib/libbison_a-gl_oset.o lib/libbison_a-pipe2.o lib/libbison_a-pipe2-safer.o lib/libbison_a-printf-frexp.o lib/libbison_a-printf-frexpl.o lib/libbison_a-progname.o lib/libbison_a-quotearg.o lib/libbison_a-gl_rbtree_oset.o lib/libbison_a-gl_rbtreehash_list.o lib/malloc/libbison_a-scratch_buffer_dupfree.o lib/malloc/libbison_a-scratch_buffer_grow.o lib/malloc/libbison_a-scratch_buffer_grow_preserve.o lib/malloc/libbison_a-scratch_buffer_set_array_size.o lib/libbison_a-setlocale_null.o lib/libbison_a-sig-handler.o lib/libbison_a-spawn-pipe.o lib/glthread/libbison_a-threadlib.o lib/libbison_a-timespec.o lib/libbison_a-timevar.o lib/glthread/libbison_a-tls.o lib/libbison_a-unicodeio.o lib/libbison_a-unistd.o lib/libbison_a-dup-safer.o lib/libbison_a-fd-safer.o lib/libbison_a-pipe-safer.o lib/unistr/libbison_a-u8-mbtoucr.o lib/unistr/libbison_a-u8-uctomb.o lib/unistr/libbison_a-u8-uctomb-aux.o lib/uniwidth/libbison_a-width.o lib/libbison_a-wait-process.o lib/libbison_a-wctype-h.o lib/libbison_a-xmalloc.o lib/libbison_a-xalloc-die.o lib/libbison_a-xconcat-filename.o lib/libbison_a-xhash.o lib/libbison_a-gl_xlist.o lib/libbison_a-gl_xmap.o lib/libbison_a-xmemdup0.o lib/libbison_a-xreadlink.o lib/libbison_a-xsize.o lib/libbison_a-xstrndup.o lib/libbison_a-get-errno.o lib/libbison_a-path-join.o lib/libbison_a-asnprintf.o lib/libbison_a-asprintf.o lib/libbison_a-fcntl.o lib/libbison_a-fprintf.o lib/libbison_a-fseterr.o lib/libbison_a-mbrtowc.o lib/libbison_a-obstack.o lib/libbison_a-printf.o lib/libbison_a-printf-args.o lib/libbison_a-printf-parse.o lib/libbison_a-readline.o lib/libbison_a-snprintf.o lib/libbison_a-spawn_faction_addchdir.o lib/libbison_a-sprintf.o lib/libbison_a-vasnprintf.o lib/libbison_a-vasprintf.o lib/libbison_a-vfprintf.o lib/libbison_a-vsnprintf.o lib/libbison_a-vsprintf.o ranlib lib/libbison.a gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o src/bison src/bison-AnnotationList.o src/bison-InadequacyList.o src/bison-Sbitset.o src/bison-assoc.o src/bison-closure.o src/bison-complain.o src/bison-conflicts.o src/bison-counterexample.o src/bison-derivation.o src/bison-derives.o src/bison-files.o src/bison-fixits.o src/bison-getargs.o src/bison-glyphs.o src/bison-gram.o src/bison-graphviz.o src/bison-ielr.o src/bison-lalr.o src/bison-location.o src/bison-lr0.o src/bison-lssi.o src/bison-main.o src/bison-muscle-tab.o src/bison-named-ref.o src/bison-nullable.o src/bison-output.o src/bison-parse-gram.o src/bison-parse-simulation.o src/bison-print-graph.o src/bison-print-xml.o src/bison-print.o src/bison-reader.o src/bison-reduce.o src/bison-relation.o src/bison-scan-code-c.o src/bison-scan-gram-c.o src/bison-scan-skel-c.o src/bison-state.o src/bison-state-item.o src/bison-strversion.o src/bison-symlist.o src/bison-symtab.o src/bison-tables.o src/bison-uniqstr.o lib/libbison.a /usr/bin/mkdir -p doc LC_ALL=C tests/bison --version >doc/bison.help.tmp LC_ALL=C tests/bison --help | \ sed -e 's,^Usage: .*/bison \[OPTION\],Usage: bison [OPTION],g' \ -e '/translation bugs/d' >>doc/bison.help.tmp ./build-aux/move-if-change doc/bison.help.tmp doc/bison.help if /bin/bash '/build/reproducible-path/bison-3.8.2+dfsg/build-aux/missing' help2man --version >/dev/null 2>&1; then \ /bin/bash '/build/reproducible-path/bison-3.8.2+dfsg/build-aux/missing' help2man \ --include=./doc/bison.x \ --output=doc/bison.1.tmp tests/bison && \ { sed 's/^\(\.TH[^"]*"[^"]*"[^"]*\)"[^"]*"/\1/' doc/bison.1 >doc/bison.1a.tmp || true; } && \ sed 's/^\(\.TH[^"]*"[^"]*"[^"]*\)"[^"]*"/\1/' doc/bison.1.tmp >doc/bison.1b.tmp && \ if diff doc/bison.1a.tmp doc/bison.1b.tmp >/dev/null 2>&1; then \ touch doc/bison.1; \ else \ mv doc/bison.1.tmp doc/bison.1; \ fi && \ rm -f doc/bison.1*.tmp; \ elif test -d ./.git; then \ echo >&2 "ERROR: doc/bison.1: help2man is needed"; \ exit 1; \ else \ touch doc/bison.1; \ fi /usr/bin/perl -pi.bak -0777 \ -e 's{(^ --.*\n(?: {10}.*\n)*)}' \ -e '{' \ -e ' $def = $1;' \ -e ' $def =~ s/‘|’//g;' \ -e ' $def;' \ -e '}gem;' ./doc/bison.info make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[2]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' dh_auto_test make -j12 check "TESTSUITEFLAGS=-j12 --verbose" VERBOSE=1 make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' if test -d ./.git \ && git --version >/dev/null 2>&1; then \ cd . && \ git submodule --quiet foreach \ 'test "$(git rev-parse "$sha1")" \ = "$(git merge-base origin "$sha1")"' \ || { echo 'maint.mk: found non-public submodule commit' >&2; \ exit 1; }; \ else \ : ; \ fi make check-recursive make[2]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' Making check in po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/po' make[3]: Nothing to be done for 'check'. make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/po' Making check in runtime-po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' make[3]: Nothing to be done for 'check'. make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' Making check in gnulib-po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' make[3]: Nothing to be done for 'check'. make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' Making check in . make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' /usr/bin/mkdir -p doc LC_ALL=C tests/bison --version >doc/bison.help.tmp LC_ALL=C tests/bison --help | \ sed -e 's,^Usage: .*/bison \[OPTION\],Usage: bison [OPTION],g' \ -e '/translation bugs/d' >>doc/bison.help.tmp ./build-aux/move-if-change doc/bison.help.tmp doc/bison.help make examples/c/calc/calc examples/c/glr/c++-types examples/c/lexcalc/lexcalc examples/c/mfcalc/mfcalc examples/c/pushcalc/calc examples/c/reccalc/reccalc examples/c/rpcalc/rpcalc examples/c++/calc++/calc++ examples/c++/glr/c++-types examples/c++/simple examples/c++/variant examples/c++/variant-11 ./tests/bison tests/atconfig tests/atlocal make[4]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' /bin/bash ./build-aux/ylwrap examples/c/calc/calc.y y.tab.c examples/c/calc/calc.c y.tab.h `echo examples/c/calc/calc.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/calc/calc.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines /bin/bash ./build-aux/ylwrap examples/c/glr/c++-types.y y.tab.c examples/c/glr/c++-types.c y.tab.h `echo examples/c/glr/c++-types.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/glr/c++-types.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines /bin/bash ./build-aux/ylwrap examples/c/lexcalc/parse.y y.tab.c examples/c/lexcalc/parse.c y.tab.h `echo examples/c/lexcalc/parse.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/lexcalc/parse.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines \ /bin/bash ./build-aux/ylwrap `test -f 'examples/c/lexcalc/scan.l' || echo './'`examples/c/lexcalc/scan.l lex.yy.c examples/c/lexcalc/scan.c -- flex /bin/bash ./build-aux/ylwrap examples/c/mfcalc/mfcalc.y y.tab.c examples/c/mfcalc/mfcalc.c y.tab.h `echo examples/c/mfcalc/mfcalc.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/mfcalc/mfcalc.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines /bin/bash ./build-aux/ylwrap examples/c/pushcalc/calc.y y.tab.c examples/c/pushcalc/calc.c y.tab.h `echo examples/c/pushcalc/calc.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/pushcalc/calc.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines /bin/bash ./build-aux/ylwrap examples/c/reccalc/parse.y y.tab.c examples/c/reccalc/parse.c y.tab.h `echo examples/c/reccalc/parse.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/reccalc/parse.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines /bin/bash ./build-aux/ylwrap examples/c/rpcalc/rpcalc.y y.tab.c examples/c/rpcalc/rpcalc.c y.tab.h `echo examples/c/rpcalc/rpcalc.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/rpcalc/rpcalc.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines rm -f examples/c++/calc++/parser.stamp touch examples/c++/calc++/parser.stamp.tmp ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines -o examples/c++/calc++/parser.cc examples/c++/calc++/parser.yy \ /bin/bash ./build-aux/ylwrap `test -f 'examples/c++/calc++/scanner.ll' || echo './'`examples/c++/calc++/scanner.ll lex.yy.c examples/c++/calc++/scanner.cc -- flex rm -f examples/c++/glr/c++-types.stamp touch examples/c++/glr/c++-types.stamp.tmp ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines -o examples/c++/glr/c++-types.cc examples/c++/glr/c++-types.yy \ /bin/bash ./build-aux/ylwrap `test -f 'examples/c++/simple.yy' || echo './'`examples/c++/simple.yy y.tab.c examples/c++/simple.cc y.tab.h `echo examples/c++/simple.cc | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c++/simple.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines updating examples/c/lexcalc/parse.output updating examples/c/calc/calc.output updating examples/c/mfcalc/mfcalc.output mv -f examples/c++/glr/c++-types.stamp.tmp examples/c++/glr/c++-types.stamp updating examples/c/glr/c++-types.output mv -f examples/c++/calc++/parser.stamp.tmp examples/c++/calc++/parser.stamp \ /bin/bash ./build-aux/ylwrap `test -f 'examples/c++/variant.yy' || echo './'`examples/c++/variant.yy y.tab.c examples/c++/variant.cc y.tab.h `echo examples/c++/variant.cc | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c++/variant.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines \ /bin/bash ./build-aux/ylwrap `test -f 'examples/c++/variant-11.yy' || echo './'`examples/c++/variant-11.yy y.tab.c examples/c++/variant-11.cc y.tab.h `echo examples/c++/variant-11.cc | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c++/variant-11.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines make[4]: 'tests/bison' is up to date. make[4]: Nothing to be done for 'tests/atconfig'. make[4]: 'tests/atlocal' is up to date. updating examples/c/calc/calc.h updating examples/c/lexcalc/parse.h updating examples/c/glr/c++-types.h updating examples/c/mfcalc/mfcalc.h gcc -DEXEEXT=\"\" -I./examples/c/calc -I./examples/c/calc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/calc/examples_c_calc_calc-calc.o `test -f 'examples/c/calc/calc.c' || echo './'`examples/c/calc/calc.c gcc -DEXEEXT=\"\" -I./examples/c/glr -I./examples/c/glr -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/glr/examples_c_glr_c___types-c++-types.o `test -f 'examples/c/glr/c++-types.c' || echo './'`examples/c/glr/c++-types.c gcc -DEXEEXT=\"\" -I./examples/c/lexcalc -I./examples/c/lexcalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/lexcalc/examples_c_lexcalc_lexcalc-parse.o `test -f 'examples/c/lexcalc/parse.c' || echo './'`examples/c/lexcalc/parse.c updating examples/c/pushcalc/calc.output gcc -DEXEEXT=\"\" -I./examples/c/lexcalc -I./examples/c/lexcalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/lexcalc/examples_c_lexcalc_lexcalc-scan.o `test -f 'examples/c/lexcalc/scan.c' || echo './'`examples/c/lexcalc/scan.c gcc -DEXEEXT=\"\" -I./examples/c/mfcalc -I./examples/c/mfcalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/mfcalc/examples_c_mfcalc_mfcalc-mfcalc.o `test -f 'examples/c/mfcalc/mfcalc.c' || echo './'`examples/c/mfcalc/mfcalc.c g++ -DEXEEXT=\"\" -I./examples/c++/calc++ -I./examples/c++/calc++ -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/calc++/calc__-driver.o `test -f 'examples/c++/calc++/driver.cc' || echo './'`examples/c++/calc++/driver.cc updating examples/c/reccalc/parse.output updating examples/c/pushcalc/calc.h g++ -DEXEEXT=\"\" -I./examples/c++/calc++ -I./examples/c++/calc++ -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/calc++/calc__-scanner.o `test -f 'examples/c++/calc++/scanner.cc' || echo './'`examples/c++/calc++/scanner.cc updating examples/c/rpcalc/rpcalc.output updating examples/c/reccalc/parse.h g++ -DEXEEXT=\"\" -I./examples/c++/calc++ -I./examples/c++/calc++ -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/calc++/calc__-calc++.o `test -f 'examples/c++/calc++/calc++.cc' || echo './'`examples/c++/calc++/calc++.cc updating examples/c/rpcalc/rpcalc.h g++ -DEXEEXT=\"\" -I./examples/c++/calc++ -I./examples/c++/calc++ -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/calc++/calc__-parser.o `test -f 'examples/c++/calc++/parser.cc' || echo './'`examples/c++/calc++/parser.cc updating examples/c++/simple.output updating examples/c++/simple.hh updating examples/c++/variant.output g++ -DEXEEXT=\"\" -I./examples/c++/glr -I./examples/c++/glr -Wdate-time -D_FORTIFY_SOURCE=2 -std=c++14 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/glr/examples_c___glr_c___types-c++-types.o `test -f 'examples/c++/glr/c++-types.cc' || echo './'`examples/c++/glr/c++-types.cc updating examples/c++/variant-11.output g++ -DEXEEXT=\"\" -I. -Wdate-time -D_FORTIFY_SOURCE=2 -std=c++11 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/simple-simple.o `test -f 'examples/c++/simple.cc' || echo './'`examples/c++/simple.cc updating examples/c++/variant.hh gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/calc/calc examples/c/calc/examples_c_calc_calc-calc.o gcc -DEXEEXT=\"\" -I./examples/c/pushcalc -I./examples/c/pushcalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/pushcalc/examples_c_pushcalc_calc-calc.o `test -f 'examples/c/pushcalc/calc.c' || echo './'`examples/c/pushcalc/calc.c gcc -DEXEEXT=\"\" -I./examples/c/reccalc -I./examples/c/reccalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/reccalc/examples_c_reccalc_reccalc-parse.o `test -f 'examples/c/reccalc/parse.c' || echo './'`examples/c/reccalc/parse.c gcc -DEXEEXT=\"\" -I./examples/c/reccalc -I./examples/c/reccalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/reccalc/examples_c_reccalc_reccalc-scan.o `test -f 'examples/c/reccalc/scan.c' || echo './'`examples/c/reccalc/scan.c updating examples/c++/variant-11.hh gcc -DEXEEXT=\"\" -I./examples/c/rpcalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/rpcalc/examples_c_rpcalc_rpcalc-rpcalc.o `test -f 'examples/c/rpcalc/rpcalc.c' || echo './'`examples/c/rpcalc/rpcalc.c g++ -DEXEEXT=\"\" -I. -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/variant-variant.o `test -f 'examples/c++/variant.cc' || echo './'`examples/c++/variant.cc g++ -DEXEEXT=\"\" -I. -Wdate-time -D_FORTIFY_SOURCE=2 -std=c++11 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/variant_11-variant-11.o `test -f 'examples/c++/variant-11.cc' || echo './'`examples/c++/variant-11.cc gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/lexcalc/lexcalc examples/c/lexcalc/examples_c_lexcalc_lexcalc-parse.o examples/c/lexcalc/examples_c_lexcalc_lexcalc-scan.o gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/mfcalc/mfcalc examples/c/mfcalc/examples_c_mfcalc_mfcalc-mfcalc.o -lm gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/reccalc/reccalc examples/c/reccalc/examples_c_reccalc_reccalc-parse.o examples/c/reccalc/examples_c_reccalc_reccalc-scan.o gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/rpcalc/rpcalc examples/c/rpcalc/examples_c_rpcalc_rpcalc-rpcalc.o -lm gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/pushcalc/calc examples/c/pushcalc/examples_c_pushcalc_calc-calc.o gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/glr/c++-types examples/c/glr/examples_c_glr_c___types-c++-types.o g++ -std=c++11 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c++/simple examples/c++/simple-simple.o g++ -std=c++11 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c++/variant-11 examples/c++/variant_11-variant-11.o g++ -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c++/calc++/calc++ examples/c++/calc++/calc__-driver.o examples/c++/calc++/calc__-scanner.o examples/c++/calc++/calc__-calc++.o examples/c++/calc++/calc__-parser.o g++ -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c++/variant examples/c++/variant-variant.o g++ -std=c++14 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c++/glr/c++-types examples/c++/glr/examples_c___glr_c___types-c++-types.o make[4]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make check-TESTS check-local make[4]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' make all-recursive make[5]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' rm -f tests/package.m4 tests/package.m4.tmp { \ echo '# Signature of the current package.'; \ echo 'm4_define([AT_PACKAGE_NAME], [GNU Bison])'; \ echo 'm4_define([AT_PACKAGE_TARNAME], [bison])'; \ echo 'm4_define([AT_PACKAGE_VERSION], [3.8.2])'; \ echo 'm4_define([AT_PACKAGE_STRING], [GNU Bison 3.8.2])'; \ echo 'm4_define([AT_PACKAGE_BUGREPORT], [bug-bison@gnu.org])'; \ } >tests/package.m4.tmp mv tests/package.m4.tmp tests/package.m4 \ /bin/bash '/build/reproducible-path/bison-3.8.2+dfsg/build-aux/missing' autom4te --language=autotest -I ./tests ./tests/testsuite.at -o tests/testsuite.tmp make[5]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' Making all in po make[6]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/po' make[6]: Nothing to be done for 'all'. make[6]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/po' Making all in runtime-po make[6]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' make[6]: Nothing to be done for 'all'. make[6]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' Making all in gnulib-po make[6]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' make[6]: Nothing to be done for 'all'. make[6]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' Making all in . make[6]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' /usr/bin/mkdir -p doc LC_ALL=C tests/bison --version >doc/bison.help.tmp LC_ALL=C tests/bison --help | \ sed -e 's,^Usage: .*/bison \[OPTION\],Usage: bison [OPTION],g' \ -e '/translation bugs/d' >>doc/bison.help.tmp ./build-aux/move-if-change doc/bison.help.tmp doc/bison.help make[6]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[5]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' PASS: examples/c/glr/c++-types.test PASS: examples/c++/simple.test PASS: examples/c++/glr/c++-types.test PASS: examples/c++/variant.test PASS: examples/c++/variant-11.test PASS: examples/c/mfcalc/mfcalc.test PASS: examples/c/rpcalc/rpcalc.test PASS: examples/c/calc/calc.test PASS: examples/c/lexcalc/lexcalc.test PASS: examples/c/pushcalc/calc.test PASS: examples/c++/calc++/calc++.test PASS: examples/c/reccalc/reccalc.test ============================================================================ Testsuite summary for GNU Bison 3.8.2 ============================================================================ # TOTAL: 12 # PASS: 12 # SKIP: 0 # XFAIL: 0 # FAIL: 0 # XPASS: 0 # ERROR: 0 ============================================================================ make[5]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' "/usr/bin/perl" -pi -e 's/\@tb\@/\t/g' tests/testsuite.tmp mv tests/testsuite.tmp tests/testsuite /bin/bash ./tests/testsuite -C tests -j12 --verbose ## --------------------------- ## ## GNU Bison 3.8.2 test suite. ## ## --------------------------- ## 1. m4.at:21: testing Generating Comments ... 2. input.at:27: testing Invalid number of arguments ... ./input.at:29: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 6. input.at:173: testing Yacc warnings on symbols ... 9. input.at:287: testing Invalid symbol declarations ... ./input.at:34: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y 2.y ./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wyacc input.y ./m4.at:53: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -S ./input.m4 input.y ./input.at:304: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y 12. input.at:427: testing Symbol declarations ... 7. input.at:204: testing Yacc warnings ... 5. input.at:147: testing Invalid inputs with {} ... ./input.at:162: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 3. input.at:58: testing Invalid options ... ./input.at:67: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -ferror=caret input.y 10. input.at:341: testing Redefining the error token ... ./input.at:354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:467: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S./dump-symbols.m4 input.y ./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wyacc input.y 4. input.at:83: testing Invalid inputs ... ./input.at:97: "$PERL" -pi -e 's/\\(\d{3})/chr(oct($1))/ge' input.y || exit 77 11. input.at:401: testing Dangling aliases ... ./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wdangling input.y stderr: 9. input.at:287: ok ./input.at:390: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 8. input.at:238: testing Yacc's %type ... 5. input.at:147: ok ./input.at:42: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --skeleton bison: invalid argument 'error=caret' for '--feature' Valid arguments are: - 'none' - 'caret', 'diagnostics-show-caret' - 'fixit', 'diagnostics-parseable-fixits' - 'syntax-only' - 'all' ./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wyacc input.y ./input.at:99: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:68: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=error=itemsets input.y ./m4.at:55: cat output.txt stderr: bison: option '--skeleton' requires an argument Try 'bison --help' for more information. ./input.at:43: sed -e \ "s/requires an argument -- skeleton/'--skeleton' requires an argument/" \ stderr ./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wdangling input.y -Werror stderr: bison: invalid argument 'error=itemsets' for '--report' Valid arguments are: - 'none' - 'states' - 'itemsets' - 'lookaheads' - 'solved' - 'counterexamples', 'cex' - 'all' 1. m4.at:21: ./input.at:72: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror?all input.y ok stderr: stderr: bison: invalid argument 'error?all' for '--warning' Valid arguments are: - 'all' - 'conflicts-rr' - 'conflicts-sr' - 'counterexamples', 'cex' - 'dangling-alias' - 'deprecated' - 'empty-rule' - 'everything' - 'midrule-values' - 'none' - 'other' - 'precedence' - 'yacc' input.y:1.11: error: invalid null character 1 | %header "ð€ˆ" | ^ input.y:2.1-2: error: invalid characters: '\0\001\002\377?' 2 | ÿ? | ^~ input.y:3.2: error: invalid null character 3 | "" | ^ input.y:5.1: error: invalid character: '?' 5 | ? | ^ input.y:6.14: error: invalid character: '}' 6 | default: 'a' } | ^ input.y:7.1: error: invalid character: '%' 7 | %& | ^ input.y:7.2: error: invalid character: '&' 7 | %& | ^ input.y:8.1-17: error: invalid directive: '%a-does-not-exist' 8 | %a-does-not-exist | ^~~~~~~~~~~~~~~~~ input.y:9.1: error: invalid character: '%' 9 | %- | ^ input.y:9.2: error: invalid character: '-' 9 | %- | ^ input.y:10.1-11.0: error: missing '%}' at end of file 10 | %{ | ^~ ./input.at:104: "$PERL" -p -e 's{([\0\200\210\360\377])}{sprintf "\\x%02x", ord($1)}ge' stderr ./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Werror 3. input.at:58: ok ./input.at:468: cat symbols.csv ./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Werror 2. input.at:27: ok ./input.at:390: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 13. input.at:528: testing Invalid $n and @n ... 14. input.at:552: testing Type Clashes ... ./input.at:565: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:536: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y 12. input.at:427: stderr: ok input.y:2.13-17: error: string literal "bar" not attached to a symbol [-Werror=dangling-alias] 2 | %type "bar" | ^~~~~ input.y:4.19-23: error: string literal "baz" not attached to a symbol [-Werror=dangling-alias] 4 | expr: "foo" "bar" "baz" | ^~~~~ 14. input.at:552: ok 4. input.at:83: ok 15. input.at:774: testing Unused values ... 13. input.at:528: ok stderr: input.y:1.1-11: error: POSIX Yacc does not support %destructor [-Werror=yacc] 1 | %destructor {} | ^~~~~~~~~~~ input.y:2.1-8: error: POSIX Yacc does not support %printer [-Werror=yacc] 2 | %printer {} | ^~~~~~~~ input.y:6.9-20: error: POSIX Yacc does not support typed midrule actions [-Werror=yacc] 6 | a: { $$ = 42; } { $$ = $1; }; | ^~~~~~~~~~~~ input.y:7.4-9: error: POSIX Yacc does not support %empty [-Werror=yacc] 7 | b: %empty { $$ = 42; }; | ^~~~~~ ./input.at:410: sed 's,.*/$,,' stderr 1>&2 stderr: ./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y input.y:1.1-6: error: POSIX Yacc does not support %nterm [-Werror=yacc] 1 | %nterm exp | ^~~~~~ input.y:2.12-15: error: POSIX Yacc does not support hexadecimal literals [-Werror=yacc] 2 | %token NUM 0x40 "number" | ^~~~ input.y:2.17-24: error: POSIX Yacc does not support string literals [-Werror=yacc] 2 | %token NUM 0x40 "number" | ^~~~~~~~ input.y:4.6-13: error: POSIX Yacc does not support string literals [-Werror=yacc] 4 | exp: "number"; | ^~~~~~~~ ./input.at:216: sed 's,.*/$,,' stderr 1>&2 ./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Werror ./input.at:182: sed 's,.*/$,,' stderr 1>&2 16. input.at:784: testing Unused values before symbol declarations ... 17. input.at:794: testing Symbol redeclared ... ./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=error 18. input.at:832: testing EOF redeclared ... ./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y 19. input.at:859: testing Symbol class redefinition ... stderr: ./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wdangling input.y --warnings=error ./input.at:871: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y input.y:2.1-6: error: POSIX Yacc does not support %nterm [-Werror=yacc] 2 | %nterm nterm1 | ^~~~~~ input.y:3.14-19: error: POSIX yacc reserves %type to nonterminals [-Werror=yacc] 3 | %type TOKEN1 TOKEN2 "TOKEN3" nterm1 nterm2 nterm3 '+' | ^~~~~~ input.y:3.28-35: error: POSIX Yacc does not support string literals [-Werror=yacc] 3 | %type TOKEN1 TOKEN2 "TOKEN3" nterm1 nterm2 nterm3 '+' | ^~~~~~~~ input.y:3.28-35: error: POSIX yacc reserves %type to nonterminals [-Werror=yacc] 3 | %type TOKEN1 TOKEN2 "TOKEN3" nterm1 nterm2 nterm3 '+' | ^~~~~~~~ input.y:3.58-60: error: POSIX yacc reserves %type to nonterminals [-Werror=yacc] 3 | %type TOKEN1 TOKEN2 "TOKEN3" nterm1 nterm2 nterm3 '+' | ^~~ input.y:5.1-6: error: POSIX Yacc does not support %nterm [-Werror=yacc] 5 | %nterm nterm2 | ^~~~~~ input.y:3.21-26: error: POSIX yacc reserves %type to nonterminals [-Werror=yacc] 3 | %type TOKEN1 TOKEN2 "TOKEN3" nterm1 nterm2 nterm3 '+' | ^~~~~~ input.y:10.9-16: error: POSIX Yacc does not support string literals [-Werror=yacc] 10 | nterm3: "TOKEN3" | ^~~~~~~~ 20. input.at:899: testing Default %printer and %destructor redeclared ... ./input.at:959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=error ./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror ./input.at:253: sed 's,.*/$,,' stderr 1>&2 21. input.at:970: testing Per-type %printer and %destructor redeclared ... ./input.at:987: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:960: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror 19. input.at:859: ok ./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror stderr: stdout: ./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Wnone,none -Werror --trace=none ./input.at:391: $PREPARSER ./input ./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Wnone,none -Werror --trace=none 21. input.at:970: ok ./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wdangling input.y -Wnone,none -Werror --trace=none stderr: 20. input.at:899: stderr: ok ./input.at:391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror input.y:1.12-14: error: symbol FOO redeclared [-Werror=other] 1 | %token FOO FOO | ^~~ input.y:1.8-10: note: previous declaration 1 | %token FOO FOO | ^~~ input.y:2.15-17: error: symbol BAR redeclared [-Werror=other] 2 | %token BAR 12 BAR 12 | ^~~ input.y:2.8-10: note: previous declaration 2 | %token BAR 12 BAR 12 | ^~~ input.y:3.14-16: error: symbol EOF redeclared [-Werror=other] 3 | %token EOF 0 EOF 0 | ^~~ input.y:3.8-10: note: previous declaration 3 | %token EOF 0 EOF 0 | ^~~ ./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=error stderr: ./input.at:804: sed 's,.*/$,,' stderr 1>&2 ./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=none -Werror --trace=none input.y:1.16-18: error: symbol FOO redeclared [-Werror=other] 1 | %token FOO BAR FOO 0 | ^~~ input.y:1.8-10: note: previous declaration 1 | %token FOO BAR FOO 0 | ^~~ 10. input.at:341: ok ./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wdangling input.y --warnings=none -Werror --trace=none ./input.at:843: sed 's,.*/$,,' stderr 1>&2 23. input.at:1045: testing Unassociated types used for a printer or destructor ... ./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y 22. input.at:1013: testing Undefined symbols ... ./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=none -Werror --trace=none stderr: input.y:12.10-32: error: unset value: $$ [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~ input.y:12.10-12: error: unused value: $1 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.18-20: error: unused value: $3 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.26-28: error: unused value: $5 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:13.10-15: error: empty rule for typed nonterminal, and no action [-Werror=other] 13 | b: INT | %empty; | ^~~~~~ input.y:14.10-62: error: unset value: $$ [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:14.22-24: error: unused value: $3 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:14.43-45: error: unused value: $5 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:15.10-49: error: unset value: $$ [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:15.18-20: error: unused value: $3 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:15.30-32: error: unused value: $5 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:16.10-37: error: unset value: $$ [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:16.18-20: error: unused value: $3 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:16.27-29: error: unused value: $5 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:18.10-58: error: unset value: $$ [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:18.10-12: error: unused value: $1 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.31-33: error: unused value: $3 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.52-54: error: unused value: $5 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:19.10-72: error: unset value: $$ [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:19.10-12: error: unused value: $1 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.31-33: error: unused value: $3 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.66-68: error: unused value: $5 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:22.10-68: error: unset value: $$ [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:22.10-12: error: unused value: $1 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:22.14-16: error: unused value: $2 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:25.23-25: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.10-50: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:25.10-12: error: unused value: $1 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.23-25: error: unused value: $2 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.27-29: error: unused value: $3 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unused value: $4 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.44-46: error: unused value: $5 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:26.23-25: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ input.y:26.40-42: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ ./input.at:1023: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error 11. input.at:401: ./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Wnone,none -Werror --trace=none ok ./input.at:775: sed 's,.*/$,,' stderr 1>&2 24. input.at:1074: testing Useless printers or destructors ... ./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y 22. input.at:1013: ok ./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error 25. input.at:1139: testing Unused values with default %destructor ... ./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror stderr: 6. input.at:173: ok input.y:12.10-32: error: unset value: $$ [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~ input.y:12.10-12: error: unused value: $1 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.18-20: error: unused value: $3 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.26-28: error: unused value: $5 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:13.10-15: error: empty rule for typed nonterminal, and no action [-Werror=other] 13 | b: INT | %empty; | ^~~~~~ input.y:14.10-62: error: unset value: $$ [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:14.22-24: error: unused value: $3 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:14.43-45: error: unused value: $5 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:15.10-49: error: unset value: $$ [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:15.18-20: error: unused value: $3 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:15.30-32: error: unused value: $5 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:16.10-37: error: unset value: $$ [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:16.18-20: error: unused value: $3 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:16.27-29: error: unused value: $5 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:18.10-58: error: unset value: $$ [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:18.10-12: error: unused value: $1 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.31-33: error: unused value: $3 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.52-54: error: unused value: $5 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:19.10-72: error: unset value: $$ [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:19.10-12: error: unused value: $1 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.31-33: error: unused value: $3 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.66-68: error: unused value: $5 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:22.10-68: error: unset value: $$ [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:22.10-12: error: unused value: $1 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:22.14-16: error: unused value: $2 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:25.23-25: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.10-50: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:25.10-12: error: unused value: $1 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.23-25: error: unused value: $2 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.27-29: error: unused value: $3 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unused value: $4 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.44-46: error: unused value: $5 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:26.23-25: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ input.y:26.40-42: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ ./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=none -Werror --trace=none ./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none 7. input.at:204: ok ./input.at:785: sed 's,.*/$,,' stderr 1>&2 ./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror ./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror stderr: 26. input.at:1187: testing Unused values with per-type %destructor ... ./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y 27. input.at:1219: testing Duplicate string ... ./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y input.y:4.22-28: error: type is used, but is not associated to any symbol [-Werror=other] input.y:5.25-31: error: type is used, but is not associated to any symbol [-Werror=other] 28. input.at:1247: testing Token collisions ... ./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error 8. input.at:238: ok ./input.at:1256: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:1062: sed 's,.*/$,,' stderr 1>&2 ./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror stderr: ./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none input.y:6.8-45: error: unset value: $$ [-Werror=other] 6 | start: end end tagged tagged { $1; $3; } ; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:6.12-14: error: unused value: $2 [-Werror=other] 6 | start: end end tagged tagged { $1; $3; } ; | ^~~ input.y:7.6-8: error: unset value: $$ [-Werror=other] 7 | end: { } ; | ^~~ stderr: 28. input.at:1247: ./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ok ./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error input.y:16.13-19: error: useless %printer for type [-Werror=other] input.y:17.16-22: error: useless %destructor for type [-Werror=other] ./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -o input.c input.y -Werror ./input.at:1152: sed 's,.*/$,,' stderr 1>&2 29. input.at:1275: testing Incompatible Aliases ... ./input.at:1285: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y stderr: input.y:6.8-22: error: unset value: $$ [-Werror=other] 6 | start: end end { $1; } ; | ^~~~~~~~~~~~~~~ input.y:6.12-14: error: unused value: $2 [-Werror=other] 6 | start: end end { $1; } ; | ^~~ input.y:7.6-8: error: unset value: $$ [-Werror=other] 7 | end: { } ; | ^~~ 30. input.at:1400: testing Torturing the Scanner ... ./input.at:1407: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1085: sed 's,.*/$,,' stderr 1>&2 18. input.at:832: ok ./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none ./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error ./input.at:1299: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1199: sed 's,.*/$,,' stderr 1>&2 ./input.at:1554: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -v -o input.c input.y 17. input.at:794: ok stderr: input.y:6.11-14: error: symbol "<=" used more than once as a literal string [-Werror=other] ./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none 32. input.at:1609: testing Require 1.0 ... ./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none ./input.at:1609: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./input.at:1313: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y 31. input.at:1569: testing Typed symbol aliases ... ./input.at:1586: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./input.at:1236: sed 's,.*/$,,' stderr 1>&2 ./input.at:1327: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:1555: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none 33. input.at:1610: testing Require 3.8.2 ... stderr: ./input.at:1610: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -o input.c input.y --warnings=error 32. input.at:1609: ok stderr: 23. input.at:1045: ok 31. input.at:1569: ok ./input.at:1344: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none 33. input.at:1610: ok ./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y ./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./input.at:1359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y ./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -o input.c input.y -Wnone,none -Werror --trace=none stderr: 34. input.at:1612: testing Require 100.0 ... ./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror ./input.at:1612: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y ./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y stdout: 35. input.at:1619: testing String aliases for character tokens ... ./input.at:1632: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./input.at:1374: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1556: $CC $CFLAGS $CPPFLAGS -c -o main.o main.c 26. input.at:1187: ok 36. input.at:1642: testing Symbols ... ./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --yacc input.y ./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -o input.c input.y --warnings=none -Werror --trace=none 37. input.at:1708: testing Numbered tokens ... stderr: input.y:3.13-14: error: useless %printer for type <> [-Werror=other] 29. input.at:1275: stderr: ok ./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror ./input.at:1720: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret redecl.y input.y:9.10-16: error: require bison 100.0, but have 3.8.2 34. input.at:1612: 35. input.at:1619: ok ./input.at:1116: sed 's,.*/$,,' stderr 1>&2 ok stderr: stdout: ./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error ./input.at:1735: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret too-large.y ./input.at:1557: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.o main.o $LIBS ./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y ./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --yacc input.y -Werror stderr: input.y:6.23-28: error: unused value: $4 [-Werror=other] input.y:8.9-11: error: unset value: $$ [-Werror=other] 37. input.at:1708: ok stderr: stdout: 39. input.at:1805: testing %start after first rule ... ./input.at:1817: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./input.at:1558: $PREPARSER ./input 41. input.at:1895: testing %prec takes a token ... ./input.at:1905: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: 27. input.at:1219: ok ./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none 41. input.at:1895: ./input.at:1175: sed 's,.*/$,,' stderr 1>&2 ok stderr: 40. input.at:1826: testing Duplicate %start symbol ... ./input.at:1558: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input.y:1.1-5: error: POSIX Yacc does not support %code [-Werror=yacc] input.y:9.8-16: error: POSIX Yacc forbids dashes in symbol names: WITH-DASH [-Werror=yacc] input.y:10.21-34: error: POSIX Yacc does not support string literals [-Werror=yacc] input.y:12.23-38: error: POSIX Yacc does not support string literals [-Werror=yacc] input.y:13.1-5: error: POSIX Yacc does not support %code [-Werror=yacc] input.y:20.8-16: error: POSIX Yacc forbids dashes in symbol names: with-dash [-Werror=yacc] input.y:22.15-28: error: POSIX Yacc does not support string literals [-Werror=yacc] input.y:24.17-32: error: POSIX Yacc does not support string literals [-Werror=yacc] 38. input.at:1750: testing Unclosed constructs ... ./input.at:1779: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y ./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error 30. input.at:1400: ok 39. input.at:1805: ok ./input.at:1666: sed 's,.*/$,,' stderr 1>&2 ./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -Werror 38. input.at:1750: ok 43. input.at:1936: testing Reject unused %code qualifiers ... ./input.at:1946: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-c.y ./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror ./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --yacc input.y --warnings=error 42. input.at:1916: testing %prec's token must be defined ... ./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none stderr: ./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y 45. input.at:2065: testing errors ... ./input.at:2077: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-redefined.y ./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -Werror ./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none input.y:1.12-14: error: duplicate directive [-Werror=other] 1 | %start exp exp exp | ^~~ input.y:1.8-10: note: previous declaration 1 | %start exp exp exp | ^~~ input.y:1.16-18: error: duplicate directive [-Werror=other] 1 | %start exp exp exp | ^~~ input.y:1.8-10: note: previous declaration 1 | %start exp exp exp | ^~~ input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] 44. input.at:2025: testing Multiple %code ... ./input.at:2054: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 46. input.at:2102: testing %define, --define, --force-define ... ./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --yacc input.y -Wnone,none -Werror --trace=none ./input.at:1960: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-c-glr.y ./input.at:2091: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-unused.y ./input.at:2118: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dvar-dd=cmd-d1 -Dvar-dd=cmd-d2 \ -Fvar-ff=cmd-f1 -Fvar-ff=cmd-f2 \ -Dvar-dfg=cmd-d -Fvar-dfg=cmd-f \ -Fvar-fd=cmd-f -Dvar-fd=cmd-d \ --skeleton ./skel.c input.y ./input.at:1836: sed 's,.*/$,,' stderr 1>&2 ./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror ./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none 47. input.at:2170: testing "%define" Boolean variables ... ./input.at:2054: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./input.at:2180: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret Input.y ./input.at:2123: cat input.tab.c ./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y stderr: 45. input.at:2065: ok input.y:12.10-32: error: unset value: $$ [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~ input.y:12.10-12: error: unused value: $1 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.18-20: error: unused value: $3 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.26-28: error: unused value: $5 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:13.10-15: error: empty rule for typed nonterminal, and no action [-Werror=other] 13 | b: INT | %empty; | ^~~~~~ input.y:14.14-20: error: unset value: $$ [-Werror=midrule-values] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~ input.y:14.26-41: error: unset value: $$ [-Werror=midrule-values] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~~~~~~~~~~ input.y:14.10-62: error: unset value: $$ [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:14.22-24: error: unused value: $3 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:14.43-45: error: unused value: $5 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:15.14-16: error: unset value: $$ [-Werror=midrule-values] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:15.10-49: error: unset value: $$ [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:15.18-20: error: unused value: $3 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:15.30-32: error: unused value: $5 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:16.10-37: error: unset value: $$ [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:16.18-20: error: unused value: $3 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:16.27-29: error: unused value: $5 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:18.10-58: error: unset value: $$ [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:18.10-12: error: unused value: $1 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.14-29: error: unused value: $2 [-Werror=midrule-values] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~ input.y:18.31-33: error: unused value: $3 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.35-50: error: unused value: $4 [-Werror=midrule-values] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~ input.y:18.52-54: error: unused value: $5 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:19.10-72: error: unset value: $$ [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:19.10-12: error: unused value: $1 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.31-33: error: unused value: $3 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.35-64: error: unused value: $4 [-Werror=midrule-values] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:19.66-68: error: unused value: $5 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:21.18-37: error: unused value: $3 [-Werror=midrule-values] 21 | j: INT | INT INT { $$ = 1; } { $$ = $1 + $2; }; | ^~~~~~~~~~~~~~~~~~~~ input.y:22.10-68: error: unset value: $$ [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:22.10-12: error: unused value: $1 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:22.14-16: error: unused value: $2 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:22.35-64: error: unused value: $4 [-Werror=midrule-values] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:25.23-25: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.10-50: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:25.10-12: error: unused value: $1 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.23-25: error: unused value: $2 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.27-29: error: unused value: $3 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unused value: $4 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.44-46: error: unused value: $5 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:26.23-25: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ input.y:26.40-42: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ ./input.at:2135: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dvar=cmd-d input-dg.y ./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./input.at:2146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Dvar=cmd-d input-dg.y ./input.at:776: sed 's,.*/$,,' stderr 1>&2 stderr: input.y:12.10-32: error: unset value: $$ [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~ input.y:12.10-12: error: unused value: $1 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.18-20: error: unused value: $3 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.26-28: error: unused value: $5 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:13.10-15: error: empty rule for typed nonterminal, and no action [-Werror=other] 13 | b: INT | %empty; | ^~~~~~ input.y:14.14-20: error: unset value: $$ [-Werror=midrule-values] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~ input.y:14.26-41: error: unset value: $$ [-Werror=midrule-values] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~~~~~~~~~~ input.y:14.10-62: error: unset value: $$ [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:14.22-24: error: unused value: $3 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:14.43-45: error: unused value: $5 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:15.14-16: error: unset value: $$ [-Werror=midrule-values] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:15.10-49: error: unset value: $$ [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:15.18-20: error: unused value: $3 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:15.30-32: error: unused value: $5 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:16.10-37: error: unset value: $$ [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:16.18-20: error: unused value: $3 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:16.27-29: error: unused value: $5 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:18.10-58: error: unset value: $$ [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:18.10-12: error: unused value: $1 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.14-29: error: unused value: $2 [-Werror=midrule-values] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~ input.y:18.31-33: error: unused value: $3 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.35-50: error: unused value: $4 [-Werror=midrule-values] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~ input.y:18.52-54: error: unused value: $5 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:19.10-72: error: unset value: $$ [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:19.10-12: error: unused value: $1 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.31-33: error: unused value: $3 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.35-64: error: unused value: $4 [-Werror=midrule-values] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:19.66-68: error: unused value: $5 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:21.18-37: error: unused value: $3 [-Werror=midrule-values] 21 | j: INT | INT INT { $$ = 1; } { $$ = $1 + $2; }; | ^~~~~~~~~~~~~~~~~~~~ input.y:22.10-68: error: unset value: $$ [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:22.10-12: error: unused value: $1 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:22.14-16: error: unused value: $2 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:22.35-64: error: unused value: $4 [-Werror=midrule-values] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:25.23-25: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.10-50: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:25.10-12: error: unused value: $1 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.23-25: error: unused value: $2 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.27-29: error: unused value: $3 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unused value: $4 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.44-46: error: unused value: $5 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:26.23-25: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ input.y:26.40-42: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ ./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --yacc input.y --warnings=none -Werror --trace=none 25. input.at:1139: ok stderr: input.y:2.8-17: error: token for %prec is not defined: PREC [-Werror=other] ./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y --warnings=error ./input.at:2158: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dunused-d -Funused-f input-unused.y ./input.at:786: sed 's,.*/$,,' stderr 1>&2 ./input.at:1925: sed 's,.*/$,,' stderr 1>&2 ./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror 47. input.at:2170: ok ./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y --warnings=error 48. input.at:2191: testing "%define" code variables ... ./input.at:1973: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-c++.y ./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error ./input.at:1678: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.yy 49. input.at:2224: testing "%define" keyword variables ... stderr: ./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y 46. input.at:2102: ok input.y:2.16-18: error: useless %printer for type <*> [-Werror=other] ./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none 50. input.at:2257: testing "%define" enum variables ... ./input.at:2269: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1681: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./input.at:2284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y stderr: ./input.at:1124: sed 's,.*/$,,' stderr 1>&2 ./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./input.at:2303: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y stdout: ./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./input.at:2055: $PREPARSER ./input stderr: ./input.at:1986: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-c++-glr.y ./input.at:2055: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror ./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy -Werror ./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error 44. input.at:2025: ok stderr: 51. input.at:2320: testing "%define" file variables ... ./input.at:2329: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y stdout: 42. input.at:1916: ok ./input.at:1694: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y ./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y --warnings=none -Werror --trace=none stderr: ./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -Wnone,none -Werror --trace=none input.y:5.1-40: error: %define variable 'lr.type' requires keyword values [-Werror=deprecated] input.y:3.1-40: error: %define variable 'lr.default-reduction' requires keyword values [-Werror=deprecated] input.y:4.1-40: error: %define variable 'lr.keep-unreachable-state' requires keyword values [-Werror=deprecated] input.y:1.1-38: error: %define variable 'api.pure' requires keyword values [-Werror=deprecated] input.y:2.1-40: error: %define variable 'api.push-pull' requires keyword values [-Werror=deprecated] 36. input.at:1642: 50. input.at:2257: ok ok ./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror ./input.at:2246: sed 's,.*/$,,' stderr 1>&2 51. input.at:2320: ./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none ok 52. input.at:2342: testing "%define" backward compatibility ... stderr: input.y:1.16-18: error: duplicate directive [-Werror=other] 1 | %start exp foo exp | ^~~ input.y:1.8-10: note: previous declaration 1 | %start exp foo exp | ^~~ input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ./input.at:2355: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1999: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret special-char-@@.y ./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error 53. input.at:2393: testing Unused api.pure ... 54. input.at:2429: testing C++ namespace reference errors ... ./input.at:2450: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 55. input.at:2482: testing Bad character literals ... ./input.at:2484: set x `LC_ALL=C ls -l 'empty.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='empty.y'; } || exit 77 ./input.at:1859: sed 's,.*/$,,' stderr 1>&2 ./input.at:2413: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: 0+0 records in 0+0 records out 0 bytes copied, 2.724e-05 s, 0.0 kB/s ./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y --warnings=none -Werror --trace=none stdout: 52. input.at:2342: ok ./input.at:2490: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret empty.y ./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error 56. input.at:2543: testing Bad escapes in literals ... stderr: input.yy:2.1-30: error: %define variable 'api.location.type' requires '{...}' values [-Werror=deprecated] input.yy:4.1-30: error: %define variable 'api.prefix' requires '{...}' values [-Werror=deprecated] input.yy:5.1-30: error: %define variable 'api.token.prefix' requires '{...}' values [-Werror=deprecated] input.yy:3.1-30: error: %define variable 'api.namespace' requires '{...}' values [-Werror=deprecated] ./input.at:2508: set x `LC_ALL=C ls -l 'two.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='two.y'; } || exit 77 ./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none 15. input.at:774: ok ./input.at:2556: "$PERL" -e 'print "start: \"\\\t\\\f\\\0\\\1\" ;";' >> input.y || exit 77 ./input.at:2452: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2558: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:2414: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2213: sed 's,.*/$,,' stderr 1>&2 56. input.at:2543: ok stderr: 57. input.at:2582: testing Unexpected end of file ... ./input.at:2586: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y 24. input.at:1074: ok ./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy --warnings=error 0+0 records in 0+0 records out 0 bytes copied, 2.388e-05 s, 0.0 kB/s ./input.at:2012: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret special-char-].y stdout: ./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./input.at:2514: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret two.y ./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none 58. input.at:2675: testing LAC: Errors for %define ... ./input.at:2591: set x `LC_ALL=C ls -l 'char.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='char.y'; } || exit 77 ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Syacc.c -Dparse.lac=none input.y ./input.at:2415: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2522: set x `LC_ALL=C ls -l 'three.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='three.y'; } || exit 77 ./input.at:2454: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Syacc.c -Dparse.lac=full input.y 59. input.at:2719: testing -Werror combinations ... 60. input.at:2764: testing %name-prefix and api.prefix are incompatible ... ./input.at:2779: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-deprecated input.y 0+0 records in 0+0 records out 0 bytes copied, 2.848e-05 s, 0.0 kB/s stdout: ./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y ./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall input.y stderr: 16. input.at:784: ./input.at:2594: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret char.y 0+0 records in 0+0 records out 0 bytes copied, 2.512e-05 s, 0.0 kB/s ok stdout: ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Syacc.c -Dparse.lac=unsupported input.y ./input.at:2528: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret three.y ./input.at:2416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2780: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dapi.prefix={foo} -p bar -Wno-deprecated input.y 43. input.at:1936: ok ./input.at:2604: set x `LC_ALL=C ls -l 'escape-in-char.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='escape-in-char.y'; } || exit 77 ./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./input.at:2456: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 55. input.at:2482: ok ./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y -Werror ./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy -Wnone,none -Werror --trace=none stderr: 0+0 records in 0+0 records out 0 bytes copied, 2.648e-05 s, 0.0 kB/s stdout: ./input.at:2781: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dapi.prefix={foo} -Wno-deprecated input.y ./input.at:2607: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret escape-in-char.y 61. input.at:2793: testing Redefined %union name ... ./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y stderr: input.y:2.15: error: stray '$' [-Werror=other] 62. input.at:2840: testing Stray $ or @ ... ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.cc -Dparse.lac=none input.y ./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall input.y ./input.at:2617: set x `LC_ALL=C ls -l 'string.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='string.y'; } || exit 77 ./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror ./input.at:2458: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror ./input.at:2782: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -p bar -Wno-deprecated input.y ./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.cc -Dparse.lac=full input.y ./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy --warnings=none -Werror --trace=none ./input.at:2727: sed 's,.*/$,,' stderr 1>&2 stderr: 63. input.at:2883: testing Code injection ... ./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S yacc.c -d input.y stderr: ./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y -Werror 0+0 records in 0+0 records out 0 bytes copied, 2.448e-05 s, 0.0 kB/s input.y:2.8-10: error: duplicate directive [-Werror=other] 2 | %start exp | ^~~ input.y:1.8-10: note: previous declaration 1 | %start exp foo | ^~~ input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] stdout: ./input.at:2620: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret string.y ./input.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y --warnings=error ./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr.c -d input.y ./input.at:2460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: input.y:3.8-10: error: %define variable 'api.value.union.name' redefined [-Werror=other] input.y:1.8-10: note: previous definition input.y:4.1-32: error: %define variable 'api.value.union.name' redefined [-Werror=other] input.y:3.8-10: note: previous definition input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ./input.at:2630: set x `LC_ALL=C ls -l 'escape-in-string.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='escape-in-string.y'; } || exit 77 60. input.at:2764: ok ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.cc -Dparse.lac=unsupported input.y ./input.at:1877: sed 's,.*/$,,' stderr 1>&2 stderr: stderr: input.y:11.19: error: stray '$' [-Werror=other] input.y:11.23: error: stray '@' [-Werror=other] input.y:12.19: error: stray '$' [-Werror=other] input.y:12.23: error: stray '@' [-Werror=other] input.y:13.19: error: stray '$' [-Werror=other] input.y:13.23: error: stray '@' [-Werror=other] input.y:16.19: error: stray '$' [-Werror=other] input.y:16.23: error: stray '@' [-Werror=other] input.y:17.19: error: stray '$' [-Werror=other] stderr: input.y:5.1-40: error: %define variable 'lr.type' requires keyword values [-Werror=deprecated] input.y:3.1-40: error: %define variable 'lr.default-reduction' requires keyword values [-Werror=deprecated] input.y:4.1-40: error: %define variable 'lr.keep-unreachable-state' requires keyword values [-Werror=deprecated] input.y:1.1-38: error: %define variable 'api.pure' requires keyword values [-Werror=deprecated] input.y:2.1-40: error: %define variable 'api.push-pull' requires keyword values [-Werror=deprecated] ./input.at:2808: sed 's,.*/$,,' stderr 1>&2 ./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.cc -d input.y 0+0 records in 0+0 records out 0 bytes copied, 2.452e-05 s, 0.0 kB/s stdout: ./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.yy ./input.at:2861: sed 's,.*/$,,' stderr 1>&2 ./input.at:2633: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret escape-in-string.y ./input.at:2247: sed 's,.*/$,,' stderr 1>&2 ./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error ./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y --warnings=error ./input.at:2643: set x `LC_ALL=C ls -l 'tstring.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='tstring.y'; } || exit 77 53. input.at:2393: ok ./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr.cc -d input.y ./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error ./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y -Wnone,none -Werror --trace=none ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.d -Dparse.lac=none input.y 64. input.at:2946: testing Deprecated directives ... stderr: 0+0 records in 0+0 records out 0 bytes copied, 2.688e-05 s, 0.0 kB/s stdout: ./input.at:3019: cp errors-all experr ./input.at:3020: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -ffixit input.y ./input.at:2462: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2646: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret tstring.y ./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none ./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y -Wnone,none -Werror --trace=none ./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr2.cc -d input.y ./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y --warnings=none -Werror --trace=none ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.d -Dparse.lac=full input.y ./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y --warnings=none -Werror --trace=none ./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./input.at:2656: set x `LC_ALL=C ls -l 'escape-in-tstring.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='escape-in-tstring.y'; } || exit 77 ./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy -Werror ./input.at:2465: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none 65. input.at:3077: testing Unput's effect on locations ... ./input.at:3092: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 62. input.at:2840: ok ./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -W input.y ./input.at:3022: sed -e '/^fix-it:/d' errors-all >experr 65. input.at:3077: ok ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.d -Dparse.lac=unsupported input.y ./input.at:2820: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: ./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.d input.y ./input.at:3023: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y 0+0 records in 0+0 records out 0 bytes copied, 2.488e-05 s, 0.0 kB/s stdout: ./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./input.at:2659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret escape-in-tstring.y ./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.java input.y ./input.at:2467: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 57. input.at:2582: ok 66. input.at:3113: testing Non-deprecated directives ... ./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y ./input.at:3027: rm -f output.c ./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S yacc.c -d input.y ./input.at:2469: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -W input.y -Werror ./input.at:3028: cp input.y input.y.orig stderr: ./input.at:3029: sed -e '/fix-it/d' experr input.yy:2.1-32: error: %define variable 'api.location.type' requires '{...}' values [-Werror=deprecated] input.yy:4.1-32: error: %define variable 'api.prefix' requires '{...}' values [-Werror=deprecated] input.yy:5.1-32: error: %define variable 'api.token.prefix' requires '{...}' values [-Werror=deprecated] input.yy:3.1-32: error: %define variable 'api.namespace' requires '{...}' values [-Werror=deprecated] ./input.at:3030: echo "bison: file 'input.y' was updated (backup: 'input.y~')" >>experr 40. input.at:1826: ./input.at:3031: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --update input.y ./input.at:2825: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ok ./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror 67. input.at:3148: testing Cannot type action ... ./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y stderr: ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.java -Dparse.lac=none input.y input.y:2.15: error: stray '$' [-Werror=other] ./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr.c -d input.y ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.java -Dparse.lac=full input.y ./input.at:2214: sed 's,.*/$,,' stderr 1>&2 ./input.at:3034: diff input.y.orig input.y~ ./input.at:3037: test ! -f output.c 68. input.at:3171: testing Character literals and api.token.raw ... ./input.at:3181: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:2730: sed 's,.*/$,,' stderr 1>&2 54. input.at:2429: ./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy --warnings=error ok ./input.at:3040: sed -e '1,8d' input.y ./input.at:3062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.java -Dparse.lac=unsupported input.y ./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.cc -d input.y ./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -W input.y --warnings=error 69. input.at:3205: testing %token-table and parse.error ... stderr: input.y:14.1-15.5: error: duplicate directive: '%file-prefix' [-Werror=other] input.y:13.1-18: note: previous declaration input.y: error: %expect-rr applies only to GLR parsers [-Werror=other] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] 49. input.at:2224: ok ./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror ./input.at:3220: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 68. input.at:3171: ok 61. input.at:2793: ok ./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr.cc -d input.y 64. input.at:2946: ok ./input.at:3133: sed 's,.*/$,,' stderr 1>&2 70. input.at:3231: testing Invalid file prefix mapping arguments ... ./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -W input.y -Wnone,none -Werror --trace=none ./input.at:3246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -M foo input.y stderr: ./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr2.cc -d input.y ./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error ./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy -Wnone,none -Werror --trace=none input.y:10.6-13: error: only midrule actions can be typed: int [-Werror=other] 10 | exp: {} | ^~~~~~~~ ./input.at:2697: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dparse.lac.es-capacity-initial=1 -Dparse.lac.memory-trace=full input.y ./input.at:3247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --file-prefix-map foo input.y 74. named-refs.at:316: testing Many kinds of errors ... ./named-refs.at:384: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y ./input.at:3156: sed 's,.*/$,,' stderr 1>&2 72. named-refs.at:196: testing Undefined and ambiguous references ... ./named-refs.at:254: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o test.c test.y ./named-refs.at:426: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o test.c test.y ./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.d input.y 72. named-refs.at:196: ok ./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none 71. named-refs.at:22: testing Tutorial calculator ... ./named-refs.at:184: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y 74. named-refs.at:316: ok 73. named-refs.at:297: testing Misleading references ... ./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -W input.y --warnings=none -Werror --trace=none ./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./input.at:3221: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.java input.y ./input.at:3248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -M foo=bar -M baz input.y ./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./input.at:2704: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.cc -Dparse.lac=full -Dparse.lac.es-capacity-initial=1 -Dparse.lac.memory-trace=full input.y ./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy --warnings=none -Werror --trace=none ./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./named-refs.at:184: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 63. input.at:2883: ok 75. named-refs.at:551: testing Missing identifiers in brackets ... ./named-refs.at:559: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y ./input.at:3249: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -M foo= -M baz input.y 75. named-refs.at:551: ok 69. input.at:3205: ok 70. input.at:3231: ok ./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y -Werror ./input.at:2704: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.java -Dparse.lac=full -Dparse.lac.es-capacity-initial=1 -Dparse.lac.memory-trace=full input.y 76. named-refs.at:567: testing Redundant words in brackets ... ./named-refs.at:575: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y 66. input.at:3113: ok ./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-none input.y 78. named-refs.at:599: testing Stray symbols in brackets ... stderr: test.y:11.22-29: error: misleading reference: '$foo.bar' [-Werror=other] test.y:11.8-10: note: refers to: $foo at $1 test.y:11.12-18: note: possibly meant: $[foo.bar] at $2 ./named-refs.at:607: "$PERL" -pi -e 's/\\(\d{3})/chr(oct($1))/ge' test.y || exit 77 ./named-refs.at:608: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y ./named-refs.at:306: sed 's,.*/$,,' stderr 1>&2 76. named-refs.at:567: ok 77. named-refs.at:583: testing Comments in brackets ... ./named-refs.at:591: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y 78. named-refs.at:599: ok ./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y --warnings=error ./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none 77. named-refs.at:583: ok 79. named-refs.at:618: testing Redundant words in LHS brackets ... ./named-refs.at:625: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y 81. named-refs.at:648: testing Unresolved references ... ./named-refs.at:676: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y 58. input.at:2675: ok 48. input.at:2191: ok 80. named-refs.at:635: testing Factored LHS ... ./named-refs.at:642: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-none input.y -Werror 81. named-refs.at:648: ok ./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y -Wnone,none -Werror --trace=none 79. named-refs.at:618: ok stderr: 67. input.at:3148: ok input.y:2.15: error: stray '$' [-Werror=other] 82. named-refs.at:715: testing $ or @ followed by . or - ... 80. named-refs.at:635: ok ./named-refs.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y ./input.at:2733: sed 's,.*/$,,' stderr 1>&2 83. output.at:68: testing Output files: -dv ... ./output.at:68: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv foo.y 85. output.at:81: testing Output files: -dv -o foo.c ... ./output.at:81: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -o foo.c foo.y ./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y --warnings=none -Werror --trace=none 87. output.at:87: testing Output files: api.header.include={"./foo.h"} -dv -y ... 84. output.at:74: testing Output files: -dv >&- ... ./output.at:74: case "$PREBISON" in *valgrind*) exit 77;; esac stderr: 89. output.at:95: testing Output files: --fixed-output-files -dv -g --html ... ./output.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv >&- foo.y ./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret test.y stdout: 89. output.at:95: 88. output.at:92: testing Output files: -dv -o foo.tab.c ... ./output.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -o foo.tab.c foo.y ./named-refs.at:185: $PREPARSER ./test input.txt stderr: skipped (output.at:95) 86. output.at:84: testing Output files: -dv -y ... ./output.at:84: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -y foo.y ./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-none input.y --warnings=error ./named-refs.at:185: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./output.at:87: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -y foo.y stderr: stderr: ./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y -Werror ./output.at:81: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 90. output.at:97: testing Output files: -Hfoo.header -v -gfoo.gv --html=foo.html ... stderr: 71. named-refs.at:22: ok 90. output.at:97: skipped (output.at:97) ./output.at:68: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: stderr: ./output.at:84: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: ./output.at:74: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:81: grep '#include "foo.h"' foo.c stdout: 91. output.at:100: testing Output files: -dv -g --xml --fixed-output-files ... #include "foo.h" ./output.at:92: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: 73. named-refs.at:297: ok 85. output.at:81: ok ./output.at:100: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g --xml --fixed-output-files foo.y test.y:4.9: error: stray '$' [-Werror=other] test.y:5.9: error: stray '@' [-Werror=other] 83. output.at:68: ok ./output.at:84: grep '#include "y.tab.h"' y.tab.c ./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-none input.y -Wnone,none -Werror --trace=none stdout: 93. output.at:104: testing Output files: %require "3.4" -dv -g --xml -y ... stderr: 84. output.at:74: ok ./named-refs.at:740: sed 's,.*/$,,' stderr 1>&2 :6: warning: deprecated option: '--fixed-output-files', use '-o y.tab.c' [-Wdeprecated] ./output.at:100: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:104: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g --xml -y foo.y stderr: foo.y:1.1-7: warning: POSIX Yacc does not support %define [-Wyacc] ./output.at:87: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 86. output.at:84: ok 92. output.at:102: testing Output files: -dv -g --xml -y ... ./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-none input.y --warnings=none -Werror --trace=none 88. output.at:92: ok 94. output.at:107: testing Output files: -dv -g --xml -o y.tab.c ... ./output.at:107: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g --xml -o y.tab.c foo.y 91. output.at:100: ok ./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y --warnings=error ./output.at:102: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g --xml -y foo.y 95. output.at:110: testing Output files: -dv -b bar ... ./output.at:110: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -b bar foo.y stderr: ./output.at:87: grep '#include "./foo.h"' y.tab.c foo.y:1.1-8: warning: POSIX Yacc does not support %require [-Wyacc] foo.y:1.10-14: warning: POSIX Yacc does not support string literals [-Wyacc] ./output.at:104: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./input.at:2738: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror,none,other input.y stderr: ./output.at:107: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: stdout: #include "./foo.h" 96. output.at:112: testing Output files: -dv -g -o foo.c ... ./output.at:110: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 87. output.at:87: ok 94. output.at:107: ok 97. output.at:116: testing Output files: %header %verbose ... ./output.at:116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y stderr: ./output.at:102: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:112: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g -o foo.c foo.y 99. output.at:121: testing Output files: %header %verbose %yacc ... ./input.at:2741: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror,no-all,other input.y ./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y -Wnone,none -Werror --trace=none 98. output.at:118: testing Output files: %header %verbose %yacc ... ./output.at:121: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy 100. output.at:125: testing Output files: %file-prefix "bar" %header %verbose ... ./output.at:118: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y 93. output.at:104: ok 95. output.at:110: ok ./output.at:125: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y 92. output.at:102: ok ./input.at:2746: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror -Wno-error=other input.y stderr: stderr: 102. output.at:129: testing Output files: %file-prefix "baz" %output "bar.c" %header %verbose %yacc ... ./output.at:121: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y --warnings=none -Werror --trace=none stderr: ./output.at:129: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y ./output.at:112: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:116: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 101. output.at:127: testing Output files: %output "bar.c" %header %verbose %yacc ... stderr: stderr: 97. output.at:116: ok 103. output.at:136: testing Output files: %header %verbose ... 99. output.at:121: ok ./output.at:125: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:118: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 82. named-refs.at:715: ok ./output.at:127: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y 96. output.at:112: ok stderr: ./output.at:136: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy ./output.at:129: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./input.at:2750: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-error=other -Werror input.y 100. output.at:125: ok 104. output.at:139: testing Output files: %header %verbose -o foo.c ... 105. output.at:142: testing Output files: --header=foo.hpp -o foo.c++ ... stderr: ./output.at:136: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 102. output.at:129: ok 98. output.at:118: ok ./output.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c foo.yy ./output.at:142: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --header=foo.hpp -o foo.c++ foo.yy 106. output.at:146: testing Output files: --header=foo.hpp -o foo.c++ ... ./output.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --header=foo.hpp -o foo.c++ foo.yy ./input.at:2754: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror=other -Wno-other input.y stderr: 103. output.at:136: ok 107. output.at:150: testing Output files: %header "foo.hpp" -o foo.c++ ... ./output.at:150: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c++ foo.yy ./output.at:127: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: 108. output.at:154: testing Output files: -o foo.c++ --graph=foo.gph ... ./output.at:154: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c++ --graph=foo.gph foo.yy stderr: ./output.at:142: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:139: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 109. output.at:160: testing Output files: %type useless --header --graph --xml --report=all -Wall -Werror ... 101. output.at:127: ok ./output.at:160: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header --graph --xml --report=all -Wall -Werror foo.y stderr: 59. input.at:2719: ok ./output.at:154: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 110. output.at:167: testing Output files: useless=--header --graph --xml --report=all -Wall -Werror ... ./output.at:167: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header --graph --xml --report=all -Wall -Werror foo.y stderr: stderr: ./output.at:146: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 108. output.at:154: ok 111. output.at:173: testing Output files: %defines -o foo.c++ ... ./output.at:150: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 104. output.at:139: ok ./output.at:173: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c++ foo.yy 113. output.at:191: testing Output files: lalr1.cc ... 112. output.at:176: testing Output files: %defines "foo.hpp" -o foo.c++ ... 107. output.at:150: ok 106. output.at:146: ok ./output.at:191: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy ./output.at:176: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c++ foo.yy 105. output.at:142: ok stderr: foo.y:1.13-19: error: symbol 'useless' is used, but is not defined as a token and has no rules [-Werror=other] foo.y: error: 1 nonterminal useless in grammar [-Werror=other] foo.y:1.13-19: error: nonterminal useless in grammar: useless [-Werror=other] ./output.at:160: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: ./output.at:191: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 114. output.at:194: testing Output files: lalr1.cc %verbose ... ./output.at:194: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy stderr: ./output.at:176: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 109. output.at:160: ok stderr: stderr: 118. output.at:206: testing Output files: lalr1.cc %header %verbose ... 115. output.at:197: testing Output files: lalr1.cc %header %verbose ... ./output.at:197: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy foo.y:1.1-15: error: %define variable 'useless' is not used ./output.at:167: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 117. output.at:203: testing Output files: lalr1.cc %header %verbose %locations ... 116. output.at:200: testing Output files: lalr1.cc %verbose %locations ... ./output.at:203: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy ./output.at:173: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: ./output.at:194: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:200: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy 112. output.at:176: ok ./output.at:206: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret subdir/foo.yy 114. output.at:194: ok 110. output.at:167: ok 113. output.at:191: ok 119. output.at:210: testing Output files: lalr1.cc %header %verbose %locations -o subdir/foo.cc ... stderr: ./output.at:203: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: ./output.at:197: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 111. output.at:173: ok 121. output.at:220: testing Output files: lalr1.cc %header %locations %verbose %file-prefix "output_dir/foo" ... stderr: 117. output.at:203: ok 120. output.at:215: testing Output files: lalr1.cc %header %verbose %file-prefix "output_dir/foo" ... stderr: ./output.at:200: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:206: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(subdir/foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 115. output.at:197: ok 122. output.at:226: testing Output files: lalr1.cc %header %locations api.location.file=none %require "3.2" ... ./output.at:226: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy 124. output.at:237: testing Output files: lalr1.cc %header %locations api.location.file="$at_dir/foo.loc.hh" %require "3.2" ... ./output.at:237: "$PERL" -pi -e 's{\$at_dir}'"{$at_group_dir}g" foo.yy || exit 77 ./output.at:237: rm -f foo.yy.bak 123. output.at:231: testing Output files: lalr1.cc %header %locations api.location.file="foo.loc.hh" %require "3.2" ... ./output.at:231: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy 126. output.at:272: testing Conflicting output files: %header "foo.output" -v ... 116. output.at:200: ok ./output.at:237: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy ./output.at:206: grep 'include .subdir/' foo.tab.cc 125. output.at:267: testing Conflicting output files: --graph="foo.tab.c" ... ./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y ./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v foo.y stderr: ./output.at:206: grep 'include .subdir/' foo.tab.hh ./output.at:226: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: ./output.at:231: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 127. output.at:277: testing Conflicting output files: lalr1.cc %header %locations --graph="location.hh" ... ./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --graph="location.hh" foo.y 122. output.at:226: 118. output.at:206: ok ok ./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y -Werror ./output.at:210: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o subdir/foo.cc subdir/foo.yy 128. output.at:282: testing Conflicting output files: -o foo.y ... stderr: ./output.at:237: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:282: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o foo.y foo.y ./output.at:215: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret gram_dir/foo.yy stderr: 123. output.at:231: ok stderr: ./output.at:210: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(subdir/foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 foo.y: error: conflicting outputs to file 'foo.tab.c' [-Werror=other] ./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v foo.y -Werror 129. output.at:328: testing Output file name: `~!@#$%^&*()-=_+{}[]|\:;<>, .' ... ./output.at:328: touch "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.tmp" || exit 77 ./output.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.c" --header="\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.h" glr.y 124. output.at:237: ok ./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="location.hh" foo.y -Werror stderr: ./output.at:267: sed 's,.*/$,,' stderr 1>&2 ./output.at:215: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(gram_dir/foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:210: grep 'include .subdir/' subdir/foo.cc ./output.at:282: cat foo.y ./output.at:328: ls "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.c" "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.h" stderr: ./output.at:210: grep 'include .subdir/' subdir/foo.hh foo.y: error: conflicting outputs to file 'foo.output' [-Werror=other] ./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y --warnings=error stdout: 130. output.at:335: testing Output file name: ( ... ./output.at:335: touch "(.tmp" || exit 77 131. output.at:336: testing Output file name: ) ... ./output.at:336: touch ").tmp" || exit 77 `~!@#$%^&*()-=_+{}[]|\:;<>, .'.c `~!@#$%^&*()-=_+{}[]|\:;<>, .'.h ./output.at:328: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.c" 132. output.at:337: testing Output file name: # ... ./output.at:337: touch "#.tmp" || exit 77 119. output.at:210: ok stderr: foo.y: error: conflicting outputs to file 'location.hh' [-Werror=other] ./output.at:335: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "(.c" --header="(.h" glr.y 128. output.at:282: ok ./output.at:337: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "#.c" --header="#.h" glr.y ./output.at:220: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret gram_dir/foo.yy 120. output.at:215: ok ./output.at:272: sed 's,.*/$,,' stderr 1>&2 ./output.at:277: sed 's,.*/$,,' stderr 1>&2 ./output.at:336: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o ").c" --header=").h" glr.y 133. output.at:338: testing Output file name: @@ ... ./output.at:338: touch "@@.tmp" || exit 77 ./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v foo.y --warnings=error ./output.at:337: ls "#.c" "#.h" ./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y -Wnone,none -Werror --trace=none stdout: stderr: ./output.at:338: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@@.c" --header="@@.h" glr.y #.c #.h ./output.at:220: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(gram_dir/foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:337: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "#.c" ./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="location.hh" foo.y --warnings=error ./output.at:335: ls "(.c" "(.h" ./output.at:336: ls ").c" ").h" 121. output.at:220: stdout: ok stdout: (.c (.h ./output.at:335: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "(.c" ).c ).h ./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="location.hh" foo.y -Wnone,none -Werror --trace=none ./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v foo.y -Wnone,none -Werror --trace=none ./output.at:336: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c ").c" 134. output.at:339: testing Output file name: @{ ... ./output.at:339: touch "@{.tmp" || exit 77 135. output.at:340: testing Output file name: @} ... ./output.at:340: touch "@}.tmp" || exit 77 ./output.at:339: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@{.c" --header="@{.h" glr.y 136. output.at:341: testing Output file name: [ ... ./output.at:341: touch "[.tmp" || exit 77 ./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y --warnings=none -Werror --trace=none ./output.at:338: ls "@@.c" "@@.h" stdout: @@.c @@.h ./output.at:340: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@}.c" --header="@}.h" glr.y ./output.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "[.c" --header="[.h" glr.y ./output.at:338: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "@@.c" ./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v foo.y --warnings=none -Werror --trace=none ./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="location.hh" foo.y --warnings=none -Werror --trace=none ./output.at:339: ls "@{.c" "@{.h" 137. output.at:342: testing Output file name: ] ... ./output.at:342: touch "].tmp" || exit 77 stdout: @{.c @{.h ./output.at:339: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "@{.c" ./output.at:340: ls "@}.c" "@}.h" ./output.at:342: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "].c" --header="].h" glr.y ./output.at:267: cat foo.y ./output.at:341: ls "[.c" "[.h" stdout: @}.c @}.h stdout: 125. output.at:267: ok ./output.at:272: cat foo.y ./output.at:340: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "@}.c" [.c [.h ./output.at:277: cat foo.y ./output.at:341: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "[.c" 126. output.at:272: ok 127. output.at:277: ok ./output.at:342: ls "].c" "].h" stdout: ].c ].h ./output.at:342: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "].c" 138. output.at:363: testing Graph with no conflicts ... ./output.at:363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y 139. output.at:403: testing Graph with unsolved S/R ... ./output.at:403: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y 140. output.at:473: testing Graph with solved S/R ... ./output.at:473: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y stderr: ./output.at:363: grep -v // input.gv stderr: 138. output.at:363: ok input.y: warning: 3 shift/reduce conflicts [-Wconflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:10.10-18: warning: rule useless in parser due to conflicts [-Wother] input.y:11.10-18: warning: rule useless in parser due to conflicts [-Wother] input.y:12.10-18: warning: rule useless in parser due to conflicts [-Wother] ./output.at:403: grep -v // input.gv stderr: input.y:6.5-7: warning: rule useless in parser due to conflicts [-Wother] input.y:14.10-18: warning: rule useless in parser due to conflicts [-Wother] input.y:15.10-18: warning: rule useless in parser due to conflicts [-Wother] ./output.at:473: grep -v // input.gv 139. output.at:403: ok 140. output.at:473: ok stderr: stdout: stderr: stderr: stdout: stdout: ./output.at:335: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "(.cc" --header="(.hh" cxx.y ./output.at:336: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o ").cc" --header=").hh" cxx.y ./output.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.cc" --header="\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.hh" cxx.y 141. output.at:538: testing Graph with R/R ... ./output.at:538: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y ./output.at:328: ls "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.cc" "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.hh" 143. output.at:641: testing Graph with a reduction rule both enabled and disabled ... stdout: `~!@#$%^&*()-=_+{}[]|\:;<>, .'.cc `~!@#$%^&*()-=_+{}[]|\:;<>, .'.hh ./output.at:328: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.cc" 142. output.at:576: testing Graph with reductions with multiple LAT ... ./output.at:576: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y ./output.at:641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y ./output.at:335: ls "(.cc" "(.hh" ./output.at:336: ls ").cc" ").hh" stdout: stdout: stderr: ).cc ).hh stderr: (.cc (.hh stderr: ./output.at:336: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c ").cc" stdout: input.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:4.3: warning: rule useless in parser due to conflicts [-Wother] stdout: ./output.at:335: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "(.cc" ./output.at:538: grep -v // input.gv stderr: ./output.at:338: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@@.cc" --header="@@.hh" cxx.y ./output.at:337: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "#.cc" --header="#.hh" cxx.y input.y: warning: 3 reduce/reduce conflicts [-Wconflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:2.14-18: warning: rule useless in parser due to conflicts [-Wother] input.y:5.3: warning: rule useless in parser due to conflicts [-Wother] ./output.at:576: grep -v // input.gv 141. output.at:538: ok 142. output.at:576: ok ./output.at:338: ls "@@.cc" "@@.hh" ./output.at:337: ls "#.cc" "#.hh" stdout: stdout: stderr: @@.cc @@.hh #.cc #.hh stdout: ./output.at:337: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "#.cc" ./output.at:338: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "@@.cc" ./output.at:339: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@{.cc" --header="@{.hh" cxx.y 144. output.at:744: testing C++ Output File Prefix Mapping ... stderr: stderr: stderr: stdout: ./output.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o out/x1.cc -M out/=bar/ x1.yy input.y: warning: 4 shift/reduce conflicts [-Wconflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stdout: ./output.at:641: grep -v // input.gv ./output.at:339: ls "@{.cc" "@{.hh" ./output.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "[.cc" --header="[.hh" cxx.y ./output.at:340: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@}.cc" --header="@}.hh" cxx.y 145. diagnostics.at:84: testing Warnings ... stdout: 143. output.at:641: ok @{.cc @{.hh ./diagnostics.at:84: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./output.at:339: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "@{.cc" ./output.at:775: $CXX $CPPFLAGS $CXXFLAGS -Iout/include -c -o out/x1.o out/x1.cc ./output.at:341: ls "[.cc" "[.hh" ./output.at:340: ls "@}.cc" "@}.hh" stdout: 146. diagnostics.at:133: testing Single point locations ... stdout: [.cc [.hh @}.cc @}.hh ./output.at:341: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "[.cc" ./output.at:340: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "@}.cc" ./diagnostics.at:84: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:84: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y ./diagnostics.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y stderr: stdout: 145. diagnostics.at:84: ok ./output.at:342: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "].cc" --header="].hh" cxx.y ./diagnostics.at:133: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./output.at:342: ls "].cc" "].hh" stdout: ].cc ].hh ./diagnostics.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y ./output.at:342: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "].cc" 147. diagnostics.at:182: testing Line is too short, and then you die ... 146. diagnostics.at:133: ok ./diagnostics.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:182: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 148. diagnostics.at:217: testing Zero-width characters ... ./diagnostics.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y 147. diagnostics.at:182: ok ./diagnostics.at:217: "$PERL" -pi -e 's{\^M}{\r}g;s{\\(\d{3}|.)}{$v = $1; $v =~ /\A\d+\z/ ? chr($v) : $v}ge' input.y experr || exit 77 ./diagnostics.at:217: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:217: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:217: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y 148. diagnostics.at:217: ok 149. diagnostics.at:235: testing Tabulations and multibyte characters ... stderr: stdout: 129. output.at:328: ok stderr: stdout: 131. output.at:336: ok ./diagnostics.at:235: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y 151. diagnostics.at:303: testing Special files ... 150. diagnostics.at:282: testing Tabulations and multibyte characters ... ./diagnostics.at:303: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:235: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:235: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y ./diagnostics.at:303: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:303: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y ./diagnostics.at:282: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y 152. diagnostics.at:328: testing Complaints from M4 ... ./diagnostics.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y 151. diagnostics.at:303: ok 149. diagnostics.at:235: ok ./diagnostics.at:282: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:282: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y ./diagnostics.at:328: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y 153. diagnostics.at:351: testing Carriage return ... 154. diagnostics.at:372: testing CR NL ... stderr: stdout: 150. diagnostics.at:282: ok 133. output.at:338: ok ./diagnostics.at:351: "$PERL" -pi -e 's{\^M}{\r}g;s{\\(\d{3}|.)}{$v = $1; $v =~ /\A\d+\z/ ? chr($v) : $v}ge' input.y experr || exit 77 ./diagnostics.at:351: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:372: "$PERL" -pi -e 's{\^M}{\r}g;s{\\(\d{3}|.)}{$v = $1; $v =~ /\A\d+\z/ ? chr($v) : $v}ge' input.y experr || exit 77 ./diagnostics.at:351: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 155. diagnostics.at:399: testing Screen width: 200 columns ... ./diagnostics.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y 152. diagnostics.at:328: ok ./diagnostics.at:351: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y 156. diagnostics.at:432: testing Screen width: 80 columns ... stderr: stdout: 153. diagnostics.at:351: 130. output.at:335: ok ok ./diagnostics.at:399: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=200 bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:372: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 stderr: ./diagnostics.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y stdout: ./diagnostics.at:432: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=80 bison -fcaret --color=debug -Wall,cex input.y 137. output.at:342: ok 159. diagnostics.at:527: testing Counterexamples ... 157. diagnostics.at:465: testing Screen width: 60 columns ... 158. diagnostics.at:504: testing Suggestions ... ./diagnostics.at:399: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 154. diagnostics.at:372: ok ./diagnostics.at:399: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=200 bison -fcaret -Wall,cex input.y ./diagnostics.at:465: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=60 bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:527: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:432: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 160. diagnostics.at:645: testing Deep Counterexamples ... ./diagnostics.at:504: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:432: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=80 bison -fcaret -Wall,cex input.y ./diagnostics.at:504: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 155. diagnostics.at:399: ok ./diagnostics.at:465: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:504: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y ./diagnostics.at:527: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 stderr: stdout: ./diagnostics.at:645: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y 161. diagnostics.at:713: testing Indentation with message suppression ... ./diagnostics.at:465: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=60 bison -fcaret -Wall,cex input.y ./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wno-other input.y 132. output.at:337: ok 156. diagnostics.at:432: ok ./diagnostics.at:527: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y 158. diagnostics.at:504: ok ./diagnostics.at:645: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 stderr: stdout: ./output.at:782: sed -ne 's/#line [0-9][0-9]* "/#line "/p;/INCLUDED/p;/\\file/{p;n;p;}' out/include/ast/loc.hh ./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wno-other input.y -Werror 157. diagnostics.at:465: ok ./diagnostics.at:645: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y ./output.at:794: sed -ne 's/^#line [0-9][0-9]* "/#line "/p;/INCLUDED/p;/\\file/{p;n;p;}' out/x1.hh ./output.at:806: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o out/x2.cc -M out/=bar/ x2.yy 162. skeletons.at:25: testing Relative skeleton file names ... ./skeletons.at:27: mkdir tmp 165. skeletons.at:166: testing Complaining during macro argument expansion ... ./skeletons.at:189: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input1.y stderr: 160. diagnostics.at:645: 159. diagnostics.at:527: ok ok input.y:2.1-12: error: deprecated directive: '%pure-parser', use '%define api.pure' [-Werror=deprecated] 2 | %pure-parser | ^~~~~~~~~~~~ | %define api.pure input.y:3.1-14: error: deprecated directive: '%error-verbose', use '%define parse.error verbose' [-Werror=deprecated] 3 | %error-verbose | ^~~~~~~~~~~~~~ | %define parse.error verbose ./output.at:806: $CXX $CPPFLAGS $CXXFLAGS -Iout/include -c -o out/x2.o out/x2.cc 164. skeletons.at:142: testing Boolean=variables: invalid skeleton defaults ... 163. skeletons.at:85: testing Installed skeleton file names ... ./skeletons.at:155: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./diagnostics.at:725: sed 's,.*/$,,' stderr 1>&2 166. skeletons.at:248: testing Fatal errors make M4 exit immediately ... ./skeletons.at:262: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input1.y ./skeletons.at:120: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --skeleton=yacc.c -o input-cmd-line.c input-cmd-line.y ./skeletons.at:63: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret tmp/input-gram.y ./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wno-other input.y --warnings=error ./skeletons.at:121: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input-cmd-line input-cmd-line.c $LIBS ./skeletons.at:64: cat input-gram.tab.c 167. skeletons.at:302: testing Fatal errors but M4 continues producing output ... ./skeletons.at:314: "$PERL" gen-skel.pl > skel.c || exit 77 168. sets.at:27: testing Nullable ... ./sets.at:42: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=sets input.y stderr: bison (GNU Bison) 3.8.2 RITEM 0: e $end (rule 0) 3: 'e' (rule 1) 5: (rule 2) DERIVES $accept derives 0 e $end e derives 1 'e' 2 %empty NULLABLE $accept: no e: yes RTC: Firsts Input BEGIN 01 .--. 0| 1| 1| | `--' RTC: Firsts Input END RTC: Firsts Output BEGIN 01 .--. 0|11| 1| 1| `--' RTC: Firsts Output END FIRSTS $accept firsts $accept e e firsts e FDERIVES $accept derives 0 e $end 1 'e' 2 %empty e derives 1 'e' 2 %empty relation_transpose: relation_transpose: output: follows after includes: FOLLOWS[goto[0] = (0, e, 2)] = $end Lookaheads: State 0: rule 2: $end State 1: rule 1: State 3: rule 0: ./skeletons.at:68: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input-gram.y ./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wno-other input.y -Wnone,none -Werror --trace=none ./sets.at:43: sed -f extract.sed stderr 164. skeletons.at:142: ok ./skeletons.at:322: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./skeletons.at:279: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input2.y ./skeletons.at:209: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input2.y 168. sets.at:27: ok ./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wno-other input.y --warnings=none -Werror --trace=none stderr: ./skeletons.at:69: cat input-gram.tab.c stdout: stderr: 134. output.at:339: ok stdout: ./skeletons.at:73: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --skeleton=tmp/skel.c tmp/input-cmd-line.y ./skeletons.at:223: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input3.y 135. output.at:340: ok 167. skeletons.at:302: ok 161. diagnostics.at:713: ok 169. sets.at:111: testing Broken Closure ... ./skeletons.at:74: cat input-cmd-line.tab.c stderr: 171. sets.at:228: testing Accept ... ./sets.at:240: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y ./sets.at:125: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=sets input.y 162. skeletons.at:25: ok 166. skeletons.at:248: ok stdout: 170. sets.at:153: testing Firsts ... ./sets.at:171: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=sets input.y ./skeletons.at:237: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input4.y 136. output.at:341: ok 172. sets.at:269: testing Build relations ... ./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./sets.at:243: sed -n 's/.*define YYFINAL *\([0-9][0-9]*\)/final state \1/p' input.c 173. sets.at:315: testing Reduced Grammar ... ./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=grammar -o input.c input.y stdout: ./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror stderr: 175. reduce.at:26: testing Useless Terminals ... stdout: final state 6 stderr: ./reduce.at:47: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y ./skeletons.at:122: $PREPARSER ./input-cmd-line stderr: bison (GNU Bison) 3.8.2 RITEM 0: exp $end (rule 0) 3: exp '<' exp (rule 1) 7: exp '>' exp (rule 2) 11: exp '+' exp (rule 3) 15: exp '-' exp (rule 4) 19: exp '^' exp (rule 5) 23: exp '=' exp (rule 6) 27: "exp" (rule 7) DERIVES $accept derives 0 exp $end exp derives 1 exp '<' exp 2 exp '>' exp 3 exp '+' exp 4 exp '-' exp 5 exp '^' exp 6 exp '=' exp 7 "exp" NULLABLE $accept: no exp: no RTC: Firsts Input BEGIN 01 .--. 0| 1| 1| 1| `--' RTC: Firsts Input END RTC: Firsts Output BEGIN 01 .--. 0|11| 1| 1| `--' RTC: Firsts Output END FIRSTS $accept firsts $accept exp exp firsts exp FDERIVES $accept derives 0 exp $end 1 exp '<' exp 2 exp '>' exp 3 exp '+' exp 4 exp '-' exp 5 exp '^' exp 6 exp '=' exp 7 "exp" exp derives 1 exp '<' exp 2 exp '>' exp 3 exp '+' exp 4 exp '-' exp 5 exp '^' exp 6 exp '=' exp 7 "exp" relation_transpose: 0: 1 2 3 4 5 6 1: 1 2 3 4 5 6 2: 1 2 3 4 5 6 3: 1 2 3 4 5 6 4: 1 2 3 4 5 6 5: 1 2 3 4 5 6 6: 1 2 3 4 5 6 relation_transpose: output: 1: 0 1 2 3 4 5 6 2: 0 1 2 3 4 5 6 3: 0 1 2 3 4 5 6 4: 0 1 2 3 4 5 6 5: 0 1 2 3 4 5 6 6: 0 1 2 3 4 5 6 follows after includes: FOLLOWS[goto[0] = (0, exp, 2)] = $end '<' '>' '+' '-' '^' '=' FOLLOWS[goto[1] = (4, exp, 10)] = $end '<' '>' '+' '-' '^' '=' FOLLOWS[goto[2] = (5, exp, 11)] = $end '<' '>' '+' '-' '^' '=' FOLLOWS[goto[3] = (6, exp, 12)] = $end '<' '>' '+' '-' '^' '=' FOLLOWS[goto[4] = (7, exp, 13)] = $end '<' '>' '+' '-' '^' '=' FOLLOWS[goto[5] = (8, exp, 14)] = $end '<' '>' '+' '-' '^' '=' FOLLOWS[goto[6] = (9, exp, 15)] = $end '<' '>' '+' '-' '^' '=' Lookaheads: State 1: rule 7: State 3: rule 0: State 10: rule 1: $end '<' '>' '+' '-' '^' '=' State 11: rule 2: $end '<' '>' '+' '-' '^' '=' State 12: rule 3: $end '<' '>' '+' '-' '^' '=' State 13: rule 4: $end '<' '>' '+' '-' '^' '=' State 14: rule 5: $end '<' '>' '+' '-' '^' '=' State 15: rule 6: $end '<' '>' '+' '-' '^' '=' stderr: ./sets.at:248: sed -n ' /^State \(.*\)/{ s//final state \1/ x } / accept/{ x p q } ' input.output 174. sets.at:394: testing Reduced Grammar with prec and assoc ... syntax error, unexpected 'a', expecting end of file bison (GNU Bison) 3.8.2 RITEM 0: a $end (rule 0) 3: b (rule 1) 5: c (rule 2) 7: d (rule 3) 9: e (rule 4) 11: f (rule 5) 13: g (rule 6) 15: h (rule 7) 17: 'h' (rule 8) DERIVES $accept derives 0 a $end a derives 1 b b derives 2 c c derives 3 d d derives 4 e e derives 5 f f derives 6 g g derives 7 h h derives 8 'h' NULLABLE $accept: no a: no b: no c: no d: no e: no f: no g: no h: no RTC: Firsts Input BEGIN 012345678 .---------. 0| 1 | 1| 1 | 2| 1 | 3| 1 | 4| 1 | 5| 1 | 6| 1 | 7| 1| 8| | `---------' RTC: Firsts Input END RTC: Firsts Output BEGIN 012345678 .---------. 0|111111111| 1| 11111111| 2| 1111111| 3| 111111| 4| 11111| 5| 1111| 6| 111| 7| 11| 8| 1| `---------' RTC: Firsts Output END FIRSTS $accept firsts $accept a b c d e f g h a firsts a b c d e f g h b firsts b c d e f g h c firsts c d e f g h d firsts d e f g h e firsts e f g h f firsts f g h g firsts g h h firsts h FDERIVES $accept derives 0 a $end 1 b 2 c 3 d 4 e 5 f 6 g 7 h 8 'h' a derives 1 b 2 c 3 d 4 e 5 f 6 g 7 h 8 'h' b derives 2 c 3 d 4 e 5 f 6 g 7 h 8 'h' c derives 3 d 4 e 5 f 6 g 7 h 8 'h' d derives 4 e 5 f 6 g 7 h 8 'h' e derives 5 f 6 g 7 h 8 'h' f derives 6 g 7 h 8 'h' g derives 7 h 8 'h' h derives 8 'h' relation_transpose: 0: 1 1: 2 2: 3 3: 4 4: 5 5: 6 6: 7 relation_transpose: output: 1: 0 2: 1 3: 2 4: 3 5: 4 6: 5 7: 6 follows after includes: FOLLOWS[goto[0] = (0, a, 2)] = $end FOLLOWS[goto[1] = (0, b, 3)] = $end FOLLOWS[goto[2] = (0, c, 4)] = $end FOLLOWS[goto[3] = (0, d, 5)] = $end FOLLOWS[goto[4] = (0, e, 6)] = $end FOLLOWS[goto[5] = (0, f, 7)] = $end FOLLOWS[goto[6] = (0, g, 8)] = $end FOLLOWS[goto[7] = (0, h, 9)] = $end Lookaheads: State 1: rule 8: State 3: rule 1: State 4: rule 2: State 5: rule 3: State 6: rule 4: State 7: rule 5: State 8: rule 6: State 9: rule 7: State 10: rule 0: ./sets.at:127: sed -n 's/[ ]*$//;/^RTC: Firsts Output BEGIN/,/^RTC: Firsts Output END/p' stderr ./skeletons.at:122: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./sets.at:412: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=grammar -o input.c input.y stderr: input.y: error: 5 reduce/reduce conflicts [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:2.14-17: error: rule useless in parser due to conflicts [-Werror=other] 2 | expr: term | term | term | term | term | term | ^~~~ input.y:2.21-24: error: rule useless in parser due to conflicts [-Werror=other] 2 | expr: term | term | term | term | term | term | ^~~~ input.y:2.28-31: error: rule useless in parser due to conflicts [-Werror=other] 2 | expr: term | term | term | term | term | term | ^~~~ input.y:2.35-38: error: rule useless in parser due to conflicts [-Werror=other] 2 | expr: term | term | term | term | term | term | ^~~~ input.y:2.42-45: error: rule useless in parser due to conflicts [-Werror=other] 2 | expr: term | term | term | term | term | term | ^~~~ ./sets.at:172: sed -f extract.sed stderr 165. skeletons.at:166: ok ./sets.at:286: sed 's,.*/$,,' stderr 1>&2 176. reduce.at:70: testing Useless Nonterminals ... 170. sets.at:153: ok ./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y 171. sets.at:228: ok 177. reduce.at:120: testing Useless Rules ... ./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./skeletons.at:126: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input-gram.c input-gram.y ./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=grammar -o input.c input.y -Werror 169. sets.at:111: ok ./reduce.at:49: sed -n '/^Grammar/q;/^$/!p' input.output 175. reduce.at:26: ok ./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror 179. reduce.at:312: testing Reduced Automaton ... 174. sets.at:394: ok 180. reduce.at:406: testing Underivable Rules ... ./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror ./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret not-reduced.y 178. reduce.at:224: testing Useless Parts ... ./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y ./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./skeletons.at:127: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input-gram input-gram.c $LIBS stderr: stderr: bison (GNU Bison) 3.8.2 input.y: error: 1 nonterminal useless in grammar [-Werror=other] input.y: error: 1 rule useless in grammar [-Werror=other] input.y:4.1-7: error: nonterminal useless in grammar: useless [-Werror=other] Reduced Grammar ntokens = 7, nnterms = 4, nsyms = 11, nrules = 6, nritems = 17 Tokens ------ Value Sprec Sassoc Tag 0 0 0 $end 1 0 0 error 2 0 0 $undefined 3 0 0 "+" 4 0 0 "*" 5 0 0 "useless" 6 0 0 "num" Nonterminals ------------ Value Tag 7 $accept 8 expr 9 term 10 fact Rules ----- Num (Prec, Assoc, Useful, UselessChain) Lhs -> (Ritem Range) Rhs 0 ( 0, 0, t, f) 7 -> ( 0- 1) 8 0 1 ( 0, 0, t, f) 8 -> ( 3- 5) 8 3 9 2 ( 0, 0, t, t) 8 -> ( 7- 7) 9 3 ( 0, 0, t, f) 9 -> ( 9-11) 9 4 10 4 ( 0, 0, t, t) 9 -> (13-13) 10 5 ( 0, 0, t, t) 10 -> (17-17) 6 6 ( 0, 0, f, t) 11 -> (15-15) 5 Rules interpreted ----------------- 0 $accept: expr $end 1 expr: expr "+" term 2 expr: term 3 term: term "*" fact 4 term: fact 5 fact: "num" 6 useless: "useless" reduced input.y defines 7 terminals, 4 nonterminals, and 6 productions. input.y: error: 3 nonterminals useless in grammar [-Werror=other] input.y: error: 3 rules useless in grammar [-Werror=other] input.y:11.1-8: error: nonterminal useless in grammar: useless1 [-Werror=other] input.y:12.1-8: error: nonterminal useless in grammar: useless2 [-Werror=other] input.y:13.1-8: error: nonterminal useless in grammar: useless3 [-Werror=other] 181. reduce.at:452: testing Bad start symbols ... ./reduce.at:467: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./sets.at:325: sed 's,.*/$,,' stderr 1>&2 ./reduce.at:89: sed 's,.*/$,,' stderr 1>&2 182. reduce.at:550: testing no lr.type: Single State Split ... ./reduce.at:550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret not-reduced.y -Werror ./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror ./reduce.at:550: sed -n '/^State 0$/,$p' input.output ./reduce.at:473: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y -Werror stderr: 172. sets.at:269: ./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=grammar -o input.c input.y --warnings=error ok input.y: error: 9 nonterminals useless in grammar [-Werror=other] input.y: error: 9 rules useless in grammar [-Werror=other] input.y:10.1-8: error: nonterminal useless in grammar: useless1 [-Werror=other] 10 | useless1: '1'; | ^~~~~~~~ input.y:11.1-8: error: nonterminal useless in grammar: useless2 [-Werror=other] 11 | useless2: '2'; | ^~~~~~~~ input.y:12.1-8: error: nonterminal useless in grammar: useless3 [-Werror=other] 12 | useless3: '3'; | ^~~~~~~~ input.y:13.1-8: error: nonterminal useless in grammar: useless4 [-Werror=other] 13 | useless4: '4'; | ^~~~~~~~ input.y:14.1-8: error: nonterminal useless in grammar: useless5 [-Werror=other] 14 | useless5: '5'; | ^~~~~~~~ input.y:15.1-8: error: nonterminal useless in grammar: useless6 [-Werror=other] 15 | useless6: '6'; | ^~~~~~~~ input.y:16.1-8: error: nonterminal useless in grammar: useless7 [-Werror=other] 16 | useless7: '7'; | ^~~~~~~~ input.y:17.1-8: error: nonterminal useless in grammar: useless8 [-Werror=other] 17 | useless8: '8'; | ^~~~~~~~ input.y:18.1-8: error: nonterminal useless in grammar: useless9 [-Werror=other] 18 | useless9: '9'; | ^~~~~~~~ ./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error stderr: ./reduce.at:550: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS not-reduced.y: error: 2 nonterminals useless in grammar [-Werror=other] not-reduced.y: error: 3 rules useless in grammar [-Werror=other] not-reduced.y:14.1-13: error: nonterminal useless in grammar: not_reachable [-Werror=other] 14 | not_reachable: useful { /* A not reachable action. */ } | ^~~~~~~~~~~~~ not-reduced.y:17.1-14: error: nonterminal useless in grammar: non_productive [-Werror=other] 17 | non_productive: non_productive useless_token | ^~~~~~~~~~~~~~ not-reduced.y:11.6-57: error: rule useless in grammar [-Werror=other] 11 | | non_productive { /* A non productive action. */ } | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ./reduce.at:480: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: ./reduce.at:146: sed 's,.*/$,,' stderr 1>&2 183. reduce.at:550: testing lr.type=lalr: Single State Split ... input.y: error: 2 nonterminals useless in grammar [-Werror=other] input.y: error: 3 rules useless in grammar [-Werror=other] input.y:6.1-11: error: nonterminal useless in grammar: underivable [-Werror=other] 6 | underivable: indirection; | ^~~~~~~~~~~ input.y:7.1-11: error: nonterminal useless in grammar: indirection [-Werror=other] 7 | indirection: underivable; | ^~~~~~~~~~~ input.y:5.15-25: error: rule useless in grammar [-Werror=other] 5 | exp: useful | underivable; | ^~~~~~~~~~~ stderr: ./reduce.at:550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y input.y: error: 1 nonterminal useless in grammar [-Werror=other] input.y: error: 1 rule useless in grammar [-Werror=other] input.y:18.1-6: error: nonterminal useless in grammar: unused [-Werror=other] 18 | unused | ^~~~~~ ./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=grammar -o input.c input.y -Wnone,none -Werror --trace=none ./reduce.at:341: sed 's,.*/$,,' stderr 1>&2 ./reduce.at:420: sed 's,.*/$,,' stderr 1>&2 ./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none ./reduce.at:488: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./reduce.at:261: sed 's,.*/$,,' stderr 1>&2 ./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret not-reduced.y --warnings=error ./reduce.at:550: sed -n '/^State 0$/,$p' input.output ./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./reduce.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y --warnings=error 184. reduce.at:550: testing lr.type=ielr: Single State Split ... ./reduce.at:550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:550: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=grammar -o input.c input.y --warnings=none -Werror --trace=none ./reduce.at:505: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret not-reduced.y -Wnone,none -Werror --trace=none stderr: ./reduce.at:550: sed -n '/^State 0$/,$p' input.output stdout: 181. reduce.at:452: ok ./skeletons.at:128: $PREPARSER ./input-gram ./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y -Wnone,none -Werror --trace=none ./reduce.at:97: sed -n '/^Grammar/q;/^$/!p' input.output ./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none stderr: ./reduce.at:550: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS syntax error, unexpected 'a', expecting end of file ./skeletons.at:128: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none stdout: ./reduce.at:109: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c 173. sets.at:315: ok ./reduce.at:550: $PREPARSER ./input ./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret not-reduced.y --warnings=none -Werror --trace=none ./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y --warnings=none -Werror --trace=none stderr: 163. skeletons.at:85: ok syntax error ./reduce.at:550: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./reduce.at:550: $PREPARSER ./input stderr: ./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none syntax error ./reduce.at:179: sed -n '/^Grammar/q;/^$/!p' input.output 182. reduce.at:550: ok ./reduce.at:550: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./reduce.at:355: sed -n '/^Grammar/q;/^$/!p' not-reduced.output 185. reduce.at:550: testing lr.type=canonical-lr: Single State Split ... ./reduce.at:270: sed -n '/^State 0/q;/^$/!p' input.output ./reduce.at:550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:213: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c 186. reduce.at:783: testing no lr.type: Lane Split ... ./reduce.at:783: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:392: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret reduced.y 183. reduce.at:550: ok ./reduce.at:298: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./reduce.at:434: sed -n '/^Grammar/q;/^$/!p' input.output stderr: ./reduce.at:550: sed -n '/^State 0$/,$p' input.output 187. reduce.at:783: testing lr.type=lalr: Lane Split ... ./reduce.at:783: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:396: sed 's/not-reduced/reduced/g' not-reduced.c stdout: 179. reduce.at:312: ok 176. reduce.at:70: ok 180. reduce.at:406: ok ./reduce.at:783: sed -n '/^State 0$/,$p' input.output ./reduce.at:783: sed -n '/^State 0$/,$p' input.output 188. reduce.at:783: testing lr.type=ielr: Lane Split ... ./reduce.at:783: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./reduce.at:783: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:550: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: ./reduce.at:783: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:550: $PREPARSER ./input 189. reduce.at:783: testing lr.type=canonical-lr: Lane Split ... ./reduce.at:783: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stderr: ./reduce.at:550: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 190. reduce.at:1027: testing no lr.type: Complex Lane Split ... stderr: stderr: ./reduce.at:783: sed -n '/^State 0$/,$p' input.output 184. reduce.at:550: ok stdout: ./reduce.at:1027: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stdout: 192. reduce.at:1027: testing lr.type=ielr: Complex Lane Split ... 191. reduce.at:1027: testing lr.type=lalr: Complex Lane Split ... 177. reduce.at:120: ok ./reduce.at:1027: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y 178. reduce.at:224: ok ./reduce.at:1027: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:783: sed -n '/^State 0$/,$p' input.output ./reduce.at:783: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:783: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:1027: sed -n '/^State 0$/,$p' input.output ./reduce.at:1027: sed -n '/^State 0$/,$p' input.output ./reduce.at:1027: sed -n '/^State 0$/,$p' input.output stderr: stdout: ./reduce.at:1027: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./reduce.at:1027: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: 194. reduce.at:1296: testing no lr.type: Split During Added Lookahead Propagation ... ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y 193. reduce.at:1027: testing lr.type=canonical-lr: Complex Lane Split ... ./output.at:835: $CXX $CPPFLAGS $CXXFLAGS -Iout/ $LDFLAGS -o parser out/x[12].o main.cc $LIBS ./reduce.at:1027: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 195. reduce.at:1296: testing lr.type=lalr: Split During Added Lookahead Propagation ... ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:783: $PREPARSER ./input ./reduce.at:1027: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stderr: syntax error ./reduce.at:783: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./reduce.at:550: $PREPARSER ./input stderr: ./reduce.at:550: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./reduce.at:1027: sed -n '/^State 0$/,$p' input.output ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror 186. reduce.at:783: ok stderr: ./reduce.at:1027: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: ./reduce.at:783: $PREPARSER ./input 185. reduce.at:550: ok stderr: ./reduce.at:783: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: 188. reduce.at:783: ok ./reduce.at:783: $PREPARSER ./input stderr: stdout: ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror stderr: ./reduce.at:783: $PREPARSER ./input syntax error stderr: ./reduce.at:783: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./reduce.at:783: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 189. reduce.at:783: ok 196. reduce.at:1296: testing lr.type=ielr: Split During Added Lookahead Propagation ... ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y 187. reduce.at:783: ok 197. reduce.at:1296: testing lr.type=canonical-lr: Split During Added Lookahead Propagation ... stderr: input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stderr: ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./reduce.at:1296: sed -n '/^State 0$/,$p' input.output ./reduce.at:1296: sed 's,.*/$,,' stderr 1>&2 198. reduce.at:1627: testing no lr.default-reduction ... ./reduce.at:1627: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:1296: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:1296: sed 's,.*/$,,' stderr 1>&2 ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error 199. reduce.at:1627: testing lr.default-reduction=most ... ./reduce.at:1296: sed -n '/^State 0$/,$p' input.output ./reduce.at:1627: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stderr: stdout: 200. reduce.at:1627: testing lr.default-reduction=consistent ... stderr: ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error stderr: ./reduce.at:1296: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:1027: $PREPARSER ./input stderr: stderr: ./reduce.at:1627: sed -n '/^State 0$/,$p' input.output stdout: stdout: ./reduce.at:1627: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:1027: $PREPARSER ./input stdout: ./reduce.at:1027: $PREPARSER ./input stderr: syntax error syntax error ./reduce.at:1027: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./reduce.at:1027: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./reduce.at:1027: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./reduce.at:1627: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:1027: $PREPARSER ./input ./reduce.at:1627: sed -n '/^State 0$/,$p' input.output 193. reduce.at:1027: ok stderr: ./reduce.at:1027: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./reduce.at:1627: sed -n '/^State 0$/,$p' input.output ./reduce.at:1627: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 191. reduce.at:1027: ok 192. reduce.at:1027: ok 190. reduce.at:1027: ok ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./reduce.at:1627: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./reduce.at:1296: $PREPARSER ./input stderr: ./reduce.at:1296: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./reduce.at:1296: sed -n '/^State 0$/,$p' input.output ./reduce.at:1296: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 202. report.at:37: testing Reports ... 201. reduce.at:1627: testing lr.default-reduction=accepting ... ./reduce.at:1627: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y 196. reduce.at:1296: ok 203. report.at:3123: testing Reports with conflicts ... ./reduce.at:1296: sed -n '/^State 0$/,$p' input.output stderr: 202. report.at:37: ./reduce.at:1627: sed -n '/^State 0$/,$p' input.output stdout: skipped (report.at:75) ./reduce.at:1296: $PREPARSER ./input stderr: ./reduce.at:1627: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:1296: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 197. reduce.at:1296: 204. conflicts.at:28: testing Token declaration order ... ./conflicts.at:81: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ok stdout: ./reduce.at:1296: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 203. report.at:3123: ./reduce.at:1627: $PREPARSER ./input skipped (report.at:3132) stderr: ./reduce.at:1627: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:82: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 205. conflicts.at:101: testing Token declaration order: literals vs. identifiers ... ./conflicts.at:130: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all -o input.c input.y 198. reduce.at:1627: 206. conflicts.at:183: testing Useless associativity warning ... ./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wprecedence input.y ok 207. conflicts.at:218: testing Useless precedence warning ... ./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y stderr: stdout: ./reduce.at:1627: $PREPARSER ./input stderr: ./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence input.y -Werror ./reduce.at:1627: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 208. conflicts.at:275: testing S/R in initial ... ./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: stdout: ./reduce.at:1627: $PREPARSER ./input 200. reduce.at:1627: ok ./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y -Werror ./reduce.at:1627: $PREPARSER ./input stderr: stderr: ./reduce.at:1627: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./reduce.at:1627: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stderr: 201. reduce.at:1627: ok 199. reduce.at:1627: ok stdout: ./conflicts.at:84: $PREPARSER ./input ./conflicts.at:131: cat input.output | sed -n '/^State 0$/,/^State 1$/p' stderr: stderr: 209. conflicts.at:301: testing %nonassoc and eof ... ./conflicts.at:368: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:84: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input.y:2.1-9: error: useless precedence and associativity for "=" [-Werror=precedence] input.y:4.1-5: error: useless associativity for "*", use %precedence [-Werror=precedence] input.y:5.1-11: error: useless precedence for "(" [-Werror=precedence] ./reduce.at:1296: $PREPARSER ./input ./conflicts.at:205: sed 's,.*/$,,' stderr 1>&2 stderr: 205. conflicts.at:101: stderr: ok input.y:7.1-9: error: useless precedence and associativity for U [-Werror=precedence] 7 | %nonassoc U | ^~~~~~~~~ input.y:6.1-6: error: useless precedence and associativity for V [-Werror=precedence] 6 | %right V | ^~~~~~ input.y:5.1-5: error: useless precedence and associativity for W [-Werror=precedence] 5 | %left W | ^~~~~ input.y:2.1-11: error: useless precedence for Z [-Werror=precedence] 2 | %precedence Z | ^~~~~~~~~~~ 204. conflicts.at:28: ok stderr: ./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence input.y --warnings=error ./conflicts.at:368: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: ./conflicts.at:248: sed 's,.*/$,,' stderr 1>&2 211. conflicts.at:513: testing parse.error=verbose and consistent errors: lr.type=ielr %glr-parser ... ./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror 210. conflicts.at:509: testing parse.error=verbose and consistent errors: lr.type=ielr ... ./conflicts.at:513: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y syntax error ./reduce.at:1296: $PREPARSER ./input ./reduce.at:1296: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./conflicts.at:509: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y --warnings=error syntax error ./reduce.at:1296: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 195. reduce.at:1296: ok stderr: 194. reduce.at:1296: ok input.y:4.10-15: error: rule useless in parser due to conflicts [-Werror=other] ./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence input.y -Wnone,none -Werror --trace=none 212. conflicts.at:518: testing parse.error=verbose and consistent errors: lr.type=ielr c++ ... ./conflicts.at:509: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:518: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 214. conflicts.at:530: testing parse.error=verbose and consistent errors: lr.type=ielr lr.default-reduction=consistent ... ./conflicts.at:530: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 213. conflicts.at:523: testing parse.error=verbose and consistent errors: lr.type=ielr java ... ./conflicts.at:284: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:523: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.java input.y ./conflicts.at:513: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y -Wnone,none -Werror --trace=none ./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence input.y --warnings=none -Werror --trace=none ./conflicts.at:530: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 215. conflicts.at:535: testing parse.error=verbose and consistent errors: lr.type=ielr lr.default-reduction=accepting ... ./conflicts.at:535: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:518: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 216. conflicts.at:540: testing parse.error=verbose and consistent errors: lr.type=canonical-lr ... ./conflicts.at:540: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error ./conflicts.at:535: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 213. conflicts.at:523: 206. conflicts.at:183: skipped (conflicts.at:523) ok ./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y --warnings=none -Werror --trace=none ./conflicts.at:540: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none 217. conflicts.at:546: testing parse.error=verbose and consistent errors: lr.type=canonical-lr parse.lac=full ... ./conflicts.at:546: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 207. conflicts.at:218: ok ./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none 218. conflicts.at:551: testing parse.error=verbose and consistent errors: lr.type=ielr parse.lac=full ... ./conflicts.at:551: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: ./conflicts.at:368: $PREPARSER ./input '0<0' stderr: ./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:368: $PREPARSER ./input '0<0<0' stderr: syntax error, unexpected '<' ./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:546: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:368: $PREPARSER ./input '0>0' ./conflicts.at:551: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o input.c input.y 219. conflicts.at:558: testing parse.error=verbose and consistent errors: c++ lr.type=canonical-lr parse.lac=full ... ./conflicts.at:558: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: ./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:368: $PREPARSER ./input '0>0>0' stderr: syntax error, unexpected '>' ./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:558: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./conflicts.at:368: $PREPARSER ./input '0<0>0' stderr: stderr: stdout: syntax error, unexpected '>' ./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:509: $PREPARSER ./input stderr: ./conflicts.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.default-reduction=consistent -o input.c input.y ./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Werror syntax error, unexpected end of file ./conflicts.at:509: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 210. conflicts.at:509: ok stdout: ./conflicts.at:530: $PREPARSER ./input stderr: syntax error, unexpected end of file, expecting 'a' or 'b' ./conflicts.at:530: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 214. conflicts.at:530: ok input.y:4.10-15: error: rule useless in parser due to conflicts [-Werror=other] 4 | e: 'e' | %empty; | ^~~~~~ ./conflicts.at:372: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:288: sed 's,.*/$,,' stderr 1>&2 stderr: ./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=error 220. conflicts.at:564: testing parse.error=verbose and consistent errors: c++ lr.type=ielr parse.lac=full ... stderr: stdout: ./conflicts.at:540: $PREPARSER ./input stdout: 221. conflicts.at:622: testing parse.error=verbose and consistent errors: ... ./conflicts.at:622: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: ./conflicts.at:535: $PREPARSER ./input syntax error, unexpected end of file, expecting 'a' or 'b' ./conflicts.at:540: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:564: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stderr: stdout: stderr: syntax error, unexpected end of file, expecting 'a' or 'b' ./conflicts.at:535: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./output.at:836: $PREPARSER ./parser ./conflicts.at:546: $PREPARSER ./input stderr: stderr: syntax error, unexpected end of file, expecting 'b' 216. conflicts.at:540: ok ./conflicts.at:546: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:622: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./output.at:836: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Wnone,none -Werror --trace=none 215. conflicts.at:535: ok 144. output.at:744: ok 217. conflicts.at:546: ok ./conflicts.at:564: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=none -Werror --trace=none 222. conflicts.at:626: testing parse.error=verbose and consistent errors: %glr-parser ... ./conflicts.at:626: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: 224. conflicts.at:638: testing parse.error=verbose and consistent errors: lr.default-reduction=accepting ... ./conflicts.at:638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:551: $PREPARSER ./input 223. conflicts.at:632: testing parse.error=verbose and consistent errors: lr.default-reduction=consistent ... stderr: stderr: syntax error, unexpected end of file, expecting 'b' ./conflicts.at:551: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:632: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stdout: stderr: ./conflicts.at:513: $PREPARSER ./input stdout: ./conflicts.at:626: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:372: $PREPARSER ./input '0<0' stderr: stderr: 225. conflicts.at:642: testing parse.error=verbose and consistent errors: lr.type=canonical-lr ... syntax error, unexpected end of file ./conflicts.at:513: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:642: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:638: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 208. conflicts.at:275: ok ./conflicts.at:372: $PREPARSER ./input '0<0<0' stderr: syntax error, unexpected '<', expecting end of file ./conflicts.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 218. conflicts.at:551: ok 211. conflicts.at:513: ok ./conflicts.at:632: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:372: $PREPARSER ./input '0>0' stderr: ./conflicts.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:642: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:372: $PREPARSER ./input '0>0>0' stderr: syntax error, unexpected '>', expecting end of file ./conflicts.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 226. conflicts.at:647: testing parse.error=verbose and consistent errors: parse.lac=full ... ./conflicts.at:647: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:372: $PREPARSER ./input '0<0>0' 227. conflicts.at:651: testing parse.error=verbose and consistent errors: parse.lac=full lr.default-reduction=accepting ... ./conflicts.at:651: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: 228. conflicts.at:676: testing LAC: %nonassoc requires splitting canonical LR states ... syntax error, unexpected '>', expecting end of file ./conflicts.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y ./conflicts.at:647: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:381: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y ./conflicts.at:651: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y -Werror ./conflicts.at:381: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: input.y: error: 2 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./conflicts.at:726: sed 's,.*/$,,' stderr 1>&2 stderr: stdout: ./conflicts.at:622: $PREPARSER ./input stderr: ./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y --warnings=error syntax error, unexpected 'b' ./conflicts.at:622: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 221. conflicts.at:622: ok stderr: ./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y -Wnone,none -Werror --trace=none stdout: ./conflicts.at:638: $PREPARSER ./input stderr: syntax error, unexpected end of file, expecting 'a' ./conflicts.at:638: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 229. conflicts.at:764: testing Unresolved SR Conflicts ... ./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c --report=all input.y stderr: ./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y --warnings=none -Werror --trace=none stdout: 224. conflicts.at:638: ok ./conflicts.at:632: $PREPARSER ./input stderr: stderr: stdout: syntax error, unexpected 'b' ./conflicts.at:632: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:381: $PREPARSER ./input '0<0' stderr: ./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 223. conflicts.at:632: ok ./conflicts.at:381: $PREPARSER ./input '0<0<0' ./conflicts.at:731: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y -Werror syntax error, unexpected '<', expecting end of file ./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 230. conflicts.at:887: testing Resolved SR Conflicts ... ./conflicts.at:898: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c --report=all input.y ./conflicts.at:381: $PREPARSER ./input '0>0' stdout: stderr: ./conflicts.at:642: $PREPARSER ./input ./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected end of file, expecting 'a' ./conflicts.at:642: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./conflicts.at:381: $PREPARSER ./input '0>0>0' input.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples 225. conflicts.at:642: ok stderr: ./conflicts.at:901: cat input.output syntax error, unexpected '>', expecting end of file ./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:774: sed 's,.*/$,,' stderr 1>&2 231. conflicts.at:989: testing %precedence suffices ... ./conflicts.at:1006: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 230. conflicts.at:887: ok ./conflicts.at:381: $PREPARSER ./input '0<0>0' ./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y --warnings=error stderr: syntax error, unexpected '>', expecting end of file ./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 231. conflicts.at:989: ok stderr: ./conflicts.at:388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -o input.c input.y 232. conflicts.at:1015: testing %precedence does not suffice ... ./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stdout: stderr: ./conflicts.at:647: $PREPARSER ./input stderr: stdout: ./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y -Wnone,none -Werror --trace=none stderr: syntax error, unexpected 'b' ./conflicts.at:647: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:518: $PREPARSER ./input stdout: ./conflicts.at:651: $PREPARSER ./input stderr: 233. conflicts.at:1096: testing Syntax error in consistent error state: yacc.c ... ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: syntax error, unexpected end of file ./conflicts.at:388: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:518: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected end of file ./conflicts.at:651: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 226. conflicts.at:647: ok ./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror 234. conflicts.at:1096: testing Syntax error in consistent error state: glr.c ... 212. conflicts.at:518: ok ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 227. conflicts.at:651: ok ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror ./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y --warnings=none -Werror --trace=none stderr: input.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:12.3-18: error: rule useless in parser due to conflicts [-Werror=other] ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror 235. conflicts.at:1096: testing Syntax error in consistent error state: lalr1.cc ... ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./conflicts.at:780: cat input.output ./conflicts.at:1033: sed 's,.*/$,,' stderr 1>&2 stderr: 236. conflicts.at:1096: testing Syntax error in consistent error state: glr.cc ... ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y input.y:17.5-25: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.5-29: error: rule useless in parser due to conflicts [-Werror=other] 229. conflicts.at:764: ok 237. conflicts.at:1096: testing Syntax error in consistent error state: glr2.cc ... ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Werror ./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error stderr: input.y:17.5-25: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.5-29: error: rule useless in parser due to conflicts [-Werror=other] stderr: stderr: ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Werror ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error input.y:17.5-25: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.5-29: error: rule useless in parser due to conflicts [-Werror=other] stderr: stdout: ./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 stdout: ./conflicts.at:558: $PREPARSER ./input ./conflicts.at:626: $PREPARSER ./input stderr: stderr: stderr: stdout: syntax error, unexpected end of file, expecting 'b' ./conflicts.at:558: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:732: $PREPARSER ./input syntax error, unexpected 'b' ./conflicts.at:626: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error stderr: syntax error, unexpected 'a', expecting 'b' ./conflicts.at:732: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 238. conflicts.at:1127: testing Defaulted Conflicted Reduction ... ./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c --report=all input.y stderr: ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Werror ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none stdout: ./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none ./conflicts.at:388: $PREPARSER ./input '0<0' 219. conflicts.at:558: ok stderr: 222. conflicts.at:626: ok ./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ -o input.c input.y ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=error stderr: input.y:17.5-25: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.5-29: error: rule useless in parser due to conflicts [-Werror=other] ./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:388: $PREPARSER ./input '0<0<0' ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none stderr: stderr: syntax error, unexpected '<', expecting end of file ./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input.y:17.5-25: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.5-29: error: rule useless in parser due to conflicts [-Werror=other] ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none ./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y -Werror ./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none ./conflicts.at:388: $PREPARSER ./input '0>0' ./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=error stderr: ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none ./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 239. conflicts.at:1264: testing %expect not enough ... ./conflicts.at:1273: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Wnone,none -Werror --trace=none 240. conflicts.at:1284: testing %expect right ... ./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ -o input.c input.y -Werror ./conflicts.at:1293: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: ./conflicts.at:388: $PREPARSER ./input '0>0>0' 239. conflicts.at:1264: ok input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:4.6-8: error: rule useless in parser due to conflicts [-Werror=other] ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=error stderr: syntax error, unexpected '>', expecting end of file ./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 232. conflicts.at:1015: ok ./conflicts.at:1138: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:1096: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:388: $PREPARSER ./input '0<0>0' ./conflicts.at:1096: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y --warnings=error stderr: ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=none -Werror --trace=none syntax error, unexpected '>', expecting end of file ./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 240. conflicts.at:1284: ok stderr: ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Wnone,none -Werror --trace=none input.y: error: 2 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples 209. conflicts.at:301: ok ./conflicts.at:737: sed 's,.*/$,,' stderr 1>&2 241. conflicts.at:1301: testing %expect too much ... ./conflicts.at:1310: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Wnone,none -Werror --trace=none ./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y -Wnone,none -Werror --trace=none 242. conflicts.at:1321: testing %expect with reduce conflicts ... ./conflicts.at:1330: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=none -Werror --trace=none ./conflicts.at:1096: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ -o input.c input.y --warnings=error 241. conflicts.at:1301: ok 242. conflicts.at:1321: ok 243. conflicts.at:1341: testing %expect in grammar rule not enough ... ./conflicts.at:1350: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=none -Werror --trace=none ./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y --warnings=none -Werror --trace=none 244. conflicts.at:1360: testing %expect in grammar rule right ... ./conflicts.at:1369: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 243. conflicts.at:1341: ok ./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ -o input.c input.y -Wnone,none -Werror --trace=none ./conflicts.at:1096: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./conflicts.at:1096: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 244. conflicts.at:1360: ok ./conflicts.at:1145: cat input.output 245. conflicts.at:1377: testing %expect in grammar rules ... ./conflicts.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -rall input.y ./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ -o input.c input.y --warnings=none -Werror --trace=none 238. conflicts.at:1127: ok 246. conflicts.at:1396: testing %expect in grammar rule too much ... ./conflicts.at:1405: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y 247. conflicts.at:1415: testing %expect-rr in grammar rule ... ./conflicts.at:1432: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 246. conflicts.at:1396: ok 248. conflicts.at:1440: testing %expect-rr too much in grammar rule ... 245. conflicts.at:1377: ok ./conflicts.at:1457: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y 247. conflicts.at:1415: ok 249. conflicts.at:1469: testing %expect-rr not enough in grammar rule ... 248. conflicts.at:1440: ok ./conflicts.at:1486: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y ./conflicts.at:742: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 249. conflicts.at:1469: ok stderr: 250. conflicts.at:1498: testing %prec with user string ... ./conflicts.at:1507: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stdout: ./conflicts.at:1096: $PREPARSER ./input stderr: 251. conflicts.at:1515: testing %no-default-prec without %prec ... ./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall -o input.c input.y syntax error ./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 250. conflicts.at:1498: ok 252. conflicts.at:1544: testing %no-default-prec with %prec ... ./conflicts.at:1560: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 233. conflicts.at:1096: ok 253. conflicts.at:1568: testing %default-prec ... ./conflicts.at:1584: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y -Werror 254. conflicts.at:1592: testing Unreachable States After Conflict Resolution ... ./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all input.y 252. conflicts.at:1544: ok 253. conflicts.at:1568: ok 255. conflicts.at:1855: testing Solved conflicts report for multiple reductions in a state ... ./conflicts.at:1881: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all -o input.c input.y ./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=all input.y -Werror stderr: 256. conflicts.at:1935: testing %nonassoc error actions for multiple reductions in a state ... ./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y input.y: error: 4 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:1.1-5: error: useless precedence and associativity for '+' [-Werror=precedence] input.y:2.1-5: error: useless precedence and associativity for '*' [-Werror=precedence] stderr: ./conflicts.at:1531: sed 's,.*/$,,' stderr 1>&2 stdout: stderr: input.y:7.5-7: warning: rule useless in parser due to conflicts [-Wother] input.y:11.5-7: warning: rule useless in parser due to conflicts [-Wother] input.y:17.11-26: warning: rule useless in parser due to conflicts [-Wother] input.y:18.11-26: warning: rule useless in parser due to conflicts [-Wother] input.y:19.11-26: warning: rule useless in parser due to conflicts [-Wother] ./conflicts.at:1882: cat input.output | sed -n '/^State 0$/,/^State 1$/p' ./conflicts.at:564: $PREPARSER ./input stderr: stderr: syntax error, unexpected end of file, expecting 'b' input.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:12.5-20: error: rule useless in parser due to conflicts [-Werror=other] input.y:20.5-20: error: rule useless in parser due to conflicts [-Werror=other] input.y:21.4: error: rule useless in parser due to conflicts [-Werror=other] input.y:25.14: error: rule useless in parser due to conflicts [-Werror=other] input.y:25.16: error: rule useless in parser due to conflicts [-Werror=other] input.y:31.5-7: error: rule useless in parser due to conflicts [-Werror=other] input.y:32.4: error: rule useless in parser due to conflicts [-Werror=other] ./conflicts.at:564: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 255. conflicts.at:1855: ok ./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y --warnings=error 220. conflicts.at:564: ok ./conflicts.at:1638: sed 's,.*/$,,' stderr 1>&2 257. conflicts.at:2299: testing %expect-rr non GLR ... ./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret 1.y 258. conflicts.at:2331: testing -W versus %expect and %expect-rr ... ./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y -Werror ./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret sr-rr.y ./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=all input.y --warnings=error ./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y -Wnone,none -Werror --trace=none ./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y -Werror stderr: bison (GNU Bison) 3.8.2 init: 0.000000 # state items: 26 State 0: 0 $accept: . start $end -> 0 $accept: start . $end => 2 start: . empty_a 'a' => 4 start: . empty_b 'b' => 6 start: . empty_c1 'c' => 7 start: . empty_c2 'c' => 8 start: . empty_c3 'c' 1 start: . 'a' DISABLED 2 start: . empty_a 'a' -> 2 start: empty_a . 'a' => 9 empty_a: %empty . <- 0 $accept: . start $end 3 start: . 'b' DISABLED 4 start: . empty_b 'b' -> 4 start: empty_b . 'b' => 10 empty_b: %empty . <- 0 $accept: . start $end 5 start: . 'c' DISABLED 6 start: . empty_c1 'c' -> 6 start: empty_c1 . 'c' => 11 empty_c1: %empty . <- 0 $accept: . start $end 7 start: . empty_c2 'c' -> 7 start: empty_c2 . 'c' => 12 empty_c2: %empty . <- 0 $accept: . start $end 8 start: . empty_c3 'c' -> 8 start: empty_c3 . 'c' => 13 empty_c3: %empty . <- 0 $accept: . start $end 9 empty_a: %empty . <- 2 start: . empty_a 'a' 10 empty_b: %empty . <- 4 start: . empty_b 'b' 11 empty_c1: %empty . <- 6 start: . empty_c1 'c' 12 empty_c2: %empty . <- 7 start: . empty_c2 'c' 13 empty_c3: %empty . <- 8 start: . empty_c3 'c' State 1: 0 $accept: start . $end -> 0 $accept: start $end . <- 0 $accept: . start $end State 2: 2 start: empty_a . 'a' -> 2 start: empty_a 'a' . <- 2 start: . empty_a 'a' State 3: 4 start: empty_b . 'b' -> 4 start: empty_b 'b' . <- 4 start: . empty_b 'b' State 4: 6 start: empty_c1 . 'c' -> 6 start: empty_c1 'c' . <- 6 start: . empty_c1 'c' State 5: 7 start: empty_c2 . 'c' -> 7 start: empty_c2 'c' . <- 7 start: . empty_c2 'c' State 6: 8 start: empty_c3 . 'c' -> 8 start: empty_c3 'c' . <- 8 start: . empty_c3 'c' State 7: 0 $accept: start $end . <- 0 $accept: start . $end State 8: 2 start: empty_a 'a' . <- 2 start: empty_a . 'a' State 9: 4 start: empty_b 'b' . <- 4 start: empty_b . 'b' State 10: 6 start: empty_c1 'c' . <- 6 start: empty_c1 . 'c' State 11: 7 start: empty_c2 'c' . <- 7 start: empty_c2 . 'c' State 12: 8 start: empty_c3 'c' . <- 8 start: empty_c3 . 'c' FIRSTS $accept firsts 'a' 'b' 'c' start firsts 'a' 'b' 'c' empty_a firsts empty_b firsts empty_c1 firsts empty_c2 firsts empty_c3 firsts input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:4.5-7: error: rule useless in parser due to conflicts [-Werror=other] 4 | 'a' | ^~~ input.y:6.5-7: error: rule useless in parser due to conflicts [-Werror=other] 6 | | 'b' | ^~~ input.y:8.5-7: error: rule useless in parser due to conflicts [-Werror=other] 8 | | 'c' | ^~~ input.y:13.10-18: error: rule useless in parser due to conflicts [-Werror=other] 13 | empty_a: %prec 'a' ; | ^~~~~~~~~ input.y:14.10-18: error: rule useless in parser due to conflicts [-Werror=other] 14 | empty_b: %prec 'b' ; | ^~~~~~~~~ input.y:15.11-19: error: rule useless in parser due to conflicts [-Werror=other] 15 | empty_c1: %prec 'c' ; | ^~~~~~~~~ input.y:16.11-19: error: rule useless in parser due to conflicts [-Werror=other] 16 | empty_c2: %prec 'c' ; | ^~~~~~~~~ input.y:17.11-19: error: rule useless in parser due to conflicts [-Werror=other] 17 | empty_c3: %prec 'c' ; | ^~~~~~~~~ REDUCE ITEM PATH: 0 $accept: . start $end 7 start: . empty_c2 'c' 12 empty_c2: %empty . CONFLICT 1 (size 1 depth 0 rc 2) 12 empty_c2: %empty . 12 empty_c2: %empty . . CONFLICT 2 (size 1 depth 0 rc 2) 13 empty_c3: %empty . 13 empty_c3: %empty . . CONFLICT 1 (size 2 depth -1 rc 4) 7 start: . empty_c2 'c' 7 start: empty_c2 . 'c' empty_c2 `-> 12: %empty . CONFLICT 2 (size 1 depth 0 rc 3) 13 empty_c3: %empty . 13 empty_c3: %empty . . CONFLICT 1 (size 1 depth 0 rc 3) 12 empty_c2: %empty . 12 empty_c2: %empty . . CONFLICT 2 (size 2 depth -1 rc 2) 8 start: . empty_c3 'c' 8 start: empty_c3 . 'c' empty_c3 `-> 13: %empty . CONFLICT 1 (size 2 depth -1 rc 3) 7 start: . empty_c2 'c' 7 start: empty_c2 . 'c' empty_c2 `-> 12: %empty . CONFLICT 2 (size 2 depth -1 rc 2) 8 start: . empty_c3 'c' 8 start: empty_c3 . 'c' empty_c3 `-> 13: %empty . CONFLICT 1 (size 3 depth -1 rc 2) 7 start: . empty_c2 'c' 7 start: empty_c2 'c' . empty_c2 `-> 12: %empty . CONFLICT 2 (size 3 depth -1 rc 2) 8 start: . empty_c3 'c' 8 start: empty_c3 'c' . empty_c3 `-> 13: %empty . CONFLICT 1 (size 2 depth -1 rc 4) 0 $accept: . start $end 0 $accept: start . $end start `-> 7: empty_c2 'c' `-> 12: %empty . CONFLICT 2 (size 3 depth -1 rc 3) 8 start: . empty_c3 'c' 8 start: empty_c3 'c' . empty_c3 `-> 13: %empty . CONFLICT 1 (size 3 depth -1 rc 3) 7 start: . empty_c2 'c' 7 start: empty_c2 'c' . empty_c2 `-> 12: %empty . CONFLICT 2 (size 2 depth -1 rc 2) 0 $accept: . start $end 0 $accept: start . $end start `-> 8: empty_c3 'c' `-> 13: %empty . CONFLICT 1 (size 2 depth -1 rc 3) 0 $accept: . start $end 0 $accept: start . $end start `-> 7: empty_c2 'c' `-> 12: %empty . CONFLICT 2 (size 2 depth -1 rc 2) 0 $accept: . start $end 0 $accept: start . $end start `-> 8: empty_c3 'c' `-> 13: %empty . ./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret sr-rr.y -Werror 259. counterexample.at:43: testing Unifying S/R ... 260. counterexample.at:83: testing Deep Unifying S/R ... ./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=all input.y -Wnone,none -Werror --trace=none ./counterexample.at:55: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: ./counterexample.at:95: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 1.y: error: %expect-rr applies only to GLR parsers [-Werror=other] ./conflicts.at:1959: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:2307: sed 's,.*/$,,' stderr 1>&2 stderr: ./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y --warnings=none -Werror --trace=none stderr: ./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y --warnings=error sr-rr.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] sr-rr.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] sr-rr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=all input.y --warnings=none -Werror --trace=none input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: A . B C Shift derivation s `-> 2: y c `-> 8: A . B `-> 4: C Reduce derivation s `-> 1: a x `-> 3: A . `-> 6: B C input.y:4.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:55: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y --warnings=error stderr: ./conflicts.at:2354: sed 's,.*/$,,' stderr 1>&2 ./counterexample.at:55: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: A . B C Shift derivation s `-> 1: ac `-> 3: A ac C `-> 4: b `-> 5: . B Reduce derivation s `-> 2: a bc `-> 7: A . `-> 10: B C input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: A A . B B C C Shift derivation s `-> 1: ac `-> 3: A ac C `-> 3: A ac C `-> 4: b `-> 6: . b `-> 5: B B Reduce derivation s `-> 2: a bc `-> 8: A a `-> 9: B bc C `-> 7: A . `-> 10: B C input.y:6.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:95: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./counterexample.at:95: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:1651: cat input.output ./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y -Wnone,none -Werror --trace=none ./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret sr-rr.y --warnings=error stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example A . B C Shift derivation s -> [ y -> [ A . B ] c -> [ C ] ] Reduce derivation s -> [ a -> [ A . ] x -> [ B C ] ] input.y:4.4: warning: rule useless in parser due to conflicts [-Wother] ./conflicts.at:1836: cat input.y >> input-keep.y 251. conflicts.at:1515: ok ./counterexample.at:55: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr ./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y -Wnone,none -Werror --trace=none ./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input-keep.y stderr: 259. counterexample.at:43: ok input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example A . B C Shift derivation s -> [ ac -> [ A ac -> [ b -> [ . B ] ] C ] ] Reduce derivation s -> [ a -> [ A . ] bc -> [ B C ] ] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example A A . B B C C Shift derivation s -> [ ac -> [ A ac -> [ A ac -> [ b -> [ . b -> [ B B ] ] ] C ] C ] ] Reduce derivation s -> [ a -> [ A a -> [ A . ] ] bc -> [ B bc -> [ B C ] C ] ] input.y:6.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:95: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr stderr: ./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y --warnings=none -Werror --trace=none ./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret sr-rr.y -Wnone,none -Werror --trace=none stdout: 260. counterexample.at:83: ok ./conflicts.at:743: $PREPARSER ./input ./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y --warnings=none -Werror --trace=none stderr: syntax error, unexpected 'a', expecting 'b' or 'c' ./conflicts.at:743: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret sr-rr.y --warnings=none -Werror --trace=none 261. counterexample.at:144: testing S/R Conflict with Nullable Symbols ... ./counterexample.at:157: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:2239: cat input.output | sed -n '/^State 0$/,/^State 1$/p' ./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y ./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-keep.y -Werror 256. conflicts.at:1935: ok 262. counterexample.at:207: testing Non-unifying Ambiguous S/R ... ./counterexample.at:220: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret 2.y ./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y 263. counterexample.at:254: testing Non-unifying Unambiguous S/R ... ./counterexample.at:265: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: stderr: input.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: A . B Shift derivation s `-> 2: A xby `-> 9: . B Reduce derivation s `-> 1: ax by `-> 3: A x `-> 6: B y `-> 4: %empty . `-> 6: %empty input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] First example: A X . B Y $end Shift derivation $accept `-> 0: s $end `-> 2: A xby `-> 10: X xby Y `-> 9: . B Second example: A X . B y $end Reduce derivation $accept `-> 0: s $end `-> 1: ax by `-> 3: A x `-> 6: B y `-> 5: X x `-> 4: %empty . input.y:5.4-9: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:157: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr input-keep.y: error: 2 shift/reduce conflicts [-Werror=conflicts-sr] input-keep.y: error: 2 reduce/reduce conflicts [-Werror=conflicts-rr] input-keep.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input-keep.y:22.4: error: rule useless in parser due to conflicts [-Werror=other] input-keep.y:26.16: error: rule useless in parser due to conflicts [-Werror=other] input-keep.y:32.5-7: error: rule useless in parser due to conflicts [-Werror=other] input-keep.y:33.4: error: rule useless in parser due to conflicts [-Werror=other] ./counterexample.at:157: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token C [-Wcounterexamples] First example: B . C $end Shift derivation $accept `-> 0: g $end `-> 2: x `-> 6: bc `-> 9: B . C Second example: B . C D $end Reduce derivation $accept `-> 0: g $end `-> 2: x `-> 5: b cd `-> 7: B . `-> 8: C D input.y:6.4: warning: rule useless in parser due to conflicts [-Wother] ./conflicts.at:1838: sed 's,.*/$,,' stderr 1>&2 ./counterexample.at:220: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] First example: A . A B $end Shift derivation $accept `-> 0: s $end `-> 1: t `-> 4: y `-> 6: A . A B Second example: A . A $end Reduce derivation $accept `-> 0: s $end `-> 2: s t `-> 1: t `-> 3: x `-> 3: x `-> 5: A `-> 5: A . ./counterexample.at:265: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr 264. counterexample.at:298: testing S/R after first token ... ./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y -Werror ./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y -Werror ./counterexample.at:220: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: input.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example A . B Shift derivation s -> [ A xby -> [ . B ] ] Reduce derivation s -> [ ax -> [ A x -> [ . ] ] by -> [ B y -> [ ] ] ] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] First example A X . B Y $end Shift derivation $accept -> [ s -> [ A xby -> [ X xby -> [ . B ] Y ] ] $end ] Second example A X . B y $end Reduce derivation $accept -> [ s -> [ ax -> [ A x -> [ X x -> [ . ] ] ] by -> [ B y ] ] $end ] input.y:5.4-9: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:157: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr ./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-keep.y --warnings=error ./counterexample.at:265: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 2.y -Werror ./counterexample.at:314: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 261. counterexample.at:144: ok stderr: stderr: stderr: sr-rr.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] sr-rr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token C [-Wcounterexamples] First example B . C $end Shift derivation $accept -> [ g -> [ x -> [ bc -> [ B . C ] ] ] $end ] Second example B . C D $end Reduce derivation $accept -> [ g -> [ x -> [ b -> [ B . ] cd -> [ C D ] ] ] $end ] input.y:6.4: warning: rule useless in parser due to conflicts [-Wother] input.y: error: 2 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./counterexample.at:220: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr stderr: stderr: 2.y: error: %expect-rr applies only to GLR parsers [-Werror=other] 2.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] 2.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples 2.y:3.12-14: error: rule useless in parser due to conflicts [-Werror=other] input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] First example A . A B $end Shift derivation $accept -> [ s -> [ t -> [ y -> [ A . A B ] ] ] $end ] Second example A . A $end Reduce derivation $accept -> [ s -> [ s -> [ t -> [ x -> [ A . ] ] ] t -> [ x -> [ A ] ] ] $end ] stderr: ./counterexample.at:265: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr input.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] Example: b . A X X Y Shift derivation a `-> 2: s `-> 7: b . xx y `-> 9: A X X `-> 11: Y Reduce derivation a `-> 1: r t `-> 3: b . `-> 6: A x xy `-> 8: X `-> 10: X Y input.y: warning: shift/reduce conflict on token X [-Wcounterexamples] First example: A X . X Shift derivation a `-> 1: t `-> 5: A xx `-> 9: X . X Second example: X . X xy Reduce derivation a `-> 1: x t `-> 8: X . `-> 6: X xy input.y:4.4: warning: rule useless in parser due to conflicts [-Wother] input.y:8.4: warning: rule useless in parser due to conflicts [-Wother] ./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-keep.y -Wnone,none -Werror --trace=none ./counterexample.at:314: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr 262. counterexample.at:207: ok ./conflicts.at:748: sed 's,.*/$,,' stderr 1>&2 ./counterexample.at:314: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:2359: sed 's,.*/$,,' stderr 1>&2 stderr: 263. counterexample.at:254: ./conflicts.at:2317: sed 's,.*/$,,' stderr 1>&2 ok stdout: ./conflicts.at:1096: $PREPARSER ./input 265. counterexample.at:363: testing Unifying R/R counterexample ... stderr: ./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y --warnings=error ./counterexample.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y syntax error ./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y --warnings=error ./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 2.y --warnings=error ./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-keep.y --warnings=none -Werror --trace=none 234. conflicts.at:1096: ok stderr: stderr: input.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] Example: A b . First reduce derivation a `-> 1: A b . Second reduce derivation a `-> 1: A b `-> 3: b . input.y:4.9: warning: rule useless in parser due to conflicts [-Wother] input.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] Example b . A X X Y Shift derivation a -> [ s -> [ b . xx -> [ A X X ] y -> [ Y ] ] ] Reduce derivation a -> [ r -> [ b . ] t -> [ A x -> [ X ] xy -> [ X Y ] ] ] input.y: warning: shift/reduce conflict on token X [-Wcounterexamples] First example A X . X Shift derivation a -> [ t -> [ A xx -> [ X . X ] ] ] Second example X . X xy Reduce derivation a -> [ x -> [ X . ] t -> [ X xy ] ] input.y:4.4: warning: rule useless in parser due to conflicts [-Wother] input.y:8.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:314: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr ./counterexample.at:372: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y -Wnone,none -Werror --trace=none ./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 2.y -Wnone,none -Werror --trace=none 267. counterexample.at:441: testing Non-unifying R/R LR(2) conflict ... ./counterexample.at:451: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 266. counterexample.at:399: testing Non-unifying R/R LR(1) conflict ... ./counterexample.at:372: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 264. counterexample.at:298: ok ./counterexample.at:409: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y -Wnone,none -Werror --trace=none 254. conflicts.at:1592: ok ./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 2.y --warnings=none -Werror --trace=none ./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y --warnings=none -Werror --trace=none stderr: 268. counterexample.at:488: testing Cex Search Prepend ... input.y: warning: 2 reduce/reduce conflicts [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on tokens A, C [-Wcounterexamples] First example: D . A $end First reduce derivation $accept `-> 0: s $end `-> 1: a A `-> 5: D . Second example: B D . A $end Second reduce derivation $accept `-> 0: s $end `-> 4: B b A `-> 6: D . input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:409: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./counterexample.at:499: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: input.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] Example A b . First reduce derivation a -> [ A b . ] Second reduce derivation a -> [ A b -> [ b . ] ] input.y:4.9: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:372: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr ./counterexample.at:409: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 265. counterexample.at:363: ok ./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y --warnings=none -Werror --trace=none 257. conflicts.at:2299: ok 269. counterexample.at:550: testing R/R cex with prec ... stderr: stderr: ./counterexample.at:562: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 270. counterexample.at:610: testing Null nonterminals ... input.y: warning: 2 reduce/reduce conflicts [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on tokens A, C [-Wcounterexamples] First example D . A $end First reduce derivation $accept -> [ s -> [ a -> [ D . ] A ] $end ] Second example B D . A $end Second reduce derivation $accept -> [ s -> [ B b -> [ D . ] A ] $end ] input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:409: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr ./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: N A . B C Shift derivation s `-> 1: n `-> 6: N b `-> 8: A . B C Reduce derivation s `-> 2: n C `-> 5: N a B `-> 7: A . input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: N N A . B D C Shift derivation s `-> 1: n `-> 4: N n C `-> 6: N b `-> 9: A . B D Reduce derivation s `-> 2: n C `-> 3: N n D `-> 5: N a B `-> 7: A . input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:499: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./counterexample.at:621: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 266. counterexample.at:399: ok ./counterexample.at:499: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 271. counterexample.at:797: testing Non-unifying Prefix Share ... ./counterexample.at:810: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: stderr: 272. counterexample.at:842: testing Deep Null Unifying ... ./counterexample.at:854: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y input.y: warning: 4 reduce/reduce conflicts [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on tokens b, c [-Wcounterexamples] Example: B . b c First reduce derivation S `-> 1: B C `-> 6: A b A `-> 7: A c A `-> 3: B . `-> 6: %empty `-> 7: %empty `-> 7: %empty Second reduce derivation S `-> 1: B C `-> 7: A c A `-> 3: B `-> 7: %empty `-> 6: A b A `-> 5: %empty . `-> 6: %empty input.y: warning: reduce/reduce conflict on tokens b, c [-Wcounterexamples] Example: C . c b First reduce derivation S `-> 2: C B `-> 7: A c A `-> 6: A b A `-> 4: C . `-> 7: %empty `-> 6: %empty `-> 6: %empty Second reduce derivation S `-> 2: C B `-> 6: A b A `-> 4: C `-> 6: %empty `-> 7: A c A `-> 5: %empty . `-> 7: %empty ./conflicts.at:753: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./counterexample.at:562: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example N A . B C Shift derivation s -> [ n -> [ N b -> [ A . B C ] ] ] Reduce derivation s -> [ n -> [ N a -> [ A . ] B ] C ] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example N N A . B D C Shift derivation s -> [ n -> [ N n -> [ N b -> [ A . B D ] ] C ] ] Reduce derivation s -> [ n -> [ N n -> [ N a -> [ A . ] B ] D ] C ] input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:499: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr 268. counterexample.at:488: ok ./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y -Werror ./counterexample.at:562: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token J [-Wcounterexamples] Example: H i J . J J Shift derivation s `-> 2: a J `-> 3: H i J . J Reduce derivation s `-> 1: a `-> 3: H i J J `-> 5: i J . input.y:5.13-15: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:810: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./counterexample.at:810: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 273. counterexample.at:884: testing Deep Null Non-unifying ... ./counterexample.at:896: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token D [-Wcounterexamples] Example: A a . D Shift derivation s `-> 1: A a d `-> 6: . D Reduce derivation s `-> 2: A a a d `-> 3: b `-> 6: D `-> 4: c `-> 5: %empty . ./counterexample.at:854: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr stderr: sr-rr.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] stderr: ./counterexample.at:854: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token D [-Wcounterexamples] First example: A a . D $end Shift derivation $accept `-> 0: s $end `-> 1: A a d `-> 6: . D Second example: A a . D E $end Reduce derivation $accept `-> 0: s $end `-> 2: A a a d E `-> 3: b `-> 6: D `-> 4: c `-> 5: %empty . ./counterexample.at:896: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr stderr: stderr: ./conflicts.at:2363: sed 's,.*/$,,' stderr 1>&2 input.y: warning: 4 reduce/reduce conflicts [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on tokens b, c [-Wcounterexamples] Example B . b c First reduce derivation S -> [ B -> [ A -> [ B . ] b A -> [ ] ] C -> [ A -> [ ] c A -> [ ] ] ] Second reduce derivation S -> [ B C -> [ A -> [ B -> [ A -> [ . ] b A -> [ ] ] ] c A -> [ ] ] ] input.y: warning: reduce/reduce conflict on tokens b, c [-Wcounterexamples] Example C . c b First reduce derivation S -> [ C -> [ A -> [ C . ] c A -> [ ] ] B -> [ A -> [ ] b A -> [ ] ] ] Second reduce derivation S -> [ C B -> [ A -> [ C -> [ A -> [ . ] c A -> [ ] ] ] b A -> [ ] ] ] input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token J [-Wcounterexamples] Example H i J . J J Shift derivation s -> [ a -> [ H i J . J ] J ] Reduce derivation s -> [ a -> [ H i -> [ i J . ] J J ] ] input.y:5.13-15: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:562: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr ./counterexample.at:896: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./counterexample.at:810: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr 274. synclines.at:194: testing Prologue syncline ... ./synclines.at:194: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 271. counterexample.at:797: ok 269. counterexample.at:550: ok ./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y --warnings=error stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token D [-Wcounterexamples] Example A a . D Shift derivation s -> [ A a d -> [ . D ] ] Reduce derivation s -> [ A a a -> [ b -> [ c -> [ . ] ] ] d -> [ D ] ] ./counterexample.at:854: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token D [-Wcounterexamples] First example A a . D $end Shift derivation $accept -> [ s -> [ A a d -> [ . D ] ] $end ] Second example A a . D E $end Reduce derivation $accept -> [ s -> [ A a a -> [ b -> [ c -> [ . ] ] ] d -> [ D ] E ] $end ] ./counterexample.at:896: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr 272. counterexample.at:842: ok ./synclines.at:194: $CC $CFLAGS $CPPFLAGS -c syncline.c 273. counterexample.at:884: ok ./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y -Wnone,none -Werror --trace=none stderr: 275. synclines.at:214: testing %union syncline ... syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:194: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF ./synclines.at:214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 276. synclines.at:237: testing %union name syncline ... stdout: syncline.c:4: #error "4" ./synclines.at:194: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 ./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y --warnings=none -Werror --trace=none ./synclines.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: ./synclines.at:194: $CC $CFLAGS $CPPFLAGS -c input.c ./conflicts.at:754: $PREPARSER ./input stderr: 277. synclines.at:264: testing Postprologue syncline ... syntax error, unexpected 'a', expecting 'b' or 'c' ./synclines.at:264: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:754: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./synclines.at:214: $CC $CFLAGS $CPPFLAGS -c syncline.c input.y:2:2: error: #error "2" 2 | #error "2" | ^~~~~ ./synclines.at:194: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF 278. synclines.at:291: testing Action syncline ... ./synclines.at:254: $CC $CFLAGS $CPPFLAGS -c syncline.c ./synclines.at:291: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stdout: stderr: 228. conflicts.at:676: ok input.y:2: #error "2" ./synclines.at:194: cat stdout syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:214: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./synclines.at:264: $CC $CFLAGS $CPPFLAGS -c syncline.c stderr: syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:254: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF 274. synclines.at:194: ok stdout: stderr: syncline.c:4: #error "4" syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:264: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stdout: ./synclines.at:254: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 syncline.c:4: #error "4" ./synclines.at:214: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 ./synclines.at:291: $CC $CFLAGS $CPPFLAGS -c syncline.c stdout: syncline.c:4: #error "4" ./synclines.at:254: $CC $CFLAGS $CPPFLAGS -c input.c ./synclines.at:264: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 ./synclines.at:214: $CC $CFLAGS $CPPFLAGS -c input.c ./synclines.at:264: $CC $CFLAGS $CPPFLAGS -c input.c stderr: syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ stderr: ./synclines.at:291: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF input.y:2:2: error: #error "2" 2 | #error "2" | ^~~~~ ./synclines.at:214: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF stdout: 279. synclines.at:310: testing Epilogue syncline ... ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 280. synclines.at:327: testing %code top syncline ... syncline.c:4: #error "4" ./synclines.at:327: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stdout: ./synclines.at:291: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 stderr: ./synclines.at:310: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y input.y:2: #error "2" stderr: ./synclines.at:214: cat stdout ./synclines.at:291: $CC $CFLAGS $CPPFLAGS -c input.c input.y:13:2: error: #error "13" 13 | #error "13" | ^~~~~ input.y:1:7: error: expected '{' before 'break' 1 | %union break | ^~~~~ input.y:1:15: error: expected '{' before 'break' 1 | %union break | ^ input.y:7:8: error: unknown type name 'YYSTYPE' 7 | int yylex (void); | ^~~~~~~ input.y:8:1: error: expected identifier or '(' before '%' token 8 | %} | ^ input.c:273:9: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 273 | typedef yytype_int8 yy_state_t; | ^~~~~~~~~~~ | yytype_uint8 input.c:429:3: error: unknown type name 'YYSTYPE' 429 | YYSTYPE yyvs_alloc; | ^~~~~~~ input.c:508:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 508 | static const yytype_int8 yytranslate[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:581:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 581 | static const yytype_int8 yypact[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:589:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 589 | static const yytype_int8 yydefact[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:595:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 595 | static const yytype_int8 yypgoto[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:601:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 601 | static const yytype_int8 yydefgoto[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:609:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 609 | static const yytype_int8 yytable[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:614:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 614 | static const yytype_int8 yycheck[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:621:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 621 | static const yytype_int8 yystos[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:627:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 627 | static const yytype_int8 yyr1[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:633:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 633 | static const yytype_int8 yyr2[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:828:37: error: unknown type name 'YYSTYPE' 828 | yysymbol_kind_t yykind, YYSTYPE *yyvaluep) | ^~~~~~~ input.c:322:5: error: expected end of line before 'push' 322 | _Pragma ("GCC diagnostic push") \ | ^~~~~~~ input.c:835:3: note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN' 835 | YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:323:5: error: expected end of line before 'ignored' 323 | _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"") \ | ^~~~~~~ input.c:835:3: note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN' 835 | YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:324:5: error: expected end of line before 'ignored' 324 | _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"") | ^~~~~~~ input.c:835:3: note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN' 835 | YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:327:5: error: expected end of line before 'pop' 327 | _Pragma ("GCC diagnostic pop") | ^~~~~~~ input.c:837:3: note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_END' 837 | YY_IGNORE_MAYBE_UNINITIALIZED_END | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:845:1: error: unknown type name 'YYSTYPE' 845 | YYSTYPE yylval; | ^~~~~~~ input.c: In function 'yyparse': input.c:875:5: error: unknown type name 'YYSTYPE' 875 | YYSTYPE yyvsa[YYINITDEPTH]; | ^~~~~~~ input.c:876:5: error: unknown type name 'YYSTYPE' 876 | YYSTYPE *yyvs = yyvsa; | ^~~~~~~ input.c:877:5: error: unknown type name 'YYSTYPE' 877 | YYSTYPE *yyvsp = yyvs; | ^~~~~~~ input.c:886:3: error: unknown type name 'YYSTYPE' 886 | YYSTYPE yyval; | ^~~~~~~ input.c:438:48: error: 'YYSTYPE' undeclared (first use in this function) 438 | ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ | ^~~~~~~ input.c:75:40: note: in definition of macro 'YY_CAST' 75 | # define YY_CAST(Type, Val) ((Type) (Val)) | ^~~ input.c:962:35: note: in expansion of macro 'YY_CAST' 962 | YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); | ^~~~~~~ input.c:269:21: note: in expansion of macro 'YY_CAST' 269 | #define YYSIZEOF(X) YY_CAST (YYPTRDIFF_T, sizeof (X)) | ^~~~~~~ input.c:438:38: note: in expansion of macro 'YYSIZEOF' 438 | ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ | ^~~~~~~~ input.c:962:54: note: in expansion of macro 'YYSTACK_BYTES' 962 | YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); | ^~~~~~~~~~~~~ input.c:438:48: note: each undeclared identifier is reported only once for each function it appears in 438 | ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ | ^~~~~~~ input.c:75:40: note: in definition of macro 'YY_CAST' 75 | # define YY_CAST(Type, Val) ((Type) (Val)) | ^~~ input.c:962:35: note: in expansion of macro 'YY_CAST' 962 | YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); | ^~~~~~~ input.c:269:21: note: in expansion of macro 'YY_CAST' 269 | #define YYSIZEOF(X) YY_CAST (YYPTRDIFF_T, sizeof (X)) | ^~~~~~~ input.c:438:38: note: in expansion of macro 'YYSIZEOF' 438 | ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ | ^~~~~~~~ input.c:962:54: note: in expansion of macro 'YYSTACK_BYTES' 962 | YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); | ^~~~~~~~~~~~~ input.c:1162:11: error: implicit declaration of function 'yydestruct' [-Wimplicit-function-declaration] 1162 | yydestruct ("Error: discarding", | ^~~~~~~~~~ ./synclines.at:264: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF ./synclines.at:254: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stdout: stdout: 275. synclines.at:214: ok input.y:13: #error "13" ./synclines.at:264: cat stdout input.y:1: #error expected '{' before 'break' %union break ^~~~~ input.y:1: #error expected '{' before 'break' %union break ^ input.y:7: #error unknown type name 'YYSTYPE' int yylex (void); ^~~~~~~ input.y:8: #error expected identifier or '(' before '%' token %} ^ input.c:273: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? typedef yytype_int8 yy_state_t; ^~~~~~~~~~~ yytype_uint8 input.c:429: #error unknown type name 'YYSTYPE' YYSTYPE yyvs_alloc; ^~~~~~~ input.c:508: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yytranslate[] = ^~~~~~~~~~~ yytype_uint8 input.c:581: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yypact[] = ^~~~~~~~~~~ yytype_uint8 input.c:589: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yydefact[] = ^~~~~~~~~~~ yytype_uint8 input.c:595: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yypgoto[] = ^~~~~~~~~~~ yytype_uint8 input.c:601: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yydefgoto[] = ^~~~~~~~~~~ yytype_uint8 input.c:609: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yytable[] = ^~~~~~~~~~~ yytype_uint8 input.c:614: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yycheck[] = ^~~~~~~~~~~ yytype_uint8 input.c:621: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yystos[] = ^~~~~~~~~~~ yytype_uint8 input.c:627: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yyr1[] = ^~~~~~~~~~~ yytype_uint8 input.c:633: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yyr2[] = ^~~~~~~~~~~ yytype_uint8 input.c:828: #error unknown type name 'YYSTYPE' yysymbol_kind_t yykind, YYSTYPE *yyvaluep) ^~~~~~~ input.c:322: #error expected end of line before 'push' _Pragma ("GCC diagnostic push") \ ^~~~~~~ input.c:835: #error note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN' YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:323: #error expected end of line before 'ignored' _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"") \ ^~~~~~~ input.c:835: #error note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN' YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:324: #error expected end of line before 'ignored' _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"") ^~~~~~~ input.c:835: #error note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN' YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:327: #error expected end of line before 'pop' _Pragma ("GCC diagnostic pop") ^~~~~~~ input.c:837: #error note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_END' YY_IGNORE_MAYBE_UNINITIALIZED_END ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:845: #error unknown type name 'YYSTYPE' input.c:875: #error unknown type name 'YYSTYPE' YYSTYPE yyvsa[YYINITDEPTH]; ^~~~~~~ input.c:876: #error unknown type name 'YYSTYPE' YYSTYPE *yyvs = yyvsa; ^~~~~~~ input.c:877: #error unknown type name 'YYSTYPE' YYSTYPE *yyvsp = yyvs; ^~~~~~~ input.c:886: #error unknown type name 'YYSTYPE' YYSTYPE yyval; ^~~~~~~ input.c:438: #error 'YYSTYPE' undeclared (first use in this function) ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ ^~~~~~~ input.c:75: #error note: in definition of macro 'YY_CAST' # define YY_CAST(Type, Val) ((Type) (Val)) ^~~ input.c:962: #error note: in expansion of macro 'YY_CAST' YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); ^~~~~~~ input.c:269: #error note: in expansion of macro 'YY_CAST' #define YYSIZEOF(X) YY_CAST (YYPTRDIFF_T, sizeof (X)) ^~~~~~~ input.c:438: #error note: in expansion of macro 'YYSIZEOF' ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ ^~~~~~~~ input.c:962: #error note: in expansion of macro 'YYSTACK_BYTES' YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); ^~~~~~~~~~~~~ input.c:438: #error note: each undeclared identifier is reported only once for each function it appears in ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ ^~~~~~~ input.c:75: #error note: in definition of macro 'YY_CAST' # define YY_CAST(Type, Val) ((Type) (Val)) ^~~ input.c:962: #error note: in expansion of macro 'YY_CAST' YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); ^~~~~~~ input.c:269: #error note: in expansion of macro 'YY_CAST' #define YYSIZEOF(X) YY_CAST (YYPTRDIFF_T, sizeof (X)) ^~~~~~~ input.c:438: #error note: in expansion of macro 'YYSIZEOF' ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ ^~~~~~~~ input.c:962: #error note: in expansion of macro 'YYSTACK_BYTES' YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); ^~~~~~~~~~~~~ input.c:1162: #error implicit declaration of function 'yydestruct' [-Wimplicit-function-declaration] yydestruct ("Error: discarding", ^~~~~~~~~~ ./synclines.at:255: grep '^input.y:1' stdout stderr: input.y: In function 'yyparse': input.y:8:2: error: #error "8" 8 | #error "8" | ^~~~~ stderr: stdout: ./synclines.at:291: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF 277. synclines.at:264: ok ./synclines.at:327: $CC $CFLAGS $CPPFLAGS -c syncline.c input.y:1: #error expected '{' before 'break' input.y:1: #error expected '{' before 'break' 276. synclines.at:237: ok ./synclines.at:310: $CC $CFLAGS $CPPFLAGS -c syncline.c stdout: stdout: ./conflicts.at:1096: $PREPARSER ./input stderr: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file input.y:8: #error "8" ./synclines.at:291: cat stdout stderr: syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:327: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF syntax error stderr: ./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 278. synclines.at:291: ok syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:310: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF stdout: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file syncline.c:4: #error "4" ./synclines.at:327: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 stdout: 236. conflicts.at:1096: ok syncline.c:4: #error "4" ./synclines.at:310: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./synclines.at:327: $CC $CFLAGS $CPPFLAGS -c input.c 282. synclines.at:370: testing %printer syncline ... ./synclines.at:370: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 283. synclines.at:440: testing syncline escapes: yacc.c ... ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 281. synclines.at:346: testing %destructor syncline ... ./synclines.at:346: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./synclines.at:310: $CC $CFLAGS $CPPFLAGS -c input.c ./synclines.at:440: $CC $CFLAGS $CPPFLAGS \"\\\"\".c -o \"\\\"\" || exit 77 stderr: input.y:2:2: error: #error "2" 2 | #error "2" | ^~~~~ ./synclines.at:327: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF stderr: 284. synclines.at:440: testing syncline escapes: glr.c ... input.y:8:2: error: #error "8" 8 | #error "8" | ^~~~~ ./synclines.at:310: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF stdout: input.y:8: #error "8" ./synclines.at:310: cat stdout stdout: input.y:2: #error "2" ./synclines.at:327: cat stdout ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./synclines.at:440: $CC $CFLAGS $CPPFLAGS \"\\\"\".c -o \"\\\"\" || exit 77 ./synclines.at:346: $CC $CFLAGS $CPPFLAGS -c syncline.c ./synclines.at:370: $CC $CFLAGS $CPPFLAGS -c syncline.c 279. synclines.at:310: ok 285. synclines.at:440: testing syncline escapes: lalr1.cc ... ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: 280. synclines.at:327: ok ./synclines.at:440: $CXX $CXXFLAGS $CPPFLAGS \"\\\"\".cc -o \"\\\"\" || exit 77 syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:346: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF stdout: stderr: syncline.c:4: #error "4" syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:346: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 ./synclines.at:370: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF ./synclines.at:346: $CC $CFLAGS $CPPFLAGS -c input.c stdout: syncline.c:4: #error "4" ./synclines.at:370: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stderr: stderr: input.y: In function 'yydestruct': input.y:2:2: error: #error "2" 2 | #error "2" | ^~~~~ ./synclines.at:346: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF stdout: ./synclines.at:370: $CC $CFLAGS $CPPFLAGS -c input.c stdout: input.y:2: #error "2" ./synclines.at:346: cat stdout ./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".c \"\\\"\".y stderr: 286. synclines.at:440: testing syncline escapes: glr.cc ... 287. synclines.at:440: testing syncline escapes: glr2.cc ... ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: stderr: ./synclines.at:440: $CXX $CXXFLAGS $CPPFLAGS \"\\\"\".cc -o \"\\\"\" || exit 77 input.y: In function 'yy_symbol_value_print': input.y:2:2: error: #error "2" 2 | #error "2" | ^~~~~ ./synclines.at:440: $CXX $CXXFLAGS $CPPFLAGS \"\\\"\".cc -o \"\\\"\" || exit 77 stdout: ./synclines.at:370: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF stdout: 281. synclines.at:346: ok ./conflicts.at:1096: $PREPARSER ./input stdout: input.y:2: #error "2" ./synclines.at:370: cat stdout ./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".c \"\\\"\".y stderr: syntax error ./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./synclines.at:440: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".c $LIBS 282. synclines.at:370: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: 235. conflicts.at:1096: ok 288. synclines.at:497: testing %no-lines: yacc.c ... stderr: stderr: stdout: ./synclines.at:440: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".c $LIBS stdout: ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.c -d input.y stdout: ./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".cc \"\\\"\".y ./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".cc \"\\\"\".y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".cc \"\\\"\".y 289. synclines.at:497: testing %no-lines: glr.c ... ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.c -d input.y ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./synclines.at:497: mv input.c without.c ./synclines.at:497: mv input.h without.h ./synclines.at:497: grep '#line' *.c *.h 290. synclines.at:497: testing %no-lines: lalr1.cc ... ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.cc -d input.y ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -d input.y ./synclines.at:440: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".cc $LIBS stderr: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stdout: ./synclines.at:440: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".cc $LIBS ./synclines.at:440: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".cc $LIBS 283. synclines.at:440: ok ./synclines.at:497: mv input.c without.c ./synclines.at:497: mv input.c with.c ./synclines.at:497: mv input.h with.h ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./synclines.at:497: mv input.h without.h ./synclines.at:497: mv input.cc without.cc ./synclines.at:497: grep -v '#line' with.c >expout ./synclines.at:497: grep '#line' *.c *.h ./synclines.at:497: mv input.hh without.hh ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -d input.y ./synclines.at:497: grep '#line' *.cc *.hh ./synclines.at:497: cat without.c ./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc -d input.y ./synclines.at:497: grep -v '#line' with.h >expout ./synclines.at:497: cat without.h ./synclines.at:497: mv input.c with.c 288. synclines.at:497: ok ./synclines.at:497: mv input.h with.h 291. synclines.at:497: testing %no-lines: glr.cc ... ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.cc -d input.y ./synclines.at:497: mv input.cc with.cc ./synclines.at:497: grep -v '#line' with.c >expout ./synclines.at:497: mv input.hh with.hh ./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file ./synclines.at:497: grep -v '#line' with.cc >expout ./synclines.at:497: cat without.c ./synclines.at:497: cat without.cc ./synclines.at:497: grep -v '#line' with.h >expout ./synclines.at:497: grep -v '#line' with.hh >expout ./synclines.at:497: mv input.cc without.cc ./synclines.at:497: cat without.h ./synclines.at:497: mv input.hh without.hh ./synclines.at:497: cat without.hh ./synclines.at:497: grep '#line' *.cc *.hh 292. synclines.at:497: testing %no-lines: glr2.cc ... ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.cc -d input.y 289. synclines.at:497: ok ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc -d input.y 290. synclines.at:497: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./synclines.at:497: mv input.cc with.cc ./synclines.at:497: mv input.hh with.hh ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./synclines.at:497: mv input.cc without.cc 293. synclines.at:507: testing Output columns ... ./synclines.at:540: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./synclines.at:497: grep -v '#line' with.cc >expout ./synclines.at:497: mv input.hh without.hh ./synclines.at:497: grep '#line' *.cc *.hh ./synclines.at:497: cat without.cc ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc -d input.y 294. headers.at:56: testing Invalid CPP guards: --defines=input/input.h ... ./synclines.at:497: grep -v '#line' with.hh >expout ./synclines.at:541: sed -ne '/--BEGIN/,/--END/{' \ -e '/input.c/s/ [0-9]* / LINE /;' \ -e 'p;}' \ input.c ./synclines.at:497: cat without.hh ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:56: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --defines=input/input.h --output=input/input.c input/input.y 291. synclines.at:497: ok ./synclines.at:497: mv input.cc with.cc ./synclines.at:497: mv input.hh with.hh 293. synclines.at:507: ok ./synclines.at:497: grep -v '#line' with.cc >expout ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./synclines.at:497: cat without.cc stderr: stdout: ./headers.at:56: $CC $CFLAGS $CPPFLAGS -c -o input/input.o -I. -c input/input.c ./synclines.at:497: grep -v '#line' with.hh >expout 284. synclines.at:440: ok ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./synclines.at:497: cat without.hh 295. headers.at:57: testing Invalid CPP guards: --defines=9foo.h ... 292. synclines.at:497: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 296. headers.at:58: testing Invalid CPP guards: %glr-parser --defines=input/input.h ... ./headers.at:57: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --defines=9foo.h --output=9foo.c 9foo.y ./headers.at:58: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --defines=input/input.h --output=input/input.c input/input.y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 297. headers.at:59: testing Invalid CPP guards: %glr-parser --defines=9foo.h ... stderr: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:57: $CC $CFLAGS $CPPFLAGS -c -o 9foo.o -I. -c 9foo.c stdout: ./headers.at:59: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --defines=9foo.h --output=9foo.c 9foo.y 298. headers.at:67: testing export YYLTYPE ... ./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --header -o input.c input.y 294. headers.at:56: ok ./headers.at:58: $CC $CFLAGS $CPPFLAGS -c -o input/input.o -I. -c input/input.c ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:59: $CC $CFLAGS $CPPFLAGS -c -o 9foo.o -I. -c 9foo.c ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header -o input.c input.y -Werror 299. headers.at:177: testing Sane headers: ... ./headers.at:177: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y stderr: stdout: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stderr: 295. headers.at:57: input.y:11.1-18: error: deprecated directive: '%name-prefix "my_"', use '%define api.prefix {my_}' [-Werror=deprecated] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:177: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./headers.at:85: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header -o input.c input.y --warnings=error ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 300. headers.at:178: testing Sane headers: %locations %debug ... ./headers.at:178: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y ./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header -o input.c input.y -Wnone,none -Werror --trace=none ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:178: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header -o input.c input.y --warnings=none -Werror --trace=none stderr: stdout: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:177: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:102: $CC $CFLAGS $CPPFLAGS -c -o caller.o caller.c stderr: stdout: 299. headers.at:177: ok stderr: stdout: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 296. headers.at:58: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: stderr: stdout: stderr: stdout: 286. synclines.at:440: ok stdout: ./headers.at:103: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c 301. headers.at:180: testing Sane headers: %glr-parser ... ./headers.at:180: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y ./conflicts.at:1096: $PREPARSER ./input stderr: syntax error ./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:180: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c 302. headers.at:181: testing Sane headers: %locations %debug %glr-parser ... ./headers.at:181: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y stderr: stdout: 237. conflicts.at:1096: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 297. headers.at:59: ok stderr: 303. headers.at:183: testing Sane headers: api.pure ... stdout: ./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file ./headers.at:181: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c 285. synclines.at:440: ok ./headers.at:183: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y ./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file ./headers.at:183: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c 304. headers.at:184: testing Sane headers: api.push-pull=both ... ./headers.at:184: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y 305. headers.at:185: testing Sane headers: api.pure api.push-pull=both ... ./headers.at:185: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y ./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file stderr: 306. headers.at:187: testing Sane headers: c++ ... stdout: ./headers.at:187: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.cc input.y ./headers.at:104: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o caller caller.o input.o $LIBS stderr: ./headers.at:184: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c stdout: ./headers.at:185: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file ./headers.at:178: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c ./headers.at:187: $CXX $CPPFLAGS $CXXFLAGS -c -o input.o input.cc stderr: stdout: ./headers.at:105: $PREPARSER ./caller stderr: stderr: ./headers.at:105: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 300. headers.at:178: ok 298. headers.at:67: ok stderr: stdout: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:183: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c stderr: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stderr: stdout: stdout: 308. headers.at:189: testing Sane headers: c++ api.value.type=variant parse.assert ... 303. headers.at:183: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ok 307. headers.at:188: testing Sane headers: %locations %debug c++ ... ./headers.at:189: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.cc input.y ./headers.at:188: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.cc input.y ./headers.at:184: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stderr: stdout: ./headers.at:189: $CXX $CPPFLAGS $CXXFLAGS -c -o input.o input.cc stderr: ./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o input.o input.cc stdout: 304. headers.at:184: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:185: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c 309. headers.at:191: testing Sane headers: %locations c++ %glr-parser ... ./headers.at:191: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.cc input.y stderr: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stdout: 305. headers.at:185: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:191: $CXX $CPPFLAGS $CXXFLAGS -c -o input.o input.cc 310. headers.at:199: testing Several parsers ... ./headers.at:320: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x1.c x1.y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 311. actions.at:24: testing Midrule actions ... ./actions.at:59: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -v -o input.c input.y ./headers.at:320: $CC $CFLAGS $CPPFLAGS -c -o x1.o x1.c ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stderr: ./actions.at:60: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stdout: ./headers.at:180: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stderr: stdout: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: stdout: ./headers.at:181: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c ./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file 301. headers.at:180: ok stderr: stdout: ./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file 302. headers.at:181: ok 312. actions.at:72: testing Typed midrule actions ... ./actions.at:109: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -v -o input.c input.y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: 313. actions.at:122: testing Implicitly empty rule ... stdout: ./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y stderr: ./actions.at:110: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: ./headers.at:320: echo "x1" >>expout 287. synclines.at:440: ok ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:321: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x2.c x2.y ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y -Werror stderr: stdout: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./actions.at:61: $PREPARSER ./input ./headers.at:321: $CC $CFLAGS $CPPFLAGS -c -o x2.o x2.c stderr: stderr: 1.y:11.17-18: error: empty rule without %empty [-Werror=empty-rule] 11 | a: /* empty. */ {}; | ^~ | %empty 1.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ./actions.at:61: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./actions.at:133: sed 's,.*/$,,' stderr 1>&2 314. actions.at:172: testing Invalid uses of %empty ... ./actions.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret one.y ./actions.at:192: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -u one.y 311. actions.at:24: ok ./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file ./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y --warnings=error ./actions.at:202: sed -e '1,8d' one.y ./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file ./actions.at:219: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret two.y ./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y -Wnone,none -Werror --trace=none ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 315. actions.at:240: testing Valid uses of %empty ... ./actions.at:259: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 314. actions.at:172: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: stdout: ./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y --warnings=none -Werror --trace=none ./headers.at:187: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc ./actions.at:259: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 316. actions.at:270: testing Add missing %empty ... ./actions.at:285: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --update -Wall input.y ./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret 2.y ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: input.y:3.4-5: warning: empty rule without %empty [-Wempty-rule] input.y:4.3-5.1: warning: empty rule without %empty [-Wempty-rule] input.y:6.3: warning: empty rule without %empty [-Wempty-rule] input.y:8.2: warning: empty rule without %empty [-Wempty-rule] input.y:9.3: warning: empty rule without %empty [-Wempty-rule] bison: file 'input.y' was updated (backup: 'input.y~') ./actions.at:286: cat input.y ./actions.at:300: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall input.y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret 2.y -Werror stderr: stdout: ./actions.at:111: $PREPARSER ./input stderr: ./actions.at:111: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: stdout: ./headers.at:189: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc 312. actions.at:72: ok 316. actions.at:270: ok ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stderr: 2.y:11.17-18: error: empty rule without %empty [-Werror=empty-rule] 11 | a: /* empty. */ {}; | ^~ | %empty 2.y:13.17-18: error: empty rule without %empty [-Werror=empty-rule] 13 | c: /* empty. */ {}; | ^~ | %empty 2.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./actions.at:149: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 318. actions.at:366: testing Initial location: yacc.c api.pure=full ... ./actions.at:366: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 317. actions.at:365: testing Initial location: yacc.c ... ./actions.at:365: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret 2.y --warnings=error ./actions.at:365: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret 2.y -Wnone,none -Werror --trace=none ./actions.at:366: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: stderr: ./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret 2.y --warnings=none -Werror --trace=none stdout: ./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:321: echo "x2" >>expout ./headers.at:322: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x3.c x3.y stderr: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stdout: ./actions.at:260: $PREPARSER ./input stderr: ./actions.at:161: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wno-empty-rule 2.y ./actions.at:260: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 315. actions.at:240: ok stderr: stdout: stderr: stdout: ./headers.at:322: $CC $CFLAGS $CPPFLAGS -c -o x3.o x3.c ./actions.at:365: $PREPARSER ./input stderr: 1.1 1.1: syntax error ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./actions.at:365: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 313. actions.at:122: ok ./headers.at:187: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc stderr: 319. actions.at:367: testing Initial location: yacc.c api.pure %parse-param { int x } ... ./actions.at:367: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stderr: stdout: 317. actions.at:365: ok stdout: stderr: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./actions.at:366: $PREPARSER ./input stdout: stderr: ./actions.at:367: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 1.1 1.1: syntax error ./actions.at:366: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 306. headers.at:187: ok ./headers.at:189: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc 318. actions.at:366: ok stderr: stdout: 308. headers.at:189: ok ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 320. actions.at:368: testing Initial location: yacc.c api.push-pull=both ... ./actions.at:368: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 321. actions.at:369: testing Initial location: yacc.c api.push-pull=both api.pure=full ... ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./actions.at:368: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 322. actions.at:370: testing Initial location: glr.c ... ./actions.at:370: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:369: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 323. actions.at:371: testing Initial location: glr.c api.pure ... 258. conflicts.at:2331: ok ./actions.at:369: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:371: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:370: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 324. actions.at:372: testing Initial location: lalr1.cc ... ./actions.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:371: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 325. actions.at:373: testing Initial location: glr.cc ... ./actions.at:373: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:372: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./actions.at:367: $PREPARSER ./input stderr: 1.1 1.1: syntax error ./actions.at:367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 319. actions.at:367: ok ./actions.at:373: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc stderr: 326. actions.at:374: testing Initial location: glr2.cc ... ./actions.at:374: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stdout: ./actions.at:369: $PREPARSER ./input stderr: 1.1 1.1: syntax error ./actions.at:369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: 321. actions.at:369: ok ./actions.at:368: $PREPARSER ./input ./actions.at:374: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: 1.1 1.1: syntax error ./actions.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: 320. actions.at:368: ok ./headers.at:191: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc stdout: ./headers.at:322: echo "x3" >>expout 327. actions.at:383: testing Initial location: yacc.c api.pure=full ... ./actions.at:383: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./headers.at:323: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x4.c x4.y ./actions.at:383: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 328. actions.at:394: testing Initial location: yacc.c api.pure=full ... ./actions.at:394: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./headers.at:323: $CC $CFLAGS $CPPFLAGS -c -o x4.o x4.c ./actions.at:394: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc stderr: stdout: ./actions.at:371: $PREPARSER ./input stderr: 1.1 1.1: syntax error ./actions.at:371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./actions.at:383: $PREPARSER ./input stderr: : syntax error ./actions.at:383: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 323. actions.at:371: ok stderr: stdout: ./actions.at:370: $PREPARSER ./input stderr: 1.1 1.1: syntax error ./actions.at:370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 327. actions.at:383: ok 322. actions.at:370: ok 329. actions.at:478: testing Location print: yacc.c ... ./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: ./actions.at:394: $PREPARSER ./input stderr: ./actions.at:478: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 0 0: syntax error ./actions.at:394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 330. actions.at:478: testing Location print: glr.c ... ./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: ./headers.at:191: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc 328. actions.at:394: ok ./actions.at:478: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 331. actions.at:478: testing Location print: lalr1.cc ... ./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:478: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 332. actions.at:478: testing Location print: glr.cc ... ./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc ./actions.at:478: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stderr: stdout: stdout: ./actions.at:478: $PREPARSER ./input 307. headers.at:188: ok stderr: stderr: stdout: ./actions.at:372: $PREPARSER ./input ./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1 1.1: syntax error ./actions.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 324. actions.at:372: ok stdout: 329. actions.at:478: ok ./actions.at:373: $PREPARSER ./input stderr: 1.1 1.1: syntax error ./actions.at:373: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 333. actions.at:478: testing Location print: glr2.cc ... ./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 325. actions.at:373: ok 334. actions.at:488: testing Exotic Dollars ... ./actions.at:532: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -v -o input.c input.y 335. actions.at:1047: testing Printers and Destructors ... ./actions.at:1047: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:478: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./actions.at:533: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 336. actions.at:1048: testing Printers and Destructors with union ... ./actions.at:1048: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1047: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./headers.at:191: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc ./actions.at:1048: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./headers.at:323: echo "x4" >>expout ./headers.at:324: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x5.cc x5.y stderr: stdout: ./actions.at:478: $PREPARSER ./input stderr: ./headers.at:324: $CXX $CPPFLAGS $CXXFLAGS -c -o x5.o x5.cc ./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./actions.at:534: $PREPARSER ./input 330. actions.at:478: ok stderr: stderr: stdout: ./actions.at:1047: $PREPARSER ./input '(x)' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:534: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1047: $PREPARSER ./input '!' stderr: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1047: $PREPARSER ./input '!!!' stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:562: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 337. actions.at:1050: testing Printers and Destructors: %glr-parser ... ./actions.at:1047: $PREPARSER ./input '(y)' stderr: sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1050: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1047: $PREPARSER ./input '(xxxxx)(x)(x)y' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:562: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1047: $PREPARSER ./input '(x)(x)x' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1050: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./actions.at:1047: $PREPARSER ./input '(x)(x)(x)(x)(x)(x)(x)' ./actions.at:1048: $PREPARSER ./input '(x)' stderr: stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: '(' (6@60-69) sending: 'x' (7@70-79) thing (7@70-79): 'x' (7@70-79) sending: ')' (8@80-89) line (6@60-89): '(' (6@60-69) thing (7@70-79) ')' (8@80-89) sending: '(' (9@90-99) sending: 'x' (10@100-109) thing (10@100-109): 'x' (10@100-109) sending: ')' (11@110-119) line (9@90-119): '(' (9@90-99) thing (10@100-109) ')' (11@110-119) sending: '(' (12@120-129) sending: 'x' (13@130-139) thing (13@130-139): 'x' (13@130-139) sending: ')' (14@140-149) line (12@120-149): '(' (12@120-129) thing (13@130-139) ')' (14@140-149) sending: '(' (15@150-159) sending: 'x' (16@160-169) thing (16@160-169): 'x' (16@160-169) sending: ')' (17@170-179) line (15@150-179): '(' (15@150-159) thing (16@160-169) ')' (17@170-179) sending: '(' (18@180-189) sending: 'x' (19@190-199) thing (19@190-199): 'x' (19@190-199) sending: ')' (20@200-209) 200.200-209.208: memory exhausted Freeing nterm thing (19@190-199) Freeing nterm line (15@150-179) Freeing nterm line (12@120-149) Freeing nterm line (9@90-119) Freeing nterm line (6@60-89) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Parsing FAILED (status 2). ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1048: $PREPARSER ./input '!' 335. actions.at:1047: ok stderr: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 338. actions.at:1051: testing Printers and Destructors with union: %glr-parser ... ./actions.at:1051: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1048: $PREPARSER ./input '!!!' stderr: stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token J [-Wcounterexamples] time limit exceeded: 6.000000 First example: H i . J K $end Shift derivation $accept `-> 0: a $end `-> 2: H i `-> 4: i . J K Second example: H i . J $end Reduce derivation $accept `-> 0: s $end `-> 1: a J `-> 2: H i . input.y:4.4-6: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:451: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1048: $PREPARSER ./input '(y)' stderr: stderr: ./counterexample.at:451: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stderr: ./actions.at:563: $PREPARSER ./input stderr: stdout: ./actions.at:1051: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:563: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:478: $PREPARSER ./input stderr: ./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 334. actions.at:488: ok ./actions.at:1048: $PREPARSER ./input '(xxxxx)(x)(x)y' 331. actions.at:478: ok stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./actions.at:1048: $PREPARSER ./input '(x)(x)x' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 309. headers.at:191: ok 339. actions.at:1053: testing Printers and Destructors: %header lalr1.cc ... ./actions.at:1053: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:1048: $PREPARSER ./input '(x)(x)(x)(x)(x)(x)(x)' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: '(' (6@60-69) sending: 'x' (7@70-79) thing (7@70-79): 'x' (7@70-79) sending: ')' (8@80-89) line (6@60-89): '(' (6@60-69) thing (7@70-79) ')' (8@80-89) sending: '(' (9@90-99) sending: 'x' (10@100-109) thing (10@100-109): 'x' (10@100-109) sending: ')' (11@110-119) line (9@90-119): '(' (9@90-99) thing (10@100-109) ')' (11@110-119) sending: '(' (12@120-129) sending: 'x' (13@130-139) thing (13@130-139): 'x' (13@130-139) sending: ')' (14@140-149) line (12@120-149): '(' (12@120-129) thing (13@130-139) ')' (14@140-149) sending: '(' (15@150-159) sending: 'x' (16@160-169) thing (16@160-169): 'x' (16@160-169) sending: ')' (17@170-179) line (15@150-179): '(' (15@150-159) thing (16@160-169) ')' (17@170-179) sending: '(' (18@180-189) sending: 'x' (19@190-199) thing (19@190-199): 'x' (19@190-199) sending: ')' (20@200-209) 200.200-209.208: memory exhausted Freeing nterm thing (19@190-199) Freeing nterm line (15@150-179) Freeing nterm line (12@120-149) Freeing nterm line (9@90-119) Freeing nterm line (6@60-89) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Parsing FAILED (status 2). ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 336. actions.at:1048: ok 340. actions.at:1054: testing Printers and Destructors with union: %header lalr1.cc ... stderr: ./actions.at:1054: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stdout: ./actions.at:478: $PREPARSER ./input stderr: ./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1053: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 332. actions.at:478: ok 341. actions.at:1056: testing Printers and Destructors: %header glr.cc ... ./actions.at:1056: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:1054: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 342. actions.at:1057: testing Printers and Destructors with union: %header glr.cc ... ./actions.at:1057: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:1056: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 343. actions.at:1059: testing Printers and Destructors: %header glr2.cc ... ./actions.at:1059: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:1057: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./actions.at:1059: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./headers.at:324: echo "x5" >>expout ./headers.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x6.c x6.y stderr: stdout: ./actions.at:374: $PREPARSER ./input stderr: 1.1 1.1: syntax error ./actions.at:374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./actions.at:1050: $PREPARSER ./input '(x)' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 326. actions.at:374: ok ./headers.at:325: $CC $CFLAGS $CPPFLAGS -c -o x6.o x6.c ./actions.at:1050: $PREPARSER ./input '!' stderr: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1050: $PREPARSER ./input '!!!' stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 344. actions.at:1060: testing Printers and Destructors with union: %header glr2.cc ... ./actions.at:1060: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:1050: $PREPARSER ./input '(y)' stderr: sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1050: $PREPARSER ./input '(xxxxx)(x)(x)y' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./headers.at:325: echo "x6" >>expout ./headers.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x7.c x7.y ./actions.at:1050: $PREPARSER ./input '(x)(x)x' ./actions.at:1060: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./headers.at:326: $CC $CFLAGS $CPPFLAGS -c -o x7.o x7.c 337. actions.at:1050: ok stderr: stdout: ./actions.at:1051: $PREPARSER ./input '(x)' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1051: $PREPARSER ./input '!' stderr: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 345. actions.at:1071: testing Default tagless %printer and %destructor ... ./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1051: $PREPARSER ./input '!!!' stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1051: $PREPARSER ./input '(y)' stderr: sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./headers.at:326: echo "x7" >>expout ./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror ./actions.at:1051: $PREPARSER ./input '(xxxxx)(x)(x)y' ./headers.at:327: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x8.c x8.y stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./headers.at:327: $CC $CFLAGS $CPPFLAGS -c -o x8.o x8.c ./actions.at:1051: $PREPARSER ./input '(x)(x)x' stderr: input.y:30.3-5: error: useless %destructor for type <*> [-Werror=other] input.y:30.3-5: error: useless %printer for type <*> [-Werror=other] stderr: stderr: stdout: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1053: $PREPARSER ./input '(x)' stderr: ./actions.at:1116: sed 's,.*/$,,' stderr 1>&2 sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error ./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1053: $PREPARSER ./input '!' stderr: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 338. actions.at:1051: ok ./actions.at:1053: $PREPARSER ./input '!!!' stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none stderr: stdout: ./actions.at:1053: $PREPARSER ./input '(y)' ./actions.at:478: $PREPARSER ./input stderr: stderr: sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1053: $PREPARSER ./input '(xxxxx)(x)(x)y' stderr: stdout: ./actions.at:1054: $PREPARSER ./input '(x)' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 333. actions.at:478: ok ./actions.at:1053: $PREPARSER ./input '(x)(x)x' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 346. actions.at:1174: testing Default tagged and per-type %printer and %destructor ... ./actions.at:1054: $PREPARSER ./input '!' 339. actions.at:1053: ok ./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stderr: stdout: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./headers.at:327: echo "x8" >>expout ./actions.at:1120: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./headers.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x9.cc x9.y ./actions.at:1054: $PREPARSER ./input '!!!' stderr: stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. stdout: ./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1054: $PREPARSER ./input '(y)' ./actions.at:1057: $PREPARSER ./input '(x)' stderr: sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 348. actions.at:1429: testing Default %printer and %destructor are not for error or $undefined ... stderr: ./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 347. actions.at:1307: testing Default %printer and %destructor for user-defined end token ... ./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input0.c input0.y ./actions.at:1054: $PREPARSER ./input '(xxxxx)(x)(x)y' ./headers.at:328: $CXX $CPPFLAGS $CXXFLAGS -c -o x9.o x9.cc stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror ./actions.at:1057: $PREPARSER ./input '!' ./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror stderr: ./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input0.c input0.y -Werror sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1054: $PREPARSER ./input '(x)(x)x' stderr: input.y:22.3-4: error: useless %destructor for type <> [-Werror=other] input.y:22.3-4: error: useless %printer for type <> [-Werror=other] stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input0.y:30.3-5: error: useless %destructor for type <*> [-Werror=other] input0.y:30.3-5: error: useless %printer for type <*> [-Werror=other] ./actions.at:1057: $PREPARSER ./input '!!!' ./actions.at:1233: sed 's,.*/$,,' stderr 1>&2 stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1416: sed 's,.*/$,,' stderr 1>&2 340. actions.at:1054: ok ./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input0.c input0.y --warnings=error stderr: ./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error input.y:23.6-8: error: useless %destructor for type <*> [-Werror=other] input.y:23.6-8: error: useless %printer for type <*> [-Werror=other] ./actions.at:1057: $PREPARSER ./input '(y)' stderr: ./actions.at:1474: sed 's,.*/$,,' stderr 1>&2 sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none ./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error ./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input0.c input0.y -Wnone,none -Werror --trace=none ./actions.at:1057: $PREPARSER ./input '(xxxxx)(x)(x)y' 349. actions.at:1532: testing Default %printer and %destructor are not for $accept ... ./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input0.c input0.y --warnings=none -Werror --trace=none ./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none ./actions.at:1416: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input0 input0.c $LIBS ./actions.at:1057: $PREPARSER ./input '(x)(x)x' ./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror ./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1237: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input.y:24.3-4: error: useless %destructor for type <> [-Werror=other] input.y:24.3-4: error: useless %printer for type <> [-Werror=other] stderr: 342. actions.at:1057: ok stdout: ./actions.at:1582: sed 's,.*/$,,' stderr 1>&2 ./actions.at:1121: $PREPARSER ./input --debug ./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none ./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token 'a' (1.1: <> printer for 'a' @ 1) Shifting token 'a' (1.1: <> printer for 'a' @ 1) Entering state 1 Stack now 0 1 Reading a token Next token is token 'b' (1.2: 'b'/'c' printer for 'b' @ 2) Shifting token 'b' (1.2: 'b'/'c' printer for 'b' @ 2) Entering state 3 Stack now 0 1 3 Reading a token Next token is token 'c' (1.3: 'b'/'c' printer for 'c' @ 3) Shifting token 'c' (1.3: 'b'/'c' printer for 'c' @ 3) Entering state 5 Stack now 0 1 3 5 Reading a token Next token is token 'd' (1.4: <> printer for 'd' @ 4) Shifting token 'd' (1.4: <> printer for 'd' @ 4) Entering state 6 Stack now 0 1 3 5 6 Reading a token Now at end of input. 1.5: syntax error, unexpected end of file, expecting 'e' Error: popping token 'd' (1.4: <> printer for 'd' @ 4) Stack now 0 1 3 5 Error: popping token 'c' (1.3: 'b'/'c' printer for 'c' @ 3) Stack now 0 1 3 Error: popping token 'b' (1.2: 'b'/'c' printer for 'b' @ 2) Stack now 0 1 Error: popping token 'a' (1.1: <> printer for 'a' @ 1) Stack now 0 Cleanup: discarding lookahead token "end of file" (1.5: ) Stack now 0 ./actions.at:1121: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 345. actions.at:1071: ok ./actions.at:1478: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none stdout: ./actions.at:1056: $PREPARSER ./input '(x)' stderr: 350. actions.at:1596: testing Default %printer and %destructor for midrule values ... ./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 351. actions.at:1743: testing @$ in %initial-action implies %locations ... ./actions.at:1743: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none ./actions.at:1056: $PREPARSER ./input '!' stderr: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1743: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror ./actions.at:1586: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./actions.at:1416: $PREPARSER ./input0 --debug ./actions.at:1056: $PREPARSER ./input '!!!' stderr: Starting parse Entering state 0 Stack now 0 Reducing stack by rule 1 (line 49): -> $$ = nterm start (1.1: <> for 'S' @ 1) Entering state 1 Stack now 0 1 Reading a token Now at end of input. Shifting token END (1.1: <> for 'E' @ 1) Entering state 2 Stack now 0 1 2 Stack now 0 1 2 Cleanup: popping token END (1.1: <> for 'E' @ 1) Cleanup: popping nterm start (1.1: <> for 'S' @ 1) ./actions.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input.y:24.57-59: error: useless %destructor for type <*> [-Werror=other] input.y:24.57-59: error: useless %printer for type <*> [-Werror=other] input.y:33.3-23: error: unset value: $$ [-Werror=other] input.y:32.3-23: error: unused value: $3 [-Werror=other] ./actions.at:1056: $PREPARSER ./input '(y)' ./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input1.c input1.y stderr: stderr: sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./actions.at:1634: sed 's,.*/$,,' stderr 1>&2 ./actions.at:1238: $PREPARSER ./input --debug stderr: ./actions.at:1056: $PREPARSER ./input '(xxxxx)(x)(x)y' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token 'a' (<*>//e printer) Shifting token 'a' (<*>//e printer) Entering state 1 Stack now 0 1 Reading a token Next token is token 'b' ( printer) Shifting token 'b' ( printer) Entering state 3 Stack now 0 1 3 Reading a token Next token is token 'c' ('c' printer) Shifting token 'c' ('c' printer) Entering state 5 Stack now 0 1 3 5 Reading a token Next token is token 'd' ('d' printer) Shifting token 'd' ('d' printer) Entering state 6 Stack now 0 1 3 5 6 Reading a token Next token is token 'e' (<*>//e printer) Shifting token 'e' (<*>//e printer) Entering state 7 Stack now 0 1 3 5 6 7 Reading a token Next token is token 'f' (<*>//e printer) Shifting token 'f' (<*>//e printer) Entering state 8 Stack now 0 1 3 5 6 7 8 Reading a token Now at end of input. syntax error, unexpected end of file, expecting 'g' Error: popping token 'f' (<*>//e printer) Stack now 0 1 3 5 6 7 Error: popping token 'e' (<*>//e printer) Stack now 0 1 3 5 6 Error: popping token 'd' ('d' printer) Stack now 0 1 3 5 Error: popping token 'c' ('c' printer) Stack now 0 1 3 Error: popping token 'b' ( printer) Stack now 0 1 Error: popping token 'a' (<*>//e printer) Stack now 0 Cleanup: discarding lookahead token "end of file" () Stack now 0 stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1056: $PREPARSER ./input '(x)(x)x' ./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1238: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none stderr: stdout: ./actions.at:1479: $PREPARSER ./input --debug stderr: 341. actions.at:1056: ok Starting parse Entering state 0 Stack now 0 Reading a token Next token is token 'a' ('a') Shifting token 'a' ('a') Entering state 1 Stack now 0 1 Reading a token Next token is token 'b' ('b') syntax error Shifting token error () Entering state 3 Stack now 0 1 3 Next token is token 'b' ('b') Shifting token 'b' ('b') Entering state 5 Stack now 0 1 3 5 Reading a token Next token is token "invalid token" () Error: popping token 'b' ('b') DESTROY 'b' Stack now 0 1 3 Error: popping token error () Stack now 0 1 Shifting token error () Entering state 3 Stack now 0 1 3 Next token is token "invalid token" () Error: discarding token "invalid token" () Error: popping token error () Stack now 0 1 Shifting token error () Entering state 3 Stack now 0 1 3 Reading a token Now at end of input. Cleanup: discarding lookahead token "end of file" () Stack now 0 1 3 Cleanup: popping token error () Cleanup: popping token 'a' ('a') DESTROY 'a' ./actions.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 346. actions.at:1174: ok ./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input1.c input1.y -Werror ./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none 348. actions.at:1429: ok stderr: input1.y:30.3-4: error: useless %destructor for type <> [-Werror=other] input1.y:30.3-4: error: useless %printer for type <> [-Werror=other] ./actions.at:1417: sed 's,.*/$,,' stderr 1>&2 ./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o input.c input.y stderr: stderr: stdout: 351. actions.at:1743: ok stdout: 352. actions.at:1744: testing @$ in %destructor implies %locations ... ./actions.at:1744: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input1.c input1.y --warnings=error 349. actions.at:1532: ok 353. actions.at:1745: testing @$ in %printer implies %locations ... ./actions.at:1745: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1744: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 354. actions.at:1856: testing Qualified $$ in actions: yacc.c ... ./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Werror ./actions.at:1745: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1856: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input1.c input1.y -Wnone,none -Werror --trace=none 355. actions.at:1856: testing Qualified $$ in actions: glr.c ... 356. actions.at:1856: testing Qualified $$ in actions: lalr1.cc ... ./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: input.y:24.57-59: error: useless %destructor for type <*> [-Werror=other] 24 | %printer { #error "<*> printer should not be used" } <*> | ^~~ input.y:24.57-59: error: useless %printer for type <*> [-Werror=other] 24 | %printer { #error "<*> printer should not be used" } <*> | ^~~ input.y:33.3-23: error: unset value: $$ [-Werror=other] 33 | { @$ = 4; } // Only used. | ^~~~~~~~~~~~~~~~~~~~~ input.y:32.3-23: error: unused value: $3 [-Werror=other] 32 | { USE ($$); @$ = 3; } // Only set. | ^~~~~~~~~~~~~~~~~~~~~ ./actions.at:1641: sed 's,.*/$,,' stderr 1>&2 ./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input1.c input1.y --warnings=none -Werror --trace=none ./actions.at:1856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=error ./actions.at:1856: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./headers.at:328: echo "x9" >>expout ./actions.at:1417: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input1 input1.c $LIBS ./headers.at:329: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o xa.cc xa.y ./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Wnone,none -Werror --trace=none stderr: stdout: ./headers.at:329: $CXX $CPPFLAGS $CXXFLAGS -c -o xa.o xa.cc stderr: stdout: 352. actions.at:1744: ok ./actions.at:1856: $PREPARSER ./input --debug stderr: ./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=none -Werror --trace=none Starting parse Entering state 0 Stack now 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Stack now 0 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Stack now 0 1 3 Reducing stack by rule 1 (line 53): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Stack now 0 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Stack now 0 2 4 Stack now 0 2 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Stack now 0 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Stack now 0 1 3 Reducing stack by rule 1 (line 53): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Stack now 0 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Stack now 0 2 4 Stack now 0 2 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed -ne '/ival:/p' stderr stdout: 353. actions.at:1745: ok 354. actions.at:1856: ok 357. actions.at:1856: testing Qualified $$ in actions: glr.cc ... ./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:1656: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 358. actions.at:1856: testing Qualified $$ in actions: glr2.cc ... ./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 359. actions.at:1863: testing Destroying lookahead assigned by semantic action ... ./actions.at:1905: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1856: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./actions.at:1906: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./actions.at:1417: $PREPARSER ./input1 --debug stderr: Starting parse Entering state 0 Stack now 0 Reducing stack by rule 1 (line 49): -> $$ = nterm start (1.1: <*> for 'S' @ 1) Entering state 1 Stack now 0 1 Reading a token Now at end of input. Shifting token END (1.1: <*> for 'E' @ 1) Entering state 2 Stack now 0 1 2 Stack now 0 1 2 Cleanup: popping token END (1.1: <*> for 'E' @ 1) Cleanup: popping nterm start (1.1: <*> for 'S' @ 1) ./actions.at:1417: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 347. actions.at:1307: ok stderr: stdout: ./actions.at:1907: $PREPARSER ./input stderr: 'b' destructor 'a' destructor ./actions.at:1907: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 359. actions.at:1863: ok 360. actions.at:1918: testing YYBACKUP ... ./actions.at:1953: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: ./actions.at:1657: $PREPARSER ./input --debug stderr: Starting parse Entering state 0 Stack now 0 Reducing stack by rule 1 (line 30): -> $$ = nterm $@1 (: ) Entering state 2 Stack now 0 2 Reducing stack by rule 2 (line 31): -> $$ = nterm @2 (: 2) Entering state 4 Stack now 0 2 4 Reducing stack by rule 3 (line 32): -> $$ = nterm @3 (: 3) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 4 (line 33): -> $$ = nterm @4 (: 4) Entering state 6 Stack now 0 2 4 5 6 Reading a token Now at end of input. syntax error Error: popping nterm @4 (: 4) DESTROY 4 Stack now 0 2 4 5 Error: popping nterm @3 (: 3) DESTROY 3 Stack now 0 2 4 Error: popping nterm @2 (: 2) DESTROY 2 Stack now 0 2 Error: popping nterm $@1 (: ) Stack now 0 Cleanup: discarding lookahead token "end of file" (: ) Stack now 0 ./actions.at:1954: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1657: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 350. actions.at:1596: ok 361. types.at:25: testing %union vs. api.value.type ... ./types.at:34: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 361. types.at:25: ok 362. types.at:44: testing %yacc vs. api.value.type=union ... ./types.at:53: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 363. types.at:139: testing yacc.c api.value.type={double} ... 362. types.at:44: ok ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: stdout: ./actions.at:1856: $PREPARSER ./input --debug 364. types.at:139: testing yacc.c api.value.type={double} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: Starting parse Entering state 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Reducing stack 0 by rule 1 (line 53): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Reducing stack 0 by rule 1 (line 53): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed -ne '/ival:/p' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 355. actions.at:1856: ok 365. types.at:139: testing yacc.c api.value.type={variant} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: stdout: stderr: stdout: ./actions.at:1955: $PREPARSER ./input stderr: ./types.at:139: $PREPARSER ./test stderr: ./actions.at:1955: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./headers.at:329: echo "xa" >>expout 360. actions.at:1918: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ok ./headers.at:330: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o xb.cc xb.y 363. types.at:139: ok stderr: stdout: ./actions.at:1856: $PREPARSER ./input --debug 366. types.at:139: testing yacc.c api.value.type={variant} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Stack now 0 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Stack now 0 1 3 Reducing stack by rule 1 (line 55): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Stack now 0 2 Reading a token Next token is token "end of file" () Shifting token "end of file" () Entering state 4 Stack now 0 2 4 Stack now 0 2 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./headers.at:330: $CXX $CPPFLAGS $CXXFLAGS -c -o xb.o xb.cc Starting parse Entering state 0 Stack now 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Stack now 0 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Stack now 0 1 3 Reducing stack by rule 1 (line 55): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Stack now 0 2 Reading a token Next token is token "end of file" () Shifting token "end of file" () Entering state 4 Stack now 0 2 4 Stack now 0 2 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed -ne '/ival:/p' stderr 367. types.at:139: testing yacc.c api.value.type={struct foo} ... stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y 356. actions.at:1856: ok stdout: ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./actions.at:1059: $PREPARSER ./input '(x)' ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: 364. types.at:139: ok sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1059: $PREPARSER ./input '!' stderr: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1059: $PREPARSER ./input '!!!' stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 368. types.at:139: testing yacc.c api.value.type={struct foo} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./actions.at:1059: $PREPARSER ./input '(y)' stderr: sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./actions.at:1059: $PREPARSER ./input '(xxxxx)(x)(x)y' ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: 369. types.at:139: testing yacc.c api.value.type={struct bar} ... sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: ./actions.at:1059: $PREPARSER ./input '(x)(x)x' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 343. actions.at:1059: ok ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 365. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 371. types.at:139: testing yacc.c api.value.type={union foo} ... ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y 370. types.at:139: testing yacc.c api.value.type={struct bar} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: 367. types.at:139: ok stdout: ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 366. types.at:139: ok 372. types.at:139: testing yacc.c api.value.type={union foo} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: stdout: ./actions.at:1856: $PREPARSER ./input --debug stderr: Starting parse Entering state 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Reducing stack 0 by rule 1 (line 55): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Reducing stack 0 by rule 1 (line 55): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed -ne '/ival:/p' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: 357. actions.at:1856: ok stdout: ./types.at:139: $PREPARSER ./test stderr: 373. types.at:139: testing yacc.c %union { float fval; int ival; }; ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 374. types.at:139: testing yacc.c %union { float fval; int ival; }; %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: stdout: 368. types.at:139: ok ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 369. types.at:139: ok ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 375. types.at:139: testing yacc.c %union foo { float fval; int ival; }; ... ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: 376. types.at:139: testing yacc.c %union foo { float fval; int ival; }; %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stdout: 371. types.at:139: ok ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 370. types.at:139: ok 377. types.at:139: testing yacc.c api.value.union.name=foo; %union { float fval; int ival; }; ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 372. types.at:139: ok ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: 378. types.at:139: testing yacc.c api.value.union.name=foo; %union { float fval; int ival; }; %header ... stdout: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $PREPARSER ./test stderr: stderr: stderr: stdout: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1060: $PREPARSER ./input '(x)' ./types.at:139: $PREPARSER ./test stderr: 373. types.at:139: ok sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./actions.at:1060: $PREPARSER ./input '!' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. 374. types.at:139: ok ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 379. types.at:139: testing yacc.c api.value.type=union ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./actions.at:1060: $PREPARSER ./input '!!!' stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./actions.at:1060: $PREPARSER ./input '(y)' stderr: sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test ./actions.at:1060: $PREPARSER ./input '(xxxxx)(x)(x)y' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./actions.at:1060: $PREPARSER ./input '(x)(x)x' stderr: 380. types.at:139: testing yacc.c api.value.type=union %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 381. types.at:139: testing glr.c api.value.type={double} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stdout: 375. types.at:139: ok ./types.at:139: $PREPARSER ./test stderr: 344. actions.at:1060: ok stderr: stdout: ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./headers.at:330: echo "xb" >>expout ./headers.at:331: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o xc.cc xc.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 376. types.at:139: ok 382. types.at:139: testing glr.c api.value.type={double} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./headers.at:331: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS -c -o xc.o xc.cc 383. types.at:139: testing glr.c api.value.type={variant} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 384. types.at:139: testing glr.c api.value.type={variant} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 377. types.at:139: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 378. types.at:139: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ok 385. types.at:139: testing glr.c api.value.type={struct foo} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: stdout: 379. types.at:139: ok 386. types.at:139: testing glr.c api.value.type={struct foo} %header ... ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 380. types.at:139: ok ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 387. types.at:139: testing glr.c api.value.type={struct bar} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: stdout: ./actions.at:1856: $PREPARSER ./input --debug stderr: Starting parse Entering state 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Reducing stack 0 by rule 1 (line 55): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 388. types.at:139: testing glr.c api.value.type={struct bar} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: Starting parse Entering state 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Reducing stack 0 by rule 1 (line 55): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed -ne '/ival:/p' stderr 358. actions.at:1856: ok ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 389. types.at:139: testing glr.c api.value.type={union foo} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 381. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 382. types.at:139: ok 390. types.at:139: testing glr.c api.value.type={union foo} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 391. types.at:139: testing glr.c %union { float fval; int ival; }; ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stdout: 383. types.at:139: ok ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 384. types.at:139: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 385. types.at:139: ok 392. types.at:139: testing glr.c %union { float fval; int ival; }; %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: 393. types.at:139: testing glr.c %union foo { float fval; int ival; }; ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stdout: ./types.at:139: $PREPARSER ./test stderr: 394. types.at:139: testing glr.c %union foo { float fval; int ival; }; %header ... ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 386. types.at:139: ok stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token J [-Wcounterexamples] time limit exceeded: 6.000000 First example H i . J K $end Shift derivation $accept -> [ a -> [ H i -> [ i . J K ] ] $end ] Second example H i . J $end Reduce derivation $accept -> [ s -> [ a -> [ H i . ] J ] $end ] input.y:4.4-6: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:451: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr 267. counterexample.at:441: ok ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 387. types.at:139: ok 396. types.at:139: testing glr.c api.value.union.name=foo; %union { float fval; int ival; }; %header ... 395. types.at:139: testing glr.c api.value.union.name=foo; %union { float fval; int ival; }; ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: 397. types.at:139: testing glr.c api.value.type=union ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stdout: ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 388. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 389. types.at:139: ok 398. types.at:139: testing glr.c api.value.type=union %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test 390. types.at:139: ok 399. types.at:139: testing lalr1.cc api.value.type={double} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 391. types.at:139: ok 400. types.at:139: testing lalr1.cc api.value.type={double} %header ... ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 401. types.at:139: testing lalr1.cc api.value.type={variant} ... stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 392. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 393. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 402. types.at:139: testing lalr1.cc api.value.type={variant} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 403. types.at:139: testing lalr1.cc api.value.type={struct foo} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 394. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 404. types.at:139: testing lalr1.cc api.value.type={struct foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 397. types.at:139: ok stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: 396. types.at:139: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 395. types.at:139: ok 405. types.at:139: testing lalr1.cc api.value.type={struct bar} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 406. types.at:139: testing lalr1.cc api.value.type={struct bar} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: 407. types.at:139: testing lalr1.cc api.value.type={union foo} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./headers.at:331: echo "xc" >>expout ./headers.at:332: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o xd.cc xd.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test ./headers.at:332: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS -c -o xd.o xd.cc stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 398. types.at:139: ok 408. types.at:139: testing lalr1.cc api.value.type={union foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./headers.at:332: echo "xd" >>expout ./headers.at:342: "$PERL" -n -0777 -e ' # Ignore comments. s{/\*.*?\*/}{}gs; s{//.*}{}g; # Ignore warnings. s{# *pragma .* message ".*"}{}g; s{\b((defined|if)\ YYDEBUG |YYChar # Template parameter. |YYNTOKENS # This is actually scoped in a C++ class. |YYPUSH_MORE(?:_DEFINED)? |S_(YY(ACCEPT|EMPTY|EOF|error|UNDEF)) # These guys are scoped. |YY(?:_REINTERPRET)?_CAST |YY_ATTRIBUTE(?:_PURE|_UNUSED) |YY_CONSTEXPR |YY_COPY |YY_CPLUSPLUS |YY_IGNORE_(?:MAYBE_UNINITIALIZED|USELESS_CAST)_(?:BEGIN|END) |YY_INITIAL_VALUE |YY_MOVE |YY_MOVE_OR_COPY |YY_MOVE_REF |YY_NOEXCEPT |YY_NOTHROW |YY_NULLPTR |YY_RVREF |YY_USE |YY_\w+_INCLUDED # Header guards. |FILE\ \*yyo # Function argument. |const\ yylocp # Function argument. )\b}{}gx; while (/^(.*YY.*)$/gm) { print "$ARGV: invalid exported YY: $1\n"; } if ($ARGV =~ /\.h$/) { while (/^(.*yy.*)$/gm) { print "$ARGV: invalid exported yy: $1\n"; } } ' -- *.hh *.h ./headers.at:387: $CC $CFLAGS $CPPFLAGS -c -o c-only.o c-only.c stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./headers.at:387: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx-only.o cxx-only.cc ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test ./headers.at:387: $CXX $CXXFLAGS $CPPFLAGS $LDFLAGS c-only.o cxx-only.o -o c-and-cxx || exit 77 stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./headers.at:387: $PREPARSER ./c-and-cxx stderr: ./headers.at:387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./headers.at:392: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o parser x[1-9a-d].o -DCC_IS_CXX=$CC_IS_CXX main.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: stdout: ./headers.at:394: $PREPARSER ./parser stderr: ./headers.at:394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 310. headers.at:199: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 409. types.at:139: testing lalr1.cc %union { float fval; int ival; }; ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: 6 reduce/reduce conflicts [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] First example: . c A A $end First reduce derivation $accept `-> 0: a $end `-> 1: b d `-> 3: %empty . `-> 6: c A A Second example: . c A A $end Second reduce derivation $accept `-> 0: a $end `-> 2: c d `-> 4: %empty . `-> 6: c A A input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] time limit exceeded: 6.000000 First example: b . c A A $end First reduce derivation $accept `-> 0: a $end `-> 1: b d `-> 5: a `-> 1: b d `-> 3: %empty . `-> 6: c A A Second example: b . A $end Second reduce derivation $accept `-> 0: a $end `-> 1: b d `-> 6: c A `-> 4: %empty . input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] time limit exceeded: 6.000000 First example: c . c A A $end First reduce derivation $accept `-> 0: a $end `-> 2: c d `-> 5: a `-> 1: b d `-> 3: %empty . `-> 6: c A A Second example: c . A $end Second reduce derivation $accept `-> 0: a $end `-> 2: c d `-> 6: c A `-> 4: %empty . input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] time limit exceeded: 6.000000 First example: b c . A Shift derivation a `-> 1: b d `-> 6: c . A Second example: b c . c A A $end Reduce derivation $accept `-> 0: a $end `-> 1: b d `-> 5: a `-> 2: c d `-> 5: a `-> 1: b d `-> 3: %empty . `-> 6: c A A input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] First example: b c . c A A $end First reduce derivation $accept `-> 0: a $end `-> 1: b d `-> 5: a `-> 2: c d `-> 5: a `-> 1: b d `-> 3: %empty . `-> 6: c A A Second example: b c . A $end Second reduce derivation $accept `-> 0: a $end `-> 1: b d `-> 5: a `-> 2: c d `-> 6: c A `-> 4: %empty . input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] First example: b c . A Shift derivation a `-> 1: b d `-> 6: c . A Second example: b c . A $end Reduce derivation $accept `-> 0: a $end `-> 1: b d `-> 5: a `-> 2: c d `-> 6: c A `-> 4: %empty . input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] Example: b d . First reduce derivation a `-> 1: b d . Second reduce derivation a `-> 1: b d `-> 7: d . input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] Example: c d . First reduce derivation a `-> 2: c d . Second reduce derivation a `-> 2: c d `-> 7: d . input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] input.y:6.15: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:621: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./counterexample.at:621: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 405. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 401. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 410. types.at:139: testing lalr1.cc %union { float fval; int ival; }; %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 403. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 411. types.at:139: testing lalr1.cc api.value.type=union ... 412. types.at:139: testing lalr1.cc api.value.type=union %header ... ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test 399. types.at:139: ok stderr: 404. types.at:139: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 402. types.at:139: ok 413. types.at:139: testing lalr1.cc api.value.type=variant ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 414. types.at:139: testing lalr1.cc api.value.type=variant %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 415. types.at:139: testing lalr1.cc api.value.type=variant ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 400. types.at:139: ok 416. types.at:139: testing lalr1.cc api.value.type=variant %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 406. types.at:139: ok 417. types.at:139: testing lalr1.cc api.value.type=variant api.token.constructor ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 408. types.at:139: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 418. types.at:139: testing lalr1.cc api.value.type=variant api.token.constructor %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 407. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 419. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 409. types.at:139: ok stderr: stderr: stdout: stdout: 420. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant %header ... ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++11 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $PREPARSER ./test stdout: ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stderr: stdout: stdout: ./types.at:139: ./check ./types.at:139: $PREPARSER ./test -std=c++11 not supported ======== Testing with C++ standard flags: '' stderr: stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 411. types.at:139: ok ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 421. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant api.token.constructor ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 412. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 422. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant api.token.constructor %header ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 410. types.at:139: ok stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 423. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant api.token.constructor ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 417. types.at:139: ok stderr: 424. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant api.token.constructor %header ... ======== Testing with C++ standard flags: '' stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 413. types.at:139: ok stderr: stdout: ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 425. types.at:139: testing glr.cc api.value.type={double} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 418. types.at:139: ok ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: ./types.at:139: ./check ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 419. types.at:139: ok 426. types.at:139: testing glr.cc api.value.type={double} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 414. types.at:139: ok 427. types.at:139: testing glr.cc api.value.type={variant} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check -std=c++11 not supported ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 428. types.at:139: testing glr.cc api.value.type={variant} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: ./check ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++11 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++11 not supported ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 420. types.at:139: ok stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: ./check 429. types.at:139: testing glr.cc api.value.type={struct foo} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++11 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 415. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 430. types.at:139: testing glr.cc api.value.type={struct foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' 416. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test 431. types.at:139: testing glr.cc api.value.type={struct bar} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: ./check ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $PREPARSER ./test stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: 6 reduce/reduce conflicts [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] First example . c A A $end First reduce derivation $accept -> [ a -> [ b -> [ . ] d -> [ c A A ] ] $end ] Second example . c A A $end Second reduce derivation $accept -> [ a -> [ c -> [ . ] d -> [ c A A ] ] $end ] input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] time limit exceeded: 6.000000 First example b . c A A $end First reduce derivation $accept -> [ a -> [ b d -> [ a -> [ b -> [ . ] d -> [ c A A ] ] ] ] $end ] Second example b . A $end Second reduce derivation $accept -> [ a -> [ b d -> [ c -> [ . ] A ] ] $end ] input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] time limit exceeded: 6.000000 First example c . c A A $end First reduce derivation $accept -> [ a -> [ c d -> [ a -> [ b -> [ . ] d -> [ c A A ] ] ] ] $end ] Second example c . A $end Second reduce derivation $accept -> [ a -> [ c d -> [ c -> [ . ] A ] ] $end ] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] time limit exceeded: 6.000000 First example b c . A Shift derivation a -> [ b d -> [ c . A ] ] Second example b c . c A A $end Reduce derivation $accept -> [ a -> [ b d -> [ a -> [ c d -> [ a -> [ b -> [ . ] d -> [ c A A ] ] ] ] ] ] $end ] input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] First example b c . c A A $end First reduce derivation $accept -> [ a -> [ b d -> [ a -> [ c d -> [ a -> [ b -> [ . ] d -> [ c A A ] ] ] ] ] ] $end ] Second example b c . A $end Second reduce derivation $accept -> [ a -> [ b d -> [ a -> [ c d -> [ c -> [ . ] A ] ] ] ] $end ] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] First example b c . A Shift derivation a -> [ b d -> [ c . A ] ] Second example b c . A $end Reduce derivation $accept -> [ a -> [ b d -> [ a -> [ c d -> [ c -> [ . ] A ] ] ] ] $end ] input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] Example b d . First reduce derivation a -> [ b d . ] Second reduce derivation a -> [ b d -> [ d . ] ] input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] Example c d . First reduce derivation a -> [ c d . ] Second reduce derivation a -> [ c d -> [ d . ] ] input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] input.y:6.15: warning: rule useless in parser due to conflicts [-Wother] ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./counterexample.at:621: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' 270. counterexample.at:610: ok ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 432. types.at:139: testing glr.cc api.value.type={struct bar} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 421. types.at:139: ok stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 433. types.at:139: testing glr.cc api.value.type={union foo} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 422. types.at:139: ok 434. types.at:139: testing glr.cc api.value.type={union foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stdout: stderr: stderr: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 423. types.at:139: ok ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 435. types.at:139: testing glr.cc %union { float fval; int ival; }; ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 424. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 436. types.at:139: testing glr.cc %union { float fval; int ival; }; %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 426. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 427. types.at:139: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test 437. types.at:139: testing glr.cc api.value.type=union ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 438. types.at:139: testing glr.cc api.value.type=union %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 425. types.at:139: ok 439. types.at:139: testing glr2.cc api.value.type={double} ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 429. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 428. types.at:139: ok 440. types.at:139: testing glr2.cc api.value.type={double} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 441. types.at:139: testing glr2.cc api.value.type={variant} ... ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 430. types.at:139: ok stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: 442. types.at:139: testing glr2.cc api.value.type={variant} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: ./check stderr: -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 431. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 443. types.at:139: testing glr2.cc api.value.type={struct foo} ... ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: ./check stdout: ./types.at:139: ./check ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' stderr: stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: stderr: ./types.at:139: ./check ./types.at:139: $PREPARSER ./test stdout: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: stdout: stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: ./check ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 432. types.at:139: ok 444. types.at:139: testing glr2.cc api.value.type={struct foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 433. types.at:139: ok stdout: ./types.at:139: ./check stderr: stdout: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 445. types.at:139: testing glr2.cc api.value.type={struct bar} ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 434. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: 446. types.at:139: testing glr2.cc api.value.type={struct bar} %header ... ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 435. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 447. types.at:139: testing glr2.cc api.value.type={union foo} ... ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: 436. types.at:139: stderr: ok stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 448. types.at:139: testing glr2.cc api.value.type={union foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 437. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 449. types.at:139: testing glr2.cc %union { float fval; int ival; }; ... stdout: ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: ./check ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check stderr: -std=c++03 not supported ======== Testing with C++ standard flags: '' stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' 438. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 450. types.at:139: testing glr2.cc %union { float fval; int ival; }; %header ... ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: ./check ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stderr: stdout: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: ./check ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: ./check ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 439. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 451. types.at:139: testing glr2.cc api.value.type=union ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: ./check ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 440. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: ./check ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 452. types.at:139: testing glr2.cc api.value.type=union %header ... ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 441. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 453. types.at:377: testing lalr1.cc: Named %union ... ./types.at:377: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 453. types.at:377: ok 454. types.at:377: testing glr.cc: Named %union ... ./types.at:377: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 454. types.at:377: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 455. scanner.at:326: testing Token numbers: yacc.c ... ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./scanner.at:326: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' stderr: stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.c ./types.at:139: $PREPARSER ./test stderr: ./scanner.at:326: $PREPARSER ./input ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stdout: ======== Testing with C++ standard flags: '' ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: 455. scanner.at:326: stderr: ok stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: ./check ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 456. scanner.at:326: testing Token numbers: yacc.c api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./scanner.at:326: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.c ./scanner.at:326: $PREPARSER ./input stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 456. scanner.at:326: ok 442. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 457. scanner.at:326: testing Token numbers: glr.c ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ======== Testing with C++ standard flags: '' 458. scanner.at:326: testing Token numbers: glr.c api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./scanner.at:326: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./scanner.at:326: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: ./check stderr: -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 443. types.at:139: ok stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' 459. scanner.at:326: testing Token numbers: lalr1.cc ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./scanner.at:326: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.c ./scanner.at:326: $PREPARSER ./input stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 458. scanner.at:326: ok stderr: stdout: stderr: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.c stdout: ./types.at:139: $PREPARSER ./test ./scanner.at:326: $PREPARSER ./input stderr: stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' 457. scanner.at:326: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: 460. scanner.at:326: testing Token numbers: lalr1.cc api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./types.at:139: $PREPARSER ./test stderr: ./scanner.at:326: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: ./check ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 461. scanner.at:326: testing Token numbers: glr.cc ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./scanner.at:326: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc ./scanner.at:326: $PREPARSER ./input stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 459. scanner.at:326: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 462. scanner.at:326: testing Token numbers: glr.cc api.token.raw ... ======== Testing with C++ standard flags: '' ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./scanner.at:326: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc ./scanner.at:326: $PREPARSER ./input ======== Testing with C++ standard flags: '' stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 460. scanner.at:326: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 463. scanner.at:326: testing Token numbers: glr2.cc ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: stderr: stdout: ./types.at:139: ./check ./types.at:139: $PREPARSER ./test ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./scanner.at:326: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc ./scanner.at:326: $PREPARSER ./input ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 461. scanner.at:326: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 464. scanner.at:326: testing Token numbers: glr2.cc api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./scanner.at:326: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc ./scanner.at:326: $PREPARSER ./input stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 462. scanner.at:326: ok 465. scanner.at:326: testing Token numbers: lalr1.d ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.d input.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 465. scanner.at:326: skipped (scanner.at:326) stderr: stderr: stdout: stdout: 466. scanner.at:326: testing Token numbers: lalr1.d api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.d input.y ./types.at:139: $PREPARSER ./test ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 444. types.at:139: ok 466. scanner.at:326: skipped (scanner.at:326) ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 467. scanner.at:326: testing Token numbers: lalr1.java ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.java input.y 468. scanner.at:326: testing Token numbers: lalr1.java api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.java input.y 467. scanner.at:326: skipped (scanner.at:326) 468. scanner.at:326: skipped (scanner.at:326) 469. scanner.at:330: testing Token numbers: lalr1.cc api.token.raw api.value.type=variant api.token.constructor ... ./scanner.at:330: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 470. calc.at:1334: testing Calculator parse.trace ... ./calc.at:1334: mv calc.y.tmp calc.y ./calc.at:1334: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./scanner.at:330: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./calc.at:1334: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: stdout: ./calc.at:1334: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./calc.at:1334: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1334: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 7) Shifting token "number" (1.1: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 7) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 7) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: -3) -> $$ = nterm exp (1.1: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: -6) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 5) Shifting token "number" (1.1: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 5) -> $$ = nterm exp (1.1: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 5) -> $$ = nterm exp (1.1: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -5) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -5) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -5) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: -1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: -1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 4) Shifting token "number" (1.1: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 4) -> $$ = nterm exp (1.1: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 4) -> $$ = nterm exp (1.1: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -4) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -4) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -4) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 2) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 8) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 256) Shifting token "number" (1.1: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 256) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 256) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 4) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 4) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 64) Shifting token "number" (1.1: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 64) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 64) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 7) Shifting token "number" (1.1: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 7) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 7) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: -3) -> $$ = nterm exp (1.1: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: -6) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 5) Shifting token "number" (1.1: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 5) -> $$ = nterm exp (1.1: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 5) -> $$ = nterm exp (1.1: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -5) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -5) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -5) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: -1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: -1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 4) Shifting token "number" (1.1: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 4) -> $$ = nterm exp (1.1: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 4) -> $$ = nterm exp (1.1: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -4) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -4) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -4) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 2) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 8) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 256) Shifting token "number" (1.1: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 256) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 256) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 4) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 4) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 64) Shifting token "number" (1.1: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 64) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 64) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: stdout: input: | 1 2 ./calc.at:1334: $PREPARSER ./calc input ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.1: 2) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.1: 2) Stack now 0 ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./calc.at:1334: cat stderr stderr: input: stdout: ./types.at:139: $PREPARSER ./test | 1//2 ./calc.at:1334: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.1: ) syntax error Error: popping token '/' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.1: ) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.1: ) syntax error Error: popping token '/' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.1: ) Stack now 0 ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 445. types.at:139: ok ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./calc.at:1334: cat stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS input: 471. calc.at:1336: testing Calculator %header ... ./calc.at:1336: mv calc.y.tmp calc.y | error ./calc.at:1334: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1336: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: stdout: stderr: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 ./calc.at:1336: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./calc.at:1334: cat stderr input: | 1 = 2 = 3 ./calc.at:1334: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.1: ) syntax error Error: popping nterm exp (1.1: 2) Stack now 0 8 19 Error: popping token '=' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.1: ) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.1: ) syntax error Error: popping nterm exp (1.1: 2) Stack now 0 8 19 Error: popping token '=' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.1: ) Stack now 0 ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1334: cat stderr input: | | +1 ./calc.at:1334: $PREPARSER ./calc input stderr: stderr: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc ./scanner.at:326: $PREPARSER ./input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (1.1: ) syntax error Error: popping nterm input (1.1: ) Stack now 0 Cleanup: discarding lookahead token '+' (1.1: ) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 464. scanner.at:326: ok stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (1.1: ) syntax error Error: popping nterm input (1.1: ) Stack now 0 Cleanup: discarding lookahead token '+' (1.1: ) Stack now 0 stdout: ./calc.at:1336: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' 472. calc.at:1337: testing Calculator %debug %locations ... ./calc.at:1337: mv calc.y.tmp calc.y ./calc.at:1337: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1334: cat stderr ./calc.at:1336: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1334: $PREPARSER ./calc /dev/null stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1336: $PREPARSER ./calc input ./calc.at:1337: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1336: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: | 1 2 ./calc.at:1336: $PREPARSER ./calc input ./calc.at:1334: cat stderr stderr: stderr: syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc input: stderr: syntax error stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stdout: ./calc.at:1334: $PREPARSER ./calc input ./scanner.at:326: $PREPARSER ./input stderr: ./scanner.at:330: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc stderr: ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.1: ) syntax error Error: popping token '+' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 3) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 1) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.1: ) syntax error Error: popping token '*' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 2) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 3333) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 4444) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 4444 != 1 -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 4444) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1336: cat stderr stderr: 463. scanner.at:326: ok ./scanner.at:330: $PREPARSER ./input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.1: ) syntax error Error: popping token '+' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 3) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 1) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.1: ) syntax error Error: popping token '*' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 2) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 3333) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 4444) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 4444 != 1 -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 4444) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: input: | 1//2 ./calc.at:1336: $PREPARSER ./calc input ./scanner.at:330: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 469. scanner.at:330: ok syntax error 473. calc.at:1338: testing Calculator %locations api.location.type={Span} ... ./calc.at:1338: mv calc.y.tmp calc.y ./calc.at:1338: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1334: cat stderr input: ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1338: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1334: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 121): $1 = token '!' (1.1: ) $2 = token '!' (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: ./calc.at:1336: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 121): $1 = token '!' (1.1: ) $2 = token '!' (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./types.at:139: $PREPARSER ./test stderr: input: | error ./calc.at:1336: $PREPARSER ./calc input ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 446. types.at:139: ok 474. calc.at:1340: testing Calculator %name-prefix "calc" ... ./calc.at:1340: mv calc.y.tmp calc.y stderr: ./calc.at:1340: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: stdout: ./calc.at:1337: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error ./calc.at:1337: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1334: cat stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1337: $PREPARSER ./calc input ./calc.at:1336: cat stderr stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 123): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 123): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1334: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 120): $1 = token '-' (1.1: ) $2 = token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 475. calc.at:1341: testing Calculator %verbose ... ./calc.at:1340: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: ./calc.at:1341: mv calc.y.tmp calc.y Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 123): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 123): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: ./calc.at:1337: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 120): $1 = token '-' (1.1: ) $2 = token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | 1 = 2 = 3 ./calc.at:1336: $PREPARSER ./calc input stderr: input: syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 ./calc.at:1337: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1341: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 syntax error ./calc.at:1334: cat stderr ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1337: cat stderr input: ./calc.at:1336: cat stderr | 1//2 ./calc.at:1337: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (* *) + (*) + (*) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1334: $PREPARSER ./calc input stderr: input: | | +1 ./calc.at:1336: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 3333) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error stderr: stdout: ./calc.at:1337: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 3333) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: | error ./calc.at:1338: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1337: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1338: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1337: cat stderr input: input: | 1 = 2 = 3 ./calc.at:1337: $PREPARSER ./calc input ./calc.at:1336: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1336: $PREPARSER ./calc /dev/null | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1338: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 stderr: stdout: syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: ./calc.at:1334: cat stderr syntax error ./types.at:139: $PREPARSER ./test ./calc.at:1340: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !+ ++ ./calc.at:1334: $PREPARSER ./calc input ./calc.at:1337: cat stderr 449. types.at:139: ok ./calc.at:1340: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c stderr: stderr: ./calc.at:1338: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 122): $1 = token '!' (1.1: ) $2 = token '+' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) input: ./calc.at:1340: $PREPARSER ./calc input ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1336: cat stderr ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | | +1 ./calc.at:1337: $PREPARSER ./calc input | 1 2 ./calc.at:1338: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1336: $PREPARSER ./calc input stderr: stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.3: syntax error stderr: stderr: ./calc.at:1340: $EGREP -c -v 'Return for a new token:|LAC:' stderr syntax error syntax error syntax error syntax error error: 4444 != 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 122): $1 = token '!' (1.1: ) $2 = token '+' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1334: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1337: cat stderr ./calc.at:1337: $PREPARSER ./calc /dev/null ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | 1 2 ./calc.at:1340: $PREPARSER ./calc input stderr: syntax error Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1336: cat stderr 476. calc.at:1342: testing Calculator %yacc ... ./calc.at:1342: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi ./calc.at:1342: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | 1 + 2 * 3 + !- ++ ./calc.at:1334: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 123): $1 = token '!' (1.1: ) $2 = token '-' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) syntax error ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stdout: ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (!!) + (1 2) = 1 ./calc.at:1336: $PREPARSER ./calc input ./calc.at:1341: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: ./calc.at:1338: cat stderr syntax error error: 2222 != 1 ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1341: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c stderr: syntax error error: 2222 != 1 ./calc.at:1337: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 123): $1 = token '!' (1.1: ) $2 = token '-' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1337: $PREPARSER ./calc input ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: | 1//2 ./calc.at:1341: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1340: cat stderr ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1338: $PREPARSER ./calc input ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1342: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS 1.3: syntax error input: | 1 2 ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1337: cat stderr syntax error stderr: | 1//2 ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error ./calc.at:1340: $PREPARSER ./calc input stderr: stderr: syntax error ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error input: ./calc.at:1336: cat stderr stderr: | (!!) + (1 2) = 1 input: ./calc.at:1337: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 128): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1334: cat stderr ./calc.at:1336: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 128): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) syntax error syntax error error: 2222 != 1 ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: syntax error | 1 + 2 * 3 + !* ++ stderr: ./calc.at:1334: $PREPARSER ./calc input syntax error syntax error error: 2222 != 1 ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 124): $1 = token '!' (1.1: ) $2 = token '*' (1.1: ) memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1340: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 124): $1 = token '!' (1.1: ) $2 = token '*' (1.1: ) memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1338: cat stderr input: | error ./calc.at:1340: $PREPARSER ./calc input stderr: syntax error ./calc.at:1341: cat stderr ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: cat stderr ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error input: | error ./calc.at:1336: cat stderr ./calc.at:1338: $PREPARSER ./calc input input: stderr: 1.1: syntax error ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1337: $PREPARSER ./calc input stderr: ./calc.at:1334: cat stderr 1.1: syntax error stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 127): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: input: ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 | (* *) + (*) + (*) ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1336: $PREPARSER ./calc input ./calc.at:1341: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 127): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) syntax error syntax error syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1338: cat stderr stderr: syntax error syntax error syntax error ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: syntax error ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1334: $PREPARSER ./calc input stderr: stderr: syntax error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2222) Shifting token "number" (1.1: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1337: cat stderr stderr: ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2222) Shifting token "number" (1.1: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: | 1 = 2 = 3 stderr: stdout: ./calc.at:1338: $PREPARSER ./calc input ./types.at:139: $PREPARSER ./test stderr: input: stderr: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.7: syntax error | (* *) + (*) + (*) ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: $PREPARSER ./calc input ./calc.at:1336: cat stderr stderr: 1.7: syntax error stderr: ./calc.at:1340: cat stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 = 2 = 3 input: ./calc.at:1340: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1341: cat stderr ./calc.at:1336: $PREPARSER ./calc input 447. types.at:139: ok stderr: stderr: ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | error stderr: ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1338: cat stderr syntax error stderr: syntax error ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1336: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: input: syntax error ./calc.at:1334: cat stderr ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1338: $PREPARSER ./calc input stderr: 2.1: syntax error input: ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1340: cat stderr input: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (1 + #) = 1111 | 1 + 2 * 3 + !- ++ stdout: stderr: ./calc.at:1336: $PREPARSER ./calc input ./calc.at:1337: cat stderr ./calc.at:1334: $PREPARSER ./calc input 2.1: syntax error ./types.at:139: $PREPARSER ./test input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1337: $PREPARSER ./calc input | | +1 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1340: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 129): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 129): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1337: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1341: cat stderr stderr: ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error input: 477. calc.at:1343: testing Calculator parse.error=detailed ... input: ./calc.at:1343: mv calc.y.tmp calc.y | 1 + 2 * 3 + !- ++ ./calc.at:1337: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1343: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ======== Testing with C++ standard flags: '' ./calc.at:1334: cat stderr stderr: ./calc.at:1338: cat stderr stderr: ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 130): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1338: $PREPARSER ./calc /dev/null input: ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: | (# + 1) = 1111 syntax error ./calc.at:1334: $PREPARSER ./calc input 1.1: syntax error ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 130): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) 1.1: syntax error stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1336: cat stderr stderr: ./calc.at:1340: cat stderr ./calc.at:1341: cat stderr ./calc.at:1340: $PREPARSER ./calc /dev/null input: | 1 + 2 * 3 + !* ++ stdout: ./calc.at:1336: $PREPARSER ./calc input stderr: ./calc.at:1342: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: syntax error memory exhausted input: ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1343: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1342: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1338: cat stderr memory exhausted | | +1 input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 input: ./calc.at:1342: $PREPARSER ./calc input ./calc.at:1341: $PREPARSER ./calc input stderr: syntax error ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1338: $PREPARSER ./calc input syntax error stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1336: cat stderr ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1334: cat stderr stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 stderr: ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error stderr: ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1342: $EGREP -c -v 'Return for a new token:|LAC:' stderr | (#) + (#) = 2222 ./calc.at:1337: cat stderr ./calc.at:1336: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1341: cat stderr input: stderr: input: input: | 1 2 syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1342: $PREPARSER ./calc input ./calc.at:1341: $PREPARSER ./calc /dev/null stderr: | (1 + # + 1) = 1111 stderr: stderr: ./calc.at:1338: cat stderr stdout: | 1 + 2 * 3 + !* ++ ./calc.at:1337: $PREPARSER ./calc input syntax error syntax error ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: ./check ./calc.at:1334: $PREPARSER ./calc input ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 131): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 131): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) syntax error | (!!) + (1 2) = 1 stderr: ./calc.at:1338: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1340: cat stderr ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1340: $PREPARSER ./calc input ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1341: cat stderr ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1342: cat stderr syntax error syntax error syntax error syntax error error: 4444 != 1 input: ./calc.at:1336: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1337: cat stderr stderr: ./calc.at:1338: cat stderr input: ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 stderr: ./calc.at:1342: $PREPARSER ./calc input syntax error syntax error syntax error syntax error error: 4444 != 1 input: stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS syntax error syntax error syntax error syntax error error: 4444 != 1 | (1 + #) = 1111 syntax error ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1336: $PREPARSER ./calc input input: ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1337: $PREPARSER ./calc input stderr: stderr: syntax error | (- *) + (1 2) = 1 ./calc.at:1338: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.8: ) Error: discarding token "invalid token" (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 syntax error: invalid character: '#' syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.8: ) Error: discarding token "invalid token" (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 stderr: ./calc.at:1334: cat stderr ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1340: cat stderr syntax error: invalid character: '#' ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1340: $PREPARSER ./calc input ./calc.at:1337: cat stderr stderr: input: ./calc.at:1342: cat stderr syntax error error: 2222 != 1 ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + #) = 1111 ./calc.at:1337: $PREPARSER ./calc input stderr: ./calc.at:1338: cat stderr syntax error error: 2222 != 1 | (1 + 1) / (1 - 1) stderr: ./calc.at:1334: $PREPARSER ./calc input input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1342: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 2) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 0) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 10 (line 101): $1 = nterm exp (1.1: 2) $2 = token '/' (1.1: ) $3 = nterm exp (1.1: 0) error: null divisor -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) syntax error input: ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) ./calc.at:1338: $PREPARSER ./calc input ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1341: cat stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1337: cat stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 2) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 0) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 10 (line 101): $1 = nterm exp (1.1: 2) $2 = token '/' (1.1: ) $3 = nterm exp (1.1: 0) error: null divisor -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1340: cat stderr ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1336: cat stderr | (!!) + (1 2) = 1 ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (# + 1) = 1111 stderr: ./calc.at:1337: $PREPARSER ./calc input syntax error error: 2222 != 1 stderr: ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1342: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1338: cat stderr stderr: syntax error error: 2222 != 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (- *) + (1 2) = 1 ./calc.at:1340: $PREPARSER ./calc input stderr: input: ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: syntax error syntax error error: 2222 != 1 input: | (# + 1) = 1111 ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1338: $PREPARSER ./calc input ./calc.at:1336: $PREPARSER ./calc input ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 stderr: ./calc.at:1342: $PREPARSER ./calc input stderr: stderr: syntax error: invalid character: '#' ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error error: 2222 != 1 syntax error ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1337: cat stderr ./calc.at:1338: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: ./calc.at:1334: cat stderr stderr: syntax error syntax error: invalid character: '#' input: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + # + 1) = 1111 ./calc.at:1337: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ ./calc.at:1338: $PREPARSER ./calc input stderr: stderr: ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 470. calc.at:1334: ok stderr: ./calc.at:1341: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: ./types.at:139: $PREPARSER ./test ./calc.at:1342: cat stderr stderr: ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: | (- *) + (1 2) = 1 ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1337: cat stderr ./calc.at:1340: cat stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: syntax error syntax error error: 2222 != 1 | | +1 ./calc.at:1342: $PREPARSER ./calc input input: 448. types.at:139: ok ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1340: $PREPARSER ./calc input input: stderr: stderr: | (1 + 1) / (1 - 1) ./calc.at:1337: $PREPARSER ./calc input syntax error syntax error error: 2222 != 1 stderr: syntax error syntax error syntax error stderr: ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 108): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 108): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: syntax error 478. calc.at:1344: testing Calculator parse.error=verbose ... ./calc.at:1344: mv calc.y.tmp calc.y ./calc.at:1336: cat stderr ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1344: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y syntax error syntax error syntax error ./calc.at:1338: cat stderr input: | (1 + # + 1) = 1111 ./calc.at:1336: $PREPARSER ./calc input ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: 479. calc.at:1346: testing Calculator api.pure=full %locations ... ./calc.at:1341: cat stderr syntax error: invalid character: '#' | 1 + 2 * 3 + !* ++ ./calc.at:1346: mv calc.y.tmp calc.y ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1338: $PREPARSER ./calc input ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1346: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y 1.14: memory exhausted ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error: invalid character: '#' ./calc.at:1340: cat stderr stdout: ./calc.at:1343: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: 1.14: memory exhausted ./calc.at:1337: cat stderr input: | (* *) + (*) + (*) ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1342: cat stderr stderr: syntax error syntax error syntax error | 1 + 2 * 3 + !+ ++ ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 472. calc.at:1337: ok ./calc.at:1340: $PREPARSER ./calc input ./calc.at:1342: $PREPARSER ./calc /dev/null stderr: stderr: ./calc.at:1343: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c syntax error syntax error syntax error ./calc.at:1344: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1338: cat stderr input: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1343: $PREPARSER ./calc input stderr: ./calc.at:1340: $EGREP -c -v 'Return for a new token:|LAC:' stderr syntax error input: stderr: | (#) + (#) = 2222 ./calc.at:1338: $PREPARSER ./calc input ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1336: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1346: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1341: cat stderr input: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1343: $EGREP -c -v 'Return for a new token:|LAC:' stderr | 1 + 2 * 3 + !- ++ ./calc.at:1340: $PREPARSER ./calc input ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (1 + 1) / (1 - 1) ./calc.at:1336: $PREPARSER ./calc input input: 480. calc.at:1347: testing Calculator api.push-pull=both api.pure=full %locations ... ./calc.at:1347: mv calc.y.tmp calc.y ./calc.at:1338: cat stderr ./calc.at:1342: cat stderr stderr: error: null divisor ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1341: $PREPARSER ./calc input stderr: | 1 2 error: null divisor input: ./calc.at:1343: $PREPARSER ./calc input ./calc.at:1347: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | (1 + #) = 1111 stderr: ./calc.at:1338: $PREPARSER ./calc input syntax error, unexpected number ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 1.6: syntax error: invalid character: '#' ./calc.at:1342: $PREPARSER ./calc input stderr: ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected number stderr: ./calc.at:1340: cat stderr ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' stderr: stderr: ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error syntax error syntax error syntax error error: 4444 != 1 input: | 1 + 2 * 3 + !* ++ ./calc.at:1341: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1340: $PREPARSER ./calc input ./calc.at:1343: cat stderr stderr: memory exhausted ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: memory exhausted input: | 1//2 ./calc.at:1343: $PREPARSER ./calc input stderr: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1336: cat stderr ./calc.at:1338: cat stderr input: stderr: ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !- ++ input: ./calc.at:1341: $PREPARSER ./calc input | (# + 1) = 1111 ./calc.at:1342: cat stderr ./calc.at:1338: $PREPARSER ./calc input syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1347: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: 471. calc.at:1336: ok stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1340: cat stderr ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 ./calc.at:1342: $PREPARSER ./calc input stderr: stderr: input: stderr: 1.2: syntax error: invalid character: '#' | (#) + (#) = 2222 ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1340: $PREPARSER ./calc input syntax error error: 2222 != 1 ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1343: cat stderr stderr: stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' syntax error error: 2222 != 1 ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | error ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: $PREPARSER ./calc input ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error, unexpected invalid token ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1338: cat stderr ./calc.at:1340: cat stderr stderr: syntax error, unexpected invalid token ./calc.at:1342: cat stderr input: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 ./calc.at:1340: $PREPARSER ./calc input stderr: input: input: syntax error: invalid character: '#' ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 | (1 + # + 1) = 1111 ./calc.at:1342: $PREPARSER ./calc input ./calc.at:1338: $PREPARSER ./calc input stderr: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error error: 2222 != 1 syntax error: invalid character: '#' ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error syntax error error: 2222 != 1 ./calc.at:1343: cat stderr input: ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1341: cat stderr | 1 = 2 = 3 ./calc.at:1343: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' stderr: syntax error, unexpected '=' ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error, unexpected '=' 481. calc.at:1348: testing Calculator parse.error=detailed %locations ... input: ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !* ++ ./calc.at:1340: cat stderr ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1348: mv calc.y.tmp calc.y input: | (# + 1) = 1111 ./calc.at:1348: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1340: $PREPARSER ./calc input ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: memory exhausted ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1342: cat stderr memory exhausted ./calc.at:1343: cat stderr syntax error: invalid character: '#' ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' input: input: ./calc.at:1338: cat stderr | | +1 ./calc.at:1343: $PREPARSER ./calc input stderr: | (* *) + (*) + (*) ./calc.at:1342: $PREPARSER ./calc input syntax error, unexpected '+' stderr: ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error syntax error ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + 1) / (1 - 1) ./calc.at:1338: $PREPARSER ./calc input stderr: stderr: 1.11-17: error: null divisor ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected '+' stderr: ./calc.at:1348: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS 1.11-17: error: null divisor ./calc.at:1340: cat stderr input: | (1 + # + 1) = 1111 ./calc.at:1340: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1341: cat stderr stderr: ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error syntax error ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (#) + (#) = 2222 ./calc.at:1341: $PREPARSER ./calc input stderr: stderr: stdout: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1346: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' syntax error: invalid character: '#' stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1346: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1338: cat stderr ./calc.at:1343: cat stderr stderr: input: stdout: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1344: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1346: $PREPARSER ./calc input 473. calc.at:1338: ok stderr: ./calc.at:1344: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1343: $PREPARSER ./calc /dev/null ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1346: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: input: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected end of file | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1340: cat stderr stderr: ./calc.at:1344: $PREPARSER ./calc input input: syntax error, unexpected end of file stderr: ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1346: $PREPARSER ./calc input input: ./calc.at:1341: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1342: cat stderr ./calc.at:1340: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1344: $EGREP -c -v 'Return for a new token:|LAC:' stderr error: null divisor ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | (1 + #) = 1111 ./calc.at:1341: $PREPARSER ./calc input stderr: 1.3: syntax error ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: null divisor input: stderr: | 1 + 2 * 3 + !+ ++ syntax error: invalid character: '#' ./calc.at:1342: $PREPARSER ./calc input ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1344: $PREPARSER ./calc input stderr: syntax error, unexpected number ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.3: syntax error syntax error, unexpected number ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' stderr: ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: cat stderr 482. calc.at:1350: testing Calculator parse.error=detailed %locations %header api.prefix={calc} %verbose %yacc ... ./calc.at:1350: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1342: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: ./calc.at:1346: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1343: $PREPARSER ./calc input ./calc.at:1344: cat stderr ./calc.at:1350: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1340: cat stderr | 1 + 2 * 3 + !- ++ ./calc.at:1342: $PREPARSER ./calc input input: stderr: stderr: input: ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 474. calc.at:1340: ok | 1//2 ./calc.at:1346: $PREPARSER ./calc input stderr: ./calc.at:1341: cat stderr stderr: 1.3: syntax error | 1//2 ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: $PREPARSER ./calc input stderr: stderr: stdout: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: ./calc.at:1347: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c syntax error, unexpected '/', expecting number or '-' or '(' or '!' stderr: syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 input: ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.3: syntax error input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1342: cat stderr ./calc.at:1347: $PREPARSER ./calc input stderr: | (# + 1) = 1111 ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1343: cat stderr stderr: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' input: | 1 + 2 * 3 + !* ++ | (!!) + (1 2) = 1 ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1343: $PREPARSER ./calc input ./calc.at:1344: cat stderr ./calc.at:1342: $PREPARSER ./calc input ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected number error: 2222 != 1 ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: memory exhausted ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1346: cat stderr syntax error, unexpected number error: 2222 != 1 483. calc.at:1351: testing Calculator parse.error=detailed %locations %header %name-prefix "calc" api.token.prefix={TOK_} %verbose %yacc ... ./calc.at:1351: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi stderr: memory exhausted stderr: syntax error: invalid character: '#' ./calc.at:1350: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1351: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y input: | error ./calc.at:1344: $PREPARSER ./calc input stderr: stderr: ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected invalid token ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1347: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error ./calc.at:1346: $PREPARSER ./calc input ./calc.at:1342: cat stderr ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: cat stderr stderr: 1.1: syntax error input: ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 stderr: ./calc.at:1343: $PREPARSER ./calc input stderr: input: syntax error, unexpected invalid token | (#) + (#) = 2222 ./calc.at:1342: $PREPARSER ./calc input input: stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.1: syntax error ./calc.at:1341: cat stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: $PREPARSER ./calc input stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: ./calc.at:1351: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS 1.3: syntax error ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: 1.3: syntax error | (1 + # + 1) = 1111 ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1344: cat stderr ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' ./calc.at:1346: cat stderr input: input: ./calc.at:1342: cat stderr | 1 = 2 = 3 ./calc.at:1346: $PREPARSER ./calc input | 1 = 2 = 3 stderr: ./calc.at:1344: $PREPARSER ./calc input ./calc.at:1347: cat stderr ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.7: syntax error ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (1 + #) = 1111 ./calc.at:1343: cat stderr ./calc.at:1342: $PREPARSER ./calc input stderr: 1.7: syntax error stderr: syntax error: invalid character: '#' syntax error, unexpected '=' ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' | 1//2 ./calc.at:1347: $PREPARSER ./calc input ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.3: syntax error ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: 1.3: syntax error stdout: ./calc.at:1346: cat stderr stderr: ./calc.at:1348: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (* *) + (*) + (*) ./calc.at:1343: $PREPARSER ./calc input | | +1 ./calc.at:1346: $PREPARSER ./calc input ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c syntax error, unexpected '=' stderr: stderr: 2.1: syntax error ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1342: cat stderr ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 2.1: syntax error ./calc.at:1341: cat stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1348: $PREPARSER ./calc input ./calc.at:1347: cat stderr stderr: stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 input: ./calc.at:1342: $PREPARSER ./calc input | error stderr: ./calc.at:1347: $PREPARSER ./calc input syntax error: invalid character: '#' stderr: ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error stderr: ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1348: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: ./calc.at:1346: cat stderr stderr: stderr: ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + 1) / (1 - 1) ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1344: cat stderr 1.1: syntax error syntax error: invalid character: '#' ./calc.at:1343: cat stderr stderr: ./calc.at:1346: $PREPARSER ./calc /dev/null input: error: null divisor input: ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1348: $PREPARSER ./calc input stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1343: $PREPARSER ./calc input 1.1: syntax error ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error, unexpected number ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1344: $PREPARSER ./calc input stderr: stderr: ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 error: null divisor stderr: 1.1: syntax error stderr: ./calc.at:1343: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: syntax error, unexpected '+' ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error, unexpected number input: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: cat stderr | 1 + 2 * 3 + !- ++ ./calc.at:1343: $PREPARSER ./calc input ./calc.at:1342: cat stderr stderr: ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1341: cat stderr stderr: ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected '+' ./calc.at:1346: cat stderr input: 475. calc.at:1341: ok | (1 + # + 1) = 1111 ./calc.at:1342: $PREPARSER ./calc input input: stderr: ./calc.at:1348: cat stderr | 1 = 2 = 3 ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: $PREPARSER ./calc input input: ./calc.at:1343: cat stderr stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' stderr: ./calc.at:1346: $PREPARSER ./calc input 1.7: syntax error ./calc.at:1344: cat stderr input: stderr: ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !* ++ ./calc.at:1343: $PREPARSER ./calc input 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 stderr: ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: memory exhausted ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1//2 ./calc.at:1344: $PREPARSER ./calc /dev/null ./calc.at:1348: $PREPARSER ./calc input stderr: stderr: syntax error, unexpected end of input memory exhausted stderr: ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' stderr: ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.7: syntax error 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 stderr: stderr: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1342: cat stderr syntax error, unexpected end of input ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1346: cat stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1343: cat stderr | (1 + 1) / (1 - 1) | (!!) + (1 2) = 1 ./calc.at:1347: cat stderr ./calc.at:1342: $PREPARSER ./calc input ./calc.at:1346: $PREPARSER ./calc input ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 484. calc.at:1353: testing Calculator %debug ... stderr: ./calc.at:1353: mv calc.y.tmp calc.y 1.11: syntax error 1.1-16: error: 2222 != 1 stderr: ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: null divisor stderr: ./calc.at:1353: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11: syntax error 1.1-16: error: 2222 != 1 input: | | +1 ./calc.at:1344: cat stderr ./calc.at:1347: $PREPARSER ./calc input stderr: 2.1: syntax error ./calc.at:1348: cat stderr ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: error: null divisor | (#) + (#) = 2222 input: ./calc.at:1343: $PREPARSER ./calc input input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: $PREPARSER ./calc input | error ./calc.at:1348: $PREPARSER ./calc input stderr: stderr: 1.1: syntax error, unexpected invalid token stderr: ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1346: cat stderr syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 2.1: syntax error syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 input: syntax error: invalid character: '#' syntax error: invalid character: '#' | (- *) + (1 2) = 1 ./calc.at:1346: $PREPARSER ./calc input stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1353: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1347: cat stderr ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1342: cat stderr ./calc.at:1347: $PREPARSER ./calc /dev/null 1.1: syntax error, unexpected invalid token stderr: 1.1: syntax error ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 476. calc.at:1342: ok stderr: 1.1: syntax error stderr: stdout: ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1344: cat stderr ./calc.at:1350: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1350: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1347: cat stderr | (!!) + (1 2) = 1 ./calc.at:1344: $PREPARSER ./calc input stderr: ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected number error: 2222 != 1 input: ./calc.at:1343: cat stderr ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1350: $PREPARSER ./calc input stderr: ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1347: $PREPARSER ./calc input stderr: ./calc.at:1348: cat stderr syntax error, unexpected number error: 2222 != 1 ./calc.at:1350: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 | (1 + #) = 1111 ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1343: $PREPARSER ./calc input stderr: stderr: syntax error: invalid character: '#' ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1346: cat stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 2 ./calc.at:1344: cat stderr ./calc.at:1350: $PREPARSER ./calc input stderr: stderr: 485. calc.at:1354: testing Calculator parse.error=detailed %debug %locations %header %name-prefix "calc" %verbose %yacc ... 1.3: syntax error, unexpected number ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 = 2 = 3 input: ./calc.at:1348: $PREPARSER ./calc input | (* *) + (*) + (*) input: stderr: | (- *) + (1 2) = 1 ./calc.at:1344: $PREPARSER ./calc input 1.3: syntax error, unexpected number ./calc.at:1346: $PREPARSER ./calc input stderr: ./calc.at:1354: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi 1.7: syntax error, unexpected '=' ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y 1.7: syntax error, unexpected '=' stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1350: cat stderr stderr: stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 input: stderr: ./calc.at:1347: cat stderr | 1//2 stdout: ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1350: $PREPARSER ./calc input ./types.at:139: $PREPARSER ./test stderr: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1348: cat stderr ./calc.at:1343: cat stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ======== Testing with C++ standard flags: '' input: ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1346: cat stderr | (!!) + (1 2) = 1 ./calc.at:1347: $PREPARSER ./calc input input: ./calc.at:1350: cat stderr | | +1 ./calc.at:1348: $PREPARSER ./calc input stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: 2.1: syntax error, unexpected '+' ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: cat stderr ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: input: stdout: | (* *) + (*) + (*) ./calc.at:1344: $PREPARSER ./calc input ./calc.at:1351: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' | error input: ./calc.at:1350: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1346: $PREPARSER ./calc input stderr: ./calc.at:1354: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 2.1: syntax error, unexpected '+' stderr: 1.1: syntax error, unexpected invalid token ./calc.at:1346: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: stderr: | (# + 1) = 1111 ./calc.at:1343: $PREPARSER ./calc input ./calc.at:1351: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h stderr: stderr: ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 input: ./calc.at:1351: $PREPARSER ./calc input ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1346: $PREPARSER ./calc input stderr: ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' stderr: stderr: ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1348: cat stderr 1.1: syntax error, unexpected invalid token ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: $PREPARSER ./calc /dev/null stderr: ./calc.at:1343: cat stderr stderr: 1.1: syntax error, unexpected end of file ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 2 ./calc.at:1351: $PREPARSER ./calc input ./calc.at:1350: cat stderr ./calc.at:1347: cat stderr stderr: ./calc.at:1346: cat stderr input: | (1 + # + 1) = 1111 ./calc.at:1343: $PREPARSER ./calc input ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1344: cat stderr input: input: 1.3: syntax error, unexpected number ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 | 1 + 2 * 3 + !* ++ ./calc.at:1346: $PREPARSER ./calc input input: ./calc.at:1350: $PREPARSER ./calc input 1.1: syntax error, unexpected end of file | (- *) + (1 2) = 1 input: ./calc.at:1347: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1344: $PREPARSER ./calc input stderr: stderr: 1.7: syntax error, unexpected '=' syntax error: invalid character: '#' stderr: stderr: 1.14: memory exhausted ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: ./types.at:139: ./check 1.3: syntax error, unexpected number stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 1.7: syntax error, unexpected '=' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./calc.at:1344: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.14: memory exhausted ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: cat stderr ./calc.at:1348: cat stderr ./calc.at:1351: cat stderr input: ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !- ++ ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1344: $PREPARSER ./calc input input: input: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1348: $PREPARSER ./calc input input: ./calc.at:1350: cat stderr | (1 + 1) / (1 - 1) | 1//2 stderr: ./calc.at:1343: $PREPARSER ./calc input stderr: ./calc.at:1351: $PREPARSER ./calc input 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1346: cat stderr stderr: stderr: ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: null divisor ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: cat stderr stderr: stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1348: cat stderr input: ./calc.at:1351: cat stderr input: | (#) + (#) = 2222 ./calc.at:1346: $PREPARSER ./calc input ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | (* *) + (*) + (*) error: null divisor ./calc.at:1347: $PREPARSER ./calc input stderr: stderr: | error | | +1 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1351: $PREPARSER ./calc input ./calc.at:1350: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (!!) + (1 2) = 1 ./calc.at:1348: $PREPARSER ./calc input stderr: stderr: stderr: 1.1: syntax error, unexpected invalid token 2.1: syntax error, unexpected '+' stderr: ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1344: cat stderr 1.1: syntax error, unexpected invalid token stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 stderr: stderr: 2.1: syntax error, unexpected '+' input: ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' | 1 + 2 * 3 + !* ++ ./calc.at:1344: $PREPARSER ./calc input ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: memory exhausted ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: cat stderr ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: cat stderr stderr: memory exhausted input: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 ./calc.at:1351: $PREPARSER ./calc input ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.7: syntax error, unexpected '=' ./calc.at:1350: cat stderr ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1343: cat stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1350: $PREPARSER ./calc /dev/null 1.7: syntax error, unexpected '=' ./calc.at:1347: cat stderr ./calc.at:1346: cat stderr stderr: ./calc.at:1344: cat stderr | (- *) + (1 2) = 1 1.1: syntax error, unexpected end of file ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1348: $PREPARSER ./calc input input: stderr: 1.1: syntax error, unexpected end of file | 1 + 2 * 3 + !+ ++ ./calc.at:1347: $PREPARSER ./calc input stderr: stderr: stderr: input: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 | (#) + (#) = 2222 ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1344: $PREPARSER ./calc input ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 ./calc.at:1346: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1353: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1347: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' 477. calc.at:1343: ok ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: cat stderr ./calc.at:1351: cat stderr stderr: ./calc.at:1353: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: input: input: input: 1.6: syntax error: invalid character: '#' | | +1 | 1 + 2 * 3 + !- ++ ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: $PREPARSER ./calc input ./calc.at:1351: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: stderr: ./calc.at:1350: $PREPARSER ./calc input stderr: input: ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: cat stderr 2.1: syntax error, unexpected '+' 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 input: stderr: stderr: ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 2.1: syntax error, unexpected '+' 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 | (* *) + (*) + (*) ./calc.at:1353: $PREPARSER ./calc input ./calc.at:1348: $PREPARSER ./calc input ./calc.at:1346: cat stderr stderr: ./calc.at:1344: cat stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' input: ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 ./calc.at:1346: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 7) Shifting token "number" (1.1: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 7) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 7) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: -3) -> $$ = nterm exp (1.1: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: -6) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 5) Shifting token "number" (1.1: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 5) -> $$ = nterm exp (1.1: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 5) -> $$ = nterm exp (1.1: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -5) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -5) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -5) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: -1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: -1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 4) Shifting token "number" (1.1: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 4) -> $$ = nterm exp (1.1: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 4) -> $$ = nterm exp (1.1: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -4) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -4) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -4) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 2) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 8) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 256) Shifting token "number" (1.1: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 256) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 256) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 4) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 4) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 64) Shifting token "number" (1.1: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 64) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 64) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: cat stderr ./calc.at:1351: cat stderr stderr: stderr: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 7) Shifting token "number" (1.1: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 7) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 7) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: -3) -> $$ = nterm exp (1.1: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: -6) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 5) Shifting token "number" (1.1: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 5) -> $$ = nterm exp (1.1: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 5) -> $$ = nterm exp (1.1: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -5) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -5) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -5) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: -1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: -1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 4) Shifting token "number" (1.1: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 4) -> $$ = nterm exp (1.1: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 4) -> $$ = nterm exp (1.1: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -4) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -4) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -4) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 2) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 8) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 256) Shifting token "number" (1.1: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 256) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 256) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 4) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 4) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 64) Shifting token "number" (1.1: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 64) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 64) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: ./calc.at:1353: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 1.2: syntax error: invalid character: '#' ./calc.at:1350: $PREPARSER ./calc input ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' stderr: input: input: | (1 + #) = 1111 | 1 2 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: cat stderr ./calc.at:1353: $PREPARSER ./calc input 486. calc.at:1355: testing Calculator parse.error=detailed %debug %locations %header api.prefix={calc} %verbose %yacc ... ./calc.at:1344: $PREPARSER ./calc input ./calc.at:1351: $PREPARSER ./calc /dev/null ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1355: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.1: 2) Stack now 0 ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 stderr: syntax error: invalid character: '#' ./calc.at:1355: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.1: 2) Stack now 0 syntax error: invalid character: '#' ./calc.at:1346: cat stderr ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: cat stderr input: input: 1.1: syntax error, unexpected end of file | 1 + 2 * 3 + !* ++ ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: $PREPARSER ./calc input stderr: ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.1: syntax error, unexpected end of file 1.14: memory exhausted | 1 + 2 * 3 + !+ ++ ./calc.at:1350: cat stderr input: ./calc.at:1348: $PREPARSER ./calc input ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + # + 1) = 1111 ./calc.at:1346: $PREPARSER ./calc input stderr: stderr: ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1348: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.6: syntax error: invalid character: '#' ./calc.at:1351: cat stderr ./calc.at:1353: cat stderr ./calc.at:1344: cat stderr stderr: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !- ++ ./calc.at:1348: $PREPARSER ./calc input stderr: ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (# + 1) = 1111 ./calc.at:1344: $PREPARSER ./calc input input: 1.14: memory exhausted input: | (- *) + (1 2) = 1 stderr: | 1//2 ./calc.at:1353: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.1: ) syntax error Error: popping token '/' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.1: ) Stack now 0 ./calc.at:1350: $PREPARSER ./calc input ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 syntax error: invalid character: '#' input: stderr: ./calc.at:1355: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.1: ) syntax error Error: popping token '/' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.1: ) Stack now 0 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: $PREPARSER ./calc input stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1346: cat stderr input: stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (1 + 1) / (1 - 1) ./calc.at:1346: $PREPARSER ./calc input 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1347: cat stderr ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: cat stderr ./calc.at:1351: cat stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: 1.11-17: error: null divisor ./calc.at:1344: cat stderr input: | (#) + (#) = 2222 ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 ./calc.at:1350: cat stderr ./calc.at:1351: $PREPARSER ./calc input ./calc.at:1347: $PREPARSER ./calc input ./calc.at:1353: cat stderr stderr: input: 1.11-17: error: null divisor input: stderr: | (1 + # + 1) = 1111 stderr: ./calc.at:1344: $PREPARSER ./calc input 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 | 1 + 2 * 3 + !* ++ ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1348: $PREPARSER ./calc input input: stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' | (* *) + (*) + (*) ./calc.at:1350: $PREPARSER ./calc input ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.14: memory exhausted 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 stderr: ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error ./calc.at:1353: $PREPARSER ./calc input stderr: stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.14: memory exhausted stderr: stderr: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' stderr: syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 ./calc.at:1351: cat stderr ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 | (- *) + (1 2) = 1 ./calc.at:1351: $PREPARSER ./calc input ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1348: cat stderr ./calc.at:1346: cat stderr ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1344: cat stderr ./calc.at:1350: cat stderr 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 479. calc.at:1346: ok input: | (1 + 1) / (1 - 1) ./calc.at:1344: $PREPARSER ./calc input ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 input: input: stderr: | (#) + (#) = 2222 ./calc.at:1348: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1350: $PREPARSER ./calc input error: null divisor ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: null divisor ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1351: cat stderr ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (* *) + (*) + (*) ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: cat stderr ./calc.at:1351: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1353: cat stderr ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: cat stderr stderr: ./calc.at:1350: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: input: ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 478. calc.at:1344: ok ./calc.at:1348: cat stderr | 1 = 2 = 3 input: ./calc.at:1353: $PREPARSER ./calc input 487. calc.at:1357: testing Calculator api.pure=full parse.error=detailed %debug %locations %header %name-prefix "calc" %verbose %yacc ... | (1 + #) = 1111 ./calc.at:1357: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi ./calc.at:1347: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.1: ) syntax error Error: popping nterm exp (1.1: 2) Stack now 0 8 19 Error: popping token '=' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.1: ) Stack now 0 1.6: syntax error: invalid character: '#' ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1351: cat stderr stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.1: ) syntax error Error: popping nterm exp (1.1: 2) Stack now 0 8 19 Error: popping token '=' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.1: ) Stack now 0 | (1 + #) = 1111 ./calc.at:1348: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' | 1 + 2 * 3 + !- ++ ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: $PREPARSER ./calc input ./calc.at:1357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !+ ++ ./calc.at:1351: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1351: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1353: cat stderr stderr: 1.6: syntax error: invalid character: '#' 1.6: syntax error: invalid character: '#' input: | | +1 ./calc.at:1353: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (1.1: ) syntax error Error: popping nterm input (1.1: ) Stack now 0 Cleanup: discarding lookahead token '+' (1.1: ) Stack now 0 ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (1.1: ) syntax error Error: popping nterm input (1.1: ) Stack now 0 Cleanup: discarding lookahead token '+' (1.1: ) Stack now 0 stderr: ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1350: cat stderr | 1 + 2 * 3 + !- ++ ./calc.at:1351: $PREPARSER ./calc input stderr: ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./calc.at:1347: cat stderr ./calc.at:1357: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: ./calc.at:1354: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1354: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h 488. calc.at:1358: testing Calculator api.push-pull=both api.pure=full parse.error=detailed %debug %locations %header api.prefix={calc} %verbose %yacc ... ./calc.at:1358: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: cat stderr input: input: | (# + 1) = 1111 | 1 + 2 * 3 + !* ++ ./calc.at:1347: $PREPARSER ./calc input ./calc.at:1350: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' input: ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1354: $PREPARSER ./calc input ./calc.at:1353: cat stderr input: stderr: ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 stderr: ./calc.at:1353: $PREPARSER ./calc /dev/null 1.2: syntax error: invalid character: '#' ./calc.at:1348: $PREPARSER ./calc input ./calc.at:1358: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: 1.14: memory exhausted Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 ./calc.at:1351: cat stderr ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 136): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 1.2: syntax error: invalid character: '#' | 1 + 2 * 3 + !* ++ ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: $PREPARSER ./calc input stderr: 1.14: memory exhausted stderr: ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 stderr: stderr: 1.14: memory exhausted Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 136): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) input: | (1 + # + 1) = 1111 ./calc.at:1347: $PREPARSER ./calc input ./calc.at:1354: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.14: memory exhausted stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 2 ./calc.at:1350: cat stderr ./calc.at:1354: $PREPARSER ./calc input ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1358: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1351: cat stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 | (#) + (#) = 2222 ./calc.at:1351: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1353: cat stderr ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1348: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1354: cat stderr ./calc.at:1347: cat stderr input: ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (#) + (#) = 2222 ./calc.at:1350: $PREPARSER ./calc input input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1351: cat stderr stderr: ./calc.at:1353: $PREPARSER ./calc input input: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + # + 1) = 1111 ./calc.at:1348: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.1: ) syntax error Error: popping token '+' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 3) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 1) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.1: ) syntax error Error: popping token '*' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 2) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 3333) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 4444) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 4444 != 1 -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 4444) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) 1.6: syntax error: invalid character: '#' input: ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1351: $PREPARSER ./calc input ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | 1//2 ./calc.at:1354: $PREPARSER ./calc input | (1 + 1) / (1 - 1) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.1: ) syntax error Error: popping token '+' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 3) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 1) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.1: ) syntax error Error: popping token '*' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 2) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 3333) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 4444) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 4444 != 1 -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 4444) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: ./calc.at:1347: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 stderr: 1.11-17: error: null divisor ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1351: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (# + 1) = 1111 stderr: stderr: ./calc.at:1351: $PREPARSER ./calc input stderr: ./calc.at:1350: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor 1.6: syntax error: invalid character: '#' 1.2: syntax error: invalid character: '#' ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + #) = 1111 ./calc.at:1350: $PREPARSER ./calc input ./calc.at:1353: cat stderr ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1354: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: 1.6: syntax error: invalid character: '#' ./calc.at:1347: cat stderr ./calc.at:1351: cat stderr ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 480. calc.at:1347: ok | error ./calc.at:1354: $PREPARSER ./calc input | (!!) + (1 2) = 1 stderr: ./calc.at:1353: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 121): $1 = token '!' (1.1: ) $2 = token '!' (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: cat stderr input: ./calc.at:1348: cat stderr | (1 + # + 1) = 1111 stderr: ./calc.at:1351: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 121): $1 = token '!' (1.1: ) $2 = token '!' (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: | (# + 1) = 1111 ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1350: $PREPARSER ./calc input input: | (1 + 1) / (1 - 1) stderr: ./calc.at:1348: $PREPARSER ./calc input ./calc.at:1354: cat stderr stderr: stderr: 1.2: syntax error: invalid character: '#' 1.6: syntax error: invalid character: '#' ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11-17: error: null divisor ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.2: syntax error: invalid character: '#' 1.6: syntax error: invalid character: '#' ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 = 2 = 3 ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1354: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1350: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 489. calc.at:1360: testing Calculator api.pure parse.error=detailed %debug %locations %header api.prefix={calc} %verbose %yacc %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1360: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi stderr: ./calc.at:1351: cat stderr ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 1.11-17: error: null divisor input: | (1 + 1) / (1 - 1) ./calc.at:1351: $PREPARSER ./calc input | (1 + # + 1) = 1111 ./calc.at:1350: $PREPARSER ./calc input stderr: ./calc.at:1353: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1354: cat stderr 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1350: cat stderr ./calc.at:1360: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11-17: error: null divisor ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1348: cat stderr | | +1 ./calc.at:1354: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor 481. calc.at:1348: ok input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 input: ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (- *) + (1 2) = 1 ./calc.at:1353: $PREPARSER ./calc input | (1 + 1) / (1 - 1) ./calc.at:1351: cat stderr ./calc.at:1350: $PREPARSER ./calc input ./calc.at:1360: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 120): $1 = token '-' (1.1: ) $2 = token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1354: cat stderr stderr: ./calc.at:1354: $PREPARSER ./calc /dev/null 483. calc.at:1351: ok stdout: stderr: 1.11-17: error: null divisor ./calc.at:1355: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 stderr: ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 120): $1 = token '-' (1.1: ) $2 = token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1355: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1355: $PREPARSER ./calc input 490. calc.at:1362: testing Calculator %no-lines api.pure parse.error=detailed %debug %locations %header api.prefix={calc} %verbose %yacc %parse-param {semantic_value *result}{int *count}{int *nerrs} ... stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 136): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: cat stderr ./calc.at:1362: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1353: cat stderr 491. calc.at:1363: testing Calculator %no-lines api.pure parse.error=verbose %debug %locations %header api.prefix={calc} %verbose %yacc %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1363: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1354: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 136): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1355: $EGREP -c -v 'Return for a new token:|LAC:' stderr 482. calc.at:1350: ok ./calc.at:1362: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y input: ./calc.at:1363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | (* *) + (*) + (*) ./calc.at:1353: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1354: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 3333) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1355: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 3333) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1354: cat stderr stderr: ./calc.at:1363: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS input: stdout: | (!!) + (1 2) = 1 ./calc.at:1354: $PREPARSER ./calc input ./types.at:139: $PREPARSER ./test stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 141): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 141): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1353: cat stderr ./calc.at:1362: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS 492. calc.at:1364: testing Calculator %no-lines api.pure parse.error=verbose %debug %locations %defines api.prefix={calc} %verbose %yacc %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1364: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi ./calc.at:1364: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 450. types.at:139: ok ./calc.at:1354: cat stderr input: input: | (- *) + (1 2) = 1 ./calc.at:1354: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 140): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1353: $PREPARSER ./calc input ./calc.at:1355: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 140): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 122): $1 = token '!' (1.1: ) $2 = token '+' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1364: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1355: $PREPARSER ./calc input ./calc.at:1354: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (* *) + (*) + (*) ./calc.at:1354: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 122): $1 = token '!' (1.1: ) $2 = token '+' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) stderr: stdout: ./calc.at:1353: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1357: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1354: cat stderr ./calc.at:1355: cat stderr input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1357: $PREPARSER ./calc input input: input: | 1 + 2 * 3 + !- ++ | 1 + 2 * 3 + !+ ++ input: ./calc.at:1353: $PREPARSER ./calc input ./calc.at:1354: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 123): $1 = token '!' (1.1: ) $2 = token '-' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 493. calc.at:1367: testing Calculator parse.error=custom ... stderr: stderr: stderr: ./calc.at:1367: mv calc.y.tmp calc.y Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 123): $1 = token '!' (1.1: ) $2 = token '-' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1367: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1355: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 142): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 | 1 2 ./calc.at:1357: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 142): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1354: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1353: cat stderr ./calc.at:1355: cat stderr input: | 1 + 2 * 3 + !* ++ ./calc.at:1353: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 124): $1 = token '!' (1.1: ) $2 = token '*' (1.1: ) memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 124): $1 = token '!' (1.1: ) $2 = token '*' (1.1: ) memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) input: ./calc.at:1357: cat stderr | 1 + 2 * 3 + !- ++ input: ./calc.at:1354: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1355: $PREPARSER ./calc input stderr: ./calc.at:1367: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 143): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 | 1//2 ./calc.at:1357: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 143): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1354: cat stderr ./calc.at:1355: cat stderr ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !* ++ ./calc.at:1354: $PREPARSER ./calc input ./calc.at:1357: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 144): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1355: $PREPARSER ./calc input input: ./calc.at:1353: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 144): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | error ./calc.at:1357: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (#) + (#) = 2222 ./calc.at:1353: $PREPARSER ./calc input stderr: stderr: ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2222) Shifting token "number" (1.1: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1354: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2222) Shifting token "number" (1.1: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 input: | (#) + (#) = 2222 ./calc.at:1354: $PREPARSER ./calc input ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: cat stderr ./calc.at:1355: cat stderr ./calc.at:1353: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1355: $PREPARSER ./calc /dev/null stderr: input: | (1 + #) = 1111 ./calc.at:1353: $PREPARSER ./calc input ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: ./calc.at:1367: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' input: | 1 = 2 = 3 ./calc.at:1357: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1354: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1367: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1367: $PREPARSER ./calc input ./calc.at:1355: cat stderr stdout: stderr: input: ./calc.at:1357: cat stderr ./calc.at:1360: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1353: cat stderr | (1 + #) = 1111 ./calc.at:1354: $PREPARSER ./calc input ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: input: stderr: input: ./calc.at:1360: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h | (# + 1) = 1111 ./calc.at:1367: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1353: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | | +1 ./calc.at:1357: $PREPARSER ./calc input ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1355: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1360: $PREPARSER ./calc input ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | 1 2 stdout: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1367: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1360: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: stderr: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1358: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1357: cat stderr ./calc.at:1354: cat stderr ./calc.at:1358: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h stderr: input: input: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) | 1 2 | (# + 1) = 1111 ./calc.at:1354: $PREPARSER ./calc input ./calc.at:1353: cat stderr ./calc.at:1360: $PREPARSER ./calc input input: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: ./calc.at:1358: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1355: cat stderr ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: $PREPARSER ./calc /dev/null stderr: ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Return for a new token: Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Return for a new token: Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Return for a new token: Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Return for a new token: Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Return for a new token: Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Return for a new token: Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Return for a new token: Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Return for a new token: Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Return for a new token: Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Return for a new token: Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Return for a new token: Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Return for a new token: Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Return for a new token: Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Return for a new token: Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Return for a new token: Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Return for a new token: Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Return for a new token: Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Return for a new token: Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Return for a new token: Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Return for a new token: Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Return for a new token: Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Return for a new token: Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Return for a new token: Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Return for a new token: Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Return for a new token: Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Return for a new token: Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Return for a new token: Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Return for a new token: Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Return for a new token: Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Return for a new token: Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Return for a new token: Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Return for a new token: Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Return for a new token: Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Return for a new token: Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Return for a new token: Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Return for a new token: Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Return for a new token: Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Return for a new token: Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 stderr: ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (!!) + (1 2) = 1 ./calc.at:1355: $PREPARSER ./calc input input: | (1 + # + 1) = 1111 ./calc.at:1353: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 141): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stderr: stderr: ./calc.at:1363: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Return for a new token: Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Return for a new token: Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Return for a new token: Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Return for a new token: Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Return for a new token: Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Return for a new token: Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Return for a new token: Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Return for a new token: Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Return for a new token: Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Return for a new token: Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Return for a new token: Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Return for a new token: Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Return for a new token: Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Return for a new token: Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Return for a new token: Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Return for a new token: Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Return for a new token: Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Return for a new token: Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Return for a new token: Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Return for a new token: Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Return for a new token: Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Return for a new token: Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Return for a new token: Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Return for a new token: Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Return for a new token: Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Return for a new token: Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Return for a new token: Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Return for a new token: Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Return for a new token: Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Return for a new token: Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Return for a new token: Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Return for a new token: Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Return for a new token: Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Return for a new token: Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Return for a new token: Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Return for a new token: Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Return for a new token: Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Return for a new token: Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1358: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1363: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 141): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1367: cat stderr ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1367: $PREPARSER ./calc input ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1355: cat stderr syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) input: ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1358: $PREPARSER ./calc input ./calc.at:1354: cat stderr stderr: ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: stdout: | (- *) + (1 2) = 1 stderr: ./calc.at:1355: $PREPARSER ./calc input input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1363: $PREPARSER ./calc input syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) input: stderr: stderr: | (1 + # + 1) = 1111 ./calc.at:1354: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 140): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1360: cat stderr ./calc.at:1362: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1353: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 140): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (1 + 1) / (1 - 1) ./calc.at:1367: cat stderr ./calc.at:1353: $PREPARSER ./calc input stderr: stderr: ./calc.at:1362: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1357: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 2) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 0) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 10 (line 101): $1 = nterm exp (1.1: 2) $2 = token '/' (1.1: ) $3 = nterm exp (1.1: 0) error: null divisor -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: stdout: ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1363: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1362: $PREPARSER ./calc input | error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 2) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 0) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 10 (line 101): $1 = nterm exp (1.1: 2) $2 = token '/' (1.1: ) $3 = nterm exp (1.1: 0) error: null divisor -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1367: $PREPARSER ./calc input input: input: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1357: $PREPARSER ./calc input ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./types.at:139: $PREPARSER ./test | 1 2 ./calc.at:1363: $PREPARSER ./calc input ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 stderr: ./calc.at:1360: $PREPARSER ./calc input stderr: ./calc.at:1354: cat stderr syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1358: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1355: cat stderr ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: ./calc.at:1362: $EGREP -c -v 'Return for a new token:|LAC:' stderr stdout: ./calc.at:1367: cat stderr stderr: ./calc.at:1364: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1353: cat stderr ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 input: ./calc.at:1362: $PREPARSER ./calc input stderr: input: stderr: | 1//2 stderr: ======== Testing with C++ standard flags: '' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: $PREPARSER ./calc input ./calc.at:1364: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 | 1 = 2 = 3 ./calc.at:1367: $PREPARSER ./calc input 484. calc.at:1353: ok ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: stderr: | (1 + 1) / (1 - 1) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Return for a new token: Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 stderr: ./calc.at:1354: $PREPARSER ./calc input ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) input: ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1355: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1364: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 121): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: cat stderr stderr: ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Return for a new token: Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 121): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1363: $PREPARSER ./calc input stderr: ./calc.at:1358: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1357: cat stderr ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1360: cat stderr ./calc.at:1354: cat stderr stderr: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) input: | error ./calc.at:1358: $PREPARSER ./calc input ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1355: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1364: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 | 1 + 2 * 3 + !+ ++ ./calc.at:1355: $PREPARSER ./calc input ./calc.at:1367: cat stderr input: | (!!) + (1 2) = 1 stderr: ./calc.at:1357: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 142): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 input: input: 485. calc.at:1354: ok Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1367: $PREPARSER ./calc input | error ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 494. calc.at:1368: testing Calculator parse.error=custom %locations api.prefix={calc} ... Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 142): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: input: ./calc.at:1355: $EGREP -c -v 'Return for a new token:|LAC:' stderr syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1368: mv calc.y.tmp calc.y ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1360: $PREPARSER ./calc input | 1 2 ./calc.at:1364: $PREPARSER ./calc input ./calc.at:1363: cat stderr ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1368: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: stderr: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 input: ./calc.at:1362: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 | 1 + 2 * 3 + !- ++ ./calc.at:1355: $PREPARSER ./calc input input: | error ./calc.at:1363: $PREPARSER ./calc input ./calc.at:1358: cat stderr stderr: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 143): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1//2 ./calc.at:1362: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 stderr: stderr: ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1367: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 stderr: | 1 = 2 = 3 ./calc.at:1357: cat stderr stderr: ./calc.at:1358: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 143): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 stdout: ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./types.at:139: ./check ./calc.at:1367: $PREPARSER ./calc /dev/null ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./calc.at:1360: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (- *) + (1 2) = 1 ./calc.at:1357: $PREPARSER ./calc input stderr: input: stderr: | 1 = 2 = 3 ./calc.at:1364: cat stderr 495. calc.at:1369: testing Calculator parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1369: mv calc.y.tmp calc.y ./calc.at:1360: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1355: cat stderr ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1368: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS input: ./calc.at:1369: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: | 1 + 2 * 3 + !* ++ Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1355: $PREPARSER ./calc input ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1363: cat stderr ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1362: cat stderr | 1//2 ./calc.at:1364: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 stderr: input: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 = 2 = 3 ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1363: $PREPARSER ./calc input ./calc.at:1367: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 144): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1358: cat stderr input: ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1360: cat stderr stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 144): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1367: $PREPARSER ./calc input stderr: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) error: 4444 != 1 ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) error: 4444 != 1 | error ./calc.at:1362: $PREPARSER ./calc input ./calc.at:1355: cat stderr input: ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1358: $PREPARSER ./calc input stderr: ./calc.at:1357: cat stderr ./calc.at:1369: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 input: ./calc.at:1363: cat stderr | | +1 input: ./calc.at:1360: $PREPARSER ./calc input | (* *) + (*) + (*) ./calc.at:1367: cat stderr ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1357: $PREPARSER ./calc input | | +1 ./calc.at:1363: $PREPARSER ./calc input ./calc.at:1358: cat stderr ./calc.at:1364: cat stderr stderr: stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1358: $PREPARSER ./calc /dev/null ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1355: $PREPARSER ./calc input input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 stderr: | error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1364: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 stderr: ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 ./calc.at:1367: $PREPARSER ./calc input ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 stderr: ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1360: cat stderr stderr: ./calc.at:1360: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 stderr: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1363: cat stderr ./calc.at:1357: cat stderr ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1363: $PREPARSER ./calc /dev/null ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1367: cat stderr stderr: ./calc.at:1358: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1362: cat stderr ./calc.at:1364: cat stderr input: ./calc.at:1355: cat stderr | 1 + 2 * 3 + !+ ++ Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 input: ./calc.at:1357: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1367: $PREPARSER ./calc input ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: stderr: stderr: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1358: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1360: cat stderr ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 = 2 = 3 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Return for a new token: Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Return for a new token: Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Return for a new token: Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Return for a new token: Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Return for a new token: Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Return for a new token: Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Return for a new token: Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Return for a new token: Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 = 2 = 3 ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1364: $PREPARSER ./calc input ./calc.at:1355: $PREPARSER ./calc input ./calc.at:1362: $PREPARSER ./calc input syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 stderr: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 ./calc.at:1360: $PREPARSER ./calc input ./calc.at:1357: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Return for a new token: Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Return for a new token: Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Return for a new token: Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Return for a new token: Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Return for a new token: Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Return for a new token: Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Return for a new token: Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Return for a new token: Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1363: cat stderr ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1367: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 + !- ++ ./calc.at:1357: $PREPARSER ./calc input ./calc.at:1364: cat stderr ./calc.at:1360: cat stderr input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1363: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: stderr: ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (* *) + (*) + (*) ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1367: $PREPARSER ./calc input input: stderr: ./calc.at:1358: cat stderr ./calc.at:1360: $PREPARSER ./calc input | | +1 stderr: ./calc.at:1364: $PREPARSER ./calc input syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1355: cat stderr stderr: ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (!!) + (1 2) = 1 ./calc.at:1358: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Return for a new token: Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1367: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Return for a new token: Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1363: cat stderr | (# + 1) = 1111 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1355: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: ./calc.at:1357: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (!!) + (1 2) = 1 ./calc.at:1363: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1367: $PREPARSER ./calc input ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1362: cat stderr ./calc.at:1358: cat stderr ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (- *) + (1 2) = 1 ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1358: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1364: cat stderr ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1360: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Return for a new token: Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 + !* ++ ./calc.at:1357: $PREPARSER ./calc input ./calc.at:1363: cat stderr ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1367: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1355: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | | +1 ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: $PREPARSER ./calc /dev/null ./calc.at:1362: $PREPARSER ./calc input input: stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 | 1 + 2 * 3 + !- ++ ./calc.at:1367: $PREPARSER ./calc input | (1 + # + 1) = 1111 ./calc.at:1355: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Return for a new token: Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 | (- *) + (1 2) = 1 ./calc.at:1363: $PREPARSER ./calc input ./calc.at:1360: $PREPARSER ./calc input ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1355: cat stderr ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + 1) / (1 - 1) ./calc.at:1358: cat stderr stderr: ./calc.at:1355: $PREPARSER ./calc input ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1367: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 121): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1357: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 121): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1362: cat stderr input: | (* *) + (*) + (*) ./calc.at:1358: $PREPARSER ./calc input input: ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (#) + (#) = 2222 stderr: ./calc.at:1357: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1362: $PREPARSER ./calc /dev/null ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: | 1 + 2 * 3 + !* ++ stderr: ./calc.at:1367: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1363: cat stderr ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1360: cat stderr stderr: memory exhausted ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stdout: stderr: ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr memory exhausted input: ./calc.at:1368: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: | (* *) + (*) + (*) input: ./calc.at:1364: cat stderr ./calc.at:1363: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 | (* *) + (*) + (*) ./calc.at:1360: $PREPARSER ./calc input ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1368: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1358: cat stderr input: ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1367: cat stderr stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1368: $PREPARSER ./calc input stderr: ./calc.at:1364: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1357: cat stderr ./calc.at:1355: cat stderr stderr: ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: stderr: | (1 + #) = 1111 stderr: ./calc.at:1357: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 486. calc.at:1355: ok stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stdout: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1368: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1358: $PREPARSER ./calc input stderr: ./calc.at:1362: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: | (#) + (#) = 2222 ./calc.at:1369: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1367: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Return for a new token: Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1362: $PREPARSER ./calc input ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 2 ./calc.at:1368: $PREPARSER ./calc input ./calc.at:1360: cat stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Return for a new token: Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1358: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1364: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1357: cat stderr ./calc.at:1369: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c stderr: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) | 1 + 2 * 3 + !+ ++ ./calc.at:1360: $PREPARSER ./calc input input: | (# + 1) = 1111 stderr: ./calc.at:1357: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 | (!!) + (1 2) = 1 ./calc.at:1369: $PREPARSER ./calc input ./calc.at:1364: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1363: cat stderr ./calc.at:1368: cat stderr ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1367: cat stderr input: stderr: stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1358: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1369: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: ./calc.at:1362: cat stderr | 1 + 2 * 3 + !+ ++ stderr: ./calc.at:1363: $PREPARSER ./calc input ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (!!) + (1 2) = 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1360: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1362: $PREPARSER ./calc input input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Return for a new token: Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1357: cat stderr | 1//2 input: ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1368: $PREPARSER ./calc input | 1 2 ./calc.at:1369: $PREPARSER ./calc input stderr: | (1 + #) = 1111 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1367: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Return for a new token: Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: stderr: 496. calc.at:1370: testing Calculator parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} api.push-pull=both api.pure=full ... 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: ./calc.at:1370: mv calc.y.tmp calc.y ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + # + 1) = 1111 syntax error: invalid character: '#' stderr: ./calc.at:1370: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1357: $PREPARSER ./calc input ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: cat stderr 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1363: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 + !- ++ ./calc.at:1360: $PREPARSER ./calc input ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1369: cat stderr input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' input: | 1 + 2 * 3 + !- ++ | (- *) + (1 2) = 1 ./calc.at:1363: $PREPARSER ./calc input ./calc.at:1358: cat stderr ./calc.at:1364: $PREPARSER ./calc input ./calc.at:1357: cat stderr stderr: input: | 1//2 ./calc.at:1367: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1369: $PREPARSER ./calc input stderr: stderr: ./calc.at:1368: cat stderr stderr: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: input: | (1 + 1) / (1 - 1) ./calc.at:1357: $PREPARSER ./calc input ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 stderr: ./calc.at:1367: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 + 2 * 3 + !* ++ ./calc.at:1358: $PREPARSER ./calc input 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1370: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error: invalid character: '#' stderr: ./calc.at:1362: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Return for a new token: Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | error ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1368: $PREPARSER ./calc input ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1369: cat stderr ./calc.at:1364: cat stderr 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1367: cat stderr stderr: ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: input: ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Return for a new token: Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: | error | (* *) + (*) + (*) ./calc.at:1369: $PREPARSER ./calc input ./calc.at:1364: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1357: cat stderr input: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1362: $PREPARSER ./calc input stderr: | (1 + # + 1) = 1111 ./calc.at:1367: $PREPARSER ./calc input stderr: ./calc.at:1360: cat stderr 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: syntax error: invalid character: '#' ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: stderr: ./calc.at:1358: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) syntax error: invalid character: '#' ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: input: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (#) + (#) = 2222 | 1 + 2 * 3 + !* ++ ./calc.at:1358: $PREPARSER ./calc input 487. calc.at:1357: ok ./calc.at:1369: cat stderr ./calc.at:1360: $PREPARSER ./calc input stderr: ./calc.at:1368: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: 1.2: syntax error: invalid character: '#' Reading a token Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: 1.8: syntax error: invalid character: '#' Reading a token Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: 1.2: syntax error: invalid character: '#' Reading a token Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: 1.8: syntax error: invalid character: '#' Reading a token Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: input: | 1 = 2 = 3 ./calc.at:1364: cat stderr ./calc.at:1369: $PREPARSER ./calc input ./calc.at:1363: cat stderr | 1 = 2 = 3 ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1368: $PREPARSER ./calc input ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) stderr: ./calc.at:1362: cat stderr ./calc.at:1367: cat stderr stderr: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | 1 + 2 * 3 + !* ++ ./calc.at:1363: $PREPARSER ./calc input stderr: | (* *) + (*) + (*) stderr: ./calc.at:1362: $PREPARSER ./calc input stderr: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1358: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) input: input: stderr: | (1 + #) = 1111 ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !+ ++ ./calc.at:1364: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1369: cat stderr input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1360: cat stderr ./calc.at:1358: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 497. calc.at:1371: testing Calculator parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} api.push-pull=both api.pure=full parse.lac=full ... | (1 + 1) / (1 - 1) ./calc.at:1367: $PREPARSER ./calc input ./calc.at:1371: mv calc.y.tmp calc.y stderr: error: null divisor ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1368: cat stderr ./calc.at:1371: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y input: | (#) + (#) = 2222 ./calc.at:1360: $PREPARSER ./calc input ./calc.at:1362: cat stderr ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | | +1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Return for a new token: 1.6: syntax error: invalid character: '#' Reading a token Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1369: $PREPARSER ./calc input stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: null divisor ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: cat stderr input: input: | 1 + 2 * 3 + !+ ++ stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | | +1 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Return for a new token: 1.6: syntax error: invalid character: '#' Reading a token Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1362: $PREPARSER ./calc input stderr: ./calc.at:1364: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1368: $PREPARSER ./calc input 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1369: cat stderr 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1360: cat stderr input: ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1369: $PREPARSER ./calc /dev/null ./calc.at:1367: cat stderr stderr: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1371: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1363: $PREPARSER ./calc input input: stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) | (1 + #) = 1111 ./calc.at:1360: $PREPARSER ./calc input stderr: ./calc.at:1358: cat stderr input: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 493. calc.at:1367: ok Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.8: ) Error: discarding token "invalid token" (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 + !- ++ ./calc.at:1364: $PREPARSER ./calc input ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1362: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.8: ) Error: discarding token "invalid token" (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1369: cat stderr input: ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1360: cat stderr ./calc.at:1358: $PREPARSER ./calc input input: | 1 + 2 * 3 + !- ++ ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1362: $PREPARSER ./calc input input: stderr: | (# + 1) = 1111 ./calc.at:1368: cat stderr ./calc.at:1364: cat stderr ./calc.at:1360: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: 1.2: syntax error: invalid character: '#' Reading a token Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1369: $PREPARSER ./calc input input: ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !* ++ stderr: ./calc.at:1364: $PREPARSER ./calc input ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 stderr: ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1368: $PREPARSER ./calc /dev/null stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1363: cat stderr 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: 1.2: syntax error: invalid character: '#' Reading a token Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1360: cat stderr ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1364: cat stderr input: | (#) + (#) = 2222 ./calc.at:1364: $PREPARSER ./calc input ./calc.at:1369: cat stderr ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 ./calc.at:1363: $PREPARSER ./calc input stderr: stderr: ./calc.at:1362: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1368: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.8: ) Error: discarding token "invalid token" (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 498. calc.at:1374: testing Calculator %start input exp NUM api.value.type=union ... ./calc.at:1358: cat stderr stderr: stderr: ./calc.at:1374: mv calc.y.tmp calc.y input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (1 + # + 1) = 1111 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.8: ) Error: discarding token "invalid token" (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1374: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1360: $PREPARSER ./calc input input: | (!!) + (1 2) = 1 ./calc.at:1369: $PREPARSER ./calc input ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: stderr: input: | 1 + 2 * 3 + !* ++ ./calc.at:1364: cat stderr ./calc.at:1362: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 | (1 + # + 1) = 1111 stderr: ./calc.at:1363: cat stderr 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 ./calc.at:1368: $PREPARSER ./calc input stderr: ./calc.at:1358: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Return for a new token: 1.6: syntax error: invalid character: '#' Reading a token Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: stderr: ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 ./calc.at:1363: $PREPARSER ./calc input 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Return for a new token: 1.6: syntax error: invalid character: '#' Reading a token Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1368: cat stderr | (1 + #) = 1111 ./calc.at:1374: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1369: cat stderr ./calc.at:1364: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (!!) + (1 2) = 1 ./calc.at:1368: $PREPARSER ./calc input | (- *) + (1 2) = 1 stderr: ./calc.at:1369: $PREPARSER ./calc input 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 ./calc.at:1358: cat stderr ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1360: cat stderr stderr: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1362: cat stderr stderr: stderr: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 input: input: stderr: input: | (1 + 1) / (1 - 1) | (1 + 1) / (1 - 1) 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 ./calc.at:1360: $PREPARSER ./calc input ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1358: $PREPARSER ./calc input stderr: ./calc.at:1368: cat stderr ./calc.at:1369: cat stderr ./calc.at:1363: cat stderr ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Return for a new token: Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Return for a new token: Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Return for a new token: Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Return for a new token: Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Return for a new token: Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Return for a new token: Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Return for a new token: Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: cat stderr ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1362: $PREPARSER ./calc input input: stderr: | (- *) + (1 2) = 1 stderr: ./calc.at:1368: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 input: ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Return for a new token: Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Return for a new token: Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Return for a new token: Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Return for a new token: Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Return for a new token: Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Return for a new token: Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Return for a new token: Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (1 + # + 1) = 1111 ./calc.at:1363: $PREPARSER ./calc input input: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (* *) + (*) + (*) ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1369: $PREPARSER ./calc input 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1360: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1368: cat stderr | (# + 1) = 1111 ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1364: $PREPARSER ./calc input ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 489. calc.at:1360: ok ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: cat stderr input: stderr: input: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) | (1 + 1) / (1 - 1) ./calc.at:1363: $PREPARSER ./calc input stderr: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: | (* *) + (*) + (*) stdout: ./calc.at:1368: $PREPARSER ./calc input ./calc.at:1370: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 488. calc.at:1358: ok ./calc.at:1362: cat stderr ./calc.at:1370: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c stderr: input: | (1 + #) = 1111 ./calc.at:1362: $PREPARSER ./calc input stderr: ./calc.at:1369: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) stderr: ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1370: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 + !+ ++ ./calc.at:1369: $PREPARSER ./calc input 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1364: cat stderr 499. calc.at:1375: testing Calculator %start input exp NUM api.value.type=union %locations parse.error=detailed ... ./calc.at:1375: mv calc.y.tmp calc.y ./calc.at:1375: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1370: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1368: cat stderr ./calc.at:1363: cat stderr ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 491. calc.at:1363: ok | (1 + # + 1) = 1111 input: input: ./calc.at:1364: $PREPARSER ./calc input | 1 2 ./calc.at:1370: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1369: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 + !+ ++ ./calc.at:1368: $PREPARSER ./calc input stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1375: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS 500. calc.at:1387: testing Calculator %glr-parser ... ./calc.at:1387: mv calc.y.tmp calc.y ./calc.at:1387: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1362: cat stderr ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: | (# + 1) = 1111 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1362: $PREPARSER ./calc input stderr: stderr: input: ./calc.at:1368: $EGREP -c -v 'Return for a new token:|LAC:' stderr | 1 + 2 * 3 + !- ++ 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1369: $PREPARSER ./calc input ./calc.at:1387: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: stderr: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./calc.at:1374: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1364: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1370: cat stderr ./calc.at:1374: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1371: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !- ++ ./calc.at:1368: $PREPARSER ./calc input stderr: ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (1 + 1) / (1 - 1) stderr: 501. calc.at:1389: testing Calculator %glr-parser %header ... ./calc.at:1389: mv calc.y.tmp calc.y ./calc.at:1364: $PREPARSER ./calc input | 1//2 ./calc.at:1370: $PREPARSER ./calc input stderr: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1389: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: ./calc.at:1371: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1374: $PREPARSER ./calc input ./calc.at:1362: cat stderr 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1369: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1368: cat stderr input: | (1 + # + 1) = 1111 ./calc.at:1362: $PREPARSER ./calc input ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1371: $PREPARSER ./calc input ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) input: stderr: | 1 + 2 * 3 + !* ++ ./calc.at:1368: $PREPARSER ./calc input ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !* ++ stderr: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1369: $PREPARSER ./calc input 1.14: memory exhausted stderr: ./calc.at:1389: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1371: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.14: memory exhausted input: | 1 2 ./calc.at:1374: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1371: $PREPARSER ./calc input stderr: stderr: ./calc.at:1364: cat stderr 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1370: cat stderr ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.14: memory exhausted 1.14: memory exhausted input: | 1 2 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./calc.at:1374: $PREPARSER ./calc input 492. calc.at:1364: ok ./calc.at:1369: cat stderr stderr: ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1368: cat stderr input: input: | error syntax error ./calc.at:1370: $PREPARSER ./calc input ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1371: cat stderr | (#) + (#) = 2222 ./calc.at:1369: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1362: cat stderr 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) input: | (#) + (#) = 2222 ./calc.at:1368: $PREPARSER ./calc input input: stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' input: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1370: cat stderr | 1//2 ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1371: $PREPARSER ./calc input | (1 + 1) / (1 - 1) ./calc.at:1362: $PREPARSER ./calc input stderr: 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) input: ./calc.at:1374: cat stderr | 1 = 2 = 3 ./calc.at:1370: $PREPARSER ./calc input 502. calc.at:1390: testing Calculator %glr-parser %locations ... ./calc.at:1390: mv calc.y.tmp calc.y ./calc.at:1390: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1371: cat stderr ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1368: cat stderr ./calc.at:1369: cat stderr stderr: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | error ./calc.at:1371: $PREPARSER ./calc input input: | 1//2 ./calc.at:1374: $PREPARSER ./calc input ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) input: ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 stderr: ./calc.at:1362: cat stderr syntax error input: | (1 + #) = 1111 ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1368: $PREPARSER ./calc input stderr: ./calc.at:1369: $PREPARSER ./calc input stderr: 490. calc.at:1362: ok 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: stderr: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) stderr: 1.6: syntax error: invalid character: '#' syntax error stderr: stdout: 1.6: syntax error: invalid character: '#' ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test ./calc.at:1390: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: stderr: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1371: cat stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1370: cat stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1368: cat stderr ======== Testing with C++ standard flags: '' input: | 1 = 2 = 3 ./calc.at:1371: $PREPARSER ./calc input stderr: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS input: ./calc.at:1369: cat stderr ./calc.at:1371: cat stderr | | +1 ./calc.at:1370: $PREPARSER ./calc input input: | | +1 ./calc.at:1371: $PREPARSER ./calc input stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 stderr: ./calc.at:1368: $PREPARSER ./calc input 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1374: cat stderr stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: stdout: ./calc.at:1371: cat stderr 1.2: syntax error: invalid character: '#' ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1375: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' input: input: ./calc.at:1371: $PREPARSER ./calc /dev/null | (# + 1) = 1111 stderr: stderr: ./calc.at:1369: $PREPARSER ./calc input 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) 1.2: syntax error: invalid character: '#' | error ./calc.at:1374: $PREPARSER ./calc input stderr: ./calc.at:1375: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: syntax error ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 1.2: syntax error: invalid character: '#' 503. calc.at:1391: testing Calculator %glr-parser %locations api.location.type={Span} ... ./calc.at:1391: mv calc.y.tmp calc.y stderr: syntax error stderr: input: ./calc.at:1368: cat stderr ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1391: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1375: $PREPARSER ./calc input stderr: ./calc.at:1371: cat stderr ./calc.at:1370: cat stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' input: ./calc.at:1374: cat stderr ./calc.at:1370: $PREPARSER ./calc /dev/null | (1 + # + 1) = 1111 ./calc.at:1368: $PREPARSER ./calc input input: | 1 = 2 = 3 ./calc.at:1374: $PREPARSER ./calc input stderr: stderr: syntax error ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: syntax error ./calc.at:1375: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: stderr: ./calc.at:1371: $PREPARSER ./calc input ./calc.at:1391: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1369: cat stderr ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: 1.6: syntax error: invalid character: '#' stderr: input: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 | 1 2 ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1370: cat stderr ./calc.at:1368: cat stderr input: stderr: 1.3: syntax error, unexpected number ./calc.at:1374: cat stderr | (1 + # + 1) = 1111 ./calc.at:1369: $PREPARSER ./calc input ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1371: cat stderr input: 1.6: syntax error: invalid character: '#' input: stderr: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 | (1 + 1) / (1 - 1) ./calc.at:1370: $PREPARSER ./calc input ./calc.at:1368: $PREPARSER ./calc input | | +1 ./calc.at:1374: $PREPARSER ./calc input ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error, unexpected number stderr: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.11-17: error: null divisor ./calc.at:1375: cat stderr ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: syntax error ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (!!) + (1 2) = 1 | 1//2 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1371: $PREPARSER ./calc input stderr: syntax error stderr: stderr: stderr: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 1.11-17: error: null divisor 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1369: cat stderr ./calc.at:1368: cat stderr 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + 1) / (1 - 1) ./calc.at:1369: $PREPARSER ./calc input stderr: stderr: 1.11-17: error: null divisor 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1370: cat stderr ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 494. calc.at:1368: ok ./calc.at:1374: cat stderr stdout: ./calc.at:1374: $PREPARSER ./calc /dev/null stderr: ./calc.at:1387: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1371: cat stderr ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: | (!!) + (1 2) = 1 1.11-17: error: null divisor input: ./calc.at:1370: $PREPARSER ./calc input syntax error ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1387: $PREPARSER ./calc input stderr: ./calc.at:1369: cat stderr stderr: input: ./calc.at:1375: cat stderr 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 | (- *) + (1 2) = 1 ./calc.at:1371: $PREPARSER ./calc input stderr: ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error 495. calc.at:1369: ok ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 input: ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: | error ./calc.at:1375: $PREPARSER ./calc input stderr: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 stderr: input: ./calc.at:1370: cat stderr input: | (- *) + (1 2) = 1 ./calc.at:1370: $PREPARSER ./calc input 1.1: syntax error, unexpected invalid token ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: $PREPARSER ./calc input stderr: 1.1: syntax error, unexpected invalid token stderr: stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 504. calc.at:1392: testing Calculator %glr-parser %name-prefix "calc" ... ./calc.at:1392: mv calc.y.tmp calc.y ./calc.at:1392: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y syntax error stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1371: cat stderr syntax error ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1374: cat stderr ./calc.at:1375: cat stderr | (* *) + (*) + (*) ./calc.at:1371: $PREPARSER ./calc input ./calc.at:1370: cat stderr stderr: input: input: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) stderr: 505. calc.at:1393: testing Calculator %glr-parser api.prefix={calc} ... ./calc.at:1393: mv calc.y.tmp calc.y | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1374: $PREPARSER ./calc input stderr: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) | 1 = 2 = 3 stdout: ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1387: cat stderr ./calc.at:1389: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1393: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1371: cat stderr input: ./calc.at:1392: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS input: stderr: | 1//2 ./calc.at:1387: $PREPARSER ./calc input input: stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1371: $PREPARSER ./calc input syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: stderr: syntax error ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.7: syntax error, unexpected '=' | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: $PREPARSER ./calc input syntax error syntax error syntax error syntax error error: 4444 != 1 stderr: | (* *) + (*) + (*) ./calc.at:1370: $PREPARSER ./calc input ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error stderr: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) stderr: 1.7: syntax error, unexpected '=' stderr: ./calc.at:1371: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) | 1 2 input: ./calc.at:1389: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1371: $PREPARSER ./calc input stderr: stderr: syntax error ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1374: cat stderr stderr: ./calc.at:1375: cat stderr ./calc.at:1370: cat stderr stdout: ./calc.at:1390: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: input: | 1 + 2 * 3 + !+ ++ ./calc.at:1370: $PREPARSER ./calc input syntax error input: stderr: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1390: $PREPARSER ./calc input stderr: | (!!) + (1 2) = 1 | | +1 ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: cat stderr stderr: ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1374: $PREPARSER ./calc input stderr: stderr: 2.1: syntax error, unexpected '+' input: ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1390: $PREPARSER ./calc input stderr: stderr: 1.3: syntax error ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error error: 2222 != 1 ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.3: syntax error ./calc.at:1370: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 2.1: syntax error, unexpected '+' stderr: syntax error error: 2222 != 1 ./calc.at:1371: cat stderr input: | error ./calc.at:1387: $PREPARSER ./calc input input: | 1 + 2 * 3 + !* ++ ./calc.at:1371: $PREPARSER ./calc input stderr: ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.14: memory exhausted stderr: syntax error ./calc.at:1389: cat stderr ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !- ++ ./calc.at:1370: $PREPARSER ./calc input ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1375: cat stderr stderr: 1.14: memory exhausted input: syntax error ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: cat stderr stderr: input: ./calc.at:1371: cat stderr | 1//2 ./calc.at:1390: $PREPARSER ./calc input ./calc.at:1374: cat stderr ./calc.at:1375: $PREPARSER ./calc /dev/null | 1//2 stderr: ./calc.at:1389: $PREPARSER ./calc input stderr: input: 1.3: syntax error | (#) + (#) = 2222 ./calc.at:1371: $PREPARSER ./calc input ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error, unexpected end of file stderr: ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error input: ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error, unexpected end of file stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1370: cat stderr | (- *) + (1 2) = 1 ./calc.at:1374: $PREPARSER ./calc input stderr: 1.3: syntax error stderr: ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1387: cat stderr syntax error ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1375: cat stderr ./calc.at:1371: cat stderr syntax error syntax error error: 2222 != 1 ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: input: stdout: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: input: ./calc.at:1375: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1391: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1387: $PREPARSER ./calc input syntax error syntax error error: 2222 != 1 | 1 + 2 * 3 + !* ++ ./calc.at:1370: $PREPARSER ./calc input stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 input: syntax error ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: ./calc.at:1391: $PREPARSER ./calc input stderr: syntax error stderr: | (1 + #) = 1111 1.14: memory exhausted ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1371: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: cat stderr stderr: ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.14: memory exhausted stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1371: cat stderr ./calc.at:1375: cat stderr input: input: input: ./calc.at:1389: cat stderr | (# + 1) = 1111 ./calc.at:1371: $PREPARSER ./calc input | 1 2 ./calc.at:1391: $PREPARSER ./calc input stderr: ./calc.at:1370: cat stderr 1.3: syntax error | error ./calc.at:1390: $PREPARSER ./calc input ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error: invalid character: '#' stderr: input: | (!!) + (1 2) = 1 ./calc.at:1387: cat stderr ./calc.at:1375: $PREPARSER ./calc input 1.3: syntax error 1.1: syntax error input: input: input: ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1387: $PREPARSER ./calc input ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1374: cat stderr stderr: | (#) + (#) = 2222 stderr: syntax error ./calc.at:1370: $PREPARSER ./calc input ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: $PREPARSER ./calc input stderr: stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: 1.1: syntax error syntax error 1.2: syntax error: invalid character: '#' ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (* *) + (*) + (*) ./calc.at:1374: $PREPARSER ./calc input stderr: ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1391: cat stderr ./calc.at:1375: cat stderr syntax error syntax error syntax error ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1371: cat stderr input: | 1//2 ./calc.at:1391: $PREPARSER ./calc input stderr: 1.3: syntax error ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | (1 + # + 1) = 1111 ./calc.at:1371: $PREPARSER ./calc input stderr: | (- *) + (1 2) = 1 ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1370: cat stderr stderr: syntax error syntax error syntax error 1.6: syntax error: invalid character: '#' ./calc.at:1390: cat stderr ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error stderr: ./calc.at:1389: cat stderr ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: cat stderr 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 = 2 = 3 ./calc.at:1390: $PREPARSER ./calc input stderr: 1.7: syntax error ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1387: $PREPARSER ./calc /dev/null stderr: stderr: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1371: cat stderr syntax error input: | 1 = 2 = 3 ./calc.at:1389: $PREPARSER ./calc input ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 stderr: stderr: 1.7: syntax error ./calc.at:1391: cat stderr ./calc.at:1370: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' syntax error ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | error stderr: ./calc.at:1391: $PREPARSER ./calc input stderr: ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error stderr: 1.1: syntax error syntax error ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1374: cat stderr ./calc.at:1375: cat stderr | (1 + 1) / (1 - 1) stderr: ./calc.at:1371: $PREPARSER ./calc input ./calc.at:1390: cat stderr stderr: stderr: 1.6: syntax error: invalid character: '#' input: | | +1 input: ./calc.at:1390: $PREPARSER ./calc input input: 1.1: syntax error ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 2.1: syntax error ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) 1.11-17: error: null divisor | 1 + 2 * 3 + !+ ++ ./calc.at:1374: $PREPARSER ./calc input ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1375: $PREPARSER ./calc input stderr: stderr: 2.1: syntax error ./calc.at:1389: cat stderr ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1370: cat stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1374: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.11-17: error: null divisor ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: cat stderr input: input: ./calc.at:1387: cat stderr | | +1 stderr: ./calc.at:1389: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ ./calc.at:1374: $PREPARSER ./calc input input: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1371: cat stderr stderr: | (# + 1) = 1111 input: ./calc.at:1370: $PREPARSER ./calc input stderr: ./calc.at:1391: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1387: $PREPARSER ./calc input syntax error stderr: ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: ./calc.at:1390: $PREPARSER ./calc /dev/null syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error stderr: stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 1.1: syntax error 1.2: syntax error: invalid character: '#' ./calc.at:1392: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 497. calc.at:1371: ok ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error | 1 = 2 = 3 ./calc.at:1391: $PREPARSER ./calc input stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1392: $PREPARSER ./calc input stderr: ./calc.at:1375: cat stderr 1.7: syntax error 1.2: syntax error: invalid character: '#' ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: 1.7: syntax error ./calc.at:1387: cat stderr stderr: input: | 1 2 ./calc.at:1392: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ stderr: ./calc.at:1370: cat stderr ./calc.at:1390: cat stderr ./calc.at:1375: $PREPARSER ./calc input 506. calc.at:1394: testing Calculator %glr-parser %verbose ... ./calc.at:1394: mv calc.y.tmp calc.y ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: syntax error ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1390: $PREPARSER ./calc input stderr: ./calc.at:1389: cat stderr stderr: input: ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1394: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error input: | (1 + # + 1) = 1111 ./calc.at:1374: cat stderr | (!!) + (1 2) = 1 ./calc.at:1370: $PREPARSER ./calc input ./calc.at:1389: $PREPARSER ./calc /dev/null ./calc.at:1387: $PREPARSER ./calc input stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error error: 2222 != 1 stderr: ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1391: cat stderr syntax error ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | | +1 ./calc.at:1391: $PREPARSER ./calc input input: ./calc.at:1375: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: 2.1: syntax error ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !* ++ ./calc.at:1374: $PREPARSER ./calc input syntax error error: 2222 != 1 ./calc.at:1392: cat stderr stderr: stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 stderr: stdout: ./calc.at:1393: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c input: stderr: | 1//2 ./calc.at:1392: $PREPARSER ./calc input memory exhausted ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1394: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS 2.1: syntax error stderr: input: 1.6: syntax error: invalid character: '#' input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: $PREPARSER ./calc input stderr: syntax error stderr: memory exhausted | 1 + 2 * 3 + !- ++ ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1370: cat stderr syntax error ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: | (1 + 1) / (1 - 1) stderr: ./calc.at:1370: $PREPARSER ./calc input ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error stderr: ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11-17: error: null divisor ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: cat stderr ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.11-17: error: null divisor ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: cat stderr ./calc.at:1374: cat stderr stderr: ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (!!) + (1 2) = 1 ./calc.at:1390: $PREPARSER ./calc input input: | 1 2 input: ./calc.at:1393: $PREPARSER ./calc input stderr: | (#) + (#) = 2222 stderr: ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1374: $PREPARSER ./calc input syntax error ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1389: cat stderr ./calc.at:1375: cat stderr input: ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1370: cat stderr input: | (- *) + (1 2) = 1 ./calc.at:1387: $PREPARSER ./calc input stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1389: $PREPARSER ./calc input syntax error syntax error error: 2222 != 1 ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1391: cat stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' syntax error syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error error: 2222 != 1 stderr: ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1392: cat stderr stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 | 1 + 2 * 3 + !* ++ ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1391: $PREPARSER ./calc /dev/null stderr: stderr: ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error syntax error syntax error syntax error error: 4444 != 1 stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.14: memory exhausted ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 496. calc.at:1370: ok 1.1: syntax error ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: 1.1: syntax error stderr: | error ./calc.at:1392: $PREPARSER ./calc input ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: cat stderr stderr: syntax error ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: cat stderr input: | (* *) + (*) + (*) ./calc.at:1387: $PREPARSER ./calc input 1.14: memory exhausted stderr: stderr: ./calc.at:1391: cat stderr syntax error syntax error syntax error ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: cat stderr syntax error ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1374: cat stderr syntax error syntax error syntax error 507. calc.at:1395: testing Calculator %glr-parser parse.error=verbose ... input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1391: $PREPARSER ./calc input input: | (1 + #) = 1111 ./calc.at:1374: $PREPARSER ./calc input ./calc.at:1389: cat stderr stderr: input: syntax error: invalid character: '#' ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1395: mv calc.y.tmp calc.y syntax error: invalid character: '#' ./calc.at:1375: cat stderr | (- *) + (1 2) = 1 ./calc.at:1390: $PREPARSER ./calc input input: ./calc.at:1395: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y input: | (#) + (#) = 2222 ./calc.at:1375: $PREPARSER ./calc input stderr: | 1//2 ./calc.at:1393: $PREPARSER ./calc input stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error stderr: ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1389: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1387: cat stderr ./calc.at:1392: cat stderr stderr: stderr: syntax error ./calc.at:1374: cat stderr ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error error: 2222 != 1 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1391: cat stderr ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stdout: ./types.at:139: $PREPARSER ./test ./calc.at:1375: cat stderr stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1387: $PREPARSER ./calc input input: input: stderr: input: ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 | (!!) + (1 2) = 1 ./calc.at:1391: $PREPARSER ./calc input | (# + 1) = 1111 ./calc.at:1392: $PREPARSER ./calc input ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1374: $PREPARSER ./calc input ./calc.at:1393: cat stderr input: | (1 + #) = 1111 ./calc.at:1375: $PREPARSER ./calc input ======== Testing with C++ standard flags: '' ./calc.at:1390: cat stderr stderr: stderr: 1.6: syntax error: invalid character: '#' syntax error ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error error: 2222 != 1 ./calc.at:1395: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: syntax error: invalid character: '#' input: stderr: ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' | 1 + 2 * 3 + !- ++ ./calc.at:1387: $PREPARSER ./calc input stderr: input: ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: syntax error ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error ./calc.at:1393: $PREPARSER ./calc input 1.11: syntax error 1.1-16: error: 2222 != 1 | (* *) + (*) + (*) ./calc.at:1390: $PREPARSER ./calc input stderr: stderr: syntax error: invalid character: '#' stderr: syntax error ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error ./calc.at:1375: cat stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 ./calc.at:1375: $PREPARSER ./calc input stderr: ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1393: cat stderr stdout: ./types.at:139: ./check stderr: input: 1.2: syntax error: invalid character: '#' ./calc.at:1389: cat stderr ./calc.at:1374: cat stderr | 1 = 2 = 3 ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: $PREPARSER ./calc input stderr: syntax error ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: input: ./calc.at:1391: cat stderr ./calc.at:1392: cat stderr | (1 + # + 1) = 1111 1.2: syntax error: invalid character: '#' ./calc.at:1374: $PREPARSER ./calc input stderr: stderr: syntax error input: input: syntax error: invalid character: '#' ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1391: $PREPARSER ./calc input ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (- *) + (1 2) = 1 ./calc.at:1389: $PREPARSER ./calc input 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1387: cat stderr ./calc.at:1375: cat stderr stderr: syntax error: invalid character: '#' syntax error syntax error error: 2222 != 1 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 stderr: syntax error syntax error error: 2222 != 1 input: | | +1 input: ./calc.at:1392: $PREPARSER ./calc input ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !* ++ ./calc.at:1387: $PREPARSER ./calc input ./calc.at:1390: cat stderr ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: input: ./calc.at:1393: cat stderr syntax error memory exhausted ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1391: cat stderr | (1 + # + 1) = 1111 input: ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: memory exhausted stderr: input: | 1 + 2 * 3 + !+ ++ | | +1 syntax error ./calc.at:1393: $PREPARSER ./calc input ./calc.at:1390: $PREPARSER ./calc input | (* *) + (*) + (*) ./calc.at:1391: $PREPARSER ./calc input ./calc.at:1374: cat stderr stderr: stderr: stderr: syntax error ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1389: cat stderr ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error input: input: | (1 + 1) / (1 - 1) ./calc.at:1374: $PREPARSER ./calc input | (* *) + (*) + (*) ./calc.at:1389: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: syntax error syntax error syntax error ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 error: null divisor 1.6: syntax error: invalid character: '#' ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ ./calc.at:1390: $PREPARSER ./calc input ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1393: cat stderr ./calc.at:1391: cat stderr syntax error syntax error syntax error stderr: ./calc.at:1387: cat stderr ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: error: null divisor input: | (#) + (#) = 2222 ./calc.at:1387: $PREPARSER ./calc input stderr: ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: $PREPARSER ./calc /dev/null ./calc.at:1375: cat stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: syntax error ./calc.at:1392: cat stderr ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: stderr: ./calc.at:1392: $PREPARSER ./calc /dev/null | 1 + 2 * 3 + !+ ++ | (1 + 1) / (1 - 1) ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1391: $PREPARSER ./calc input stderr: stderr: ./calc.at:1389: cat stderr ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: input: stderr: | 1 + 2 * 3 + !+ ++ 1.11-17: error: null divisor | 1 + 2 * 3 + !- ++ ./calc.at:1389: $PREPARSER ./calc input ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1391: $PREPARSER ./calc input syntax error stderr: ./calc.at:1374: cat stderr ./calc.at:1387: cat stderr stderr: ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: cat stderr stderr: stderr: ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11-17: error: null divisor stderr: input: | 123 input: input: ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1374: $PREPARSER ./calc --num input ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !* ++ | (1 + #) = 1111 ./calc.at:1387: $PREPARSER ./calc input ./calc.at:1392: cat stderr ./calc.at:1390: $PREPARSER ./calc input input: input: ./calc.at:1375: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1392: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ stderr: stderr: ./calc.at:1389: $PREPARSER ./calc input stderr: ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.14: memory exhausted stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1374: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1393: cat stderr syntax error: invalid character: '#' ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' input: stderr: stderr: | 123 ./calc.at:1391: cat stderr ./calc.at:1375: $PREPARSER ./calc --num input stderr: input: 1.14: memory exhausted | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1393: $PREPARSER ./calc input input: ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 ./calc.at:1374: $PREPARSER ./calc --num input stderr: ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error syntax error syntax error syntax error error: 4444 != 1 stderr: stderr: ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !* ++ syntax error ./calc.at:1391: $PREPARSER ./calc input stderr: ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1390: cat stderr syntax error syntax error syntax error syntax error error: 4444 != 1 stderr: stdout: ./calc.at:1392: cat stderr ./calc.at:1394: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c 1.14: memory exhausted ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1375: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: input: | (!!) + (1 2) = 1 1.14: memory exhausted ./calc.at:1392: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1394: $PREPARSER ./calc input input: stderr: ./calc.at:1387: cat stderr stderr: stderr: syntax error input: ./calc.at:1389: cat stderr ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 syntax error error: 2222 != 1 ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1390: $PREPARSER ./calc input ./calc.at:1375: $PREPARSER ./calc --num input ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error error: 2222 != 1 stderr: ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: input: ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 + 2 * 3 + !* ++ 1.3: syntax error, unexpected '+', expecting end of file input: ./calc.at:1389: $PREPARSER ./calc input stderr: stderr: memory exhausted ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: $PREPARSER ./calc input ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' input: ./calc.at:1391: cat stderr ./calc.at:1393: cat stderr | 1 2 ./calc.at:1394: $PREPARSER ./calc input stderr: ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error: invalid character: '#' stderr: ./calc.at:1392: cat stderr ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr memory exhausted stderr: input: stderr: syntax error: invalid character: '#' 1.3: syntax error, unexpected '+', expecting end of file ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: syntax error | (#) + (#) = 2222 | (- *) + (1 2) = 1 ./calc.at:1391: $PREPARSER ./calc input ./calc.at:1392: $PREPARSER ./calc input stderr: stderr: syntax error syntax error error: 2222 != 1 ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: syntax error syntax error error: 2222 != 1 ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1374: cat stderr ./calc.at:1393: $PREPARSER ./calc input ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1390: cat stderr stderr: ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error error: 2222 != 1 input: ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1375: cat stderr ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: cat stderr | 1 + 2 * 3 ./calc.at:1374: $PREPARSER ./calc --exp input stderr: stderr: input: stderr: | (1 + #) = 1111 syntax error error: 2222 != 1 ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1389: cat stderr ./calc.at:1390: $PREPARSER ./calc input input: ./calc.at:1394: cat stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 ./calc.at:1375: $PREPARSER ./calc --exp input | (1 + # + 1) = 1111 ./calc.at:1387: $PREPARSER ./calc input stderr: ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error: invalid character: '#' ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1374: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: | (#) + (#) = 2222 syntax error: invalid character: '#' ./calc.at:1389: $PREPARSER ./calc input ./calc.at:1392: cat stderr stderr: ./calc.at:1391: cat stderr syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: input: | (* *) + (*) + (*) ./calc.at:1392: $PREPARSER ./calc input | 1//2 ./calc.at:1394: $PREPARSER ./calc input stderr: syntax error syntax error syntax error stderr: ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error syntax error ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 1.6: syntax error: invalid character: '#' ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 498. calc.at:1374: ok ./calc.at:1375: $EGREP -c -v 'Return for a new token:|LAC:' stderr syntax error ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 ./calc.at:1391: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1387: cat stderr stderr: ./calc.at:1392: cat stderr 499. calc.at:1375: ok ./calc.at:1393: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (1 + 1) / (1 - 1) ./calc.at:1387: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' input: error: null divisor ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1393: $PREPARSER ./calc input ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: stderr: error: null divisor | 1 + 2 * 3 + !+ ++ ./calc.at:1392: $PREPARSER ./calc input ./calc.at:1394: cat stderr syntax error syntax error error: 2222 != 1 ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: cat stderr stderr: input: ./calc.at:1390: cat stderr | (1 + #) = 1111 ./calc.at:1389: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' syntax error syntax error error: 2222 != 1 input: input: | 1 + 2 * 3 + !- ++ ./calc.at:1392: $PREPARSER ./calc input ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error ./calc.at:1394: $PREPARSER ./calc input stderr: input: ./calc.at:1391: cat stderr stderr: 508. calc.at:1397: testing Calculator %glr-parser api.pure %locations ... ./calc.at:1397: mv calc.y.tmp calc.y ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 ./calc.at:1390: $PREPARSER ./calc input stderr: stderr: ./calc.at:1397: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y syntax error ./calc.at:1387: cat stderr ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (# + 1) = 1111 ./calc.at:1391: $PREPARSER ./calc input stderr: syntax error 500. calc.at:1387: ok 1.2: syntax error: invalid character: '#' ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1389: cat stderr stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (# + 1) = 1111 ./calc.at:1389: $PREPARSER ./calc input ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error: invalid character: '#' ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 509. calc.at:1398: testing Calculator %glr-parser parse.error=verbose %locations ... ./calc.at:1398: mv calc.y.tmp calc.y ./calc.at:1398: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1393: cat stderr input: stderr: ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1390: cat stderr | (* *) + (*) + (*) ./calc.at:1393: $PREPARSER ./calc input ./calc.at:1392: cat stderr stderr: syntax error syntax error syntax error ./calc.at:1398: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1394: cat stderr stderr: syntax error syntax error syntax error ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | 1 = 2 = 3 ./calc.at:1394: $PREPARSER ./calc input | 1 + 2 * 3 + !* ++ ./calc.at:1392: $PREPARSER ./calc input stderr: stderr: syntax error ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr memory exhausted ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error input: | (1 + # + 1) = 1111 ./calc.at:1390: $PREPARSER ./calc input stderr: memory exhausted stderr: ./calc.at:1397: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS 1.6: syntax error: invalid character: '#' ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1391: cat stderr ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 510. calc.at:1400: testing Calculator %glr-parser parse.error=custom %locations %header %name-prefix "calc" %verbose ... ./calc.at:1400: mv calc.y.tmp calc.y ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stdout: input: | (1 + # + 1) = 1111 ./calc.at:1391: $PREPARSER ./calc input ./calc.at:1395: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: cat stderr stderr: ./calc.at:1392: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1389: cat stderr ./calc.at:1393: cat stderr input: | (1 + 1) / (1 - 1) ./calc.at:1390: $PREPARSER ./calc input input: stderr: input: ./calc.at:1400: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | (#) + (#) = 2222 ./calc.at:1392: $PREPARSER ./calc input 1.11-17: error: null divisor | 1 + 2 * 3 + !+ ++ ./calc.at:1393: $PREPARSER ./calc input ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1394: cat stderr input: ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | | +1 ./calc.at:1394: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: input: stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1393: $PREPARSER ./calc input input: ./calc.at:1395: $PREPARSER ./calc input syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: | (1 + # + 1) = 1111 ./calc.at:1389: $PREPARSER ./calc input stderr: ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error syntax error: invalid character: '#' ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: cat stderr ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error: invalid character: '#' ./calc.at:1400: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1391: cat stderr 502. calc.at:1390: ok stderr: stderr: syntax error input: input: | 1 2 ./calc.at:1395: $PREPARSER ./calc input ./calc.at:1392: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1391: $PREPARSER ./calc input stderr: ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.11-17: error: null divisor ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: syntax error, unexpected number | (1 + #) = 1111 ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: $PREPARSER ./calc input stderr: syntax error, unexpected number ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error: invalid character: '#' ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' 1.11-17: error: null divisor 511. calc.at:1401: testing Calculator %glr-parser parse.error=custom %locations %header %name-prefix "calc" %verbose api.pure ... ./calc.at:1389: cat stderr ./calc.at:1401: mv calc.y.tmp calc.y ./calc.at:1394: cat stderr ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1394: $PREPARSER ./calc /dev/null ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1401: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1395: cat stderr ./calc.at:1393: cat stderr input: stderr: | (1 + 1) / (1 - 1) syntax error ./calc.at:1389: $PREPARSER ./calc input ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: cat stderr input: stderr: | 1//2 ./calc.at:1395: $PREPARSER ./calc input error: null divisor input: ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1391: cat stderr | 1 + 2 * 3 + !* ++ stderr: ./calc.at:1393: $PREPARSER ./calc input error: null divisor stderr: input: memory exhausted ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 stderr: stderr: ./calc.at:1392: $PREPARSER ./calc input memory exhausted syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected '/', expecting number or '-' or '(' or '!' syntax error 503. calc.at:1391: ok ./calc.at:1401: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1395: cat stderr ./calc.at:1389: cat stderr ./calc.at:1393: cat stderr stderr: 501. calc.at:1389: ok syntax error: invalid character: '#' input: | error ./calc.at:1395: $PREPARSER ./calc input input: stderr: | (#) + (#) = 2222 ./calc.at:1393: $PREPARSER ./calc input syntax error, unexpected invalid token ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 512. calc.at:1402: testing Calculator %glr-parser parse.error=detailed %locations %header %name-prefix "calc" %verbose ... ./calc.at:1392: cat stderr ./calc.at:1394: cat stderr stderr: ./calc.at:1402: mv calc.y.tmp calc.y stderr: input: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1394: $PREPARSER ./calc input ./calc.at:1402: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: syntax error, unexpected invalid token input: | (1 + # + 1) = 1111 ./calc.at:1392: $PREPARSER ./calc input syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' stderr: ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 stderr: syntax error: invalid character: '#' ./calc.at:1395: cat stderr input: | 1 = 2 = 3 513. calc.at:1403: testing Calculator %glr-parser parse.error=verbose %locations %header %name-prefix "calc" %verbose ... ./calc.at:1403: mv calc.y.tmp calc.y ./calc.at:1395: $PREPARSER ./calc input stderr: syntax error, unexpected '=' ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1403: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected '=' ./calc.at:1394: cat stderr ./calc.at:1392: cat stderr ./calc.at:1393: cat stderr ./calc.at:1403: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS input: ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 input: ./calc.at:1394: $PREPARSER ./calc input input: stderr: ./calc.at:1395: cat stderr | (1 + #) = 1111 ./calc.at:1393: $PREPARSER ./calc input syntax error error: 2222 != 1 | (1 + 1) / (1 - 1) stderr: ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: $PREPARSER ./calc input syntax error: invalid character: '#' stderr: ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error error: 2222 != 1 error: null divisor ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | | +1 stderr: stderr: ./calc.at:1395: $PREPARSER ./calc input syntax error: invalid character: '#' stderr: error: null divisor syntax error, unexpected '+' ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error, unexpected '+' ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1394: cat stderr ./calc.at:1392: cat stderr ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: cat stderr 504. calc.at:1392: ok ./calc.at:1395: cat stderr input: input: | (# + 1) = 1111 | (- *) + (1 2) = 1 ./calc.at:1393: $PREPARSER ./calc input ./calc.at:1395: $PREPARSER ./calc /dev/null ./calc.at:1394: $PREPARSER ./calc input stderr: stdout: stderr: stderr: syntax error syntax error error: 2222 != 1 ./calc.at:1398: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1398: $PREPARSER ./calc input syntax error, unexpected end of input stderr: ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error error: 2222 != 1 stderr: stderr: syntax error, unexpected end of input syntax error: invalid character: '#' stderr: 514. calc.at:1405: testing Calculator %glr-parser parse.error=custom %locations %header %name-prefix "calc" %verbose ... input: | 1 2 ./calc.at:1398: $PREPARSER ./calc input ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1405: mv calc.y.tmp calc.y stderr: 1.3: syntax error, unexpected number ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1405: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1395: cat stderr ./calc.at:1394: cat stderr stderr: 1.3: syntax error, unexpected number input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1395: $PREPARSER ./calc input | (* *) + (*) + (*) ./calc.at:1394: $PREPARSER ./calc input stderr: syntax error syntax error syntax error ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: cat stderr stderr: syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1398: cat stderr stderr: stderr: syntax error syntax error syntax error syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 input: ./calc.at:1405: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS | 1//2 ./calc.at:1398: $PREPARSER ./calc input input: stderr: | (1 + # + 1) = 1111 ./calc.at:1393: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1394: cat stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' syntax error: invalid character: '#' ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1395: cat stderr ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1398: cat stderr input: stderr: input: | 1 + 2 * 3 + !+ ++ ./calc.at:1394: $PREPARSER ./calc input | error ./calc.at:1398: $PREPARSER ./calc input stderr: stdout: stderr: input: ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: cat stderr ./calc.at:1397: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c | (!!) + (1 2) = 1 ./calc.at:1395: $PREPARSER ./calc input stderr: 1.1: syntax error, unexpected invalid token ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected number error: 2222 != 1 input: ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 | 1 + 2 * 3 + !- ++ ./calc.at:1397: $PREPARSER ./calc input syntax error, unexpected number error: 2222 != 1 ./calc.at:1394: $PREPARSER ./calc input stderr: stdout: input: stderr: ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1400: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h stderr: ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (1 + 1) / (1 - 1) ./calc.at:1393: $PREPARSER ./calc input stderr: error: null divisor 1.1: syntax error, unexpected invalid token ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1400: $PREPARSER ./calc input input: stderr: ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1397: $PREPARSER ./calc input stderr: stderr: input: stderr: ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 ./calc.at:1400: $PREPARSER ./calc input error: null divisor stderr: 1.3: syntax error ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./calc.at:1394: cat stderr ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) stderr: ./calc.at:1398: cat stderr stdout: stderr: input: 1.3: syntax error | 1 + 2 * 3 + !* ++ ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1394: $PREPARSER ./calc input ./calc.at:1400: cat stderr ./calc.at:1401: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1395: cat stderr ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: memory exhausted input: ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 ./calc.at:1398: $PREPARSER ./calc input input: stderr: stderr: | (- *) + (1 2) = 1 1.7: syntax error, unexpected '=' ./calc.at:1395: $PREPARSER ./calc input ./calc.at:1393: cat stderr ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr memory exhausted stderr: 1.7: syntax error, unexpected '=' input: stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 | 1//2 ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1400: $PREPARSER ./calc input ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1401: $PREPARSER ./calc input ./calc.at:1398: cat stderr 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: 505. calc.at:1393: ok 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 stderr: | | +1 ./calc.at:1398: $PREPARSER ./calc input stderr: 2.1: syntax error, unexpected '+' ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1400: cat stderr ./calc.at:1397: cat stderr input: ./calc.at:1394: cat stderr | 1 2 ./calc.at:1401: $PREPARSER ./calc input input: stderr: stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: | (#) + (#) = 2222 ./calc.at:1394: $PREPARSER ./calc input ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 2.1: syntax error, unexpected '+' input: stderr: | 1//2 syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1397: $PREPARSER ./calc input ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | error ./calc.at:1400: $PREPARSER ./calc input stderr: ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1398: cat stderr 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./calc.at:1398: $PREPARSER ./calc /dev/null ./calc.at:1395: cat stderr stderr: ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error, unexpected end of input ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error, unexpected end of input ./calc.at:1401: cat stderr input: ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) stderr: ./calc.at:1395: $PREPARSER ./calc input 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1398: cat stderr ./calc.at:1400: cat stderr ./calc.at:1394: cat stderr ./calc.at:1397: cat stderr input: 515. calc.at:1407: testing Calculator %glr-parser %debug ... ./calc.at:1407: mv calc.y.tmp calc.y ./calc.at:1407: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | 1//2 input: ./calc.at:1401: $PREPARSER ./calc input stderr: input: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' input: | (1 + #) = 1111 | error ./calc.at:1397: $PREPARSER ./calc input ./calc.at:1394: $PREPARSER ./calc input stderr: | 1 = 2 = 3 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1400: $PREPARSER ./calc input input: stderr: ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1398: $PREPARSER ./calc input 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) stderr: ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) stderr: 1.1: syntax error stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) stderr: stderr: stdout: ./calc.at:1400: cat stderr syntax error: invalid character: '#' ./calc.at:1402: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1401: cat stderr input: ./calc.at:1397: cat stderr ./calc.at:1407: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS | | +1 input: ./calc.at:1400: $PREPARSER ./calc input ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1402: $PREPARSER ./calc input ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: input: ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1395: cat stderr input: | 1 = 2 = 3 | error ./calc.at:1397: $PREPARSER ./calc input ./calc.at:1401: $PREPARSER ./calc input 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1398: cat stderr stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) 1.7: syntax error stderr: ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) input: ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: 1.7: syntax error | (!!) + (1 2) = 1 ./calc.at:1398: $PREPARSER ./calc input | 1 2 stderr: ./calc.at:1400: cat stderr stderr: ./calc.at:1402: $PREPARSER ./calc input stderr: input: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) stdout: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1395: $PREPARSER ./calc input ./calc.at:1403: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h 1.3: syntax error, unexpected number ./calc.at:1400: $PREPARSER ./calc /dev/null ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1401: cat stderr stderr: stderr: ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1403: $PREPARSER ./calc input 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error, unexpected number 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 input: ./calc.at:1400: cat stderr | 1 = 2 = 3 ./calc.at:1401: $PREPARSER ./calc input ./calc.at:1394: cat stderr ./calc.at:1397: cat stderr stderr: input: ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1400: $PREPARSER ./calc input stderr: input: stderr: stderr: ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) | (# + 1) = 1111 ./calc.at:1394: $PREPARSER ./calc input stderr: input: syntax error: invalid character: '#' input: ./calc.at:1402: cat stderr input: ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1403: $PREPARSER ./calc input ./calc.at:1398: cat stderr stderr: stderr: | | +1 1.3: syntax error, unexpected number ./calc.at:1397: $PREPARSER ./calc input input: ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 | 1 + 2 * 3 + !- ++ ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1398: $PREPARSER ./calc input ./calc.at:1401: cat stderr ./calc.at:1395: $PREPARSER ./calc input stderr: input: stderr: stderr: 1.3: syntax error, unexpected number stderr: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 stderr: ./calc.at:1402: $PREPARSER ./calc input 2.1: syntax error ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | | +1 ./calc.at:1401: $PREPARSER ./calc input stderr: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' stderr: 2.1: syntax error ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1400: cat stderr stderr: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 stderr: ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: input: ./calc.at:1403: cat stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' stderr: | (!!) + (1 2) = 1 ./calc.at:1400: $PREPARSER ./calc input input: | 1//2 ./calc.at:1403: $PREPARSER ./calc input stderr: stderr: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1401: cat stderr ./calc.at:1394: cat stderr ./calc.at:1395: cat stderr ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1401: $PREPARSER ./calc /dev/null ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !* ++ ./calc.at:1395: $PREPARSER ./calc input input: ./calc.at:1398: cat stderr ./calc.at:1402: cat stderr stderr: stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1403: cat stderr ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 | (1 + # + 1) = 1111 stderr: ./calc.at:1394: $PREPARSER ./calc input stderr: stderr: memory exhausted 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stdout: stderr: input: syntax error: invalid character: '#' ./calc.at:1401: cat stderr | error ./calc.at:1402: $PREPARSER ./calc input | error ./calc.at:1403: $PREPARSER ./calc input ./types.at:139: $PREPARSER ./test input: ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr memory exhausted stderr: stderr: | (* *) + (*) + (*) ./calc.at:1398: $PREPARSER ./calc input ./calc.at:1397: cat stderr input: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 1.1: syntax error, unexpected invalid token stderr: stderr: ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1401: $PREPARSER ./calc input ./calc.at:1400: cat stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error: invalid character: '#' ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: $PREPARSER ./calc /dev/null stderr: 1.1: syntax error, unexpected invalid token 1.1: syntax error, unexpected invalid token ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 | (- *) + (1 2) = 1 ./calc.at:1400: $PREPARSER ./calc input ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 stderr: ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1395: cat stderr ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1403: cat stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 451. types.at:139: ok stderr: stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 1.1: syntax error 1.1: syntax error, unexpected invalid token input: | 1 = 2 = 3 ./calc.at:1403: $PREPARSER ./calc input input: ./calc.at:1394: cat stderr ./calc.at:1400: cat stderr stderr: ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.7: syntax error, unexpected '=' ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (#) + (#) = 2222 ./calc.at:1395: $PREPARSER ./calc input ./calc.at:1401: cat stderr input: stderr: ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) ./calc.at:1400: $PREPARSER ./calc input 1.7: syntax error, unexpected '=' ./calc.at:1402: cat stderr input: stderr: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (!!) + (1 2) = 1 stderr: ./calc.at:1401: $PREPARSER ./calc input stderr: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: ./calc.at:1397: cat stderr 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 ./calc.at:1398: cat stderr ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + 1) / (1 - 1) ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1400: cat stderr ./calc.at:1394: $PREPARSER ./calc input ./calc.at:1397: $PREPARSER ./calc input stderr: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 stderr: ./calc.at:1403: cat stderr 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: input: | 1 = 2 = 3 stderr: | 1 + 2 * 3 + !+ ++ 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1398: $PREPARSER ./calc input error: null divisor input: ./calc.at:1401: cat stderr ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: $PREPARSER ./calc input | | +1 stderr: ./calc.at:1403: $PREPARSER ./calc input ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.7: syntax error, unexpected '=' error: null divisor ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !+ ++ ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1400: $PREPARSER ./calc input stderr: stderr: 2.1: syntax error, unexpected '+' stderr: stderr: ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.7: syntax error, unexpected '=' ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 516. calc.at:1408: testing Calculator %glr-parser parse.error=verbose %debug %locations %header %name-prefix "calc" %verbose ... ./calc.at:1408: mv calc.y.tmp calc.y stderr: input: 2.1: syntax error, unexpected '+' ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !- ++ ./calc.at:1397: cat stderr ./calc.at:1398: $PREPARSER ./calc input input: ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: | 1 + 2 * 3 + !- ++ ./calc.at:1400: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1395: cat stderr ./calc.at:1402: cat stderr ./calc.at:1401: $PREPARSER ./calc input ./calc.at:1394: cat stderr ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | (!!) + (1 2) = 1 input: ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: $PREPARSER ./calc input | | +1 ./calc.at:1402: $PREPARSER ./calc input ./calc.at:1403: cat stderr input: ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 506. calc.at:1394: ok 1.11: syntax error 1.1-16: error: 2222 != 1 2.1: syntax error, unexpected '+' ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1408: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: stderr: stderr: | (1 + #) = 1111 ./calc.at:1395: $PREPARSER ./calc input 2.1: syntax error, unexpected '+' ./calc.at:1403: $PREPARSER ./calc /dev/null stderr: syntax error: invalid character: '#' 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error, unexpected end of input 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1400: cat stderr ./calc.at:1398: cat stderr stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 stderr: ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' ./calc.at:1397: cat stderr input: stderr: 1.1: syntax error, unexpected end of input | 1 + 2 * 3 + !* ++ ./calc.at:1398: $PREPARSER ./calc input ./calc.at:1401: cat stderr stderr: input: 1.14: memory exhausted ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1397: $PREPARSER ./calc input ./calc.at:1402: cat stderr stderr: input: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) ./calc.at:1401: $PREPARSER ./calc input stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 stderr: input: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) | 1 + 2 * 3 + !* ++ ./calc.at:1400: $PREPARSER ./calc input ./calc.at:1402: $PREPARSER ./calc /dev/null 517. calc.at:1409: testing Calculator %glr-parser parse.error=verbose %debug %locations %header api.prefix={calc} api.token.prefix={TOK_} %verbose ... stderr: ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: mv calc.y.tmp calc.y ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.14: memory exhausted ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1401: cat stderr ./calc.at:1403: cat stderr stderr: ./calc.at:1395: cat stderr 1.14: memory exhausted 1.14: memory exhausted ./calc.at:1409: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1408: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1403: $PREPARSER ./calc input 1.1: syntax error, unexpected end of file ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | 1 + 2 * 3 + !+ ++ 1.1: syntax error, unexpected end of file ./calc.at:1401: $PREPARSER ./calc input stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: | (# + 1) = 1111 ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1395: $PREPARSER ./calc input stderr: ./calc.at:1400: cat stderr stderr: syntax error: invalid character: '#' ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: cat stderr ./calc.at:1398: cat stderr stderr: syntax error: invalid character: '#' ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1403: cat stderr input: ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1402: cat stderr input: | 1 + 2 * 3 + !- ++ | (#) + (#) = 2222 ./calc.at:1395: cat stderr input: ./calc.at:1401: $PREPARSER ./calc input ./calc.at:1400: $PREPARSER ./calc input input: stderr: stderr: | (!!) + (1 2) = 1 ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1403: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 input: stderr: | (#) + (#) = 2222 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 input: ./calc.at:1398: $PREPARSER ./calc input | (1 + # + 1) = 1111 ./calc.at:1395: $PREPARSER ./calc input | (* *) + (*) + (*) stderr: ./calc.at:1402: $PREPARSER ./calc input stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1409: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 1.2: syntax error 1.10: syntax error 1.16: syntax error stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1401: cat stderr ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1395: cat stderr stdout: ./calc.at:1403: cat stderr ./calc.at:1405: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1402: cat stderr | (- *) + (1 2) = 1 stderr: input: ./calc.at:1403: $PREPARSER ./calc input 1.2: syntax error 1.10: syntax error 1.16: syntax error input: | (1 + 1) / (1 - 1) | 1 + 2 * 3 + !* ++ ./calc.at:1395: $PREPARSER ./calc input stderr: ./calc.at:1401: $PREPARSER ./calc input 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: null divisor ./calc.at:1400: cat stderr stderr: ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 input: | (!!) + (1 2) = 1 ./calc.at:1402: $PREPARSER ./calc input stderr: ./calc.at:1398: cat stderr stderr: ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.14: memory exhausted error: null divisor ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: ./calc.at:1403: cat stderr input: | (1 + #) = 1111 stderr: ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1400: $PREPARSER ./calc input | (* *) + (*) + (*) ./calc.at:1403: $PREPARSER ./calc input stderr: ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 1.14: memory exhausted | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1405: $PREPARSER ./calc input ./calc.at:1395: cat stderr stderr: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: cat stderr stderr: ./calc.at:1401: cat stderr 1.6: syntax error: invalid character: '#' stderr: | (1 + #) = 1111 507. calc.at:1395: ok ./calc.at:1398: $PREPARSER ./calc input ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: cat stderr ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (#) + (#) = 2222 ./calc.at:1401: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' stderr: input: stderr: | 1 2 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1405: $PREPARSER ./calc input ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' input: stderr: 1.6: syntax error: invalid character: '#' input: | 1 + 2 * 3 + !+ ++ ./calc.at:1400: cat stderr ./calc.at:1397: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1402: $PREPARSER ./calc input stderr: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1403: cat stderr ./calc.at:1405: cat stderr | (# + 1) = 1111 ./calc.at:1400: $PREPARSER ./calc input stderr: ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error: invalid character: '#' 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 518. calc.at:1411: testing Calculator %glr-parser api.pure parse.error=verbose %debug %locations %header %name-prefix "calc" %verbose ... input: ./calc.at:1411: mv calc.y.tmp calc.y | 1//2 ./calc.at:1405: $PREPARSER ./calc input ./calc.at:1401: cat stderr stderr: ./calc.at:1411: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y input: input: 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !+ ++ input: stderr: ./calc.at:1403: $PREPARSER ./calc input ./calc.at:1398: cat stderr | (1 + #) = 1111 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1401: $PREPARSER ./calc input stderr: stderr: ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' | 1 + 2 * 3 + !- ++ stderr: ./calc.at:1397: $PREPARSER ./calc input ./calc.at:1405: cat stderr ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1400: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: input: | (# + 1) = 1111 | error input: | (1 + # + 1) = 1111 ./calc.at:1405: $PREPARSER ./calc input ./calc.at:1400: $PREPARSER ./calc input ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1398: $PREPARSER ./calc input stderr: stderr: stderr: stderr: 1.6: syntax error: invalid character: '#' 1.2: syntax error: invalid character: '#' ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1402: cat stderr input: | 1 + 2 * 3 + !- ++ ./calc.at:1403: $PREPARSER ./calc input stderr: ./calc.at:1401: cat stderr stderr: ./calc.at:1411: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 stderr: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1401: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' stderr: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) input: | (* *) + (*) + (*) ./calc.at:1402: $PREPARSER ./calc input ./calc.at:1397: cat stderr stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1398: cat stderr ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' input: | (1 + # + 1) = 1111 ./calc.at:1398: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' input: ./calc.at:1405: cat stderr | 1 + 2 * 3 + !* ++ ./calc.at:1403: cat stderr ./calc.at:1397: $PREPARSER ./calc input ./calc.at:1400: cat stderr stderr: 1.14: memory exhausted ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' input: stderr: ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.14: memory exhausted input: stderr: | 1 = 2 = 3 ./calc.at:1405: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' | 1 + 2 * 3 + !* ++ ./calc.at:1403: $PREPARSER ./calc input input: stderr: stderr: 1.14: memory exhausted ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1401: cat stderr stderr: | (1 + 1) / (1 - 1) ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1400: $PREPARSER ./calc input 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.14: memory exhausted stderr: stderr: ./calc.at:1398: cat stderr 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) 1.11-17: error: null divisor ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (1 + # + 1) = 1111 ./calc.at:1402: cat stderr ./calc.at:1401: $PREPARSER ./calc input 1.11-17: error: null divisor stderr: ./calc.at:1405: cat stderr ./calc.at:1397: cat stderr input: ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.6: syntax error: invalid character: '#' | 1 + 2 * 3 + !+ ++ input: ./calc.at:1402: $PREPARSER ./calc input | (#) + (#) = 2222 ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: $PREPARSER ./calc input stderr: input: | (1 + 1) / (1 - 1) ./calc.at:1398: $PREPARSER ./calc input ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor input: ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | | +1 ./calc.at:1405: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: stderr: ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11-17: error: null divisor 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) 1.6: syntax error: invalid character: '#' ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1400: cat stderr ./calc.at:1403: cat stderr stderr: ./calc.at:1405: cat stderr ./calc.at:1405: $PREPARSER ./calc /dev/null stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1401: cat stderr 510. calc.at:1400: ok ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1397: cat stderr stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1402: $PREPARSER ./calc input | (#) + (#) = 2222 ./calc.at:1403: $PREPARSER ./calc input 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1398: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1401: $PREPARSER ./calc input ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + #) = 1111 ./calc.at:1397: $PREPARSER ./calc input stderr: stderr: 509. calc.at:1398: ok stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1405: cat stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' 1.11-17: error: null divisor ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1402: cat stderr stderr: 1.6: syntax error: invalid character: '#' input: ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1401: cat stderr ./calc.at:1405: $PREPARSER ./calc input 519. calc.at:1413: testing Calculator %glr-parser api.pure parse.error=verbose %debug %locations %header %name-prefix "calc" %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1413: mv calc.y.tmp calc.y ./calc.at:1403: cat stderr stderr: input: ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1413: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | 1 + 2 * 3 + !* ++ 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: $PREPARSER ./calc input 511. calc.at:1401: ok ./calc.at:1397: cat stderr input: stderr: 1.14: memory exhausted ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1403: $PREPARSER ./calc input stderr: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 input: | (# + 1) = 1111 ./calc.at:1397: $PREPARSER ./calc input stderr: 520. calc.at:1414: testing Calculator %glr-parser api.pure parse.error=verbose %debug %locations %header api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... stderr: stderr: 1.14: memory exhausted stderr: stdout: 1.2: syntax error: invalid character: '#' 1.6: syntax error: invalid character: '#' ./calc.at:1405: cat stderr ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1414: mv calc.y.tmp calc.y ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1407: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1402: cat stderr input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1407: $PREPARSER ./calc input input: input: ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 521. calc.at:1416: testing Calculator %glr-parser %no-lines api.pure parse.error=verbose %debug %locations %header api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1416: mv calc.y.tmp calc.y | (!!) + (1 2) = 1 stderr: ./calc.at:1405: $PREPARSER ./calc input | (#) + (#) = 2222 ./calc.at:1402: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 7) Shifting token "number" (1.1: 7) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 7) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 7) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 10 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -3) Entering state 31 Next token is token '=' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: -3) -> $$ = nterm exp (1.1: -6) Entering state 30 Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: -6) -> $$ = nterm exp (1.1: -5) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 5) Shifting token "number" (1.1: 5) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 5) -> $$ = nterm exp (1.1: 5) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 5) -> $$ = nterm exp (1.1: -5) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -5) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -5) -> $$ = nterm exp (1.1: -5) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -5) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 10 Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: -1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 10 Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 1) Entering state 10 Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 29 Reading a token Next token is token '-' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: -1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -4) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 4) Shifting token "number" (1.1: 4) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 4) -> $$ = nterm exp (1.1: 4) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 4) -> $$ = nterm exp (1.1: -4) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -4) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -4) -> $$ = nterm exp (1.1: -4) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -4) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 2) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -1) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 29 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 2) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 8) Entering state 33 Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 8) -> $$ = nterm exp (1.1: 256) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 256) Shifting token "number" (1.1: 256) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 256) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 256) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 4) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 4) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 4) Entering state 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 4) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 64) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 64) Shifting token "number" (1.1: 64) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 64) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 64) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: cat stderr stderr: ./calc.at:1403: cat stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1414: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1413: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + # + 1) = 1111 ./calc.at:1397: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 7) Shifting token "number" (1.1: 7) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 7) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 7) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 10 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -3) Entering state 31 Next token is token '=' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: -3) -> $$ = nterm exp (1.1: -6) Entering state 30 Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: -6) -> $$ = nterm exp (1.1: -5) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 5) Shifting token "number" (1.1: 5) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 5) -> $$ = nterm exp (1.1: 5) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 5) -> $$ = nterm exp (1.1: -5) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -5) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -5) -> $$ = nterm exp (1.1: -5) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -5) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 10 Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: -1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 10 Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 1) Entering state 10 Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 29 Reading a token Next token is token '-' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: -1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -4) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 4) Shifting token "number" (1.1: 4) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 4) -> $$ = nterm exp (1.1: 4) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 4) -> $$ = nterm exp (1.1: -4) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -4) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -4) -> $$ = nterm exp (1.1: -4) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -4) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 2) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -1) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 29 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 2) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 8) Entering state 33 Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 8) -> $$ = nterm exp (1.1: 256) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 256) Shifting token "number" (1.1: 256) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 256) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 256) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 4) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 4) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 4) Entering state 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 4) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 64) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 64) Shifting token "number" (1.1: 64) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 64) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 64) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' input: 1.6: syntax error: invalid character: '#' ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 1.6: syntax error: invalid character: '#' | (# + 1) = 1111 ./calc.at:1403: $PREPARSER ./calc input | 1 2 ./calc.at:1407: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.1: 2) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1405: cat stderr ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.1: 2) ./calc.at:1402: cat stderr stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1397: cat stderr ./calc.at:1414: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS input: | (- *) + (1 2) = 1 ./calc.at:1405: $PREPARSER ./calc input input: stderr: | (1 + #) = 1111 ./calc.at:1402: $PREPARSER ./calc input 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + 1) / (1 - 1) ./calc.at:1397: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.11-17: error: null divisor ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 1.6: syntax error: invalid character: '#' ./calc.at:1403: cat stderr ./calc.at:1407: cat stderr stderr: 1.11-17: error: null divisor input: | (1 + # + 1) = 1111 ./calc.at:1403: $PREPARSER ./calc input ./calc.at:1405: cat stderr input: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: $PREPARSER ./calc input stderr: ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Reading a token Next token is token '/' (1.1: ) syntax error Error: popping token '/' (1.1: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1402: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Reading a token Next token is token '/' (1.1: ) syntax error Error: popping token '/' (1.1: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.1: ) input: | (# + 1) = 1111 input: ./calc.at:1402: $PREPARSER ./calc input | (* *) + (*) + (*) ./calc.at:1405: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' stderr: stderr: ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' stderr: stderr: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1397: cat stderr ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' ./calc.at:1403: cat stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1405: cat stderr ./calc.at:1407: cat stderr ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 508. calc.at:1397: ok input: | (1 + 1) / (1 - 1) ./calc.at:1403: $PREPARSER ./calc input stderr: input: ./calc.at:1402: cat stderr 1.11-17: error: null divisor ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !+ ++ | error input: ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1405: $PREPARSER ./calc input | (1 + # + 1) = 1111 ./calc.at:1402: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.11-17: error: null divisor Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1402: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) input: ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1403: cat stderr | 1 + 2 * 3 + !- ++ input: | (1 + 1) / (1 - 1) ./calc.at:1402: $PREPARSER ./calc input ./calc.at:1405: $PREPARSER ./calc input stderr: 513. calc.at:1403: ok ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11-17: error: null divisor ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor stderr: stdout: 522. calc.at:1426: testing Calculator lalr1.cc %header ... ./calc.at:1426: mv calc.y.tmp calc.y ./calc.at:1408: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h stderr: ./calc.at:1426: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1407: cat stderr ./calc.at:1402: cat stderr input: 512. calc.at:1402: ok | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1405: cat stderr stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) | 1 = 2 = 3 ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1426: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Reading a token Next token is token '=' (1.1: ) syntax error Error: popping nterm exp (1.1: 2) Error: popping token '=' (1.1: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 523. calc.at:1431: testing Calculator C++ ... input: stderr: ./calc.at:1431: mv calc.y.tmp calc.y stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) | 1 + 2 * 3 + !* ++ ./calc.at:1405: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Reading a token Next token is token '=' (1.1: ) syntax error Error: popping nterm exp (1.1: 2) Error: popping token '=' (1.1: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.1: ) ./calc.at:1431: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: stderr: | 1 2 stderr: 1.14: memory exhausted ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stderr: ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1409: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h 1.14: memory exhausted stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 524. calc.at:1432: testing Calculator C++ %locations ... ./calc.at:1432: mv calc.y.tmp calc.y ./calc.at:1432: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1409: $PREPARSER ./calc input ./calc.at:1405: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1431: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1407: cat stderr | (#) + (#) = 2222 ./calc.at:1405: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) input: input: | 1 2 | | +1 ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1409: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '+' (1.1: ) syntax error Error: popping nterm input (1.1: ) Cleanup: discarding lookahead token '+' (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) stdout: ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: cat stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1411: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h input: | 1//2 ./calc.at:1408: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '+' (1.1: ) syntax error Error: popping nterm input (1.1: ) Cleanup: discarding lookahead token '+' (1.1: ) stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1405: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1432: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1411: $PREPARSER ./calc input stderr: ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) | (1 + #) = 1111 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1405: $PREPARSER ./calc input ./calc.at:1409: cat stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 2 1.6: syntax error: invalid character: '#' ./calc.at:1411: $PREPARSER ./calc input ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: cat stderr stderr: 1.6: syntax error: invalid character: '#' stderr: input: | 1//2 ./calc.at:1407: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1409: $PREPARSER ./calc input input: ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1407: $PREPARSER ./calc /dev/null ./calc.at:1405: cat stderr stderr: Starting parse Entering state 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: Starting parse Entering state 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) | (# + 1) = 1111 ./calc.at:1405: $PREPARSER ./calc input ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1411: cat stderr 1.2: syntax error: invalid character: '#' ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1409: cat stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1405: cat stderr input: | 1//2 ./calc.at:1411: $PREPARSER ./calc input stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1409: $PREPARSER ./calc input ./calc.at:1407: cat stderr ./calc.at:1408: cat stderr stderr: stderr: stderr: input: | (1 + # + 1) = 1111 ./calc.at:1405: $PREPARSER ./calc input stdout: stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./types.at:139: $PREPARSER ./test 1.6: syntax error: invalid character: '#' ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' stderr: stderr: input: input: ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1411: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1407: $PREPARSER ./calc input stderr: ./calc.at:1405: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 2) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 3) Entering state 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token ')' (1.1: ) syntax error Error: popping token '+' (1.1: ) Error: popping nterm exp (1.1: 3) Shifting token error (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 31 Reading a token Next token is token '*' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 1) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token '*' (1.1: ) syntax error Error: popping token '*' (1.1: ) Error: popping nterm exp (1.1: 2) Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 3333) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 4444) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 4444) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 4444 != 1 -> $$ = nterm exp (1.1: 4444) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 4444) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + 1) / (1 - 1) ./calc.at:1405: $PREPARSER ./calc input stderr: 1.11-17: error: null divisor ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 2) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 3) Entering state 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token ')' (1.1: ) syntax error Error: popping token '+' (1.1: ) Error: popping nterm exp (1.1: 3) Shifting token error (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 31 Reading a token Next token is token '*' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 1) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token '*' (1.1: ) syntax error Error: popping token '*' (1.1: ) Error: popping nterm exp (1.1: 2) Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 3333) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 4444) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 4444) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 4444 != 1 -> $$ = nterm exp (1.1: 4444) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 4444) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) 452. types.at:139: ok | error stderr: ./calc.at:1411: $PREPARSER ./calc input 1.11-17: error: null divisor ./calc.at:1409: cat stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1405: cat stderr Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 514. calc.at:1405: ok ./calc.at:1407: cat stderr ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | (!!) + (1 2) = 1 ./calc.at:1407: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1409: $PREPARSER ./calc input stderr: ./calc.at:1408: cat stderr Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 16 Reducing stack 0 by rule 16 (line 121): $1 = token '!' (1.1: ) $2 = token '!' (1.1: ) Shifting token error (1.1: ) Entering state 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 16 Reducing stack 0 by rule 16 (line 121): $1 = token '!' (1.1: ) $2 = token '!' (1.1: ) Shifting token error (1.1: ) Entering state 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1408: $PREPARSER ./calc input stderr: ./calc.at:1411: cat stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 525. calc.at:1433: testing Calculator C++ %locations $NO_EXCEPTIONS_CXXFLAGS ... ./calc.at:1433: mv calc.y.tmp calc.y ./calc.at:1433: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: cat stderr stderr: input: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 526. calc.at:1434: testing Calculator C++ %locations api.location.type={Span} ... ./calc.at:1434: mv calc.y.tmp calc.y ./calc.at:1434: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y | 1 = 2 = 3 ./calc.at:1411: $PREPARSER ./calc input input: ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: stdout: ./calc.at:1413: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1408: cat stderr | (- *) + (1 2) = 1 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1409: cat stderr stderr: ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1433: $CXX $CPPFLAGS $CXXFLAGS $NO_EXCEPTIONS_CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1408: $PREPARSER ./calc /dev/null stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 9 Reducing stack 0 by rule 15 (line 120): $1 = token '-' (1.1: ) $2 = token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1411: cat stderr ./calc.at:1413: $PREPARSER ./calc input | | +1 stderr: ./calc.at:1409: $PREPARSER ./calc input input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) | | +1 ./calc.at:1411: $PREPARSER ./calc input ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 9 Reducing stack 0 by rule 15 (line 120): $1 = token '-' (1.1: ) $2 = token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1434: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS input: | 1 2 ./calc.at:1413: $PREPARSER ./calc input stderr: ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: cat stderr ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1408: cat stderr stderr: ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1411: cat stderr ./calc.at:1409: $PREPARSER ./calc /dev/null stdout: stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1416: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1411: $PREPARSER ./calc /dev/null stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) stderr: ./calc.at:1407: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1413: cat stderr input: ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1416: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1409: cat stderr input: ./calc.at:1408: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: input: stdout: | 1//2 ./calc.at:1413: $PREPARSER ./calc input ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) input: | (* *) + (*) + (*) ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1411: cat stderr stderr: | (!!) + (1 2) = 1 ./calc.at:1408: $PREPARSER ./calc input stderr: ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1414: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1409: $PREPARSER ./calc input input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 3333) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) | 1 2 ./calc.at:1416: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 128): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 128): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) input: stderr: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1414: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 3333) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1411: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: cat stderr ./calc.at:1409: cat stderr stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) | error ./calc.at:1413: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 2 ./calc.at:1414: $PREPARSER ./calc input stderr: ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) | (!!) + (1 2) = 1 ./calc.at:1409: $PREPARSER ./calc input ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 128): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: cat stderr ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 128): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | (- *) + (1 2) = 1 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1416: cat stderr ./calc.at:1408: $PREPARSER ./calc input stderr: stderr: ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1407: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 127): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) input: | (!!) + (1 2) = 1 ./calc.at:1411: $PREPARSER ./calc input input: ./calc.at:1409: cat stderr stderr: input: | 1//2 ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 14 Reducing stack 0 by rule 17 (line 122): $1 = token '!' (1.1: ) $2 = token '+' (1.1: ) Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1409: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 14 Reducing stack 0 by rule 17 (line 122): $1 = token '!' (1.1: ) $2 = token '+' (1.1: ) Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1414: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 127): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 127): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) | 1 + 2 * 3 + !- ++ ./calc.at:1407: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 127): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 13 Reducing stack 0 by rule 18 (line 123): $1 = token '!' (1.1: ) $2 = token '-' (1.1: ) Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | 1 = 2 = 3 ./calc.at:1408: cat stderr ./calc.at:1413: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 13 Reducing stack 0 by rule 18 (line 123): $1 = token '!' (1.1: ) $2 = token '-' (1.1: ) Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) stderr: | 1//2 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1414: $PREPARSER ./calc input ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (* *) + (*) + (*) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: cat stderr stderr: ./calc.at:1411: cat stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) stderr: ./calc.at:1416: cat stderr | (* *) + (*) + (*) ./calc.at:1409: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1407: cat stderr input: | 1 + 2 * 3 + !* ++ ./calc.at:1407: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 15 Reducing stack 0 by rule 19 (line 124): $1 = token '!' (1.1: ) $2 = token '*' (1.1: ) memory exhausted Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: input: ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error ./calc.at:1416: $PREPARSER ./calc input ./calc.at:1408: cat stderr ./calc.at:1413: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (- *) + (1 2) = 1 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 15 Reducing stack 0 by rule 19 (line 124): $1 = token '!' (1.1: ) $2 = token '*' (1.1: ) memory exhausted Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1411: $PREPARSER ./calc input ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) stderr: input: ./calc.at:1414: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 + 2 * 3 + !+ ++ Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | | +1 ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1413: $PREPARSER ./calc input ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 129): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) stderr: ./calc.at:1411: cat stderr ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1409: cat stderr input: | (* *) + (*) + (*) ./calc.at:1411: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1414: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 129): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: input: ./calc.at:1411: cat stderr Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !+ ++ ./calc.at:1409: $PREPARSER ./calc input input: | 1 + 2 * 3 + !+ ++ ./calc.at:1411: $PREPARSER ./calc input stderr: stderr: ./calc.at:1407: cat stderr | 1 + 2 * 3 + !- ++ stderr: ./calc.at:1408: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1416: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 129): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 130): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: | 1 = 2 = 3 input: ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1416: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 129): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (#) + (#) = 2222 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) input: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | 1 + 2 * 3 + !- ++ ./calc.at:1409: $PREPARSER ./calc input input: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) stderr: ./calc.at:1407: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ stderr: ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 130): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 130): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1414: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 130): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 2222) Shifting token "number" (1.1: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1413: cat stderr input: ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1413: $PREPARSER ./calc /dev/null | 1 = 2 = 3 stderr: ./calc.at:1414: $PREPARSER ./calc input stderr: ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 2222) Shifting token "number" (1.1: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1408: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: cat stderr input: | 1 + 2 * 3 + !* ++ ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 131): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 131): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: cat stderr | 1 + 2 * 3 + !* ++ ./calc.at:1409: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 131): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1407: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1411: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 131): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1408: cat stderr | | +1 ./calc.at:1416: $PREPARSER ./calc input input: | (1 + #) = 1111 ./calc.at:1407: $PREPARSER ./calc input stderr: stderr: ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Error: popping token '+' (1.1: ) Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1413: cat stderr input: ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1409: cat stderr | (#) + (#) = 2222 ./calc.at:1408: $PREPARSER ./calc input | 1 + 2 * 3 + !* ++ stderr: ./calc.at:1414: cat stderr ./calc.at:1411: $PREPARSER ./calc input stderr: stderr: ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Error: popping token '+' (1.1: ) Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1413: $PREPARSER ./calc input input: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | | +1 ./calc.at:1414: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) stderr: stderr: ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (#) + (#) = 2222 ./calc.at:1409: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1411: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: cat stderr ./calc.at:1408: cat stderr input: | (#) + (#) = 2222 ./calc.at:1411: $PREPARSER ./calc input ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1416: cat stderr ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) stderr: ./calc.at:1413: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: input: | (1 + #) = 1111 ./calc.at:1408: $PREPARSER ./calc input | (# + 1) = 1111 ./calc.at:1416: $PREPARSER ./calc /dev/null ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (!!) + (1 2) = 1 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: $PREPARSER ./calc input ./calc.at:1411: cat stderr Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1414: cat stderr stderr: ./calc.at:1409: cat stderr stderr: input: | (1 + #) = 1111 ./calc.at:1411: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: cat stderr ./calc.at:1414: $PREPARSER ./calc /dev/null ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + #) = 1111 stderr: stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1409: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (# + 1) = 1111 ./calc.at:1408: $PREPARSER ./calc input stderr: ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./calc.at:1432: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1411: cat stderr ./calc.at:1416: cat stderr ./calc.at:1407: cat stderr stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) input: | (# + 1) = 1111 input: ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1411: $PREPARSER ./calc input stderr: stderr: | (1 + # + 1) = 1111 ./calc.at:1407: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Error: popping token '+' (1.1: ) Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1409: cat stderr input: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1432: $PREPARSER ./calc input input: input: ./calc.at:1413: cat stderr stderr: ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: $PREPARSER ./calc input ./calc.at:1411: cat stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Error: popping token '+' (1.1: ) Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1432: $EGREP -c -v 'Return for a new token:|LAC:' stderr | (# + 1) = 1111 ./calc.at:1409: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1408: cat stderr input: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (- *) + (1 2) = 1 ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1414: cat stderr ./calc.at:1413: $PREPARSER ./calc input input: | (1 + # + 1) = 1111 ./calc.at:1411: $PREPARSER ./calc input | 1 2 ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1432: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.3: syntax error stderr: ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (1 + # + 1) = 1111 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: cat stderr ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: cat stderr stderr: input: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.3: syntax error input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1414: $PREPARSER ./calc input ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + 1) / (1 - 1) ./calc.at:1407: $PREPARSER ./calc input | (1 + # + 1) = 1111 ./calc.at:1409: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 2) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 2) Entering state 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 29 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 0) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 0) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 0) Entering state 32 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 10 (line 101): $1 = nterm exp (1.1: 2) $2 = token '/' (1.1: ) $3 = nterm exp (1.1: 0) error: null divisor -> $$ = nterm exp (1.1: 2) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 2) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 2) Entering state 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 29 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 0) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 0) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 0) Entering state 32 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 10 (line 101): $1 = nterm exp (1.1: 2) $2 = token '/' (1.1: ) $3 = nterm exp (1.1: 0) error: null divisor -> $$ = nterm exp (1.1: 2) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: ./calc.at:1432: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1411: $PREPARSER ./calc input stderr: ./calc.at:1413: cat stderr ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1416: cat stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1432: $PREPARSER ./calc input ./calc.at:1409: cat stderr ./calc.at:1414: cat stderr ./calc.at:1408: cat stderr | (* *) + (*) + (*) ./calc.at:1407: cat stderr stderr: ./calc.at:1413: $PREPARSER ./calc input stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + 1) / (1 - 1) ./calc.at:1409: $PREPARSER ./calc input input: stderr: stderr: 515. calc.at:1407: ok 1.3: syntax error | (!!) + (1 2) = 1 input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 108): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1416: $PREPARSER ./calc input ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + 1) / (1 - 1) ./calc.at:1408: $PREPARSER ./calc input stderr: input: ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 108): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (!!) + (1 2) = 1 ./calc.at:1414: $PREPARSER ./calc input ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 108): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 108): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1432: cat stderr ./calc.at:1413: cat stderr ./calc.at:1411: cat stderr ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !+ ++ ./calc.at:1413: $PREPARSER ./calc input input: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 518. calc.at:1411: ok | error ./calc.at:1432: $PREPARSER ./calc input ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1408: cat stderr stderr: ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: cat stderr ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 516. calc.at:1408: ok 1.1: syntax error ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1413: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) 517. calc.at:1409: 1.1: syntax error ok Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 527. calc.at:1435: testing Calculator C++ %header %locations parse.error=verbose %name-prefix "calc" %verbose ... ./calc.at:1435: mv calc.y.tmp calc.y ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1416: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1435: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y 528. calc.at:1437: testing Calculator C++ %locations parse.error=verbose api.prefix={calc} %verbose ... ./calc.at:1437: mv calc.y.tmp calc.y ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1413: cat stderr stderr: stdout: ./calc.at:1433: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1414: cat stderr | (- *) + (1 2) = 1 input: ./calc.at:1416: $PREPARSER ./calc input input: | 1 + 2 * 3 + !* ++ ./calc.at:1432: cat stderr stderr: ./calc.at:1413: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1433: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1433: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: | 1 2 ./calc.at:1433: $PREPARSER ./calc input ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1435: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS | 1 = 2 = 3 ./calc.at:1432: $PREPARSER ./calc input 1.3: syntax error ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.3: syntax error 1.7: syntax error input: ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (- *) + (1 2) = 1 stderr: ./calc.at:1414: $PREPARSER ./calc input 529. calc.at:1438: testing Calculator C++ %locations parse.error=verbose %debug %name-prefix "calc" %verbose ... 1.7: syntax error stderr: ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: mv calc.y.tmp calc.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1437: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS 530. calc.at:1440: testing Calculator C++ %locations parse.error=verbose %debug api.prefix={calc} %verbose ... ./calc.at:1440: mv calc.y.tmp calc.y ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1413: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: cat stderr ./calc.at:1416: cat stderr ./calc.at:1433: cat stderr ./calc.at:1414: cat stderr input: | (#) + (#) = 2222 ./calc.at:1413: $PREPARSER ./calc input input: | (* *) + (*) + (*) ./calc.at:1414: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | (* *) + (*) + (*) ./calc.at:1416: $PREPARSER ./calc input input: input: ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1//2 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1433: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | | +1 ./calc.at:1432: $PREPARSER ./calc input stderr: stderr: 1.3: syntax error ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1440: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 2.1: syntax error ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.3: syntax error Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1438: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS 2.1: syntax error ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stdout: ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1431: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1414: cat stderr input: ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !+ ++ ./calc.at:1414: $PREPARSER ./calc input input: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1413: cat stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1431: $PREPARSER ./calc input ./calc.at:1433: cat stderr ./calc.at:1416: cat stderr ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1432: cat stderr | error ./calc.at:1433: $PREPARSER ./calc input ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1432: $PREPARSER ./calc /dev/null stderr: 1.1: syntax error ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (1 + #) = 1111 ./calc.at:1413: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: | 1 + 2 * 3 + !+ ++ ./calc.at:1416: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: input: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | 1 + 2 * 3 + !- ++ ./calc.at:1414: $PREPARSER ./calc input ./calc.at:1431: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error stderr: ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: | 1 + 2 * 3 + !- ++ ./calc.at:1416: $PREPARSER ./calc input stderr: ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1432: cat stderr stdout: ./calc.at:1434: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc input: stderr: ./calc.at:1413: cat stderr ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1432: $PREPARSER ./calc input | 1 2 ./calc.at:1431: $PREPARSER ./calc input 1.1: syntax error stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1434: $PREPARSER ./calc input 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1416: cat stderr stderr: stderr: ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 input: stderr: ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error input: | 1 + 2 * 3 + !* ++ ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: $PREPARSER ./calc input ./calc.at:1434: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: | (# + 1) = 1111 ./calc.at:1413: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: syntax error stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: cat stderr input: ./calc.at:1414: cat stderr ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1434: $PREPARSER ./calc input stderr: ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1433: cat stderr input: | 1 + 2 * 3 + !* ++ ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: $PREPARSER ./calc input ./calc.at:1416: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.3: syntax error | (!!) + (1 2) = 1 input: ./calc.at:1432: $PREPARSER ./calc input stderr: ./calc.at:1431: cat stderr | (#) + (#) = 2222 ./calc.at:1416: $PREPARSER ./calc input ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: stderr: ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 = 2 = 3 ./calc.at:1433: $PREPARSER ./calc input 1.11: syntax error 1.1-16: error: 2222 != 1 stderr: 1.3: syntax error ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1//2 ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1413: cat stderr ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: $PREPARSER ./calc input 1.7: syntax error ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: ./calc.at:1414: cat stderr ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11: syntax error 1.1-16: error: 2222 != 1 stderr: 1.7: syntax error | (1 + # + 1) = 1111 syntax error ./calc.at:1413: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1434: cat stderr ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: stderr: | (#) + (#) = 2222 ./calc.at:1414: $PREPARSER ./calc input | 1//2 ./calc.at:1434: $PREPARSER ./calc input stdout: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1416: cat stderr ./calc.at:1426: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1433: cat stderr ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 stderr: ./calc.at:1416: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: cat stderr input: 1.3: syntax error | | +1 input: ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1433: $PREPARSER ./calc input ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1426: $PREPARSER ./calc input stderr: stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1431: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1432: cat stderr ./calc.at:1413: $PREPARSER ./calc input 1.3: syntax error ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1426: $EGREP -c -v 'Return for a new token:|LAC:' stderr 2.1: syntax error ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: | (- *) + (1 2) = 1 2.1: syntax error ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: $PREPARSER ./calc input ./calc.at:1434: cat stderr input: input: ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error | 1 2 ./calc.at:1426: $PREPARSER ./calc input ./calc.at:1431: $PREPARSER ./calc input ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: cat stderr stderr: stderr: stderr: ./calc.at:1413: cat stderr 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 input: syntax error ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1414: cat stderr ./calc.at:1434: $PREPARSER ./calc input ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 519. calc.at:1413: ok syntax error ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error stderr: 1.1: syntax error | (# + 1) = 1111 ./calc.at:1416: $PREPARSER ./calc input ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error input: stderr: | (1 + #) = 1111 ./calc.at:1433: cat stderr ./calc.at:1414: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1433: $PREPARSER ./calc /dev/null stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error ./calc.at:1416: cat stderr 1.1: syntax error ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + # + 1) = 1111 ./calc.at:1416: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.1: syntax error ./calc.at:1432: cat stderr ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1426: cat stderr stderr: ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: cat stderr 531. calc.at:1441: testing Calculator C++ %locations parse.error=verbose %debug api.prefix={calc} api.token.prefix={TOK_} %verbose ... ./calc.at:1441: mv calc.y.tmp calc.y ./calc.at:1441: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (# + 1) = 1111 ./calc.at:1414: $PREPARSER ./calc input stderr: ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1426: $PREPARSER ./calc input stderr: input: ./calc.at:1433: cat stderr | (* *) + (*) + (*) syntax error ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1432: $PREPARSER ./calc input stderr: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1433: $PREPARSER ./calc input 1.2: syntax error 1.10: syntax error 1.16: syntax error Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: cat stderr stderr: ./calc.at:1434: cat stderr 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error syntax error ./calc.at:1414: cat stderr ./calc.at:1441: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + # + 1) = 1111 ./calc.at:1414: $PREPARSER ./calc input stderr: ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: cat stderr | 1 = 2 = 3 input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1434: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1416: cat stderr 1.7: syntax error ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1426: cat stderr stderr: syntax error 1.7: syntax error ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | (1 + 1) / (1 - 1) ./calc.at:1416: $PREPARSER ./calc input ./calc.at:1433: cat stderr stderr: ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: | 1 + 2 * 3 + !+ ++ ./calc.at:1432: $PREPARSER ./calc input syntax error | error ./calc.at:1414: cat stderr input: ./calc.at:1426: $PREPARSER ./calc input stderr: ./calc.at:1434: cat stderr | (!!) + (1 2) = 1 ./calc.at:1433: $PREPARSER ./calc input stderr: ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1432: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: 1.11: syntax error 1.1-16: error: 2222 != 1 | | +1 ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: $PREPARSER ./calc input | (1 + 1) / (1 - 1) ./calc.at:1414: $PREPARSER ./calc input stderr: syntax error ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 2.1: syntax error stderr: ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1416: cat stderr input: | 1 + 2 * 3 + !- ++ ./calc.at:1432: $PREPARSER ./calc input ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 2.1: syntax error 521. calc.at:1416: ok ./calc.at:1431: cat stderr ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1426: cat stderr ./calc.at:1433: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: input: | | +1 | (- *) + (1 2) = 1 ./calc.at:1433: $PREPARSER ./calc input input: ./calc.at:1431: $PREPARSER ./calc input | 1 = 2 = 3 stderr: ./calc.at:1426: $PREPARSER ./calc input ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: ./calc.at:1414: cat stderr 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 syntax error ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error syntax error ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 520. calc.at:1414: ok stderr: ./calc.at:1434: cat stderr ./calc.at:1433: cat stderr syntax error ./calc.at:1432: cat stderr ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1434: $PREPARSER ./calc /dev/null input: | (* *) + (*) + (*) ./calc.at:1433: $PREPARSER ./calc input input: 532. calc.at:1443: testing Calculator C++ %header %locations parse.error=verbose %debug %name-prefix "calc" %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1443: mv calc.y.tmp calc.y ./calc.at:1443: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y | (#) + (#) = 2222 stderr: stderr: ./calc.at:1432: $PREPARSER ./calc input 1.1: syntax error 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.1: syntax error ./calc.at:1431: cat stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1426: cat stderr stderr: ./calc.at:1443: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' 533. calc.at:1445: testing Calculator C++ parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1445: mv calc.y.tmp calc.y ./calc.at:1445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1431: $PREPARSER ./calc /dev/null stderr: ./calc.at:1434: cat stderr syntax error input: ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | | +1 stderr: ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1434: $PREPARSER ./calc input syntax error ./calc.at:1426: $PREPARSER ./calc input stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1433: cat stderr ./calc.at:1432: cat stderr ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !+ ++ ./calc.at:1433: $PREPARSER ./calc input ./calc.at:1445: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS input: ./calc.at:1426: cat stderr stderr: | (1 + #) = 1111 ./calc.at:1432: $PREPARSER ./calc input ./calc.at:1431: cat stderr ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: cat stderr ./calc.at:1426: $PREPARSER ./calc /dev/null stderr: ./calc.at:1433: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: input: stderr: 1.6: syntax error: invalid character: '#' | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1431: $PREPARSER ./calc input syntax error ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (!!) + (1 2) = 1 stderr: ./calc.at:1434: $PREPARSER ./calc input syntax error syntax error syntax error syntax error error: 4444 != 1 stderr: ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error input: stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1433: $PREPARSER ./calc input 1.11: syntax error 1.1-16: error: 2222 != 1 stderr: ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11: syntax error 1.1-16: error: 2222 != 1 stderr: ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error syntax error syntax error syntax error error: 4444 != 1 stderr: ./calc.at:1432: cat stderr ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1426: cat stderr ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (# + 1) = 1111 ./calc.at:1432: $PREPARSER ./calc input stderr: ./calc.at:1434: cat stderr 1.2: syntax error: invalid character: '#' ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1433: cat stderr ./calc.at:1431: cat stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1426: $PREPARSER ./calc input input: | (- *) + (1 2) = 1 ./calc.at:1434: $PREPARSER ./calc input stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (#) + (#) = 2222 input: ./calc.at:1433: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' stderr: | (!!) + (1 2) = 1 ./calc.at:1431: $PREPARSER ./calc input 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 stderr: stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error error: 2222 != 1 ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error error: 2222 != 1 ./calc.at:1432: cat stderr stderr: ./calc.at:1434: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + # + 1) = 1111 ./calc.at:1432: $PREPARSER ./calc input input: | (* *) + (*) + (*) stderr: ./calc.at:1434: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' ./calc.at:1431: cat stderr ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1426: cat stderr ./calc.at:1433: cat stderr input: stderr: 1.6: syntax error: invalid character: '#' 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 ./calc.at:1426: $PREPARSER ./calc input input: | (- *) + (1 2) = 1 ./calc.at:1431: $PREPARSER ./calc input stderr: stderr: syntax error syntax error error: 2222 != 1 stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error syntax error error: 2222 != 1 ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error error: 2222 != 1 input: | (1 + #) = 1111 ./calc.at:1433: $PREPARSER ./calc input ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.6: syntax error: invalid character: '#' ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error error: 2222 != 1 ./calc.at:1434: cat stderr stderr: 1.6: syntax error: invalid character: '#' input: ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !+ ++ ./calc.at:1434: $PREPARSER ./calc input ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1432: cat stderr stderr: ./calc.at:1434: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1433: cat stderr input: | (1 + 1) / (1 - 1) ./calc.at:1432: $PREPARSER ./calc input ./calc.at:1431: cat stderr ./calc.at:1426: cat stderr input: | 1 + 2 * 3 + !- ++ ./calc.at:1434: $PREPARSER ./calc input input: input: input: | (* *) + (*) + (*) | (- *) + (1 2) = 1 stderr: ./calc.at:1431: $PREPARSER ./calc input stderr: | (# + 1) = 1111 ./calc.at:1426: $PREPARSER ./calc input ./calc.at:1433: $PREPARSER ./calc input stderr: stderr: ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error error: 2222 != 1 ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error syntax error ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor stderr: stderr: ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error syntax error 1.2: syntax error: invalid character: '#' ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error error: 2222 != 1 1.11-17: error: null divisor stderr: ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1431: cat stderr ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: cat stderr ./calc.at:1426: cat stderr ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | 1 + 2 * 3 + !+ ++ ./calc.at:1434: cat stderr ./calc.at:1431: $PREPARSER ./calc input | (* *) + (*) + (*) ./calc.at:1426: $PREPARSER ./calc input stderr: stderr: syntax error syntax error syntax error 524. calc.at:1432: ok ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1433: cat stderr stderr: syntax error syntax error syntax error stderr: ./calc.at:1431: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: input: | (#) + (#) = 2222 ./calc.at:1434: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ ./calc.at:1431: $PREPARSER ./calc input stderr: stderr: ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1426: cat stderr stderr: input: input: | (1 + # + 1) = 1111 ./calc.at:1433: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1426: $PREPARSER ./calc input ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1431: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1426: $EGREP -c -v 'Return for a new token:|LAC:' stderr 534. calc.at:1446: testing Calculator C++ %header %locations parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1446: mv calc.y.tmp calc.y input: | (#) + (#) = 2222 ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1431: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' input: ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1426: $PREPARSER ./calc input ./calc.at:1434: cat stderr stderr: ./calc.at:1446: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1433: cat stderr input: stderr: | (1 + 1) / (1 - 1) ./calc.at:1433: $PREPARSER ./calc input stderr: stdout: ./calc.at:1437: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: input: 1.11-17: error: null divisor ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1437: $PREPARSER ./calc input | (1 + #) = 1111 ./calc.at:1434: $PREPARSER ./calc input stderr: ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: ./calc.at:1437: $EGREP -c -v 'Return for a new token:|LAC:' stderr 1.11-17: error: null divisor ./calc.at:1446: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS input: 1.6: syntax error: invalid character: '#' ./calc.at:1431: cat stderr | 1 2 ./calc.at:1437: $PREPARSER ./calc input ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.6: syntax error: invalid character: '#' 1.3: syntax error, unexpected number ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error, unexpected number ./calc.at:1426: cat stderr ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | (1 + #) = 1111 ./calc.at:1431: $PREPARSER ./calc input ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (#) + (#) = 2222 syntax error: invalid character: '#' ./calc.at:1426: $PREPARSER ./calc input stderr: ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: cat stderr ./calc.at:1433: cat stderr ./calc.at:1437: cat stderr stderr: stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' syntax error: invalid character: '#' input: | (# + 1) = 1111 ./calc.at:1434: $PREPARSER ./calc input 525. calc.at:1433: ok stderr: input: 1.2: syntax error: invalid character: '#' ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' stderr: ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1426: cat stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: cat stderr 535. calc.at:1448: testing Calculator C++ %header %locations api.location.file=none ... ./calc.at:1448: mv calc.y.tmp calc.y input: ./calc.at:1431: cat stderr | (1 + #) = 1111 ./calc.at:1426: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1448: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: ./calc.at:1434: cat stderr input: syntax error: invalid character: '#' ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error input: | (# + 1) = 1111 input: ./calc.at:1426: cat stderr | (1 + # + 1) = 1111 ./calc.at:1434: $PREPARSER ./calc input ./calc.at:1437: $PREPARSER ./calc input ./calc.at:1431: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error, unexpected invalid token ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stdout: ./calc.at:1440: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc syntax error: invalid character: '#' ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' stderr: | (# + 1) = 1111 ./calc.at:1426: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1448: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS 1.1: syntax error, unexpected invalid token input: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1440: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1437: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1440: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1434: cat stderr input: | 1 = 2 = 3 ./calc.at:1437: $PREPARSER ./calc input input: | 1 2 ./calc.at:1440: $PREPARSER ./calc input stderr: ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: cat stderr stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1426: cat stderr | (1 + # + 1) = 1111 ./calc.at:1431: $PREPARSER ./calc input stderr: stderr: 1.7: syntax error, unexpected '=' input: ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1440: cat stderr syntax error: invalid character: '#' ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (1 + # + 1) = 1111 ./calc.at:1426: $PREPARSER ./calc input | (1 + 1) / (1 - 1) 1.7: syntax error, unexpected '=' ./calc.at:1434: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' stderr: ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.11-17: error: null divisor ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' | 1//2 stderr: ./calc.at:1440: $PREPARSER ./calc input syntax error: invalid character: '#' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1431: cat stderr stderr: ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11-17: error: null divisor input: ./calc.at:1440: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1431: $PREPARSER ./calc input stderr: error: null divisor ./calc.at:1437: cat stderr ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: error: null divisor ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | error ./calc.at:1426: cat stderr ./calc.at:1440: $PREPARSER ./calc input ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: cat stderr | | +1 stderr: ./calc.at:1437: $PREPARSER ./calc input stderr: ./calc.at:1434: cat stderr stdout: ./calc.at:1438: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc 523. calc.at:1431: ok input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 | (1 + 1) / (1 - 1) ./calc.at:1426: $PREPARSER ./calc input input: 2.1: syntax error, unexpected '+' ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 526. calc.at:1434: ok error: null divisor ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: null divisor | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1438: $PREPARSER ./calc input ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 2.1: syntax error, unexpected '+' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1438: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1440: cat stderr ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1426: cat stderr ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: input: ./calc.at:1437: cat stderr | 1 = 2 = 3 ./calc.at:1441: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1440: $PREPARSER ./calc input input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 | 1 2 ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1441: $PREPARSER ./calc input stderr: 522. calc.at:1426: ok ./calc.at:1438: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1437: $PREPARSER ./calc /dev/null 536. calc.at:1449: testing Calculator C++ %header %locations api.location.file="my-location.hh" ... stderr: 1.1: syntax error, unexpected end of input ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 stderr: ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error, unexpected end of input ./calc.at:1449: mv calc.y.tmp calc.y stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 stderr: ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1449: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1441: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1437: cat stderr 537. calc.at:1451: testing Calculator C++ %no-lines %header %locations api.location.file="my-location.hh" ... ./calc.at:1440: cat stderr ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1451: mv calc.y.tmp calc.y | 1 2 ./calc.at:1441: $PREPARSER ./calc input input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 538. calc.at:1453: testing Calculator C++ %locations parse.lac=full parse.error=verbose ... ./calc.at:1453: mv calc.y.tmp calc.y ./calc.at:1437: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 input: ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1438: cat stderr | | +1 ./calc.at:1440: $PREPARSER ./calc input ./calc.at:1453: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1451: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1//2 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1438: $PREPARSER ./calc input ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1449: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 stdout: ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1435: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: cat stderr ./calc.at:1441: cat stderr input: ./calc.at:1438: cat stderr ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1435: $PREPARSER ./calc input input: | 1//2 ./calc.at:1441: $PREPARSER ./calc input stderr: input: ./calc.at:1451: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS ./calc.at:1453: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1440: cat stderr | (!!) + (1 2) = 1 ./calc.at:1437: $PREPARSER ./calc input input: | error stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1438: $PREPARSER ./calc input stderr: stderr: ./calc.at:1440: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 stderr: ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1441: cat stderr stderr: ./calc.at:1435: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 | error ./calc.at:1441: $PREPARSER ./calc input input: stderr: ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 ./calc.at:1435: $PREPARSER ./calc input ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1438: cat stderr stderr: 1.3: syntax error, unexpected number ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1437: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 input: stderr: ./calc.at:1440: cat stderr | 1 = 2 = 3 ./calc.at:1438: $PREPARSER ./calc input 1.3: syntax error, unexpected number stderr: input: ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1441: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1437: $PREPARSER ./calc input stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 stderr: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1440: $PREPARSER ./calc input input: ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 ./calc.at:1441: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1435: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of inpStarting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ut (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1438: cat stderr 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 input: ./calc.at:1438: $PREPARSER ./calc input | 1//2 ./calc.at:1435: $PREPARSER ./calc input stderr: ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1441: cat stderr ./calc.at:1437: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1440: cat stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (* *) + (*) + (*) ./calc.at:1437: $PREPARSER ./calc input stderr: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: ./calc.at:1437: cat stderr input: | | +1 ./calc.at:1441: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1437: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 ./calc.at:1440: $PREPARSER ./calc input ./calc.at:1438: cat stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' stderr: ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1437: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: ./calc.at:1438: $PREPARSER ./calc /dev/null ./calc.at:1445: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 input: | 1 + 2 * 3 + !- ++ ./calc.at:1437: $PREPARSER ./calc input stderr: ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1435: cat stderr input: | error ./calc.at:1435: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1440: cat stderr ./calc.at:1445: $PREPARSER ./calc input ./calc.at:1441: cat stderr stderr: 1.1: syntax error, unexpected invalid token stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' () Reducing stack by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' () Reducing stack by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' () Reducing stack by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' () Reducing stack by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' () Reducing stack by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 ./calc.at:1441: $PREPARSER ./calc /dev/null ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 input: stderr: ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1440: $PREPARSER ./calc input 1.1: syntax error, unexpected invalid token ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1437: cat stderr ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1435: cat stderr ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 = 2 = 3 ./calc.at:1435: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' () Reducing stack by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' () Reducing stack by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' () Reducing stack by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' () Reducing stack by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' () Reducing stack by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: 1.7: syntax error, unexpected '=' ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: stderr: | (#) + (#) = 2222 ./calc.at:1437: $PREPARSER ./calc input stderr: 1.7: syntax error, unexpected '=' 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1441: cat stderr ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: cat stderr input: ./calc.at:1440: cat stderr ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1437: cat stderr | 1 2 ./calc.at:1445: $PREPARSER ./calc input ./calc.at:1435: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1438: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Stack now 0 Cleanup: discarding lookahead token number (2) Stack now 0 ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: stderr: stderr: | | +1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1435: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Stack now 0 Cleanup: discarding lookahead token number (2) Stack now 0 ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (* *) + (*) + (*) 2.1: syntax error, unexpected '+' ./calc.at:1440: $PREPARSER ./calc input input: ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1441: $PREPARSER ./calc input | (1 + #) = 1111 ./calc.at:1437: $PREPARSER ./calc input stderr: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 2.1: syntax error, unexpected '+' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.6: syntax error: invalid character: '#' ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1440: cat stderr input: | 1 + 2 * 3 + !+ ++ ./calc.at:1440: $PREPARSER ./calc input ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: cat stderr ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1441: cat stderr input: ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1438: cat stderr | 1//2 ./calc.at:1445: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Stack now 0 8 Error: popping nterm exp (1) Stack now 0 Cleanup: discarding lookahead token '/' () Stack now 0 ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Stack now 0 8 Error: popping nterm exp (1) Stack now 0 Cleanup: discarding lookahead token '/' () Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1440: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1435: $PREPARSER ./calc /dev/null ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: cat stderr stderr: 1.1: syntax error, unexpected end of input ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !- ++ ./calc.at:1440: $PREPARSER ./calc input input: stderr: stderr: 1.1: syntax error, unexpected end of input ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (!!) + (1 2) = 1 ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1438: $PREPARSER ./calc input | (!!) + (1 2) = 1 stderr: ./calc.at:1445: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1441: $PREPARSER ./calc input ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1440: cat stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 stderr: ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1437: $PREPARSER ./calc input | (#) + (#) = 2222 ./calc.at:1440: $PREPARSER ./calc input input: | error stderr: ./calc.at:1445: $PREPARSER ./calc input ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1435: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: 1.2: syntax error: invalid character: '#' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () Stack now 0 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1441: cat stderr ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' ./calc.at:1435: cat stderr ./calc.at:1438: cat stderr ./calc.at:1440: cat stderr ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | (- *) + (1 2) = 1 ./calc.at:1441: $PREPARSER ./calc input | (!!) + (1 2) = 1 ./calc.at:1435: $PREPARSER ./calc input stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (- *) + (1 2) = 1 ./calc.at:1438: $PREPARSER ./calc input input: ./calc.at:1445: cat stderr | (1 + #) = 1111 stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1440: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1437: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 ./calc.at:1445: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1441: cat stderr input: ./calc.at:1435: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Stack now 0 8 18 Error: popping token '=' () Stack now 0 8 Error: popping nterm exp (1) Stack now 0 Cleanup: discarding lookahead token '=' () Stack now 0 ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: cat stderr ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + # + 1) = 1111 ./calc.at:1437: $PREPARSER ./calc input ./calc.at:1440: cat stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | (* *) + (*) + (*) | (* *) + (*) + (*) ./calc.at:1441: $PREPARSER ./calc input ./calc.at:1438: $PREPARSER ./calc input stderr: | (- *) + (1 2) = 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1435: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: | (# + 1) = 1111 stderr: ./calc.at:1440: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.6: syntax error: invalid character: '#' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Stack now 0 8 18 Error: popping token '=' () Stack now 0 8 Error: popping nterm exp (1) Stack now 0 Cleanup: discarding lookahead token '=' () Stack now 0 stderr: ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: cat stderr 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1445: cat stderr ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1437: cat stderr input: | | +1 ./calc.at:1445: $PREPARSER ./calc input input: ./calc.at:1441: cat stderr stderr: | 1 + 2 * 3 + !+ ++ Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Stack now 0 Cleanup: discarding lookahead token '+' () Stack now 0 ./calc.at:1438: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + 1) / (1 - 1) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1437: $PREPARSER ./calc input input: ./calc.at:1438: $EGREP -c -v 'Return for a new token:|LAC:' stderr | 1 + 2 * 3 + !+ ++ stderr: ./calc.at:1441: $PREPARSER ./calc input 1.11-17: error: null divisor ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: cat stderr stderr: 1.11-17: error: null divisor stderr: input: stderr: | 1 + 2 * 3 + !- ++ Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1438: $PREPARSER ./calc input ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Stack now 0 Cleanup: discarding lookahead token '+' () Stack now 0 stderr: stderr: | (* *) + (*) + (*) ./calc.at:1435: $PREPARSER ./calc input stderr: ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1441: $EGREP -c -v 'Return for a new token:|LAC:' stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1440: cat stderr ./calc.at:1437: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1445: cat stderr input: | (1 + # + 1) = 1111 ./calc.at:1440: $PREPARSER ./calc input ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 528. calc.at:1437: ok ./calc.at:1438: cat stderr ./calc.at:1435: cat stderr | 1 + 2 * 3 + !- ++ ./calc.at:1441: $PREPARSER ./calc input ./calc.at:1445: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input () syntax error, unexpected end of input Cleanup: discarding lookahead token end of input () Stack now 0 stderr: input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | 1 + 2 * 3 + !+ ++ ./calc.at:1435: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1438: $PREPARSER ./calc input stderr: stderr: stderr: stdout: ./calc.at:1443: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1443: $PREPARSER ./calc input ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1435: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input () syntax error, unexpected end of input Cleanup: discarding lookahead token end of input () Stack now 0 ./calc.at:1440: cat stderr stderr: ./calc.at:1441: cat stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1443: $EGREP -c -v 'Return for a new token:|LAC:' stderr | 1 + 2 * 3 + !- ++ ./calc.at:1435: $PREPARSER ./calc input ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 539. calc.at:1454: testing Calculator C++ %locations parse.lac=full parse.error=detailed ... ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1438: cat stderr | (1 + 1) / (1 - 1) stderr: ./calc.at:1440: $PREPARSER ./calc input input: input: input: | (#) + (#) = 2222 ./calc.at:1441: $PREPARSER ./calc input | 1 2 ./calc.at:1443: $PREPARSER ./calc input stderr: ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 ./calc.at:1454: mv calc.y.tmp calc.y ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1454: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: cat stderr stderr: stderr: ./calc.at:1445: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 input: ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: $PREPARSER ./calc input ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1454: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: ./calc.at:1440: cat stderr ./calc.at:1441: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Stack now 0 8 20 4 12 Error: popping nterm exp (3) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' () Reducing stack by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Stack now 0 8 20 4 12 Error: popping nterm exp (2) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () input: ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (#) + (#) = 2222 ./calc.at:1435: $PREPARSER ./calc input ./calc.at:1443: cat stderr stderr: ./calc.at:1438: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' input: ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 530. calc.at:1440: ok | (1 + #) = 1111 ./calc.at:1441: $PREPARSER ./calc input stderr: stderr: | 1//2 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1443: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' input: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 | (# + 1) = 1111 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Stack now 0 8 20 4 12 Error: popping nterm exp (3) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' () Reducing stack by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Stack now 0 8 20 4 12 Error: popping nterm exp (2) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1438: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1435: cat stderr stderr: ./calc.at:1441: cat stderr ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1443: cat stderr ./calc.at:1445: cat stderr input: | error ./calc.at:1443: $PREPARSER ./calc input 540. calc.at:1455: testing Calculator C++ %locations parse.lac=full parse.error=detailed parse.trace ... ./calc.at:1455: mv calc.y.tmp calc.y stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1455: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1435: $PREPARSER ./calc input stderr: input: 1.6: syntax error: invalid character: '#' ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1438: cat stderr | (# + 1) = 1111 ./calc.at:1441: $PREPARSER ./calc input | (!!) + (1 2) = 1 stderr: ./calc.at:1445: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token number (2) Error: discarding token number (2) Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1435: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token number (2) Error: discarding token number (2) Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () | (1 + # + 1) = 1111 ./calc.at:1455: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1438: $PREPARSER ./calc input stderr: ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1441: cat stderr input: ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (# + 1) = 1111 ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1435: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1443: cat stderr input: | (1 + # + 1) = 1111 ./calc.at:1441: $PREPARSER ./calc input ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1445: cat stderr ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1438: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | 1 = 2 = 3 ./calc.at:1443: $PREPARSER ./calc input input: | (1 + 1) / (1 - 1) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1438: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (- *) + (1 2) = 1 ./calc.at:1438: cat stderr ./calc.at:1445: $PREPARSER ./calc input stderr: ./calc.at:1441: cat stderr 529. calc.at:1438: ok Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' () $2 = token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token number (2) Error: discarding token number (2) Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1435: cat stderr stderr: | (1 + 1) / (1 - 1) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' () $2 = token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token number (2) Error: discarding token number (2) Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1441: $PREPARSER ./calc input stderr: stderr: ./calc.at:1443: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | (1 + # + 1) = 1111 ./calc.at:1435: $PREPARSER ./calc input stdout: ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1453: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc 1.6: syntax error: invalid character: '#' ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 1.6: syntax error: invalid character: '#' | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1453: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | | +1 ./calc.at:1443: $PREPARSER ./calc input ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 stderr: ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1445: cat stderr ./calc.at:1435: cat stderr stderr: ./calc.at:1453: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + 1) / (1 - 1) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1435: $PREPARSER ./calc input 541. calc.at:1457: testing Calculator C++ parse.error=custom ... ./calc.at:1457: mv calc.y.tmp calc.y ./calc.at:1457: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1441: cat stderr stderr: input: 531. calc.at:1441: ok 1.11-17: error: null divisor ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) ./calc.at:1445: $PREPARSER ./calc input input: ./calc.at:1457: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS | 1 2 ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.11-17: error: null divisor ./calc.at:1453: $PREPARSER ./calc input stderr: ./calc.at:1443: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' () Reducing stack by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1443: $PREPARSER ./calc /dev/null stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 1.3: syntax error, unexpected number ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1435: cat stderr stderr: ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: cat stderr 1.3: syntax error, unexpected number Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' () Reducing stack by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1443: $PREPARSER ./calc input stderr: 527. calc.at:1435: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ok ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1453: cat stderr 542. calc.at:1458: testing Calculator C++ parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1458: mv calc.y.tmp calc.y ./calc.at:1458: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: cat stderr input: | 1//2 ./calc.at:1453: $PREPARSER ./calc input ./calc.at:1445: cat stderr stderr: input: | (!!) + (1 2) = 1 ./calc.at:1443: $PREPARSER ./calc input stderr: stdout: stderr: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1448: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh stderr: input: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' | 1 + 2 * 3 + !+ ++ ./calc.at:1445: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Stack now 0 8 20 Cleanup: popping token '+' () Cleanup: popping nterm exp (7) | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1448: $PREPARSER ./calc input ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stdout: ./calc.at:1458: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: 543. calc.at:1459: testing Calculator C++ parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} parse.lac=full ... ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1459: mv calc.y.tmp calc.y stderr: ./calc.at:1448: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1459: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Stack now 0 8 20 Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1445: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1453: cat stderr ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | 1 2 ./calc.at:1448: $PREPARSER ./calc input input: ./calc.at:1443: cat stderr | error ./calc.at:1453: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1446: $PREPARSER ./calc input stderr: stderr: 1.1: syntax error, unexpected invalid token 1.3: syntax error ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (- *) + (1 2) = 1 ./calc.at:1443: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ ./calc.at:1445: $PREPARSER ./calc input stderr: stderr: 1.3: syntax error stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Stack now 0 8 20 Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1459: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS 1.1: syntax error, unexpected invalid token ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1446: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: ./calc.at:1448: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Stack now 0 8 20 Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1453: cat stderr ./calc.at:1443: cat stderr input: | 1 2 ./calc.at:1446: $PREPARSER ./calc input stderr: | 1//2 ./calc.at:1448: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 input: input: | (* *) + (*) + (*) | 1 = 2 = 3 ./calc.at:1443: $PREPARSER ./calc input ./calc.at:1453: $PREPARSER ./calc input stderr: ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.7: syntax error, unexpected '=' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.7: syntax error, unexpected '=' stderr: ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1445: cat stderr ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1453: cat stderr | (#) + (#) = 2222 ./calc.at:1445: $PREPARSER ./calc input ./calc.at:1448: cat stderr ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1443: cat stderr input: stdout: ./calc.at:1449: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1446: cat stderr input: stderr: input: | error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1448: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1449: $PREPARSER ./calc input input: | 1//2 ./calc.at:1446: $PREPARSER ./calc input ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: | | +1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error stderr: ./calc.at:1453: $PREPARSER ./calc input ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1449: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 stderr: input: | 1 + 2 * 3 + !+ ++ ./calc.at:1443: $PREPARSER ./calc input stderr: 1.1: syntax error 2.1: syntax error, unexpected '+' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 2.1: syntax error, unexpected '+' stderr: ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | 1 2 ./calc.at:1449: $PREPARSER ./calc input ./calc.at:1448: cat stderr stderr: ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) 1.3: syntax error ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 = 2 = 3 ./calc.at:1448: $PREPARSER ./calc input ./calc.at:1443: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: stderr: 1.3: syntax error 1.7: syntax error ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.7: syntax error ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: cat stderr input: ./calc.at:1446: cat stderr ./calc.at:1453: cat stderr ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !- ++ ./calc.at:1443: $PREPARSER ./calc input | error ./calc.at:1446: $PREPARSER ./calc input ./calc.at:1453: $PREPARSER ./calc /dev/null stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1449: cat stderr input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (1 + #) = 1111 ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error, unexpected end of input ./calc.at:1445: $PREPARSER ./calc input ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1//2 ./calc.at:1449: $PREPARSER ./calc input stderr: stderr: ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.1: syntax error, unexpected end of input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 1.3: syntax error ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.3: syntax error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 4 12 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Stack now 0 4 12 Error: popping nterm exp (1) Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: cat stderr ./calc.at:1446: cat stderr ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 4 12 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Stack now 0 4 12 Error: popping nterm exp (1) Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () input: input: ./calc.at:1453: cat stderr ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 ./calc.at:1446: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 | | +1 ./calc.at:1448: $PREPARSER ./calc input input: ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 2.1: syntax error ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1443: $PREPARSER ./calc input stderr: ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1453: $PREPARSER ./calc input 2.1: syntax error ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1445: cat stderr ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1449: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (# + 1) = 1111 ./calc.at:1445: $PREPARSER ./calc input stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' () Error: discarding token '+' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1) Error: discarding token number (1) Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: ./calc.at:1448: cat stderr ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: input: ./calc.at:1448: $PREPARSER ./calc /dev/null ./calc.at:1446: cat stderr | error stderr: ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1449: $PREPARSER ./calc input ./calc.at:1443: cat stderr input: | | +1 ./calc.at:1451: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1446: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 input: stderr: ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' () Error: discarding token '+' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1) Error: discarding token number (1) Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1443: $PREPARSER ./calc input stderr: input: 1.1: syntax error | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1451: $PREPARSER ./calc input stderr: ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 1.1: syntax error ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1451: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error ./calc.at:1446: cat stderr input: | (!!) + (1 2) = 1 ./calc.at:1445: cat stderr input: ./calc.at:1453: $PREPARSER ./calc input ./calc.at:1448: cat stderr ./calc.at:1446: $PREPARSER ./calc /dev/null ./calc.at:1443: cat stderr | 1 2 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 stderr: ./calc.at:1451: $PREPARSER ./calc input input: ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 | (1 + # + 1) = 1111 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1448: $PREPARSER ./calc input ./calc.at:1445: $PREPARSER ./calc input | (# + 1) = 1111 stderr: ./calc.at:1443: $PREPARSER ./calc input 1.3: syntax error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 4 12 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Stack now 0 4 12 Error: popping nterm exp (1) Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' () Error: discarding token '+' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1) Error: discarding token number (1) Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.3: syntax error ./calc.at:1446: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 4 12 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Stack now 0 4 12 Error: popping nterm exp (1) Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' () Error: discarding token '+' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1) Error: discarding token number (1) Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1449: cat stderr ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | 1 = 2 = 3 ./calc.at:1449: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1448: cat stderr ./calc.at:1446: $PREPARSER ./calc input stderr: 1.7: syntax error ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of inpstderr: ut (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1453: cat stderr ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (!!) + (1 2) = 1 ./calc.at:1445: cat stderr ./calc.at:1448: $PREPARSER ./calc input ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.7: syntax error stderr: input: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1446: cat stderr ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + 1) / (1 - 1) stderr: input: ./calc.at:1445: $PREPARSER ./calc input 1.11: syntax error 1.1-16: error: 2222 != 1 | (1 + # + 1) = 1111 input: ./calc.at:1443: $PREPARSER ./calc input | (- *) + (1 2) = 1 | (!!) + (1 2) = 1 ./calc.at:1446: $PREPARSER ./calc input ./calc.at:1453: $PREPARSER ./calc input ./calc.at:1451: cat stderr ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1449: cat stderr 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Stack now 0 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' () Reducing stack by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' () Reducing stack by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 input: ./calc.at:1448: cat stderr ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1449: $PREPARSER ./calc input stderr: ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1451: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: stderr: 2.1: syntax error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Stack now 0 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' () Reducing stack by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' () Reducing stack by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | (- *) + (1 2) = 1 ./calc.at:1448: $PREPARSER ./calc input stderr: 2.1: syntax error stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error ./calc.at:1443: cat stderr input: ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) ./calc.at:1453: $PREPARSER ./calc input stderr: ./calc.at:1446: cat stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: cat stderr input: ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + 1) / (1 - 1) ./calc.at:1443: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: 533. calc.at:1445: ok ./calc.at:1449: cat stderr ./calc.at:1448: cat stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' input: ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 stderr: ./calc.at:1446: $PREPARSER ./calc input ./calc.at:1451: cat stderr ./calc.at:1449: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: 1.1: syntax error stderr: | (* *) + (*) + (*) ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: $PREPARSER ./calc input ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: cat stderr stderr: | error stderr: ./calc.at:1451: $PREPARSER ./calc input 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1443: cat stderr 1.1: syntax error stderr: 1.1: syntax error ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.1: syntax error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 532. calc.at:1443: input: ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ok | 1 + 2 * 3 + !+ ++ ./calc.at:1453: $PREPARSER ./calc input stderr: ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 544. calc.at:1468: testing Calculator glr.cc ... ./calc.at:1449: cat stderr ./calc.at:1468: mv calc.y.tmp calc.y ./calc.at:1468: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1453: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: cat stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1449: $PREPARSER ./calc input ./calc.at:1446: cat stderr input: | 1 + 2 * 3 + !- ++ input: ./calc.at:1453: $PREPARSER ./calc input ./calc.at:1451: cat stderr stderr: | 1 + 2 * 3 + !+ ++ stderr: ./calc.at:1448: $PREPARSER ./calc input 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 = 2 = 3 ./calc.at:1451: $PREPARSER ./calc input stderr: input: stderr: stderr: stderr: 1.7: syntax error | (* *) + (*) + (*) ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1446: $PREPARSER ./calc input stderr: 1.7: syntax error stderr: ./calc.at:1448: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1451: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1468: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS | 1 + 2 * 3 + !- ++ ./calc.at:1448: $PREPARSER ./calc input input: ./calc.at:1453: cat stderr stderr: | | +1 ./calc.at:1451: $PREPARSER ./calc input ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: input: ./calc.at:1449: cat stderr | (#) + (#) = 2222 2.1: syntax error ./calc.at:1453: $PREPARSER ./calc input ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./calc.at:1446: cat stderr ./calc.at:1454: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc input: stderr: ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1449: $PREPARSER ./calc input 2.1: syntax error stderr: input: stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1454: $PREPARSER ./calc input stderr: ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 545. calc.at:1469: testing Calculator glr2.cc ... ./calc.at:1469: mv calc.y.tmp calc.y ./calc.at:1469: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' | 1 + 2 * 3 + !+ ++ ./calc.at:1446: $PREPARSER ./calc input ./calc.at:1454: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: cat stderr stderr: stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1451: cat stderr ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 2 stderr: ./calc.at:1454: $PREPARSER ./calc input input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1453: cat stderr ./calc.at:1446: $EGREP -c -v 'Return for a new token:|LAC:' stderr | (#) + (#) = 2222 ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: $PREPARSER ./calc input stderr: stderr: ./calc.at:1451: $PREPARSER ./calc /dev/null ./calc.at:1469: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS input: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ 1.3: syntax error, unexpected number 1.1: syntax error ./calc.at:1446: $PREPARSER ./calc input input: ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1449: cat stderr | (1 + #) = 1111 ./calc.at:1453: $PREPARSER ./calc input stderr: ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: 1.6: syntax error: invalid character: '#' 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 1.3: syntax error, unexpected number stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (- *) + (1 2) = 1 ./calc.at:1449: $PREPARSER ./calc input ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error stderr: ./calc.at:1446: cat stderr 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (#) + (#) = 2222 ./calc.at:1446: $PREPARSER ./calc input 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 stderr: ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: cat stderr ./calc.at:1454: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1451: cat stderr stderr: ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | (1 + #) = 1111 input: ./calc.at:1448: $PREPARSER ./calc input ./calc.at:1453: cat stderr | 1//2 input: ./calc.at:1454: $PREPARSER ./calc input stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1451: $PREPARSER ./calc input ./calc.at:1449: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (# + 1) = 1111 stderr: ./calc.at:1453: $PREPARSER ./calc input 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: cat stderr input: stderr: | (* *) + (*) + (*) ./calc.at:1449: $PREPARSER ./calc input 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 stderr: ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error 1.6: syntax error: invalid character: '#' ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' stderr: ./calc.at:1454: cat stderr 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1453: cat stderr input: | error | (1 + #) = 1111 ./calc.at:1454: $PREPARSER ./calc input stderr: 1.1: syntax error, unexpected invalid token ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: $PREPARSER ./calc input stderr: stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + # + 1) = 1111 ./calc.at:1453: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error, unexpected invalid token ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1448: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1451: cat stderr ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (# + 1) = 1111 ./calc.at:1448: $PREPARSER ./calc input ./calc.at:1454: cat stderr stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1449: cat stderr input: stderr: input: 1.2: syntax error: invalid character: '#' | (!!) + (1 2) = 1 ./calc.at:1451: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1454: $PREPARSER ./calc input stderr: stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1453: cat stderr 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.7: syntax error, unexpected '=' input: ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: input: ./calc.at:1457: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc | 1 + 2 * 3 + !+ ++ ./calc.at:1449: $PREPARSER ./calc input stderr: ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1457: $PREPARSER ./calc input ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (1 + 1) / (1 - 1) ./calc.at:1453: $PREPARSER ./calc input ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1446: cat stderr stderr: stderr: 1.7: syntax error, unexpected '=' ./calc.at:1449: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor ./calc.at:1451: cat stderr | (# + 1) = 1111 ./calc.at:1446: $PREPARSER ./calc input ./calc.at:1448: cat stderr stderr: ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1457: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: 1.11-17: error: null divisor stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + # + 1) = 1111 ./calc.at:1448: $PREPARSER ./calc input input: stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1449: $PREPARSER ./calc input input: | 1 2 input: stderr: ./calc.at:1457: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1451: $PREPARSER ./calc input stderr: ./calc.at:1454: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 input: ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1454: $PREPARSER ./calc input stderr: stderr: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) stderr: ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: cat stderr ./calc.at:1453: cat stderr 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1448: cat stderr 2.1: syntax error, unexpected '+' stderr: ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + 1) / (1 - 1) ./calc.at:1448: $PREPARSER ./calc input stderr: 2.1: syntax error, unexpected '+' stderr: 538. calc.at:1453: ok stderr: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) 1.11-17: error: null divisor ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + # + 1) = 1111 stderr: ./calc.at:1446: $PREPARSER ./calc input stdout: stderr: ./calc.at:1457: cat stderr stderr: ./calc.at:1458: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11-17: error: null divisor ./calc.at:1454: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1451: cat stderr input: | 1//2 ./calc.at:1457: $PREPARSER ./calc input ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1454: $PREPARSER ./calc /dev/null stderr: stderr: stderr: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1449: cat stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error, unexpected end of file ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1458: $PREPARSER ./calc input 546. calc.at:1476: testing Calculator C++ %glr-parser ... ./calc.at:1451: $PREPARSER ./calc input ./calc.at:1476: mv calc.y.tmp calc.y stderr: ./calc.at:1476: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: stderr: 1.1: syntax error, unexpected end of file stderr: stderr: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) input: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stdout: ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1448: cat stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (#) + (#) = 2222 stderr: ./calc.at:1446: cat stderr ./calc.at:1449: $PREPARSER ./calc input ./calc.at:1455: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc 535. calc.at:1448: ok ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: ./calc.at:1458: $EGREP -c -v 'Return for a new token:|LAC:' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1455: $PREPARSER ./calc input stderr: stderr: | (1 + 1) / (1 - 1) ./calc.at:1454: cat stderr ./calc.at:1457: cat stderr ./calc.at:1446: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) LAC: initial context established for '=' LAC: checking lookahead '=': R9 G29 R7 G8 S18 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 92): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) LAC: initial context established for '=' LAC: checking lookahead '=': R11 G30 R9 G29 R7 G8 S18 Reducing stack by rule 11 (line 115): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 105): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 92): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 92): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G10 R11 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 115): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 92): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) LAC: initial context established for ')' LAC: checking lookahead ')': R11 G12 S26 Reducing stack by rule 11 (line 115): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 92): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 92): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) LAC: initial context established for '=' LAC: checking lookahead '=': R11 G10 R11 G10 R11 G8 S18 Reducing stack by rule 11 (line 115): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 115): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 115): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 92): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) LAC: initial context established for '-' LAC: checking lookahead '-': R8 G8 S19 Reducing stack by rule 8 (line 104): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) LAC: initial context discarded due to shift Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 92): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) LAC: initial context established for '=' LAC: checking lookahead '=': R8 G8 S18 Reducing stack by rule 8 (line 104): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 92): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 92): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) LAC: initial context established for ')' LAC: checking lookahead ')': R8 G12 S26 Reducing stack by rule 8 (line 104): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) LAC: initial context established for '=' LAC: checking lookahead '=': R8 G8 S18 Reducing stack by rule 8 (line 104): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 92): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 92): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G32 R12 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 116): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 92): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 92): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) LAC: initial context established for ')' LAC: checking lookahead ')': R12 G12 S26 Reducing stack by rule 12 (line 116): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 92): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (14.1: ) Shifting token end of file (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 2 ./calc.at:1458: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1451: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) LAC: initial context established for '=' LAC: checking lookahead '=': R9 G29 R7 G8 S18 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 92): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) LAC: initial context established for '=' LAC: checking lookahead '=': R11 G30 R9 G29 R7 G8 S18 Reducing stack by rule 11 (line 115): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 105): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 92): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 92): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G10 R11 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 115): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 92): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) LAC: initial context established for ')' LAC: checking lookahead ')': R11 G12 S26 Reducing stack by rule 11 (line 115): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 92): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 92): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) LAC: initial context established for '=' LAC: checking lookahead '=': R11 G10 R11 G10 R11 G8 S18 Reducing stack by rule 11 (line 115): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 115): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 115): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 92): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) LAC: initial context established for '-' LAC: checking lookahead '-': R8 G8 S19 Reducing stack by rule 8 (line 104): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) LAC: initial context discarded due to shift Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 92): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) LAC: initial context established for '=' LAC: checking lookahead '=': R8 G8 S18 Reducing stack by rule 8 (line 104): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 92): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 92): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) LAC: initial context established for ')' LAC: checking lookahead ')': R8 G12 S26 Reducing stack by rule 8 (line 104): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) LAC: initial context established for '=' LAC: checking lookahead '=': R8 G8 S18 Reducing stack by rule 8 (line 104): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 92): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 92): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G32 R12 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 116): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 92): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 92): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) LAC: initial context established for ')' LAC: checking lookahead ')': R12 G12 S26 Reducing stack by rule 12 (line 116): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 92): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (14.1: ) Shifting token end of file (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1455: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: input: ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1457: $PREPARSER ./calc input stderr: ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1476: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS input: stderr: ./calc.at:1454: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1451: $PREPARSER ./calc input ./calc.at:1449: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: stderr: | 1 2 ./calc.at:1455: $PREPARSER ./calc input syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: stderr: ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1458: cat stderr ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) LAC: initial context established for number LAC: checking lookahead number: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: Err LAC: checking lookahead '=': S18 LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: ./calc.at:1446: cat stderr | (1 + #) = 1111 ./calc.at:1449: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) LAC: initial context established for number LAC: checking lookahead number: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: Err LAC: checking lookahead '=': S18 LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) 547. calc.at:1476: testing Calculator glr2.cc ... input: stderr: | 1//2 1.6: syntax error: invalid character: '#' ./calc.at:1451: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1458: $PREPARSER ./calc input ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: mv calc.y.tmp calc.y stderr: 534. calc.at:1446: ok ./calc.at:1455: cat stderr ./calc.at:1454: cat stderr input: 1.6: syntax error: invalid character: '#' | 1//2 ./calc.at:1455: $PREPARSER ./calc input stderr: 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) stderr: ./calc.at:1476: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) LAC: initial context established for '/' LAC: checking lookahead '/': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) LAC: initial context established for '/' LAC: checking lookahead '/': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !- ++ ./calc.at:1451: $PREPARSER ./calc input stderr: ./calc.at:1457: cat stderr ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) stderr: stderr: input: | (!!) + (1 2) = 1 ./calc.at:1454: $PREPARSER ./calc input input: ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stdout: ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1459: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc | 1 = 2 = 3 ./calc.at:1457: $PREPARSER ./calc input ./calc.at:1455: cat stderr 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: ./calc.at:1451: cat stderr 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1458: cat stderr ./calc.at:1449: cat stderr syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 | error ./calc.at:1459: $PREPARSER ./calc input ./calc.at:1455: $PREPARSER ./calc input ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': S3 LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 548. calc.at:1477: testing Calculator C++ %glr-parser %locations ... Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': S3 LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 input: input: stderr: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) ./calc.at:1476: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS input: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1458: $PREPARSER ./calc input | (#) + (#) = 2222 ./calc.at:1451: $PREPARSER ./calc input ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: mv calc.y.tmp calc.y stderr: ./calc.at:1455: cat stderr stderr: stderr: | (# + 1) = 1111 ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1477: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 = 2 = 3 ./calc.at:1455: $PREPARSER ./calc input ./calc.at:1449: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1454: cat stderr ./calc.at:1459: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: stderr: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) LAC: checking lookahead '=': Err LAC: checking lookahead end of file: R6 G8 Err LAC: checking lookahead number: R6 G8 Err LAC: checking lookahead '=': Err LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 LAC: checking lookahead NEG: R6 G8 Err LAC: checking lookahead '^': S23 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: 1.2: syntax error: invalid character: '#' 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1457: cat stderr | (- *) + (1 2) = 1 ./calc.at:1454: $PREPARSER ./calc input input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) LAC: checking lookahead '=': Err LAC: checking lookahead end of file: R6 G8 Err LAC: checking lookahead number: R6 G8 Err LAC: checking lookahead '=': Err LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 LAC: checking lookahead NEG: R6 G8 Err LAC: checking lookahead '^': S23 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1458: cat stderr stderr: | 1 2 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1459: $PREPARSER ./calc input ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1451: cat stderr stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: | (1 + #) = 1111 ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1449: cat stderr ./calc.at:1451: $PREPARSER ./calc input stderr: stderr: input: 1.6: syntax error: invalid character: '#' input: ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1457: $PREPARSER ./calc input input: | (1 + # + 1) = 1111 ./calc.at:1449: $PREPARSER ./calc input 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 stderr: stderr: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) | 1 = 2 = 3 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./calc.at:1458: $PREPARSER ./calc input stderr: ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1455: cat stderr ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1459: cat stderr input: ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1455: $PREPARSER ./calc input 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) ./calc.at:1477: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS input: ./calc.at:1454: cat stderr | 1//2 ./calc.at:1459: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) LAC: initial context established for '+' LAC: checking lookahead '+': Err LAC: checking lookahead end of file: S16 LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': S3 LAC: checking lookahead '(': S4 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1449: cat stderr ./calc.at:1457: cat stderr ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1451: cat stderr stderr: 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) stderr: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1457: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) LAC: initial context established for '+' LAC: checking lookahead '+': Err LAC: checking lookahead end of file: S16 LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': S3 LAC: checking lookahead '(': S4 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 input: stderr: | (* *) + (*) + (*) syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1454: $PREPARSER ./calc input input: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) stderr: stderr: input: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: | (# + 1) = 1111 ./calc.at:1451: $PREPARSER ./calc input 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) stderr: ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + 1) / (1 - 1) ./calc.at:1449: $PREPARSER ./calc input stderr: 1.11-17: error: null divisor ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' ./calc.at:1457: cat stderr ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1458: cat stderr stderr: 1.2: syntax error: invalid character: '#' 1.11-17: error: null divisor ./calc.at:1455: cat stderr stderr: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' input: ./calc.at:1459: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1455: $PREPARSER ./calc /dev/null stderr: ./calc.at:1457: $PREPARSER ./calc input ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of file (1.1: ) LAC: initial context established for end of file LAC: checking lookahead end of file: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': S3 LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1459: $PREPARSER ./calc input ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: stderr: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) error: 4444 != 1 ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of file (1.1: ) LAC: initial context established for end of file LAC: checking lookahead end of file: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': S3 LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1454: cat stderr 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) | | +1 stderr: ./calc.at:1458: $PREPARSER ./calc input stderr: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) error: 4444 != 1 ./calc.at:1449: cat stderr ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1451: cat stderr ./calc.at:1455: cat stderr stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) input: stderr: | 1 + 2 * 3 + !+ ++ 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1454: $PREPARSER ./calc input 536. calc.at:1449: ok input: ./calc.at:1458: cat stderr stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1455: $PREPARSER ./calc input input: ./calc.at:1457: cat stderr ./calc.at:1458: $PREPARSER ./calc /dev/null ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1459: cat stderr stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) | (1 + # + 1) = 1111 ./calc.at:1451: $PREPARSER ./calc input ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) LAC: initial context established for ')' LAC: checking lookahead ')': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G12 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G12 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) LAC: initial context established for ')' LAC: checking lookahead ')': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G8 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G8 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) LAC: initial context established for '*' LAC: checking lookahead '*': R9 G12 S21 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) LAC: initial context discarded due to shift Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1454: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: stderr: | 1 = 2 = 3 ./calc.at:1459: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) LAC: initial context established for ')' LAC: checking lookahead ')': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G12 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G12 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) LAC: initial context established for ')' LAC: checking lookahead ')': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G8 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G8 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) LAC: initial context established for '*' LAC: checking lookahead '*': R9 G12 S21 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) LAC: initial context discarded due to shift Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (!!) + (1 2) = 1 ./calc.at:1457: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) 549. calc.at:1477: testing Calculator glr2.cc %locations ... stderr: stderr: ./calc.at:1477: mv calc.y.tmp calc.y ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 1.6: syntax error: invalid character: '#' ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ ./calc.at:1454: $PREPARSER ./calc input ./calc.at:1477: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 stderr: ./calc.at:1458: cat stderr ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1455: cat stderr stderr: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: | (!!) + (1 2) = 1 ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1455: $PREPARSER ./calc input input: ./calc.at:1457: cat stderr ./calc.at:1459: cat stderr ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 | | +1 ./calc.at:1459: $PREPARSER ./calc input stderr: stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1458: $PREPARSER ./calc input stderr: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 120): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) LAC: initial context established for number LAC: checking lookahead number: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: Err LAC: checking lookahead '=': S18 LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 ./calc.at:1454: cat stderr ./calc.at:1459: cat stderr ./calc.at:1459: $PREPARSER ./calc /dev/null stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) input: ./calc.at:1451: cat stderr ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (- *) + (1 2) = 1 ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1457: $PREPARSER ./calc input ./calc.at:1477: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: stderr: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 120): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) LAC: initial context established for number LAC: checking lookahead number: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: Err LAC: checking lookahead '=': S18 LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 input: stderr: | (#) + (#) = 2222 | (1 + 1) / (1 - 1) ./calc.at:1451: $PREPARSER ./calc input ./calc.at:1454: $PREPARSER ./calc input stderr: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1459: cat stderr 1.11-17: error: null divisor ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1458: cat stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1455: cat stderr stderr: ./calc.at:1457: cat stderr input: | (- *) + (1 2) = 1 ./calc.at:1455: $PREPARSER ./calc input 1.11-17: error: null divisor input: input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1459: $PREPARSER ./calc input ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (!!) + (1 2) = 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 119): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) LAC: initial context established for number LAC: checking lookahead number: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: Err LAC: checking lookahead '=': S18 LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1458: $PREPARSER ./calc input ./calc.at:1454: cat stderr stderr: | (* *) + (*) + (*) 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 ./calc.at:1457: $PREPARSER ./calc input 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 stderr: ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 119): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) LAC: initial context established for number LAC: checking lookahead number: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: Err LAC: checking lookahead '=': S18 LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: stdout: ./calc.at:1468: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1451: cat stderr stderr: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 | (1 + #) = 1111 ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1454: $PREPARSER ./calc input 537. calc.at:1451: ok stderr: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1468: $PREPARSER ./calc input ./calc.at:1455: cat stderr stderr: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1459: cat stderr ./calc.at:1457: cat stderr stderr: ./calc.at:1458: cat stderr stderr: input: 1.6: syntax error: invalid character: '#' input: | (!!) + (1 2) = 1 ./calc.at:1459: $PREPARSER ./calc input | (* *) + (*) + (*) stderr: ./calc.at:1455: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G8 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R7 G8 S24 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G8 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R7 G8 S24 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 input: ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 input: ./calc.at:1468: $PREPARSER ./calc input ./calc.at:1455: cat stderr stderr: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error | 1 + 2 * 3 + !+ ++ ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1457: $PREPARSER ./calc input | (- *) + (1 2) = 1 stderr: ./calc.at:1458: $PREPARSER ./calc input ./calc.at:1454: cat stderr stderr: stderr: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 syntax error 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 stderr: input: | 1 + 2 * 3 + !+ ++ ./calc.at:1455: $PREPARSER ./calc input ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1459: cat stderr stderr: ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 550. calc.at:1478: testing Calculator C++ %glr-parser %locations api.location.type={Span} ... ./calc.at:1478: mv calc.y.tmp calc.y ./calc.at:1478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: ./calc.at:1457: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) LAC: initial context established for '+' LAC: checking lookahead '+': R9 G29 R7 G8 S20 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 121): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1454: $PREPARSER ./calc input stderr: | (- *) + (1 2) = 1 ./calc.at:1459: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.2: syntax error: invalid character: '#' input: stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 | 1 + 2 * 3 + !- ++ ./calc.at:1468: cat stderr ./calc.at:1457: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) LAC: initial context established for '+' LAC: checking lookahead '+': R9 G29 R7 G8 S20 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 121): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1458: cat stderr ./calc.at:1455: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | 1 + 2 * 3 + !- ++ ./calc.at:1455: $PREPARSER ./calc input ./calc.at:1454: cat stderr | (* *) + (*) + (*) ./calc.at:1458: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) LAC: initial context established for '+' LAC: checking lookahead '+': R9 G29 R7 G8 S20 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 122): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1468: $PREPARSER ./calc input stderr: stderr: stderr: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) stderr: ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 input: stderr: syntax error stderr: | (1 + # + 1) = 1111 ./calc.at:1454: $PREPARSER ./calc input stderr: stderr: ./calc.at:1457: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) LAC: initial context established for '+' LAC: checking lookahead '+': R9 G29 R7 G8 S20 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 122): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.6: syntax error: invalid character: '#' ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1459: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1458: cat stderr input: input: | (#) + (#) = 2222 ./calc.at:1457: $PREPARSER ./calc input input: ./calc.at:1468: cat stderr ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1459: $PREPARSER ./calc input stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1458: $PREPARSER ./calc input stderr: ./calc.at:1454: cat stderr input: syntax error: invalid character: '#' syntax error: invalid character: '#' 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1455: cat stderr | error ./calc.at:1468: $PREPARSER ./calc input stderr: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' syntax error: invalid character: '#' syntax error ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + 1) / (1 - 1) ./calc.at:1454: $PREPARSER ./calc input stderr: input: stderr: ./calc.at:1458: $EGREP -c -v 'Return for a new token:|LAC:' stderr | (#) + (#) = 2222 ./calc.at:1455: $PREPARSER ./calc input stderr: stderr: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.11-17: error: null divisor stderr: ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) syntax error ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1457: cat stderr ./calc.at:1459: cat stderr stderr: input: stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1458: $PREPARSER ./calc input stderr: ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1468: cat stderr 1.11-17: error: null divisor input: | (1 + #) = 1111 ./calc.at:1457: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' stderr: | 1 + 2 * 3 + !+ ++ input: ./calc.at:1459: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1468: $PREPARSER ./calc input ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error ./calc.at:1454: cat stderr ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1458: cat stderr stderr: ./calc.at:1455: cat stderr syntax error 539. calc.at:1454: ok ./calc.at:1457: cat stderr ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (#) + (#) = 2222 ./calc.at:1458: $PREPARSER ./calc input input: stderr: stderr: | (# + 1) = 1111 ./calc.at:1459: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1457: $PREPARSER ./calc input input: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 ./calc.at:1455: $PREPARSER ./calc input input: | 1 + 2 * 3 + !- ++ stderr: ./calc.at:1459: $PREPARSER ./calc input stderr: stderr: syntax error: invalid character: '#' ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' ./calc.at:1468: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: stdout: ./calc.at:1476: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 551. calc.at:1478: testing Calculator glr2.cc %locations api.location.type={Span} ... ./calc.at:1455: cat stderr ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: mv calc.y.tmp calc.y ./calc.at:1478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: | | +1 stderr: ./calc.at:1468: $PREPARSER ./calc input input: ./calc.at:1458: cat stderr | (# + 1) = 1111 ./calc.at:1455: $PREPARSER ./calc input stderr: ./calc.at:1459: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) LAC: initial context established for '+' LAC: checking lookahead '+': Err Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: syntax error input: | 1 2 ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1457: cat stderr stderr: ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1458: $PREPARSER ./calc input input: stderr: stderr: syntax error 1.6: syntax error: invalid character: '#' stderr: | (#) + (#) = 2222 ./calc.at:1459: $PREPARSER ./calc input ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) LAC: initial context established for '+' LAC: checking lookahead '+': Err Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: syntax error | (1 + # + 1) = 1111 ./calc.at:1457: $PREPARSER ./calc input ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error: invalid character: '#' ./calc.at:1455: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1458: cat stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1459: cat stderr input: ./calc.at:1468: cat stderr | (# + 1) = 1111 ./calc.at:1458: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' input: ./calc.at:1468: $PREPARSER ./calc /dev/null | (1 + # + 1) = 1111 ./calc.at:1455: $PREPARSER ./calc input ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1457: cat stderr stderr: input: | (1 + 1) / (1 - 1) ./calc.at:1457: $PREPARSER ./calc input | (1 + #) = 1111 ./calc.at:1476: cat stderr ./calc.at:1459: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) LAC: initial context established for '+' LAC: checking lookahead '+': Err Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: error: null divisor ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: error: null divisor 1.6: syntax error: invalid character: '#' 1.2: syntax error: invalid character: '#' syntax error input: stderr: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) LAC: initial context established for '+' LAC: checking lookahead '+': Err Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1//2 ./calc.at:1476: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1458: cat stderr ./calc.at:1455: cat stderr ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1457: cat stderr input: ./calc.at:1459: cat stderr input: | (1 + # + 1) = 1111 stderr: ./calc.at:1468: cat stderr syntax error ./calc.at:1458: $PREPARSER ./calc input | (1 + 1) / (1 - 1) 541. calc.at:1457: ok ./calc.at:1455: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' stderr: input: | (# + 1) = 1111 stderr: input: ./calc.at:1459: $PREPARSER ./calc input stderr: stdout: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) LAC: initial context established for ')' LAC: checking lookahead ')': R7 G12 S26 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 92): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) LAC: initial context established for ')' LAC: checking lookahead ')': R8 G12 S26 Reducing stack by rule 8 (line 104): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R10 G8 S24 Reducing stack by rule 10 (line 106): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 1.2: syntax error: invalid character: '#' ./calc.at:1468: $PREPARSER ./calc input ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1477: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: ./calc.at:1458: cat stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + 1) / (1 - 1) ./calc.at:1458: $PREPARSER ./calc input syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor input: stderr: 1.2: syntax error: invalid character: '#' stderr: stderr: ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1477: $PREPARSER ./calc input syntax error syntax error syntax error syntax error error: 4444 != 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) LAC: initial context established for ')' LAC: checking lookahead ')': R7 G12 S26 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 92): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) LAC: initial context established for ')' LAC: checking lookahead ')': R8 G12 S26 Reducing stack by rule 8 (line 104): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R10 G8 S24 Reducing stack by rule 10 (line 106): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1476: cat stderr stderr: ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1459: cat stderr stderr: stderr: | error input: | 1 2 ./calc.at:1476: $PREPARSER ./calc input stderr: ./calc.at:1477: $PREPARSER ./calc input 1.11-17: error: null divisor stderr: syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error ./calc.at:1458: cat stderr | (1 + # + 1) = 1111 ./calc.at:1459: $PREPARSER ./calc input stderr: 1.3: syntax error ./calc.at:1455: cat stderr stderr: 1.6: syntax error: invalid character: '#' 552. calc.at:1479: testing Calculator C++ %glr-parser %header parse.error=verbose %name-prefix "calc" %verbose ... ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 542. calc.at:1458: ok ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: mv calc.y.tmp calc.y stderr: ./calc.at:1468: cat stderr 1.6: syntax error: invalid character: '#' 540. calc.at:1455: ok ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: cat stderr ./calc.at:1479: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: input: ./calc.at:1459: cat stderr | 1 = 2 = 3 ./calc.at:1476: $PREPARSER ./calc input | (!!) + (1 2) = 1 ./calc.at:1468: $PREPARSER ./calc input stderr: syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1477: cat stderr stderr: syntax error syntax error error: 2222 != 1 ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + 1) / (1 - 1) stderr: ./calc.at:1459: $PREPARSER ./calc input stderr: syntax error error: 2222 != 1 input: 1.11-17: error: null divisor | 1//2 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 553. calc.at:1479: testing Calculator glr2.cc %header parse.error=verbose %name-prefix "calc" %verbose ... ./calc.at:1479: mv calc.y.tmp calc.y 1.3: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error ./calc.at:1479: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS stderr: 1.11-17: error: null divisor ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1476: cat stderr ./calc.at:1459: cat stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1468: cat stderr input: | | +1 ./calc.at:1476: $PREPARSER ./calc input 543. calc.at:1459: ok stderr: 554. calc.at:1480: testing Calculator C++ %glr-parser parse.error=verbose api.prefix={calc} %verbose ... input: ./calc.at:1480: mv calc.y.tmp calc.y syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y | (- *) + (1 2) = 1 ./calc.at:1468: $PREPARSER ./calc input ./calc.at:1477: cat stderr ./calc.at:1479: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS stderr: stderr: syntax error syntax error error: 2222 != 1 ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error input: ./calc.at:1480: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: | error syntax error syntax error error: 2222 != 1 ./calc.at:1477: $PREPARSER ./calc input stderr: 1.1: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 555. calc.at:1480: testing Calculator glr2.cc parse.error=verbose api.prefix={calc} %verbose ... ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: mv calc.y.tmp calc.y ./calc.at:1476: cat stderr ./calc.at:1480: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1476: $PREPARSER ./calc /dev/null ./calc.at:1477: cat stderr ./calc.at:1468: cat stderr stderr: syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error input: input: | 1 = 2 = 3 | (* *) + (*) + (*) ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1468: $PREPARSER ./calc input stderr: 1.7: syntax error stderr: ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error syntax error ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1476: cat stderr stderr: syntax error syntax error syntax error 1.7: syntax error input: ./calc.at:1480: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1477: cat stderr syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1468: cat stderr stderr: input: | 1 + 2 * 3 + !+ ++ stdout: ./calc.at:1468: $PREPARSER ./calc input input: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1469: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc | | +1 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: 2.1: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1469: $PREPARSER ./calc input stderr: input: ./calc.at:1476: cat stderr | 1 + 2 * 3 + !- ++ stderr: ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1468: $PREPARSER ./calc input 2.1: syntax error stderr: ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 input: ./calc.at:1476: $PREPARSER ./calc input | 1 2 ./calc.at:1469: $PREPARSER ./calc input stderr: stderr: syntax error error: 2222 != 1 syntax error ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: cat stderr stderr: stderr: stderr: ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error error: 2222 != 1 ./calc.at:1477: $PREPARSER ./calc /dev/null stdout: syntax error ./calc.at:1478: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: 1.1: syntax error input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1468: cat stderr stderr: input: | 1 2 ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error stderr: input: ./calc.at:1476: cat stderr 1.3: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1468: $PREPARSER ./calc input ./calc.at:1469: cat stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1477: cat stderr syntax error: invalid character: '#' syntax error: invalid character: '#' 1.3: syntax error input: ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1477: $PREPARSER ./calc input | 1//2 ./calc.at:1469: $PREPARSER ./calc input stderr: | (- *) + (1 2) = 1 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: $PREPARSER ./calc input stderr: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error stderr: ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error error: 2222 != 1 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: syntax error ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error syntax error error: 2222 != 1 ./calc.at:1478: cat stderr input: ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1468: cat stderr ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.3: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: cat stderr stderr: ./calc.at:1477: cat stderr 1.3: syntax error input: input: | (1 + #) = 1111 | (* *) + (*) + (*) ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1468: $PREPARSER ./calc input input: ./calc.at:1469: cat stderr stderr: syntax error: invalid character: '#' | (!!) + (1 2) = 1 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error syntax error syntax error 1.11: syntax error 1.1-16: error: 2222 != 1 stderr: ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | error ./calc.at:1478: cat stderr ./calc.at:1469: $PREPARSER ./calc input stderr: input: | error ./calc.at:1478: $PREPARSER ./calc input stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 syntax error: invalid character: '#' stderr: stdout: stderr: 1.1: syntax error ./calc.at:1476: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error syntax error ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1476: $PREPARSER ./calc input 1.1: syntax error ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: cat stderr stderr: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1468: cat stderr input: ./calc.at:1478: cat stderr | 1 2 ./calc.at:1476: $PREPARSER ./calc input input: | (- *) + (1 2) = 1 ./calc.at:1477: $PREPARSER ./calc input stderr: syntax error input: ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (# + 1) = 1111 ./calc.at:1468: $PREPARSER ./calc input input: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error | 1 = 2 = 3 ./calc.at:1478: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.7: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.7: syntax error stderr: ./calc.at:1469: cat stderr ./calc.at:1476: cat stderr 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 stderr: syntax error: invalid character: '#' ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 = 2 = 3 ./calc.at:1469: $PREPARSER ./calc input stderr: syntax error input: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !+ ++ ./calc.at:1476: cat stderr ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | 1//2 ./calc.at:1476: $PREPARSER ./calc input stderr: syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error stderr: ./calc.at:1478: cat stderr ./calc.at:1468: cat stderr ./calc.at:1477: cat stderr syntax error input: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 input: ./calc.at:1478: $PREPARSER ./calc input input: ./calc.at:1476: cat stderr | (* *) + (*) + (*) ./calc.at:1477: $PREPARSER ./calc input stderr: input: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (1 + # + 1) = 1111 ./calc.at:1468: $PREPARSER ./calc input | error ./calc.at:1476: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ ./calc.at:1476: $PREPARSER ./calc input 2.1: syntax error ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error stderr: stderr: 2.1: syntax error syntax error: invalid character: '#' ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error ./calc.at:1469: cat stderr stderr: ./calc.at:1477: cat stderr input: | 1 + 2 * 3 + !+ ++ ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error: invalid character: '#' ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: | | +1 input: ./calc.at:1469: $PREPARSER ./calc input ./calc.at:1476: cat stderr | 1 + 2 * 3 + !- ++ ./calc.at:1477: $PREPARSER ./calc input stderr: stderr: syntax error ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 stderr: ./calc.at:1476: $PREPARSER ./calc input syntax error stderr: ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: cat stderr ./calc.at:1478: $PREPARSER ./calc /dev/null stderr: stderr: ./calc.at:1468: cat stderr ./calc.at:1476: cat stderr 1.1: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error 1.1: syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | (1 + 1) / (1 - 1) ./calc.at:1468: $PREPARSER ./calc input ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (#) + (#) = 2222 ./calc.at:1476: $PREPARSER ./calc input stderr: stderr: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: cat stderr error: null divisor ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: syntax error stderr: | (#) + (#) = 2222 stderr: ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1469: cat stderr error: null divisor stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1469: $PREPARSER ./calc /dev/null 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1478: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1476: cat stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1478: $PREPARSER ./calc input syntax error input: stderr: | (1 + #) = 1111 ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1476: cat stderr stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: cat stderr syntax error: invalid character: '#' ./calc.at:1468: cat stderr ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: syntax error: invalid character: '#' | | +1 ./calc.at:1476: $PREPARSER ./calc input stderr: stderr: 544. calc.at:1468: ok syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: cat stderr input: stderr: syntax error ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1469: cat stderr | (1 + #) = 1111 ./calc.at:1477: $PREPARSER ./calc input stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (# + 1) = 1111 1.6: syntax error: invalid character: '#' ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' ./calc.at:1478: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1469: $PREPARSER ./calc input stderr: stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: cat stderr syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1476: $PREPARSER ./calc /dev/null input: stderr: | (!!) + (1 2) = 1 syntax error ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1477: cat stderr syntax error syntax error syntax error syntax error error: 4444 != 1 556. calc.at:1482: testing Calculator C++ %glr-parser %debug ... ./calc.at:1482: mv calc.y.tmp calc.y syntax error ./calc.at:1482: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (# + 1) = 1111 ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: cat stderr ./calc.at:1482: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1469: cat stderr ./calc.at:1476: cat stderr stderr: input: ./calc.at:1478: cat stderr input: stderr: stdout: | (!!) + (1 2) = 1 ./calc.at:1469: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1476: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' ./calc.at:1480: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: syntax error error: 2222 != 1 stderr: ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + # + 1) = 1111 ./calc.at:1476: $PREPARSER ./calc input stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error error: 2222 != 1 input: input: stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1480: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1478: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: cat stderr ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1476: cat stderr ./calc.at:1469: cat stderr stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 input: | (!!) + (1 2) = 1 ./calc.at:1476: $PREPARSER ./calc input stderr: syntax error error: 2222 != 1 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (- *) + (1 2) = 1 ./calc.at:1469: $PREPARSER ./calc input ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: syntax error syntax error error: 2222 != 1 ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1480: $PREPARSER ./calc input input: stderr: syntax error syntax error error: 2222 != 1 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + # + 1) = 1111 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1476: cat stderr stderr: stderr: syntax error error: 2222 != 1 input: | (1 + 1) / (1 - 1) ./calc.at:1476: $PREPARSER ./calc input stderr: syntax error, unexpected number ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: ./calc.at:1477: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc syntax error, unexpected number ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1478: cat stderr input: error: null divisor ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1477: $PREPARSER ./calc input stderr: stderr: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (* *) + (*) + (*) ./calc.at:1478: $PREPARSER ./calc input stderr: error: null divisor stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 2 ./calc.at:1480: cat stderr ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1469: cat stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error input: | 1//2 ./calc.at:1480: $PREPARSER ./calc input stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (* *) + (*) + (*) ./calc.at:1469: $PREPARSER ./calc input stderr: stderr: 1.3: syntax error ./calc.at:1477: cat stderr syntax error syntax error syntax error ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: cat stderr stderr: stderr: input: syntax error, unexpected '/', expecting number or '-' or '(' or '!' syntax error syntax error syntax error input: | 1 + 2 * 3 + !+ ++ | (1 + 1) / (1 - 1) ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1477: $PREPARSER ./calc input stderr: stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11-17: error: null divisor ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: cat stderr stderr: stderr: ./calc.at:1477: cat stderr input: 1.11-17: error: null divisor ./calc.at:1476: cat stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !- ++ ./calc.at:1478: $PREPARSER ./calc input stderr: ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: ./calc.at:1480: cat stderr | 1//2 ./calc.at:1477: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 546. calc.at:1476: ok stderr: input: stderr: 1.3: syntax error | error ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1469: cat stderr syntax error syntax error error: 2222 != 1 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: cat stderr stderr: stderr: syntax error, unexpected invalid token syntax error syntax error error: 2222 != 1 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 548. calc.at:1477: ok stderr: input: 1.3: syntax error | 1 + 2 * 3 + !+ ++ ./calc.at:1469: $PREPARSER ./calc input stderr: ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected invalid token input: 557. calc.at:1482: testing Calculator glr2.cc %debug ... | 1 + 2 * 3 + !- ++ ./calc.at:1469: $PREPARSER ./calc input ./calc.at:1482: mv calc.y.tmp calc.y ./calc.at:1482: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1478: cat stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: cat stderr stderr: input: input: | (#) + (#) = 2222 ./calc.at:1476: cat stderr ./calc.at:1478: $PREPARSER ./calc input | error ./calc.at:1477: $PREPARSER ./calc input stderr: 1.1: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) ./calc.at:1476: $PREPARSER ./calc input stderr: ./calc.at:1482: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: stderr: ./calc.at:1480: cat stderr syntax error syntax error syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 558. calc.at:1485: testing Calculator C++ %glr-parser parse.error=detailed %debug %name-prefix "calc" %verbose ... ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1469: cat stderr input: input: syntax error syntax error syntax error | 1 = 2 = 3 ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1485: mv calc.y.tmp calc.y | (#) + (#) = 2222 ./calc.at:1469: $PREPARSER ./calc input stderr: ./calc.at:1478: cat stderr stderr: ./calc.at:1485: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y syntax error, unexpected '=' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1477: cat stderr ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + #) = 1111 stderr: ./calc.at:1478: $PREPARSER ./calc input stderr: syntax error, unexpected '=' stderr: input: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' syntax error: invalid character: '#' | 1 = 2 = 3 ./calc.at:1477: $PREPARSER ./calc input stderr: 1.7: syntax error 1.6: syntax error: invalid character: '#' ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.7: syntax error stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1485: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1476: cat stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !+ ++ ./calc.at:1476: $PREPARSER ./calc input input: | | +1 ./calc.at:1480: $PREPARSER ./calc input stderr: stderr: syntax error, unexpected '+' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: cat stderr ./calc.at:1469: cat stderr ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected '+' ./calc.at:1478: cat stderr input: stderr: | (1 + #) = 1111 ./calc.at:1469: $PREPARSER ./calc input input: stderr: syntax error: invalid character: '#' ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | | +1 ./calc.at:1477: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ ./calc.at:1476: $PREPARSER ./calc input input: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: | (# + 1) = 1111 ./calc.at:1478: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1480: cat stderr stderr: 2.1: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./calc.at:1480: $PREPARSER ./calc /dev/null ./calc.at:1479: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh stderr: stderr: stderr: syntax error, unexpected end of input 1.2: syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 2.1: syntax error input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1479: $PREPARSER ./calc input stderr: ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected end of input stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1478: cat stderr ./calc.at:1469: cat stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stdout: | 1 2 ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1477: cat stderr ./calc.at:1478: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1480: cat stderr input: | (# + 1) = 1111 ./calc.at:1469: $PREPARSER ./calc input stderr: ./calc.at:1476: cat stderr stderr: syntax error, unexpected number input: ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: $PREPARSER ./calc /dev/null | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1480: $PREPARSER ./calc input syntax error: invalid character: '#' input: ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: | (1 + # + 1) = 1111 1.1: syntax error ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: 1.6: syntax error: invalid character: '#' | (#) + (#) = 2222 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: $PREPARSER ./calc input input: stderr: syntax error: invalid character: '#' stderr: stderr: syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' syntax error, unexpected number | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1478: $PREPARSER ./calc input stderr: stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' 1.1: syntax error stderr: ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: cat stderr ./calc.at:1469: cat stderr ./calc.at:1480: cat stderr input: stderr: | 1//2 ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1478: cat stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + # + 1) = 1111 ./calc.at:1469: $PREPARSER ./calc input input: | 1 2 | (!!) + (1 2) = 1 ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1480: $PREPARSER ./calc input stderr: ./calc.at:1477: cat stderr stderr: stderr: stderr: syntax error: invalid character: '#' input: ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: cat stderr stderr: stderr: 1.3: syntax error syntax error, unexpected number error: 2222 != 1 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected number error: 2222 != 1 | (1 + 1) / (1 - 1) syntax error: invalid character: '#' ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 1.11-17: error: null divisor ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: cat stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1480: cat stderr stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1//2 | (1 + #) = 1111 ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1479: cat stderr ./calc.at:1476: $PREPARSER ./calc input stderr: stderr: input: stderr: 1.3: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11-17: error: null divisor syntax error: invalid character: '#' ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (- *) + (1 2) = 1 ./calc.at:1480: $PREPARSER ./calc input stderr: input: | error syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: cat stderr ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1479: $PREPARSER ./calc input syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 stderr: ./calc.at:1469: cat stderr ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' stderr: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected invalid token ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1478: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1469: $PREPARSER ./calc input stderr: error: null divisor ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1480: cat stderr stderr: stderr: stderr: syntax error, unexpected invalid token error: null divisor 1.11: syntax error 1.1-16: error: 2222 != 1 input: ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1478: $PREPARSER ./calc input input: ./calc.at:1478: cat stderr stderr: | (* *) + (*) + (*) 1.1: syntax error ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: cat stderr stderr: stderr: stderr: 1.1: syntax error 550. calc.at:1478: ok ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: cat stderr 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' | (# + 1) = 1111 ./calc.at:1476: $PREPARSER ./calc input stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 = 2 = 3 ./calc.at:1479: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1469: cat stderr ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: cat stderr stderr: syntax error, unexpected '=' ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 545. calc.at:1469: stderr: ok ./calc.at:1480: cat stderr syntax error: invalid character: '#' input: ./calc.at:1477: cat stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1480: $PREPARSER ./calc input stderr: syntax error, unexpected '=' 559. calc.at:1485: testing Calculator glr2.cc parse.error=detailed %debug %name-prefix "calc" %verbose ... ./calc.at:1485: mv calc.y.tmp calc.y input: | 1 = 2 = 3 ./calc.at:1478: $PREPARSER ./calc input stderr: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1485: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1480: $PREPARSER ./calc input 1.7: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (- *) + (1 2) = 1 1.7: syntax error ./calc.at:1477: $PREPARSER ./calc input stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: cat stderr ./calc.at:1476: cat stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: 560. calc.at:1486: testing Calculator C++ %glr-parser parse.error=verbose %debug %name-prefix "calc" %verbose ... ./calc.at:1486: mv calc.y.tmp calc.y input: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 | (1 + # + 1) = 1111 ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1486: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y syntax error: invalid character: '#' | | +1 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr ./calc.at:1479: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1478: cat stderr input: ./calc.at:1477: cat stderr stderr: | (#) + (#) = 2222 ./calc.at:1480: $PREPARSER ./calc input syntax error, unexpected '+' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (* *) + (*) + (*) ./calc.at:1477: $PREPARSER ./calc input syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' syntax error, unexpected '+' input: stderr: | | +1 ./calc.at:1478: $PREPARSER ./calc input 1.2: syntax error 1.10: syntax error 1.16: syntax error stderr: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 2.1: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: cat stderr ./calc.at:1486: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS input: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 ./calc.at:1480: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error 1.10: syntax error 1.16: syntax error stderr: ./calc.at:1476: cat stderr ./calc.at:1479: cat stderr 2.1: syntax error ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: $PREPARSER ./calc /dev/null stderr: syntax error, unexpected end of input ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + 1) / (1 - 1) ./calc.at:1476: $PREPARSER ./calc input stderr: ./calc.at:1480: cat stderr stderr: syntax error, unexpected end of input ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: cat stderr error: null divisor input: | (# + 1) = 1111 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: $PREPARSER ./calc input stderr: stdout: stderr: ./calc.at:1482: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc syntax error: invalid character: '#' stderr: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: null divisor input: ./calc.at:1478: cat stderr | 1 + 2 * 3 + !+ ++ input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1477: $PREPARSER ./calc input stderr: stdout: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1478: $PREPARSER ./calc /dev/null stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1479: cat stderr stderr: ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.1: syntax error stderr: | 1 2 ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: stderr: input: | 1 + 2 * 3 + !- ++ ./calc.at:1477: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) input: ./calc.at:1479: $PREPARSER ./calc input stderr: stderr: stderr: 1.1: syntax error syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 | 1 2 ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: cat stderr ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected number stderr: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 stderr: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 547. calc.at:1476: ok ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error, unexpected number ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: cat stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: ./calc.at:1482: cat stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1479: cat stderr | (1 + # + 1) = 1111 stderr: ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1480: cat stderr 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: cat stderr stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 stderr: input: input: 561. calc.at:1486: testing Calculator glr2.cc parse.error=verbose %debug %name-prefix "calc" %verbose ... syntax error: invalid character: '#' | (#) + (#) = 2222 ./calc.at:1486: mv calc.y.tmp calc.y ./calc.at:1477: $PREPARSER ./calc input | 1//2 input: input: ./calc.at:1480: $PREPARSER ./calc input | 1//2 ./calc.at:1482: $PREPARSER ./calc input stderr: stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1486: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (!!) + (1 2) = 1 stderr: ./calc.at:1479: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error, unexpected number error: 2222 != 1 stderr: ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () stderr: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected number error: 2222 != 1 ./calc.at:1478: cat stderr ./calc.at:1477: cat stderr ./calc.at:1480: cat stderr ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS input: | (1 + #) = 1111 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (!!) + (1 2) = 1 ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1482: cat stderr input: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr stderr: stderr: ./calc.at:1479: cat stderr input: | (1 + 1) / (1 - 1) ./calc.at:1480: $PREPARSER ./calc input | error 1.6: syntax error: invalid character: '#' 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: $PREPARSER ./calc input stderr: stderr: stderr: syntax error, unexpected invalid token input: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error error: null divisor ./calc.at:1482: $PREPARSER ./calc input stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 input: Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error Cleanup: discarding lookahead token "invalid token" () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1479: $PREPARSER ./calc input syntax error, unexpected invalid token stderr: stderr: error: null divisor syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: cat stderr stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error Cleanup: discarding lookahead token "invalid token" () ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (# + 1) = 1111 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1479: cat stderr stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (* *) + (*) + (*) ./calc.at:1479: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' stderr: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr ./calc.at:1482: cat stderr ./calc.at:1480: cat stderr 554. calc.at:1480: ok ./calc.at:1478: cat stderr ./calc.at:1477: cat stderr input: input: | (- *) + (1 2) = 1 ./calc.at:1478: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1480: $PREPARSER ./calc input stderr: input: input: | 1 = 2 = 3 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 | (1 + # + 1) = 1111 stderr: ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: $PREPARSER ./calc input syntax error, unexpected '=' ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.6: syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1479: cat stderr stderr: 1.6: syntax error: invalid character: '#' syntax error, unexpected '=' ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 562. calc.at:1487: testing Calculator glr2.cc parse.error=custom %debug %name-prefix "calc" %verbose ... | 1 + 2 * 3 + !+ ++ ./calc.at:1479: $PREPARSER ./calc input stderr: ./calc.at:1487: mv calc.y.tmp calc.y ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: cat stderr ./calc.at:1477: cat stderr ./calc.at:1487: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + 1) / (1 - 1) ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1480: cat stderr input: input: | (* *) + (*) + (*) ./calc.at:1478: $PREPARSER ./calc input stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1479: $PREPARSER ./calc input 1.11-17: error: null divisor stderr: ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1482: cat stderr ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | | +1 ./calc.at:1480: $PREPARSER ./calc input stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error stderr: stderr: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected '+' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.11-17: error: null divisor ./calc.at:1479: cat stderr ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1482: $PREPARSER ./calc input input: | (#) + (#) = 2222 ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1487: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error, unexpected '+' syntax error: invalid character: '#' syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: cat stderr ./calc.at:1477: cat stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error Error: popping nterm input () Cleanup: discarding lookahead token '+' () input: 549. calc.at:1477: ok | 1 + 2 * 3 + !+ ++ ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !- ++ ./calc.at:1478: $PREPARSER ./calc input stderr: ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1480: cat stderr ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: cat stderr ./calc.at:1478: cat stderr ./calc.at:1480: $PREPARSER ./calc /dev/null ./calc.at:1482: cat stderr stderr: syntax error, unexpected end of input input: input: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1479: $PREPARSER ./calc input stderr: | (#) + (#) = 2222 syntax error: invalid character: '#' ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: $PREPARSER ./calc /dev/null stderr: stderr: stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' syntax error, unexpected end of input ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" () 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 563. calc.at:1489: testing Calculator C++ %glr-parser parse.error=verbose %debug %name-prefix "calc" api.token.prefix={TOK_} %verbose ... ./calc.at:1489: mv calc.y.tmp calc.y ./calc.at:1489: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: cat stderr ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr stderr: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: stdout: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 | (# + 1) = 1111 ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1478: cat stderr ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1485: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: syntax error: invalid character: '#' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: cat stderr stderr: stderr: syntax error: invalid character: '#' input: syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 input: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1485: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1482: $PREPARSER ./calc input | (1 + #) = 1111 stderr: ./calc.at:1478: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () input: input: stderr: | (!!) + (1 2) = 1 | 1 2 ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1485: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: cat stderr syntax error, unexpected number error: 2222 != 1 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) input: | (1 + # + 1) = 1111 ./calc.at:1479: $PREPARSER ./calc input stderr: stderr: syntax error: invalid character: '#' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected number error: 2222 != 1 stderr: ./calc.at:1478: cat stderr syntax error: invalid character: '#' ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr ./calc.at:1485: cat stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | (- *) + (1 2) = 1 ./calc.at:1480: $PREPARSER ./calc input input: stderr: input: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 | (!!) + (1 2) = 1 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: $PREPARSER ./calc input | 1//2 | (# + 1) = 1111 ./calc.at:1485: $PREPARSER ./calc input stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1479: cat stderr ./calc.at:1478: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: cat stderr input: 1.2: syntax error: invalid character: '#' ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (* *) + (*) + (*) ./calc.at:1480: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' | (1 + 1) / (1 - 1) ./calc.at:1479: $PREPARSER ./calc input stderr: stderr: stderr: error: null divisor Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' stderr: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 error: null divisor ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr input: ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (- *) + (1 2) = 1 ./calc.at:1482: $PREPARSER ./calc input stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1478: cat stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1480: $PREPARSER ./calc input stderr: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1485: cat stderr stderr: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !- ++ ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1479: cat stderr stderr: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (1 + # + 1) = 1111 ./calc.at:1478: $PREPARSER ./calc input 552. calc.at:1479: ok ./calc.at:1482: cat stderr input: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1480: cat stderr stderr: 1.6: syntax error: invalid character: '#' input: | (#) + (#) = 2222 ./calc.at:1480: $PREPARSER ./calc input input: stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' | (* *) + (*) + (*) ./calc.at:1482: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () stderr: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () ./calc.at:1478: cat stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: input: ./calc.at:1480: cat stderr ./calc.at:1479: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh input: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1479: $PREPARSER ./calc input stderr: | (1 + 1) / (1 - 1) ./calc.at:1478: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: 1.11-17: error: null divisor ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1480: $PREPARSER ./calc input stderr: 564. calc.at:1489: testing Calculator glr2.cc parse.error=verbose %debug %name-prefix "calc" api.token.prefix={TOK_} %verbose ... stderr: ./calc.at:1489: mv calc.y.tmp calc.y input: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1489: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: 1.11-17: error: null divisor stderr: ./calc.at:1482: cat stderr syntax error: invalid character: '#' ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected number ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1485: cat stderr stderr: stderr: syntax error, unexpected number Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1478: cat stderr input: input: | 1 = 2 = 3 ./calc.at:1485: $PREPARSER ./calc input 551. calc.at:1478: | 1 + 2 * 3 + !- ++ ok ./calc.at:1482: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1489: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1480: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) input: | 1//2 ./calc.at:1479: $PREPARSER ./calc input stderr: input: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 ./calc.at:1480: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 565. calc.at:1491: testing Calculator C++ %glr-parser %locations %header parse.error=verbose %debug %name-prefix "calc" %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1485: cat stderr ./calc.at:1491: mv calc.y.tmp calc.y stderr: syntax error: invalid character: '#' ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr input: ./calc.at:1479: cat stderr | | +1 ./calc.at:1485: $PREPARSER ./calc input stderr: ./calc.at:1491: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () input: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (#) + (#) = 2222 ./calc.at:1482: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | error ./calc.at:1480: cat stderr ./calc.at:1479: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: stderr: | (1 + # + 1) = 1111 ./calc.at:1480: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected invalid token ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected invalid token stderr: syntax error: invalid character: '#' ./calc.at:1485: cat stderr ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr ./calc.at:1485: $PREPARSER ./calc /dev/null ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr stderr: Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of file Cleanup: discarding lookahead token end of file () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + 1) / (1 - 1) ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1479: cat stderr stderr: stderr: error: null divisor stderr: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of file Cleanup: discarding lookahead token end of file () input: stdout: stderr: | (1 + #) = 1111 ./calc.at:1482: $PREPARSER ./calc input error: null divisor ./calc.at:1486: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: cat stderr input: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 | 1 = 2 = 3 ./calc.at:1486: $PREPARSER ./calc input ./calc.at:1479: $PREPARSER ./calc input stderr: stderr: syntax error, unexpected '=' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected '=' stderr: 555. calc.at:1480: ok stderr: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: ./calc.at:1479: cat stderr | 1 2 input: ./calc.at:1486: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1485: $PREPARSER ./calc input input: | | +1 ./calc.at:1479: $PREPARSER ./calc input stderr: syntax error, unexpected '+' stderr: ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error, unexpected '+' Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: cat stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1479: $PREPARSER ./calc /dev/null stderr: syntax error, unexpected end of input ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 566. calc.at:1491: testing Calculator glr2.cc %locations %header parse.error=verbose %debug %name-prefix "calc" %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1491: mv calc.y.tmp calc.y ./calc.at:1491: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1482: cat stderr stderr: syntax error, unexpected end of input ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1485: cat stderr ./calc.at:1486: cat stderr ./calc.at:1491: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS | (# + 1) = 1111 ./calc.at:1482: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1479: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: input: input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 120): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1479: $PREPARSER ./calc input stderr: syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 120): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr ./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () input: | (- *) + (1 2) = 1 ./calc.at:1485: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 119): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 119): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1479: cat stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + # + 1) = 1111 ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1485: cat stderr stderr: input: input: | (* *) + (*) + (*) ./calc.at:1485: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: cat stderr ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () | (!!) + (1 2) = 1 ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: $PREPARSER ./calc input input: stderr: | error ./calc.at:1486: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: stderr: syntax error, unexpected number error: 2222 != 1 ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected number error: 2222 != 1 stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" () ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: cat stderr input: | 1 + 2 * 3 + !+ ++ ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr stderr: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 121): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: cat stderr input: ./calc.at:1479: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1482: $PREPARSER ./calc input input: stderr: | 1 = 2 = 3 ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 121): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () input: | 1 + 2 * 3 + !- ++ stderr: ./calc.at:1485: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 122): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 122): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) input: | (- *) + (1 2) = 1 ./calc.at:1479: $PREPARSER ./calc input stdout: stderr: ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1485: cat stderr stderr: ./calc.at:1482: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (#) + (#) = 2222 syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1485: $PREPARSER ./calc input stderr: input: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: cat stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | | +1 ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1482: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1479: cat stderr input: | 1 2 ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 556. calc.at:1482: ok ./calc.at:1485: cat stderr input: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1486: cat stderr stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) | (1 + #) = 1111 ./calc.at:1485: $PREPARSER ./calc input syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: $PREPARSER ./calc /dev/null stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" () ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: cat stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1486: $PREPARSER ./calc input stderr: ./calc.at:1482: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 567. calc.at:1492: testing Calculator C++ %glr-parser %locations %header parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: ./calc.at:1492: mv calc.y.tmp calc.y | 1//2 ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: cat stderr ./calc.at:1485: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 ./calc.at:1485: $PREPARSER ./calc input stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1492: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: ./calc.at:1486: cat stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1479: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (!!) + (1 2) = 1 ./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: ./calc.at:1482: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: | error ./calc.at:1482: $PREPARSER ./calc input input: stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error Cleanup: discarding lookahead token "invalid token" () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: | 1 + 2 * 3 + !- ++ Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error Cleanup: discarding lookahead token "invalid token" () ./calc.at:1479: $PREPARSER ./calc input stderr: ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: ./calc.at:1489: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS input: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1489: $PREPARSER ./calc input ./calc.at:1485: cat stderr ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: | (1 + # + 1) = 1111 ./calc.at:1485: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr | 1 2 ./calc.at:1489: $PREPARSER ./calc input input: stderr: | (- *) + (1 2) = 1 ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) ./calc.at:1486: $PREPARSER ./calc input ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1479: cat stderr ./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | 1 = 2 = 3 stderr: ./calc.at:1482: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: | (1 + 1) / (1 - 1) ./calc.at:1485: $PREPARSER ./calc input input: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () | (#) + (#) = 2222 ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 106): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 106): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: cat stderr ./calc.at:1489: cat stderr ./calc.at:1486: cat stderr ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | (1 + #) = 1111 input: ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1485: cat stderr | 1//2 ./calc.at:1489: $PREPARSER ./calc input | (* *) + (*) + (*) ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: stderr: syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: cat stderr ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 558. calc.at:1485: ok stderr: stderr: stderr: syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: | | +1 ./calc.at:1482: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: cat stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error Error: popping nterm input () Cleanup: discarding lookahead token '+' () 568. calc.at:1492: testing Calculator glr2.cc %locations %header parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1492: mv calc.y.tmp calc.y ./calc.at:1489: cat stderr input: ./calc.at:1492: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y | (# + 1) = 1111 ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1486: cat stderr stderr: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: syntax error: invalid character: '#' input: ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1489: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: stderr: syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: cat stderr Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" () ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: $PREPARSER ./calc /dev/null stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1492: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS ./calc.at:1479: cat stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" () input: ./calc.at:1489: cat stderr ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: input: | 1 = 2 = 3 input: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" () stderr: | (1 + # + 1) = 1111 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) stderr: stderr: syntax error: invalid character: '#' ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: cat stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr ./calc.at:1489: cat stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1482: $PREPARSER ./calc input | (#) + (#) = 2222 ./calc.at:1479: cat stderr ./calc.at:1486: $PREPARSER ./calc input input: stderr: | | +1 ./calc.at:1489: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + 1) / (1 - 1) stderr: ./calc.at:1479: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stdout: stderr: ./calc.at:1485: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () stderr: stderr: error: null divisor ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1489: cat stderr ./calc.at:1489: $PREPARSER ./calc /dev/null stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" () error: null divisor ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () input: | 1 2 ./calc.at:1485: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" () ./calc.at:1482: cat stderr ./calc.at:1486: cat stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + #) = 1111 ./calc.at:1485: cat stderr | (!!) + (1 2) = 1 ./calc.at:1486: $PREPARSER ./calc input ./calc.at:1482: $PREPARSER ./calc input stderr: ./calc.at:1479: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: 553. calc.at:1479: | 1//2 ok ./calc.at:1485: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: cat stderr input: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1489: $PREPARSER ./calc input input: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | error ./calc.at:1486: cat stderr ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1482: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (- *) + (1 2) = 1 ./calc.at:1482: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () | (# + 1) = 1111 ./calc.at:1486: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () 569. calc.at:1494: testing Calculator C++ %glr-parser %no-lines %locations %header parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1494: mv calc.y.tmp calc.y ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1494: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stdout: ./calc.at:1485: cat stderr ./calc.at:1486: cat stderr ./calc.at:1489: cat stderr ./calc.at:1486: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc input: input: input: input: ./calc.at:1482: cat stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1486: $PREPARSER ./calc input | (1 + # + 1) = 1111 | 1 = 2 = 3 ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1486: $PREPARSER ./calc input | (!!) + (1 2) = 1 ./calc.at:1489: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () | (* *) + (*) + (*) ./calc.at:1494: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS ./calc.at:1482: $PREPARSER ./calc input stderr: input: stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: cat stderr stderr: ./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: cat stderr input: input: | (1 + 1) / (1 - 1) input: ./calc.at:1486: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1489: $PREPARSER ./calc input | | +1 stderr: ./calc.at:1485: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1486: cat stderr input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1482: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) input: ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: cat stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1485: cat stderr | 1 + 2 * 3 + !- ++ ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1486: cat stderr stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1485: $PREPARSER ./calc /dev/null | (* *) + (*) + (*) ./calc.at:1489: $PREPARSER ./calc input ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of file Cleanup: discarding lookahead token end of file () stderr: ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 560. calc.at:1486: ok Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of file Cleanup: discarding lookahead token end of file () ./calc.at:1486: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | error ./calc.at:1486: $PREPARSER ./calc input ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: cat stderr ./calc.at:1485: cat stderr ./calc.at:1489: cat stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () input: input: stdout: | (#) + (#) = 2222 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1491: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh input: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1489: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stdout: 570. calc.at:1494: testing Calculator glr2.cc %no-lines %locations %header parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) input: ./calc.at:1494: mv calc.y.tmp calc.y ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1487: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1486: cat stderr ./calc.at:1494: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 input: ./calc.at:1487: $PREPARSER ./calc input ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: $PREPARSER ./calc input stderr: input: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1482: cat stderr ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () | 1 2 ./calc.at:1485: cat stderr ./calc.at:1491: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) | 1 2 Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () input: ./calc.at:1487: $PREPARSER ./calc input | (1 + #) = 1111 ./calc.at:1482: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1494: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS stderr: | (!!) + (1 2) = 1 ./calc.at:1485: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 120): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1489: cat stderr ./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 120): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: cat stderr input: ./calc.at:1491: cat stderr | (#) + (#) = 2222 input: ./calc.at:1489: $PREPARSER ./calc input | | +1 stderr: ./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: input: ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stdout: ./calc.at:1487: $PREPARSER ./calc input stderr: input: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1489: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () stderr: ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1491: $PREPARSER ./calc input input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1489: $PREPARSER ./calc input stderr: stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) stderr: ./calc.at:1482: cat stderr | (- *) + (1 2) = 1 ./calc.at:1485: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (# + 1) = 1111 ./calc.at:1482: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 119): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: input: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 119): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: cat stderr ./calc.at:1489: cat stderr | 1 2 stderr: ./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: ./calc.at:1491: cat stderr ./calc.at:1486: $PREPARSER ./calc /dev/null stderr: | error stderr: | (1 + #) = 1111 ./calc.at:1487: $PREPARSER ./calc input ./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token end of input () stderr: stderr: ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) Cleanup: discarding lookahead token invalid token () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1491: $PREPARSER ./calc input stderr: ./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token end of input () stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) Cleanup: discarding lookahead token invalid token () Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: cat stderr | (* *) + (*) + (*) ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1489: cat stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1487: cat stderr | (1 + # + 1) = 1111 ./calc.at:1482: $PREPARSER ./calc input input: stderr: ./calc.at:1486: cat stderr ./calc.at:1489: cat stderr stderr: | 1//2 ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 input: stderr: ./calc.at:1487: $PREPARSER ./calc input input: | (# + 1) = 1111 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: $PREPARSER ./calc input stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () | 1 = 2 = 3 ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !+ ++ stderr: ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) stderr: ./calc.at:1487: cat stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 121): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: cat stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: input: stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 121): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) | (1 + 1) / (1 - 1) | error ./calc.at:1489: $PREPARSER ./calc input | | +1 ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1487: $PREPARSER ./calc input ./calc.at:1486: cat stderr stderr: input: input: | (1 + # + 1) = 1111 stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1489: $PREPARSER ./calc input stderr: ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 122): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: | (!!) + (1 2) = 1 Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () ./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) Error: popping nterm input () Cleanup: discarding lookahead token '+' () stderr: input: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 122): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () | | +1 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1487: cat stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1482: cat stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1487: $PREPARSER ./calc /dev/null ./calc.at:1489: cat stderr ./calc.at:1485: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) Starting parse Entering state 0 Reading a token Now at end of input. syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) Cleanup: discarding lookahead token end of file () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: cat stderr 557. calc.at:1482: ok stderr: input: input: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Now at end of input. syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) Cleanup: discarding lookahead token end of file () | 1 = 2 = 3 | (#) + (#) = 2222 ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1489: $PREPARSER ./calc input stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: stdout: | (1 + 1) / (1 - 1) stderr: ./calc.at:1486: cat stderr ./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1492: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1491: cat stderr ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: input: | (- *) + (1 2) = 1 ./calc.at:1486: $PREPARSER ./calc input ./calc.at:1487: cat stderr ./calc.at:1491: $PREPARSER ./calc /dev/null | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: ./calc.at:1492: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: input: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1487: $PREPARSER ./calc input ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 571. calc.at:1504: testing Calculator lalr1.d ... stderr: stderr: stderr: ./calc.at:1504: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1485: cat stderr input: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 ./calc.at:1492: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: ./calc.at:1489: cat stderr ./calc.at:1489: cat stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 ./calc.at:1485: $PREPARSER ./calc input 571. calc.at:1504: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: skipped (calc.at:1504) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () 563. calc.at:1489: ok ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1486: cat stderr | | +1 ./calc.at:1489: $PREPARSER ./calc input ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1487: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 input: stderr: ./calc.at:1491: $PREPARSER ./calc input stderr: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () | (!!) + (1 2) = 1 ./calc.at:1487: $PREPARSER ./calc input stderr: ./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 120): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 120): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1492: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 572. calc.at:1509: testing Calculator D ... ./calc.at:1509: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y | 1//2 ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: $PREPARSER ./calc input ./calc.at:1485: cat stderr ./calc.at:1491: cat stderr stderr: ./calc.at:1487: cat stderr ./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 573. calc.at:1510: testing Calculator D %locations ... ./calc.at:1510: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y ./calc.at:1489: $PREPARSER ./calc /dev/null | (!!) + (1 2) = 1 ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: | (# + 1) = 1111 ./calc.at:1486: cat stderr ./calc.at:1485: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token end of input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: stderr: | (- *) + (1 2) = 1 ./calc.at:1487: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 572. calc.at:1509: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 119): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) skipped (calc.at:1509) stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 119): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 573. calc.at:1510: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token end of input () | 1 + 2 * 3 + !+ ++ ./calc.at:1486: $PREPARSER ./calc input skipped (calc.at:1510) stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1487: cat stderr ./calc.at:1492: cat stderr stderr: input: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1491: cat stderr input: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !- ++ | (* *) + (*) + (*) ./calc.at:1487: $PREPARSER ./calc input ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) input: ./calc.at:1485: cat stderr ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () | error stderr: ./calc.at:1492: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) input: input: | (- *) + (1 2) = 1 input: ./calc.at:1491: $PREPARSER ./calc input | (1 + # + 1) = 1111 ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1485: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1487: cat stderr stderr: ./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: stderr: 575. calc.at:1514: testing Calculator D %debug ... Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 574. calc.at:1512: testing Calculator D parse.error=detailed api.prefix={calc} %verbose ... Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1512: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y | 1 + 2 * 3 + !+ ++ ./calc.at:1487: $PREPARSER ./calc input ./calc.at:1514: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y stderr: stderr: ./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 121): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1485: cat stderr input: ./calc.at:1492: cat stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 121): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 574. calc.at:1512: | 1 = 2 = 3 ./calc.at:1492: $PREPARSER ./calc input input: | (#) + (#) = 2222 | 1 + 2 * 3 + !- ++ stderr: skipped (calc.at:1512) ./calc.at:1486: $PREPARSER ./calc input 575. calc.at:1514: ./calc.at:1487: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1491: cat stderr input: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr skipped (calc.at:1514) stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 122): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (1 + 1) / (1 - 1) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (* *) + (*) + (*) ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 122): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1491: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 106): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: cat stderr ./calc.at:1489: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | | +1 ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: | (!!) + (1 2) = 1 ./calc.at:1489: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 106): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1487: cat stderr ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 577. calc.at:1517: testing Calculator D %locations parse.error=custom ... ./calc.at:1491: cat stderr ./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: ./calc.at:1517: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y 576. calc.at:1516: testing Calculator D parse.error=custom ... ./calc.at:1516: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) input: input: | (#) + (#) = 2222 ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !+ ++ ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1487: $PREPARSER ./calc input stderr: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 ./calc.at:1486: $PREPARSER ./calc input ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: cat stderr ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1492: $PREPARSER ./calc /dev/null 576. calc.at:1516: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) input: | (- *) + (1 2) = 1 577. calc.at:1517: ./calc.at:1489: $PREPARSER ./calc input 559. calc.at:1485: ok stderr: skipped (calc.at:1517) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () skipped (calc.at:1516) ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1486: cat stderr input: | 1 + 2 * 3 + !- ++ ./calc.at:1491: $PREPARSER ./calc input stderr: ./calc.at:1487: cat stderr stderr: input: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) | (# + 1) = 1111 ./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: cat stderr stderr: input: | (1 + #) = 1111 ./calc.at:1487: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () 578. calc.at:1518: testing Calculator D %locations parse.error=detailed ... ./calc.at:1518: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) ./calc.at:1492: cat stderr ./calc.at:1489: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 578. calc.at:1518: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: cat stderr skipped (calc.at:1518) ./calc.at:1486: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1487: cat stderr 579. calc.at:1519: testing Calculator D %locations parse.error=simple ... input: ./calc.at:1519: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y | (1 + # + 1) = 1111 ./calc.at:1486: $PREPARSER ./calc input input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1492: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | (#) + (#) = 2222 ./calc.at:1491: $PREPARSER ./calc input | (# + 1) = 1111 stderr: 580. calc.at:1520: testing Calculator D parse.error=detailed %debug %verbose ... ./calc.at:1520: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1489: cat stderr ./calc.at:1487: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 581. calc.at:1521: testing Calculator D parse.error=detailed %debug api.symbol.prefix={SYMB_} api.token.prefix={TOK_} %verbose ... Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) input: | 1 + 2 * 3 + !- ++ ./calc.at:1489: $PREPARSER ./calc input ./calc.at:1521: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1486: cat stderr 579. calc.at:1519: skipped (calc.at:1519) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1487: cat stderr input: ./calc.at:1492: cat stderr input: | (1 + # + 1) = 1111 ./calc.at:1487: $PREPARSER ./calc input stderr: | (1 + 1) / (1 - 1) stderr: ./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) 581. calc.at:1521: 580. calc.at:1520: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1491: cat stderr stderr: skipped (calc.at:1521) skipped (calc.at:1520) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 ./calc.at:1492: $PREPARSER ./calc input stderr: input: | (1 + #) = 1111 ./calc.at:1491: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () 582. calc.at:1523: testing Calculator D %locations parse.lac=full parse.error=detailed ... ./calc.at:1523: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stderr: ./calc.at:1494: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1487: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stdout: ./calc.at:1491: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1489: cat stderr 582. calc.at:1523: stderr: input: skipped (calc.at:1523) ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1491: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 583. calc.at:1524: testing Calculator D %locations parse.lac=full parse.error=custom ... | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1486: cat stderr ./calc.at:1492: cat stderr ./calc.at:1524: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y ./calc.at:1494: $PREPARSER ./calc input input: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (14.1: ) Entering state 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: | (1 + 1) / (1 - 1) ./calc.at:1487: $PREPARSER ./calc input 561. calc.at:1486: ok Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (#) + (#) = 2222 ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1489: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () | (- *) + (1 2) = 1 ./calc.at:1492: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (14.1: ) Entering state 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 106): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 584. calc.at:1525: testing Calculator D %locations parse.lac=full parse.error=detailed parse.trace ... ./calc.at:1525: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y stderr: input: ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (stderr: 5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) | 1 2 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: 585. calc.at:1530: testing Calculator D api.token.constructor %locations parse.error=custom api.value.type=union ... Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 106): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1491: $PREPARSER ./calc input stderr: input: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token number (1.3: 2) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1530: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 stderr: ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token number (1.3: 2) stderr: 584. calc.at:1525: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 583. calc.at:1524: stderr: input: ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) skipped (calc.at:1525) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) skipped (calc.at:1524) | (# + 1) = 1111 ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: ./calc.at:1487: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) 586. calc.at:1531: testing Calculator D api.token.constructor %locations parse.error=detailed ... ./calc.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1//2 ./calc.at:1491: $PREPARSER ./calc input stderr: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 585. calc.at:1530: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) 562. calc.at:1487: ok ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) skipped (calc.at:1530) ./calc.at:1494: cat stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: cat stderr ./calc.at:1492: cat stderr stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 588. calc.at:1533: testing Calculator D parse.trace parse.error=custom %locations api.push-pull=both parse.lac=full ... ./calc.at:1533: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y input: input: 586. calc.at:1531: | (* *) + (*) + (*) Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1492: $PREPARSER ./calc input | 1//2 ./calc.at:1494: $PREPARSER ./calc input skipped (calc.at:1531) input: | (1 + #) = 1111 ./calc.at:1489: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 587. calc.at:1532: testing Calculator D api.push-pull=both ... ./calc.at:1532: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () 588. calc.at:1533: skipped (calc.at:1533) input: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 589. calc.at:1544: testing Calculator Java ... | (1 + # + 1) = 1111 ./calc.at:1491: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 590. calc.at:1545: testing Calculator Java parse.error=custom ... ./calc.at:1545: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y ./calc.at:1491: cat stderr ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1544: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1494: cat stderr 587. calc.at:1532: stderr: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | error ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1492: cat stderr skipped (calc.at:1532) 591. calc.at:1546: testing Calculator Java parse.error=detailed ... ./calc.at:1546: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) ./calc.at:1489: cat stderr ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 590. calc.at:1545: input: | error ./calc.at:1494: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1492: $PREPARSER ./calc input 589. calc.at:1544: skipped (calc.at:1545) stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) input: | (# + 1) = 1111 ./calc.at:1489: $PREPARSER ./calc input 591. calc.at:1546: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1491: cat stderr stderr: skipped (calc.at:1544) skipped (calc.at:1546) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) input: 592. calc.at:1547: testing Calculator Java parse.error=verbose ... ./calc.at:1547: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y stderr: ./calc.at:1491: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1491: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () input: 593. calc.at:1548: testing Calculator Java %locations parse.error=custom ... ./calc.at:1548: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 + !- ++ ./calc.at:1492: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: cat stderr stderr: stderr: 595. calc.at:1550: testing Calculator Java %locations parse.error=verbose ... ./calc.at:1550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 592. calc.at:1547: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 594. calc.at:1549: testing Calculator Java %locations parse.error=detailed ... 596. calc.at:1551: testing Calculator Java parse.trace parse.error=verbose ... ./calc.at:1551: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y ./calc.at:1549: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y ./calc.at:1489: cat stderr skipped (calc.at:1547) input: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | 1 = 2 = 3 ./calc.at:1494: $PREPARSER ./calc input 593. calc.at:1548: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) skipped (calc.at:1548) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + # + 1) = 1111 ./calc.at:1489: $PREPARSER ./calc input ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 596. calc.at:1551: 595. calc.at:1550: 594. calc.at:1549: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr skipped (calc.at:1549) skipped (calc.at:1551) ./calc.at:1492: cat stderr ./calc.at:1491: cat stderr stderr: skipped (calc.at:1550) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1491: cat stderr 565. calc.at:1491: ok 597. calc.at:1552: testing Calculator Java parse.trace parse.error=verbose %locations %lex-param {InputStream is} ... input: ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1552: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y | (#) + (#) = 2222 input: ./calc.at:1494: cat stderr ./calc.at:1492: $PREPARSER ./calc input stderr: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1491: $PREPARSER ./calc input 598. calc.at:1554: testing Calculator Java api.push-pull=both ... ./calc.at:1554: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) | | +1 ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 599. calc.at:1555: testing Calculator Java api.push-pull=both parse.error=detailed %locations ... ./calc.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y 602. calc.at:1560: testing Calculator Java parse.trace parse.error=custom %locations parse.lac=full ... Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) stderr: input: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1560: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) | (1 + 1) / (1 - 1) ./calc.at:1489: $PREPARSER ./calc input 597. calc.at:1552: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 601. calc.at:1557: testing Calculator Java parse.trace parse.error=verbose %locations %lex-param {InputStream is} api.push-pull=both ... 599. calc.at:1555: 600. calc.at:1556: testing Calculator Java parse.trace parse.error=custom %locations %lex-param {InputStream is} api.push-pull=both ... ./calc.at:1556: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y skipped (calc.at:1555) ./calc.at:1492: cat stderr ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1557: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y skipped (calc.at:1552) 598. calc.at:1554: stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 skipped (calc.at:1554) ./calc.at:1494: cat stderr ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () input: | (1 + #) = 1111 ./calc.at:1492: $PREPARSER ./calc input ./calc.at:1491: $PREPARSER ./calc /dev/null stderr: ./calc.at:1494: $PREPARSER ./calc /dev/null stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: 602. calc.at:1560: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) skipped (calc.at:1560) Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 600. calc.at:1556: stderr: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) skipped (calc.at:1556) 601. calc.at:1557: ./calc.at:1489: cat stderr stderr: stderr: skipped (calc.at:1557) Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 605. torture.at:216: testing Big horizontal ... ./torture.at:230: "$PERL" -w ./gengram.pl 1000 || exit 77 604. torture.at:132: testing Big triangle ... ./torture.at:138: "$PERL" -w ./gengram.pl 200 || exit 77 564. calc.at:1489: ok stderr: stdout: %code top { /* -*- c -*- */ /* Adjust to the compiler. We used to do it here, but each time we add a new line, we have to adjust all the line numbers in error messages. It's simpler to use a constant include to a varying file. */ #include } %define parse.error verbose %debug %{ #include #include #define MAX 1000 static int yylex (void); #include /* !POSIX */ static void yyerror (const char *msg); %} %token t1 1 "1" t2 2 "2" t3 3 "3" t4 4 "4" t5 5 "5" t6 6 "6" t7 7 "7" t8 8 "8" t9 9 "9" t10 10 "10" t11 11 "11" t12 12 "12" t13 13 "13" t14 14 "14" t15 15 "15" t16 16 "16" t17 17 "17" t18 18 "18" t19 19 "19" t20 20 "20" t21 21 "21" t22 22 "22" t23 23 "23" t24 24 "24" t25 25 "25" t26 26 "26" t27 27 "27" t28 28 "28" t29 29 "29" t30 30 "30" t31 31 "31" t32 32 "32" t33 33 "33" t34 34 "34" t35 35 "35" t36 36 "36" t37 37 "37" t38 38 "38" t39 39 "39" t40 40 "40" t41 41 "41" t42 42 "42" t43 43 "43" t44 44 "44" t45 45 "45" t46 46 "46" t47 47 "47" t48 48 "48" t49 49 "49" t50 50 "50" t51 51 "51" t52 52 "52" t53 53 "53" t54 54 "54" t55 55 "55" t56 56 "56" t57 57 "57" t58 58 "58" t59 59 "59" t60 60 "60" t61 61 "61" t62 62 "62" t63 63 "63" t64 64 "64" t65 65 "65" t66 66 "66" t67 67 "67" t68 68 "68" t69 69 "69" t70 70 "70" t71 71 "71" t72 72 "72" t73 73 "73" t74 74 "74" t75 75 "75" t76 76 "76" t77 77 "77" t78 78 "78" t79 79 "79" t80 80 "80" t81 81 "81" t82 82 "82" t83 83 "83" t84 84 "84" t85 85 "85" t86 86 "86" t87 87 "87" t88 88 "88" t89 89 "89" t90 90 "90" t91 91 "91" t92 92 "92" t93 93 "93" t94 94 "94" t95 95 "95" t96 96 "96" t97 97 "97" t98 98 "98" t99 99 "99" t100 100 "100" t101 101 "101" t102 102 "102" t103 103 "103" t104 104 "104" t105 105 "105" t106 106 "106" t107 107 "107" t108 108 "108" t109 109 "109" t110 110 "110" t111 111 "111" t112 112 "112" t113 113 "113" t114 114 "114" t115 115 "115" t116 116 "116" t117 117 "117" t118 118 "118" t119 119 "119" t120 120 "120" t121 121 "121" t122 122 "122" t123 123 "123" t124 124 "124" t125 125 "125" t126 126 "126" t127 127 "127" t128 128 "128" t129 129 "129" t130 130 "130" t131 131 "131" t132 132 "132" t133 133 "133" t134 134 "134" t135 135 "135" t136 136 "136" t137 137 "137" t138 138 "138" t139 139 "139" t140 140 "140" t141 141 "141" t142 142 "142" t143 143 "143" t144 144 "144" t145 145 "145" t146 146 "146" t147 147 "147" t148 148 "148" t149 149 "149" t150 150 "150" t151 151 "151" t152 152 "152" t153 153 "153" t154 154 "154" t155 155 "155" t156 156 "156" t157 157 "157" t158 158 "158" t159 159 "159" t160 160 "160" t161 161 "161" t162 162 "162" t163 163 "163" t164 164 "164" t165 165 "165" t166 166 "166" t167 167 "167" t168 168 "168" t169 169 "169" t170 170 "170" t171 171 "171" t172 172 "172" t173 173 "173" t174 174 "174" t175 175 "175" t176 176 "176" t177 177 "177" t178 178 "178" t179 179 "179" t180 180 "180" t181 181 "181" t182 182 "182" t183 183 "183" t184 184 "184" t185 185 "185" t186 186 "186" t187 187 "187" t188 188 "188" t189 189 "189" t190 190 "190" t191 191 "191" t192 192 "192" t193 193 "193" t194 194 "194" t195 195 "195" t196 196 "196" t197 197 "197" t198 198 "198" t199 199 "199" t200 200 "200" t201 201 "201" t202 202 "202" t203 203 "203" t204 204 "204" t205 205 "205" t206 206 "206" t207 207 "207" t208 208 "208" t209 209 "209" t210 210 "210" t211 211 "211" t212 212 "212" t213 213 "213" t214 214 "214" t215 215 "215" t216 216 "216" t217 217 "217" t218 218 "218" t219 219 "219" t220 220 "220" t221 221 "221" t222 222 "222" t223 223 "223" t224 224 "224" t225 225 "225" t226 226 "226" t227 227 "227" t228 228 "228" t229 229 "229" t230 230 "230" t231 231 "231" t232 232 "232" t233 233 "233" t234 234 "234" t235 235 "235" t236 236 "236" t237 237 "237" t238 238 "238" t239 239 "239" t240 240 "240" t241 241 "241" t242 242 "242" t243 243 "243" t244 244 "244" t245 245 "245" t246 246 "246" t247 247 "247" t248 248 "248" t249 249 "249" t250 250 "250" t251 251 "251" t252 252 "252" t253 253 "253" t254 254 "254" t255 255 "255" t256 256 "256" t257 257 "257" t258 258 "258" t259 259 "259" t260 260 "260" t261 261 "261" t262 262 "262" t263 263 "263" t264 264 "264" t265 265 "265" t266 266 "266" t267 267 "267" t268 268 "268" t269 269 "269" t270 270 "270" t271 271 "271" t272 272 "272" t273 273 "273" t274 274 "274" t275 275 "275" t276 276 "276" t277 277 "277" t278 278 "278" t279 279 "279" t280 280 "280" t281 281 "281" t282 282 "282" t283 283 "283" t284 284 "284" t285 285 "285" t286 286 "286" t287 287 "287" t288 288 "288" t289 289 "289" t290 290 "290" t291 291 "291" t292 292 "292" t293 293 "293" t294 294 "294" t295 295 "295" t296 296 "296" t297 297 "297" t298 298 "298" t299 299 "299" t300 300 "300" t301 301 "301" t302 302 "302" t303 303 "303" t304 304 "304" t305 305 "305" t306 306 "306" t307 307 "307" t308 308 "308" t309 309 "309" t310 310 "310" t311 311 "311" t312 312 "312" t313 313 "313" t314 314 "314" t315 315 "315" t316 316 "316" t317 317 "317" t318 318 "318" t319 319 "319" t320 320 "320" t321 321 "321" t322 322 "322" t323 323 "323" t324 324 "324" t325 325 "325" t326 326 "326" t327 327 "327" t328 328 "328" t329 329 "329" t330 330 "330" t331 331 "331" t332 332 "332" t333 333 "333" t334 334 "334" t335 335 "335" t336 336 "336" t337 337 "337" t338 338 "338" t339 339 "339" t340 340 "340" t341 341 "341" t342 342 "342" t343 343 "343" t344 344 "344" t345 345 "345" t346 346 "346" t347 347 "347" t348 348 "348" t349 349 "349" t350 350 "350" t351 351 "351" t352 352 "352" t353 353 "353" t354 354 "354" t355 355 "355" t356 356 "356" t357 357 "357" t358 358 "358" t359 359 "359" t360 360 "360" t361 361 "361" t362 362 "362" t363 363 "363" t364 364 "364" t365 365 "365" t366 366 "366" t367 367 "367" t368 368 "368" t369 369 "369" t370 370 "370" t371 371 "371" t372 372 "372" t373 373 "373" t374 374 "374" t375 375 "375" t376 376 "376" t377 377 "377" t378 378 "378" t379 379 "379" t380 380 "380" t381 381 "381" t382 382 "382" t383 383 "383" t384 384 "384" t385 385 "385" t386 386 "386" t387 387 "387" t388 388 "388" t389 389 "389" t390 390 "390" t391 391 "391" t392 392 "392" t393 393 "393" t394 394 "394" t395 395 "395" t396 396 "396" t397 397 "397" t398 398 "398" t399 399 "399" t400 400 "400" t401 401 "401" t402 402 "402" t403 403 "403" t404 404 "404" t405 405 "405" t406 406 "406" t407 407 "407" t408 408 "408" t409 409 "409" t410 410 "410" t411 411 "411" t412 412 "412" t413 413 "413" t414 414 "414" t415 415 "415" t416 416 "416" t417 417 "417" t418 418 "418" t419 419 "419" t420 420 "420" t421 421 "421" t422 422 "422" t423 423 "423" t424 424 "424" t425 425 "425" t426 426 "426" t427 427 "427" t428 428 "428" t429 429 "429" t430 430 "430" t431 431 "431" t432 432 "432" t433 433 "433" t434 434 "434" t435 435 "435" t436 436 "436" t437 437 "437" t438 438 "438" t439 439 "439" t440 440 "440" t441 441 "441" t442 442 "442" t443 443 "443" t444 444 "444" t445 445 "445" t446 446 "446" t447 447 "447" t448 448 "448" t449 449 "449" t450 450 "450" t451 451 "451" t452 452 "452" t453 453 "453" t454 454 "454" t455 455 "455" t456 456 "456" t457 457 "457" t458 458 "458" t459 459 "459" t460 460 "460" t461 461 "461" t462 462 "462" t463 463 "463" t464 464 "464" t465 465 "465" t466 466 "466" t467 467 "467" t468 468 "468" t469 469 "469" t470 470 "470" t471 471 "471" t472 472 "472" t473 473 "473" t474 474 "474" t475 475 "475" t476 476 "476" t477 477 "477" t478 478 "478" t479 479 "479" t480 480 "480" t481 481 "481" t482 482 "482" t483 483 "483" t484 484 "484" t485 485 "485" t486 486 "486" t487 487 "487" t488 488 "488" t489 489 "489" t490 490 "490" t491 491 "491" t492 492 "492" t493 493 "493" t494 494 "494" t495 495 "495" t496 496 "496" t497 497 "497" t498 498 "498" t499 499 "499" t500 500 "500" t501 501 "501" t502 502 "502" t503 503 "503" t504 504 "504" t505 505 "505" t506 506 "506" t507 507 "507" t508 508 "508" t509 509 "509" t510 510 "510" t511 511 "511" t512 512 "512" t513 513 "513" t514 514 "514" t515 515 "515" t516 516 "516" t517 517 "517" t518 518 "518" t519 519 "519" t520 520 "520" t521 521 "521" t522 522 "522" t523 523 "523" t524 524 "524" t525 525 "525" t526 526 "526" t527 527 "527" t528 528 "528" t529 529 "529" t530 530 "530" t531 531 "531" t532 532 "532" t533 533 "533" t534 534 "534" t535 535 "535" t536 536 "536" t537 537 "537" t538 538 "538" t539 539 "539" t540 540 "540" t541 541 "541" t542 542 "542" t543 543 "543" t544 544 "544" t545 545 "545" t546 546 "546" t547 547 "547" t548 548 "548" t549 549 "549" t550 550 "550" t551 551 "551" t552 552 "552" t553 553 "553" t554 554 "554" t555 555 "555" t556 556 "556" t557 557 "557" t558 558 "558" t559 559 "559" t560 560 "560" t561 561 "561" t562 562 "562" t563 563 "563" t564 564 "564" t565 565 "565" t566 566 "566" t567 567 "567" t568 568 "568" t569 569 "569" t570 570 "570" t571 571 "571" t572 572 "572" t573 573 "573" t574 574 "574" t575 575 "575" t576 576 "576" t577 577 "577" t578 578 "578" t579 579 "579" t580 580 "580" t581 581 "581" t582 582 "582" t583 583 "583" t584 584 "584" t585 585 "585" t586 586 "586" t587 587 "587" t588 588 "588" t589 589 "589" t590 590 "590" t591 591 "591" t592 592 "592" t593 593 "593" t594 594 "594" t595 595 "595" t596 596 "596" t597 597 "597" t598 598 "598" t599 599 "599" t600 600 "600" t601 601 "601" t602 602 "602" t603 603 "603" t604 604 "604" t605 605 "605" t606 606 "606" t607 607 "607" t608 608 "608" t609 609 "609" t610 610 "610" t611 611 "611" t612 612 "612" t613 613 "613" t614 614 "614" t615 615 "615" t616 616 "616" t617 617 "617" t618 618 "618" t619 619 "619" t620 620 "620" t621 621 "621" t622 622 "622" t623 623 "623" t624 624 "624" t625 625 "625" t626 626 "626" t627 627 "627" t628 628 "628" t629 629 "629" t630 630 "630" t631 631 "631" t632 632 "632" t633 633 "633" t634 634 "634" t635 635 "635" t636 636 "636" t637 637 "637" t638 638 "638" t639 639 "639" t640 640 "640" t641 641 "641" t642 642 "642" t643 643 "643" t644 644 "644" t645 645 "645" t646 646 "646" t647 647 "647" t648 648 "648" t649 649 "649" t650 650 "650" t651 651 "651" t652 652 "652" t653 653 "653" t654 654 "654" t655 655 "655" t656 656 "656" t657 657 "657" t658 658 "658" t659 659 "659" t660 660 "660" t661 661 "661" t662 662 "662" t663 663 "663" t664 664 "664" t665 665 "665" t666 666 "666" t667 667 "667" t668 668 "668" t669 669 "669" t670 670 "670" t671 671 "671" t672 672 "672" t673 673 "673" t674 674 "674" t675 675 "675" t676 676 "676" t677 677 "677" t678 678 "678" t679 679 "679" t680 680 "680" t681 681 "681" t682 682 "682" t683 683 "683" t684 684 "684" t685 685 "685" t686 686 "686" t687 687 "687" t688 688 "688" t689 689 "689" t690 690 "690" t691 691 "691" t692 692 "692" t693 693 "693" t694 694 "694" t695 695 "695" t696 696 "696" t697 697 "697" t698 698 "698" t699 699 "699" t700 700 "700" t701 701 "701" t702 702 "702" t703 703 "703" t704 704 "704" t705 705 "705" t706 706 "706" t707 707 "707" t708 708 "708" t709 709 "709" t710 710 "710" t711 711 "711" t712 712 "712" t713 713 "713" t714 714 "714" t715 715 "715" t716 716 "716" t717 717 "717" t718 718 "718" t719 719 "719" t720 720 "720" t721 721 "721" t722 722 "722" t723 723 "723" t724 724 "724" t725 725 "725" t726 726 "726" t727 727 "727" t728 728 "728" t729 729 "729" t730 730 "730" t731 731 "731" t732 732 "732" t733 733 "733" t734 734 "734" t735 735 "735" t736 736 "736" t737 737 "737" t738 738 "738" t739 739 "739" t740 740 "740" t741 741 "741" t742 742 "742" t743 743 "743" t744 744 "744" t745 745 "745" t746 746 "746" t747 747 "747" t748 748 "748" t749 749 "749" t750 750 "750" t751 751 "751" t752 752 "752" t753 753 "753" t754 754 "754" t755 755 "755" t756 756 "756" t757 757 "757" t758 758 "758" t759 759 "759" t760 760 "760" t761 761 "761" t762 762 "762" t763 763 "763" t764 764 "764" t765 765 "765" t766 766 "766" t767 767 "767" t768 768 "768" t769 769 "769" t770 770 "770" t771 771 "771" t772 772 "772" t773 773 "773" t774 774 "774" t775 775 "775" t776 776 "776" t777 777 "777" t778 778 "778" t779 779 "779" t780 780 "780" t781 781 "781" t782 782 "782" t783 783 "783" t784 784 "784" t785 785 "785" t786 786 "786" t787 787 "787" t788 788 "788" t789 789 "789" t790 790 "790" t791 791 "791" t792 792 "792" t793 793 "793" t794 794 "794" t795 795 "795" t796 796 "796" t797 797 "797" t798 798 "798" t799 799 "799" t800 800 "800" t801 801 "801" t802 802 "802" t803 803 "803" t804 804 "804" t805 805 "805" t806 806 "806" t807 807 "807" t808 808 "808" t809 809 "809" t810 810 "810" t811 811 "811" t812 812 "812" t813 813 "813" t814 814 "814" t815 815 "815" t816 816 "816" t817 817 "817" t818 818 "818" t819 819 "819" t820 820 "820" t821 821 "821" t822 822 "822" t823 823 "823" t824 824 "824" t825 825 "825" t826 826 "826" t827 827 "827" t828 828 "828" t829 829 "829" t830 830 "830" t831 831 "831" t832 832 "832" t833 833 "833" t834 834 "834" t835 835 "835" t836 836 "836" t837 837 "837" t838 838 "838" t839 839 "839" t840 840 "840" t841 841 "841" t842 842 "842" t843 843 "843" t844 844 "844" t845 845 "845" t846 846 "846" t847 847 "847" t848 848 "848" t849 849 "849" t850 850 "850" t851 851 "851" t852 852 "852" t853 853 "853" t854 854 "854" t855 855 "855" t856 856 "856" t857 857 "857" t858 858 "858" t859 859 "859" t860 860 "860" t861 861 "861" t862 862 "862" t863 863 "863" t864 864 "864" t865 865 "865" t866 866 "866" t867 867 "867" t868 868 "868" t869 869 "869" t870 870 "870" t871 871 "871" t872 872 "872" t873 873 "873" t874 874 "874" t875 875 "875" t876 876 "876" t877 877 "877" t878 878 "878" t879 879 "879" t880 880 "880" t881 881 "881" t882 882 "882" t883 883 "883" t884 884 "884" t885 885 "885" t886 886 "886" t887 887 "887" t888 888 "888" t889 889 "889" t890 890 "890" t891 891 "891" t892 892 "892" t893 893 "893" t894 894 "894" t895 895 "895" t896 896 "896" t897 897 "897" t898 898 "898" t899 899 "899" t900 900 "900" t901 901 "901" t902 902 "902" t903 903 "903" t904 904 "904" t905 905 "905" t906 906 "906" t907 907 "907" t908 908 "908" t909 909 "909" t910 910 "910" t911 911 "911" t912 912 "912" t913 913 "913" t914 914 "914" t915 915 "915" t916 916 "916" t917 917 "917" t918 918 "918" t919 919 "919" t920 920 "920" t921 921 "921" t922 922 "922" t923 923 "923" t924 924 "924" t925 925 "925" t926 926 "926" t927 927 "927" t928 928 "928" t929 929 "929" t930 930 "930" t931 931 "931" t932 932 "932" t933 933 "933" t934 934 "934" t935 935 "935" t936 936 "936" t937 937 "937" t938 938 "938" t939 939 "939" t940 940 "940" t941 941 "941" t942 942 "942" t943 943 "943" t944 944 "944" t945 945 "945" t946 946 "946" t947 947 "947" t948 948 "948" t949 949 "949" t950 950 "950" t951 951 "951" t952 952 "952" t953 953 "953" t954 954 "954" t955 955 "955" t956 956 "956" t957 957 "957" t958 958 "958" t959 959 "959" t960 960 "960" t961 961 "961" t962 962 "962" t963 963 "963" t964 964 "964" t965 965 "965" t966 966 "966" t967 967 "967" t968 968 "968" t969 969 "969" t970 970 "970" t971 971 "971" t972 972 "972" t973 973 "973" t974 974 "974" t975 975 "975" t976 976 "976" t977 977 "977" t978 978 "978" t979 979 "979" t980 980 "980" t981 981 "981" t982 982 "982" t983 983 "983" t984 984 "984" t985 985 "985" t986 986 "986" t987 987 "987" t988 988 "988" t989 989 "989" t990 990 "990" t991 991 "991" t992 992 "992" t993 993 "993" t994 994 "994" t995 995 "995" t996 996 "996" t997 997 "997" t998 998 "998" t999 999 "999" t1000 1000 "1000" %% exp: "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" "196" "197" "198" "199" "200" "201" "202" "203" "204" "205" "206" "207" "208" "209" "210" "211" "212" "213" "214" "215" "216" "217" "218" "219" "220" "221" "222" "223" "224" "225" "226" "227" "228" "229" "230" "231" "232" "233" "234" "235" "236" "237" "238" "239" "240" "241" "242" "243" "244" "245" "246" "247" "248" "249" "250" "251" "252" "253" "254" "255" "256" "257" "258" "259" "260" "261" "262" "263" "264" "265" "266" "267" "268" "269" "270" "271" "272" "273" "274" "275" "276" "277" "278" "279" "280" "281" "282" "283" "284" "285" "286" "287" "288" "289" "290" "291" "292" "293" "294" "295" "296" "297" "298" "299" "300" "301" "302" "303" "304" "305" "306" "307" "308" "309" "310" "311" "312" "313" "314" "315" "316" "317" "318" "319" "320" "321" "322" "323" "324" "325" "326" "327" "328" "329" "330" "331" "332" "333" "334" "335" "336" "337" "338" "339" "340" "341" "342" "343" "344" "345" "346" "347" "348" "349" "350" "351" "352" "353" "354" "355" "356" "357" "358" "359" "360" "361" "362" "363" "364" "365" "366" "367" "368" "369" "370" "371" "372" "373" "374" "375" "376" "377" "378" "379" "380" "381" "382" "383" "384" "385" "386" "387" "388" "389" "390" "391" "392" "393" "394" "395" "396" "397" "398" "399" "400" "401" "402" "403" "404" "405" "406" "407" "408" "409" "410" "411" "412" "413" "414" "415" "416" "417" "418" "419" "420" "421" "422" "423" "424" "425" "426" "427" "428" "429" "430" "431" "432" "433" "434" "435" "436" "437" "438" "439" "440" "441" "442" "443" "444" "445" "446" "447" "448" "449" "450" "451" "452" "453" "454" "455" "456" "457" "458" "459" "460" "461" "462" "463" "464" "465" "466" "467" "468" "469" "470" "471" "472" "473" "474" "475" "476" "477" "478" "479" "480" "481" "482" "483" "484" "485" "486" "487" "488" "489" "490" "491" "492" "493" "494" "495" "496" "497" "498" "499" "500" "501" "502" "503" "504" "505" "506" "507" "508" "509" "510" "511" "512" "513" "514" "515" "516" "517" "518" "519" "520" "521" "522" "523" "524" "525" "526" "527" "528" "529" "530" "531" "532" "533" "534" "535" "536" "537" "538" "539" "540" "541" "542" "543" "544" "545" "546" "547" "548" "549" "550" "551" "552" "553" "554" "555" "556" "557" "558" "559" "560" "561" "562" "563" "564" "565" "566" "567" "568" "569" "570" "571" "572" "573" "574" "575" "576" "577" "578" "579" "580" "581" "582" "583" "584" "585" "586" "587" "588" "589" "590" "591" "592" "593" "594" "595" "596" "597" "598" "599" "600" "601" "602" "603" "604" "605" "606" "607" "608" "609" "610" "611" "612" "613" "614" "615" "616" "617" "618" "619" "620" "621" "622" "623" "624" "625" "626" "627" "628" "629" "630" "631" "632" "633" "634" "635" "636" "637" "638" "639" "640" "641" "642" "643" "644" "645" "646" "647" "648" "649" "650" "651" "652" "653" "654" "655" "656" "657" "658" "659" "660" "661" "662" "663" "664" "665" "666" "667" "668" "669" "670" "671" "672" "673" "674" "675" "676" "677" "678" "679" "680" "681" "682" "683" "684" "685" "686" "687" "688" "689" "690" "691" "692" "693" "694" "695" "696" "697" "698" "699" "700" "701" "702" "703" "704" "705" "706" "707" "708" "709" "710" "711" "712" "713" "714" "715" "716" "717" "718" "719" "720" "721" "722" "723" "724" "725" "726" "727" "728" "729" "730" "731" "732" "733" "734" "735" "736" "737" "738" "739" "740" "741" "742" "743" "744" "745" "746" "747" "748" "749" "750" "751" "752" "753" "754" "755" "756" "757" "758" "759" "760" "761" "762" "763" "764" "765" "766" "767" "768" "769" "770" "771" "772" "773" "774" "775" "776" "777" "778" "779" "780" "781" "782" "783" "784" "785" "786" "787" "788" "789" "790" "791" "792" "793" "794" "795" "796" "797" "798" "799" "800" "801" "802" "803" "804" "805" "806" "807" "808" "809" "810" "811" "812" "813" "814" "815" "816" "817" "818" "819" "820" "821" "822" "823" "824" "825" "826" "827" "828" "829" "830" "831" "832" "833" "834" "835" "836" "837" "838" "839" "840" "841" "842" "843" "844" "845" "846" "847" "848" "849" "850" "851" "852" "853" "854" "855" "856" "857" "858" "859" "860" "861" "862" "863" "864" "865" "866" "867" "868" "869" "870" "871" "872" "873" "874" "875" "876" "877" "878" "879" "880" "881" "882" "883" "884" "885" "886" "887" "888" "889" "890" "891" "892" "893" "894" "895" "896" "897" "898" "899" "900" "901" "902" "903" "904" "905" "906" "907" "908" "909" "910" "911" "912" "913" "914" "915" "916" "917" "918" "919" "920" "921" "922" "923" "924" "925" "926" "927" "928" "929" "930" "931" "932" "933" "934" "935" "936" "937" "938" "939" "940" "941" "942" "943" "944" "945" "946" "947" "948" "949" "950" "951" "952" "953" "954" "955" "956" "957" "958" "959" "960" "961" "962" "963" "964" "965" "966" "967" "968" "969" "970" "971" "972" "973" "974" "975" "976" "977" "978" "979" "980" "981" "982" "983" "984" "985" "986" "987" "988" "989" "990" "991" "992" "993" "994" "995" "996" "997" "998" "999" "1000" ; %% #include /* A C error reporting function. */ /* !POSIX */ static void yyerror (const char *msg) { fprintf (stderr, "%s\n", msg); } static int yylex (void) { static int counter = 1; if (counter <= MAX) return counter++; assert (counter++ == MAX + 1); return 0; } #include /* getenv. */ #include /* strcmp. */ int main (int argc, char const* argv[]) { (void) argc; (void) argv; return yyparse (); } ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./torture.at:236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./calc.at:1492: cat stderr stdout: 603. calc.at:1561: testing Calculator Java parse.trace parse.error=custom %locations api.push-pull=both parse.lac=full ... ./calc.at:1561: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: cat stderr ./calc.at:1492: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh input: ./calc.at:1491: cat stderr | (# + 1) = 1111 ./calc.at:1492: $PREPARSER ./calc input input: input: stderr: 603. calc.at:1561: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1494: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1492: $PREPARSER ./calc input 608. torture.at:272: testing State number type: 256 states ... ./torture.at:272: ruby $abs_top_srcdir/tests/linear 256 >input.y || exit 77 skipped (calc.at:1561) stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1491: $PREPARSER ./calc input stderr: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 606. torture.at:270: testing State number type: 128 states ... ./torture.at:270: ruby $abs_top_srcdir/tests/linear 128 >input.y || exit 77 Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (14.1: ) Entering state 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 607. torture.at:271: testing State number type: 129 states ... ./torture.at:271: ruby $abs_top_srcdir/tests/linear 129 >input.y || exit 77 stderr: --- /dev/null 2026-03-27 17:47:36.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/608/stderr 2026-03-27 18:45:14.157669377 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/608/test-source: line 14: ruby: command not found ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 608. torture.at:272: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) --- /dev/null 2026-03-27 17:47:36.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/606/stderr 2026-03-27 18:45:14.173669377 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/606/test-source: line 14: ruby: command not found stderr: 606. torture.at:270: skipped (torture.at:270) --- /dev/null 2026-03-27 17:47:36.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/607/stderr 2026-03-27 18:45:14.181669377 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/607/test-source: line 14: ruby: command not found skipped (torture.at:272) 607. torture.at:271: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (14.1: ) Entering state 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) skipped (torture.at:271) ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stdout: | 1 2 ./calc.at:1492: $PREPARSER ./calc input %code top { /* -*- c -*- */ /* Adjust to the compiler. We used to do it here, but each time we add a new line, we have to adjust all the line numbers in error messages. It's simpler to use a constant include to a varying file. */ #include } %define parse.error verbose %debug %{ #include #include #include #define MAX 200 static int yylex (void); #include /* !POSIX */ static void yyerror (const char *msg); %} %union { int val; }; %token END "end" %type exp input %token t1 1 "1" %token t2 2 "2" %token t3 3 "3" %token t4 4 "4" %token t5 5 "5" %token t6 6 "6" %token t7 7 "7" %token t8 8 "8" %token t9 9 "9" %token t10 10 "10" %token t11 11 "11" %token t12 12 "12" %token t13 13 "13" %token t14 14 "14" %token t15 15 "15" %token t16 16 "16" %token t17 17 "17" %token t18 18 "18" %token t19 19 "19" %token t20 20 "20" %token t21 21 "21" %token t22 22 "22" %token t23 23 "23" %token t24 24 "24" %token t25 25 "25" %token t26 26 "26" %token t27 27 "27" %token t28 28 "28" %token t29 29 "29" %token t30 30 "30" %token t31 31 "31" %token t32 32 "32" %token t33 33 "33" %token t34 34 "34" %token t35 35 "35" %token t36 36 "36" %token t37 37 "37" %token t38 38 "38" %token t39 39 "39" %token t40 40 "40" %token t41 41 "41" %token t42 42 "42" %token t43 43 "43" %token t44 44 "44" %token t45 45 "45" %token t46 46 "46" %token t47 47 "47" %token t48 48 "48" %token t49 49 "49" %token t50 50 "50" %token t51 51 "51" %token t52 52 "52" %token t53 53 "53" %token t54 54 "54" %token t55 55 "55" %token t56 56 "56" %token t57 57 "57" %token t58 58 "58" %token t59 59 "59" %token t60 60 "60" %token t61 61 "61" %token t62 62 "62" %token t63 63 "63" %token t64 64 "64" %token t65 65 "65" %token t66 66 "66" %token t67 67 "67" %token t68 68 "68" %token t69 69 "69" %token t70 70 "70" %token t71 71 "71" %token t72 72 "72" %token t73 73 "73" %token t74 74 "74" %token t75 75 "75" %token t76 76 "76" %token t77 77 "77" %token t78 78 "78" %token t79 79 "79" %token t80 80 "80" %token t81 81 "81" %token t82 82 "82" %token t83 83 "83" %token t84 84 "84" %token t85 85 "85" %token t86 86 "86" %token t87 87 "87" %token t88 88 "88" %token t89 89 "89" %token t90 90 "90" %token t91 91 "91" %token t92 92 "92" %token t93 93 "93" %token t94 94 "94" %token t95 95 "95" %token t96 96 "96" %token t97 97 "97" %token t98 98 "98" %token t99 99 "99" %token t100 100 "100" %token t101 101 "101" %token t102 102 "102" %token t103 103 "103" %token t104 104 "104" %token t105 105 "105" %token t106 106 "106" %token t107 107 "107" %token t108 108 "108" %token t109 109 "109" %token t110 110 "110" %token t111 111 "111" %token t112 112 "112" %token t113 113 "113" %token t114 114 "114" %token t115 115 "115" %token t116 116 "116" %token t117 117 "117" %token t118 118 "118" %token t119 119 "119" %token t120 120 "120" %token t121 121 "121" %token t122 122 "122" %token t123 123 "123" %token t124 124 "124" %token t125 125 "125" %token t126 126 "126" %token t127 127 "127" %token t128 128 "128" %token t129 129 "129" %token t130 130 "130" %token t131 131 "131" %token t132 132 "132" %token t133 133 "133" %token t134 134 "134" %token t135 135 "135" %token t136 136 "136" %token t137 137 "137" %token t138 138 "138" %token t139 139 "139" %token t140 140 "140" %token t141 141 "141" %token t142 142 "142" %token t143 143 "143" %token t144 144 "144" %token t145 145 "145" %token t146 146 "146" %token t147 147 "147" %token t148 148 "148" %token t149 149 "149" %token t150 150 "150" %token t151 151 "151" %token t152 152 "152" %token t153 153 "153" %token t154 154 "154" %token t155 155 "155" %token t156 156 "156" %token t157 157 "157" %token t158 158 "158" %token t159 159 "159" %token t160 160 "160" %token t161 161 "161" %token t162 162 "162" %token t163 163 "163" %token t164 164 "164" %token t165 165 "165" %token t166 166 "166" %token t167 167 "167" %token t168 168 "168" %token t169 169 "169" %token t170 170 "170" %token t171 171 "171" %token t172 172 "172" %token t173 173 "173" %token t174 174 "174" %token t175 175 "175" %token t176 176 "176" %token t177 177 "177" %token t178 178 "178" %token t179 179 "179" %token t180 180 "180" %token t181 181 "181" %token t182 182 "182" %token t183 183 "183" %token t184 184 "184" %token t185 185 "185" %token t186 186 "186" %token t187 187 "187" %token t188 188 "188" %token t189 189 "189" %token t190 190 "190" %token t191 191 "191" %token t192 192 "192" %token t193 193 "193" %token t194 194 "194" %token t195 195 "195" %token t196 196 "196" %token t197 197 "197" %token t198 198 "198" %token t199 199 "199" %token t200 200 "200" %% input: exp { assert ($1 == 0); $$ = $1; } | input exp { assert ($2 == $1 + 1); $$ = $2; } ; exp: END { $$ = 0; } | "1" END { $$ = 1; } | "1" "2" END { $$ = 2; } | "1" "2" "3" END { $$ = 3; } | "1" "2" "3" "4" END { $$ = 4; } | "1" "2" "3" "4" "5" END { $$ = 5; } | "1" "2" "3" "4" "5" "6" END { $$ = 6; } | "1" "2" "3" "4" "5" "6" "7" END { $$ = 7; } | "1" "2" "3" "4" "5" "6" "7" "8" END { $$ = 8; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" END { $$ = 9; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" END { $$ = 10; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" END { $$ = 11; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" END { $$ = 12; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" END { $$ = 13; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" END { $$ = 14; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" END { $$ = 15; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" END { $$ = 16; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" END { $$ = 17; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" END { $$ = 18; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" END { $$ = 19; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" END { $$ = 20; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" END { $$ = 21; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" END { $$ = 22; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" END { $$ = 23; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" END { $$ = 24; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" END { $$ = 25; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" END { $$ = 26; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" END { $$ = 27; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" END { $$ = 28; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" END { $$ = 29; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" END { $$ = 30; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" END { $$ = 31; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" END { $$ = 32; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" END { $$ = 33; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" END { $$ = 34; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" END { $$ = 35; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" END { $$ = 36; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" END { $$ = 37; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" END { $$ = 38; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" END { $$ = 39; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" END { $$ = 40; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" END { $$ = 41; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" END { $$ = 42; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" END { $$ = 43; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" END { $$ = 44; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" END { $$ = 45; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" END { $$ = 46; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" END { $$ = 47; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" END { $$ = 48; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" END { $$ = 49; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" END { $$ = 50; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" END { $$ = 51; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" END { $$ = 52; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" END { $$ = 53; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" END { $$ = 54; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" END { $$ = 55; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" END { $$ = 56; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" END { $$ = 57; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" END { $$ = 58; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" END { $$ = 59; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" END { $$ = 60; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" END { $$ = 61; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" END { $$ = 62; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" END { $$ = 63; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" END { $$ = 64; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" END { $$ = 65; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" END { $$ = 66; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" END { $$ = 67; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" END { $$ = 68; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" END { $$ = 69; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" END { $$ = 70; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" END { $$ = 71; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" END { $$ = 72; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" END { $$ = 73; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" END { $$ = 74; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" END { $$ = 75; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" END { $$ = 76; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" END { $$ = 77; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" END { $$ = 78; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" END { $$ = 79; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" END { $$ = 80; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" END { $$ = 81; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" END { $$ = 82; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" END { $$ = 83; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" END { $$ = 84; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" END { $$ = 85; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" END { $$ = 86; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" END { $$ = 87; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" END { $$ = 88; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" END { $$ = 89; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" END { $$ = 90; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" END { $$ = 91; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" END { $$ = 92; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" END { $$ = 93; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" END { $$ = 94; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" END { $$ = 95; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" END { $$ = 96; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" END { $$ = 97; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" END { $$ = 98; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" END { $$ = 99; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" END { $$ = 100; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" END { $$ = 101; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" END { $$ = 102; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" END { $$ = 103; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" END { $$ = 104; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" END { $$ = 105; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" END { $$ = 106; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" END { $$ = 107; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" END { $$ = 108; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" END { $$ = 109; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" END { $$ = 110; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" END { $$ = 111; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" END { $$ = 112; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" END { $$ = 113; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" END { $$ = 114; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" END { $$ = 115; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" END { $$ = 116; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" END { $$ = 117; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" END { $$ = 118; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" END { $$ = 119; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" END { $$ = 120; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" END { $$ = 121; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" END { $$ = 122; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" END { $$ = 123; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" END { $$ = 124; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" END { $$ = 125; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" END { $$ = 126; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" END { $$ = 127; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" END { $$ = 128; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" END { $$ = 129; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" END { $$ = 130; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" END { $$ = 131; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" END { $$ = 132; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" END { $$ = 133; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" END { $$ = 134; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" END { $$ = 135; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" END { $$ = 136; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" END { $$ = 137; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" END { $$ = 138; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" END { $$ = 139; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" END { $$ = 140; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" END { $$ = 141; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" END { $$ = 142; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" END { $$ = 143; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" END { $$ = 144; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" END { $$ = 145; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" END { $$ = 146; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" END { $$ = 147; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" END { $$ = 148; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" END { $$ = 149; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" END { $$ = 150; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" END { $$ = 151; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" END { $$ = 152; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" END { $$ = 153; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" END { $$ = 154; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" END { $$ = 155; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" END { $$ = 156; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" END { $$ = 157; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" END { $$ = 158; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" END { $$ = 159; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" END { $$ = 160; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" END { $$ = 161; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" END { $$ = 162; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" END { $$ = 163; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" END { $$ = 164; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" END { $$ = 165; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" END { $$ = 166; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24"stderr: "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" END { $$ = 167; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" END { $$ = 168; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" END { $$ = 169; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" END { $$ = 170; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" END { $$ = 171; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" END { $$ = 172; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" END { $$ = 173; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" END { $$ = 174; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" END { $$ = 175; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" END { $$ = 176; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" END { $$ = 177; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" END { $$ = 178; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" END { $$ = 179; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" END { $$ = 180; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" END { $$ = 181; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" END { $$ = 182; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" END { $$ = 183; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" END { $$ = 184; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" END { $$ = 185; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" END { $$ = 186; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" END { $$ = 187; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" END { $$ = 188; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" END { $$ = 189; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" END { $$ = 190; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" END { $$ = 191; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" END { $$ = 192; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" END { $$ = 193; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" END { $$ = 194; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" END { $$ = 195; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" "196" END { $$ = 196; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" "196" "197" END { $$ = 197; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" "196" "197" "198" END { $$ = 198; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" "196" "197" "198" "199" END { $$ = 199; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" "196" "197" "198" "199" "200" END { $$ = 200; } ; %% /* A C error reporting function. */ /* !POSIX */ static void yyerror (const char *msg) { fprintf (stderr, "%s\n", msg); } static int yylex (void) { static int inner = 1; static int outer = 0; if (outer > MAX) return 0; else if (inner > outer) { inner = 1; ++outer; return END; } return inner++; } #include /* getenv. */ #include /* strcmp. */ int main (int argc, char const* argv[]) { (void) argc; (void) argv; return yyparse (); } ./calc.at:1492: cat stderr 609. torture.at:273: testing State number type: 257 states ... ./torture.at:273: ruby $abs_top_srcdir/tests/linear 257 >input.y || exit 77 ./torture.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token number (1.3: 2) ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 610. torture.at:274: testing State number type: 32768 states ... ./torture.at:274: ruby $abs_top_srcdir/tests/linear 32768 >input.y || exit 77 --- /dev/null 2026-03-27 17:47:36.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/610/stderr 2026-03-27 18:45:14.273669377 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/610/test-source: line 14: ruby: command not found | (1 + # + 1) = 1111 ./calc.at:1492: $PREPARSER ./calc input ./calc.at:1491: cat stderr --- /dev/null 2026-03-27 17:47:36.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/609/stderr 2026-03-27 18:45:14.265669377 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/609/test-source: line 14: ruby: command not found 610. torture.at:274: stderr: ./calc.at:1494: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 609. torture.at:273: 611. torture.at:275: testing State number type: 65536 states ... ./torture.at:275: ruby $abs_top_srcdir/tests/linear 65536 >input.y || exit 77 --- /dev/null 2026-03-27 17:47:36.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/611/stderr 2026-03-27 18:45:14.277669377 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/611/test-source: line 14: ruby: command not found skipped (torture.at:274) 611. torture.at:275: stderr: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr skipped (torture.at:273) skipped (torture.at:275) Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token number (1.3: 2) input: | (!!) + (1 2) = 1 input: ./calc.at:1491: $PREPARSER ./calc input | (!!) + (1 2) = 1 ./calc.at:1494: $PREPARSER ./calc input stderr: stderr: stderr: 613. torture.at:385: testing Many lookahead tokens ... ./torture.at:387: "$PERL" -w ./gengram.pl 1000 || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 612. torture.at:276: testing State number type: 65537 states ... ./torture.at:276: ruby $abs_top_srcdir/tests/linear 65537 >input.y || exit 77 --- /dev/null 2026-03-27 17:47:36.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/612/stderr 2026-03-27 18:45:14.329669377 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/612/test-source: line 14: ruby: command not found ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 612. torture.at:276: skipped (torture.at:276) ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: cat stderr %define parse.error verbose %debug %{ /* Adjust to the compiler. We used to do it here, but each time we add a new line, we have to adjust all the line numbers in error messages. It's simpler to use a constant include to a varying file. */ #include # include # include # include # define MAX 1000 static int yylex (void); #include /* !POSIX */ static void yyerror (const char *msg); %} %union { int val; }; %type input exp %token token %type n1 n2 n3 n4 n5 n6 n7 n8 n9 n10 n11 n12 n13 n14 n15 n16 n17 n18 n19 n20 n21 n22 n23 n24 n25 n26 n27 n28 n29 n30 n31 n32 n33 n34 n35 n36 n37 n38 n39 n40 n41 n42 n43 n44 n45 n46 n47 n48 n49 n50 n51 n52 n53 n54 n55 n56 n57 n58 n59 n60 n61 n62 n63 n64 n65 n66 n67 n68 n69 n70 n71 n72 n73 n74 n75 n76 n77 n78 n79 n80 n81 n82 n83 n84 n85 n86 n87 n88 n89 n90 n91 n92 n93 n94 n95 n96 n97 n98 n99 n100 n101 n102 n103 n104 n105 n106 n107 n108 n109 n110 n111 n112 n113 n114 n115 n116 n117 n118 n119 n120 n121 n122 n123 n124 n125 n126 n127 n128 n129 n130 n131 n132 n133 n134 n135 n136 n137 n138 n139 n140 n141 n142 n143 n144 n145 n146 n147 n148 n149 n150 n151 n152 n153 n154 n155 n156 n157 n158 n159 n160 n161 n162 n163 n164 n165 n166 n167 n168 n169 n170 n171 n172 n173 n174 n175 n176 n177 n178 n179 n180 n181 n182 n183 n184 n185 n186 n187 n188 n189 n190 n191 n192 n193 n194 n195 n196 n197 n198 n199 n200 n201 n202 n203 n204 n205 n206 n207 n208 n209 n210 n211 n212 n213 n214 n215 n216 n217 n218 n219 n220 n221 n222 n223 n224 n225 n226 n227 n228 n229 n230 n231 n232 n233 n234 n235 n236 n237 n238 n239 n240 n241 n242 n243 n244 n245 n246 n247 n248 n249 n250 n251 n252 n253 n254 n255 n256 n257 n258 n259 n260 n261 n262 n263 n264 n265 n266 n267 n268 n269 n270 n271 n272 n273 n274 n275 n276 n277 n278 n279 n280 n281 n282 n283 n284 n285 n286 n287 n288 n289 n290 n291 n292 n293 n294 n295 n296 n297 n298 n299 n300 n301 n302 n303 n304 n305 n306 n307 n308 n309 n310 n311 n312 n313 n314 n315 n316 n317 n318 n319 n320 n321 n322 n323 n324 n325 n326 n327 n328 n329 n330 n331 n332 n333 n334 n335 n336 n337 n338 n339 n340 n341 n342 n343 n344 n345 n346 n347 n348 n349 n350 n351 n352 n353 n354 n355 n356 n357 n358 n359 n360 n361 n362 n363 n364 n365 n366 n367 n368 n369 n370 n371 n372 n373 n374 n375 n376 n377 n378 n379 n380 n381 n382 n383 n384 n385 n386 n387 n388 n389 n390 n391 n392 n393 n394 n395 n396 n397 n398 n399 n400 n401 n402 n403 n404 n405 n406 n407 n408 n409 n410 n411 n412 n413 n414 n415 n416 n417 n418 n419 n420 n421 n422 n423 n424 n425 n426 n427 n428 n429 n430 n431 n432 n433 n434 n435 n436 n437 n438 n439 n440 n441 n442 n443 n444 n445 n446 n447 n448 n449 n450 n451 n452 n453 n454 n455 n456 n457 n458 n459 n460 n461 n462 n463 n464 n465 n466 n467 n468 n469 n470 n471 n472 n473 n474 n475 n476 n477 n478 n479 n480 n481 n482 n483 n484 n485 n486 n487 n488 n489 n490 n491 n492 n493 n494 n495 n496 n497 n498 n499 n500 n501 n502 n503 n504 n505 n506 n507 n508 n509 n510 n511 n512 n513 n514 n515 n516 n517 n518 n519 n520 n521 n522 n523 n524 n525 n526 n527 n528 n529 n530 n531 n532 n533 n534 n535 n536 n537 n538 n539 n540 n541 n542 n543 n544 n545 n546 n547 n548 n549 n550 n551 n552 n553 n554 n555 n556 n557 n558 n559 n560 n561 n562 n563 n564 n565 n566 n567 n568 n569 n570 n571 n572 n573 n574 n575 n576 n577 n578 n579 n580 n581 n582 n583 n584 n585 n586 n587 n588 n589 n590 n591 n592 n593 n594 n595 n596 n597 n598 n599 n600 n601 n602 n603 n604 n605 n606 n607 n608 n609 n610 n611 n612 n613 n614 n615 n616 n617 n618 n619 n620 n621 n622 n623 n624 n625 n626 n627 n628 n629 n630 n631 n632 n633 n634 n635 n636 n637 n638 n639 n640 n641 n642 n643 n644 n645 n646 n647 n648 n649 n650 n651 n652 n653 n654 n655 n656 n657 n658 n659 n660 n661 n662 n663 n664 n665 n666 n667 n668 n669 n670 n671 n672 n673 n674 n675 n676 n677 n678 n679 n680 n681 n682 n683 n684 n685 n686 n687 n688 n689 n690 n691 n692 n693 n694 n695 n696 n697 n698 n699 n700 n701 n702 n703 n704 n705 n706 n707 n708 n709 n710 n711 n712 n713 n714 n715 n716 n717 n718 n719 n720 n721 n722 n723 n724 n725 n726 n727 n728 n729 n730 n731 n732 n733 n734 n735 n736 n737 n738 n739 n740 n741 n742 n743 n744 n745 n746 n747 n748 n749 n750 n751 n752 n753 n754 n755 n756 n757 n758 n759 n760 n761 n762 n763 n764 n765 n766 n767 n768 n769 n770 n771 n772 n773 n774 n775 n776 n777 n778 n779 n780 n781 n782 n783 n784 n785 n786 n787 n788 n789 n790 n791 n792 n793 n794 n795 n796 n797 n798 n799 n800 n801 n802 n803 n804 n805 n806 n807 n808 n809 n810 n811 n812 n813 n814 n815 n816 n817 n818 n819 n820 n821 n822 n823 n824 n825 n826 n827 n828 n829 n830 n831 n832 n833 n834 n835 n836 n837 n838 n839 n840 n841 n842 n843 n844 n845 n846 n847 n848 n849 n850 n851 n852 n853 n854 n855 n856 n857 n858 n859 n860 n861 n862 n863 n864 n865 n866 n867 n868 n869 n870 n871 n872 n873 n874 n875 n876 n877 n878 n879 n880 n881 n882 n883 n884 n885 n886 n887 n888 n889 n890 n891 n892 n893 n894 n895 n896 n897 n898 n899 n900 n901 n902 n903 n904 n905 n906 n907 n908 n909 n910 n911 n912 n913 n914 n915 n916 n917 n918 n919 n920 n921 n922 n923 n924 n925 n926 n927 n928 n929 n930 n931 n932 n933 n934 n935 n936 n937 n938 n939 n940 n941 n942 n943 n944 n945 n946 n947 n948 n949 n950 n951 n952 n953 n954 n955 n956 n957 n958 n959 n960 n961 n962 n963 n964 n965 n966 n967 n968 n969 n970 n971 n972 n973 n974 n975 n976 n977 n978 n979 n980 n981 n982 n983 n984 n985 n986 n987 n988 n989 n990 n991 n992 n993 n994 n995 n996 n997 n998 n999 n1000 %token t1 1 "1" t2 2 "2" t3 3 "3" t4 4 "4" t5 5 "5" t6 6 "6" t7 7 "7" t8 8 "8" t9 9 "9" t10 10 "10" t11 11 "11" t12 12 "12" t13 13 "13" t14 14 "14" t15 15 "15" t16 16 "16" t17 17 "17" t18 18 "18" t19 19 "19" t20 20 "20" t21 21 "21" t22 22 "22" t23 23 "23" t24 24 "24" t25 25 "25" t26 26 "26" t27 27 "27" t28 28 "28" t29 29 "29" t30 30 "30" t31 31 "31" t32 32 "32" t33 33 "33" t34 34 "34" t35 35 "35" t36 36 "36" t37 37 "37" t38 38 "38" t39 39 "39" t40 40 "40" t41 41 "41" t42 42 "42" t43 43 "43" t44 44 "44" t45 45 "45" t46 46 "46" t47 47 "47" t48 48 "48" t49 49 "49" t50 50 "50" t51 51 "51" t52 52 "52" t53 53 "53" t54 54 "54" t55 55 "55" t56 56 "56" t57 57 "57" t58 58 "58" t59 59 "59" t60 60 "60" t61 61 "61" t62 62 "62" t63 63 "63" t64 64 "64" t65 65 "65" t66 66 "66" t67 67 "67" t68 68 "68" t69 69 "69" t70 70 "70" t71 71 "71" t72 72 "72" t73 73 "73" t74 74 "74" t75 75 "75" t76 76 "76" t77 77 "77" t78 78 "78" t79 79 "79" t80 80 "80" t81 81 "81" t82 82 "82" t83 83 "83" t84 84 "84" t85 85 "85" t86 86 "86" t87 87 "87" t88 88 "88" t89 89 "89" t90 90 "90" t91 91 "91" t92 92 "92" t93 93 "93" t94 94 "94" t95 95 "95" t96 96 "96" t97 97 "97" t98 98 "98" t99 99 "99" t100 100 "100" t101 101 "101" t102 102 "102" t103 103 "103" t104 104 "104" t105 105 "105" t106 106 "106" t107 107 "107" t108 108 "108" t109 109 "109" t110 110 "110" t111 111 "111" t112 112 "112" t113 113 "113" t114 114 "114" t115 115 "115" t116 116 "116" t117 117 "117" t118 118 "118" t119 119 "119" t120 120 "120" t121 121 "121" t122 122 "122" t123 123 "123" t124 124 "124" t125 125 "125" t126 126 "126" t127 127 "127" t128 128 "128" t129 129 "129" t130 130 "130" t131 131 "131" t132 132 "132" t133 133 "133" t134 134 "134" t135 135 "135" t136 136 "136" t137 137 "137" t138 138 "138" t139 139 "139" t140 140 "140" t141 141 "141" t142 142 "142" t143 143 "143" t144 144 "144" t145 145 "145" t146 146 "146" t147 147 "147" t148 148 "148" t149 149 "149" t150 150 "150" t151 151 "151" t152 152 "152" t153 153 "153" t154 154 "154" t155 155 "155" t156 156 "156" t157 157 "157" t158 158 "158" t159 159 "159" t160 160 "160" t161 161 "161" t162 162 "162" t163 163 "163" t164 164 "164" t165 165 "165" t166 166 "166" t167 167 "167" t168 168 "168" t169 169 "169" t170 170 "170" t171 171 "171" t172 172 "172" t173 173 "173" t174 174 "174" t175 175 "175" t176 176 "176" t177 177 "177" t178 178 "178" t179 179 "179" t180 180 "180" t181 181 "181" t182 182 "182" t183 183 "183" t184 184 "184" t185 185 "185" t186 186 "186" t187 187 "187" t188 188 "188" t189 189 "189" t190 190 "190" t191 191 "191" t192 192 "192" t193 193 "193" t194 194 "194" t195 195 "195" t196 196 "196" t197 197 "197" t198 198 "198" t199 199 "199" t200 200 "200" t201 201 "201" t202 202 "202" t203 203 "203" t204 204 "204" t205 205 "205" t206 206 "206" t207 207 "207" t208 208 "208" t209 209 "209" t210 210 "210" t211 211 "211" t212 212 "212" t213 213 "213" t214 214 "214" t215 215 "215" t216 216 "216" t217 217 "217" t218 218 "218" t219 219 "219" t220 220 "220" t221 221 "221" t222 222 "222" t223 223 "223" t224 224 "224" t225 225 "225" t226 226 "226" t227 227 "227" t228 228 "228" t229 229 "229" t230 230 "230" t231 231 "231" t232 232 "232" t233 233 "233" t234 234 "234" t235 235 "235" t236 236 "236" t237 237 "237" t238 238 "238" t239 239 "239" t240 240 "240" t241 241 "241" t242 242 "242" t243 243 "243" t244 244 "244" t245 245 "245" t246 246 "246" t247 247 "247" t248 248 "248" t249 249 "249" t250 250 "250" t251 251 "251" t252 252 "252" t253 253 "253" t254 254 "254" t255 255 "255" t256 256 "256" t257 257 "257" t258 258 "258" t259 259 "259" t260 260 "260" t261 261 "261" t262 262 "262" t263 263 "263" t264 264 "264" t265 265 "265" t266 266 "266" t267 267 "267" t268 268 "268" t269 269 "269" t270 270 "270" t271 271 "271" t272 272 "272" t273 273 "273" t274 274 "274" t275 275 "275" t276 276 "276" t277 277 "277" t278 278 "278" t279 279 "279" t280 280 "280" t281 281 "281" t282 282 "282" t283 283 "283" t284 284 "284" t285 285 "285" t286 286 "286" t287 287 "287" t288 288 "288" t289 289 "289" t290 290 "290" t291 291 "291" t292 292 "292" t293 293 "293" t294 294 "294" t295 295 "295" t296 296 "296" t297 297 "297" t298 298 "298" t299 299 "299" t300 300 "300" t301 301 "301" t302 302 "302" t303 303 "303" t304 304 "304" t305 305 "305" t306 306 "306" t307 307 "307" t308 308 "308" t309 309 "309" t310 310 "310" t311 311 "311" t312 312 "312" t313 313 "313" t314 314 "314" t315 315 "315" t316 316 "316" t317 317 "317" t318 318 "318" t319 319 "319" t320 320 "320" t321 321 "321" t322 322 "322" t323 323 "323" t324 324 "324" t325 325 "325" t326 326 "326" t327 327 "327" t328 328 "328" t329 329 "329" t330 330 "330" t331 331 "331" t332 332 "332" t333 333 "333" t334 334 "334" t335 335 "335" t336 336 "336" t337 337 "337" t338 338 "338" t339 339 "339" t340 340 "340" t341 341 "341" t342 342 "342" t343 343 "343" t344 344 "344" t345 345 "345" t346 346 "346" t347 347 "347" t348 348 "348" t349 349 "349" t350 350 "350" t351 351 "351" t352 352 "352" t353 353 "353" t354 354 "354" t355 355 "355" t356 356 "356" t357 357 "357" t358 358 "358" t359 359 "359" t360 360 "360" t361 361 "361" t362 362 "362" t363 363 "363" t364 364 "364" t365 365 "365" t366 366 "366" t367 367 "367" t368 368 "368" t369 369 "369" t370 370 "370" t371 371 "371" t372 372 "372" t373 373 "373" t374 374 "374" t375 375 "375" t376 376 "376" t377 377 "377" t378 378 "378" t379 379 "379" t380 380 "380" t381 381 "381" t382 382 "382" t383 383 "383" t384 384 "384" t385 385 "385" t386 386 "386" t387 387 "387" t388 388 "388" t389 389 "389" t390 390 "390" t391 391 "391" t392 392 "392" t393 393 "393" t394 394 "394" t395 395 "395" t396 396 "396" t397 397 "397" t398 398 "398" t399 399 "399" t400 400 "400" t401 401 "401" t402 402 "402" t403 403 "403" t404 404 "404" t405 405 "405" t406 406 "406" t407 407 "407" t408 408 "408" t409 409 "409" t410 410 "410" t411 411 "411" t412 412 "412" t413 413 "413" t414 414 "414" t415 415 "415" t416 416 "416" t417 417 "417" t418 418 "418" t419 419 "419" t420 420 "420" t421 421 "421" t422 422 "422" t423 423 "423" t424 424 "424" t425 425 "425" t426 426 "426" t427 427 "427" t428 428 "428" t429 429 "429" t430 430 "430" t431 431 "431" t432 432 "432" t433 433 "433" t434 434 "434" t435 435 "435" t436 436 "436" t437 437 "437" t438 438 "438" t439 439 "439" t440 440 "440" t441 441 "441" t442 442 "442" t443 443 "443" t444 444 "444" t445 445 "445" t446 446 "446" t447 447 "447" t448 448 "448" t449 449 "449" t450 450 "450" t451 451 "451" t452 452 "452" t453 453 "453" t454 454 "454" t455 455 "455" t456 456 "456" t457 457 "457" t458 458 "458" t459 459 "459" t460 460 "460" t461 461 "461" t462 462 "462" t463 463 "463" t464 464 "464" t465 465 "465" t466 466 "466" t467 467 "467" t468 468 "468" t469 469 "469" t470 470 "470" t471 471 "471" t472 472 "472" t473 473 "473" t474 474 "474" t475 475 "475" t476 476 "476" t477 477 "477" t478 478 "478" t479 479 "479" t480 480 "480" t481 481 "481" t482 482 "482" t483 483 "483" t484 484 "484" t485 485 "485" t486 486 "486" t487 487 "487" t488 488 "488" t489 489 "489" t490 490 "490" t491 491 "491" t492 492 "492" t493 493 "493" t494 494 "494" t495 495 "495" t496 496 "496" t497 497 "497" t498 498 "498" t499 499 "499" t500 500 "500" t501 501 "501" t502 502 "502" t503 503 "503" t504 504 "504" t505 505 "505" t506 506 "506" t507 507 "507" t508 508 "508" t509 509 "509" t510 510 "510" t511 511 "511" t512 512 "512" t513 513 "513" t514 514 "514" t515 515 "515" t516 516 "516" t517 517 "517" t518 518 "518" t519 519 "519" t520 520 "520" t521 521 "521" t522 522 "522" t523 523 "523" t524 524 "524" t525 525 "525" t526 526 "526" t527 527 "527" t528 528 "528" t529 529 "529" t530 530 "530" t531 531 "531" t532 532 "532" t533 533 "533" t534 534 "534" t535 535 "535" t536 536 "536" t537 537 "537" t538 538 "538" t539 539 "539" t540 540 "540" t541 541 "541" t542 542 "542" t543 543 "543" t544 544 "544" t545 545 "545" t546 546 "546" t547 547 "547" t548 548 "548" t549 549 "549" t550 550 "550" t551 551 "551" t552 552 "552" t553 553 "553" t554 554 "554" t555 555 "555" t556 556 "556" t557 557 "557" t558 558 "558" t559 559 "559" t560 560 "560" t561 561 "561" t562 562 "562" t563 563 "563" t564 564 "564" t565 565 "565" t566 566 "566" t567 567 "567" t568 568 "568" t569 569 "569" t570 570 "570" t571 571 "571" t572 572 "572" t573 573 "573" t574 574 "574" t575 575 "575" t576 576 "576" t577 577 "577" t578 578 "578" t579 579 "579" t580 580 "580" t581 581 "581" t582 582 "582" t583 583 "583" t584 584 "584" t585 585 "585" t586 586 "586" t587 587 "587" t588 588 "588" t589 589 "589" t590 590 "590" t591 591 "591" t592 592 "592" t593 593 "593" t594 594 "594" t595 595 "595" t596 596 "596" t597 597 "597" t598 598 "598" t599 599 "599" t600 600 "600" t601 601 "601" t602 602 "602" t603 603 "603" t604 604 "604" t605 605 "605" t606 606 "606" t607 607 "607" t608 608 "608" t609 609 "609" t610 610 "610" t611 611 "611" t612 612 "612" t613 613 "613" t614 614 "614" t615 615 "615" t616 616 "616" t617 617 "617" t618 618 "618" t619 619 "619" t620 620 "620" t621 621 "621" t622 622 "622" t623 623 "623" t624 624 "624" t625 625 "625" t626 626 "626" t627 627 "627" t628 628 "628" t629 629 "629" t630 630 "630" t631 631 "631" t632 632 "632" t633 633 "633" t634 634 "634" t635 635 "635" t636 636 "636" t637 637 "637" t638 638 "638" t639 639 "639" t640 640 "640" t641 641 "641" t642 642 "642" t643 643 "643" t644 644 "644" t645 645 "645" t646 646 "646" t647 647 "647" t648 648 "648" t649 649 "649" t650 650 "650" t651 651 "651" t652 652 "652" t653 653 "653" t654 654 "654" t655 655 "655" t656 656 "656" t657 657 "657" t658 658 "658" t659 659 "659" t660 660 "660" t661 661 "661" t662 662 "662" t663 663 "663" t664 664 "664" t665 665 "665" t666 666 "666" t667 667 "667" t668 668 "668" t669 669 "669" t670 670 "670" t671 671 "671" t672 672 "672" t673 673 "673" t674 674 "674" t675 675 "675" t676 676 "676" t677 677 "677" t678 678 "678" t679 679 "679" t680 680 "680" t681 681 "681" t682 682 "682" t683 683 "683" t684 684 "684" t685 685 "685" t686 686 "686" t687 687 "687" t688 688 "688" t689 689 "689" t690 690 "690" t691 691 "691" t692 692 "692" t693 693 "693" t694 694 "694" t695 695 "695" t696 696 "696" t697 697 "697" t698 698 "698" t699 699 "699" t700 700 "700" t701 701 "701" t702 702 "702" t703 703 "703" t704 704 "704" t705 705 "705" t706 706 "706" t707 707 "707" t708 708 "708" t709 709 "709" t710 710 "710" t711 711 "711" t712 712 "712" t713 713 "713" t714 714 "714" t715 715 "715" t716 716 "716" t717 717 "717" t718 718 "718" t719 719 "719" t720 720 "720" t721 721 "721" t722 722 "722" t723 723 "723" t724 724 "724" t725 725 "725" t726 726 "726" t727 727 "727" t728 728 "728" t729 729 "729" t730 730 "730" t731 731 "731" t732 732 "732" t733 733 "733" t734 734 "734" t735 735 "735" t736 736 "736" t737 737 "737" t738 738 "738" t739 739 "739" t740 740 "740" t741 741 "741" t742 742 "742" t743 743 "743" t744 744 "744" t745 745 "745" t746 746 "746" t747 747 "747" t748 748 "748" t749 749 "749" t750 750 "750" t751 751 "751" t752 752 "752" t753 753 "753" t754 754 "754" t755 755 "755" t756 756 "756" t757 757 "757" t758 758 "758" t759 759 "759" t760 760 "760" t761 761 "761" t762 762 "762" t763 763 "763" t764 764 "764" t765 765 "765" t766 766 "766" t767 767 "767" t768 768 "768" t769 769 "769" t770 770 "770" t771 771 "771" t772 772 "772" t773 773 "773" t774 774 "774" t775 775 "775" t776 776 "776" t777 777 "777" t778 778 "778" t779 779 "779" t780 780 "780" t781 781 "781" t782 782 "782" t783 783 "783" t784 784 "784" t785 785 "785" t786 786 "786" t787 787 "787" t788 788 "788" t789 789 "789" t790 790 "790" t791 791 "791" t792 792 "792" t793 793 "793" t794 794 "794" t795 795 "795" t796 796 "796" t797 797 "797" t798 798 "798" t799 799 "799" t800 800 "800" t801 801 "801" t802 802 "802" t803 803 "803" t804 804 "804" t805 805 "805" t806 806 "806" t807 807 "807" t808 808 "808" t809 809 "809" t810 810 "810" t811 811 "811" t812 812 "812" t813 813 "813" t814 814 "814" t815 815 "815" t816 816 "816" t817 817 "817" t818 818 "818" t819 819 "819" t820 820 "820" t821 821 "821" t822 822 "822" t823 823 "823" t824 824 "824" t825 825 "825" t826 826 "826" t827 827 "827" t828 828 "828" t829 829 "829" t830 830 "830" t831 831 "831" t832 832 "832" t833 833 "833" t834 834 "834" t835 835 "835" t836 836 "836" t837 837 "837" t838 838 "838" t839 839 "839" t840 840 "840" t841 841 "841" t842 842 "842" t843 843 "843" t844 844 "844" t845 845 "845" t846 846 "846" t847 847 "847" t848 848 "848" t849 849 "849" t850 850 "850" t851 851 "851" t852 852 "852" t853 853 "853" t854 854 "854" t855 855 "855" t856 856 "856" t857 857 "857" t858 858 "858" t859 859 "859" t860 860 "860" t861 861 "861" t862 862 "862" t863 863 "863" t864 864 "864" t865 865 "865" t866 866 "866" t867 867 "867" t868 868 "868" t869 869 "869" t870 870 "870" t871 871 "871" t872 872 "872" t873 873 "873" t874 874 "874" t875 875 "875" t876 876 "876" t877 877 "877" t878 878 "878" t879 879 "879" t880 880 "880" t881 881 "881" t882 882 "882" t883 883 "883" t884 884 "884" t885 885 "885" t886 886 "886" t887 887 "887" t888 888 "888" t889 889 "889" t890 890 "890" t891 891 "891" t892 892 "892" t893 893 "893" t894 894 "894" t895 895 "895" t896 896 "896" t897 897 "897" t898 898 "898" t899 899 "899" t900 900 "900" t901 901 "901" t902 902 "902" t903 903 "903" t904 904 "904" t905 905 "905" t906 906 "906" t907 907 "907" t908 908 "908" t909 909 "909" t910 910 "910" t911 911 "911" t912 912 "912" t913 913 "913" t914 914 "914" t915 915 "915" t916 916 "916" t917 917 "917" t918 918 "918" t919 919 "919" t920 920 "920" t921 921 "921" t922 922 "922" t923 923 "923" t924 924 "924" t925 925 "925" t926 926 "926" t927 927 "927" t928 928 "928" t929 929 "929" t930 930 "930" t931 931 "931" t932 932 "932" t933 933 "933" t934 934 "934" t935 935 "935" t936 936 "936" t937 937 "937" t938 938 "938" t939 939 "939" t940 940 "940" t941 941 "941" t942 942 "942" t943 943 "943" t944 944 "944" t945 945 "945" t946 946 "946" t947 947 "947" t948 948 "948" t949 949 "949" t950 950 "950" t951 951 "951" t952 952 "952" t953 953 "953" t954 954 "954" t955 955 "955" t956 956 "956" t957 957 "957" t958 958 "958" t959 959 "959" t960 960 "960" t961 961 "961" t962 962 "962" t963 963 "963" t964 964 "964" t965 965 "965" t966 966 "966" t967 967 "967" t968 968 "968" t969 969 "969" t970 970 "970" t971 971 "971" t972 972 "972" t973 973 "973" t974 974 "974" t975 975 "975" t976 976 "976" t977 977 "977" t978 978 "978" t979 979 "979" t980 980 "980" t981 981 "981" t982 982 "982" t983 983 "983" t984 984 "984" t985 985 "985" t986 986 "986" t987 987 "987" t988 988 "988" t989 989 "989" t990 990 "990" t991 991 "991" t992 992 "992" t993 993 "993" t994 994 "994" t995 995 "995" t996 996 "996" t997 997 "997" t998 998 "998" t999 999 "999" t1000 1000 "1000" %% input: exp { assert ($1 == 1); $$ = $1; } | input exp { assert ($2 == $1 + 1); $$ = $2; } ; exp: n1 "1" { assert ($1 == 1); $$ = $1; } | n2 "2" { assert ($1 == 2); $$ = $1; } | n3 "3" { assert ($1 == 3); $$ = $1; } | n4 "4" { assert ($1 == 4); $$ = $1; } | n5 "5" { assert ($1 == 5); $$ = $1; } | n6 "6" { assert ($1 == 6); $$ = $1; } | n7 "7" { assert ($1 == 7); $$ = $1; } | n8 "8" { assert ($1 == 8); $$ = $1; } | n9 "9" { assert ($1 == 9); $$ = $1; } | n10 "10" { assert ($1 == 10); $$ = $1; } | n11 "11" { assert ($1 == 11); $$ = $1; } | n12 "12" { assert ($1 == 12); $$ = $1; } | n13 "13" { assert ($1 == 13); $$ = $1; } | n14 "14" { assert ($1 == 14); $$ = $1; } | n15 "15" { assert ($1 == 15); $$ = $1; } | n16 "16" { assert ($1 == 16); $$ = $1; } | n17 "17" { assert ($1 == 17); $$ = $1; } | n18 "18" { assert ($1 == 18); $$ = $1; } | n19 "19" { assert ($1 == 19); $$ = $1; } | n20 "20" { assert ($1 == 20); $$ = $1; } | n21 "21" { assert ($1 == 21); $$ = $1; } | n22 "22" { assert ($1 == 22); $$ = $1; } | n23 "23" { assert ($1 == 23); $$ = $1; } | n24 "24" { assert ($1 == 24); $$ = $1; } | n25 "25" { assert ($1 == 25); $$ = $1; } | n26 "26" { assert ($1 == 26); $$ = $1; } | n27 "27" { assert ($1 == 27); $$ = $1; } | n28 "28" { assert ($1 == 28); $$ = $1; } | n29 "29" { assert ($1 == 29); $$ = $1; } | n30 "30" { assert ($1 == 30); $$ = $1; } | n31 "31" { assert ($1 == 31); $$ = $1; } | n32 "32" { assert ($1 == 32); $$ = $1; } | n33 "33" { assert ($1 == 33); $$ = $1; } | n34 "34" { assert ($1 == 34); $$ = $1; } | n35 "35" { assert ($1 == 35); $$ = $1; } | n36 "36" { assert ($1 == 36); $$ = $1; } | n37 "37" { assert ($1 == 37); $$ = $1; } | n38 "38" { assert ($1 == 38); $$ = $1; } | n39 "39" { assert ($1 == 39); $$ = $1; } | n40 "40" { assert ($1 == 40); $$ = $1; } | n41 "41" { assert ($1 == 41); $$ = $1; } | n42 "42" { assert ($1 == 42); $$ = $1; } | n43 "43" { assert ($1 == 43); $$ = $1; } | n44 "44" { assert ($1 == 44); $$ = $1; } | n45 "45" { assert ($1 == 45); $$ = $1; } | n46 "46" { assert ($1 == 46); $$ = $1; } | n47 "47" { assert ($1 == 47); $$ = $1; } | n48 "48" { assert ($1 == 48); $$ = $1; } | n49 "49" { assert ($1 == 49); $$ = $1; } | n50 "50" { assert ($1 == 50); $$ = $1; } | n51 "51" { assert ($1 == 51); $$ = $1; } | n52 "52" { assert ($1 == 52); $$ = $1; } | n53 "53" { assert ($1 == 53); $$ = $1; } | n54 "54" { assert ($1 == 54); $$ = $1; } | n55 "55" { assert ($1 == 55); $$ = $1; } | n56 "56" { assert ($1 == 56); $$ = $1; } | n57 "57" { assert ($1 == 57); $$ = $1; } | n58 "58" { assert ($1 == 58); $$ = $1; } | n59 "59" { assert ($1 == 59); $$ = $1; } | n60 "60" { assert ($1 == 60); $$ = $1; } | n61 "61" { assert ($1 == 61); $$ = $1; } | n62 "62" { assert ($1 == 62); $$ = $1; } | n63 "63" { assert ($1 == 63); $$ = $1; } | n64 "64" { assert ($1 == 64); $$ = $1; } | n65 "65" { assert ($1 == 65); $$ = $1; } | n66 "66" { assert ($1 == 66); $$ = $1; } | n67 "67" { assert ($1 == 67); $$ = $1; } | n68 "68" { assert ($1 == 68); $$ = $1; } | n69 "69" { assert ($1 == 69); $$ = $1; } | n70 "70" { assert ($1 == 70); $$ = $1; } | n71 "71" { assert ($1 == 71); $$ = $1; } | n72 "72" { assert ($1 == 72); $$ = $1; } | n73 "73" { assert ($1 == 73); $$ = $1; } | n74 "74" { assert ($1 == 74); $$ = $1; } | n75 "75" { assert ($1 == 75); $$ = $1; } | n76 "76" { assert ($1 == 76); $$ = $1; } | n77 "77" { assert ($1 == 77); $$ = $1; } | n78 "78" { assert ($1 == 78); $$ = $1; } | n79 "79" { assert ($1 == 79); $$ = $1; } | n80 "80" { assert ($1 == 80); $$ = $1; } | n81 "81" { assert ($1 == 81); $$ = $1; } | n82 "82" { assert ($1 == 82); $$ = $1; } | n83 "83" { assert ($1 == 83); $$ = $1; } | n84 "84" { assert ($1 == 84); $$ = $1; } | n85 "85" { assert ($1 == 85); $$ = $1; } | n86 "86" { assert ($1 == 86); $$ = $1; } | n87 "87" { assert ($1 == 87); $$ = $1; } | n88 "88" { assert ($1 == 88); $$ = $1; } | n89 "89" { assert ($1 == 89); $$ = $1; } | n90 "90" { assert ($1 == 90); $$ = $1; } | n91 "91" { assert ($1 == 91); $$ = $1; } | n92 "92" { assert ($1 == 92); $$ = $1; } | n93 "93" { assert ($1 == 93); $$ = $1; } | n94 "94" { assert ($1 == 94); $$ = $1; } | n95 "95" { assert ($1 == 95); $$ = $1; } | n96 "96" { assert ($1 == 96); $$ = $1; } | n97 "97" { assert ($1 == 97); $$ = $1; } | n98 "98" { assert ($1 == 98); $$ = $1; } | n99 "99" { assert ($1 == 99); $$ = $1; } | n100 "100" { assert ($1 == 100); $$ = $1; } | n101 "101" { assert ($1 == 101); $$ = $1; } | n102 "102" { assert ($1 == 102); $$ = $1; } | n103 "103" { assert ($1 == 103); $$ = $1; } | n104 "104" { assert ($1 == 104); $$ = $1; } | n105 "105" { assert ($1 == 105); $$ = $1; } | n106 "106" { assert ($1 == 106); $$ = $1; } | n107 "107" { assert ($1 == 107); $$ = $1; } | n108 "108" { assert ($1 == 108); $$ = $1; } | n109 "109" { assert ($1 == 109); $$ = $1; } | n110 "110" { assert ($1 == 110); $$ = $1; } | n111 "111" { assert ($1 == 111); $$ = $1; } | n112 "112" { assert ($1 == 112); $$ = $1; } | n113 "113" { assert ($1 == 113); $$ = $1; } | n114 "114" { assert ($1 == 114); $$ = $1; } | n115 "115" { assert ($1 == 115); $$ = $1; } | n116 "116" { assert ($1 == 116); $$ = $1; } | n117 "117" { assert ($1 == 117); $$ = $1; } | n118 "118" { assert ($1 == 118); $$ = $1; } | n119 "119" { assert ($1 == 119); $$ = $1; } | n120 "120" { assert ($1 == 120); $$ = $1; } | n121 "121" { assert ($1 == 121); $$ = $1; } | n122 "122" { assert ($1 == 122); $$ = $1; } | n123 "123" { assert ($1 == 123); $$ = $1; } | n124 "124" { assert ($1 == 124); $$ = $1; } | n125 "125" { assert ($1 == 125); $$ = $1; } | n126 "126" { assert ($1 == 126); $$ = $1; } | n127 "127" { assert ($1 == 127); $$ = $1; } | n128 "128" { assert ($1 == 128); $$ = $1; } | n129 "129" { assert ($1 == 129); $$ = $1; } | n130 "130" { assert ($1 == 130); $$ = $1; } | n131 "131" { assert ($1 == 131); $$ = $1; } | n132 "132" { assert ($1 == 132); $$ = $1; } | n133 "133" { assert ($1 == 133); $$ = $1; } | n134 "134" { assert ($1 == 134); $$ = $1; } | n135 "135" { assert ($1 == 135); $$ = $1; } | n136 "136" { assert ($1 == 136); $$ = $1; } | n137 "137" { assert ($1 == 137); $$ = $1; } | n138 "138" { assert ($1 == 138); $$ = $1; } | n139 "139" { assert ($1 == 139); $$ = $1; } | n140 "140" { assert ($1 == 140); $$ = $1; } | n141 "141" { assert ($1 == 141); $$ = $1; } | n142 "142" { assert ($1 == 142); $$ = $1; } | n143 "143" { assert ($1 == 143); $$ = $1; } | n144 "144" { assert ($1 == 144); $$ = $1; } | n145 "145" { assert ($1 == 145); $$ = $1; } | n146 "146" { assert ($1 == 146); $$ = $1; } | n147 "147" { assert ($1 == 147); $$ = $1; } | n148 "148" { assert ($1 == 148); $$ = $1; } | n149 "149" { assert ($1 == 149); $$ = $1; } | n150 "150" { assert ($1 == 150); $$ = $1; } | n151 "151" { assert ($1 == 151); $$ = $1; } | n152 "152" { assert ($1 == 152); $$ = $1; } | n153 "153" { assert ($1 == 153); $$ = $1; } | n154 "154" { assert ($1 == 154); $$ = $1; } | n155 "155" { assert ($1 == 155); $$ = $1; } | n156 "156" { assert ($1 == 156); $$ = $1; } | n157 "157" { assert ($1 == 157); $$ = $1; } | n158 "158" { assert ($1 == 158); $$ = $1; } | n159 "159" { assert ($1 == 159); $$ = $1; } | n160 "160" { assert ($1 == 160); $$ = $1; } | n161 "161" { assert ($1 == 161); $$ = $1; } | n162 "162" { assert ($1 == 162); $$ = $1; } | n163 "163" { assert ($1 == 163); $$ = $1; } | n164 "164" { assert ($1 == 164); $$ = $1; } | n165 "165" { assert ($1 == 165); $$ = $1; } | n166 "166" { assert ($1 == 166); $$ = $1; } | n167 "167" { assert ($1 == 167); $$ = $1; } | n168 "168" { assert ($1 == 168); $$ = $1; } | n169 "169" { assert ($1 == 169); $$ = $1; } | n170 "170" { assert ($1 == 170); $$ = $1; } | n171 "171" { assert ($1 == 171); $$ = $1; } | n172 "172" { assert ($1 == 172); $$ = $1; } | n173 "173" { assert ($1 == 173); $$ = $1; } | n174 "174" { assert ($1 == 174); $$ = $1; } | n175 "175" { assert ($1 == 175); $$ = $1; } | n176 "176" { assert ($1 == 176); $$ = $1; } | n177 "177" { assert ($1 == 177); $$ = $1; } | n178 "178" { assert ($1 == 178); $$ = $1; } | n179 "179" { assert ($1 == 179); $$ = $1; } | n180 "180" { assert ($1 == 180); $$ = $1; } | n181 "181" { assert ($1 == 181); $$ = $1; } | n182 "182" { assert ($1 == 182); $$ = $1; } | n183 "183" { assert ($1 == 183); $$ = $1; } | n184 "184" { assert ($1 == 184); $$ = $1; } | n185 "185" { assert ($1 == 185); $$ = $1; } | n186 "186" { assert ($1 == 186); $$ = $1; } | n187 "187" { assert ($1 == 187); $$ = $1; } | n188 "188" { assert ($1 == 188); $$ = $1; } | n189 "189" { assert ($1 == 189); $$ = $1; } | n190 "190" { assert ($1 == 190); $$ = $1; } | n191 "191" { assert ($1 == 191); $$ = $1; } | n192 "192" { assert ($1 == 192); $$ = $1; } | n193 "193" { assert ($1 == 193); $$ = $1; } | n194 "194" { assert ($1 == 194); $$ = $1; } | n195 "195" { assert ($1 == 195); $$ = $1; } | n196 "196" { assert ($1 == 196); $$ = $1; } | n197 "197" { assert ($1 == 197); $$ = $1; } | n198 "198" { assert ($1 == 198); $$ = $1; } | n199 "199" { assert ($1 == 199); $$ = $1; } | n200 "200" { assert ($1 == 200); $$ = $1; } | n201 "201" { assert ($1 == 201); $$ = $1; } | n202 "202" { assert ($1 == 202); $$ = $1; } | n203 "203" { assert ($1 == 203); $$ = $1; } | n204 "204" { assert ($1 == 204); $$ = $1; } | n205 "205" { assert ($1 == 205); $$ = $1; } | n206 "206" { assert ($1 == 206); $$ = $1; } | n207 "207" { assert ($1 == 207); $$ = $1; } | n208 "208" { assert ($1 == 208); $$ = $1; } | n209 "209" { assert ($1 == 209); $$ = $1; } | n210 "210" { assert ($1 == 210); $$ = $1; } | n211 "211" { assert ($1 == 211); $$ = $1; } | n212 "212" { assert ($1 == 212); $$ = $1; } | n213 "213" { assert ($1 == 213); $$ = $1; } | n214 "214" { assert ($1 == 214); $$ = $1; } | n215 "215" { assert ($1 == 215); $$ = $1; } | n216 "216" { assert ($1 == 216); $$ = $1; } | n217 "217" { assert ($1 == 217); $$ = $1; } | n218 "218" { assert ($1 == 218); $$ = $1; } | n219 "219" { assert ($1 == 219); $$ = $1; } | n220 "220" { assert ($1 == 220); $$ = $1; } | n221 "221" { assert ($1 == 221); $$ = $1; } | n222 "222" { assert ($1 == 222); $$ = $1; } | n223 "223" { assert ($1 == 223); $$ = $1; } | n224 "224" { assert ($1 == 224); $$ = $1; } | n225 "225" { assert ($1 == 225); $$ = $1; } | n226 "226" { assert ($1 == 226); $$ = $1; } | n227 "227" { assert ($1 == 227); $$ = $1; } | n228 "228" { assert ($1 == 228); $$ = $1; } | n229 "229" { assert ($1 == 229); $$ = $1; } | n230 "230" { assert ($1 == 230); $$ = $1; } | n231 "231" { assert ($1 == 231); $$ = $1; } | n232 "232" { assert ($1 == 232); $$ = $1; } | n233 "233" { assert ($1 == 233); $$ = $1; } | n234 "234" { assert ($1 == 234); $$ = $1; } | n235 "235" { assert ($1 == 235); $$ = $1; } | n236 "236" { assert ($1 == 236); $$ = $1; } | n237 "237" { assert ($1 == 237); $$ = $1; } | n238 "238" { assert ($1 == 238); $$ = $1; } | n239 "239" { assert ($1 == 239); $$ = $1; } | n240 "240" { assert ($1 == 240); $$ = $1; } | n241 "241" { assert ($1 == 241); $$ = $1; } | n242 "242" { assert ($1 == 242); $$ = $1; } | n243 "243" { assert ($1 == 243); $$ = $1; } | n244 "244" { assert ($1 == 244); $$ = $1; } | n245 "245" { assert ($1 == 245); $$ = $1; } | n246 "246" { assert ($1 == 246); $$ = $1; } | n247 "247" { assert ($1 == 247); $$ = $1; } | n248 "248" { assert ($1 == 248); $$ = $1; } | n249 "249" { assert ($1 == 249); $$ = $1; } | n250 "250" { assert ($1 == 250); $$ = $1; } | n251 "251" { assert ($1 == 251); $$ = $1; } | n252 "252" { assert ($1 == 252); $$ = $1; } | n253 "253" { assert ($1 == 253); $$ = $1; } | n254 "254" { assert ($1 == 254); $$ = $1; } | n255 "255" { assert ($1 == 255); $$ = $1; } | n256 "256" { assert ($1 == 256); $$ = $1; } | n257 "257" { assert ($1 == 257); $$ = $1; } | n258 "258" { assert ($1 == 258); $$ = $1; } | n259 "259" { assert ($1 == 259); $$ = $1; } | n260 "260" { assert ($1 == 260); $$ = $1; } | n261 "261" { assert ($1 == 261); $$ = $1; } | n262 "262" { assert ($1 == 262); $$ = $1; } | n263 "263" { assert ($1 == 263); $$ = $1; } | n264 "264" { assert ($1 == 264); $$ = $1; } | n265 "265" { assert ($1 == 265); $$ = $1; } | n266 "266" { assert ($1 == 266); $$ = $1; } | n267 "267" { assert ($1 == 267); $$ = $1; } | n268 "268" { assert ($1 == 268); $$ = $1; } | n269 "269" { assert ($1 == 269); $$ = $1; } | n270 "270" { assert ($1 == 270); $$ = $1; } | n271 "271" { assert ($1 == 271); $$ = $1; } | n272 "272" { assert ($1 == 272); $$ = $1; } | n273 "273" { assert ($1 == 273); $$ = $1; } | n274 "274" { assert ($1 == 274); $$ = $1; } | n275 "275" { assert ($1 == 275); $$ = $1; } | n276 "276" { assert ($1 == 276); $$ = $1; } | n277 "277" { assert ($1 == 277); $$ = $1; } | n278 "278" { assert ($1 == 278); $$ = $1; } | n279 "279" { assert ($1 == 279); $$ = $1; } | n280 "280" { assert ($1 == 280); $$ = $1; } | n281 "281" { assert ($1 == 281); $$ = $1; } | n282 "282" { assert ($1 == 282); $$ = $1; } | n283 "283" { assert ($1 == 283); $$ = $1; } | n284 "284" { assert ($1 == 284); $$ = $1; } | n285 "285" { assert ($1 == 285); $$ = $1; } | n286 "286" { assert ($1 == 286); $$ = $1; } | n287 "287" { assert ($1 == 287); $$ = $1; } | n288 "288" { assert ($1 == 288); $$ = $1; } | n289 "289" { assert ($1 == 289); $$ = $1; } | n290 "290" { assert ($1 == 290); $$ = $1; } | n291 "291" { assert ($1 == 291); $$ = $1; } | n292 "292" { assert ($1 == 292); $$ = $1; } | n293 "293" { assert ($1 == 293); $$ = $1; } | n294 "294" { assert ($1 == 294); $$ = $1; } | n295 "295" { assert ($1 == 295); $$ = $1; } | n296 "296" { assert ($1 == 296); $$ = $1; } | n297 "297" { assert ($1 == 297); $$ = $1; } | n298 "298" { assert ($1 == 298); $$ = $1; } | n299 "299" { assert ($1 == 299); $$ = $1; } | n300 "300" { assert ($1 == 300); $$ = $1; } | n301 "301" { assert ($1 == 301); $$ = $1; } | n302 "302" { assert ($1 == 302); $$ = $1; } | n303 "303" { assert ($1 == 303); $$ = $1; } | n304 "304" { assert ($1 == 304); $$ = $1; } | n305 "305" { assert ($1 == 305); $$ = $1; } | n306 "306" { assert ($1 == 306); $$ = $1; } | n307 "307" { assert ($1 == 307); $$ = $1; } | n308 "308" { assert ($1 == 308); $$ = $1; } | n309 "309" { assert ($1 == 309); $$ = $1; } | n310 "310" { assert ($1 == 310); $$ = $1; } | n311 "311" { assert ($1 == 311); $$ = $1; } | n312 "312" { assert ($1 == 312); $$ = $1; } | n313 "313" { assert ($1 == 313); $$ = $1; } | n314 "314" { assert ($1 == 314); $$ = $1; } | n315 "315" { assert ($1 == 315); $$ = $1; } | n316 "316" { assert ($1 == 316); $$ = $1; } | n317 "317" { assert ($1 == 317); $$ = $1; } | n318 "318" { assert ($1 == 318); $$ = $1; } | n319 "319" { assert ($1 == 319); $$ = $1; } | n320 "320" { assert ($1 == 320); $$ = $1; } | n321 "321" { assert ($1 == 321); $$ = $1; } | n322 "322" { assert ($1 == 322); $$ = $1; } | n323 "323" { assert ($1 == 323); $$ = $1; } | n324 "324" { assert ($1 == 324); $$ = $1; } | n325 "325" { assert ($1 == 325); $$ = $1; } | n326 "326" { assert ($1 == 326); $$ = $1; } | n327 "327" { assert ($1 == 327); $$ = $1; } | n328 "328" { assert ($1 == 328); $$ = $1; } | n329 "329" { assert ($1 == 329); $$ = $1; } | n330 "330" { assert ($1 == 330); $$ = $1; } | n331 "331" { assert ($1 == 331); $$ = $1; } | n332 "332" { assert ($1 == 332); $$ = $1; } | n333 "333" { assert ($1 == 333); $$ = $1; } | n334 "334" { assert ($1 == 334); $$ = $1; } | n335 "335" { assert ($1 == 335); $$ = $1; } | n336 "336" { assert ($1 == 336); $$ = $1; } | n337 "337" { assert ($1 == 337); $$ = $1; } | n338 "338" { assert ($1 == 338); $$ = $1; } | n339 "339" { assert ($1 == 339); $$ = $1; } | n340 "340" { assert ($1 == 340); $$ = $1; } | n341 "341" { assert ($1 == 341); $$ = $1; } | n342 "342" { assert ($1 == 342); $$ = $1; } | n343 "343" { assert ($1 == 343); $$ = $1; } | n344 "344" { assert ($1 == 344); $$ = $1; } | n345 "345" { assert ($1 == 345); $$ = $1; } | n346 "346" { assert ($1 == 346); $$ = $1; } | n347 "347" { assert ($1 == 347); $$ = $1; } | n348 "348" { assert ($1 == 348); $$ = $1; } | n349 "349" { assert ($1 == 349); $$ = $1; } | n350 "350" { assert ($1 == 350); $$ = $1; } | n351 "351" { assert ($1 == 351); $$ = $1; } | n352 "352" { assert ($1 == 352); $$ = $1; } | n353 "353" { assert ($1 == 353); $$ = $1; } | n354 "354" { assert ($1 == 354); $$ = $1; } | n355 "355" { assert ($1 == 355); $$ = $1; } | n356 "356" { assert ($1 == 356); $$ = $1; } | n357 "357" { assert ($1 == 357); $$ = $1; } | n358 "358" { assert ($1 == 358); $$ = $1; } | n359 "359" { assert ($1 == 359); $$ = $1; } | n360 "360" { assert ($1 == 360); $$ = $1; } | n361 "361" { assert ($1 == 361); $$ = $1; } | n362 "362" { assert ($1 == 362); $$ = $1; } | n363 "363" { assert ($1 == 363); $$ = $1; } | n364 "364" { assert ($1 == 364); $$ = $1; } | n365 "365" { assert ($1 == 365); $$ = $1; } | n366 "366" { assert ($1 == 366); $$ = $1; } | n367 "367" { assert ($1 == 367); $$ = $1; } | n368 "368" { assert ($1 == 368); $$ = $1; } | n369 "369" { assert ($1 == 369); $$ = $1; } | n370 "370" { assert ($1 == 370); $$ = $1; } | n371 "371" { assert ($1 == 371); $$ = $1; } | n372 "372" { assert ($1 == 372); $$ = $1; } | n373 "373" { assert ($1 == 373); $$ = $1; } | n374 "374" { assert ($1 == 374); $$ = $1; } | n375 "375" { assert ($1 == 375); $$ = $1; } | n376 "376" { assert ($1 == 376); $$ = $1; } | n377 "377" { assert ($1 == 377); $$ = $1; } | n378 "378" { assert ($1 == 378); $$ = $1; } | n379 "379" { assert ($1 == 379); $$ = $1; } | n380 "380" { assert ($1 == 380); $$ = $1; } | n381 "381" { assert ($1 == 381); $$ = $1; } | n382 "382" { assert ($1 == 382); $$ = $1; } | n383 "383" { assert ($1 == 383); $$ = $1; } | n384 "384" { assert ($1 == 384); $$ = $1; } | n385 "385" { assert ($1 == 385); $$ = $1; } | n386 "386" { assert ($1 == 386); $$ = $1; } | n387 "387" { assert ($1 == 387); $$ = $1; } | n388 "388" { assert ($1 == 388); $$ = $1; } | n389 "389" { assert ($1 == 389); $$ = $1; } | n390 "390" { assert ($1 == 390); $$ = $1; } | n391 "391" { assert ($1 == 391); $$ = $1; } | n392 "392" { assert ($1 == 392); $$ = $1; } | n393 "393" { assert ($1 == 393); $$ = $1; } | n394 "394" { assert ($1 == 394); $$ = $1; } | n395 "395" { assert ($1 == 395); $$ = $1; } | n396 "396" { assert ($1 == 396); $$ = $1; } | n397 "397" { assert ($1 == 397); $$ = $1; } | n398 "398" { assert ($1 == 398); $$ = $1; } | n399 "399" { assert ($1 == 399); $$ = $1; } | n400 "400" { assert ($1 == 400); $$ = $1; } | n401 "401" { assert ($1 == 401); $$ = $1; } | n402 "402" { assert ($1 == 402); $$ = $1; } | n403 "403" { assert ($1 == 403); $$ = $1; } | n404 "404" { assert ($1 == 404); $$ = $1; } | n405 "405" { assert ($1 == 405); $$ = $1; } | n406 "406" { assert ($1 == 406); $$ = $1; } | n407 "407" { assert ($1 == 407); $$ = $1; } | n408 "408" { assert ($1 == 408); $$ = $1; } | n409 "409" { assert ($1 == 409); $$ = $1; } | n410 "410" { assert ($1 == 410); $$ = $1; } | n411 "411" { assert ($1 == 411); $$ = $1; } | n412 "412" { assert ($1 == 412); $$ = $1; } | n413 "413" { assert ($1 == 413); $$ = $1; } | n414 "414" { assert ($1 == 414); $$ = $1; } | n415 "415" { assert ($1 == 415); $$ = $1; } | n416 "416" { assert ($1 == 416); $$ = $1; } | n417 "417" { assert ($1 == 417); $$ = $1; } | n418 "418" { assert ($1 == 418); $$ = $1; } | n419 "419" { assert ($1 == 419); $$ = $1; } | n420 "420" { assert ($1 == 420); $$ = $1; } | n421 "421" { assert ($1 == 421); $$ = $1; } | n422 "422" { assert ($1 == 422); $$ = $1; } | n423 "423" { assert ($1 == 423); $$ = $1; } | n424 "424" { assert ($1 == 424); $$ = $1; } | n425 "425" { assert ($1 == 425); $$ = $1; } | n426 "426" { assert ($1 == 426); $$ = $1; } | n427 "427" { assert ($1 == 427); $$ = $1; } | n428 "428" { assert ($1 == 428); $$ = $1; } | n429 "429" { assert ($1 == 429); $$ = $1; } | n430 "430" { assert ($1 == 430); $$ = $1; } | n431 "431" { assert ($1 == 431); $$ = $1; } | n432 "432" { assert ($1 == 432); $$ = $1; } | n433 "433" { assert ($1 == 433); $$ = $1; } | n434 "434" { assert ($1 == 434); $$ = $1; } | n435 "435" { assert ($1 == 435); $$ = $1; } | n436 "436" { assert ($1 == 436); $$ = $1; } | n437 "437" { assert ($1 == 437); $$ = $1; } | n438 "438" { assert ($1 == 438); $$ = $1; } | n439 "439" { assert ($1 == 439); $$ = $1; } | n440 "440" { assert ($1 == 440); $$ = $1; } | n441 "441" { assert ($1 == 441); $$ = $1; } | n442 "442" { assert ($1 == 442); $$ = $1; } | n443 "443" { assert ($1 == 443); $$ = $1; } | n444 "444" { assert ($1 == 444); $$ = $1; } | n445 "445" { assert ($1 == 445); $$ = $1; } | n446 "446" { assert ($1 == 446); $$ = $1; } | n447 "447" { assert ($1 == 447); $$ = $1; } | n448 "448" { assert ($1 == 448); $$ = $1; } | n449 "449" { assert ($1 == 449); $$ = $1; } | n450 "450" { assert ($1 == 450); $$ = $1; } | n451 "451" { assert ($1 == 451); $$ = $1; } | n452 "452" { assert ($1 == 452); $$ = $1; } | n453 "453" { assert ($1 == 453); $$ = $1; } | n454 "454" { assert ($1 == 454); $$ = $1; } | n455 "455" { assert ($1 == 455); $$ = $1; } | n456 "456" { assert ($1 == 456); $$ = $1; } | n457 "457" { assert ($1 == 457); $$ = $1; } | n458 "458" { assert ($1 == 458); $$ = $1; } | n459 "459" { assert ($1 == 459); $$ = $1; } | n460 "460" { assert ($1 == 460); $$ = $1; } | n461 "461" { assert ($1 == 461); $$ = $1; } | n462 "462" { assert ($1 == 462); $$ = $1; } | n463 "463" { assert ($1 == 463); $$ = $1; } | n464 "464" { assert ($1 == 464); $$ = $1; } | n465 "465" { assert ($1 == 465); $$ = $1; } | n466 "466" { assert ($1 == 466); $$ = $1; } | n467 "467" { assert ($1 == 467); $$ = $1; } | n468 "468" { assert ($1 == 468); $$ = $1; } | n469 "469" { assert ($1 == 469); $$ = $1; } | n470 "470" { assert ($1 == 470); $$ = $1; } | n471 "471" { assert ($1 == 471); $$ = $1; } | n472 "472" { assert ($1 == 472); $$ = $1; } | n473 "473" { assert ($1 == 473); $$ = $1; } | n474 "474" { assert ($1 == 474); $$ = $1; } | n475 "475" { assert ($1 == 475); $$ = $1; } | n476 "476" { assert ($1 == 476); $$ = $1; } | n477 "477" { assert ($1 == 477); $$ = $1; } | n478 "478" { assert ($1 == 478); $$ = $1; } | n479 "479" { assert ($1 == 479); $$ = $1; } | n480 "480" { assert ($1 == 480); $$ = $1; } | n481 "481" { assert ($1 == 481); $$ = $1; } | n482 "482" { assert ($1 == 482); $$ = $1; } | n483 "483" { assert ($1 == 483); $$ = $1; } | n484 "484" { assert ($1 == 484); $$ = $1; } | n485 "485" { assert ($1 == 485); $$ = $1; } | n486 "486" { assert ($1 == 486); $$ = $1; } | n487 "487" { assert ($1 == 487); $$ = $1; } | n488 "488" { assert ($1 == 488); $$ = $1; } | n489 "489" { assert ($1 == 489); $$ = $1; } | n490 "490" { assert ($1 == 490); $$ = $1; } | n491 "491" { assert ($1 == 491); $$ = $1; } | n492 "492" { assert ($1 == 492); $$ = $1; } | n493 "493" { assert ($1 == 493); $$ = $1; } | n494 "494" { assert ($1 == 494); $$ = $1; } | n495 "495" { assert ($1 == 495); $$ = $1; } | n496 "496" { assert ($1 == 496); $$ = $1; } | n497 "497" { assert ($1 == 497); $$ = $1; } | n498 "498" { assert ($1 == 498); $$ = $1; } | n499 "499" { assert ($1 == 499); $$ = $1; } | n500 "500" { assert ($1 == 500); $$ = $1; } | n501 "501" { assert ($1 == 501); $$ = $1; } | n502 "502" { assert ($1 == 502); $$ = $1; } | n503 "503" { assert ($1 == 503); $$ = $1; } | n504 "504" { assert ($1 == 504); $$ = $1; } | n505 "505" { assert ($1 == 505); $$ = $1; } | n506 "506" { assert ($1 == 506); $$ = $1; } | n507 "507" { assert ($1 == 507); $$ = $1; } | n508 "508" { assert ($1 == 508); $$ = $1; } | n509 "509" { assert ($1 == 509); $$ = $1; } | n510 "510" { assert ($1 == 510); $$ = $1; } | n511 "511" { assert ($1 == 511); $$ = $1; } | n512 "512" { assert ($1 == 512); $$ = $1; } | n513 "513" { assert ($1 == 513); $$ = $1; } | n514 "514" { assert ($1 == 514); $$ = $1; } | n515 "515" { assert ($1 == 515); $$ = $1; } | n516 "516" { assert ($1 == 516); $$ = $1; } | n517 "517" { assert ($1 == 517); $$ = $1; } | n518 "518" { assert ($1 == 518); $$ = $1; } | n519 "519" { assert ($1 == 519); $$ = $1; } | n520 "520" { assert ($1 == 520); $$ = $1; } | n521 "521" { assert ($1 == 521); $$ = $1; } | n522 "522" { assert ($1 == 522); $$ = $1; } | n523 "523" { assert ($1 == 523); $$ = $1; } | n524 "524" { assert ($1 == 524); $$ = $1; } | n525 "525" { assert ($1 == 525); $$ = $1; } | n526 "526" { assert ($1 == 526); $$ = $1; } | n527 "527" { assert ($1 == 527); $$ = $1; } | n528 "528" { assert ($1 == 528); $$ = $1; } | n529 "529" { assert ($1 == 529); $$ = $1; } | n530 "530" { assert ($1 == 530); $$ = $1; } | n531 "531" { assert ($1 == 531); $$ = $1; } | n532 "532" { assert ($1 == 532); $$ = $1; } | n533 "533" { assert ($1 == 533); $$ = $1; } | n534 "534" { assert ($1 == 534); $$ = $1; } | n535 "535" { assert ($1 == 535); $$ = $1; } | n536 "536" { assert ($1 == 536); $$ = $1; } | n537 "537" { assert ($1 == 537); $$ = $1; } | n538 "538" { assert ($1 == 538); $$ = $1; } | n539 "539" { assert ($1 == 539); $$ = $1; } | n540 "540" { assert ($1 == 540); $$ = $1; } | n541 "541" { assert ($1 == 541); $$ = $1; } | n542 "542" { assert ($1 == 542); $$ = $1; } | n543 "543" { assert ($1 == 543); $$ = $1; } | n544 "544" { assert ($1 == 544); $$ = $1; } | n545 "545" { assert ($1 == 545); $$ = $1; } | n546 "546" { assert ($1 == 546); $$ = $1; } | n547 "547" { assert ($1 == 547); $$ = $1; } | n548 "548" { assert ($1 == 548); $$ = $1; } | n549 "549" { assert ($1 == 549); $$ = $1; } | n550 "550" { assert ($1 == 550); $$ = $1; } | n551 "551" { assert ($1 == 551); $$ = $1; } | n552 "552" { assert ($1 == 552); $$ = $1; } | n553 "553" { assert ($1 == 553); $$ = $1; } | n554 "554" { assert ($1 == 554); $$ = $1; } | n555 "555" { assert ($1 == 555); $$ = $1; } | n556 "556" { assert ($1 == 556); $$ = $1; } | n557 "557" { assert ($1 == 557); $$ = $1; } | n558 "558" { assert ($1 == 558); $$ = $1; } | n559 "559" { assert ($1 == 559); $$ = $1; } | n560 "560" { assert ($1 == 560); $$ = $1; } | n561 "561" { assert ($1 == 561); $$ = $1; } | n562 "562" { assert ($1 == 562); $$ = $1; } | n563 "563" { assert ($1 == 563); $$ = $1; } | n564 "564" { assert ($1 == 564); $$ = $1; } | n565 "565" { assert ($1 == 565); $$ = $1; } | n566 "566" { assert ($1 == 566); $$ = $1; } | n567 "567" { assert ($1 == 567); $$ = $1; } | n568 "568" { assert ($1 == 568); $$ = $1; } | n569 "569" { assert ($1 == 569); $$ = $1; } | n570 "570" { assert ($1 == 570); $$ = $1; } | n571 "571" { assert ($1 == 571); $$ = $1; } | n572 "572" { assert ($1 == 572); $$ = $1; } | n573 "573" { assert ($1 == 573); $$ = $1; } | n574 "574" { assert ($1 == 574); $$ = $1; } | n575 "575" { assert ($1 == 575); $$ = $1; } | n576 "576" { assert ($1 == 576); $$ = $1; } | n577 "577" { assert ($1 == 577); $$ = $1; } | n578 "578" { assert ($1 == 578); $$ = $1; } | n579 "579" { assert ($1 == 579); $$ = $1; } | n580 "580" { assert ($1 == 580); $$ = $1; } | n581 "581" { assert ($1 == 581); $$ = $1; } | n582 "582" { assert ($1 == 582); $$ = $1; } | n583 "583" { assert ($1 == 583); $$ = $1; } | n584 "584" { assert ($1 == 584); $$ = $1; } | n585 "585" { assert ($1 == 585); $$ = $1; } | n586 "586" { assert ($1 == 586); $$ = $1; } | n587 "587" { assert ($1 == 587); $$ = $1; } | n588 "588" { assert ($1 == 588); $$ = $1; } | n589 "589" { assert ($1 == 589); $$ = $1; } | n590 "590" { assert ($1 == 590); $$ = $1; } | n591 "591" { assert ($1 == 591); $$ = $1; } | n592 "592" { assert ($1 == 592); $$ = $1; } | n593 "593" { assert ($1 == 593); $$ = $1; } | n594 "594" { assert ($1 == 594); $$ = $1; } | n595 "595" { assert ($1 == 595); $$ = $1; } | n596 "596" { assert ($1 == 596); $$ = $1; } | n597 "597" { assert ($1 == 597); $$ = $1; } | n598 "598" { assert ($1 == 598); $$ = $1; } | n599 "599" { assert ($1 == 599); $$ = $1; } | n600 "600" { assert ($1 == 600); $$ = $1; } | n601 "601" { assert ($1 == 601); $$ = $1; } | n602 "602" { assert ($1 == 602); $$ = $1; } | n603 "603" { assert ($1 == 603); $$ = $1; } | n604 "604" { assert ($1 == 604); $$ = $1; } | n605 "605" { assert ($1 == 605); $$ = $1; } | n606 "606" { assert ($1 == 606); $$ = $1; } | n607 "607" { assert ($1 == 607); $$ = $1; } | n608 "608" { assert ($1 == 608); $$ = $1; } | n609 "609" { assert ($1 == 609); $$ = $1; } | n610 "610" { assert ($1 == 610); $$ = $1; } | n611 "611" { assert ($1 == 611); $$ = $1; } | n612 "612" { assert ($1 == 612); $$ = $1; } | n613 "613" { assert ($1 == 613); $$ = $1; } | n614 "614" { assert ($1 == 614); $$ = $1; } | n615 "615" { assert ($1 == 615); $$ = $1; } | n616 "616" { assert ($1 == 616); $$ = $1; } | n617 "617" { assert ($1 == 617); $$ = $1; } | n618 "618" { assert ($1 == 618); $$ = $1; } | n619 "619" { assert ($1 == 619); $$ = $1; } | n620 "620" { assert ($1 == 620); $$ = $1; } | n621 "621" { assert ($1 == 621); $$ = $1; } | n622 "622" { assert ($1 == 622); $$ = $1; } | n623 "623" { assert ($1 == 623); $$ = $1; } | n624 "624" { assert ($1 == 624); $$ = $1; } | n625 "625" { assert ($1 == 625); $$ = $1; } | n626 "626" { assert ($1 == 626); $$ = $1; } | n627 "627" { assert ($1 == 627); $$ = $1; } | n628 "628" { assert ($1 == 628); $$ = $1; } | n629 "629" { assert ($1 == 629); $$ = $1; } | n630 "630" { assert ($1 == 630); $$ = $1; } | n631 "631" { assert ($1 == 631); $$ = $1; } | n632 "632" { assert ($1 == 632); $$ = $1; } | n633 "633" { assert ($1 == 633); $$ = $1; } | n634 "634" { assert ($1 == 634); $$ = $1; } | n635 "635" { assert ($1 == 635); $$ = $1; } | n636 "636" { assert ($1 == 636); $$ = $1; } | n637 "637" { assert ($1 == 637); $$ = $1; } | n638 "638" { assert ($1 == 638); $$ = $1; } | n639 "639" { assert ($1 == 639); $$ = $1; } | n640 "640" { assert ($1 == 640); $$ = $1; } | n641 "641" { assert ($1 == 641); $$ = $1; } | n642 "642" { assert ($1 == 642); $$ = $1; } | n643 "643" { assert ($1 == 643); $$ = $1; } | n644 "644" { assert ($1 == 644); $$ = $1; } | n645 "645" { assert ($1 == 645); $$ = $1; } | n646 "646" { assert ($1 == 646); $$ = $1; } | n647 "647" { assert ($1 == 647); $$ = $1; } | n648 "648" { assert ($1 == 648); $$ = $1; } | n649 "649" { assert ($1 == 649); $$ = $1; } | n650 "650" { assert ($1 == 650); $$ = $1; } | n651 "651" { assert ($1 == 651); $$ = $1; } | n652 "652" { assert ($1 == 652); $$ = $1; } | n653 "653" { assert ($1 == 653); $$ = $1; } | n654 "654" { assert ($1 == 654); $$ = $1; } | n655 "655" { assert ($1 == 655); $$ = $1; } | n656 "656" { assert ($1 == 656); $$ = $1; } | n657 "657" { assert ($1 == 657); $$ = $1; } | n658 "658" { assert ($1 == 658); $$ = $1; } | n659 "659" { assert ($1 == 659); $$ = $1; } | n660 "660" { assert ($1 == 660); $$ = $1; } | n661 "661" { assert ($1 == 661); $$ = $1; } | n662 "662" { assert ($1 == 662); $$ = $1; } | n663 "663" { assert ($1 == 663); $$ = $1; } | n664 "664" { assert ($1 == 664); $$ = $1; } | n665 "665" { assert ($1 == 665); $$ = $1; } | n666 "666" { assert ($1 == 666); $$ = $1; } | n667 "667" { assert ($1 == 667); $$ = $1; } | n668 "668" { assert ($1 == 668); $$ = $1; } | n669 "669" { assert ($1 == 669); $$ = $1; } | n670 "670" { assert ($1 == 670); $$ = $1; } | n671 "671" { assert ($1 == 671); $$ = $1; } | n672 "672" { assert ($1 == 672); $$ = $1; } | n673 "673" { assert ($1 == 673); $$ = $1; } | n674 "674" { assert ($1 == 674); $$ = $1; } | n675 "675" { assert ($1 == 675); $$ = $1; } | n676 "676" { assert ($1 == 676); $$ = $1; } | n677 "677" { assert ($1 == 677); $$ = $1; } | n678 "678" { assert ($1 == 678); $$ = $1; } | n679 "679" { assert ($1 == 679); $$ = $1; } | n680 "680" { assert ($1 == 680); $$ = $1; } | n681 "681" { assert ($1 == 681); $$ = $1; } | n682 "682" { assert ($1 == 682); $$ = $1; } | n683 "683" { assert ($1 == 683); $$ = $1; } | n684 "684" { assert ($1 == 684); $$ = $1; } | n685 "685" { assert ($1 == 685); $$ = $1; } | n686 "686" { assert ($1 == 686); $$ = $1; } | n687 "687" { assert ($1 == 687); $$ = $1; } | n688 "688" { assert ($1 == 688); $$ = $1; } | n689 "689" { assert ($1 == 689); $$ = $1; } | n690 "690" { assert ($1 == 690); $$ = $1; } | n691 "691" { assert ($1 == 691); $$ = $1; } | n692 "692" { assert ($1 == 692); $$ = $1; } | n693 "693" { assert ($1 == 693); $$ = $1; } | n694 "694" { assert ($1 == 694); $$ = $1; } | n695 "695" { assert ($1 == 695); $$ = $1; } | n696 "696" { assert ($1 == 696); $$ = $1; } | n697 "697" { assert ($1 == 697); $$ = $1; } | n698 "698" { assert ($1 == 698); $$ = $1; } | n699 "699" { assert ($1 == 699); $$ = $1; } | n700 "700" { assert ($1 == 700); $$ = $1; } | n701 "701" { assert ($1 == 701); $$ = $1; } | n702 "702" { assert ($1 == 702); $$ = $1; } | n703 "703" { assert ($1 == 703); $$ = $1; } | n704 "704" { assert ($1 == 704); $$ = $1; } | n705 "705" { assert ($1 == 705); $$ = $1; } | n706 "706" { assert ($1 == 706); $$ = $1; } | n707 "707" { assert ($1 == 707); $$ = $1; } | n708 "708" { assert ($1 == 708); $$ = $1; } | n709 "709" { assert ($1 == 709); $$ = $1; } | n710 "710" { assert ($1 == 710); $$ = $1; } | n711 "711" { assert ($1 == 711); $$ = $1; } | n712 "712" { assert ($1 == 712); $$ = $1; } | n713 "713" { assert ($1 == 713); $$ = $1; } | n714 "714" { assert ($1 == 714); $$ = $1; } | n715 "715" { assert ($1 == 715); $$ = $1; } | n716 "716" { assert ($1 == 716); $$ = $1; } | n717 "717" { assert ($1 == 717); $$ = $1; } | n718 "718" { assert ($1 == 718); $$ = $1; } | n719 "719" { assert ($1 == 719); $$ = $1; } | n720 "720" { assert ($1 == 720); $$ = $1; } | n721 "721" { assert ($1 == 721); $$ = $1; } | n722 "722" { assert ($1 == 722); $$ = $1; } | n723 "723" { assert ($1 == 723); $$ = $1; } | n724 "724" { assert ($1 == 724); $$ = $1; } | n725 "725" { assert ($1 == 725); $$ = $1; } | n726 "726" { assert ($1 == 726); $$ = $1; } | n727 "727" { assert ($1 == 727); $$ = $1; } | n728 "728" { assert ($1 == 728); $$ = $1; } | n729 "729" { assert ($1 == 729); $$ = $1; } | n730 "730" { assert ($1 == 730); $$ = $1; } | n731 "731" { assert ($1 == 731); $$ = $1; } | n732 "732" { assert ($1 == 732); $$ = $1; } | n733 "733" { assert ($1 == 733); $$ = $1; } | n734 "734" { assert ($1 == 734); $$ = $1; } | n735 "735" { assert ($1 == 735); $$ = $1; } | n736 "736" { assert ($1 == 736); $$ = $1; } | n737 "737" { assert ($1 == 737); $$ = $1; } | n738 "738" { assert ($1 == 738); $$ = $1; } | n739 "739" { assert ($1 == 739); $$ = $1; } | n740 "740" { assert ($1 == 740); $$ = $1; } | n741 "741" { assert ($1 == 741); $$ = $1; } | n742 "742" { assert ($1 == 742); $$ = $1; } | n743 "743" { assert ($1 == 743); $$ = $1; } | n744 "744" { assert ($1 == 744); $$ = $1; } | n745 "745" { assert ($1 == 745); $$ = $1; } | n746 "746" { assert ($1 == 746); $$ = $1; } | n747 "747" { assert ($1 == 747); $$ = $1; } | n748 "748" { assert ($1 == 748); $$ = $1; } | n749 "749" { assert ($1 == 749); $$ = $1; } | n750 "750" { assert ($1 == 750); $$ = $1; } | n751 "751" { assert ($1 == 751); $$ = $1; } | n752 "752" { assert ($1 == 752); $$ = $1; } | n753 "753" { assert ($1 == 753); $$ = $1; } | n754 "754" { assert ($1 == 754); $$ = $1; } | n755 "755" { assert ($1 == 755); $$ = $1; } | n756 "756" { assert ($1 == 756); $$ = $1; } | n757 "757" { assert ($1 == 757); $$ = $1; } | n758 "758" { assert ($1 == 758); $$ = $1; } | n759 "759" { assert ($1 == 759); $$ = $1; } | n760 "760" { assert ($1 == 760); $$ = $1; } | n761 "761" { assert ($1 == 761); $$ = $1; } | n762 "762" { assert ($1 == 762); $$ = $1; } | n763 "763" { assert ($1 == 763); $$ = $1; } | n764 "764" { assert ($1 == 764); $$ = $1; } | n765 "765" { assert ($1 == 765); $$ = $1; } | n766 "766" { assert ($1 == 766); $$ = $1; } | n767 "767" { assert ($1 == 767); $$ = $1; } | n768 "768" { assert ($1 == 768); $$ = $1; } | n769 "769" { assert ($1 == 769); $$ = $1; } | n770 "770" { assert ($1 == 770); $$ = $1; } | n771 "771" { assert ($1 == 771); $$ = $1; } | n772 "772" { assert ($1 == 772); $$ = $1; } | n773 "773" { assert ($1 == 773); $$ = $1; } | n774 "774" { assert ($1 == 774); $$ = $1; } | n775 "775" { assert ($1 == 775); $$ = $1; } | n776 "776" { assert ($1 == 776); $$ = $1; } | n777 "777" { assert ($1 == 777); $$ = $1; } | n778 "778" { assert ($1 == 778); $$ = $1; } | n779 "779" { assert ($1 == 779); $$ = $1; } | n780 "780" { assert ($1 == 780); $$ = $1; } | n781 "781" { assert ($1 == 781); $$ = $1; } | n782 "782" { assert ($1 == 782); $$ = $1; } | n783 "783" { assert ($1 == 783); $$ = $1; } | n784 "784" { assert ($1 == 784); $$ = $1; } | n785 "785" { assert ($1 == 785); $$ = $1; } | n786 "786" { assert ($1 == 786); $$ = $1; } | n787 "787" { assert ($1 == 787); $$ = $1; } | n788 "788" { assert ($1 == 788); $$ = $1; } | n789 "789" { assert ($1 == 789); $$ = $1; } | n790 "790" { assert ($1 == 790); $$ = $1; } | n791 "791" { assert ($1 == 791); $$ = $1; } | n792 "792" { assert ($1 == 792); $$ = $1; } | n793 "793" { assert ($1 == 793); $$ = $1; } | n794 "794" { assert ($1 == 794); $$ = $1; } | n795 "795" { assert ($1 == 795); $$ = $1; } | n796 "796" { assert ($1 == 796); $$ = $1; } | n797 "797" { assert ($1 == 797); $$ = $1; } | n798 "798" { assert ($1 == 798); $$ = $1; } | n799 "799" { assert ($1 == 799); $$ = $1; } | n800 "800" { assert ($1 == 800); $$ = $1; } | n801 "801" { assert ($1 == 801); $$ = $1; } | n802 "802" { assert ($1 == 802); $$ = $1; } | n803 "803" { assert ($1 == 803); $$ = $1; } | n804 "804" { assert ($1 == 804); $$ = $1; } | n805 "805" { assert ($1 == 805); $$ = $1; } | n806 "806" { assert ($1 == 806); $$ = $1; } | n807 "807" { assert ($1 == 807); $$ = $1; } | n808 "808" { assert ($1 == 808); $$ = $1; } | n809 "809" { assert ($1 == 809); $$ = $1; } | n810 "810" { assert ($1 == 810); $$ = $1; } | n811 "811" { assert ($1 == 811); $$ = $1; } | n812 "812" { assert ($1 == 812); $$ = $1; } | n813 "813" { assert ($1 == 813); $$ = $1; } | n814 "814" { assert ($1 == 814); $$ = $1; } | n815 "815" { assert ($1 == 815); $$ = $1; } | n816 "816" { assert ($1 == 816); $$ = $1; } | n817 "817" { assert ($1 == 817); $$ = $1; } | n818 "818" { assert ($1 == 818); $$ = $1; } | n819 "819" { assert ($1 == 819); $$ = $1; } | n820 "820" { assert ($1 == 820); $$ = $1; } | n821 "821" { assert ($1 == 821); $$ = $1; } | n822 "822" { assert ($1 == 822); $$ = $1; } | n823 "823" { assert ($1 == 823); $$ = $1; } | n824 "824" { assert ($1 == 824); $$ = $1; } | n825 "825" { assert ($1 == 825); $$ = $1; } | n826 "826" { assert ($1 == 826); $$ = $1; } | n827 "827" { assert ($1 == 827); $$ = $1; } | n828 "828" { assert ($1 == 828); $$ = $1; } | n829 "829" { assert ($1 == 829); $$ = $1; } | n830 "830" { assert ($1 == 830); $$ = $1; } | n831 "831" { assert ($1 == 831); $$ = $1; } | n832 "832" { assert ($1 == 832); $$ = $1; } | n833 "833" { assert ($1 == 833); $$ = $1; } | n834 "834" { assert ($1 == 834); $$ = $1; } | n835 "835" { assert ($1 == 835); $$ = $1; } | n836 "836" { assert ($1 == 836); $$ = $1; } | n837 "837" { assert ($1 == 837); $$ = $1; } | n838 "838" { assert ($1 == 838); $$ = $1; } | n839 "839" { assert ($1 == 839); $$ = $1; } | n840 "840" { assert ($1 == 840); $$ = $1; } | n841 "841" { assert ($1 == 841); $$ = $1; } | n842 "842" { assert ($1 == 842); $$ = $1; } | n843 "843" { assert ($1 == 843); $$ = $1; } | n844 "844" { assert ($1 == 844); $$ = $1; } | n845 "845" { assert ($1 == 845); $$ = $1; } | n846 "846" { assert ($1 == 846); $$ = $1; } | n847 "847" { assert ($1 == 847); $$ = $1; } | n848 "848" { assert ($1 == 848); $$ = $1; } | n849 "849" { assert ($1 == 849); $$ = $1; } | n850 "850" { assert ($1 == 850); $$ = $1; } | n851 "851" { assert ($1 == 851); $$ = $1; } | n852 "852" { assert ($1 == 852); $$ = $1; } | n853 "853" { assert ($1 == 853); $$ = $1; } | n854 "854" { assert ($1 == 854); $$ = $1; } | n855 "855" { assert ($1 == 855); $$ = $1; } | n856 "856" { assert ($1 == 856); $$ = $1; } | n857 "857" { assert ($1 == 857); $$ = $1; } | n858 "858" { assert ($1 == 858); $$ = $1; } | n859 "859" { assert ($1 == 859); $$ = $1; } | n860 "860" { assert ($1 == 860); $$ = $1; } | n861 "861" { assert ($1 == 861); $$ = $1; } | n862 "862" { assert ($1 == 862); $$ = $1; } | n863 "863" { assert ($1 == 863); $$ = $1; } | n864 "864" { assert ($1 == 864); $$ = $1; } | n865 "865" { assert ($1 == 865); $$ = $1; } | n866 "866" { assert ($1 == 866); $$ = $1; } | n867 "867" { assert ($1 == 867); $$ = $1; } | n868 "868" { assert ($1 == 868); $$ = $1; } | n869 "869" { assert ($1 == 869); $$ = $1; } | n870 "870" { assert ($1 == 870); $$ = $1; } | n871 "871" { assert ($1 == 871); $$ = $1; } | n872 "872" { assert ($1 == 872); $$ = $1; } | n873 "873" { assert ($1 == 873); $$ = $1; } | n874 "874" { assert ($1 == 874); $$ = $1; } | n875 "875" { assert ($1 == 875); $$ = $1; } | n876 "876" { assert ($1 == 876); $$ = $1; } | n877 "877" { assert ($1 == 877); $$ = $1; } | n878 "878" { assert ($1 == 878); $$ = $1; } | n879 "879" { assert ($1 == 879); $$ = $1; } | n880 "880" { assert ($1 == 880); $$ = $1; } | n881 "881" { assert ($1 == 881); $$ = $1; } | n882 "882" { assert ($1 == 882); $$ = $1; } | n883 "883" { assert ($1 == 883); $$ = $1; } | n884 "884" { assert ($1 == 884); $$ = $1; } | n885 "885" { assert ($1 == 885); $$ = $1; } | n886 "886" { assert ($1 == 886); $$ = $1; } | n887 "887" { assert ($1 == 887); $$ = $1; } | n888 "888" { assert ($1 == 888); $$ = $1; } | n889 "889" { assert ($1 == 889); $$ = $1; } | n890 "890" { assert ($1 == 890); $$ = $1; } | n891 "891" { assert ($1 == 891); $$ = $1; } | n892 "892" { assert ($1 == 892); $$ = $1; } | n893 "893" { assert ($1 == 893); $$ = $1; } | n894 "894" { assert ($1 == 894); $$ = $1; } | n895 "895" { assert ($1 == 895); $$ = $1; } | n896 "896" { assert ($1 == 896); $$ = $1; } | n897 "897" { assert ($1 =./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 = 897); $$ = $1; } | n898 "898" { assert ($1 == 898); $$ = $1; } | n899 "899" { assert ($1 == 899); $$ = $1; } | n900 "900" { assert ($1 == 900); $$ = $1; } | n901 "901" { assert ($1 == 901); $$ = $1; } | n902 "902" { assert ($1 == 902); $$ = $1; } | n903 "903" { assert ($1 == 903); $$ = $1; } | n904 "904" { assert ($1 == 904); $$ = $1; } | n905 "905" { assert ($1 == 905); $$ = $1; } | n906 "906" { assert ($1 == 906); $$ = $1; } | n907 "907" { assert ($1 == 907); $$ = $1; } | n908 "908" { assert ($1 == 908); $$ = $1; } | n909 "909" { assert ($1 == 909); $$ = $1; } | n910 "910" { assert ($1 == 910); $$ = $1; } | n911 "911" { assert ($1 == 911); $$ = $1; } | n912 "912" { assert ($1 == 912); $$ = $1; } | n913 "913" { assert ($1 == 913); $$ = $1; } | n914 "914" { assert ($1 == 914); $$ = $1; } | n915 "915" { assert ($1 == 915); $$ = $1; } | n916 "916" { assert ($1 == 916); $$ = $1; } | n917 "917" { assert ($1 == 917); $$ = $1; } | n918 "918" { assert ($1 == 918); $$ = $1; } | n919 "919" { assert ($1 == 919); $$ = $1; } | n920 "920" { assert ($1 == 920); $$ = $1; } | n921 "921" { assert ($1 == 921); $$ = $1; } | n922 "922" { assert ($1 == 922); $$ = $1; } | n923 "923" { assert ($1 == 923); $$ = $1; } | n924 "924" { assert ($1 == 924); $$ = $1; } | n925 "925" { assert ($1 == 925); $$ = $1; } | n926 "926" { assert ($1 == 926); $$ = $1; } | n927 "927" { assert ($1 == 927); $$ = $1; } | n928 "928" { assert ($1 == 928); $$ = $1; } | n929 "929" { assert ($1 == 929); $$ = $1; } | n930 "930" { assert ($1 == 930); $$ = $1; } | n931 "931" { assert ($1 == 931); $$ = $1; } | n932 "932" { assert ($1 == 932); $$ = $1; } | n933 "933" { assert ($1 == 933); $$ = $1; } | n934 "934" { assert ($1 == 934); $$ = $1; } | n935 "935" { assert ($1 == 935); $$ = $1; } | n936 "936" { assert ($1 == 936); $$ = $1; } | n937 "937" { assert ($1 == 937); $$ = $1; } | n938 "938" { assert ($1 == 938); $$ = $1; } | n939 "939" { assert ($1 == 939); $$ = $1; } | n940 "940" { assert ($1 == 940); $$ = $1; } | n941 "941" { assert ($1 == 941); $$ = $1; } | n942 "942" { assert ($1 == 942); $$ = $1; } | n943 "943" { assert ($1 == 943); $$ = $1; } | n944 "944" { assert ($1 == 944); $$ = $1; } | n945 "945" { assert ($1 == 945); $$ = $1; } | n946 "946" { assert ($1 == 946); $$ = $1; } | n947 "947" { assert ($1 == 947); $$ = $1; } | n948 "948" { assert ($1 == 948); $$ = $1; } | n949 "949" { assert ($1 == 949); $$ = $1; } | n950 "950" { assert ($1 == 950); $$ = $1; } | n951 "951" { assert ($1 == 951); $$ = $1; } | n952 "952" { assert ($1 == 952); $$ = $1; } | n953 "953" { assert ($1 == 953); $$ = $1; } | n954 "954" { assert ($1 == 954); $$ = $1; } | n955 "955" { assert ($1 == 955); $$ = $1; } | n956 "956" { assert ($1 == 956); $$ = $1; } | n957 "957" { assert ($1 == 957); $$ = $1; } | n958 "958" { assert ($1 == 958); $$ = $1; } | n959 "959" { assert ($1 == 959); $$ = $1; } | n960 "960" { assert ($1 == 960); $$ = $1; } | n961 "961" { assert ($1 == 961); $$ = $1; } | n962 "962" { assert ($1 == 962); $$ = $1; } | n963 "963" { assert ($1 == 963); $$ = $1; } | n964 "964" { assert ($1 == 964); $$ = $1; } | n965 "965" { assert ($1 == 965); $$ = $1; } | n966 "966" { assert ($1 == 966); $$ = $1; } | n967 "967" { assert ($1 == 967); $$ = $1; } | n968 "968" { assert ($1 == 968); $$ = $1; } | n969 "969" { assert ($1 == 969); $$ = $1; } | n970 "970" { assert ($1 == 970); $$ = $1; } | n971 "971" { assert ($1 == 971); $$ = $1; } | n972 "972" { assert ($1 == 972); $$ = $1; } | n973 "973" { assert ($1 == 973); $$ = $1; } | n974 "974" { assert ($1 == 974); $$ = $1; } | n975 "975" { assert ($1 == 975); $$ = $1; } | n976 "976" { assert ($1 == 976); $$ = $1; } | n977 "977" { assert ($1 == 977); $$ = $1; } | n978 "978" { assert ($1 == 978); $$ = $1; } | n979 "979" { assert ($1 == 979); $$ = $1; } | n980 "980" { assert ($1 == 980); $$ = $1; } | n981 "981" { assert ($1 == 981); $$ = $1; } | n982 "982" { assert ($1 == 982); $$ = $1; } | n983 "983" { assert ($1 == 983); $$ = $1; } | n984 "984" { assert ($1 == 984); $$ = $1; } | n985 "985" { assert ($1 == 985); $$ = $1; } | n986 "986" { assert ($1 == 986); $$ = $1; } | n987 "987" { assert ($1 == 987); $$ = $1; } | n988 "988" { assert ($1 == 988); $$ = $1; } | n989 "989" { assert ($1 == 989); $$ = $1; } | n990 "990" { assert ($1 == 990); $$ = $1; } | n991 "991" { assert ($1 == 991); $$ = $1; } | n992 "992" { assert ($1 == 992); $$ = $1; } | n993 "993" { assert ($1 == 993); $$ = $1; } | n994 "994" { assert ($1 == 994); $$ = $1; } | n995 "995" { assert ($1 == 995); $$ = $1; } | n996 "996" { assert ($1 == 996); $$ = $1; } | n997 "997" { assert ($1 == 997); $$ = $1; } | n998 "998" { assert ($1 == 998); $$ = $1; } | n999 "999" { assert ($1 == 999); $$ = $1; } | n1000 "1000" { assert ($1 == 1000); $$ = $1; } ; n1: token { $$ = 1; }; n2: token { $$ = 2; }; n3: token { $$ = 3; }; n4: token { $$ = 4; }; n5: token { $$ = 5; }; n6: token { $$ = 6; }; n7: token { $$ = 7; }; n8: token { $$ = 8; }; n9: token { $$ = 9; }; n10: token { $$ = 10; }; n11: token { $$ = 11; }; n12: token { $$ = 12; }; n13: token { $$ = 13; }; n14: token { $$ = 14; }; n15: token { $$ = 15; }; n16: token { $$ = 16; }; n17: token { $$ = 17; }; n18: token { $$ = 18; }; n19: token { $$ = 19; }; n20: token { $$ = 20; }; n21: token { $$ = 21; }; n22: token { $$ = 22; }; n23: token { $$ = 23; }; n24: token { $$ = 24; }; n25: token { $$ = 25; }; n26: token { $$ = 26; }; n27: token { $$ = 27; }; n28: token { $$ = 28; }; n29: token { $$ = 29; }; n30: token { $$ = 30; }; n31: token { $$ = 31; }; n32: token { $$ = 32; }; n33: token { $$ = 33; }; n34: token { $$ = 34; }; n35: token { $$ = 35; }; n36: token { $$ = 36; }; n37: token { $$ = 37; }; n38: token { $$ = 38; }; n39: token { $$ = 39; }; n40: token { $$ = 40; }; n41: token { $$ = 41; }; n42: token { $$ = 42; }; n43: token { $$ = 43; }; n44: token { $$ = 44; }; n45: token { $$ = 45; }; n46: token { $$ = 46; }; n47: token { $$ = 47; }; n48: token { $$ = 48; }; n49: token { $$ = 49; }; n50: token { $$ = 50; }; n51: token { $$ = 51; }; n52: token { $$ = 52; }; n53: token { $$ = 53; }; n54: token { $$ = 54; }; n55: token { $$ = 55; }; n56: token { $$ = 56; }; n57: token { $$ = 57; }; n58: token { $$ = 58; }; n59: token { $$ = 59; }; n60: token { $$ = 60; }; n61: token { $$ = 61; }; n62: token { $$ = 62; }; n63: token { $$ = 63; }; n64: token { $$ = 64; }; n65: token { $$ = 65; }; n66: token { $$ = 66; }; n67: token { $$ = 67; }; n68: token { $$ = 68; }; n69: token { $$ = 69; }; n70: token { $$ = 70; }; n71: token { $$ = 71; }; n72: token { $$ = 72; }; n73: token { $$ = 73; }; n74: token { $$ = 74; }; n75: token { $$ = 75; }; n76: token { $$ = 76; }; n77: token { $$ = 77; }; n78: token { $$ = 78; }; n79: token { $$ = 79; }; n80: token { $$ = 80; }; n81: token { $$ = 81; }; n82: token { $$ = 82; }; n83: token { $$ = 83; }; n84: token { $$ = 84; }; n85: token { $$ = 85; }; n86: token { $$ = 86; }; n87: token { $$ = 87; }; n88: token { $$ = 88; }; n89: token { $$ = 89; }; n90: token { $$ = 90; }; n91: token { $$ = 91; }; n92: token { $$ = 92; }; n93: token { $$ = 93; }; n94: token { $$ = 94; }; n95: token { $$ = 95; }; n96: token { $$ = 96; }; n97: token { $$ = 97; }; n98: token { $$ = 98; }; n99: token { $$ = 99; }; n100: token { $$ = 100; }; n101: token { $$ = 101; }; n102: token { $$ = 102; }; n103: token { $$ = 103; }; n104: token { $$ = 104; }; n105: token { $$ = 105; }; n106: token { $$ = 106; }; n107: token { $$ = 107; }; n108: token { $$ = 108; }; n109: token { $$ = 109; }; n110: token { $$ = 110; }; n111: token { $$ = 111; }; n112: token { $$ = 112; }; n113: token { $$ = 113; }; n114: token { $$ = 114; }; n115: token { $$ = 115; }; n116: token { $$ = 116; }; n117: token { $$ = 117; }; n118: token { $$ = 118; }; n119: token { $$ = 119; }; n120: token { $$ = 120; }; n121: token { $$ = 121; }; n122: token { $$ = 122; }; n123: token { $$ = 123; }; n124: token { $$ = 124; }; n125: token { $$ = 125; }; n126: token { $$ = 126; }; n127: token { $$ = 127; }; n128: token { $$ = 128; }; n129: token { $$ = 129; }; n130: token { $$ = 130; }; n131: token { $$ = 131; }; n132: token { $$ = 132; }; n133: token { $$ = 133; }; n134: token { $$ = 134; }; n135: token { $$ = 135; }; n136: token { $$ = 136; }; n137: token { $$ = 137; }; n138: token { $$ = 138; }; n139: token { $$ = 139; }; n140: token { $$ = 140; }; n141: token { $$ = 141; }; n142: token { $$ = 142; }; n143: token { $$ = 143; }; n144: token { $$ = 144; }; n145: token { $$ = 145; }; n146: token { $$ = 146; }; n147: token { $$ = 147; }; n148: token { $$ = 148; }; n149: token { $$ = 149; }; n150: token { $$ = 150; }; n151: token { $$ = 151; }; n152: token { $$ = 152; }; n153: token { $$ = 153; }; n154: token { $$ = 154; }; n155: token { $$ = 155; }; n156: token { $$ = 156; }; n157: token { $$ = 157; }; n158: token { $$ = 158; }; n159: token { $$ = 159; }; n160: token { $$ = 160; }; n161: token { $$ = 161; }; n162: token { $$ = 162; }; n163: token { $$ = 163; }; n164: token { $$ = 164; }; n165: token { $$ = 165; }; n166: token { $$ = 166; }; n167: token { $$ = 167; }; n168: token { $$ = 168; }; n169: token { $$ = 169; }; n170: token { $$ = 170; }; n171: token { $$ = 171; }; n172: token { $$ = 172; }; n173: token { $$ = 173; }; n174: token { $$ = 174; }; n175: token { $$ = 175; }; n176: token { $$ = 176; }; n177: token { $$ = 177; }; n178: token { $$ = 178; }; n179: token { $$ = 179; }; n180: token { $$ = 180; }; n181: token { $$ = 181; }; n182: token { $$ = 182; }; n183: token { $$ = 183; }; n184: token { $$ = 184; }; n185: token { $$ = 185; }; n186: token { $$ = 186; }; n187: token { $$ = 187; }; n188: token { $$ = 188; }; n189: token { $$ = 189; }; n190: token { $$ = 190; }; n191: token { $$ = 191; }; n192: token { $$ = 192; }; n193: token { $$ = 193; }; n194: token { $$ = 194; }; n195: token { $$ = 195; }; n196: token { $$ = 196; }; n197: token { $$ = 197; }; n198: token { $$ = 198; }; n199: token { $$ = 199; }; n200: token { $$ = 200; }; n201: token { $$ = 201; }; n202: token { $$ = 202; }; n203: token { $$ = 203; }; n204: token { $$ = 204; }; n205: token { $$ = 205; }; n206: token { $$ = 206; }; n207: token { $$ = 207; }; n208: token { $$ = 208; }; n209: token { $$ = 209; }; n210: token { $$ = 210; }; n211: token { $$ = 211; }; n212: token { $$ = 212; }; n213: token { $$ = 213; }; n214: token { $$ = 214; }; n215: token { $$ = 215; }; n216: token { $$ = 216; }; n217: token { $$ = 217; }; n218: token { $$ = 218; }; n219: token { $$ = 219; }; n220: token { $$ = 220; }; n221: token { $$ = 221; }; n222: token { $$ = 222; }; n223: token { $$ = 223; }; n224: token { $$ = 224; }; n225: token { $$ = 225; }; n226: token { $$ = 226; }; n227: token { $$ = 227; }; n228: token { $$ = 228; }; n229: token { $$ = 229; }; n230: token { $$ = 230; }; n231: token { $$ = 231; }; n232: token { $$ = 232; }; n233: token { $$ = 233; }; n234: token { $$ = 234; }; n235: token { $$ = 235; }; n236: token { $$ = 236; }; n237: token { $$ = 237; }; n238: token { $$ = 238; }; n239: token { $$ = 239; }; n240: token { $$ = 240; }; n241: token { $$ = 241; }; n242: token { $$ = 242; }; n243: token { $$ = 243; }; n244: token { $$ = 244; }; n245: token { $$ = 245; }; n246: token { $$ = 246; }; n247: token { $$ = 247; }; n248: token { $$ = 248; }; n249: token { $$ = 249; }; n250: token { $$ = 250; }; n251: token { $$ = 251; }; n252: token { $$ = 252; }; n253: token { $$ = 253; }; n254: token { $$ = 254; }; n255: token { $$ = 255; }; n256: token { $$ = 256; }; n257: token { $$ = 257; }; n258: token { $$ = 258; }; n259: token { $$ = 259; }; n260: token { $$ = 260; }; n261: token { $$ = 261; }; n262: token { $$ = 262; }; n263: token { $$ = 263; }; n264: token { $$ = 264; }; n265: token { $$ = 265; }; n266: token { $$ = 266; }; n267: token { $$ = 267; }; n268: token { $$ = 268; }; n269: token { $$ = 269; }; n270: token { $$ = 270; }; n271: token { $$ = 271; }; n272: token { $$ = 272; }; n273: token { $$ = 273; }; n274: token { $$ = 274; }; n275: token { $$ = 275; }; n276: token { $$ = 276; }; n277: token { $$ = 277; }; n278: token { $$ = 278; }; n279: token { $$ = 279; }; n280: token { $$ = 280; }; n281: token { $$ = 281; }; n282: token { $$ = 282; }; n283: token { $$ = 283; }; n284: token { $$ = 284; }; n285: token { $$ = 285; }; n286: token { $$ = 286; }; n287: token { $$ = 287; }; n288: token { $$ = 288; }; n289: token { $$ = 289; }; n290: token { $$ = 290; }; n291: token { $$ = 291; }; n292: token { $$ = 292; }; n293: token { $$ = 293; }; n294: token { $$ = 294; }; n295: token { $$ = 295; }; n296: token { $$ = 296; }; n297: token { $$ = 297; }; n298: token { $$ = 298; }; n299: token { $$ = 299; }; n300: token { $$ = 300; }; n301: token { $$ = 301; }; n302: token { $$ = 302; }; n303: token { $$ = 303; }; n304: token { $$ = 304; }; n305: token { $$ = 305; }; n306: token { $$ = 306; }; n307: token { $$ = 307; }; n308: token { $$ = 308; }; n309: token { $$ = 309; }; n310: token { $$ = 310; }; n311: token { $$ = 311; }; n312: token { $$ = 312; }; n313: token { $$ = 313; }; n314: token { $$ = 314; }; n315: token { $$ = 315; }; n316: token { $$ = 316; }; n317: token { $$ = 317; }; n318: token { $$ = 318; }; n319: token { $$ = 319; }; n320: token { $$ = 320; }; n321: token { $$ = 321; }; n322: token { $$ = 322; }; n323: token { $$ = 323; }; n324: token { $$ = 324; }; n325: token { $$ = 325; }; n326: token { $$ = 326; }; n327: token { $$ = 327; }; n328: token { $$ = 328; }; n329: token { $$ = 329; }; n330: token { $$ = 330; }; n331: token { $$ = 331; }; n332: token { $$ = 332; }; n333: token { $$ = 333; }; n334: token { $$ = 334; }; n335: token { $$ = 335; }; n336: token { $$ = 336; }; n337: token { $$ = 337; }; n338: token { $$ = 338; }; n339: token { $$ = 339; }; n340: token { $$ = 340; }; n341: token { $$ = 341; }; n342: token { $$ = 342; }; n343: token { $$ = 343; }; n344: token { $$ = 344; }; n345: token { $$ = 345; }; n346: token { $$ = 346; }; n347: token { $$ = 347; }; n348: token { $$ = 348; }; n349: token { $$ = 349; }; n350: token { $$ = 350; }; n351: token { $$ = 351; }; n352: token { $$ = 352; }; n353: token { $$ = 353; }; n354: token { $$ = 354; }; n355: token { $$ = 355; }; n356: token { $$ = 356; }; n357: token { $$ = 357; }; n358: token { $$ = 358; }; n359: token { $$ = 359; }; n360: token { $$ = 360; }; n361: token { $$ = 361; }; n362: token { $$ = 362; }; n363: token { $$ = 363; }; n364: token { $$ = 364; }; n365: token { $$ = 365; }; n366: token { $$ = 366; }; n367: token { $$ = 367; }; n368: token { $$ = 368; }; n369: token { $$ = 369; }; n370: token { $$ = 370; }; n371: token { $$ = 371; }; n372: token { $$ = 372; }; n373: token { $$ = 373; }; n374: token { $$ = 374; }; n375: token { $$ = 375; }; n376: token { $$ = 376; }; n377: token { $$ = 377; }; n378: token { $$ = 378; }; n379: token { $$ = 379; }; n380: token { $$ = 380; }; n381: token { $$ = 381; }; n382: token { $$ = 382; }; n383: token { $$ = 383; }; n384: token { $$ = 384; }; n385: token { $$ = 385; }; n386: token { $$ = 386; }; n387: token { $$ = 387; }; n388: token { $$ = 388; }; n389: token { $$ = 389; }; n390: token { $$ = 390; }; n391: token { $$ = 391; }; n392: token { $$ = 392; }; n393: token { $$ = 393; }; n394: token { $$ = 394; }; n395: token { $$ = 395; }; n396: token { $$ = 396; }; n397: token { $$ = 397; }; n398: token { $$ = 398; }; n399: token { $$ = 399; }; n400: token { $$ = 400; }; n401: token { $$ = 401; }; n402: token { $$ = 402; }; n403: token { $$ = 403; }; n404: token { $$ = 404; }; n405: token { $$ = 405; }; n406: token { $$ = 406; }; n407: token { $$ = 407; }; n408: token { $$ = 408; }; n409: token { $$ = 409; }; n410: token { $$ = 410; }; n411: token { $$ = 411; }; n412: token { $$ = 412; }; n413: token { $$ = 413; }; n414: token { $$ = 414; }; n415: token { $$ = 415; }; n416: token { $$ = 416; }; n417: token { $$ = 417; }; n418: token { $$ = 418; }; n419: token { $$ = 419; }; n420: token { $$ = 420; }; n421: token { $$ = 421; }; n422: token { $$ = 422; }; n423: token { $$ = 423; }; n424: token { $$ = 424; }; n425: token { $$ = 425; }; n426: token { $$ = 426; }; n427: token { $$ = 427; }; n428: token { $$ = 428; }; n429: token { $$ = 429; }; n430: token { $$ = 430; }; n431: token { $$ = 431; }; n432: token { $$ = 432; }; n433: token { $$ = 433; }; n434: token { $$ = 434; }; n435: token { $$ = 435; }; n436: token { $$ = 436; }; n437: token { $$ = 437; }; n438: token { $$ = 438; }; n439: token { $$ = 439; }; n440: token { $$ = 440; }; n441: token { $$ = 441; }; n442: token { $$ = 442; }; n443: token { $$ = 443; }; n444: token { $$ = 444; }; n445: token { $$ = 445; }; n446: token { $$ = 446; }; n447: token { $$ = 447; }; n448: token { $$ = 448; }; n449: token { $$ = 449; }; n450: token { $$ = 450; }; n451: token { $$ = 451; }; n452: token { $$ = 452; }; n453: token { $$ = 453; }; n454: token { $$ = 454; }; n455: token { $$ = 455; }; n456: token { $$ = 456; }; n457: token { $$ = 457; }; n458: token { $$ = 458; }; n459: token { $$ = 459; }; n460: token { $$ = 460; }; n461: token { $$ = 461; }; n462: token { $$ = 462; }; n463: token { $$ = 463; }; n464: token { $$ = 464; }; n465: token { $$ = 465; }; n466: token { $$ = 466; }; n467: token { $$ = 467; }; n468: token { $$ = 468; }; n469: token { $$ = 469; }; n470: token { $$ = 470; }; n471: token { $$ = 471; }; n472: token { $$ = 472; }; n473: token { $$ = 473; }; n474: token { $$ = 474; }; n475: token { $$ = 475; }; n476: token { $$ = 476; }; n477: token { $$ = 477; }; n478: token { $$ = 478; }; n479: token { $$ = 479; }; n480: token { $$ = 480; }; n481: token { $$ = 481; }; n482: token { $$ = 482; }; n483: token { $$ = 483; }; n484: token { $$ = 484; }; n485: token { $$ = 485; }; n486: token { $$ = 486; }; n487: token { $$ = 487; }; n488: token { $$ = 488; }; n489: token { $$ = 489; }; n490: token { $$ = 490; }; n491: token { $$ = 491; }; n492: token { $$ = 492; }; n493: token { $$ = 493; }; n494: token { $$ = 494; }; n495: token { $$ = 495; }; n496: token { $$ = 496; }; n497: token { $$ = 497; }; n498: token { $$ = 498; }; n499: token { $$ = 499; }; n500: token { $$ = 500; }; n501: token { $$ = 501; }; n502: token { $$ = 502; }; n503: token { $$ = 503; }; n504: token { $$ = 504; }; n505: token { $$ = 505; }; n506: token { $$ = 506; }; n507: token { $$ = 507; }; n508: token { $$ = 508; }; n509: token { $$ = 509; }; n510: token { $$ = 510; }; n511: token { $$ = 511; }; n512: token { $$ = 512; }; n513: token { $$ = 513; }; n514: token { $$ = 514; }; n515: token { $$ = 515; }; n516: token { $$ = 516; }; n517: token { $$ = 517; }; n518: token { $$ = 518; }; n519: token { $$ = 519; }; n520: token { $$ = 520; }; n521: token { $$ = 521; }; n522: token { $$ = 522; }; n523: token { $$ = 523; }; n524: token { $$ = 524; }; n525: token { $$ = 525; }; n526: token { $$ = 526; }; n527: token { $$ = 527; }; n528: token { $$ = 528; }; n529: token { $$ = 529; }; n530: token { $$ = 530; }; n531: token { $$ = 531; }; n532: token { $$ = 532; }; n533: token { $$ = 533; }; n534: token { $$ = 534; }; n535: token { $$ = 535; }; n536: token { $$ = 536; }; n537: token { $$ = 537; }; n538: token { $$ = 538; }; n539: token { $$ = 539; }; n540: token { $$ = 540; }; n541: token { $$ = 541; }; n542: token { $$ = 542; }; n543: token { $$ = 543; }; n544: token { $$ = 544; }; n545: token { $$ = 545; }; n546: token { $$ = 546; }; n547: token { $$ = 547; }; n548: token { $$ = 548; }; n549: token { $$ = 549; }; n550: token { $$ = 550; }; n551: token { $$ = 551; }; n552: token { $$ = 552; }; n553: token { $$ = 553; }; n554: token { $$ = 554; }; n555: token { $$ = 555; }; n556: token { $$ = 556; }; n557: token { $$ = 557; }; n558: token { $$ = 558; }; n559: token { $$ = 559; }; n560: token { $$ = 560; }; n561: token { $$ = 561; }; n562: token { $$ = 562; }; n563: token { $$ = 563; }; n564: token { $$ = 564; }; n565: token { $$ = 565; }; n566: token { $$ = 566; }; n567: token { $$ = 567; }; n568: token { $$ = 568; }; n569: token { $$ = 569; }; n570: token { $$ = 570; }; n571: token { $$ = 571; }; n572: token { $$ = 572; }; n573: token { $$ = 573; }; n574: token { $$ = 574; }; n575: token { $$ = 575; }; n576: token { $$ = 576; }; n577: token { $$ = 577; }; n578: token { $$ = 578; }; n579: token { $$ = 579; }; n580: token { $$ = 580; }; n581: token { $$ = 581; }; n582: token { $$ = 582; }; n583: token { $$ = 583; }; n584: token { $$ = 584; }; n585: token { $$ = 585; }; n586: token { $$ = 586; }; n587: token { $$ = 587; }; n588: token { $$ = 588; }; n589: token { $$ = 589; }; n590: token { $$ = 590; }; n591: token { $$ = 591; }; n592: token { $$ = 592; }; n593: token { $$ = 593; }; n594: token { $$ = 594; }; n595: token { $$ = 595; }; n596: token { $$ = 596; }; n597: token { $$ = 597; }; n598: token { $$ = 598; }; n599: token { $$ = 599; }; n600: token { $$ = 600; }; n601: token { $$ = 601; }; n602: token { $$ = 602; }; n603: token { $$ = 603; }; n604: token { $$ = 604; }; n605: token { $$ = 605; }; n606: token { $$ = 606; }; n607: token { $$ = 607; }; n608: token { $$ = 608; }; n609: token { $$ = 609; }; n610: token { $$ = 610; }; n611: token { $$ = 611; }; n612: token { $$ = 612; }; n613: token { $$ = 613; }; n614: token { $$ = 614; }; n615: token { $$ = 615; }; n616: token { $$ = 616; }; n617: token { $$ = 617; }; n618: token { $$ = 618; }; n619: token { $$ = 619; }; n620: token { $$ = 620; }; n621: token { $$ = 621; }; n622: token { $$ = 622; }; n623: token { $$ = 623; }; n624: token { $$ = 624; }; n625: token { $$ = 625; }; n626: token { $$ = 626; }; n627: token { $$ = 627; }; n628: token { $$ = 628; }; n629: token { $$ = 629; }; n630: token { $$ = 630; }; n631: token { $$ = 631; }; n632: token { $$ = 632; }; n633: token { $$ = 633; }; n634: token { $$ = 634; }; n635: token { $$ = 635; }; n636: token { $$ = 636; }; n637: token { $$ = 637; }; n638: token { $$ = 638; }; n639: token { $$ = 639; }; n640: token { $$ = 640; }; n641: token { $$ = 641; }; n642: token { $$ = 642; }; n643: token { $$ = 643; }; n644: token { $$ = 644; }; n645: token { $$ = 645; }; n646: token { $$ = 646; }; n647: token { $$ = 647; }; n648: token { $$ = 648; }; n649: token { $$ = 649; }; n650: token { $$ = 650; }; n651: token { $$ = 651; }; n652: token { $$ = 652; }; n653: token { $$ = 653; }; n654: token { $$ = 654; }; n655: token { $$ = 655; }; n656: token { $$ = 656; }; n657: token { $$ = 657; }; n658: token { $$ = 658; }; n659: token { $$ = 659; }; n660: token { $$ = 660; }; n661: token { $$ = 661; }; n662: token { $$ = 662; }; n663: token { $$ = 663; }; n664: token { $$ = 664; }; n665: token { $$ = 665; }; n666: token { $$ = 666; }; n667: token { $$ = 667; }; n668: token { $$ = 668; }; n669: token { $$ = 669; }; n670: token { $$ = 670; }; n671: token { $$ = 671; }; n672: token { $$ = 672; }; n673: token { $$ = 673; }; n674: token { $$ = 674; }; n675: token { $$ = 675; }; n676: token { $$ = 676; }; n677: token { $$ = 677; }; n678: token { $$ = 678; }; n679: token { $$ = 679; }; n680: token { $$ = 680; }; n681: token { $$ = 681; }; n682: token { $$ = 682; }; n683: token { $$ = 683; }; n684: token { $$ = 684; }; n685: token { $$ = 685; }; n686: token { $$ = 686; }; n687: token { $$ = 687; }; n688: token { $$ = 688; }; n689: token { $$ = 689; }; n690: token { $$ = 690; }; n691: token { $$ = 691; }; n692: token { $$ = 692; }; n693: token { $$ = 693; }; n694: token { $$ = 694; }; n695: token { $$ = 695; }; n696: token { $$ = 696; }; n697: token { $$ = 697; }; n698: token { $$ = 698; }; n699: token { $$ = 699; }; n700: token { $$ = 700; }; n701: token { $$ = 701; }; n702: token { $$ = 702; }; n703: token { $$ = 703; }; n704: token { $$ = 704; }; n705: token { $$ = 705; }; n706: token { $$ = 706; }; n707: token { $$ = 707; }; n708: token { $$ = 708; }; n709: token { $$ = 709; }; n710: token { $$ = 710; }; n711: token { $$ = 711; }; n712: token { $$ = 712; }; n713: token { $$ = 713; }; n714: token { $$ = 714; }; n715: token { $$ = 715; }; n716: token { $$ = 716; }; n717: token { $$ = 717; }; n718: token { $$ = 718; }; n719: token { $$ = 719; }; n720: token { $$ = 720; }; n721: token { $$ = 721; }; n722: token { $$ = 722; }; n723: token { $$ = 723; }; n724: token { $$ = 724; }; n725: token { $$ = 725; }; n726: token { $$ = 726; }; n727: token { $$ = 727; }; n728: token { $$ = 728; }; n729: token { $$ = 729; }; n730: token { $$ = 730; }; n731: token { $$ = 731; }; n732: token { $$ = 732; }; n733: token { $$ = 733; }; n734: token { $$ = 734; }; n735: token { $$ = 735; }; n736: token { $$ = 736; }; n737: token { $$ = 737; }; n738: token { $$ = 738; }; n739: token { $$ = 739; }; n740: token { $$ = 740; }; n741: token { $$ = 741; }; n742: token { $$ = 742; }; n743: token { $$ = 743; }; n744: token { $$ = 744; }; n745: token { $$ = 745; }; n746: token { $$ = 746; }; n747: token { $$ = 747; }; n748: token { $$ = 748; }; n749: token { $$ = 749; }; n750: token { $$ = 750; }; n751: token { $$ = 751; }; n752: token { $$ = 752; }; n753: token { $$ = 753; }; n754: token { $$ = 754; }; n755: token { $$ = 755; }; n756: token { $$ = 756; }; n757: token { $$ = 757; }; n758: token { $$ = 758; }; n759: token { $$ = 759; }; n760: token { $$ = 760; }; n761: token { $$ = 761; }; n762: token { $$ = 762; }; n763: token { $$ = 763; }; n764: token { $$ = 764; }; n765: token { $$ = 765; }; n766: token { $$ = 766; }; n767: token { $$ = 767; }; n768: token { $$ = 768; }; n769: token { $$ = 769; }; n770: token { $$ = 770; }; n771: token { $$ = 771; }; n772: token { $$ = 772; }; n773: token { $$ = 773; }; n774: token { $$ = 774; }; n775: token { $$ = 775; }; n776: token { $$ = 776; }; n777: token { $$ = 777; }; n778: token { $$ = 778; }; n779: token { $$ = 779; }; n780: token { $$ = 780; }; n781: token { $$ = 781; }; n782: token { $$ = 782; }; n783: token { $$ = 783; }; n784: token { $$ = 784; }; n785: token { $$ = 785; }; n786: token { $$ = 786; }; n787: token { $$ = 787; }; n788: token { $$ = 788; }; n789: token { $$ = 789; }; n790: token { $$ = 790; }; n791: token { $$ = 791; }; n792: token { $$ = 792; }; n793: token { $$ = 793; }; n794: token { $$ = 794; }; n795: token { $$ = 795; }; n796: token { $$ = 796; }; n797: token { $$ = 797; }; n798: token { $$ = 798; }; n799: token { $$ = 799; }; n800: token { $$ = 800; }; n801: token { $$ = 801; }; n802: token { $$ = 802; }; n803: token { $$ = 803; }; n804: token { $$ = 804; }; n805: token { $$ = 805; }; n806: token { $$ = 806; }; n807: token { $$ = 807; }; n808: token { $$ = 808; }; n809: token { $$ = 809; }; n810: token { $$ = 810; }; n811: token { $$ = 811; }; n812: token { $$ = 812; }; n813: token { $$ = 813; }; n814: token { $$ = 814; }; n815: token { $$ = 815; }; n816: token { $$ = 816; }; n817: token { $$ = 817; }; n818: token { $$ = 818; }; n819: token { $$ = 819; }; n820: token { $$ = 820; }; n821: token { $$ = 821; }; n822: token { $$ = 822; }; n823: token { $$ = 823; }; n824: token { $$ = 824; }; n825: token { $$ = 825; }; n826: token { $$ = 826; }; n827: token { $$ = 827; }; n828: token { $$ = 828; }; n829: token { $$ = 829; }; n830: token { $$ = 830; }; n831: token { $$ = 831; }; n832: token { $$ = 832; }; n833: token { $$ = 833; }; n834: token { $$ = 834; }; n835: token { $$ = 835; }; n836: token { $$ = 836; }; n837: token { $$ = 837; }; n838: token { $$ = 838; }; n839: token { $$ = 839; }; n840: token { $$ = 840; }; n841: token { $$ = 841; }; n842: token { $$ = 842; }; n843: token { $$ = 843; }; n844: token { $$ = 844; }; n845: token { $$ = 845; }; n846: token { $$ = 846; }; n847: token { $$ = 847; }; n848: token { $$ = 848; }; n849: token { $$ = 849; }; n850: token { $$ = 850; }; n851: token { $$ = 851; }; n852: token { $$ = 852; }; n853: token { $$ = 853; }; n854: token { $$ = 854; }; n855: token { $$ = 855; }; n856: token { $$ = 856; }; n857: token { $$ = 857; }; n858: token { $$ = 858; }; n859: token { $$ = 859; }; n860: token { $$ = 860; }; n861: token { $$ = 861; }; n862: token { $$ = 862; }; n863: token { $$ = 863; }; n864: token { $$ = 864; }; n865: token { $$ = 865; }; n866: token { $$ = 866; }; n867: token { $$ = 867; }; n868: token { $$ = 868; }; n869: token { $$ = 869; }; n870: token { $$ = 870; }; n871: token { $$ = 871; }; n872: token { $$ = 872; }; n873: token { $$ = 873; }; n874: token { $$ = 874; }; n875: token { $$ = 875; }; n876: token { $$ = 876; }; n877: token { $$ = 877; }; n878: token { $$ = 878; }; n879: token { $$ = 879; }; n880: token { $$ = 880; }; n881: token { $$ = 881; }; n882: token { $$ = 882; }; n883: token { $$ = 883; }; n884: token { $$ = 884; }; n885: token { $$ = 885; }; n886: token { $$ = 886; }; n887: token { $$ = 887; }; n888: token { $$ = 888; }; n889: token { $$ = 889; }; n890: token { $$ = 890; }; n891: token { $$ = 891; }; n892: token { $$ = 892; }; n893: token { $$ = 893; }; n894: token { $$ = 894; }; n895: token { $$ = 895; }; n896: token { $$ = 896; }; n897: token { $$ = 897; }; n898: token { $$ = 898; }; n899: token { $$ = 899; }; n900: token { $$ = 900; }; n901: token { $$ = 901; }; n902: token { $$ = 902; }; n903: token { $$ = 903; }; n904: token { $$ = 904; }; n905: token { $$ = 905; }; n906: token { $$ = 906; }; n907: token { $$ = 907; }; n908: token { $$ = 908; }; n909: token { $$ = 909; }; n910: token { $$ = 910; }; n911: token { $$ = 911; }; n912: token { $$ = 912; }; n913: token { $$ = 913; }; n914: token { $$ = 914; }; n915: token { $$ = 915; }; n916: token { $$ = 916; }; n917: token { $$ = 917; }; n918: token { $$ = 918; }; n919: token { $$ = 919; }; n920: token { $$ = 920; }; n921: token { $$ = 921; }; n922: token { $$ = 922; }; n923: token { $$ = 923; }; n924: token { $$ = 924; }; n925: token { $$ = 925; }; n926: token { $$ = 926; }; n927: token { $$ = 927; }; n928: token { $$ = 928; }; n929: token { $$ = 929; }; n930: token { $$ = 930; }; n931: token { $$ = 931; }; n932: token { $$ = 932; }; n933: token { $$ = 933; }; n934: token { $$ = 934; }; n935: token { $$ = 935; }; n936: token { $$ = 936; }; n937: token { $$ = 937; }; n938: token { $$ = 938; }; n939: token { $$ = 939; }; n940: token { $$ = 940; }; n941: token { $$ = 941; }; n942: token { $$ = 942; }; n943: token { $$ = 943; }; n944: token { $$ = 944; }; n945: token { $$ = 945; }; n946: token { $$ = 946; }; n947: token { $$ = 947; }; n948: token { $$ = 948; }; n949: token { $$ = 949; }; n950: token { $$ = 950; }; n951: token { $$ = 951; }; n952: token { $$ = 952; }; n953: token { $$ = 953; }; n954: token { $$ = 954; }; n955: token { $$ = 955; }; n956: token { $$ = 956; }; n957: token { $$ = 957; }; n958: token { $$ = 958; }; n959: token { $$ = 959; }; n960: token { $$ = 960; }; n961: token { $$ = 961; }; n962: token { $$ = 962; }; n963: token { $$ = 963; }; n964: token { $$ = 964; }; n965: token { $$ = 965; }; n966: token { $$ = 966; }; n967: token { $$ = 967; }; n968: token { $$ = 968; }; n969: token { $$ = 969; }; n970: token { $$ = 970; }; n971: token { $$ = 971; }; n972: token { $$ = 972; }; n973: token { $$ = 973; }; n974: token { $$ = 974; }; n975: token { $$ = 975; }; n976: token { $$ = 976; }; n977: token { $$ = 977; }; n978: token { $$ = 978; }; n979: token { $$ = 979; }; n980: token { $$ = 980; }; n981: token { $$ = 981; }; n982: token { $$ = 982; }; n983: token { $$ = 983; }; n984: token { $$ = 984; }; n985: token { $$ = 985; }; n986: token { $$ = 986; }; n987: token { $$ = 987; }; n988: token { $$ = 988; }; n989: token { $$ = 989; }; n990: token { $$ = 990; }; n991: token { $$ = 991; }; n992: token { $$ = 992; }; n993: token { $$ = 993; }; n994: token { $$ = 994; }; n995: token { $$ = 995; }; n996: token { $$ = 996; }; n997: token { $$ = 997; }; n998: token { $$ = 998; }; n999: token { $$ = 999; }; n1000: token { $$ = 1000; }; %% /* A C error reporting function. */ /* !POSIX */ static void yyerror (const char *msg) { fprintf (stderr, "%s\n", msg); } static int yylex (void) { static int return_token = 1; static int counter = 1; if (counter > MAX) { assert (counter++ == MAX + 1); return 0; } if (return_token) { return_token = 0; return token; } return_token = 1; return counter++; } #include /* getenv. */ #include /* strcmp. */ int main (int argc, char const* argv[]) { (void) argc; (void) argv; return yyparse (); } stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 614. torture.at:485: testing Exploding the Stack Size with Alloca ... ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./torture.at:494: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./calc.at:1492: cat stderr 615. torture.at:531: testing Exploding the Stack Size with Malloc ... ./torture.at:535: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y input: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1492: $PREPARSER ./calc input ./torture.at:494: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./torture.at:393: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y ./calc.at:1494: cat stderr stderr: input: | (1 + 1) / (1 - 1) ./calc.at:1492: $PREPARSER ./calc input stderr: ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 617. existing.at:74: testing GNU AWK 3.1.0 Grammar: IELR(1) ... ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y input: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 616. existing.at:74: testing GNU AWK 3.1.0 Grammar: LALR(1) ... ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./torture.at:535: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS | (- *) + (1 2) = 1 ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (- *) + (1 2) = 1 ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: cat stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: cat stderr stderr: 567. calc.at:1492: ok input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | error ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: $PREPARSER ./calc input ./calc.at:1494: cat stderr stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror Starting parse Entering state 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) input: input: | (* *) + (*) + (*) ./calc.at:1491: $PREPARSER ./calc input | (* *) + (*) + (*) stderr: ./calc.at:1494: $PREPARSER ./calc input ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./torture.at:497: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 20 stderr: ./calc.at:1492: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./torture.at:538: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 20 stderr: ./torture.at:497: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./torture.at:538: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: 618. existing.at:74: testing GNU AWK 3.1.0 Grammar: Canonical LR(1) ... ./torture.at:541: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 900 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 = 2 = 3 ./calc.at:1492: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: ./torture.at:541: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./torture.at:500: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 900 ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y input.y:66.10: error: empty rule without %empty [-Werror=empty-rule] input.y:170.10: error: empty rule without %empty [-Werror=empty-rule] input.y:175.10: error: empty rule without %empty [-Werror=empty-rule] input.y:180.10: error: empty rule without %empty [-Werror=empty-rule] input.y:188.10: error: empty rule without %empty [-Werror=empty-rule] input.y:202.10: error: empty rule without %empty [-Werror=empty-rule] input.y:207.10: error: empty rule without %empty [-Werror=empty-rule] input.y:221.10: error: empty rule without %empty [-Werror=empty-rule] input.y:300.10: error: empty rule without %empty [-Werror=empty-rule] input.y:323.10: error: empty rule without %empty [-Werror=empty-rule] input.y: error: 65 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:39.1-5: error: useless associativity for FUNC_CALL, use %precedence [-Werror=precedence] input.y:44.1-5: error: useless associativity for YNUMBER, use %precedence [-Werror=precedence] input.y:44.1-5: error: useless associativity for YSTRING, use %precedence [-Werror=precedence] input.y:42.1-9: error: useless precedence and associativity for APPEND_OP [-Werror=precedence] input.y:33.1-6: error: useless associativity for ASSIGNOP, use %precedence [-Werror=precedence] input.y:43.1-5: error: useless associativity for CONCAT_OP, use %precedence [-Werror=precedence] input.y:37.1-5: error: useless precedence and associativity for LEX_GETLINE [-Werror=precedence] input.y:38.1-9: error: useless associativity for LEX_IN, use %precedence [-Werror=precedence] input.y:49.1-5: error: useless associativity for INCREMENT, use %precedence [-Werror=precedence] input.y:49.1-5: error: useless associativity for DECREMENT, use %precedence [-Werror=precedence] input.y:39.1-5: error: useless associativity for LEX_BUILTIN, use %precedence [-Werror=precedence] input.y:39.1-5: error: useless associativity for LEX_LENGTH, use %precedence [-Werror=precedence] input.y:40.1-9: error: useless precedence and associativity for ',' [-Werror=precedence] input.y:47.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] input.y:47.1-6: error: useless associativity for UNARY, use %precedence [-Werror=precedence] input.y:50.1-5: error: useless associativity for '$', use %precedence [-Werror=precedence] input.y:51.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] input.y:51.1-5: error: useless precedence and associativity for ')' [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) stderr: ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./torture.at:500: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./torture.at:545: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 10000 ./calc.at:1491: cat stderr stderr: stderr: ./existing.at:74: sed 's,.*/$,,' stderr 1>&2 ./calc.at:1494: cat stderr stderr: memory exhausted memory exhausted ./torture.at:545: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./torture.at:504: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 10000 stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) input.y:66.10: error: empty rule without %empty [-Werror=empty-rule] input.y:170.10: error: empty rule without %empty [-Werror=empty-rule] input.y:175.10: error: empty rule without %empty [-Werror=empty-rule] input.y:180.10: error: empty rule without %empty [-Werror=empty-rule] input.y:188.10: error: empty rule without %empty [-Werror=empty-rule] input.y:202.10: error: empty rule without %empty [-Werror=empty-rule] input.y:207.10: error: empty rule without %empty [-Werror=empty-rule] input.y:221.10: error: empty rule without %empty [-Werror=empty-rule] input.y:300.10: error: empty rule without %empty [-Werror=empty-rule] input.y:323.10: error: empty rule without %empty [-Werror=empty-rule] input.y: error: 65 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:39.1-5: error: useless associativity for FUNC_CALL, use %precedence [-Werror=precedence] input.y:44.1-5: error: useless associativity for YNUMBER, use %precedence [-Werror=precedence] input.y:44.1-5: error: useless associativity for YSTRING, use %precedence [-Werror=precedence] input.y:42.1-9: error: useless precedence and associativity for APPEND_OP [-Werror=precedence] input.y:33.1-6: error: useless associativity for ASSIGNOP, use %precedence [-Werror=precedence] input.y:43.1-5: error: useless associativity for CONCAT_OP, use %precedence [-Werror=precedence] input.y:37.1-5: error: useless precedence and associativity for LEX_GETLINE [-Werror=precedence] input.y:38.1-9: error: useless associativity for LEX_IN, use %precedence [-Werror=precedence] input.y:49.1-5: error: useless associativity for INCREMENT, use %precedence [-Werror=precedence] input.y:49.1-5: error: useless associativity for DECREMENT, use %precedence [-Werror=precedence] input.y:39.1-5: error: useless associativity for LEX_BUILTIN, use %precedence [-Werror=precedence] input.y:39.1-5: error: useless associativity for LEX_LENGTH, use %precedence [-Werror=precedence] input.y:40.1-9: error: useless precedence and associativity for ',' [-Werror=precedence] input.y:47.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] input.y:47.1-6: error: useless associativity for UNARY, use %precedence [-Werror=precedence] input.y:50.1-5: error: useless associativity for '$', use %precedence [-Werror=precedence] input.y:51.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] input.y:51.1-5: error: useless precedence and associativity for ')' [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] stderr: ./existing.at:74: sed 's,.*/$,,' stderr 1>&2 input: memory exhausted memory exhausted ./torture.at:504: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !+ ++ ./calc.at:1491: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error stderr: ./calc.at:1494: $PREPARSER ./calc input ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error memory exhausted memory exhausted stderr: stderr: stderr: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 memory exhausted memory exhausted Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./torture.at:548: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./torture.at:510: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./calc.at:1492: cat stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: input: input: | 1 + 2 * 3 + !- ++ ./calc.at:1494: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ | | +1 ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1492: $PREPARSER ./calc input stderr: ./torture.at:548: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./torture.at:510: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: cat stderr ./calc.at:1491: cat stderr ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (#) + (#) = 2222 ./calc.at:1494: $PREPARSER ./calc input ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: cat stderr input: ./torture.at:237: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1492: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (#) + (#) = 2222 ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) stderr: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: cat stderr ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./torture.at:140: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./calc.at:1492: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: cat stderr input: ./calc.at:1494: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1492: $PREPARSER ./calc input input: input: stderr: | (# + 1) = 1111 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (1 + #) = 1111 ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1494: $PREPARSER ./calc input stderr: stderr: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./existing.at:74: sed -n 's/^State //p' input.output | tail -1 ./existing.at:74: sed 's/^%define lr.type .*$//' input.y > input-lalr.y ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: cat stderr stderr: ./calc.at:1491: cat stderr input: | (!!) + (1 2) = 1 ./calc.at:1492: $PREPARSER ./calc input ./calc.at:1494: cat stderr ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror stdout: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./torture.at:513: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 20 input-lalr.y: warning: 65 shift/reduce conflicts [-Wconflicts-sr] input-lalr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stdout: ./existing.at:74: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: | (1 + # + 1) = 1111 stdout: input: ./calc.at:1494: $PREPARSER ./calc input ./torture.at:551: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 20 ./torture.at:513: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./torture.at:551: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 ./calc.at:1491: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./existing.at:74: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./torture.at:553: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 900 ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./torture.at:515: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 900 stderr: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./existing.at:74: sed -n 's/^State //p' input.output | tail -1 ./torture.at:553: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./torture.at:515: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:74: sed 's/^%define lr.type .*$//' input.y > input-lalr.y ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./torture.at:555: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 10000 ./calc.at:1491: cat stderr stderr: ./torture.at:517: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 10000 stderr: memory exhausted memory exhausted input: ./torture.at:555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: memory exhausted memory exhausted stdout: input: ./calc.at:1492: $PREPARSER ./calc input ./torture.at:517: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./torture.at:238: $PREPARSER ./input ./calc.at:1494: cat stderr | (1 + # + 1) = 1111 ./calc.at:1491: $PREPARSER ./calc input stderr: stderr: stderr: memory exhausted memory exhausted stderr: 615. torture.at:531: ok Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./torture.at:238: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: memory exhausted memory exhausted 605. torture.at:216: ok Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: 614. torture.at:485: ok | (1 + 1) / (1 - 1) ./calc.at:1494: $PREPARSER ./calc input ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input-lalr.y: warning: 65 shift/reduce conflicts [-Wconflicts-sr] input-lalr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stderr: stdout: ./existing.at:74: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:74: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stdout: ./calc.at:1494: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: cat stderr input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1494: $PREPARSER ./calc input ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: cat stderr 619. existing.at:808: testing GNU Cim Grammar: LALR(1) ... stderr: ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (14.1: ) Entering state 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 620. existing.at:808: testing GNU Cim Grammar: IELR(1) ... ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (14.1: ) Entering state 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) input: input: ./calc.at:1494: cat stderr input: stderr: | (* *) + (*) + (*) ./calc.at:1492: $PREPARSER ./calc input | (1 + 1) / (1 - 1) ./calc.at:1491: $PREPARSER ./calc input | 1 2 ./calc.at:1494: $PREPARSER ./calc input 621. existing.at:808: testing GNU Cim Grammar: Canonical LR(1) ... ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stdout: stderr: ./torture.at:141: $PREPARSER ./input stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token number (1.3: 2) stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./torture.at:141: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 569. calc.at:1494: ok ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 604. torture.at:132: ok ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token number (1.3: 2) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: cat stderr ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: cat stderr 622. existing.at:1460: testing GNU pic (Groff 1.18.1) Grammar: LALR(1) ... ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stderr: ./calc.at:1492: cat stderr 566. calc.at:1491: ok stdout: input: | 1//2 ./existing.at:74: $PREPARSER ./input ./calc.at:1494: $PREPARSER ./calc input stderr: input: ./existing.at:74: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) | 1 + 2 * 3 + !+ ++ ./calc.at:1492: $PREPARSER ./calc input ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror stderr: stdout: ./existing.at:74: $PREPARSER ./input 617. existing.at:74: ok stderr: syntax error, unexpected '*', expecting NEWLINE or '{' or ';' ./existing.at:74: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 623. existing.at:1460: testing GNU pic (Groff 1.18.1) Grammar: IELR(1) ... Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) 616. existing.at:74: ok ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stderr: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input.y:66.10: error: empty rule without %empty [-Werror=empty-rule] input.y:170.10: error: empty rule without %empty [-Werror=empty-rule] input.y:175.10: error: empty rule without %empty [-Werror=empty-rule] input.y:180.10: error: empty rule without %empty [-Werror=empty-rule] input.y:188.10: error: empty rule without %empty [-Werror=empty-rule] input.y:202.10: error: empty rule without %empty [-Werror=empty-rule] input.y:207.10: error: empty rule without %empty [-Werror=empty-rule] input.y:221.10: error: empty rule without %empty [-Werror=empty-rule] input.y:300.10: error: empty rule without %empty [-Werror=empty-rule] input.y:323.10: error: empty rule without %empty [-Werror=empty-rule] input.y: error: 265 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:39.1-5: error: useless associativity for FUNC_CALL, use %precedence [-Werror=precedence] input.y:44.1-5: error: useless associativity for YNUMBER, use %precedence [-Werror=precedence] input.y:44.1-5: error: useless associativity for YSTRING, use %precedence [-Werror=precedence] input.y:42.1-9: error: useless precedence and associativity for APPEND_OP [-Werror=precedence] input.y:33.1-6: error: useless associativity for ASSIGNOP, use %precedence [-Werror=precedence] input.y:43.1-5: error: useless associativity for CONCAT_OP, use %precedence [-Werror=precedence] input.y:37.1-5: error: useless precedence and associativity for LEX_GETLINE [-Werror=precedence] input.y:38.1-9: error: useless associativity for LEX_IN, use %precedence [-Werror=precedence] input.y:49.1-5: error: useless associativity for INCREMENT, use %precedence [-Werror=precedence] input.y:49.1-5: error: useless associativity for DECREMENT, use %precedence [-Werror=precedence] input.y:39.1-5: error: useless associativity for LEX_BUILTIN, use %precedence [-Werror=precedence] input.y:39.1-5: error: useless associativity for LEX_LENGTH, use %precedence [-Werror=precedence] input.y:40.1-9: error: useless precedence and associativity for ',' [-Werror=precedence] input.y:47.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] input.y:47.1-6: error: useless associativity for UNARY, use %precedence [-Werror=precedence] input.y:50.1-5: error: useless associativity for '$', use %precedence [-Werror=precedence] input.y:51.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] input.y:51.1-5: error: useless precedence and associativity for ')' [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] stderr: ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) 624. existing.at:1460: testing GNU pic (Groff 1.18.1) Grammar: Canonical LR(1) ... ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./calc.at:1494: cat stderr input: | 1 + 2 * 3 + !- ++ ./existing.at:74: sed 's,.*/$,,' stderr 1>&2 ./calc.at:1492: $PREPARSER ./calc input input: stderr: | error ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 625. regression.at:25: testing Trivial grammars ... ./regression.at:43: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error Starting parse Entering state 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./regression.at:44: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c 626. regression.at:55: testing YYSTYPE typedef ... ./regression.at:73: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./calc.at:1494: cat stderr ./calc.at:1492: cat stderr stderr: input.y:128.18: error: empty rule without %empty [-Werror=empty-rule] input.y:137.18: error: empty rule without %empty [-Werror=empty-rule] input.y:142.18: error: empty rule without %empty [-Werror=empty-rule] input.y:161.18: error: empty rule without %empty [-Werror=empty-rule] input.y:179.18: error: empty rule without %empty [-Werror=empty-rule] input.y:205.18: error: empty rule without %empty [-Werror=empty-rule] input.y:213.18: error: empty rule without %empty [-Werror=empty-rule] input.y:225.18: error: empty rule without %empty [-Werror=empty-rule] input.y:292.18: error: empty rule without %empty [-Werror=empty-rule] input.y:294.20: error: empty rule without %empty [-Werror=empty-rule] input.y:367.18: error: empty rule without %empty [-Werror=empty-rule] input.y:373.18: error: empty rule without %empty [-Werror=empty-rule] input.y:387.18: error: empty rule without %empty [-Werror=empty-rule] input.y:401.18: error: empty rule without %empty [-Werror=empty-rule] input.y:413.18: error: empty rule without %empty [-Werror=empty-rule] input.y:443.18: error: empty rule without %empty [-Werror=empty-rule] input.y:471.18: error: empty rule without %empty [-Werror=empty-rule] input.y:474.18: error: empty rule without %empty [-Werror=empty-rule] input.y:489.18: error: empty rule without %empty [-Werror=empty-rule] input.y:506.18: error: empty rule without %empty [-Werror=empty-rule] input.y:587.18: error: empty rule without %empty [-Werror=empty-rule] input.y:591.18: error: empty rule without %empty [-Werror=empty-rule] input.y: error: 78 shift/reduce conflicts [-Werror=conflicts-sr] input.y: error: 10 reduce/reduce conflicts [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:72.1-5: error: useless associativity for HQUA, use %precedence [-Werror=precedence] input.y:53.1-6: error: useless associativity for HASSIGN, use %precedence [-Werror=precedence] input.y:54.1-5: error: useless associativity for HORELSE, use %precedence [-Werror=precedence] input.y:55.1-5: error: useless associativity for HANDTHEN, use %precedence [-Werror=precedence] input.y:61.1-5: error: useless associativity for HNOT, use %precedence [-Werror=precedence] input.y:68.1-5: error: useless associativity for UNEAR, use %precedence [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] input: ./existing.at:808: sed 's,.*/$,,' stderr 1>&2 input: ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error | 1 = 2 = 3 | (#) + (#) = 2222 ./calc.at:1494: $PREPARSER ./calc input ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror ./calc.at:1492: $PREPARSER ./calc input ./regression.at:74: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: cat stderr ./calc.at:1494: cat stderr stderr: input.y:128.18: error: empty rule without %empty [-Werror=empty-rule] input.y:137.18: error: empty rule without %empty [-Werror=empty-rule] input.y:142.18: error: empty rule without %empty [-Werror=empty-rule] input.y:161.18: error: empty rule without %empty [-Werror=empty-rule] input.y:179.18: error: empty rule without %empty [-Werror=empty-rule] input.y:205.18: error: empty rule without %empty [-Werror=empty-rule] input.y:213.18: error: empty rule without %empty [-Werror=empty-rule] input.y:225.18: error: empty rule without %empty [-Werror=empty-rule] input.y:292.18: error: empty rule without %empty [-Werror=empty-rule] input.y:294.20: error: empty rule without %empty [-Werror=empty-rule] input.y:367.18: error: empty rule without %empty [-Werror=empty-rule] input.y:373.18: error: empty rule without %empty [-Werror=empty-rule] input.y:387.18: error: empty rule without %empty [-Werror=empty-rule] input.y:401.18: error: empty rule without %empty [-Werror=empty-rule] input.y:413.18: error: empty rule without %empty [-Werror=empty-rule] input.y:443.18: error: empty rule without %empty [-Werror=empty-rule] input.y:471.18: error: empty rule without %empty [-Werror=empty-rule] input.y:474.18: error: empty rule without %empty [-Werror=empty-rule] input.y:489.18: error: empty rule without %empty [-Werror=empty-rule] input.y:506.18: error: empty rule without %empty [-Werror=empty-rule] input.y:587.18: error: empty rule without %empty [-Werror=empty-rule] input.y:591.18: error: empty rule without %empty [-Werror=empty-rule] input.y: error: 78 shift/reduce conflicts [-Werror=conflicts-sr] input.y: error: 10 reduce/reduce conflicts [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:72.1-5: error: useless associativity for HQUA, use %precedence [-Werror=precedence] input.y:53.1-6: error: useless associativity for HASSIGN, use %precedence [-Werror=precedence] input.y:54.1-5: error: useless associativity for HORELSE, use %precedence [-Werror=precedence] input.y:55.1-5: error: useless associativity for HANDTHEN, use %precedence [-Werror=precedence] input.y:61.1-5: error: useless associativity for HNOT, use %precedence [-Werror=precedence] input.y:68.1-5: error: useless associativity for UNEAR, use %precedence [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] stderr: stdout: 626. regression.at:55: ok ./existing.at:808: sed 's,.*/$,,' stderr 1>&2 input: input: stderr: | (1 + #) = 1111 | | +1 ./calc.at:1494: $PREPARSER ./calc input ./calc.at:1492: $PREPARSER ./calc input ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) stdout: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:45: $CC $CFLAGS $CPPFLAGS -c -o input.o -DYYDEBUG -c input.c stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: cat stderr stderr: input.y:202.20: error: empty rule without %empty [-Werror=empty-rule] input.y:270.7: error: empty rule without %empty [-Werror=empty-rule] input.y:292.13: error: empty rule without %empty [-Werror=empty-rule] input.y:309.18: error: empty rule without %empty [-Werror=empty-rule] input.y:382.14: error: empty rule without %empty [-Werror=empty-rule] input.y:471.11-48: error: rule useless in parser due to conflicts [-Werror=other] input.y:154.1-5: error: useless associativity for LABEL, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for VARIABLE, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for NUMBER, use %precedence [-Werror=precedence] input.y:141.1-5: error: useless associativity for TEXT, use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for ORDINAL, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for LAST, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for UP, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for DOWN, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for BOX, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for CIRCLE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ELLIPSE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ARC, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for LINE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ARROW, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for SPLINE, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for HEIGHT, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for RADIUS, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for WIDTH, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for DIAMETER, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for FROM, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for TO, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for AT, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for SOLID [-Werror=precedence] input.y:153.1-5: error: useless associativity for DOTTED, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for DASHED, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for CHOP, use %precedence [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for LJUST [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for RJUST [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for ABOVE [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for BELOW [-Werror=precedence] input.y:176.1-5: error: useless associativity for OF, use %precedence [-Werror=precedence] input.y:176.1-5: error: useless associativity for BETWEEN, use %precedence [-Werror=precedence] input.y:177.1-5: error: useless associativity for AND, use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for HERE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_N, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_E, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_W, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_S, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_NE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_SE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_NW, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_SW, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_C, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for DOT_START, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for DOT_END, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SIN, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for COS, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for ATAN2, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for LOG, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for EXP, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SQRT, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for K_MAX, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for K_MIN, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for INT, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for RAND, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SRAND, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for TOP, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for BOTTOM, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for UPPER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for LOWER, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for LEFT_CORNER, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for RIGHT_CORNER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for NORTH, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for SOUTH, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for EAST, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for WEST, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for CENTER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for END, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for START, use %precedence [-Werror=precedence] input.y:140.1-5: error: useless associativity for PLOT, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for THICKNESS, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for FILL, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for COLORED [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for OUTLINED [-Werror=precedence] input.y:141.1-5: error: useless associativity for SPRINTF, use %precedence [-Werror=precedence] input.y:137.1-5: error: useless associativity for '.', use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for '`', use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for '[', use %precedence [-Werror=precedence] input.y:170.1-5: error: useless associativity for ',', use %precedence [-Werror=precedence] input.y:181.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ./calc.at:1494: $PREPARSER ./calc /dev/null stderr: stderr: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) input.y:202.20: error: empty rule without %empty [-Werror=empty-rule] input.y:270.7: error: empty rule without %empty [-Werror=empty-rule] input.y:292.13: error: empty rule without %empty [-Werror=empty-rule] input.y:309.18: error: empty rule without %empty [-Werror=empty-rule] input.y:382.14: error: empty rule without %empty [-Werror=empty-rule] input.y:471.11-48: error: rule useless in parser due to conflicts [-Werror=other] input.y:154.1-5: error: useless associativity for LABEL, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for VARIABLE, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for NUMBER, use %precedence [-Werror=precedence] input.y:141.1-5: error: useless associativity for TEXT, use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for ORDINAL, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for LAST, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for UP, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for DOWN, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for BOX, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for CIRCLE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ELLIPSE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ARC, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for LINE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ARROW, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for SPLINE, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for HEIGHT, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for RADIUS, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for WIDTH, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for DIAMETER, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for FROM, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for TO, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for AT, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for SOLID [-Werror=precedence] input.y:153.1-5: error: useless associativity for DOTTED, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for DASHED, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for CHOP, use %precedence [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for LJUST [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for RJUST [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for ABOVE [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for BELOW [-Werror=precedence] input.y:176.1-5: error: useless associativity for OF, use %precedence [-Werror=precedence] input.y:176.1-5: error: useless associativity for BETWEEN, use %precedence [-Werror=precedence] input.y:177.1-5: error: useless associativity for AND, use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for HERE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_N, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_E, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_W, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_S, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_NE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_SE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_NW, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_SW, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_C, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for DOT_START, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for DOT_END, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SIN, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for COS, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for ATAN2, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for LOG, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for EXP, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SQRT, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for K_MAX, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for K_MIN, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for INT, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for RAND, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SRAND, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for TOP, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for BOTTOM, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for UPPER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for LOWER, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for LEFT_CORNER, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for RIGHT_CORNER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for NORTH, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for SOUTH, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for EAST, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for WEST, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for CENTER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for END, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for START, use %precedence [-Werror=precedence] input.y:140.1-5: error: useless associativity for PLOT, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for THICKNESS, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for FILL, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for COLORED [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for OUTLINED [-Werror=precedence] input.y:141.1-5: error: useless associativity for SPRINTF, use %precedence [-Werror=precedence] input.y:137.1-5: error: useless associativity for '.', use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for '`', use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for '[', use %precedence [-Werror=precedence] input.y:170.1-5: error: useless associativity for ',', use %precedence [-Werror=precedence] input.y:181.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ./existing.at:1460: sed 's,.*/$,,' stderr 1>&2 ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: cat stderr stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) ./existing.at:1460: sed 's,.*/$,,' stderr 1>&2 627. regression.at:85: testing Early token definitions with --yacc ... ./regression.at:115: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --yacc -o input.c input.y ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error input: | (# + 1) = 1111 ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: $PREPARSER ./calc input stderr: ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./calc.at:1494: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./regression.at:116: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: cat stderr ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./torture.at:394: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./calc.at:1494: cat stderr stdout: input: | (1 + # + 1) = 1111 ./calc.at:1492: $PREPARSER ./calc input 625. regression.at:25: ok ./existing.at:808: sed -n 's/^State //p' input.output | tail -1 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: ./existing.at:808: sed 's/^%define lr.type .*$//' input.y > input-lalr.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 627. regression.at:85: ok ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: cat stderr 628. regression.at:127: testing Early token definitions without --yacc ... ./regression.at:161: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./calc.at:1494: cat stderr input: ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none | (1 + 1) / (1 - 1) input: ./calc.at:1492: $PREPARSER ./calc input stderr: | (- *) + (1 2) = 1 ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: cat stderr ./regression.at:162: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 629. regression.at:173: testing Braces parsing ... stderr: ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./regression.at:185: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: | (* *) + (*) + (*) ./calc.at:1494: $PREPARSER ./calc input input-lalr.y: warning: 78 shift/reduce conflicts [-Wconflicts-sr] input-lalr.y: warning: 10 reduce/reduce conflicts [-Wconflicts-rr] input-lalr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stdout: ./existing.at:808: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./regression.at:187: grep 'tests = {{{{{{{{{{}}}}}}}}}};' input.c stderr: stdout: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) { tests = {{{{{{{{{{}}}}}}}}}}; } 629. regression.at:173: ./calc.at:1492: cat stderr ok ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./existing.at:808: grep '^State.*conflicts:' input.output ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 568. calc.at:1492: ok ./existing.at:808: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./calc.at:1494: cat stderr ./existing.at:808: sed -n 's/^State //p' input.output | tail -1 ./existing.at:808: sed 's/^%define lr.type .*$//' input.y > input-lalr.y ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y stderr: 630. regression.at:196: testing Rule Line Numbers ... input: ./regression.at:232: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -v input.y stdout: | 1 + 2 * 3 + !+ ++ ./calc.at:1494: $PREPARSER ./calc input ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none 628. regression.at:127: ok stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./regression.at:235: cat input.output ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 630. regression.at:196: ok stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none input: 631. regression.at:345: testing Mixing %token styles ... ./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -Wall -o input.c input.y | 1 + 2 * 3 + !- ++ ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -Wall -o input.c input.y -Werror stderr: stdout: stderr: ./existing.at:808: $PREPARSER ./input Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: stderr: ./existing.at:808: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input-lalr.y: warning: 78 shift/reduce conflicts [-Wconflicts-sr] input-lalr.y: warning: 10 reduce/reduce conflicts [-Wconflicts-rr] input-lalr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stdout: ./existing.at:1460: sed -n 's/^State //p' input.output | tail -1 ./existing.at:808: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' 632. regression.at:437: testing Token definitions: parse.error=detailed ... ./existing.at:1460: sed 's/^%define lr.type .*$//' input.y > input-lalr.y ./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o input.c input.y ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y stderr: 619. existing.at:808: ok input.y:3.1-5: error: useless precedence and associativity for "||" [-Werror=precedence] input.y:3.1-5: error: useless precedence and associativity for "<=" [-Werror=precedence] ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./existing.at:808: grep '^State.*conflicts:' input.output ./regression.at:357: sed 's,.*/$,,' stderr 1>&2 633. regression.at:438: testing Token definitions: parse.error=verbose ... ./calc.at:1494: cat stderr ./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o input.c input.y ./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Werror ./existing.at:808: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS input: ./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -Wall -o input.c input.y --warnings=error | (#) + (#) = 2222 ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Werror input.y:26.8-14: error: symbol SPECIAL redeclared [-Werror=other] 26 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" | ^~~~~~~ input.y:25.8-14: note: previous declaration 25 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" | ^~~~~~~ input.y:26.16-63: error: symbol "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" used more than once as a literal string [-Werror=other] 26 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:1460: sed -n 's/^State //p' input.output | tail -1 ./existing.at:1460: sed 's/^%define lr.type .*$//' input.y > input-lalr.y ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y ./regression.at:437: sed 's,.*/$,,' stderr 1>&2 634. regression.at:447: testing Characters Escapes ... stderr: ./regression.at:465: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -Wall -o input.c input.y -Wnone,none -Werror --trace=none stderr: ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: cat stderr ./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=error input.y:26.8-14: error: symbol SPECIAL redeclared [-Werror=other] 26 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" | ^~~~~~~ input.y:25.8-14: note: previous declaration 25 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" | ^~~~~~~ input.y:26.16-63: error: symbol "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" used more than once as a literal string [-Werror=other] 26 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ stderr: input-lalr.y:471.11-48: warning: rule useless in parser due to conflicts [-Wother] stdout: ./existing.at:1460: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' input: | (1 + #) = 1111 ./calc.at:1494: $PREPARSER ./calc input ./regression.at:438: sed 's,.*/$,,' stderr 1>&2 ./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=error ./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -Wall -o input.c input.y --warnings=none -Werror --trace=none ./existing.at:1460: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./regression.at:466: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Wnone,none -Werror --trace=none ./existing.at:808: $PREPARSER ./input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./existing.at:808: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input-lalr.y:471.11-48: warning: rule useless in parser due to conflicts [-Wother] stdout: ./existing.at:1460: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' 631. regression.at:345: ok ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 620. existing.at:808: ok ./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Wnone,none -Werror --trace=none ./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=none -Werror --trace=none ./calc.at:1494: cat stderr stderr: ./existing.at:74: sed -n 's/^State //p' input.output | tail -1 ./existing.at:1460: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: ./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=none -Werror --trace=none input: | (# + 1) = 1111 ./calc.at:1494: $PREPARSER ./calc input 634. regression.at:447: ok stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./regression.at:437: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 635. regression.at:480: testing Web2c Report ... ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:505: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v input.y stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./regression.at:438: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 636. regression.at:661: testing Web2c Actions ... ./regression.at:674: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./existing.at:74: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./regression.at:506: cat input.output stderr: stdout: ./calc.at:1494: cat stderr ./existing.at:1460: $PREPARSER ./input 635. regression.at:480: ok stderr: syntax error, unexpected LEFT ./existing.at:1460: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 622. existing.at:1460: ok 637. regression.at:812: testing Useless Tokens ... ./regression.at:912: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -o input.c input.y input: | (1 + # + 1) = 1111 ./regression.at:679: cat tables.c ./calc.at:1494: $PREPARSER ./calc input stderr: 636. regression.at:661: ok Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./regression.at:917: cat tables.c stderr: stdout: ./regression.at:437: $PREPARSER ./input stderr: 640. regression.at:1145: testing Dancer lalr1.cc ... ./calc.at:1494: cat stderr ./regression.at:1145: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o dancer.cc dancer.y 637. regression.at:812: ok syntax error, unexpected a, expecting ∃¬∩∪∀ ./regression.at:437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 638. regression.at:1143: testing Dancer ... ./regression.at:1143: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o dancer.c dancer.y input: 639. regression.at:1144: testing Dancer %glr-parser ... | (1 + 1) / (1 - 1) ./calc.at:1494: $PREPARSER ./calc input ./regression.at:1144: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o dancer.c dancer.y stderr: 632. regression.at:437: ok Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./regression.at:1145: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o dancer dancer.cc $LIBS ./regression.at:1143: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o dancer dancer.c $LIBS Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./regression.at:1144: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o dancer dancer.c $LIBS ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: cat stderr stderr: stderr: stdout: 641. regression.at:1220: testing Expecting two tokens ... ./regression.at:1220: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o expect2.c expect2.y stdout: ./existing.at:1460: $PREPARSER ./input stderr: ./regression.at:438: $PREPARSER ./input 570. calc.at:1494: ok stderr: 642. regression.at:1221: testing Expecting two tokens %glr-parser ... ./regression.at:1221: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o expect2.c expect2.y ./existing.at:1460: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected a, expecting "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" ./regression.at:438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 623. existing.at:1460: ok 633. regression.at:438: ok ./regression.at:1220: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o expect2 expect2.c $LIBS ./regression.at:1221: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o expect2 expect2.c $LIBS stderr: ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror stdout: ./existing.at:74: $PREPARSER ./input stderr: ./existing.at:74: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 643. regression.at:1222: testing Expecting two tokens lalr1.cc ... ./regression.at:1222: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o expect2.cc expect2.y stderr: stdout: 618. existing.at:74: ok 644. regression.at:1230: testing Braced code in declaration in rules section ... ./regression.at:1143: $PREPARSER ./dancer ./regression.at:1261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: syntax error, unexpected ':' ./regression.at:1143: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 645. regression.at:1291: testing String alias declared after use ... ./regression.at:1304: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./regression.at:1222: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o expect2 expect2.cc $LIBS 638. regression.at:1143: ok ./regression.at:1262: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 645. regression.at:1291: ok stderr: stdout: ./regression.at:1220: $PREPARSER ./expect2 stderr: syntax error, unexpected '+', expecting A or B ./regression.at:1220: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 646. regression.at:1314: testing Extra lookahead sets in report ... ./regression.at:1329: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all input.y 647. regression.at:1355: testing Token number in precedence declaration ... ./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall -o input.c input.y ./regression.at:1330: sed -n '/^State 1$/,/^State 2$/p' input.output 641. regression.at:1220: ok 646. regression.at:1314: ok 648. regression.at:1408: testing parse-gram.y: LALR = IELR ... ./regression.at:1414: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -Dlr.type=lalr input.y ./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y -Werror stderr: input.y:24.5-19: error: rule useless in parser due to conflicts [-Werror=other] input.y:28.5-19: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.1-5: error: useless precedence and associativity for TK1 [-Werror=precedence] stderr: stdout: ./regression.at:1144: $PREPARSER ./dancer ./regression.at:1388: sed 's,.*/$,,' stderr 1>&2 stderr: 649. regression.at:1430: testing parse.error=verbose and YYSTACK_USE_ALLOCA ... syntax error, unexpected ':' ./regression.at:1144: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1481: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 639. regression.at:1144: ok 650. regression.at:1504: testing parse.error=verbose overflow ... ./regression.at:1604: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y --warnings=error ./regression.at:1482: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./regression.at:1611: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y -Wnone,none -Werror --trace=none ./regression.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -Dlr.type=ielr input.y ./regression.at:1221: $PREPARSER ./expect2 stderr: syntax error, unexpected '+', expecting A or B 651. regression.at:1628: testing LAC: Exploratory stack ... ./regression.at:1713: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full \ -Dparse.lac.es-capacity-initial=1 \ -Dparse.lac.memory-trace=full -o input.c input.y ./regression.at:1221: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y --warnings=none -Werror --trace=none ./regression.at:1713: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: 642. regression.at:1221: ok stdout: ./regression.at:1263: $PREPARSER ./input --debug ./regression.at:1393: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reducing stack by rule 1 (line 20): -> $$ = nterm start () Entering state 1 Stack now 0 1 Reading a token Next token is token 'a' (PRINTER) syntax error, unexpected 'a', expecting end of file Error: popping nterm start () Stack now 0 Cleanup: discarding lookahead token 'a' (PRINTER) DESTRUCTOR Stack now 0 ./regression.at:1263: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 644. regression.at:1230: ok stderr: input.y: In function 'yyparse': input.y:59:24: warning: format '%d' expects argument of type 'int', but argument 3 has type 'long int' [-Wformat=] 59 | fprintf (stderr, " yymsg_alloc = %d\n", yymsg_alloc); | ^~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~ | | | long int input.y:60:24: warning: format '%d' expects argument of type 'int', but argument 3 has type 'long int' [-Wformat=] 60 | fprintf (stderr, " YYSTACK_ALLOC_MAXIMUM = %d\n", | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:62:24: warning: format '%d' expects argument of type 'int', but argument 3 has type 'long int' [-Wformat=] 62 | fprintf (stderr, " YYSIZE_MAXIMUM = %d\n", YYSIZE_MAXIMUM); | ^~~~~~~~~~~~~~~~~~~~~~~~~ stdout: ./regression.at:1613: $PREPARSER ./input stderr: syntax error, unexpected 'a', expecting 123456789112345678921234567893123456789412345678951234567896123A or 123456789112345678921234567893123456789412345678951234567896123B or 123456789112345678921234567893123456789412345678951234567896123C syntax error, unexpected 'd' syntax error memory exhausted ./regression.at:1613: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 650. regression.at:1504: ok ./regression.at:1420: diff lalr.c ielr.c 648. regression.at:1408: ok 652. regression.at:1739: testing LAC: Memory exhaustion ... ./regression.at:1771: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -Dparse.lac.es-capacity-initial=1 -o input.c input.y 653. regression.at:1874: testing Lex and parse params: yacc.c ... ./regression.at:1874: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: ./regression.at:1771: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./regression.at:1145: $PREPARSER ./dancer stdout: ./regression.at:1483: $PREPARSER ./input 654. regression.at:1875: testing Lex and parse params: glr.c ... stderr: stderr: syntax error, unexpected 'a', expecting 123456789112345678921234567893123456789412345678951234567896123A or 123456789112345678921234567893123456789412345678951234567896123B syntax error, unexpected end of file, expecting 123456789112345678921234567893123456789412345678951234567896123A or 123456789112345678921234567893123456789412345678951234567896123B ./regression.at:1483: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected ':' ./regression.at:1875: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./regression.at:1145: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1874: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 655. regression.at:1876: testing Lex and parse params: lalr1.cc ... ./regression.at:1876: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 649. regression.at:1430: ok 640. regression.at:1145: ok stderr: ./regression.at:1875: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: ./regression.at:1876: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./regression.at:1394: $PREPARSER ./input stderr: ./regression.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 647. regression.at:1355: ok stderr: stdout: stderr: stdout: ./regression.at:1874: $PREPARSER ./input stderr: ./regression.at:1713: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt ./regression.at:1874: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 653. regression.at:1874: ok stderr: 656. regression.at:1877: testing Lex and parse params: glr.cc ... ./regression.at:1713: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 657. regression.at:1878: testing Lex and parse params: glr2.cc ... ./regression.at:1878: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./regression.at:1713: grep 'syntax error,' stderr.txt 658. regression.at:1889: testing stdio.h is not needed ... ./regression.at:1713: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt ./regression.at:1906: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./regression.at:1877: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./regression.at:1878: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror ./regression.at:1713: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt ./regression.at:1906: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./regression.at:1713: "$PERL" -0777 -ne 'print s/\(realloc//g;' < stderr.txt 659. push.at:25: testing Memory Leak for Early Deletion ... ./push.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: ./regression.at:1222: $PREPARSER ./expect2 stderr: ./regression.at:1714: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full \ -Dparse.lac.es-capacity-initial=1 \ -Dparse.lac.memory-trace=full -o input.c input.y stderr: stdout: ./regression.at:1771: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS syntax error, unexpected '+', expecting A or B ./regression.at:1222: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./push.at:75: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 643. regression.at:1222: ok ./regression.at:1714: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: 658. regression.at:1889: ok 660. push.at:84: testing Multiple impure instances ... ./push.at:134: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./push.at:134: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 661. push.at:145: testing Unsupported Skeletons ... ./push.at:156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: stdout: stderr: input.y:202.20: error: empty rule without %empty [-Werror=empty-rule] input.y:270.7: error: empty rule without %empty [-Werror=empty-rule] input.y:292.13: error: empty rule without %empty [-Werror=empty-rule] input.y:309.18: error: empty rule without %empty [-Werror=empty-rule] input.y:382.14: error: empty rule without %empty [-Werror=empty-rule] input.y:471.11-48: error: rule useless in parser due to conflicts [-Werror=other] input.y:154.1-5: error: useless associativity for LABEL, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for VARIABLE, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for NUMBER, use %precedence [-Werror=precedence] input.y:141.1-5: error: useless associativity for TEXT, use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for ORDINAL, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for LAST, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for UP, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for DOWN, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for BOX, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for CIRCLE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ELLIPSE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ARC, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for LINE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ARROW, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for SPLINE, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for HEIGHT, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for RADIUS, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for WIDTH, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for DIAMETER, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for FROM, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for TO, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for AT, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for SOLID [-Werror=precedence] input.y:153.1-5: error: useless associativity for DOTTED, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for DASHED, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for CHOP, use %precedence [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for LJUST [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for RJUST [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for ABOVE [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for BELOW [-Werror=precedence] input.y:176.1-5: error: useless associativity for OF, use %precedence [-Werror=precedence] input.y:176.1-5: error: useless associativity for BETWEEN, use %precedence [-Werror=precedence] input.y:177.1-5: error: useless associativity for AND, use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for HERE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_N, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_E, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_W, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_S, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_NE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_SE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_NW, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_SW, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_C, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for DOT_START, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for DOT_END, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SIN, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for COS, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for ATAN2, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for LOG, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for EXP, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SQRT, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for K_MAX, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for K_MIN, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for INT, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for RAND, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SRAND, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for TOP, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for BOTTOM, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for UPPER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for LOWER, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for LEFT_CORNER, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for RIGHT_CORNER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for NORTH, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for SOUTH, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for EAST, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for WEST, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for CENTER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for END, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for START, use %precedence [-Werror=precedence] input.y:140.1-5: error: useless associativity for PLOT, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for THICKNESS, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for FILL, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for COLORED [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for OUTLINED [-Werror=precedence] input.y:141.1-5: error: useless associativity for SPRINTF, use %precedence [-Werror=precedence] input.y:137.1-5: error: useless associativity for '.', use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for '`', use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for '[', use %precedence [-Werror=precedence] input.y:170.1-5: error: useless associativity for ',', use %precedence [-Werror=precedence] input.y:181.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ./push.at:76: $PREPARSER ./input stderr: stderr: ./push.at:76: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./regression.at:1875: $PREPARSER ./input stderr: 661. push.at:145: ok ./existing.at:1460: sed 's,.*/$,,' stderr 1>&2 659. push.at:25: ok ./regression.at:1875: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error stderr: stdout: ./regression.at:1772: $PREPARSER ./input --debug stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. LAC: initial context established for "end of file" LAC: checking lookahead "end of file": R2 G3 R2 G5 R2 G6 R2 G7 R2 G8 R2 G9 R2 G10 R2 G11 R2 (max size exceeded) memory exhausted Cleanup: discarding lookahead token "end of file" () Stack now 0 ./regression.at:1772: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 654. regression.at:1875: ok stderr: stdout: ./push.at:134: $PREPARSER ./input stderr: ./push.at:134: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1787: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -Dparse.lac.es-capacity-initial=1 -o input.c input.y ./push.at:135: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 662. push.at:167: testing Pstate reuse ... 663. c++.at:26: testing C++ Locations Unit Tests ... ./push.at:276: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./regression.at:1787: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./regression.at:1714: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./push.at:135: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./regression.at:1714: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1714: grep 'syntax error,' stderr.txt ./push.at:276: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 664. c++.at:107: testing C++ Variant-based Symbols Unit Tests ... ./c++.at:234: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.yy ./regression.at:1714: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./regression.at:1714: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt ======== Testing with C++ standard flags: '' ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./regression.at:1714: "$PERL" -0777 -ne 'print s/\(realloc//g;' < stderr.txt stderr: stdout: ./regression.at:1876: $PREPARSER ./input ./regression.at:1715: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full \ -Dparse.lac.es-capacity-initial=1 \ -Dparse.lac.memory-trace=full -o input.c input.y stderr: stderr: ./regression.at:1876: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./regression.at:1715: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./push.at:135: $PREPARSER ./input stderr: 655. regression.at:1876: ok ./push.at:135: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 660. push.at:84: ok stderr: stdout: 666. c++.at:566: testing Variants lalr1.cc ... ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./push.at:277: ./input stderr: stdout: ./regression.at:1787: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 665. c++.at:247: testing Multiple occurrences of $n and api.value.automove ... ./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.yy 662. push.at:167: ok ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.yy -Werror 667. c++.at:567: testing Variants lalr1.cc parse.assert ... ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: input.yy:16.33-34: error: multiple occurrences of $2 with api.value.automove [-Werror=other] 16 | | "twice" exp { $$ = $2 + $2; } | ^~ input.yy:17.33-36: error: multiple occurrences of $2 with api.value.automove [-Werror=other] 17 | | "thrice" exp[val] { $$ = $2 + $val + $2; } | ^~~~ input.yy:17.40-41: error: multiple occurrences of $2 with api.value.automove [-Werror=other] 17 | | "thrice" exp[val] { $$ = $2 + $val + $2; } | ^~ stderr: ./c++.at:263: sed 's,.*/$,,' stderr 1>&2 stdout: ./regression.at:1877: $PREPARSER ./input stderr: stdout: ./regression.at:1715: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt stderr: stderr: ./regression.at:1715: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1715: grep 'syntax error,' stderr.txt ./regression.at:1715: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt ./regression.at:1715: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt ./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.yy --warnings=error ./regression.at:1877: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1715: "$PERL" -0777 -ne 'print s/\(realloc//g;' < stderr.txt ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS 656. regression.at:1877: ok ./regression.at:1716: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full \ -Dparse.lac.es-capacity-initial=1 \ -Dparse.lac.memory-trace=full -o input.c input.y ./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.yy -Wnone,none -Werror --trace=none stderr: stdout: ./regression.at:1788: $PREPARSER ./input --debug ./regression.at:1716: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" () LAC: initial context established for "invalid token" LAC: checking lookahead "invalid token": Always Err Constructing syntax error message LAC: checking lookahead "end of file": R2 G3 R2 G5 R2 G6 R2 G7 R2 G8 R2 G9 R2 G10 R2 G11 R2 (max size exceeded) syntax error memory exhausted Cleanup: discarding lookahead token "invalid token" () Stack now 0 ./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.yy --warnings=none -Werror --trace=none ./regression.at:1788: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 668. c++.at:568: testing Variants lalr1.cc parse.assert api.value.automove ... ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y 652. regression.at:1739: ok 665. c++.at:247: ok ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS 670. c++.at:570: testing Variants lalr1.cc parse.assert %code {\n#define TWO_STAGE_BUILD\n} ... 669. c++.at:569: testing Variants lalr1.cc parse.assert %locations ... ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./regression.at:1716: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt stderr: ./regression.at:1716: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1716: grep 'syntax error,' stderr.txt ./regression.at:1716: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt ./regression.at:1716: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt ./regression.at:1716: "$PERL" -0777 -ne 'print s/\(realloc//g;' < stderr.txt ./regression.at:1719: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -o input.cc input.y stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./regression.at:1719: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./regression.at:1878: $PREPARSER ./input stderr: ./regression.at:1878: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 657. regression.at:1878: ok stderr: stdout: ./c++.at:235: $PREPARSER ./list stderr: ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS 671. c++.at:571: testing Variants lalr1.cc parse.assert api.token.constructor ... ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: input.y:128.18: error: empty rule without %empty [-Werror=empty-rule] input.y:137.18: error: empty rule without %empty [-Werror=empty-rule] input.y:142.18: error: empty rule without %empty [-Werror=empty-rule] input.y:161.18: error: empty rule without %empty [-Werror=empty-rule] input.y:179.18: error: empty rule without %empty [-Werror=empty-rule] input.y:205.18: error: empty rule without %empty [-Werror=empty-rule] input.y:213.18: error: empty rule without %empty [-Werror=empty-rule] input.y:225.18: error: empty rule without %empty [-Werror=empty-rule] input.y:292.18: error: empty rule without %empty [-Werror=empty-rule] input.y:294.20: error: empty rule without %empty [-Werror=empty-rule] input.y:367.18: error: empty rule without %empty [-Werror=empty-rule] input.y:373.18: error: empty rule without %empty [-Werror=empty-rule] input.y:387.18: error: empty rule without %empty [-Werror=empty-rule] input.y:401.18: error: empty rule without %empty [-Werror=empty-rule] input.y:413.18: error: empty rule without %empty [-Werror=empty-rule] input.y:443.18: error: empty rule without %empty [-Werror=empty-rule] input.y:471.18: error: empty rule without %empty [-Werror=empty-rule] input.y:474.18: error: empty rule without %empty [-Werror=empty-rule] input.y:489.18: error: empty rule without %empty [-Werror=empty-rule] input.y:506.18: error: empty rule without %empty [-Werror=empty-rule] input.y:587.18: error: empty rule without %empty [-Werror=empty-rule] input.y:591.18: error: empty rule without %empty [-Werror=empty-rule] input.y: error: 1876 shift/reduce conflicts [-Werror=conflicts-sr] input.y: error: 144 reduce/reduce conflicts [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:72.1-5: error: useless associativity for HQUA, use %precedence [-Werror=precedence] input.y:53.1-6: error: useless associativity for HASSIGN, use %precedence [-Werror=precedence] input.y:54.1-5: error: useless associativity for HORELSE, use %precedence [-Werror=precedence] input.y:55.1-5: error: useless associativity for HANDTHEN, use %precedence [-Werror=precedence] input.y:61.1-5: error: useless associativity for HNOT, use %precedence [-Werror=precedence] input.y:68.1-5: error: useless associativity for UNEAR, use %precedence [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] stderr: ./existing.at:808: sed 's,.*/$,,' stderr 1>&2 stderr: stdout: ./c++.at:567: $here/modern stdout: Modern C++: 201703 ./c++.at:567: $PREPARSER ./list stderr: stdout: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./regression.at:1719: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error stderr: ./regression.at:1719: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./regression.at:1719: grep 'syntax error,' stderr.txt ./regression.at:1719: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt ./regression.at:1719: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt stderr: ./regression.at:1727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -o input.java input.y stdout: ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none stdout: ./torture.at:395: $PREPARSER ./input stderr: ./torture.at:395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 613. torture.at:385: ok 651. regression.at:1628: skipped (regression.at:1727) 673. c++.at:573: testing Variants lalr1.cc parse.assert api.token.constructor api.token.prefix={TOK_} %locations ... stderr: 672. c++.at:572: testing Variants lalr1.cc parse.assert api.token.constructor api.token.prefix={TOK_} ... ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stdout: stderr: stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:568: $here/modern stdout: Modern C++: 201703 ./c++.at:568: $PREPARSER ./list ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:235: $PREPARSER ./list stderr: ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:566: $here/modern stdout: Modern C++: 201703 ./c++.at:566: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:569: $here/modern stdout: Modern C++: 201703 stderr: ./c++.at:569: $PREPARSER ./list stdout: ./c++.at:570: $here/modern stdout: stderr: Modern C++: 201703 ./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./existing.at:1460: sed -n 's/^State //p' input.output | tail -1 ./existing.at:1460: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./c++.at:571: $here/modern stdout: Modern C++: 201703 ./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:567: $here/modern stdout: Legac++ ./c++.at:567: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:235: $PREPARSER ./list stderr: ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./existing.at:1460: $PREPARSER ./input ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stderr: ./existing.at:1460: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 624. existing.at:1460: ok stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS 674. c++.at:574: testing Variants lalr1.cc parse.assert api.token.constructor api.token.prefix={TOK_} %locations api.value.automove ... stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:566: $here/modern stdout: Legac++ ./c++.at:566: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:573: $here/modern stdout: stderr: Modern C++: 201703 ./c++.at:573: $PREPARSER ./list stderr: stdout: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:572: $here/modern ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stdout: Modern C++: 201703 ./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:568: $here/modern stdout: ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y Legac++ ./c++.at:568: $PREPARSER ./list stderr: ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:570: $here/modern ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stdout: Legac++ ./c++.at:570: $PREPARSER ./list stderr: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:235: $PREPARSER ./list stderr: stderr: ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:569: $here/modern ======== Testing with C++ standard flags: '' stdout: ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS Legac++ ./c++.at:569: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:571: $here/modern stdout: Legac++ ./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:567: $here/modern stdout: Legac++ ./c++.at:567: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:566: $here/modern stdout: Legac++ ./c++.at:566: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stderr: stdout: stdout: ./c++.at:574: $here/modern stdout: stderr: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS Modern C++: 201703 ./c++.at:574: $PREPARSER ./list stdout: stderr: ./c++.at:573: $here/modern Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) stdout: Legac++ ./c++.at:573: $PREPARSER ./list stderr: stderr: stdout: ./c++.at:568: $here/modern ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) Legac++ ./c++.at:568: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:570: $here/modern ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stdout: Legac++ ./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:572: $here/modern stdout: Legac++ ./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:235: $PREPARSER ./list stderr: ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none stderr: stdout: stderr: ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:571: $here/modern stdout: Legac++ ./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) stderr: stdout: ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:566: $here/modern stdout: Modern C++: 201103 ./c++.at:566: $PREPARSER ./list stderr: ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:569: $here/modern stdout: Legac++ ./c++.at:569: $PREPARSER ./list stderr: stderr: stdout: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:567: $here/modern ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: Modern C++: 201103 ./c++.at:567: $PREPARSER ./list ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stderr: stdout: stdout: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:235: $PREPARSER ./list stderr: ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:573: $here/modern stdout: Legac++ ./c++.at:573: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:572: $here/modern stdout: Legac++ ./c++.at:572: $PREPARSER ./list stderr: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: ./c++.at:574: $here/modern stdout: Legac++ ./c++.at:574: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:570: $here/modern stdout: Modern C++: 201103 ./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:568: $here/modern ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stdout: Modern C++: 201103 ./c++.at:568: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 663. c++.at:26: ok 675. c++.at:584: testing Variants and Typed Midrule Actions ... ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:571: $here/modern stdout: Modern C++: 201103 ./c++.at:571: $PREPARSER ./list stderr: ./existing.at:808: sed -n 's/^State //p' input.output | tail -1 Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:235: $PREPARSER ./list stderr: ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:808: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ======== Testing with C++ standard flags: '' ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: stderr: stdout: ./c++.at:567: $here/modern stdout: ./c++.at:566: $here/modern Modern C++: 201402 ./c++.at:567: $PREPARSER ./list stderr: stdout: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) Modern C++: 201402 ./c++.at:566: $PREPARSER ./list ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:569: $here/modern stdout: Modern C++: 201103 ./c++.at:569: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./existing.at:808: $PREPARSER ./input stderr: ./existing.at:808: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 621. existing.at:808: ok stderr: stdout: ./c++.at:572: $here/modern stdout: Modern C++: 201103 ./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y 676. c++.at:794: testing Doxygen Public Documentation ... stderr: ./c++.at:794: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stdout: ./c++.at:573: $here/modern ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: Modern C++: 201103 ./c++.at:573: $PREPARSER ./list stderr: stderr: stdout: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:659: $PREPARSER ./input stderr: ./c++.at:794: doxygen --version || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y --- /dev/null 2026-03-27 17:47:36.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/676/stderr 2026-03-27 18:45:36.501669377 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/676/test-source: line 180: doxygen: command not found stdout: 676. c++.at:794: skipped (c++.at:794) ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:570: $here/modern stdout: Modern C++: 201402 ./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) stderr: stdout: ./c++.at:574: $here/modern ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: 677. c++.at:795: testing Doxygen Private Documentation ... Legac++ ./c++.at:574: $PREPARSER ./list stderr: ./c++.at:795: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:795: doxygen --version || exit 77 ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y --- /dev/null 2026-03-27 17:47:36.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/677/stderr 2026-03-27 18:45:36.757669377 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/677/test-source: line 180: doxygen: command not found stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS 677. c++.at:795: skipped (c++.at:795) stderr: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: ./c++.at:568: $here/modern stdout: Modern C++: 201402 ./c++.at:568: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y 678. c++.at:848: testing Relative namespace references ... ./c++.at:849: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:571: $here/modern stderr: stdout: stdout: Modern C++: 201402 ./c++.at:566: $here/modern ./c++.at:571: $PREPARSER ./list stdout: Modern C++: 201703 ./c++.at:566: $PREPARSER ./list stderr: stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:235: $PREPARSER ./list stderr: ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS 664. c++.at:107: ok stderr: stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 679. c++.at:854: testing Absolute namespace references ... ./c++.at:855: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stderr: stdout: ./c++.at:567: $here/modern stdout: Modern C++: 201703 ./c++.at:567: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:569: $here/modern stdout: Modern C++: 201402 ./c++.at:569: $PREPARSER ./list ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: stderr: ./c++.at:659: $PREPARSER ./input stdout: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:572: $here/modern stdout: Modern C++: 201402 ./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stderr: stdout: ./c++.at:849: $PREPARSER ./input stdout: stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:573: $here/modern stdout: Modern C++: 201402 stderr: ./c++.at:573: $PREPARSER ./list stdout: stderr: ./c++.at:855: $PREPARSER ./input Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) stderr: ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:570: $here/modern stdout: Modern C++: 201703 ./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:574: $here/modern stdout: Modern C++: 201103 ./c++.at:574: $PREPARSER ./list stderr: stderr: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) stdout: ./c++.at:568: $here/modern ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: Modern C++: 201703 ./c++.at:568: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: stderr: stdout: ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:659: $PREPARSER ./input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./c++.at:855: $PREPARSER ./input stderr: ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:571: $here/modern stdout: Modern C++: 201703 ./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:855: $PREPARSER ./input stderr: ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:569: $here/modern stdout: stderr: Modern C++: 201703 ./c++.at:569: $PREPARSER ./list stdout: ./c++.at:567: $here/modern stdout: stderr: Modern C++: 202002 ./c++.at:567: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:566: $here/modern stdout: ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS Modern C++: 202002 ./c++.at:566: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:572: $here/modern stdout: Modern C++: 201703 ./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:659: $PREPARSER ./input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 stderr: ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:573: $here/modern stdout: Modern C++: 201703 ./c++.at:573: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:855: $PREPARSER ./input stderr: ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:574: $here/modern stdout: Modern C++: 201402 ./c++.at:574: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:855: $PREPARSER ./input stderr: ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:570: $here/modern stdout: Modern C++: 202002 ./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:659: $PREPARSER ./input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:571: $here/modern stdout: Modern C++: 202002 ./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:568: $here/modern stdout: Modern C++: 202002 ./c++.at:568: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:855: $PREPARSER ./input stderr: ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:569: $here/modern stdout: Modern C++: 202002 ./c++.at:569: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:855: $PREPARSER ./input stderr: ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:574: $here/modern ======== Testing with C++ standard flags: '' stdout: ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS Modern C++: 201703 ./c++.at:574: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: stderr: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stdout: ./c++.at:659: $PREPARSER ./input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:573: $here/modern stdout: Modern C++: 202002 ./c++.at:573: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:850: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ======== Testing with C++ standard flags: '' ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:567: $here/modern stdout: Modern C++: 202302 ./c++.at:567: $PREPARSER ./list stderr: stderr: stdout: ./c++.at:572: $here/modern stdout: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) Modern C++: 202002 ./c++.at:572: $PREPARSER ./list stderr: ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 667. c++.at:567: ok ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS 680. c++.at:863: testing Syntactically invalid namespace references ... ./c++.at:864: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ./c++.at:865: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ./c++.at:868: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stderr: stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:869: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ./c++.at:870: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stderr: stdout: ./c++.at:855: $PREPARSER ./input stderr: stderr: ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: 680. c++.at:863: ok stderr: ./c++.at:856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 681. c++.at:884: testing Syntax error discarding no lookahead ... ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:566: $here/modern stdout: Modern C++: 202302 ./c++.at:566: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 666. c++.at:566: ok stderr: stdout: ./c++.at:850: $PREPARSER ./input stderr: ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:659: $PREPARSER ./input 682. c++.at:1064: testing Syntax error as exception: lalr1.cc ... ./c++.at:1064: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ======== Testing with C++ standard flags: '' ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:856: $PREPARSER ./input stderr: ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:850: $PREPARSER ./input stderr: ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:570: $here/modern stdout: Modern C++: 202302 ./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 670. c++.at:570: ok stderr: stdout: ./c++.at:571: $here/modern stderr: stdout: Modern C++: 202302 stdout: ./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:568: $here/modern stdout: ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Modern C++: 202302 ./c++.at:568: $PREPARSER ./list 671. c++.at:571: ok stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 683. c++.at:1065: testing Syntax error as exception: glr.cc ... ./c++.at:1065: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy 668. c++.at:568: ok 684. c++.at:1066: testing Syntax error as exception: glr2.cc ... ./c++.at:1066: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ======== Testing with C++ standard flags: '' ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS 685. c++.at:1360: testing Exception safety with error recovery ... ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o exceptions exceptions.cc $LIBS stderr: stdout: ./c++.at:574: $here/modern stdout: Modern C++: 202002 ./c++.at:574: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ======== Testing with C++ standard flags: '' ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:1066: ./check ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: ./c++.at:856: $PREPARSER ./input stderr: ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:941: $PREPARSER ./input stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:850: $PREPARSER ./input stderr: ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: ./c++.at:1360: ./exceptions || exit 77 stderr: Inner caught Outer caught ./c++.at:1360: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc --report=all input.yy ======== Testing with C++ standard flags: '' ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: ./c++.at:856: $PREPARSER ./input stderr: ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:659: $PREPARSER ./input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:573: $here/modern stdout: Modern C++: 202302 ./c++.at:573: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 673. c++.at:573: ok 675. c++.at:584: ok 686. c++.at:1361: testing Exception safety without error recovery ... ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o exceptions exceptions.cc $LIBS 687. c++.at:1362: testing Exception safety with error recovery api.value.type=variant ... ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o exceptions exceptions.cc $LIBS stderr: stdout: ./c++.at:850: $PREPARSER ./input stderr: ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:856: $PREPARSER ./input stderr: ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stderr: stdout: ./c++.at:941: $PREPARSER ./input stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:569: $here/modern stdout: ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS Modern C++: 202302 ./c++.at:569: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 669. c++.at:569: ok stderr: stdout: ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in 688. c++.at:1363: testing Exception safety without error recovery api.value.type=variant ... stderr: error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o exceptions exceptions.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: ./c++.at:1362: ./exceptions || exit 77 stderr: Inner caught Outer caught ./c++.at:1362: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc --report=all input.yy stderr: stdout: ./c++.at:1361: ./exceptions || exit 77 stderr: Inner caught Outer caught ./c++.at:1361: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc --report=all input.yy ======== Testing with C++ standard flags: '' ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:850: $PREPARSER ./input stderr: ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in ======== Testing with C++ standard flags: '' ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: ./c++.at:941: $PREPARSER ./input stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:572: $here/modern stdout: Modern C++: 202302 ./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1363: ./exceptions || exit 77 stderr: Inner caught Outer caught ./c++.at:1363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc --report=all input.yy stderr: stdout: ./c++.at:1360: $PREPARSER ./input aaaas stderr: 672. c++.at:572: ok exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 689. c++.at:1371: testing C++ GLR parser identifier shadowing ... ./c++.at:1410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ./c++.at:1360: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:856: $PREPARSER ./input ./c++.at:1360: $PREPARSER ./input aaaap ======== Testing with C++ standard flags: '' stderr: ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1360: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaf2a7af40->Object::Object { } Next token is token 'a' (0xaaaaf2a7af40 'a') Shifting token 'a' (0xaaaaf2a7af40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf2a7af40 'a') -> $$ = nterm item (0xaaaaf2a7af40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaaf2a7af90->Object::Object { 0xaaaaf2a7af40 } Next token is token 'a' (0xaaaaf2a7af90 'a') Shifting token 'a' (0xaaaaf2a7af90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf2a7af90 'a') -> $$ = nterm item (0xaaaaf2a7af90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaaf2a7afe0->Object::Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90 } Next token is token 'a' (0xaaaaf2a7afe0 'a') Shifting token 'a' (0xaaaaf2a7afe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf2a7afe0 'a') -> $$ = nterm item (0xaaaaf2a7afe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaaf2a7b030->Object::Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0 } Next token is token 'a' (0xaaaaf2a7b030 'a') Shifting token 'a' (0xaaaaf2a7b030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf2a7b030 'a') -> $$ = nterm item (0xaaaaf2a7b030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaaf2a7b080->Object::Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0, 0xaaaaf2a7b030 } Next token is token 'p' (0xaaaaf2a7b080 'p'Exception caught: cleaning lookahead and stack 0xaaaaf2a7b080->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0, 0xaaaaf2a7b030, 0xaaaaf2a7b080 } 0xaaaaf2a7b030->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0, 0xaaaaf2a7b030 } 0xaaaaf2a7afe0->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0 } 0xaaaaf2a7af90->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90 } 0xaaaaf2a7af40->Object::~Object { 0xaaaaf2a7af40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaf2a7af40->Object::Object { } Next token is token 'a' (0xaaaaf2a7af40 'a') Shifting token 'a' (0xaaaaf2a7af40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf2a7af40 'a') -> $$ = nterm item (0xaaaaf2a7af40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaaf2a7af90->Object::Object { 0xaaaaf2a7af40 } Next token is token 'a' (0xaaaaf2a7af90 'a') Shifting token 'a' (0xaaaaf2a7af90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf2a7af90 'a') -> $$ = nterm item (0xaaaaf2a7af90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaaf2a7afe0->Object::Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90 } Next token is token 'a' (0xaaaaf2a7afe0 'a') Shifting token 'a' (0xaaaaf2a7afe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf2a7afe0 'a') -> $$ = nterm item (0xaaaaf2a7afe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaaf2a7b030->Object::Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0 } Next token is token 'a' (0xaaaaf2a7b030 'a') Shifting token 'a' (0xaaaaf2a7b030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf2a7b030 'a') -> $$ = nterm item (0xaaaaf2a7b030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaaf2a7b080->Object::Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0, 0xaaaaf2a7b030 } Next token is token 'p' (0xaaaaf2a7b080 'p'Exception caught: cleaning lookahead and stack 0xaaaaf2a7b080->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0, 0xaaaaf2a7b030, 0xaaaaf2a7b080 } 0xaaaaf2a7b030->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0, 0xaaaaf2a7b030 } 0xaaaaf2a7afe0->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0 } 0xaaaaf2a7af90->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90 } 0xaaaaf2a7af40->Object::~Object { 0xaaaaf2a7af40 } exception caught: printer end { } ./c++.at:1360: grep '^exception caught: printer$' stderr stdout: stdout: exception caught: printer ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:1360: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaT ./c++.at:1064: $PREPARSER ./input < in stderr: stderr: error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: ./c++.at:1360: $PREPARSER ./input aaaaR stdout: ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ./c++.at:850: $PREPARSER ./input stderr: stderr: ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stderr: stdout: ./c++.at:1361: $PREPARSER ./input aaaas stderr: stderr: exception caught: reduction ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stdout: ./c++.at:1065: $PREPARSER ./input < in ./c++.at:1361: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: ./check ./c++.at:1361: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -std=c++98 not supported ======== Testing with C++ standard flags: '' ./c++.at:1361: $PREPARSER ./input aaaap stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae906cf40->Object::Object { } Next token is token 'a' (0xaaaae906cf40 'a') Shifting token 'a' (0xaaaae906cf40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae906cf40 'a') -> $$ = nterm item (0xaaaae906cf40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaae906cf90->Object::Object { 0xaaaae906cf40 } Next token is token 'a' (0xaaaae906cf90 'a') Shifting token 'a' (0xaaaae906cf90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae906cf90 'a') -> $$ = nterm item (0xaaaae906cf90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaae906cfe0->Object::Object { 0xaaaae906cf40, 0xaaaae906cf90 } Next token is token 'a' (0xaaaae906cfe0 'a') Shifting token 'a' (0xaaaae906cfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae906cfe0 'a') -> $$ = nterm item (0xaaaae906cfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaae906d030->Object::Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0 } Next token is token 'a' (0xaaaae906d030 'a') Shifting token 'a' (0xaaaae906d030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae906d030 'a') -> $$ = nterm item (0xaaaae906d030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaae906d080->Object::Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0, 0xaaaae906d030 } Next token is token 'p' (0xaaaae906d080 'p'Exception caught: cleaning lookahead and stack 0xaaaae906d080->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0, 0xaaaae906d030, 0xaaaae906d080 } 0xaaaae906d030->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0, 0xaaaae906d030 } 0xaaaae906cfe0->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0 } 0xaaaae906cf90->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90 } 0xaaaae906cf40->Object::~Object { 0xaaaae906cf40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae906cf40->Object::Object { } Next token is token 'a' (0xaaaae906cf40 'a') Shifting token 'a' (0xaaaae906cf40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae906cf40 'a') -> $$ = nterm item (0xaaaae906cf40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaae906cf90->Object::Object { 0xaaaae906cf40 } Next token is token 'a' (0xaaaae906cf90 'a') Shifting token 'a' (0xaaaae906cf90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae906cf90 'a') -> $$ = nterm item (0xaaaae906cf90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaae906cfe0->Object::Object { 0xaaaae906cf40, 0xaaaae906cf90 } Next token is token 'a' (0xaaaae906cfe0 'a') Shifting token 'a' (0xaaaae906cfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae906cfe0 'a') -> $$ = nterm item (0xaaaae906cfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaae906d030->Object::Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0 } Next token is token 'a' (0xaaaae906d030 'a') Shifting token 'a' (0xaaaae906d030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae906d030 'a') -> $$ = nterm item (0xaaaae906d030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaae906d080->Object::Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0, 0xaaaae906d030 } Next token is token 'p' (0xaaaae906d080 'p'Exception caught: cleaning lookahead and stack 0xaaaae906d080->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0, 0xaaaae906d030, 0xaaaae906d080 } 0xaaaae906d030->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0, 0xaaaae906d030 } 0xaaaae906cfe0->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0 } 0xaaaae906cf90->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90 } 0xaaaae906cf40->Object::~Object { 0xaaaae906cf40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1361: $PREPARSER ./input aaaae ./c++.at:1065: $PREPARSER ./input < in stderr: exception caught: syntax error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS error: invalid expression ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in stderr: ./c++.at:1361: $PREPARSER ./input aaaaT error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1361: $PREPARSER ./input aaaaR ./c++.at:1066: ./check stderr: -std=c++03 not supported ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:856: $PREPARSER ./input stderr: stdout: ./c++.at:1362: $PREPARSER ./input aaaas stderr: ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1362: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1362: $PREPARSER ./input i stdout: stderr: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: ./check stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ./c++.at:1362: $PREPARSER ./input aaaap stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffea093d10->Object::Object { } 0xffffea093e10->Object::Object { 0xffffea093d10 } 0xffffea093d10->Object::~Object { 0xffffea093d10, 0xffffea093e10 } Next token is token 'a' (0xffffea093e10 'a') 0xffffea093d50->Object::Object { 0xffffea093e10 } 0xffffea093e10->Object::~Object { 0xffffea093d50, 0xffffea093e10 } Shifting token 'a' (0xffffea093d50 'a') 0xaaab0a89d2e0->Object::Object { 0xffffea093d50 } 0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xffffea093d50 } Entering state 2 Stack now 0 2 0xffffea093e30->Object::Object { 0xaaab0a89d2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0a89d2e0 'a') -> $$ = nterm item (0xffffea093e30 'a') 0xaaab0a89d2e0->Object::~Object { 0xaaab0a89d2e0, 0xffffea093e30 } 0xaaab0a89d2e0->Object::Object { 0xffffea093e30 } 0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xffffea093e30 } Entering state 11 Stack now 0 11 Reading a token 0xffffea093d10->Object::Object { 0xaaab0a89d2e0 } 0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xffffea093d10 } 0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xffffea093d10, 0xffffea093e10 } Next token is token 'a' (0xffffea093e10 'a') 0xffffea093d50->Object::Object { 0xaaab0a89d2e0, 0xffffea093e10 } 0xffffea093e10->Object::~Object { 0xaaab0a89d2e0, 0xffffea093d50, 0xffffea093e10 } Shifting token 'a' (0xffffea093d50 'a') 0xaaab0a89d300->Object::Object { 0xaaab0a89d2e0, 0xffffea093d50 } 0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d50 } Entering state 2 Stack now 0 11 2 0xffffea093e30->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0a89d300 'a') -> $$ = nterm item (0xffffea093e30 'a') 0xaaab0a89d300->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e30 } 0xaaab0a89d300->Object::Object { 0xaaab0a89d2e0, 0xffffea093e30 } 0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e30 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffea093d10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300 } 0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d10 } 0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d10, 0xffffea093e10 } Next token is token 'a' (0xffffea093e10 'a') 0xffffea093d50->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e10 } 0xffffea093e10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d50, 0xffffea093e10 } Shifting token 'a' (0xffffea093d50 'a') 0xaaab0a89d320->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d50 } 0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d50 } Entering state 2 Stack now 0 11 11 2 0xffffea093e30->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0a89d320 'a') -> $$ = nterm item (0xffffea093e30 'a') 0xaaab0a89d320->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e30 } 0xaaab0a89d320->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e30 } 0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e30 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffea093d10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320 } 0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d10 } 0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d10, 0xffffea093e10 } Next token is token 'a' (0xffffea093e10 'a') 0xffffea093d50->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e10 } 0xffffea093e10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d50, 0xffffea093e10 } Shifting token 'a' (0xffffea093d50 'a') 0xaaab0a89d340->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d50 } 0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093d50 } Entering state 2 Stack now 0 11 11 11 2 0xffffea093e30->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0a89d340 'a') -> $$ = nterm item (0xffffea093e30 'a') 0xaaab0a89d340->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093e30 } 0xaaab0a89d340->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e30 } 0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093e30 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffea093d10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340 } 0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093d10 } 0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093d10, 0xffffea093e10 } Next token is token 'p' (0xffffea093e10 'p'Exception caught: cleaning lookahead and stack 0xaaab0a89d340->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093e10 } 0xaaab0a89d320->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e10 } 0xaaab0a89d300->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e10 } 0xaaab0a89d2e0->Object::~Object { 0xaaab0a89d2e0, 0xffffea093e10 } 0xffffea093e10->Object::~Object { 0xffffea093e10 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffea093d10->Object::Object { } 0xffffea093e10->Object::Object { 0xffffea093d10 } 0xffffea093d10->Object::~Object { 0xffffea093d10, 0xffffea093e10 } Next token is token 'a' (0xffffea093e10 'a') 0xffffea093d50->Object::Object { 0xffffea093e10 } 0xffffea093e10->Object::~Object { 0xffffea093d50, 0xffffea093e10 } Shifting token 'a' (0xffffea093d50 'a') 0xaaab0a89d2e0->Object::Object { 0xffffea093d50 } 0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xffffea093d50 } Entering state 2 Stack now 0 2 0xffffea093e30->Object::Object { 0xaaab0a89d2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0a89d2e0 'a') -> $$ = nterm item (0xffffea093e30 'a') 0xaaab0a89d2e0->Object::~Object { 0xaaab0a89d2e0, 0xffffea093e30 } 0xaaab0a89d2e0->Object::Object { 0xffffea093e30 } 0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xffffea093e30 } Entering state 11 Stack now 0 11 Reading a token 0xffffea093d10->Object::Object { 0xaaab0a89d2e0 } 0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xffffea093d10 } 0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xffffea093d10, 0xffffea093e10 } Next token is token 'a' (0xffffea093e10 'a') 0xffffea093d50->Object::Object { 0xaaab0a89d2e0, 0xffffea093e10 } 0xffffea093e10->Object::~Object { 0xaaab0a89d2e0, 0xffffea093d50, 0xffffea093e10 } Shifting token 'a' (0xffffea093d50 'a') 0xaaab0a89d300->Object::Object { 0xaaab0a89d2e0, 0xffffea093d50 } 0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d50 } Entering state 2 Stack now 0 11 2 0xffffea093e30->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0a89d300 'a') -> $$ = nterm item (0xffffea093e30 'a') 0xaaab0a89d300->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e30 } 0xaaab0a89d300->Object::Object { 0xaaab0a89d2e0, 0xffffea093e30 } 0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e30 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffea093d10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300 } 0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d10 } 0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d10, 0xffffea093e10 } Next token is token 'a' (0xffffea093e10 'a') 0xffffea093d50->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e10 } 0xffffea093e10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d50, 0xffffea093e10 } Shifting token 'a' (0xffffea093d50 'a') 0xaaab0a89d320->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d50 } 0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d50 } Entering state 2 Stack now 0 11 11 2 0xffffea093e30->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0a89d320 'a') -> $$ = nterm item (0xffffea093e30 'a') 0xaaab0a89d320->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e30 } 0xaaab0a89d320->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e30 } 0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e30 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffea093d10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320 } 0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d10 } 0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d10, 0xffffea093e10 } Next token is token 'a' (0xffffea093e10 'a') 0xffffea093d50->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e10 } 0xffffea093e10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d50, 0xffffea093e10 } Shifting token 'a' (0xffffea093d50 'a') 0xaaab0a89d340->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d50 } 0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093d50 } Entering state 2 Stack now 0 11 11 11 2 0xffffea093e30->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0a89d340 'a') -> $$ = nterm item (0xffffea093e30 'a') 0xaaab0a89d340->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093e30 } 0xaaab0a89d340->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e30 } 0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093e30 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffea093d10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340 } 0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093d10 } 0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093d10, 0xffffea093e10 } Next token is token 'p' (0xffffea093e10 'p'Exception caught: cleaning lookahead and stack 0xaaab0a89d340->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093e10 } 0xaaab0a89d320->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e10 } 0xaaab0a89d300->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e10 } 0xaaab0a89d2e0->Object::~Object { 0xaaab0a89d2e0, 0xffffea093e10 } 0xffffea093e10->Object::~Object { 0xffffea093e10 } exception caught: printer end { } ./c++.at:1362: grep '^exception caught: printer$' stderr stderr: stdout: exception caught: printer stdout: ./c++.at:1362: $PREPARSER ./input aaaae ./c++.at:941: $PREPARSER ./input stderr: stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:1362: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:574: $here/modern stdout: Modern C++: 202302 ./c++.at:574: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) stderr: ./c++.at:1362: $PREPARSER ./input aaaaT stdout: ./c++.at:850: $PREPARSER ./input stderr: ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 674. c++.at:574: ok ./c++.at:1362: $PREPARSER ./input aaaaR stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 690. c++.at:1422: testing Shared locations ... ./c++.at:1456: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o x1.cc x1.yy stderr: ./c++.at:1456: $CXX $CPPFLAGS $CXXFLAGS -Iinclude -c -o x1.o x1.cc stdout: ./c++.at:1363: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaap stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffffe9d2010->Object::Object { } 0xfffffe9d2110->Object::Object { 0xfffffe9d2010 } 0xfffffe9d2010->Object::~Object { 0xfffffe9d2010, 0xfffffe9d2110 } Next token is token 'a' (0xfffffe9d2110 'a') 0xfffffe9d2050->Object::Object { 0xfffffe9d2110 } 0xfffffe9d2110->Object::~Object { 0xfffffe9d2050, 0xfffffe9d2110 } Shifting token 'a' (0xfffffe9d2050 'a') 0xaaab0764b2e0->Object::Object { 0xfffffe9d2050 } 0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2050 } Entering state 1 Stack now 0 1 0xfffffe9d2130->Object::Object { 0xaaab0764b2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0764b2e0 'a') -> $$ = nterm item (0xfffffe9d2130 'a') 0xaaab0764b2e0->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2130 } 0xaaab0764b2e0->Object::Object { 0xfffffe9d2130 } 0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2130 } Entering state 10 Stack now 0 10 Reading a token 0xfffffe9d2010->Object::Object { 0xaaab0764b2e0 } 0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2010 } 0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2010, 0xfffffe9d2110 } Next token is token 'a' (0xfffffe9d2110 'a') 0xfffffe9d2050->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2110 } 0xfffffe9d2110->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2050, 0xfffffe9d2110 } Shifting token 'a' (0xfffffe9d2050 'a') 0xaaab0764b300->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2050 } 0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2050 } Entering state 1 Stack now 0 10 1 0xfffffe9d2130->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0764b300 'a') -> $$ = nterm item (0xfffffe9d2130 'a') 0xaaab0764b300->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2130 } 0xaaab0764b300->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2130 } 0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2130 } Entering state 10 Stack now 0 10 10 Reading a token 0xfffffe9d2010->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300 } 0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2010 } 0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2010, 0xfffffe9d2110 } Next token is token 'a' (0xfffffe9d2110 'a') 0xfffffe9d2050->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2110 } 0xfffffe9d2110->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2050, 0xfffffe9d2110 } Shifting token 'a' (0xfffffe9d2050 'a') 0xaaab0764b320->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2050 } 0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2050 } Entering state 1 Stack now 0 10 10 1 0xfffffe9d2130->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0764b320 'a') -> $$ = nterm item (0xfffffe9d2130 'a') 0xaaab0764b320->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2130 } 0xaaab0764b320->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2130 } 0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2130 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xfffffe9d2010->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320 } 0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2010 } 0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2010, 0xfffffe9d2110 } Next token is token 'a' (0xfffffe9d2110 'a') 0xfffffe9d2050->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2110 } 0xfffffe9d2110->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2050, 0xfffffe9d2110 } Shifting token 'a' (0xfffffe9d2050 'a') 0xaaab0764b340->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2050 } 0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2050 } Entering state 1 Stack now 0 10 10 10 1 0xfffffe9d2130->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0764b340 'a') -> $$ = nterm item (0xfffffe9d2130 'a') 0xaaab0764b340->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2130 } 0xaaab0764b340->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2130 } 0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2130 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xfffffe9d2010->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340 } 0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2010 } 0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2010, 0xfffffe9d2110 } Next token is token 'p' (0xfffffe9d2110 'p'Exception caught: cleaning lookahead and stack 0xaaab0764b340->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2110 } 0xaaab0764b320->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2110 } 0xaaab0764b300->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2110 } 0xaaab0764b2e0->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2110 } 0xfffffe9d2110->Object::~Object { 0xfffffe9d2110 } exception caught: printer end { } ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffffe9d2010->Object::Object { } 0xfffffe9d2110->Object::Object { 0xfffffe9d2010 } 0xfffffe9d2010->Object::~Object { 0xfffffe9d2010, 0xfffffe9d2110 } Next token is token 'a' (0xfffffe9d2110 'a') 0xfffffe9d2050->Object::Object { 0xfffffe9d2110 } 0xfffffe9d2110->Object::~Object { 0xfffffe9d2050, 0xfffffe9d2110 } Shifting token 'a' (0xfffffe9d2050 'a') 0xaaab0764b2e0->Object::Object { 0xfffffe9d2050 } 0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2050 } Entering state 1 Stack now 0 1 0xfffffe9d2130->Object::Object { 0xaaab0764b2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0764b2e0 'a') -> $$ = nterm item (0xfffffe9d2130 'a') 0xaaab0764b2e0->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2130 } 0xaaab0764b2e0->Object::Object { 0xfffffe9d2130 } 0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2130 } Entering state 10 Stack now 0 10 Reading a token 0xfffffe9d2010->Object::Object { 0xaaab0764b2e0 } 0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2010 } 0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2010, 0xfffffe9d2110 } Next token is token 'a' (0xfffffe9d2110 'a') 0xfffffe9d2050->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2110 } 0xfffffe9d2110->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2050, 0xfffffe9d2110 } Shifting token 'a' (0xfffffe9d2050 'a') 0xaaab0764b300->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2050 } 0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2050 } Entering state 1 Stack now 0 10 1 0xfffffe9d2130->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0764b300 'a') -> $$ = nterm item (0xfffffe9d2130 'a') 0xaaab0764b300->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2130 } 0xaaab0764b300->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2130 } 0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2130 } Entering state 10 Stack now 0 10 10 Reading a token 0xfffffe9d2010->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300 } 0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2010 } 0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2010, 0xfffffe9d2110 } Next token is token 'a' (0xfffffe9d2110 'a') 0xfffffe9d2050->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2110 } 0xfffffe9d2110->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2050, 0xfffffe9d2110 } Shifting token 'a' (0xfffffe9d2050 'a') 0xaaab0764b320->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2050 } 0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2050 } Entering state 1 Stack now 0 10 10 1 0xfffffe9d2130->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0764b320 'a') -> $$ = nterm item (0xfffffe9d2130 'a') 0xaaab0764b320->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2130 } 0xaaab0764b320->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2130 } 0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2130 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xfffffe9d2010->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320 } 0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2010 } 0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2010, 0xfffffe9d2110 } Next token is token 'a' (0xfffffe9d2110 'a') 0xfffffe9d2050->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2110 } 0xfffffe9d2110->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2050, 0xfffffe9d2110 } Shifting token 'a' (0xfffffe9d2050 'a') 0xaaab0764b340->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2050 } 0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2050 } Entering state 1 Stack now 0 10 10 10 1 0xfffffe9d2130->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0764b340 'a') -> $$ = nterm item (0xfffffe9d2130 'a') 0xaaab0764b340->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2130 } 0xaaab0764b340->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2130 } 0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2130 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xfffffe9d2010->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340 } 0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2010 } 0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2010, 0xfffffe9d2110 } Next token is token 'p' (0xfffffe9d2110 'p'Exception caught: cleaning lookahead and stack 0xaaab0764b340->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2110 } 0xaaab0764b320->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2110 } 0xaaab0764b300->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2110 } 0xaaab0764b2e0->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2110 } 0xfffffe9d2110->Object::~Object { 0xfffffe9d2110 } exception caught: printer end { } ./c++.at:1363: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1363: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: $PREPARSER ./input aaaaE stderr: stdout: stderr: exception caught: syntax error, unexpected end of file, expecting 'a' stdout: ./c++.at:1064: $PREPARSER ./input < in ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaas stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: stderr: error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1363: $PREPARSER ./input aaaaT ======== Testing with C++ standard flags: '' ./c++.at:1064: $PREPARSER ./input < in stderr: ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaal ======== Testing with C++ standard flags: '' ./c++.at:1363: $PREPARSER ./input aaaaR ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stderr: exception caught: yylex ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1360: $PREPARSER ./input i ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: exception caught: initial-action ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaap stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaab0a588f40->Object::Object { } Next token is token 'a' (0xaaab0a588f40 'a') Shifting token 'a' (0xaaab0a588f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab0a588f40 'a') -> $$ = nterm item (0xaaab0a588f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaab0a588f90->Object::Object { 0xaaab0a588f40 } Next token is token 'a' (0xaaab0a588f90 'a') Shifting token 'a' (0xaaab0a588f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab0a588f90 'a') -> $$ = nterm item (0xaaab0a588f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaab0a588fe0->Object::Object { 0xaaab0a588f40, 0xaaab0a588f90 } Next token is token 'a' (0xaaab0a588fe0 'a') Shifting token 'a' (0xaaab0a588fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab0a588fe0 'a') -> $$ = nterm item (0xaaab0a588fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaab0a589030->Object::Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0 } Next token is token 'a' (0xaaab0a589030 'a') Shifting token 'a' (0xaaab0a589030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab0a589030 'a') -> $$ = nterm item (0xaaab0a589030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaab0a589080->Object::Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0, 0xaaab0a589030 } Next token is token 'p' (0xaaab0a589080 'p'Exception caught: cleaning lookahead and stack 0xaaab0a589080->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0, 0xaaab0a589030, 0xaaab0a589080 } 0xaaab0a589030->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0, 0xaaab0a589030 } 0xaaab0a588fe0->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0 } 0xaaab0a588f90->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90 } 0xaaab0a588f40->Object::~Object { 0xaaab0a588f40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stdout: ./c++.at:856: $PREPARSER ./input stderr: ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' Starting parse Entering state 0 Stack now 0 Reading a token 0xaaab0a588f40->Object::Object { } Next token is token 'a' (0xaaab0a588f40 'a') Shifting token 'a' (0xaaab0a588f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab0a588f40 'a') -> $$ = nterm item (0xaaab0a588f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaab0a588f90->Object::Object { 0xaaab0a588f40 } Next token is token 'a' (0xaaab0a588f90 'a') Shifting token 'a' (0xaaab0a588f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab0a588f90 'a') -> $$ = nterm item (0xaaab0a588f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaab0a588fe0->Object::Object { 0xaaab0a588f40, 0xaaab0a588f90 } Next token is token 'a' (0xaaab0a588fe0 'a') Shifting token 'a' (0xaaab0a588fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab0a588fe0 'a') -> $$ = nterm item (0xaaab0a588fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaab0a589030->Object::Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0 } Next token is token 'a' (0xaaab0a589030 'a') Shifting token 'a' (0xaaab0a589030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab0a589030 'a') -> $$ = nterm item (0xaaab0a589030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaab0a589080->Object::Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0, 0xaaab0a589030 } Next token is token 'p' (0xaaab0a589080 'p'Exception caught: cleaning lookahead and stack 0xaaab0a589080->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0, 0xaaab0a589030, 0xaaab0a589080 } 0xaaab0a589030->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0, 0xaaab0a589030 } 0xaaab0a588fe0->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0 } 0xaaab0a588f90->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90 } 0xaaab0a588f40->Object::~Object { 0xaaab0a588f40 } exception caught: printer end { } ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1360: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaT stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaR stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:941: $PREPARSER ./input stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1361: $PREPARSER ./input aaaas ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stderr: exception caught: reduction ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1361: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1463: sed -ne '/INCLUDED/p;/\\file/{p;n;p;}' include/ast/loc.hh ./c++.at:1361: $PREPARSER ./input i ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:1471: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o x2.cc x2.yy exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaap stderr: ./c++.at:1471: $CXX $CPPFLAGS $CXXFLAGS -Iinclude -c -o x2.o x2.cc ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaec95df40->Object::Object { } Next token is token 'a' (0xaaaaec95df40 'a') Shifting token 'a' (0xaaaaec95df40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaec95df40 'a') -> $$ = nterm item (0xaaaaec95df40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaaec95df90->Object::Object { 0xaaaaec95df40 } Next token is token 'a' (0xaaaaec95df90 'a') Shifting token 'a' (0xaaaaec95df90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaec95df90 'a') -> $$ = nterm item (0xaaaaec95df90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaaec95dfe0->Object::Object { 0xaaaaec95df40, 0xaaaaec95df90 } Next token is token 'a' (0xaaaaec95dfe0 'a') Shifting token 'a' (0xaaaaec95dfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaec95dfe0 'a') -> $$ = nterm item (0xaaaaec95dfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaaec95e030->Object::Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0 } Next token is token 'a' (0xaaaaec95e030 'a') Shifting token 'a' (0xaaaaec95e030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaec95e030 'a') -> $$ = nterm item (0xaaaaec95e030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaaec95e080->Object::Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0, 0xaaaaec95e030 } Next token is token 'p' (0xaaaaec95e080 'p'Exception caught: cleaning lookahead and stack 0xaaaaec95e080->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0, 0xaaaaec95e030, 0xaaaaec95e080 } 0xaaaaec95e030->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0, 0xaaaaec95e030 } 0xaaaaec95dfe0->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0 } 0xaaaaec95df90->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90 } 0xaaaaec95df40->Object::~Object { 0xaaaaec95df40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1065: $PREPARSER ./input < in stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaec95df40->Object::Object { } Next token is token 'a' (0xaaaaec95df40 'a') Shifting token 'a' (0xaaaaec95df40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaec95df40 'a') -> $$ = nterm item (0xaaaaec95df40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaaec95df90->Object::Object { 0xaaaaec95df40 } Next token is token 'a' (0xaaaaec95df90 'a') Shifting token 'a' (0xaaaaec95df90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaec95df90 'a') -> $$ = nterm item (0xaaaaec95df90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaaec95dfe0->Object::Object { 0xaaaaec95df40, 0xaaaaec95df90 } Next token is token 'a' (0xaaaaec95dfe0 'a') Shifting token 'a' (0xaaaaec95dfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaec95dfe0 'a') -> $$ = nterm item (0xaaaaec95dfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaaec95e030->Object::Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0 } Next token is token 'a' (0xaaaaec95e030 'a') Shifting token 'a' (0xaaaaec95e030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaec95e030 'a') -> $$ = nterm item (0xaaaaec95e030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaaec95e080->Object::Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0, 0xaaaaec95e030 } Next token is token 'p' (0xaaaaec95e080 'p'Exception caught: cleaning lookahead and stack 0xaaaaec95e080->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0, 0xaaaaec95e030, 0xaaaaec95e080 } 0xaaaaec95e030->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0, 0xaaaaec95e030 } 0xaaaaec95dfe0->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0 } 0xaaaaec95df90->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90 } 0xaaaaec95df40->Object::~Object { 0xaaaaec95df40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: exception caught: printer ./c++.at:1361: $PREPARSER ./input aaaae stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:1065: $PREPARSER ./input < in exception caught: syntax error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: invalid expression ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in ./c++.at:1361: $PREPARSER ./input aaaaT stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaR stderr: ======== Testing with C++ standard flags: '' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:850: $PREPARSER ./input stderr: ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:851: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ======== Testing with C++ standard flags: '' ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: stderr: stdout: stderr: ./c++.at:1501: $CXX $CPPFLAGS $CXXFLAGS -Iinclude $LDFLAGS -o parser x[12].o main.cc $LIBS stdout: error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in ./c++.at:1362: $PREPARSER ./input aaaal stderr: stderr: stderr: stdout: exception caught: yylex ======== Testing with C++ standard flags: '' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: ./c++.at:1362: $PREPARSER ./input aaaap stdout: ./c++.at:941: $PREPARSER ./input stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffffcd63500->Object::Object { } 0xfffffcd635e0->Object::Object { 0xfffffcd63500 } 0xfffffcd63500->Object::~Object { 0xfffffcd63500, 0xfffffcd635e0 } Next token is token 'a' (0xfffffcd635e0 'a') 0xfffffcd63540->Object::Object { 0xfffffcd635e0 } 0xfffffcd634f0->Object::Object { 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd634f0->Object::~Object { 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd635e0->Object::~Object { 0xfffffcd63540, 0xfffffcd635e0 } Shifting token 'a' (0xfffffcd63540 'a') 0xaaaae725b2e0->Object::Object { 0xfffffcd63540 } 0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xfffffcd63540 } 0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xfffffcd634c8, 0xfffffcd63540 } 0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63540 } Entering state 2 Stack now 0 2 0xfffffcd63600->Object::Object { 0xaaaae725b2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae725b2e0 'a') -> $$ = nterm item (0xfffffcd63600 'a') 0xaaaae725b2e0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63600 } 0xaaaae725b2e0->Object::Object { 0xfffffcd63600 } 0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xfffffcd63600 } 0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd635b0, 0xfffffcd63600 } 0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63600 } Entering state 11 Stack now 0 11 Reading a token 0xfffffcd63500->Object::Object { 0xaaaae725b2e0 } 0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xfffffcd63500 } 0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63500, 0xfffffcd635e0 } Next token is token 'a' (0xfffffcd635e0 'a') 0xfffffcd63540->Object::Object { 0xaaaae725b2e0, 0xfffffcd635e0 } 0xfffffcd634f0->Object::Object { 0xaaaae725b2e0, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd634f0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd635e0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63540, 0xfffffcd635e0 } Shifting token 'a' (0xfffffcd63540 'a') 0xaaaae725b300->Object::Object { 0xaaaae725b2e0, 0xfffffcd63540 } 0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540 } 0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd634c8, 0xfffffcd63540 } 0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540 } Entering state 2 Stack now 0 11 2 0xfffffcd63600->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae725b300 'a') -> $$ = nterm item (0xfffffcd63600 'a') 0xaaaae725b300->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } 0xaaaae725b300->Object::Object { 0xaaaae725b2e0, 0xfffffcd63600 } 0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } 0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd635b0, 0xfffffcd63600 } 0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } Entering state 11 Stack now 0 11 11 Reading a token 0xfffffcd63500->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300 } 0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63500 } 0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63500, 0xfffffcd635e0 } Next token is token 'a' (0xfffffcd635e0 'a') 0xfffffcd63540->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd635e0 } 0xfffffcd634f0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd634f0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd635e0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540, 0xfffffcd635e0 } Shifting token 'a' (0xfffffcd63540 'a') 0xaaaae725b320->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540 } 0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540 } 0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd634c8, 0xfffffcd63540 } 0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540 } Entering state 2 Stack now 0 11 11 2 0xfffffcd63600->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae725b320 'a') -> $$ = nterm item (0xfffffcd63600 'a') 0xaaaae725b320->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } 0xaaaae725b320->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } 0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } 0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd635b0, 0xfffffcd63600 } 0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xfffffcd63500->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320 } 0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63500 } 0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63500, 0xfffffcd635e0 } Next token is token 'a' (0xfffffcd635e0 'a') 0xfffffcd63540->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd635e0 } 0xfffffcd634f0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd634f0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd635e0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540, 0xfffffcd635e0 } Shifting token 'a' (0xfffffcd63540 'a') 0xaaaae725b340->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540 } 0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63540 } 0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd634c8, 0xfffffcd63540 } 0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63540 } Entering state 2 Stack now 0 11 11 11 2 0xfffffcd63600->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae725b340 'a') -> $$ = nterm item (0xfffffcd63600 'a') 0xaaaae725b340->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63600 } 0xaaaae725b340->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } 0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63600 } 0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd635b0, 0xfffffcd63600 } 0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63600 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xfffffcd63500->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340 } 0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63500 } 0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63500, 0xfffffcd635e0 } Next token is token 'p' (0xfffffcd635e0 'p'Exception caught: cleaning lookahead and stack 0xaaaae725b340->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd635e0 } 0xaaaae725b320->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd635e0 } 0xaaaae725b300->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd635e0 } 0xaaaae725b2e0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd635e0 } 0xfffffcd635e0->Object::~Object { 0xfffffcd635e0 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffffcd63500->Object::Object { } 0xfffffcd635e0->Object::Object { 0xfffffcd63500 } 0xfffffcd63500->Object::~Object { 0xfffffcd63500, 0xfffffcd635e0 } Next token is token 'a' (0xfffffcd635e0 'a') 0xfffffcd63540->Object::Object { 0xfffffcd635e0 } 0xfffffcd634f0->Object::Object { 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd634f0->Object::~Object { 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd635e0->Object::~Object { 0xfffffcd63540, 0xfffffcd635e0 } Shifting token 'a' (0xfffffcd63540 'a') 0xaaaae725b2e0->Object::Object { 0xfffffcd63540 } 0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xfffffcd63540 } 0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xfffffcd634c8, 0xfffffcd63540 } 0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63540 } Entering state 2 Stack now 0 2 0xfffffcd63600->Object::Object { 0xaaaae725b2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae725b2e0 'a') -> $$ = nterm item (0xfffffcd63600 'a') 0xaaaae725b2e0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63600 } 0xaaaae725b2e0->Object::Object { 0xfffffcd63600 } 0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xfffffcd63600 } 0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd635b0, 0xfffffcd63600 } 0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63600 } Entering state 11 Stack now 0 11 Reading a token 0xfffffcd63500->Object::Object { 0xaaaae725b2e0 } 0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xfffffcd63500 } 0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63500, 0xfffffcd635e0 } Next token is token 'a' (0xfffffcd635e0 'a') 0xfffffcd63540->Object::Object { 0xaaaae725b2e0, 0xfffffcd635e0 } 0xfffffcd634f0->Object::Object { 0xaaaae725b2e0, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd634f0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd635e0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63540, 0xfffffcd635e0 } Shifting token 'a' (0xfffffcd63540 'a') 0xaaaae725b300->Object::Object { 0xaaaae725b2e0, 0xfffffcd63540 } 0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540 } 0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd634c8, 0xfffffcd63540 } 0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540 } Entering state 2 Stack now 0 11 2 0xfffffcd63600->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae725b300 'a') -> $$ = nterm item (0xfffffcd63600 'a') 0xaaaae725b300->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } 0xaaaae725b300->Object::Object { 0xaaaae725b2e0, 0xfffffcd63600 } 0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } 0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd635b0, 0xfffffcd63600 } 0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } Entering state 11 Stack now 0 11 11 Reading a token 0xfffffcd63500->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300 } 0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63500 } 0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63500, 0xfffffcd635e0 } Next token is token 'a' (0xfffffcd635e0 'a') 0xfffffcd63540->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd635e0 } 0xfffffcd634f0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd634f0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd635e0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540, 0xfffffcd635e0 } Shifting token 'a' (0xfffffcd63540 'a') 0xaaaae725b320->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540 } 0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540 } 0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd634c8, 0xfffffcd63540 } 0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540 } Entering state 2 Stack now 0 11 11 2 0xfffffcd63600->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae725b320 'a') -> $$ = nterm item (0xfffffcd63600 'a') 0xaaaae725b320->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } 0xaaaae725b320->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } 0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } 0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd635b0, 0xfffffcd63600 } 0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xfffffcd63500->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320 } 0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63500 } 0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63500, 0xfffffcd635e0 } Next token is token 'a' (0xfffffcd635e0 'a') 0xfffffcd63540->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd635e0 } 0xfffffcd634f0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd634f0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } 0xfffffcd635e0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540, 0xfffffcd635e0 } Shifting token 'a' (0xfffffcd63540 'a') 0xaaaae725b340->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540 } 0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63540 } 0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd634c8, 0xfffffcd63540 } 0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63540 } Entering state 2 Stack now 0 11 11 11 2 0xfffffcd63600->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae725b340 'a') -> $$ = nterm item (0xfffffcd63600 'a') 0xaaaae725b340->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63600 } 0xaaaae725b340->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } 0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63600 } 0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd635b0, 0xfffffcd63600 } 0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63600 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xfffffcd63500->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340 } 0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63500 } 0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63500, 0xfffffcd635e0 } Next token is token 'p' (0xfffffcd635e0 'p'Exception caught: cleaning lookahead and stack 0xaaaae725b340->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd635e0 } 0xaaaae725b320->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd635e0 } 0xaaaae725b300->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd635e0 } 0xaaaae725b2e0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd635e0 } 0xfffffcd635e0->Object::~Object { 0xfffffcd635e0 } exception caught: printer end { } ./c++.at:1362: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1363: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaT stderr: ./c++.at:1363: $PREPARSER ./input aaaal ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaR stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input i stderr: exception caught: initial-action ======== Testing with C++ standard flags: '' ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1363: $PREPARSER ./input aaaap stderr: stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1360: $PREPARSER ./input aaaas ./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: stderr: exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffcb68b7a0->Object::Object { } 0xffffcb68b880->Object::Object { 0xffffcb68b7a0 } 0xffffcb68b7a0->Object::~Object { 0xffffcb68b7a0, 0xffffcb68b880 } Next token is token 'a' (0xffffcb68b880 'a') 0xffffcb68b7e0->Object::Object { 0xffffcb68b880 } 0xffffcb68b790->Object::Object { 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b790->Object::~Object { 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b880->Object::~Object { 0xffffcb68b7e0, 0xffffcb68b880 } Shifting token 'a' (0xffffcb68b7e0 'a') 0xaaaaf501a2e0->Object::Object { 0xffffcb68b7e0 } 0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7e0 } 0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b768, 0xffffcb68b7e0 } 0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b7e0 } Entering state 1 Stack now 0 1 0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf501a2e0 'a') -> $$ = nterm item (0xffffcb68b8a0 'a') 0xaaaaf501a2e0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } 0xaaaaf501a2e0->Object::Object { 0xffffcb68b8a0 } 0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } 0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b850, 0xffffcb68b8a0 } 0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } Entering state 10 Stack now 0 10 Reading a token 0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0 } 0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7a0 } 0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b7a0, 0xffffcb68b880 } Next token is token 'a' (0xffffcb68b880 'a') 0xffffcb68b7e0->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b880 } 0xffffcb68b790->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b790->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b880->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b7e0, 0xffffcb68b880 } Shifting token 'a' (0xffffcb68b7e0 'a') 0xaaaaf501a300->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7e0 } 0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0 } 0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b768, 0xffffcb68b7e0 } 0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0 } Entering state 1 Stack now 0 10 1 0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf501a300 'a') -> $$ = nterm item (0xffffcb68b8a0 'a') 0xaaaaf501a300->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } 0xaaaaf501a300->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } 0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } 0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b850, 0xffffcb68b8a0 } 0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300 } 0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7a0 } 0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7a0, 0xffffcb68b880 } Next token is token 'a' (0xffffcb68b880 'a') 0xffffcb68b7e0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b880 } 0xffffcb68b790->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b790->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b880->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0, 0xffffcb68b880 } Shifting token 'a' (0xffffcb68b7e0 'a') 0xaaaaf501a320->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0 } 0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0 } 0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b768, 0xffffcb68b7e0 } 0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0 } Entering state 1 Stack now 0 10 10 1 0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf501a320 'a') -> $$ = nterm item (0xffffcb68b8a0 'a') 0xaaaaf501a320->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } 0xaaaaf501a320->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } 0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } 0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b850, 0xffffcb68b8a0 } 0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320 } 0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7a0 } 0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7a0, 0xffffcb68b880 } Next token is token 'a' (0xffffcb68b880 'a') 0xffffcb68b7e0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b880 } 0xffffcb68b790->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b790->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b880->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0, 0xffffcb68b880 } Shifting token 'a' (0xffffcb68b7e0 'a') 0xaaaaf501a340->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0 } 0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7e0 } 0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b768, 0xffffcb68b7e0 } 0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7e0 } Entering state 1 Stack now 0 10 10 10 1 0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf501a340 'a') -> $$ = nterm item (0xffffcb68b8a0 'a') 0xaaaaf501a340->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b8a0 } 0xaaaaf501a340->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } 0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b8a0 } 0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b850, 0xffffcb68b8a0 } 0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b8a0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340 } 0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7a0 } 0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7a0, 0xffffcb68b880 } Next token is token 'p' (0xffffcb68b880 'p'Exception caught: cleaning lookahead and stack 0xaaaaf501a340->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b880 } 0xaaaaf501a320->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b880 } 0xaaaaf501a300->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b880 } 0xaaaaf501a2e0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b880 } 0xffffcb68b880->Object::~Object { 0xffffcb68b880 } exception caught: printer end { } stdout: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1502: $PREPARSER ./parser ./c++.at:1360: $PREPARSER ./input aaaal stderr: stderr: stderr: ./c++.at:1502: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: yylex ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 690. c++.at:1422: ok stdout: ./c++.at:1066: $PREPARSER ./input < in stderr: stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token 0xffffcb68b7a0->Object::Object { } 0xffffcb68b880->Object::Object { 0xffffcb68b7a0 } 0xffffcb68b7a0->Object::~Object { 0xffffcb68b7a0, 0xffffcb68b880 } Next token is token 'a' (0xffffcb68b880 'a') 0xffffcb68b7e0->Object::Object { 0xffffcb68b880 } 0xffffcb68b790->Object::Object { 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b790->Object::~Object { 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b880->Object::~Object { 0xffffcb68b7e0, 0xffffcb68b880 } Shifting token 'a' (0xffffcb68b7e0 'a') 0xaaaaf501a2e0->Object::Object { 0xffffcb68b7e0 } 0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7e0 } 0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b768, 0xffffcb68b7e0 } 0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b7e0 } Entering state 1 Stack now 0 1 0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf501a2e0 'a') -> $$ = nterm item (0xffffcb68b8a0 'a') 0xaaaaf501a2e0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } 0xaaaaf501a2e0->Object::Object { 0xffffcb68b8a0 } 0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } 0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b850, 0xffffcb68b8a0 } 0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } Entering state 10 Stack now 0 10 Reading a token 0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0 } 0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7a0 } 0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b7a0, 0xffffcb68b880 } Next token is token 'a' (0xffffcb68b880 'a') 0xffffcb68b7e0->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b880 } 0xffffcb68b790->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b790->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b880->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b7e0, 0xffffcb68b880 } Shifting token 'a' (0xffffcb68b7e0 'a') 0xaaaaf501a300->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7e0 } 0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0 } 0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b768, 0xffffcb68b7e0 } 0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0 } Entering state 1 Stack now 0 10 1 0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf501a300 'a') -> $$ = nterm item (0xffffcb68b8a0 'a') 0xaaaaf501a300->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } 0xaaaaf501a300->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } 0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } 0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b850, 0xffffcb68b8a0 } 0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300 } 0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7a0 } 0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7a0, 0xffffcb68b880 } Next token is token 'a' (0xffffcb68b880 'a') 0xffffcb68b7e0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b880 } 0xffffcb68b790->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b790->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b880->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0, 0xffffcb68b880 } Shifting token 'a' (0xffffcb68b7e0 'a') 0xaaaaf501a320->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0 } 0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0 } 0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b768, 0xffffcb68b7e0 } 0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0 } Entering state 1 Stack now 0 10 10 1 0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf501a320 'a') -> $$ = nterm item (0xffffcb68b8a0 'a') 0xaaaaf501a320->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } 0xaaaaf501a320->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } 0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } 0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b850, 0xffffcb68b8a0 } 0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320 } 0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7a0 } 0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7a0, 0xffffcb68b880 } Next token is token 'a' (0xffffcb68b880 'a') 0xffffcb68b7e0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b880 } 0xffffcb68b790->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b790->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } 0xffffcb68b880->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0, 0xffffcb68b880 } Shifting token 'a' (0xffffcb68b7e0 'a') 0xaaaaf501a340->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0 } 0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7e0 } 0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b768, 0xffffcb68b7e0 } 0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7e0 } Entering state 1 Stack now 0 10 10 10 1 0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf501a340 'a') -> $$ = nterm item (0xffffcb68b8a0 'a') 0xaaaaf501a340->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b8a0 } 0xaaaaf501a340->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } 0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b8a0 } 0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b850, 0xffffcb68b8a0 } 0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b8a0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340 } 0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7a0 } 0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7a0, 0xffffcb68b880 } Next token is token 'p' (0xffffcb68b880 'p'Exception caught: cleaning lookahead and stack 0xaaaaf501a340->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b880 } 0xaaaaf501a320->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b880 } 0xaaaaf501a300->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b880 } 0xaaaaf501a2e0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b880 } 0xffffcb68b880->Object::~Object { 0xffffcb68b880 } exception caught: printer end { } ./c++.at:1363: grep '^exception caught: printer$' stderr ./c++.at:1066: $PREPARSER ./input < in ./c++.at:1360: $PREPARSER ./input i stderr: stdout: stderr: exception caught: initial-action exception caught: printer error: invalid expression ./c++.at:1363: $PREPARSER ./input aaaae ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $PREPARSER ./input < in ./c++.at:1363: $PREPARSER ./input aaaaE ./c++.at:1360: $PREPARSER ./input aaaap stderr: stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: invalid character ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 691. c++.at:1517: testing Default action ... stderr: ======== Testing with C++ standard flags: '' ./c++.at:1363: $PREPARSER ./input aaaaT ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input --debug aaaap stderr: ./c++.at:1363: $PREPARSER ./input aaaaR stdout: stderr: ./c++.at:856: $PREPARSER ./input ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaadffc9f40->Object::Object { } Next token is token 'a' (0xaaaadffc9f40 'a') Shifting token 'a' (0xaaaadffc9f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadffc9f40 'a') -> $$ = nterm item (0xaaaadffc9f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaadffc9f90->Object::Object { 0xaaaadffc9f40 } Next token is token 'a' (0xaaaadffc9f90 'a') Shifting token 'a' (0xaaaadffc9f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadffc9f90 'a') -> $$ = nterm item (0xaaaadffc9f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaadffc9fe0->Object::Object { 0xaaaadffc9f40, 0xaaaadffc9f90 } Next token is token 'a' (0xaaaadffc9fe0 'a') Shifting token 'a' (0xaaaadffc9fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadffc9fe0 'a') -> $$ = nterm item (0xaaaadffc9fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaadffca030->Object::Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0 } Next token is token 'a' (0xaaaadffca030 'a') Shifting token 'a' (0xaaaadffca030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadffca030 'a') -> $$ = nterm item (0xaaaadffca030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaadffca080->Object::Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0, 0xaaaadffca030 } Next token is token 'p' (0xaaaadffca080 'p'Exception caught: cleaning lookahead and stack 0xaaaadffca080->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0, 0xaaaadffca030, 0xaaaadffca080 } 0xaaaadffca030->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0, 0xaaaadffca030 } 0xaaaadffc9fe0->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0 } 0xaaaadffc9f90->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90 } 0xaaaadffc9f40->Object::~Object { 0xaaaadffc9f40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:857: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaadffc9f40->Object::Object { } Next token is token 'a' (0xaaaadffc9f40 'a') Shifting token 'a' (0xaaaadffc9f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadffc9f40 'a') -> $$ = nterm item (0xaaaadffc9f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaadffc9f90->Object::Object { 0xaaaadffc9f40 } Next token is token 'a' (0xaaaadffc9f90 'a') Shifting token 'a' (0xaaaadffc9f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadffc9f90 'a') -> $$ = nterm item (0xaaaadffc9f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaadffc9fe0->Object::Object { 0xaaaadffc9f40, 0xaaaadffc9f90 } Next token is token 'a' (0xaaaadffc9fe0 'a') Shifting token 'a' (0xaaaadffc9fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadffc9fe0 'a') -> $$ = nterm item (0xaaaadffc9fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaadffca030->Object::Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0 } Next token is token 'a' (0xaaaadffca030 'a') Shifting token 'a' (0xaaaadffca030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadffca030 'a') -> $$ = nterm item (0xaaaadffca030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaadffca080->Object::Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0, 0xaaaadffca030 } Next token is token 'p' (0xaaaadffca080 'p'Exception caught: cleaning lookahead and stack 0xaaaadffca080->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0, 0xaaaadffca030, 0xaaaadffca080 } 0xaaaadffca030->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0, 0xaaaadffca030 } 0xaaaadffc9fe0->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0 } 0xaaaadffc9f90->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90 } 0xaaaadffc9f40->Object::~Object { 0xaaaadffc9f40 } exception caught: printer end { } ./c++.at:1360: grep '^exception caught: printer$' stderr stdout: ======== Testing with C++ standard flags: '' ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae stderr: stdout: ./c++.at:1066: ./check ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1555: ./check ./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y ./c++.at:1360: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaT ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: ./c++.at:851: $PREPARSER ./input ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1360: $PREPARSER ./input aaaaR ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1361: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input i stderr: stderr: exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1065: $PREPARSER ./input < in ./c++.at:1361: $PREPARSER ./input aaaap stderr: stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaf6b83f40->Object::Object { } Next token is token 'a' (0xaaaaf6b83f40 'a') Shifting token 'a' (0xaaaaf6b83f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf6b83f40 'a') -> $$ = nterm item (0xaaaaf6b83f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaaf6b83f90->Object::Object { 0xaaaaf6b83f40 } Next token is token 'a' (0xaaaaf6b83f90 'a') Shifting token 'a' (0xaaaaf6b83f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf6b83f90 'a') -> $$ = nterm item (0xaaaaf6b83f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaaf6b83fe0->Object::Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90 } Next token is token 'a' (0xaaaaf6b83fe0 'a') Shifting token 'a' (0xaaaaf6b83fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf6b83fe0 'a') -> $$ = nterm item (0xaaaaf6b83fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaaf6b84030->Object::Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0 } Next token is token 'a' (0xaaaaf6b84030 'a') Shifting token 'a' (0xaaaaf6b84030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf6b84030 'a') -> $$ = nterm item (0xaaaaf6b84030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaaf6b84080->Object::Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0, 0xaaaaf6b84030 } Next token is token 'p' (0xaaaaf6b84080 'p'Exception caught: cleaning lookahead and stack 0xaaaaf6b84080->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0, 0xaaaaf6b84030, 0xaaaaf6b84080 } 0xaaaaf6b84030->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0, 0xaaaaf6b84030 } 0xaaaaf6b83fe0->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0 } 0xaaaaf6b83f90->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90 } 0xaaaaf6b83f40->Object::~Object { 0xaaaaf6b83f40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaf6b83f40->Object::Object { } Next token is token 'a' (0xaaaaf6b83f40 'a') Shifting token 'a' (0xaaaaf6b83f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf6b83f40 'a') -> $$ = nterm item (0xaaaaf6b83f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaaf6b83f90->Object::Object { 0xaaaaf6b83f40 } Next token is token 'a' (0xaaaaf6b83f90 'a') Shifting token 'a' (0xaaaaf6b83f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf6b83f90 'a') -> $$ = nterm item (0xaaaaf6b83f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaaf6b83fe0->Object::Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90 } Next token is token 'a' (0xaaaaf6b83fe0 'a') Shifting token 'a' (0xaaaaf6b83fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf6b83fe0 'a') -> $$ = nterm item (0xaaaaf6b83fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaaf6b84030->Object::Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0 } Next token is token 'a' (0xaaaaf6b84030 'a') Shifting token 'a' (0xaaaaf6b84030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf6b84030 'a') -> $$ = nterm item (0xaaaaf6b84030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaaf6b84080->Object::Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0, 0xaaaaf6b84030 } Next token is token 'p' (0xaaaaf6b84080 'p'Exception caught: cleaning lookahead and stack 0xaaaaf6b84080->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0, 0xaaaaf6b84030, 0xaaaaf6b84080 } 0xaaaaf6b84030->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0, 0xaaaaf6b84030 } 0xaaaaf6b83fe0->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0 } 0xaaaaf6b83f90->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90 } 0xaaaaf6b83f40->Object::~Object { 0xaaaaf6b83f40 } exception caught: printer end { } error: invalid expression ./c++.at:1361: grep '^exception caught: printer$' stderr ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: exception caught: printer ./c++.at:1361: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ./c++.at:1361: $PREPARSER ./input aaaaT stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaR stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:857: $PREPARSER ./input stderr: ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:851: $PREPARSER ./input stderr: ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:941: $PREPARSER ./input stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1555: $PREPARSER ./test stderr: ./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./c++.at:1362: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaap stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffff6539bc0->Object::Object { } 0xfffff6539ca0->Object::Object { 0xfffff6539bc0 } 0xfffff6539bc0->Object::~Object { 0xfffff6539bc0, 0xfffff6539ca0 } Next token is token 'a' (0xfffff6539ca0 'a') 0xfffff6539c00->Object::Object { 0xfffff6539ca0 } 0xfffff6539bb0->Object::Object { 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539bb0->Object::~Object { 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539ca0->Object::~Object { 0xfffff6539c00, 0xfffff6539ca0 } Shifting token 'a' (0xfffff6539c00 'a') 0xaaaaf4b662e0->Object::Object { 0xfffff6539c00 } 0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xfffff6539c00 } 0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539b88, 0xfffff6539c00 } 0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539c00 } Entering state 2 Stack now 0 2 0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf4b662e0 'a') -> $$ = nterm item (0xfffff6539cc0 'a') 0xaaaaf4b662e0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } 0xaaaaf4b662e0->Object::Object { 0xfffff6539cc0 } 0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } 0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539c70, 0xfffff6539cc0 } 0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } Entering state 11 Stack now 0 11 Reading a token 0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0 } 0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xfffff6539bc0 } 0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539bc0, 0xfffff6539ca0 } Next token is token 'a' (0xfffff6539ca0 'a') 0xfffff6539c00->Object::Object { 0xaaaaf4b662e0, 0xfffff6539ca0 } 0xfffff6539bb0->Object::Object { 0xaaaaf4b662e0, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539bb0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539ca0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539c00, 0xfffff6539ca0 } Shifting token 'a' (0xfffff6539c00 'a') 0xaaaaf4b66300->Object::Object { 0xaaaaf4b662e0, 0xfffff6539c00 } 0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00 } 0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539b88, 0xfffff6539c00 } 0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00 } Entering state 2 Stack now 0 11 2 0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf4b66300 'a') -> $$ = nterm item (0xfffff6539cc0 'a') 0xaaaaf4b66300->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } 0xaaaaf4b66300->Object::Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } 0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } 0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c70, 0xfffff6539cc0 } 0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } Entering state 11 Stack now 0 11 11 Reading a token 0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300 } 0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539bc0 } 0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539bc0, 0xfffff6539ca0 } Next token is token 'a' (0xfffff6539ca0 'a') 0xfffff6539c00->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539ca0 } 0xfffff6539bb0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539bb0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539ca0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00, 0xfffff6539ca0 } Shifting token 'a' (0xfffff6539c00 'a') 0xaaaaf4b66320->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00 } 0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00 } 0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539b88, 0xfffff6539c00 } 0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00 } Entering state 2 Stack now 0 11 11 2 0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf4b66320 'a') -> $$ = nterm item (0xfffff6539cc0 'a') 0xaaaaf4b66320->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } 0xaaaaf4b66320->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } 0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } 0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c70, 0xfffff6539cc0 } 0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320 } 0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539bc0 } 0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539bc0, 0xfffff6539ca0 } Next token is token 'a' (0xfffff6539ca0 'a') 0xfffff6539c00->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539ca0 } 0xfffff6539bb0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539bb0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539ca0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00, 0xfffff6539ca0 } Shifting token 'a' (0xfffff6539c00 'a') 0xaaaaf4b66340->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00 } 0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539c00 } 0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539b88, 0xfffff6539c00 } 0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539c00 } Entering state 2 Stack now 0 11 11 11 2 0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf4b66340 'a') -> $$ = nterm item (0xfffff6539cc0 'a') 0xaaaaf4b66340->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539cc0 } 0xaaaaf4b66340->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } 0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539cc0 } 0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539c70, 0xfffff6539cc0 } 0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539cc0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340 } 0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539bc0 } 0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539bc0, 0xfffff6539ca0 } Next token is token 'p' (0xfffff6539ca0 'p'Exception caught: cleaning lookahead and stack 0xaaaaf4b66340->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539ca0 } 0xaaaaf4b66320->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539ca0 } 0xaaaaf4b66300->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539ca0 } 0xaaaaf4b662e0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539ca0 } 0xfffff6539ca0->Object::~Object { 0xfffff6539ca0 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffff6539bc0->Object::Object { } 0xfffff6539ca0->Object::Object { 0xfffff6539bc0 } 0xfffff6539bc0->Object::~Object { 0xfffff6539bc0, 0xfffff6539ca0 } Next token is token 'a' (0xfffff6539ca0 'a') 0xfffff6539c00->Object::Object { 0xfffff6539ca0 } 0xfffff6539bb0->Object::Object { 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539bb0->Object::~Object { 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539ca0->Object::~Object { 0xfffff6539c00, 0xfffff6539ca0 } Shifting token 'a' (0xfffff6539c00 'a') 0xaaaaf4b662e0->Object::Object { 0xfffff6539c00 } 0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xfffff6539c00 } 0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539b88, 0xfffff6539c00 } 0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539c00 } Entering state 2 Stack now 0 2 0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf4b662e0 'a') -> $$ = nterm item (0xfffff6539cc0 'a') 0xaaaaf4b662e0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } 0xaaaaf4b662e0->Object::Object { 0xfffff6539cc0 } 0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } 0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539c70, 0xfffff6539cc0 } 0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } Entering state 11 Stack now 0 11 Reading a token 0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0 } 0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xfffff6539bc0 } 0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539bc0, 0xfffff6539ca0 } Next token is token 'a' (0xfffff6539ca0 'a') 0xfffff6539c00->Object::Object { 0xaaaaf4b662e0, 0xfffff6539ca0 } 0xfffff6539bb0->Object::Object { 0xaaaaf4b662e0, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539bb0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539ca0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539c00, 0xfffff6539ca0 } Shifting token 'a' (0xfffff6539c00 'a') 0xaaaaf4b66300->Object::Object { 0xaaaaf4b662e0, 0xfffff6539c00 } 0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00 } 0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539b88, 0xfffff6539c00 } 0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00 } Entering state 2 Stack now 0 11 2 0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf4b66300 'a') -> $$ = nterm item (0xfffff6539cc0 'a') 0xaaaaf4b66300->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } 0xaaaaf4b66300->Object::Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } 0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } 0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c70, 0xfffff6539cc0 } 0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } Entering state 11 Stack now 0 11 11 Reading a token 0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300 } 0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539bc0 } 0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539bc0, 0xfffff6539ca0 } Next token is token 'a' (0xfffff6539ca0 'a') 0xfffff6539c00->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539ca0 } 0xfffff6539bb0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539bb0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539ca0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00, 0xfffff6539ca0 } Shifting token 'a' (0xfffff6539c00 'a') 0xaaaaf4b66320->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00 } 0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00 } 0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539b88, 0xfffff6539c00 } 0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00 } Entering state 2 Stack now 0 11 11 2 0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf4b66320 'a') -> $$ = nterm item (0xfffff6539cc0 'a') 0xaaaaf4b66320->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } 0xaaaaf4b66320->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } 0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } 0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c70, 0xfffff6539cc0 } 0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320 } 0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539bc0 } 0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539bc0, 0xfffff6539ca0 } Next token is token 'a' (0xfffff6539ca0 'a') 0xfffff6539c00->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539ca0 } 0xfffff6539bb0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539bb0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } 0xfffff6539ca0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00, 0xfffff6539ca0 } Shifting token 'a' (0xfffff6539c00 'a') 0xaaaaf4b66340->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00 } 0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539c00 } 0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539b88, 0xfffff6539c00 } 0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539c00 } Entering state 2 Stack now 0 11 11 11 2 0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf4b66340 'a') -> $$ = nterm item (0xfffff6539cc0 'a') 0xaaaaf4b66340->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539cc0 } 0xaaaaf4b66340->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } 0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539cc0 } 0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539c70, 0xfffff6539cc0 } 0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539cc0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340 } 0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539bc0 } 0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539bc0, 0xfffff6539ca0 } Next token is token 'p' (0xfffff6539ca0 'p'Exception caught: cleaning lookahead and stack 0xaaaaf4b66340->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539ca0 } 0xaaaaf4b66320->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539ca0 } 0xaaaaf4b66300->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539ca0 } 0xaaaaf4b662e0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539ca0 } 0xfffff6539ca0->Object::~Object { 0xfffff6539ca0 } exception caught: printer end { } ./c++.at:1362: grep '^exception caught: printer$' stderr stdout: stdout: exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae stderr: ./c++.at:1555: ./check exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -std=c++98 not supported ======== Testing with C++ standard flags: '' ./c++.at:1362: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaT ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaR stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1363: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaap stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1363: $PREPARSER ./input --debug aaaap ./c++.at:1360: $PREPARSER ./input aaaas stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc989b1b0->Object::Object { } 0xffffc989b290->Object::Object { 0xffffc989b1b0 } 0xffffc989b1b0->Object::~Object { 0xffffc989b1b0, 0xffffc989b290 } Next token is token 'a' (0xffffc989b290 'a') 0xffffc989b1f0->Object::Object { 0xffffc989b290 } 0xffffc989b1a0->Object::Object { 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b1a0->Object::~Object { 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b290->Object::~Object { 0xffffc989b1f0, 0xffffc989b290 } Shifting token 'a' (0xffffc989b1f0 'a') 0xaaab093cb2e0->Object::Object { 0xffffc989b1f0 } 0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xffffc989b1f0 } 0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xffffc989b178, 0xffffc989b1f0 } 0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1f0 } Entering state 1 Stack now 0 1 0xffffc989b2b0->Object::Object { 0xaaab093cb2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab093cb2e0 'a') -> $$ = nterm item (0xffffc989b2b0 'a') 0xaaab093cb2e0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b2b0 } 0xaaab093cb2e0->Object::Object { 0xffffc989b2b0 } 0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xffffc989b2b0 } 0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xffffc989b260, 0xffffc989b2b0 } 0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b2b0 } Entering state 10 Stack now 0 10 Reading a token 0xffffc989b1b0->Object::Object { 0xaaab093cb2e0 } 0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xffffc989b1b0 } 0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1b0, 0xffffc989b290 } Next token is token 'a' (0xffffc989b290 'a') 0xffffc989b1f0->Object::Object { 0xaaab093cb2e0, 0xffffc989b290 } 0xffffc989b1a0->Object::Object { 0xaaab093cb2e0, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b1a0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b290->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1f0, 0xffffc989b290 } Shifting token 'a' (0xffffc989b1f0 'a') 0xaaab093cb300->Object::Object { 0xaaab093cb2e0, 0xffffc989b1f0 } 0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0 } 0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b178, 0xffffc989b1f0 } 0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0 } Entering state 1 Stack now 0 10 1 0xffffc989b2b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab093cb300 'a') -> $$ = nterm item (0xffffc989b2b0 'a') 0xaaab093cb300->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } 0xaaab093cb300->Object::Object { 0xaaab093cb2e0, 0xffffc989b2b0 } 0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } 0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b260, 0xffffc989b2b0 } 0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffc989b1b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300 } 0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1b0 } 0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1b0, 0xffffc989b290 } Next token is token 'a' (0xffffc989b290 'a') 0xffffc989b1f0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b290 } 0xffffc989b1a0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b1a0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b290->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0, 0xffffc989b290 } Shifting token 'a' (0xffffc989b1f0 'a') 0xaaab093cb320->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0 } 0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0 } 0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b178, 0xffffc989b1f0 } 0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0 } Entering state 1 Stack now 0 10 10 1 0xffffc989b2b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab093cb320 'a') -> $$ = nterm item (0xffffc989b2b0 'a') 0xaaab093cb320->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } 0xaaab093cb320->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } 0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } 0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b260, 0xffffc989b2b0 } 0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffc989b1b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320 } 0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1b0 } 0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1b0, 0xffffc989b290 } Next token is token 'a' (0xffffc989b290 'a') 0xffffc989b1f0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b290 } 0xffffc989b1a0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b1a0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b290->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0, 0xffffc989b290 } Shifting token 'a' (0xffffc989b1f0 'a') 0xaaab093cb340->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0 } 0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1f0 } 0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b178, 0xffffc989b1f0 } 0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1f0 } Entering state 1 Stack now 0 10 10 10 1 0xffffc989b2b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab093cb340 'a') -> $$ = nterm item (0xffffc989b2b0 'a') 0xaaab093cb340->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b2b0 } 0xaaab093cb340->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } 0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b2b0 } 0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b260, 0xffffc989b2b0 } 0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b2b0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffc989b1b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340 } 0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1b0 } 0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1b0, 0xffffc989b290 } Next token is token 'p' (0xffffc989b290 'p'Exception caught: cleaning lookahead and stack 0xaaab093cb340->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b290 } 0xaaab093cb320->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b290 } 0xaaab093cb300->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b290 } 0xaaab093cb2e0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b290 } 0xffffc989b290->Object::~Object { 0xffffc989b290 } exception caught: printer end { } ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc989b1b0->Object::Object { } 0xffffc989b290->Object::Object { 0xffffc989b1b0 } 0xffffc989b1b0->Object::~Object { 0xffffc989b1b0, 0xffffc989b290 } Next token is token 'a' (0xffffc989b290 'a') 0xffffc989b1f0->Object::Object { 0xffffc989b290 } 0xffffc989b1a0->Object::Object { 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b1a0->Object::~Object { 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b290->Object::~Object { 0xffffc989b1f0, 0xffffc989b290 } Shifting token 'a' (0xffffc989b1f0 'a') 0xaaab093cb2e0->Object::Object { 0xffffc989b1f0 } 0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xffffc989b1f0 } 0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xffffc989b178, 0xffffc989b1f0 } 0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1f0 } Entering state 1 Stack now 0 1 0xffffc989b2b0->Object::Object { 0xaaab093cb2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab093cb2e0 'a') -> $$ = nterm item (0xffffc989b2b0 'a') 0xaaab093cb2e0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b2b0 } 0xaaab093cb2e0->Object::Object { 0xffffc989b2b0 } 0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xffffc989b2b0 } 0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xffffc989b260, 0xffffc989b2b0 } 0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b2b0 } Entering state 10 Stack now 0 10 Reading a token 0xffffc989b1b0->Object::Object { 0xaaab093cb2e0 } 0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xffffc989b1b0 } 0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1b0, 0xffffc989b290 } Next token is token 'a' (0xffffc989b290 'a') 0xffffc989b1f0->Object::Object { 0xaaab093cb2e0, 0xffffc989b290 } 0xffffc989b1a0->Object::Object { 0xaaab093cb2e0, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b1a0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b290->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1f0, 0xffffc989b290 } Shifting token 'a' (0xffffc989b1f0 'a') 0xaaab093cb300->Object::Object { 0xaaab093cb2e0, 0xffffc989b1f0 } 0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0 } 0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b178, 0xffffc989b1f0 } 0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0 } Entering state 1 Stack now 0 10 1 0xffffc989b2b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab093cb300 'a') -> $$ = nterm item (0xffffc989b2b0 'a') 0xaaab093cb300->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } 0xaaab093cb300->Object::Object { 0xaaab093cb2e0, 0xffffc989b2b0 } 0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } 0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b260, 0xffffc989b2b0 } 0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffc989b1b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300 } 0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1b0 } 0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1b0, 0xffffc989b290 } Next token is token 'a' (0xffffc989b290 'a') 0xffffc989b1f0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b290 } 0xffffc989b1a0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b1a0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b290->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0, 0xffffc989b290 } Shifting token 'a' (0xffffc989b1f0 'a') 0xaaab093cb320->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0 } 0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0 } 0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b178, 0xffffc989b1f0 } 0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0 } Entering state 1 Stack now 0 10 10 1 0xffffc989b2b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab093cb320 'a') -> $$ = nterm item (0xffffc989b2b0 'a') 0xaaab093cb320->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } 0xaaab093cb320->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } 0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } 0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b260, 0xffffc989b2b0 } 0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffc989b1b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320 } 0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1b0 } 0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1b0, 0xffffc989b290 } Next token is token 'a' (0xffffc989b290 'a') 0xffffc989b1f0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b290 } 0xffffc989b1a0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b1a0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } 0xffffc989b290->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0, 0xffffc989b290 } Shifting token 'a' (0xffffc989b1f0 'a') 0xaaab093cb340->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0 } 0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1f0 } 0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b178, 0xffffc989b1f0 } 0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1f0 } Entering state 1 Stack now 0 10 10 10 1 0xffffc989b2b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab093cb340 'a') -> $$ = nterm item (0xffffc989b2b0 'a') 0xaaab093cb340->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b2b0 } 0xaaab093cb340->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } 0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b2b0 } 0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b260, 0xffffc989b2b0 } 0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b2b0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffc989b1b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340 } 0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1b0 } 0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1b0, 0xffffc989b290 } Next token is token 'p' (0xffffc989b290 'p'Exception caught: cleaning lookahead and stack 0xaaab093cb340->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b290 } 0xaaab093cb320->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b290 } 0xaaab093cb300->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b290 } 0xaaab093cb2e0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b290 } 0xffffc989b290->Object::~Object { 0xffffc989b290 } exception caught: printer end { } ./c++.at:1363: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1363: $PREPARSER ./input aaaae ./c++.at:1360: $PREPARSER ./input aaaal stderr: stderr: stderr: exception caught: yylex ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaE stdout: stderr: ./c++.at:1360: $PREPARSER ./input i exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: initial-action ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaT ./c++.at:1555: ./check stderr: ./c++.at:1360: $PREPARSER ./input aaaap ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: $PREPARSER ./input aaaaR ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -std=c++03 not supported ======== Testing with C++ standard flags: '' ./c++.at:1360: $PREPARSER ./input --debug aaaap ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae5ef1f40->Object::Object { } Next token is token 'a' (0xaaaae5ef1f40 'a') Shifting token 'a' (0xaaaae5ef1f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae5ef1f40 'a') -> $$ = nterm item (0xaaaae5ef1f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaae5ef1f90->Object::Object { 0xaaaae5ef1f40 } Next token is token 'a' (0xaaaae5ef1f90 'a') Shifting token 'a' (0xaaaae5ef1f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae5ef1f90 'a') -> $$ = nterm item (0xaaaae5ef1f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaae5ef1fe0->Object::Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90 } Next token is token 'a' (0xaaaae5ef1fe0 'a') Shifting token 'a' (0xaaaae5ef1fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae5ef1fe0 'a') -> $$ = nterm item (0xaaaae5ef1fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaae5ef2030->Object::Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0 } Next token is token 'a' (0xaaaae5ef2030 'a') Shifting token 'a' (0xaaaae5ef2030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae5ef2030 'a') -> $$ = nterm item (0xaaaae5ef2030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaae5ef2080->Object::Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0, 0xaaaae5ef2030 } Next token is token 'p' (0xaaaae5ef2080 'p'Exception caught: cleaning lookahead and stack 0xaaaae5ef2080->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0, 0xaaaae5ef2030, 0xaaaae5ef2080 } 0xaaaae5ef2030->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0, 0xaaaae5ef2030 } 0xaaaae5ef1fe0->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0 } 0xaaaae5ef1f90->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90 } 0xaaaae5ef1f40->Object::~Object { 0xaaaae5ef1f40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae5ef1f40->Object::Object { } Next token is token 'a' (0xaaaae5ef1f40 'a') Shifting token 'a' (0xaaaae5ef1f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae5ef1f40 'a') -> $$ = nterm item (0xaaaae5ef1f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaae5ef1f90->Object::Object { 0xaaaae5ef1f40 } Next token is token 'a' (0xaaaae5ef1f90 'a') Shifting token 'a' (0xaaaae5ef1f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae5ef1f90 'a') -> $$ = nterm item (0xaaaae5ef1f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaae5ef1fe0->Object::Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90 } Next token is token 'a' (0xaaaae5ef1fe0 'a') Shifting token 'a' (0xaaaae5ef1fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae5ef1fe0 'a') -> $$ = nterm item (0xaaaae5ef1fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaae5ef2030->Object::Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0 } Next token is token 'a' (0xaaaae5ef2030 'a') Shifting token 'a' (0xaaaae5ef2030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae5ef2030 'a') -> $$ = nterm item (0xaaaae5ef2030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaae5ef2080->Object::Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0, 0xaaaae5ef2030 } Next token is token 'p' (0xaaaae5ef2080 'p'Exception caught: cleaning lookahead and stack 0xaaaae5ef2080->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0, 0xaaaae5ef2030, 0xaaaae5ef2080 } 0xaaaae5ef2030->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0, 0xaaaae5ef2030 } 0xaaaae5ef1fe0->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0 } 0xaaaae5ef1f90->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90 } 0xaaaae5ef1f40->Object::~Object { 0xaaaae5ef1f40 } exception caught: printer end { } ./c++.at:1360: grep '^exception caught: printer$' stderr ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaT stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaR stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ======== Testing with C++ standard flags: '' stdout: ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: ./c++.at:851: $PREPARSER ./input ./c++.at:1555: ./check stderr: -std=c++11 not supported ======== Testing with C++ standard flags: '' ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1555: ./check ./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y stderr: stdout: ./c++.at:857: $PREPARSER ./input stderr: ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1361: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaap stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaadaf72f40->Object::Object { } Next token is token 'a' (0xaaaadaf72f40 'a') Shifting token 'a' (0xaaaadaf72f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadaf72f40 'a') -> $$ = nterm item (0xaaaadaf72f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaadaf72f90->Object::Object { 0xaaaadaf72f40 } Next token is token 'a' (0xaaaadaf72f90 'a') Shifting token 'a' (0xaaaadaf72f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadaf72f90 'a') -> $$ = nterm item (0xaaaadaf72f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaadaf72fe0->Object::Object { 0xaaaadaf72f40, 0xaaaadaf72f90 } Next token is token 'a' (0xaaaadaf72fe0 'a') Shifting token 'a' (0xaaaadaf72fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadaf72fe0 'a') -> $$ = nterm item (0xaaaadaf72fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaadaf73030->Object::Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0 } Next token is token 'a' (0xaaaadaf73030 'a') Shifting token 'a' (0xaaaadaf73030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadaf73030 'a') -> $$ = nterm item (0xaaaadaf73030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaadaf73080->Object::Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0, 0xaaaadaf73030 } Next token is token 'p' (0xaaaadaf73080 'p'Exception caught: cleaning lookahead and stack 0xaaaadaf73080->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0, 0xaaaadaf73030, 0xaaaadaf73080 } 0xaaaadaf73030->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0, 0xaaaadaf73030 } 0xaaaadaf72fe0->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0 } 0xaaaadaf72f90->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90 } 0xaaaadaf72f40->Object::~Object { 0xaaaadaf72f40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaadaf72f40->Object::Object { } Next token is token 'a' (0xaaaadaf72f40 'a') Shifting token 'a' (0xaaaadaf72f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadaf72f40 'a') -> $$ = nterm item (0xaaaadaf72f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaadaf72f90->Object::Object { 0xaaaadaf72f40 } Next token is token 'a' (0xaaaadaf72f90 'a') Shifting token 'a' (0xaaaadaf72f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadaf72f90 'a') -> $$ = nterm item (0xaaaadaf72f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaadaf72fe0->Object::Object { 0xaaaadaf72f40, 0xaaaadaf72f90 } Next token is token 'a' (0xaaaadaf72fe0 'a') Shifting token 'a' (0xaaaadaf72fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadaf72fe0 'a') -> $$ = nterm item (0xaaaadaf72fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaadaf73030->Object::Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0 } Next token is token 'a' (0xaaaadaf73030 'a') Shifting token 'a' (0xaaaadaf73030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadaf73030 'a') -> $$ = nterm item (0xaaaadaf73030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaadaf73080->Object::Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0, 0xaaaadaf73030 } Next token is token 'p' (0xaaaadaf73080 'p'Exception caught: cleaning lookahead and stack 0xaaaadaf73080->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0, 0xaaaadaf73030, 0xaaaadaf73080 } 0xaaaadaf73030->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0, 0xaaaadaf73030 } 0xaaaadaf72fe0->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0 } 0xaaaadaf72f90->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90 } 0xaaaadaf72f40->Object::~Object { 0xaaaadaf72f40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1361: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaE stderr: stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaT stderr: stdout: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaR ./c++.at:1065: $PREPARSER ./input < in stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1065: $PREPARSER ./input < in ======== Testing with C++ standard flags: '' ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: error: invalid expression ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:941: $PREPARSER ./input stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' 681. c++.at:884: ok ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 692. java.at:25: testing Java invalid directives ... ./java.at:35: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret YYParser.y stderr: stdout: stderr: stdout: ./c++.at:1066: ./check ./java.at:50: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret YYParser.y ./c++.at:851: $PREPARSER ./input stderr: ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 692. java.at:25: ok stderr: stdout: ./c++.at:1362: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input i stderr: stdout: stderr: stderr: ./c++.at:857: $PREPARSER ./input exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: 693. java.at:186: testing Java parser class and package names ... stderr: ./java.at:188: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y stderr: ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1555: $PREPARSER ./test ./c++.at:1360: $PREPARSER ./input aaaas stderr: ./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1362: $PREPARSER ./input aaaap stderr: stderr: exception caught: reduction ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1362: $PREPARSER ./input --debug aaaap ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./c++.at:1360: $PREPARSER ./input aaaal ./java.at:188: grep '[mb]4_' YYParser.y stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffcf641fd0->Object::Object { } 0xffffcf642080->Object::Object { 0xffffcf641fd0 } 0xffffcf641fd0->Object::~Object { 0xffffcf641fd0, 0xffffcf642080 } Next token is token 'a' (0xffffcf642080 'a') 0xffffcf641fc0->Object::Object { 0xffffcf642080 } 0xffffcf642080->Object::~Object { 0xffffcf641fc0, 0xffffcf642080 } Shifting token 'a' (0xffffcf641fc0 'a') 0xaaab09e922e0->Object::Object { 0xffffcf641fc0 } 0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xffffcf641fc0 } Entering state 2 Stack now 0 2 0xffffcf6420a0->Object::Object { 0xaaab09e922e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab09e922e0 'a') -> $$ = nterm item (0xffffcf6420a0 'a') 0xaaab09e922e0->Object::~Object { 0xaaab09e922e0, 0xffffcf6420a0 } 0xaaab09e922e0->Object::Object { 0xffffcf6420a0 } 0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xffffcf6420a0 } Entering state 11 Stack now 0 11 Reading a token 0xffffcf641fd0->Object::Object { 0xaaab09e922e0 } 0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xffffcf641fd0 } 0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xffffcf641fd0, 0xffffcf642080 } Next token is token 'a' (0xffffcf642080 'a') 0xffffcf641fc0->Object::Object { 0xaaab09e922e0, 0xffffcf642080 } 0xffffcf642080->Object::~Object { 0xaaab09e922e0, 0xffffcf641fc0, 0xffffcf642080 } Shifting token 'a' (0xffffcf641fc0 'a') 0xaaab09e92300->Object::Object { 0xaaab09e922e0, 0xffffcf641fc0 } 0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fc0 } Entering state 2 Stack now 0 11 2 0xffffcf6420a0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab09e92300 'a') -> $$ = nterm item (0xffffcf6420a0 'a') 0xaaab09e92300->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf6420a0 } 0xaaab09e92300->Object::Object { 0xaaab09e922e0, 0xffffcf6420a0 } 0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf6420a0 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffcf641fd0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300 } 0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fd0 } 0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fd0, 0xffffcf642080 } Next token is token 'a' (0xffffcf642080 'a') 0xffffcf641fc0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf642080 } 0xffffcf642080->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fc0, 0xffffcf642080 } Shifting token 'a' (0xffffcf641fc0 'a') 0xaaab09e92320->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fc0 } 0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fc0 } Entering state 2 Stack now 0 11 11 2 0xffffcf6420a0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab09e92320 'a') -> $$ = nterm item (0xffffcf6420a0 'a') 0xaaab09e92320->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf6420a0 } 0xaaab09e92320->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf6420a0 } 0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf6420a0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffcf641fd0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320 } 0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fd0 } 0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fd0, 0xffffcf642080 } Next token is token 'a' (0xffffcf642080 'a') 0xffffcf641fc0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf642080 } 0xffffcf642080->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fc0, 0xffffcf642080 } Shifting token 'a' (0xffffcf641fc0 'a') 0xaaab09e92340->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fc0 } 0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf641fc0 } Entering state 2 Stack now 0 11 11 11 2 0xffffcf6420a0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab09e92340 'a') -> $$ = nterm item (0xffffcf6420a0 'a') 0xaaab09e92340->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf6420a0 } 0xaaab09e92340->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf6420a0 } 0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf6420a0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffcf641fd0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340 } 0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf641fd0 } 0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf641fd0, 0xffffcf642080 } Next token is token 'p' (0xffffcf642080 'p'Exception caught: cleaning lookahead and stack 0xaaab09e92340->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf642080 } 0xaaab09e92320->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf642080 } 0xaaab09e92300->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf642080 } 0xaaab09e922e0->Object::~Object { 0xaaab09e922e0, 0xffffcf642080 } 0xffffcf642080->Object::~Object { 0xffffcf642080 } exception caught: printer end { } stdout: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 693. java.at:186: ./c++.at:1360: $PREPARSER ./input i stderr: skipped (java.at:188) Starting parse Entering state 0 Stack now 0 Reading a token 0xffffcf641fd0->Object::Object { } 0xffffcf642080->Object::Object { 0xffffcf641fd0 } 0xffffcf641fd0->Object::~Object { 0xffffcf641fd0, 0xffffcf642080 } Next token is token 'a' (0xffffcf642080 'a') 0xffffcf641fc0->Object::Object { 0xffffcf642080 } 0xffffcf642080->Object::~Object { 0xffffcf641fc0, 0xffffcf642080 } Shifting token 'a' (0xffffcf641fc0 'a') 0xaaab09e922e0->Object::Object { 0xffffcf641fc0 } 0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xffffcf641fc0 } Entering state 2 Stack now 0 2 0xffffcf6420a0->Object::Object { 0xaaab09e922e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab09e922e0 'a') -> $$ = nterm item (0xffffcf6420a0 'a') 0xaaab09e922e0->Object::~Object { 0xaaab09e922e0, 0xffffcf6420a0 } 0xaaab09e922e0->Object::Object { 0xffffcf6420a0 } 0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xffffcf6420a0 } Entering state 11 Stack now 0 11 Reading a token 0xffffcf641fd0->Object::Object { 0xaaab09e922e0 } 0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xffffcf641fd0 } 0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xffffcf641fd0, 0xffffcf642080 } Next token is token 'a' (0xffffcf642080 'a') 0xffffcf641fc0->Object::Object { 0xaaab09e922e0, 0xffffcf642080 } 0xffffcf642080->Object::~Object { 0xaaab09e922e0, 0xffffcf641fc0, 0xffffcf642080 } Shifting token 'a' (0xffffcf641fc0 'a') 0xaaab09e92300->Object::Object { 0xaaab09e922e0, 0xffffcf641fc0 } 0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fc0 } Entering state 2 Stack now 0 11 2 0xffffcf6420a0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab09e92300 'a') -> $$ = nterm item (0xffffcf6420a0 'a') 0xaaab09e92300->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf6420a0 } 0xaaab09e92300->Object::Object { 0xaaab09e922e0, 0xffffcf6420a0 } 0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf6420a0 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffcf641fd0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300 } 0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fd0 } 0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fd0, 0xffffcf642080 } Next token is token 'a' (0xffffcf642080 'a') 0xffffcf641fc0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf642080 } 0xffffcf642080->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fc0, 0xffffcf642080 } Shifting token 'a' (0xffffcf641fc0 'a') 0xaaab09e92320->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fc0 } 0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fc0 } Entering state 2 Stack now 0 11 11 2 0xffffcf6420a0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab09e92320 'a') -> $$ = nterm item (0xffffcf6420a0 'a') 0xaaab09e92320->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf6420a0 } 0xaaab09e92320->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf6420a0 } 0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf6420a0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffcf641fd0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320 } 0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fd0 } 0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fd0, 0xffffcf642080 } Next token is token 'a' (0xffffcf642080 'a') 0xffffcf641fc0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf642080 } 0xffffcf642080->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fc0, 0xffffcf642080 } Shifting token 'a' (0xffffcf641fc0 'a') 0xaaab09e92340->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fc0 } 0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf641fc0 } Entering state 2 Stack now 0 11 11 11 2 0xffffcf6420a0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab09e92340 'a') -> $$ = nterm item (0xffffcf6420a0 'a') 0xaaab09e92340->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf6420a0 } 0xaaab09e92340->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf6420a0 } 0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf6420a0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffcf641fd0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340 } 0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf641fd0 } 0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf641fd0, 0xffffcf642080 } Next token is token 'p' (0xffffcf642080 'p'Exception caught: cleaning lookahead and stack 0xaaab09e92340->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf642080 } 0xaaab09e92320->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf642080 } 0xaaab09e92300->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf642080 } 0xaaab09e922e0->Object::~Object { 0xaaab09e922e0, 0xffffcf642080 } 0xffffcf642080->Object::~Object { 0xffffcf642080 } exception caught: printer end { } ./c++.at:1362: grep '^exception caught: printer$' stderr stderr: exception caught: initial-action ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1360: $PREPARSER ./input aaaap stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1360: $PREPARSER ./input --debug aaaap stderr: ./c++.at:1555: ./check ./c++.at:1362: $PREPARSER ./input aaaaE Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae734ef40->Object::Object { } Next token is token 'a' (0xaaaae734ef40 'a') Shifting token 'a' (0xaaaae734ef40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae734ef40 'a') -> $$ = nterm item (0xaaaae734ef40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaae734ef90->Object::Object { 0xaaaae734ef40 } Next token is token 'a' (0xaaaae734ef90 'a') Shifting token 'a' (0xaaaae734ef90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae734ef90 'a') -> $$ = nterm item (0xaaaae734ef90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaae734efe0->Object::Object { 0xaaaae734ef40, 0xaaaae734ef90 } Next token is token 'a' (0xaaaae734efe0 'a') Shifting token 'a' (0xaaaae734efe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae734efe0 'a') -> $$ = nterm item (0xaaaae734efe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaae734f030->Object::Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0 } Next token is token 'a' (0xaaaae734f030 'a') Shifting token 'a' (0xaaaae734f030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae734f030 'a') -> $$ = nterm item (0xaaaae734f030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaae734f080->Object::Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0, 0xaaaae734f030 } Next token is token 'p' (0xaaaae734f080 'p'Exception caught: cleaning lookahead and stack 0xaaaae734f080->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0, 0xaaaae734f030, 0xaaaae734f080 } 0xaaaae734f030->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0, 0xaaaae734f030 } 0xaaaae734efe0->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0 } 0xaaaae734ef90->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90 } 0xaaaae734ef40->Object::~Object { 0xaaaae734ef40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae734ef40->Object::Object { } Next token is token 'a' (0xaaaae734ef40 'a') Shifting token 'a' (0xaaaae734ef40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae734ef40 'a') -> $$ = nterm item (0xaaaae734ef40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaae734ef90->Object::Object { 0xaaaae734ef40 } Next token is token 'a' (0xaaaae734ef90 'a') Shifting token 'a' (0xaaaae734ef90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae734ef90 'a') -> $$ = nterm item (0xaaaae734ef90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaae734efe0->Object::Object { 0xaaaae734ef40, 0xaaaae734ef90 } Next token is token 'a' (0xaaaae734efe0 'a') Shifting token 'a' (0xaaaae734efe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae734efe0 'a') -> $$ = nterm item (0xaaaae734efe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaae734f030->Object::Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0 } Next token is token 'a' (0xaaaae734f030 'a') Shifting token 'a' (0xaaaae734f030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae734f030 'a') -> $$ = nterm item (0xaaaae734f030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaae734f080->Object::Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0, 0xaaaae734f030 } Next token is token 'p' (0xaaaae734f080 'p'Exception caught: cleaning lookahead and stack 0xaaaae734f080->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0, 0xaaaae734f030, 0xaaaae734f080 } 0xaaaae734f030->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0, 0xaaaae734f030 } 0xaaaae734efe0->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0 } 0xaaaae734ef90->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90 } 0xaaaae734ef40->Object::~Object { 0xaaaae734ef40 } exception caught: printer end { } ./c++.at:1360: grep '^exception caught: printer$' stderr ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae ./c++.at:1362: $PREPARSER ./input aaaaT stderr: 694. java.at:217: testing Java parser class modifiers ... ./java.at:219: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./java.at:219: grep '[mb]4_' YYParser.y stdout: 694. java.at:217: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr skipped (java.at:219) ./c++.at:1362: $PREPARSER ./input aaaaR stderr: ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./c++.at:1360: $PREPARSER ./input aaaaE ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 695. java.at:287: testing Java parser class extends and implements ... ======== Testing with C++ standard flags: '' ./java.at:289: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:1360: $PREPARSER ./input aaaaT stdout: ./c++.at:1064: $PREPARSER ./input < in stderr: stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./java.at:289: grep '[mb]4_' YYParser.y ./c++.at:1360: $PREPARSER ./input aaaaR error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: stdout: ./c++.at:1363: $PREPARSER ./input aaaas ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1064: $PREPARSER ./input < in exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 695. java.at:287: ======== Testing with C++ standard flags: '' skipped (java.at:289) stderr: ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1363: $PREPARSER ./input aaaal error: invalid character stderr: ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: exception caught: yylex ./c++.at:1361: $PREPARSER ./input aaaas ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' exception caught: reduction ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ./c++.at:1363: $PREPARSER ./input i ./c++.at:1361: $PREPARSER ./input aaaal stderr: stderr: exception caught: initial-action exception caught: yylex ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input i stderr: 696. java.at:307: testing Java %parse-param and %lex-param ... ./java.at:309: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y ./c++.at:1363: $PREPARSER ./input aaaap exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaap stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: ./java.at:309: grep '[mb]4_' YYParser.y ./c++.at:1361: $PREPARSER ./input --debug aaaap stdout: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffdb7dd660->Object::Object { } 0xffffdb7dd760->Object::Object { 0xffffdb7dd660 } 0xffffdb7dd660->Object::~Object { 0xffffdb7dd660, 0xffffdb7dd760 } Next token is token 'a' (0xffffdb7dd760 'a') 0xffffdb7dd6a0->Object::Object { 0xffffdb7dd760 } 0xffffdb7dd760->Object::~Object { 0xffffdb7dd6a0, 0xffffdb7dd760 } Shifting token 'a' (0xffffdb7dd6a0 'a') 0xaaab151902e0->Object::Object { 0xffffdb7dd6a0 } 0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xffffdb7dd6a0 } Entering state 1 Stack now 0 1 0xffffdb7dd780->Object::Object { 0xaaab151902e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab151902e0 'a') -> $$ = nterm item (0xffffdb7dd780 'a') 0xaaab151902e0->Object::~Object { 0xaaab151902e0, 0xffffdb7dd780 } 0xaaab151902e0->Object::Object { 0xffffdb7dd780 } 0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xffffdb7dd780 } Entering state 10 Stack now 0 10 Reading a token 0xffffdb7dd660->Object::Object { 0xaaab151902e0 } 0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xffffdb7dd660 } 0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xffffdb7dd660, 0xffffdb7dd760 } Next token is token 'a' (0xffffdb7dd760 'a') 0xffffdb7dd6a0->Object::Object { 0xaaab151902e0, 0xffffdb7dd760 } 0xffffdb7dd760->Object::~Object { 0xaaab151902e0, 0xffffdb7dd6a0, 0xffffdb7dd760 } Shifting token 'a' (0xffffdb7dd6a0 'a') 0xaaab15190300->Object::Object { 0xaaab151902e0, 0xffffdb7dd6a0 } 0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd6a0 } Entering state 1 Stack now 0 10 1 0xffffdb7dd780->Object::Object { 0xaaab151902e0, 0xaaab15190300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab15190300 'a') -> $$ = nterm item (0xffffdb7dd780 'a') 0xaaab15190300->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd780 } 0xaaab15190300->Object::Object { 0xaaab151902e0, 0xffffdb7dd780 } 0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd780 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffdb7dd660->Object::Object { 0xaaab151902e0, 0xaaab15190300 } 0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd660 } 0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd660, 0xffffdb7dd760 } Next token is token 'a' (0xffffdb7dd760 'a') 0xffffdb7dd6a0->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd760 } 0xffffdb7dd760->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd6a0, 0xffffdb7dd760 } Shifting token 'a' (0xffffdb7dd6a0 'a') 0xaaab15190320->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd6a0 } 0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd6a0 } Entering state 1 Stack now 0 10 10 1 0xffffdb7dd780->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab15190320 'a') -> $$ = nterm item (0xffffdb7dd780 'a') 0xaaab15190320->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd780 } 0xaaab15190320->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd780 } 0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd780 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffdb7dd660->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320 } 0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd660 } 0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd660, 0xffffdb7dd760 } Next token is token 'a' (0xffffdb7dd760 'a') 0xffffdb7dd6a0->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd760 } 0xffffdb7dd760->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd6a0, 0xffffdb7dd760 } Shifting token 'a' (0xffffdb7dd6a0 'a') 0xaaab15190340->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd6a0 } 0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd6a0 } Entering state 1 Stack now 0 10 10 10 1 0xffffdb7dd780->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab15190340 'a') -> $$ = nterm item (0xffffdb7dd780 'a') 0xaaab15190340->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd780 } 0xaaab15190340->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd780 } 0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd780 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffdb7dd660->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340 } 0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd660 } 0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd660, 0xffffdb7dd760 } Next token is token 'p' (0xffffdb7dd760 'p'Exception caught: cleaning lookahead and stack 0xaaab15190340->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd760 } 0xaaab15190320->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd760 } 0xaaab15190300->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd760 } 0xaaab151902e0->Object::~Object { 0xaaab151902e0, 0xffffdb7dd760 } 0xffffdb7dd760->Object::~Object { 0xffffdb7dd760 } exception caught: printer end { } stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaadd188f40->Object::Object { } Next token is token 'a' (0xaaaadd188f40 'a') Shifting token 'a' (0xaaaadd188f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadd188f40 'a') -> $$ = nterm item (0xaaaadd188f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaadd188f90->Object::Object { 0xaaaadd188f40 } Next token is token 'a' (0xaaaadd188f90 'a') Shifting token 'a' (0xaaaadd188f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadd188f90 'a') -> $$ = nterm item (0xaaaadd188f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaadd188fe0->Object::Object { 0xaaaadd188f40, 0xaaaadd188f90 } Next token is token 'a' (0xaaaadd188fe0 'a') Shifting token 'a' (0xaaaadd188fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadd188fe0 'a') -> $$ = nterm item (0xaaaadd188fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaadd189030->Object::Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0 } Next token is token 'a' (0xaaaadd189030 'a') Shifting token 'a' (0xaaaadd189030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadd189030 'a') -> $$ = nterm item (0xaaaadd189030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaadd189080->Object::Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0, 0xaaaadd189030 } Next token is token 'p' (0xaaaadd189080 'p'Exception caught: cleaning lookahead and stack 0xaaaadd189080->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0, 0xaaaadd189030, 0xaaaadd189080 } 0xaaaadd189030->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0, 0xaaaadd189030 } 0xaaaadd188fe0->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0 } 0xaaaadd188f90->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90 } 0xaaaadd188f40->Object::~Object { 0xaaaadd188f40 } exception caught: printer end { } ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 696. java.at:307: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffdb7dd660->Object::Object { } 0xffffdb7dd760->Object::Object { 0xffffdb7dd660 } 0xffffdb7dd660->Object::~Object { 0xffffdb7dd660, 0xffffdb7dd760 } Next token is token 'a' (0xffffdb7dd760 'a') 0xffffdb7dd6a0->Object::Object { 0xffffdb7dd760 } 0xffffdb7dd760->Object::~Object { 0xffffdb7dd6a0, 0xffffdb7dd760 } Shifting token 'a' (0xffffdb7dd6a0 'a') 0xaaab151902e0->Object::Object { 0xffffdb7dd6a0 } 0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xffffdb7dd6a0 } Entering state 1 Stack now 0 1 0xffffdb7dd780->Object::Object { 0xaaab151902e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab151902e0 'a') -> $$ = nterm item (0xffffdb7dd780 'a') 0xaaab151902e0->Object::~Object { 0xaaab151902e0, 0xffffdb7dd780 } 0xaaab151902e0->Object::Object { 0xffffdb7dd780 } 0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xffffdb7dd780 } Entering state 10 Stack now 0 10 Reading a token 0xffffdb7dd660->Object::Object { 0xaaab151902e0 } 0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xffffdb7dd660 } 0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xffffdb7dd660, 0xffffdb7dd760 } Next token is token 'a' (0xffffdb7dd760 'a') 0xffffdb7dd6a0->Object::Object { 0xaaab151902e0, 0xffffdb7dd760 } 0xffffdb7dd760->Object::~Object { 0xaaab151902e0, 0xffffdb7dd6a0, 0xffffdb7dd760 } Shifting token 'a' (0xffffdb7dd6a0 'a') 0xaaab15190300->Object::Object { 0xaaab151902e0, 0xffffdb7dd6a0 } 0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd6a0 } Entering state 1 Stack now 0 10 1 0xffffdb7dd780->Object::Object { 0xaaab151902e0, 0xaaab15190300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab15190300 'a') -> $$ = nterm item (0xffffdb7dd780 'a') 0xaaab15190300->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd780 } 0xaaab15190300->Object::Object { 0xaaab151902e0, 0xffffdb7dd780 } 0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd780 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffdb7dd660->Object::Object { 0xaaab151902e0, 0xaaab15190300 } 0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd660 } 0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd660, 0xffffdb7dd760 } Next token is token 'a' (0xffffdb7dd760 'a') 0xffffdb7dd6a0->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd760 } 0xffffdb7dd760->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd6a0, 0xffffdb7dd760 } Shifting token 'a' (0xffffdb7dd6a0 'a') 0xaaab15190320->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd6a0 } 0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd6a0 } Entering state 1 Stack now 0 10 10 1 0xffffdb7dd780->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab15190320 'a') -> $$ = nterm item (0xffffdb7dd780 'a') 0xaaab15190320->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd780 } 0xaaab15190320->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd780 } 0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd780 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffdb7dd660->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320 } 0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd660 } 0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd660, 0xffffdb7dd760 } Next token is token 'a' (0xffffdb7dd760 'a') 0xffffdb7dd6a0->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd760 } 0xffffdb7dd760->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd6a0, 0xffffdb7dd760 } Shifting token 'a' (0xffffdb7dd6a0 'a') 0xaaab15190340->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd6a0 } 0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd6a0 } Entering state 1 Stack now 0 10 10 10 1 0xffffdb7dd780->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab15190340 'a') -> $$ = nterm item (0xffffdb7dd780 'a') 0xaaab15190340->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd780 } 0xaaab15190340->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd780 } 0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd780 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffdb7dd660->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340 } 0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd660 } 0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd660, 0xffffdb7dd760 } Next token is token 'p' (0xffffdb7dd760 'p'Exception caught: cleaning lookahead and stack 0xaaab15190340->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd760 } 0xaaab15190320->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd760 } 0xaaab15190300->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd760 } 0xaaab151902e0->Object::~Object { 0xaaab151902e0, 0xffffdb7dd760 } 0xffffdb7dd760->Object::~Object { 0xffffdb7dd760 } exception caught: printer end { } skipped (java.at:309) ./c++.at:1363: grep '^exception caught: printer$' stderr stdout: stderr: exception caught: printer ./c++.at:1363: $PREPARSER ./input aaaae Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaadd188f40->Object::Object { } Next token is token 'a' (0xaaaadd188f40 'a') Shifting token 'a' (0xaaaadd188f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadd188f40 'a') -> $$ = nterm item (0xaaaadd188f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaadd188f90->Object::Object { 0xaaaadd188f40 } Next token is token 'a' (0xaaaadd188f90 'a') Shifting token 'a' (0xaaaadd188f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadd188f90 'a') -> $$ = nterm item (0xaaaadd188f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaadd188fe0->Object::Object { 0xaaaadd188f40, 0xaaaadd188f90 } Next token is token 'a' (0xaaaadd188fe0 'a') Shifting token 'a' (0xaaaadd188fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadd188fe0 'a') -> $$ = nterm item (0xaaaadd188fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaadd189030->Object::Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0 } Next token is token 'a' (0xaaaadd189030 'a') Shifting token 'a' (0xaaaadd189030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadd189030 'a') -> $$ = nterm item (0xaaaadd189030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaadd189080->Object::Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0, 0xaaaadd189030 } Next token is token 'p' (0xaaaadd189080 'p'Exception caught: cleaning lookahead and stack 0xaaaadd189080->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0, 0xaaaadd189030, 0xaaaadd189080 } 0xaaaadd189030->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0, 0xaaaadd189030 } 0xaaaadd188fe0->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0 } 0xaaaadd188f90->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90 } 0xaaaadd188f40->Object::~Object { 0xaaaadd188f40 } exception caught: printer end { } stderr: stdout: ./c++.at:1361: grep '^exception caught: printer$' stderr ./c++.at:851: $PREPARSER ./input stderr: stdout: exception caught: printer ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaae stderr: ======== Testing with C++ standard flags: '' ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: exception caught: syntax error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaE ./c++.at:1361: $PREPARSER ./input aaaaE stderr: 697. java.at:381: testing Java throws specifications ... ./java.at:441: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./java.at:441: grep '[mb]4_' YYParser.y stdout: ./c++.at:1361: $PREPARSER ./input aaaaT stderr: 697. java.at:381: ./c++.at:1363: $PREPARSER ./input aaaaT ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: skipped (java.at:441) ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaR ./c++.at:1363: $PREPARSER ./input aaaaR stderr: stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:857: $PREPARSER ./input stderr: ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 698. java.at:470: testing Java constructor init and init_throws ... ./java.at:475: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y stderr: stdout: 689. c++.at:1371: ok ./java.at:475: grep '[mb]4_' YYParser.y stdout: 698. java.at:470: skipped (java.at:475) 699. java.at:497: testing Java value, position, and location types ... ./java.at:499: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y ./java.at:499: grep '[mb]4_' YYParser.y stdout: 700. java.at:528: testing Java syntax error handling without error token ... ./java.at:579: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret YYParser.y 699. java.at:497: skipped (java.at:499) stderr: stdout: ./c++.at:1065: $PREPARSER ./input < in 700. java.at:528: stderr: skipped (java.at:580) error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 701. javapush.at:172: testing Trivial Push Parser with api.push-pull verification ... ./javapush.at:181: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dapi.push-pull=pull -o Main.java input.y ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in ./javapush.at:182: grep -c '^.*public boolean parse().*$' Main.java 702. javapush.at:217: testing Trivial Push Parser with %initial-action ... stderr: error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./javapush.at:227: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dapi.push-pull=push -o Main.java input.y ./javapush.at:187: grep -c '^.*public int push_parse(int yylextoken, Object yylexval).*$' Main.java ======== Testing with C++ standard flags: '' ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ./javapush.at:191: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dapi.push-pull=both -o Main.java input.y ./javapush.at:228: grep -c '^System.err.println("Initial action invoked");$' Main.java ./javapush.at:192: grep -c '^.*public boolean parse().*$' Main.java 702. javapush.at:217: skipped (javapush.at:230) ./javapush.at:195: grep -c '^.*public int push_parse(int yylextoken, Object yylexval).*$' Main.java stderr: stdout: ./c++.at:851: $PREPARSER ./input stderr: stderr: ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1555: $PREPARSER ./test ./javapush.at:199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dapi.push-pull=push -o Main.java input.y ======== Testing with C++ standard flags: '' stderr: ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./javapush.at:200: grep -c '^.*public boolean parse().*$' Main.java ./javapush.at:203: grep -c '^.*public int push_parse(int yylextoken, Object yylexval).*$' Main.java stderr: stdout: ./c++.at:1555: ./check 703. d.at:103: testing D parser class extends and implements ... ./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y ./d.at:106: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y 701. javapush.at:172: ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS skipped (javapush.at:207) ./d.at:106: grep '[mb]4_' YYParser.y stdout: 703. d.at:103: skipped (d.at:106) 704. d.at:138: testing D parser class api.token.raw true by default ... ./d.at:141: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y ./d.at:141: grep '[mb]4_' YYParser.y stdout: 705. cxx-type.at:409: testing GLR: Resolve ambiguity, impure, no locations ... 704. d.at:138: skipped (d.at:141) ./cxx-type.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y stderr: stdout: ./c++.at:857: $PREPARSER ./input stderr: types.y:77.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stderr: ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:410: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS ======== Testing with C++ standard flags: '' ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 706. cxx-type.at:415: testing GLR: Resolve ambiguity, impure, locations ... ./cxx-type.at:416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y stderr: stderr: types.y:87.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stdout: ./c++.at:1362: $PREPARSER ./input aaaas ./cxx-type.at:416: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS stderr: exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1362: $PREPARSER ./input aaaal stdout: stderr: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaal stderr: ./c++.at:1362: $PREPARSER ./input aaaap exception caught: yylex ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input i ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: exception caught: initial-action stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token 0xffffde9c34f0->Object::Object { } 0xffffde9c35a0->Object::Object { 0xffffde9c34f0 } 0xffffde9c34f0->Object::~Object { 0xffffde9c34f0, 0xffffde9c35a0 } Next token is token 'a' (0xffffde9c35a0 'a') 0xffffde9c34e0->Object::Object { 0xffffde9c35a0 } 0xffffde9c35a0->Object::~Object { 0xffffde9c34e0, 0xffffde9c35a0 } Shifting token 'a' (0xffffde9c34e0 'a') 0xaaaafb6772e0->Object::Object { 0xffffde9c34e0 } 0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c34e0 } Entering state 2 Stack now 0 2 0xffffde9c35c0->Object::Object { 0xaaaafb6772e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafb6772e0 'a') -> $$ = nterm item (0xffffde9c35c0 'a') 0xaaaafb6772e0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c35c0 } 0xaaaafb6772e0->Object::Object { 0xffffde9c35c0 } 0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c35c0 } Entering state 11 Stack now 0 11 Reading a token 0xffffde9c34f0->Object::Object { 0xaaaafb6772e0 } 0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xffffde9c34f0 } 0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c34f0, 0xffffde9c35a0 } Next token is token 'a' (0xffffde9c35a0 'a') 0xffffde9c34e0->Object::Object { 0xaaaafb6772e0, 0xffffde9c35a0 } 0xffffde9c35a0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c34e0, 0xffffde9c35a0 } Shifting token 'a' (0xffffde9c34e0 'a') 0xaaaafb677300->Object::Object { 0xaaaafb6772e0, 0xffffde9c34e0 } 0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34e0 } Entering state 2 Stack now 0 11 2 0xffffde9c35c0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafb677300 'a') -> $$ = nterm item (0xffffde9c35c0 'a') 0xaaaafb677300->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35c0 } 0xaaaafb677300->Object::Object { 0xaaaafb6772e0, 0xffffde9c35c0 } 0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35c0 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffde9c34f0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300 } 0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34f0 } 0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34f0, 0xffffde9c35a0 } Next token is token 'a' (0xffffde9c35a0 'a') 0xffffde9c34e0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35a0 } 0xffffde9c35a0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34e0, 0xffffde9c35a0 } Shifting token 'a' (0xffffde9c34e0 'a') 0xaaaafb677320->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34e0 } 0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34e0 } Entering state 2 Stack now 0 11 11 2 0xffffde9c35c0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafb677320 'a') -> $$ = nterm item (0xffffde9c35c0 'a') 0xaaaafb677320->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35c0 } 0xaaaafb677320->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35c0 } 0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35c0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffde9c34f0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320 } 0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34f0 } 0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34f0, 0xffffde9c35a0 } Next token is token 'a' (0xffffde9c35a0 'a') 0xffffde9c34e0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35a0 } 0xffffde9c35a0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34e0, 0xffffde9c35a0 } Shifting token 'a' (0xffffde9c34e0 'a') 0xaaaafb677340->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34e0 } 0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c34e0 } Entering state 2 Stack now 0 11 11 11 2 0xffffde9c35c0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafb677340 'a') -> $$ = nterm item (0xffffde9c35c0 'a') 0xaaaafb677340->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c35c0 } 0xaaaafb677340->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35c0 } 0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c35c0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffde9c34f0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340 } 0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c34f0 } 0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c34f0, 0xffffde9c35a0 } Next token is token 'p' (0xffffde9c35a0 'p'Exception caught: cleaning lookahead and stack 0xaaaafb677340->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c35a0 } 0xaaaafb677320->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35a0 } 0xaaaafb677300->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35a0 } 0xaaaafb6772e0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c35a0 } 0xffffde9c35a0->Object::~Object { 0xffffde9c35a0 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaap stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffde9c34f0->Object::Object { } 0xffffde9c35a0->Object::Object { 0xffffde9c34f0 } 0xffffde9c34f0->Object::~Object { 0xffffde9c34f0, 0xffffde9c35a0 } Next token is token 'a' (0xffffde9c35a0 'a') 0xffffde9c34e0->Object::Object { 0xffffde9c35a0 } 0xffffde9c35a0->Object::~Object { 0xffffde9c34e0, 0xffffde9c35a0 } Shifting token 'a' (0xffffde9c34e0 'a') 0xaaaafb6772e0->Object::Object { 0xffffde9c34e0 } 0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c34e0 } Entering state 2 Stack now 0 2 0xffffde9c35c0->Object::Object { 0xaaaafb6772e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafb6772e0 'a') -> $$ = nterm item (0xffffde9c35c0 'a') 0xaaaafb6772e0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c35c0 } 0xaaaafb6772e0->Object::Object { 0xffffde9c35c0 } 0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c35c0 } Entering state 11 Stack now 0 11 Reading a token 0xffffde9c34f0->Object::Object { 0xaaaafb6772e0 } 0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xffffde9c34f0 } 0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c34f0, 0xffffde9c35a0 } Next token is token 'a' (0xffffde9c35a0 'a') 0xffffde9c34e0->Object::Object { 0xaaaafb6772e0, 0xffffde9c35a0 } 0xffffde9c35a0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c34e0, 0xffffde9c35a0 } Shifting token 'a' (0xffffde9c34e0 'a') 0xaaaafb677300->Object::Object { 0xaaaafb6772e0, 0xffffde9c34e0 } 0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34e0 } Entering state 2 Stack now 0 11 2 0xffffde9c35c0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafb677300 'a') -> $$ = nterm item (0xffffde9c35c0 'a') 0xaaaafb677300->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35c0 } 0xaaaafb677300->Object::Object { 0xaaaafb6772e0, 0xffffde9c35c0 } 0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35c0 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffde9c34f0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300 } 0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34f0 } 0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34f0, 0xffffde9c35a0 } Next token is token 'a' (0xffffde9c35a0 'a') 0xffffde9c34e0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35a0 } 0xffffde9c35a0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34e0, 0xffffde9c35a0 } Shifting token 'a' (0xffffde9c34e0 'a') 0xaaaafb677320->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34e0 } 0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34e0 } Entering state 2 Stack now 0 11 11 2 0xffffde9c35c0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafb677320 'a') -> $$ = nterm item (0xffffde9c35c0 'a') 0xaaaafb677320->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35c0 } 0xaaaafb677320->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35c0 } 0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35c0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffde9c34f0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320 } 0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34f0 } 0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34f0, 0xffffde9c35a0 } Next token is token 'a' (0xffffde9c35a0 'a') 0xffffde9c34e0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35a0 } 0xffffde9c35a0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34e0, 0xffffde9c35a0 } Shifting token 'a' (0xffffde9c34e0 'a') 0xaaaafb677340->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34e0 } 0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c34e0 } Entering state 2 Stack now 0 11 11 11 2 0xffffde9c35c0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafb677340 'a') -> $$ = nterm item (0xffffde9c35c0 'a') 0xaaaafb677340->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c35c0 } 0xaaaafb677340->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35c0 } 0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c35c0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffde9c34f0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340 } 0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c34f0 } 0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c34f0, 0xffffde9c35a0 } Next token is token 'p' (0xffffde9c35a0 'p'Exception caught: cleaning lookahead and stack 0xaaaafb677340->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c35a0 } 0xaaaafb677320->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35a0 } 0xaaaafb677300->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35a0 } 0xaaaafb6772e0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c35a0 } 0xffffde9c35a0->Object::~Object { 0xffffde9c35a0 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae ./c++.at:1360: $PREPARSER ./input --debug aaaap stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaab051e6f40->Object::Object { } Next token is token 'a' (0xaaab051e6f40 'a') Shifting token 'a' (0xaaab051e6f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab051e6f40 'a') -> $$ = nterm item (0xaaab051e6f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaab051e6f90->Object::Object { 0xaaab051e6f40 } Next token is token 'a' (0xaaab051e6f90 'a') Shifting token 'a' (0xaaab051e6f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab051e6f90 'a') -> $$ = nterm item (0xaaab051e6f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaab051e6fe0->Object::Object { 0xaaab051e6f40, 0xaaab051e6f90 } Next token is token 'a' (0xaaab051e6fe0 'a') Shifting token 'a' (0xaaab051e6fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab051e6fe0 'a') -> $$ = nterm item (0xaaab051e6fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaab051e7030->Object::Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0 } Next token is token 'a' (0xaaab051e7030 'a') Shifting token 'a' (0xaaab051e7030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab051e7030 'a') -> $$ = nterm item (0xaaab051e7030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaab051e7080->Object::Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0, 0xaaab051e7030 } Next token is token 'p' (0xaaab051e7080 'p'Exception caught: cleaning lookahead and stack 0xaaab051e7080->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0, 0xaaab051e7030, 0xaaab051e7080 } 0xaaab051e7030->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0, 0xaaab051e7030 } 0xaaab051e6fe0->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0 } 0xaaab051e6f90->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90 } 0xaaab051e6f40->Object::~Object { 0xaaab051e6f40 } exception caught: printer end { } stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: syntax error stdout: ./c++.at:1361: $PREPARSER ./input aaaas stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaab051e6f40->Object::Object { } Next token is token 'a' (0xaaab051e6f40 'a') Shifting token 'a' (0xaaab051e6f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab051e6f40 'a') -> $$ = nterm item (0xaaab051e6f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaab051e6f90->Object::Object { 0xaaab051e6f40 } Next token is token 'a' (0xaaab051e6f90 'a') Shifting token 'a' (0xaaab051e6f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab051e6f90 'a') -> $$ = nterm item (0xaaab051e6f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaab051e6fe0->Object::Object { 0xaaab051e6f40, 0xaaab051e6f90 } Next token is token 'a' (0xaaab051e6fe0 'a') Shifting token 'a' (0xaaab051e6fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab051e6fe0 'a') -> $$ = nterm item (0xaaab051e6fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaab051e7030->Object::Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0 } Next token is token 'a' (0xaaab051e7030 'a') Shifting token 'a' (0xaaab051e7030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab051e7030 'a') -> $$ = nterm item (0xaaab051e7030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaab051e7080->Object::Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0, 0xaaab051e7030 } Next token is token 'p' (0xaaab051e7080 'p'Exception caught: cleaning lookahead and stack 0xaaab051e7080->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0, 0xaaab051e7030, 0xaaab051e7080 } 0xaaab051e7030->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0, 0xaaab051e7030 } 0xaaab051e6fe0->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0 } 0xaaab051e6f90->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90 } 0xaaab051e6f40->Object::~Object { 0xaaab051e6f40 } exception caught: printer end { } ./c++.at:1360: grep '^exception caught: printer$' stderr exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1362: $PREPARSER ./input aaaaE exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae stderr: exception caught: syntax error, unexpected end of file, expecting 'a' stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaal ./c++.at:1360: $PREPARSER ./input aaaaE stderr: exception caught: yylex ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaT stderr: stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1362: $PREPARSER ./input aaaaR stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1361: $PREPARSER ./input i ======== Testing with C++ standard flags: '' ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:851: $PREPARSER ./input stderr: stderr: ./c++.at:1360: $PREPARSER ./input aaaaT exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1360: $PREPARSER ./input aaaaR ./c++.at:1361: $PREPARSER ./input aaaap stderr: stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaad4bb8f40->Object::Object { } Next token is token 'a' (0xaaaad4bb8f40 'a') Shifting token 'a' (0xaaaad4bb8f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaad4bb8f40 'a') -> $$ = nterm item (0xaaaad4bb8f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaad4bb8f90->Object::Object { 0xaaaad4bb8f40 } Next token is token 'a' (0xaaaad4bb8f90 'a') Shifting token 'a' (0xaaaad4bb8f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaad4bb8f90 'a') -> $$ = nterm item (0xaaaad4bb8f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaad4bb8fe0->Object::Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90 } Next token is token 'a' (0xaaaad4bb8fe0 'a') Shifting token 'a' (0xaaaad4bb8fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaad4bb8fe0 'a') -> $$ = nterm item (0xaaaad4bb8fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaad4bb9030->Object::Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0 } Next token is token 'a' (0xaaaad4bb9030 'a') Shifting token 'a' (0xaaaad4bb9030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaad4bb9030 'a') -> $$ = nterm item (0xaaaad4bb9030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaad4bb9080->Object::Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0, 0xaaaad4bb9030 } Next token is token 'p' (0xaaaad4bb9080 'p'Exception caught: cleaning lookahead and stack 0xaaaad4bb9080->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0, 0xaaaad4bb9030, 0xaaaad4bb9080 } 0xaaaad4bb9030->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0, 0xaaaad4bb9030 } 0xaaaad4bb8fe0->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0 } 0xaaaad4bb8f90->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90 } 0xaaaad4bb8f40->Object::~Object { 0xaaaad4bb8f40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaad4bb8f40->Object::Object { } Next token is token 'a' (0xaaaad4bb8f40 'a') Shifting token 'a' (0xaaaad4bb8f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaad4bb8f40 'a') -> $$ = nterm item (0xaaaad4bb8f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaad4bb8f90->Object::Object { 0xaaaad4bb8f40 } Next token is token 'a' (0xaaaad4bb8f90 'a') Shifting token 'a' (0xaaaad4bb8f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaad4bb8f90 'a') -> $$ = nterm item (0xaaaad4bb8f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaad4bb8fe0->Object::Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90 } Next token is token 'a' (0xaaaad4bb8fe0 'a') Shifting token 'a' (0xaaaad4bb8fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaad4bb8fe0 'a') -> $$ = nterm item (0xaaaad4bb8fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaad4bb9030->Object::Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0 } Next token is token 'a' (0xaaaad4bb9030 'a') Shifting token 'a' (0xaaaad4bb9030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaad4bb9030 'a') -> $$ = nterm item (0xaaaad4bb9030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaad4bb9080->Object::Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0, 0xaaaad4bb9030 } Next token is token 'p' (0xaaaad4bb9080 'p'Exception caught: cleaning lookahead and stack 0xaaaad4bb9080->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0, 0xaaaad4bb9030, 0xaaaad4bb9080 } 0xaaaad4bb9030->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0, 0xaaaad4bb9030 } 0xaaaad4bb8fe0->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0 } 0xaaaad4bb8f90->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90 } 0xaaaad4bb8f40->Object::~Object { 0xaaaad4bb8f40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1361: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stdout: stdout: ./cxx-type.at:412: $PREPARSER ./types test-input stderr: syntax error ./cxx-type.at:412: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:412: $PREPARSER ./types -p test-input ./c++.at:1363: $PREPARSER ./input aaaas stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -stderr: > $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () ./cxx-type.at:412: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaE stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () 705. cxx-type.at:409: ok stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaal stderr: ./c++.at:1361: $PREPARSER ./input aaaaT exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stdout: ./c++.at:1066: $PREPARSER ./input < in ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaR stderr: stderr: stderr: stderr: stdout: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1555: $PREPARSER ./test ./c++.at:857: $PREPARSER ./input stderr: stderr: ./c++.at:1363: $PREPARSER ./input i error: invalid expression caught error error: invalid character caught error ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' 707. cxx-type.at:420: testing GLR: Resolve ambiguity, pure, no locations ... ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ======== Testing with C++ standard flags: '' ./cxx-type.at:421: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./c++.at:1363: $PREPARSER ./input aaaap ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1066: $PREPARSER ./input < in ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: types.y:77.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stderr: ./cxx-type.at:421: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS stderr: error: invalid character stdout: ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:417: $PREPARSER ./types test-input stderr: ./c++.at:1363: $PREPARSER ./input --debug aaaap 17.5: syntax error ./cxx-type.at:417: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:417: $PREPARSER ./types -p test-input stderr: stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) ./cxx-type.at:417: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc0c137e0->Object::Object { } 0xffffc0c138e0->Object::Object { 0xffffc0c137e0 } 0xffffc0c137e0->Object::~Object { 0xffffc0c137e0, 0xffffc0c138e0 } Next token is token 'a' (0xffffc0c138e0 'a') 0xffffc0c13820->Object::Object { 0xffffc0c138e0 } 0xffffc0c138e0->Object::~Object { 0xffffc0c13820, 0xffffc0c138e0 } Shifting token 'a' (0xffffc0c13820 'a') 0xaaaadf0782e0->Object::Object { 0xffffc0c13820 } 0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13820 } Entering state 1 Stack now 0 1 0xffffc0c13900->Object::Object { 0xaaaadf0782e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadf0782e0 'a') -> $$ = nterm item (0xffffc0c13900 'a') 0xaaaadf0782e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13900 } 0xaaaadf0782e0->Object::Object { 0xffffc0c13900 } 0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13900 } Entering state 10 Stack now 0 10 Reading a token 0xffffc0c137e0->Object::Object { 0xaaaadf0782e0 } 0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xffffc0c137e0 } 0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c137e0, 0xffffc0c138e0 } Next token is token 'a' (0xffffc0c138e0 'a') 0xffffc0c13820->Object::Object { 0xaaaadf0782e0, 0xffffc0c138e0 } 0xffffc0c138e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13820, 0xffffc0c138e0 } Shifting token 'a' (0xffffc0c13820 'a') 0xaaaadf078300->Object::Object { 0xaaaadf0782e0, 0xffffc0c13820 } 0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13820 } Entering state 1 Stack now 0 10 1 0xffffc0c13900->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadf078300 'a') -> $$ = nterm item (0xffffc0c13900 'a') 0xaaaadf078300->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13900 } 0xaaaadf078300->Object::Object { 0xaaaadf0782e0, 0xffffc0c13900 } 0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13900 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffc0c137e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300 } 0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c137e0 } 0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c137e0, 0xffffc0c138e0 } Next token is token 'a' (0xffffc0c138e0 'a') 0xffffc0c13820->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c138e0 } 0xffffc0c138e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13820, 0xffffc0c138e0 } Shifting token 'a' (0xffffc0c13820 'a') 0xaaaadf078320->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13820 } 0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13820 } Entering state 1 Stack now 0 10 10 1 0xffffc0c13900->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadf078320 'a') -> $$ = nterm item (0xffffc0c13900 'a') 0xaaaadf078320->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13900 } 0xaaaadf078320->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13900 } 0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13900 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffc0c137e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320 } 0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c137e0 } 0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c137e0, 0xffffc0c138e0 } Next token is token 'a' (0xffffc0c138e0 'a') 0xffffc0c13820->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c138e0 } 0xffffc0c138e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13820, 0xffffc0c138e0 } Shifting token 'a' (0xffffc0c13820 'a') 0xaaaadf078340->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13820 } 0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c13820 } Entering state 1 Stack now 0 10 10 10 1 0xffffc0c13900->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadf078340 'a') -> $$ = nterm item (0xffffc0c13900 'a') 0xaaaadf078340->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c13900 } 0xaaaadf078340->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13900 } 0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c13900 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffc0c137e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340 } 0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c137e0 } 0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c137e0, 0xffffc0c138e0 } Next token is token 'p' (0xffffc0c138e0 'p'Exception caught: cleaning lookahead and stack 0xaaaadf078340->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c138e0 } 0xaaaadf078320->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c138e0 } 0xaaaadf078300->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c138e0 } 0xaaaadf0782e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c138e0 } 0xffffc0c138e0->Object::~Object { 0xffffc0c138e0 } exception caught: printer end { } ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) stdout: 706. cxx-type.at:415: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc0c137e0->Object::Object { } 0xffffc0c138e0->Object::Object { 0xffffc0c137e0 } 0xffffc0c137e0->Object::~Object { 0xffffc0c137e0, 0xffffc0c138e0 } Next token is token 'a' (0xffffc0c138e0 'a') 0xffffc0c13820->Object::Object { 0xffffc0c138e0 } 0xffffc0c138e0->Object::~Object { 0xffffc0c13820, 0xffffc0c138e0 } Shifting token 'a' (0xffffc0c13820 'a') 0xaaaadf0782e0->Object::Object { 0xffffc0c13820 } 0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13820 } Entering state 1 Stack now 0 1 0xffffc0c13900->Object::Object { 0xaaaadf0782e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadf0782e0 'a') -> $$ = nterm item (0xffffc0c13900 'a') 0xaaaadf0782e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13900 } 0xaaaadf0782e0->Object::Object { 0xffffc0c13900 } 0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13900 } Entering state 10 Stack now 0 10 Reading a token 0xffffc0c137e0->Object::Object { 0xaaaadf0782e0 } 0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xffffc0c137e0 } 0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c137e0, 0xffffc0c138e0 } Next token is token 'a' (0xffffc0c138e0 'a') 0xffffc0c13820->Object::Object { 0xaaaadf0782e0, 0xffffc0c138e0 } 0xffffc0c138e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13820, 0xffffc0c138e0 } Shifting token 'a' (0xffffc0c13820 'a') 0xaaaadf078300->Object::Object { 0xaaaadf0782e0, 0xffffc0c13820 } 0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13820 } Entering state 1 Stack now 0 10 1 0xffffc0c13900->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadf078300 'a') -> $$ = nterm item (0xffffc0c13900 'a') 0xaaaadf078300->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13900 } 0xaaaadf078300->Object::Object { 0xaaaadf0782e0, 0xffffc0c13900 } 0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13900 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffc0c137e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300 } 0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c137e0 } 0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c137e0, 0xffffc0c138e0 } Next token is token 'a' (0xffffc0c138e0 'a') 0xffffc0c13820->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c138e0 } 0xffffc0c138e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13820, 0xffffc0c138e0 } Shifting token 'a' (0xffffc0c13820 'a') 0xaaaadf078320->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13820 } 0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13820 } Entering state 1 Stack now 0 10 10 1 0xffffc0c13900->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadf078320 'a') -> $$ = nterm item (0xffffc0c13900 'a') 0xaaaadf078320->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13900 } 0xaaaadf078320->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13900 } 0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13900 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffc0c137e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320 } 0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c137e0 } 0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c137e0, 0xffffc0c138e0 } Next token is token 'a' (0xffffc0c138e0 'a') 0xffffc0c13820->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c138e0 } 0xffffc0c138e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13820, 0xffffc0c138e0 } Shifting token 'a' (0xffffc0c13820 'a') 0xaaaadf078340->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13820 } 0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c13820 } Entering state 1 Stack now 0 10 10 10 1 0xffffc0c13900->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadf078340 'a') -> $$ = nterm item (0xffffc0c13900 'a') 0xaaaadf078340->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c13900 } 0xaaaadf078340->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13900 } 0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c13900 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffc0c137e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340 } 0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c137e0 } 0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c137e0, 0xffffc0c138e0 } Next token is token 'p' (0xffffc0c138e0 'p'Exception caught: cleaning lookahead and stack 0xaaaadf078340->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c138e0 } 0xaaaadf078320->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c138e0 } 0xaaaadf078300->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c138e0 } 0xaaaadf0782e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c138e0 } 0xffffc0c138e0->Object::~Object { 0xffffc0c138e0 } exception caught: printer end { } ok ./c++.at:1555: ./check ./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y ./c++.at:1363: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1363: $PREPARSER ./input aaaae ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1066: ./check ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS 708. cxx-type.at:426: testing GLR: Resolve ambiguity, pure, locations ... ./cxx-type.at:427: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y ./c++.at:1363: $PREPARSER ./input aaaaT stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaR stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: types.y:87.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./cxx-type.at:427: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS stderr: stdout: ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./cxx-type.at:423: $PREPARSER ./types test-input ./c++.at:1065: $PREPARSER ./input < in stderr: stderr: syntax error error: invalid expression ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:423: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:423: $PREPARSER ./types -p test-input ./c++.at:1065: $PREPARSER ./input < in stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () stderr: ./cxx-type.at:423: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () 707. cxx-type.at:420: ok ======== Testing with C++ standard flags: '' ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in 709. cxx-type.at:432: testing GLR: Merge conflicting parses, impure, no locations ... stderr: error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 682. c++.at:1064: ok ./cxx-type.at:433: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y stderr: types.y:77.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./cxx-type.at:433: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS stderr: stdout: ./c++.at:857: $PREPARSER ./input stderr: 710. cxx-type.at:438: testing GLR: Merge conflicting parses, impure, locations ... ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:439: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y ======== Testing with C++ standard flags: '' ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: types.y:87.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./cxx-type.at:439: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS stderr: stderr: stdout: stdout: ./cxx-type.at:429: $PREPARSER ./types test-input ./c++.at:851: $PREPARSER ./input stderr: stderr: 17.5: syntax error ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:429: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 678. c++.at:848: ok ./cxx-type.at:429: $PREPARSER ./types -p test-input stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) ./cxx-type.at:429: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) 708. cxx-type.at:426: ok 711. cxx-type.at:444: testing GLR: Merge conflicting parses, pure, no locations ... ./cxx-type.at:445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y stderr: types.y:77.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./cxx-type.at:445: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS 712. cxx-type.at:449: testing GLR: Merge conflicting parses, pure, locations ... ./cxx-type.at:450: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y stderr: stdout: stderr: types.y:87.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./c++.at:1362: $PREPARSER ./input aaaas stderr: ./cxx-type.at:450: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1360: $PREPARSER ./input aaaas stderr: ./c++.at:1362: $PREPARSER ./input aaaal exception caught: reduction stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaal stderr: ./c++.at:1362: $PREPARSER ./input i exception caught: yylex ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input i stderr: ./c++.at:1362: $PREPARSER ./input aaaap stderr: exception caught: initial-action ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: stdout: ./c++.at:1360: $PREPARSER ./input aaaap stderr: stderr: ./c++.at:1361: $PREPARSER ./input aaaas ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc1017cf0->Object::Object { } 0xffffc1017df0->Object::Object { 0xffffc1017cf0 } 0xffffc1017cf0->Object::~Object { 0xffffc1017cf0, 0xffffc1017df0 } Next token is token 'a' (0xffffc1017df0 'a') 0xffffc1017d30->Object::Object { 0xffffc1017df0 } 0xffffc1017df0->Object::~Object { 0xffffc1017d30, 0xffffc1017df0 } Shifting token 'a' (0xffffc1017d30 'a') 0xaaaadfe9c2e0->Object::Object { 0xffffc1017d30 } 0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017d30 } Entering state 2 Stack now 0 2 0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadfe9c2e0 'a') -> $$ = nterm item (0xffffc1017e10 'a') 0xaaaadfe9c2e0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017e10 } 0xaaaadfe9c2e0->Object::Object { 0xffffc1017e10 } 0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017e10 } Entering state 11 Stack now 0 11 Reading a token 0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0 } 0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017cf0 } 0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017cf0, 0xffffc1017df0 } Next token is token 'a' (0xffffc1017df0 'a') 0xffffc1017d30->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017df0 } 0xffffc1017df0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017d30, 0xffffc1017df0 } Shifting token 'a' (0xffffc1017d30 'a') 0xaaaadfe9c300->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017d30 } 0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017d30 } Entering state 2 Stack now 0 11 2 0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadfe9c300 'a') -> $$ = nterm item (0xffffc1017e10 'a') 0xaaaadfe9c300->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017e10 } 0xaaaadfe9c300->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017e10 } 0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017e10 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300 } 0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017cf0 } 0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017cf0, 0xffffc1017df0 } Next token is token 'a' (0xffffc1017df0 'a') 0xffffc1017d30->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017df0 } 0xffffc1017df0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017d30, 0xffffc1017df0 } Shifting token 'a' (0xffffc1017d30 'a') 0xaaaadfe9c320->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017d30 } 0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017d30 } Entering state 2 Stack now 0 11 11 2 0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadfe9c320 'a') -> $$ = nterm item (0xffffc1017e10 'a') 0xaaaadfe9c320->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017e10 } 0xaaaadfe9c320->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017e10 } 0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017e10 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320 } 0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017cf0 } 0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017cf0, 0xffffc1017df0 } Next token is token 'a' (0xffffc1017df0 'a') 0xffffc1017d30->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017df0 } 0xffffc1017df0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017d30, 0xffffc1017df0 } Shifting token 'a' (0xffffc1017d30 'a') 0xaaaadfe9c340->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017d30 } 0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017d30 } Entering state 2 Stack now 0 11 11 11 2 0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadfe9c340 'a') -> $$ = nterm item (0xffffc1017e10 'a') 0xaaaadfe9c340->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017e10 } 0xaaaadfe9c340->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017e10 } 0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017e10 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340 } 0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017cf0 } 0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017cf0, 0xffffc1017df0 } Next token is token 'p' (0xffffc1017df0 'p'Exception caught: cleaning lookahead and stack 0xaaaadfe9c340->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017df0 } 0xaaaadfe9c320->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017df0 } 0xaaaadfe9c300->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017df0 } 0xaaaadfe9c2e0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017df0 } 0xffffc1017df0->Object::~Object { 0xffffc1017df0 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: reduction ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:435: $PREPARSER ./types test-input ./c++.at:1360: $PREPARSER ./input --debug aaaap stderr: stderr: ./c++.at:1361: $PREPARSER ./input aaaal syntax error Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc1017cf0->Object::Object { } 0xffffc1017df0->Object::Object { 0xffffc1017cf0 } 0xffffc1017cf0->Object::~Object { 0xffffc1017cf0, 0xffffc1017df0 } Next token is token 'a' (0xffffc1017df0 'a') 0xffffc1017d30->Object::Object { 0xffffc1017df0 } 0xffffc1017df0->Object::~Object { 0xffffc1017d30, 0xffffc1017df0 } Shifting token 'a' (0xffffc1017d30 'a') 0xaaaadfe9c2e0->Object::Object { 0xffffc1017d30 } 0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017d30 } Entering state 2 Stack now 0 2 0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadfe9c2e0 'a') -> $$ = nterm item (0xffffc1017e10 'a') 0xaaaadfe9c2e0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017e10 } 0xaaaadfe9c2e0->Object::Object { 0xffffc1017e10 } 0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017e10 } Entering state 11 Stack now 0 11 Reading a token 0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0 } 0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017cf0 } 0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017cf0, 0xffffc1017df0 } Next token is token 'a' (0xffffc1017df0 'a') 0xffffc1017d30->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017df0 } 0xffffc1017df0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017d30, 0xffffc1017df0 } Shifting token 'a' (0xffffc1017d30 'a') 0xaaaadfe9c300->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017d30 } 0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017d30 } Entering state 2 Stack now 0 11 2 0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadfe9c300 'a') -> $$ = nterm item (0xffffc1017e10 'a') 0xaaaadfe9c300->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017e10 } 0xaaaadfe9c300->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017e10 } 0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017e10 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300 } 0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017cf0 } 0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017cf0, 0xffffc1017df0 } Next token is token 'a' (0xffffc1017df0 'a') 0xffffc1017d30->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017df0 } 0xffffc1017df0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017d30, 0xffffc1017df0 } Shifting token 'a' (0xffffc1017d30 'a') 0xaaaadfe9c320->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017d30 } 0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017d30 } Entering state 2 Stack now 0 11 11 2 0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadfe9c320 'a') -> $$ = nterm item (0xffffc1017e10 'a') 0xaaaadfe9c320->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017e10 } 0xaaaadfe9c320->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017e10 } 0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017e10 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320 } 0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017cf0 } 0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017cf0, 0xffffc1017df0 } Next token is token 'a' (0xffffc1017df0 'a') 0xffffc1017d30->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017df0 } 0xffffc1017df0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017d30, 0xffffc1017df0 } Shifting token 'a' (0xffffc1017d30 'a') 0xaaaadfe9c340->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017d30 } 0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017d30 } Entering state 2 Stack now 0 11 11 11 2 0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaadfe9c340 'a') -> $$ = nterm item (0xffffc1017e10 'a') 0xaaaadfe9c340->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017e10 } 0xaaaadfe9c340->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017e10 } 0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017e10 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340 } 0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017cf0 } 0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017cf0, 0xffffc1017df0 } Next token is token 'p' (0xffffc1017df0 'p'Exception caught: cleaning lookahead and stack 0xaaaadfe9c340->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017df0 } 0xaaaadfe9c320->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017df0 } 0xaaaadfe9c300->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017df0 } 0xaaaadfe9c2e0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017df0 } 0xffffc1017df0->Object::~Object { 0xffffc1017df0 } exception caught: printer end { } ./c++.at:1362: grep '^exception caught: printer$' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae43d8f40->Object::Object { } Next token is token 'a' (0xaaaae43d8f40 'a') Shifting token 'a' (0xaaaae43d8f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae43d8f40 'a') -> $$ = nterm item (0xaaaae43d8f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaae43d8f90->Object::Object { 0xaaaae43d8f40 } Next token is token 'a' (0xaaaae43d8f90 'a') Shifting token 'a' (0xaaaae43d8f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae43d8f90 'a') -> $$ = nterm item (0xaaaae43d8f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaae43d8fe0->Object::Object { 0xaaaae43d8f40, 0xaaaae43d8f90 } Next token is token 'a' (0xaaaae43d8fe0 'a') Shifting token 'a' (0xaaaae43d8fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae43d8fe0 'a') -> $$ = nterm item (0xaaaae43d8fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaae43d9030->Object::Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0 } Next token is token 'a' (0xaaaae43d9030 'a') Shifting token 'a' (0xaaaae43d9030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae43d9030 'a') -> $$ = nterm item (0xaaaae43d9030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaae43d9080->Object::Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0, 0xaaaae43d9030 } Next token is token 'p' (0xaaaae43d9080 'p'Exception caught: cleaning lookahead and stack 0xaaaae43d9080->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0, 0xaaaae43d9030, 0xaaaae43d9080 } 0xaaaae43d9030->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0, 0xaaaae43d9030 } 0xaaaae43d8fe0->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0 } 0xaaaae43d8f90->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90 } 0xaaaae43d8f40->Object::~Object { 0xaaaae43d8f40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: yylex ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae43d8f40->Object::Object { } Next token is token 'a' (0xaaaae43d8f40 'a') Shifting token 'a' (0xaaaae43d8f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae43d8f40 'a') -> $$ = nterm item (0xaaaae43d8f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaae43d8f90->Object::Object { 0xaaaae43d8f40 } Next token is token 'a' (0xaaaae43d8f90 'a') Shifting token 'a' (0xaaaae43d8f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae43d8f90 'a') -> $$ = nterm item (0xaaaae43d8f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaae43d8fe0->Object::Object { 0xaaaae43d8f40, 0xaaaae43d8f90 } Next token is token 'a' (0xaaaae43d8fe0 'a') Shifting token 'a' (0xaaaae43d8fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae43d8fe0 'a') -> $$ = nterm item (0xaaaae43d8fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaae43d9030->Object::Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0 } Next token is token 'a' (0xaaaae43d9030 'a') Shifting token 'a' (0xaaaae43d9030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae43d9030 'a') -> $$ = nterm item (0xaaaae43d9030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaae43d9080->Object::Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0, 0xaaaae43d9030 } Next token is token 'p' (0xaaaae43d9080 'p'Exception caught: cleaning lookahead and stack 0xaaaae43d9080->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0, 0xaaaae43d9030, 0xaaaae43d9080 } 0xaaaae43d9030->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0, 0xaaaae43d9030 } 0xaaaae43d8fe0->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0 } 0xaaaae43d8f90->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90 } 0xaaaae43d8f40->Object::~Object { 0xaaaae43d8f40 } exception caught: printer end { } ./c++.at:1360: grep '^exception caught: printer$' stderr exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae stdout: stderr: exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaE stderr: ./cxx-type.at:435: $PREPARSER ./types -p test-input exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () ./c++.at:1362: $PREPARSER ./input aaaaT ./cxx-type.at:435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input i stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () stderr: stderr: ./c++.at:1360: $PREPARSER ./input aaaaE 709. cxx-type.at:432: ok ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: $PREPARSER ./input aaaap ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaR ./c++.at:1361: $PREPARSER ./input --debug aaaap ./c++.at:1360: $PREPARSER ./input aaaaT stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae3ef4f40->Object::Object { } Next token is token 'a' (0xaaaae3ef4f40 'a') Shifting token 'a' (0xaaaae3ef4f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae3ef4f40 'a') -> $$ = nterm item (0xaaaae3ef4f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaae3ef4f90->Object::Object { 0xaaaae3ef4f40 } Next token is token 'a' (0xaaaae3ef4f90 'a') Shifting token 'a' (0xaaaae3ef4f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae3ef4f90 'a') -> $$ = nterm item (0xaaaae3ef4f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaae3ef4fe0->Object::Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90 } Next token is token 'a' (0xaaaae3ef4fe0 'a') Shifting token 'a' (0xaaaae3ef4fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae3ef4fe0 'a') -> $$ = nterm item (0xaaaae3ef4fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaae3ef5030->Object::Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0 } Next token is token 'a' (0xaaaae3ef5030 'a') Shifting token 'a' (0xaaaae3ef5030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae3ef5030 'a') -> $$ = nterm item (0xaaaae3ef5030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaae3ef5080->Object::Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0, 0xaaaae3ef5030 } Next token is token 'p' (0xaaaae3ef5080 'p'Exception caught: cleaning lookahead and stack 0xaaaae3ef5080->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0, 0xaaaae3ef5030, 0xaaaae3ef5080 } 0xaaaae3ef5030->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0, 0xaaaae3ef5030 } 0xaaaae3ef4fe0->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0 } 0xaaaae3ef4f90->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90 } 0xaaaae3ef4f40->Object::~Object { 0xaaaae3ef4f40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae3ef4f40->Object::Object { } Next token is token 'a' (0xaaaae3ef4f40 'a') Shifting token 'a' (0xaaaae3ef4f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae3ef4f40 'a') -> $$ = nterm item (0xaaaae3ef4f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaae3ef4f90->Object::Object { 0xaaaae3ef4f40 } Next token is token 'a' (0xaaaae3ef4f90 'a') Shifting token 'a' (0xaaaae3ef4f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae3ef4f90 'a') -> $$ = nterm item (0xaaaae3ef4f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaae3ef4fe0->Object::Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90 } Next token is token 'a' (0xaaaae3ef4fe0 'a') Shifting token 'a' (0xaaaae3ef4fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae3ef4fe0 'a') -> $$ = nterm item (0xaaaae3ef4fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaae3ef5030->Object::Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0 } Next token is token 'a' (0xaaaae3ef5030 'a') Shifting token 'a' (0xaaaae3ef5030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae3ef5030 'a') -> $$ = nterm item (0xaaaae3ef5030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaae3ef5080->Object::Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0, 0xaaaae3ef5030 } Next token is token 'p' (0xaaaae3ef5080 'p'Exception caught: cleaning lookahead and stack 0xaaaae3ef5080->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0, 0xaaaae3ef5030, 0xaaaae3ef5080 } 0xaaaae3ef5030->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0, 0xaaaae3ef5030 } 0xaaaae3ef4fe0->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0 } 0xaaaae3ef4f90->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90 } 0xaaaae3ef4f40->Object::~Object { 0xaaaae3ef4f40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1361: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1361: $PREPARSER ./input aaaaE ./c++.at:1360: $PREPARSER ./input aaaaR stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaT ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaR stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' 713. cxx-type.at:455: testing GLR: Verbose messages, resolve ambiguity, impure, no locations ... ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ======== Testing with C++ standard flags: '' ./cxx-type.at:456: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: types.y:77.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./cxx-type.at:456: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS stderr: stdout: ./cxx-type.at:441: $PREPARSER ./types test-input stderr: 17.5: syntax error stderr: stdout: ./c++.at:1555: $PREPARSER ./test ./cxx-type.at:441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 691. c++.at:1517: ok ./cxx-type.at:441: $PREPARSER ./types -p test-input stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (13.3: ) -> $$ = nterm expr (13.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (13.0: ) $2 = token '(' (13.2: ) $3 = nterm expr (13.3: ) $4 = token ')' (13.4: ) -> $$ = nterm expr (13.0-4: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (13.0-4: ) $2 = token ';' (13.5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.3: ) -> $$ = nterm expr (15.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (15.0: ) $2 = token '(' (15.2: ) $3 = nterm expr (15.3: ) $4 = token ')' (15.4: ) -> $$ = nterm expr (15.0-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 10 (line 94): $1 = nterm expr (15.0-4: ) $2 = token '=' (15.6: ) $3 = nterm expr (15.8-12: ) -> $$ = nterm expr (15.0-12: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (15.0-12: ) $2 = token ';' (15.13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) ./cxx-type.at:441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: 714. glr-regression.at:205: testing Badly Collapsed GLR States: glr.c ... Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (13.3: ) -> $$ = nterm expr (13.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (13.0: ) $2 = token '(' (13.2: ) $3 = nterm expr (13.3: ) $4 = token ')' (13.4: ) -> $$ = nterm expr (13.0-4: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (13.0-4: ) $2 = token ';' (13.5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.3: ) -> $$ = nterm expr (15.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (15.0: ) $2 = token '(' (15.2: ) $3 = nterm expr (15.3: ) $4 = token ')' (15.4: ) -> $$ = nterm expr (15.0-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 10 (line 94): $1 = nterm expr (15.0-4: ) $2 = token '=' (15.6: ) $3 = nterm expr (15.8-12: ) -> $$ = nterm expr (15.0-12: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (15.0-12: ) $2 = token ';' (15.13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) ./cxx-type.at:447: $PREPARSER ./types test-input ./glr-regression.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o glr-regr1.c glr-regr1.y stderr: 710. cxx-type.at:438: ok stdout: stderr: syntax error ./c++.at:1363: $PREPARSER ./input aaaas stderr: ./cxx-type.at:447: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:447: $PREPARSER ./types -p test-input ./c++.at:1363: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input i stderr: stderr: exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -./glr-regression.at:205: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr1 glr-regr1.c $LIBS > $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () ./c++.at:1363: $PREPARSER ./input aaaap ./cxx-type.at:447: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc7383f50->Object::Object { } 0xffffc7384050->Object::Object { 0xffffc7383f50 } 0xffffc7383f50->Object::~Object { 0xffffc7383f50, 0xffffc7384050 } Next token is token 'a' (0xffffc7384050 'a') 0xffffc7383f90->Object::Object { 0xffffc7384050 } 0xffffc7384050->Object::~Object { 0xffffc7383f90, 0xffffc7384050 } Shifting token 'a' (0xffffc7383f90 'a') 0xaaaaddfd62e0->Object::Object { 0xffffc7383f90 } 0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xffffc7383f90 } Entering state 1 Stack now 0 1 0xffffc7384070->Object::Object { 0xaaaaddfd62e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaddfd62e0 'a') -> $$ = nterm item (0xffffc7384070 'a') 0xaaaaddfd62e0->Object::~Object { 0xaaaaddfd62e0, 0xffffc7384070 } 0xaaaaddfd62e0->Object::Object { 0xffffc7384070 } 0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xffffc7384070 } Entering state 10 Stack now 0 10 Reading a token 0xffffc7383f50->Object::Object { 0xaaaaddfd62e0 } 0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xffffc7383f50 } 0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xffffc7383f50, 0xffffc7384050 } Next token is token 'a' (0xffffc7384050 'a') 0xffffc7383f90->Object::Object { 0xaaaaddfd62e0, 0xffffc7384050 } 0xffffc7384050->Object::~Object { 0xaaaaddfd62e0, 0xffffc7383f90, 0xffffc7384050 } Shifting token 'a' (0xffffc7383f90 'a') 0xaaaaddfd6300->Object::Object { 0xaaaaddfd62e0, 0xffffc7383f90 } 0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f90 } Entering state 1 Stack now 0 10 1 0xffffc7384070->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaddfd6300 'a') -> $$ = nterm item (0xffffc7384070 'a') 0xaaaaddfd6300->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384070 } 0xaaaaddfd6300->Object::Object { 0xaaaaddfd62e0, 0xffffc7384070 } 0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384070 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffc7383f50->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300 } 0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f50 } 0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f50, 0xffffc7384050 } Next token is token 'a' (0xffffc7384050 'a') 0xffffc7383f90->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384050 } 0xffffc7384050->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f90, 0xffffc7384050 } Shifting token 'a' (0xffffc7383f90 'a') 0xaaaaddfd6320->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f90 } 0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f90 } Entering state 1 Stack now 0 10 10 1 0xffffc7384070->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaddfd6320 'a') -> $$ = nterm item (0xffffc7384070 'a') 0xaaaaddfd6320->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384070 } 0xaaaaddfd6320->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384070 } 0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384070 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffc7383f50->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320 } 0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f50 } 0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f50, 0xffffc7384050 } Next token is token 'a' (0xffffc7384050 'a') 0xffffc7383f90->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384050 } 0xffffc7384050->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f90, 0xffffc7384050 } Shifting token 'a' (0xffffc7383f90 'a') 0xaaaaddfd6340->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f90 } 0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7383f90 } Entering state 1 Stack now 0 10 10 10 1 0xffffc7384070->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaddfd6340 'a') -> $$ = nterm item (0xffffc7384070 'a') 0xaaaaddfd6340->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7384070 } 0xaaaaddfd6340->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384070 } 0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7384070 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffc7383f50->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340 } 0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7383f50 } 0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7383f50, 0xffffc7384050 } Next token is token 'p' (0xffffc7384050 'p'Exception caught: cleaning lookahead and stack 0xaaaaddfd6340->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7384050 } 0xaaaaddfd6320->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384050 } 0xaaaaddfd6300->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384050 } 0xaaaaddfd62e0->Object::~Object { 0xaaaaddfd62e0, 0xffffc7384050 } 0xffffc7384050->Object::~Object { 0xffffc7384050 } exception caught: printer end { } ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc7383f50->Object::Object { } 0xffffc7384050->Object::Object { 0xffffc7383f50 } 0xffffc7383f50->Object::~Object { 0xffffc7383f50, 0xffffc7384050 } Next token is token 'a' (0xffffc7384050 'a') 0xffffc7383f90->Object::Object { 0xffffc7384050 } 0xffffc7384050->Object::~Object { 0xffffc7383f90, 0xffffc7384050 } Shifting token 'a' (0xffffc7383f90 'a') 0xaaaaddfd62e0->Object::Object { 0xffffc7383f90 } 0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xffffc7383f90 } Entering state 1 Stack now 0 1 0xffffc7384070->Object::Object { 0xaaaaddfd62e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaddfd62e0 'a') -> $$ = nterm item (0xffffc7384070 'a') 0xaaaaddfd62e0->Object::~Object { 0xaaaaddfd62e0, 0xffffc7384070 } 0xaaaaddfd62e0->Object::Object { 0xffffc7384070 } 0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xffffc7384070 } Entering state 10 Stack now 0 10 Reading a token 0xffffc7383f50->Object::Object { 0xaaaaddfd62e0 } 0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xffffc7383f50 } 0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xffffc7383f50, 0xffffc7384050 } Next token is token 'a' (0xffffc7384050 'a') 0xffffc7383f90->Object::Object { 0xaaaaddfd62e0, 0xffffc7384050 } 0xffffc7384050->Object::~Object { 0xaaaaddfd62e0, 0xffffc7383f90, 0xffffc7384050 } Shifting token 'a' (0xffffc7383f90 'a') 0xaaaaddfd6300->Object::Object { 0xaaaaddfd62e0, 0xffffc7383f90 } 0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f90 } Entering state 1 Stack now 0 10 1 0xffffc7384070->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaddfd6300 'a') -> $$ = nterm item (0xffffc7384070 'a') 0xaaaaddfd6300->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384070 } 0xaaaaddfd6300->Object::Object { 0xaaaaddfd62e0, 0xffffc7384070 } 0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384070 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffc7383f50->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300 } 0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f50 } 0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f50, 0xffffc7384050 } Next token is token 'a' (0xffffc7384050 'a') 0xffffc7383f90->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384050 } 0xffffc7384050->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f90, 0xffffc7384050 } Shifting token 'a' (0xffffc7383f90 'a') 0xaaaaddfd6320->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f90 } 0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f90 } Entering state 1 Stack now 0 10 10 1 0xffffc7384070->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaddfd6320 'a') -> $$ = nterm item (0xffffc7384070 'a') 0xaaaaddfd6320->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384070 } 0xaaaaddfd6320->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384070 } 0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384070 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffc7383f50->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320 } 0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f50 } 0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f50, 0xffffc7384050 } Next token is token 'a' (0xffffc7384050 'a') 0xffffc7383f90->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384050 } 0xffffc7384050->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f90, 0xffffc7384050 } Shifting token 'a' (0xffffc7383f90 'a') 0xaaaaddfd6340->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f90 } 0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7383f90 } Entering state 1 Stack now 0 10 10 10 1 0xffffc7384070->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaddfd6340 'a') -> $$ = nterm item (0xffffc7384070 'a') 0xaaaaddfd6340->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7384070 } 0xaaaaddfd6340->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384070 } 0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7384070 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffc7383f50->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340 } 0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7383f50 } 0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7383f50, 0xffffc7384050 } Next token is token 'p' (0xffffc7384050 'p'Exception caught: cleaning lookahead and stack 0xaaaaddfd6340->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7384050 } 0xaaaaddfd6320->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384050 } 0xaaaaddfd6300->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384050 } 0xaaaaddfd62e0->Object::~Object { 0xaaaaddfd62e0, 0xffffc7384050 } 0xffffc7384050->Object::~Object { 0xffffc7384050 } exception caught: printer end { } ./c++.at:1363: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1363: $PREPARSER ./input aaaae stderr: stderr: exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () 711. cxx-type.at:444: ok 715. glr-regression.at:206: testing Badly Collapsed GLR States: glr.cc ... ./glr-regression.at:206: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o glr-regr1.cc glr-regr1.y ./c++.at:1363: $PREPARSER ./input aaaaE ./glr-regression.at:206: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr1 glr-regr1.cc $LIBS stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaT stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaR stderr: 716. glr-regression.at:207: testing Badly Collapsed GLR States: glr2.cc ... ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:207: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o glr-regr1.cc glr-regr1.y ======== Testing with C++ standard flags: '' ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./glr-regression.at:207: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr1 glr-regr1.cc $LIBS stderr: stdout: ./cxx-type.at:452: $PREPARSER ./types test-input stderr: 17.5: syntax error ./cxx-type.at:452: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:452: $PREPARSER ./types -p test-input stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (13.3: ) -> $$ = nterm expr (13.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (13.0: ) $2 = token '(' (13.2: ) $3 = nterm expr (13.3: ) $4 = token ')' (13.4: ) -> $$ = nterm expr (13.0-4: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (13.0-4: ) $2 = token ';' (13.5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.3: ) -> $$ = nterm expr (15.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (15.0: ) $2 = token '(' (15.2: ) $3 = nterm expr (15.3: ) $4 = token ')' (15.4: ) -> $$ = nterm expr (15.0-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 10 (line 94): $1 = nterm expr (15.0-4: ) $2 = token '=' (15.6: ) $3 = nterm expr (15.8-12: ) -> $$ = nterm expr (15.0-12: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (15.0-12: ) $2 = token ';' (15.13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) ./cxx-type.at:452: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (13.3: ) -> $$ = nterm expr (13.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (13.0: ) $2 = token '(' (13.2: ) $3 = nterm expr (13.3: ) $4 = token ')' (13.4: ) -> $$ = nterm expr (13.0-4: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (13.0-4: ) $2 = token ';' (13.5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.3: ) -> $$ = nterm expr (15.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (15.0: ) $2 = token '(' (15.2: ) $3 = nterm expr (15.3: ) $4 = token ')' (15.4: ) -> $$ = nterm expr (15.0-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 10 (line 94): $1 = nterm expr (15.0-4: ) $2 = token '=' (15.6: ) $3 = nterm expr (15.8-12: ) -> $$ = nterm expr (15.0-12: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (15.0-12: ) $2 = token ';' (15.13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) 712. cxx-type.at:449: ok stderr: stdout: 717. glr-regression.at:354: testing Improper handling of embedded actions and dollar(-N) in GLR parsers: glr.c ... ./cxx-type.at:458: $PREPARSER ./types test-input stderr: stdout: stderr: ./glr-regression.at:354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr2a.c glr-regr2a.y ./glr-regression.at:205: $PREPARSER ./glr-regr1 BPBPB stderr: syntax error, unexpected ID, expecting '=' or '+' or ')' ./cxx-type.at:458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:205: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:354: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr2a glr-regr2a.c $LIBS 714. glr-regression.at:205: ok stderr: stdout: ./c++.at:857: $PREPARSER ./input stderr: ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:858: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ./cxx-type.at:458: $PREPARSER ./types -p test-input stderr: ======== Testing with C++ standard flags: '' ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error, unexpected ID, expecting '=' or '+' or ')' Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () ./cxx-type.at:458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 718. glr-regression.at:355: testing Improper handling of embedded actions and dollar(-N) in GLR parsers: glr.cc ... ./glr-regression.at:355: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr2a.cc glr-regr2a.y Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error, unexpected ID, expecting '=' or '+' or ')' Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () 713. cxx-type.at:455: ok ./glr-regression.at:355: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr2a glr-regr2a.cc $LIBS 719. glr-regression.at:356: testing Improper handling of embedded actions and dollar(-N) in GLR parsers: glr2.cc ... ./glr-regression.at:356: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr2a.cc glr-regr2a.y ./glr-regression.at:356: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr2a glr-regr2a.cc $LIBS stderr: stdout: ./glr-regression.at:206: $PREPARSER ./glr-regr1 BPBPB stderr: ./glr-regression.at:206: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 715. glr-regression.at:206: ok stderr: stdout: ./c++.at:858: $PREPARSER ./input stderr: ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 720. glr-regression.at:488: testing Improper merging of GLR delayed action sets: glr.c ... ./glr-regression.at:488: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr3.c glr-regr3.y ======== Testing with C++ standard flags: '' ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: stderr: stdout: ./glr-regression.at:354: $PREPARSER ./glr-regr2a input1.txt stderr: ./c++.at:1066: $PREPARSER ./input < in stderr: ./glr-regression.at:354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:488: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr3 glr-regr3.c $LIBS error: invalid expression caught error error: invalid character caught error ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:354: $PREPARSER ./glr-regr2a input2.txt stderr: ./c++.at:1066: $PREPARSER ./input < in ./glr-regression.at:354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: invalid expression ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:354: $PREPARSER ./glr-regr2a input3.txt stderr: ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 717. glr-regression.at:354: ok stderr: stdout: ./c++.at:1362: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 721. glr-regression.at:489: testing Improper merging of GLR delayed action sets: glr.cc ... ./glr-regression.at:489: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr3.cc glr-regr3.y stderr: stdout: ./c++.at:1362: $PREPARSER ./input aaaap stderr: ./c++.at:1066: ./check ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffd43f7710->Object::Object { } 0xffffd43f7810->Object::Object { 0xffffd43f7710 } 0xffffd43f7710->Object::~Object { 0xffffd43f7710, 0xffffd43f7810 } Next token is token 'a' (0xffffd43f7810 'a') 0xffffd43f7750->Object::Object { 0xffffd43f7810 } 0xffffd43f7810->Object::~Object { 0xffffd43f7750, 0xffffd43f7810 } Shifting token 'a' (0xffffd43f7750 'a') 0xaaaaba1992e0->Object::Object { 0xffffd43f7750 } 0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7750 } Entering state 2 Stack now 0 2 0xffffd43f7830->Object::Object { 0xaaaaba1992e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaba1992e0 'a') -> $$ = nterm item (0xffffd43f7830 'a') 0xaaaaba1992e0->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7830 } 0xaaaaba1992e0->Object::Object { 0xffffd43f7830 } 0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7830 } Entering state 11 Stack now 0 11 Reading a token 0xffffd43f7710->Object::Object { 0xaaaaba1992e0 } 0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xffffd43f7710 } 0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7710, 0xffffd43f7810 } Next token is token 'a' (0xffffd43f7810 'a') 0xffffd43f7750->Object::Object { 0xaaaaba1992e0, 0xffffd43f7810 } 0xffffd43f7810->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7750, 0xffffd43f7810 } Shifting token 'a' (0xffffd43f7750 'a') 0xaaaaba199300->Object::Object { 0xaaaaba1992e0, 0xffffd43f7750 } 0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7750 } Entering state 2 Stack now 0 11 2 0xffffd43f7830->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaba199300 'a') -> $$ = nterm item (0xffffd43f7830 'a') 0xaaaaba199300->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7830 } 0xaaaaba199300->Object::Object { 0xaaaaba1992e0, 0xffffd43f7830 } 0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7830 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffd43f7710->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300 } 0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7710 } 0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7710, 0xffffd43f7810 } Next token is token 'a' (0xffffd43f7810 'a') 0xffffd43f7750->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7810 } 0xffffd43f7810->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7750, 0xffffd43f7810 } Shifting token 'a' (0xffffd43f7750 'a') 0xaaaaba199320->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7750 } 0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7750 } Entering state 2 Stack now 0 11 11 2 0xffffd43f7830->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaba199320 'a') -> $$ = nterm item (0xffffd43f7830 'a') 0xaaaaba199320->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7830 } 0xaaaaba199320->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7830 } 0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7830 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffd43f7710->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320 } 0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7710 } 0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7710, 0xffffd43f7810 } Next token is token 'a' (0xffffd43f7810 'a') 0xffffd43f7750->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7810 } 0xffffd43f7810->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7750, 0xffffd43f7810 } Shifting token 'a' (0xffffd43f7750 'a') 0xaaaaba199340->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7750 } 0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7750 } Entering state 2 Stack now 0 11 11 11 2 0xffffd43f7830->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaba199340 'a') -> $$ = nterm item (0xffffd43f7830 'a') 0xaaaaba199340->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7830 } 0xaaaaba199340->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7830 } 0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7830 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffd43f7710->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340 } 0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7710 } 0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7710, 0xffffd43f7810 } Next token is token 'p' (0xffffd43f7810 'p'Exception caught: cleaning lookahead and stack 0xaaaaba199340->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7810 } 0xaaaaba199320->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7810 } 0xaaaaba199300->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7810 } 0xaaaaba1992e0->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7810 } 0xffffd43f7810->Object::~Object { 0xffffd43f7810 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: ./glr-regression.at:489: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr3 glr-regr3.cc $LIBS Starting parse Entering state 0 Stack now 0 Reading a token 0xffffd43f7710->Object::Object { } 0xffffd43f7810->Object::Object { 0xffffd43f7710 } 0xffffd43f7710->Object::~Object { 0xffffd43f7710, 0xffffd43f7810 } Next token is token 'a' (0xffffd43f7810 'a') 0xffffd43f7750->Object::Object { 0xffffd43f7810 } 0xffffd43f7810->Object::~Object { 0xffffd43f7750, 0xffffd43f7810 } Shifting token 'a' (0xffffd43f7750 'a') 0xaaaaba1992e0->Object::Object { 0xffffd43f7750 } 0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7750 } Entering state 2 Stack now 0 2 0xffffd43f7830->Object::Object { 0xaaaaba1992e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaba1992e0 'a') -> $$ = nterm item (0xffffd43f7830 'a') 0xaaaaba1992e0->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7830 } 0xaaaaba1992e0->Object::Object { 0xffffd43f7830 } 0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7830 } Entering state 11 Stack now 0 11 Reading a token 0xffffd43f7710->Object::Object { 0xaaaaba1992e0 } 0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xffffd43f7710 } 0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7710, 0xffffd43f7810 } Next token is token 'a' (0xffffd43f7810 'a') 0xffffd43f7750->Object::Object { 0xaaaaba1992e0, 0xffffd43f7810 } 0xffffd43f7810->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7750, 0xffffd43f7810 } Shifting token 'a' (0xffffd43f7750 'a') 0xaaaaba199300->Object::Object { 0xaaaaba1992e0, 0xffffd43f7750 } 0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7750 } Entering state 2 Stack now 0 11 2 0xffffd43f7830->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaba199300 'a') -> $$ = nterm item (0xffffd43f7830 'a') 0xaaaaba199300->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7830 } 0xaaaaba199300->Object::Object { 0xaaaaba1992e0, 0xffffd43f7830 } 0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7830 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffd43f7710->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300 } 0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7710 } 0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7710, 0xffffd43f7810 } Next token is token 'a' (0xffffd43f7810 'a') 0xffffd43f7750->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7810 } 0xffffd43f7810->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7750, 0xffffd43f7810 } Shifting token 'a' (0xffffd43f7750 'a') 0xaaaaba199320->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7750 } 0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7750 } Entering state 2 Stack now 0 11 11 2 0xffffd43f7830->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaba199320 'a') -> $$ = nterm item (0xffffd43f7830 'a') 0xaaaaba199320->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7830 } 0xaaaaba199320->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7830 } 0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7830 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffd43f7710->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320 } 0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7710 } 0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7710, 0xffffd43f7810 } Next token is token 'a' (0xffffd43f7810 'a') 0xffffd43f7750->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7810 } 0xffffd43f7810->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7750, 0xffffd43f7810 } Shifting token 'a' (0xffffd43f7750 'a') 0xaaaaba199340->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7750 } 0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7750 } Entering state 2 Stack now 0 11 11 11 2 0xffffd43f7830->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaba199340 'a') -> $$ = nterm item (0xffffd43f7830 'a') 0xaaaaba199340->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7830 } 0xaaaaba199340->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7830 } 0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7830 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffd43f7710->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340 } 0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7710 } 0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7710, 0xffffd43f7810 } Next token is token 'p' (0xffffd43f7810 'p'Exception caught: cleaning lookahead and stack 0xaaaaba199340->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7810 } 0xaaaaba199320->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7810 } 0xaaaaba199300->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7810 } 0xaaaaba1992e0->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7810 } 0xffffd43f7810->Object::~Object { 0xffffd43f7810 } exception caught: printer end { } ./c++.at:1362: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./glr-regression.at:355: $PREPARSER ./glr-regr2a input1.txt stderr: ./glr-regression.at:355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:355: $PREPARSER ./glr-regr2a input2.txt stderr: ./glr-regression.at:355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./glr-regression.at:355: $PREPARSER ./glr-regr2a input3.txt stderr: ./c++.at:1362: $PREPARSER ./input aaaaE stdout: ./glr-regression.at:355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1065: $PREPARSER ./input < in 718. glr-regression.at:355: ok ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in ./c++.at:1362: $PREPARSER ./input aaaaT stderr: stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaR stderr: stdout: stderr: ./c++.at:1363: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 683. c++.at:1065: ok ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 722. glr-regression.at:490: testing Improper merging of GLR delayed action sets: glr2.cc ... ======== Testing with C++ standard flags: '' ./glr-regression.at:490: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr3.cc glr-regr3.y ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1363: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaap stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:490: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr3 glr-regr3.cc $LIBS 723. glr-regression.at:592: testing Duplicate representation of merged trees: %union { char *ptr; } glr.c ... ./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: ./glr-regression.at:592: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.c glr-regr4.y stdout: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffe877f390->Object::Object { } 0xffffe877f490->Object::Object { 0xffffe877f390 } 0xffffe877f390->Object::~Object { 0xffffe877f390, 0xffffe877f490 } Next token is token 'a' (0xffffe877f490 'a') 0xffffe877f3d0->Object::Object { 0xffffe877f490 } 0xffffe877f490->Object::~Object { 0xffffe877f3d0, 0xffffe877f490 } Shifting token 'a' (0xffffe877f3d0 'a') 0xaaaae3a232e0->Object::Object { 0xffffe877f3d0 } 0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f3d0 } Entering state 1 Stack now 0 1 0xffffe877f4b0->Object::Object { 0xaaaae3a232e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae3a232e0 'a') -> $$ = nterm item (0xffffe877f4b0 'a') 0xaaaae3a232e0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f4b0 } 0xaaaae3a232e0->Object::Object { 0xffffe877f4b0 } 0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f4b0 } Entering state 10 Stack now 0 10 Reading a token 0xffffe877f390->Object::Object { 0xaaaae3a232e0 } 0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xffffe877f390 } 0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xffffe877f390, 0xffffe877f490 } Next token is token 'a' (0xffffe877f490 'a') 0xffffe877f3d0->Object::Object { 0xaaaae3a232e0, 0xffffe877f490 } 0xffffe877f490->Object::~Object { 0xaaaae3a232e0, 0xffffe877f3d0, 0xffffe877f490 } Shifting token 'a' (0xffffe877f3d0 'a') 0xaaaae3a23300->Object::Object { 0xaaaae3a232e0, 0xffffe877f3d0 } 0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f3d0 } Entering state 1 Stack now 0 10 1 0xffffe877f4b0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae3a23300 'a') -> $$ = nterm item (0xffffe877f4b0 'a') 0xaaaae3a23300->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f4b0 } 0xaaaae3a23300->Object::Object { 0xaaaae3a232e0, 0xffffe877f4b0 } 0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f4b0 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffe877f390->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300 } 0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f390 } 0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f390, 0xffffe877f490 } Next token is token 'a' (0xffffe877f490 'a') 0xffffe877f3d0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f490 } 0xffffe877f490->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f3d0, 0xffffe877f490 } Shifting token 'a' (0xffffe877f3d0 'a') 0xaaaae3a23320->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f3d0 } 0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f3d0 } Entering state 1 Stack now 0 10 10 1 0xffffe877f4b0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae3a23320 'a') -> $$ = nterm item (0xffffe877f4b0 'a') 0xaaaae3a23320->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f4b0 } 0xaaaae3a23320->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f4b0 } 0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f4b0 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffe877f390->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320 } 0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f390 } 0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f390, 0xffffe877f490 } Next token is token 'a' (0xffffe877f490 'a') 0xffffe877f3d0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f490 } 0xffffe877f490->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f3d0, 0xffffe877f490 } Shifting token 'a' (0xffffe877f3d0 'a') 0xaaaae3a23340->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f3d0 } 0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f3d0 } Entering state 1 Stack now 0 10 10 10 1 0xffffe877f4b0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae3a23340 'a') -> $$ = nterm item (0xffffe877f4b0 'a') 0xaaaae3a23340->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f4b0 } 0xaaaae3a23340->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f4b0 } 0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f4b0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffe877f390->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340 } 0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f390 } 0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f390, 0xffffe877f490 } Next token is token 'p' (0xffffe877f490 'p'Exception caught: cleaning lookahead and stack 0xaaaae3a23340->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f490 } 0xaaaae3a23320->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f490 } 0xaaaae3a23300->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f490 } 0xaaaae3a232e0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f490 } 0xffffe877f490->Object::~Object { 0xffffe877f490 } exception caught: printer end { } ./c++.at:1360: $PREPARSER ./input aaaas stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1360: $PREPARSER ./input aaaal Starting parse Entering state 0 Stack now 0 Reading a token 0xffffe877f390->Object::Object { } 0xffffe877f490->Object::Object { 0xffffe877f390 } 0xffffe877f390->Object::~Object { 0xffffe877f390, 0xffffe877f490 } Next token is token 'a' (0xffffe877f490 'a') 0xffffe877f3d0->Object::Object { 0xffffe877f490 } 0xffffe877f490->Object::~Object { 0xffffe877f3d0, 0xffffe877f490 } Shifting token 'a' (0xffffe877f3d0 'a') 0xaaaae3a232e0->Object::Object { 0xffffe877f3d0 } 0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f3d0 } Entering state 1 Stack now 0 1 0xffffe877f4b0->Object::Object { 0xaaaae3a232e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae3a232e0 'a') -> $$ = nterm item (0xffffe877f4b0 'a') 0xaaaae3a232e0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f4b0 } 0xaaaae3a232e0->Object::Object { 0xffffe877f4b0 } 0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f4b0 } Entering state 10 Stack now 0 10 Reading a token 0xffffe877f390->Object::Object { 0xaaaae3a232e0 } 0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xffffe877f390 } 0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xffffe877f390, 0xffffe877f490 } Next token is token 'a' (0xffffe877f490 'a') 0xffffe877f3d0->Object::Object { 0xaaaae3a232e0, 0xffffe877f490 } 0xffffe877f490->Object::~Object { 0xaaaae3a232e0, 0xffffe877f3d0, 0xffffe877f490 } Shifting token 'a' (0xffffe877f3d0 'a') 0xaaaae3a23300->Object::Object { 0xaaaae3a232e0, 0xffffe877f3d0 } 0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f3d0 } Entering state 1 Stack now 0 10 1 0xffffe877f4b0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae3a23300 'a') -> $$ = nterm item (0xffffe877f4b0 'a') 0xaaaae3a23300->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f4b0 } 0xaaaae3a23300->Object::Object { 0xaaaae3a232e0, 0xffffe877f4b0 } 0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f4b0 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffe877f390->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300 } 0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f390 } 0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f390, 0xffffe877f490 } Next token is token 'a' (0xffffe877f490 'a') 0xffffe877f3d0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f490 } 0xffffe877f490->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f3d0, 0xffffe877f490 } Shifting token 'a' (0xffffe877f3d0 'a') 0xaaaae3a23320->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f3d0 } 0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f3d0 } Entering state 1 Stack now 0 10 10 1 0xffffe877f4b0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae3a23320 'a') -> $$ = nterm item (0xffffe877f4b0 'a') 0xaaaae3a23320->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f4b0 } 0xaaaae3a23320->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f4b0 } 0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f4b0 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffe877f390->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320 } 0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f390 } 0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f390, 0xffffe877f490 } Next token is token 'a' (0xffffe877f490 'a') 0xffffe877f3d0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f490 } 0xffffe877f490->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f3d0, 0xffffe877f490 } Shifting token 'a' (0xffffe877f3d0 'a') 0xaaaae3a23340->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f3d0 } 0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f3d0 } Entering state 1 Stack now 0 10 10 10 1 0xffffe877f4b0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae3a23340 'a') -> $$ = nterm item (0xffffe877f4b0 'a') 0xaaaae3a23340->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f4b0 } 0xaaaae3a23340->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f4b0 } 0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f4b0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffe877f390->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340 } 0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f390 } 0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f390, 0xffffe877f490 } Next token is token 'p' (0xffffe877f490 'p'Exception caught: cleaning lookahead and stack 0xaaaae3a23340->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f490 } 0xaaaae3a23320->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f490 } 0xaaaae3a23300->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f490 } 0xaaaae3a232e0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f490 } 0xffffe877f490->Object::~Object { 0xffffe877f490 } exception caught: printer end { } ./c++.at:1363: grep '^exception caught: printer$' stderr stderr: stdout: exception caught: yylex exception caught: printer ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: $PREPARSER ./input aaaae stderr: stdout: ./glr-regression.at:592: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr4 glr-regr4.c $LIBS exception caught: syntax error ./c++.at:1361: $PREPARSER ./input aaaas ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./c++.at:1360: $PREPARSER ./input i stdout: stderr: exception caught: reduction exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./glr-regression.at:488: $PREPARSER ./glr-regr3 input.txt ./c++.at:1363: $PREPARSER ./input aaaaE stdout: stderr: ./c++.at:858: $PREPARSER ./input stderr: stderr: ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1360: $PREPARSER ./input aaaap ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./glr-regression.at:488: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaal ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1360: $PREPARSER ./input --debug aaaap ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae011ff40->Object::Object { } Next token is token 'a' (0xaaaae011ff40 'a') Shifting token 'a' (0xaaaae011ff40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae011ff40 'a') -> $$ = nterm item (0xaaaae011ff40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaae011ff90->Object::Object { 0xaaaae011ff40 } Next token is token 'a' (0xaaaae011ff90 'a') Shifting token 'a' (0xaaaae011ff90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae011ff90 'a') -> $$ = nterm item (0xaaaae011ff90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaae011ffe0->Object::Object { 0xaaaae011ff40, 0xaaaae011ff90 } Next token is token 'a' (0xaaaae011ffe0 'a') Shifting token 'a' (0xaaaae011ffe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae011ffe0 'a') -> $$ = nterm item (0xaaaae011ffe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaae0120030->Object::Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0 } Next token is token 'a' (0xaaaae0120030 'a') Shifting token 'a' (0xaaaae0120030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae0120030 'a') -> $$ = nterm item (0xaaaae0120030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaae0120080->Object::Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0, 0xaaaae0120030 } Next token is token 'p' (0xaaaae0120080 'p'Exception caught: cleaning lookahead and stack 0xaaaae0120080->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0, 0xaaaae0120030, 0xaaaae0120080 } 0xaaaae0120030->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0, 0xaaaae0120030 } 0xaaaae011ffe0->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0 } 0xaaaae011ff90->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90 } 0xaaaae011ff40->Object::~Object { 0xaaaae011ff40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: $PREPARSER ./input aaaaT exception caught: yylex 720. glr-regression.at:488: ok ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae011ff40->Object::Object { } Next token is token 'a' (0xaaaae011ff40 'a') Shifting token 'a' (0xaaaae011ff40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae011ff40 'a') -> $$ = nterm item (0xaaaae011ff40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaae011ff90->Object::Object { 0xaaaae011ff40 } Next token is token 'a' (0xaaaae011ff90 'a') Shifting token 'a' (0xaaaae011ff90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae011ff90 'a') -> $$ = nterm item (0xaaaae011ff90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaae011ffe0->Object::Object { 0xaaaae011ff40, 0xaaaae011ff90 } Next token is token 'a' (0xaaaae011ffe0 'a') Shifting token 'a' (0xaaaae011ffe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae011ffe0 'a') -> $$ = nterm item (0xaaaae011ffe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaae0120030->Object::Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0 } Next token is token 'a' (0xaaaae0120030 'a') Shifting token 'a' (0xaaaae0120030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae0120030 'a') -> $$ = nterm item (0xaaaae0120030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaae0120080->Object::Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0, 0xaaaae0120030 } Next token is token 'p' (0xaaaae0120080 'p'Exception caught: cleaning lookahead and stack 0xaaaae0120080->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0, 0xaaaae0120030, 0xaaaae0120080 } 0xaaaae0120030->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0, 0xaaaae0120030 } 0xaaaae011ffe0->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0 } 0xaaaae011ff90->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90 } 0xaaaae011ff40->Object::~Object { 0xaaaae011ff40 } exception caught: printer end { } ./c++.at:1360: grep '^exception caught: printer$' stderr ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae ./c++.at:1363: $PREPARSER ./input aaaaR ./c++.at:1361: $PREPARSER ./input i stderr: stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' 724. glr-regression.at:593: testing Duplicate representation of merged trees: %union { char *ptr; } glr.cc ... ./glr-regression.at:593: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.cc glr-regr4.y ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaap stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaT ./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaf835cf40->Object::Object { } Next token is token 'a' (0xaaaaf835cf40 'a') Shifting token 'a' (0xaaaaf835cf40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf835cf40 'a') -> $$ = nterm item (0xaaaaf835cf40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaaf835cf90->Object::Object { 0xaaaaf835cf40 } Next token is token 'a' (0xaaaaf835cf90 'a') Shifting token 'a' (0xaaaaf835cf90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf835cf90 'a') -> $$ = nterm item (0xaaaaf835cf90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaaf835cfe0->Object::Object { 0xaaaaf835cf40, 0xaaaaf835cf90 } Next token is token 'a' (0xaaaaf835cfe0 'a') Shifting token 'a' (0xaaaaf835cfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf835cfe0 'a') -> $$ = nterm item (0xaaaaf835cfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaaf835d030->Object::Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0 } Next token is token 'a' (0xaaaaf835d030 'a') Shifting token 'a' (0xaaaaf835d030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf835d030 'a') -> $$ = nterm item (0xaaaaf835d030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaaf835d080->Object::Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0, 0xaaaaf835d030 } Next token is token 'p' (0xaaaaf835d080 'p'Exception caught: cleaning lookahead and stack 0xaaaaf835d080->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0, 0xaaaaf835d030, 0xaaaaf835d080 } 0xaaaaf835d030->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0, 0xaaaaf835d030 } 0xaaaaf835cfe0->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0 } 0xaaaaf835cf90->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90 } 0xaaaaf835cf40->Object::~Object { 0xaaaaf835cf40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaR stderr: ./glr-regression.at:593: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr4 glr-regr4.cc $LIBS stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaf835cf40->Object::Object { } Next token is token 'a' (0xaaaaf835cf40 'a') Shifting token 'a' (0xaaaaf835cf40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf835cf40 'a') -> $$ = nterm item (0xaaaaf835cf40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaaf835cf90->Object::Object { 0xaaaaf835cf40 } Next token is token 'a' (0xaaaaf835cf90 'a') Shifting token 'a' (0xaaaaf835cf90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf835cf90 'a') -> $$ = nterm item (0xaaaaf835cf90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaaf835cfe0->Object::Object { 0xaaaaf835cf40, 0xaaaaf835cf90 } Next token is token 'a' (0xaaaaf835cfe0 'a') Shifting token 'a' (0xaaaaf835cfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf835cfe0 'a') -> $$ = nterm item (0xaaaaf835cfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaaf835d030->Object::Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0 } Next token is token 'a' (0xaaaaf835d030 'a') Shifting token 'a' (0xaaaaf835d030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf835d030 'a') -> $$ = nterm item (0xaaaaf835d030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaaf835d080->Object::Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0, 0xaaaaf835d030 } Next token is token 'p' (0xaaaaf835d080 'p'Exception caught: cleaning lookahead and stack 0xaaaaf835d080->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0, 0xaaaaf835d030, 0xaaaaf835d080 } 0xaaaaf835d030->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0, 0xaaaaf835d030 } 0xaaaaf835cfe0->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0 } 0xaaaaf835cf90->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90 } 0xaaaaf835cf40->Object::~Object { 0xaaaaf835cf40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr stderr: stdout: ./glr-regression.at:207: $PREPARSER ./glr-regr1 BPBPB stderr: ./glr-regression.at:207: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: exception caught: printer ./c++.at:1361: $PREPARSER ./input aaaae 685. c++.at:1360: ok stderr: exception caught: syntax error 716. glr-regression.at:207: ok ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 725. glr-regression.at:594: testing Duplicate representation of merged trees: %union { char *ptr; } glr2.cc ... ./c++.at:1361: $PREPARSER ./input aaaaT ./glr-regression.at:594: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.cc glr-regr4.y stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 726. glr-regression.at:596: testing Duplicate representation of merged trees: api.value.type=union glr.c ... ./c++.at:1361: $PREPARSER ./input aaaaR stderr: ./glr-regression.at:596: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.c glr-regr4.y ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 686. c++.at:1361: ok ./glr-regression.at:594: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr4 glr-regr4.cc $LIBS ./glr-regression.at:596: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr4 glr-regr4.c $LIBS 727. glr-regression.at:597: testing Duplicate representation of merged trees: api.value.type=union glr.cc ... ./glr-regression.at:597: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.cc glr-regr4.y stderr: stdout: ./glr-regression.at:592: $PREPARSER ./glr-regr4 stderr: ./glr-regression.at:592: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:597: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr4 glr-regr4.cc $LIBS 723. glr-regression.at:592: ok stderr: stdout: ./glr-regression.at:489: $PREPARSER ./glr-regr3 input.txt stderr: stdout: stderr: ./c++.at:858: $PREPARSER ./input stderr: ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./glr-regression.at:489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 721. glr-regression.at:489: ok 728. glr-regression.at:598: testing Duplicate representation of merged trees: api.value.type=union glr2.cc ... ./glr-regression.at:598: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.cc glr-regr4.y ./glr-regression.at:598: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr4 glr-regr4.cc $LIBS 729. glr-regression.at:670: testing User destructor for unresolved GLR semantic value: glr.c ... ./glr-regression.at:670: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr5.c glr-regr5.y ./glr-regression.at:670: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr5 glr-regr5.c $LIBS stderr: stdout: ./glr-regression.at:596: $PREPARSER ./glr-regr4 stderr: ./glr-regression.at:596: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 726. glr-regression.at:596: ok stderr: stdout: ./glr-regression.at:356: $PREPARSER ./glr-regr2a input1.txt stderr: ./glr-regression.at:356: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 730. glr-regression.at:671: testing User destructor for unresolved GLR semantic value: glr.cc ... ./glr-regression.at:671: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr5.cc glr-regr5.y ./glr-regression.at:356: $PREPARSER ./glr-regr2a input2.txt stderr: ./glr-regression.at:356: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:356: $PREPARSER ./glr-regr2a input3.txt stderr: ./glr-regression.at:356: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 719. glr-regression.at:356: ok ./glr-regression.at:671: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr5 glr-regr5.cc $LIBS 731. glr-regression.at:672: testing User destructor for unresolved GLR semantic value: glr2.cc ... ./glr-regression.at:672: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr5.cc glr-regr5.y stderr: stdout: ./glr-regression.at:593: $PREPARSER ./glr-regr4 stderr: ./glr-regression.at:593: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:858: $PREPARSER ./input 724. glr-regression.at:593: ok stderr: ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:672: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr5 glr-regr5.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 732. glr-regression.at:738: testing User destructor after an error during a split parse: glr.c ... ./glr-regression.at:738: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr6.c glr-regr6.y stderr: stdout: ./glr-regression.at:670: $PREPARSER ./glr-regr5 stderr: Ambiguity detected. Option 1, start -> 'a' Option 2, start -> 'a' syntax is ambiguous stderr: stdout: ./glr-regression.at:738: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr6 glr-regr6.c $LIBS ./glr-regression.at:670: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:597: $PREPARSER ./glr-regr4 stderr: ./glr-regression.at:597: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 727. glr-regression.at:597: ok 729. glr-regression.at:670: ok 733. glr-regression.at:739: testing User destructor after an error during a split parse: glr.cc ... 734. glr-regression.at:740: testing User destructor after an error during a split parse: glr2.cc ... ./glr-regression.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr6.cc glr-regr6.y ./glr-regression.at:739: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr6.cc glr-regr6.y ./glr-regression.at:739: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr6 glr-regr6.cc $LIBS ./glr-regression.at:740: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr6 glr-regr6.cc $LIBS stderr: stdout: ./glr-regression.at:738: $PREPARSER ./glr-regr6 stderr: Ambiguity detected. Option 1, start -> 'a' Option 2, start -> 'a' syntax is ambiguous ./glr-regression.at:738: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 732. glr-regression.at:738: ok stderr: stdout: stderr: ./glr-regression.at:490: $PREPARSER ./glr-regr3 input.txt stdout: stderr: ./c++.at:858: $PREPARSER ./input stderr: ./glr-regression.at:490: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 722. glr-regression.at:490: ok ======== Testing with C++ standard flags: '' ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 735. glr-regression.at:843: testing Duplicated user destructor for lookahead: glr.c ... ./glr-regression.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr7.c glr-regr7.y stderr: stdout: ./glr-regression.at:671: $PREPARSER ./glr-regr5 stderr: ./glr-regression.at:843: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr7 glr-regr7.c $LIBS Ambiguity detected. Option 1, start -> 'a' Option 2, start -> 'a' syntax is ambiguous ./glr-regression.at:671: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1362: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaal 730. glr-regression.at:671: stderr: ok exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaap stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffffa294ce0->Object::Object { } 0xfffffa294de0->Object::Object { 0xfffffa294ce0 } 0xfffffa294ce0->Object::~Object { 0xfffffa294ce0, 0xfffffa294de0 } Next token is token 'a' (0xfffffa294de0 'a') 0xfffffa294d20->Object::Object { 0xfffffa294de0 } 0xfffffa294de0->Object::~Object { 0xfffffa294d20, 0xfffffa294de0 } Shifting token 'a' (0xfffffa294d20 'a') 0xaaaacf2732e0->Object::Object { 0xfffffa294d20 } 0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xfffffa294d20 } Entering state 2 Stack now 0 2 0xfffffa294e00->Object::Object { 0xaaaacf2732e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacf2732e0 'a') -> $$ = nterm item (0xfffffa294e00 'a') 0xaaaacf2732e0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294e00 } 0xaaaacf2732e0->Object::Object { 0xfffffa294e00 } 0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xfffffa294e00 } Entering state 11 Stack now 0 11 Reading a token 0xfffffa294ce0->Object::Object { 0xaaaacf2732e0 } 0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xfffffa294ce0 } 0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294ce0, 0xfffffa294de0 } Next token is token 'a' (0xfffffa294de0 'a') 0xfffffa294d20->Object::Object { 0xaaaacf2732e0, 0xfffffa294de0 } 0xfffffa294de0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294d20, 0xfffffa294de0 } Shifting token 'a' (0xfffffa294d20 'a') 0xaaaacf273300->Object::Object { 0xaaaacf2732e0, 0xfffffa294d20 } 0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294d20 } Entering state 2 Stack now 0 11 2 0xfffffa294e00->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacf273300 'a') -> $$ = nterm item (0xfffffa294e00 'a') 0xaaaacf273300->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294e00 } 0xaaaacf273300->Object::Object { 0xaaaacf2732e0, 0xfffffa294e00 } 0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294e00 } Entering state 11 Stack now 0 11 11 Reading a token 0xfffffa294ce0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300 } 0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294ce0 } 0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294ce0, 0xfffffa294de0 } Next token is token 'a' (0xfffffa294de0 'a') 0xfffffa294d20->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294de0 } 0xfffffa294de0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294d20, 0xfffffa294de0 } Shifting token 'a' (0xfffffa294d20 'a') 0xaaaacf273320->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294d20 } 0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294d20 } Entering state 2 Stack now 0 11 11 2 0xfffffa294e00->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacf273320 'a') -> $$ = nterm item (0xfffffa294e00 'a') 0xaaaacf273320->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294e00 } 0xaaaacf273320->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294e00 } 0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294e00 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xfffffa294ce0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320 } 0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294ce0 } 0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294ce0, 0xfffffa294de0 } Next token is token 'a' (0xfffffa294de0 'a') 0xfffffa294d20->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294de0 } 0xfffffa294de0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294d20, 0xfffffa294de0 } Shifting token 'a' (0xfffffa294d20 'a') 0xaaaacf273340->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294d20 } 0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294d20 } Entering state 2 Stack now 0 11 11 11 2 0xfffffa294e00->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacf273340 'a') -> $$ = nterm item (0xfffffa294e00 'a') 0xaaaacf273340->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294e00 } 0xaaaacf273340->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294e00 } 0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294e00 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xfffffa294ce0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340 } 0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294ce0 } 0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294ce0, 0xfffffa294de0 } Next token is token 'p' (0xfffffa294de0 'p'Exception caught: cleaning lookahead and stack 0xaaaacf273340->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294de0 } 0xaaaacf273320->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294de0 } 0xaaaacf273300->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294de0 } 0xaaaacf2732e0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294de0 } 0xfffffa294de0->Object::~Object { 0xfffffa294de0 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 736. glr-regression.at:844: testing Duplicated user destructor for lookahead: glr.cc ... ./glr-regression.at:844: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr7.cc glr-regr7.y Starting parse Entering state 0 Stack now 0 Reading a token 0xfffffa294ce0->Object::Object { } 0xfffffa294de0->Object::Object { 0xfffffa294ce0 } 0xfffffa294ce0->Object::~Object { 0xfffffa294ce0, 0xfffffa294de0 } Next token is token 'a' (0xfffffa294de0 'a') 0xfffffa294d20->Object::Object { 0xfffffa294de0 } 0xfffffa294de0->Object::~Object { 0xfffffa294d20, 0xfffffa294de0 } Shifting token 'a' (0xfffffa294d20 'a') 0xaaaacf2732e0->Object::Object { 0xfffffa294d20 } 0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xfffffa294d20 } Entering state 2 Stack now 0 2 0xfffffa294e00->Object::Object { 0xaaaacf2732e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacf2732e0 'a') -> $$ = nterm item (0xfffffa294e00 'a') 0xaaaacf2732e0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294e00 } 0xaaaacf2732e0->Object::Object { 0xfffffa294e00 } 0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xfffffa294e00 } Entering state 11 Stack now 0 11 Reading a token 0xfffffa294ce0->Object::Object { 0xaaaacf2732e0 } 0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xfffffa294ce0 } 0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294ce0, 0xfffffa294de0 } Next token is token 'a' (0xfffffa294de0 'a') 0xfffffa294d20->Object::Object { 0xaaaacf2732e0, 0xfffffa294de0 } 0xfffffa294de0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294d20, 0xfffffa294de0 } Shifting token 'a' (0xfffffa294d20 'a') 0xaaaacf273300->Object::Object { 0xaaaacf2732e0, 0xfffffa294d20 } 0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294d20 } Entering state 2 Stack now 0 11 2 0xfffffa294e00->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacf273300 'a') -> $$ = nterm item (0xfffffa294e00 'a') 0xaaaacf273300->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294e00 } 0xaaaacf273300->Object::Object { 0xaaaacf2732e0, 0xfffffa294e00 } 0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294e00 } Entering state 11 Stack now 0 11 11 Reading a token 0xfffffa294ce0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300 } 0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294ce0 } 0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294ce0, 0xfffffa294de0 } Next token is token 'a' (0xfffffa294de0 'a') 0xfffffa294d20->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294de0 } 0xfffffa294de0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294d20, 0xfffffa294de0 } Shifting token 'a' (0xfffffa294d20 'a') 0xaaaacf273320->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294d20 } 0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294d20 } Entering state 2 Stack now 0 11 11 2 0xfffffa294e00->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacf273320 'a') -> $$ = nterm item (0xfffffa294e00 'a') 0xaaaacf273320->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294e00 } 0xaaaacf273320->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294e00 } 0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294e00 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xfffffa294ce0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320 } 0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294ce0 } 0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294ce0, 0xfffffa294de0 } Next token is token 'a' (0xfffffa294de0 'a') 0xfffffa294d20->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294de0 } 0xfffffa294de0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294d20, 0xfffffa294de0 } Shifting token 'a' (0xfffffa294d20 'a') 0xaaaacf273340->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294d20 } 0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294d20 } Entering state 2 Stack now 0 11 11 11 2 0xfffffa294e00->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacf273340 'a') -> $$ = nterm item (0xfffffa294e00 'a') 0xaaaacf273340->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294e00 } 0xaaaacf273340->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294e00 } 0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294e00 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xfffffa294ce0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340 } 0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294ce0 } 0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294ce0, 0xfffffa294de0 } Next token is token 'p' (0xfffffa294de0 'p'Exception caught: cleaning lookahead and stack 0xaaaacf273340->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294de0 } 0xaaaacf273320->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294de0 } 0xaaaacf273300->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294de0 } 0xaaaacf2732e0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294de0 } 0xfffffa294de0->Object::~Object { 0xfffffa294de0 } exception caught: printer end { } ./c++.at:1362: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 737. glr-regression.at:845: testing Duplicated user destructor for lookahead: glr2.cc ... ./glr-regression.at:845: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr7.cc glr-regr7.y ./glr-regression.at:844: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr7 glr-regr7.cc $LIBS ./c++.at:1362: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:845: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr7 glr-regr7.cc $LIBS ./c++.at:1362: $PREPARSER ./input aaaaT stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaR stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 687. c++.at:1362: ok stdout: ./c++.at:1363: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 738. glr-regression.at:944: testing Incorrectly initialized location for empty right-hand side in GLR: glr.c ... ./glr-regression.at:944: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr8.c glr-regr8.y ./c++.at:1363: $PREPARSER ./input aaaap stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./glr-regression.at:598: $PREPARSER ./glr-regr4 ./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: ./glr-regression.at:598: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffeb822140->Object::Object { } 0xffffeb822240->Object::Object { 0xffffeb822140 } 0xffffeb822140->Object::~Object { 0xffffeb822140, 0xffffeb822240 } Next token is token 'a' (0xffffeb822240 'a') 0xffffeb822180->Object::Object { 0xffffeb822240 } 0xffffeb822240->Object::~Object { 0xffffeb822180, 0xffffeb822240 } Shifting token 'a' (0xffffeb822180 'a') 0xaaaab82d12e0->Object::Object { 0xffffeb822180 } 0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xffffeb822180 } Entering state 1 Stack now 0 1 0xffffeb822260->Object::Object { 0xaaaab82d12e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab82d12e0 'a') -> $$ = nterm item (0xffffeb822260 'a') 0xaaaab82d12e0->Object::~Object { 0xaaaab82d12e0, 0xffffeb822260 } 0xaaaab82d12e0->Object::Object { 0xffffeb822260 } 0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xffffeb822260 } Entering state 10 Stack now 0 10 Reading a token 0xffffeb822140->Object::Object { 0xaaaab82d12e0 } 0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xffffeb822140 } 0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xffffeb822140, 0xffffeb822240 } Next token is token 'a' (0xffffeb822240 'a') 0xffffeb822180->Object::Object { 0xaaaab82d12e0, 0xffffeb822240 } 0xffffeb822240->Object::~Object { 0xaaaab82d12e0, 0xffffeb822180, 0xffffeb822240 } Shifting token 'a' (0xffffeb822180 'a') 0xaaaab82d1300->Object::Object { 0xaaaab82d12e0, 0xffffeb822180 } 0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822180 } Entering state 1 Stack now 0 10 1 0xffffeb822260->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab82d1300 'a') -> $$ = nterm item (0xffffeb822260 'a') 0xaaaab82d1300->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822260 } 0xaaaab82d1300->Object::Object { 0xaaaab82d12e0, 0xffffeb822260 } 0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822260 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffeb822140->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300 } 0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822140 } 0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822140, 0xffffeb822240 } Next token is token 'a' (0xffffeb822240 'a') 0xffffeb822180->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822240 } 0xffffeb822240->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822180, 0xffffeb822240 } Shifting token 'a' (0xffffeb822180 'a') 0xaaaab82d1320->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822180 } 0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822180 } Entering state 1 Stack now 0 10 10 1 0xffffeb822260->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab82d1320 'a') -> $$ = nterm item (0xffffeb822260 'a') 0xaaaab82d1320->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822260 } 0xaaaab82d1320->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822260 } 0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822260 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffeb822140->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320 } 0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822140 } 0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822140, 0xffffeb822240 } Next token is token 'a' (0xffffeb822240 'a') 0xffffeb822180->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822240 } 0xffffeb822240->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822180, 0xffffeb822240 } Shifting token 'a' (0xffffeb822180 'a') 0xaaaab82d1340->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822180 } 0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822180 } Entering state 1 Stack now 0 10 10 10 1 0xffffeb822260->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab82d1340 'a') -> $$ = nterm item (0xffffeb822260 'a') 0xaaaab82d1340->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822260 } 0xaaaab82d1340->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822260 } 0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822260 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffeb822140->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340 } 0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822140 } 0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822140, 0xffffeb822240 } Next token is token 'p' (0xffffeb822240 'p'Exception caught: cleaning lookahead and stack 0xaaaab82d1340->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822240 } 0xaaaab82d1320->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822240 } 0xaaaab82d1300->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822240 } 0xaaaab82d12e0->Object::~Object { 0xaaaab82d12e0, 0xffffeb822240 } 0xffffeb822240->Object::~Object { 0xffffeb822240 } exception caught: printer end { } stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:944: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr8 glr-regr8.c $LIBS 728. glr-regression.at:598: ok stdout: stderr: ./glr-regression.at:843: $PREPARSER ./glr-regr7 stderr: memory exhausted Starting parse Entering state 0 Stack now 0 Reading a token 0xffffeb822140->Object::Object { } 0xffffeb822240->Object::Object { 0xffffeb822140 } 0xffffeb822140->Object::~Object { 0xffffeb822140, 0xffffeb822240 } Next token is token 'a' (0xffffeb822240 'a') 0xffffeb822180->Object::Object { 0xffffeb822240 } 0xffffeb822240->Object::~Object { 0xffffeb822180, 0xffffeb822240 } Shifting token 'a' (0xffffeb822180 'a') 0xaaaab82d12e0->Object::Object { 0xffffeb822180 } 0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xffffeb822180 } Entering state 1 Stack now 0 1 0xffffeb822260->Object::Object { 0xaaaab82d12e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab82d12e0 'a') -> $$ = nterm item (0xffffeb822260 'a') 0xaaaab82d12e0->Object::~Object { 0xaaaab82d12e0, 0xffffeb822260 } 0xaaaab82d12e0->Object::Object { 0xffffeb822260 } 0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xffffeb822260 } Entering state 10 Stack now 0 10 Reading a token 0xffffeb822140->Object::Object { 0xaaaab82d12e0 } 0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xffffeb822140 } 0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xffffeb822140, 0xffffeb822240 } Next token is token 'a' (0xffffeb822240 'a') 0xffffeb822180->Object::Object { 0xaaaab82d12e0, 0xffffeb822240 } 0xffffeb822240->Object::~Object { 0xaaaab82d12e0, 0xffffeb822180, 0xffffeb822240 } Shifting token 'a' (0xffffeb822180 'a') 0xaaaab82d1300->Object::Object { 0xaaaab82d12e0, 0xffffeb822180 } 0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822180 } Entering state 1 Stack now 0 10 1 0xffffeb822260->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab82d1300 'a') -> $$ = nterm item (0xffffeb822260 'a') 0xaaaab82d1300->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822260 } 0xaaaab82d1300->Object::Object { 0xaaaab82d12e0, 0xffffeb822260 } 0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822260 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffeb822140->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300 } 0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822140 } 0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822140, 0xffffeb822240 } Next token is token 'a' (0xffffeb822240 'a') 0xffffeb822180->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822240 } 0xffffeb822240->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822180, 0xffffeb822240 } Shifting token 'a' (0xffffeb822180 'a') 0xaaaab82d1320->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822180 } 0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822180 } Entering state 1 Stack now 0 10 10 1 0xffffeb822260->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab82d1320 'a') -> $$ = nterm item (0xffffeb822260 'a') 0xaaaab82d1320->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822260 } 0xaaaab82d1320->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822260 } 0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822260 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffeb822140->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320 } 0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822140 } 0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822140, 0xffffeb822240 } Next token is token 'a' (0xffffeb822240 'a') 0xffffeb822180->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822240 } 0xffffeb822240->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822180, 0xffffeb822240 } Shifting token 'a' (0xffffeb822180 'a') 0xaaaab82d1340->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822180 } 0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822180 } Entering state 1 Stack now 0 10 10 10 1 0xffffeb822260->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab82d1340 'a') -> $$ = nterm item (0xffffeb822260 'a') 0xaaaab82d1340->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822260 } 0xaaaab82d1340->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822260 } 0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822260 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffeb822140->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340 } 0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822140 } 0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822140, 0xffffeb822240 } Next token is token 'p' (0xffffeb822240 'p'Exception caught: cleaning lookahead and stack 0xaaaab82d1340->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822240 } 0xaaaab82d1320->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822240 } 0xaaaab82d1300->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822240 } 0xaaaab82d12e0->Object::~Object { 0xaaaab82d12e0, 0xffffeb822240 } 0xffffeb822240->Object::~Object { 0xffffeb822240 } exception caught: printer end { } ./glr-regression.at:843: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1363: $PREPARSER ./input aaaae stderr: 735. glr-regression.at:843: ok exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaT stderr: stderr: stdout: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:739: $PREPARSER ./glr-regr6 stderr: Ambiguity detected. Option 1, start -> 'a' Option 2, start -> 'a' syntax is ambiguous ./glr-regression.at:739: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaR 733. glr-regression.at:739: ok stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 739. glr-regression.at:945: testing Incorrectly initialized location for empty right-hand side in GLR: glr.cc ... 740. glr-regression.at:946: testing Incorrectly initialized location for empty right-hand side in GLR: glr2.cc ... ./glr-regression.at:946: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr8.cc glr-regr8.y 688. c++.at:1363: ok ./glr-regression.at:945: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr8.cc glr-regr8.y ./glr-regression.at:946: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr8 glr-regr8.cc $LIBS ./glr-regression.at:945: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr8 glr-regr8.cc $LIBS 741. glr-regression.at:1036: testing No users destructors if stack 0 deleted: glr.c ... stderr: ./glr-regression.at:1036: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr9.c glr-regr9.y stdout: ./c++.at:858: $PREPARSER ./input stderr: ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 742. glr-regression.at:1037: testing No users destructors if stack 0 deleted: glr.cc ... ======== Testing with C++ standard flags: '' stderr: ./glr-regression.at:1037: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr9.cc glr-regr9.y ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: ./glr-regression.at:594: $PREPARSER ./glr-regr4 stderr: ./glr-regression.at:1036: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr9 glr-regr9.c $LIBS ./glr-regression.at:594: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1037: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr9 glr-regr9.cc $LIBS 725. glr-regression.at:594: ok 743. glr-regression.at:1038: testing No users destructors if stack 0 deleted: glr2.cc ... ./glr-regression.at:1038: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr9.cc glr-regr9.y ./glr-regression.at:1038: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr9 glr-regr9.cc $LIBS stderr: stdout: ./glr-regression.at:944: $PREPARSER ./glr-regr8 stderr: ./glr-regression.at:944: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 738. glr-regression.at:944: ok 744. glr-regression.at:1102: testing Corrupted semantic options if user action cuts parse: glr.c ... ./glr-regression.at:1102: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr10.c glr-regr10.y stderr: stdout: ./glr-regression.at:844: $PREPARSER ./glr-regr7 stderr: memory exhausted ./glr-regression.at:1102: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr10 glr-regr10.c $LIBS ./glr-regression.at:844: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 736. glr-regression.at:844: ok stderr: stdout: ./glr-regression.at:672: $PREPARSER ./glr-regr5 stderr: Ambiguity detected. Option 1, start -> 'a' Option 2, start -> 'a' syntax is ambiguous ./glr-regression.at:672: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 745. glr-regression.at:1103: testing Corrupted semantic options if user action cuts parse: glr.cc ... ./glr-regression.at:1103: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr10.cc glr-regr10.y 731. glr-regression.at:672: ok ./glr-regression.at:1103: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr10 glr-regr10.cc $LIBS stderr: stdout: ./glr-regression.at:1036: $PREPARSER ./glr-regr9 stderr: memory exhausted ./glr-regression.at:1036: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 741. glr-regression.at:1036: ok stderr: stdout: ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $PREPARSER ./input < in stderr: 746. glr-regression.at:1104: testing Corrupted semantic options if user action cuts parse: glr2.cc ... error: invalid expression ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid character ./glr-regression.at:1104: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr10.cc glr-regr10.y ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 684. c++.at:1066: ok ./glr-regression.at:1104: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr10 glr-regr10.cc $LIBS stderr: stdout: 747. glr-regression.at:1174: testing Undesirable destructors if user action cuts parse: glr.c ... ./glr-regression.at:1174: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr11.c glr-regr11.y ./c++.at:858: $PREPARSER ./input stderr: ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 748. glr-regression.at:1175: testing Undesirable destructors if user action cuts parse: glr.cc ... ./glr-regression.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr11.cc glr-regr11.y ======== Testing with C++ standard flags: '' ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./glr-regression.at:1174: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr11 glr-regr11.c $LIBS ./glr-regression.at:1175: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr11 glr-regr11.cc $LIBS stdout: ./glr-regression.at:945: $PREPARSER ./glr-regr8 stderr: stderr: stderr: stdout: stdout: ./glr-regression.at:945: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1102: $PREPARSER ./glr-regr10 ./glr-regression.at:1037: $PREPARSER ./glr-regr9 739. glr-regression.at:945: ok stderr: stderr: memory exhausted ./glr-regression.at:1037: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1102: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 742. glr-regression.at:1037: ok stdout: 744. glr-regression.at:1102: ok ./glr-regression.at:740: $PREPARSER ./glr-regr6 stderr: Ambiguity detected. Option 1, start -> 'a' Option 2, start -> 'a' syntax is ambiguous ./glr-regression.at:740: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 749. glr-regression.at:1176: testing Undesirable destructors if user action cuts parse: glr2.cc ... ./glr-regression.at:1176: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr11.cc glr-regr11.y 734. glr-regression.at:740: ok 750. glr-regression.at:1310: testing Leaked semantic values if user action cuts parse: glr.c ... ./glr-regression.at:1310: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr12.c glr-regr12.y ./glr-regression.at:1310: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr12 glr-regr12.c $LIBS 751. glr-regression.at:1311: testing Leaked semantic values if user action cuts parse: glr.cc ... ./glr-regression.at:1311: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr12.cc glr-regr12.y ./glr-regression.at:1176: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr11 glr-regr11.cc $LIBS ./glr-regression.at:1311: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr12 glr-regr12.cc $LIBS 752. glr-regression.at:1312: testing Leaked semantic values if user action cuts parse: glr2.cc ... ./glr-regression.at:1312: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr12.cc glr-regr12.y ./glr-regression.at:1312: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr12 glr-regr12.cc $LIBS stderr: stdout: ./glr-regression.at:1174: $PREPARSER ./glr-regr11 stderr: ./glr-regression.at:1174: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 747. glr-regression.at:1174: ok stderr: stdout: stderr: stdout: ./glr-regression.at:845: $PREPARSER ./glr-regr7 ./glr-regression.at:1103: $PREPARSER ./glr-regr10 stderr: stderr: memory exhausted ./glr-regression.at:845: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 753. glr-regression.at:1445: testing Incorrect lookahead during deterministic GLR: glr.c ... stdout: ./glr-regression.at:1310: $PREPARSER ./glr-regr12 stderr: ./glr-regression.at:1445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr13.c glr-regr13.y stderr: ./glr-regression.at:1310: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 737. glr-regression.at:845: ok ./glr-regression.at:1103: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 745. glr-regression.at:1103: ok 750. glr-regression.at:1310: ok ./glr-regression.at:1445: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr13 glr-regr13.c $LIBS 754. glr-regression.at:1446: testing Incorrect lookahead during deterministic GLR: glr.cc ... ./glr-regression.at:1446: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr13.cc glr-regr13.y 756. glr-regression.at:1678: testing Incorrect lookahead during nondeterministic GLR: glr.c ... ./glr-regression.at:1678: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr14.c glr-regr14.y 755. glr-regression.at:1447: testing Incorrect lookahead during deterministic GLR: glr2.cc ... ./glr-regression.at:1447: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr13.cc glr-regr13.y ./glr-regression.at:1446: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr13 glr-regr13.cc $LIBS ./glr-regression.at:1678: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr14 glr-regr14.c $LIBS ./glr-regression.at:1447: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr13 glr-regr13.cc $LIBS stderr: stdout: ./glr-regression.at:1175: $PREPARSER ./glr-regr11 stderr: ./glr-regression.at:1175: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 748. glr-regression.at:1175: ok 757. glr-regression.at:1679: testing Incorrect lookahead during nondeterministic GLR: glr.cc ... ./glr-regression.at:1679: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr14.cc glr-regr14.y ./glr-regression.at:1679: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr14 glr-regr14.cc $LIBS stderr: stdout: ./glr-regression.at:1311: $PREPARSER ./glr-regr12 stderr: ./glr-regression.at:1311: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 751. glr-regression.at:1311: ok stderr: stdout: ./glr-regression.at:946: $PREPARSER ./glr-regr8 stderr: ./glr-regression.at:946: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./glr-regression.at:1445: $PREPARSER ./glr-regr13 758. glr-regression.at:1680: testing Incorrect lookahead during nondeterministic GLR: glr2.cc ... ./glr-regression.at:1680: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr14.cc glr-regr14.y stderr: 740. glr-regression.at:946: ok ./glr-regression.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1680: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr14 glr-regr14.cc $LIBS 753. glr-regression.at:1445: ok stderr: stdout: ./c++.at:858: $PREPARSER ./input stderr: ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy 759. glr-regression.at:1785: testing Leaked semantic values when reporting ambiguity: glr.c ... ./glr-regression.at:1785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr15.c glr-regr15.y ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 760. glr-regression.at:1786: testing Leaked semantic values when reporting ambiguity: glr.cc ... ./glr-regression.at:1786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr15.cc glr-regr15.y ./glr-regression.at:1785: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr15 glr-regr15.c $LIBS stderr: stdout: ./glr-regression.at:1038: $PREPARSER ./glr-regr9 stderr: memory exhausted ./glr-regression.at:1038: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1786: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr15 glr-regr15.cc $LIBS 743. glr-regression.at:1038: ok 761. glr-regression.at:1787: testing Leaked semantic values when reporting ambiguity: glr2.cc ... stderr: stdout: ./glr-regression.at:1787: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr15.cc glr-regr15.y ./glr-regression.at:1678: $PREPARSER ./glr-regr14 stderr: ./glr-regression.at:1678: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 756. glr-regression.at:1678: ok ./glr-regression.at:1787: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr15 glr-regr15.cc $LIBS 762. glr-regression.at:1860: testing Leaked lookahead after nondeterministic parse syntax error: glr.c ... ./glr-regression.at:1860: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr16.c glr-regr16.y stderr: stdout: ./glr-regression.at:1446: $PREPARSER ./glr-regr13 ./glr-regression.at:1860: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr16 glr-regr16.c $LIBS stderr: ./glr-regression.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 754. glr-regression.at:1446: ok stderr: stdout: ./glr-regression.at:1785: $PREPARSER ./glr-regr15 stderr: Ambiguity detected. Option 1, ambiguity -> ambiguity1 -> Option 2, ambiguity -> ambiguity2 -> syntax is ambiguous ./glr-regression.at:1785: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 759. glr-regression.at:1785: ok 763. glr-regression.at:1861: testing Leaked lookahead after nondeterministic parse syntax error: glr.cc ... ./glr-regression.at:1861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr16.cc glr-regr16.y stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./glr-regression.at:1861: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr16 glr-regr16.cc $LIBS 764. glr-regression.at:1862: testing Leaked lookahead after nondeterministic parse syntax error: glr2.cc ... ./glr-regression.at:1862: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr16.cc glr-regr16.y stderr: stdout: ./glr-regression.at:1176: $PREPARSER ./glr-regr11 stderr: ./glr-regression.at:1176: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 749. glr-regression.at:1176: ok ./glr-regression.at:1862: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr16 glr-regr16.cc $LIBS stderr: stdout: ./glr-regression.at:1312: $PREPARSER ./glr-regr12 stderr: ./glr-regression.at:1312: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: 752. glr-regression.at:1312: ok ./glr-regression.at:1104: $PREPARSER ./glr-regr10 stderr: ./glr-regression.at:1104: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 746. glr-regression.at:1104: ok 765. glr-regression.at:1964: testing Uninitialized location when reporting ambiguity: glr.c api.pure ... ./glr-regression.at:1964: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr17.c glr-regr17.y stderr: 766. glr-regression.at:1965: testing Uninitialized location when reporting ambiguity: glr.cc ... ./glr-regression.at:1965: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr17.cc glr-regr17.y stdout: ./glr-regression.at:1679: $PREPARSER ./glr-regr14 stderr: stderr: stdout: ./glr-regression.at:1860: $PREPARSER ./glr-regr16 stderr: syntax error ./glr-regression.at:1860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1679: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1964: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr17 glr-regr17.c $LIBS ./glr-regression.at:1965: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr17 glr-regr17.cc $LIBS 757. glr-regression.at:1679: ok 762. glr-regression.at:1860: ok 767. glr-regression.at:1966: testing Uninitialized location when reporting ambiguity: glr2.cc ... ./glr-regression.at:1966: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr17.cc glr-regr17.y stderr: stdout: ./glr-regression.at:1786: $PREPARSER ./glr-regr15 stderr: Ambiguity detected. Option 1, ambiguity -> ambiguity1 -> Option 2, ambiguity -> ambiguity2 -> syntax is ambiguous ./glr-regression.at:1786: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 768. glr-regression.at:2035: testing Missed %merge type warnings when LHS type is declared later: glr.c ... ./glr-regression.at:1966: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr17 glr-regr17.cc $LIBS ./glr-regression.at:2035: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o glr-regr18.c -rall -fcaret glr-regr18.y 760. glr-regression.at:1786: ok 768. glr-regression.at:2035: ok 769. glr-regression.at:2036: testing Missed %merge type warnings when LHS type is declared later: glr.cc ... ./glr-regression.at:2036: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o glr-regr18.c -rall -fcaret glr-regr18.y 769. glr-regression.at:2036: ok 770. glr-regression.at:2037: testing Missed %merge type warnings when LHS type is declared later: glr2.cc ... ./glr-regression.at:2037: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o glr-regr18.c -rall -fcaret glr-regr18.y 770. glr-regression.at:2037: ok 771. glr-regression.at:2149: testing Ambiguity reports: glr.c ... ./glr-regression.at:2149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./glr-regression.at:2149: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 773. glr-regression.at:2151: testing Ambiguity reports: glr2.cc ... ./glr-regression.at:2151: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 772. glr-regression.at:2150: testing Ambiguity reports: glr.cc ... ./glr-regression.at:2150: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./c++.at:859: $PREPARSER ./input ./glr-regression.at:2151: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2150: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./glr-regression.at:1861: $PREPARSER ./glr-regr16 stderr: syntax error ./glr-regression.at:1861: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 763. glr-regression.at:1861: ok stderr: stdout: ./glr-regression.at:1964: $PREPARSER ./glr-regr17 stderr: 774. glr-regression.at:2229: testing Predicates: glr.c ... Ambiguity detected. Option 1, start -> ambig1 -> sub_ambig2 -> empty2 -> 'a' 'b' empty1 -> Option 2, start -> ambig2 -> sub_ambig2 -> empty2 -> 'a' 'b' empty2 -> 1.1-2.2: syntax is ambiguous ./glr-regression.at:1964: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2229: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 765. glr-regression.at:1964: ok ./glr-regression.at:2229: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./glr-regression.at:2149: $PREPARSER ./input --debug 775. glr-regression.at:2230: testing Predicates: glr.cc ... stderr: Starting parse Entering state 0 Reading a token Next token is token 'a' () Shifting token 'a' () Entering state 1 Reading a token Next token is token 'b' () Shifting token 'b' () Entering state 3 Reducing stack 0 by rule 3 (line 30): $1 = token 'b' () -> $$ = nterm b () Entering state 4 Reading a token Next token is token 'c' () Shifting token 'c' () Entering state 6 Reducing stack 0 by rule 4 (line 31): -> $$ = nterm d () Entering state 7 Reading a token Now at end of input. Stack 0 Entering state 7 Now at end of input. Splitting off stack 1 from 0. Reduced stack 1 by rule 2 (line 28); action deferred. Now in state 2. Stack 1 Entering state 2 Now at end of input. Reduced stack 0 by rule 1 (line 27); action deferred. Now in state 2. Merging stack 0 into stack 1. Stack 1 Entering state 2 Now at end of input. Removing dead stacks. Rename stack 1 -> 0. On stack 0, shifting token "end of file" () Stack 0 now in state 5 Ambiguity detected. Option 1, start -> 'a' b 'c' d Option 2, start -> 'a' b 'c' d syntax is ambiguous Cleanup: popping token "end of file" () Cleanup: popping unresolved nterm start () Cleanup: popping nterm d () Cleanup: popping token 'c' () Cleanup: popping nterm b () Cleanup: popping token 'a' () ./glr-regression.at:2149: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2230: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 771. glr-regression.at:2149: ok stderr: stdout: ./glr-regression.at:1447: $PREPARSER ./glr-regr13 stderr: ./glr-regression.at:1447: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 755. glr-regression.at:1447: ok ./glr-regression.at:2230: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 776. glr-regression.at:2231: testing Predicates: glr2.cc ... ./glr-regression.at:2231: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./glr-regression.at:2231: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./glr-regression.at:1680: $PREPARSER ./glr-regr14 stderr: ./glr-regression.at:1680: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./glr-regression.at:1965: $PREPARSER ./glr-regr17 758. glr-regression.at:1680: ok stderr: Ambiguity detected. Option 1, start -> ambig1 -> sub_ambig2 -> empty2 -> 'a' 'b' empty1 -> Option 2, start -> ambig2 -> sub_ambig2 -> empty2 -> 'a' 'b' empty2 -> 1.1-2.2: syntax is ambiguous ./glr-regression.at:1965: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 766. glr-regression.at:1965: ok stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./glr-regression.at:2229: $PREPARSER ./input Nwin stderr: ./glr-regression.at:2229: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2229: $PREPARSER ./input Owin stderr: stderr: stdout: syntax error, unexpected 'n', expecting 'o' ./glr-regression.at:1787: $PREPARSER ./glr-regr15 ./glr-regression.at:2229: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Ambiguity detected. Option 1, ambiguity -> ambiguity1 -> Option 2, ambiguity -> ambiguity2 -> syntax is ambiguous ./glr-regression.at:1787: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 761. glr-regression.at:1787: ok ./glr-regression.at:2229: $PREPARSER ./input Owio stderr: ./glr-regression.at:2229: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2229: $PREPARSER ./input Nwio stderr: syntax error, unexpected 'o', expecting 'n' ./glr-regression.at:2229: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 774. glr-regression.at:2229: ok stderr: stdout: ./glr-regression.at:2150: $PREPARSER ./input --debug stderr: Starting parse Entering state 0 Reading a token Next token is token 'a' () Shifting token 'a' () Entering state 1 Reading a token Next token is token 'b' () Shifting token 'b' () Entering state 3 Reducing stack 0 by rule 3 (line 30): $1 = token 'b' () -> $$ = nterm b () Entering state 4 Reading a token Next token is token 'c' () Shifting token 'c' () Entering state 6 Reducing stack 0 by rule 4 (line 31): -> $$ = nterm d () Entering state 7 Reading a token Now at end of input. Stack 0 Entering state 7 Now at end of input. Splitting off stack 1 from 0. Reduced stack 1 by rule 2 (line 28); action deferred. Now in state 2. Stack 1 Entering state 2 Now at end of input. Reduced stack 0 by rule 1 (line 27); action deferred. Now in state 2. Merging stack 0 into stack 1. Stack 1 Entering state 2 Now at end of input. Removing dead stacks. Rename stack 1 -> 0. On stack 0, shifting token "end of file" () Stack 0 now in state 5 Ambiguity detected. Option 1, start -> 'a' b 'c' d Option 2, start -> 'a' b 'c' d syntax is ambiguous Cleanup: popping token "end of file" () Cleanup: popping unresolved nterm start () Cleanup: popping nterm d () Cleanup: popping token 'c' () Cleanup: popping nterm b () Cleanup: popping token 'a' () ./glr-regression.at:2150: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 772. glr-regression.at:2150: ok stderr: stdout: ./glr-regression.at:2230: $PREPARSER ./input Nwin stderr: ./glr-regression.at:2230: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2230: $PREPARSER ./input Owin stderr: syntax error, unexpected 'n', expecting 'o' ./glr-regression.at:2230: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2230: $PREPARSER ./input Owio stderr: ./glr-regression.at:2230: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2230: $PREPARSER ./input Nwio stderr: syntax error, unexpected 'o', expecting 'n' ./glr-regression.at:2230: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 775. glr-regression.at:2230: ok stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./glr-regression.at:1862: $PREPARSER ./glr-regr16 stderr: syntax error ./glr-regression.at:1862: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 764. glr-regression.at:1862: ok stderr: stdout: ./glr-regression.at:1966: $PREPARSER ./glr-regr17 stderr: Ambiguity detected. Option 1, start -> ambig1 -> sub_ambig2 -> empty2 -> 'a' 'b' empty1 -> Option 2, start -> ambig2 -> sub_ambig2 -> empty2 -> 'a' 'b' empty2 -> 1.1-2.2: syntax is ambiguous ./glr-regression.at:1966: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 767. glr-regression.at:1966: ok stderr: stdout: ./glr-regression.at:2151: $PREPARSER ./input --debug stderr: Starting parse Entering state 0 Reading a token Next token is token 'a' () Shifting token 'a' () Entering state 1 Reading a token Next token is token 'b' () Shifting token 'b' () Entering state 3 Reducing stack 0 by rule 3 (line 30): $1 = token 'b' () -> $$ = nterm b () Entering state 4 Reading a token Next token is token 'c' () Shifting token 'c' () Entering state 6 Reducing stack 0 by rule 4 (line 31): -> $$ = nterm d () Entering state 7 Reading a token Now at end of input. Stack 0 Entering state 7 Now at end of input. Splitting off stack 1 from 0. Reduced stack 1 by rule 2 (line 28); action deferred. Now in state 2. Stack 1 Entering state 2 Now at end of input. Reduced stack 0 by rule 1 (line 27); action deferred. Now in state 2. Merging stack 0 into stack 1. Stack 1 Entering state 2 Now at end of input. Removing dead stacks. Rename stack 1 -> 0. On stack 0, shifting token "end of file" () Stack 0 now in state 5 Ambiguity detected. Option 1, start -> 'a' b 'c' d Option 2, start -> 'a' b 'c' d syntax is ambiguous Cleanup: popping token "end of file" () Cleanup: popping unresolved nterm start () Cleanup: popping nterm d () Cleanup: popping token 'c' () Cleanup: popping nterm b () Cleanup: popping token 'a' () ./glr-regression.at:2151: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 773. glr-regression.at:2151: ok stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./glr-regression.at:2231: $PREPARSER ./input Nwin stderr: ./glr-regression.at:2231: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2231: $PREPARSER ./input Owin stderr: syntax error, unexpected 'n', expecting 'o' ./glr-regression.at:2231: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2231: $PREPARSER ./input Owio stderr: ./glr-regression.at:2231: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2231: $PREPARSER ./input Nwio stderr: syntax error, unexpected 'o', expecting 'n' ./glr-regression.at:2231: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 776. glr-regression.at:2231: ok stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:860: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 679. c++.at:854: ok ## ------------- ## ## Test results. ## ## ------------- ## 712 tests were successful. 64 tests were skipped. make[4]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[2]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' create-stamp debian/debhelper-build-stamp dh_prep dh_auto_install make -j12 install DESTDIR=/build/reproducible-path/bison-3.8.2\+dfsg/debian/tmp AM_UPDATE_INFO_DIR=no make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' make install-recursive make[2]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' Making install in po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/po' installing bg.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/bg/LC_MESSAGES/bison.mo installing ca.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ca/LC_MESSAGES/bison.mo installing da.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/da/LC_MESSAGES/bison.mo installing de.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/de/LC_MESSAGES/bison.mo installing el.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/el/LC_MESSAGES/bison.mo installing eo.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/eo/LC_MESSAGES/bison.mo installing es.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/es/LC_MESSAGES/bison.mo installing et.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/et/LC_MESSAGES/bison.mo installing fi.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/fi/LC_MESSAGES/bison.mo installing fr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/fr/LC_MESSAGES/bison.mo installing ga.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ga/LC_MESSAGES/bison.mo installing hr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/hr/LC_MESSAGES/bison.mo installing id.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/id/LC_MESSAGES/bison.mo installing it.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/it/LC_MESSAGES/bison.mo installing ja.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ja/LC_MESSAGES/bison.mo installing ms.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ms/LC_MESSAGES/bison.mo installing nb.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/nb/LC_MESSAGES/bison.mo installing nl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/nl/LC_MESSAGES/bison.mo installing pl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pl/LC_MESSAGES/bison.mo installing pt.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pt/LC_MESSAGES/bison.mo installing pt_BR.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pt_BR/LC_MESSAGES/bison.mo installing ro.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ro/LC_MESSAGES/bison.mo installing ru.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ru/LC_MESSAGES/bison.mo installing sr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sr/LC_MESSAGES/bison.mo installing sv.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sv/LC_MESSAGES/bison.mo installing tr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/tr/LC_MESSAGES/bison.mo installing uk.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/uk/LC_MESSAGES/bison.mo installing vi.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/vi/LC_MESSAGES/bison.mo installing zh_CN.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/zh_CN/LC_MESSAGES/bison.mo installing zh_TW.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/zh_TW/LC_MESSAGES/bison.mo if test "bison" = "gettext-tools"; then \ /usr/bin/mkdir -p /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po; \ for file in Makefile.in.in remove-potcdate.sin quot.sed boldquot.sed en@quot.header en@boldquot.header insert-header.sin Rules-quot Makevars.template; do \ /usr/bin/install -c -m 644 ./$file \ /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po/$file; \ done; \ for file in Makevars; do \ rm -f /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po/$file; \ done; \ else \ : ; \ fi make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/po' Making install in runtime-po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' installing ast.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ast/LC_MESSAGES/bison-runtime.mo installing bg.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/bg/LC_MESSAGES/bison-runtime.mo installing ca.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ca/LC_MESSAGES/bison-runtime.mo installing da.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/da/LC_MESSAGES/bison-runtime.mo installing de.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/de/LC_MESSAGES/bison-runtime.mo installing el.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/el/LC_MESSAGES/bison-runtime.mo installing eo.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/eo/LC_MESSAGES/bison-runtime.mo installing es.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/es/LC_MESSAGES/bison-runtime.mo installing et.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/et/LC_MESSAGES/bison-runtime.mo installing fi.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/fi/LC_MESSAGES/bison-runtime.mo installing fr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/fr/LC_MESSAGES/bison-runtime.mo installing ga.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ga/LC_MESSAGES/bison-runtime.mo installing gl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/gl/LC_MESSAGES/bison-runtime.mo installing hr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/hr/LC_MESSAGES/bison-runtime.mo installing hu.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/hu/LC_MESSAGES/bison-runtime.mo installing ia.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ia/LC_MESSAGES/bison-runtime.mo installing id.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/id/LC_MESSAGES/bison-runtime.mo installing it.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/it/LC_MESSAGES/bison-runtime.mo installing ja.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ja/LC_MESSAGES/bison-runtime.mo installing ky.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ky/LC_MESSAGES/bison-runtime.mo installing lt.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/lt/LC_MESSAGES/bison-runtime.mo installing lv.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/lv/LC_MESSAGES/bison-runtime.mo installing ms.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ms/LC_MESSAGES/bison-runtime.mo installing nb.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/nb/LC_MESSAGES/bison-runtime.mo installing nl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/nl/LC_MESSAGES/bison-runtime.mo installing pl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pl/LC_MESSAGES/bison-runtime.mo installing pt.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pt/LC_MESSAGES/bison-runtime.mo installing pt_BR.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pt_BR/LC_MESSAGES/bison-runtime.mo installing ro.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ro/LC_MESSAGES/bison-runtime.mo installing ru.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ru/LC_MESSAGES/bison-runtime.mo installing sl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sl/LC_MESSAGES/bison-runtime.mo installing sq.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sq/LC_MESSAGES/bison-runtime.mo installing sr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sr/LC_MESSAGES/bison-runtime.mo installing sv.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sv/LC_MESSAGES/bison-runtime.mo installing ta.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ta/LC_MESSAGES/bison-runtime.mo installing th.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/th/LC_MESSAGES/bison-runtime.mo installing tr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/tr/LC_MESSAGES/bison-runtime.mo installing uk.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/uk/LC_MESSAGES/bison-runtime.mo installing vi.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/vi/LC_MESSAGES/bison-runtime.mo installing zh_CN.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/zh_CN/LC_MESSAGES/bison-runtime.mo installing zh_TW.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/zh_TW/LC_MESSAGES/bison-runtime.mo if test "bison" = "gettext-tools"; then \ /usr/bin/mkdir -p /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po; \ for file in Makefile.in.in remove-potcdate.sin quot.sed boldquot.sed en@quot.header en@boldquot.header insert-header.sin Rules-quot Makevars.template; do \ /usr/bin/install -c -m 644 ./$file \ /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po/$file; \ done; \ for file in Makevars; do \ rm -f /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po/$file; \ done; \ else \ : ; \ fi make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' Making install in gnulib-po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' installing af.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/af/LC_MESSAGES/bison-gnulib.mo installing be.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/be/LC_MESSAGES/bison-gnulib.mo installing bg.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/bg/LC_MESSAGES/bison-gnulib.mo installing ca.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ca/LC_MESSAGES/bison-gnulib.mo installing cs.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/cs/LC_MESSAGES/bison-gnulib.mo installing da.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/da/LC_MESSAGES/bison-gnulib.mo installing de.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/de/LC_MESSAGES/bison-gnulib.mo installing el.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/el/LC_MESSAGES/bison-gnulib.mo installing eo.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/eo/LC_MESSAGES/bison-gnulib.mo installing es.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/es/LC_MESSAGES/bison-gnulib.mo installing et.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/et/LC_MESSAGES/bison-gnulib.mo installing eu.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/eu/LC_MESSAGES/bison-gnulib.mo installing fi.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/fi/LC_MESSAGES/bison-gnulib.mo installing fr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/fr/LC_MESSAGES/bison-gnulib.mo installing ga.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ga/LC_MESSAGES/bison-gnulib.mo installing gl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/gl/LC_MESSAGES/bison-gnulib.mo installing hu.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/hu/LC_MESSAGES/bison-gnulib.mo installing it.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/it/LC_MESSAGES/bison-gnulib.mo installing ja.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ja/LC_MESSAGES/bison-gnulib.mo installing ko.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ko/LC_MESSAGES/bison-gnulib.mo installing ms.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ms/LC_MESSAGES/bison-gnulib.mo installing nb.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/nb/LC_MESSAGES/bison-gnulib.mo installing nl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/nl/LC_MESSAGES/bison-gnulib.mo installing pl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pl/LC_MESSAGES/bison-gnulib.mo installing pt.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pt/LC_MESSAGES/bison-gnulib.mo installing pt_BR.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pt_BR/LC_MESSAGES/bison-gnulib.mo installing ro.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ro/LC_MESSAGES/bison-gnulib.mo installing ru.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ru/LC_MESSAGES/bison-gnulib.mo installing rw.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/rw/LC_MESSAGES/bison-gnulib.mo installing sk.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sk/LC_MESSAGES/bison-gnulib.mo installing sl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sl/LC_MESSAGES/bison-gnulib.mo installing sr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sr/LC_MESSAGES/bison-gnulib.mo installing sv.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sv/LC_MESSAGES/bison-gnulib.mo installing tr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/tr/LC_MESSAGES/bison-gnulib.mo installing uk.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/uk/LC_MESSAGES/bison-gnulib.mo installing vi.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/vi/LC_MESSAGES/bison-gnulib.mo installing zh_CN.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/zh_CN/LC_MESSAGES/bison-gnulib.mo installing zh_TW.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/zh_TW/LC_MESSAGES/bison-gnulib.mo if test "bison" = "gettext-tools"; then \ /usr/bin/mkdir -p /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po; \ for file in Makefile.in.in remove-potcdate.sin quot.sed boldquot.sed en@quot.header en@boldquot.header insert-header.sin Rules-quot Makevars.template; do \ /usr/bin/install -c -m 644 ./$file \ /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po/$file; \ done; \ for file in Makevars; do \ rm -f /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po/$file; \ done; \ else \ : ; \ fi make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' Making install in . make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' /usr/bin/mkdir -p doc LC_ALL=C tests/bison --version >doc/bison.help.tmp LC_ALL=C tests/bison --help | \ sed -e 's,^Usage: .*/bison \[OPTION\],Usage: bison [OPTION],g' \ -e '/translation bugs/d' >>doc/bison.help.tmp ./build-aux/move-if-change doc/bison.help.tmp doc/bison.help make[4]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/lib/aarch64-linux-gnu' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin' /usr/bin/install -c -m 644 lib/liby.a '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/lib/aarch64-linux-gnu' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/aclocal' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++/calc++' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++' /usr/bin/install -c src/yacc '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin' /usr/bin/install -c -m 644 m4/bison-i18n.m4 '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/aclocal' /usr/bin/install -c src/bison '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin' ( cd '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/lib/aarch64-linux-gnu' && ranlib liby.a ) /usr/bin/install -c -m 644 examples/c++/calc++/driver.cc examples/c++/calc++/driver.hh examples/c++/calc++/scanner.ll examples/c++/calc++/calc++.cc examples/c++/calc++/parser.yy '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++/calc++' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/bistromathic' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/calc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d/calc' /usr/bin/install -c -m 644 examples/c/bistromathic/parse.y examples/c/bistromathic/Makefile examples/c/bistromathic/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/bistromathic' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++/calc++' /usr/bin/install -c -m 644 examples/c++/simple.yy '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++' /usr/bin/install -c -m 644 examples/c/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c' /usr/bin/install -c -m 644 examples/d/calc/calc.y examples/d/calc/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d/calc' /usr/bin/install -c -m 644 examples/c/calc/calc.y examples/c/calc/Makefile examples/c/calc/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/calc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d' /usr/bin/install -c -m 644 examples/c++/README.md examples/c++/Makefile examples/c++/variant.yy examples/c++/variant-11.yy '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples' /usr/bin/install -c -m 644 examples/c++/calc++/README.md examples/c++/calc++/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++/calc++' /usr/bin/install -c -m 644 examples/d/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/glr' /usr/bin/install -c -m 644 AUTHORS COPYING NEWS README THANKS TODO '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java' /usr/bin/install -c -m 644 examples/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java/calc' /usr/bin/install -c -m 644 examples/c/glr/c++-types.y examples/c/glr/Makefile examples/c/glr/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/glr' /usr/bin/install -c -m 644 examples/java/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java/simple' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/lexcalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/m4sugar' /usr/bin/install -c -m 644 examples/java/calc/Calc.y examples/java/calc/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java/calc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/mfcalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison' /usr/bin/install -c -m 644 examples/java/simple/Calc.y examples/java/simple/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java/simple' /usr/bin/install -c -m 644 examples/c/lexcalc/parse.y examples/c/lexcalc/scan.l examples/c/lexcalc/Makefile examples/c/lexcalc/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/lexcalc' /usr/bin/install -c -m 644 examples/c/mfcalc/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/mfcalc' /usr/bin/install -c -m 644 data/README.md data/bison-default.css '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/pushcalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/reccalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/rpcalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d/simple' /usr/bin/install -c -m 644 data/m4sugar/foreach.m4 data/m4sugar/m4sugar.m4 '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/m4sugar' /usr/bin/install -c -m 644 examples/c/pushcalc/calc.y examples/c/pushcalc/Makefile examples/c/pushcalc/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/pushcalc' /usr/bin/install -c -m 644 examples/c/reccalc/parse.y examples/c/reccalc/scan.l examples/c/reccalc/Makefile examples/c/reccalc/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/reccalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/skeletons' /usr/bin/mkdir -p doc /usr/bin/install -c -m 644 examples/c/rpcalc/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/rpcalc' /usr/bin/install -c -m 644 examples/d/simple/calc.y examples/d/simple/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d/simple' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/xslt' LC_ALL=C tests/bison --version >doc/bison.help.tmp /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/mfcalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/rpcalc' /usr/bin/install -c -m 644 data/xslt/bison.xsl data/xslt/xml2dot.xsl data/xslt/xml2text.xsl data/xslt/xml2xhtml.xsl '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/xslt' /usr/bin/install -c -m 644 data/skeletons/bison.m4 data/skeletons/c++-skel.m4 data/skeletons/c++.m4 data/skeletons/c-like.m4 data/skeletons/c-skel.m4 data/skeletons/c.m4 data/skeletons/glr.c data/skeletons/glr.cc data/skeletons/glr2.cc data/skeletons/java-skel.m4 data/skeletons/java.m4 data/skeletons/lalr1.cc data/skeletons/lalr1.java data/skeletons/location.cc data/skeletons/stack.hh data/skeletons/traceon.m4 data/skeletons/variant.hh data/skeletons/yacc.c data/skeletons/d-skel.m4 data/skeletons/d.m4 data/skeletons/lalr1.d '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/skeletons' /usr/bin/install -c -m 644 examples/c/mfcalc/calc.h examples/c/mfcalc/mfcalc.y '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/mfcalc' LC_ALL=C tests/bison --help | \ sed -e 's,^Usage: .*/bison \[OPTION\],Usage: bison [OPTION],g' \ -e '/translation bugs/d' >>doc/bison.help.tmp /usr/bin/install -c -m 644 examples/c/rpcalc/rpcalc.y '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/rpcalc' ./build-aux/move-if-change doc/bison.help.tmp doc/bison.help /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/man/man1' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/info' /usr/bin/install -c -m 644 ./doc/bison.1 doc/yacc.1 '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/man/man1' /usr/bin/install -c -m 644 ./doc/bison.info '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/info' make[4]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[2]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' debian/rules execute_after_dh_auto_install make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' rm -f -R /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/info/ mv /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin/yacc /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin/bison.yacc mv /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/man/man1/yacc.1 \ /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/man/man1/bison.yacc.1 make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' dh_install dh_installdocs dh_installchangelogs dh_installexamples dh_installman dh_lintian dh_perl dh_link dh_strip_nondeterminism Normalized debian/bison/usr/share/locale/uk/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/uk/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/tr/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/tr/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/tr/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/th/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ta/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/sv/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/sv/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/sv/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/it/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/it/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/id/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/id/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/ia/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/hu/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/hu/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/hr/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/hr/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/gl/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/eu/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/et/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/et/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/et/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/es/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/es/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/es/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/eo/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/eo/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/eo/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/ru/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/ro/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ro/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ro/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/pt_BR/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/pt_BR/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/pt_BR/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/pt/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/pt/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/pt/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/zh_TW/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/zh_TW/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/zh_TW/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/zh_CN/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/zh_CN/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/zh_CN/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/vi/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/vi/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/vi/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/uk/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ms/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ms/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/lv/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/lt/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ky/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ko/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ja/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ja/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ja/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/it/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/gl/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ga/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ga/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ga/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/fr/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/fr/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/fr/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/fi/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/fi/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/fi/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/ca/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ca/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ca/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/bg/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/bg/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/bg/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/be/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ast/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/af/LC_MESSAGES/bison-gnulib.mo Garbage at end of string in strptime: +02:00 at /usr/lib/aarch64-linux-gnu/perl/5.40/Time/Piece.pm line 598. Perhaps a format flag did not match the actual input? at /usr/lib/aarch64-linux-gnu/perl/5.40/Time/Piece.pm line 598. Normalized debian/bison/usr/share/locale/sr/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/sr/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/sr/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/sq/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/sl/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/sl/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/sk/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/rw/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ru/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ru/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/el/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/el/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/el/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/de/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/de/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/de/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/da/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/da/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/da/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/cs/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/pl/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/pl/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/pl/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/nl/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/nl/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/nl/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/nb/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/nb/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/nb/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/ms/LC_MESSAGES/bison-gnulib.mo dh_compress dh_fixperms dh_missing dh_dwz dh_strip dh_makeshlibs dh_shlibdeps dpkg-shlibdeps: warning: diversions involved - output may be incorrect diversion by libc6 from: /lib/ld-linux-aarch64.so.1 dpkg-shlibdeps: warning: diversions involved - output may be incorrect diversion by libc6 to: /lib/ld-linux-aarch64.so.1.usr-is-merged dh_installdeb dh_gencontrol dh_md5sums dh_builddeb dpkg-deb: building package 'bison' in '../bison_3.8.2+dfsg-1_arm64.deb'. dpkg-deb: building package 'bison-dbgsym' in '../bison-dbgsym_3.8.2+dfsg-1_arm64.deb'. dpkg-deb: building package 'libbison-dev' in '../libbison-dev_3.8.2+dfsg-1_arm64.deb'. dpkg-genbuildinfo --build=binary -O../bison_3.8.2+dfsg-1_arm64.buildinfo dpkg-genchanges --build=binary -O../bison_3.8.2+dfsg-1_arm64.changes dpkg-genchanges: info: binary-only upload (no source code included) dpkg-source --after-build . dpkg-buildpackage: info: binary-only upload (no source included) dpkg-genchanges: info: including full source code in upload I: copying local configuration I: unmounting dev/ptmx filesystem I: unmounting dev/pts filesystem I: unmounting dev/shm filesystem I: unmounting proc filesystem I: unmounting sys filesystem I: cleaning the build env I: removing directory /srv/workspace/pbuilder/1898584 and its subdirectories I: Current time: Fri Mar 27 06:46:44 -12 2026 I: pbuilder-time-stamp: 1774637204 Sat Feb 22 12:23:47 UTC 2025 I: 1st build successful. Starting 2nd build on remote node codethink04-arm64.debian.net. Sat Feb 22 12:23:47 UTC 2025 I: Preparing to do remote build '2' on codethink04-arm64.debian.net. Sat Feb 22 12:23:47 UTC 2025 - checking /var/lib/jenkins/offline_nodes if codethink04-arm64.debian.net is marked as down. Sat Feb 22 12:23:47 UTC 2025 - checking via ssh if codethink04-arm64.debian.net is up. removed '/tmp/read-only-fs-test-04s4b8' ==================================================================================== Sat Feb 22 12:23:48 UTC 2025 - running /srv/jenkins/bin/reproducible_build.sh (for job /srv/jenkins/bin/reproducible_build.sh) on codethink04-arm64, called using "2 bison trixie /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe 2:3.8.2+dfsg-1" as arguments. Sat Feb 22 12:23:48 UTC 2025 - actually running "reproducible_build.sh" (md5sum 68e686e434c9ab7bc3ec047d8b309cbc) as "/tmp/jenkins-script-3evhjfDU" $ git clone https://salsa.debian.org/qa/jenkins.debian.net.git ; more CONTRIBUTING Sat Feb 22 12:23:48 UTC 2025 I: Downloading source for trixie/bison=2:3.8.2+dfsg-1 Reading package lists... Need to get 2668 kB of source archives. Get:1 http://deb.debian.org/debian trixie/main bison 2:3.8.2+dfsg-1 (dsc) [1855 B] Get:2 http://deb.debian.org/debian trixie/main bison 2:3.8.2+dfsg-1 (tar) [2655 kB] Get:3 http://deb.debian.org/debian trixie/main bison 2:3.8.2+dfsg-1 (diff) [11.2 kB] Fetched 2668 kB in 0s (60.5 MB/s) Download complete and in download only mode Reading package lists... Need to get 2668 kB of source archives. Get:1 http://deb.debian.org/debian trixie/main bison 2:3.8.2+dfsg-1 (dsc) [1855 B] Get:2 http://deb.debian.org/debian trixie/main bison 2:3.8.2+dfsg-1 (tar) [2655 kB] Get:3 http://deb.debian.org/debian trixie/main bison 2:3.8.2+dfsg-1 (diff) [11.2 kB] Fetched 2668 kB in 0s (60.5 MB/s) Download complete and in download only mode ============================================================================= Re-Building bison in trixie on arm64 on codethink04-arm64 now. Date: Sat Feb 22 12:23:48 GMT 2025 Date UTC: Sat Feb 22 12:23:48 UTC 2025 ============================================================================= ++ mktemp -t pbuilderrc_XXXX --tmpdir=/srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe + local TMPCFG=/srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/pbuilderrc_u001 + case ${ARCH} in + case $ARCH in + locale=nl_BE + language=nl + case "${SUITE}" in + reproducible_buildflags=+all + extra_deb_build_options= + case "${SRCPACKAGE}" in + cat + echo BUILDDIR=/build/reproducible-path + '[' bison = debian-installer -o bison = debian-installer-netboot-images ']' + pbuilder_options=() + local pbuilder_options + DEBBUILDOPTS=-b + BINARYTARGET= + '[' bison = u-boot ']' + case "${SRCPACKAGE}" in + PBUILDERTIMEOUT=24 + local PRESULT=0 + sudo timeout -k 24.1h 24h /usr/bin/ionice -c 3 /usr/bin/nice -n 11 /usr/bin/unshare --uts -- /usr/sbin/pbuilder --build --configfile /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/pbuilderrc_u001 --distribution trixie --hookdir /etc/pbuilder/rebuild-hooks --debbuildopts -b --basetgz /var/cache/pbuilder/trixie-reproducible-base.tgz --buildresult /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/b2 --logfile b2/build.log bison_3.8.2+dfsg-1.dsc W: /root/.pbuilderrc does not exist I: Logging to b2/build.log I: pbuilder: network access will be disabled during build I: Current time: Sun Feb 23 02:23:49 +14 2025 I: pbuilder-time-stamp: 1740227029 I: Building the build Environment I: extracting base tarball [/var/cache/pbuilder/trixie-reproducible-base.tgz] I: copying local configuration W: --override-config is not set; not updating apt.conf Read the manpage for details. I: mounting /proc filesystem I: mounting /sys filesystem I: creating /{dev,run}/shm I: mounting /dev/pts filesystem I: redirecting /dev/ptmx to /dev/pts/ptmx I: policy-rc.d already exists I: Copying source file I: copying [bison_3.8.2+dfsg-1.dsc] I: copying [./bison_3.8.2+dfsg.orig.tar.xz] I: copying [./bison_3.8.2+dfsg-1.debian.tar.xz] I: Extracting source dpkg-source: warning: cannot verify inline signature for ./bison_3.8.2+dfsg-1.dsc: unsupported subcommand dpkg-source: info: extracting bison in bison-3.8.2+dfsg dpkg-source: info: unpacking bison_3.8.2+dfsg.orig.tar.xz dpkg-source: info: unpacking bison_3.8.2+dfsg-1.debian.tar.xz dpkg-source: info: using patch list from debian/patches/series dpkg-source: info: applying 01_keep_stamp_files dpkg-source: info: applying 02_parse_h_dependency I: using fakeroot in build. I: Installing the build-deps I: user script /srv/workspace/pbuilder/900897/tmp/hooks/D01_modify_environment starting debug: Running on codethink04-arm64. I: Changing host+domainname to test build reproducibility I: Adding a custom variable just for the fun of it... I: Changing /bin/sh to bash '/bin/sh' -> '/bin/bash' lrwxrwxrwx 1 root root 9 Feb 22 12:23 /bin/sh -> /bin/bash I: Setting pbuilder2's login shell to /bin/bash I: Setting pbuilder2's GECOS to second user,second room,second work-phone,second home-phone,second other I: user script /srv/workspace/pbuilder/900897/tmp/hooks/D01_modify_environment finished I: user script /srv/workspace/pbuilder/900897/tmp/hooks/D02_print_environment starting I: set BASH=/bin/sh BASHOPTS=checkwinsize:cmdhist:complete_fullquote:extquote:force_fignore:globasciiranges:globskipdots:hostcomplete:interactive_comments:patsub_replacement:progcomp:promptvars:sourcepath BASH_ALIASES=() BASH_ARGC=() BASH_ARGV=() BASH_CMDS=() BASH_LINENO=([0]="12" [1]="0") BASH_LOADABLES_PATH=/usr/local/lib/bash:/usr/lib/bash:/opt/local/lib/bash:/usr/pkg/lib/bash:/opt/pkg/lib/bash:. BASH_SOURCE=([0]="/tmp/hooks/D02_print_environment" [1]="/tmp/hooks/D02_print_environment") BASH_VERSINFO=([0]="5" [1]="2" [2]="37" [3]="1" [4]="release" [5]="aarch64-unknown-linux-gnu") BASH_VERSION='5.2.37(1)-release' BUILDDIR=/build/reproducible-path BUILDUSERGECOS='second user,second room,second work-phone,second home-phone,second other' BUILDUSERNAME=pbuilder2 BUILD_ARCH=arm64 DEBIAN_FRONTEND=noninteractive DEB_BUILD_OPTIONS='buildinfo=+all reproducible=+all parallel=12 ' DIRSTACK=() DISTRIBUTION=trixie EUID=0 FUNCNAME=([0]="Echo" [1]="main") GROUPS=() HOME=/root HOSTNAME=i-capture-the-hostname HOSTTYPE=aarch64 HOST_ARCH=arm64 IFS=' ' INVOCATION_ID=9ab0a127dcc04df38166a67ffb8e70a7 LANG=C LANGUAGE=nl_BE:nl LC_ALL=C MACHTYPE=aarch64-unknown-linux-gnu MAIL=/var/mail/root OPTERR=1 OPTIND=1 OSTYPE=linux-gnu PATH=/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/i/capture/the/path PBCURRENTCOMMANDLINEOPERATION=build PBUILDER_OPERATION=build PBUILDER_PKGDATADIR=/usr/share/pbuilder PBUILDER_PKGLIBDIR=/usr/lib/pbuilder PBUILDER_SYSCONFDIR=/etc PIPESTATUS=([0]="0") POSIXLY_CORRECT=y PPID=900897 PS4='+ ' PWD=/ SHELL=/bin/bash SHELLOPTS=braceexpand:errexit:hashall:interactive-comments:posix SHLVL=3 SUDO_COMMAND='/usr/bin/timeout -k 24.1h 24h /usr/bin/ionice -c 3 /usr/bin/nice -n 11 /usr/bin/unshare --uts -- /usr/sbin/pbuilder --build --configfile /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/pbuilderrc_u001 --distribution trixie --hookdir /etc/pbuilder/rebuild-hooks --debbuildopts -b --basetgz /var/cache/pbuilder/trixie-reproducible-base.tgz --buildresult /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/b2 --logfile b2/build.log bison_3.8.2+dfsg-1.dsc' SUDO_GID=109 SUDO_UID=104 SUDO_USER=jenkins TERM=unknown TZ=/usr/share/zoneinfo/Etc/GMT-14 UID=0 USER=root _='I: set' http_proxy=http://192.168.101.4:3128 I: uname -a Linux i-capture-the-hostname 6.1.0-31-cloud-arm64 #1 SMP Debian 6.1.128-1 (2025-02-07) aarch64 GNU/Linux I: ls -l /bin lrwxrwxrwx 1 root root 7 Nov 22 14:40 /bin -> usr/bin I: user script /srv/workspace/pbuilder/900897/tmp/hooks/D02_print_environment finished -> Attempting to satisfy build-dependencies -> Creating pbuilder-satisfydepends-dummy package Package: pbuilder-satisfydepends-dummy Version: 0.invalid.0 Architecture: arm64 Maintainer: Debian Pbuilder Team Description: Dummy package to satisfy dependencies with aptitude - created by pbuilder This package was created automatically by pbuilder to satisfy the build-dependencies of the package being currently built. Depends: debhelper-compat (= 12), gettext, flex, m4 (>= 1.4-14), help2man dpkg-deb: building package 'pbuilder-satisfydepends-dummy' in '/tmp/satisfydepends-aptitude/pbuilder-satisfydepends-dummy.deb'. Selecting previously unselected package pbuilder-satisfydepends-dummy. (Reading database ... 19972 files and directories currently installed.) Preparing to unpack .../pbuilder-satisfydepends-dummy.deb ... Unpacking pbuilder-satisfydepends-dummy (0.invalid.0) ... dpkg: pbuilder-satisfydepends-dummy: dependency problems, but configuring anyway as you requested: pbuilder-satisfydepends-dummy depends on debhelper-compat (= 12); however: Package debhelper-compat is not installed. pbuilder-satisfydepends-dummy depends on gettext; however: Package gettext is not installed. pbuilder-satisfydepends-dummy depends on flex; however: Package flex is not installed. pbuilder-satisfydepends-dummy depends on m4 (>= 1.4-14); however: Package m4 is not installed. pbuilder-satisfydepends-dummy depends on help2man; however: Package help2man is not installed. Setting up pbuilder-satisfydepends-dummy (0.invalid.0) ... Reading package lists... Building dependency tree... Reading state information... Initializing package states... Writing extended state information... Building tag database... pbuilder-satisfydepends-dummy is already installed at the requested version (0.invalid.0) pbuilder-satisfydepends-dummy is already installed at the requested version (0.invalid.0) The following NEW packages will be installed: autoconf{a} automake{a} autopoint{a} autotools-dev{a} bsdextrautils{a} debhelper{a} dh-autoreconf{a} dh-strip-nondeterminism{a} dwz{a} file{a} flex{a} gettext{a} gettext-base{a} groff-base{a} help2man{a} intltool-debian{a} libarchive-zip-perl{a} libdebhelper-perl{a} libelf1t64{a} libfile-stripnondeterminism-perl{a} libicu72{a} liblocale-gettext-perl{a} libmagic-mgc{a} libmagic1t64{a} libpipeline1{a} libtool{a} libuchardet0{a} libunistring5{a} libxml2{a} m4{a} man-db{a} po-debconf{a} sensible-utils{a} The following packages are RECOMMENDED but will NOT be installed: curl libarchive-cpio-perl libfl-dev libltdl-dev libmail-sendmail-perl lynx wget 0 packages upgraded, 33 newly installed, 0 to remove and 0 not upgraded. Need to get 20.7 MB of archives. After unpacking 82.3 MB will be used. Writing extended state information... Get: 1 http://deb.debian.org/debian trixie/main arm64 m4 arm64 1.4.19-5 [284 kB] Get: 2 http://deb.debian.org/debian trixie/main arm64 flex arm64 2.6.4-8.2+b4 [412 kB] Get: 3 http://deb.debian.org/debian trixie/main arm64 liblocale-gettext-perl arm64 1.07-7+b1 [15.2 kB] Get: 4 http://deb.debian.org/debian trixie/main arm64 sensible-utils all 0.0.24 [24.8 kB] Get: 5 http://deb.debian.org/debian trixie/main arm64 libmagic-mgc arm64 1:5.45-3+b1 [314 kB] Get: 6 http://deb.debian.org/debian trixie/main arm64 libmagic1t64 arm64 1:5.45-3+b1 [102 kB] Get: 7 http://deb.debian.org/debian trixie/main arm64 file arm64 1:5.45-3+b1 [43.4 kB] Get: 8 http://deb.debian.org/debian trixie/main arm64 gettext-base arm64 0.23.1-1 [241 kB] Get: 9 http://deb.debian.org/debian trixie/main arm64 libuchardet0 arm64 0.0.8-1+b2 [69.2 kB] Get: 10 http://deb.debian.org/debian trixie/main arm64 groff-base arm64 1.23.0-7 [1129 kB] Get: 11 http://deb.debian.org/debian trixie/main arm64 bsdextrautils arm64 2.40.4-3 [92.0 kB] Get: 12 http://deb.debian.org/debian trixie/main arm64 libpipeline1 arm64 1.5.8-1 [40.2 kB] Get: 13 http://deb.debian.org/debian trixie/main arm64 man-db arm64 2.13.0-1 [1404 kB] Get: 14 http://deb.debian.org/debian trixie/main arm64 autoconf all 2.72-3 [493 kB] Get: 15 http://deb.debian.org/debian trixie/main arm64 autotools-dev all 20220109.1 [51.6 kB] Get: 16 http://deb.debian.org/debian trixie/main arm64 automake all 1:1.17-3 [862 kB] Get: 17 http://deb.debian.org/debian trixie/main arm64 autopoint all 0.23.1-1 [770 kB] Get: 18 http://deb.debian.org/debian trixie/main arm64 libdebhelper-perl all 13.24.1 [90.9 kB] Get: 19 http://deb.debian.org/debian trixie/main arm64 libtool all 2.5.4-3 [539 kB] Get: 20 http://deb.debian.org/debian trixie/main arm64 dh-autoreconf all 20 [17.1 kB] Get: 21 http://deb.debian.org/debian trixie/main arm64 libarchive-zip-perl all 1.68-1 [104 kB] Get: 22 http://deb.debian.org/debian trixie/main arm64 libfile-stripnondeterminism-perl all 1.14.1-2 [19.7 kB] Get: 23 http://deb.debian.org/debian trixie/main arm64 dh-strip-nondeterminism all 1.14.1-2 [8620 B] Get: 24 http://deb.debian.org/debian trixie/main arm64 libelf1t64 arm64 0.192-4 [189 kB] Get: 25 http://deb.debian.org/debian trixie/main arm64 dwz arm64 0.15-1+b1 [102 kB] Get: 26 http://deb.debian.org/debian trixie/main arm64 libunistring5 arm64 1.3-1 [449 kB] Get: 27 http://deb.debian.org/debian trixie/main arm64 libicu72 arm64 72.1-6 [9239 kB] Get: 28 http://deb.debian.org/debian trixie/main arm64 libxml2 arm64 2.12.7+dfsg+really2.9.14-0.2+b1 [630 kB] Get: 29 http://deb.debian.org/debian trixie/main arm64 gettext arm64 0.23.1-1 [1610 kB] Get: 30 http://deb.debian.org/debian trixie/main arm64 intltool-debian all 0.35.0+20060710.6 [22.9 kB] Get: 31 http://deb.debian.org/debian trixie/main arm64 po-debconf all 1.0.21+nmu1 [248 kB] Get: 32 http://deb.debian.org/debian trixie/main arm64 debhelper all 13.24.1 [920 kB] Get: 33 http://deb.debian.org/debian trixie/main arm64 help2man arm64 1.49.3+b1 [198 kB] Fetched 20.7 MB in 0s (120 MB/s) Preconfiguring packages ... Selecting previously unselected package m4. (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 19972 files and directories currently installed.) Preparing to unpack .../00-m4_1.4.19-5_arm64.deb ... Unpacking m4 (1.4.19-5) ... Selecting previously unselected package flex. Preparing to unpack .../01-flex_2.6.4-8.2+b4_arm64.deb ... Unpacking flex (2.6.4-8.2+b4) ... Selecting previously unselected package liblocale-gettext-perl. Preparing to unpack .../02-liblocale-gettext-perl_1.07-7+b1_arm64.deb ... Unpacking liblocale-gettext-perl (1.07-7+b1) ... Selecting previously unselected package sensible-utils. Preparing to unpack .../03-sensible-utils_0.0.24_all.deb ... Unpacking sensible-utils (0.0.24) ... Selecting previously unselected package libmagic-mgc. Preparing to unpack .../04-libmagic-mgc_1%3a5.45-3+b1_arm64.deb ... Unpacking libmagic-mgc (1:5.45-3+b1) ... Selecting previously unselected package libmagic1t64:arm64. Preparing to unpack .../05-libmagic1t64_1%3a5.45-3+b1_arm64.deb ... Unpacking libmagic1t64:arm64 (1:5.45-3+b1) ... Selecting previously unselected package file. Preparing to unpack .../06-file_1%3a5.45-3+b1_arm64.deb ... Unpacking file (1:5.45-3+b1) ... Selecting previously unselected package gettext-base. Preparing to unpack .../07-gettext-base_0.23.1-1_arm64.deb ... Unpacking gettext-base (0.23.1-1) ... Selecting previously unselected package libuchardet0:arm64. Preparing to unpack .../08-libuchardet0_0.0.8-1+b2_arm64.deb ... Unpacking libuchardet0:arm64 (0.0.8-1+b2) ... Selecting previously unselected package groff-base. Preparing to unpack .../09-groff-base_1.23.0-7_arm64.deb ... Unpacking groff-base (1.23.0-7) ... Selecting previously unselected package bsdextrautils. Preparing to unpack .../10-bsdextrautils_2.40.4-3_arm64.deb ... Unpacking bsdextrautils (2.40.4-3) ... Selecting previously unselected package libpipeline1:arm64. Preparing to unpack .../11-libpipeline1_1.5.8-1_arm64.deb ... Unpacking libpipeline1:arm64 (1.5.8-1) ... Selecting previously unselected package man-db. Preparing to unpack .../12-man-db_2.13.0-1_arm64.deb ... Unpacking man-db (2.13.0-1) ... Selecting previously unselected package autoconf. Preparing to unpack .../13-autoconf_2.72-3_all.deb ... Unpacking autoconf (2.72-3) ... Selecting previously unselected package autotools-dev. Preparing to unpack .../14-autotools-dev_20220109.1_all.deb ... Unpacking autotools-dev (20220109.1) ... Selecting previously unselected package automake. Preparing to unpack .../15-automake_1%3a1.17-3_all.deb ... Unpacking automake (1:1.17-3) ... Selecting previously unselected package autopoint. Preparing to unpack .../16-autopoint_0.23.1-1_all.deb ... Unpacking autopoint (0.23.1-1) ... Selecting previously unselected package libdebhelper-perl. Preparing to unpack .../17-libdebhelper-perl_13.24.1_all.deb ... Unpacking libdebhelper-perl (13.24.1) ... Selecting previously unselected package libtool. Preparing to unpack .../18-libtool_2.5.4-3_all.deb ... Unpacking libtool (2.5.4-3) ... Selecting previously unselected package dh-autoreconf. Preparing to unpack .../19-dh-autoreconf_20_all.deb ... Unpacking dh-autoreconf (20) ... Selecting previously unselected package libarchive-zip-perl. Preparing to unpack .../20-libarchive-zip-perl_1.68-1_all.deb ... Unpacking libarchive-zip-perl (1.68-1) ... Selecting previously unselected package libfile-stripnondeterminism-perl. Preparing to unpack .../21-libfile-stripnondeterminism-perl_1.14.1-2_all.deb ... Unpacking libfile-stripnondeterminism-perl (1.14.1-2) ... Selecting previously unselected package dh-strip-nondeterminism. Preparing to unpack .../22-dh-strip-nondeterminism_1.14.1-2_all.deb ... Unpacking dh-strip-nondeterminism (1.14.1-2) ... Selecting previously unselected package libelf1t64:arm64. Preparing to unpack .../23-libelf1t64_0.192-4_arm64.deb ... Unpacking libelf1t64:arm64 (0.192-4) ... Selecting previously unselected package dwz. Preparing to unpack .../24-dwz_0.15-1+b1_arm64.deb ... Unpacking dwz (0.15-1+b1) ... Selecting previously unselected package libunistring5:arm64. Preparing to unpack .../25-libunistring5_1.3-1_arm64.deb ... Unpacking libunistring5:arm64 (1.3-1) ... Selecting previously unselected package libicu72:arm64. Preparing to unpack .../26-libicu72_72.1-6_arm64.deb ... Unpacking libicu72:arm64 (72.1-6) ... Selecting previously unselected package libxml2:arm64. Preparing to unpack .../27-libxml2_2.12.7+dfsg+really2.9.14-0.2+b1_arm64.deb ... Unpacking libxml2:arm64 (2.12.7+dfsg+really2.9.14-0.2+b1) ... Selecting previously unselected package gettext. Preparing to unpack .../28-gettext_0.23.1-1_arm64.deb ... Unpacking gettext (0.23.1-1) ... Selecting previously unselected package intltool-debian. Preparing to unpack .../29-intltool-debian_0.35.0+20060710.6_all.deb ... Unpacking intltool-debian (0.35.0+20060710.6) ... Selecting previously unselected package po-debconf. Preparing to unpack .../30-po-debconf_1.0.21+nmu1_all.deb ... Unpacking po-debconf (1.0.21+nmu1) ... Selecting previously unselected package debhelper. Preparing to unpack .../31-debhelper_13.24.1_all.deb ... Unpacking debhelper (13.24.1) ... Selecting previously unselected package help2man. Preparing to unpack .../32-help2man_1.49.3+b1_arm64.deb ... Unpacking help2man (1.49.3+b1) ... Setting up libpipeline1:arm64 (1.5.8-1) ... Setting up libicu72:arm64 (72.1-6) ... Setting up bsdextrautils (2.40.4-3) ... Setting up libmagic-mgc (1:5.45-3+b1) ... Setting up libarchive-zip-perl (1.68-1) ... Setting up libdebhelper-perl (13.24.1) ... Setting up libmagic1t64:arm64 (1:5.45-3+b1) ... Setting up gettext-base (0.23.1-1) ... Setting up m4 (1.4.19-5) ... Setting up file (1:5.45-3+b1) ... Setting up libelf1t64:arm64 (0.192-4) ... Setting up autotools-dev (20220109.1) ... Setting up libunistring5:arm64 (1.3-1) ... Setting up autopoint (0.23.1-1) ... Setting up autoconf (2.72-3) ... Setting up dwz (0.15-1+b1) ... Setting up sensible-utils (0.0.24) ... Setting up libuchardet0:arm64 (0.0.8-1+b2) ... Setting up libxml2:arm64 (2.12.7+dfsg+really2.9.14-0.2+b1) ... Setting up liblocale-gettext-perl (1.07-7+b1) ... Setting up automake (1:1.17-3) ... update-alternatives: using /usr/bin/automake-1.17 to provide /usr/bin/automake (automake) in auto mode Setting up libfile-stripnondeterminism-perl (1.14.1-2) ... Setting up flex (2.6.4-8.2+b4) ... Setting up gettext (0.23.1-1) ... Setting up libtool (2.5.4-3) ... Setting up intltool-debian (0.35.0+20060710.6) ... Setting up help2man (1.49.3+b1) ... Setting up dh-autoreconf (20) ... Setting up dh-strip-nondeterminism (1.14.1-2) ... Setting up groff-base (1.23.0-7) ... Setting up po-debconf (1.0.21+nmu1) ... Setting up man-db (2.13.0-1) ... Not building database; man-db/auto-update is not 'true'. Setting up debhelper (13.24.1) ... Processing triggers for libc-bin (2.40-7) ... Reading package lists... Building dependency tree... Reading state information... Reading extended state information... Initializing package states... Writing extended state information... Building tag database... -> Finished parsing the build-deps Reading package lists... Building dependency tree... Reading state information... fakeroot is already the newest version (1.37-1). 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. I: Building the package I: user script /srv/workspace/pbuilder/900897/tmp/hooks/A99_set_merged_usr starting Not re-configuring usrmerge for trixie I: user script /srv/workspace/pbuilder/900897/tmp/hooks/A99_set_merged_usr finished hostname: Name or service not known I: Running cd /build/reproducible-path/bison-3.8.2+dfsg/ && env PATH="/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/i/capture/the/path" HOME="/nonexistent/second-build" dpkg-buildpackage -us -uc -b && env PATH="/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/i/capture/the/path" HOME="/nonexistent/second-build" dpkg-genchanges -S > ../bison_3.8.2+dfsg-1_source.changes dpkg-buildpackage: info: source package bison dpkg-buildpackage: info: source version 2:3.8.2+dfsg-1 dpkg-buildpackage: info: source distribution unstable dpkg-buildpackage: info: source changed by Chuan-kai Lin dpkg-source --before-build . dpkg-buildpackage: info: host architecture arm64 debian/rules clean dh clean debian/rules override_dh_auto_clean make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' [ ! -f /build/reproducible-path/bison-3.8.2+dfsg/Makefile ] || dh_auto_clean make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' dh_clean debian/rules binary dh binary dh_update_autotools_config debian/rules execute_before_dh_autoreconf make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' echo '@setfilename bison.info' > /build/reproducible-path/bison-3.8.2+dfsg/doc/bison.texi make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' dh_autoreconf Copying file build-aux/config.rpath Copying file m4/extern-inline.m4 Copying file m4/glibc2.m4 Copying file m4/glibc21.m4 Copying file m4/intdiv0.m4 Copying file m4/intl.m4 Copying file m4/intldir.m4 Copying file m4/intmax.m4 Copying file m4/inttypes-pri.m4 Copying file m4/lcmessage.m4 Copying file m4/longlong.m4 Copying file m4/printf-posix.m4 Copying file m4/uintmax_t.m4 Copying file gnulib-po/Makevars.template Copying file runtime-po/Makevars.template Copying file po/Makevars.template Copying file gnulib-po/remove-potcdate.sin debian/rules override_dh_auto_configure make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' dh_auto_configure -- --disable-silent-rules ./configure --build=aarch64-linux-gnu --prefix=/usr --includedir=\${prefix}/include --mandir=\${prefix}/share/man --infodir=\${prefix}/share/info --sysconfdir=/etc --localstatedir=/var --disable-option-checking --disable-silent-rules --libdir=\${prefix}/lib/aarch64-linux-gnu --runstatedir=/run --disable-maintainer-mode --disable-dependency-tracking --disable-silent-rules checking for a BSD-compatible install... /usr/bin/install -c checking whether sleep supports fractional seconds... yes checking filesystem timestamp resolution... 0.01 checking whether build environment is sane... yes checking for a race-free mkdir -p... /usr/bin/mkdir -p checking for gawk... no checking for mawk... mawk checking whether make sets $(MAKE)... yes checking whether make supports nested variables... yes checking xargs -n works... yes checking for gcc... gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... checking whether we are cross compiling... no checking for suffix of object files... o checking whether the compiler supports GNU C... yes checking whether gcc accepts -g... yes checking for gcc option to enable C11 features... none needed checking whether gcc understands -c and -o together... yes checking whether the compiler is clang... no checking for compiler option needed when checking for declarations... none checking whether make supports the include directive... yes (GNU style) checking dependency style of gcc... none checking for g++... g++ checking whether the compiler supports GNU C++... yes checking whether g++ accepts -g... yes checking for g++ option to enable C++11 features... none needed checking dependency style of g++... none checking for stdio.h... yes checking for stdlib.h... yes checking for string.h... yes checking for inttypes.h... yes checking for stdint.h... yes checking for strings.h... yes checking for sys/stat.h... yes checking for sys/types.h... yes checking for unistd.h... yes checking for wchar.h... yes checking for minix/config.h... no checking for locale.h... yes checking for sys/param.h... yes checking for sys/socket.h... yes checking for stdio_ext.h... yes checking for features.h... yes checking for getopt.h... yes checking for sys/cdefs.h... yes checking for sys/time.h... yes checking for iconv.h... yes checking for limits.h... yes checking for crtdefs.h... no checking for wctype.h... yes checking for threads.h... yes checking for math.h... yes checking for sys/mman.h... yes checking for spawn.h... yes checking for sys/ioctl.h... yes checking for sys/resource.h... yes checking for sys/times.h... yes checking for sys/wait.h... yes checking for termios.h... yes checking for dirent.h... yes checking for xlocale.h... no checking whether it is safe to define __EXTENSIONS__... yes checking whether _XOPEN_SOURCE should be defined... no checking build system type... aarch64-unknown-linux-gnu checking host system type... aarch64-unknown-linux-gnu checking how to run the C preprocessor... gcc -E checking for egrep -e... /usr/bin/grep -E checking for Minix Amsterdam compiler... no checking for ar... ar checking for ranlib... ranlib checking for special C compiler options needed for large files... no checking for _FILE_OFFSET_BITS value needed for large files... no checking for ld used by gcc... /usr/bin/ld checking if the linker (/usr/bin/ld) is GNU ld... yes checking for shared library run path origin... done checking 32-bit host C ABI... no checking for ELF binary format... yes checking for the common suffixes of directories in the library search path... lib,lib,lib checking for libtextstyle... no checking for inline... inline checking for tcdrain... yes checking for canonicalize_file_name... yes checking for faccessat... yes checking for realpath... yes checking for lstat... yes checking for readlinkat... yes checking for _set_invalid_parameter_handler... no checking for fchdir... yes checking for fcntl... yes checking for symlink... yes checking for ffsl... yes checking for vasnprintf... no checking for snprintf... yes checking for fsync... yes checking for microuptime... no checking for nanouptime... no checking for getprogname... no checking for getexecname... no checking for getrusage... yes checking for gettimeofday... yes checking for iswcntrl... yes checking for iswblank... yes checking for mbsinit... yes checking for mbrtowc... yes checking for isascii... yes checking for mprotect... yes checking for obstack_printf... yes checking for strerror_r... yes checking for __xpg_strerror_r... yes checking for pipe... yes checking for pipe2... yes checking for posix_spawn_file_actions_addchdir_np... yes checking for posix_spawn_file_actions_addchdir... no checking for readlink... yes checking for setenv... yes checking for link... yes checking for sigaction... yes checking for sigaltstack... yes checking for siginterrupt... yes checking for stpncpy... yes checking for strndup... yes checking for wcwidth... yes checking for fdopendir... yes checking for mempcpy... yes checking for __fseterr... no checking for fstatat... yes checking for getdelim... yes checking for getdtablesize... yes checking for openat... yes checking for catgets... yes checking for setlocale... yes checking whether pragma GCC diagnostic push works... yes checking whether C++ compiler handles -Werror -Wunknown-warning-option... no checking whether C++ compiler handles -fno-exceptions... yes checking whether C++ compiler accepts -std=c++98... yes checking whether C++ compiler accepts -std=c++03... yes checking whether C++ compiler accepts -std=c++11... yes checking whether C++ compiler accepts -std=c++14... yes checking whether C++ compiler accepts -std=c++17... yes checking whether C++ compiler accepts -std=c++20... yes checking whether C++ compiler accepts -std=c++2b... yes checking whether gcc supports POSIXLY_CORRECT=1... yes checking whether g++ builds executables that work... yes checking whether g++ supports POSIXLY_CORRECT=1... yes checking for dmd... no checking for -g... no checking for Java compiler... no checking for Java virtual machine... no checking for flex... flex checking whether lex is flex... yes checking whether flex supports --header=FILE... yes checking lex output file root... lex.yy checking lex library... none needed checking whether yytext is a pointer... no checking for bison... no checking for byacc... no checking for ranlib... (cached) ranlib checking for GNU M4 that supports accurate traces... /usr/bin/m4 checking whether /usr/bin/m4 accepts --gnu... yes checking how m4 supports trace files... --debugfile checking for perl... /usr/bin/perl checking for xsltproc... no checking for inline... (cached) inline checking for size_t... yes checking for working alloca.h... yes checking for alloca... yes checking whether malloc is ptrdiff_t safe... yes checking whether malloc, realloc, calloc set errno on failure... yes checking whether lstat correctly handles trailing slash... yes checking whether // is distinct from /... no checking whether realpath works... yes checking for getcwd... yes checking for C/C++ restrict keyword... __restrict__ checking if environ is properly declared... yes checking whether the preprocessor supports include_next... yes checking whether source code line length is unlimited... yes checking for complete errno.h... yes checking for gcc options needed to detect all undeclared functions... none needed checking whether strerror_r is declared... yes checking whether strerror_r returns char *... yes checking for mode_t... yes checking for sig_atomic_t... yes checking for working fcntl.h... yes checking for pid_t... yes checking for eaccess... yes checking for stdint.h... yes checking for inttypes.h... yes checking whether printf supports size specifiers as in C99... yes checking whether printf supports 'long double' arguments... yes checking whether printf supports infinite 'double' arguments... yes checking whether byte ordering is bigendian... no checking whether long double and double are the same... no checking whether printf supports infinite 'long double' arguments... yes checking whether printf supports the 'a' and 'A' directives... yes checking whether printf supports the 'F' directive... yes checking whether printf supports the 'n' directive... no checking whether printf supports the 'ls' directive... yes checking whether printf supports POSIX/XSI format strings with positions... yes checking whether printf supports the grouping flag... yes checking whether printf supports the left-adjust flag correctly... yes checking whether printf supports the zero flag correctly... yes checking whether printf supports large precisions... yes checking whether the compiler produces multi-arch binaries... no checking whether printf survives out-of-memory conditions... yes checking for wchar_t... yes checking for wint_t... yes checking whether wint_t is large enough... yes checking for intmax_t... yes checking where to find the exponent in a 'double'... word 1 bit 20 checking whether snprintf returns a byte count as in C99... yes checking whether snprintf truncates the result as in C99... yes checking for snprintf... (cached) yes checking for strnlen... yes checking for wcslen... yes checking for wcsnlen... yes checking for mbrtowc... (cached) yes checking for wcrtomb... yes checking whether _snprintf is declared... no checking whether frexp() can be used without linking with libm... yes checking whether alarm is declared... yes checking whether getcwd (NULL, 0) allocates memory for result... yes checking for getcwd with POSIX signature... yes checking whether getcwd is declared... yes checking for d_ino member in directory struct... yes checking for arithmetic hrtime_t... no checking for getopt.h... (cached) yes checking for getopt_long_only... yes checking whether getopt is POSIX compatible... yes checking for working GNU getopt function... yes checking for working GNU getopt_long function... yes checking for struct timeval... yes checking for wide-enough struct timeval.tv_sec member... yes checking for iconv... yes checking for working iconv... yes checking whether iconv is compatible with its POSIX signature... yes checking whether limits.h has WORD_BIT, BOOL_WIDTH etc.... yes checking whether stdint.h conforms to C99... yes checking whether stdint.h works without ISO C predefines... yes checking whether stdint.h has UINTMAX_WIDTH etc.... yes checking whether INT32_MAX < INTMAX_MAX... yes checking whether INT64_MAX == LONG_MAX... yes checking whether UINT32_MAX < UINTMAX_MAX... yes checking whether UINT64_MAX == ULONG_MAX... yes checking where to find the exponent in a 'float'... word 0 bit 23 checking whether isnan(float) can be used without linking with libm... yes checking whether isnan(float) works... yes checking whether isnan(double) can be used without linking with libm... yes checking whether isnan(long double) can be used without linking with libm... yes checking whether isnanl works... yes checking whether iswcntrl works... yes checking for towlower... yes checking for wctype_t... yes checking for wctrans_t... yes checking for nl_langinfo and CODESET... yes checking for a traditional french locale... fr_FR checking for a traditional japanese locale... ja_JP.EUC-JP checking for a french Unicode locale... fr_FR.UTF-8 checking for a transitional chinese locale... zh_CN.GB18030 checking whether ldexp() can be used without linking with libm... yes checking whether imported symbols can be declared weak... yes checking for pthread.h... yes checking for pthread_kill in -lpthread... yes checking whether POSIX threads API is available... yes checking for multithread API to use... posix checking for a sed that does not truncate output... /usr/bin/sed checking for grep that handles long lines and -e... /usr/bin/grep checking whether NAN macro works... yes checking whether HUGE_VAL works... yes checking for mbstate_t... yes checking for mmap... yes checking for MAP_ANONYMOUS... yes checking whether memchr works... yes checking whether defines MIN and MAX... no checking whether defines MIN and MAX... yes checking whether obstack_printf is declared... yes checking for O_CLOEXEC... yes checking for promoted mode_t type... mode_t checking whether strerror(0) succeeds... yes checking for strerror_r with POSIX signature... no checking whether __xpg_strerror_r works... yes checking for library containing posix_spawn... none required checking for posix_spawn... yes checking whether posix_spawn is declared... yes checking whether posix_spawn works... yes checking whether posix_spawn rejects scripts without shebang... yes checking whether posix_spawnp rejects scripts without shebang... yes checking whether posix_spawnattr_setschedpolicy is supported... yes checking whether posix_spawnattr_setschedparam is supported... yes checking for ptrdiff_t... yes checking for egrep... /usr/bin/grep -E checking whether C symbols are prefixed with underscore at the linker level... no checking for sigset_t... yes checking for shared library path variable... LD_LIBRARY_PATH checking whether to activate relocatable installation... no checking whether malloc (0) returns nonnull... yes checking whether setenv is declared... yes checking for sched.h... yes checking for struct sched_param... yes checking for uid_t... yes checking for gid_t... yes checking for volatile sig_atomic_t... yes checking for sighandler_t... yes checking whether snprintf is declared... yes checking for posix_spawnattr_t... yes checking for posix_spawn_file_actions_t... yes checking whether stat file-mode macros are broken... no checking for nlink_t... yes checking for stdbool.h that conforms to C99... yes checking for _Bool... yes checking for good max_align_t... yes checking whether NULL can be used in arbitrary expressions... yes checking whether fcloseall is declared... yes checking which flavor of printf attribute matches inttypes macros... system checking whether ecvt is declared... yes checking whether fcvt is declared... yes checking whether gcvt is declared... yes checking whether stpncpy is declared... yes checking whether strdup is declared... yes checking whether strndup is declared... yes checking whether declares ioctl... yes checking for struct tms... yes checking for struct timespec in ... yes checking for TIME_UTC in ... yes checking whether execvpe is declared... yes checking whether clearerr_unlocked is declared... yes checking whether feof_unlocked is declared... yes checking whether ferror_unlocked is declared... yes checking whether fflush_unlocked is declared... yes checking whether fgets_unlocked is declared... yes checking whether fputc_unlocked is declared... yes checking whether fputs_unlocked is declared... yes checking whether fread_unlocked is declared... yes checking whether fwrite_unlocked is declared... yes checking whether getc_unlocked is declared... yes checking whether getchar_unlocked is declared... yes checking whether putc_unlocked is declared... yes checking whether putchar_unlocked is declared... yes checking whether unsetenv is declared... yes checking whether vsnprintf is declared... yes checking whether uses 'inline' correctly... yes checking whether wcsdup is declared... yes checking POSIX termios... yes checking whether use of TIOCGWINSZ requires termios.h... no checking whether fchdir is declared... yes checking whether getdelim is declared... yes checking whether getdtablesize is declared... yes checking whether getline is declared... yes checking whether setlocale (LC_ALL, NULL) is multithread-safe... yes checking whether setlocale (category, NULL) is multithread-safe... yes checking whether locale.h defines locale_t... yes checking whether locale.h conforms to POSIX:2001... yes checking whether struct lconv is properly defined... yes checking whether memrchr is declared... yes checking whether strnlen is declared... yes checking for alloca as a compiler built-in... yes checking whether to enable assertions... yes checking for __builtin_expect... yes checking whether calloc (0, n) and calloc (n, 0) return nonnull... yes checking for library containing clock_gettime... none required checking for clock_gettime... yes checking for clock_settime... yes checking whether // is distinct from /... (cached) no checking whether dup2 works... yes checking for error_at_line... yes checking whether fcntl handles F_DUPFD correctly... yes checking whether fcntl understands F_DUPFD_CLOEXEC... needs runtime check checking whether conversion from 'int' to 'long double' works... yes checking whether fopen recognizes a trailing slash... yes checking whether fopen supports the mode character 'x'... yes checking whether fopen supports the mode character 'e'... yes checking for __fpending... yes checking whether __fpending is declared... yes checking for ptrdiff_t... (cached) yes checking whether free is known to preserve errno... yes checking whether frexp works... yes checking whether frexpl is declared... yes checking whether frexpl() can be used without linking with libm... yes checking whether frexpl works... yes checking whether getcwd handles long file names properly... yes checking for getpagesize... yes checking whether getcwd succeeds when 4k < cwd_length < 16k... yes checking whether gethrtime is declared... no checking whether CLOCK_MONOTONIC or CLOCK_REALTIME is defined... yes checking whether program_invocation_name is declared... yes checking whether program_invocation_short_name is declared... yes checking whether __argv is declared... no checking for gettimeofday with POSIX signature... yes checking whether the compiler generally respects inline... yes checking whether isnan macro works... yes checking whether isnan(double) can be used without linking with libm... (cached) yes checking whether isnan(double) can be used without linking with libm... (cached) yes checking whether isnan(float) can be used without linking with libm... (cached) yes checking whether isnan(float) works... (cached) yes checking whether isnan(long double) can be used without linking with libm... (cached) yes checking whether isnanl works... (cached) yes checking whether isnan(long double) can be used without linking with libm... (cached) yes checking whether isnanl works... (cached) yes checking whether iswblank is declared... yes checking whether iswdigit is ISO C compliant... yes checking whether iswxdigit is ISO C compliant... yes checking whether ldexpl is declared... yes checking whether ldexpl() can be used without linking with libm... yes checking whether ldexpl works... yes checking whether the compiler supports the __inline keyword... yes checking for pthread_rwlock_t... yes checking whether pthread_rwlock_rdlock prefers a writer to a reader... no checking whether malloc (0) returns nonnull... (cached) yes checking whether mbrtowc handles incomplete characters... yes checking whether mbrtowc works as well as mbtowc... yes checking whether mbrtowc handles a NULL pwc argument... yes checking whether mbrtowc handles a NULL string argument... yes checking whether mbrtowc has a correct return value... yes checking whether mbrtowc returns 0 when parsing a NUL character... yes checking whether mbrtowc stores incomplete characters... no checking whether mbrtowc works on empty input... yes checking whether the C locale is free of encoding errors... no checking whether mbrtowc handles incomplete characters... (cached) yes checking whether mbrtowc works as well as mbtowc... (cached) yes checking whether mbswidth is declared in ... no checking for mbstate_t... (cached) yes checking for mempcpy... (cached) yes checking for obstacks that work with any size object... no checking whether open recognizes a trailing slash... yes checking whether perror matches strerror... yes checking whether posix_spawn_file_actions_addclose works... yes checking whether posix_spawn_file_actions_adddup2 works... yes checking whether posix_spawn_file_actions_addopen works... yes checking whether frexp works... (cached) yes checking whether ldexp can be used without linking with libm... (cached) yes checking whether frexpl() can be used without linking with libm... (cached) yes checking whether frexpl works... (cached) yes checking whether frexpl is declared... (cached) yes checking whether ldexpl() can be used without linking with libm... (cached) yes checking whether ldexpl works... (cached) yes checking whether ldexpl is declared... (cached) yes checking whether program_invocation_name is declared... (cached) yes checking whether program_invocation_short_name is declared... (cached) yes checking for raise... yes checking for sigprocmask... yes checking for rawmemchr... yes checking for readline... no checking for readline/readline.h... no checking for readline/history.h... no checking whether readlink signature is correct... yes checking whether readlink handles trailing slash correctly... yes checking whether readlink truncates results correctly... yes checking whether realloc (0, 0) returns nonnull... yes checking for reallocarray... yes checking for getcwd... (cached) yes checking whether free is known to preserve errno... (cached) yes checking for mempcpy... (cached) yes checking for rawmemchr... (cached) yes checking for search.h... yes checking for tsearch... yes checking whether rename honors trailing slash on destination... yes checking whether rename honors trailing slash on source... yes checking whether rename manages hard links correctly... yes checking whether rename manages existing destinations correctly... yes checking for struct sigaction.sa_sigaction... yes checking for signbit macro... yes checking for signbit compiler built-ins... yes checking for sigprocmask... (cached) yes checking for stdint.h... (cached) yes checking for SIZE_MAX... yes checking for snprintf... (cached) yes checking whether snprintf respects a size of 1... yes checking whether printf supports POSIX/XSI format strings with positions... (cached) yes checking for snprintf... (cached) yes checking whether snprintf fully supports the 'n' directive... no checking whether snprintf respects a size of 1... (cached) yes checking whether vsnprintf respects a zero size as in C99... yes checking for ptrdiff_t... (cached) yes checking for ptrdiff_t... (cached) yes checking for ssize_t... yes checking whether stat handles trailing slashes on files... yes checking for working stdalign.h... yes checking for stpcpy... yes checking for working stpncpy... yes checking for working strerror function... yes checking for working strndup... yes checking whether strtod obeys C99... yes checking for strverscmp... yes checking for sys/single_threaded.h... yes checking whether unlink honors trailing slashes... yes checking whether unlink of a parent directory fails as it should... guessing yes checking for unsetenv... yes checking for unsetenv() return type... int checking whether unsetenv obeys POSIX... yes checking for ptrdiff_t... (cached) yes checking for vasprintf... yes checking for vasprintf... (cached) yes checking for ptrdiff_t... (cached) yes checking for vsnprintf... yes checking whether snprintf respects a size of 1... (cached) yes checking whether printf supports POSIX/XSI format strings with positions... (cached) yes checking for vsnprintf... (cached) yes checking whether snprintf fully supports the 'n' directive... (cached) no checking whether snprintf respects a size of 1... (cached) yes checking whether vsnprintf respects a zero size as in C99... (cached) yes checking for ptrdiff_t... (cached) yes checking for ptrdiff_t... (cached) yes checking for waitid... yes checking whether wcwidth is declared... yes checking whether wcwidth works reasonably in UTF-8 locales... yes checking whether use of TIOCGWINSZ requires sys/ioctl.h... yes checking whether use of TIOCGWINSZ requires termios.h... (cached) no checking whether use of struct winsize requires sys/ptem.h... no checking for stdint.h... (cached) yes checking whether getdtablesize works... yes checking whether setlocale (LC_ALL, NULL) is multithread-safe... (cached) yes checking whether setlocale (category, NULL) is multithread-safe... (cached) yes checking for ptrdiff_t... (cached) yes checking for getline... yes checking for working getline function... yes checking whether NLS is requested... yes checking for msgfmt... /usr/bin/msgfmt checking for gmsgfmt... /usr/bin/msgfmt checking for xgettext... /usr/bin/xgettext checking for msgmerge... /usr/bin/msgmerge checking for CFPreferencesCopyAppValue... no checking for CFLocaleCopyCurrent... no checking for GNU gettext in libc... yes checking whether to use NLS... yes checking where the gettext function comes from... libc checking for valgrind... no checking Valgrind suppression file... checking that generated files are newer than configure... done configure: creating ./config.status config.status: creating src/yacc config.status: creating javacomp.sh config.status: creating javaexec.sh config.status: creating gnulib-po/Makefile.in config.status: creating runtime-po/Makefile.in config.status: creating etc/bench.pl config.status: creating tests/atlocal config.status: creating tests/bison config.status: creating Makefile config.status: creating po/Makefile.in config.status: creating doc/yacc.1 config.status: creating lib/config.h config.status: executing depfiles commands config.status: executing po-directories commands config.status: creating gnulib-po/POTFILES config.status: creating gnulib-po/Makefile config.status: creating runtime-po/POTFILES config.status: creating runtime-po/Makefile config.status: creating po/POTFILES config.status: creating po/Makefile config.status: executing tests/atconfig commands make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' debian/rules execute_before_dh_auto_build make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' # Touch all files in the dependency tree of bison.info to # inhibit makeinfo invocation in the build process. install -d /build/reproducible-path/bison-3.8.2+dfsg/doc/figs touch --date="Jan 01 2000" \ /build/reproducible-path/bison-3.8.2+dfsg/doc/bison.info \ /build/reproducible-path/bison-3.8.2+dfsg/doc/bison.help \ /build/reproducible-path/bison-3.8.2+dfsg/doc/figs/example.txt \ /build/reproducible-path/bison-3.8.2+dfsg/doc/figs/example-reduce.txt \ /build/reproducible-path/bison-3.8.2+dfsg/doc/figs/example-shift.txt \ /build/reproducible-path/bison-3.8.2+dfsg/doc/*.texi \ /build/reproducible-path/bison-3.8.2+dfsg/build-aux/cross-options.pl \ /build/reproducible-path/bison-3.8.2+dfsg/src/getargs.c make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' dh_auto_build make -j12 make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' rm -f examples/c/reccalc/scan.stamp examples/c/reccalc/scan.stamp.tmp rm -f lib/alloca.h-t lib/alloca.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''HAVE_ALLOCA_H''@|1|g' < ./lib/alloca.in.h; \ } > lib/alloca.h-t && \ mv -f lib/alloca.h-t lib/alloca.h /usr/bin/mkdir -p examples/c/reccalc rm -f lib/configmake.h-t && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ echo '#if HAVE_WINSOCK2_H'; \ echo '# include /* avoid mingw pollution on DATADIR */'; \ echo '#endif'; \ echo '#define PREFIX "/usr"'; \ echo '#define EXEC_PREFIX "/usr"'; \ echo '#define BINDIR "/usr/bin"'; \ echo '#define SBINDIR "/usr/sbin"'; \ echo '#define LIBEXECDIR "/usr/libexec"'; \ echo '#define DATAROOTDIR "/usr/share"'; \ echo '#define DATADIR "/usr/share"'; \ echo '#define SYSCONFDIR "/etc"'; \ echo '#define SHAREDSTATEDIR "/usr/com"'; \ echo '#define LOCALSTATEDIR "/var"'; \ echo '#define RUNSTATEDIR "/run"'; \ echo '#define INCLUDEDIR "/usr/include"'; \ echo '#define OLDINCLUDEDIR "/usr/include"'; \ echo '#define DOCDIR "/usr/share/doc/bison"'; \ echo '#define INFODIR "/usr/share/info"'; \ echo '#define HTMLDIR "/usr/share/doc/bison"'; \ echo '#define DVIDIR "/usr/share/doc/bison"'; \ echo '#define PDFDIR "/usr/share/doc/bison"'; \ echo '#define PSDIR "/usr/share/doc/bison"'; \ echo '#define LIBDIR "/usr/lib/aarch64-linux-gnu"'; \ echo '#define LISPDIR "/usr/share/emacs/site-lisp"'; \ echo '#define LOCALEDIR "/usr/share/locale"'; \ echo '#define MANDIR "/usr/share/man"'; \ echo '#define MANEXT ""'; \ echo '#define PKGDATADIR "/usr/share/bison"'; \ echo '#define PKGINCLUDEDIR "/usr/include/bison"'; \ echo '#define PKGLIBDIR "/usr/lib/aarch64-linux-gnu/bison"'; \ echo '#define PKGLIBEXECDIR "/usr/libexec/bison"'; \ } | sed '/""/d' > lib/configmake.h-t && \ mv -f lib/configmake.h-t lib/configmake.h touch examples/c/reccalc/scan.stamp.tmp rm -f lib/fcntl.h-t lib/fcntl.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_FCNTL_H''@||g' \ -e 's/@''GNULIB_CREAT''@/0/g' \ -e 's/@''GNULIB_FCNTL''@/1/g' \ -e 's/@''GNULIB_NONBLOCKING''@/0/g' \ -e 's/@''GNULIB_OPEN''@/1/g' \ -e 's/@''GNULIB_OPENAT''@/0/g' \ -e 's/@''GNULIB_MDA_CREAT''@/1/g' \ -e 's/@''GNULIB_MDA_OPEN''@/1/g' \ -e 's|@''HAVE_FCNTL''@|1|g' \ -e 's|@''HAVE_OPENAT''@|1|g' \ -e 's|@''REPLACE_CREAT''@|0|g' \ -e 's|@''REPLACE_FCNTL''@|1|g' \ -e 's|@''REPLACE_OPEN''@|0|g' \ -e 's|@''REPLACE_OPENAT''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/fcntl.in.h; \ } > lib/fcntl.h-t && \ mv lib/fcntl.h-t lib/fcntl.h flex -oexamples/c/reccalc/scan.c --header=examples/c/reccalc/scan.h ./examples/c/reccalc/scan.l rm -f lib/iconv.h-t lib/iconv.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_ICONV_H''@||g' \ -e 's/@''GNULIB_ICONV''@/1/g' \ -e 's|@''ICONV_CONST''@||g' \ -e 's|@''REPLACE_ICONV''@|0|g' \ -e 's|@''REPLACE_ICONV_OPEN''@|0|g' \ -e 's|@''REPLACE_ICONV_UTF''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/iconv.in.h; \ } > lib/iconv.h-t && \ mv lib/iconv.h-t lib/iconv.h rm -f lib/inttypes.h-t lib/inttypes.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's/@''HAVE_INTTYPES_H''@/1/g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_INTTYPES_H''@||g' \ -e 's/@''APPLE_UNIVERSAL_BUILD''@/0/g' \ -e 's/@''PRIPTR_PREFIX''@/"l"/g' \ -e 's/@''GNULIB_IMAXABS''@/0/g' \ -e 's/@''GNULIB_IMAXDIV''@/0/g' \ -e 's/@''GNULIB_STRTOIMAX''@/0/g' \ -e 's/@''GNULIB_STRTOUMAX''@/0/g' \ -e 's/@''HAVE_DECL_IMAXABS''@/1/g' \ -e 's/@''HAVE_DECL_IMAXDIV''@/1/g' \ -e 's/@''HAVE_DECL_STRTOIMAX''@/1/g' \ -e 's/@''HAVE_DECL_STRTOUMAX''@/1/g' \ -e 's/@''HAVE_IMAXDIV_T''@/1/g' \ -e 's/@''REPLACE_STRTOIMAX''@/0/g' \ -e 's/@''REPLACE_STRTOUMAX''@/0/g' \ -e 's/@''INT32_MAX_LT_INTMAX_MAX''@/1/g' \ -e 's/@''INT64_MAX_EQ_LONG_MAX''@/1/g' \ -e 's/@''UINT32_MAX_LT_UINTMAX_MAX''@/1/g' \ -e 's/@''UINT64_MAX_EQ_ULONG_MAX''@/1/g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/inttypes.in.h; \ } > lib/inttypes.h-t && \ mv lib/inttypes.h-t lib/inttypes.h rm -f lib/textstyle.h-t lib/textstyle.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ cat ./lib/textstyle.in.h; \ } > lib/textstyle.h-t && \ mv lib/textstyle.h-t lib/textstyle.h rm -f lib/limits.h-t lib/limits.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_LIMITS_H''@||g' \ < ./lib/limits.in.h; \ } > lib/limits.h-t && \ mv lib/limits.h-t lib/limits.h mv examples/c/reccalc/scan.stamp.tmp examples/c/reccalc/scan.stamp rm -f lib/locale.h-t lib/locale.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_LOCALE_H''@||g' \ -e 's/@''GNULIB_LOCALECONV''@/0/g' \ -e 's/@''GNULIB_SETLOCALE''@/0/g' \ -e 's/@''GNULIB_SETLOCALE_NULL''@/1/g' \ -e 's/@''GNULIB_DUPLOCALE''@/0/g' \ -e 's/@''GNULIB_LOCALENAME''@/0/g' \ -e 's|@''HAVE_NEWLOCALE''@|1|g' \ -e 's|@''HAVE_DUPLOCALE''@|1|g' \ -e 's|@''HAVE_FREELOCALE''@|1|g' \ -e 's|@''HAVE_XLOCALE_H''@|0|g' \ -e 's|@''REPLACE_LOCALECONV''@|0|g' \ -e 's|@''REPLACE_SETLOCALE''@|0|g' \ -e 's|@''REPLACE_NEWLOCALE''@|0|g' \ -e 's|@''REPLACE_DUPLOCALE''@|0|g' \ -e 's|@''REPLACE_FREELOCALE''@|0|g' \ -e 's|@''REPLACE_STRUCT_LCONV''@|0|g' \ -e 's|@''LOCALENAME_ENHANCE_LOCALE_FUNCS''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/locale.in.h; \ } > lib/locale.h-t && \ mv lib/locale.h-t lib/locale.h rm -f lib/math.h-t lib/math.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT_AS_FIRST_DIRECTIVE''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_AS_FIRST_DIRECTIVE_MATH_H''@||g' \ -e 's/@''GNULIB_ACOSF''@/0/g' \ -e 's/@''GNULIB_ACOSL''@/0/g' \ -e 's/@''GNULIB_ASINF''@/0/g' \ -e 's/@''GNULIB_ASINL''@/0/g' \ -e 's/@''GNULIB_ATANF''@/0/g' \ -e 's/@''GNULIB_ATANL''@/0/g' \ -e 's/@''GNULIB_ATAN2F''@/0/g' \ -e 's/@''GNULIB_CBRT''@/0/g' \ -e 's/@''GNULIB_CBRTF''@/0/g' \ -e 's/@''GNULIB_CBRTL''@/0/g' \ -e 's/@''GNULIB_CEIL''@/0/g' \ -e 's/@''GNULIB_CEILF''@/0/g' \ -e 's/@''GNULIB_CEILL''@/0/g' \ -e 's/@''GNULIB_COPYSIGN''@/0/g' \ -e 's/@''GNULIB_COPYSIGNF''@/0/g' \ -e 's/@''GNULIB_COPYSIGNL''@/0/g' \ -e 's/@''GNULIB_COSF''@/0/g' \ -e 's/@''GNULIB_COSL''@/0/g' \ -e 's/@''GNULIB_COSHF''@/0/g' \ -e 's/@''GNULIB_EXPF''@/0/g' \ -e 's/@''GNULIB_EXPL''@/0/g' \ -e 's/@''GNULIB_EXP2''@/0/g' \ -e 's/@''GNULIB_EXP2F''@/0/g' \ -e 's/@''GNULIB_EXP2L''@/0/g' \ -e 's/@''GNULIB_EXPM1''@/0/g' \ -e 's/@''GNULIB_EXPM1F''@/0/g' \ -e 's/@''GNULIB_EXPM1L''@/0/g' \ -e 's/@''GNULIB_FABSF''@/0/g' \ -e 's/@''GNULIB_FABSL''@/0/g' \ -e 's/@''GNULIB_FLOOR''@/0/g' \ -e 's/@''GNULIB_FLOORF''@/0/g' \ -e 's/@''GNULIB_FLOORL''@/0/g' \ -e 's/@''GNULIB_FMA''@/0/g' \ -e 's/@''GNULIB_FMAF''@/0/g' \ -e 's/@''GNULIB_FMAL''@/0/g' \ -e 's/@''GNULIB_FMOD''@/0/g' \ -e 's/@''GNULIB_FMODF''@/0/g' \ -e 's/@''GNULIB_FMODL''@/0/g' \ -e 's/@''GNULIB_FREXPF''@/0/g' \ -e 's/@''GNULIB_FREXP''@/1/g' \ -e 's/@''GNULIB_FREXPL''@/1/g' \ -e 's/@''GNULIB_HYPOT''@/0/g' \ -e 's/@''GNULIB_HYPOTF''@/0/g' \ -e 's/@''GNULIB_HYPOTL''@/0/g' \ < ./lib/math.in.h | \ sed -e 's/@''GNULIB_ILOGB''@/0/g' \ -e 's/@''GNULIB_ILOGBF''@/0/g' \ -e 's/@''GNULIB_ILOGBL''@/0/g' \ -e 's/@''GNULIB_ISFINITE''@/0/g' \ -e 's/@''GNULIB_ISINF''@/0/g' \ -e 's/@''GNULIB_ISNAN''@/1/g' \ -e 's/@''GNULIB_ISNANF''@/1/g' \ -e 's/@''GNULIB_ISNAND''@/1/g' \ -e 's/@''GNULIB_ISNANL''@/1/g' \ -e 's/@''GNULIB_LDEXPF''@/0/g' \ -e 's/@''GNULIB_LDEXPL''@/1/g' \ -e 's/@''GNULIB_LOG''@/0/g' \ -e 's/@''GNULIB_LOGF''@/0/g' \ -e 's/@''GNULIB_LOGL''@/0/g' \ -e 's/@''GNULIB_LOG10''@/0/g' \ -e 's/@''GNULIB_LOG10F''@/0/g' \ -e 's/@''GNULIB_LOG10L''@/0/g' \ -e 's/@''GNULIB_LOG1P''@/0/g' \ -e 's/@''GNULIB_LOG1PF''@/0/g' \ -e 's/@''GNULIB_LOG1PL''@/0/g' \ -e 's/@''GNULIB_LOG2''@/0/g' \ -e 's/@''GNULIB_LOG2F''@/0/g' \ -e 's/@''GNULIB_LOG2L''@/0/g' \ -e 's/@''GNULIB_LOGB''@/0/g' \ -e 's/@''GNULIB_LOGBF''@/0/g' \ -e 's/@''GNULIB_LOGBL''@/0/g' \ -e 's/@''GNULIB_MODF''@/0/g' \ -e 's/@''GNULIB_MODFF''@/0/g' \ -e 's/@''GNULIB_MODFL''@/0/g' \ -e 's/@''GNULIB_POWF''@/0/g' \ -e 's/@''GNULIB_REMAINDER''@/0/g' \ -e 's/@''GNULIB_REMAINDERF''@/0/g' \ -e 's/@''GNULIB_REMAINDERL''@/0/g' \ -e 's/@''GNULIB_RINT''@/0/g' \ -e 's/@''GNULIB_RINTF''@/0/g' \ -e 's/@''GNULIB_RINTL''@/0/g' \ -e 's/@''GNULIB_ROUND''@/0/g' \ -e 's/@''GNULIB_ROUNDF''@/0/g' \ -e 's/@''GNULIB_ROUNDL''@/0/g' \ -e 's/@''GNULIB_SIGNBIT''@/1/g' \ -e 's/@''GNULIB_SINF''@/0/g' \ -e 's/@''GNULIB_SINL''@/0/g' \ -e 's/@''GNULIB_SINHF''@/0/g' \ -e 's/@''GNULIB_SQRTF''@/0/g' \ -e 's/@''GNULIB_SQRTL''@/0/g' \ -e 's/@''GNULIB_TANF''@/0/g' \ -e 's/@''GNULIB_TANL''@/0/g' \ -e 's/@''GNULIB_TANHF''@/0/g' \ -e 's/@''GNULIB_TRUNC''@/0/g' \ -e 's/@''GNULIB_TRUNCF''@/0/g' \ -e 's/@''GNULIB_TRUNCL''@/0/g' \ -e 's/@''GNULIB_MDA_J0''@/1/g' \ -e 's/@''GNULIB_MDA_J1''@/1/g' \ -e 's/@''GNULIB_MDA_JN''@/1/g' \ -e 's/@''GNULIB_MDA_Y0''@/1/g' \ -e 's/@''GNULIB_MDA_Y1''@/1/g' \ -e 's/@''GNULIB_MDA_YN''@/1/g' \ | \ sed -e 's|@''HAVE_ACOSF''@|1|g' \ -e 's|@''HAVE_ACOSL''@|1|g' \ -e 's|@''HAVE_ASINF''@|1|g' \ -e 's|@''HAVE_ASINL''@|1|g' \ -e 's|@''HAVE_ATANF''@|1|g' \ -e 's|@''HAVE_ATANL''@|1|g' \ -e 's|@''HAVE_ATAN2F''@|1|g' \ -e 's|@''HAVE_CBRT''@|1|g' \ -e 's|@''HAVE_CBRTF''@|1|g' \ -e 's|@''HAVE_CBRTL''@|1|g' \ -e 's|@''HAVE_COPYSIGN''@|1|g' \ -e 's|@''HAVE_COPYSIGNL''@|1|g' \ -e 's|@''HAVE_COSF''@|1|g' \ -e 's|@''HAVE_COSL''@|1|g' \ -e 's|@''HAVE_COSHF''@|1|g' \ -e 's|@''HAVE_EXPF''@|1|g' \ -e 's|@''HAVE_EXPL''@|1|g' \ -e 's|@''HAVE_EXPM1''@|1|g' \ -e 's|@''HAVE_EXPM1F''@|1|g' \ -e 's|@''HAVE_FABSF''@|1|g' \ -e 's|@''HAVE_FABSL''@|1|g' \ -e 's|@''HAVE_FMA''@|1|g' \ -e 's|@''HAVE_FMAF''@|1|g' \ -e 's|@''HAVE_FMAL''@|1|g' \ -e 's|@''HAVE_FMODF''@|1|g' \ -e 's|@''HAVE_FMODL''@|1|g' \ -e 's|@''HAVE_FREXPF''@|1|g' \ -e 's|@''HAVE_HYPOTF''@|1|g' \ -e 's|@''HAVE_HYPOTL''@|1|g' \ -e 's|@''HAVE_ILOGB''@|1|g' \ -e 's|@''HAVE_ILOGBF''@|1|g' \ -e 's|@''HAVE_ILOGBL''@|1|g' \ -e 's|@''HAVE_ISNANF''@|1|g' \ -e 's|@''HAVE_ISNAND''@|1|g' \ -e 's|@''HAVE_ISNANL''@|1|g' \ -e 's|@''HAVE_LDEXPF''@|1|g' \ -e 's|@''HAVE_LOGF''@|1|g' \ -e 's|@''HAVE_LOGL''@|1|g' \ -e 's|@''HAVE_LOG10F''@|1|g' \ -e 's|@''HAVE_LOG10L''@|1|g' \ -e 's|@''HAVE_LOG1P''@|1|g' \ -e 's|@''HAVE_LOG1PF''@|1|g' \ -e 's|@''HAVE_LOG1PL''@|1|g' \ -e 's|@''HAVE_LOGBF''@|1|g' \ -e 's|@''HAVE_LOGBL''@|1|g' \ -e 's|@''HAVE_MODFF''@|1|g' \ -e 's|@''HAVE_MODFL''@|1|g' \ -e 's|@''HAVE_POWF''@|1|g' \ -e 's|@''HAVE_REMAINDER''@|1|g' \ -e 's|@''HAVE_REMAINDERF''@|1|g' \ -e 's|@''HAVE_RINT''@|1|g' \ -e 's|@''HAVE_RINTL''@|1|g' \ -e 's|@''HAVE_SINF''@|1|g' \ -e 's|@''HAVE_SINL''@|1|g' \ -e 's|@''HAVE_SINHF''@|1|g' \ -e 's|@''HAVE_SQRTF''@|1|g' \ -e 's|@''HAVE_SQRTL''@|1|g' \ -e 's|@''HAVE_TANF''@|1|g' \ -e 's|@''HAVE_TANL''@|1|g' \ -e 's|@''HAVE_TANHF''@|1|g' \ -e 's|@''HAVE_DECL_ACOSL''@|1|g' \ -e 's|@''HAVE_DECL_ASINL''@|1|g' \ -e 's|@''HAVE_DECL_ATANL''@|1|g' \ -e 's|@''HAVE_DECL_CBRTF''@|1|g' \ -e 's|@''HAVE_DECL_CBRTL''@|1|g' \ -e 's|@''HAVE_DECL_CEILF''@|1|g' \ -e 's|@''HAVE_DECL_CEILL''@|1|g' \ -e 's|@''HAVE_DECL_COPYSIGNF''@|1|g' \ -e 's|@''HAVE_DECL_COSL''@|1|g' \ -e 's|@''HAVE_DECL_EXPL''@|1|g' \ -e 's|@''HAVE_DECL_EXP2''@|1|g' \ -e 's|@''HAVE_DECL_EXP2F''@|1|g' \ -e 's|@''HAVE_DECL_EXP2L''@|1|g' \ -e 's|@''HAVE_DECL_EXPM1L''@|1|g' \ -e 's|@''HAVE_DECL_FLOORF''@|1|g' \ -e 's|@''HAVE_DECL_FLOORL''@|1|g' \ -e 's|@''HAVE_DECL_FREXPL''@|1|g' \ -e 's|@''HAVE_DECL_LDEXPL''@|1|g' \ -e 's|@''HAVE_DECL_LOGL''@|1|g' \ -e 's|@''HAVE_DECL_LOG10L''@|1|g' \ -e 's|@''HAVE_DECL_LOG2''@|1|g' \ -e 's|@''HAVE_DECL_LOG2F''@|1|g' \ -e 's|@''HAVE_DECL_LOG2L''@|1|g' \ -e 's|@''HAVE_DECL_LOGB''@|1|g' \ -e 's|@''HAVE_DECL_REMAINDER''@|1|g' \ -e 's|@''HAVE_DECL_REMAINDERL''@|1|g' \ -e 's|@''HAVE_DECL_RINTF''@|1|g' \ -e 's|@''HAVE_DECL_ROUND''@|1|g' \ -e 's|@''HAVE_DECL_ROUNDF''@|1|g' \ -e 's|@''HAVE_DECL_ROUNDL''@|1|g' \ -e 's|@''HAVE_DECL_SINL''@|1|g' \ -e 's|@''HAVE_DECL_SQRTL''@|1|g' \ -e 's|@''HAVE_DECL_TANL''@|1|g' \ -e 's|@''HAVE_DECL_TRUNC''@|1|g' \ -e 's|@''HAVE_DECL_TRUNCF''@|1|g' \ -e 's|@''HAVE_DECL_TRUNCL''@|1|g' \ | \ sed -e 's|@''REPLACE_ACOSF''@|0|g' \ -e 's|@''REPLACE_ASINF''@|0|g' \ -e 's|@''REPLACE_ATANF''@|0|g' \ -e 's|@''REPLACE_ATAN2F''@|0|g' \ -e 's|@''REPLACE_CBRTF''@|0|g' \ -e 's|@''REPLACE_CBRTL''@|0|g' \ -e 's|@''REPLACE_CEIL''@|0|g' \ -e 's|@''REPLACE_CEILF''@|0|g' \ -e 's|@''REPLACE_CEILL''@|0|g' \ -e 's|@''REPLACE_COSF''@|0|g' \ -e 's|@''REPLACE_COSHF''@|0|g' \ -e 's|@''REPLACE_EXPF''@|0|g' \ -e 's|@''REPLACE_EXPL''@|0|g' \ -e 's|@''REPLACE_EXPM1''@|0|g' \ -e 's|@''REPLACE_EXPM1F''@|0|g' \ -e 's|@''REPLACE_EXPM1L''@|0|g' \ -e 's|@''REPLACE_EXP2''@|0|g' \ -e 's|@''REPLACE_EXP2L''@|0|g' \ -e 's|@''REPLACE_FABSL''@|0|g' \ -e 's|@''REPLACE_FLOOR''@|0|g' \ -e 's|@''REPLACE_FLOORF''@|0|g' \ -e 's|@''REPLACE_FLOORL''@|0|g' \ -e 's|@''REPLACE_FMA''@|0|g' \ -e 's|@''REPLACE_FMAF''@|0|g' \ -e 's|@''REPLACE_FMAL''@|0|g' \ -e 's|@''REPLACE_FMOD''@|0|g' \ -e 's|@''REPLACE_FMODF''@|0|g' \ -e 's|@''REPLACE_FMODL''@|0|g' \ -e 's|@''REPLACE_FREXPF''@|0|g' \ -e 's|@''REPLACE_FREXP''@|0|g' \ -e 's|@''REPLACE_FREXPL''@|0|g' \ -e 's|@''REPLACE_HUGE_VAL''@|0|g' \ -e 's|@''REPLACE_HYPOT''@|0|g' \ -e 's|@''REPLACE_HYPOTF''@|0|g' \ -e 's|@''REPLACE_HYPOTL''@|0|g' \ -e 's|@''REPLACE_ILOGB''@|0|g' \ -e 's|@''REPLACE_ILOGBF''@|0|g' \ -e 's|@''REPLACE_ILOGBL''@|0|g' \ -e 's|@''REPLACE_ISFINITE''@|0|g' \ -e 's|@''REPLACE_ISINF''@|0|g' \ -e 's|@''REPLACE_ISNAN''@|0|g' \ -e 's|@''REPLACE_ITOLD''@|0|g' \ -e 's|@''REPLACE_LDEXPL''@|0|g' \ -e 's|@''REPLACE_LOG''@|0|g' \ -e 's|@''REPLACE_LOGF''@|0|g' \ -e 's|@''REPLACE_LOGL''@|0|g' \ -e 's|@''REPLACE_LOG10''@|0|g' \ -e 's|@''REPLACE_LOG10F''@|0|g' \ -e 's|@''REPLACE_LOG10L''@|0|g' \ -e 's|@''REPLACE_LOG1P''@|0|g' \ -e 's|@''REPLACE_LOG1PF''@|0|g' \ -e 's|@''REPLACE_LOG1PL''@|0|g' \ -e 's|@''REPLACE_LOG2''@|0|g' \ -e 's|@''REPLACE_LOG2F''@|0|g' \ -e 's|@''REPLACE_LOG2L''@|0|g' \ -e 's|@''REPLACE_LOGB''@|0|g' \ -e 's|@''REPLACE_LOGBF''@|0|g' \ -e 's|@''REPLACE_LOGBL''@|0|g' \ -e 's|@''REPLACE_MODF''@|0|g' \ -e 's|@''REPLACE_MODFF''@|0|g' \ -e 's|@''REPLACE_MODFL''@|0|g' \ -e 's|@''REPLACE_NAN''@|0|g' \ -e 's|@''REPLACE_REMAINDER''@|0|g' \ -e 's|@''REPLACE_REMAINDERF''@|0|g' \ -e 's|@''REPLACE_REMAINDERL''@|0|g' \ -e 's|@''REPLACE_RINTL''@|0|g' \ -e 's|@''REPLACE_ROUND''@|0|g' \ -e 's|@''REPLACE_ROUNDF''@|0|g' \ -e 's|@''REPLACE_ROUNDL''@|0|g' \ -e 's|@''REPLACE_SIGNBIT''@|0|g' \ -e 's|@''REPLACE_SIGNBIT_USING_BUILTINS''@|1|g' \ -e 's|@''REPLACE_SINF''@|0|g' \ -e 's|@''REPLACE_SINHF''@|0|g' \ -e 's|@''REPLACE_SQRTF''@|0|g' \ -e 's|@''REPLACE_SQRTL''@|0|g' \ -e 's|@''REPLACE_TANF''@|0|g' \ -e 's|@''REPLACE_TANHF''@|0|g' \ -e 's|@''REPLACE_TRUNC''@|0|g' \ -e 's|@''REPLACE_TRUNCF''@|0|g' \ -e 's|@''REPLACE_TRUNCL''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h'; \ } > lib/math.h-t && \ mv lib/math.h-t lib/math.h rm -f lib/sched.h-t lib/sched.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''HAVE_SCHED_H''@|1|g' \ -e 's|@''HAVE_SYS_CDEFS_H''@|1|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SCHED_H''@||g' \ -e 's|@''HAVE_STRUCT_SCHED_PARAM''@|1|g' \ -e 's/@''GNULIB_SCHED_YIELD''@/0/g' \ -e 's|@''HAVE_SCHED_YIELD''@|1|g' \ -e 's|@''REPLACE_SCHED_YIELD''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/sched.in.h; \ } > lib/sched.h-t && \ mv lib/sched.h-t lib/sched.h /usr/bin/mkdir -p lib/malloc rm -f lib/malloc/scratch_buffer.gl.h-t lib/malloc/scratch_buffer.gl.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|__always_inline|inline _GL_ATTRIBUTE_ALWAYS_INLINE|g' \ -e 's|__glibc_likely|_GL_LIKELY|g' \ -e 's|__glibc_unlikely|_GL_UNLIKELY|g' \ -e '/libc_hidden_proto/d' \ < ./lib/malloc/scratch_buffer.h; \ } > lib/malloc/scratch_buffer.gl.h-t && \ mv lib/malloc/scratch_buffer.gl.h-t lib/malloc/scratch_buffer.gl.h rm -f lib/signal.h-t lib/signal.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SIGNAL_H''@||g' \ -e 's/@''GNULIB_PTHREAD_SIGMASK''@/0/g' \ -e 's/@''GNULIB_RAISE''@/1/g' \ -e 's/@''GNULIB_SIGNAL_H_SIGPIPE''@/0/g' \ -e 's/@''GNULIB_SIGPROCMASK''@/1/g' \ -e 's/@''GNULIB_SIGACTION''@/1/g' \ -e 's|@''HAVE_POSIX_SIGNALBLOCKING''@|1|g' \ -e 's|@''HAVE_PTHREAD_SIGMASK''@|1|g' \ -e 's|@''HAVE_RAISE''@|1|g' \ -e 's|@''HAVE_SIGSET_T''@|1|g' \ -e 's|@''HAVE_SIGINFO_T''@|1|g' \ -e 's|@''HAVE_SIGACTION''@|1|g' \ -e 's|@''HAVE_STRUCT_SIGACTION_SA_SIGACTION''@|1|g' \ -e 's|@''HAVE_TYPE_VOLATILE_SIG_ATOMIC_T''@|1|g' \ -e 's|@''HAVE_SIGHANDLER_T''@|1|g' \ -e 's|@''REPLACE_PTHREAD_SIGMASK''@|0|g' \ -e 's|@''REPLACE_RAISE''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/signal.in.h; \ } > lib/signal.h-t && \ mv lib/signal.h-t lib/signal.h rm -f lib/spawn.h-t lib/spawn.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''HAVE_SPAWN_H''@|1|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SPAWN_H''@||g' \ -e 's/@''GNULIB_POSIX_SPAWN''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWNP''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWN_FILE_ACTIONS_INIT''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWN_FILE_ACTIONS_DESTROY''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_INIT''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_GETFLAGS''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_SETFLAGS''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_GETPGROUP''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_SETPGROUP''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_GETSCHEDPARAM''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_SETSCHEDPARAM''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_GETSCHEDPOLICY''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_SETSCHEDPOLICY''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_GETSIGDEFAULT''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_SETSIGDEFAULT''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_GETSIGMASK''@/0/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_SETSIGMASK''@/1/g' \ -e 's/@''GNULIB_POSIX_SPAWNATTR_DESTROY''@/1/g' \ -e 's|@''HAVE_POSIX_SPAWN''@|1|g' \ -e 's|@''HAVE_POSIX_SPAWNATTR_T''@|1|g' \ -e 's|@''HAVE_POSIX_SPAWN_FILE_ACTIONS_T''@|1|g' \ -e 's|@''HAVE_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR''@|0|g' \ -e 's|@''HAVE_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR''@|1|g' \ -e 's|@''REPLACE_POSIX_SPAWN''@|0|g' \ -e 's|@''REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR''@|0|g' \ -e 's|@''REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE''@|0|g' \ -e 's|@''REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2''@|0|g' \ -e 's|@''REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDFCHDIR''@|0|g' \ -e 's|@''REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/spawn.in.h; \ } > lib/spawn.h-t && \ mv lib/spawn.h-t lib/spawn.h rm -f lib/stdio.h-t lib/stdio.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_STDIO_H''@||g' \ -e 's/@''GNULIB_DPRINTF''@/0/g' \ -e 's/@''GNULIB_FCLOSE''@/0/g' \ -e 's/@''GNULIB_FDOPEN''@/0/g' \ -e 's/@''GNULIB_FFLUSH''@/0/g' \ -e 's/@''GNULIB_FGETC''@/1/g' \ -e 's/@''GNULIB_FGETS''@/1/g' \ -e 's/@''GNULIB_FOPEN''@/1/g' \ -e 's/@''GNULIB_FPRINTF''@/1/g' \ -e 's/@''GNULIB_FPRINTF_POSIX''@/1/g' \ -e 's/@''GNULIB_FPURGE''@/0/g' \ -e 's/@''GNULIB_FPUTC''@/1/g' \ -e 's/@''GNULIB_FPUTS''@/1/g' \ -e 's/@''GNULIB_FREAD''@/1/g' \ -e 's/@''GNULIB_FREOPEN''@/0/g' \ -e 's/@''GNULIB_FSCANF''@/1/g' \ -e 's/@''GNULIB_FSEEK''@/0/g' \ -e 's/@''GNULIB_FSEEKO''@/0/g' \ -e 's/@''GNULIB_FTELL''@/0/g' \ -e 's/@''GNULIB_FTELLO''@/0/g' \ -e 's/@''GNULIB_FWRITE''@/1/g' \ -e 's/@''GNULIB_GETC''@/1/g' \ -e 's/@''GNULIB_GETCHAR''@/1/g' \ -e 's/@''GNULIB_GETDELIM''@/0/g' \ -e 's/@''GNULIB_GETLINE''@/1/g' \ -e 's/@''GNULIB_OBSTACK_PRINTF''@/1/g' \ -e 's/@''GNULIB_OBSTACK_PRINTF_POSIX''@/0/g' \ -e 's/@''GNULIB_PCLOSE''@/0/g' \ -e 's/@''GNULIB_PERROR''@/1/g' \ -e 's/@''GNULIB_POPEN''@/0/g' \ -e 's/@''GNULIB_PRINTF''@/1/g' \ -e 's/@''GNULIB_PRINTF_POSIX''@/1/g' \ -e 's/@''GNULIB_PUTC''@/1/g' \ -e 's/@''GNULIB_PUTCHAR''@/1/g' \ -e 's/@''GNULIB_PUTS''@/1/g' \ -e 's/@''GNULIB_REMOVE''@/0/g' \ -e 's/@''GNULIB_RENAME''@/1/g' \ -e 's/@''GNULIB_RENAMEAT''@/0/g' \ -e 's/@''GNULIB_SCANF''@/1/g' \ -e 's/@''GNULIB_SNPRINTF''@/1/g' \ -e 's/@''GNULIB_SPRINTF_POSIX''@/1/g' \ -e 's/@''GNULIB_STDIO_H_NONBLOCKING''@/0/g' \ -e 's/@''GNULIB_STDIO_H_SIGPIPE''@/0/g' \ -e 's/@''GNULIB_TMPFILE''@/0/g' \ -e 's/@''GNULIB_VASPRINTF''@/1/g' \ -e 's/@''GNULIB_VDPRINTF''@/0/g' \ -e 's/@''GNULIB_VFPRINTF''@/1/g' \ -e 's/@''GNULIB_VFPRINTF_POSIX''@/1/g' \ -e 's/@''GNULIB_VFSCANF''@/0/g' \ -e 's/@''GNULIB_VSCANF''@/0/g' \ -e 's/@''GNULIB_VPRINTF''@/1/g' \ -e 's/@''GNULIB_VPRINTF_POSIX''@/0/g' \ -e 's/@''GNULIB_VSNPRINTF''@/1/g' \ -e 's/@''GNULIB_VSPRINTF_POSIX''@/1/g' \ -e 's/@''GNULIB_MDA_FCLOSEALL''@/1/g' \ -e 's/@''GNULIB_MDA_FDOPEN''@/1/g' \ -e 's/@''GNULIB_MDA_FILENO''@/1/g' \ -e 's/@''GNULIB_MDA_GETW''@/1/g' \ -e 's/@''GNULIB_MDA_PUTW''@/1/g' \ -e 's/@''GNULIB_MDA_TEMPNAM''@/1/g' \ < ./lib/stdio.in.h | \ sed -e 's|@''HAVE_DECL_FCLOSEALL''@|1|g' \ -e 's|@''HAVE_DECL_FPURGE''@|1|g' \ -e 's|@''HAVE_DECL_FSEEKO''@|1|g' \ -e 's|@''HAVE_DECL_FTELLO''@|1|g' \ -e 's|@''HAVE_DECL_GETDELIM''@|1|g' \ -e 's|@''HAVE_DECL_GETLINE''@|1|g' \ -e 's|@''HAVE_DECL_OBSTACK_PRINTF''@|1|g' \ -e 's|@''HAVE_DECL_SNPRINTF''@|1|g' \ -e 's|@''HAVE_DECL_VSNPRINTF''@|1|g' \ -e 's|@''HAVE_DPRINTF''@|1|g' \ -e 's|@''HAVE_FSEEKO''@|1|g' \ -e 's|@''HAVE_FTELLO''@|1|g' \ -e 's|@''HAVE_PCLOSE''@|1|g' \ -e 's|@''HAVE_POPEN''@|1|g' \ -e 's|@''HAVE_RENAMEAT''@|1|g' \ -e 's|@''HAVE_VASPRINTF''@|1|g' \ -e 's|@''HAVE_VDPRINTF''@|1|g' \ -e 's|@''REPLACE_DPRINTF''@|0|g' \ -e 's|@''REPLACE_FCLOSE''@|0|g' \ -e 's|@''REPLACE_FDOPEN''@|0|g' \ -e 's|@''REPLACE_FFLUSH''@|0|g' \ -e 's|@''REPLACE_FOPEN''@|0|g' \ -e 's|@''REPLACE_FPRINTF''@|1|g' \ -e 's|@''REPLACE_FPURGE''@|0|g' \ -e 's|@''REPLACE_FREOPEN''@|0|g' \ -e 's|@''REPLACE_FSEEK''@|0|g' \ -e 's|@''REPLACE_FSEEKO''@|0|g' \ -e 's|@''REPLACE_FTELL''@|0|g' \ -e 's|@''REPLACE_FTELLO''@|0|g' \ -e 's|@''REPLACE_GETDELIM''@|0|g' \ -e 's|@''REPLACE_GETLINE''@|0|g' \ -e 's|@''REPLACE_OBSTACK_PRINTF''@|0|g' \ -e 's|@''REPLACE_PERROR''@|0|g' \ -e 's|@''REPLACE_POPEN''@|0|g' \ -e 's|@''REPLACE_PRINTF''@|1|g' \ -e 's|@''REPLACE_REMOVE''@|0|g' \ -e 's|@''REPLACE_RENAME''@|0|g' \ -e 's|@''REPLACE_RENAMEAT''@|0|g' \ -e 's|@''REPLACE_SNPRINTF''@|1|g' \ -e 's|@''REPLACE_SPRINTF''@|1|g' \ -e 's|@''REPLACE_STDIO_READ_FUNCS''@|0|g' \ -e 's|@''REPLACE_STDIO_WRITE_FUNCS''@|0|g' \ -e 's|@''REPLACE_TMPFILE''@|0|g' \ -e 's|@''REPLACE_VASPRINTF''@|1|g' \ -e 's|@''REPLACE_VDPRINTF''@|0|g' \ -e 's|@''REPLACE_VFPRINTF''@|1|g' \ -e 's|@''REPLACE_VPRINTF''@|0|g' \ -e 's|@''REPLACE_VSNPRINTF''@|1|g' \ -e 's|@''REPLACE_VSPRINTF''@|1|g' \ -e 's|@''ASM_SYMBOL_PREFIX''@|""|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h'; \ } > lib/stdio.h-t && \ mv lib/stdio.h-t lib/stdio.h rm -f lib/stdlib.h-t lib/stdlib.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_STDLIB_H''@||g' \ -e 's/@''GNULIB__EXIT''@/0/g' \ -e 's/@''GNULIB_ALIGNED_ALLOC''@/0/g' \ -e 's/@''GNULIB_ATOLL''@/0/g' \ -e 's/@''GNULIB_CALLOC_POSIX''@/1/g' \ -e 's/@''GNULIB_CANONICALIZE_FILE_NAME''@/1/g' \ -e 's/@''GNULIB_FREE_POSIX''@/1/g' \ -e 's/@''GNULIB_GETLOADAVG''@/0/g' \ -e 's/@''GNULIB_GETSUBOPT''@/0/g' \ -e 's/@''GNULIB_GRANTPT''@/0/g' \ -e 's/@''GNULIB_MALLOC_POSIX''@/1/g' \ -e 's/@''GNULIB_MBTOWC''@/0/g' \ -e 's/@''GNULIB_MKDTEMP''@/0/g' \ -e 's/@''GNULIB_MKOSTEMP''@/0/g' \ -e 's/@''GNULIB_MKOSTEMPS''@/0/g' \ -e 's/@''GNULIB_MKSTEMP''@/0/g' \ -e 's/@''GNULIB_MKSTEMPS''@/0/g' \ -e 's/@''GNULIB_POSIX_MEMALIGN''@/0/g' \ -e 's/@''GNULIB_POSIX_OPENPT''@/0/g' \ -e 's/@''GNULIB_PTSNAME''@/0/g' \ -e 's/@''GNULIB_PTSNAME_R''@/0/g' \ -e 's/@''GNULIB_PUTENV''@/0/g' \ -e 's/@''GNULIB_QSORT_R''@/0/g' \ -e 's/@''GNULIB_RANDOM''@/0/g' \ -e 's/@''GNULIB_RANDOM_R''@/0/g' \ -e 's/@''GNULIB_REALLOC_POSIX''@/1/g' \ -e 's/@''GNULIB_REALLOCARRAY''@/1/g' \ -e 's/@''GNULIB_REALPATH''@/1/g' \ -e 's/@''GNULIB_RPMATCH''@/0/g' \ -e 's/@''GNULIB_SECURE_GETENV''@/0/g' \ -e 's/@''GNULIB_SETENV''@/0/g' \ -e 's/@''GNULIB_STRTOD''@/1/g' \ -e 's/@''GNULIB_STRTOL''@/0/g' \ -e 's/@''GNULIB_STRTOLD''@/0/g' \ -e 's/@''GNULIB_STRTOLL''@/0/g' \ -e 's/@''GNULIB_STRTOUL''@/0/g' \ -e 's/@''GNULIB_STRTOULL''@/0/g' \ -e 's/@''GNULIB_SYSTEM_POSIX''@/0/g' \ -e 's/@''GNULIB_UNLOCKPT''@/0/g' \ -e 's/@''GNULIB_UNSETENV''@/1/g' \ -e 's/@''GNULIB_WCTOMB''@/0/g' \ -e 's/@''GNULIB_MDA_ECVT''@/1/g' \ -e 's/@''GNULIB_MDA_FCVT''@/1/g' \ -e 's/@''GNULIB_MDA_GCVT''@/1/g' \ -e 's/@''GNULIB_MDA_MKTEMP''@/1/g' \ -e 's/@''GNULIB_MDA_PUTENV''@/1/g' \ < ./lib/stdlib.in.h | \ sed -e 's|@''HAVE__EXIT''@|1|g' \ -e 's|@''HAVE_ALIGNED_ALLOC''@|1|g' \ -e 's|@''HAVE_ATOLL''@|1|g' \ -e 's|@''HAVE_CANONICALIZE_FILE_NAME''@|1|g' \ -e 's|@''HAVE_DECL_ECVT''@|1|g' \ -e 's|@''HAVE_DECL_FCVT''@|1|g' \ -e 's|@''HAVE_DECL_GCVT''@|1|g' \ -e 's|@''HAVE_DECL_GETLOADAVG''@|1|g' \ -e 's|@''HAVE_GETSUBOPT''@|1|g' \ -e 's|@''HAVE_GRANTPT''@|1|g' \ -e 's|@''HAVE_INITSTATE''@|1|g' \ -e 's|@''HAVE_DECL_INITSTATE''@|1|g' \ -e 's|@''HAVE_MBTOWC''@|1|g' \ -e 's|@''HAVE_MKDTEMP''@|1|g' \ -e 's|@''HAVE_MKOSTEMP''@|1|g' \ -e 's|@''HAVE_MKOSTEMPS''@|1|g' \ -e 's|@''HAVE_MKSTEMP''@|1|g' \ -e 's|@''HAVE_MKSTEMPS''@|1|g' \ -e 's|@''HAVE_POSIX_MEMALIGN''@|1|g' \ -e 's|@''HAVE_POSIX_OPENPT''@|1|g' \ -e 's|@''HAVE_PTSNAME''@|1|g' \ -e 's|@''HAVE_PTSNAME_R''@|1|g' \ -e 's|@''HAVE_QSORT_R''@|1|g' \ -e 's|@''HAVE_RANDOM''@|1|g' \ -e 's|@''HAVE_RANDOM_H''@|1|g' \ -e 's|@''HAVE_RANDOM_R''@|1|g' \ -e 's|@''HAVE_REALLOCARRAY''@|1|g' \ -e 's|@''HAVE_REALPATH''@|1|g' \ -e 's|@''HAVE_RPMATCH''@|1|g' \ -e 's|@''HAVE_SECURE_GETENV''@|1|g' \ -e 's|@''HAVE_DECL_SETENV''@|1|g' \ -e 's|@''HAVE_SETSTATE''@|1|g' \ -e 's|@''HAVE_DECL_SETSTATE''@|1|g' \ -e 's|@''HAVE_STRTOD''@|1|g' \ -e 's|@''HAVE_STRTOL''@|1|g' \ -e 's|@''HAVE_STRTOLD''@|1|g' \ -e 's|@''HAVE_STRTOLL''@|1|g' \ -e 's|@''HAVE_STRTOUL''@|1|g' \ -e 's|@''HAVE_STRTOULL''@|1|g' \ -e 's|@''HAVE_STRUCT_RANDOM_DATA''@|1|g' \ -e 's|@''HAVE_SYS_LOADAVG_H''@|0|g' \ -e 's|@''HAVE_UNLOCKPT''@|1|g' \ -e 's|@''HAVE_DECL_UNSETENV''@|1|g' \ -e 's|@''REPLACE_ALIGNED_ALLOC''@|0|g' \ -e 's|@''REPLACE_CALLOC''@|0|g' \ -e 's|@''REPLACE_CANONICALIZE_FILE_NAME''@|0|g' \ -e 's|@''REPLACE_FREE''@|0|g' \ -e 's|@''REPLACE_INITSTATE''@|0|g' \ -e 's|@''REPLACE_MALLOC''@|0|g' \ -e 's|@''REPLACE_MBTOWC''@|0|g' \ -e 's|@''REPLACE_MKSTEMP''@|0|g' \ -e 's|@''REPLACE_POSIX_MEMALIGN''@|0|g' \ -e 's|@''REPLACE_PTSNAME''@|0|g' \ -e 's|@''REPLACE_PTSNAME_R''@|0|g' \ -e 's|@''REPLACE_PUTENV''@|0|g' \ -e 's|@''REPLACE_QSORT_R''@|0|g' \ -e 's|@''REPLACE_RANDOM''@|0|g' \ -e 's|@''REPLACE_RANDOM_R''@|0|g' \ -e 's|@''REPLACE_REALLOC''@|0|g' \ -e 's|@''REPLACE_REALLOCARRAY''@|0|g' \ -e 's|@''REPLACE_REALPATH''@|0|g' \ -e 's|@''REPLACE_SETENV''@|0|g' \ -e 's|@''REPLACE_SETSTATE''@|0|g' \ -e 's|@''REPLACE_STRTOD''@|0|g' \ -e 's|@''REPLACE_STRTOL''@|0|g' \ -e 's|@''REPLACE_STRTOLD''@|0|g' \ -e 's|@''REPLACE_STRTOLL''@|0|g' \ -e 's|@''REPLACE_STRTOUL''@|0|g' \ -e 's|@''REPLACE_STRTOULL''@|0|g' \ -e 's|@''REPLACE_UNSETENV''@|0|g' \ -e 's|@''REPLACE_WCTOMB''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _Noreturn/r ./lib/_Noreturn.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h'; \ } > lib/stdlib.h-t && \ mv lib/stdlib.h-t lib/stdlib.h rm -f lib/string.h-t lib/string.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_STRING_H''@||g' \ -e 's/@''GNULIB_EXPLICIT_BZERO''@/0/g' \ -e 's/@''GNULIB_FFSL''@/1/g' \ -e 's/@''GNULIB_FFSLL''@/0/g' \ -e 's/@''GNULIB_MBSLEN''@/0/g' \ -e 's/@''GNULIB_MBSNLEN''@/0/g' \ -e 's/@''GNULIB_MBSCHR''@/0/g' \ -e 's/@''GNULIB_MBSRCHR''@/0/g' \ -e 's/@''GNULIB_MBSSTR''@/0/g' \ -e 's/@''GNULIB_MBSCASECMP''@/0/g' \ -e 's/@''GNULIB_MBSNCASECMP''@/0/g' \ -e 's/@''GNULIB_MBSPCASECMP''@/0/g' \ -e 's/@''GNULIB_MBSCASESTR''@/0/g' \ -e 's/@''GNULIB_MBSCSPN''@/0/g' \ -e 's/@''GNULIB_MBSPBRK''@/0/g' \ -e 's/@''GNULIB_MBSSPN''@/0/g' \ -e 's/@''GNULIB_MBSSEP''@/0/g' \ -e 's/@''GNULIB_MBSTOK_R''@/0/g' \ -e 's/@''GNULIB_MEMCHR''@/1/g' \ -e 's/@''GNULIB_MEMMEM''@/0/g' \ -e 's/@''GNULIB_MEMPCPY''@/1/g' \ -e 's/@''GNULIB_MEMRCHR''@/0/g' \ -e 's/@''GNULIB_RAWMEMCHR''@/1/g' \ -e 's/@''GNULIB_STPCPY''@/1/g' \ -e 's/@''GNULIB_STPNCPY''@/1/g' \ -e 's/@''GNULIB_STRCHRNUL''@/0/g' \ -e 's/@''GNULIB_STRDUP''@/1/g' \ -e 's/@''GNULIB_STRNCAT''@/0/g' \ -e 's/@''GNULIB_STRNDUP''@/1/g' \ -e 's/@''GNULIB_STRNLEN''@/0/g' \ -e 's/@''GNULIB_STRPBRK''@/0/g' \ -e 's/@''GNULIB_STRSEP''@/0/g' \ -e 's/@''GNULIB_STRSTR''@/0/g' \ -e 's/@''GNULIB_STRCASESTR''@/0/g' \ -e 's/@''GNULIB_STRTOK_R''@/0/g' \ -e 's/@''GNULIB_STRERROR''@/1/g' \ -e 's/@''GNULIB_STRERROR_R''@/0/g' \ -e 's/@''GNULIB_STRERRORNAME_NP''@/0/g' \ -e 's/@''GNULIB_SIGABBREV_NP''@/0/g' \ -e 's/@''GNULIB_SIGDESCR_NP''@/0/g' \ -e 's/@''GNULIB_STRSIGNAL''@/0/g' \ -e 's/@''GNULIB_STRVERSCMP''@/1/g' \ -e 's/@''GNULIB_MDA_MEMCCPY''@/1/g' \ -e 's/@''GNULIB_MDA_STRDUP''@/1/g' \ < ./lib/string.in.h | \ sed -e 's|@''HAVE_EXPLICIT_BZERO''@|1|g' \ -e 's|@''HAVE_FFSL''@|1|g' \ -e 's|@''HAVE_FFSLL''@|1|g' \ -e 's|@''HAVE_MBSLEN''@|0|g' \ -e 's|@''HAVE_DECL_MEMMEM''@|1|g' \ -e 's|@''HAVE_MEMPCPY''@|1|g' \ -e 's|@''HAVE_DECL_MEMRCHR''@|1|g' \ -e 's|@''HAVE_RAWMEMCHR''@|1|g' \ -e 's|@''HAVE_STPCPY''@|1|g' \ -e 's|@''HAVE_STPNCPY''@|1|g' \ -e 's|@''HAVE_STRCHRNUL''@|1|g' \ -e 's|@''HAVE_DECL_STRDUP''@|1|g' \ -e 's|@''HAVE_DECL_STRNDUP''@|1|g' \ -e 's|@''HAVE_DECL_STRNLEN''@|1|g' \ -e 's|@''HAVE_STRPBRK''@|1|g' \ -e 's|@''HAVE_STRSEP''@|1|g' \ -e 's|@''HAVE_STRCASESTR''@|1|g' \ -e 's|@''HAVE_DECL_STRTOK_R''@|1|g' \ -e 's|@''HAVE_DECL_STRERROR_R''@|1|g' \ -e 's|@''HAVE_STRERRORNAME_NP''@|1|g' \ -e 's|@''HAVE_SIGABBREV_NP''@|1|g' \ -e 's|@''HAVE_SIGDESCR_NP''@|1|g' \ -e 's|@''HAVE_DECL_STRSIGNAL''@|1|g' \ -e 's|@''HAVE_STRVERSCMP''@|1|g' \ -e 's|@''REPLACE_FFSLL''@|0|g' \ -e 's|@''REPLACE_MEMCHR''@|0|g' \ -e 's|@''REPLACE_MEMMEM''@|0|g' \ -e 's|@''REPLACE_FREE''@|0|g' \ -e 's|@''REPLACE_STPNCPY''@|0|g' \ -e 's|@''REPLACE_STRCHRNUL''@|0|g' \ -e 's|@''REPLACE_STRDUP''@|0|g' \ -e 's|@''REPLACE_STRNCAT''@|0|g' \ -e 's|@''REPLACE_STRNDUP''@|0|g' \ -e 's|@''REPLACE_STRNLEN''@|0|g' \ -e 's|@''REPLACE_STRSTR''@|0|g' \ -e 's|@''REPLACE_STRCASESTR''@|0|g' \ -e 's|@''REPLACE_STRTOK_R''@|0|g' \ -e 's|@''REPLACE_STRERROR''@|0|g' \ -e 's|@''REPLACE_STRERROR_R''@|1|g' \ -e 's|@''REPLACE_STRERRORNAME_NP''@|0|g' \ -e 's|@''REPLACE_STRSIGNAL''@|0|g' \ -e 's|@''UNDEFINE_STRTOK_R''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h'; \ < ./lib/string.in.h; \ } > lib/string.h-t && \ mv lib/string.h-t lib/string.h /usr/bin/mkdir -p lib/sys rm -f lib/sys/ioctl.h-t lib/sys/ioctl.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''HAVE_SYS_IOCTL_H''@|1|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SYS_IOCTL_H''@||g' \ -e 's/@''GNULIB_IOCTL''@/0/g' \ -e 's|@''SYS_IOCTL_H_HAVE_WINSOCK2_H''@|0|g' \ -e 's|@''SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS''@|0|g' \ -e 's|@''REPLACE_IOCTL''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/sys_ioctl.in.h; \ } > lib/sys/ioctl.h-t && \ mv lib/sys/ioctl.h-t lib/sys/ioctl.h /usr/bin/mkdir -p lib/sys rm -f lib/sys/resource.h-t lib/sys/resource.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SYS_RESOURCE_H''@||g' \ -e 's|@''HAVE_SYS_RESOURCE_H''@|1|g' \ -e 's/@''GNULIB_GETRUSAGE''@/1/g' \ -e 's/@''HAVE_GETRUSAGE''@/1/g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/sys_resource.in.h; \ } > lib/sys/resource.h-t && \ mv -f lib/sys/resource.h-t lib/sys/resource.h /usr/bin/mkdir -p lib/sys rm -f lib/sys/stat.h-t lib/sys/stat.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SYS_STAT_H''@||g' \ -e 's|@''WINDOWS_64_BIT_ST_SIZE''@|0|g' \ -e 's|@''WINDOWS_STAT_TIMESPEC''@|0|g' \ -e 's/@''GNULIB_FCHMODAT''@/0/g' \ -e 's/@''GNULIB_FSTAT''@/0/g' \ -e 's/@''GNULIB_FSTATAT''@/0/g' \ -e 's/@''GNULIB_FUTIMENS''@/0/g' \ -e 's/@''GNULIB_GETUMASK''@/0/g' \ -e 's/@''GNULIB_LCHMOD''@/0/g' \ -e 's/@''GNULIB_LSTAT''@/0/g' \ -e 's/@''GNULIB_MKDIR''@/0/g' \ -e 's/@''GNULIB_MKDIRAT''@/0/g' \ -e 's/@''GNULIB_MKFIFO''@/0/g' \ -e 's/@''GNULIB_MKFIFOAT''@/0/g' \ -e 's/@''GNULIB_MKNOD''@/0/g' \ -e 's/@''GNULIB_MKNODAT''@/0/g' \ -e 's/@''GNULIB_STAT''@/1/g' \ -e 's/@''GNULIB_UTIMENSAT''@/0/g' \ -e 's/@''GNULIB_OVERRIDES_STRUCT_STAT''@/0/g' \ -e 's/@''GNULIB_MDA_CHMOD''@/1/g' \ -e 's/@''GNULIB_MDA_MKDIR''@/1/g' \ -e 's/@''GNULIB_MDA_UMASK''@/1/g' \ -e 's|@''HAVE_FCHMODAT''@|1|g' \ -e 's|@''HAVE_FSTATAT''@|1|g' \ -e 's|@''HAVE_FUTIMENS''@|1|g' \ -e 's|@''HAVE_GETUMASK''@|1|g' \ -e 's|@''HAVE_LCHMOD''@|1|g' \ -e 's|@''HAVE_LSTAT''@|1|g' \ -e 's|@''HAVE_MKDIRAT''@|1|g' \ -e 's|@''HAVE_MKFIFO''@|1|g' \ -e 's|@''HAVE_MKFIFOAT''@|1|g' \ -e 's|@''HAVE_MKNOD''@|1|g' \ -e 's|@''HAVE_MKNODAT''@|1|g' \ -e 's|@''HAVE_UTIMENSAT''@|1|g' \ -e 's|@''REPLACE_FCHMODAT''@|0|g' \ -e 's|@''REPLACE_FSTAT''@|0|g' \ -e 's|@''REPLACE_FSTATAT''@|0|g' \ -e 's|@''REPLACE_FUTIMENS''@|0|g' \ -e 's|@''REPLACE_LSTAT''@|0|g' \ -e 's|@''REPLACE_MKDIR''@|0|g' \ -e 's|@''REPLACE_MKFIFO''@|0|g' \ -e 's|@''REPLACE_MKFIFOAT''@|0|g' \ -e 's|@''REPLACE_MKNOD''@|0|g' \ -e 's|@''REPLACE_MKNODAT''@|0|g' \ -e 's|@''REPLACE_STAT''@|0|g' \ -e 's|@''REPLACE_UTIMENSAT''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/sys_stat.in.h; \ } > lib/sys/stat.h-t && \ mv lib/sys/stat.h-t lib/sys/stat.h /usr/bin/mkdir -p lib/sys rm -f lib/sys/time.h-t lib/sys/time.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's/@''HAVE_SYS_TIME_H''@/1/g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SYS_TIME_H''@||g' \ -e 's/@''GNULIB_GETTIMEOFDAY''@/1/g' \ -e 's|@''HAVE_WINSOCK2_H''@|0|g' \ -e 's/@''HAVE_GETTIMEOFDAY''@/1/g' \ -e 's/@''HAVE_STRUCT_TIMEVAL''@/1/g' \ -e 's/@''REPLACE_GETTIMEOFDAY''@/0/g' \ -e 's/@''REPLACE_STRUCT_TIMEVAL''@/0/g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/sys_time.in.h; \ } > lib/sys/time.h-t && \ mv lib/sys/time.h-t lib/sys/time.h /usr/bin/mkdir -p lib/sys /usr/bin/mkdir -p lib/sys rm -f lib/sys/times.h-t lib/sys/times.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's/@''HAVE_SYS_TIMES_H''@/1/g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SYS_TIMES_H''@||g' \ -e 's/@''GNULIB_TIMES''@/0/g' \ -e 's|@''HAVE_STRUCT_TMS''@|1|g' \ -e 's|@''HAVE_TIMES''@|1|g' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/sys_times.in.h; \ } > lib/sys/times.h-t && \ mv lib/sys/times.h-t lib/sys/times.h rm -f lib/sys/types.h-t lib/sys/types.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SYS_TYPES_H''@||g' \ -e 's|@''WINDOWS_64_BIT_OFF_T''@|0|g' \ -e 's|@''WINDOWS_STAT_INODES''@|0|g' \ < ./lib/sys_types.in.h; \ } > lib/sys/types.h-t && \ mv lib/sys/types.h-t lib/sys/types.h /usr/bin/mkdir -p lib/sys rm -f lib/termios.h-t lib/termios.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_TERMIOS_H''@||g' \ -e 's/@''GNULIB_TCGETSID''@/0/g' \ -e 's|@''HAVE_DECL_TCGETSID''@|1|g' \ -e 's|@''HAVE_TERMIOS_H''@|1|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/termios.in.h; \ } > lib/termios.h-t && \ mv lib/termios.h-t lib/termios.h rm -f lib/sys/wait.h-t lib/sys/wait.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_SYS_WAIT_H''@||g' \ -e 's/@''GNULIB_WAITPID''@/1/g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/sys_wait.in.h; \ } > lib/sys/wait.h-t && \ mv lib/sys/wait.h-t lib/sys/wait.h rm -f lib/time.h-t lib/time.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_TIME_H''@||g' \ -e 's/@''GNULIB_CTIME''@/0/g' \ -e 's/@''GNULIB_LOCALTIME''@/0/g' \ -e 's/@''GNULIB_MKTIME''@/0/g' \ -e 's/@''GNULIB_NANOSLEEP''@/0/g' \ -e 's/@''GNULIB_STRFTIME''@/0/g' \ -e 's/@''GNULIB_STRPTIME''@/0/g' \ -e 's/@''GNULIB_TIMEGM''@/0/g' \ -e 's/@''GNULIB_TIMESPEC_GET''@/0/g' \ -e 's/@''GNULIB_TIME_R''@/0/g' \ -e 's/@''GNULIB_TIME_RZ''@/0/g' \ -e 's/@''GNULIB_TZSET''@/0/g' \ -e 's/@''GNULIB_MDA_TZSET''@/1/g' \ -e 's|@''HAVE_DECL_LOCALTIME_R''@|1|g' \ -e 's|@''HAVE_NANOSLEEP''@|1|g' \ -e 's|@''HAVE_STRPTIME''@|1|g' \ -e 's|@''HAVE_TIMEGM''@|1|g' \ -e 's|@''HAVE_TIMESPEC_GET''@|1|g' \ -e 's|@''HAVE_TIMEZONE_T''@|0|g' \ -e 's|@''REPLACE_CTIME''@|GNULIB_PORTCHECK|g' \ -e 's|@''REPLACE_GMTIME''@|0|g' \ -e 's|@''REPLACE_LOCALTIME''@|0|g' \ -e 's|@''REPLACE_LOCALTIME_R''@|GNULIB_PORTCHECK|g' \ -e 's|@''REPLACE_MKTIME''@|GNULIB_PORTCHECK|g' \ -e 's|@''REPLACE_NANOSLEEP''@|GNULIB_PORTCHECK|g' \ -e 's|@''REPLACE_STRFTIME''@|GNULIB_PORTCHECK|g' \ -e 's|@''REPLACE_TIMEGM''@|GNULIB_PORTCHECK|g' \ -e 's|@''REPLACE_TZSET''@|GNULIB_PORTCHECK|g' \ -e 's|@''PTHREAD_H_DEFINES_STRUCT_TIMESPEC''@|0|g' \ -e 's|@''SYS_TIME_H_DEFINES_STRUCT_TIMESPEC''@|0|g' \ -e 's|@''TIME_H_DEFINES_STRUCT_TIMESPEC''@|1|g' \ -e 's|@''UNISTD_H_DEFINES_STRUCT_TIMESPEC''@|0|g' \ -e 's|@''TIME_H_DEFINES_TIME_UTC''@|1|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/time.in.h; \ } > lib/time.h-t && \ mv lib/time.h-t lib/time.h rm -f lib/unistd.h-t lib/unistd.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''HAVE_UNISTD_H''@|1|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_UNISTD_H''@||g' \ -e 's|@''WINDOWS_64_BIT_OFF_T''@|0|g' \ -e 's/@''GNULIB_ACCESS''@/1/g' \ -e 's/@''GNULIB_CHDIR''@/0/g' \ -e 's/@''GNULIB_CHOWN''@/0/g' \ -e 's/@''GNULIB_CLOSE''@/1/g' \ -e 's/@''GNULIB_COPY_FILE_RANGE''@/0/g' \ -e 's/@''GNULIB_DUP''@/0/g' \ -e 's/@''GNULIB_DUP2''@/1/g' \ -e 's/@''GNULIB_DUP3''@/0/g' \ -e 's/@''GNULIB_ENVIRON''@/1/g' \ -e 's/@''GNULIB_EUIDACCESS''@/0/g' \ -e 's/@''GNULIB_EXECL''@/0/g' \ -e 's/@''GNULIB_EXECLE''@/0/g' \ -e 's/@''GNULIB_EXECLP''@/0/g' \ -e 's/@''GNULIB_EXECV''@/0/g' \ -e 's/@''GNULIB_EXECVE''@/0/g' \ -e 's/@''GNULIB_EXECVP''@/0/g' \ -e 's/@''GNULIB_EXECVPE''@/0/g' \ -e 's/@''GNULIB_FACCESSAT''@/0/g' \ -e 's/@''GNULIB_FCHDIR''@/0/g' \ -e 's/@''GNULIB_FCHOWNAT''@/0/g' \ -e 's/@''GNULIB_FDATASYNC''@/0/g' \ -e 's/@''GNULIB_FSYNC''@/1/g' \ -e 's/@''GNULIB_FTRUNCATE''@/0/g' \ -e 's/@''GNULIB_GETCWD''@/1/g' \ -e 's/@''GNULIB_GETDOMAINNAME''@/0/g' \ -e 's/@''GNULIB_GETDTABLESIZE''@/1/g' \ -e 's/@''GNULIB_GETENTROPY''@/0/g' \ -e 's/@''GNULIB_GETGROUPS''@/0/g' \ -e 's/@''GNULIB_GETHOSTNAME''@/0/g' \ -e 's/@''GNULIB_GETLOGIN''@/0/g' \ -e 's/@''GNULIB_GETLOGIN_R''@/0/g' \ -e 's/@''GNULIB_GETOPT_POSIX''@/1/g' \ -e 's/@''GNULIB_GETPAGESIZE''@/0/g' \ -e 's/@''GNULIB_GETPASS''@/0/g' \ -e 's/@''GNULIB_GETUSERSHELL''@/0/g' \ -e 's/@''GNULIB_GROUP_MEMBER''@/0/g' \ -e 's/@''GNULIB_ISATTY''@/0/g' \ -e 's/@''GNULIB_LCHOWN''@/0/g' \ -e 's/@''GNULIB_LINK''@/0/g' \ -e 's/@''GNULIB_LINKAT''@/0/g' \ -e 's/@''GNULIB_LSEEK''@/0/g' \ -e 's/@''GNULIB_PIPE''@/1/g' \ -e 's/@''GNULIB_PIPE2''@/1/g' \ -e 's/@''GNULIB_PREAD''@/0/g' \ -e 's/@''GNULIB_PWRITE''@/0/g' \ -e 's/@''GNULIB_READ''@/0/g' \ -e 's/@''GNULIB_READLINK''@/1/g' \ -e 's/@''GNULIB_READLINKAT''@/0/g' \ -e 's/@''GNULIB_RMDIR''@/0/g' \ -e 's/@''GNULIB_SETHOSTNAME''@/0/g' \ -e 's/@''GNULIB_SLEEP''@/0/g' \ -e 's/@''GNULIB_SYMLINK''@/0/g' \ -e 's/@''GNULIB_SYMLINKAT''@/0/g' \ -e 's/@''GNULIB_TRUNCATE''@/0/g' \ -e 's/@''GNULIB_TTYNAME_R''@/0/g' \ -e 's/@''GNULIB_UNISTD_H_GETOPT''@/00/g' \ -e 's/@''GNULIB_UNISTD_H_NONBLOCKING''@/0/g' \ -e 's/@''GNULIB_UNISTD_H_SIGPIPE''@/0/g' \ -e 's/@''GNULIB_UNLINK''@/1/g' \ -e 's/@''GNULIB_UNLINKAT''@/0/g' \ -e 's/@''GNULIB_USLEEP''@/0/g' \ -e 's/@''GNULIB_WRITE''@/0/g' \ -e 's/@''GNULIB_MDA_ACCESS''@/1/g' \ -e 's/@''GNULIB_MDA_CHDIR''@/1/g' \ -e 's/@''GNULIB_MDA_CLOSE''@/1/g' \ -e 's/@''GNULIB_MDA_DUP''@/1/g' \ -e 's/@''GNULIB_MDA_DUP2''@/1/g' \ -e 's/@''GNULIB_MDA_EXECL''@/1/g' \ -e 's/@''GNULIB_MDA_EXECLE''@/1/g' \ -e 's/@''GNULIB_MDA_EXECLP''@/1/g' \ -e 's/@''GNULIB_MDA_EXECV''@/1/g' \ -e 's/@''GNULIB_MDA_EXECVE''@/1/g' \ -e 's/@''GNULIB_MDA_EXECVP''@/1/g' \ -e 's/@''GNULIB_MDA_EXECVPE''@/1/g' \ -e 's/@''GNULIB_MDA_GETCWD''@/1/g' \ -e 's/@''GNULIB_MDA_GETPID''@/1/g' \ -e 's/@''GNULIB_MDA_ISATTY''@/1/g' \ -e 's/@''GNULIB_MDA_LSEEK''@/1/g' \ -e 's/@''GNULIB_MDA_READ''@/1/g' \ -e 's/@''GNULIB_MDA_RMDIR''@/1/g' \ -e 's/@''GNULIB_MDA_SWAB''@/1/g' \ -e 's/@''GNULIB_MDA_UNLINK''@/1/g' \ -e 's/@''GNULIB_MDA_WRITE''@/1/g' \ < ./lib/unistd.in.h | \ sed -e 's|@''HAVE_CHOWN''@|1|g' \ -e 's|@''HAVE_COPY_FILE_RANGE''@|1|g' \ -e 's|@''HAVE_DUP3''@|1|g' \ -e 's|@''HAVE_EUIDACCESS''@|1|g' \ -e 's|@''HAVE_EXECVPE''@|1|g' \ -e 's|@''HAVE_FACCESSAT''@|1|g' \ -e 's|@''HAVE_FCHDIR''@|1|g' \ -e 's|@''HAVE_FCHOWNAT''@|1|g' \ -e 's|@''HAVE_FDATASYNC''@|1|g' \ -e 's|@''HAVE_FSYNC''@|1|g' \ -e 's|@''HAVE_FTRUNCATE''@|1|g' \ -e 's|@''HAVE_GETDTABLESIZE''@|1|g' \ -e 's|@''HAVE_GETENTROPY''@|1|g' \ -e 's|@''HAVE_GETGROUPS''@|1|g' \ -e 's|@''HAVE_GETHOSTNAME''@|1|g' \ -e 's|@''HAVE_GETPAGESIZE''@|1|g' \ -e 's|@''HAVE_GETPASS''@|1|g' \ -e 's|@''HAVE_GROUP_MEMBER''@|1|g' \ -e 's|@''HAVE_LCHOWN''@|1|g' \ -e 's|@''HAVE_LINK''@|1|g' \ -e 's|@''HAVE_LINKAT''@|1|g' \ -e 's|@''HAVE_PIPE''@|1|g' \ -e 's|@''HAVE_PIPE2''@|1|g' \ -e 's|@''HAVE_PREAD''@|1|g' \ -e 's|@''HAVE_PWRITE''@|1|g' \ -e 's|@''HAVE_READLINK''@|1|g' \ -e 's|@''HAVE_READLINKAT''@|1|g' \ -e 's|@''HAVE_SETHOSTNAME''@|1|g' \ -e 's|@''HAVE_SLEEP''@|1|g' \ -e 's|@''HAVE_SYMLINK''@|1|g' \ -e 's|@''HAVE_SYMLINKAT''@|1|g' \ -e 's|@''HAVE_UNLINKAT''@|1|g' \ -e 's|@''HAVE_USLEEP''@|1|g' \ -e 's|@''HAVE_DECL_ENVIRON''@|1|g' \ -e 's|@''HAVE_DECL_EXECVPE''@|1|g' \ -e 's|@''HAVE_DECL_FCHDIR''@|1|g' \ -e 's|@''HAVE_DECL_FDATASYNC''@|1|g' \ -e 's|@''HAVE_DECL_GETDOMAINNAME''@|1|g' \ -e 's|@''HAVE_DECL_GETLOGIN''@|1|g' \ -e 's|@''HAVE_DECL_GETLOGIN_R''@|1|g' \ -e 's|@''HAVE_DECL_GETPAGESIZE''@|1|g' \ -e 's|@''HAVE_DECL_GETUSERSHELL''@|1|g' \ -e 's|@''HAVE_DECL_SETHOSTNAME''@|1|g' \ -e 's|@''HAVE_DECL_TRUNCATE''@|1|g' \ -e 's|@''HAVE_DECL_TTYNAME_R''@|1|g' \ -e 's|@''HAVE_OS_H''@|0|g' \ -e 's|@''HAVE_SYS_PARAM_H''@|0|g' \ | \ sed -e 's|@''REPLACE_ACCESS''@|0|g' \ -e 's|@''REPLACE_CHOWN''@|0|g' \ -e 's|@''REPLACE_CLOSE''@|0|g' \ -e 's|@''REPLACE_DUP''@|0|g' \ -e 's|@''REPLACE_DUP2''@|0|g' \ -e 's|@''REPLACE_EXECL''@|0|g' \ -e 's|@''REPLACE_EXECLE''@|0|g' \ -e 's|@''REPLACE_EXECLP''@|0|g' \ -e 's|@''REPLACE_EXECV''@|0|g' \ -e 's|@''REPLACE_EXECVE''@|0|g' \ -e 's|@''REPLACE_EXECVP''@|0|g' \ -e 's|@''REPLACE_EXECVPE''@|0|g' \ -e 's|@''REPLACE_FACCESSAT''@|0|g' \ -e 's|@''REPLACE_FCHOWNAT''@|0|g' \ -e 's|@''REPLACE_FTRUNCATE''@|0|g' \ -e 's|@''REPLACE_GETCWD''@|0|g' \ -e 's|@''REPLACE_GETDOMAINNAME''@|0|g' \ -e 's|@''REPLACE_GETDTABLESIZE''@|0|g' \ -e 's|@''REPLACE_GETLOGIN_R''@|0|g' \ -e 's|@''REPLACE_GETGROUPS''@|0|g' \ -e 's|@''REPLACE_GETPAGESIZE''@|0|g' \ -e 's|@''REPLACE_GETPASS''@|0|g' \ -e 's|@''REPLACE_ISATTY''@|0|g' \ -e 's|@''REPLACE_LCHOWN''@|0|g' \ -e 's|@''REPLACE_LINK''@|0|g' \ -e 's|@''REPLACE_LINKAT''@|0|g' \ -e 's|@''REPLACE_LSEEK''@|0|g' \ -e 's|@''REPLACE_PREAD''@|0|g' \ -e 's|@''REPLACE_PWRITE''@|0|g' \ -e 's|@''REPLACE_READ''@|0|g' \ -e 's|@''REPLACE_READLINK''@|0|g' \ -e 's|@''REPLACE_READLINKAT''@|0|g' \ -e 's|@''REPLACE_RMDIR''@|0|g' \ -e 's|@''REPLACE_SLEEP''@|0|g' \ -e 's|@''REPLACE_SYMLINK''@|0|g' \ -e 's|@''REPLACE_SYMLINKAT''@|0|g' \ -e 's|@''REPLACE_TRUNCATE''@|0|g' \ -e 's|@''REPLACE_TTYNAME_R''@|0|g' \ -e 's|@''REPLACE_UNLINK''@|0|g' \ -e 's|@''REPLACE_UNLINKAT''@|0|g' \ -e 's|@''REPLACE_USLEEP''@|0|g' \ -e 's|@''REPLACE_WRITE''@|0|g' \ -e 's|@''UNISTD_H_HAVE_SYS_RANDOM_H''@|0|g' \ -e 's|@''UNISTD_H_HAVE_WINSOCK2_H''@|0|g' \ -e 's|@''UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h'; \ } > lib/unistd.h-t && \ mv lib/unistd.h-t lib/unistd.h rm -f lib/unistr.h-t lib/unistr.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ cat ./lib/unistr.in.h; \ } > lib/unistr.h-t && \ mv -f lib/unistr.h-t lib/unistr.h rm -f lib/unitypes.h-t lib/unitypes.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ cat ./lib/unitypes.in.h; \ } > lib/unitypes.h-t && \ mv -f lib/unitypes.h-t lib/unitypes.h rm -f lib/uniwidth.h-t lib/uniwidth.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ cat ./lib/uniwidth.in.h; \ } > lib/uniwidth.h-t && \ mv -f lib/uniwidth.h-t lib/uniwidth.h rm -f lib/wchar.h-t lib/wchar.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''HAVE_FEATURES_H''@|1|g' \ -e 's|@''NEXT_WCHAR_H''@||g' \ -e 's|@''HAVE_WCHAR_H''@|1|g' \ -e 's/@''HAVE_CRTDEFS_H''@/0/g' \ -e 's/@''GNULIBHEADERS_OVERRIDE_WINT_T''@/0/g' \ -e 's/@''GNULIB_BTOWC''@/0/g' \ -e 's/@''GNULIB_WCTOB''@/0/g' \ -e 's/@''GNULIB_MBSINIT''@/1/g' \ -e 's/@''GNULIB_MBRTOWC''@/1/g' \ -e 's/@''GNULIB_MBRLEN''@/0/g' \ -e 's/@''GNULIB_MBSRTOWCS''@/0/g' \ -e 's/@''GNULIB_MBSNRTOWCS''@/0/g' \ -e 's/@''GNULIB_WCRTOMB''@/0/g' \ -e 's/@''GNULIB_WCSRTOMBS''@/0/g' \ -e 's/@''GNULIB_WCSNRTOMBS''@/0/g' \ -e 's/@''GNULIB_WCWIDTH''@/1/g' \ -e 's/@''GNULIB_WMEMCHR''@/0/g' \ -e 's/@''GNULIB_WMEMCMP''@/0/g' \ -e 's/@''GNULIB_WMEMCPY''@/0/g' \ -e 's/@''GNULIB_WMEMMOVE''@/0/g' \ -e 's/@''GNULIB_WMEMPCPY''@/0/g' \ -e 's/@''GNULIB_WMEMSET''@/0/g' \ -e 's/@''GNULIB_WCSLEN''@/0/g' \ -e 's/@''GNULIB_WCSNLEN''@/0/g' \ -e 's/@''GNULIB_WCSCPY''@/0/g' \ -e 's/@''GNULIB_WCPCPY''@/0/g' \ -e 's/@''GNULIB_WCSNCPY''@/0/g' \ -e 's/@''GNULIB_WCPNCPY''@/0/g' \ -e 's/@''GNULIB_WCSCAT''@/0/g' \ -e 's/@''GNULIB_WCSNCAT''@/0/g' \ -e 's/@''GNULIB_WCSCMP''@/0/g' \ -e 's/@''GNULIB_WCSNCMP''@/0/g' \ -e 's/@''GNULIB_WCSCASECMP''@/0/g' \ -e 's/@''GNULIB_WCSNCASECMP''@/0/g' \ -e 's/@''GNULIB_WCSCOLL''@/0/g' \ -e 's/@''GNULIB_WCSXFRM''@/0/g' \ -e 's/@''GNULIB_WCSDUP''@/0/g' \ -e 's/@''GNULIB_WCSCHR''@/0/g' \ -e 's/@''GNULIB_WCSRCHR''@/0/g' \ -e 's/@''GNULIB_WCSCSPN''@/0/g' \ -e 's/@''GNULIB_WCSSPN''@/0/g' \ -e 's/@''GNULIB_WCSPBRK''@/0/g' \ -e 's/@''GNULIB_WCSSTR''@/0/g' \ -e 's/@''GNULIB_WCSTOK''@/0/g' \ -e 's/@''GNULIB_WCSWIDTH''@/0/g' \ -e 's/@''GNULIB_WCSFTIME''@/0/g' \ -e 's/@''GNULIB_MDA_WCSDUP''@/1/g' \ < ./lib/wchar.in.h | \ sed -e 's|@''HAVE_WINT_T''@|1|g' \ -e 's|@''HAVE_BTOWC''@|1|g' \ -e 's|@''HAVE_MBSINIT''@|1|g' \ -e 's|@''HAVE_MBRTOWC''@|1|g' \ -e 's|@''HAVE_MBRLEN''@|1|g' \ -e 's|@''HAVE_MBSRTOWCS''@|1|g' \ -e 's|@''HAVE_MBSNRTOWCS''@|1|g' \ -e 's|@''HAVE_WCRTOMB''@|1|g' \ -e 's|@''HAVE_WCSRTOMBS''@|1|g' \ -e 's|@''HAVE_WCSNRTOMBS''@|1|g' \ -e 's|@''HAVE_WMEMCHR''@|1|g' \ -e 's|@''HAVE_WMEMCMP''@|1|g' \ -e 's|@''HAVE_WMEMCPY''@|1|g' \ -e 's|@''HAVE_WMEMMOVE''@|1|g' \ -e 's|@''HAVE_WMEMPCPY''@|1|g' \ -e 's|@''HAVE_WMEMSET''@|1|g' \ -e 's|@''HAVE_WCSLEN''@|1|g' \ -e 's|@''HAVE_WCSNLEN''@|1|g' \ -e 's|@''HAVE_WCSCPY''@|1|g' \ -e 's|@''HAVE_WCPCPY''@|1|g' \ -e 's|@''HAVE_WCSNCPY''@|1|g' \ -e 's|@''HAVE_WCPNCPY''@|1|g' \ -e 's|@''HAVE_WCSCAT''@|1|g' \ -e 's|@''HAVE_WCSNCAT''@|1|g' \ -e 's|@''HAVE_WCSCMP''@|1|g' \ -e 's|@''HAVE_WCSNCMP''@|1|g' \ -e 's|@''HAVE_WCSCASECMP''@|1|g' \ -e 's|@''HAVE_WCSNCASECMP''@|1|g' \ -e 's|@''HAVE_WCSCOLL''@|1|g' \ -e 's|@''HAVE_WCSXFRM''@|1|g' \ -e 's|@''HAVE_WCSDUP''@|1|g' \ -e 's|@''HAVE_WCSCHR''@|1|g' \ -e 's|@''HAVE_WCSRCHR''@|1|g' \ -e 's|@''HAVE_WCSCSPN''@|1|g' \ -e 's|@''HAVE_WCSSPN''@|1|g' \ -e 's|@''HAVE_WCSPBRK''@|1|g' \ -e 's|@''HAVE_WCSSTR''@|1|g' \ -e 's|@''HAVE_WCSTOK''@|1|g' \ -e 's|@''HAVE_WCSWIDTH''@|1|g' \ -e 's|@''HAVE_WCSFTIME''@|1|g' \ -e 's|@''HAVE_DECL_WCTOB''@|1|g' \ -e 's|@''HAVE_DECL_WCSDUP''@|1|g' \ -e 's|@''HAVE_DECL_WCWIDTH''@|1|g' \ | \ sed -e 's|@''REPLACE_MBSTATE_T''@|0|g' \ -e 's|@''REPLACE_BTOWC''@|0|g' \ -e 's|@''REPLACE_WCTOB''@|0|g' \ -e 's|@''REPLACE_FREE''@|0|g' \ -e 's|@''REPLACE_MBSINIT''@|0|g' \ -e 's|@''REPLACE_MBRTOWC''@|1|g' \ -e 's|@''REPLACE_MBRLEN''@|0|g' \ -e 's|@''REPLACE_MBSRTOWCS''@|0|g' \ -e 's|@''REPLACE_MBSNRTOWCS''@|0|g' \ -e 's|@''REPLACE_WCRTOMB''@|0|g' \ -e 's|@''REPLACE_WCSRTOMBS''@|0|g' \ -e 's|@''REPLACE_WCSNRTOMBS''@|0|g' \ -e 's|@''REPLACE_WCWIDTH''@|0|g' \ -e 's|@''REPLACE_WCSWIDTH''@|0|g' \ -e 's|@''REPLACE_WCSFTIME''@|0|g' \ -e 's|@''REPLACE_WCSTOK''@|0|g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_ARG_NONNULL/r ./lib/arg-nonnull.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h'; \ } > lib/wchar.h-t && \ mv lib/wchar.h-t lib/wchar.h rm -f lib/wctype.h-t lib/wctype.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ -e 's/@''HAVE_WCTYPE_H''@/1/g' \ -e 's|@''INCLUDE_NEXT''@|include_next|g' \ -e 's|@''PRAGMA_SYSTEM_HEADER''@|#pragma GCC system_header|g' \ -e 's|@''PRAGMA_COLUMNS''@||g' \ -e 's|@''NEXT_WCTYPE_H''@||g' \ -e 's/@''HAVE_CRTDEFS_H''@/0/g' \ -e 's/@''GNULIBHEADERS_OVERRIDE_WINT_T''@/0/g' \ -e 's/@''GNULIB_ISWBLANK''@/1/g' \ -e 's/@''GNULIB_ISWDIGIT''@/1/g' \ -e 's/@''GNULIB_ISWXDIGIT''@/1/g' \ -e 's/@''GNULIB_WCTYPE''@/0/g' \ -e 's/@''GNULIB_ISWCTYPE''@/0/g' \ -e 's/@''GNULIB_WCTRANS''@/0/g' \ -e 's/@''GNULIB_TOWCTRANS''@/0/g' \ -e 's/@''HAVE_ISWBLANK''@/1/g' \ -e 's/@''HAVE_ISWCNTRL''@/1/g' \ -e 's/@''HAVE_WCTYPE_T''@/1/g' \ -e 's/@''HAVE_WCTRANS_T''@/1/g' \ -e 's/@''HAVE_WINT_T''@/1/g' \ -e 's/@''REPLACE_ISWBLANK''@/0/g' \ -e 's/@''REPLACE_ISWDIGIT''@/0/g' \ -e 's/@''REPLACE_ISWXDIGIT''@/0/g' \ -e 's/@''REPLACE_ISWCNTRL''@/0/g' \ -e 's/@''REPLACE_TOWLOWER''@/0/g' \ -e '/definitions of _GL_FUNCDECL_RPL/r ./lib/c++defs.h' \ -e '/definition of _GL_WARN_ON_USE/r ./lib/warn-on-use.h' \ < ./lib/wctype.in.h; \ } > lib/wctype.h-t && \ mv lib/wctype.h-t lib/wctype.h echo 3.8.2 > .version-t && mv .version-t .version make all-recursive make[2]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' Making all in po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/po' make[3]: Nothing to be done for 'all'. make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/po' Making all in runtime-po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' make[3]: Nothing to be done for 'all'. make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' Making all in gnulib-po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' make[3]: Nothing to be done for 'all'. make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' Making all in . make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-bitsetv.o `test -f 'lib/bitsetv.c' || echo './'`lib/bitsetv.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-c-ctype.o `test -f 'lib/c-ctype.c' || echo './'`lib/c-ctype.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-c-strcasecmp.o `test -f 'lib/c-strcasecmp.c' || echo './'`lib/c-strcasecmp.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-c-strncasecmp.o `test -f 'lib/c-strncasecmp.c' || echo './'`lib/c-strncasecmp.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-canonicalize.o `test -f 'lib/canonicalize.c' || echo './'`lib/canonicalize.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-careadlinkat.o `test -f 'lib/careadlinkat.c' || echo './'`lib/careadlinkat.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-cloexec.o `test -f 'lib/cloexec.c' || echo './'`lib/cloexec.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-close-stream.o `test -f 'lib/close-stream.c' || echo './'`lib/close-stream.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-closeout.o `test -f 'lib/closeout.c' || echo './'`lib/closeout.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-concat-filename.o `test -f 'lib/concat-filename.c' || echo './'`lib/concat-filename.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-dirname.o `test -f 'lib/dirname.c' || echo './'`lib/dirname.c lib/careadlinkat.c: In function 'careadlinkat': lib/careadlinkat.c:178:5: warning: #warning "GCC might issue a bogus -Wreturn-local-addr warning here." [-Wcpp] 178 | #warning "GCC might issue a bogus -Wreturn-local-addr warning here." | ^~~~~~~ gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-basename.o `test -f 'lib/basename.c' || echo './'`lib/basename.c lib/careadlinkat.c:179:5: warning: #warning "See ." [-Wcpp] 179 | #warning "See ." | ^~~~~~~ lib/canonicalize.c: In function 'canonicalize_filename_mode': lib/canonicalize.c:484:5: warning: #warning "GCC might issue a bogus -Wreturn-local-addr warning here." [-Wcpp] 484 | #warning "GCC might issue a bogus -Wreturn-local-addr warning here." | ^~~~~~~ lib/canonicalize.c:485:5: warning: #warning "See ." [-Wcpp] 485 | #warning "See ." | ^~~~~~~ lib/careadlinkat.c:182:10: warning: function may return address of local variable [-Wreturn-local-addr] 182 | return readlink_stk (fd, filename, buffer, buffer_size, alloc, | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 183 | preadlinkat, stack_buf); | ~~~~~~~~~~~~~~~~~~~~~~~ lib/careadlinkat.c:181:8: note: declared here 181 | char stack_buf[STACK_BUF_SIZE]; | ^~~~~~~~~ gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-dirname-lgpl.o `test -f 'lib/dirname-lgpl.c' || echo './'`lib/dirname-lgpl.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-stripslash.o `test -f 'lib/stripslash.c' || echo './'`lib/stripslash.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-execute.o `test -f 'lib/execute.c' || echo './'`lib/execute.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-exitfail.o `test -f 'lib/exitfail.c' || echo './'`lib/exitfail.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fatal-signal.o `test -f 'lib/fatal-signal.c' || echo './'`lib/fatal-signal.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fd-safer-flag.o `test -f 'lib/fd-safer-flag.c' || echo './'`lib/fd-safer-flag.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-dup-safer-flag.o `test -f 'lib/dup-safer-flag.c' || echo './'`lib/dup-safer-flag.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-file-set.o `test -f 'lib/file-set.c' || echo './'`lib/file-set.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-findprog-in.o `test -f 'lib/findprog-in.c' || echo './'`lib/findprog-in.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fopen-safer.o `test -f 'lib/fopen-safer.c' || echo './'`lib/fopen-safer.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fstrcmp.o `test -f 'lib/fstrcmp.c' || echo './'`lib/fstrcmp.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gethrxtime.o `test -f 'lib/gethrxtime.c' || echo './'`lib/gethrxtime.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xtime.o `test -f 'lib/xtime.c' || echo './'`lib/xtime.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-getprogname.o `test -f 'lib/getprogname.c' || echo './'`lib/getprogname.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gettime.o `test -f 'lib/gettime.c' || echo './'`lib/gettime.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-hard-locale.o `test -f 'lib/hard-locale.c' || echo './'`lib/hard-locale.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-hash.o `test -f 'lib/hash.c' || echo './'`lib/hash.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_hash_map.o `test -f 'lib/gl_hash_map.c' || echo './'`lib/gl_hash_map.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-hash-pjw.o `test -f 'lib/hash-pjw.c' || echo './'`lib/hash-pjw.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-hash-triple-simple.o `test -f 'lib/hash-triple-simple.c' || echo './'`lib/hash-triple-simple.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-ialloc.o `test -f 'lib/ialloc.c' || echo './'`lib/ialloc.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-integer_length.o `test -f 'lib/integer_length.c' || echo './'`lib/integer_length.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-integer_length_l.o `test -f 'lib/integer_length_l.c' || echo './'`lib/integer_length_l.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_linked_list.o `test -f 'lib/gl_linked_list.c' || echo './'`lib/gl_linked_list.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_list.o `test -f 'lib/gl_list.c' || echo './'`lib/gl_list.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-localcharset.o `test -f 'lib/localcharset.c' || echo './'`lib/localcharset.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_map.o `test -f 'lib/gl_map.c' || echo './'`lib/gl_map.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-math.o `test -f 'lib/math.c' || echo './'`lib/math.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-mbchar.o `test -f 'lib/mbchar.c' || echo './'`lib/mbchar.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-mbfile.o `test -f 'lib/mbfile.c' || echo './'`lib/mbfile.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-mbswidth.o `test -f 'lib/mbswidth.c' || echo './'`lib/mbswidth.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_oset.o `test -f 'lib/gl_oset.c' || echo './'`lib/gl_oset.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-pipe2.o `test -f 'lib/pipe2.c' || echo './'`lib/pipe2.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-pipe2-safer.o `test -f 'lib/pipe2-safer.c' || echo './'`lib/pipe2-safer.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-printf-frexp.o `test -f 'lib/printf-frexp.c' || echo './'`lib/printf-frexp.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-printf-frexpl.o `test -f 'lib/printf-frexpl.c' || echo './'`lib/printf-frexpl.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-progname.o `test -f 'lib/progname.c' || echo './'`lib/progname.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-quotearg.o `test -f 'lib/quotearg.c' || echo './'`lib/quotearg.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_rbtree_oset.o `test -f 'lib/gl_rbtree_oset.c' || echo './'`lib/gl_rbtree_oset.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_rbtreehash_list.o `test -f 'lib/gl_rbtreehash_list.c' || echo './'`lib/gl_rbtreehash_list.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-setlocale_null.o `test -f 'lib/setlocale_null.c' || echo './'`lib/setlocale_null.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-sig-handler.o `test -f 'lib/sig-handler.c' || echo './'`lib/sig-handler.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-spawn-pipe.o `test -f 'lib/spawn-pipe.c' || echo './'`lib/spawn-pipe.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/glthread/libbison_a-threadlib.o `test -f 'lib/glthread/threadlib.c' || echo './'`lib/glthread/threadlib.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-timespec.o `test -f 'lib/timespec.c' || echo './'`lib/timespec.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-timevar.o `test -f 'lib/timevar.c' || echo './'`lib/timevar.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/glthread/libbison_a-tls.o `test -f 'lib/glthread/tls.c' || echo './'`lib/glthread/tls.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-unicodeio.o `test -f 'lib/unicodeio.c' || echo './'`lib/unicodeio.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-unistd.o `test -f 'lib/unistd.c' || echo './'`lib/unistd.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-dup-safer.o `test -f 'lib/dup-safer.c' || echo './'`lib/dup-safer.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fd-safer.o `test -f 'lib/fd-safer.c' || echo './'`lib/fd-safer.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-pipe-safer.o `test -f 'lib/pipe-safer.c' || echo './'`lib/pipe-safer.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-wait-process.o `test -f 'lib/wait-process.c' || echo './'`lib/wait-process.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-wctype-h.o `test -f 'lib/wctype-h.c' || echo './'`lib/wctype-h.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xmalloc.o `test -f 'lib/xmalloc.c' || echo './'`lib/xmalloc.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xalloc-die.o `test -f 'lib/xalloc-die.c' || echo './'`lib/xalloc-die.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xconcat-filename.o `test -f 'lib/xconcat-filename.c' || echo './'`lib/xconcat-filename.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xhash.o `test -f 'lib/xhash.c' || echo './'`lib/xhash.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_xlist.o `test -f 'lib/gl_xlist.c' || echo './'`lib/gl_xlist.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_xmap.o `test -f 'lib/gl_xmap.c' || echo './'`lib/gl_xmap.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xmemdup0.o `test -f 'lib/xmemdup0.c' || echo './'`lib/xmemdup0.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xreadlink.o `test -f 'lib/xreadlink.c' || echo './'`lib/xreadlink.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xsize.o `test -f 'lib/xsize.c' || echo './'`lib/xsize.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-xstrndup.o `test -f 'lib/xstrndup.c' || echo './'`lib/xstrndup.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-get-errno.o `test -f 'lib/get-errno.c' || echo './'`lib/get-errno.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-path-join.o `test -f 'lib/path-join.c' || echo './'`lib/path-join.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-asnprintf.o `test -f 'lib/asnprintf.c' || echo './'`lib/asnprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-asprintf.o `test -f 'lib/asprintf.c' || echo './'`lib/asprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fcntl.o `test -f 'lib/fcntl.c' || echo './'`lib/fcntl.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fprintf.o `test -f 'lib/fprintf.c' || echo './'`lib/fprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-fseterr.o `test -f 'lib/fseterr.c' || echo './'`lib/fseterr.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-mbrtowc.o `test -f 'lib/mbrtowc.c' || echo './'`lib/mbrtowc.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-obstack.o `test -f 'lib/obstack.c' || echo './'`lib/obstack.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-printf.o `test -f 'lib/printf.c' || echo './'`lib/printf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-printf-args.o `test -f 'lib/printf-args.c' || echo './'`lib/printf-args.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-printf-parse.o `test -f 'lib/printf-parse.c' || echo './'`lib/printf-parse.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-readline.o `test -f 'lib/readline.c' || echo './'`lib/readline.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-snprintf.o `test -f 'lib/snprintf.c' || echo './'`lib/snprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-spawn_faction_addchdir.o `test -f 'lib/spawn_faction_addchdir.c' || echo './'`lib/spawn_faction_addchdir.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-sprintf.o `test -f 'lib/sprintf.c' || echo './'`lib/sprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-vasnprintf.o `test -f 'lib/vasnprintf.c' || echo './'`lib/vasnprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-vasprintf.o `test -f 'lib/vasprintf.c' || echo './'`lib/vasprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-vfprintf.o `test -f 'lib/vfprintf.c' || echo './'`lib/vfprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-vsnprintf.o `test -f 'lib/vsnprintf.c' || echo './'`lib/vsnprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-vsprintf.o `test -f 'lib/vsprintf.c' || echo './'`lib/vsprintf.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/main.o lib/main.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/yyerror.o lib/yyerror.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-AnnotationList.o `test -f 'src/AnnotationList.c' || echo './'`src/AnnotationList.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-InadequacyList.o `test -f 'src/InadequacyList.c' || echo './'`src/InadequacyList.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-Sbitset.o `test -f 'src/Sbitset.c' || echo './'`src/Sbitset.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-assoc.o `test -f 'src/assoc.c' || echo './'`src/assoc.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-closure.o `test -f 'src/closure.c' || echo './'`src/closure.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-complain.o `test -f 'src/complain.c' || echo './'`src/complain.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-conflicts.o `test -f 'src/conflicts.c' || echo './'`src/conflicts.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-counterexample.o `test -f 'src/counterexample.c' || echo './'`src/counterexample.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-derivation.o `test -f 'src/derivation.c' || echo './'`src/derivation.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-derives.o `test -f 'src/derives.c' || echo './'`src/derives.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-files.o `test -f 'src/files.c' || echo './'`src/files.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-fixits.o `test -f 'src/fixits.c' || echo './'`src/fixits.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-getargs.o `test -f 'src/getargs.c' || echo './'`src/getargs.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-glyphs.o `test -f 'src/glyphs.c' || echo './'`src/glyphs.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-gram.o `test -f 'src/gram.c' || echo './'`src/gram.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-graphviz.o `test -f 'src/graphviz.c' || echo './'`src/graphviz.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-ielr.o `test -f 'src/ielr.c' || echo './'`src/ielr.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-lalr.o `test -f 'src/lalr.c' || echo './'`src/lalr.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-location.o `test -f 'src/location.c' || echo './'`src/location.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-lr0.o `test -f 'src/lr0.c' || echo './'`src/lr0.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-lssi.o `test -f 'src/lssi.c' || echo './'`src/lssi.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-main.o `test -f 'src/main.c' || echo './'`src/main.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-muscle-tab.o `test -f 'src/muscle-tab.c' || echo './'`src/muscle-tab.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-named-ref.o `test -f 'src/named-ref.c' || echo './'`src/named-ref.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-nullable.o `test -f 'src/nullable.c' || echo './'`src/nullable.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-output.o `test -f 'src/output.c' || echo './'`src/output.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-parse-gram.o `test -f 'src/parse-gram.c' || echo './'`src/parse-gram.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-parse-simulation.o `test -f 'src/parse-simulation.c' || echo './'`src/parse-simulation.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-print-graph.o `test -f 'src/print-graph.c' || echo './'`src/print-graph.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-print-xml.o `test -f 'src/print-xml.c' || echo './'`src/print-xml.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-print.o `test -f 'src/print.c' || echo './'`src/print.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-reader.o `test -f 'src/reader.c' || echo './'`src/reader.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-reduce.o `test -f 'src/reduce.c' || echo './'`src/reduce.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-relation.o `test -f 'src/relation.c' || echo './'`src/relation.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-scan-code-c.o `test -f 'src/scan-code-c.c' || echo './'`src/scan-code-c.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-scan-gram-c.o `test -f 'src/scan-gram-c.c' || echo './'`src/scan-gram-c.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-scan-skel-c.o `test -f 'src/scan-skel-c.c' || echo './'`src/scan-skel-c.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-state.o `test -f 'src/state.c' || echo './'`src/state.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-state-item.o `test -f 'src/state-item.c' || echo './'`src/state-item.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-strversion.o `test -f 'src/strversion.c' || echo './'`src/strversion.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-symlist.o `test -f 'src/symlist.c' || echo './'`src/symlist.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-symtab.o `test -f 'src/symtab.c' || echo './'`src/symtab.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-tables.o `test -f 'src/tables.c' || echo './'`src/tables.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DINSTALLDIR=\"/usr/bin\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o src/bison-uniqstr.o `test -f 'src/uniqstr.c' || echo './'`src/uniqstr.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-allocator.o `test -f 'lib/allocator.c' || echo './'`lib/allocator.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-areadlink.o `test -f 'lib/areadlink.c' || echo './'`lib/areadlink.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-argmatch.o `test -f 'lib/argmatch.c' || echo './'`lib/argmatch.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-gl_array_list.o `test -f 'lib/gl_array_list.c' || echo './'`lib/gl_array_list.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-basename-lgpl.o `test -f 'lib/basename-lgpl.c' || echo './'`lib/basename-lgpl.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-binary-io.o `test -f 'lib/binary-io.c' || echo './'`lib/binary-io.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-bitrotate.o `test -f 'lib/bitrotate.c' || echo './'`lib/bitrotate.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-bitset.o `test -f 'lib/bitset.c' || echo './'`lib/bitset.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/bitset/libbison_a-array.o `test -f 'lib/bitset/array.c' || echo './'`lib/bitset/array.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/bitset/libbison_a-stats.o `test -f 'lib/bitset/stats.c' || echo './'`lib/bitset/stats.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/bitset/libbison_a-table.o `test -f 'lib/bitset/table.c' || echo './'`lib/bitset/table.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/bitset/libbison_a-list.o `test -f 'lib/bitset/list.c' || echo './'`lib/bitset/list.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/bitset/libbison_a-vector.o `test -f 'lib/bitset/vector.c' || echo './'`lib/bitset/vector.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/glthread/libbison_a-lock.o `test -f 'lib/glthread/lock.c' || echo './'`lib/glthread/lock.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/malloc/libbison_a-scratch_buffer_dupfree.o `test -f 'lib/malloc/scratch_buffer_dupfree.c' || echo './'`lib/malloc/scratch_buffer_dupfree.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/malloc/libbison_a-scratch_buffer_grow.o `test -f 'lib/malloc/scratch_buffer_grow.c' || echo './'`lib/malloc/scratch_buffer_grow.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/malloc/libbison_a-scratch_buffer_grow_preserve.o `test -f 'lib/malloc/scratch_buffer_grow_preserve.c' || echo './'`lib/malloc/scratch_buffer_grow_preserve.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/malloc/libbison_a-scratch_buffer_set_array_size.o `test -f 'lib/malloc/scratch_buffer_set_array_size.c' || echo './'`lib/malloc/scratch_buffer_set_array_size.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/unistr/libbison_a-u8-mbtoucr.o `test -f 'lib/unistr/u8-mbtoucr.c' || echo './'`lib/unistr/u8-mbtoucr.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/unistr/libbison_a-u8-uctomb.o `test -f 'lib/unistr/u8-uctomb.c' || echo './'`lib/unistr/u8-uctomb.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/unistr/libbison_a-u8-uctomb-aux.o `test -f 'lib/unistr/u8-uctomb-aux.c' || echo './'`lib/unistr/u8-uctomb-aux.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/uniwidth/libbison_a-width.o `test -f 'lib/uniwidth/width.c' || echo './'`lib/uniwidth/width.c rm -f lib/liby.a ar cr lib/liby.a lib/main.o lib/yyerror.o ranlib lib/liby.a rm -f lib/libbison.a ar cr lib/libbison.a lib/libbison_a-allocator.o lib/libbison_a-areadlink.o lib/libbison_a-argmatch.o lib/libbison_a-gl_array_list.o lib/libbison_a-basename-lgpl.o lib/libbison_a-binary-io.o lib/libbison_a-bitrotate.o lib/libbison_a-bitset.o lib/bitset/libbison_a-array.o lib/bitset/libbison_a-stats.o lib/bitset/libbison_a-table.o lib/bitset/libbison_a-list.o lib/bitset/libbison_a-vector.o lib/libbison_a-bitsetv.o lib/libbison_a-c-ctype.o lib/libbison_a-c-strcasecmp.o lib/libbison_a-c-strncasecmp.o lib/libbison_a-canonicalize.o lib/libbison_a-careadlinkat.o lib/libbison_a-cloexec.o lib/libbison_a-close-stream.o lib/libbison_a-closeout.o lib/libbison_a-concat-filename.o lib/libbison_a-dirname.o lib/libbison_a-basename.o lib/libbison_a-dirname-lgpl.o lib/libbison_a-stripslash.o lib/libbison_a-execute.o lib/libbison_a-exitfail.o lib/libbison_a-fatal-signal.o lib/libbison_a-fd-safer-flag.o lib/libbison_a-dup-safer-flag.o lib/libbison_a-file-set.o lib/libbison_a-findprog-in.o lib/libbison_a-fopen-safer.o lib/libbison_a-fstrcmp.o lib/libbison_a-gethrxtime.o lib/libbison_a-xtime.o lib/libbison_a-getprogname.o lib/libbison_a-gettime.o lib/libbison_a-hard-locale.o lib/libbison_a-hash.o lib/libbison_a-gl_hash_map.o lib/libbison_a-hash-pjw.o lib/libbison_a-hash-triple-simple.o lib/libbison_a-ialloc.o lib/libbison_a-integer_length.o lib/libbison_a-integer_length_l.o lib/libbison_a-gl_linked_list.o lib/libbison_a-gl_list.o lib/libbison_a-localcharset.o lib/glthread/libbison_a-lock.o lib/libbison_a-gl_map.o lib/libbison_a-math.o lib/libbison_a-mbchar.o lib/libbison_a-mbfile.o lib/libbison_a-mbswidth.o lib/libbison_a-gl_oset.o lib/libbison_a-pipe2.o lib/libbison_a-pipe2-safer.o lib/libbison_a-printf-frexp.o lib/libbison_a-printf-frexpl.o lib/libbison_a-progname.o lib/libbison_a-quotearg.o lib/libbison_a-gl_rbtree_oset.o lib/libbison_a-gl_rbtreehash_list.o lib/malloc/libbison_a-scratch_buffer_dupfree.o lib/malloc/libbison_a-scratch_buffer_grow.o lib/malloc/libbison_a-scratch_buffer_grow_preserve.o lib/malloc/libbison_a-scratch_buffer_set_array_size.o lib/libbison_a-setlocale_null.o lib/libbison_a-sig-handler.o lib/libbison_a-spawn-pipe.o lib/glthread/libbison_a-threadlib.o lib/libbison_a-timespec.o lib/libbison_a-timevar.o lib/glthread/libbison_a-tls.o lib/libbison_a-unicodeio.o lib/libbison_a-unistd.o lib/libbison_a-dup-safer.o lib/libbison_a-fd-safer.o lib/libbison_a-pipe-safer.o lib/unistr/libbison_a-u8-mbtoucr.o lib/unistr/libbison_a-u8-uctomb.o lib/unistr/libbison_a-u8-uctomb-aux.o lib/uniwidth/libbison_a-width.o lib/libbison_a-wait-process.o lib/libbison_a-wctype-h.o lib/libbison_a-xmalloc.o lib/libbison_a-xalloc-die.o lib/libbison_a-xconcat-filename.o lib/libbison_a-xhash.o lib/libbison_a-gl_xlist.o lib/libbison_a-gl_xmap.o lib/libbison_a-xmemdup0.o lib/libbison_a-xreadlink.o lib/libbison_a-xsize.o lib/libbison_a-xstrndup.o lib/libbison_a-get-errno.o lib/libbison_a-path-join.o lib/libbison_a-asnprintf.o lib/libbison_a-asprintf.o lib/libbison_a-fcntl.o lib/libbison_a-fprintf.o lib/libbison_a-fseterr.o lib/libbison_a-mbrtowc.o lib/libbison_a-obstack.o lib/libbison_a-printf.o lib/libbison_a-printf-args.o lib/libbison_a-printf-parse.o lib/libbison_a-readline.o lib/libbison_a-snprintf.o lib/libbison_a-spawn_faction_addchdir.o lib/libbison_a-sprintf.o lib/libbison_a-vasnprintf.o lib/libbison_a-vasprintf.o lib/libbison_a-vfprintf.o lib/libbison_a-vsnprintf.o lib/libbison_a-vsprintf.o ranlib lib/libbison.a gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o src/bison src/bison-AnnotationList.o src/bison-InadequacyList.o src/bison-Sbitset.o src/bison-assoc.o src/bison-closure.o src/bison-complain.o src/bison-conflicts.o src/bison-counterexample.o src/bison-derivation.o src/bison-derives.o src/bison-files.o src/bison-fixits.o src/bison-getargs.o src/bison-glyphs.o src/bison-gram.o src/bison-graphviz.o src/bison-ielr.o src/bison-lalr.o src/bison-location.o src/bison-lr0.o src/bison-lssi.o src/bison-main.o src/bison-muscle-tab.o src/bison-named-ref.o src/bison-nullable.o src/bison-output.o src/bison-parse-gram.o src/bison-parse-simulation.o src/bison-print-graph.o src/bison-print-xml.o src/bison-print.o src/bison-reader.o src/bison-reduce.o src/bison-relation.o src/bison-scan-code-c.o src/bison-scan-gram-c.o src/bison-scan-skel-c.o src/bison-state.o src/bison-state-item.o src/bison-strversion.o src/bison-symlist.o src/bison-symtab.o src/bison-tables.o src/bison-uniqstr.o lib/libbison.a /usr/bin/mkdir -p doc LC_ALL=C tests/bison --version >doc/bison.help.tmp LC_ALL=C tests/bison --help | \ sed -e 's,^Usage: .*/bison \[OPTION\],Usage: bison [OPTION],g' \ -e '/translation bugs/d' >>doc/bison.help.tmp ./build-aux/move-if-change doc/bison.help.tmp doc/bison.help if /bin/sh '/build/reproducible-path/bison-3.8.2+dfsg/build-aux/missing' help2man --version >/dev/null 2>&1; then \ /bin/sh '/build/reproducible-path/bison-3.8.2+dfsg/build-aux/missing' help2man \ --include=./doc/bison.x \ --output=doc/bison.1.tmp tests/bison && \ { sed 's/^\(\.TH[^"]*"[^"]*"[^"]*\)"[^"]*"/\1/' doc/bison.1 >doc/bison.1a.tmp || true; } && \ sed 's/^\(\.TH[^"]*"[^"]*"[^"]*\)"[^"]*"/\1/' doc/bison.1.tmp >doc/bison.1b.tmp && \ if diff doc/bison.1a.tmp doc/bison.1b.tmp >/dev/null 2>&1; then \ touch doc/bison.1; \ else \ mv doc/bison.1.tmp doc/bison.1; \ fi && \ rm -f doc/bison.1*.tmp; \ elif test -d ./.git; then \ echo >&2 "ERROR: doc/bison.1: help2man is needed"; \ exit 1; \ else \ touch doc/bison.1; \ fi /usr/bin/perl -pi.bak -0777 \ -e 's{(^ --.*\n(?: {10}.*\n)*)}' \ -e '{' \ -e ' $def = $1;' \ -e ' $def =~ s/‘|’//g;' \ -e ' $def;' \ -e '}gem;' ./doc/bison.info make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[2]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' dh_auto_test make -j12 check "TESTSUITEFLAGS=-j12 --verbose" VERBOSE=1 make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' if test -d ./.git \ && git --version >/dev/null 2>&1; then \ cd . && \ git submodule --quiet foreach \ 'test "$(git rev-parse "$sha1")" \ = "$(git merge-base origin "$sha1")"' \ || { echo 'maint.mk: found non-public submodule commit' >&2; \ exit 1; }; \ else \ : ; \ fi make check-recursive make[2]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' Making check in po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/po' make[3]: Nothing to be done for 'check'. make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/po' Making check in runtime-po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' make[3]: Nothing to be done for 'check'. make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' Making check in gnulib-po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' make[3]: Nothing to be done for 'check'. make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' Making check in . make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' /usr/bin/mkdir -p doc LC_ALL=C tests/bison --version >doc/bison.help.tmp LC_ALL=C tests/bison --help | \ sed -e 's,^Usage: .*/bison \[OPTION\],Usage: bison [OPTION],g' \ -e '/translation bugs/d' >>doc/bison.help.tmp ./build-aux/move-if-change doc/bison.help.tmp doc/bison.help make examples/c/calc/calc examples/c/glr/c++-types examples/c/lexcalc/lexcalc examples/c/mfcalc/mfcalc examples/c/pushcalc/calc examples/c/reccalc/reccalc examples/c/rpcalc/rpcalc examples/c++/calc++/calc++ examples/c++/glr/c++-types examples/c++/simple examples/c++/variant examples/c++/variant-11 ./tests/bison tests/atconfig tests/atlocal make[4]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' /bin/sh ./build-aux/ylwrap examples/c/calc/calc.y y.tab.c examples/c/calc/calc.c y.tab.h `echo examples/c/calc/calc.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/calc/calc.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines /bin/sh ./build-aux/ylwrap examples/c/glr/c++-types.y y.tab.c examples/c/glr/c++-types.c y.tab.h `echo examples/c/glr/c++-types.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/glr/c++-types.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines /bin/sh ./build-aux/ylwrap examples/c/lexcalc/parse.y y.tab.c examples/c/lexcalc/parse.c y.tab.h `echo examples/c/lexcalc/parse.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/lexcalc/parse.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines \ /bin/sh ./build-aux/ylwrap `test -f 'examples/c/lexcalc/scan.l' || echo './'`examples/c/lexcalc/scan.l lex.yy.c examples/c/lexcalc/scan.c -- flex /bin/sh ./build-aux/ylwrap examples/c/mfcalc/mfcalc.y y.tab.c examples/c/mfcalc/mfcalc.c y.tab.h `echo examples/c/mfcalc/mfcalc.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/mfcalc/mfcalc.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines /bin/sh ./build-aux/ylwrap examples/c/pushcalc/calc.y y.tab.c examples/c/pushcalc/calc.c y.tab.h `echo examples/c/pushcalc/calc.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/pushcalc/calc.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines /bin/sh ./build-aux/ylwrap examples/c/reccalc/parse.y y.tab.c examples/c/reccalc/parse.c y.tab.h `echo examples/c/reccalc/parse.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/reccalc/parse.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines /bin/sh ./build-aux/ylwrap examples/c/rpcalc/rpcalc.y y.tab.c examples/c/rpcalc/rpcalc.c y.tab.h `echo examples/c/rpcalc/rpcalc.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/rpcalc/rpcalc.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines rm -f examples/c++/calc++/parser.stamp \ /bin/sh ./build-aux/ylwrap `test -f 'examples/c++/calc++/scanner.ll' || echo './'`examples/c++/calc++/scanner.ll lex.yy.c examples/c++/calc++/scanner.cc -- flex touch examples/c++/calc++/parser.stamp.tmp ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines -o examples/c++/calc++/parser.cc examples/c++/calc++/parser.yy rm -f examples/c++/glr/c++-types.stamp touch examples/c++/glr/c++-types.stamp.tmp ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines -o examples/c++/glr/c++-types.cc examples/c++/glr/c++-types.yy \ /bin/sh ./build-aux/ylwrap `test -f 'examples/c++/simple.yy' || echo './'`examples/c++/simple.yy y.tab.c examples/c++/simple.cc y.tab.h `echo examples/c++/simple.cc | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c++/simple.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines updating examples/c/glr/c++-types.output mv -f examples/c++/calc++/parser.stamp.tmp examples/c++/calc++/parser.stamp updating examples/c/lexcalc/parse.output \ /bin/sh ./build-aux/ylwrap `test -f 'examples/c++/variant.yy' || echo './'`examples/c++/variant.yy y.tab.c examples/c++/variant.cc y.tab.h `echo examples/c++/variant.cc | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c++/variant.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines \ /bin/sh ./build-aux/ylwrap `test -f 'examples/c++/variant-11.yy' || echo './'`examples/c++/variant-11.yy y.tab.c examples/c++/variant-11.cc y.tab.h `echo examples/c++/variant-11.cc | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c++/variant-11.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines make[4]: 'tests/bison' is up to date. make[4]: Nothing to be done for 'tests/atconfig'. make[4]: 'tests/atlocal' is up to date. updating examples/c/glr/c++-types.h updating examples/c/lexcalc/parse.h updating examples/c/pushcalc/calc.output mv -f examples/c++/glr/c++-types.stamp.tmp examples/c++/glr/c++-types.stamp gcc -DEXEEXT=\"\" -I./examples/c/glr -I./examples/c/glr -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/glr/examples_c_glr_c___types-c++-types.o `test -f 'examples/c/glr/c++-types.c' || echo './'`examples/c/glr/c++-types.c gcc -DEXEEXT=\"\" -I./examples/c/lexcalc -I./examples/c/lexcalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/lexcalc/examples_c_lexcalc_lexcalc-parse.o `test -f 'examples/c/lexcalc/parse.c' || echo './'`examples/c/lexcalc/parse.c gcc -DEXEEXT=\"\" -I./examples/c/lexcalc -I./examples/c/lexcalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/lexcalc/examples_c_lexcalc_lexcalc-scan.o `test -f 'examples/c/lexcalc/scan.c' || echo './'`examples/c/lexcalc/scan.c g++ -DEXEEXT=\"\" -I./examples/c++/calc++ -I./examples/c++/calc++ -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/calc++/calc__-driver.o `test -f 'examples/c++/calc++/driver.cc' || echo './'`examples/c++/calc++/driver.cc updating examples/c/calc/calc.output updating examples/c/rpcalc/rpcalc.output updating examples/c/mfcalc/mfcalc.output updating examples/c/pushcalc/calc.h updating examples/c/reccalc/parse.output g++ -DEXEEXT=\"\" -I./examples/c++/calc++ -I./examples/c++/calc++ -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/calc++/calc__-scanner.o `test -f 'examples/c++/calc++/scanner.cc' || echo './'`examples/c++/calc++/scanner.cc updating examples/c/mfcalc/mfcalc.h updating examples/c/calc/calc.h g++ -DEXEEXT=\"\" -I./examples/c++/calc++ -I./examples/c++/calc++ -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/calc++/calc__-calc++.o `test -f 'examples/c++/calc++/calc++.cc' || echo './'`examples/c++/calc++/calc++.cc g++ -DEXEEXT=\"\" -I./examples/c++/calc++ -I./examples/c++/calc++ -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/calc++/calc__-parser.o `test -f 'examples/c++/calc++/parser.cc' || echo './'`examples/c++/calc++/parser.cc updating examples/c/rpcalc/rpcalc.h updating examples/c/reccalc/parse.h gcc -DEXEEXT=\"\" -I./examples/c/calc -I./examples/c/calc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/calc/examples_c_calc_calc-calc.o `test -f 'examples/c/calc/calc.c' || echo './'`examples/c/calc/calc.c gcc -DEXEEXT=\"\" -I./examples/c/mfcalc -I./examples/c/mfcalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/mfcalc/examples_c_mfcalc_mfcalc-mfcalc.o `test -f 'examples/c/mfcalc/mfcalc.c' || echo './'`examples/c/mfcalc/mfcalc.c updating examples/c++/simple.output updating examples/c++/variant.output updating examples/c++/variant-11.output updating examples/c++/simple.hh updating examples/c++/variant.hh gcc -DEXEEXT=\"\" -I./examples/c/pushcalc -I./examples/c/pushcalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/pushcalc/examples_c_pushcalc_calc-calc.o `test -f 'examples/c/pushcalc/calc.c' || echo './'`examples/c/pushcalc/calc.c gcc -DEXEEXT=\"\" -I./examples/c/reccalc -I./examples/c/reccalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/reccalc/examples_c_reccalc_reccalc-parse.o `test -f 'examples/c/reccalc/parse.c' || echo './'`examples/c/reccalc/parse.c updating examples/c++/variant-11.hh gcc -DEXEEXT=\"\" -I./examples/c/reccalc -I./examples/c/reccalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/reccalc/examples_c_reccalc_reccalc-scan.o `test -f 'examples/c/reccalc/scan.c' || echo './'`examples/c/reccalc/scan.c gcc -DEXEEXT=\"\" -I./examples/c/rpcalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/rpcalc/examples_c_rpcalc_rpcalc-rpcalc.o `test -f 'examples/c/rpcalc/rpcalc.c' || echo './'`examples/c/rpcalc/rpcalc.c g++ -DEXEEXT=\"\" -I./examples/c++/glr -I./examples/c++/glr -Wdate-time -D_FORTIFY_SOURCE=2 -std=c++14 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/glr/examples_c___glr_c___types-c++-types.o `test -f 'examples/c++/glr/c++-types.cc' || echo './'`examples/c++/glr/c++-types.cc g++ -DEXEEXT=\"\" -I. -Wdate-time -D_FORTIFY_SOURCE=2 -std=c++11 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/simple-simple.o `test -f 'examples/c++/simple.cc' || echo './'`examples/c++/simple.cc g++ -DEXEEXT=\"\" -I. -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/variant-variant.o `test -f 'examples/c++/variant.cc' || echo './'`examples/c++/variant.cc g++ -DEXEEXT=\"\" -I. -Wdate-time -D_FORTIFY_SOURCE=2 -std=c++11 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/variant_11-variant-11.o `test -f 'examples/c++/variant-11.cc' || echo './'`examples/c++/variant-11.cc gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/calc/calc examples/c/calc/examples_c_calc_calc-calc.o gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/lexcalc/lexcalc examples/c/lexcalc/examples_c_lexcalc_lexcalc-parse.o examples/c/lexcalc/examples_c_lexcalc_lexcalc-scan.o gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/mfcalc/mfcalc examples/c/mfcalc/examples_c_mfcalc_mfcalc-mfcalc.o -lm gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/rpcalc/rpcalc examples/c/rpcalc/examples_c_rpcalc_rpcalc-rpcalc.o -lm gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/reccalc/reccalc examples/c/reccalc/examples_c_reccalc_reccalc-parse.o examples/c/reccalc/examples_c_reccalc_reccalc-scan.o gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/pushcalc/calc examples/c/pushcalc/examples_c_pushcalc_calc-calc.o gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/glr/c++-types examples/c/glr/examples_c_glr_c___types-c++-types.o g++ -std=c++11 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c++/simple examples/c++/simple-simple.o g++ -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c++/calc++/calc++ examples/c++/calc++/calc__-driver.o examples/c++/calc++/calc__-scanner.o examples/c++/calc++/calc__-calc++.o examples/c++/calc++/calc__-parser.o g++ -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c++/variant examples/c++/variant-variant.o g++ -std=c++11 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c++/variant-11 examples/c++/variant_11-variant-11.o g++ -std=c++14 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c++/glr/c++-types examples/c++/glr/examples_c___glr_c___types-c++-types.o make[4]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make check-TESTS check-local make[4]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' make all-recursive rm -f tests/package.m4 tests/package.m4.tmp { \ echo '# Signature of the current package.'; \ echo 'm4_define([AT_PACKAGE_NAME], [GNU Bison])'; \ echo 'm4_define([AT_PACKAGE_TARNAME], [bison])'; \ echo 'm4_define([AT_PACKAGE_VERSION], [3.8.2])'; \ echo 'm4_define([AT_PACKAGE_STRING], [GNU Bison 3.8.2])'; \ echo 'm4_define([AT_PACKAGE_BUGREPORT], [bug-bison@gnu.org])'; \ } >tests/package.m4.tmp mv tests/package.m4.tmp tests/package.m4 \ /bin/sh '/build/reproducible-path/bison-3.8.2+dfsg/build-aux/missing' autom4te --language=autotest -I ./tests ./tests/testsuite.at -o tests/testsuite.tmp make[5]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' make[5]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' Making all in po make[6]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/po' make[6]: Nothing to be done for 'all'. make[6]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/po' Making all in runtime-po make[6]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' make[6]: Nothing to be done for 'all'. make[6]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' Making all in gnulib-po make[6]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' make[6]: Nothing to be done for 'all'. make[6]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' Making all in . make[6]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' PASS: examples/c/glr/c++-types.test /usr/bin/mkdir -p doc PASS: examples/c++/simple.test LC_ALL=C tests/bison --version >doc/bison.help.tmp LC_ALL=C tests/bison --help | \ sed -e 's,^Usage: .*/bison \[OPTION\],Usage: bison [OPTION],g' \ -e '/translation bugs/d' >>doc/bison.help.tmp ./build-aux/move-if-change doc/bison.help.tmp doc/bison.help PASS: examples/c++/glr/c++-types.test PASS: examples/c++/variant.test make[6]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[5]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' PASS: examples/c++/variant-11.test PASS: examples/c/lexcalc/lexcalc.test PASS: examples/c/mfcalc/mfcalc.test PASS: examples/c/calc/calc.test PASS: examples/c++/calc++/calc++.test PASS: examples/c/pushcalc/calc.test PASS: examples/c/reccalc/reccalc.test PASS: examples/c/rpcalc/rpcalc.test ============================================================================ Testsuite summary for GNU Bison 3.8.2 ============================================================================ # TOTAL: 12 # PASS: 12 # SKIP: 0 # XFAIL: 0 # FAIL: 0 # XPASS: 0 # ERROR: 0 ============================================================================ make[5]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' "/usr/bin/perl" -pi -e 's/\@tb\@/\t/g' tests/testsuite.tmp mv tests/testsuite.tmp tests/testsuite /bin/sh ./tests/testsuite -C tests -j12 --verbose ## --------------------------- ## ## GNU Bison 3.8.2 test suite. ## ## --------------------------- ## 1. m4.at:21: testing Generating Comments ... ./m4.at:53: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -S ./input.m4 input.y 6. input.at:173: testing Yacc warnings on symbols ... ./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wyacc input.y 7. input.at:204: testing Yacc warnings ... 2. input.at:27: testing Invalid number of arguments ... ./input.at:29: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 11. input.at:401: testing Dangling aliases ... 12. input.at:427: testing Symbol declarations ... 8. input.at:238: testing Yacc's %type ... 9. input.at:287: testing Invalid symbol declarations ... ./input.at:304: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y 4. input.at:83: testing Invalid inputs ... ./input.at:97: "$PERL" -pi -e 's/\\(\d{3})/chr(oct($1))/ge' input.y || exit 77 ./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wyacc input.y 5. input.at:147: testing Invalid inputs with {} ... 10. input.at:341: testing Redefining the error token ... ./input.at:354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y 3. input.at:58: testing Invalid options ... ./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wyacc input.y ./input.at:162: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wdangling input.y ./input.at:67: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -ferror=caret input.y ./input.at:99: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:467: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S./dump-symbols.m4 input.y 9. input.at:287: ok 5. input.at:147: ok stderr: stderr: input.y:1.11: error: invalid null character 1 | %header "ð€ˆ" | ^ input.y:2.1-2: error: invalid characters: '\0\001\002\377?' 2 | ÿ? | ^~ input.y:3.2: error: invalid null character 3 | "" | ^ input.y:5.1: error: invalid character: '?' 5 | ? | ^ input.y:6.14: error: invalid character: '}' 6 | default: 'a' } | ^ input.y:7.1: error: invalid character: '%' 7 | %& | ^ input.y:7.2: error: invalid character: '&' 7 | %& | ^ input.y:8.1-17: error: invalid directive: '%a-does-not-exist' 8 | %a-does-not-exist | ^~~~~~~~~~~~~~~~~ input.y:9.1: error: invalid character: '%' 9 | %- | ^ input.y:9.2: error: invalid character: '-' 9 | %- | ^ input.y:10.1-11.0: error: missing '%}' at end of file 10 | %{ | ^~ bison: invalid argument 'error=caret' for '--feature' Valid arguments are: - 'none' - 'caret', 'diagnostics-show-caret' - 'fixit', 'diagnostics-parseable-fixits' - 'syntax-only' - 'all' ./input.at:104: "$PERL" -p -e 's{([\0\200\210\360\377])}{sprintf "\\x%02x", ord($1)}ge' stderr ./input.at:34: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y 2.y ./input.at:68: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=error=itemsets input.y 4. input.at:83: ok ./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Werror ./input.at:390: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: ./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Werror ./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wdangling input.y -Werror ./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Werror ./m4.at:55: cat output.txt 13. input.at:528: testing Invalid $n and @n ... bison: invalid argument 'error=itemsets' for '--report' Valid arguments are: - 'none' - 'states' - 'itemsets' - 'lookaheads' - 'solved' - 'counterexamples', 'cex' - 'all' ./input.at:536: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:72: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror?all input.y 1. m4.at:21: ok stderr: ./input.at:42: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --skeleton stderr: stderr: input.y:1.1-11: error: POSIX Yacc does not support %destructor [-Werror=yacc] 1 | %destructor {} | ^~~~~~~~~~~ input.y:2.1-8: error: POSIX Yacc does not support %printer [-Werror=yacc] 2 | %printer {} | ^~~~~~~~ input.y:6.9-20: error: POSIX Yacc does not support typed midrule actions [-Werror=yacc] 6 | a: { $$ = 42; } { $$ = $1; }; | ^~~~~~~~~~~~ input.y:7.4-9: error: POSIX Yacc does not support %empty [-Werror=yacc] 7 | b: %empty { $$ = 42; }; | ^~~~~~ 14. input.at:552: testing Type Clashes ... ./input.at:468: cat symbols.csv input.y:1.1-6: error: POSIX Yacc does not support %nterm [-Werror=yacc] 1 | %nterm exp | ^~~~~~ input.y:2.12-15: error: POSIX Yacc does not support hexadecimal literals [-Werror=yacc] 2 | %token NUM 0x40 "number" | ^~~~ input.y:2.17-24: error: POSIX Yacc does not support string literals [-Werror=yacc] 2 | %token NUM 0x40 "number" | ^~~~~~~~ input.y:4.6-13: error: POSIX Yacc does not support string literals [-Werror=yacc] 4 | exp: "number"; | ^~~~~~~~ stderr: bison: invalid argument 'error?all' for '--warning' Valid arguments are: - 'all' - 'conflicts-rr' - 'conflicts-sr' - 'counterexamples', 'cex' - 'dangling-alias' - 'deprecated' - 'empty-rule' - 'everything' - 'midrule-values' - 'none' - 'other' - 'precedence' - 'yacc' ./input.at:565: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y input.y:2.1-6: error: POSIX Yacc does not support %nterm [-Werror=yacc] 2 | %nterm nterm1 | ^~~~~~ input.y:3.14-19: error: POSIX yacc reserves %type to nonterminals [-Werror=yacc] 3 | %type TOKEN1 TOKEN2 "TOKEN3" nterm1 nterm2 nterm3 '+' | ^~~~~~ input.y:3.28-35: error: POSIX Yacc does not support string literals [-Werror=yacc] 3 | %type TOKEN1 TOKEN2 "TOKEN3" nterm1 nterm2 nterm3 '+' | ^~~~~~~~ input.y:3.28-35: error: POSIX yacc reserves %type to nonterminals [-Werror=yacc] 3 | %type TOKEN1 TOKEN2 "TOKEN3" nterm1 nterm2 nterm3 '+' | ^~~~~~~~ input.y:3.58-60: error: POSIX yacc reserves %type to nonterminals [-Werror=yacc] 3 | %type TOKEN1 TOKEN2 "TOKEN3" nterm1 nterm2 nterm3 '+' | ^~~ input.y:5.1-6: error: POSIX Yacc does not support %nterm [-Werror=yacc] 5 | %nterm nterm2 | ^~~~~~ input.y:3.21-26: error: POSIX yacc reserves %type to nonterminals [-Werror=yacc] 3 | %type TOKEN1 TOKEN2 "TOKEN3" nterm1 nterm2 nterm3 '+' | ^~~~~~ input.y:10.9-16: error: POSIX Yacc does not support string literals [-Werror=yacc] 10 | nterm3: "TOKEN3" | ^~~~~~~~ 3. input.at:58: ok stderr: ./input.at:390: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./input.at:253: sed 's,.*/$,,' stderr 1>&2 ./input.at:216: sed 's,.*/$,,' stderr 1>&2 bison: option '--skeleton' requires an argument Try 'bison --help' for more information. ./input.at:43: sed -e \ "s/requires an argument -- skeleton/'--skeleton' requires an argument/" \ stderr ./input.at:182: sed 's,.*/$,,' stderr 1>&2 12. input.at:427: ok ./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=error 13. input.at:528: ok ./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=error 16. input.at:784: testing Unused values before symbol declarations ... 2. input.at:27: ok ./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=error 14. input.at:552: ok ./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y stderr: input.y:2.13-17: error: string literal "bar" not attached to a symbol [-Werror=dangling-alias] 2 | %type "bar" | ^~~~~ input.y:4.19-23: error: string literal "baz" not attached to a symbol [-Werror=dangling-alias] 4 | expr: "foo" "bar" "baz" | ^~~~~ ./input.at:410: sed 's,.*/$,,' stderr 1>&2 15. input.at:774: testing Unused values ... ./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wdangling input.y --warnings=error 19. input.at:859: testing Symbol class redefinition ... ./input.at:871: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y 17. input.at:794: testing Symbol redeclared ... ./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Wnone,none -Werror --trace=none ./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Wnone,none -Werror --trace=none 19. input.at:859: ok ./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Wnone,none -Werror --trace=none 18. input.at:832: testing EOF redeclared ... 20. input.at:899: testing Default %printer and %destructor redeclared ... ./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wdangling input.y -Wnone,none -Werror --trace=none ./input.at:959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./input.at:960: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror ./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=none -Werror --trace=none ./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=none -Werror --trace=none 22. input.at:1013: testing Undefined symbols ... ./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wdangling input.y --warnings=none -Werror --trace=none ./input.at:1023: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y 21. input.at:970: testing Per-type %printer and %destructor redeclared ... ./input.at:987: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=none -Werror --trace=none ./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror stderr: 6. input.at:173: ok 20. input.at:899: 22. input.at:1013: ok ok input.y:1.12-14: error: symbol FOO redeclared [-Werror=other] 1 | %token FOO FOO | ^~~ input.y:1.8-10: note: previous declaration 1 | %token FOO FOO | ^~~ input.y:2.15-17: error: symbol BAR redeclared [-Werror=other] 2 | %token BAR 12 BAR 12 | ^~~ input.y:2.8-10: note: previous declaration 2 | %token BAR 12 BAR 12 | ^~~ input.y:3.14-16: error: symbol EOF redeclared [-Werror=other] 3 | %token EOF 0 EOF 0 | ^~~ input.y:3.8-10: note: previous declaration 3 | %token EOF 0 EOF 0 | ^~~ 21. input.at:970: ok ./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror stderr: ./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror stdout: 8. input.at:238: ok ./input.at:391: $PREPARSER ./input stderr: ./input.at:804: sed 's,.*/$,,' stderr 1>&2 ./input.at:391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 11. input.at:401: ok 7. input.at:204: ok stderr: 10. input.at:341: ok 23. input.at:1045: testing Unassociated types used for a printer or destructor ... ./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y ./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error 26. input.at:1187: testing Unused values with per-type %destructor ... ./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y input.y:1.16-18: error: symbol FOO redeclared [-Werror=other] 1 | %token FOO BAR FOO 0 | ^~~ input.y:1.8-10: note: previous declaration 1 | %token FOO BAR FOO 0 | ^~~ 25. input.at:1139: testing Unused values with default %destructor ... ./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y 24. input.at:1074: testing Useless printers or destructors ... ./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y 29. input.at:1275: testing Incompatible Aliases ... ./input.at:843: sed 's,.*/$,,' stderr 1>&2 27. input.at:1219: testing Duplicate string ... ./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y ./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./input.at:1285: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y 28. input.at:1247: testing Token collisions ... ./input.at:1256: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y 28. input.at:1247: ok ./input.at:1299: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror ./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror stderr: ./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -o input.c input.y -Werror stderr: ./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror input.y:12.10-32: error: unset value: $$ [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~ input.y:12.10-12: error: unused value: $1 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.18-20: error: unused value: $3 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.26-28: error: unused value: $5 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:13.10-15: error: empty rule for typed nonterminal, and no action [-Werror=other] 13 | b: INT | %empty; | ^~~~~~ input.y:14.10-62: error: unset value: $$ [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:14.22-24: error: unused value: $3 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:14.43-45: error: unused value: $5 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:15.10-49: error: unset value: $$ [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:15.18-20: error: unused value: $3 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:15.30-32: error: unused value: $5 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:16.10-37: error: unset value: $$ [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:16.18-20: error: unused value: $3 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:16.27-29: error: unused value: $5 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:18.10-58: error: unset value: $$ [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:18.10-12: error: unused value: $1 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.31-33: error: unused value: $3 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.52-54: error: unused value: $5 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:19.10-72: error: unset value: $$ [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:19.10-12: error: unused value: $1 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.31-33: error: unused value: $3 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.66-68: error: unused value: $5 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:22.10-68: error: unset value: $$ [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:22.10-12: error: unused value: $1 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:22.14-16: error: unused value: $2 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:25.23-25: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.10-50: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:25.10-12: error: unused value: $1 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.23-25: error: unused value: $2 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.27-29: error: unused value: $3 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unused value: $4 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.44-46: error: unused value: $5 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:26.23-25: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ input.y:26.40-42: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ ./input.at:1313: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none input.y:12.10-32: error: unset value: $$ [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~ input.y:12.10-12: error: unused value: $1 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.18-20: error: unused value: $3 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.26-28: error: unused value: $5 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:13.10-15: error: empty rule for typed nonterminal, and no action [-Werror=other] 13 | b: INT | %empty; | ^~~~~~ input.y:14.10-62: error: unset value: $$ [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:14.22-24: error: unused value: $3 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:14.43-45: error: unused value: $5 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:15.10-49: error: unset value: $$ [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:15.18-20: error: unused value: $3 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:15.30-32: error: unused value: $5 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:16.10-37: error: unset value: $$ [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:16.18-20: error: unused value: $3 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:16.27-29: error: unused value: $5 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:18.10-58: error: unset value: $$ [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:18.10-12: error: unused value: $1 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.31-33: error: unused value: $3 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.52-54: error: unused value: $5 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:19.10-72: error: unset value: $$ [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:19.10-12: error: unused value: $1 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.31-33: error: unused value: $3 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.66-68: error: unused value: $5 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:22.10-68: error: unset value: $$ [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:22.10-12: error: unused value: $1 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:22.14-16: error: unused value: $2 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:25.23-25: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.10-50: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:25.10-12: error: unused value: $1 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.23-25: error: unused value: $2 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.27-29: error: unused value: $3 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unused value: $4 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.44-46: error: unused value: $5 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:26.23-25: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ input.y:26.40-42: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ ./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror stderr: ./input.at:785: sed 's,.*/$,,' stderr 1>&2 31. input.at:1569: testing Typed symbol aliases ... ./input.at:1586: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./input.at:775: sed 's,.*/$,,' stderr 1>&2 input.y:6.8-22: error: unset value: $$ [-Werror=other] 6 | start: end end { $1; } ; | ^~~~~~~~~~~~~~~ input.y:6.12-14: error: unused value: $2 [-Werror=other] 6 | start: end end { $1; } ; | ^~~ input.y:7.6-8: error: unset value: $$ [-Werror=other] 7 | end: { } ; | ^~~ ./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none stderr: input.y:6.11-14: error: symbol "<=" used more than once as a literal string [-Werror=other] 30. input.at:1400: testing Torturing the Scanner ... ./input.at:1407: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1327: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1199: sed 's,.*/$,,' stderr 1>&2 ./input.at:1236: sed 's,.*/$,,' stderr 1>&2 ./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error stderr: input.y:6.8-45: error: unset value: $$ [-Werror=other] 6 | start: end end tagged tagged { $1; $3; } ; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:6.12-14: error: unused value: $2 [-Werror=other] 6 | start: end end tagged tagged { $1; $3; } ; | ^~~ input.y:7.6-8: error: unset value: $$ [-Werror=other] 7 | end: { } ; | ^~~ ./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./input.at:1344: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1554: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -v -o input.c input.y 31. input.at:1569: ok ./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -o input.c input.y --warnings=error ./input.at:1152: sed 's,.*/$,,' stderr 1>&2 ./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none stderr: input.y:4.22-28: error: type is used, but is not associated to any symbol [-Werror=other] input.y:5.25-31: error: type is used, but is not associated to any symbol [-Werror=other] stderr: ./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./input.at:1062: sed 's,.*/$,,' stderr 1>&2 input.y:16.13-19: error: useless %printer for type [-Werror=other] input.y:17.16-22: error: useless %destructor for type [-Werror=other] ./input.at:1359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error ./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none 32. input.at:1609: testing Require 1.0 ... 17. input.at:794: ok ./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:1609: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 18. input.at:832: ok ./input.at:1555: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./input.at:1085: sed 's,.*/$,,' stderr 1>&2 ./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -o input.c input.y -Wnone,none -Werror --trace=none ./input.at:1374: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none ./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none 29. input.at:1275: ok stderr: ./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none 32. input.at:1609: ok 33. input.at:1610: testing Require 3.8.2 ... ./input.at:1610: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -o input.c input.y --warnings=none -Werror --trace=none ./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error ./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none 35. input.at:1619: testing String aliases for character tokens ... ./input.at:1632: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y 26. input.at:1187: ok 34. input.at:1612: testing Require 100.0 ... ./input.at:1612: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y 36. input.at:1642: testing Symbols ... ./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --yacc input.y stderr: 33. input.at:1610: ok stderr: 27. input.at:1219: ok input.y:9.10-16: error: require bison 100.0, but have 3.8.2 37. input.at:1708: testing Numbered tokens ... 34. input.at:1612: ok ./input.at:1720: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret redecl.y ./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none ./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --yacc input.y -Werror 35. input.at:1619: ok ./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror 38. input.at:1750: testing Unclosed constructs ... 23. input.at:1045: ok ./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./input.at:1779: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y 39. input.at:1805: testing %start after first rule ... ./input.at:1817: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 38. input.at:1750: ok stderr: ./input.at:1735: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret too-large.y stdout: ./input.at:1556: $CC $CFLAGS $CPPFLAGS -c -o main.o main.c stderr: input.y:1.1-5: error: POSIX Yacc does not support %code [-Werror=yacc] input.y:9.8-16: error: POSIX Yacc forbids dashes in symbol names: WITH-DASH [-Werror=yacc] input.y:10.21-34: error: POSIX Yacc does not support string literals [-Werror=yacc] input.y:12.23-38: error: POSIX Yacc does not support string literals [-Werror=yacc] input.y:13.1-5: error: POSIX Yacc does not support %code [-Werror=yacc] input.y:20.8-16: error: POSIX Yacc forbids dashes in symbol names: with-dash [-Werror=yacc] input.y:22.15-28: error: POSIX Yacc does not support string literals [-Werror=yacc] input.y:24.17-32: error: POSIX Yacc does not support string literals [-Werror=yacc] 40. input.at:1826: testing Duplicate %start symbol ... ./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y 37. input.at:1708: ok ./input.at:1666: sed 's,.*/$,,' stderr 1>&2 stderr: ./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none input.y:6.23-28: error: unused value: $4 [-Werror=other] input.y:8.9-11: error: unset value: $$ [-Werror=other] ./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none 42. input.at:1916: testing %prec's token must be defined ... ./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y 41. input.at:1895: testing %prec takes a token ... ./input.at:1905: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --yacc input.y --warnings=error 39. input.at:1805: ok ./input.at:1175: sed 's,.*/$,,' stderr 1>&2 41. input.at:1895: ok stderr: ./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror 43. input.at:1936: testing Reject unused %code qualifiers ... ./input.at:1946: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-c.y stdout: ./input.at:1557: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.o main.o $LIBS 44. input.at:2025: testing Multiple %code ... ./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror ./input.at:2054: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error 45. input.at:2065: testing errors ... ./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y ./input.at:2077: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-redefined.y ./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --yacc input.y -Wnone,none -Werror --trace=none stderr: 46. input.at:2102: testing %define, --define, --force-define ... input.y:1.12-14: error: duplicate directive [-Werror=other] 1 | %start exp exp exp | ^~~ input.y:1.8-10: note: previous declaration 1 | %start exp exp exp | ^~~ input.y:1.16-18: error: duplicate directive [-Werror=other] 1 | %start exp exp exp | ^~~ input.y:1.8-10: note: previous declaration 1 | %start exp exp exp | ^~~ input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y stderr: ./input.at:1836: sed 's,.*/$,,' stderr 1>&2 stdout: ./input.at:2118: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dvar-dd=cmd-d1 -Dvar-dd=cmd-d2 \ -Fvar-ff=cmd-f1 -Fvar-ff=cmd-f2 \ -Dvar-dfg=cmd-d -Fvar-dfg=cmd-f \ -Fvar-fd=cmd-f -Dvar-fd=cmd-d \ --skeleton ./skel.c input.y ./input.at:1558: $PREPARSER ./input ./input.at:2091: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-unused.y stderr: ./input.at:1960: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-c-glr.y ./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./input.at:1558: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 30. input.at:1400: stderr: ok input.y:2.8-17: error: token for %prec is not defined: PREC [-Werror=other] ./input.at:2054: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./input.at:2123: cat input.tab.c ./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y ./input.at:1925: sed 's,.*/$,,' stderr 1>&2 ./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --yacc input.y --warnings=none -Werror --trace=none ./input.at:2135: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dvar=cmd-d input-dg.y ./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error ./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none ./input.at:2146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Dvar=cmd-d input-dg.y 45. input.at:2065: ok 47. input.at:2170: testing "%define" Boolean variables ... ./input.at:2180: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret Input.y ./input.at:2158: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dunused-d -Funused-f input-unused.y ./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror ./input.at:1973: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-c++.y ./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./input.at:1678: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 47. input.at:2170: ok ./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none stderr: input.y:3.13-14: error: useless %printer for type <> [-Werror=other] ./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none ./input.at:1681: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -Werror ./input.at:1116: sed 's,.*/$,,' stderr 1>&2 48. input.at:2191: testing "%define" code variables ... 49. input.at:2224: testing "%define" keyword variables ... ./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y ./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.yy ./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error ./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./input.at:1986: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-c++-glr.y ./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror 46. input.at:2102: 25. input.at:1139: ok ok ./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -Werror ./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror 50. input.at:2257: testing "%define" enum variables ... ./input.at:2269: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y 42. input.at:1916: ok stderr: stderr: input.y:1.16-18: error: duplicate directive [-Werror=other] 1 | %start exp foo exp | ^~~ input.y:1.8-10: note: previous declaration 1 | %start exp foo exp | ^~~ input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] stdout: stderr: ./input.at:1694: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y ./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none ./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy -Werror stdout: ./input.at:1859: sed 's,.*/$,,' stderr 1>&2 51. input.at:2320: testing "%define" file variables ... ./input.at:2284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:2329: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:2055: $PREPARSER ./input stderr: ./input.at:2055: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 36. input.at:1642: ./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ok ./input.at:2303: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y 52. input.at:2342: testing "%define" backward compatibility ... ./input.at:2355: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y 44. input.at:2025: ./input.at:1999: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret special-char-@@.y ok 52. input.at:2342: ok ./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none stderr: input.y:12.10-32: error: unset value: $$ [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~ input.y:12.10-12: error: unused value: $1 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.18-20: error: unused value: $3 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.26-28: error: unused value: $5 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:13.10-15: error: empty rule for typed nonterminal, and no action [-Werror=other] 13 | b: INT | %empty; | ^~~~~~ input.y:14.14-20: error: unset value: $$ [-Werror=midrule-values] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~ input.y:14.26-41: error: unset value: $$ [-Werror=midrule-values] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~~~~~~~~~~ input.y:14.10-62: error: unset value: $$ [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:14.22-24: error: unused value: $3 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:14.43-45: error: unused value: $5 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:15.14-16: error: unset value: $$ [-Werror=midrule-values] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:15.10-49: error: unset value: $$ [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:15.18-20: error: unused value: $3 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:15.30-32: error: unused value: $5 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:16.10-37: error: unset value: $$ [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:16.18-20: error: unused value: $3 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:16.27-29: error: unused value: $5 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:18.10-58: error: unset value: $$ [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:18.10-12: error: unused value: $1 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.14-29: error: unused value: $2 [-Werror=midrule-values] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~ input.y:18.31-33: error: unused value: $3 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.35-50: error: unused value: $4 [-Werror=midrule-values] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~ input.y:18.52-54: error: unused value: $5 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:19.10-72: error: unset value: $$ [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:19.10-12: error: unused value: $1 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.31-33: error: unused value: $3 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.35-64: error: unused value: $4 [-Werror=midrule-values] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:19.66-68: error: unused value: $5 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:21.18-37: error: unused value: $3 [-Werror=midrule-values] 21 | j: INT | INT INT { $$ = 1; } { $$ = $1 + $2; }; | ^~~~~~~~~~~~~~~~~~~~ input.y:22.10-68: error: unset value: $$ [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:22.10-12: error: unused value: $1 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:22.14-16: error: unused value: $2 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:22.35-64: error: unused value: $4 [-Werror=midrule-values] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:25.23-25: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.10-50: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:25.10-12: error: unused value: $1 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.23-25: error: unused value: $2 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.27-29: error: unused value: $3 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unused value: $4 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.44-46: error: unused value: $5 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:26.23-25: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ input.y:26.40-42: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ stderr: ./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none 54. input.at:2429: testing C++ namespace reference errors ... ./input.at:2450: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:776: sed 's,.*/$,,' stderr 1>&2 input.y:5.1-40: error: %define variable 'lr.type' requires keyword values [-Werror=deprecated] input.y:3.1-40: error: %define variable 'lr.default-reduction' requires keyword values [-Werror=deprecated] input.y:4.1-40: error: %define variable 'lr.keep-unreachable-state' requires keyword values [-Werror=deprecated] input.y:1.1-38: error: %define variable 'api.pure' requires keyword values [-Werror=deprecated] input.y:2.1-40: error: %define variable 'api.push-pull' requires keyword values [-Werror=deprecated] stderr: input.yy:2.1-30: error: %define variable 'api.location.type' requires '{...}' values [-Werror=deprecated] input.yy:4.1-30: error: %define variable 'api.prefix' requires '{...}' values [-Werror=deprecated] input.yy:5.1-30: error: %define variable 'api.token.prefix' requires '{...}' values [-Werror=deprecated] input.yy:3.1-30: error: %define variable 'api.namespace' requires '{...}' values [-Werror=deprecated] 55. input.at:2482: testing Bad character literals ... stderr: 51. input.at:2320: ok input.y:12.10-32: error: unset value: $$ [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~ input.y:12.10-12: error: unused value: $1 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.18-20: error: unused value: $3 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:12.26-28: error: unused value: $5 [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~ input.y:13.10-15: error: empty rule for typed nonterminal, and no action [-Werror=other] 13 | b: INT | %empty; | ^~~~~~ input.y:14.14-20: error: unset value: $$ [-Werror=midrule-values] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~ input.y:14.26-41: error: unset value: $$ [-Werror=midrule-values] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~~~~~~~~~~ input.y:14.10-62: error: unset value: $$ [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:14.22-24: error: unused value: $3 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:14.43-45: error: unused value: $5 [-Werror=other] 14 | c: INT | INT { $1; } INT { $2; } INT { $4; }; | ^~~ input.y:15.14-16: error: unset value: $$ [-Werror=midrule-values] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:15.10-49: error: unset value: $$ [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:15.18-20: error: unused value: $3 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:15.30-32: error: unused value: $5 [-Werror=other] 15 | d: INT | INT { } INT { $1; } INT { $2; }; | ^~~ input.y:16.10-37: error: unset value: $$ [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:16.18-20: error: unused value: $3 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:16.27-29: error: unused value: $5 [-Werror=other] 16 | e: INT | INT { } INT { } INT { $1; }; | ^~~ input.y:18.10-58: error: unset value: $$ [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:18.10-12: error: unused value: $1 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.14-29: error: unused value: $2 [-Werror=midrule-values] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~ input.y:18.31-33: error: unused value: $3 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:18.35-50: error: unused value: $4 [-Werror=midrule-values] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~~~~~~~~~~~~~~ input.y:18.52-54: error: unused value: $5 [-Werror=other] 18 | g: INT | INT { $$; } INT { $$; } INT { }; | ^~~ input.y:19.10-72: error: unset value: $$ [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:19.10-12: error: unused value: $1 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.31-33: error: unused value: $3 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:19.35-64: error: unused value: $4 [-Werror=midrule-values] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:19.66-68: error: unused value: $5 [-Werror=other] 19 | h: INT | INT { $$; } INT { $$ = $2; } INT { }; | ^~~ input.y:21.18-37: error: unused value: $3 [-Werror=midrule-values] 21 | j: INT | INT INT { $$ = 1; } { $$ = $1 + $2; }; | ^~~~~~~~~~~~~~~~~~~~ input.y:22.10-68: error: unset value: $$ [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:22.10-12: error: unused value: $1 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:22.14-16: error: unused value: $2 [-Werror=other] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~ input.y:22.35-64: error: unused value: $4 [-Werror=midrule-values] 22 | k: INT | INT INT { $$; } { $$ = $3; } { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:25.23-25: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.10-50: error: unset value: $$ [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:25.10-12: error: unused value: $1 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.23-25: error: unused value: $2 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.27-29: error: unused value: $3 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.40-42: error: unused value: $4 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:25.44-46: error: unused value: $5 [-Werror=other] 25 | n: INT | INT { } INT { } INT { }; | ^~~ input.y:26.23-25: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ input.y:26.40-42: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ ./input.at:2484: set x `LC_ALL=C ls -l 'empty.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='empty.y'; } || exit 77 53. input.at:2393: testing Unused api.pure ... ./input.at:2413: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2213: sed 's,.*/$,,' stderr 1>&2 ./input.at:2246: sed 's,.*/$,,' stderr 1>&2 ./input.at:786: sed 's,.*/$,,' stderr 1>&2 stderr: 0+0 records in 0+0 records out 0 bytes copied, 2.664e-05 s, 0.0 kB/s stdout: 50. input.at:2257: ok ./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y ./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy --warnings=error ./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y --warnings=error ./input.at:2490: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret empty.y 56. input.at:2543: testing Bad escapes in literals ... ./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./input.at:2556: "$PERL" -e 'print "start: \"\\\t\\\f\\\0\\\1\" ;";' >> input.y || exit 77 ./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y --warnings=error ./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error ./input.at:2508: set x `LC_ALL=C ls -l 'two.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='two.y'; } || exit 77 ./input.at:2558: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2414: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2012: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret special-char-].y stderr: 57. input.at:2582: testing Unexpected end of file ... ./input.at:2586: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:2452: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2591: set x `LC_ALL=C ls -l 'char.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='char.y'; } || exit 77 56. input.at:2543: ok 0+0 records in 0+0 records out 0 bytes copied, 2.548e-05 s, 0.0 kB/s stdout: stderr: ./input.at:2514: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret two.y 0+0 records in 0+0 records out 0 bytes copied, 2.5e-05 s, 0 B/s stdout: ./input.at:2594: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret char.y ./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror ./input.at:2522: set x `LC_ALL=C ls -l 'three.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='three.y'; } || exit 77 ./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./input.at:2604: set x `LC_ALL=C ls -l 'escape-in-char.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='escape-in-char.y'; } || exit 77 ./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy -Wnone,none -Werror --trace=none ./input.at:2415: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: 0+0 records in 0+0 records out 0 bytes copied, 2.5e-05 s, 0 B/s stdout: ./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none 43. input.at:1936: ./input.at:2528: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret three.y stderr: ok 0+0 records in 0+0 records out 0 bytes copied, 2.312e-05 s, 0.0 kB/s stdout: ./input.at:2607: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret escape-in-char.y 55. input.at:2482: ok 58. input.at:2675: testing LAC: Errors for %define ... ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Syacc.c -Dparse.lac=none input.y stderr: input.y:2.16-18: error: useless %printer for type <*> [-Werror=other] ./input.at:2617: set x `LC_ALL=C ls -l 'string.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='string.y'; } || exit 77 ./input.at:2454: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:1124: sed 's,.*/$,,' stderr 1>&2 stderr: ./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror 0+0 records in 0+0 records out 0 bytes copied, 2.62e-05 s, 0.0 kB/s stdout: 59. input.at:2719: testing -Werror combinations ... ./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall input.y ./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error ./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Syacc.c -Dparse.lac=full input.y ./input.at:2620: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret string.y ./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy --warnings=none -Werror --trace=none ./input.at:2416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: input.y:2.8-10: error: duplicate directive [-Werror=other] 2 | %start exp | ^~~ input.y:1.8-10: note: previous declaration 1 | %start exp foo | ^~~ input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] 60. input.at:2764: testing %name-prefix and api.prefix are incompatible ... ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Syacc.c -Dparse.lac=unsupported input.y ./input.at:2456: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2779: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-deprecated input.y ./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y -Werror ./input.at:1877: sed 's,.*/$,,' stderr 1>&2 ./input.at:2630: set x `LC_ALL=C ls -l 'escape-in-string.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='escape-in-string.y'; } || exit 77 ./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none stderr: ./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./input.at:2780: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dapi.prefix={foo} -p bar -Wno-deprecated input.y ./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.yy ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.cc -Dparse.lac=none input.y stderr: input.y:2.15: error: stray '$' [-Werror=other] 0+0 records in 0+0 records out 0 bytes copied, 2.556e-05 s, 0.0 kB/s stdout: ./input.at:2633: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret escape-in-string.y ./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y ./input.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2458: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./input.at:2643: set x `LC_ALL=C ls -l 'tstring.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='tstring.y'; } || exit 77 ./input.at:2727: sed 's,.*/$,,' stderr 1>&2 ./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y --warnings=none -Werror --trace=none ./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y --warnings=none -Werror --trace=none stderr: ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.cc -Dparse.lac=full input.y ./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y --warnings=error 0+0 records in 0+0 records out 0 bytes copied, 2.436e-05 s, 0.0 kB/s ./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none stdout: ./input.at:2646: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret tstring.y ./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror ./input.at:2460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.cc -Dparse.lac=unsupported input.y ./input.at:2781: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dapi.prefix={foo} -Wno-deprecated input.y ./input.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy -Werror 24. input.at:1074: ok ./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y -Wnone,none -Werror --trace=none ./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./input.at:2656: set x `LC_ALL=C ls -l 'escape-in-tstring.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='escape-in-tstring.y'; } || exit 77 stderr: stderr: 0+0 records in 0+0 records out 0 bytes copied, 2.284e-05 s, 0.0 kB/s stdout: ./input.at:2659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret escape-in-tstring.y input.y:5.1-40: error: %define variable 'lr.type' requires keyword values [-Werror=deprecated] input.y:3.1-40: error: %define variable 'lr.default-reduction' requires keyword values [-Werror=deprecated] input.y:4.1-40: error: %define variable 'lr.keep-unreachable-state' requires keyword values [-Werror=deprecated] input.y:1.1-38: error: %define variable 'api.pure' requires keyword values [-Werror=deprecated] input.y:2.1-40: error: %define variable 'api.push-pull' requires keyword values [-Werror=deprecated] ./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y --warnings=none -Werror --trace=none 61. input.at:2793: testing Redefined %union name ... 53. input.at:2393: ./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y ok ./input.at:2782: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -p bar -Wno-deprecated input.y ./input.at:2462: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 57. input.at:2582: ok ./input.at:2247: sed 's,.*/$,,' stderr 1>&2 stderr: input.yy:2.1-32: error: %define variable 'api.location.type' requires '{...}' values [-Werror=deprecated] input.yy:4.1-32: error: %define variable 'api.prefix' requires '{...}' values [-Werror=deprecated] input.yy:5.1-32: error: %define variable 'api.token.prefix' requires '{...}' values [-Werror=deprecated] input.yy:3.1-32: error: %define variable 'api.namespace' requires '{...}' values [-Werror=deprecated] 16. input.at:784: ok ./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.d -Dparse.lac=none input.y 15. input.at:774: ./input.at:2214: sed 's,.*/$,,' stderr 1>&2 ok ./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror 40. input.at:1826: ok ./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -W input.y ./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy --warnings=error 62. input.at:2840: testing Stray $ or @ ... ./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall input.y ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.d -Dparse.lac=full input.y 60. input.at:2764: ok 64. input.at:2946: testing Deprecated directives ... 63. input.at:2883: testing Code injection ... stderr: ./input.at:3019: cp errors-all experr input.y:3.8-10: error: %define variable 'api.value.union.name' redefined [-Werror=other] input.y:1.8-10: note: previous definition input.y:4.1-32: error: %define variable 'api.value.union.name' redefined [-Werror=other] input.y:3.8-10: note: previous definition input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S yacc.c -d input.y 65. input.at:3077: testing Unput's effect on locations ... ./input.at:3020: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -ffixit input.y ./input.at:3092: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2808: sed 's,.*/$,,' stderr 1>&2 ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.d -Dparse.lac=unsupported input.y 66. input.at:3113: testing Non-deprecated directives ... ./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y ./input.at:2465: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 65. input.at:3077: ok 67. input.at:3148: testing Cannot type action ... ./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none ./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -W input.y -Werror ./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error ./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y -Werror ./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy -Wnone,none -Werror --trace=none 68. input.at:3171: testing Character literals and api.token.raw ... ./input.at:3181: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:3022: sed -e '/^fix-it:/d' errors-all >experr ./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr.c -d input.y ./input.at:3023: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y ./input.at:2467: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror 68. input.at:3171: ok stderr: input.y:11.19: error: stray '$' [-Werror=other] input.y:11.23: error: stray '@' [-Werror=other] input.y:12.19: error: stray '$' [-Werror=other] input.y:12.23: error: stray '@' [-Werror=other] input.y:13.19: error: stray '$' [-Werror=other] input.y:13.23: error: stray '@' [-Werror=other] input.y:16.19: error: stray '$' [-Werror=other] input.y:16.23: error: stray '@' [-Werror=other] input.y:17.19: error: stray '$' [-Werror=other] ./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.java -Dparse.lac=none input.y stderr: input.y:2.15: error: stray '$' [-Werror=other] ./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none ./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./input.at:3027: rm -f output.c stderr: ./input.at:3028: cp input.y input.y.orig ./input.at:2861: sed 's,.*/$,,' stderr 1>&2 input.y:10.6-13: error: only midrule actions can be typed: int [-Werror=other] 10 | exp: {} | ^~~~~~~~ ./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.cc -d input.y ./input.at:2730: sed 's,.*/$,,' stderr 1>&2 ./input.at:2469: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:3156: sed 's,.*/$,,' stderr 1>&2 ./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y --warnings=error 69. input.at:3205: testing %token-table and parse.error ... ./input.at:3220: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:3029: sed -e '/fix-it/d' experr ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.java -Dparse.lac=full input.y ./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./input.at:3030: echo "bison: file 'input.y' was updated (backup: 'input.y~')" >>experr ./input.at:3031: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --update input.y ./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -W input.y --warnings=error ./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none stderr: ./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy --warnings=none -Werror --trace=none input.y:14.1-15.5: error: duplicate directive: '%file-prefix' [-Werror=other] input.y:13.1-18: note: previous declaration input.y: error: %expect-rr applies only to GLR parsers [-Werror=other] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ./input.at:3034: diff input.y.orig input.y~ ./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr.cc -d input.y ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.java -Dparse.lac=unsupported input.y ./input.at:3133: sed 's,.*/$,,' stderr 1>&2 ./input.at:3037: test ! -f output.c 54. input.at:2429: ./input.at:3040: sed -e '1,8d' input.y ok ./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y -Wnone,none -Werror --trace=none ./input.at:3221: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error ./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:3062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y ./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -W input.y -Wnone,none -Werror --trace=none ./input.at:2820: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 70. input.at:3231: testing Invalid file prefix mapping arguments ... ./input.at:3246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -M foo input.y 69. input.at:3205: ok ./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr2.cc -d input.y ./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y --warnings=none -Werror --trace=none ./input.at:3247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --file-prefix-map foo input.y 64. input.at:2946: ok ./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none ./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -W input.y --warnings=none -Werror --trace=none ./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./input.at:3248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -M foo=bar -M baz input.y 49. input.at:2224: ok ./input.at:2697: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dparse.lac.es-capacity-initial=1 -Dparse.lac.memory-trace=full input.y ./input.at:3249: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -M foo= -M baz input.y ./input.at:2825: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 71. named-refs.at:22: testing Tutorial calculator ... 72. named-refs.at:196: testing Undefined and ambiguous references ... ./named-refs.at:254: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o test.c test.y ./named-refs.at:184: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y 62. input.at:2840: ok 67. input.at:3148: ok ./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-none input.y 48. input.at:2191: ok ./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none 70. input.at:3231: ok ./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.d input.y ./input.at:2704: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.cc -Dparse.lac=full -Dparse.lac.es-capacity-initial=1 -Dparse.lac.memory-trace=full input.y 72. named-refs.at:196: ok 73. named-refs.at:297: testing Misleading references ... ./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.java input.y 75. named-refs.at:551: testing Missing identifiers in brackets ... ./named-refs.at:559: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y 74. named-refs.at:316: testing Many kinds of errors ... ./named-refs.at:384: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y ./named-refs.at:426: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o test.c test.y 77. named-refs.at:583: testing Comments in brackets ... 76. named-refs.at:567: testing Redundant words in brackets ... ./named-refs.at:575: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y ./named-refs.at:591: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y 61. input.at:2793: ok 78. named-refs.at:599: testing Stray symbols in brackets ... ./named-refs.at:184: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./named-refs.at:607: "$PERL" -pi -e 's/\\(\d{3})/chr(oct($1))/ge' test.y || exit 77 ./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y -Werror ./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-none input.y -Werror 66. input.at:3113: ok 76. named-refs.at:567: ok 75. named-refs.at:551: ok 77. named-refs.at:583: ok ./named-refs.at:608: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y 74. named-refs.at:316: ok ./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S yacc.c -d input.y ./input.at:2704: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.java -Dparse.lac=full -Dparse.lac.es-capacity-initial=1 -Dparse.lac.memory-trace=full input.y 79. named-refs.at:618: testing Redundant words in LHS brackets ... ./named-refs.at:625: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y 80. named-refs.at:635: testing Factored LHS ... 78. named-refs.at:599: ok ./named-refs.at:642: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: test.y:11.22-29: error: misleading reference: '$foo.bar' [-Werror=other] test.y:11.8-10: note: refers to: $foo at $1 test.y:11.12-18: note: possibly meant: $[foo.bar] at $2 81. named-refs.at:648: testing Unresolved references ... ./named-refs.at:676: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y stderr: 82. named-refs.at:715: testing $ or @ followed by . or - ... input.y:2.15: error: stray '$' [-Werror=other] ./named-refs.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y 83. output.at:68: testing Output files: -dv ... ./named-refs.at:306: sed 's,.*/$,,' stderr 1>&2 ./output.at:68: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv foo.y ./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr.c -d input.y 79. named-refs.at:618: ok 84. output.at:74: testing Output files: -dv >&- ... ./output.at:74: case "$PREBISON" in *valgrind*) exit 77;; esac ./input.at:2733: sed 's,.*/$,,' stderr 1>&2 81. named-refs.at:648: ok ./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y --warnings=error ./output.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv >&- foo.y ./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret test.y ./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-none input.y --warnings=error 85. output.at:81: testing Output files: -dv -o foo.c ... 58. input.at:2675: ok ./output.at:81: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -o foo.c foo.y stderr: ./output.at:68: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 80. named-refs.at:635: ok 86. output.at:84: testing Output files: -dv -y ... ./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y -Wnone,none -Werror --trace=none ./output.at:84: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -y foo.y stderr: ./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.cc -d input.y 83. output.at:68: ok ./output.at:74: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-none input.y -Wnone,none -Werror --trace=none 87. output.at:87: testing Output files: api.header.include={"./foo.h"} -dv -y ... ./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y -Werror stderr: ./output.at:81: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:87: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -y foo.y ./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y --warnings=none -Werror --trace=none stderr: 84. output.at:74: ok ./output.at:84: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr.cc -d input.y 89. output.at:95: testing Output files: --fixed-output-files -dv -g --html ... 89. output.at:95: ./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-none input.y --warnings=none -Werror --trace=none 88. output.at:92: testing Output files: -dv -o foo.tab.c ... skipped (output.at:95) stderr: foo.y:1.1-7: warning: POSIX Yacc does not support %define [-Wyacc] ./output.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -o foo.tab.c foo.y ./output.at:87: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: test.y:4.9: error: stray '$' [-Werror=other] test.y:5.9: error: stray '@' [-Werror=other] ./output.at:81: grep '#include "foo.h"' foo.c ./output.at:84: grep '#include "y.tab.h"' y.tab.c stdout: ./output.at:87: grep '#include "./foo.h"' y.tab.c #include "foo.h" stdout: stdout: 85. output.at:81: ok 86. output.at:84: #include "./foo.h" ok 90. output.at:97: testing Output files: -Hfoo.header -v -gfoo.gv --html=foo.html ... 87. output.at:87: ok ./named-refs.at:740: sed 's,.*/$,,' stderr 1>&2 90. output.at:97: skipped (output.at:97) stderr: ./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y --warnings=error ./output.at:92: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./input.at:2738: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror,none,other input.y 91. output.at:100: testing Output files: -dv -g --xml --fixed-output-files ... ./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr2.cc -d input.y 73. named-refs.at:297: 92. output.at:102: testing Output files: -dv -g --xml -y ... ok 88. output.at:92: ok ./output.at:100: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g --xml --fixed-output-files foo.y ./output.at:102: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g --xml -y foo.y 94. output.at:107: testing Output files: -dv -g --xml -o y.tab.c ... 96. output.at:112: testing Output files: -dv -g -o foo.c ... 95. output.at:110: testing Output files: -dv -b bar ... ./output.at:110: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -b bar foo.y ./output.at:107: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g --xml -o y.tab.c foo.y ./output.at:112: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g -o foo.c foo.y 93. output.at:104: testing Output files: %require "3.4" -dv -g --xml -y ... ./output.at:104: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g --xml -y foo.y ./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y -Wnone,none -Werror --trace=none ./input.at:2741: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror,no-all,other input.y stderr: ./output.at:110: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 97. output.at:116: testing Output files: %header %verbose ... stderr: 98. output.at:118: testing Output files: %header %verbose %yacc ... stderr: ./output.at:102: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: stderr: ./output.at:107: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 :6: warning: deprecated option: '--fixed-output-files', use '-o y.tab.c' [-Wdeprecated] ./output.at:100: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:112: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y ./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.d input.y 95. output.at:110: ok 92. output.at:102: ok ./output.at:118: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y stderr: 96. output.at:112: ok foo.y:1.1-8: warning: POSIX Yacc does not support %require [-Wyacc] foo.y:1.10-14: warning: POSIX Yacc does not support string literals [-Wyacc] ./output.at:104: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y --warnings=none -Werror --trace=none 94. output.at:107: ok 93. output.at:104: ok stderr: 91. output.at:100: ok stdout: stderr: ./named-refs.at:185: $PREPARSER ./test input.txt ./output.at:116: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.java input.y stderr: ./input.at:2746: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror -Wno-error=other input.y 100. output.at:125: testing Output files: %file-prefix "bar" %header %verbose ... ./named-refs.at:185: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./output.at:125: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y 97. output.at:116: stderr: ok stderr: 71. named-refs.at:22: ok ./output.at:118: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 99. output.at:121: testing Output files: %header %verbose %yacc ... 102. output.at:129: testing Output files: %file-prefix "baz" %output "bar.c" %header %verbose %yacc ... 101. output.at:127: testing Output files: %output "bar.c" %header %verbose %yacc ... ./output.at:127: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y 82. named-refs.at:715: ok 98. output.at:118: ok stderr: ./output.at:121: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy ./output.at:129: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y ./output.at:125: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 103. output.at:136: testing Output files: %header %verbose ... ./output.at:136: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy ./input.at:2750: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-error=other -Werror input.y 63. input.at:2883: ok 105. output.at:142: testing Output files: --header=foo.hpp -o foo.c++ ... 104. output.at:139: testing Output files: %header %verbose -o foo.c ... ./output.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c foo.yy stderr: ./output.at:142: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --header=foo.hpp -o foo.c++ foo.yy ./output.at:127: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 107. output.at:150: testing Output files: %header "foo.hpp" -o foo.c++ ... 100. output.at:125: ok 108. output.at:154: testing Output files: -o foo.c++ --graph=foo.gph ... ./output.at:150: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c++ foo.yy 106. output.at:146: testing Output files: --header=foo.hpp -o foo.c++ ... stderr: stderr: ./output.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --header=foo.hpp -o foo.c++ foo.yy ./output.at:129: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:154: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c++ --graph=foo.gph foo.yy ./output.at:121: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 101. output.at:127: ok ./input.at:2754: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror=other -Wno-other input.y stderr: ./output.at:136: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: stderr: ./output.at:139: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 99. output.at:121: ok ./output.at:142: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 110. output.at:167: testing Output files: useless=--header --graph --xml --report=all -Wall -Werror ... 109. output.at:160: testing Output files: %type useless --header --graph --xml --report=all -Wall -Werror ... ./output.at:167: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header --graph --xml --report=all -Wall -Werror foo.y 104. output.at:139: ok stderr: ./output.at:160: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header --graph --xml --report=all -Wall -Werror foo.y stderr: ./output.at:154: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 102. output.at:129: ok stderr: 103. output.at:136: ok ./output.at:146: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:150: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 105. output.at:142: ok 111. output.at:173: testing Output files: %defines -o foo.c++ ... ./output.at:173: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c++ foo.yy 108. output.at:154: ok 106. output.at:146: ok 107. output.at:150: ok 112. output.at:176: testing Output files: %defines "foo.hpp" -o foo.c++ ... ./output.at:176: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c++ foo.yy stderr: foo.y:1.13-19: error: symbol 'useless' is used, but is not defined as a token and has no rules [-Werror=other] foo.y: error: 1 nonterminal useless in grammar [-Werror=other] foo.y:1.13-19: error: nonterminal useless in grammar: useless [-Werror=other] ./output.at:160: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 113. output.at:191: testing Output files: lalr1.cc ... stderr: 59. input.at:2719: ok ./output.at:191: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy foo.y:1.1-15: error: %define variable 'useless' is not used 116. output.at:200: testing Output files: lalr1.cc %verbose %locations ... 115. output.at:197: testing Output files: lalr1.cc %header %verbose ... 114. output.at:194: testing Output files: lalr1.cc %verbose ... ./output.at:200: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy stderr: 109. output.at:160: ./output.at:194: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy ok ./output.at:197: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy ./output.at:167: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 118. output.at:206: testing Output files: lalr1.cc %header %verbose ... ./output.at:173: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 117. output.at:203: testing Output files: lalr1.cc %header %verbose %locations ... ./output.at:203: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy stderr: ./output.at:176: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 119. output.at:210: testing Output files: lalr1.cc %header %verbose %locations -o subdir/foo.cc ... stderr: 111. output.at:173: ok ./output.at:206: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret subdir/foo.yy ./output.at:191: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 112. output.at:176: ok stderr: stderr: 110. output.at:167: ok 113. output.at:191: ./output.at:197: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:194: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ok 121. output.at:220: testing Output files: lalr1.cc %header %locations %verbose %file-prefix "output_dir/foo" ... 120. output.at:215: testing Output files: lalr1.cc %header %verbose %file-prefix "output_dir/foo" ... stderr: ./output.at:200: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 115. output.at:197: ok 114. output.at:194: ok stderr: ./output.at:206: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(subdir/foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 116. output.at:200: ok stderr: ./output.at:203: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 122. output.at:226: testing Output files: lalr1.cc %header %locations api.location.file=none %require "3.2" ... 124. output.at:237: testing Output files: lalr1.cc %header %locations api.location.file="$at_dir/foo.loc.hh" %require "3.2" ... 123. output.at:231: testing Output files: lalr1.cc %header %locations api.location.file="foo.loc.hh" %require "3.2" ... ./output.at:226: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy ./output.at:237: "$PERL" -pi -e 's{\$at_dir}'"{$at_group_dir}g" foo.yy || exit 77 ./output.at:206: grep 'include .subdir/' foo.tab.cc ./output.at:231: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy ./output.at:206: grep 'include .subdir/' foo.tab.hh 125. output.at:267: testing Conflicting output files: --graph="foo.tab.c" ... ./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y ./output.at:237: rm -f foo.yy.bak 117. output.at:203: ./output.at:237: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy ok 126. output.at:272: testing Conflicting output files: %header "foo.output" -v ... 118. output.at:206: ok ./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v foo.y stderr: ./output.at:226: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 stderr: 128. output.at:282: testing Conflicting output files: -o foo.y ... ./output.at:282: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o foo.y foo.y ./output.at:231: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 127. output.at:277: testing Conflicting output files: lalr1.cc %header %locations --graph="location.hh" ... ./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y -Werror 129. output.at:328: testing Output file name: `~!@#$%^&*()-=_+{}[]|\:;<>, .' ... ./output.at:328: touch "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.tmp" || exit 77 stderr: ./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --graph="location.hh" foo.y ./output.at:237: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 130. output.at:335: testing Output file name: ( ... ./output.at:335: touch "(.tmp" || exit 77 123. output.at:231: ok ./output.at:215: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret gram_dir/foo.yy ./output.at:335: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "(.c" --header="(.h" glr.y 124. output.at:237: ok ./output.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.c" --header="\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.h" glr.y ./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v foo.y -Werror 122. output.at:226: ok ./output.at:282: cat foo.y ./output.at:210: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o subdir/foo.cc subdir/foo.yy 128. output.at:282: ok stderr: ./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="location.hh" foo.y -Werror foo.y: error: conflicting outputs to file 'foo.tab.c' [-Werror=other] stderr: ./output.at:335: ls "(.c" "(.h" 131. output.at:336: testing Output file name: ) ... ./output.at:336: touch ").tmp" || exit 77 ./output.at:215: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(gram_dir/foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:336: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o ").c" --header=").h" glr.y stdout: 132. output.at:337: testing Output file name: # ... ./output.at:337: touch "#.tmp" || exit 77 ./output.at:328: ls "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.c" "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.h" (.c (.h stderr: stderr: stdout: ./output.at:335: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "(.c" foo.y: error: conflicting outputs to file 'foo.output' [-Werror=other] `~!@#$%^&*()-=_+{}[]|\:;<>, .'.c `~!@#$%^&*()-=_+{}[]|\:;<>, .'.h ./output.at:210: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(subdir/foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:328: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.c" ./output.at:267: sed 's,.*/$,,' stderr 1>&2 ./output.at:220: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret gram_dir/foo.yy 120. output.at:215: ok ./output.at:272: sed 's,.*/$,,' stderr 1>&2 stderr: 133. output.at:338: testing Output file name: @@ ... ./output.at:338: touch "@@.tmp" || exit 77 ./output.at:338: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@@.c" --header="@@.h" glr.y foo.y: error: conflicting outputs to file 'location.hh' [-Werror=other] ./output.at:337: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "#.c" --header="#.h" glr.y ./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v foo.y --warnings=error ./output.at:210: grep 'include .subdir/' subdir/foo.cc 134. output.at:339: testing Output file name: @{ ... ./output.at:339: touch "@{.tmp" || exit 77 ./output.at:339: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@{.c" --header="@{.h" glr.y ./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y --warnings=error ./output.at:210: grep 'include .subdir/' subdir/foo.hh ./output.at:277: sed 's,.*/$,,' stderr 1>&2 119. output.at:210: ok ./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="location.hh" foo.y --warnings=error ./output.at:336: ls ").c" ").h" stdout: ).c ).h stderr: ./output.at:220: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(gram_dir/foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:339: ls "@{.c" "@{.h" ./output.at:336: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c ").c" 121. output.at:220: ok ./output.at:338: ls "@@.c" "@@.h" stdout: @{.c @{.h stdout: 135. output.at:340: testing Output file name: @} ... ./output.at:340: touch "@}.tmp" || exit 77 @@.c @@.h ./output.at:339: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "@{.c" ./output.at:338: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "@@.c" ./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y -Wnone,none -Werror --trace=none ./output.at:337: ls "#.c" "#.h" ./output.at:340: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@}.c" --header="@}.h" glr.y ./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="location.hh" foo.y -Wnone,none -Werror --trace=none stdout: #.c #.h ./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v foo.y -Wnone,none -Werror --trace=none ./output.at:337: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "#.c" 136. output.at:341: testing Output file name: [ ... ./output.at:341: touch "[.tmp" || exit 77 ./output.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "[.c" --header="[.h" glr.y 137. output.at:342: testing Output file name: ] ... ./output.at:342: touch "].tmp" || exit 77 ./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="location.hh" foo.y --warnings=none -Werror --trace=none ./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y --warnings=none -Werror --trace=none ./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v foo.y --warnings=none -Werror --trace=none ./output.at:340: ls "@}.c" "@}.h" stdout: @}.c @}.h ./output.at:342: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "].c" --header="].h" glr.y ./output.at:340: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "@}.c" ./output.at:341: ls "[.c" "[.h" ./output.at:272: cat foo.y ./output.at:277: cat foo.y stdout: [.c [.h ./output.at:267: cat foo.y ./output.at:341: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "[.c" 127. output.at:277: ok 125. output.at:267: ok 126. output.at:272: ok ./output.at:342: ls "].c" "].h" stdout: ].c ].h ./output.at:342: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "].c" 138. output.at:363: testing Graph with no conflicts ... ./output.at:363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y 140. output.at:473: testing Graph with solved S/R ... 139. output.at:403: testing Graph with unsolved S/R ... ./output.at:473: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y ./output.at:403: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y stderr: stderr: stderr: ./output.at:363: grep -v // input.gv input.y:6.5-7: warning: rule useless in parser due to conflicts [-Wother] input.y:14.10-18: warning: rule useless in parser due to conflicts [-Wother] input.y:15.10-18: warning: rule useless in parser due to conflicts [-Wother] ./output.at:473: grep -v // input.gv input.y: warning: 3 shift/reduce conflicts [-Wconflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:10.10-18: warning: rule useless in parser due to conflicts [-Wother] input.y:11.10-18: warning: rule useless in parser due to conflicts [-Wother] input.y:12.10-18: warning: rule useless in parser due to conflicts [-Wother] ./output.at:403: grep -v // input.gv 138. output.at:363: ok 140. output.at:473: ok 139. output.at:403: ok stderr: stderr: stdout: stdout: ./output.at:335: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "(.cc" --header="(.hh" cxx.y 141. output.at:538: testing Graph with R/R ... ./output.at:538: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y 143. output.at:641: testing Graph with a reduction rule both enabled and disabled ... ./output.at:641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y ./output.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.cc" --header="\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.hh" cxx.y ./output.at:335: ls "(.cc" "(.hh" 142. output.at:576: testing Graph with reductions with multiple LAT ... stdout: ./output.at:576: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y (.cc (.hh ./output.at:335: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "(.cc" stderr: ./output.at:328: ls "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.cc" "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.hh" stderr: stderr: input.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:4.3: warning: rule useless in parser due to conflicts [-Wother] ./output.at:538: grep -v // input.gv stdout: stdout: stderr: stderr: ./output.at:338: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@@.cc" --header="@@.hh" cxx.y stdout: stdout: stdout: ./output.at:337: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "#.cc" --header="#.hh" cxx.y 141. output.at:538: ok `~!@#$%^&*()-=_+{}[]|\:;<>, .'.cc `~!@#$%^&*()-=_+{}[]|\:;<>, .'.hh ./output.at:339: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@{.cc" --header="@{.hh" cxx.y ./output.at:336: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o ").cc" --header=").hh" cxx.y ./output.at:328: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.cc" stderr: input.y: warning: 3 reduce/reduce conflicts [-Wconflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:2.14-18: warning: rule useless in parser due to conflicts [-Wother] input.y:5.3: warning: rule useless in parser due to conflicts [-Wother] ./output.at:576: grep -v // input.gv 142. output.at:576: ok ./output.at:337: ls "#.cc" "#.hh" ./output.at:338: ls "@@.cc" "@@.hh" ./output.at:339: ls "@{.cc" "@{.hh" stdout: stdout: #.cc #.hh @{.cc @{.hh ./output.at:337: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "#.cc" ./output.at:339: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "@{.cc" 144. output.at:744: testing C++ Output File Prefix Mapping ... stdout: @@.cc @@.hh ./output.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o out/x1.cc -M out/=bar/ x1.yy ./output.at:338: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "@@.cc" ./output.at:336: ls ").cc" ").hh" stderr: stdout: stdout: ).cc ).hh ./output.at:336: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c ").cc" ./output.at:340: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@}.cc" --header="@}.hh" cxx.y 145. diagnostics.at:84: testing Warnings ... stderr: stdout: ./output.at:775: $CXX $CPPFLAGS $CXXFLAGS -Iout/include -c -o out/x1.o out/x1.cc ./output.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "[.cc" --header="[.hh" cxx.y ./diagnostics.at:84: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./output.at:340: ls "@}.cc" "@}.hh" stdout: stderr: @}.cc @}.hh input.y: warning: 4 shift/reduce conflicts [-Wconflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./output.at:641: grep -v // input.gv ./output.at:340: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "@}.cc" ./output.at:341: ls "[.cc" "[.hh" stdout: [.cc [.hh stderr: stdout: ./output.at:341: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "[.cc" 143. output.at:641: ok ./output.at:342: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "].cc" --header="].hh" cxx.y ./diagnostics.at:84: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:84: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y ./output.at:342: ls "].cc" "].hh" stdout: ].cc ].hh 146. diagnostics.at:133: testing Single point locations ... ./output.at:342: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "].cc" 145. diagnostics.at:84: ok ./diagnostics.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:133: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 147. diagnostics.at:182: testing Line is too short, and then you die ... ./diagnostics.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y 146. diagnostics.at:133: ok ./diagnostics.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:182: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y 147. diagnostics.at:182: ok 148. diagnostics.at:217: testing Zero-width characters ... ./diagnostics.at:217: "$PERL" -pi -e 's{\^M}{\r}g;s{\\(\d{3}|.)}{$v = $1; $v =~ /\A\d+\z/ ? chr($v) : $v}ge' input.y experr || exit 77 149. diagnostics.at:235: testing Tabulations and multibyte characters ... ./diagnostics.at:217: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:217: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:217: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y ./diagnostics.at:235: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y 148. diagnostics.at:217: ok ./diagnostics.at:235: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 150. diagnostics.at:282: testing Tabulations and multibyte characters ... ./diagnostics.at:235: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y stderr: ./diagnostics.at:282: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y stdout: 130. output.at:335: ok stderr: stdout: stderr: 133. output.at:338: ok stdout: ./diagnostics.at:282: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 149. diagnostics.at:235: 129. output.at:328: ./diagnostics.at:282: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y ok ok stderr: stdout: stderr: 132. output.at:337: ok stdout: 134. output.at:339: ok 151. diagnostics.at:303: testing Special files ... 150. diagnostics.at:282: ok 153. diagnostics.at:351: testing Carriage return ... 154. diagnostics.at:372: testing CR NL ... stderr: ./diagnostics.at:303: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y stdout: 152. diagnostics.at:328: testing Complaints from M4 ... 131. output.at:336: 157. diagnostics.at:465: testing Screen width: 60 columns ... ok ./diagnostics.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:372: "$PERL" -pi -e 's{\^M}{\r}g;s{\\(\d{3}|.)}{$v = $1; $v =~ /\A\d+\z/ ? chr($v) : $v}ge' input.y experr || exit 77 155. diagnostics.at:399: testing Screen width: 200 columns ... 156. diagnostics.at:432: testing Screen width: 80 columns ... ./diagnostics.at:465: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=60 bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:351: "$PERL" -pi -e 's{\^M}{\r}g;s{\\(\d{3}|.)}{$v = $1; $v =~ /\A\d+\z/ ? chr($v) : $v}ge' input.y experr || exit 77 ./diagnostics.at:399: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=200 bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:303: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:351: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y stderr: stdout: 136. output.at:341: ok ./diagnostics.at:303: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y ./diagnostics.at:351: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:351: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y stderr: ./diagnostics.at:372: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 stdout: 153. diagnostics.at:351: ok ./diagnostics.at:432: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=80 bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:328: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 158. diagnostics.at:504: testing Suggestions ... 135. output.at:340: ./diagnostics.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y ok ./diagnostics.at:399: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y 159. diagnostics.at:527: testing Counterexamples ... ./diagnostics.at:399: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=200 bison -fcaret -Wall,cex input.y 151. diagnostics.at:303: ok ./diagnostics.at:465: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:465: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=60 bison -fcaret -Wall,cex input.y ./diagnostics.at:432: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:527: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:504: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y 154. diagnostics.at:372: ok 160. diagnostics.at:645: testing Deep Counterexamples ... ./diagnostics.at:432: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=80 bison -fcaret -Wall,cex input.y 161. diagnostics.at:713: testing Indentation with message suppression ... ./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wno-other input.y ./diagnostics.at:645: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y 155. diagnostics.at:399: ok 152. diagnostics.at:328: ok ./diagnostics.at:504: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 ./diagnostics.at:504: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y 162. skeletons.at:25: testing Relative skeleton file names ... ./skeletons.at:27: mkdir tmp ./diagnostics.at:645: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 158. diagnostics.at:504: ok ./diagnostics.at:645: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y 157. diagnostics.at:465: ok 165. skeletons.at:166: testing Complaining during macro argument expansion ... 163. skeletons.at:85: testing Installed skeleton file names ... ./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wno-other input.y -Werror ./skeletons.at:189: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input1.y ./skeletons.at:63: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret tmp/input-gram.y ./skeletons.at:120: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --skeleton=yacc.c -o input-cmd-line.c input-cmd-line.y ./diagnostics.at:527: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { ++$example; $_ = "" if $example % 2 == 0; } ' experr || exit 77 stderr: 160. diagnostics.at:645: ok stdout: ./output.at:782: sed -ne 's/#line [0-9][0-9]* "/#line "/p;/INCLUDED/p;/\\file/{p;n;p;}' out/include/ast/loc.hh ./diagnostics.at:527: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y 164. skeletons.at:142: testing Boolean=variables: invalid skeleton defaults ... ./skeletons.at:155: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./output.at:794: sed -ne 's/^#line [0-9][0-9]* "/#line "/p;/INCLUDED/p;/\\file/{p;n;p;}' out/x1.hh 156. diagnostics.at:432: ok ./skeletons.at:64: cat input-gram.tab.c ./skeletons.at:68: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input-gram.y ./output.at:806: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o out/x2.cc -M out/=bar/ x2.yy 166. skeletons.at:248: testing Fatal errors make M4 exit immediately ... ./skeletons.at:69: cat input-gram.tab.c ./skeletons.at:262: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input1.y 167. skeletons.at:302: testing Fatal errors but M4 continues producing output ... ./skeletons.at:314: "$PERL" gen-skel.pl > skel.c || exit 77 ./skeletons.at:121: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input-cmd-line input-cmd-line.c $LIBS ./skeletons.at:322: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: input.y:2.1-12: error: deprecated directive: '%pure-parser', use '%define api.pure' [-Werror=deprecated] 2 | %pure-parser | ^~~~~~~~~~~~ | %define api.pure input.y:3.1-14: error: deprecated directive: '%error-verbose', use '%define parse.error verbose' [-Werror=deprecated] 3 | %error-verbose | ^~~~~~~~~~~~~~ | %define parse.error verbose 168. sets.at:27: testing Nullable ... ./sets.at:42: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=sets input.y ./output.at:806: $CXX $CPPFLAGS $CXXFLAGS -Iout/include -c -o out/x2.o out/x2.cc ./skeletons.at:73: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --skeleton=tmp/skel.c tmp/input-cmd-line.y ./skeletons.at:209: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input2.y 159. diagnostics.at:527: ok ./diagnostics.at:725: sed 's,.*/$,,' stderr 1>&2 164. skeletons.at:142: ok 169. sets.at:111: testing Broken Closure ... 167. skeletons.at:302: ok ./sets.at:125: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=sets input.y ./skeletons.at:74: cat input-cmd-line.tab.c stderr: ./skeletons.at:223: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input3.y bison (GNU Bison) 3.8.2 RITEM 0: e $end (rule 0) 3: 'e' (rule 1) 5: (rule 2) DERIVES $accept derives 0 e $end e derives 1 'e' 2 %empty NULLABLE $accept: no e: yes RTC: Firsts Input BEGIN 01 .--. 0| 1| 1| | `--' RTC: Firsts Input END RTC: Firsts Output BEGIN 01 .--. 0|11| 1| 1| `--' RTC: Firsts Output END FIRSTS $accept firsts $accept e e firsts e FDERIVES $accept derives 0 e $end 1 'e' 2 %empty e derives 1 'e' 2 %empty relation_transpose: relation_transpose: output: follows after includes: FOLLOWS[goto[0] = (0, e, 2)] = $end Lookaheads: State 0: rule 2: $end State 1: rule 1: State 3: rule 0: ./sets.at:43: sed -f extract.sed stderr ./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wno-other input.y --warnings=error ./skeletons.at:279: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input2.y 162. skeletons.at:25: ok 168. sets.at:27: ok 170. sets.at:153: testing Firsts ... ./sets.at:171: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=sets input.y stderr: bison (GNU Bison) 3.8.2 RITEM 0: a $end (rule 0) 3: b (rule 1) 5: c (rule 2) 7: d (rule 3) 9: e (rule 4) 11: f (rule 5) 13: g (rule 6) 15: h (rule 7) 17: 'h' (rule 8) DERIVES $accept derives 0 a $end a derives 1 b b derives 2 c c derives 3 d d derives 4 e e derives 5 f f derives 6 g g derives 7 h h derives 8 'h' NULLABLE $accept: no a: no b: no c: no d: no e: no f: no g: no h: no RTC: Firsts Input BEGIN 012345678 .---------. 0| 1 | 1| 1 | 2| 1 | 3| 1 | 4| 1 | 5| 1 | 6| 1 | 7| 1| 8| | `---------' RTC: Firsts Input END RTC: Firsts Output BEGIN 012345678 .---------. 0|111111111| 1| 11111111| 2| 1111111| 3| 111111| 4| 11111| 5| 1111| 6| 111| 7| 11| 8| 1| `---------' RTC: Firsts Output END FIRSTS $accept firsts $accept a b c d e f g h a firsts a b c d e f g h b firsts b c d e f g h c firsts c d e f g h d firsts d e f g h e firsts e f g h f firsts f g h g firsts g h h firsts h FDERIVES $accept derives 0 a $end 1 b 2 c 3 d 4 e 5 f 6 g 7 h 8 'h' a derives 1 b 2 c 3 d 4 e 5 f 6 g 7 h 8 'h' b derives 2 c 3 d 4 e 5 f 6 g 7 h 8 'h' c derives 3 d 4 e 5 f 6 g 7 h 8 'h' d derives 4 e 5 f 6 g 7 h 8 'h' e derives 5 f 6 g 7 h 8 'h' f derives 6 g 7 h 8 'h' g derives 7 h 8 'h' h derives 8 'h' relation_transpose: 0: 1 1: 2 2: 3 3: 4 4: 5 5: 6 6: 7 relation_transpose: output: 1: 0 2: 1 3: 2 4: 3 5: 4 6: 5 7: 6 follows after includes: FOLLOWS[goto[0] = (0, a, 2)] = $end FOLLOWS[goto[1] = (0, b, 3)] = $end FOLLOWS[goto[2] = (0, c, 4)] = $end FOLLOWS[goto[3] = (0, d, 5)] = $end FOLLOWS[goto[4] = (0, e, 6)] = $end FOLLOWS[goto[5] = (0, f, 7)] = $end FOLLOWS[goto[6] = (0, g, 8)] = $end FOLLOWS[goto[7] = (0, h, 9)] = $end Lookaheads: State 1: rule 8: State 3: rule 1: State 4: rule 2: State 5: rule 3: State 6: rule 4: State 7: rule 5: State 8: rule 6: State 9: rule 7: State 10: rule 0: ./sets.at:127: sed -n 's/[ ]*$//;/^RTC: Firsts Output BEGIN/,/^RTC: Firsts Output END/p' stderr 172. sets.at:269: testing Build relations ... ./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y 169. sets.at:111: ok 166. skeletons.at:248: ok ./skeletons.at:237: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input4.y 171. sets.at:228: testing Accept ... 173. sets.at:315: testing Reduced Grammar ... stderr: bison (GNU Bison) 3.8.2 RITEM 0: exp $end (rule 0) 3: exp '<' exp (rule 1) 7: exp '>' exp (rule 2) 11: exp '+' exp (rule 3) 15: exp '-' exp (rule 4) 19: exp '^' exp (rule 5) 23: exp '=' exp (rule 6) 27: "exp" (rule 7) DERIVES $accept derives 0 exp $end exp derives 1 exp '<' exp 2 exp '>' exp 3 exp '+' exp 4 exp '-' exp 5 exp '^' exp 6 exp '=' exp 7 "exp" NULLABLE $accept: no exp: no RTC: Firsts Input BEGIN 01 .--. 0| 1| 1| 1| `--' RTC: Firsts Input END RTC: Firsts Output BEGIN 01 .--. 0|11| 1| 1| `--' RTC: Firsts Output END FIRSTS $accept firsts $accept exp exp firsts exp FDERIVES $accept derives 0 exp $end 1 exp '<' exp 2 exp '>' exp 3 exp '+' exp 4 exp '-' exp 5 exp '^' exp 6 exp '=' exp 7 "exp" exp derives 1 exp '<' exp 2 exp '>' exp 3 exp '+' exp 4 exp '-' exp 5 exp '^' exp 6 exp '=' exp 7 "exp" relation_transpose: 0: 1 2 3 4 5 6 1: 1 2 3 4 5 6 2: 1 2 3 4 5 6 3: 1 2 3 4 5 6 4: 1 2 3 4 5 6 5: 1 2 3 4 5 6 6: 1 2 3 4 5 6 relation_transpose: output: 1: 0 1 2 3 4 5 6 2: 0 1 2 3 4 5 6 3: 0 1 2 3 4 5 6 4: 0 1 2 3 4 5 6 5: 0 1 2 3 4 5 6 6: 0 1 2 3 4 5 6 follows after includes: FOLLOWS[goto[0] = (0, exp, 2)] = $end '<' '>' '+' '-' '^' '=' FOLLOWS[goto[1] = (4, exp, 10)] = $end '<' '>' '+' '-' '^' '=' FOLLOWS[goto[2] = (5, exp, 11)] = $end '<' '>' '+' '-' '^' '=' FOLLOWS[goto[3] = (6, exp, 12)] = $end '<' '>' '+' '-' '^' '=' FOLLOWS[goto[4] = (7, exp, 13)] = $end '<' '>' '+' '-' '^' '=' FOLLOWS[goto[5] = (8, exp, 14)] = $end '<' '>' '+' '-' '^' '=' FOLLOWS[goto[6] = (9, exp, 15)] = $end '<' '>' '+' '-' '^' '=' Lookaheads: State 1: rule 7: State 3: rule 0: State 10: rule 1: $end '<' '>' '+' '-' '^' '=' State 11: rule 2: $end '<' '>' '+' '-' '^' '=' State 12: rule 3: $end '<' '>' '+' '-' '^' '=' State 13: rule 4: $end '<' '>' '+' '-' '^' '=' State 14: rule 5: $end '<' '>' '+' '-' '^' '=' State 15: rule 6: $end '<' '>' '+' '-' '^' '=' ./sets.at:172: sed -f extract.sed stderr ./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=grammar -o input.c input.y ./sets.at:240: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y 170. sets.at:153: ok stderr: stdout: 174. sets.at:394: testing Reduced Grammar with prec and assoc ... ./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wno-other input.y -Wnone,none -Werror --trace=none ./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror 137. output.at:342: ok ./sets.at:412: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=grammar -o input.c input.y 176. reduce.at:70: testing Useless Nonterminals ... ./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y 175. reduce.at:26: testing Useless Terminals ... 165. skeletons.at:166: ok ./sets.at:243: sed -n 's/.*define YYFINAL *\([0-9][0-9]*\)/final state \1/p' input.c ./reduce.at:47: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y stdout: final state 6 ./sets.at:248: sed -n ' /^State \(.*\)/{ s//final state \1/ x } / accept/{ x p q } ' input.output 177. reduce.at:120: testing Useless Rules ... stderr: ./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y input.y: error: 5 reduce/reduce conflicts [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:2.14-17: error: rule useless in parser due to conflicts [-Werror=other] 2 | expr: term | term | term | term | term | term | ^~~~ input.y:2.21-24: error: rule useless in parser due to conflicts [-Werror=other] 2 | expr: term | term | term | term | term | term | ^~~~ input.y:2.28-31: error: rule useless in parser due to conflicts [-Werror=other] 2 | expr: term | term | term | term | term | term | ^~~~ input.y:2.35-38: error: rule useless in parser due to conflicts [-Werror=other] 2 | expr: term | term | term | term | term | term | ^~~~ input.y:2.42-45: error: rule useless in parser due to conflicts [-Werror=other] 2 | expr: term | term | term | term | term | term | ^~~~ ./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=grammar -o input.c input.y -Werror 178. reduce.at:224: testing Useless Parts ... ./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y 171. sets.at:228: ok ./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wno-other input.y --warnings=none -Werror --trace=none ./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror 179. reduce.at:312: testing Reduced Automaton ... ./sets.at:286: sed 's,.*/$,,' stderr 1>&2 174. sets.at:394: ok ./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret not-reduced.y ./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./reduce.at:49: sed -n '/^Grammar/q;/^$/!p' input.output stderr: bison (GNU Bison) 3.8.2 input.y: error: 1 nonterminal useless in grammar [-Werror=other] input.y: error: 1 rule useless in grammar [-Werror=other] input.y:4.1-7: error: nonterminal useless in grammar: useless [-Werror=other] Reduced Grammar ntokens = 7, nnterms = 4, nsyms = 11, nrules = 6, nritems = 17 Tokens ------ Value Sprec Sassoc Tag 0 0 0 $end 1 0 0 error 2 0 0 $undefined 3 0 0 "+" 4 0 0 "*" 5 0 0 "useless" 6 0 0 "num" Nonterminals ------------ Value Tag 7 $accept 8 expr 9 term 10 fact Rules ----- Num (Prec, Assoc, Useful, UselessChain) Lhs -> (Ritem Range) Rhs 0 ( 0, 0, t, f) 7 -> ( 0- 1) 8 0 1 ( 0, 0, t, f) 8 -> ( 3- 5) 8 3 9 2 ( 0, 0, t, t) 8 -> ( 7- 7) 9 3 ( 0, 0, t, f) 9 -> ( 9-11) 9 4 10 4 ( 0, 0, t, t) 9 -> (13-13) 10 5 ( 0, 0, t, t) 10 -> (17-17) 6 6 ( 0, 0, f, t) 11 -> (15-15) 5 Rules interpreted ----------------- 0 $accept: expr $end 1 expr: expr "+" term 2 expr: term 3 term: term "*" fact 4 term: fact 5 fact: "num" 6 useless: "useless" reduced input.y defines 7 terminals, 4 nonterminals, and 6 productions. 161. diagnostics.at:713: 175. reduce.at:26: ok ok 180. reduce.at:406: testing Underivable Rules ... ./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y ./sets.at:325: sed 's,.*/$,,' stderr 1>&2 ./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror ./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret not-reduced.y -Werror stderr: input.y: error: 3 nonterminals useless in grammar [-Werror=other] input.y: error: 3 rules useless in grammar [-Werror=other] input.y:11.1-8: error: nonterminal useless in grammar: useless1 [-Werror=other] input.y:12.1-8: error: nonterminal useless in grammar: useless2 [-Werror=other] input.y:13.1-8: error: nonterminal useless in grammar: useless3 [-Werror=other] 181. reduce.at:452: testing Bad start symbols ... ./reduce.at:467: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y -Werror ./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none stderr: ./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=grammar -o input.c input.y --warnings=error stdout: ./reduce.at:89: sed 's,.*/$,,' stderr 1>&2 182. reduce.at:550: testing no lr.type: Single State Split ... ./skeletons.at:122: $PREPARSER ./input-cmd-line ./reduce.at:550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror stderr: stderr: syntax error, unexpected 'a', expecting end of file ./skeletons.at:122: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 183. reduce.at:550: testing lr.type=lalr: Single State Split ... ./reduce.at:550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stderr: ./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error input.y: error: 9 nonterminals useless in grammar [-Werror=other] input.y: error: 9 rules useless in grammar [-Werror=other] input.y:10.1-8: error: nonterminal useless in grammar: useless1 [-Werror=other] 10 | useless1: '1'; | ^~~~~~~~ input.y:11.1-8: error: nonterminal useless in grammar: useless2 [-Werror=other] 11 | useless2: '2'; | ^~~~~~~~ input.y:12.1-8: error: nonterminal useless in grammar: useless3 [-Werror=other] 12 | useless3: '3'; | ^~~~~~~~ input.y:13.1-8: error: nonterminal useless in grammar: useless4 [-Werror=other] 13 | useless4: '4'; | ^~~~~~~~ input.y:14.1-8: error: nonterminal useless in grammar: useless5 [-Werror=other] 14 | useless5: '5'; | ^~~~~~~~ input.y:15.1-8: error: nonterminal useless in grammar: useless6 [-Werror=other] 15 | useless6: '6'; | ^~~~~~~~ input.y:16.1-8: error: nonterminal useless in grammar: useless7 [-Werror=other] 16 | useless7: '7'; | ^~~~~~~~ input.y:17.1-8: error: nonterminal useless in grammar: useless8 [-Werror=other] 17 | useless8: '8'; | ^~~~~~~~ input.y:18.1-8: error: nonterminal useless in grammar: useless9 [-Werror=other] 18 | useless9: '9'; | ^~~~~~~~ ./reduce.at:473: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y not-reduced.y: error: 2 nonterminals useless in grammar [-Werror=other] not-reduced.y: error: 3 rules useless in grammar [-Werror=other] not-reduced.y:14.1-13: error: nonterminal useless in grammar: not_reachable [-Werror=other] 14 | not_reachable: useful { /* A not reachable action. */ } | ^~~~~~~~~~~~~ not-reduced.y:17.1-14: error: nonterminal useless in grammar: non_productive [-Werror=other] 17 | non_productive: non_productive useless_token | ^~~~~~~~~~~~~~ not-reduced.y:11.6-57: error: rule useless in grammar [-Werror=other] 11 | | non_productive { /* A non productive action. */ } | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ./skeletons.at:126: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input-gram.c input-gram.y stderr: ./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=grammar -o input.c input.y -Wnone,none -Werror --trace=none stderr: ./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./reduce.at:550: sed -n '/^State 0$/,$p' input.output input.y: error: 2 nonterminals useless in grammar [-Werror=other] input.y: error: 3 rules useless in grammar [-Werror=other] input.y:6.1-11: error: nonterminal useless in grammar: underivable [-Werror=other] 6 | underivable: indirection; | ^~~~~~~~~~~ input.y:7.1-11: error: nonterminal useless in grammar: indirection [-Werror=other] 7 | indirection: underivable; | ^~~~~~~~~~~ input.y:5.15-25: error: rule useless in grammar [-Werror=other] 5 | exp: useful | underivable; | ^~~~~~~~~~~ ./reduce.at:341: sed 's,.*/$,,' stderr 1>&2 input.y: error: 1 nonterminal useless in grammar [-Werror=other] input.y: error: 1 rule useless in grammar [-Werror=other] input.y:18.1-6: error: nonterminal useless in grammar: unused [-Werror=other] 18 | unused | ^~~~~~ ./reduce.at:550: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:550: sed -n '/^State 0$/,$p' input.output ./reduce.at:146: sed 's,.*/$,,' stderr 1>&2 ./reduce.at:420: sed 's,.*/$,,' stderr 1>&2 ./reduce.at:480: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret not-reduced.y --warnings=error ./reduce.at:550: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:261: sed 's,.*/$,,' stderr 1>&2 ./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none ./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y --warnings=error ./skeletons.at:127: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input-gram input-gram.c $LIBS ./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=grammar -o input.c input.y --warnings=none -Werror --trace=none ./reduce.at:488: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 172. sets.at:269: ok ./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret not-reduced.y -Wnone,none -Werror --trace=none ./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y -Wnone,none -Werror --trace=none ./reduce.at:97: sed -n '/^Grammar/q;/^$/!p' input.output ./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret not-reduced.y --warnings=none -Werror --trace=none ./reduce.at:109: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./reduce.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 173. sets.at:315: ok ./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y --warnings=none -Werror --trace=none ./reduce.at:505: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./reduce.at:355: sed -n '/^Grammar/q;/^$/!p' not-reduced.output 181. reduce.at:452: ok 185. reduce.at:550: testing lr.type=canonical-lr: Single State Split ... 184. reduce.at:550: testing lr.type=ielr: Single State Split ... ./reduce.at:550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:434: sed -n '/^Grammar/q;/^$/!p' input.output ./reduce.at:392: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret reduced.y ./reduce.at:270: sed -n '/^State 0/q;/^$/!p' input.output 180. reduce.at:406: ok ./reduce.at:179: sed -n '/^Grammar/q;/^$/!p' input.output ./reduce.at:298: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c stderr: 186. reduce.at:783: testing no lr.type: Lane Split ... ./reduce.at:783: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stdout: ./reduce.at:213: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./reduce.at:550: $PREPARSER ./input stderr: ./reduce.at:550: sed -n '/^State 0$/,$p' input.output syntax error ./reduce.at:550: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./reduce.at:550: sed -n '/^State 0$/,$p' input.output ./reduce.at:550: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:783: sed -n '/^State 0$/,$p' input.output 187. reduce.at:783: testing lr.type=lalr: Lane Split ... ./reduce.at:783: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y 183. reduce.at:550: stderr: ok stdout: ./reduce.at:396: sed 's/not-reduced/reduced/g' not-reduced.c stderr: stdout: 176. reduce.at:70: ok ./reduce.at:550: $PREPARSER ./input ./reduce.at:550: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: syntax error ./reduce.at:550: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 179. reduce.at:312: ok ./reduce.at:783: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./skeletons.at:128: $PREPARSER ./input-gram 182. reduce.at:550: ok ./reduce.at:783: sed -n '/^State 0$/,$p' input.output stderr: syntax error, unexpected 'a', expecting end of file ./skeletons.at:128: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 188. reduce.at:783: testing lr.type=ielr: Lane Split ... ./reduce.at:783: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:783: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 163. skeletons.at:85: ok 189. reduce.at:783: testing lr.type=canonical-lr: Lane Split ... ./reduce.at:783: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stderr: ./reduce.at:783: sed -n '/^State 0$/,$p' input.output stdout: stderr: ./reduce.at:783: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 178. reduce.at:224: 190. reduce.at:1027: testing no lr.type: Complex Lane Split ... ./reduce.at:1027: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stdout: ok 177. reduce.at:120: ok 191. reduce.at:1027: testing lr.type=lalr: Complex Lane Split ... ./reduce.at:1027: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y 192. reduce.at:1027: testing lr.type=ielr: Complex Lane Split ... ./reduce.at:783: sed -n '/^State 0$/,$p' input.output ./reduce.at:1027: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:1027: sed -n '/^State 0$/,$p' input.output ./reduce.at:1027: sed -n '/^State 0$/,$p' input.output ./reduce.at:1027: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:1027: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:783: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 193. reduce.at:1027: testing lr.type=canonical-lr: Complex Lane Split ... ./reduce.at:1027: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y 194. reduce.at:1296: testing no lr.type: Split During Added Lookahead Propagation ... ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:1027: sed -n '/^State 0$/,$p' input.output stderr: stdout: ./reduce.at:550: $PREPARSER ./input stderr: ./reduce.at:1027: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:550: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 184. reduce.at:550: ok stderr: stdout: ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror ./reduce.at:550: $PREPARSER ./input ./reduce.at:1027: sed -n '/^State 0$/,$p' input.output stderr: ./reduce.at:550: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 185. reduce.at:550: ok stdout: ./reduce.at:783: $PREPARSER ./input ./reduce.at:1027: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: ./reduce.at:783: $PREPARSER ./input stderr: stderr: syntax error ./reduce.at:783: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 187. reduce.at:783: ok syntax error ./reduce.at:783: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples 195. reduce.at:1296: testing lr.type=lalr: Split During Added Lookahead Propagation ... 196. reduce.at:1296: testing lr.type=ielr: Split During Added Lookahead Propagation ... ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y 197. reduce.at:1296: testing lr.type=canonical-lr: Split During Added Lookahead Propagation ... stderr: ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stdout: ./reduce.at:1296: sed 's,.*/$,,' stderr 1>&2 ./reduce.at:783: $PREPARSER ./input 186. reduce.at:783: ok stderr: ./reduce.at:783: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 188. reduce.at:783: ok stderr: stdout: ./reduce.at:1027: $PREPARSER ./input ./reduce.at:1296: sed -n '/^State 0$/,$p' input.output ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error stderr: syntax error ./reduce.at:1027: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror 198. reduce.at:1627: testing no lr.default-reduction ... ./reduce.at:1296: sed -n '/^State 0$/,$p' input.output ./reduce.at:1627: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stderr: stderr: stdout: stdout: 191. reduce.at:1027: ./reduce.at:783: $PREPARSER ./input ok ./reduce.at:1027: $PREPARSER ./input ./reduce.at:1296: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stderr: ./reduce.at:783: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./reduce.at:1027: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./reduce.at:1296: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:1627: sed -n '/^State 0$/,$p' input.output stderr: 190. reduce.at:1027: ok stderr: 189. reduce.at:783: ok stdout: 199. reduce.at:1627: testing lr.default-reduction=most ... ./reduce.at:1027: $PREPARSER ./input stderr: ./reduce.at:1627: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:1027: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./reduce.at:1627: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y 192. reduce.at:1027: ok stderr: ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none stdout: ./reduce.at:1027: $PREPARSER ./input stderr: ./reduce.at:1027: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 200. reduce.at:1627: testing lr.default-reduction=consistent ... ./reduce.at:1627: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./reduce.at:1296: sed 's,.*/$,,' stderr 1>&2 193. reduce.at:1027: ok ./reduce.at:1627: sed -n '/^State 0$/,$p' input.output ./reduce.at:1627: sed -n '/^State 0$/,$p' input.output ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error ./reduce.at:1627: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 203. report.at:3123: testing Reports with conflicts ... ./reduce.at:1627: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 201. reduce.at:1627: testing lr.default-reduction=accepting ... ./reduce.at:1627: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y 203. report.at:3123: ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none 202. report.at:37: testing Reports ... skipped (report.at:3132) 204. conflicts.at:28: testing Token declaration order ... 202. report.at:37: ./conflicts.at:81: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y skipped (report.at:75) ./reduce.at:1627: sed -n '/^State 0$/,$p' input.output ./reduce.at:1627: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./reduce.at:1296: sed -n '/^State 0$/,$p' input.output 206. conflicts.at:183: testing Useless associativity warning ... ./conflicts.at:82: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wprecedence input.y stderr: stdout: ./reduce.at:1296: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:1627: $PREPARSER ./input 205. conflicts.at:101: testing Token declaration order: literals vs. identifiers ... stderr: ./reduce.at:1627: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: ./conflicts.at:130: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all -o input.c input.y 198. reduce.at:1627: ok ./output.at:835: $CXX $CPPFLAGS $CXXFLAGS -Iout/ $LDFLAGS -o parser out/x[12].o main.cc $LIBS stderr: stdout: ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./reduce.at:1296: $PREPARSER ./input stderr: stdout: ./reduce.at:1296: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./reduce.at:1296: $PREPARSER ./input ./reduce.at:1296: sed -n '/^State 0$/,$p' input.output 196. reduce.at:1296: ok stderr: ./reduce.at:1296: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./conflicts.at:131: cat input.output | sed -n '/^State 0$/,/^State 1$/p' ./reduce.at:1296: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./reduce.at:1627: $PREPARSER ./input stderr: 197. reduce.at:1296: ./reduce.at:1627: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ok ./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence input.y -Werror 208. conflicts.at:275: testing S/R in initial ... ./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 207. conflicts.at:218: testing Useless precedence warning ... ./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y 205. conflicts.at:101: 200. reduce.at:1627: ok ok stderr: stdout: ./reduce.at:1627: $PREPARSER ./input stderr: 209. conflicts.at:301: testing %nonassoc and eof ... ./conflicts.at:368: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./reduce.at:1627: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y -Werror ./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror stderr: stderr: stdout: input.y:2.1-9: error: useless precedence and associativity for "=" [-Werror=precedence] input.y:4.1-5: error: useless associativity for "*", use %precedence [-Werror=precedence] input.y:5.1-11: error: useless precedence for "(" [-Werror=precedence] 199. reduce.at:1627: ok ./conflicts.at:84: $PREPARSER ./input stderr: ./conflicts.at:84: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:205: sed 's,.*/$,,' stderr 1>&2 stderr: stdout: ./reduce.at:1627: $PREPARSER ./input 204. conflicts.at:28: ok stderr: stderr: 210. conflicts.at:509: testing parse.error=verbose and consistent errors: lr.type=ielr ... input.y:4.10-15: error: rule useless in parser due to conflicts [-Werror=other] ./reduce.at:1627: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:509: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:368: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 201. reduce.at:1627: ok 212. conflicts.at:518: testing parse.error=verbose and consistent errors: lr.type=ielr c++ ... stderr: 211. conflicts.at:513: testing parse.error=verbose and consistent errors: lr.type=ielr %glr-parser ... ./conflicts.at:513: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:518: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./conflicts.at:284: sed 's,.*/$,,' stderr 1>&2 stdout: ./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence input.y --warnings=error ./reduce.at:1296: $PREPARSER ./input stderr: ./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error stderr: input.y:7.1-9: error: useless precedence and associativity for U [-Werror=precedence] 7 | %nonassoc U | ^~~~~~~~~ input.y:6.1-6: error: useless precedence and associativity for V [-Werror=precedence] 6 | %right V | ^~~~~~ input.y:5.1-5: error: useless precedence and associativity for W [-Werror=precedence] 5 | %left W | ^~~~~ input.y:2.1-11: error: useless precedence for Z [-Werror=precedence] 2 | %precedence Z | ^~~~~~~~~~~ syntax error ./reduce.at:1296: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:248: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:509: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 194. reduce.at:1296: ok ./conflicts.at:518: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./conflicts.at:513: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 213. conflicts.at:523: testing parse.error=verbose and consistent errors: lr.type=ielr java ... ./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence input.y -Wnone,none -Werror --trace=none ./conflicts.at:523: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.java input.y ./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none stderr: stdout: ./reduce.at:1296: $PREPARSER ./input ./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y --warnings=error stderr: 214. conflicts.at:530: testing parse.error=verbose and consistent errors: lr.type=ielr lr.default-reduction=consistent ... ./conflicts.at:530: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y syntax error ./reduce.at:1296: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 215. conflicts.at:535: testing parse.error=verbose and consistent errors: lr.type=ielr lr.default-reduction=accepting ... ./conflicts.at:535: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none ./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence input.y --warnings=none -Werror --trace=none 213. conflicts.at:523: 195. reduce.at:1296: ok ./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y -Wnone,none -Werror --trace=none skipped (conflicts.at:523) ./conflicts.at:530: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:535: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o input.c input.y 206. conflicts.at:183: ok 216. conflicts.at:540: testing parse.error=verbose and consistent errors: lr.type=canonical-lr ... ./conflicts.at:540: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y --warnings=none -Werror --trace=none 217. conflicts.at:546: testing parse.error=verbose and consistent errors: lr.type=canonical-lr parse.lac=full ... ./conflicts.at:546: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Werror 207. conflicts.at:218: ./conflicts.at:540: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ok stderr: input.y:4.10-15: error: rule useless in parser due to conflicts [-Werror=other] 4 | e: 'e' | %empty; | ^~~~~~ stderr: stdout: ./conflicts.at:546: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 218. conflicts.at:551: testing parse.error=verbose and consistent errors: lr.type=ielr parse.lac=full ... ./conflicts.at:368: $PREPARSER ./input '0<0' ./conflicts.at:551: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:288: sed 's,.*/$,,' stderr 1>&2 stderr: ./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 219. conflicts.at:558: testing parse.error=verbose and consistent errors: c++ lr.type=canonical-lr parse.lac=full ... ./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=error ./conflicts.at:368: $PREPARSER ./input '0<0<0' ./conflicts.at:558: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./conflicts.at:551: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: syntax error, unexpected '<' ./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./conflicts.at:509: $PREPARSER ./input ./conflicts.at:368: $PREPARSER ./input '0>0' stderr: stderr: ./conflicts.at:558: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Wnone,none -Werror --trace=none syntax error, unexpected end of file ./conflicts.at:509: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./conflicts.at:368: $PREPARSER ./input '0>0>0' stdout: ./conflicts.at:535: $PREPARSER ./input ./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=none -Werror --trace=none stderr: syntax error, unexpected end of file, expecting 'a' or 'b' stderr: ./conflicts.at:535: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected '>' 210. conflicts.at:509: ok ./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./conflicts.at:530: $PREPARSER ./input stderr: syntax error, unexpected end of file, expecting 'a' or 'b' ./conflicts.at:530: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 215. conflicts.at:535: ok 214. conflicts.at:530: ok ./conflicts.at:368: $PREPARSER ./input '0<0>0' stderr: syntax error, unexpected '>' ./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 208. conflicts.at:275: ok ./conflicts.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.default-reduction=consistent -o input.c input.y 221. conflicts.at:622: testing parse.error=verbose and consistent errors: ... ./conflicts.at:622: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 222. conflicts.at:626: testing parse.error=verbose and consistent errors: %glr-parser ... ./conflicts.at:626: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: 220. conflicts.at:564: testing parse.error=verbose and consistent errors: c++ lr.type=ielr parse.lac=full ... ./conflicts.at:564: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stdout: ./conflicts.at:540: $PREPARSER ./input ./conflicts.at:626: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./conflicts.at:564: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./conflicts.at:372: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./output.at:836: $PREPARSER ./parser syntax error, unexpected end of file, expecting 'a' or 'b' ./conflicts.at:540: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:622: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./output.at:836: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 223. conflicts.at:632: testing parse.error=verbose and consistent errors: lr.default-reduction=consistent ... ./conflicts.at:632: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: 144. output.at:744: ok stdout: ./conflicts.at:546: $PREPARSER ./input 216. conflicts.at:540: ok stderr: syntax error, unexpected end of file, expecting 'b' ./conflicts.at:546: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:632: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 217. conflicts.at:546: ok 224. conflicts.at:638: testing parse.error=verbose and consistent errors: lr.default-reduction=accepting ... stderr: ./conflicts.at:638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stdout: 225. conflicts.at:642: testing parse.error=verbose and consistent errors: lr.type=canonical-lr ... ./conflicts.at:551: $PREPARSER ./input ./conflicts.at:642: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: syntax error, unexpected end of file, expecting 'b' ./conflicts.at:551: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:638: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./conflicts.at:642: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: 218. conflicts.at:551: ok ./conflicts.at:513: $PREPARSER ./input 226. conflicts.at:647: testing parse.error=verbose and consistent errors: parse.lac=full ... ./conflicts.at:647: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: ./conflicts.at:372: $PREPARSER ./input '0<0' stderr: syntax error, unexpected end of file stderr: ./conflicts.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:513: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:372: $PREPARSER ./input '0<0<0' stderr: 211. conflicts.at:513: ok syntax error, unexpected '<', expecting end of file ./conflicts.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:647: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:372: $PREPARSER ./input '0>0' stderr: ./conflicts.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./conflicts.at:372: $PREPARSER ./input '0>0>0' stderr: ./conflicts.at:622: $PREPARSER ./input syntax error, unexpected '>', expecting end of file ./conflicts.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 227. conflicts.at:651: testing parse.error=verbose and consistent errors: parse.lac=full lr.default-reduction=accepting ... ./conflicts.at:372: $PREPARSER ./input '0<0>0' stderr: stderr: syntax error, unexpected '>', expecting end of file ./conflicts.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:651: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y syntax error, unexpected 'b' ./conflicts.at:622: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:381: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y 228. conflicts.at:676: testing LAC: %nonassoc requires splitting canonical LR states ... ./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y 221. conflicts.at:622: ok ./conflicts.at:651: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:381: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y -Werror stderr: stdout: ./conflicts.at:638: $PREPARSER ./input stderr: 229. conflicts.at:764: testing Unresolved SR Conflicts ... ./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c --report=all input.y syntax error, unexpected end of file, expecting 'a' ./conflicts.at:638: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input.y: error: 2 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stdout: 224. conflicts.at:638: ok ./conflicts.at:726: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:632: $PREPARSER ./input ./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y -Werror stderr: syntax error, unexpected 'b' ./conflicts.at:632: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y --warnings=error stderr: input.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./conflicts.at:774: sed 's,.*/$,,' stderr 1>&2 223. conflicts.at:632: ok ./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y -Wnone,none -Werror --trace=none ./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y --warnings=error stderr: stdout: 230. conflicts.at:887: testing Resolved SR Conflicts ... ./conflicts.at:626: $PREPARSER ./input stderr: ./conflicts.at:898: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c --report=all input.y syntax error, unexpected 'b' ./conflicts.at:626: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y --warnings=none -Werror --trace=none stderr: ./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y -Wnone,none -Werror --trace=none stdout: ./conflicts.at:647: $PREPARSER ./input stderr: 222. conflicts.at:626: ok syntax error, unexpected 'b' ./conflicts.at:647: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 231. conflicts.at:989: testing %precedence suffices ... ./conflicts.at:1006: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:901: cat input.output 226. conflicts.at:647: ok ./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y --warnings=none -Werror --trace=none stderr: stdout: ./conflicts.at:642: $PREPARSER ./input 230. conflicts.at:887: ok stderr: stderr: stdout: ./conflicts.at:651: $PREPARSER ./input syntax error, unexpected end of file, expecting 'a' ./conflicts.at:642: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected end of file ./conflicts.at:651: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:731: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 231. conflicts.at:989: ok 227. conflicts.at:651: ok 232. conflicts.at:1015: testing %precedence does not suffice ... ./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: ./conflicts.at:518: $PREPARSER ./input stderr: ./conflicts.at:780: cat input.output stderr: stdout: syntax error, unexpected end of file ./conflicts.at:518: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:381: $PREPARSER ./input '0<0' stderr: ./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 212. conflicts.at:518: ok ./conflicts.at:381: $PREPARSER ./input '0<0<0' 233. conflicts.at:1096: testing Syntax error in consistent error state: yacc.c ... 229. conflicts.at:764: ok stderr: ./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror syntax error, unexpected '<', expecting end of file ./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 225. conflicts.at:642: ok 235. conflicts.at:1096: testing Syntax error in consistent error state: lalr1.cc ... ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 234. conflicts.at:1096: testing Syntax error in consistent error state: glr.c ... ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:381: $PREPARSER ./input '0>0' stderr: ./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 236. conflicts.at:1096: testing Syntax error in consistent error state: glr.cc ... ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Werror ./conflicts.at:381: $PREPARSER ./input '0>0>0' ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror stderr: 237. conflicts.at:1096: testing Syntax error in consistent error state: glr2.cc ... ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y syntax error, unexpected '>', expecting end of file ./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Werror ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror 239. conflicts.at:1264: testing %expect not enough ... ./conflicts.at:1273: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y stderr: input.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:12.3-18: error: rule useless in parser due to conflicts [-Werror=other] stderr: input.y:17.5-25: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.5-29: error: rule useless in parser due to conflicts [-Werror=other] ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Werror ./conflicts.at:381: $PREPARSER ./input '0<0>0' ./conflicts.at:1033: sed 's,.*/$,,' stderr 1>&2 stderr: input.y:17.5-25: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.5-29: error: rule useless in parser due to conflicts [-Werror=other] ./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 238. conflicts.at:1127: testing Defaulted Conflicted Reduction ... ./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c --report=all input.y 239. conflicts.at:1264: ok stderr: stderr: input.y:17.5-25: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.5-29: error: rule useless in parser due to conflicts [-Werror=other] syntax error, unexpected '>', expecting end of file ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error ./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 input.y:17.5-25: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.5-29: error: rule useless in parser due to conflicts [-Werror=other] ./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error stderr: input.y:17.5-25: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.5-29: error: rule useless in parser due to conflicts [-Werror=other] ./conflicts.at:388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -o input.c input.y ./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y -Werror ./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=error ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=error 240. conflicts.at:1284: testing %expect right ... ./conflicts.at:388: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:1293: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error stderr: input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:4.6-8: error: rule useless in parser due to conflicts [-Werror=other] ./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=error ./conflicts.at:1138: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Wnone,none -Werror --trace=none ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Wnone,none -Werror --trace=none stderr: stdout: ./conflicts.at:732: $PREPARSER ./input stderr: syntax error, unexpected 'a', expecting 'b' ./conflicts.at:732: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none ./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ -o input.c input.y 240. conflicts.at:1284: ok ./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y --warnings=error ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=none -Werror --trace=none ./conflicts.at:1096: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y -Wnone,none -Werror --trace=none ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Wnone,none -Werror --trace=none ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=none -Werror --trace=none ./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none ./conflicts.at:1096: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ -o input.c input.y -Werror 241. conflicts.at:1301: testing %expect too much ... ./conflicts.at:1310: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y --warnings=none -Werror --trace=none ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=none -Werror --trace=none 241. conflicts.at:1301: ok ./conflicts.at:1096: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./conflicts.at:1096: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 232. conflicts.at:1015: ok stderr: input.y: error: 2 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./conflicts.at:737: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:1145: cat input.output 242. conflicts.at:1321: testing %expect with reduce conflicts ... ./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ -o input.c input.y --warnings=error 243. conflicts.at:1341: testing %expect in grammar rule not enough ... ./conflicts.at:1350: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:1330: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:1096: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 238. conflicts.at:1127: ok 242. conflicts.at:1321: ok 243. conflicts.at:1341: ok ./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ -o input.c input.y -Wnone,none -Werror --trace=none 244. conflicts.at:1360: testing %expect in grammar rule right ... ./conflicts.at:1369: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 244. conflicts.at:1360: ok stderr: stderr: stdout: stdout: ./conflicts.at:388: $PREPARSER ./input '0<0' stderr: ./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 245. conflicts.at:1377: testing %expect in grammar rules ... ./conflicts.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -rall input.y ./conflicts.at:558: $PREPARSER ./input 246. conflicts.at:1396: testing %expect in grammar rule too much ... ./conflicts.at:388: $PREPARSER ./input '0<0<0' ./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ -o input.c input.y --warnings=none -Werror --trace=none stderr: ./conflicts.at:1405: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y stderr: syntax error, unexpected end of file, expecting 'b' ./conflicts.at:558: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected '<', expecting end of file ./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 245. conflicts.at:1377: ok ./conflicts.at:388: $PREPARSER ./input '0>0' 246. conflicts.at:1396: ok ./conflicts.at:742: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 219. conflicts.at:558: ok stderr: ./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 247. conflicts.at:1415: testing %expect-rr in grammar rule ... ./conflicts.at:1432: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 247. conflicts.at:1415: ok ./conflicts.at:388: $PREPARSER ./input '0>0>0' stderr: syntax error, unexpected '>', expecting end of file ./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:388: $PREPARSER ./input '0<0>0' stderr: syntax error, unexpected '>', expecting end of file stderr: ./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 248. conflicts.at:1440: testing %expect-rr too much in grammar rule ... ./conflicts.at:1457: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y stdout: ./conflicts.at:564: $PREPARSER ./input stderr: syntax error, unexpected end of file, expecting 'b' 249. conflicts.at:1469: testing %expect-rr not enough in grammar rule ... ./conflicts.at:1486: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y ./conflicts.at:564: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 209. conflicts.at:301: ok 250. conflicts.at:1498: testing %prec with user string ... ./conflicts.at:1507: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 220. conflicts.at:564: ok 250. conflicts.at:1498: ok 248. conflicts.at:1440: ok 251. conflicts.at:1515: testing %no-default-prec without %prec ... ./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall -o input.c input.y stderr: 249. conflicts.at:1469: ok stdout: ./conflicts.at:1096: $PREPARSER ./input stderr: syntax error ./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 253. conflicts.at:1568: testing %default-prec ... 233. conflicts.at:1096: ok 252. conflicts.at:1544: testing %no-default-prec with %prec ... ./conflicts.at:1560: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:1584: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 254. conflicts.at:1592: testing Unreachable States After Conflict Resolution ... ./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all input.y 255. conflicts.at:1855: testing Solved conflicts report for multiple reductions in a state ... ./conflicts.at:1881: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all -o input.c input.y 252. conflicts.at:1544: ok 256. conflicts.at:1935: testing %nonassoc error actions for multiple reductions in a state ... ./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y 253. conflicts.at:1568: ok stderr: ./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y -Werror input.y:7.5-7: warning: rule useless in parser due to conflicts [-Wother] input.y:11.5-7: warning: rule useless in parser due to conflicts [-Wother] input.y:17.11-26: warning: rule useless in parser due to conflicts [-Wother] input.y:18.11-26: warning: rule useless in parser due to conflicts [-Wother] input.y:19.11-26: warning: rule useless in parser due to conflicts [-Wother] ./conflicts.at:1882: cat input.output | sed -n '/^State 0$/,/^State 1$/p' ./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y -Werror ./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=all input.y -Werror stderr: stderr: bison (GNU Bison) 3.8.2 init: 0.000000 # state items: 26 State 0: 0 $accept: . start $end -> 0 $accept: start . $end => 2 start: . empty_a 'a' => 4 start: . empty_b 'b' => 6 start: . empty_c1 'c' => 7 start: . empty_c2 'c' => 8 start: . empty_c3 'c' 1 start: . 'a' DISABLED 2 start: . empty_a 'a' -> 2 start: empty_a . 'a' => 9 empty_a: %empty . <- 0 $accept: . start $end 3 start: . 'b' DISABLED 4 start: . empty_b 'b' -> 4 start: empty_b . 'b' => 10 empty_b: %empty . <- 0 $accept: . start $end 5 start: . 'c' DISABLED 6 start: . empty_c1 'c' -> 6 start: empty_c1 . 'c' => 11 empty_c1: %empty . <- 0 $accept: . start $end 7 start: . empty_c2 'c' -> 7 start: empty_c2 . 'c' => 12 empty_c2: %empty . <- 0 $accept: . start $end 8 start: . empty_c3 'c' -> 8 start: empty_c3 . 'c' => 13 empty_c3: %empty . <- 0 $accept: . start $end 9 empty_a: %empty . <- 2 start: . empty_a 'a' 10 empty_b: %empty . <- 4 start: . empty_b 'b' 11 empty_c1: %empty . <- 6 start: . empty_c1 'c' 12 empty_c2: %empty . <- 7 start: . empty_c2 'c' 13 empty_c3: %empty . <- 8 start: . empty_c3 'c' State 1: 0 $accept: start . $end -> 0 $accept: start $end . <- 0 $accept: . start $end State 2: 2 start: empty_a . 'a' -> 2 start: empty_a 'a' . <- 2 start: . empty_a 'a' State 3: 4 start: empty_b . 'b' -> 4 start: empty_b 'b' . <- 4 start: . empty_b 'b' State 4: 6 start: empty_c1 . 'c' -> 6 start: empty_c1 'c' . <- 6 start: . empty_c1 'c' State 5: 7 start: empty_c2 . 'c' -> 7 start: empty_c2 'c' . <- 7 start: . empty_c2 'c' State 6: 8 start: empty_c3 . 'c' -> 8 start: empty_c3 'c' . <- 8 start: . empty_c3 'c' State 7: 0 $accept: start $end . <- 0 $accept: start . $end State 8: 2 start: empty_a 'a' . <- 2 start: empty_a . 'a' State 9: 4 start: empty_b 'b' . <- 4 start: empty_b . 'b' State 10: 6 start: empty_c1 'c' . <- 6 start: empty_c1 . 'c' State 11: 7 start: empty_c2 'c' . <- 7 start: empty_c2 . 'c' State 12: 8 start: empty_c3 'c' . <- 8 start: empty_c3 . 'c' FIRSTS $accept firsts 'a' 'b' 'c' start firsts 'a' 'b' 'c' empty_a firsts empty_b firsts empty_c1 firsts empty_c2 firsts empty_c3 firsts input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:4.5-7: error: rule useless in parser due to conflicts [-Werror=other] 4 | 'a' | ^~~ input.y:6.5-7: error: rule useless in parser due to conflicts [-Werror=other] 6 | | 'b' | ^~~ input.y:8.5-7: error: rule useless in parser due to conflicts [-Werror=other] 8 | | 'c' | ^~~ input.y:13.10-18: error: rule useless in parser due to conflicts [-Werror=other] 13 | empty_a: %prec 'a' ; | ^~~~~~~~~ input.y:14.10-18: error: rule useless in parser due to conflicts [-Werror=other] 14 | empty_b: %prec 'b' ; | ^~~~~~~~~ input.y:15.11-19: error: rule useless in parser due to conflicts [-Werror=other] 15 | empty_c1: %prec 'c' ; | ^~~~~~~~~ input.y:16.11-19: error: rule useless in parser due to conflicts [-Werror=other] 16 | empty_c2: %prec 'c' ; | ^~~~~~~~~ input.y:17.11-19: error: rule useless in parser due to conflicts [-Werror=other] 17 | empty_c3: %prec 'c' ; | ^~~~~~~~~ REDUCE ITEM PATH: 0 $accept: . start $end 7 start: . empty_c2 'c' 12 empty_c2: %empty . CONFLICT 1 (size 1 depth 0 rc 2) 12 empty_c2: %empty . 12 empty_c2: %empty . . CONFLICT 2 (size 1 depth 0 rc 2) 13 empty_c3: %empty . 13 empty_c3: %empty . . CONFLICT 1 (size 2 depth -1 rc 4) 7 start: . empty_c2 'c' 7 start: empty_c2 . 'c' empty_c2 `-> 12: %empty . CONFLICT 2 (size 1 depth 0 rc 3) 13 empty_c3: %empty . 13 empty_c3: %empty . . CONFLICT 1 (size 1 depth 0 rc 3) 12 empty_c2: %empty . 12 empty_c2: %empty . . CONFLICT 2 (size 2 depth -1 rc 2) 8 start: . empty_c3 'c' 8 start: empty_c3 . 'c' empty_c3 `-> 13: %empty . CONFLICT 1 (size 2 depth -1 rc 3) 7 start: . empty_c2 'c' 7 start: empty_c2 . 'c' empty_c2 `-> 12: %empty . CONFLICT 2 (size 2 depth -1 rc 2) 8 start: . empty_c3 'c' 8 start: empty_c3 . 'c' empty_c3 `-> 13: %empty . CONFLICT 1 (size 3 depth -1 rc 2) 7 start: . empty_c2 'c' 7 start: empty_c2 'c' . empty_c2 `-> 12: %empty . CONFLICT 2 (size 3 depth -1 rc 2) 8 start: . empty_c3 'c' 8 start: empty_c3 'c' . empty_c3 `-> 13: %empty . CONFLICT 1 (size 2 depth -1 rc 4) 0 $accept: . start $end 0 $accept: start . $end start `-> 7: empty_c2 'c' `-> 12: %empty . CONFLICT 2 (size 3 depth -1 rc 3) 8 start: . empty_c3 'c' 8 start: empty_c3 'c' . empty_c3 `-> 13: %empty . CONFLICT 1 (size 3 depth -1 rc 3) 7 start: . empty_c2 'c' 7 start: empty_c2 'c' . empty_c2 `-> 12: %empty . CONFLICT 2 (size 2 depth -1 rc 2) 0 $accept: . start $end 0 $accept: start . $end start `-> 8: empty_c3 'c' `-> 13: %empty . CONFLICT 1 (size 2 depth -1 rc 3) 0 $accept: . start $end 0 $accept: start . $end start `-> 7: empty_c2 'c' `-> 12: %empty . CONFLICT 2 (size 2 depth -1 rc 2) 0 $accept: . start $end 0 $accept: start . $end start `-> 8: empty_c3 'c' `-> 13: %empty . 257. conflicts.at:2299: testing %expect-rr non GLR ... ./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret 1.y 255. conflicts.at:1855: ok input.y: error: 4 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:1.1-5: error: useless precedence and associativity for '+' [-Werror=precedence] input.y:2.1-5: error: useless precedence and associativity for '*' [-Werror=precedence] stderr: input.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:12.5-20: error: rule useless in parser due to conflicts [-Werror=other] input.y:20.5-20: error: rule useless in parser due to conflicts [-Werror=other] input.y:21.4: error: rule useless in parser due to conflicts [-Werror=other] input.y:25.14: error: rule useless in parser due to conflicts [-Werror=other] input.y:25.16: error: rule useless in parser due to conflicts [-Werror=other] input.y:31.5-7: error: rule useless in parser due to conflicts [-Werror=other] input.y:32.4: error: rule useless in parser due to conflicts [-Werror=other] ./conflicts.at:1531: sed 's,.*/$,,' stderr 1>&2 258. conflicts.at:2331: testing -W versus %expect and %expect-rr ... ./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret sr-rr.y ./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y --warnings=error 259. counterexample.at:43: testing Unifying S/R ... ./counterexample.at:55: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:1638: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=all input.y --warnings=error stderr: stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: A . B C Shift derivation s `-> 2: y c `-> 8: A . B `-> 4: C Reduce derivation s `-> 1: a x `-> 3: A . `-> 6: B C input.y:4.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:55: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr stdout: ./conflicts.at:1959: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:743: $PREPARSER ./input stderr: syntax error, unexpected 'a', expecting 'b' or 'c' ./conflicts.at:743: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./counterexample.at:55: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret sr-rr.y -Werror ./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y ./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y -Wnone,none -Werror --trace=none ./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y --warnings=error ./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y -Werror 260. counterexample.at:83: testing Deep Unifying S/R ... ./counterexample.at:95: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=all input.y -Wnone,none -Werror --trace=none stderr: ./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y -Wnone,none -Werror --trace=none input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example A . B C Shift derivation s -> [ y -> [ A . B ] c -> [ C ] ] Reduce derivation s -> [ a -> [ A . ] x -> [ B C ] ] input.y:4.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:55: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr stderr: stderr: sr-rr.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] sr-rr.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] sr-rr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples 1.y: error: %expect-rr applies only to GLR parsers [-Werror=other] ./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y --warnings=none -Werror --trace=none ./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=all input.y --warnings=none -Werror --trace=none stderr: ./conflicts.at:2354: sed 's,.*/$,,' stderr 1>&2 input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: A . B C Shift derivation s `-> 1: ac `-> 3: A ac C `-> 4: b `-> 5: . B Reduce derivation s `-> 2: a bc `-> 7: A . `-> 10: B C input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: A A . B B C C Shift derivation s `-> 1: ac `-> 3: A ac C `-> 3: A ac C `-> 4: b `-> 6: . b `-> 5: B B Reduce derivation s `-> 2: a bc `-> 8: A a `-> 9: B bc C `-> 7: A . `-> 10: B C input.y:6.4: warning: rule useless in parser due to conflicts [-Wother] ./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y --warnings=none -Werror --trace=none ./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y -Werror 259. counterexample.at:43: ok ./conflicts.at:2307: sed 's,.*/$,,' stderr 1>&2 ./counterexample.at:95: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret sr-rr.y --warnings=error stderr: input.y: error: 2 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples 251. conflicts.at:1515: ./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y --warnings=error ok ./counterexample.at:95: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:748: sed 's,.*/$,,' stderr 1>&2 261. counterexample.at:144: testing S/R Conflict with Nullable Symbols ... ./counterexample.at:157: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:2239: cat input.output | sed -n '/^State 0$/,/^State 1$/p' ./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y --warnings=error ./conflicts.at:1651: cat input.output 256. conflicts.at:1935: ok ./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret sr-rr.y -Wnone,none -Werror --trace=none stderr: stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example A . B C Shift derivation s -> [ ac -> [ A ac -> [ b -> [ . B ] ] C ] ] Reduce derivation s -> [ a -> [ A . ] bc -> [ B C ] ] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example A A . B B C C Shift derivation s -> [ ac -> [ A ac -> [ A ac -> [ b -> [ . b -> [ B B ] ] ] C ] C ] ] Reduce derivation s -> [ a -> [ A a -> [ A . ] ] bc -> [ B bc -> [ B C ] C ] ] input.y:6.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:95: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr stdout: ./conflicts.at:1096: $PREPARSER ./input 260. counterexample.at:83: ok stderr: ./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y -Wnone,none -Werror --trace=none syntax error ./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./conflicts.at:1836: cat input.y >> input-keep.y input.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: A . B Shift derivation s `-> 2: A xby `-> 9: . B Reduce derivation s `-> 1: ax by `-> 3: A x `-> 6: B y `-> 4: %empty . `-> 6: %empty input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] First example: A X . B Y $end Shift derivation $accept `-> 0: s $end `-> 2: A xby `-> 10: X xby Y `-> 9: . B Second example: A X . B y $end Reduce derivation $accept `-> 0: s $end `-> 1: ax by `-> 3: A x `-> 6: B y `-> 5: X x `-> 4: %empty . input.y:5.4-9: warning: rule useless in parser due to conflicts [-Wother] 262. counterexample.at:207: testing Non-unifying Ambiguous S/R ... ./counterexample.at:157: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr 263. counterexample.at:254: testing Non-unifying Unambiguous S/R ... ./counterexample.at:220: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y -Wnone,none -Werror --trace=none ./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret sr-rr.y --warnings=none -Werror --trace=none ./counterexample.at:265: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input-keep.y 234. conflicts.at:1096: ok ./counterexample.at:157: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] First example: A . A B $end Shift derivation $accept `-> 0: s $end `-> 1: t `-> 4: y `-> 6: A . A B Second example: A . A $end Reduce derivation $accept `-> 0: s $end `-> 2: s t `-> 1: t `-> 3: x `-> 3: x `-> 5: A `-> 5: A . ./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y --warnings=none -Werror --trace=none ./counterexample.at:265: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr stderr: ./counterexample.at:265: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: 264. counterexample.at:298: testing S/R after first token ... ./counterexample.at:314: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y input.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example A . B Shift derivation s -> [ A xby -> [ . B ] ] Reduce derivation s -> [ ax -> [ A x -> [ . ] ] by -> [ B y -> [ ] ] ] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] First example A X . B Y $end Shift derivation $accept -> [ s -> [ A xby -> [ X xby -> [ . B ] Y ] ] $end ] Second example A X . B y $end Reduce derivation $accept -> [ s -> [ ax -> [ A x -> [ X x -> [ . ] ] ] by -> [ B y ] ] $end ] input.y:5.4-9: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:157: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token C [-Wcounterexamples] First example: B . C $end Shift derivation $accept `-> 0: g $end `-> 2: x `-> 6: bc `-> 9: B . C Second example: B . C D $end Reduce derivation $accept `-> 0: g $end `-> 2: x `-> 5: b cd `-> 7: B . `-> 8: C D input.y:6.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:220: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./counterexample.at:220: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y --warnings=none -Werror --trace=none 265. counterexample.at:363: testing Unifying R/R counterexample ... ./counterexample.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 261. counterexample.at:144: ok ./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y ./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret 2.y ./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-keep.y -Werror stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] First example A . A B $end Shift derivation $accept -> [ s -> [ t -> [ y -> [ A . A B ] ] ] $end ] Second example A . A $end Reduce derivation $accept -> [ s -> [ s -> [ t -> [ x -> [ A . ] ] ] t -> [ x -> [ A ] ] ] $end ] ./counterexample.at:265: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr stderr: 263. counterexample.at:254: ok stderr: input.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] Example: A b . First reduce derivation a `-> 1: A b . Second reduce derivation a `-> 1: A b `-> 3: b . input.y:4.9: warning: rule useless in parser due to conflicts [-Wother] stderr: ./counterexample.at:372: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token C [-Wcounterexamples] First example B . C $end Shift derivation $accept -> [ g -> [ x -> [ bc -> [ B . C ] ] ] $end ] Second example B . C D $end Reduce derivation $accept -> [ g -> [ x -> [ b -> [ B . ] cd -> [ C D ] ] ] $end ] input.y:6.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:220: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr input.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] Example: b . A X X Y Shift derivation a `-> 2: s `-> 7: b . xx y `-> 9: A X X `-> 11: Y Reduce derivation a `-> 1: r t `-> 3: b . `-> 6: A x xy `-> 8: X `-> 10: X Y input.y: warning: shift/reduce conflict on token X [-Wcounterexamples] First example: A X . X Shift derivation a `-> 1: t `-> 5: A xx `-> 9: X . X Second example: X . X xy Reduce derivation a `-> 1: x t `-> 8: X . `-> 6: X xy input.y:4.4: warning: rule useless in parser due to conflicts [-Wother] input.y:8.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:314: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./conflicts.at:753: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./counterexample.at:372: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: ./counterexample.at:314: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y input-keep.y: error: 2 shift/reduce conflicts [-Werror=conflicts-sr] input-keep.y: error: 2 reduce/reduce conflicts [-Werror=conflicts-rr] input-keep.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input-keep.y:22.4: error: rule useless in parser due to conflicts [-Werror=other] input-keep.y:26.16: error: rule useless in parser due to conflicts [-Werror=other] input-keep.y:32.5-7: error: rule useless in parser due to conflicts [-Werror=other] input-keep.y:33.4: error: rule useless in parser due to conflicts [-Werror=other] 262. counterexample.at:207: ok ./conflicts.at:1838: sed 's,.*/$,,' stderr 1>&2 266. counterexample.at:399: testing Non-unifying R/R LR(1) conflict ... ./counterexample.at:409: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 2.y -Werror ./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y -Werror stderr: input.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] Example A b . First reduce derivation a -> [ A b . ] Second reduce derivation a -> [ A b -> [ b . ] ] input.y:4.9: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:372: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr 267. counterexample.at:441: testing Non-unifying R/R LR(2) conflict ... ./counterexample.at:451: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-keep.y --warnings=error stderr: input.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] Example b . A X X Y Shift derivation a -> [ s -> [ b . xx -> [ A X X ] y -> [ Y ] ] ] Reduce derivation a -> [ r -> [ b . ] t -> [ A x -> [ X ] xy -> [ X Y ] ] ] input.y: warning: shift/reduce conflict on token X [-Wcounterexamples] First example A X . X Shift derivation a -> [ t -> [ A xx -> [ X . X ] ] ] Second example X . X xy Reduce derivation a -> [ x -> [ X . ] t -> [ X xy ] ] input.y:4.4: warning: rule useless in parser due to conflicts [-Wother] input.y:8.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:314: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr 265. counterexample.at:363: ok 264. counterexample.at:298: ok stderr: input.y: warning: 2 reduce/reduce conflicts [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on tokens A, C [-Wcounterexamples] First example: D . A $end First reduce derivation $accept `-> 0: s $end `-> 1: a A `-> 5: D . Second example: B D . A $end Second reduce derivation $accept `-> 0: s $end `-> 4: B b A `-> 6: D . input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:409: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./counterexample.at:409: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: sr-rr.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] sr-rr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stderr: ./conflicts.at:2359: sed 's,.*/$,,' stderr 1>&2 2.y: error: %expect-rr applies only to GLR parsers [-Werror=other] 2.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] 2.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples 2.y:3.12-14: error: rule useless in parser due to conflicts [-Werror=other] 268. counterexample.at:488: testing Cex Search Prepend ... ./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y --warnings=error ./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-keep.y -Wnone,none -Werror --trace=none ./counterexample.at:499: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:2317: sed 's,.*/$,,' stderr 1>&2 stderr: input.y: warning: 2 reduce/reduce conflicts [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on tokens A, C [-Wcounterexamples] First example D . A $end First reduce derivation $accept -> [ s -> [ a -> [ D . ] A ] $end ] Second example B D . A $end Second reduce derivation $accept -> [ s -> [ B b -> [ D . ] A ] $end ] input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:409: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr 269. counterexample.at:550: testing R/R cex with prec ... ./counterexample.at:562: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 266. counterexample.at:399: ok ./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 2.y --warnings=error ./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y -Wnone,none -Werror --trace=none stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: N A . B C Shift derivation s `-> 1: n `-> 6: N b `-> 8: A . B C Reduce derivation s `-> 2: n C `-> 5: N a B `-> 7: A . input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: N N A . B D C Shift derivation s `-> 1: n `-> 4: N n C `-> 6: N b `-> 9: A . B D Reduce derivation s `-> 2: n C `-> 3: N n D `-> 5: N a B `-> 7: A . input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:499: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-keep.y --warnings=none -Werror --trace=none ./counterexample.at:499: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 270. counterexample.at:610: testing Null nonterminals ... ./counterexample.at:621: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example N A . B C Shift derivation s -> [ n -> [ N b -> [ A . B C ] ] ] Reduce derivation s -> [ n -> [ N a -> [ A . ] B ] C ] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example N N A . B D C Shift derivation s -> [ n -> [ N n -> [ N b -> [ A . B D ] ] C ] ] Reduce derivation s -> [ n -> [ N n -> [ N a -> [ A . ] B ] D ] C ] input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:499: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr ./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 2.y -Wnone,none -Werror --trace=none ./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y --warnings=none -Werror --trace=none 254. conflicts.at:1592: ok 271. counterexample.at:797: testing Non-unifying Prefix Share ... ./counterexample.at:810: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 268. counterexample.at:488: ok stderr: input.y: warning: 4 reduce/reduce conflicts [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on tokens b, c [-Wcounterexamples] Example: B . b c First reduce derivation S `-> 1: B C `-> 6: A b A `-> 7: A c A `-> 3: B . `-> 6: %empty `-> 7: %empty `-> 7: %empty Second reduce derivation S `-> 1: B C `-> 7: A c A `-> 3: B `-> 7: %empty `-> 6: A b A `-> 5: %empty . `-> 6: %empty input.y: warning: reduce/reduce conflict on tokens b, c [-Wcounterexamples] Example: C . c b First reduce derivation S `-> 2: C B `-> 7: A c A `-> 6: A b A `-> 4: C . `-> 7: %empty `-> 6: %empty `-> 6: %empty Second reduce derivation S `-> 2: C B `-> 6: A b A `-> 4: C `-> 6: %empty `-> 7: A c A `-> 5: %empty . `-> 7: %empty ./counterexample.at:562: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 2.y --warnings=none -Werror --trace=none ./counterexample.at:562: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token J [-Wcounterexamples] Example: H i J . J J Shift derivation s `-> 2: a J `-> 3: H i J . J Reduce derivation s `-> 1: a `-> 3: H i J J `-> 5: i J . input.y:5.13-15: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:810: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./counterexample.at:810: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 257. conflicts.at:2299: ok 272. counterexample.at:842: testing Deep Null Unifying ... ./counterexample.at:854: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y stderr: input.y: warning: 4 reduce/reduce conflicts [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on tokens b, c [-Wcounterexamples] Example B . b c First reduce derivation S -> [ B -> [ A -> [ B . ] b A -> [ ] ] C -> [ A -> [ ] c A -> [ ] ] ] Second reduce derivation S -> [ B C -> [ A -> [ B -> [ A -> [ . ] b A -> [ ] ] ] c A -> [ ] ] ] input.y: warning: reduce/reduce conflict on tokens b, c [-Wcounterexamples] Example C . c b First reduce derivation S -> [ C -> [ A -> [ C . ] c A -> [ ] ] B -> [ A -> [ ] b A -> [ ] ] ] Second reduce derivation S -> [ C B -> [ A -> [ C -> [ A -> [ . ] c A -> [ ] ] ] b A -> [ ] ] ] ./counterexample.at:562: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token J [-Wcounterexamples] Example H i J . J J Shift derivation s -> [ a -> [ H i J . J ] J ] Reduce derivation s -> [ a -> [ H i -> [ i J . ] J J ] ] input.y:5.13-15: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:810: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr stderr: 271. counterexample.at:797: ok input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token D [-Wcounterexamples] Example: A a . D Shift derivation s `-> 1: A a d `-> 6: . D Reduce derivation s `-> 2: A a a d `-> 3: b `-> 6: D `-> 4: c `-> 5: %empty . ./counterexample.at:854: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr 269. counterexample.at:550: ok 273. counterexample.at:884: testing Deep Null Non-unifying ... ./counterexample.at:896: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 274. synclines.at:194: testing Prologue syncline ... ./synclines.at:194: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: ./counterexample.at:854: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stdout: ./conflicts.at:754: $PREPARSER ./input 275. synclines.at:214: testing %union syncline ... ./synclines.at:214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stderr: ./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y -Werror input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token D [-Wcounterexamples] First example: A a . D $end Shift derivation $accept `-> 0: s $end `-> 1: A a d `-> 6: . D Second example: A a . D E $end Reduce derivation $accept `-> 0: s $end `-> 2: A a a d E `-> 3: b `-> 6: D `-> 4: c `-> 5: %empty . ./counterexample.at:896: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr stderr: syntax error, unexpected 'a', expecting 'b' or 'c' ./counterexample.at:896: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./conflicts.at:754: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token D [-Wcounterexamples] Example A a . D Shift derivation s -> [ A a d -> [ . D ] ] Reduce derivation s -> [ A a a -> [ b -> [ c -> [ . ] ] ] d -> [ D ] ] ./counterexample.at:854: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr ./conflicts.at:1096: $PREPARSER ./input 228. conflicts.at:676: ok stderr: ./synclines.at:214: $CC $CFLAGS $CPPFLAGS -c syncline.c 272. counterexample.at:842: ok syntax error ./synclines.at:194: $CC $CFLAGS $CPPFLAGS -c syncline.c ./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:214: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF stderr: 276. synclines.at:237: testing %union name syncline ... input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token D [-Wcounterexamples] First example A a . D $end Shift derivation $accept -> [ s -> [ A a d -> [ . D ] ] $end ] Second example A a . D E $end Reduce derivation $accept -> [ s -> [ A a a -> [ b -> [ c -> [ . ] ] ] d -> [ D ] E ] $end ] ./counterexample.at:896: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr sr-rr.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] stdout: ./synclines.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ syncline.c:4: #error "4" ./synclines.at:214: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 273. counterexample.at:884: ok ./synclines.at:194: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF 235. conflicts.at:1096: ok ./conflicts.at:2363: sed 's,.*/$,,' stderr 1>&2 stdout: syncline.c:4: #error "4" ./synclines.at:194: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 277. synclines.at:264: testing Postprologue syncline ... ./synclines.at:194: $CC $CFLAGS $CPPFLAGS -c input.c ./synclines.at:214: $CC $CFLAGS $CPPFLAGS -c input.c ./synclines.at:264: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y --warnings=error ./synclines.at:254: $CC $CFLAGS $CPPFLAGS -c syncline.c 278. synclines.at:291: testing Action syncline ... ./synclines.at:291: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: input.y:2:2: error: #error "2" 2 | #error "2" | ^~~~~ stderr: stderr: ./synclines.at:214: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF input.y:2:2: error: #error "2" 2 | #error "2" | ^~~~~ syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:194: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF ./synclines.at:254: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF stdout: input.y:2: #error "2" ./synclines.at:194: cat stdout stdout: stdout: input.y:2: #error "2" syncline.c:4: #error "4" ./synclines.at:264: $CC $CFLAGS $CPPFLAGS -c syncline.c ./synclines.at:254: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 274. synclines.at:194: ok ./synclines.at:214: cat stdout ./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y -Wnone,none -Werror --trace=none 279. synclines.at:310: testing Epilogue syncline ... ./synclines.at:310: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 280. synclines.at:327: testing %code top syncline ... ./synclines.at:254: $CC $CFLAGS $CPPFLAGS -c input.c 275. synclines.at:214: ok stderr: syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:264: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF ./synclines.at:327: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./synclines.at:291: $CC $CFLAGS $CPPFLAGS -c syncline.c ./synclines.at:310: $CC $CFLAGS $CPPFLAGS -c syncline.c stderr: syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:291: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF stdout: syncline.c:4: #error "4" stderr: ./synclines.at:264: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:310: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF ./synclines.at:264: $CC $CFLAGS $CPPFLAGS -c input.c ./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y --warnings=none -Werror --trace=none stdout: syncline.c:4: #error "4" ./synclines.at:310: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 ./synclines.at:327: $CC $CFLAGS $CPPFLAGS -c syncline.c stderr: input.y:1:7: error: expected '{' before 'break' 1 | %union break | ^~~~~ input.y:1:15: error: expected '{' before 'break' 1 | %union break | ^ input.y:7:8: error: unknown type name 'YYSTYPE' 7 | int yylex (void); | ^~~~~~~ input.y:8:1: error: expected identifier or '(' before '%' token 8 | %} | ^ input.c:273:9: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 273 | typedef yytype_int8 yy_state_t; | ^~~~~~~~~~~ | yytype_uint8 input.c:429:3: error: unknown type name 'YYSTYPE' 429 | YYSTYPE yyvs_alloc; | ^~~~~~~ input.c:508:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 508 | static const yytype_int8 yytranslate[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:581:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 581 | static const yytype_int8 yypact[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:589:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 589 | static const yytype_int8 yydefact[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:595:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 595 | static const yytype_int8 yypgoto[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:601:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 601 | static const yytype_int8 yydefgoto[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:609:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 609 | static const yytype_int8 yytable[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:614:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 614 | static const yytype_int8 yycheck[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:621:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 621 | static const yytype_int8 yystos[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:627:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 627 | static const yytype_int8 yyr1[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:633:14: error: unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? 633 | static const yytype_int8 yyr2[] = | ^~~~~~~~~~~ | yytype_uint8 input.c:828:37: error: unknown type name 'YYSTYPE' 828 | yysymbol_kind_t yykind, YYSTYPE *yyvaluep) | ^~~~~~~ input.c:322:5: error: expected end of line before 'push' 322 | _Pragma ("GCC diagnostic push") \ | ^~~~~~~ input.c:835:3: note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN' 835 | YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:323:5: error: expected end of line before 'ignored' 323 | _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"") \ | ^~~~~~~ input.c:835:3: note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN' 835 | YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:324:5: error: expected end of line before 'ignored' 324 | _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"") | ^~~~~~~ input.c:835:3: note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN' 835 | YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:327:5: error: expected end of line before 'pop' 327 | _Pragma ("GCC diagnostic pop") | ^~~~~~~ input.c:837:3: note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_END' 837 | YY_IGNORE_MAYBE_UNINITIALIZED_END | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:845:1: error: unknown type name 'YYSTYPE' 845 | YYSTYPE yylval; | ^~~~~~~ input.c: In function 'yyparse': input.c:875:5: error: unknown type name 'YYSTYPE' 875 | YYSTYPE yyvsa[YYINITDEPTH]; | ^~~~~~~ input.c:876:5: error: unknown type name 'YYSTYPE' 876 | YYSTYPE *yyvs = yyvsa; | ^~~~~~~ input.c:877:5: error: unknown type name 'YYSTYPE' 877 | YYSTYPE *yyvsp = yyvs; | ^~~~~~~ input.c:886:3: error: unknown type name 'YYSTYPE' 886 | YYSTYPE yyval; | ^~~~~~~ input.c:438:48: error: 'YYSTYPE' undeclared (first use in this function) 438 | ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ | ^~~~~~~ input.c:75:40: note: in definition of macro 'YY_CAST' 75 | # define YY_CAST(Type, Val) ((Type) (Val)) | ^~~ input.c:962:35: note: in expansion of macro 'YY_CAST' 962 | YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); | ^~~~~~~ input.c:269:21: note: in expansion of macro 'YY_CAST' 269 | #define YYSIZEOF(X) YY_CAST (YYPTRDIFF_T, sizeof (X)) | ^~~~~~~ input.c:438:38: note: in expansion of macro 'YYSIZEOF' 438 | ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ | ^~~~~~~~ input.c:962:54: note: in expansion of macro 'YYSTACK_BYTES' 962 | YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); | ^~~~~~~~~~~~~ input.c:438:48: note: each undeclared identifier is reported only once for each function it appears in 438 | ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ | ^~~~~~~ input.c:75:40: note: in definition of macro 'YY_CAST' 75 | # define YY_CAST(Type, Val) ((Type) (Val)) | ^~~ input.c:962:35: note: in expansion of macro 'YY_CAST' 962 | YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); | ^~~~~~~ input.c:269:21: note: in expansion of macro 'YY_CAST' 269 | #define YYSIZEOF(X) YY_CAST (YYPTRDIFF_T, sizeof (X)) | ^~~~~~~ input.c:438:38: note: in expansion of macro 'YYSIZEOF' 438 | ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ | ^~~~~~~~ input.c:962:54: note: in expansion of macro 'YYSTACK_BYTES' 962 | YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); | ^~~~~~~~~~~~~ input.c:1162:11: error: implicit declaration of function 'yydestruct' [-Wimplicit-function-declaration] 1162 | yydestruct ("Error: discarding", | ^~~~~~~~~~ 282. synclines.at:370: testing %printer syncline ... stdout: ./synclines.at:254: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF ./synclines.at:370: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y syncline.c:4: #error "4" ./synclines.at:291: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 stderr: input.y:13:2: error: #error "13" 13 | #error "13" | ^~~~~ ./synclines.at:264: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF ./synclines.at:310: $CC $CFLAGS $CPPFLAGS -c input.c 281. synclines.at:346: testing %destructor syncline ... ./synclines.at:346: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: ./synclines.at:291: $CC $CFLAGS $CPPFLAGS -c input.c syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ stdout: ./synclines.at:327: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF stdout: syncline.c:4: #error "4" ./synclines.at:327: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 stdout: input.y:13: #error "13" stderr: stderr: ./synclines.at:327: $CC $CFLAGS $CPPFLAGS -c input.c ./synclines.at:264: cat stdout input.y:8:2: error: #error "8" 8 | #error "8" | ^~~~~ stdout: ./synclines.at:310: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF input.y:1: #error expected '{' before 'break' %union break ^~~~~ input.y:1: #error expected '{' before 'break' %union break ^ input.y:7: #error unknown type name 'YYSTYPE' int yylex (void); ^~~~~~~ input.y:8: #error expected identifier or '(' before '%' token %} ^ input.c:273: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? typedef yytype_int8 yy_state_t; ^~~~~~~~~~~ yytype_uint8 input.c:429: #error unknown type name 'YYSTYPE' YYSTYPE yyvs_alloc; ^~~~~~~ input.c:508: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yytranslate[] = ^~~~~~~~~~~ yytype_uint8 input.c:581: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yypact[] = ^~~~~~~~~~~ yytype_uint8 input.c:589: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yydefact[] = ^~~~~~~~~~~ yytype_uint8 input.c:595: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yypgoto[] = ^~~~~~~~~~~ yytype_uint8 input.c:601: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yydefgoto[] = ^~~~~~~~~~~ yytype_uint8 input.c:609: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yytable[] = ^~~~~~~~~~~ yytype_uint8 input.c:614: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yycheck[] = ^~~~~~~~~~~ yytype_uint8 input.c:621: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yystos[] = ^~~~~~~~~~~ yytype_uint8 input.c:627: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yyr1[] = ^~~~~~~~~~~ yytype_uint8 input.c:633: #error unknown type name 'yytype_int8'; did you mean 'yytype_uint8'? static const yytype_int8 yyr2[] = ^~~~~~~~~~~ yytype_uint8 input.c:828: #error unknown type name 'YYSTYPE' yysymbol_kind_t yykind, YYSTYPE *yyvaluep) ^~~~~~~ input.c:322: #error expected end of line before 'push' _Pragma ("GCC diagnostic push") \ ^~~~~~~ input.c:835: #error note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN' YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:323: #error expected end of line before 'ignored' _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"") \ ^~~~~~~ input.c:835: #error note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN' YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:324: #error expected end of line before 'ignored' _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"") ^~~~~~~ input.c:835: #error note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN' YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:327: #error expected end of line before 'pop' _Pragma ("GCC diagnostic pop") ^~~~~~~ input.c:837: #error note: in expansion of macro 'YY_IGNORE_MAYBE_UNINITIALIZED_END' YY_IGNORE_MAYBE_UNINITIALIZED_END ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.c:845: #error unknown type name 'YYSTYPE' input.c:875: #error unknown type name 'YYSTYPE' YYSTYPE yyvsa[YYINITDEPTH]; ^~~~~~~ input.c:876: #error unknown type name 'YYSTYPE' YYSTYPE *yyvs = yyvsa; ^~~~~~~ input.c:877: #error unknown type name 'YYSTYPE' YYSTYPE *yyvsp = yyvs; ^~~~~~~ input.c:886: #error unknown type name 'YYSTYPE' YYSTYPE yyval; ^~~~~~~ input.c:438: #error 'YYSTYPE' undeclared (first use in this function) ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ ^~~~~~~ input.c:75: #error note: in definition of macro 'YY_CAST' # define YY_CAST(Type, Val) ((Type) (Val)) ^~~ input.c:962: #error note: in expansion of macro 'YY_CAST' YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); ^~~~~~~ input.c:269: #error note: in expansion of macro 'YY_CAST' #define YYSIZEOF(X) YY_CAST (YYPTRDIFF_T, sizeof (X)) ^~~~~~~ input.c:438: #error note: in expansion of macro 'YYSIZEOF' ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ ^~~~~~~~ input.c:962: #error note: in expansion of macro 'YYSTACK_BYTES' YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); ^~~~~~~~~~~~~ input.c:438: #error note: each undeclared identifier is reported only once for each function it appears in ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ ^~~~~~~ input.c:75: #error note: in definition of macro 'YY_CAST' # define YY_CAST(Type, Val) ((Type) (Val)) ^~~ input.c:962: #error note: in expansion of macro 'YY_CAST' YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); ^~~~~~~ input.c:269: #error note: in expansion of macro 'YY_CAST' #define YYSIZEOF(X) YY_CAST (YYPTRDIFF_T, sizeof (X)) ^~~~~~~ input.c:438: #error note: in expansion of macro 'YYSIZEOF' ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \ ^~~~~~~~ input.c:962: #error note: in expansion of macro 'YYSTACK_BYTES' YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize)))); ^~~~~~~~~~~~~ input.c:1162: #error implicit declaration of function 'yydestruct' [-Wimplicit-function-declaration] yydestruct ("Error: discarding", ^~~~~~~~~~ ./conflicts.at:1096: $PREPARSER ./input ./synclines.at:255: grep '^input.y:1' stdout stdout: stdout: stderr: input.y:8: #error "8" ./synclines.at:310: cat stdout syntax error ./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input.y:1: #error expected '{' before 'break' input.y:1: #error expected '{' before 'break' 279. synclines.at:310: ok ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 276. synclines.at:237: ok stderr: 277. synclines.at:264: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file input.y: In function 'yyparse': input.y:8:2: error: #error "8" 8 | #error "8" | ^~~~~ ./synclines.at:370: $CC $CFLAGS $CPPFLAGS -c syncline.c ./synclines.at:346: $CC $CFLAGS $CPPFLAGS -c syncline.c ./synclines.at:291: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF stderr: input.y:2:2: error: #error "2" 2 | #error "2" | ^~~~~ ./synclines.at:327: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF stdout: stdout: stderr: stderr: input.y:2: #error "2" 236. conflicts.at:1096: ok ./synclines.at:327: cat stdout syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ ./synclines.at:370: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF ./synclines.at:346: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF 283. synclines.at:440: testing syncline escapes: yacc.c ... input.y:8: #error "8" ./synclines.at:291: cat stdout 280. synclines.at:327: ok stdout: stdout: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file syncline.c:4: #error "4" ./synclines.at:370: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 ./synclines.at:440: $CC $CFLAGS $CPPFLAGS \"\\\"\".c -o \"\\\"\" || exit 77 syncline.c:4: #error "4" ./synclines.at:346: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 278. synclines.at:291: 285. synclines.at:440: testing syncline escapes: lalr1.cc ... ./synclines.at:440: $CXX $CXXFLAGS $CPPFLAGS \"\\\"\".cc -o \"\\\"\" || exit 77 ok ./synclines.at:370: $CC $CFLAGS $CPPFLAGS -c input.c ./synclines.at:346: $CC $CFLAGS $CPPFLAGS -c input.c ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 284. synclines.at:440: testing syncline escapes: glr.c ... ./synclines.at:440: $CC $CFLAGS $CPPFLAGS \"\\\"\".c -o \"\\\"\" || exit 77 stderr: stderr: input.y: In function 'yydestruct': input.y:2:2: error: #error "2" 2 | #error "2" | ^~~~~ ./synclines.at:346: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF input.y: In function 'yy_symbol_value_print': input.y:2:2: error: #error "2" 2 | #error "2" | ^~~~~ ./synclines.at:370: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; # 1. Remove useless lines. # distcc clutter. s/^distcc\[\d+\] .*\n//gm; # c vs. c++. s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; # Function context. s/^[^:]*: In function '[^']+':\n//gm; # Caret error (with possible '~' to underline). s/^ *#error.*\n *\^~*\n//gm; # Number of errors. s/^1 error generated\.\n//gm; # 2. Normalize the lines we kept. # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; # Remove column. s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; # Map all combinations of "error: " and "#error: " to "#error ". s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF 287. synclines.at:440: testing syncline escapes: glr2.cc ... ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stdout: input.y:2: #error "2" stdout: ./synclines.at:346: cat stdout input.y:2: #error "2" ./synclines.at:370: cat stdout ./synclines.at:440: $CXX $CXXFLAGS $CPPFLAGS \"\\\"\".cc -o \"\\\"\" || exit 77 286. synclines.at:440: testing syncline escapes: glr.cc ... ./synclines.at:440: $CXX $CXXFLAGS $CPPFLAGS \"\\\"\".cc -o \"\\\"\" || exit 77 281. synclines.at:346: ok 282. synclines.at:370: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: 288. synclines.at:497: testing %no-lines: yacc.c ... ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.c -d input.y stdout: stderr: stdout: ./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".c \"\\\"\".y ./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".c \"\\\"\".y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stderr: ./synclines.at:497: mv input.c without.c stdout: stderr: ./synclines.at:497: mv input.h without.h ./synclines.at:497: grep '#line' *.c *.h stdout: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 289. synclines.at:497: testing %no-lines: glr.c ... ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -d input.y ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.c -d input.y ./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".cc \"\\\"\".y ./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".cc \"\\\"\".y 290. synclines.at:497: testing %no-lines: lalr1.cc ... ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.cc -d input.y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./synclines.at:440: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".c $LIBS ./synclines.at:497: mv input.c without.c ./synclines.at:497: mv input.h without.h ./synclines.at:497: mv input.cc without.cc ./synclines.at:497: grep '#line' *.c *.h ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -d input.y stdout: ./synclines.at:497: mv input.hh without.hh ./synclines.at:497: grep '#line' *.cc *.hh ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc -d input.y ./synclines.at:440: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".cc $LIBS ./synclines.at:440: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".c $LIBS ./synclines.at:440: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".cc $LIBS ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".cc \"\\\"\".y ./synclines.at:497: mv input.c with.c ./synclines.at:497: mv input.c with.c ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./synclines.at:497: mv input.h with.h ./synclines.at:497: grep -v '#line' with.c >expout ./synclines.at:497: mv input.h with.h ./synclines.at:497: cat without.c ./synclines.at:497: grep -v '#line' with.c >expout ./synclines.at:497: grep -v '#line' with.h >expout ./synclines.at:497: cat without.c ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./synclines.at:497: cat without.h ./synclines.at:497: mv input.cc with.cc ./synclines.at:497: mv input.hh with.hh ./synclines.at:497: grep -v '#line' with.cc >expout ./synclines.at:497: cat without.cc ./synclines.at:497: grep -v '#line' with.hh >expout ./synclines.at:497: grep -v '#line' with.h >expout ./synclines.at:440: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".cc $LIBS ./synclines.at:497: cat without.hh ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 289. synclines.at:497: ok ./synclines.at:497: cat without.h 290. synclines.at:497: ok 288. synclines.at:497: ok 292. synclines.at:497: testing %no-lines: glr2.cc ... ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.cc -d input.y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 291. synclines.at:497: testing %no-lines: glr.cc ... ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.cc -d input.y ./synclines.at:497: mv input.cc without.cc ./synclines.at:497: mv input.hh without.hh ./synclines.at:497: grep '#line' *.cc *.hh ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc -d input.y stderr: stdout: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 293. synclines.at:507: testing Output columns ... ./synclines.at:540: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./synclines.at:497: mv input.cc with.cc ./synclines.at:497: mv input.hh with.hh 283. synclines.at:440: ok ./synclines.at:497: grep -v '#line' with.cc >expout ./synclines.at:497: mv input.cc without.cc ./synclines.at:497: cat without.cc ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./synclines.at:497: mv input.hh without.hh ./synclines.at:497: grep -v '#line' with.hh >expout ./synclines.at:497: grep '#line' *.cc *.hh ./synclines.at:497: cat without.hh ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc -d input.y ./synclines.at:541: sed -ne '/--BEGIN/,/--END/{' \ -e '/input.c/s/ [0-9]* / LINE /;' \ -e 'p;}' \ input.c ./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file 292. synclines.at:497: ok 294. headers.at:56: testing Invalid CPP guards: --defines=input/input.h ... 293. synclines.at:507: ok ./synclines.at:497: mv input.cc with.cc ./synclines.at:497: mv input.hh with.hh ./synclines.at:497: grep -v '#line' with.cc >expout ./synclines.at:497: cat without.cc ./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file ./headers.at:56: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --defines=input/input.h --output=input/input.c input/input.y ./synclines.at:497: grep -v '#line' with.hh >expout ./synclines.at:497: cat without.hh 291. synclines.at:497: ok 295. headers.at:57: testing Invalid CPP guards: --defines=9foo.h ... ./headers.at:57: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --defines=9foo.h --output=9foo.c 9foo.y ./headers.at:56: $CC $CFLAGS $CPPFLAGS -c -o input/input.o -I. -c input/input.c ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 296. headers.at:58: testing Invalid CPP guards: %glr-parser --defines=input/input.h ... ./headers.at:57: $CC $CFLAGS $CPPFLAGS -c -o 9foo.o -I. -c 9foo.c ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:58: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --defines=input/input.h --output=input/input.c input/input.y stderr: stdout: 297. headers.at:59: testing Invalid CPP guards: %glr-parser --defines=9foo.h ... ./headers.at:58: $CC $CFLAGS $CPPFLAGS -c -o input/input.o -I. -c input/input.c ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 294. headers.at:56: ok ./headers.at:59: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --defines=9foo.h --output=9foo.c 9foo.y ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: ./headers.at:59: $CC $CFLAGS $CPPFLAGS -c -o 9foo.o -I. -c 9foo.c stderr: stdout: stdout: 284. synclines.at:440: ok 298. headers.at:67: testing export YYLTYPE ... 295. headers.at:57: ok ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --header -o input.c input.y ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 299. headers.at:177: testing Sane headers: ... ./headers.at:177: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y ./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header -o input.c input.y -Werror ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 300. headers.at:178: testing Sane headers: %locations %debug ... ./headers.at:178: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y stderr: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: stdout: ./conflicts.at:1096: $PREPARSER ./input input.y:11.1-18: error: deprecated directive: '%name-prefix "my_"', use '%define api.prefix {my_}' [-Werror=deprecated] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] stderr: syntax error ./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./headers.at:177: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c 237. conflicts.at:1096: ok ./headers.at:85: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:178: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header -o input.c input.y --warnings=error 301. headers.at:180: testing Sane headers: %glr-parser ... ./headers.at:180: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y ./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header -o input.c input.y -Wnone,none -Werror --trace=none ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:180: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header -o input.c input.y --warnings=none -Werror --trace=none stderr: stdout: ./headers.at:177: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c stderr: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stdout: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: stdout: 299. headers.at:177: ok 296. headers.at:58: ok ./headers.at:102: $CC $CFLAGS $CPPFLAGS -c -o caller.o caller.c stderr: stdout: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 297. headers.at:59: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: 302. headers.at:181: testing Sane headers: %locations %debug %glr-parser ... stderr: stdout: ./headers.at:181: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y stdout: 285. synclines.at:440: ok 304. headers.at:184: testing Sane headers: api.push-pull=both ... ./headers.at:184: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y 303. headers.at:183: testing Sane headers: api.pure ... ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:183: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y ./headers.at:103: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./headers.at:181: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:184: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./headers.at:183: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c stderr: stdout: 286. synclines.at:440: ok ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 305. headers.at:185: testing Sane headers: api.pure api.push-pull=both ... ./headers.at:185: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: stderr: stdout: stdout: ./headers.at:104: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o caller caller.o input.o $LIBS ./headers.at:178: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c 306. headers.at:187: testing Sane headers: c++ ... ./headers.at:187: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.cc input.y ./headers.at:185: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c stderr: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stdout: ./headers.at:187: $CXX $CPPFLAGS $CXXFLAGS -c -o input.o input.cc ./headers.at:105: $PREPARSER ./caller stderr: ./headers.at:105: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 298. headers.at:67: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stderr: stdout: stderr: stdout: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 300. headers.at:178: ok ./headers.at:184: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c ./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file stderr: stdout: 304. headers.at:184: ok ./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file 308. headers.at:189: testing Sane headers: c++ api.value.type=variant parse.assert ... ./headers.at:189: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.cc input.y 307. headers.at:188: testing Sane headers: %locations %debug c++ ... ./headers.at:188: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.cc input.y ./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file 309. headers.at:191: testing Sane headers: %locations c++ %glr-parser ... ./headers.at:191: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.cc input.y ./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file ./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o input.o input.cc ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:189: $CXX $CPPFLAGS $CXXFLAGS -c -o input.o input.cc stderr: stdout: ./headers.at:183: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c stderr: stdout: ./headers.at:191: $CXX $CPPFLAGS $CXXFLAGS -c -o input.o input.cc ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stderr: stdout: stderr: ./headers.at:185: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c ./headers.at:180: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c stdout: 303. headers.at:183: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: stderr: stdout: stdout: 305. headers.at:185: ok 301. headers.at:180: ok ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 310. headers.at:199: testing Several parsers ... ./headers.at:320: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x1.c x1.y 311. actions.at:24: testing Midrule actions ... ./actions.at:59: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -v -o input.c input.y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 312. actions.at:72: testing Typed midrule actions ... ./actions.at:109: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -v -o input.c input.y ./headers.at:320: $CC $CFLAGS $CPPFLAGS -c -o x1.o x1.c ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./actions.at:60: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./actions.at:110: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: stdout: ./headers.at:181: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c stderr: stdout: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 302. headers.at:181: ok stderr: stdout: ./headers.at:320: echo "x1" >>expout ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:321: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x2.c x2.y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:321: $CC $CFLAGS $CPPFLAGS -c -o x2.o x2.c 313. actions.at:122: testing Implicitly empty rule ... ./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file ./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y -Werror stderr: stdout: 287. synclines.at:440: ok stderr: 1.y:11.17-18: error: empty rule without %empty [-Werror=empty-rule] 11 | a: /* empty. */ {}; | ^~ | %empty 1.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ./actions.at:133: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file stderr: stdout: ./actions.at:111: $PREPARSER ./input stderr: ./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y --warnings=error ./actions.at:111: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 314. actions.at:172: testing Invalid uses of %empty ... 312. actions.at:72: ok stderr: ./actions.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret one.y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stdout: ./actions.at:192: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -u one.y ./actions.at:202: sed -e '1,8d' one.y ./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y -Wnone,none -Werror --trace=none ./actions.at:219: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret two.y ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 314. actions.at:172: ./headers.at:187: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc ok ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 315. actions.at:240: testing Valid uses of %empty ... ./actions.at:259: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y --warnings=none -Werror --trace=none ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./actions.at:259: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: stderr: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 316. actions.at:270: testing Add missing %empty ... ./actions.at:285: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --update -Wall input.y stdout: ./actions.at:61: $PREPARSER ./input ./headers.at:321: echo "x2" >>expout stderr: ./headers.at:322: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x3.c x3.y stderr: ./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret 2.y input.y:3.4-5: warning: empty rule without %empty [-Wempty-rule] input.y:4.3-5.1: warning: empty rule without %empty [-Wempty-rule] input.y:6.3: warning: empty rule without %empty [-Wempty-rule] input.y:8.2: warning: empty rule without %empty [-Wempty-rule] input.y:9.3: warning: empty rule without %empty [-Wempty-rule] bison: file 'input.y' was updated (backup: 'input.y~') ./actions.at:286: cat input.y ./actions.at:61: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file ./actions.at:300: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall input.y ./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret 2.y -Werror 311. actions.at:24: ok ./headers.at:322: $CC $CFLAGS $CPPFLAGS -c -o x3.o x3.c 316. actions.at:270: ok ./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file stderr: 2.y:11.17-18: error: empty rule without %empty [-Werror=empty-rule] 11 | a: /* empty. */ {}; | ^~ | %empty 2.y:13.17-18: error: empty rule without %empty [-Werror=empty-rule] 13 | c: /* empty. */ {}; | ^~ | %empty 2.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ./actions.at:149: sed 's,.*/$,,' stderr 1>&2 ./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret 2.y --warnings=error stderr: stdout: ./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret 2.y -Wnone,none -Werror --trace=none 317. actions.at:365: testing Initial location: yacc.c ... ./actions.at:365: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stdout: ./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc ./actions.at:365: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret 2.y --warnings=none -Werror --trace=none ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 318. actions.at:366: testing Initial location: yacc.c api.pure=full ... ./actions.at:366: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: ./headers.at:191: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc stdout: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./actions.at:260: $PREPARSER ./input ./actions.at:161: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wno-empty-rule 2.y stderr: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./actions.at:260: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:366: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 315. actions.at:240: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 313. actions.at:122: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stdout: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 319. actions.at:367: testing Initial location: yacc.c api.pure %parse-param { int x } ... ./actions.at:367: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./headers.at:187: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc 320. actions.at:368: testing Initial location: yacc.c api.push-pull=both ... ./actions.at:368: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:367: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./actions.at:368: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stderr: ./actions.at:365: $PREPARSER ./input stdout: stderr: 306. headers.at:187: ok 1.1 1.1: syntax error ./actions.at:365: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: 317. actions.at:365: ok stdout: stderr: stdout: ./actions.at:366: $PREPARSER ./input ./headers.at:189: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc stderr: 1.1 1.1: syntax error ./actions.at:366: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 321. actions.at:369: testing Initial location: yacc.c api.push-pull=both api.pure=full ... ./actions.at:369: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 318. actions.at:366: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: stdout: 322. actions.at:370: testing Initial location: glr.c ... ./actions.at:370: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./headers.at:322: echo "x3" >>expout ./headers.at:323: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x4.c x4.y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stderr: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./actions.at:369: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: stderr: ./actions.at:370: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: ./actions.at:367: $PREPARSER ./input ./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc stderr: 323. actions.at:371: testing Initial location: glr.c api.pure ... ./actions.at:371: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 1.1 1.1: syntax error ./actions.at:367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 258. conflicts.at:2331: ok stderr: 319. actions.at:367: ok stdout: ./headers.at:323: $CC $CFLAGS $CPPFLAGS -c -o x4.o x4.c stderr: ./actions.at:371: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: ./actions.at:368: $PREPARSER ./input ./headers.at:191: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc stderr: 1.1 1.1: syntax error ./actions.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 324. actions.at:372: testing Initial location: lalr1.cc ... ./actions.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 320. actions.at:368: ok 325. actions.at:373: testing Initial location: glr.cc ... ./actions.at:373: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:372: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./actions.at:373: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 326. actions.at:374: testing Initial location: glr2.cc ... ./actions.at:374: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: stderr: stdout: ./actions.at:369: $PREPARSER ./input ./headers.at:189: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc stderr: 1.1 1.1: syntax error ./actions.at:369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:374: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: 321. actions.at:369: ok 308. headers.at:189: ok stderr: stdout: ./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc 327. actions.at:383: testing Initial location: yacc.c api.pure=full ... ./actions.at:383: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: 328. actions.at:394: testing Initial location: yacc.c api.pure=full ... ./actions.at:394: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:383: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./headers.at:191: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc ./actions.at:394: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./actions.at:370: $PREPARSER ./input stderr: 1.1 1.1: syntax error ./actions.at:370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 322. actions.at:370: ok stderr: stdout: ./actions.at:371: $PREPARSER ./input stderr: 1.1 1.1: syntax error ./actions.at:371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 329. actions.at:478: testing Location print: yacc.c ... ./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 323. actions.at:371: ok ./actions.at:478: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: stderr: ./headers.at:323: echo "x4" >>expout stdout: ./headers.at:324: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x5.cc x5.y ./actions.at:383: $PREPARSER ./input stderr: : syntax error ./actions.at:383: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 330. actions.at:478: testing Location print: glr.c ... ./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 327. actions.at:383: ok ./headers.at:324: $CXX $CPPFLAGS $CXXFLAGS -c -o x5.o x5.cc ./actions.at:478: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc stderr: stdout: stderr: ./actions.at:394: $PREPARSER ./input stdout: 331. actions.at:478: testing Location print: lalr1.cc ... ./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: 0 0: syntax error ./actions.at:394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 307. headers.at:188: ok stderr: stdout: ./actions.at:478: $PREPARSER ./input stderr: ./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:478: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 329. actions.at:478: ok 328. actions.at:394: ok 332. actions.at:478: testing Location print: glr.cc ... ./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: 333. actions.at:478: testing Location print: glr2.cc ... ./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 309. headers.at:191: ok 334. actions.at:488: testing Exotic Dollars ... ./actions.at:532: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -v -o input.c input.y ./actions.at:478: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./actions.at:478: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 335. actions.at:1047: testing Printers and Destructors ... ./actions.at:1047: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:533: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1047: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./actions.at:372: $PREPARSER ./input stderr: 1.1 1.1: syntax error ./actions.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 324. actions.at:372: ok stderr: stdout: ./actions.at:373: $PREPARSER ./input stderr: 1.1 1.1: syntax error ./actions.at:373: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 325. actions.at:373: ok 336. actions.at:1048: testing Printers and Destructors with union ... ./actions.at:1048: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1048: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 337. actions.at:1050: testing Printers and Destructors: %glr-parser ... ./actions.at:1050: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: stderr: stdout: ./actions.at:534: $PREPARSER ./input stderr: ./actions.at:478: $PREPARSER ./input stderr: ./actions.at:1050: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:534: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 330. actions.at:478: ok ./actions.at:562: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: ./actions.at:562: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1047: $PREPARSER ./input '(x)' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 338. actions.at:1051: testing Printers and Destructors with union: %glr-parser ... ./actions.at:1051: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1047: $PREPARSER ./input '!' stderr: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1047: $PREPARSER ./input '!!!' stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1051: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1047: $PREPARSER ./input '(y)' stderr: sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./actions.at:1047: $PREPARSER ./input '(xxxxx)(x)(x)y' ./actions.at:563: $PREPARSER ./input stderr: stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:563: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1047: $PREPARSER ./input '(x)(x)x' stderr: 334. actions.at:488: ok sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1047: $PREPARSER ./input '(x)(x)(x)(x)(x)(x)(x)' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: '(' (6@60-69) sending: 'x' (7@70-79) thing (7@70-79): 'x' (7@70-79) sending: ')' (8@80-89) line (6@60-89): '(' (6@60-69) thing (7@70-79) ')' (8@80-89) sending: '(' (9@90-99) sending: 'x' (10@100-109) thing (10@100-109): 'x' (10@100-109) sending: ')' (11@110-119) line (9@90-119): '(' (9@90-99) thing (10@100-109) ')' (11@110-119) sending: '(' (12@120-129) sending: 'x' (13@130-139) thing (13@130-139): 'x' (13@130-139) sending: ')' (14@140-149) line (12@120-149): '(' (12@120-129) thing (13@130-139) ')' (14@140-149) sending: '(' (15@150-159) sending: 'x' (16@160-169) thing (16@160-169): 'x' (16@160-169) sending: ')' (17@170-179) line (15@150-179): '(' (15@150-159) thing (16@160-169) ')' (17@170-179) sending: '(' (18@180-189) sending: 'x' (19@190-199) thing (19@190-199): 'x' (19@190-199) sending: ')' (20@200-209) 200.200-209.208: memory exhausted Freeing nterm thing (19@190-199) Freeing nterm line (15@150-179) Freeing nterm line (12@120-149) Freeing nterm line (9@90-119) Freeing nterm line (6@60-89) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Parsing FAILED (status 2). ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 335. actions.at:1047: ok stderr: stdout: ./actions.at:1048: $PREPARSER ./input '(x)' 339. actions.at:1053: testing Printers and Destructors: %header lalr1.cc ... ./actions.at:1053: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: 340. actions.at:1054: testing Printers and Destructors with union: %header lalr1.cc ... ./actions.at:1054: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1048: $PREPARSER ./input '!' stderr: ./actions.at:1053: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1048: $PREPARSER ./input '!!!' stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1054: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./actions.at:1048: $PREPARSER ./input '(y)' stderr: sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./headers.at:324: echo "x5" >>expout ./actions.at:1048: $PREPARSER ./input '(xxxxx)(x)(x)y' stderr: ./headers.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x6.c x6.y sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1048: $PREPARSER ./input '(x)(x)x' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./headers.at:325: $CC $CFLAGS $CPPFLAGS -c -o x6.o x6.c stdout: ./actions.at:1048: $PREPARSER ./input '(x)(x)(x)(x)(x)(x)(x)' ./actions.at:478: $PREPARSER ./input stderr: stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: '(' (6@60-69) sending: 'x' (7@70-79) thing (7@70-79): 'x' (7@70-79) sending: ')' (8@80-89) line (6@60-89): '(' (6@60-69) thing (7@70-79) ')' (8@80-89) sending: '(' (9@90-99) sending: 'x' (10@100-109) thing (10@100-109): 'x' (10@100-109) sending: ')' (11@110-119) line (9@90-119): '(' (9@90-99) thing (10@100-109) ')' (11@110-119) sending: '(' (12@120-129) sending: 'x' (13@130-139) thing (13@130-139): 'x' (13@130-139) sending: ')' (14@140-149) line (12@120-149): '(' (12@120-129) thing (13@130-139) ')' (14@140-149) sending: '(' (15@150-159) sending: 'x' (16@160-169) thing (16@160-169): 'x' (16@160-169) sending: ')' (17@170-179) line (15@150-179): '(' (15@150-159) thing (16@160-169) ')' (17@170-179) sending: '(' (18@180-189) sending: 'x' (19@190-199) thing (19@190-199): 'x' (19@190-199) sending: ')' (20@200-209) 200.200-209.208: memory exhausted Freeing nterm thing (19@190-199) Freeing nterm line (15@150-179) Freeing nterm line (12@120-149) Freeing nterm line (9@90-119) Freeing nterm line (6@60-89) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Parsing FAILED (status 2). ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 331. actions.at:478: ok 336. actions.at:1048: ok 342. actions.at:1057: testing Printers and Destructors with union: %header glr.cc ... ./actions.at:1057: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 341. actions.at:1056: testing Printers and Destructors: %header glr.cc ... ./actions.at:1056: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:1057: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./actions.at:1056: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./headers.at:325: echo "x6" >>expout stderr: stdout: ./headers.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x7.c x7.y ./actions.at:478: $PREPARSER ./input stderr: ./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 332. actions.at:478: ok ./headers.at:326: $CC $CFLAGS $CPPFLAGS -c -o x7.o x7.c 343. actions.at:1059: testing Printers and Destructors: %header glr2.cc ... ./actions.at:1059: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:1059: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./headers.at:326: echo "x7" >>expout ./headers.at:327: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x8.c x8.y stderr: stdout: ./actions.at:1050: $PREPARSER ./input '(x)' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1050: $PREPARSER ./input '!' ./headers.at:327: $CC $CFLAGS $CPPFLAGS -c -o x8.o x8.c stderr: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1050: $PREPARSER ./input '!!!' stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1050: $PREPARSER ./input '(y)' stderr: sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1050: $PREPARSER ./input '(xxxxx)(x)(x)y' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1050: $PREPARSER ./input '(x)(x)x' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 337. actions.at:1050: ok stderr: stdout: ./headers.at:327: echo "x8" >>expout ./headers.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x9.cc x9.y 344. actions.at:1060: testing Printers and Destructors with union: %header glr2.cc ... ./actions.at:1060: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./headers.at:328: $CXX $CPPFLAGS $CXXFLAGS -c -o x9.o x9.cc stderr: stdout: ./actions.at:1051: $PREPARSER ./input '(x)' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1060: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./actions.at:1051: $PREPARSER ./input '!' stderr: stderr: stdout: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:374: $PREPARSER ./input ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1 1.1: syntax error ./actions.at:374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1051: $PREPARSER ./input '!!!' stderr: 326. actions.at:374: ok sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1051: $PREPARSER ./input '(y)' stderr: sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1051: $PREPARSER ./input '(xxxxx)(x)(x)y' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 345. actions.at:1071: testing Default tagless %printer and %destructor ... input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token J [-Wcounterexamples] time limit exceeded: 6.000000 First example: H i . J K $end Shift derivation $accept `-> 0: a $end `-> 2: H i `-> 4: i . J K Second example: H i . J $end Reduce derivation $accept `-> 0: s $end `-> 1: a J `-> 2: H i . input.y:4.4-6: warning: rule useless in parser due to conflicts [-Wother] ./actions.at:1051: $PREPARSER ./input '(x)(x)x' ./counterexample.at:451: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./counterexample.at:451: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y 338. actions.at:1051: ok ./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror stderr: input.y:30.3-5: error: useless %destructor for type <*> [-Werror=other] input.y:30.3-5: error: useless %printer for type <*> [-Werror=other] 346. actions.at:1174: testing Default tagged and per-type %printer and %destructor ... ./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1116: sed 's,.*/$,,' stderr 1>&2 stderr: stdout: ./actions.at:1057: $PREPARSER ./input '(x)' stderr: ./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror ./actions.at:1057: $PREPARSER ./input '!' stderr: stderr: stdout: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1053: $PREPARSER ./input '(x)' stderr: ./actions.at:1057: $PREPARSER ./input '!!!' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1056: $PREPARSER ./input '(x)' ./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none stderr: ./actions.at:1053: $PREPARSER ./input '!' sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. stderr: stderr: ./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1057: $PREPARSER ./input '(y)' ./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input.y:22.3-4: error: useless %destructor for type <> [-Werror=other] input.y:22.3-4: error: useless %printer for type <> [-Werror=other] stderr: ./actions.at:1056: $PREPARSER ./input '!' sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1233: sed 's,.*/$,,' stderr 1>&2 ./actions.at:1053: $PREPARSER ./input '!!!' stderr: stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none ./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error ./actions.at:1057: $PREPARSER ./input '(xxxxx)(x)(x)y' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1056: $PREPARSER ./input '!!!' ./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1053: $PREPARSER ./input '(y)' stderr: stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1057: $PREPARSER ./input '(x)(x)x' ./actions.at:1056: $PREPARSER ./input '(y)' stderr: stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1053: $PREPARSER ./input '(xxxxx)(x)(x)y' ./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1120: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 342. actions.at:1057: ok ./actions.at:1053: $PREPARSER ./input '(x)(x)x' ./actions.at:1056: $PREPARSER ./input '(xxxxx)(x)(x)y' stderr: stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none 339. actions.at:1053: ok ./actions.at:1056: $PREPARSER ./input '(x)(x)x' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./actions.at:478: $PREPARSER ./input 341. actions.at:1056: ok stderr: 347. actions.at:1307: testing Default %printer and %destructor for user-defined end token ... ./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input0.c input0.y ./actions.at:1237: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 333. actions.at:478: ok 348. actions.at:1429: testing Default %printer and %destructor are not for error or $undefined ... ./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input0.c input0.y -Werror stderr: stdout: ./actions.at:1054: $PREPARSER ./input '(x)' stderr: 349. actions.at:1532: testing Default %printer and %destructor are not for $accept ... sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input0.y:30.3-5: error: useless %destructor for type <*> [-Werror=other] input0.y:30.3-5: error: useless %printer for type <*> [-Werror=other] ./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror ./actions.at:1054: $PREPARSER ./input '!' 350. actions.at:1596: testing Default %printer and %destructor for midrule values ... ./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: ./actions.at:1416: sed 's,.*/$,,' stderr 1>&2 sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror stderr: input.y:23.6-8: error: useless %destructor for type <*> [-Werror=other] input.y:23.6-8: error: useless %printer for type <*> [-Werror=other] ./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input0.c input0.y --warnings=error ./actions.at:1054: $PREPARSER ./input '!!!' stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1474: sed 's,.*/$,,' stderr 1>&2 stderr: ./actions.at:1054: $PREPARSER ./input '(y)' input.y:24.3-4: error: useless %destructor for type <> [-Werror=other] input.y:24.3-4: error: useless %printer for type <> [-Werror=other] ./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror stderr: sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error ./actions.at:1582: sed 's,.*/$,,' stderr 1>&2 ./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input0.c input0.y -Wnone,none -Werror --trace=none ./actions.at:1054: $PREPARSER ./input '(xxxxx)(x)(x)y' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error stderr: ./actions.at:1054: $PREPARSER ./input '(x)(x)x' ./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input0.c input0.y --warnings=none -Werror --trace=none ./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none input.y:24.57-59: error: useless %destructor for type <*> [-Werror=other] input.y:24.57-59: error: useless %printer for type <*> [-Werror=other] input.y:33.3-23: error: unset value: $$ [-Werror=other] input.y:32.3-23: error: unused value: $3 [-Werror=other] stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1634: sed 's,.*/$,,' stderr 1>&2 340. actions.at:1054: ok stderr: stdout: ./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none ./headers.at:328: echo "x9" >>expout ./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none ./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error ./actions.at:1416: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input0 input0.c $LIBS stderr: stdout: ./headers.at:329: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o xa.cc xa.y ./actions.at:1121: $PREPARSER ./input --debug stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token 'a' (1.1: <> printer for 'a' @ 1) Shifting token 'a' (1.1: <> printer for 'a' @ 1) Entering state 1 Stack now 0 1 Reading a token Next token is token 'b' (1.2: 'b'/'c' printer for 'b' @ 2) Shifting token 'b' (1.2: 'b'/'c' printer for 'b' @ 2) Entering state 3 Stack now 0 1 3 Reading a token Next token is token 'c' (1.3: 'b'/'c' printer for 'c' @ 3) Shifting token 'c' (1.3: 'b'/'c' printer for 'c' @ 3) Entering state 5 Stack now 0 1 3 5 Reading a token Next token is token 'd' (1.4: <> printer for 'd' @ 4) Shifting token 'd' (1.4: <> printer for 'd' @ 4) Entering state 6 Stack now 0 1 3 5 6 Reading a token Now at end of input. 1.5: syntax error, unexpected end of file, expecting 'e' Error: popping token 'd' (1.4: <> printer for 'd' @ 4) Stack now 0 1 3 5 Error: popping token 'c' (1.3: 'b'/'c' printer for 'c' @ 3) Stack now 0 1 3 Error: popping token 'b' (1.2: 'b'/'c' printer for 'b' @ 2) Stack now 0 1 Error: popping token 'a' (1.1: <> printer for 'a' @ 1) Stack now 0 Cleanup: discarding lookahead token "end of file" (1.5: ) Stack now 0 ./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none ./actions.at:1121: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1478: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none 351. actions.at:1743: testing @$ in %initial-action implies %locations ... ./actions.at:1743: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 345. actions.at:1071: ok stderr: ./headers.at:329: $CXX $CPPFLAGS $CXXFLAGS -c -o xa.o xa.cc stdout: ./actions.at:1238: $PREPARSER ./input --debug ./actions.at:1586: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token 'a' (<*>//e printer) Shifting token 'a' (<*>//e printer) Entering state 1 Stack now 0 1 Reading a token Next token is token 'b' ( printer) Shifting token 'b' ( printer) Entering state 3 Stack now 0 1 3 Reading a token Next token is token 'c' ('c' printer) Shifting token 'c' ('c' printer) Entering state 5 Stack now 0 1 3 5 Reading a token Next token is token 'd' ('d' printer) Shifting token 'd' ('d' printer) Entering state 6 Stack now 0 1 3 5 6 Reading a token Next token is token 'e' (<*>//e printer) Shifting token 'e' (<*>//e printer) Entering state 7 Stack now 0 1 3 5 6 7 Reading a token Next token is token 'f' (<*>//e printer) Shifting token 'f' (<*>//e printer) Entering state 8 Stack now 0 1 3 5 6 7 8 Reading a token Now at end of input. syntax error, unexpected end of file, expecting 'g' Error: popping token 'f' (<*>//e printer) Stack now 0 1 3 5 6 7 Error: popping token 'e' (<*>//e printer) Stack now 0 1 3 5 6 Error: popping token 'd' ('d' printer) Stack now 0 1 3 5 Error: popping token 'c' ('c' printer) Stack now 0 1 3 Error: popping token 'b' ( printer) Stack now 0 1 Error: popping token 'a' (<*>//e printer) Stack now 0 Cleanup: discarding lookahead token "end of file" () Stack now 0 ./actions.at:1238: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1743: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none 346. actions.at:1174: ok 352. actions.at:1744: testing @$ in %destructor implies %locations ... ./actions.at:1744: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o input.c input.y ./actions.at:1744: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 353. actions.at:1745: testing @$ in %printer implies %locations ... ./actions.at:1745: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Werror stderr: ./actions.at:1745: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS input.y:24.57-59: error: useless %destructor for type <*> [-Werror=other] 24 | %printer { #error "<*> printer should not be used" } <*> | ^~~ input.y:24.57-59: error: useless %printer for type <*> [-Werror=other] 24 | %printer { #error "<*> printer should not be used" } <*> | ^~~ input.y:33.3-23: error: unset value: $$ [-Werror=other] 33 | { @$ = 4; } // Only used. | ^~~~~~~~~~~~~~~~~~~~~ input.y:32.3-23: error: unused value: $3 [-Werror=other] 32 | { USE ($$); @$ = 3; } // Only set. | ^~~~~~~~~~~~~~~~~~~~~ ./actions.at:1641: sed 's,.*/$,,' stderr 1>&2 stderr: stdout: ./actions.at:1479: $PREPARSER ./input --debug ./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=error stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token 'a' ('a') Shifting token 'a' ('a') Entering state 1 Stack now 0 1 Reading a token Next token is token 'b' ('b') syntax error Shifting token error () Entering state 3 Stack now 0 1 3 Next token is token 'b' ('b') Shifting token 'b' ('b') Entering state 5 Stack now 0 1 3 5 Reading a token Next token is token "invalid token" () Error: popping token 'b' ('b') DESTROY 'b' Stack now 0 1 3 Error: popping token error () Stack now 0 1 Shifting token error () Entering state 3 Stack now 0 1 3 Next token is token "invalid token" () Error: discarding token "invalid token" () Error: popping token error () Stack now 0 1 Shifting token error () Entering state 3 Stack now 0 1 3 Reading a token Now at end of input. Cleanup: discarding lookahead token "end of file" () Stack now 0 1 3 Cleanup: popping token error () Cleanup: popping token 'a' ('a') DESTROY 'a' ./actions.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: 349. actions.at:1532: ok stderr: 348. actions.at:1429: ok stdout: ./actions.at:1416: $PREPARSER ./input0 --debug stderr: Starting parse Entering state 0 Stack now 0 Reducing stack by rule 1 (line 49): -> $$ = nterm start (1.1: <> for 'S' @ 1) Entering state 1 Stack now 0 1 Reading a token Now at end of input. Shifting token END (1.1: <> for 'E' @ 1) Entering state 2 Stack now 0 1 2 Stack now 0 1 2 Cleanup: popping token END (1.1: <> for 'E' @ 1) Cleanup: popping nterm start (1.1: <> for 'S' @ 1) ./actions.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Wnone,none -Werror --trace=none ./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input1.c input1.y 354. actions.at:1856: testing Qualified $$ in actions: yacc.c ... ./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=none -Werror --trace=none 355. actions.at:1856: testing Qualified $$ in actions: glr.c ... ./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: 352. actions.at:1744: ok stderr: stdout: 351. actions.at:1743: ok ./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input1.c input1.y -Werror ./actions.at:1856: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1856: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1656: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: input1.y:30.3-4: error: useless %destructor for type <> [-Werror=other] input1.y:30.3-4: error: useless %printer for type <> [-Werror=other] 356. actions.at:1856: testing Qualified $$ in actions: lalr1.cc ... ./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 357. actions.at:1856: testing Qualified $$ in actions: glr.cc ... ./actions.at:1417: sed 's,.*/$,,' stderr 1>&2 ./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./actions.at:1856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input1.c input1.y --warnings=error 353. actions.at:1745: ok ./actions.at:1856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input1.c input1.y -Wnone,none -Werror --trace=none 358. actions.at:1856: testing Qualified $$ in actions: glr2.cc ... ./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input1.c input1.y --warnings=none -Werror --trace=none ./actions.at:1856: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./actions.at:1856: $PREPARSER ./input --debug ./actions.at:1417: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input1 input1.c $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Stack now 0 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Stack now 0 1 3 Reducing stack by rule 1 (line 53): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Stack now 0 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Stack now 0 2 4 Stack now 0 2 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: ./actions.at:1657: $PREPARSER ./input --debug Starting parse Entering state 0 Stack now 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Stack now 0 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Stack now 0 1 3 Reducing stack by rule 1 (line 53): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Stack now 0 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Stack now 0 2 4 Stack now 0 2 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed -ne '/ival:/p' stderr stderr: Starting parse Entering state 0 Stack now 0 Reducing stack by rule 1 (line 30): -> $$ = nterm $@1 (: ) Entering state 2 Stack now 0 2 Reducing stack by rule 2 (line 31): -> $$ = nterm @2 (: 2) Entering state 4 Stack now 0 2 4 Reducing stack by rule 3 (line 32): -> $$ = nterm @3 (: 3) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 4 (line 33): -> $$ = nterm @4 (: 4) Entering state 6 Stack now 0 2 4 5 6 Reading a token Now at end of input. syntax error Error: popping nterm @4 (: 4) DESTROY 4 Stack now 0 2 4 5 Error: popping nterm @3 (: 3) DESTROY 3 Stack now 0 2 4 Error: popping nterm @2 (: 2) DESTROY 2 Stack now 0 2 Error: popping nterm $@1 (: ) Stack now 0 Cleanup: discarding lookahead token "end of file" (: ) Stack now 0 ./actions.at:1657: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 354. actions.at:1856: ok 350. actions.at:1596: ok 359. actions.at:1863: testing Destroying lookahead assigned by semantic action ... ./actions.at:1905: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 360. actions.at:1918: testing YYBACKUP ... ./actions.at:1953: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1906: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1954: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./actions.at:1417: $PREPARSER ./input1 --debug stderr: Starting parse Entering state 0 Stack now 0 Reducing stack by rule 1 (line 49): -> $$ = nterm start (1.1: <*> for 'S' @ 1) Entering state 1 Stack now 0 1 Reading a token Now at end of input. Shifting token END (1.1: <*> for 'E' @ 1) Entering state 2 Stack now 0 1 2 Stack now 0 1 2 Cleanup: popping token END (1.1: <*> for 'E' @ 1) Cleanup: popping nterm start (1.1: <*> for 'S' @ 1) ./actions.at:1417: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: 347. actions.at:1307: ./actions.at:1907: $PREPARSER ./input ok stderr: 'b' destructor 'a' destructor ./actions.at:1907: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 359. actions.at:1863: ok 361. types.at:25: testing %union vs. api.value.type ... ./types.at:34: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 362. types.at:44: testing %yacc vs. api.value.type=union ... ./types.at:53: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 361. types.at:25: ok 362. types.at:44: ok stderr: stderr: stderr: stdout: ./headers.at:329: echo "xa" >>expout ./headers.at:330: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o xb.cc xb.y stdout: stdout: ./actions.at:1856: $PREPARSER ./input --debug 363. types.at:139: testing yacc.c api.value.type={double} ... ./actions.at:1955: $PREPARSER ./input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Reducing stack 0 by rule 1 (line 53): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: ./actions.at:1955: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Reducing stack 0 by rule 1 (line 53): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed -ne '/ival:/p' stderr 360. actions.at:1918: ok 355. actions.at:1856: ok 364. types.at:139: testing yacc.c api.value.type={double} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./headers.at:330: $CXX $CPPFLAGS $CXXFLAGS -c -o xb.o xb.cc ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 366. types.at:139: testing yacc.c api.value.type={variant} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y 365. types.at:139: testing yacc.c api.value.type={variant} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./actions.at:1856: $PREPARSER ./input --debug stderr: 364. types.at:139: ok stderr: stdout: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Stack now 0 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Stack now 0 1 3 Reducing stack by rule 1 (line 55): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Stack now 0 2 Reading a token Next token is token "end of file" () Shifting token "end of file" () Entering state 4 Stack now 0 2 4 Stack now 0 2 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Stack now 0 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Stack now 0 1 3 Reducing stack by rule 1 (line 55): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Stack now 0 2 Reading a token Next token is token "end of file" () Shifting token "end of file" () Entering state 4 Stack now 0 2 4 Stack now 0 2 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed -ne '/ival:/p' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 356. actions.at:1856: ok 363. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 367. types.at:139: testing yacc.c api.value.type={struct foo} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 366. types.at:139: ok 368. types.at:139: testing yacc.c api.value.type={struct foo} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 369. types.at:139: testing yacc.c api.value.type={struct bar} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 370. types.at:139: testing yacc.c api.value.type={struct bar} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stdout: stderr: ./actions.at:1059: $PREPARSER ./input '(x)' stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: 365. types.at:139: ok ./actions.at:1856: $PREPARSER ./input --debug stderr: Starting parse Entering state 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Reducing stack 0 by rule 1 (line 55): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1059: $PREPARSER ./input '!' ./actions.at:1856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Reducing stack 0 by rule 1 (line 55): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed -ne '/ival:/p' stderr ./actions.at:1059: $PREPARSER ./input '!!!' stderr: 357. actions.at:1856: ok sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 371. types.at:139: testing yacc.c api.value.type={union foo} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stdout: ./actions.at:1059: $PREPARSER ./input '(y)' stderr: ./types.at:139: $PREPARSER ./test sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./actions.at:1059: $PREPARSER ./input '(xxxxx)(x)(x)y' stderr: stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. 367. types.at:139: ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ok stdout: 372. types.at:139: testing yacc.c api.value.type={union foo} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $PREPARSER ./test stderr: ./actions.at:1059: $PREPARSER ./input '(x)(x)x' stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 368. types.at:139: ok ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: 343. actions.at:1059: ok stdout: stderr: ./types.at:139: $PREPARSER ./test stdout: ./types.at:139: $PREPARSER ./test 373. types.at:139: testing yacc.c %union { float fval; int ival; }; ... stderr: stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 369. types.at:139: ok 370. types.at:139: ok 374. types.at:139: testing yacc.c %union { float fval; int ival; }; %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 375. types.at:139: testing yacc.c %union foo { float fval; int ival; }; ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y 377. types.at:139: testing yacc.c api.value.union.name=foo; %union { float fval; int ival; }; ... 376. types.at:139: testing yacc.c %union foo { float fval; int ival; }; %header ... ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 371. types.at:139: ok 372. types.at:139: ok stderr: stdout: ./actions.at:1060: $PREPARSER ./input '(x)' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (0@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1060: $PREPARSER ./input '!' stderr: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty check-spontaneous-errors (5@9-19): error (@9-19) Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 378. types.at:139: testing yacc.c api.value.union.name=foo; %union { float fval; int ival; }; %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 376. types.at:139: ok ./actions.at:1060: $PREPARSER ./input '!!!' stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) raise (5@10-29): ! (1@20-29) ! (2@20-29) check-spontaneous-errors (5@10-29): error (@10-29) sending: END (3@30-39) Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1060: $PREPARSER ./input '(y)' stderr: 379. types.at:139: testing yacc.c api.value.type=union ... stderr: stdout: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' Freeing token 'y' (1@10-19) sending: ')' (2@20-29) line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. stderr: ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test ./actions.at:1060: $PREPARSER ./input '(xxxxx)(x)(x)y' stderr: stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: 'x' (2@20-29) thing (2@20-29): 'x' (2@20-29) sending: 'x' (3@30-39) 30.30-39.38: syntax error, unexpected 'x', expecting ')' Freeing nterm thing (2@20-29) Freeing nterm thing (1@10-19) Freeing token 'x' (3@30-39) sending: 'x' (4@40-49) Freeing token 'x' (4@40-49) sending: 'x' (5@50-59) Freeing token 'x' (5@50-59) sending: ')' (6@60-69) line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) sending: '(' (7@70-79) sending: 'x' (8@80-89) thing (8@80-89): 'x' (8@80-89) sending: ')' (9@90-99) line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) sending: '(' (10@100-109) sending: 'x' (11@110-119) thing (11@110-119): 'x' (11@110-119) sending: ')' (12@120-129) line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) sending: 'y' (13@130-139) input (0@129-129): /* Nothing */ input (2@100-129): line (10@100-129) input (0@129-129) input (2@70-129): line (7@70-99) input (2@100-129) input (2@0-129): line (-1@0-69) input (2@70-129) 130.130-139.138: syntax error, unexpected 'y', expecting END Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test ./actions.at:1060: $PREPARSER ./input '(x)(x)x' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) sending: ')' (5@50-59) line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) sending: 'x' (6@60-69) thing (6@60-69): 'x' (6@60-69) sending: END (7@70-79) 70.70-79.78: syntax error, unexpected END, expecting 'x' Freeing nterm thing (6@60-69) Freeing nterm line (3@30-59) Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 344. actions.at:1060: ok stderr: 373. types.at:139: ok stdout: 375. types.at:139: ok ./headers.at:330: echo "xb" >>expout 380. types.at:139: testing yacc.c api.value.type=union %header ... ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./headers.at:331: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o xc.cc xc.y stderr: stderr: stdout: stdout: 381. types.at:139: testing glr.c api.value.type={double} ... ./types.at:139: $PREPARSER ./test ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: ./types.at:139: $PREPARSER ./test ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: 382. types.at:139: testing glr.c api.value.type={double} %header ... ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y 383. types.at:139: testing glr.c api.value.type={variant} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 377. types.at:139: ok ./headers.at:331: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS -c -o xc.o xc.cc 374. types.at:139: ok ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 384. types.at:139: testing glr.c api.value.type={variant} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y 385. types.at:139: testing glr.c api.value.type={struct foo} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 378. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./actions.at:1856: $PREPARSER ./input --debug stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Reducing stack 0 by rule 1 (line 55): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 386. types.at:139: testing glr.c api.value.type={struct foo} %header ... stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: 379. types.at:139: ok Starting parse Entering state 0 Reading a token Next token is token UNTYPED (ival: 10, fval: 0.1) Shifting token UNTYPED (ival: 10, fval: 0.1) Entering state 1 Reading a token Next token is token INT (ival: 20, fval: 0.2) Shifting token INT (ival: 20, fval: 0.2) Entering state 3 Reducing stack 0 by rule 1 (line 55): $1 = token UNTYPED (ival: 10, fval: 0.1) $2 = token INT (ival: 20, fval: 0.2) -> $$ = nterm float (ival: 30, fval: 0.3) Entering state 2 Reading a token Now at end of input. Shifting token "end of file" () Entering state 4 Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed -ne '/ival:/p' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 358. actions.at:1856: ok 380. types.at:139: ok ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 387. types.at:139: testing glr.c api.value.type={struct bar} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y 388. types.at:139: testing glr.c api.value.type={struct bar} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y 389. types.at:139: testing glr.c api.value.type={union foo} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: 385. types.at:139: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 381. types.at:139: ok 390. types.at:139: testing glr.c api.value.type={union foo} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y 391. types.at:139: testing glr.c %union { float fval; int ival; }; ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: 382. types.at:139: ok stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 383. types.at:139: ok 392. types.at:139: testing glr.c %union { float fval; int ival; }; %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token J [-Wcounterexamples] time limit exceeded: 6.000000 First example H i . J K $end Shift derivation $accept -> [ a -> [ H i -> [ i . J K ] ] $end ] Second example H i . J $end Reduce derivation $accept -> [ s -> [ a -> [ H i . ] J ] $end ] input.y:4.4-6: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:451: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr 393. types.at:139: testing glr.c %union foo { float fval; int ival; }; ... 267. counterexample.at:441: ok ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 389. types.at:139: ok 394. types.at:139: testing glr.c %union foo { float fval; int ival; }; %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 395. types.at:139: testing glr.c api.value.union.name=foo; %union { float fval; int ival; }; ... stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: 386. types.at:139: ok ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS 384. types.at:139: ok 396. types.at:139: testing glr.c api.value.union.name=foo; %union { float fval; int ival; }; %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y 397. types.at:139: testing glr.c api.value.type=union ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test 387. types.at:139: ok stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 388. types.at:139: ok 398. types.at:139: testing glr.c api.value.type=union %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y 399. types.at:139: testing lalr1.cc api.value.type={double} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test 393. types.at:139: ok stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 391. types.at:139: ok 400. types.at:139: testing lalr1.cc api.value.type={double} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 401. types.at:139: testing lalr1.cc api.value.type={variant} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 392. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 390. types.at:139: 402. types.at:139: testing lalr1.cc api.value.type={variant} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 403. types.at:139: testing lalr1.cc api.value.type={struct foo} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: 395. types.at:139: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 394. types.at:139: ok 404. types.at:139: testing lalr1.cc api.value.type={struct foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test 405. types.at:139: testing lalr1.cc api.value.type={struct bar} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: 397. types.at:139: ok ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: 396. types.at:139: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 398. types.at:139: ok 406. types.at:139: testing lalr1.cc api.value.type={struct bar} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 407. types.at:139: testing lalr1.cc api.value.type={union foo} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 408. types.at:139: testing lalr1.cc api.value.type={union foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./headers.at:331: echo "xc" >>expout ./headers.at:332: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o xd.cc xd.y ./headers.at:332: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS -c -o xd.o xd.cc stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./headers.at:332: echo "xd" >>expout ./headers.at:342: "$PERL" -n -0777 -e ' # Ignore comments. s{/\*.*?\*/}{}gs; s{//.*}{}g; # Ignore warnings. s{# *pragma .* message ".*"}{}g; s{\b((defined|if)\ YYDEBUG |YYChar # Template parameter. |YYNTOKENS # This is actually scoped in a C++ class. |YYPUSH_MORE(?:_DEFINED)? |S_(YY(ACCEPT|EMPTY|EOF|error|UNDEF)) # These guys are scoped. |YY(?:_REINTERPRET)?_CAST |YY_ATTRIBUTE(?:_PURE|_UNUSED) |YY_CONSTEXPR |YY_COPY |YY_CPLUSPLUS |YY_IGNORE_(?:MAYBE_UNINITIALIZED|USELESS_CAST)_(?:BEGIN|END) |YY_INITIAL_VALUE |YY_MOVE |YY_MOVE_OR_COPY |YY_MOVE_REF |YY_NOEXCEPT |YY_NOTHROW |YY_NULLPTR |YY_RVREF |YY_USE |YY_\w+_INCLUDED # Header guards. |FILE\ \*yyo # Function argument. |const\ yylocp # Function argument. )\b}{}gx; while (/^(.*YY.*)$/gm) { print "$ARGV: invalid exported YY: $1\n"; } if ($ARGV =~ /\.h$/) { while (/^(.*yy.*)$/gm) { print "$ARGV: invalid exported yy: $1\n"; } } ' -- *.hh *.h stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./headers.at:387: $CC $CFLAGS $CPPFLAGS -c -o c-only.o c-only.c ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./headers.at:387: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx-only.o cxx-only.cc ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./headers.at:387: $CXX $CXXFLAGS $CPPFLAGS $LDFLAGS c-only.o cxx-only.o -o c-and-cxx || exit 77 stderr: stdout: ./headers.at:387: $PREPARSER ./c-and-cxx stderr: ./headers.at:387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./headers.at:392: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o parser x[1-9a-d].o -DCC_IS_CXX=$CC_IS_CXX main.cc $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: 6 reduce/reduce conflicts [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] First example: . c A A $end First reduce derivation $accept `-> 0: a $end `-> 1: b d `-> 3: %empty . `-> 6: c A A Second example: . c A A $end Second reduce derivation $accept `-> 0: a $end `-> 2: c d `-> 4: %empty . `-> 6: c A A input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] time limit exceeded: 6.000000 First example: b . c A A $end First reduce derivation $accept `-> 0: a $end `-> 1: b d `-> 5: a `-> 1: b d `-> 3: %empty . `-> 6: c A A Second example: b . A $end Second reduce derivation $accept `-> 0: a $end `-> 1: b d `-> 6: c A `-> 4: %empty . input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] time limit exceeded: 6.000000 First example: c . c A A $end First reduce derivation $accept `-> 0: a $end `-> 2: c d `-> 5: a `-> 1: b d `-> 3: %empty . `-> 6: c A A Second example: c . A $end Second reduce derivation $accept `-> 0: a $end `-> 2: c d `-> 6: c A `-> 4: %empty . input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] time limit exceeded: 6.000000 First example: b c . A Shift derivation a `-> 1: b d `-> 6: c . A Second example: b c . c A A $end Reduce derivation $accept `-> 0: a $end `-> 1: b d `-> 5: a `-> 2: c d `-> 5: a `-> 1: b d `-> 3: %empty . `-> 6: c A A input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] First example: b c . c A A $end First reduce derivation $accept `-> 0: a $end `-> 1: b d `-> 5: a `-> 2: c d `-> 5: a `-> 1: b d `-> 3: %empty . `-> 6: c A A Second example: b c . A $end Second reduce derivation $accept `-> 0: a $end `-> 1: b d `-> 5: a `-> 2: c d `-> 6: c A `-> 4: %empty . input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] First example: b c . A Shift derivation a `-> 1: b d `-> 6: c . A Second example: b c . A $end Reduce derivation $accept `-> 0: a $end `-> 1: b d `-> 5: a `-> 2: c d `-> 6: c A `-> 4: %empty . input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] Example: b d . First reduce derivation a `-> 1: b d . Second reduce derivation a `-> 1: b d `-> 7: d . input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] Example: c d . First reduce derivation a `-> 2: c d . Second reduce derivation a `-> 2: c d `-> 7: d . input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] input.y:6.15: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:621: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./counterexample.at:621: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./headers.at:394: $PREPARSER ./parser stderr: ./headers.at:394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 310. headers.at:199: ok 409. types.at:139: testing lalr1.cc %union { float fval; int ival; }; ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 399. types.at:139: ok 410. types.at:139: testing lalr1.cc %union { float fval; int ival; }; %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 408. types.at:139: ok 411. types.at:139: testing lalr1.cc api.value.type=union ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 401. types.at:139: ok 412. types.at:139: testing lalr1.cc api.value.type=union %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 400. types.at:139: ok 413. types.at:139: testing lalr1.cc api.value.type=variant ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 403. types.at:139: ok stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 407. types.at:139: ok stderr: 414. types.at:139: testing lalr1.cc api.value.type=variant %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 415. types.at:139: testing lalr1.cc api.value.type=variant ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 405. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 416. types.at:139: testing lalr1.cc api.value.type=variant %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 402. types.at:139: ok 417. types.at:139: testing lalr1.cc api.value.type=variant api.token.constructor ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 406. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 418. types.at:139: testing lalr1.cc api.value.type=variant api.token.constructor %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 404. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 419. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' stderr: stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++11 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 409. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 420. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant %header ... ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: 6 reduce/reduce conflicts [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] First example . c A A $end First reduce derivation $accept -> [ a -> [ b -> [ . ] d -> [ c A A ] ] $end ] Second example . c A A $end Second reduce derivation $accept -> [ a -> [ c -> [ . ] d -> [ c A A ] ] $end ] input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] time limit exceeded: 6.000000 First example b . c A A $end First reduce derivation $accept -> [ a -> [ b d -> [ a -> [ b -> [ . ] d -> [ c A A ] ] ] ] $end ] Second example b . A $end Second reduce derivation $accept -> [ a -> [ b d -> [ c -> [ . ] A ] ] $end ] input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] time limit exceeded: 6.000000 First example c . c A A $end First reduce derivation $accept -> [ a -> [ c d -> [ a -> [ b -> [ . ] d -> [ c A A ] ] ] ] $end ] Second example c . A $end Second reduce derivation $accept -> [ a -> [ c d -> [ c -> [ . ] A ] ] $end ] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] time limit exceeded: 6.000000 First example b c . A Shift derivation a -> [ b d -> [ c . A ] ] Second example b c . c A A $end Reduce derivation $accept -> [ a -> [ b d -> [ a -> [ c d -> [ a -> [ b -> [ . ] d -> [ c A A ] ] ] ] ] ] $end ] input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] First example b c . c A A $end First reduce derivation $accept -> [ a -> [ b d -> [ a -> [ c d -> [ a -> [ b -> [ . ] d -> [ c A A ] ] ] ] ] ] $end ] Second example b c . A $end Second reduce derivation $accept -> [ a -> [ b d -> [ a -> [ c d -> [ c -> [ . ] A ] ] ] ] $end ] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] First example b c . A Shift derivation a -> [ b d -> [ c . A ] ] Second example b c . A $end Reduce derivation $accept -> [ a -> [ b d -> [ a -> [ c d -> [ c -> [ . ] A ] ] ] ] $end ] input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] Example b d . First reduce derivation a -> [ b d . ] Second reduce derivation a -> [ b d -> [ d . ] ] input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] Example c d . First reduce derivation a -> [ c d . ] Second reduce derivation a -> [ c d -> [ d . ] ] input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] input.y:6.15: warning: rule useless in parser due to conflicts [-Wother] ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./counterexample.at:621: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 270. counterexample.at:610: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 421. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant api.token.constructor ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: ./check ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: ./check stderr: -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++11 not supported ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: ./check ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -std=c++11 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ======== Testing with C++ standard flags: '' ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: ./check ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stderr: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 411. types.at:139: ok stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test 422. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant api.token.constructor %header ... ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 412. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 423. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant api.token.constructor ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stderr: stdout: ./types.at:139: ./check stdout: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 410. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 424. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant api.token.constructor %header ... ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 419. types.at:139: ok stderr: stdout: 425. types.at:139: testing glr.cc api.value.type={double} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 417. types.at:139: ok stderr: stdout: 426. types.at:139: testing glr.cc api.value.type={double} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 413. types.at:139: ok stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: 427. types.at:139: testing glr.cc api.value.type={variant} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: stdout: ./types.at:139: ./check ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -std=c++98 not supported ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: ./check -std=c++11 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check stderr: -std=c++03 not supported ======== Testing with C++ standard flags: '' stdout: stderr: ./types.at:139: ./check ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 418. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: ./check -std=c++11 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 428. types.at:139: testing glr.cc api.value.type={variant} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check -std=c++11 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 414. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 429. types.at:139: testing glr.cc api.value.type={struct foo} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 420. types.at:139: ok 430. types.at:139: testing glr.cc api.value.type={struct foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 415. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: 431. types.at:139: testing glr.cc api.value.type={struct bar} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 416. types.at:139: ok stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 432. types.at:139: testing glr.cc api.value.type={struct bar} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $PREPARSER ./test stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: stderr: ./types.at:139: ./check stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: 421. types.at:139: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 433. types.at:139: testing glr.cc api.value.type={union foo} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: ./types.at:139: ./check ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: stderr: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stdout: stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: ./check stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: ./check ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 423. types.at:139: ok ./types.at:139: $PREPARSER ./test 422. types.at:139: ok stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 424. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 434. types.at:139: testing glr.cc api.value.type={union foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 435. types.at:139: testing glr.cc %union { float fval; int ival; }; ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 436. types.at:139: testing glr.cc %union { float fval; int ival; }; %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: 425. types.at:139: ok ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 437. types.at:139: testing glr.cc api.value.type=union ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 426. types.at:139: ok 438. types.at:139: testing glr.cc api.value.type=union %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 428. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 439. types.at:139: testing glr2.cc api.value.type={double} ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 430. types.at:139: ok stderr: 440. types.at:139: testing glr2.cc api.value.type={double} %header ... stdout: ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 431. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: 441. types.at:139: testing glr2.cc api.value.type={variant} ... stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 427. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 442. types.at:139: testing glr2.cc api.value.type={variant} %header ... ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 429. types.at:139: ok stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 443. types.at:139: testing glr2.cc api.value.type={struct foo} ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check stderr: -std=c++98 not supported ======== Testing with C++ standard flags: '' stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 432. types.at:139: ok 444. types.at:139: testing glr2.cc api.value.type={struct foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stdout: stderr: stderr: ./types.at:139: ./check stdout: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 433. types.at:139: ok stderr: stdout: ./types.at:139: ./check stderr: -std=c++98 not supported ======== Testing with C++ standard flags: '' stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 445. types.at:139: testing glr2.cc api.value.type={struct bar} ... ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: ./types.at:139: ./check stdout: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: ./check stdout: ./types.at:139: $PREPARSER ./test -std=c++03 not supported ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: stdout: ./types.at:139: ./check ./types.at:139: $PREPARSER ./test -std=c++98 not supported ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: ./check ./types.at:139: ./check ======== Testing with C++ standard flags: '' -std=c++98 not supported ======== Testing with C++ standard flags: '' -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: stdout: ./types.at:139: ./check ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 435. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 446. types.at:139: testing glr2.cc api.value.type={struct bar} %header ... ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' 434. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 447. types.at:139: testing glr2.cc api.value.type={union foo} ... ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: ./check stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 438. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 448. types.at:139: testing glr2.cc api.value.type={union foo} %header ... ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: stdout: ./types.at:139: ./check ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 436. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 449. types.at:139: testing glr2.cc %union { float fval; int ival; }; ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stderr: stdout: stdout: ./types.at:139: ./check ./types.at:139: $PREPARSER ./test ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 437. types.at:139: ok stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: 450. types.at:139: testing glr2.cc %union { float fval; int ival; }; %header ... ======== Testing with C++ standard flags: '' ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: stderr: ./types.at:139: ./check stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' stderr: stdout: stderr: ./types.at:139: ./check stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stdout: ./types.at:139: ./check ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: ./check ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stdout: stderr: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 439. types.at:139: ok 451. types.at:139: testing glr2.cc api.value.type=union ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 441. types.at:139: ok stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 452. types.at:139: testing glr2.cc api.value.type=union %header ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: stdout: ./types.at:139: ./check ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 440. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 453. types.at:377: testing lalr1.cc: Named %union ... ./types.at:377: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 453. types.at:377: ok 454. types.at:377: testing glr.cc: Named %union ... ./types.at:377: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 454. types.at:377: ok 455. scanner.at:326: testing Token numbers: yacc.c ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./scanner.at:326: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 442. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' 456. scanner.at:326: testing Token numbers: yacc.c api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.c ./scanner.at:326: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./scanner.at:326: $PREPARSER ./input stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 455. scanner.at:326: ok stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 457. scanner.at:326: testing Token numbers: glr.c ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./scanner.at:326: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.c 443. types.at:139: ok ./scanner.at:326: $PREPARSER ./input stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: 456. scanner.at:326: ok ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y 458. scanner.at:326: testing Token numbers: glr.c api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 459. scanner.at:326: testing Token numbers: lalr1.cc ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./scanner.at:326: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./scanner.at:326: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stderr: stdout: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 444. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 460. scanner.at:326: testing Token numbers: lalr1.cc api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./scanner.at:326: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.c ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./scanner.at:326: $PREPARSER ./input stderr: stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: 457. scanner.at:326: ok ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: 461. scanner.at:326: testing Token numbers: glr.cc ... ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.c ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./scanner.at:326: $PREPARSER ./input stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 458. scanner.at:326: ok ./scanner.at:326: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: ./check stderr: -std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 462. scanner.at:326: testing Token numbers: glr.cc api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 445. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: ./scanner.at:326: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: 463. scanner.at:326: testing Token numbers: glr2.cc ... ./types.at:139: ./check ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -std=c++03 not supported ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./scanner.at:326: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./types.at:139: ./check stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc ./scanner.at:326: $PREPARSER ./input stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 459. scanner.at:326: ok 464. scanner.at:326: testing Token numbers: glr2.cc api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./scanner.at:326: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc ./scanner.at:326: $PREPARSER ./input stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 460. scanner.at:326: ok stderr: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc ./scanner.at:326: $PREPARSER ./input 465. scanner.at:326: testing Token numbers: lalr1.d ... stderr: ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.d input.y ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 461. scanner.at:326: ok stderr: stdout: ./types.at:139: $PREPARSER ./test 465. scanner.at:326: stderr: skipped (scanner.at:326) ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' 466. scanner.at:326: testing Token numbers: lalr1.d api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.d input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 467. scanner.at:326: testing Token numbers: lalr1.java ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.java input.y 466. scanner.at:326: stderr: stdout: skipped (scanner.at:326) ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc 467. scanner.at:326: skipped (scanner.at:326) ./scanner.at:326: $PREPARSER ./input stderr: stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: ./check 468. scanner.at:326: testing Token numbers: lalr1.java api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.java input.y -std=c++98 not supported ======== Testing with C++ standard flags: '' 462. scanner.at:326: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 469. scanner.at:330: testing Token numbers: lalr1.cc api.token.raw api.value.type=variant api.token.constructor ... ./scanner.at:330: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 468. scanner.at:326: skipped (scanner.at:326) 470. calc.at:1334: testing Calculator parse.trace ... ./calc.at:1334: mv calc.y.tmp calc.y ./calc.at:1334: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./scanner.at:330: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 471. calc.at:1336: testing Calculator %header ... ./calc.at:1336: mv calc.y.tmp calc.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./calc.at:1336: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1334: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1336: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test stdout: stderr: ./calc.at:1336: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1336: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h stderr: input: ======== Testing with C++ standard flags: '' | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1336: $PREPARSER ./calc input stdout: stderr: ./calc.at:1334: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./calc.at:1334: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c stderr: ./calc.at:1336: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1334: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 7) Shifting token "number" (1.1: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 7) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 7) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: -3) -> $$ = nterm exp (1.1: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: -6) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 5) Shifting token "number" (1.1: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 5) -> $$ = nterm exp (1.1: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 5) -> $$ = nterm exp (1.1: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -5) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -5) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -5) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: -1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: -1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 4) Shifting token "number" (1.1: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 4) -> $$ = nterm exp (1.1: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 4) -> $$ = nterm exp (1.1: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -4) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -4) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -4) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 2) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 8) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 256) Shifting token "number" (1.1: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 256) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 256) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 4) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 4) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 64) Shifting token "number" (1.1: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 64) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 64) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 2 ./calc.at:1336: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 7) Shifting token "number" (1.1: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 7) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 7) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: -3) -> $$ = nterm exp (1.1: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: -6) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 5) Shifting token "number" (1.1: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 5) -> $$ = nterm exp (1.1: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 5) -> $$ = nterm exp (1.1: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -5) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -5) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -5) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: -1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: -1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 4) Shifting token "number" (1.1: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 4) -> $$ = nterm exp (1.1: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 4) -> $$ = nterm exp (1.1: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -4) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -4) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -4) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 2) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 8) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 256) Shifting token "number" (1.1: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 256) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 256) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 4) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 4) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 64) Shifting token "number" (1.1: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 64) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 64) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | 1 2 ./calc.at:1334: $PREPARSER ./calc input syntax error stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.1: 2) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.1: 2) Stack now 0 stdout: stderr: ./types.at:139: ./check ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1336: cat stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1334: cat stderr ======== Testing with C++ standard flags: '' input: input: | 1//2 ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./calc.at:1336: $PREPARSER ./calc input ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS | 1//2 stderr: ./calc.at:1334: $PREPARSER ./calc input stderr: syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.1: ) syntax error Error: popping token '/' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.1: ) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.1: ) syntax error Error: popping token '/' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.1: ) Stack now 0 ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1336: cat stderr stderr: ./calc.at:1334: cat stderr stdout: input: ./types.at:139: ./check input: | error ./calc.at:1334: $PREPARSER ./calc input stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1336: $PREPARSER ./calc input stderr: stderr: syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 stderr: syntax error ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1334: cat stderr input: ./calc.at:1336: cat stderr | 1 = 2 = 3 ./calc.at:1334: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.1: ) syntax error Error: popping nterm exp (1.1: 2) Stack now 0 8 19 Error: popping token '=' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.1: ) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 = 2 = 3 ./calc.at:1336: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.1: ) syntax error Error: popping nterm exp (1.1: 2) Stack now 0 8 19 Error: popping token '=' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.1: ) Stack now 0 syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: stderr: ./types.at:139: $PREPARSER ./test ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1334: cat stderr stdout: stderr: ./scanner.at:330: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc input: ./calc.at:1336: cat stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1334: $PREPARSER ./calc input ./scanner.at:330: $PREPARSER ./input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (1.1: ) syntax error Error: popping nterm input (1.1: ) Stack now 0 Cleanup: discarding lookahead token '+' (1.1: ) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' input: stderr: | | +1 ./calc.at:1336: $PREPARSER ./calc input ./scanner.at:330: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (1.1: ) syntax error Error: popping nterm input (1.1: ) Stack now 0 Cleanup: discarding lookahead token '+' (1.1: ) Stack now 0 syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 469. scanner.at:330: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: syntax error ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1336: cat stderr ./calc.at:1334: cat stderr ./calc.at:1336: $PREPARSER ./calc /dev/null 472. calc.at:1337: testing Calculator %debug %locations ... ./calc.at:1337: mv calc.y.tmp calc.y ./calc.at:1337: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: stderr: ./calc.at:1334: $PREPARSER ./calc /dev/null syntax error stdout: ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./types.at:139: ./check Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stderr: syntax error Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 ./calc.at:1337: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./calc.at:1336: cat stderr ./calc.at:1334: cat stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1336: $PREPARSER ./calc input input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1334: $PREPARSER ./calc input syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.1: ) syntax error Error: popping token '+' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 3) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 1) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.1: ) syntax error Error: popping token '*' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 2) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 3333) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 4444) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 4444 != 1 -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 4444) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.1: ) syntax error Error: popping token '+' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 3) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 1) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.1: ) syntax error Error: popping token '*' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 2) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 3333) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 4444) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 4444 != 1 -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 4444) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1336: cat stderr ./calc.at:1334: cat stderr input: input: | (!!) + (1 2) = 1 ./calc.at:1336: $PREPARSER ./calc input stderr: | (!!) + (1 2) = 1 ./calc.at:1334: $PREPARSER ./calc input syntax error error: 2222 != 1 stderr: ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 121): $1 = token '!' (1.1: ) $2 = token '!' (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error error: 2222 != 1 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 121): $1 = token '!' (1.1: ) $2 = token '!' (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./scanner.at:326: $PREPARSER ./input stderr: ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 463. scanner.at:326: ok ./calc.at:1336: cat stderr ./calc.at:1334: cat stderr input: | (- *) + (1 2) = 1 ./calc.at:1336: $PREPARSER ./calc input stderr: input: syntax error syntax error error: 2222 != 1 ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (- *) + (1 2) = 1 stdout: ./calc.at:1334: $PREPARSER ./calc input stderr: stderr: syntax error syntax error error: 2222 != 1 ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 120): $1 = token '-' (1.1: ) $2 = token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./scanner.at:326: $PREPARSER ./input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 120): $1 = token '-' (1.1: ) $2 = token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: 473. calc.at:1338: testing Calculator %locations api.location.type={Span} ... ./calc.at:1338: mv calc.y.tmp calc.y stderr: ./calc.at:1338: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stdout: ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1337: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 464. scanner.at:326: ok ./calc.at:1336: cat stderr input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1337: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 123): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 123): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1334: cat stderr ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (* *) + (*) + (*) ./calc.at:1336: $PREPARSER ./calc input ./calc.at:1338: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 123): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 123): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 123): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 124): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) input: ./calc.at:1337: $EGREP -c -v 'Return for a new token:|LAC:' stderr syntax error syntax error syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) ./calc.at:1334: $PREPARSER ./calc input stderr: stderr: input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 3333) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) syntax error syntax error syntax error ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stderr: | 1 2 ./calc.at:1337: $PREPARSER ./calc input 474. calc.at:1340: testing Calculator %name-prefix "calc" ... ./types.at:139: $PREPARSER ./test ./calc.at:1340: mv calc.y.tmp calc.y Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 3333) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1340: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 ======== Testing with C++ standard flags: '' ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1336: cat stderr ./calc.at:1340: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./calc.at:1334: cat stderr ./calc.at:1337: cat stderr input: | 1 + 2 * 3 + !+ ++ ./calc.at:1336: $PREPARSER ./calc input input: stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1334: $PREPARSER ./calc input input: ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 stderr: ./calc.at:1337: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 122): $1 = token '!' (1.1: ) $2 = token '+' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1336: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: stderr: stderr: stdout: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 122): $1 = token '!' (1.1: ) $2 = token '+' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1334: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./types.at:139: ./check input: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !- ++ ./calc.at:1336: $PREPARSER ./calc input stderr: input: | 1 + 2 * 3 + !- ++ ./calc.at:1334: $PREPARSER ./calc input stderr: ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 123): $1 = token '!' (1.1: ) $2 = token '-' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1337: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 123): $1 = token '!' (1.1: ) $2 = token '-' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS input: | error ./calc.at:1337: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1336: cat stderr input: | 1 + 2 * 3 + !* ++ ./calc.at:1334: cat stderr ./calc.at:1336: $PREPARSER ./calc input stderr: ./calc.at:1337: cat stderr memory exhausted ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: stdout: stdout: input: ./calc.at:1340: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1338: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' | 1 = 2 = 3 | 1 + 2 * 3 + !* ++ stderr: ./calc.at:1337: $PREPARSER ./calc input ./calc.at:1334: $PREPARSER ./calc input memory exhausted stderr: stderr: ./calc.at:1338: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 124): $1 = token '!' (1.1: ) $2 = token '*' (1.1: ) memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1340: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c stderr: stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 124): $1 = token '!' (1.1: ) $2 = token '*' (1.1: ) memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1338: $PREPARSER ./calc input input: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1340: $PREPARSER ./calc input ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./types.at:139: $PREPARSER ./test stderr: stderr: ./calc.at:1336: cat stderr ./calc.at:1340: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1338: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: cat stderr input: input: | (#) + (#) = 2222 input: ./calc.at:1336: $PREPARSER ./calc input | 1 2 ./calc.at:1340: $PREPARSER ./calc input stderr: | 1 2 input: ./calc.at:1338: $PREPARSER ./calc input ======== Testing with C++ standard flags: '' ./calc.at:1334: cat stderr syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: | | +1 ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: $PREPARSER ./calc input syntax error stderr: stderr: ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stderr: syntax error input: stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 | (#) + (#) = 2222 ./calc.at:1334: $PREPARSER ./calc input 1.3: syntax error stderr: ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2222) Shifting token "number" (1.1: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2222) Shifting token "number" (1.1: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1337: cat stderr ./calc.at:1336: cat stderr ./calc.at:1337: $PREPARSER ./calc /dev/null stderr: ./calc.at:1338: cat stderr ./calc.at:1340: cat stderr ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./types.at:139: ./check | (1 + #) = 1111 ./calc.at:1336: $PREPARSER ./calc input input: input: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stderr: | 1//2 | 1//2 ./calc.at:1338: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1340: $PREPARSER ./calc input ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1334: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 1.3: syntax error stderr: ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error: invalid character: '#' ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: stderr: | (1 + #) = 1111 ./calc.at:1334: $PREPARSER ./calc input 1.3: syntax error syntax error stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: cat stderr ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1337: $PREPARSER ./calc input ./calc.at:1338: cat stderr stdout: stderr: ./calc.at:1336: cat stderr ./types.at:139: $PREPARSER ./test Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1340: cat stderr stderr: input: | error ./calc.at:1338: $PREPARSER ./calc input stderr: stderr: | (# + 1) = 1111 ./calc.at:1336: $PREPARSER ./calc input input: 1.1: syntax error ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | error ./calc.at:1340: $PREPARSER ./calc input stderr: ./calc.at:1334: cat stderr syntax error: invalid character: '#' ======== Testing with C++ standard flags: '' stderr: ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: stderr: | (# + 1) = 1111 ./calc.at:1334: $PREPARSER ./calc input ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS syntax error: invalid character: '#' syntax error stderr: ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1338: cat stderr | (!!) + (1 2) = 1 ./calc.at:1337: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 128): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1340: cat stderr ./calc.at:1336: cat stderr input: | 1 = 2 = 3 ./calc.at:1338: $PREPARSER ./calc input stderr: stderr: stderr: 1.7: syntax error ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 128): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stdout: | 1 = 2 = 3 ./types.at:139: ./check input: ./calc.at:1340: $PREPARSER ./calc input stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y | (1 + # + 1) = 1111 stderr: ./calc.at:1336: $PREPARSER ./calc input 1.7: syntax error ./calc.at:1334: cat stderr syntax error ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error input: ./calc.at:1337: cat stderr stderr: | (1 + # + 1) = 1111 ./calc.at:1334: $PREPARSER ./calc input syntax error: invalid character: '#' stderr: ./calc.at:1338: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS | (- *) + (1 2) = 1 ./calc.at:1337: $PREPARSER ./calc input input: ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: | | +1 ./calc.at:1338: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 127): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 2.1: syntax error ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 127): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1340: cat stderr stderr: 2.1: syntax error ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1336: cat stderr ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1340: $PREPARSER ./calc input stderr: ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + 1) / (1 - 1) ./calc.at:1336: $PREPARSER ./calc input stderr: stderr: ./calc.at:1337: cat stderr ./calc.at:1334: cat stderr syntax error error: null divisor ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1338: cat stderr input: | (* *) + (*) + (*) ./calc.at:1337: $PREPARSER ./calc input stderr: error: null divisor input: stderr: ./calc.at:1338: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (1 + 1) / (1 - 1) ./calc.at:1334: $PREPARSER ./calc input ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error stderr: ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 2) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 0) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 10 (line 101): $1 = nterm exp (1.1: 2) $2 = token '/' (1.1: ) $3 = nterm exp (1.1: 0) error: null divisor -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.1: syntax error stderr: ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 2) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 0) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 10 (line 101): $1 = nterm exp (1.1: 2) $2 = token '/' (1.1: ) $3 = nterm exp (1.1: 0) error: null divisor -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1340: cat stderr ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1340: $PREPARSER ./calc /dev/null ./calc.at:1336: cat stderr stderr: syntax error ./calc.at:1337: cat stderr ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 471. calc.at:1336: ok ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error ./calc.at:1338: cat stderr input: | 1 + 2 * 3 + !+ ++ ./calc.at:1337: $PREPARSER ./calc input stderr: ./calc.at:1334: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 129): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 470. calc.at:1334: ok ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1338: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 129): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1337: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1340: cat stderr 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 input: | 1 + 2 * 3 + !- ++ ./calc.at:1337: $PREPARSER ./calc input 475. calc.at:1341: testing Calculator %verbose ... stderr: ./calc.at:1341: mv calc.y.tmp calc.y input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 130): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1340: $PREPARSER ./calc input ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 130): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 476. calc.at:1342: testing Calculator %yacc ... ./calc.at:1342: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1338: cat stderr ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1342: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1341: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS input: | (!!) + (1 2) = 1 ./calc.at:1338: $PREPARSER ./calc input stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: cat stderr stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 input: ./calc.at:1340: cat stderr | 1 + 2 * 3 + !* ++ ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1337: $PREPARSER ./calc input stderr: input: ./calc.at:1342: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 131): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (!!) + (1 2) = 1 ./calc.at:1340: $PREPARSER ./calc input ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1338: cat stderr stderr: syntax error error: 2222 != 1 ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 131): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) syntax error error: 2222 != 1 | (- *) + (1 2) = 1 ./calc.at:1338: $PREPARSER ./calc input stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 stderr: stdout: ./calc.at:1337: cat stderr ./types.at:139: $PREPARSER ./test stderr: ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1340: cat stderr | (#) + (#) = 2222 ./calc.at:1337: $PREPARSER ./calc input ======== Testing with C++ standard flags: '' stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.8: ) Error: discarding token "invalid token" (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1338: cat stderr ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS | (- *) + (1 2) = 1 ./calc.at:1340: $PREPARSER ./calc input stderr: stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.8: ) Error: discarding token "invalid token" (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) syntax error syntax error error: 2222 != 1 ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) ./calc.at:1338: $PREPARSER ./calc input stderr: stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error error: 2222 != 1 stderr: ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error 1.10: syntax error 1.16: syntax error stderr: stdout: ./calc.at:1341: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1341: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1337: cat stderr ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1338: cat stderr stderr: stderr: input: ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: | (1 + #) = 1111 ./calc.at:1337: $PREPARSER ./calc input ./calc.at:1340: cat stderr stderr: ./types.at:139: ./check input: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y | 1 + 2 * 3 + !+ ++ stdout: ./calc.at:1338: $PREPARSER ./calc input ./calc.at:1342: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' input: ./calc.at:1341: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: stderr: | (* *) + (*) + (*) ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1340: $PREPARSER ./calc input stderr: ./calc.at:1342: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: syntax error syntax error syntax error ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 2 ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1338: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1342: $PREPARSER ./calc input stderr: syntax error stderr: ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error syntax error ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS input: | 1 + 2 * 3 + !- ++ ./calc.at:1338: $PREPARSER ./calc input ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1337: cat stderr syntax error stderr: ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1342: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: input: | (# + 1) = 1111 ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1337: $PREPARSER ./calc input input: stderr: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 ./calc.at:1342: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error stderr: ./calc.at:1340: cat stderr ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1341: cat stderr stderr: syntax error ./calc.at:1338: cat stderr input: input: | 1 + 2 * 3 + !+ ++ ./calc.at:1340: $PREPARSER ./calc input ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 stderr: ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | 1 + 2 * 3 + !* ++ ./calc.at:1338: $PREPARSER ./calc input syntax error ./calc.at:1337: cat stderr ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.14: memory exhausted stderr: ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1340: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: stderr: 1.14: memory exhausted syntax error input: | (1 + # + 1) = 1111 ./calc.at:1337: $PREPARSER ./calc input input: ./calc.at:1342: cat stderr stderr: ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 + !- ++ ./calc.at:1340: $PREPARSER ./calc input ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1342: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1338: cat stderr ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1341: cat stderr syntax error | (#) + (#) = 2222 ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1338: $PREPARSER ./calc input stderr: ./calc.at:1337: cat stderr input: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' | error ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1340: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1337: $PREPARSER ./calc input stderr: syntax error ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 108): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 + 2 * 3 + !* ++ ./calc.at:1342: cat stderr ./calc.at:1340: $PREPARSER ./calc input syntax error ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 105): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 106): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 125): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 108): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: memory exhausted ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: memory exhausted ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error ./calc.at:1338: cat stderr ./calc.at:1342: $PREPARSER ./calc input stderr: syntax error ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1337: cat stderr | (1 + #) = 1111 ./calc.at:1338: $PREPARSER ./calc input stderr: stderr: ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.6: syntax error: invalid character: '#' ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error 472. calc.at:1337: ok ./calc.at:1341: cat stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1340: cat stderr input: ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | (#) + (#) = 2222 syntax error ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1340: $PREPARSER ./calc input stderr: stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1342: cat stderr ./calc.at:1338: cat stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' input: 477. calc.at:1343: testing Calculator parse.error=detailed ... ./calc.at:1343: mv calc.y.tmp calc.y input: | 1 = 2 = 3 ./calc.at:1343: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1342: $PREPARSER ./calc input | (# + 1) = 1111 ./calc.at:1338: $PREPARSER ./calc input stderr: syntax error ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1341: cat stderr 1.2: syntax error: invalid character: '#' ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS input: ./calc.at:1340: cat stderr ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1341: $PREPARSER ./calc input stderr: syntax error ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1342: cat stderr input: ./calc.at:1338: cat stderr stderr: | (1 + #) = 1111 ./calc.at:1340: $PREPARSER ./calc input syntax error stderr: input: | | +1 input: ./calc.at:1342: $PREPARSER ./calc input syntax error: invalid character: '#' | (1 + # + 1) = 1111 ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1338: $PREPARSER ./calc input stderr: stderr: stderr: syntax error ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' stderr: stderr: stdout: stderr: syntax error 1.6: syntax error: invalid character: '#' ./types.at:139: $PREPARSER ./test stderr: ./calc.at:1341: cat stderr ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1341: $PREPARSER ./calc /dev/null stderr: syntax error ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 447. types.at:139: ./calc.at:1340: cat stderr ./calc.at:1338: cat stderr ok stderr: syntax error input: input: ./calc.at:1342: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1338: $PREPARSER ./calc input | (# + 1) = 1111 ./calc.at:1340: $PREPARSER ./calc input stderr: stderr: 1.11-17: error: null divisor ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1342: $PREPARSER ./calc /dev/null syntax error: invalid character: '#' ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11-17: error: null divisor stderr: stderr: syntax error syntax error: invalid character: '#' ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1341: cat stderr 478. calc.at:1344: testing Calculator parse.error=verbose ... ./calc.at:1344: mv calc.y.tmp calc.y ./calc.at:1344: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1338: cat stderr ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 473. calc.at:1338: ok ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1341: $PREPARSER ./calc input stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1342: cat stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1342: $PREPARSER ./calc input stderr: stderr: ./calc.at:1340: cat stderr syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS syntax error syntax error syntax error syntax error error: 4444 != 1 stderr: input: syntax error syntax error syntax error syntax error error: 4444 != 1 | (1 + # + 1) = 1111 ./calc.at:1340: $PREPARSER ./calc input 479. calc.at:1346: testing Calculator api.pure=full %locations ... ./calc.at:1346: mv calc.y.tmp calc.y ./calc.at:1346: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: stderr: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stdout: syntax error: invalid character: '#' ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1341: cat stderr input: ./types.at:139: $PREPARSER ./test | (!!) + (1 2) = 1 ./calc.at:1341: $PREPARSER ./calc input stderr: stderr: syntax error error: 2222 != 1 ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./calc.at:1346: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: syntax error error: 2222 != 1 ./calc.at:1343: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ======== Testing with C++ standard flags: '' ./calc.at:1343: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1343: $PREPARSER ./calc input ./calc.at:1342: cat stderr ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1341: cat stderr stdout: ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: input: | (!!) + (1 2) = 1 ./calc.at:1342: $PREPARSER ./calc input stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1340: cat stderr input: stderr: ./calc.at:1343: $EGREP -c -v 'Return for a new token:|LAC:' stderr | (- *) + (1 2) = 1 ./calc.at:1341: $PREPARSER ./calc input syntax error error: 2222 != 1 ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' input: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS | (1 + 1) / (1 - 1) ./calc.at:1340: $PREPARSER ./calc input input: stderr: | 1 2 stderr: ./calc.at:1343: $PREPARSER ./calc input stderr: syntax error syntax error error: 2222 != 1 syntax error error: 2222 != 1 ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: null divisor stderr: ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected number ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error syntax error error: 2222 != 1 stderr: ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: error: null divisor ./types.at:139: ./check syntax error, unexpected number ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./calc.at:1342: cat stderr stderr: ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stdout: ./calc.at:1346: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1346: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: cat stderr input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1346: $PREPARSER ./calc input stderr: input: stderr: ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stdout: ./calc.at:1346: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: | 1 2 ./calc.at:1346: $PREPARSER ./calc input ./calc.at:1341: cat stderr stderr: 1.3: syntax error ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1342: $PREPARSER ./calc input ./types.at:139: ./check ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./calc.at:1340: cat stderr | 1//2 ./calc.at:1343: $PREPARSER ./calc input stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stderr: input: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error syntax error syntax error error: 2222 != 1 | (* *) + (*) + (*) ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1341: $PREPARSER ./calc input 474. calc.at:1340: ok stderr: stderr: syntax error, unexpected '/', expecting number or '-' or '(' or '!' stderr: syntax error syntax error error: 2222 != 1 syntax error syntax error syntax error ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error syntax error syntax error ./calc.at:1346: cat stderr ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./calc.at:1343: cat stderr input: stdout: | 1//2 ./calc.at:1344: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1346: $PREPARSER ./calc input ./calc.at:1342: cat stderr stderr: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 1.3: syntax error ./calc.at:1344: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error input: ./calc.at:1343: $PREPARSER ./calc input stderr: | (* *) + (*) + (*) ./calc.at:1342: $PREPARSER ./calc input input: stderr: stderr: syntax error, unexpected invalid token | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 syntax error syntax error syntax error ./calc.at:1344: $PREPARSER ./calc input ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error ./calc.at:1341: cat stderr 480. calc.at:1347: testing Calculator api.push-pull=both api.pure=full %locations ... ./calc.at:1347: mv calc.y.tmp calc.y stderr: ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: stderr: stderr: syntax error syntax error syntax error ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: syntax error, unexpected invalid token | 1 + 2 * 3 + !+ ++ ./calc.at:1344: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1341: $PREPARSER ./calc input stderr: ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1346: cat stderr ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 2 stderr: ./calc.at:1344: $PREPARSER ./calc input ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1341: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1343: cat stderr stderr: syntax error, unexpected number input: ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1346: $PREPARSER ./calc input ./calc.at:1342: cat stderr input: stderr: input: stderr: | 1 = 2 = 3 ./calc.at:1343: $PREPARSER ./calc input syntax error, unexpected number | 1 + 2 * 3 + !- ++ stderr: 1.1: syntax error ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected '=' ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 + 2 * 3 + !+ ++ stderr: ./calc.at:1342: $PREPARSER ./calc input stderr: 1.1: syntax error stderr: syntax error, unexpected '=' ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1344: cat stderr ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1342: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: ./calc.at:1343: cat stderr ./calc.at:1341: cat stderr | 1//2 | 1 + 2 * 3 + !- ++ ./calc.at:1344: $PREPARSER ./calc input ./calc.at:1342: $PREPARSER ./calc input stderr: stderr: ./calc.at:1346: cat stderr syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | | +1 ./calc.at:1343: $PREPARSER ./calc input input: stderr: stderr: | 1 = 2 = 3 stderr: ./calc.at:1346: $PREPARSER ./calc input stderr: syntax error, unexpected '+' syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !* ++ 1.7: syntax error ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1341: $PREPARSER ./calc input stderr: stderr: memory exhausted stderr: ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.7: syntax error syntax error, unexpected '+' stderr: ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 memory exhausted ./calc.at:1344: cat stderr ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1346: cat stderr ./calc.at:1342: cat stderr ./calc.at:1343: cat stderr ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error ./calc.at:1344: $PREPARSER ./calc input stderr: syntax error, unexpected invalid token ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: syntax error, unexpected invalid token ./calc.at:1343: $PREPARSER ./calc /dev/null input: | 1 + 2 * 3 + !* ++ ./calc.at:1342: $PREPARSER ./calc input | | +1 stderr: ./calc.at:1341: cat stderr stderr: syntax error, unexpected end of file ./calc.at:1346: $PREPARSER ./calc input ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr memory exhausted ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: memory exhausted syntax error, unexpected end of file ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 2.1: syntax error ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1344: cat stderr 2.1: syntax error | (#) + (#) = 2222 ./calc.at:1341: $PREPARSER ./calc input stderr: ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1344: $PREPARSER ./calc input ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: stderr: ./calc.at:1343: cat stderr syntax error, unexpected '=' stderr: stdout: ./calc.at:1342: cat stderr stdout: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected '=' ./types.at:139: $PREPARSER ./test ./calc.at:1346: cat stderr ./calc.at:1347: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: input: input: ./calc.at:1346: $PREPARSER ./calc /dev/null | (#) + (#) = 2222 ./calc.at:1342: $PREPARSER ./calc input ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1343: $PREPARSER ./calc input ./calc.at:1347: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c stderr: stderr: 1.1: syntax error ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 446. types.at:139: ok ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: 1.1: syntax error syntax error: invalid character: '#' syntax error: invalid character: '#' | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: ./calc.at:1344: cat stderr ./calc.at:1347: $PREPARSER ./calc input stderr: syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1341: cat stderr stderr: ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: | | +1 ./calc.at:1344: $PREPARSER ./calc input stderr: syntax error, unexpected '+' ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1346: cat stderr input: | 1 2 ./calc.at:1347: $PREPARSER ./calc input | (1 + #) = 1111 ./calc.at:1342: cat stderr stderr: ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1343: cat stderr stderr: 481. calc.at:1348: testing Calculator parse.error=detailed %locations ... ./calc.at:1348: mv calc.y.tmp calc.y ./calc.at:1348: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: 1.3: syntax error ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected '+' syntax error: invalid character: '#' input: ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 input: stderr: ./calc.at:1346: $PREPARSER ./calc input | (1 + #) = 1111 stderr: ./calc.at:1342: $PREPARSER ./calc input syntax error: invalid character: '#' stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 stderr: ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.3: syntax error | (!!) + (1 2) = 1 ./calc.at:1343: $PREPARSER ./calc input ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 syntax error, unexpected number error: 2222 != 1 syntax error: invalid character: '#' ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: cat stderr ./calc.at:1344: $PREPARSER ./calc /dev/null stderr: syntax error, unexpected number error: 2222 != 1 ./calc.at:1341: cat stderr stderr: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected end of input ./calc.at:1348: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: cat stderr stderr: syntax error, unexpected end of input input: | (# + 1) = 1111 ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1346: cat stderr ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: syntax error: invalid character: '#' | 1//2 ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: $PREPARSER ./calc input ./calc.at:1343: cat stderr ./calc.at:1342: cat stderr stderr: stderr: syntax error: invalid character: '#' 1.3: syntax error ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (!!) + (1 2) = 1 ./calc.at:1346: $PREPARSER ./calc input input: ./calc.at:1344: cat stderr input: | (- *) + (1 2) = 1 stderr: stderr: ./calc.at:1343: $PREPARSER ./calc input stderr: 1.3: syntax error | (# + 1) = 1111 syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1342: $PREPARSER ./calc input 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1344: $PREPARSER ./calc input ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 stderr: stderr: syntax error: invalid character: '#' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11: syntax error 1.1-16: error: 2222 != 1 stderr: stderr: syntax error: invalid character: '#' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1341: cat stderr ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: cat stderr ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + # + 1) = 1111 ./calc.at:1341: $PREPARSER ./calc input stderr: input: ./calc.at:1343: cat stderr | error ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1346: cat stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1344: cat stderr | (- *) + (1 2) = 1 ./calc.at:1346: $PREPARSER ./calc input input: ./calc.at:1342: cat stderr stderr: stderr: | (* *) + (*) + (*) ./calc.at:1343: $PREPARSER ./calc input 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 syntax error: invalid character: '#' stderr: ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.1: syntax error stderr: | (!!) + (1 2) = 1 stderr: ./calc.at:1344: $PREPARSER ./calc input syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 stderr: | (1 + # + 1) = 1111 ./calc.at:1342: $PREPARSER ./calc input syntax error, unexpected number error: 2222 != 1 stderr: ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected number error: 2222 != 1 stderr: syntax error: invalid character: '#' ./calc.at:1341: cat stderr ./calc.at:1346: cat stderr ./calc.at:1347: cat stderr ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: input: ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + 1) / (1 - 1) | 1 = 2 = 3 ./calc.at:1347: $PREPARSER ./calc input ./calc.at:1343: cat stderr ./calc.at:1341: $PREPARSER ./calc input | (* *) + (*) + (*) ./calc.at:1344: cat stderr ./calc.at:1346: $PREPARSER ./calc input stderr: stderr: stderr: 1.7: syntax error ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: null divisor input: ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !+ ++ | (- *) + (1 2) = 1 ./calc.at:1344: $PREPARSER ./calc input stderr: ./calc.at:1342: cat stderr ./calc.at:1343: $PREPARSER ./calc input stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error stderr: stderr: stderr: error: null divisor ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.7: syntax error syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + 1) / (1 - 1) ./calc.at:1343: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1342: $PREPARSER ./calc input ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 stderr: error: null divisor ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: cat stderr input: | 1 + 2 * 3 + !- ++ ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: $PREPARSER ./calc input ./calc.at:1346: cat stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: stderr: error: null divisor ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: cat stderr input: stdout: input: | | +1 ./calc.at:1347: $PREPARSER ./calc input ./calc.at:1348: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1341: cat stderr 2.1: syntax error ./calc.at:1346: $PREPARSER ./calc input input: ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) ./calc.at:1344: $PREPARSER ./calc input ./calc.at:1348: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c stderr: stderr: stderr: stdout: ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 2.1: syntax error 475. calc.at:1341: ./types.at:139: $PREPARSER ./test ok input: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: stderr: ./calc.at:1348: $PREPARSER ./calc input ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1346: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1343: cat stderr ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1342: cat stderr stderr: input: input: ./calc.at:1347: cat stderr | 1 + 2 * 3 + !* ++ | 1 + 2 * 3 + !- ++ ./calc.at:1348: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1343: $PREPARSER ./calc input ./calc.at:1346: $PREPARSER ./calc input 476. calc.at:1342: ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ======== Testing with C++ standard flags: '' ok ./calc.at:1347: $PREPARSER ./calc /dev/null stderr: stderr: stderr: ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr memory exhausted 1.1: syntax error ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: cat stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS input: stderr: | 1 2 stderr: ./calc.at:1348: $PREPARSER ./calc input stderr: 482. calc.at:1350: testing Calculator parse.error=detailed %locations %header api.prefix={calc} %verbose %yacc ... 1.1: syntax error stderr: ./calc.at:1350: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi memory exhausted 1.3: syntax error, unexpected number ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !+ ++ ./calc.at:1344: $PREPARSER ./calc input ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error, unexpected number ./calc.at:1350: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: cat stderr 483. calc.at:1351: testing Calculator parse.error=detailed %locations %header %name-prefix "calc" api.token.prefix={TOK_} %verbose %yacc ... ./calc.at:1344: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1346: cat stderr ./calc.at:1351: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: cat stderr input: input: ./calc.at:1348: cat stderr input: | 1 + 2 * 3 + !* ++ | 1 + 2 * 3 + !- ++ stderr: ./calc.at:1346: $PREPARSER ./calc input ./calc.at:1344: $PREPARSER ./calc input ./calc.at:1351: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1347: $PREPARSER ./calc input stderr: stderr: stdout: stderr: | (#) + (#) = 2222 ./calc.at:1343: $PREPARSER ./calc input 1.14: memory exhausted ./types.at:139: ./check ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1350: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: | 1//2 ./calc.at:1348: $PREPARSER ./calc input stderr: ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 stderr: stderr: 1.14: memory exhausted 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1351: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: cat stderr ./calc.at:1346: cat stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./calc.at:1344: cat stderr ./calc.at:1343: cat stderr input: ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1347: $PREPARSER ./calc input input: input: input: stderr: | (#) + (#) = 2222 | (1 + #) = 1111 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1343: $PREPARSER ./calc input ./calc.at:1346: $PREPARSER ./calc input ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !* ++ stderr: ./calc.at:1348: cat stderr ./calc.at:1344: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: stderr: ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: memory exhausted stdout: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: input: stderr: stderr: stderr: | error 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1348: $PREPARSER ./calc input memory exhausted ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error, unexpected invalid token ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 448. types.at:139: ok ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.1: syntax error, unexpected invalid token ./calc.at:1347: cat stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1346: cat stderr ./calc.at:1344: cat stderr ./calc.at:1343: cat stderr | (- *) + (1 2) = 1 ./calc.at:1347: $PREPARSER ./calc input ./calc.at:1348: cat stderr stderr: input: input: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | (#) + (#) = 2222 ./calc.at:1344: $PREPARSER ./calc input | (# + 1) = 1111 | (1 + #) = 1111 ./calc.at:1343: $PREPARSER ./calc input ./calc.at:1346: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1348: $PREPARSER ./calc input stderr: stderr: stderr: stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' syntax error: invalid character: '#' 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.7: syntax error, unexpected '=' 484. calc.at:1353: testing Calculator %debug ... ./calc.at:1353: mv calc.y.tmp calc.y ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1353: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y syntax error: invalid character: '#' syntax error: invalid character: '#' 1.6: syntax error: invalid character: '#' stderr: 1.7: syntax error, unexpected '=' ./calc.at:1347: cat stderr ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: cat stderr input: ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1346: cat stderr | (* *) + (*) + (*) ./calc.at:1347: $PREPARSER ./calc input ./calc.at:1343: cat stderr ./calc.at:1353: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: ./calc.at:1344: cat stderr input: input: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1348: $PREPARSER ./calc input input: | (# + 1) = 1111 stderr: ./calc.at:1346: $PREPARSER ./calc input stderr: stderr: 2.1: syntax error, unexpected '+' ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + # + 1) = 1111 ./calc.at:1343: $PREPARSER ./calc input 1.2: syntax error 1.10: syntax error 1.16: syntax error 1.2: syntax error: invalid character: '#' ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: syntax error: invalid character: '#' ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1344: $PREPARSER ./calc input 2.1: syntax error, unexpected '+' stderr: stderr: ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: cat stderr stderr: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' ./calc.at:1347: cat stderr ./calc.at:1348: $PREPARSER ./calc /dev/null ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.1: syntax error, unexpected end of file ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1343: cat stderr input: | 1 + 2 * 3 + !+ ++ ./calc.at:1346: cat stderr stderr: ./calc.at:1347: $PREPARSER ./calc input stderr: 1.1: syntax error, unexpected end of file ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1344: cat stderr input: | (1 + 1) / (1 - 1) ./calc.at:1343: $PREPARSER ./calc input | (1 + # + 1) = 1111 stderr: ./calc.at:1346: $PREPARSER ./calc input stderr: stderr: stderr: stderr: stdout: ./calc.at:1347: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: stdout: error: null divisor 1.6: syntax error: invalid character: '#' ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1351: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1344: $PREPARSER ./calc input ./calc.at:1351: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h stderr: stderr: input: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1351: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1350: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h | 1 + 2 * 3 + !- ++ ./calc.at:1348: cat stderr stderr: ./calc.at:1347: $PREPARSER ./calc input error: null divisor syntax error: invalid character: '#' ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: syntax error: invalid character: '#' input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1351: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1350: $PREPARSER ./calc input stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1348: $PREPARSER ./calc input stderr: ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1346: cat stderr ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 ./calc.at:1351: $PREPARSER ./calc input stderr: ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1343: cat stderr ./calc.at:1344: cat stderr 1.3: syntax error, unexpected number ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1350: $EGREP -c -v 'Return for a new token:|LAC:' stderr 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 | (1 + 1) / (1 - 1) ./calc.at:1346: $PREPARSER ./calc input 477. calc.at:1343: input: ok stderr: ./calc.at:1347: cat stderr stderr: | (1 + # + 1) = 1111 ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error, unexpected number ./calc.at:1344: $PREPARSER ./calc input input: 1.11-17: error: null divisor | 1 2 stderr: ./calc.at:1350: $PREPARSER ./calc input ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1348: cat stderr stderr: input: 1.3: syntax error, unexpected number | 1 + 2 * 3 + !* ++ ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: $PREPARSER ./calc input stderr: ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.11-17: error: null divisor syntax error: invalid character: '#' input: | (!!) + (1 2) = 1 ./calc.at:1348: $PREPARSER ./calc input ./calc.at:1351: cat stderr stderr: 1.14: memory exhausted ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error, unexpected number 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: 1.14: memory exhausted stderr: ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 | 1//2 ./calc.at:1351: $PREPARSER ./calc input ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1346: cat stderr ./calc.at:1344: cat stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 479. calc.at:1346: ok ./calc.at:1350: cat stderr input: stderr: 485. calc.at:1354: testing Calculator parse.error=detailed %debug %locations %header %name-prefix "calc" %verbose %yacc ... ./calc.at:1354: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1348: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1344: $PREPARSER ./calc input stderr: input: error: null divisor ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: cat stderr ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1350: $PREPARSER ./calc input stderr: stderr: ./calc.at:1354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1351: cat stderr input: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' error: null divisor ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1348: $PREPARSER ./calc input input: stderr: | (#) + (#) = 2222 ./calc.at:1347: $PREPARSER ./calc input input: stderr: stderr: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' | error ./calc.at:1351: $PREPARSER ./calc input ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error, unexpected invalid token ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 486. calc.at:1355: testing Calculator parse.error=detailed %debug %locations %header api.prefix={calc} %verbose %yacc ... stderr: ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1355: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 stderr: 1.1: syntax error, unexpected invalid token ./calc.at:1344: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1350: cat stderr ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 478. calc.at:1344: ./calc.at:1354: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ok ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1355: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y input: ./calc.at:1348: cat stderr | error ./calc.at:1350: $PREPARSER ./calc input stderr: ./calc.at:1351: cat stderr stderr: stdout: ./calc.at:1347: cat stderr ./calc.at:1353: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' 1.1: syntax error, unexpected invalid token ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | (* *) + (*) + (*) | 1 = 2 = 3 ./calc.at:1348: $PREPARSER ./calc input ./calc.at:1351: $PREPARSER ./calc input stderr: stderr: input: stderr: ./calc.at:1353: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 1.1: syntax error, unexpected invalid token ./calc.at:1347: $PREPARSER ./calc input 1.7: syntax error, unexpected '=' ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: 1.6: syntax error: invalid character: '#' | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: ./calc.at:1353: $PREPARSER ./calc input ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.7: syntax error, unexpected '=' stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 7) Shifting token "number" (1.1: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 7) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 7) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: -3) -> $$ = nterm exp (1.1: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: -6) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 5) Shifting token "number" (1.1: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 5) -> $$ = nterm exp (1.1: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 5) -> $$ = nterm exp (1.1: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -5) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -5) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -5) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: -1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: -1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 4) Shifting token "number" (1.1: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 4) -> $$ = nterm exp (1.1: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 4) -> $$ = nterm exp (1.1: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -4) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -4) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -4) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 2) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 8) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 256) Shifting token "number" (1.1: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 256) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 256) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 4) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 4) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 64) Shifting token "number" (1.1: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 64) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 64) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1355: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1350: cat stderr ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 487. calc.at:1357: testing Calculator api.pure=full parse.error=detailed %debug %locations %header %name-prefix "calc" %verbose %yacc ... ./calc.at:1357: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 7) Shifting token "number" (1.1: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 7) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 7) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: -3) -> $$ = nterm exp (1.1: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: -6) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 5) Shifting token "number" (1.1: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 5) -> $$ = nterm exp (1.1: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 5) -> $$ = nterm exp (1.1: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -5) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -5) -> $$ = nterm exp (1.1: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -5) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: -1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: -1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (1.1: 4) Shifting token "number" (1.1: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 4) -> $$ = nterm exp (1.1: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 4) -> $$ = nterm exp (1.1: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: -4) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -4) -> $$ = nterm exp (1.1: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: -4) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 2) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 8) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 256) Shifting token "number" (1.1: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 256) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 256) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 4) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 12 (line 117): $1 = nterm exp (1.1: 4) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (1.1: 64) Shifting token "number" (1.1: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 64) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 64) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1353: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1348: cat stderr ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 = 2 = 3 ./calc.at:1351: cat stderr ./calc.at:1350: $PREPARSER ./calc input input: input: ./calc.at:1357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: | 1 2 | 1 + 2 * 3 + !+ ++ 1.7: syntax error, unexpected '=' ./calc.at:1353: $PREPARSER ./calc input ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1348: $PREPARSER ./calc input ./calc.at:1347: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.1: 2) Stack now 0 stderr: input: ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 input: stderr: ./calc.at:1351: $PREPARSER ./calc input 1.7: syntax error, unexpected '=' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.1: 2) Stack now 0 | (# + 1) = 1111 ./calc.at:1347: $PREPARSER ./calc input stderr: stderr: 2.1: syntax error, unexpected '+' ./calc.at:1348: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.2: syntax error: invalid character: '#' 2.1: syntax error, unexpected '+' input: ./calc.at:1350: cat stderr | 1 + 2 * 3 + !- ++ ./calc.at:1348: $PREPARSER ./calc input ./calc.at:1357: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1351: cat stderr | | +1 stderr: ./calc.at:1350: $PREPARSER ./calc input ./calc.at:1353: cat stderr stderr: ./calc.at:1347: cat stderr ./calc.at:1351: $PREPARSER ./calc /dev/null 2.1: syntax error, unexpected '+' stderr: ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error, unexpected end of file ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | 1//2 ./calc.at:1353: $PREPARSER ./calc input stderr: stderr: ./calc.at:1348: cat stderr 2.1: syntax error, unexpected '+' | (1 + # + 1) = 1111 ./calc.at:1347: $PREPARSER ./calc input 1.1: syntax error, unexpected end of file Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.1: ) syntax error Error: popping token '/' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.1: ) Stack now 0 stderr: ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.1: ) syntax error Error: popping token '/' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.1: ) Stack now 0 | 1 + 2 * 3 + !* ++ ./calc.at:1348: $PREPARSER ./calc input stderr: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1350: cat stderr 1.14: memory exhausted ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: cat stderr stderr: ./calc.at:1350: $PREPARSER ./calc /dev/null stderr: 1.14: memory exhausted input: 1.1: syntax error, unexpected end of file ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1351: $PREPARSER ./calc input stderr: stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error, unexpected end of file ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1353: cat stderr ./calc.at:1347: cat stderr stderr: ./calc.at:1348: cat stderr 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | (#) + (#) = 2222 ./calc.at:1350: cat stderr ./calc.at:1348: $PREPARSER ./calc input ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + 1) / (1 - 1) input: stderr: ./calc.at:1347: $PREPARSER ./calc input | error ./calc.at:1353: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 stderr: ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1351: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: 1.11-17: error: null divisor ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: input: ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 1.11-17: error: null divisor ./calc.at:1351: $PREPARSER ./calc input stderr: ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1348: cat stderr ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 input: | (1 + #) = 1111 ./calc.at:1348: $PREPARSER ./calc input ./calc.at:1350: cat stderr ./calc.at:1347: cat stderr ./calc.at:1353: cat stderr ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 480. calc.at:1347: ok 1.6: syntax error: invalid character: '#' ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | (!!) + (1 2) = 1 ./calc.at:1350: $PREPARSER ./calc input stderr: ./calc.at:1351: cat stderr | 1 = 2 = 3 ./calc.at:1353: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.1: ) syntax error Error: popping nterm exp (1.1: 2) Stack now 0 8 19 Error: popping token '=' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.1: ) Stack now 0 ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.1: ) syntax error Error: popping nterm exp (1.1: 2) Stack now 0 8 19 Error: popping token '=' (1.1: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.1: ) Stack now 0 input: 1.6: syntax error: invalid character: '#' ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (- *) + (1 2) = 1 ./calc.at:1351: $PREPARSER ./calc input ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1348: cat stderr ./calc.at:1353: cat stderr stderr: 488. calc.at:1358: testing Calculator api.push-pull=both api.pure=full parse.error=detailed %debug %locations %header api.prefix={calc} %verbose %yacc ... 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1358: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi input: | (# + 1) = 1111 ./calc.at:1348: $PREPARSER ./calc input stderr: | | +1 ./calc.at:1353: $PREPARSER ./calc input ./calc.at:1350: cat stderr 1.2: syntax error: invalid character: '#' ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stdout: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (1.1: ) syntax error Error: popping nterm input (1.1: ) Stack now 0 Cleanup: discarding lookahead token '+' (1.1: ) Stack now 0 ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1354: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1358: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1351: cat stderr | (- *) + (1 2) = 1 ./calc.at:1350: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' stderr: stdout: ./calc.at:1354: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (1.1: ) syntax error Error: popping nterm input (1.1: ) Stack now 0 Cleanup: discarding lookahead token '+' (1.1: ) Stack now 0 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1357: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | (* *) + (*) + (*) | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1351: $PREPARSER ./calc input ./calc.at:1354: $PREPARSER ./calc input 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 stderr: ./calc.at:1348: cat stderr stderr: ./calc.at:1357: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 136): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 136): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1354: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: | (1 + # + 1) = 1111 ./calc.at:1348: $PREPARSER ./calc input ./calc.at:1350: cat stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1357: $PREPARSER ./calc input 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' stderr: 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: ./calc.at:1353: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1358: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1354: $PREPARSER ./calc input | (* *) + (*) + (*) ./calc.at:1350: $PREPARSER ./calc input ./calc.at:1353: $PREPARSER ./calc /dev/null stderr: stderr: ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 stderr: ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1357: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: stderr: ./calc.at:1351: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./calc.at:1355: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: stderr: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1355: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h stderr: input: ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !+ ++ input: ./calc.at:1351: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 | 1 2 ./calc.at:1357: $PREPARSER ./calc input ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1348: cat stderr ./calc.at:1350: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: ./calc.at:1355: $PREPARSER ./calc input ./calc.at:1354: cat stderr ./calc.at:1351: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 | 1 + 2 * 3 + !+ ++ Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 136): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) | (1 + 1) / (1 - 1) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1348: $PREPARSER ./calc input ./calc.at:1350: $PREPARSER ./calc input stdout: input: stderr: stderr: | 1//2 ./calc.at:1354: $PREPARSER ./calc input ./types.at:139: $PREPARSER ./test ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.11-17: error: null divisor stderr: ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1351: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 136): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 136): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next toke./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 n is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 137): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1353: cat stderr ./calc.at:1355: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1350: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1357: cat stderr ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11-17: error: null divisor input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1353: $PREPARSER ./calc input 449. types.at:139: ok Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 stderr: input: input: input: | 1 + 2 * 3 + !- ++ | 1 2 stderr: ./calc.at:1350: $PREPARSER ./calc input ./calc.at:1355: $PREPARSER ./calc input | 1//2 ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1357: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.1: ) syntax error Error: popping token '+' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 3) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 1) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.1: ) syntax error Error: popping token '*' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 2) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 3333) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 4444) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 4444 != 1 -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 4444) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1348: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.1: ) syntax error Error: popping token '+' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 3) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 1) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.1: ) syntax error Error: popping token '*' (1.1: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.1: 2) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 3333) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 4444) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 4444 != 1 -> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 4444) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: ./calc.at:1354: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1351: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 481. calc.at:1348: ok ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !* ++ ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1351: $PREPARSER ./calc input input: stderr: ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1355: cat stderr | error 1.14: memory exhausted ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: cat stderr ./calc.at:1354: $PREPARSER ./calc input ./calc.at:1350: cat stderr 489. calc.at:1360: testing Calculator api.pure parse.error=detailed %debug %locations %header api.prefix={calc} %verbose %yacc %parse-param {semantic_value *result}{int *count}{int *nerrs} ... stderr: stderr: 1.14: memory exhausted ./calc.at:1360: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1353: cat stderr input: | 1//2 input: ./calc.at:1355: $PREPARSER ./calc input | error ./calc.at:1357: $PREPARSER ./calc input ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: | 1 + 2 * 3 + !* ++ stderr: ./calc.at:1350: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1351: cat stderr input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1360: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 ./calc.at:1353: $PREPARSER ./calc input stderr: 1.14: memory exhausted Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 490. calc.at:1362: testing Calculator %no-lines api.pure parse.error=detailed %debug %locations %header api.prefix={calc} %verbose %yacc %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1362: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi stderr: ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 121): $1 = token '!' (1.1: ) $2 = token '!' (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 stderr: 1.14: memory exhausted | (#) + (#) = 2222 ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1351: $PREPARSER ./calc input stderr: stderr: ./calc.at:1354: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 121): $1 = token '!' (1.1: ) $2 = token '!' (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1362: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1355: cat stderr ./calc.at:1350: cat stderr input: ./calc.at:1357: cat stderr | 1 = 2 = 3 ./calc.at:1354: $PREPARSER ./calc input stderr: stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 input: input: ./calc.at:1360: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (#) + (#) = 2222 ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1350: $PREPARSER ./calc input | 1 = 2 = 3 | error stderr: ./calc.at:1357: $PREPARSER ./calc input ./calc.at:1355: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: cat stderr stderr: stderr: ./calc.at:1353: cat stderr ./calc.at:1362: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1354: cat stderr input: ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 | (- *) + (1 2) = 1 ./calc.at:1353: $PREPARSER ./calc input ./calc.at:1351: $PREPARSER ./calc input stderr: stderr: input: ./calc.at:1357: cat stderr ./calc.at:1350: cat stderr 1.6: syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 120): $1 = token '-' (1.1: ) $2 = token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1355: cat stderr | | +1 ./calc.at:1354: $PREPARSER ./calc input input: stderr: | (1 + #) = 1111 ./calc.at:1350: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 120): $1 = token '-' (1.1: ) $2 = token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' | | +1 ./calc.at:1357: $PREPARSER ./calc input ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 = 2 = 3 ./calc.at:1355: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1351: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 input: ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1351: $PREPARSER ./calc input ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1350: cat stderr stderr: ./calc.at:1354: cat stderr 1.2: syntax error: invalid character: '#' ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: cat stderr ./calc.at:1353: cat stderr ./calc.at:1355: cat stderr input: ./calc.at:1354: $PREPARSER ./calc /dev/null stderr: stderr: ./calc.at:1357: $PREPARSER ./calc /dev/null | (# + 1) = 1111 ./calc.at:1350: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' input: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: | | +1 ./calc.at:1355: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) stderr: ./calc.at:1353: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' stderr: ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 3333) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 stderr: ./calc.at:1351: cat stderr 1.2: syntax error: invalid character: '#' ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 3333) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1354: cat stderr ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1357: cat stderr | (1 + # + 1) = 1111 ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1351: $PREPARSER ./calc input ./calc.at:1355: cat stderr ./calc.at:1350: cat stderr stderr: input: 1.6: syntax error: invalid character: '#' ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1354: $PREPARSER ./calc input ./calc.at:1355: $PREPARSER ./calc /dev/null stderr: stderr: input: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1357: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + # + 1) = 1111 ./calc.at:1353: cat stderr stderr: ./calc.at:1350: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: 1.6: syntax error: invalid character: '#' ./types.at:139: $PREPARSER ./test ./calc.at:1351: cat stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1353: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 122): $1 = token '!' (1.1: ) $2 = token '+' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1354: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1351: $PREPARSER ./calc input ./calc.at:1355: cat stderr stderr: ======== Testing with C++ standard flags: '' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 122): $1 = token '!' (1.1: ) $2 = token '+' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1353: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1357: cat stderr 1.11-17: error: null divisor ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./calc.at:1350: cat stderr | (!!) + (1 2) = 1 stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1355: $PREPARSER ./calc input input: ./calc.at:1354: $PREPARSER ./calc input input: 1.11-17: error: null divisor stderr: | (!!) + (1 2) = 1 stderr: ./calc.at:1357: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1353: $PREPARSER ./calc input ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 141): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stdout: ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 123): $1 = token '!' (1.1: ) $2 = token '-' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) | (1 + 1) / (1 - 1) ./calc.at:1350: $PREPARSER ./calc input ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: ./calc.at:1351: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 141): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 123): $1 = token '!' (1.1: ) $2 = token '-' (1.1: ) Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) 1.11-17: error: null divisor ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 483. calc.at:1351: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ======== Testing with C++ standard flags: '' stderr: 1.11-17: error: null divisor ./calc.at:1355: cat stderr ./calc.at:1357: cat stderr ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1354: cat stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: input: stdout: input: ./calc.at:1350: cat stderr | (!!) + (1 2) = 1 ./calc.at:1355: $PREPARSER ./calc input ./calc.at:1353: cat stderr | (- *) + (1 2) = 1 ./calc.at:1354: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1357: $PREPARSER ./calc input ./types.at:139: ./check stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 141): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 140): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 482. calc.at:1350: ok input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 140): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 141): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 + !* ++ ./calc.at:1353: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 124): $1 = token '!' (1.1: ) $2 = token '*' (1.1: ) memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 491. calc.at:1363: testing Calculator %no-lines api.pure parse.error=verbose %debug %locations %header api.prefix={calc} %verbose %yacc %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1363: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi stdout: ./calc.at:1358: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 124): $1 = token '!' (1.1: ) $2 = token '*' (1.1: ) memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1354: cat stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./calc.at:1358: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./types.at:139: ./check ./calc.at:1363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1355: cat stderr ./calc.at:1357: cat stderr ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | (* *) + (*) + (*) input: ./calc.at:1354: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1358: $PREPARSER ./calc input stderr: | (* *) + (*) + (*) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: $PREPARSER ./calc input stderr: 492. calc.at:1364: testing Calculator %no-lines api.pure parse.error=verbose %debug %locations %defines api.prefix={calc} %verbose %yacc %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1364: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else mv calc.y.tmp calc.y fi stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1353: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Return for a new token: Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Return for a new token: Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Return for a new token: Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Return for a new token: Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Return for a new token: Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Return for a new token: Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Return for a new token: Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Return for a new token: Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Return for a new token: Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Return for a new token: Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Return for a new token: Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Return for a new token: Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Return for a new token: Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Return for a new token: Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Return for a new token: Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Return for a new token: Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Return for a new token: Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Return for a new token: Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Return for a new token: Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Return for a new token: Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Return for a new token: Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Return for a new token: Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Return for a new token: Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Return for a new token: Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Return for a new token: Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Return for a new token: Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Return for a new token: Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Return for a new token: Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Return for a new token: Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Return for a new token: Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Return for a new token: Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Return for a new token: Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Return for a new token: Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Return for a new token: Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Return for a new token: Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Return for a new token: Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Return for a new token: Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Return for a new token: Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1355: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 140): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Return for a new token: Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Return for a new token: Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Return for a new token: Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Return for a new token: Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Return for a new token: Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Return for a new token: Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Return for a new token: Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Return for a new token: Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Return for a new token: Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Return for a new token: Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Return for a new token: Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Return for a new token: Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Return for a new token: Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Return for a new token: Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Return for a new token: Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Return for a new token: Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Return for a new token: Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Return for a new token: Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Return for a new token: Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Return for a new token: Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Return for a new token: Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Return for a new token: Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Return for a new token: Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Return for a new token: Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Return for a new token: Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Return for a new token: Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Return for a new token: Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Return for a new token: Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Return for a new token: Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Return for a new token: Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Return for a new token: Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Return for a new token: Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Return for a new token: Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Return for a new token: Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Return for a new token: Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Return for a new token: Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Return for a new token: Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Return for a new token: Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Return for a new token: Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Return for a new token: Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Return for a new token: Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Return for a new token: Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Return for a new token: Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1363: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1364: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./calc.at:1358: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 140): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (#) + (#) = 2222 ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1353: $PREPARSER ./calc input stderr: ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2222) Shifting token "number" (1.1: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1354: cat stderr | 1 2 ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1358: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 2222) Shifting token "number" (1.1: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1357: cat stderr ./calc.at:1355: cat stderr stderr: input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: input: | 1 + 2 * 3 + !+ ++ ./calc.at:1354: $PREPARSER ./calc input ./calc.at:1360: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1357: $PREPARSER ./calc input stderr: input: ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 142): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1360: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1364: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS | (* *) + (*) + (*) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1355: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1353: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 142): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1354: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1360: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1357: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) input: input: | (1 + #) = 1111 input: | 1 + 2 * 3 + !- ++ ./calc.at:1354: $PREPARSER ./calc input ./calc.at:1353: $PREPARSER ./calc input ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1357: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 143): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: ./calc.at:1360: $EGREP -c -v 'Return for a new token:|LAC:' stderr | 1//2 ./calc.at:1358: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1355: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Return for a new token: Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 143): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stdout: stderr: input: ./calc.at:1362: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' | 1 2 input: ./calc.at:1360: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Return for a new token: Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 | 1 + 2 * 3 + !+ ++ ./calc.at:1355: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1362: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 142): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1362: $PREPARSER ./calc input ./calc.at:1354: cat stderr stderr: ./calc.at:1357: cat stderr ./calc.at:1353: cat stderr stderr: stderr: ./calc.at:1358: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 142): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1355: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: input: stderr: | 1 + 2 * 3 + !* ++ input: ./calc.at:1354: $PREPARSER ./calc input input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 101): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 101): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 101): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 101): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 101): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 101): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 101): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 101): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 101): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) | (# + 1) = 1111 stderr: ./calc.at:1353: $PREPARSER ./calc input ./calc.at:1362: $EGREP -c -v 'Return for a new token:|LAC:' stderr | error ./calc.at:1358: $PREPARSER ./calc input ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !* ++ stderr: stderr: ./calc.at:1357: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 144): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ ./calc.at:1355: $PREPARSER ./calc input ./calc.at:1360: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) | 1 2 ./calc.at:1362: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 144): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 143): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 | 1//2 stderr: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1360: $PREPARSER ./calc input ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 143): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1354: cat stderr stderr: ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: cat stderr ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1358: cat stderr stderr: ./calc.at:1355: cat stderr ./calc.at:1353: cat stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 input: ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (#) + (#) = 2222 ./calc.at:1354: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1358: $PREPARSER ./calc input input: stderr: ./calc.at:1362: cat stderr | (#) + (#) = 2222 stderr: ./calc.at:1357: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !* ++ ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1355: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + # + 1) = 1111 input: stderr: ./calc.at:1353: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 144): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: | 1//2 ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1362: $PREPARSER ./calc input ./calc.at:1360: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: stderr: ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 144): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./types.at:139: $PREPARSER ./test stderr: ./calc.at:1358: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token syntax error: invalid character: '#' Error: popping token '+' (1.1: ) Stack now 0 4 12 Error: popping nterm exp (1.1: 1) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.1: ) Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: input: stderr: ./calc.at:1354: cat stderr | error ./calc.at:1360: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 input: input: 450. types.at:139: ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ok ./calc.at:1355: cat stderr ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1358: $PREPARSER ./calc input ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 ./calc.at:1354: $PREPARSER ./calc input stderr: ./calc.at:1362: cat stderr ./calc.at:1357: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 input: stderr: ./calc.at:1353: cat stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: | error | (#) + (#) = 2222 ./calc.at:1355: $PREPARSER ./calc input ./calc.at:1362: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 | (1 + #) = 1111 stderr: ./calc.at:1357: $PREPARSER ./calc input stderr: input: ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 | (1 + 1) / (1 - 1) ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1353: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1354: cat stderr ./calc.at:1360: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 2) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 0) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 10 (line 101): $1 = nterm exp (1.1: 2) $2 = token '/' (1.1: ) $3 = nterm exp (1.1: 0) error: null divisor -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1358: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 493. calc.at:1367: testing Calculator parse.error=custom ... ./calc.at:1367: mv calc.y.tmp calc.y ./calc.at:1358: $PREPARSER ./calc /dev/null stderr: ./calc.at:1367: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: input: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 2) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.1: ) Reducing stack by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 0) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 10 (line 101): $1 = nterm exp (1.1: 2) $2 = token '/' (1.1: ) $3 = nterm exp (1.1: 0) error: null divisor -> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) | (# + 1) = 1111 ./calc.at:1354: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 | 1 = 2 = 3 ./calc.at:1360: $PREPARSER ./calc input ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1357: cat stderr stderr: ./calc.at:1355: cat stderr stderr: ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1362: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: | (# + 1) = 1111 ./calc.at:1357: $PREPARSER ./calc input ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 input: ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1367: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: | 1 = 2 = 3 ./calc.at:1362: $PREPARSER ./calc input | (1 + #) = 1111 ./calc.at:1355: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1354: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: cat stderr ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1353: cat stderr ./calc.at:1360: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | (1 + # + 1) = 1111 ./calc.at:1354: $PREPARSER ./calc input 484. calc.at:1353: ok input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 stderr: input: ./calc.at:1357: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 | | +1 ./calc.at:1360: $PREPARSER ./calc input stdout: ./calc.at:1358: $PREPARSER ./calc input stderr: ./calc.at:1364: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Return for a new token: Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Return for a new token: Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Return for a new token: Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Return for a new token: Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Return for a new token: Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Return for a new token: Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Return for a new token: Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Return for a new token: Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1355: cat stderr ./calc.at:1362: cat stderr | (1 + # + 1) = 1111 ./calc.at:1357: $PREPARSER ./calc input input: stderr: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1364: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Return for a new token: Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Return for a new token: Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Return for a new token: Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Return for a new token: Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Return for a new token: Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Return for a new token: Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Return for a new token: Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Return for a new token: Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.47-2.0: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Enter./calc.at:1355: $PREPARSER ./calc input ing state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) input: ./calc.at:1354: cat stderr ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | | +1 stderr: ./calc.at:1362: $PREPARSER ./calc input stdout: ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1364: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1360: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 494. calc.at:1368: testing Calculator parse.error=custom %locations api.prefix={calc} ... input: ./calc.at:1368: mv calc.y.tmp calc.y stderr: | (1 + 1) / (1 - 1) ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1354: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1363: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1360: $PREPARSER ./calc /dev/null ./calc.at:1368: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 121): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1357: cat stderr | (!!) + (1 2) = 1 ./calc.at:1358: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 96): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1363: $PREPARSER ./calc input stderr: ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1355: cat stderr | 1 2 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Return for a new token: Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 121): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Enter | (1 + 1) / (1 - 1) ./calc.at:1357: $PREPARSER ./calc input ing state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 stderr: stderr: ./calc.at:1362: cat stderr ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Return for a new token: Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (1 + # + 1) = 1111 stderr: ./calc.at:1355: $PREPARSER ./calc input ./calc.at:1368: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1362: $PREPARSER ./calc /dev/null ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1354: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 20 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 Reducing stack by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: ./calc.at:1363: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 485. calc.at:1354: ok ./calc.at:1360: cat stderr ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1358: cat stderr input: stderr: ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 ./calc.at:1363: $PREPARSER ./calc input ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 input: stderr: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1360: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 ./calc.at:1357: cat stderr | (- *) + (1 2) = 1 ./calc.at:1358: $PREPARSER ./calc input ./calc.at:1364: cat stderr stderr: ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: 487. calc.at:1357: ok ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Return for a new token: Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1355: cat stderr input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: | 1//2 ./calc.at:1364: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Return for a new token: Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Return for a new token: Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1362: cat stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 | (1 + 1) / (1 - 1) ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1355: $PREPARSER ./calc input ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1363: cat stderr input: 495. calc.at:1369: testing Calculator parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1369: mv calc.y.tmp calc.y ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 121): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1369: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1362: $PREPARSER ./calc input ./calc.at:1360: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: cat stderr stderr: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 118): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 119): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 138): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 121): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | 1//2 ./calc.at:1363: $PREPARSER ./calc input | (!!) + (1 2) = 1 ./calc.at:1360: $PREPARSER ./calc input stderr: ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 stderr: input: stdout: 496. calc.at:1370: testing Calculator parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} api.push-pull=both api.pure=full ... ./calc.at:1370: mv calc.y.tmp calc.y ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) ./calc.at:1358: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1367: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1370: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1364: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1369: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1355: cat stderr ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1367: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 486. calc.at:1355: ok ./calc.at:1362: cat stderr input: stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1367: $PREPARSER ./calc input ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error ./calc.at:1364: $PREPARSER ./calc input stderr: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1370: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 ./calc.at:1363: cat stderr | (!!) + (1 2) = 1 ./calc.at:1362: $PREPARSER ./calc input ./calc.at:1358: cat stderr stderr: ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1367: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1358: $PREPARSER ./calc input ./calc.at:1360: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 stderr: stderr: | error ./calc.at:1363: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Return for a new token: Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 | 1 2 ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1367: $PREPARSER ./calc input input: | (- *) + (1 2) = 1 ./calc.at:1360: $PREPARSER ./calc input ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Return for a new token: Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) 497. calc.at:1371: testing Calculator parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} api.push-pull=both api.pure=full parse.lac=full ... ./calc.at:1371: mv calc.y.tmp calc.y ./calc.at:1358: $EGREP -c -v 'Return for a new token:|LAC:' stderr syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1371: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !- ++ ./calc.at:1358: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1364: $PREPARSER ./calc input ./calc.at:1362: cat stderr stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Return for a new token: Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1363: cat stderr ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1362: $PREPARSER ./calc input ./calc.at:1367: cat stderr stderr: ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Return for a new token: Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 stderr: ./calc.at:1360: cat stderr | 1 = 2 = 3 ./calc.at:1363: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1371: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stdout: ./calc.at:1368: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' | 1//2 ./calc.at:1367: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: input: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1368: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (* *) + (*) + (*) ./calc.at:1358: cat stderr ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: cat stderr ./calc.at:1360: $PREPARSER ./calc input input: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1368: $PREPARSER ./calc input stderr: | 1 + 2 * 3 + !* ++ ./calc.at:1358: $PREPARSER ./calc input ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 19 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Return for a new token: Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | | +1 ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: $PREPARSER ./calc input stderr: stdout: ./calc.at:1362: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1369: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Return for a new token: Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Return for a new token: Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1367: cat stderr ./calc.at:1369: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c input: stderr: | (* *) + (*) + (*) ./calc.at:1362: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 stderr: ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: stderr: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error ./calc.at:1367: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1368: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: ./calc.at:1369: $PREPARSER ./calc input stderr: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1363: $PREPARSER ./calc input ./calc.at:1360: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1360: $PREPARSER ./calc input input: ./calc.at:1358: cat stderr ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 2 ./calc.at:1368: $PREPARSER ./calc input stderr: ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1369: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: input: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1358: $PREPARSER ./calc input input: ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1362: cat stderr stderr: | 1 2 ./calc.at:1369: $PREPARSER ./calc input ./calc.at:1364: cat stderr stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) stderr: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !+ ++ ./calc.at:1362: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1360: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: 1.2: syntax error: invalid character: '#' Reading a token Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: 1.8: syntax error: invalid character: '#' Reading a token Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1367: cat stderr stderr: stderr: ./calc.at:1364: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 130): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1362: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: 1.2: syntax error: invalid character: '#' Reading a token Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: 1.8: syntax error: invalid character: '#' Reading a token Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1368: cat stderr 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1360: $PREPARSER ./calc input input: | 1 + 2 * 3 + !- ++ ./calc.at:1362: $PREPARSER ./calc input ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1369: cat stderr input: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1363: cat stderr ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1368: $PREPARSER ./calc input ./calc.at:1367: $PREPARSER ./calc input stderr: ./calc.at:1358: cat stderr stderr: ./calc.at:1363: $PREPARSER ./calc /dev/null ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) | 1//2 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1369: $PREPARSER ./calc input ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1358: $PREPARSER ./calc input ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) stderr: stderr: 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Return for a new token: 1.6: syntax error: invalid character: '#' Reading a token Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 ./calc.at:1364: cat stderr ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1362: cat stderr stderr: ./calc.at:1367: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Return for a new token: 1.6: syntax error: invalid character: '#' Reading a token Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1360: cat stderr ./calc.at:1369: cat stderr input: stderr: input: ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1368: cat stderr stdout: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1364: $PREPARSER ./calc input | | +1 ./calc.at:1367: $PREPARSER ./calc input ./calc.at:1370: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: input: stderr: | 1 + 2 * 3 + !* ++ Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stdout: ./calc.at:1363: cat stderr ./calc.at:1362: $PREPARSER ./calc input ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1371: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' input: | 1 + 2 * 3 + !* ++ ./calc.at:1360: $PREPARSER ./calc input stderr: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1370: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c stderr: | error stderr: input: stderr: ./calc.at:1368: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1358: cat stderr syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: | error ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1369: $PREPARSER ./calc input ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1371: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: ./calc.at:1370: $PREPARSER ./calc input ./calc.at:1364: cat stderr stderr: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: input: ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1363: $PREPARSER ./calc input | (# + 1) = 1111 ./calc.at:1358: $PREPARSER ./calc input syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: stderr: ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1371: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 101): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 132): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: 1.2: syntax error: invalid character: '#' Reading a token Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1370: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: stderr: ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1368: cat stderr ./calc.at:1362: cat stderr | (!!) + (1 2) = 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: 1.2: syntax error: invalid character: '#' Reading a token Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1364: $PREPARSER ./calc input stderr: ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: ./calc.at:1367: cat stderr input: | 1 = 2 = 3 ./calc.at:1368: $PREPARSER ./calc input | 1 2 ./calc.at:1371: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: ./calc.at:1360: cat stderr ./calc.at:1370: $PREPARSER ./calc input input: stderr: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) stderr: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 21 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 21 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 21 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 21 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 21 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 21 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 21 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (#) + (#) = 2222 stderr: ./calc.at:1362: $PREPARSER ./calc input 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./calc.at:1369: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1367: $PREPARSER ./calc /dev/null ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1358: cat stderr stderr: stderr: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) input: ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (#) + (#) = 2222 | 1 2 stderr: ./calc.at:1363: cat stderr ./calc.at:1360: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1371: $PREPARSER ./calc input 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: stderr: stderr: ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 ./calc.at:1369: $PREPARSER ./calc input ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) stderr: ./calc.at:1368: cat stderr ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) input: input: | (!!) + (1 2) = 1 ./calc.at:1363: $PREPARSER ./calc input ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + # + 1) = 1111 ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: $PREPARSER ./calc input ./calc.at:1368: $PREPARSER ./calc input stderr: stderr: stderr: stderr: ./calc.at:1364: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Return for a new token: 1.6: syntax error: invalid character: '#' Reading a token Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) | (- *) + (1 2) = 1 ./calc.at:1364: $PREPARSER ./calc input stderr: stderr: stderr: stderr: ./calc.at:1370: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 Reducing stack by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1362: cat stderr 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Return for a new token: 1.6: syntax error: invalid character: '#' Reading a token Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Return for a new token: Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Return for a new token: Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1371: cat stderr stderr: ./calc.at:1368: cat stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | (1 + #) = 1111 ./calc.at:1362: $PREPARSER ./calc input ./calc.at:1368: $PREPARSER ./calc /dev/null stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1367: cat stderr | 1//2 ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1370: $PREPARSER ./calc input ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1358: cat stderr ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1371: $PREPARSER ./calc input stderr: 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1369: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1363: cat stderr ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1360: cat stderr input: ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1367: $PREPARSER ./calc input 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) stderr: | (1 + 1) / (1 - 1) input: ./calc.at:1358: $PREPARSER ./calc input | (1 + #) = 1111 syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) error: 4444 != 1 ./calc.at:1360: $PREPARSER ./calc input ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Return for a new token: Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Return for a new token: Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Return for a new token: Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Return for a new token: Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Return for a new token: Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Return for a new token: Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Return for a new token: Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Return for a new token: Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Return for a new token: Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Return for a new token: Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Return for a new token: Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Return for a new token: Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Return for a new token: Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Return for a new token: Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Return for a new token: Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1368: cat stderr stderr: stderr: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) error: 4444 != 1 | (- *) + (1 2) = 1 ./calc.at:1364: cat stderr ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: $PREPARSER ./calc input 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) stderr: stderr: 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: input: ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1368: $PREPARSER ./calc input ./calc.at:1371: cat stderr | | +1 ./calc.at:1369: $PREPARSER ./calc input ./calc.at:1370: cat stderr stderr: ./calc.at:1358: cat stderr ./calc.at:1367: cat stderr 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1362: cat stderr stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: input: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 | error ./calc.at:1371: $PREPARSER ./calc input input: ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 ./calc.at:1362: $PREPARSER ./calc input ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 488. calc.at:1358: ok stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) input: stderr: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1360: cat stderr | (* *) + (*) + (*) | error ./calc.at:1370: $PREPARSER ./calc input ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1368: cat stderr stderr: ./calc.at:1364: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (!!) + (1 2) = 1 ./calc.at:1367: $PREPARSER ./calc input stderr: input: ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 ./calc.at:1360: $PREPARSER ./calc input 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: cat stderr stderr: ./calc.at:1371: cat stderr ./calc.at:1369: cat stderr stderr: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1369: $PREPARSER ./calc /dev/null | (!!) + (1 2) = 1 ./calc.at:1368: $PREPARSER ./calc input ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: stderr: input: | (* *) + (*) + (*) ./calc.at:1363: $PREPARSER ./calc input 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 ./calc.at:1360: cat stderr ./calc.at:1370: cat stderr ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1362: cat stderr | 1 = 2 = 3 ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1371: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) stderr: ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: cat stderr 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) input: | 1 = 2 = 3 input: ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1370: $PREPARSER ./calc input stderr: input: | (1 + # + 1) = 1111 stderr: | (1 + # + 1) = 1111 ./calc.at:1362: $PREPARSER ./calc input ./calc.at:1360: $PREPARSER ./calc input 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 21 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 21 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1367: cat stderr input: stderr: stderr: ./calc.at:1368: cat stderr ./calc.at:1369: cat stderr 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 + !+ ++ ./calc.at:1364: $PREPARSER ./calc input ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 498. calc.at:1374: testing Calculator %start input exp NUM api.value.type=union ... ./calc.at:1374: mv calc.y.tmp calc.y ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1374: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y input: stderr: | (- *) + (1 2) = 1 ./calc.at:1367: $PREPARSER ./calc input stderr: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (- *) + (1 2) = 1 stderr: ./calc.at:1368: $PREPARSER ./calc input 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1369: $PREPARSER ./calc input ./calc.at:1371: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1363: cat stderr ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1370: cat stderr stderr: ./calc.at:1367: cat stderr ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 | | +1 ./calc.at:1371: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1364: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1363: $PREPARSER ./calc input 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 input: input: | | +1 ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) ./calc.at:1370: $PREPARSER ./calc input stderr: ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1367: $PREPARSER ./calc input ./calc.at:1360: cat stderr ./calc.at:1368: cat stderr input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1362: cat stderr | 1 + 2 * 3 + !- ++ stderr: ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: $PREPARSER ./calc input stderr: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) input: ./calc.at:1374: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1369: cat stderr stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (1 + 1) / (1 - 1) ./calc.at:1360: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 Reducing stack by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1363: $EGREP -c -v 'Return for a new token:|LAC:' stderr | (* *) + (*) + (*) ./calc.at:1368: $PREPARSER ./calc input stderr: stderr: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) | (1 + 1) / (1 - 1) ./calc.at:1371: cat stderr ./calc.at:1362: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: stderr: | (!!) + (1 2) = 1 ./calc.at:1369: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1371: $PREPARSER ./calc /dev/null 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1370: cat stderr stderr: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 | 1 + 2 * 3 + !- ++ ./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: $PREPARSER ./calc input 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: stderr: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1370: $PREPARSER ./calc /dev/null ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1367: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 126): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1364: cat stderr 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1368: cat stderr stderr: ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) input: ./calc.at:1369: cat stderr ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 Reducing stack by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: | 1 + 2 * 3 + !+ ++ ./calc.at:1367: $PREPARSER ./calc input stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) | 1 + 2 * 3 + !* ++ ./calc.at:1362: cat stderr ./calc.at:1364: $PREPARSER ./calc input input: ./calc.at:1360: cat stderr ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !+ ++ stderr: ./calc.at:1368: $PREPARSER ./calc input ./calc.at:1371: cat stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (- *) + (1 2) = 1 stderr: ./calc.at:1369: $PREPARSER ./calc input ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 490. calc.at:1362: 489. calc.at:1360: ok ok ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1370: cat stderr ./calc.at:1367: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: ./calc.at:1363: cat stderr 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 stderr: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 input: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1371: $PREPARSER ./calc input ./calc.at:1368: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1370: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ ./calc.at:1367: $PREPARSER ./calc input stderr: stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 stderr: stderr: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 input: ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 | 1 + 2 * 3 + !* ++ ./calc.at:1363: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ ./calc.at:1368: $PREPARSER ./calc input stderr: ./calc.at:1364: cat stderr ./calc.at:1369: cat stderr stderr: ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 stderr: input: | (* *) + (*) + (*) ./calc.at:1369: $PREPARSER ./calc input 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 stderr: | (#) + (#) = 2222 ./calc.at:1364: $PREPARSER ./calc input stderr: stderr: 499. calc.at:1375: testing Calculator %start input exp NUM api.value.type=union %locations parse.error=detailed ... ./calc.at:1375: mv calc.y.tmp calc.y 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 500. calc.at:1387: testing Calculator %glr-parser ... Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 Reducing stack by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1371: cat stderr stderr: ./calc.at:1375: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1387: mv calc.y.tmp calc.y Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.8: ) Error: discarding token "invalid token" (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1370: cat stderr ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1368: cat stderr ./calc.at:1367: cat stderr ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.8: ) Error: discarding token "invalid token" (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: | (!!) + (1 2) = 1 ./calc.at:1371: $PREPARSER ./calc input ./calc.at:1363: cat stderr | (!!) + (1 2) = 1 ./calc.at:1370: $PREPARSER ./calc input input: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) stderr: stderr: | 1 + 2 * 3 + !* ++ ./calc.at:1368: $PREPARSER ./calc input 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 input: stderr: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 1.14: memory exhausted ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !* ++ ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1367: $PREPARSER ./calc input ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (#) + (#) = 2222 ./calc.at:1369: cat stderr ./calc.at:1363: $PREPARSER ./calc input ./calc.at:1387: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1364: cat stderr memory exhausted stderr: ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 1.14: memory exhausted Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.8: ) Error: discarding token "invalid token" (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1375: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 stderr: input: ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1369: $PREPARSER ./calc input memory exhausted ./calc.at:1368: cat stderr input: ./calc.at:1371: cat stderr stderr: stderr: | (1 + #) = 1111 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token 1.8: syntax error: invalid character: '#' Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Next token is token "invalid token" (1.8: ) Error: discarding token "invalid token" (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1364: $PREPARSER ./calc input ./calc.at:1370: cat stderr stdout: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1374: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' input: | (#) + (#) = 2222 ./calc.at:1368: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (- *) + (1 2) = 1 ./calc.at:1371: $PREPARSER ./calc input ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: stderr: ./calc.at:1367: cat stderr | (- *) + (1 2) = 1 ./calc.at:1374: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1369: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1370: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: cat stderr stderr: ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' | (#) + (#) = 2222 input: ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1367: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1374: $PREPARSER ./calc input stderr: input: stderr: stderr: | (1 + #) = 1111 ./calc.at:1363: $PREPARSER ./calc input 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 syntax error: invalid character: '#' syntax error: invalid character: '#' | 1 + 2 * 3 + !- ++ ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1369: $PREPARSER ./calc input ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1368: cat stderr ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1364: cat stderr syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1374: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1371: cat stderr input: ./calc.at:1370: cat stderr stderr: stderr: | (1 + #) = 1111 ./calc.at:1368: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: input: 1.6: syntax error: invalid character: '#' ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (* *) + (*) + (*) ./calc.at:1371: $PREPARSER ./calc input | 1 2 | (# + 1) = 1111 ./calc.at:1364: $PREPARSER ./calc input ./calc.at:1374: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1367: cat stderr 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) input: stderr: | (* *) + (*) + (*) 1.6: syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1369: cat stderr ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1370: $PREPARSER ./calc input syntax error ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) input: ./calc.at:1363: cat stderr stderr: stderr: input: ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1368: cat stderr syntax error 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) stderr: ./calc.at:1367: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: | 1 + 2 * 3 + !* ++ ./calc.at:1369: $PREPARSER ./calc input stderr: input: syntax error: invalid character: '#' stderr: ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.14: memory exhausted input: | (# + 1) = 1111 ./calc.at:1363: $PREPARSER ./calc input stderr: ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1371: cat stderr | (# + 1) = 1111 ./calc.at:1368: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) syntax error: invalid character: '#' stderr: ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1370: cat stderr stderr: ./calc.at:1364: cat stderr 1.14: memory exhausted input: stderr: stderr: | 1 + 2 * 3 + !+ ++ 1.2: syntax error: invalid character: '#' ./calc.at:1371: $PREPARSER ./calc input stderr: ./calc.at:1369: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.2: ) Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1374: cat stderr input: ./calc.at:1367: cat stderr | 1 + 2 * 3 + !+ ++ | (1 + # + 1) = 1111 ./calc.at:1370: $PREPARSER ./calc input ./calc.at:1364: $PREPARSER ./calc input stderr: ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: input: ./calc.at:1368: cat stderr stderr: | (#) + (#) = 2222 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1369: $PREPARSER ./calc input | (# + 1) = 1111 ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1367: $PREPARSER ./calc input stderr: ./calc.at:1374: $PREPARSER ./calc input ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1371: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' input: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + # + 1) = 1111 stderr: stderr: ./calc.at:1368: $PREPARSER ./calc input ./calc.at:1363: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1370: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: input: syntax error syntax error: invalid character: '#' | 1 + 2 * 3 + !- ++ ./calc.at:1371: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' input: ./calc.at:1364: cat stderr | (1 + # + 1) = 1111 ./calc.at:1363: $PREPARSER ./calc input ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' | 1 + 2 * 3 + !- ++ ./calc.at:1370: $PREPARSER ./calc input stderr: ./calc.at:1367: cat stderr stderr: stderr: ./calc.at:1369: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1368: cat stderr | (1 + 1) / (1 - 1) input: ./calc.at:1364: $PREPARSER ./calc input | (1 + # + 1) = 1111 ./calc.at:1367: $PREPARSER ./calc input ./calc.at:1371: cat stderr stderr: input: stderr: stderr: | (1 + #) = 1111 ./calc.at:1369: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token 1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token "invalid token" (1.6: ) Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) syntax error: invalid character: '#' ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1374: cat stderr stderr: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.6: syntax error: invalid character: '#' input: | 1 + 2 * 3 + !* ++ ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + 1) / (1 - 1) ./calc.at:1371: $PREPARSER ./calc input stderr: ./calc.at:1368: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1370: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: input: ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11-17: error: null divisor ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.14: memory exhausted | error ./calc.at:1374: $PREPARSER ./calc input stderr: ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: ./calc.at:1363: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error | 1 + 2 * 3 + !* ++ stderr: ./calc.at:1370: $PREPARSER ./calc input stdout: ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11-17: error: null divisor stderr: ./calc.at:1375: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1367: cat stderr 1.14: memory exhausted ./calc.at:1369: cat stderr stderr: input: stderr: ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1375: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c 1.14: memory exhausted ./calc.at:1364: cat stderr ./calc.at:1368: cat stderr input: syntax error | (1 + 1) / (1 - 1) stderr: ./calc.at:1363: $PREPARSER ./calc input | (1 + 1) / (1 - 1) ./calc.at:1367: $PREPARSER ./calc input input: 1.14: memory exhausted stderr: stderr: 494. calc.at:1368: ok 492. calc.at:1364: ok | (# + 1) = 1111 input: ./calc.at:1369: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1371: cat stderr error: null divisor ./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1370: cat stderr stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: null divisor stderr: | (#) + (#) = 2222 input: ./calc.at:1371: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 23 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 Reducing stack by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (#) + (#) = 2222 stderr: ./calc.at:1370: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1375: $EGREP -c -v 'Return for a new token:|LAC:' stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1374: cat stderr ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1367: cat stderr ./calc.at:1363: cat stderr stderr: stderr: ./calc.at:1369: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' input: stdout: | 1 2 ./calc.at:1375: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./types.at:139: $PREPARSER ./test stderr: 493. calc.at:1367: ok 501. calc.at:1389: testing Calculator %glr-parser %header ... ./calc.at:1389: mv calc.y.tmp calc.y 1.3: syntax error, unexpected number ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y 491. calc.at:1363: ok input: stderr: | 1 = 2 = 3 ./calc.at:1371: cat stderr 502. calc.at:1390: testing Calculator %glr-parser %locations ... ./calc.at:1390: mv calc.y.tmp calc.y ./calc.at:1390: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1374: $PREPARSER ./calc input stderr: syntax error input: ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1370: cat stderr stderr: | (1 + # + 1) = 1111 ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1369: $PREPARSER ./calc input input: | (1 + #) = 1111 stderr: ./calc.at:1371: $PREPARSER ./calc input stderr: 1.3: syntax error, unexpected number ======== Testing with C++ standard flags: '' syntax error input: 1.6: syntax error: invalid character: '#' stderr: | (1 + #) = 1111 ./calc.at:1370: $PREPARSER ./calc input ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.6: syntax error: invalid character: '#' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./calc.at:1375: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1389: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1390: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 503. calc.at:1391: testing Calculator %glr-parser %locations api.location.type={Span} ... ./calc.at:1391: mv calc.y.tmp calc.y | 1//2 ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1369: cat stderr ./calc.at:1391: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: ./calc.at:1371: cat stderr 504. calc.at:1392: testing Calculator %glr-parser %name-prefix "calc" ... ./calc.at:1392: mv calc.y.tmp calc.y stderr: ./calc.at:1392: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1374: cat stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' input: stderr: | (1 + 1) / (1 - 1) ./calc.at:1369: $PREPARSER ./calc input input: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' | (# + 1) = 1111 ./calc.at:1371: $PREPARSER ./calc input stderr: input: ./calc.at:1370: cat stderr | | +1 ./calc.at:1374: $PREPARSER ./calc input 1.11-17: error: null divisor stderr: ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' input: ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1391: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: | (# + 1) = 1111 ./calc.at:1370: $PREPARSER ./calc input stderr: 1.11-17: error: null divisor stderr: stderr: ./calc.at:1375: cat stderr 1.2: syntax error: invalid character: '#' ./calc.at:1392: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS 1.2: syntax error: invalid character: '#' syntax error stderr: ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./calc.at:1369: cat stderr ./types.at:139: ./check input: stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./calc.at:1371: cat stderr | error ./calc.at:1375: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 495. calc.at:1369: ok stderr: ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error, unexpected invalid token ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1370: cat stderr input: | (1 + # + 1) = 1111 ./calc.at:1371: $PREPARSER ./calc input stderr: stderr: 1.1: syntax error, unexpected invalid token 1.6: syntax error: invalid character: '#' input: ./calc.at:1374: cat stderr | (1 + # + 1) = 1111 ./calc.at:1370: $PREPARSER ./calc input ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./calc.at:1374: $PREPARSER ./calc /dev/null ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.6: syntax error: invalid character: '#' stdout: 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1375: cat stderr ./calc.at:1387: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1387: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1371: cat stderr 1.6: syntax error: invalid character: '#' syntax error input: ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 505. calc.at:1393: testing Calculator %glr-parser api.prefix={calc} ... ./calc.at:1393: mv calc.y.tmp calc.y | 1 = 2 = 3 ./calc.at:1393: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1375: $PREPARSER ./calc input stderr: ./calc.at:1370: cat stderr stderr: input: input: 1.7: syntax error, unexpected '=' | (1 + 1) / (1 - 1) ./calc.at:1371: $PREPARSER ./calc input ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1387: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: syntax error ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.7: syntax error, unexpected '=' 1.11-17: error: null divisor | (1 + 1) / (1 - 1) ./calc.at:1370: $PREPARSER ./calc input stderr: stderr: 1.11-17: error: null divisor ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1374: cat stderr ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1393: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS 1.11-17: error: null divisor stderr: input: ./calc.at:1375: cat stderr 1.11-17: error: null divisor | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1374: $PREPARSER ./calc input stderr: ./calc.at:1371: cat stderr ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1370: cat stderr | | +1 497. calc.at:1371: ok ./calc.at:1375: $PREPARSER ./calc input stderr: 496. calc.at:1370: ok ./calc.at:1387: cat stderr stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 2.1: syntax error, unexpected '+' ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | 1//2 ./calc.at:1387: $PREPARSER ./calc input 2.1: syntax error, unexpected '+' stderr: ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error ./calc.at:1375: cat stderr 506. calc.at:1394: testing Calculator %glr-parser %verbose ... ./calc.at:1394: mv calc.y.tmp calc.y ./calc.at:1374: cat stderr ./calc.at:1394: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y 507. calc.at:1395: testing Calculator %glr-parser parse.error=verbose ... ./calc.at:1395: mv calc.y.tmp calc.y ./calc.at:1375: $PREPARSER ./calc /dev/null stderr: 1.1: syntax error, unexpected end of file ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: 1.1: syntax error, unexpected end of file ./calc.at:1395: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | (!!) + (1 2) = 1 ./calc.at:1374: $PREPARSER ./calc input ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error error: 2222 != 1 ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1375: cat stderr ./calc.at:1387: cat stderr ./calc.at:1395: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: syntax error error: 2222 != 1 ./calc.at:1394: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS input: | error ./calc.at:1387: $PREPARSER ./calc input input: stderr: stderr: syntax error | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stdout: ./types.at:139: $PREPARSER ./test ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1375: $PREPARSER ./calc input stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ======== Testing with C++ standard flags: '' ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: syntax error stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: stdout: ./calc.at:1374: cat stderr ./calc.at:1390: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1390: $PREPARSER ./calc input stderr: | (- *) + (1 2) = 1 ./calc.at:1374: $PREPARSER ./calc input ./calc.at:1375: cat stderr ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1387: cat stderr syntax error syntax error error: 2222 != 1 ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (!!) + (1 2) = 1 stderr: ./calc.at:1375: $PREPARSER ./calc input stderr: stderr: stderr: input: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 syntax error syntax error error: 2222 != 1 ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 input: ./calc.at:1390: $PREPARSER ./calc input stdout: ./types.at:139: ./check stderr: | 1 = 2 = 3 ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./calc.at:1387: $PREPARSER ./calc input stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 stderr: stderr: 1.3: syntax error syntax error ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1389: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h stderr: stderr: syntax error ./calc.at:1375: cat stderr 1.3: syntax error input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1389: $PREPARSER ./calc input input: ./calc.at:1374: cat stderr | (- *) + (1 2) = 1 ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1375: $PREPARSER ./calc input ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (* *) + (*) + (*) ./calc.at:1374: $PREPARSER ./calc input stderr: stderr: stderr: stderr: ./calc.at:1387: cat stderr ./calc.at:1390: cat stderr syntax error syntax error syntax error ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: input: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 stdout: ./calc.at:1391: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1392: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c stderr: | 1 2 ./calc.at:1389: $PREPARSER ./calc input input: input: | 1//2 ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1390: $PREPARSER ./calc input syntax error syntax error syntax error stderr: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: ./calc.at:1392: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1391: $PREPARSER ./calc input | | +1 ./calc.at:1387: $PREPARSER ./calc input syntax error 1.3: syntax error ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1375: cat stderr stderr: stderr: ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error 1.3: syntax error stderr: ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error input: input: input: ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) | 1 2 ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1374: cat stderr | 1 2 ./calc.at:1391: $PREPARSER ./calc input ./calc.at:1392: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1390: cat stderr stderr: ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1374: $PREPARSER ./calc input stderr: syntax error stderr: 1.3: syntax error ./calc.at:1389: cat stderr stderr: ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1393: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c input: | error ./calc.at:1390: $PREPARSER ./calc input input: ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1//2 stderr: ./calc.at:1387: cat stderr ./calc.at:1374: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1389: $PREPARSER ./calc input 1.1: syntax error stderr: ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: $PREPARSER ./calc input stderr: ./calc.at:1387: $PREPARSER ./calc /dev/null ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1375: cat stderr stderr: syntax error ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error 1.1: syntax error ./calc.at:1391: cat stderr input: stderr: stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1374: $PREPARSER ./calc input ./calc.at:1392: cat stderr syntax error stderr: input: input: input: | 1//2 ./calc.at:1391: $PREPARSER ./calc input ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1393: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1375: $PREPARSER ./calc input 1.3: syntax error stderr: ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: syntax error | 1//2 ./calc.at:1392: $PREPARSER ./calc input ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: stderr: ./calc.at:1389: cat stderr syntax error ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1390: cat stderr 1.3: syntax error stderr: ./calc.at:1375: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: input: syntax error ./calc.at:1387: cat stderr input: ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error | 1 = 2 = 3 ./calc.at:1390: $PREPARSER ./calc input ./calc.at:1389: $PREPARSER ./calc input stderr: stderr: ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.7: syntax error ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: syntax error ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !- ++ ./calc.at:1375: $PREPARSER ./calc input stderr: ./calc.at:1391: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1387: $PREPARSER ./calc input stderr: ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error stderr: ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.7: syntax error ./calc.at:1393: cat stderr stderr: input: stderr: ./calc.at:1374: cat stderr | error ./calc.at:1391: $PREPARSER ./calc input ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1392: cat stderr syntax error syntax error syntax error syntax error error: 4444 != 1 input: ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: 1.1: syntax error ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 | 1 + 2 * 3 + !* ++ ./calc.at:1393: $PREPARSER ./calc input ./calc.at:1374: $PREPARSER ./calc input stderr: input: ./calc.at:1390: cat stderr stderr: stderr: ./calc.at:1375: cat stderr memory exhausted ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error ./calc.at:1389: cat stderr syntax error | error ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: $PREPARSER ./calc input input: stderr: input: | | +1 ./calc.at:1390: $PREPARSER ./calc input syntax error ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 memory exhausted | 1 + 2 * 3 + !* ++ 2.1: syntax error ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1375: $PREPARSER ./calc input input: syntax error stderr: | 1 = 2 = 3 stderr: ./calc.at:1389: $PREPARSER ./calc input syntax error 1.14: memory exhausted ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: cat stderr stderr: syntax error stderr: ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 2.1: syntax error ./calc.at:1391: cat stderr stderr: stderr: input: ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error 1.14: memory exhausted | (!!) + (1 2) = 1 ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: $PREPARSER ./calc input input: ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error error: 2222 != 1 ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 ./calc.at:1391: $PREPARSER ./calc input stderr: ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1374: cat stderr 1.7: syntax error ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: cat stderr ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error error: 2222 != 1 ./calc.at:1375: cat stderr input: ./calc.at:1392: cat stderr stderr: ./calc.at:1390: $PREPARSER ./calc /dev/null 1.7: syntax error | (#) + (#) = 2222 stderr: ./calc.at:1393: cat stderr ./calc.at:1374: $PREPARSER ./calc input input: stderr: input: | (#) + (#) = 2222 1.1: syntax error ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1389: cat stderr ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: $PREPARSER ./calc input stderr: ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' | error ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: $PREPARSER ./calc input stderr: syntax error ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' 1.1: syntax error stderr: syntax error input: ./calc.at:1387: cat stderr ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | | +1 stdout: ./calc.at:1389: $PREPARSER ./calc input stderr: ./calc.at:1394: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' syntax error stderr: stderr: ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1391: cat stderr syntax error ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error input: input: ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 | (- *) + (1 2) = 1 stderr: ./calc.at:1387: $PREPARSER ./calc input ./calc.at:1394: $PREPARSER ./calc input ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error stderr: | | +1 ./calc.at:1391: $PREPARSER ./calc input ./calc.at:1390: cat stderr stderr: ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1375: cat stderr syntax error syntax error error: 2222 != 1 ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 2.1: syntax error input: ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1374: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1390: $PREPARSER ./calc input stderr: stderr: stderr: stderr: syntax error syntax error error: 2222 != 1 stdout: input: input: 2.1: syntax error 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 ./calc.at:1395: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1375: $PREPARSER ./calc input | 1 2 ./calc.at:1393: cat stderr input: ./calc.at:1394: $PREPARSER ./calc input ./calc.at:1392: cat stderr stderr: | (1 + #) = 1111 ./calc.at:1374: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' stderr: stderr: ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error input: ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 input: ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 syntax error: invalid character: '#' ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: cat stderr ./calc.at:1393: $PREPARSER ./calc input stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 input: ./calc.at:1395: $PREPARSER ./calc input ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1392: $PREPARSER ./calc input stderr: syntax error ./calc.at:1389: $PREPARSER ./calc /dev/null ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error 1.6: syntax error: invalid character: '#' ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error: invalid character: '#' stderr: stderr: stderr: syntax error syntax error ./calc.at:1391: cat stderr stderr: ./calc.at:1390: cat stderr ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: cat stderr ./calc.at:1391: $PREPARSER ./calc /dev/null input: syntax error | 1 2 stderr: ./calc.at:1375: cat stderr ./calc.at:1395: $PREPARSER ./calc input 1.1: syntax error ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: syntax error, unexpected number ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (!!) + (1 2) = 1 ./calc.at:1390: $PREPARSER ./calc input ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.1: syntax error | (* *) + (*) + (*) | (# + 1) = 1111 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1375: $PREPARSER ./calc input ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: $PREPARSER ./calc input syntax error, unexpected number stderr: stderr: syntax error syntax error syntax error stderr: ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1394: cat stderr ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: cat stderr ./calc.at:1389: cat stderr stderr: ./calc.at:1392: cat stderr stderr: ./calc.at:1374: cat stderr syntax error syntax error syntax error ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' input: ./calc.at:1392: $PREPARSER ./calc /dev/null | 1//2 ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1394: $PREPARSER ./calc input input: stderr: ./calc.at:1395: cat stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 syntax error ./calc.at:1389: $PREPARSER ./calc input ./calc.at:1391: cat stderr ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: syntax error ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1393: $PREPARSER ./calc input ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (# + 1) = 1111 ./calc.at:1374: $PREPARSER ./calc input stderr: syntax error stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 input: stderr: ./calc.at:1375: cat stderr ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1395: $PREPARSER ./calc input syntax error ./calc.at:1390: cat stderr syntax error: invalid character: '#' input: ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1391: $PREPARSER ./calc input stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 syntax error, unexpected '/', expecting number or '-' or '(' or '!' input: ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error syntax error: invalid character: '#' | (1 + # + 1) = 1111 ./calc.at:1375: $PREPARSER ./calc input 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 input: ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: cat stderr | (- *) + (1 2) = 1 stderr: stderr: ./calc.at:1390: $PREPARSER ./calc input stderr: stderr: syntax error, unexpected '/', expecting number or '-' or '(' or '!' 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 1.6: syntax error: invalid character: '#' ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 input: ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1392: cat stderr ./calc.at:1387: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 stderr: ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1394: cat stderr input: ./calc.at:1374: cat stderr ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1393: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1392: $PREPARSER ./calc input ./calc.at:1389: cat stderr ./calc.at:1395: cat stderr ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1375: cat stderr ./calc.at:1391: cat stderr input: input: syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1393: $PREPARSER ./calc /dev/null ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ input: stderr: ./calc.at:1387: $PREPARSER ./calc input input: input: | error ./calc.at:1394: $PREPARSER ./calc input | error syntax error ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 stderr: stderr: ./calc.at:1389: $PREPARSER ./calc input ./calc.at:1395: $PREPARSER ./calc input stderr: | (1 + # + 1) = 1111 ./calc.at:1374: $PREPARSER ./calc input ./calc.at:1390: cat stderr input: syntax error ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (!!) + (1 2) = 1 ./calc.at:1391: $PREPARSER ./calc input | (1 + 1) / (1 - 1) stderr: stderr: ./calc.at:1375: $PREPARSER ./calc input syntax error syntax error syntax error syntax error error: 4444 != 1 stderr: stderr: syntax error, unexpected invalid token syntax error error: 2222 != 1 ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error stderr: stderr: ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error 1.11-17: error: null divisor ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: stderr: syntax error error: 2222 != 1 stderr: | (* *) + (*) + (*) syntax error: invalid character: '#' syntax error, unexpected invalid token ./calc.at:1390: $PREPARSER ./calc input 1.11-17: error: null divisor ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1393: cat stderr ./calc.at:1392: cat stderr ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: cat stderr ./calc.at:1375: cat stderr ./calc.at:1394: cat stderr ./calc.at:1395: cat stderr input: ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1393: $PREPARSER ./calc input | (!!) + (1 2) = 1 input: input: ./calc.at:1374: cat stderr ./calc.at:1392: $PREPARSER ./calc input input: | 123 ./calc.at:1391: cat stderr ./calc.at:1389: cat stderr stderr: ./calc.at:1375: $PREPARSER ./calc --num input stderr: | 1 = 2 = 3 syntax error error: 2222 != 1 | 1 + 2 * 3 + !* ++ ./calc.at:1387: $PREPARSER ./calc input ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1394: $PREPARSER ./calc input stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 stderr: input: stderr: ./calc.at:1395: $PREPARSER ./calc input ./calc.at:1390: cat stderr syntax error input: ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr memory exhausted | (1 + 1) / (1 - 1) ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1374: $PREPARSER ./calc input stderr: | (- *) + (1 2) = 1 stderr: input: ./calc.at:1389: $PREPARSER ./calc input ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error error: 2222 != 1 stderr: syntax error, unexpected '=' syntax error syntax error syntax error syntax error error: 4444 != 1 stderr: error: null divisor ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error error: 2222 != 1 | (- *) + (1 2) = 1 ./calc.at:1391: $PREPARSER ./calc input ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr memory exhausted stderr: syntax error stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1375: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: error: null divisor syntax error syntax error error: 2222 != 1 | 1 + 2 * 3 + !+ ++ stderr: ./calc.at:1390: $PREPARSER ./calc input syntax error, unexpected '=' stderr: stderr: input: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 | 1 + 2 * 3 ./calc.at:1375: $PREPARSER ./calc --num input ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error, unexpected '+', expecting end of file ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: cat stderr input: ./calc.at:1392: cat stderr ./calc.at:1395: cat stderr stderr: ./calc.at:1374: cat stderr | 1 + 2 * 3 + !- ++ ./calc.at:1390: $PREPARSER ./calc input ./calc.at:1391: cat stderr ./calc.at:1394: cat stderr 1.3: syntax error, unexpected '+', expecting end of file stderr: ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1389: cat stderr input: | (!!) + (1 2) = 1 ./calc.at:1387: cat stderr input: ./calc.at:1393: $PREPARSER ./calc input input: | (- *) + (1 2) = 1 | 123 ./calc.at:1374: $PREPARSER ./calc --num input ./calc.at:1392: $PREPARSER ./calc input | | +1 stderr: input: ./calc.at:1395: $PREPARSER ./calc input ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: stderr: | | +1 stderr: stderr: syntax error error: 2222 != 1 input: ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1394: $PREPARSER ./calc input | (* *) + (*) + (*) syntax error, unexpected '+' ./calc.at:1391: $PREPARSER ./calc input input: stderr: ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error error: 2222 != 1 stderr: | (#) + (#) = 2222 ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: $PREPARSER ./calc input ./calc.at:1387: $PREPARSER ./calc input syntax error stderr: ./calc.at:1375: cat stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error syntax error stderr: syntax error error: 2222 != 1 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1374: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: syntax error, unexpected '+' syntax error input: syntax error syntax error error: 2222 != 1 1.2: syntax error 1.10: syntax error 1.16: syntax error | 1 + 2 * 3 stderr: ./calc.at:1375: $PREPARSER ./calc --exp input syntax error: invalid character: '#' syntax error: invalid character: '#' input: stderr: stderr: ./calc.at:1390: cat stderr | 1 + 2 * 3 ./calc.at:1374: $PREPARSER ./calc --num input syntax error syntax error syntax error ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !* ++ ./calc.at:1375: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1390: $PREPARSER ./calc input ./calc.at:1391: cat stderr stderr: ./calc.at:1393: cat stderr ./calc.at:1395: cat stderr stderr: ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.14: memory exhausted syntax error ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 499. calc.at:1375: ok ./calc.at:1392: cat stderr ./calc.at:1395: $PREPARSER ./calc /dev/null ./calc.at:1394: cat stderr input: stderr: input: syntax error, unexpected end of input ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1393: $PREPARSER ./calc input ./calc.at:1394: $PREPARSER ./calc /dev/null stderr: | 1 + 2 * 3 + !+ ++ stderr: ./calc.at:1391: $PREPARSER ./calc input ./calc.at:1389: cat stderr ./calc.at:1387: cat stderr syntax error syntax error error: 2222 != 1 1.14: memory exhausted input: ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected end of input ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) ./calc.at:1392: $PREPARSER ./calc input syntax error stderr: ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: syntax error syntax error error: 2222 != 1 ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | 1 + 2 * 3 + !+ ++ syntax error syntax error syntax error syntax error ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: $PREPARSER ./calc input ./calc.at:1374: cat stderr | (1 + #) = 1111 stderr: ./calc.at:1387: $PREPARSER ./calc input input: stderr: ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ stderr: ./calc.at:1391: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1390: cat stderr ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error syntax error ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 ./calc.at:1374: $PREPARSER ./calc --exp input 508. calc.at:1397: testing Calculator %glr-parser api.pure %locations ... stderr: stderr: ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1395: cat stderr ./calc.at:1397: mv calc.y.tmp calc.y stderr: | (#) + (#) = 2222 ./calc.at:1390: $PREPARSER ./calc input ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y syntax error: invalid character: '#' stderr: input: input: ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ ./calc.at:1389: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1395: $PREPARSER ./calc input stderr: ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1374: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1394: cat stderr ./calc.at:1393: cat stderr stderr: syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: ./calc.at:1392: cat stderr input: 498. calc.at:1374: ok input: stderr: syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 | (* *) + (*) + (*) ./calc.at:1393: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1394: $PREPARSER ./calc input ./calc.at:1397: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS syntax error syntax error syntax error ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1391: cat stderr stderr: ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error syntax error syntax error syntax error error: 4444 != 1 input: ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1392: $PREPARSER ./calc input syntax error syntax error syntax error stderr: stderr: ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1390: cat stderr syntax error syntax error syntax error syntax error error: 4444 != 1 input: ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1387: cat stderr | 1 + 2 * 3 + !* ++ ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1391: $PREPARSER ./calc input stderr: stderr: input: ./calc.at:1395: cat stderr input: 1.14: memory exhausted ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 | (1 + #) = 1111 ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: $PREPARSER ./calc input ./calc.at:1390: $PREPARSER ./calc input input: stderr: stderr: stderr: ./calc.at:1389: cat stderr syntax error: invalid character: '#' 1.6: syntax error: invalid character: '#' ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: $PREPARSER ./calc input 509. calc.at:1398: testing Calculator %glr-parser parse.error=verbose %locations ... ./calc.at:1398: mv calc.y.tmp calc.y input: 1.14: memory exhausted ./calc.at:1398: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | (!!) + (1 2) = 1 ./calc.at:1395: $PREPARSER ./calc input stderr: ./calc.at:1393: cat stderr input: stderr: | 1 + 2 * 3 + !* ++ ./calc.at:1389: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected number error: 2222 != 1 stderr: ./calc.at:1394: cat stderr ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' input: memory exhausted ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !+ ++ ./calc.at:1393: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected number error: 2222 != 1 input: memory exhausted | (!!) + (1 2) = 1 ./calc.at:1394: $PREPARSER ./calc input stderr: stderr: syntax error error: 2222 != 1 ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1391: cat stderr ./calc.at:1390: cat stderr ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1398: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error error: 2222 != 1 | 1 + 2 * 3 + !- ++ ./calc.at:1393: $PREPARSER ./calc input input: input: ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (#) + (#) = 2222 ./calc.at:1391: $PREPARSER ./calc input stderr: ./calc.at:1387: cat stderr ./calc.at:1395: cat stderr stderr: | (# + 1) = 1111 ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: cat stderr input: input: stderr: stderr: | (1 + # + 1) = 1111 ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1389: cat stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1387: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1395: $PREPARSER ./calc input stderr: stderr: 1.2: syntax error: invalid character: '#' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: syntax error: invalid character: '#' ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (#) + (#) = 2222 | 1 + 2 * 3 + !* ++ ./calc.at:1389: $PREPARSER ./calc input ./calc.at:1392: $PREPARSER ./calc input stderr: ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1394: cat stderr ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: memory exhausted ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' input: stderr: stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' | (- *) + (1 2) = 1 ./calc.at:1394: $PREPARSER ./calc input ./calc.at:1391: cat stderr memory exhausted stderr: syntax error syntax error error: 2222 != 1 ./calc.at:1390: cat stderr ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1393: cat stderr | (1 + #) = 1111 ./calc.at:1391: $PREPARSER ./calc input ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: input: ./calc.at:1395: cat stderr 1.6: syntax error: invalid character: '#' syntax error syntax error error: 2222 != 1 ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + # + 1) = 1111 input: ./calc.at:1390: $PREPARSER ./calc input | 1 + 2 * 3 + !* ++ ./calc.at:1393: $PREPARSER ./calc input stderr: ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1387: cat stderr 1.6: syntax error: invalid character: '#' 1.6: syntax error: invalid character: '#' ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (* *) + (*) + (*) ./calc.at:1395: $PREPARSER ./calc input memory exhausted ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1389: cat stderr ./calc.at:1392: cat stderr 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 memory exhausted | (1 + 1) / (1 - 1) ./calc.at:1387: $PREPARSER ./calc input ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' input: error: null divisor input: ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1391: cat stderr ./calc.at:1389: $PREPARSER ./calc input | (#) + (#) = 2222 ./calc.at:1392: $PREPARSER ./calc input ./calc.at:1394: cat stderr stderr: stderr: error: null divisor stderr: input: syntax error: invalid character: '#' ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: cat stderr input: | (* *) + (*) + (*) ./calc.at:1394: $PREPARSER ./calc input syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 ./calc.at:1391: $PREPARSER ./calc input ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' stderr: 1.2: syntax error: invalid character: '#' syntax error syntax error syntax error ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' syntax error: invalid character: '#' | (1 + 1) / (1 - 1) stderr: ./calc.at:1390: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1395: cat stderr syntax error syntax error syntax error stderr: ./calc.at:1393: cat stderr 1.11-17: error: null divisor ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1387: cat stderr ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | (#) + (#) = 2222 stderr: ./calc.at:1393: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1395: $PREPARSER ./calc input ./calc.at:1391: cat stderr ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + # + 1) = 1111 stdout: ./calc.at:1391: $PREPARSER ./calc input ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1389: cat stderr ./calc.at:1397: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 500. calc.at:1387: ok ./calc.at:1392: cat stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: stderr: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1397: $PREPARSER ./calc input input: | 1 + 2 * 3 + !- ++ ./calc.at:1390: cat stderr stderr: ./calc.at:1395: $PREPARSER ./calc input ./calc.at:1394: cat stderr stderr: | (# + 1) = 1111 1.6: syntax error: invalid character: '#' syntax error: invalid character: '#' syntax error: invalid character: '#' | (1 + #) = 1111 ./calc.at:1389: $PREPARSER ./calc input stderr: ./calc.at:1392: $PREPARSER ./calc input ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 502. calc.at:1390: stderr: ok stderr: input: ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error: invalid character: '#' ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1394: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' input: stderr: | 1 2 stderr: ./calc.at:1397: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1391: cat stderr 1.3: syntax error input: ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 510. calc.at:1400: testing Calculator %glr-parser parse.error=custom %locations %header %name-prefix "calc" %verbose ... ./calc.at:1400: mv calc.y.tmp calc.y ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !- ++ stderr: ./calc.at:1394: $PREPARSER ./calc input ./calc.at:1393: cat stderr ./calc.at:1395: cat stderr stderr: 1.3: syntax error input: ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1400: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | (1 + 1) / (1 - 1) ./calc.at:1391: $PREPARSER ./calc input ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: 1.11-17: error: null divisor ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1393: $PREPARSER ./calc input input: stderr: | 1 + 2 * 3 + !* ++ ./calc.at:1395: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: cat stderr stderr: stderr: ./calc.at:1389: cat stderr 511. calc.at:1401: testing Calculator %glr-parser parse.error=custom %locations %header %name-prefix "calc" %verbose api.pure ... ./calc.at:1401: mv calc.y.tmp calc.y 1.11-17: error: null divisor memory exhausted ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' memory exhausted input: ./calc.at:1397: cat stderr ./calc.at:1401: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (# + 1) = 1111 ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1392: $PREPARSER ./calc input | (1 + # + 1) = 1111 ./calc.at:1389: $PREPARSER ./calc input ./calc.at:1400: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: syntax error: invalid character: '#' ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' input: ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1391: cat stderr ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1394: cat stderr | 1//2 ./calc.at:1397: $PREPARSER ./calc input syntax error: invalid character: '#' stderr: 503. calc.at:1391: ok syntax error: invalid character: '#' 1.3: syntax error ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1395: cat stderr input: ./calc.at:1393: cat stderr | 1 + 2 * 3 + !* ++ ./calc.at:1394: $PREPARSER ./calc input stderr: ./calc.at:1401: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS input: stderr: 1.3: syntax error | (#) + (#) = 2222 ./calc.at:1395: $PREPARSER ./calc input input: memory exhausted ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 ./calc.at:1393: $PREPARSER ./calc input syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error: invalid character: '#' ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr memory exhausted stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1392: cat stderr stderr: ./calc.at:1397: cat stderr ./calc.at:1389: cat stderr syntax error: invalid character: '#' 512. calc.at:1402: testing Calculator %glr-parser parse.error=detailed %locations %header %name-prefix "calc" %verbose ... input: ./calc.at:1402: mv calc.y.tmp calc.y ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error input: ./calc.at:1397: $PREPARSER ./calc input input: ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (1 + 1) / (1 - 1) | (1 + # + 1) = 1111 1.1: syntax error ./calc.at:1389: $PREPARSER ./calc input ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: $PREPARSER ./calc input ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1402: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: ./calc.at:1395: cat stderr syntax error: invalid character: '#' ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: null divisor ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1394: cat stderr 1.1: syntax error stderr: syntax error: invalid character: '#' input: stderr: ./calc.at:1393: cat stderr | (#) + (#) = 2222 ./calc.at:1394: $PREPARSER ./calc input error: null divisor ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | (1 + #) = 1111 ./calc.at:1395: $PREPARSER ./calc input syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' input: ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + # + 1) = 1111 ./calc.at:1393: $PREPARSER ./calc input stderr: ./calc.at:1397: cat stderr ./calc.at:1402: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS syntax error: invalid character: '#' syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: cat stderr input: stderr: syntax error: invalid character: '#' | 1 = 2 = 3 ./calc.at:1397: $PREPARSER ./calc input ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1389: cat stderr 1.7: syntax error | (1 + 1) / (1 - 1) ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: $PREPARSER ./calc input ./calc.at:1395: cat stderr stderr: 501. calc.at:1389: ok stderr: error: null divisor ./calc.at:1394: cat stderr ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.7: syntax error ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (# + 1) = 1111 input: ./calc.at:1395: $PREPARSER ./calc input stderr: ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + #) = 1111 stderr: error: null divisor ./calc.at:1394: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1393: cat stderr stderr: syntax error: invalid character: '#' ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./calc.at:1397: cat stderr syntax error: invalid character: '#' ./calc.at:1398: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c input: ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (1 + 1) / (1 - 1) ./calc.at:1393: $PREPARSER ./calc input syntax error: invalid character: '#' input: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: | | +1 ./calc.at:1398: $PREPARSER ./calc input ./calc.at:1397: $PREPARSER ./calc input error: null divisor stderr: ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 513. calc.at:1403: testing Calculator %glr-parser parse.error=verbose %locations %header %name-prefix "calc" %verbose ... ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1392: cat stderr 2.1: syntax error ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1403: mv calc.y.tmp calc.y ./calc.at:1395: cat stderr error: null divisor 504. calc.at:1392: ok stderr: ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 2.1: syntax error stderr: input: input: | 1 2 ./calc.at:1398: $PREPARSER ./calc input ./calc.at:1403: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | (1 + # + 1) = 1111 ./calc.at:1394: cat stderr ./calc.at:1395: $PREPARSER ./calc input stderr: ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.3: syntax error, unexpected number ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (# + 1) = 1111 stderr: ./calc.at:1394: $PREPARSER ./calc input stderr: ./calc.at:1397: cat stderr 1.3: syntax error, unexpected number syntax error: invalid character: '#' stderr: ./calc.at:1393: cat stderr syntax error: invalid character: '#' ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: $PREPARSER ./calc /dev/null ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1403: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: stderr: 1.1: syntax error ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1398: cat stderr 514. calc.at:1405: testing Calculator %glr-parser parse.error=custom %locations %header %name-prefix "calc" %verbose ... ./calc.at:1405: mv calc.y.tmp calc.y syntax error: invalid character: '#' 505. calc.at:1393: ok ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.1: syntax error ./calc.at:1395: cat stderr ./calc.at:1405: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y input: | 1//2 ./calc.at:1398: $PREPARSER ./calc input ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' | (1 + 1) / (1 - 1) ./calc.at:1395: $PREPARSER ./calc input ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: null divisor ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' error: null divisor ./calc.at:1397: cat stderr ./calc.at:1394: cat stderr ./calc.at:1405: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS input: ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 515. calc.at:1407: testing Calculator %glr-parser %debug ... | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1397: $PREPARSER ./calc input input: ./calc.at:1407: mv calc.y.tmp calc.y ./calc.at:1398: cat stderr | (1 + # + 1) = 1111 ./calc.at:1394: $PREPARSER ./calc input stderr: ./calc.at:1407: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1395: cat stderr stderr: input: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 | error ./calc.at:1398: $PREPARSER ./calc input syntax error: invalid character: '#' stderr: 1.1: syntax error, unexpected invalid token ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 507. calc.at:1395: ok stderr: ./calc.at:1407: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS 1.1: syntax error, unexpected invalid token ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1397: cat stderr ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (!!) + (1 2) = 1 ./calc.at:1398: cat stderr ./calc.at:1397: $PREPARSER ./calc input stderr: ./calc.at:1394: cat stderr 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 = 2 = 3 ./calc.at:1398: $PREPARSER ./calc input stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 stderr: 1.7: syntax error, unexpected '=' ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 516. calc.at:1408: testing Calculator %glr-parser parse.error=verbose %debug %locations %header %name-prefix "calc" %verbose ... ./calc.at:1408: mv calc.y.tmp calc.y | (1 + 1) / (1 - 1) ./calc.at:1394: $PREPARSER ./calc input stderr: error: null divisor ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.7: syntax error, unexpected '=' ./calc.at:1408: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: error: null divisor ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1398: cat stderr ./calc.at:1397: cat stderr input: ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1398: $PREPARSER ./calc input stderr: input: ./calc.at:1408: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS 2.1: syntax error, unexpected '+' | (- *) + (1 2) = 1 ./calc.at:1397: $PREPARSER ./calc input ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1394: cat stderr 2.1: syntax error, unexpected '+' stderr: 506. calc.at:1394: ok ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1398: cat stderr stderr: stdout: ./calc.at:1400: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1398: $PREPARSER ./calc /dev/null input: stderr: ./calc.at:1397: cat stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1400: $PREPARSER ./calc input stderr: 1.1: syntax error, unexpected end of input ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (* *) + (*) + (*) stderr: ./calc.at:1397: $PREPARSER ./calc input stderr: 1.1: syntax error, unexpected end of input stderr: stdout: input: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1401: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 517. calc.at:1409: testing Calculator %glr-parser parse.error=verbose %debug %locations %header api.prefix={calc} api.token.prefix={TOK_} %verbose ... ./calc.at:1409: mv calc.y.tmp calc.y | 1 2 ./calc.at:1400: $PREPARSER ./calc input ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: stderr: ./calc.at:1398: cat stderr 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1401: $PREPARSER ./calc input stderr: stderr: ./calc.at:1409: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1398: $PREPARSER ./calc input stderr: stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1400: cat stderr input: ./calc.at:1397: cat stderr | 1 2 ./calc.at:1401: $PREPARSER ./calc input stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: input: ./calc.at:1409: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: | 1//2 ./calc.at:1400: $PREPARSER ./calc input input: stdout: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1402: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h | 1 + 2 * 3 + !+ ++ ./calc.at:1397: $PREPARSER ./calc input 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1402: $PREPARSER ./calc input stderr: stderr: stderr: stderr: ./calc.at:1398: cat stderr 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) stdout: ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./types.at:139: $PREPARSER ./test | 1 + 2 * 3 + !- ++ ./calc.at:1397: $PREPARSER ./calc input input: ./calc.at:1401: cat stderr stderr: ./calc.at:1400: cat stderr | (!!) + (1 2) = 1 ./calc.at:1398: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 stderr: | 1 2 ./calc.at:1401: $PREPARSER ./calc input input: ./calc.at:1402: $PREPARSER ./calc input stderr: stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 stderr: 1.3: syntax error, unexpected number 452. types.at:139: ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ok | error 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1400: $PREPARSER ./calc input ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1398: cat stderr 1.3: syntax error, unexpected number stderr: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1397: cat stderr input: ./calc.at:1401: cat stderr | (- *) + (1 2) = 1 ./calc.at:1398: $PREPARSER ./calc input ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1400: cat stderr 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 | 1 + 2 * 3 + !* ++ ./calc.at:1397: $PREPARSER ./calc input input: ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: cat stderr stderr: | error ./calc.at:1401: $PREPARSER ./calc input 1.14: memory exhausted input: stderr: ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 ./calc.at:1400: $PREPARSER ./calc input 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: | 1//2 ./calc.at:1402: $PREPARSER ./calc input 1.14: memory exhausted stderr: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: 518. calc.at:1411: testing Calculator %glr-parser api.pure parse.error=verbose %debug %locations %header %name-prefix "calc" %verbose ... 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: mv calc.y.tmp calc.y ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) ./calc.at:1398: cat stderr ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1401: cat stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1400: cat stderr input: ./calc.at:1411: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y input: | (* *) + (*) + (*) ./calc.at:1398: $PREPARSER ./calc input ./calc.at:1397: cat stderr ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 ./calc.at:1401: $PREPARSER ./calc input stderr: input: | | +1 stderr: ./calc.at:1400: $PREPARSER ./calc input 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: cat stderr 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) input: ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: | (#) + (#) = 2222 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1397: $PREPARSER ./calc input stderr: stderr: stderr: stdout: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) input: ./calc.at:1403: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1411: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS | error 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1402: $PREPARSER ./calc input input: stderr: stderr: ./calc.at:1401: cat stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1403: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: ./calc.at:1398: cat stderr 1.1: syntax error, unexpected invalid token ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1400: cat stderr ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | | +1 ./calc.at:1401: $PREPARSER ./calc input 1.1: syntax error, unexpected invalid token input: ./calc.at:1400: $PREPARSER ./calc /dev/null | 1 + 2 * 3 + !+ ++ stderr: ./calc.at:1398: $PREPARSER ./calc input input: stderr: stderr: ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1403: $PREPARSER ./calc input stderr: ./calc.at:1397: cat stderr ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: 1.3: syntax error, unexpected number ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: cat stderr 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: input: input: | 1 + 2 * 3 + !- ++ | (1 + #) = 1111 ./calc.at:1398: $PREPARSER ./calc input ./calc.at:1397: $PREPARSER ./calc input stdout: stderr: ./calc.at:1405: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h 1.3: syntax error, unexpected number stderr: input: ./calc.at:1400: cat stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1401: cat stderr | 1 = 2 = 3 ./calc.at:1402: $PREPARSER ./calc input stderr: stderr: ./calc.at:1401: $PREPARSER ./calc /dev/null input: 1.7: syntax error, unexpected '=' ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 1.6: syntax error: invalid character: '#' 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1405: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1403: cat stderr ./calc.at:1400: $PREPARSER ./calc input stderr: ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.7: syntax error, unexpected '=' ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1//2 ./calc.at:1403: $PREPARSER ./calc input stderr: ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1398: cat stderr stderr: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1401: cat stderr | 1 2 ./calc.at:1405: $PREPARSER ./calc input stderr: ./calc.at:1400: cat stderr stderr: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1402: cat stderr 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1397: cat stderr | 1 + 2 * 3 + !* ++ stderr: ./calc.at:1398: $PREPARSER ./calc input 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1401: $PREPARSER ./calc input | | +1 ./calc.at:1402: $PREPARSER ./calc input stderr: input: 1.14: memory exhausted 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1403: cat stderr stderr: input: | (!!) + (1 2) = 1 ./calc.at:1400: $PREPARSER ./calc input 2.1: syntax error, unexpected '+' | (# + 1) = 1111 ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: $PREPARSER ./calc input stderr: ./calc.at:1405: cat stderr stderr: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 stderr: stderr: ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.14: memory exhausted 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 stderr: 2.1: syntax error, unexpected '+' stderr: | error stderr: ./calc.at:1403: $PREPARSER ./calc input stdout: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 input: 1.2: syntax error: invalid character: '#' stderr: ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error, unexpected invalid token ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c | 1//2 ./calc.at:1405: $PREPARSER ./calc input ./calc.at:1401: cat stderr stderr: ./calc.at:1398: cat stderr input: ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1400: cat stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 1.1: syntax error, unexpected invalid token ./calc.at:1402: cat stderr ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 7) Shifting token "number" (1.1: 7) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 7) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 7) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 10 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -3) Entering state 31 Next token is token '=' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: -3) -> $$ = nterm exp (1.1: -6) Entering state 30 Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: -6) -> $$ = nterm exp (1.1: -5) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 5) Shifting token "number" (1.1: 5) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 5) -> $$ = nterm exp (1.1: 5) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 5) -> $$ = nterm exp (1.1: -5) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -5) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -5) -> $$ = nterm exp (1.1: -5) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -5) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 10 Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: -1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 10 Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 1) Entering state 10 Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 29 Reading a token Next token is token '-' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: -1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -4) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 4) Shifting token "number" (1.1: 4) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 4) -> $$ = nterm exp (1.1: 4) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 4) -> $$ = nterm exp (1.1: -4) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -4) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -4) -> $$ = nterm exp (1.1: -4) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -4) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 2) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -1) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 29 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 2) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 8) Entering state 33 Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 8) -> $$ = nterm exp (1.1: 256) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 256) Shifting token "number" (1.1: 256) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 256) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 256) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 4) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 4) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 4) Entering state 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 4) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 64) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 64) Shifting token "number" (1.1: 64) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 64) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 64) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: $PREPARSER ./calc /dev/null 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) | (!!) + (1 2) = 1 ./calc.at:1401: $PREPARSER ./calc input stderr: | (#) + (#) = 2222 ./calc.at:1398: $PREPARSER ./calc input ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' 1.1: syntax error, unexpected end of file ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' | (- *) + (1 2) = 1 stderr: ./calc.at:1400: $PREPARSER ./calc input 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1403: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 7) Shifting token "number" (1.1: 7) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 7) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 7) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 7) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 10 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -3) Entering state 31 Next token is token '=' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: -3) -> $$ = nterm exp (1.1: -6) Entering state 30 Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: -6) -> $$ = nterm exp (1.1: -5) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 5) Shifting token "number" (1.1: 5) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 5) -> $$ = nterm exp (1.1: 5) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 5) -> $$ = nterm exp (1.1: -5) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -5) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -5) -> $$ = nterm exp (1.1: -5) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -5) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 10 Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: -1) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 1) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 10 Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 1) Entering state 10 Next token is token '=' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: -1) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -1) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -1) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 29 Reading a token Next token is token '-' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: -1) Entering state 8 Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: -1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -4) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token "number" (1.1: 4) Shifting token "number" (1.1: 4) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 4) -> $$ = nterm exp (1.1: 4) Entering state 10 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 11 (line 116): $1 = token '-' (1.1: ) $2 = nterm exp (1.1: 4) -> $$ = nterm exp (1.1: -4) Entering state 28 Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: -4) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: -4) -> $$ = nterm exp (1.1: -4) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: -4) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 29 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 2) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: -1) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: -1) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: -1) Entering state 29 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: -1) -> $$ = nterm exp (1.1: 2) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 8) Entering state 33 Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 8) -> $$ = nterm exp (1.1: 256) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 256) Shifting token "number" (1.1: 256) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 256) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 256) -> $$ = nterm exp (1.1: 256) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 256) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 33 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 2) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 4) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 4) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 4) Entering state 8 Reading a token Next token is token '^' (1.1: ) Shifting token '^' (1.1: ) Entering state 24 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 33 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 12 (line 117): $1 = nterm exp (1.1: 4) $2 = token '^' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 64) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 64) Shifting token "number" (1.1: 64) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 64) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 64) -> $$ = nterm exp (1.1: 64) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 64) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 18 Reducing stack 0 by rule 2 (line 72): $1 = nterm input (1.1: ) $2 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1405: cat stderr ./calc.at:1397: cat stderr stderr: stderr: stderr: 1.1: syntax error, unexpected end of file input: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | 1 = 2 = 3 ./calc.at:1403: $PREPARSER ./calc input | 1 2 stderr: ./calc.at:1407: $PREPARSER ./calc input input: stdout: ./calc.at:1408: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.1: 2) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1401: cat stderr | error ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 stderr: ./calc.at:1405: $PREPARSER ./calc input stderr: 1.7: syntax error, unexpected '=' ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1398: cat stderr stderr: input: | (1 + # + 1) = 1111 1.7: syntax error, unexpected '=' ./calc.at:1397: $PREPARSER ./calc input stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1408: $PREPARSER ./calc input 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.1: 2) input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' | (- *) + (1 2) = 1 ./calc.at:1401: $PREPARSER ./calc input ./calc.at:1402: cat stderr ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1400: cat stderr stderr: stderr: stderr: stderr: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) | (1 + #) = 1111 ./calc.at:1398: $PREPARSER ./calc input 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1402: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' input: stderr: stderr: | 1 2 ./calc.at:1408: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1403: cat stderr | (* *) + (*) + (*) stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1405: cat stderr ./calc.at:1400: $PREPARSER ./calc input stderr: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stdout: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: cat stderr ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./types.at:139: $PREPARSER ./test 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: input: ./calc.at:1401: cat stderr ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1//2 ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1407: cat stderr input: input: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1397: cat stderr stderr: | 1 = 2 = 3 ./calc.at:1398: cat stderr ./calc.at:1405: $PREPARSER ./calc input | | +1 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1403: $PREPARSER ./calc input ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) 2.1: syntax error, unexpected '+' ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 451. types.at:139: ok stderr: ./calc.at:1400: cat stderr | (* *) + (*) + (*) ./calc.at:1401: $PREPARSER ./calc input ./calc.at:1402: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) | 1//2 ./calc.at:1407: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Reading a token Next token is token '/' (1.1: ) syntax error Error: popping token '/' (1.1: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (1 + 1) / (1 - 1) ./calc.at:1397: $PREPARSER ./calc input stderr: 2.1: syntax error, unexpected '+' stderr: input: 1.11-17: error: null divisor stderr: ./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) ./calc.at:1405: cat stderr ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: | (# + 1) = 1111 1.11-17: error: null divisor input: ./calc.at:1398: $PREPARSER ./calc input ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Reading a token Next token is token '/' (1.1: ) syntax error Error: popping token '/' (1.1: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.1: ) | (!!) + (1 2) = 1 ./calc.at:1403: cat stderr 1.2: syntax error: invalid character: '#' | 1 + 2 * 3 + !+ ++ ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: $PREPARSER ./calc input ./calc.at:1403: $PREPARSER ./calc /dev/null ./calc.at:1400: $PREPARSER ./calc input stderr: stderr: ./calc.at:1408: cat stderr 1.1: syntax error, unexpected end of input ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: stdout: ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1409: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) stderr: 1.1: syntax error, unexpected end of input | | +1 input: stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1405: $PREPARSER ./calc input stderr: stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 | error stderr: ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1397: cat stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ ./calc.at:1401: cat stderr ./calc.at:1400: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1409: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1398: cat stderr ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 519. calc.at:1413: testing Calculator %glr-parser api.pure parse.error=verbose %debug %locations %header %name-prefix "calc" %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1413: mv calc.y.tmp calc.y ./calc.at:1403: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '508. calc.at:1397: (' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ok ./calc.at:1407: cat stderr 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1402: cat stderr stderr: input: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 123): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 124): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) | 1 + 2 * 3 + !+ ++ input: ./calc.at:1401: $PREPARSER ./calc input input: | (1 + # + 1) = 1111 ./calc.at:1398: $PREPARSER ./calc input | 1 2 stderr: ./calc.at:1409: $PREPARSER ./calc input ./calc.at:1413: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: input: 1.6: syntax error: invalid character: '#' ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1405: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) input: ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1402: $PREPARSER ./calc input ./calc.at:1408: cat stderr stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 | error ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1403: $PREPARSER ./calc input stderr: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 stderr: stderr: ./calc.at:1400: cat stderr ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1405: $PREPARSER ./calc /dev/null ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) input: stderr: stderr: input: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 | 1 = 2 = 3 stderr: stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) | 1 + 2 * 3 + !- ++ ./calc.at:1401: $PREPARSER ./calc input ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) input: stderr: ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !* ++ ./calc.at:1413: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1400: $PREPARSER ./calc input ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1398: cat stderr stderr: stderr: ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1403: cat stderr 1.14: memory exhausted 520. calc.at:1414: testing Calculator %glr-parser api.pure parse.error=verbose %debug %locations %header api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: cat stderr ./calc.at:1409: cat stderr input: ./calc.at:1414: mv calc.y.tmp calc.y ./calc.at:1401: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1398: $PREPARSER ./calc input stderr: stderr: ./calc.at:1405: cat stderr input: ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.14: memory exhausted ./calc.at:1407: cat stderr 1.11-17: error: null divisor input: input: ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 ./calc.at:1403: $PREPARSER ./calc input | (* *) + (*) + (*) | 1//2 ./calc.at:1402: $PREPARSER ./calc input ./calc.at:1414: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y input: ./calc.at:1409: $PREPARSER ./calc input stderr: stderr: stderr: | 1 + 2 * 3 + !* ++ ./calc.at:1401: $PREPARSER ./calc input 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: cat stderr 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 1.11-17: error: null divisor stderr: ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1400: cat stderr input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) stderr: ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: 1.14: memory exhausted ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 stderr: ./calc.at:1405: $PREPARSER ./calc input | 1 = 2 = 3 input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1407: $PREPARSER ./calc input 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | | +1 ./calc.at:1408: $PREPARSER ./calc input input: stderr: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 stderr: ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 stderr: ./calc.at:1400: $PREPARSER ./calc input 1.14: memory exhausted Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Reading a token Next token is token '=' (1.1: ) syntax error Error: popping nterm exp (1.1: 2) Error: popping token '=' (1.1: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1398: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 509. calc.at:1398: ok stderr: ./calc.at:1401: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 28 Reading a token Next token is token '=' (1.1: ) syntax error Error: popping nterm exp (1.1: 2) Error: popping token '=' (1.1: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.1: ) stderr: ./calc.at:1414: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) stderr: ./calc.at:1402: cat stderr ./calc.at:1403: cat stderr ./calc.at:1409: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' input: ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1405: cat stderr | (#) + (#) = 2222 input: ./calc.at:1401: $PREPARSER ./calc input input: input: | 1 + 2 * 3 + !+ ++ | (- *) + (1 2) = 1 | error ./calc.at:1409: $PREPARSER ./calc input ./calc.at:1402: $PREPARSER ./calc input ./calc.at:1403: $PREPARSER ./calc input stderr: ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1408: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1400: cat stderr stderr: stderr: stderr: input: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) | (!!) + (1 2) = 1 ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1405: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1408: $PREPARSER ./calc /dev/null stderr: ./calc.at:1407: cat stderr 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 input: stderr: ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1400: $PREPARSER ./calc input 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 stderr: stderr: input: ./calc.at:1401: cat stderr 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 input: 521. calc.at:1416: testing Calculator %glr-parser %no-lines api.pure parse.error=verbose %debug %locations %header api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1416: mv calc.y.tmp calc.y stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1407: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ ./calc.at:1402: $PREPARSER ./calc input ./calc.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y input: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) stderr: | (1 + #) = 1111 ./calc.at:1401: $PREPARSER ./calc input ./calc.at:1405: cat stderr ./calc.at:1409: cat stderr stderr: stderr: ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '+' (1.1: ) syntax error Error: popping nterm input (1.1: ) Cleanup: discarding lookahead token '+' (1.1: ) 1.6: syntax error: invalid character: '#' ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' input: ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1403: cat stderr | 1 = 2 = 3 ./calc.at:1409: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 3 Reducing stack 0 by rule 3 (line 76): $1 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Next token is token '+' (1.1: ) syntax error Error: popping nterm input (1.1: ) Cleanup: discarding lookahead token '+' (1.1: ) ./calc.at:1408: cat stderr input: stderr: stderr: | (- *) + (1 2) = 1 ./calc.at:1405: $PREPARSER ./calc input ./calc.at:1400: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 input: ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) | (* *) + (*) + (*) | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 input: ./calc.at:1403: $PREPARSER ./calc input ./calc.at:1408: $PREPARSER ./calc input stderr: ./calc.at:1402: cat stderr stderr: | (# + 1) = 1111 ./calc.at:1416: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1400: $PREPARSER ./calc input stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1401: cat stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1405: cat stderr input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1409: cat stderr ./calc.at:1407: cat stderr input: stderr: stderr: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' | 1 + 2 * 3 + !* ++ | (# + 1) = 1111 ./calc.at:1401: $PREPARSER ./calc input ./calc.at:1402: $PREPARSER ./calc input ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' stderr: stderr: 1.2: syntax error: invalid character: '#' input: input: ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: $PREPARSER ./calc /dev/null 1.14: memory exhausted ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1409: $PREPARSER ./calc input ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (* *) + (*) + (*) ./calc.at:1408: cat stderr ./calc.at:1405: $PREPARSER ./calc input stderr: stdout: stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1400: cat stderr 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Starting parse Entering state 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1411: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h 1.2: syntax error: invalid character: '#' ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1403: cat stderr stderr: 1.14: memory exhausted stderr: input: stderr: input: stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) | (!!) + (1 2) = 1 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Starting parse Entering state 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 input: ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1401: cat stderr ./calc.at:1411: $PREPARSER ./calc input input: stderr: | (1 + # + 1) = 1111 stderr: ./calc.at:1400: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1403: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 128): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1405: cat stderr ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' input: ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: cat stderr | (1 + # + 1) = 1111 ./calc.at:1401: $PREPARSER ./calc input stderr: ./calc.at:1409: cat stderr stderr: stderr: ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 128): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) 1.6: syntax error: invalid character: '#' input: input: ./calc.at:1409: $PREPARSER ./calc /dev/null input: ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' input: stderr: | 1 2 | 1 + 2 * 3 + !+ ++ | (#) + (#) = 2222 stderr: ./calc.at:1405: $PREPARSER ./calc input ./calc.at:1402: $PREPARSER ./calc input ./calc.at:1411: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ stderr: stderr: ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1403: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1400: cat stderr ./calc.at:1407: cat stderr ./calc.at:1408: cat stderr stderr: ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1401: cat stderr stderr: stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' input: input: input: | 1 + 2 * 3 + !- ++ ./calc.at:1405: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) stderr: | (1 + 1) / (1 - 1) | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 input: stderr: ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1400: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1408: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 2) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 3) Entering state 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token ')' (1.1: ) syntax error Error: popping token '+' (1.1: ) Error: popping nterm exp (1.1: 3) Shifting token error (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 31 Reading a token Next token is token '*' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 1) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token '*' (1.1: ) syntax error Error: popping token '*' (1.1: ) Error: popping nterm exp (1.1: 2) Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 3333) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 4444) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 4444) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 4444 != 1 -> $$ = nterm exp (1.1: 4444) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 4444) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: 1.11-17: error: null divisor ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (1 + 1) / (1 - 1) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 127): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1401: $PREPARSER ./calc input ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: cat stderr ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1411: cat stderr ./calc.at:1409: cat stderr stderr: stderr: 1.11-17: error: null divisor ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1403: cat stderr 1.11-17: error: null divisor stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 2) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 3) Entering state 12 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token ')' (1.1: ) syntax error Error: popping token '+' (1.1: ) Error: popping nterm exp (1.1: 3) Shifting token error (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 31 Reading a token Next token is token '*' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 1) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 12 Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token '*' (1.1: ) syntax error Error: popping token '*' (1.1: ) Error: popping nterm exp (1.1: 2) Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 3333) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 4444) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 4444) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 4444 != 1 -> $$ = nterm exp (1.1: 4444) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 4444) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 127): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1405: cat stderr input: stderr: | (1 + #) = 1111 input: ./calc.at:1402: $PREPARSER ./calc input 1.11-17: error: null divisor stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1400: cat stderr ./calc.at:1409: $PREPARSER ./calc input | 1//2 1.6: syntax error: invalid character: '#' ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: $PREPARSER ./calc input ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 510. calc.at:1400: | 1 + 2 * 3 + !* ++ input: ./calc.at:1403: $PREPARSER ./calc input ok ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.6: syntax error: invalid character: '#' ./calc.at:1408: cat stderr stderr: | 1 + 2 * 3 + !* ++ ./calc.at:1401: cat stderr ./calc.at:1405: $PREPARSER ./calc input stderr: 1.14: memory exhausted stderr: stderr: 1.14: memory exhausted ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 511. calc.at:1401: ok ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1407: cat stderr | (* *) + (*) + (*) ./calc.at:1408: $PREPARSER ./calc input stderr: stderr: stderr: 1.14: memory exhausted ./calc.at:1402: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.14: memory exhausted ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1405: cat stderr stderr: input: | (!!) + (1 2) = 1 ./calc.at:1409: cat stderr ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1411: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (# + 1) = 1111 ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1402: $PREPARSER ./calc input stderr: stderr: input: ./calc.at:1403: cat stderr 1.2: syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 16 Reducing stack 0 by rule 16 (line 121): $1 = token '!' (1.1: ) $2 = token '!' (1.1: ) Shifting token error (1.1: ) Entering state 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 | (#) + (#) = 2222 ./calc.at:1405: $PREPARSER ./calc input ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: $PREPARSER ./calc input input: stderr: stderr: input: 1.2: syntax error: invalid character: '#' | error ./calc.at:1411: $PREPARSER ./calc input ./calc.at:1408: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 128): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 522. calc.at:1426: testing Calculator lalr1.cc %header ... ./calc.at:1426: mv calc.y.tmp calc.y stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1403: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 16 Reducing stack 0 by rule 16 (line 121): $1 = token '!' (1.1: ) $2 = token '!' (1.1: ) Shifting token error (1.1: ) Entering state 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 128): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1426: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 523. calc.at:1431: testing Calculator C++ ... ./calc.at:1431: mv calc.y.tmp calc.y input: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) | 1 + 2 * 3 + !+ ++ ./calc.at:1408: $PREPARSER ./calc input stderr: ./calc.at:1431: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1402: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 129): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1405: cat stderr ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1409: cat stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1411: cat stderr ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | (1 + # + 1) = 1111 ./calc.at:1402: $PREPARSER ./calc input ./calc.at:1403: cat stderr stderr: | (1 + #) = 1111 stderr: ./calc.at:1405: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 129): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1426: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS input: 1.6: syntax error: invalid character: '#' | (- *) + (1 2) = 1 ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1409: $PREPARSER ./calc input stderr: input: 1.6: syntax error: invalid character: '#' | 1 + 2 * 3 + !- ++ | 1 = 2 = 3 ./calc.at:1411: $PREPARSER ./calc input ./calc.at:1408: $PREPARSER ./calc input stderr: ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 127): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1431: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1407: cat stderr ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) | (1 + #) = 1111 ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1403: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 130): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' stderr: stderr: 1.6: syntax error: invalid character: '#' stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 130): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (- *) + (1 2) = 1 ./calc.at:1407: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 127): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 9 Reducing stack 0 by rule 15 (line 120): $1 = token '-' (1.1: ) $2 = token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1405: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 2 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 9 Reducing stack 0 by rule 15 (line 120): $1 = token '-' (1.1: ) $2 = token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token "number" (1.1: 2) syntax error Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token "number" (1.1: 2) Error: discarding token "number" (1.1: 2) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1) error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) input: ./calc.at:1409: cat stderr ./calc.at:1408: cat stderr input: | (1 + 1) / (1 - 1) ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1402: $PREPARSER ./calc input ./calc.at:1411: cat stderr stderr: | (# + 1) = 1111 ./calc.at:1405: $PREPARSER ./calc input ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1403: cat stderr 1.11-17: error: null divisor | (* *) + (*) + (*) ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1409: $PREPARSER ./calc input input: stderr: input: stderr: | 1 + 2 * 3 + !* ++ ./calc.at:1408: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' | | +1 ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1407: cat stderr 1.11-17: error: null divisor Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 131): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (# + 1) = 1111 ./calc.at:1403: $PREPARSER ./calc input stderr: stderr: 1.2: syntax error: invalid character: '#' stderr: input: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) 1.2: syntax error: invalid character: '#' ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1405: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 131): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: stderr: ./calc.at:1411: cat stderr ./calc.at:1402: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 3333) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) 1.2: syntax error: invalid character: '#' ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: $PREPARSER ./calc /dev/null input: stderr: 512. calc.at:1402: ok ./calc.at:1409: cat stderr ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + # + 1) = 1111 stderr: ./calc.at:1405: $PREPARSER ./calc input ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 2222) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 3333) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 3333) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1408: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1403: cat stderr Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) | 1 + 2 * 3 + !+ ++ ./calc.at:1409: $PREPARSER ./calc input stderr: stderr: 1.6: syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 129): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (1 + # + 1) = 1111 ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1405: cat stderr ./calc.at:1403: $PREPARSER ./calc input ./calc.at:1411: cat stderr stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 129): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.6: syntax error: invalid character: '#' ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !- ++ ./calc.at:1409: $PREPARSER ./calc input stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 130): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + 1) / (1 - 1) ./calc.at:1405: $PREPARSER ./calc input 524. calc.at:1432: testing Calculator C++ %locations ... ./calc.at:1432: mv calc.y.tmp calc.y ./calc.at:1407: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1411: $PREPARSER ./calc input stderr: stderr: ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1432: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y 1.11-17: error: null divisor stdout: stderr: ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1416: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h 1.6: syntax error: invalid character: '#' ./calc.at:1408: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 130): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: input: 1.11-17: error: null divisor input: stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1407: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 input: ./calc.at:1416: $PREPARSER ./calc input stderr: | (1 + #) = 1111 ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 14 Reducing stack 0 by rule 17 (line 122): $1 = token '!' (1.1: ) $2 = token '+' (1.1: ) Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1405: cat stderr ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1409: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 514. calc.at:1405: ok stderr: ./calc.at:1403: cat stderr stderr: ./calc.at:1411: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 14 Reducing stack 0 by rule 17 (line 122): $1 = token '!' (1.1: ) $2 = token '+' (1.1: ) Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: input: stderr: | 1 + 2 * 3 + !- ++ Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) | 1 + 2 * 3 + !* ++ input: ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1409: $PREPARSER ./calc input input: | (1 + 1) / (1 - 1) stderr: ./calc.at:1403: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 13 Reducing stack 0 by rule 18 (line 123): $1 = token '!' (1.1: ) $2 = token '-' (1.1: ) Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (!!) + (1 2) = 1 ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 stderr: ./calc.at:1411: $PREPARSER ./calc input stderr: ./calc.at:1416: $PREPARSER ./calc input 1.11-17: error: null divisor Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 131): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1408: cat stderr stdout: stderr: ./calc.at:1414: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 13 Reducing stack 0 by rule 18 (line 123): $1 = token '!' (1.1: ) $2 = token '-' (1.1: ) Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) 1.11-17: error: null divisor ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 131): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (# + 1) = 1111 ./calc.at:1408: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1414: $PREPARSER ./calc input ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) 525. calc.at:1433: testing Calculator C++ %locations $NO_EXCEPTIONS_CXXFLAGS ... ./calc.at:1403: cat stderr stderr: ./calc.at:1433: mv calc.y.tmp calc.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1409: cat stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1433: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stdout: input: ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '('513. calc.at:1403: ok (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1411: cat stderr ./calc.at:1413: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.c calc.h | (#) + (#) = 2222 ./calc.at:1416: cat stderr ./calc.at:1409: $PREPARSER ./calc input ./calc.at:1407: cat stderr input: stderr: ./calc.at:1408: cat stderr | 1 2 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1414: $PREPARSER ./calc input ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 | (- *) + (1 2) = 1 stderr: ./calc.at:1411: $PREPARSER ./calc input | 1//2 ./calc.at:1413: $PREPARSER ./calc input ./calc.at:1416: $PREPARSER ./calc input input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) stderr: stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) | 1 + 2 * 3 + !* ++ ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1433: $CXX $CPPFLAGS $CXXFLAGS $NO_EXCEPTIONS_CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS | (1 + # + 1) = 1111 stderr: ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 15 Reducing stack 0 by rule 19 (line 124): $1 = token '!' (1.1: ) $2 = token '*' (1.1: ) memory exhausted Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 19 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 19 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 19 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 19 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 20 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 19 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 111): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 29 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 19 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 33 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 19 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 112): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 19 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Reducing stack 0 by rule 2 (line 79): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: stderr: ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 2) Shifting token "number" (1.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2) -> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 22 Reading a token Next token is token "number" (1.1: 3) Shifting token "number" (1.1: 3) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 3) -> $$ = nterm exp (1.1: 3) Entering state 31 Reading a token Next token is token '+' (1.1: ) Reducing stack 0 by rule 9 (line 100): $1 = nterm exp (1.1: 2) $2 = token '*' (1.1: ) $3 = nterm exp (1.1: 3) -> $$ = nterm exp (1.1: 6) Entering state 30 Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 6) -> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '!' (1.1: ) Shifting token '!' (1.1: ) Entering state 5 Reading a token Next token is token '*' (1.1: ) Shifting token '*' (1.1: ) Entering state 15 Reducing stack 0 by rule 19 (line 124): $1 = token '!' (1.1: ) $2 = token '*' (1.1: ) memory exhausted Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | 1 2 ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1413: $PREPARSER ./calc input stderr: ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: cat stderr ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 526. calc.at:1434: testing Calculator C++ %locations api.location.type={Span} ... ./calc.at:1434: mv calc.y.tmp calc.y ./calc.at:1416: cat stderr ./calc.at:1414: cat stderr ./calc.at:1411: cat stderr ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1408: cat stderr input: | (1 + #) = 1111 ./calc.at:1409: $PREPARSER ./calc input stderr: input: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) input: | error | 1//2 ./calc.at:1414: $PREPARSER ./calc input stderr: | (* *) + (*) + (*) ./calc.at:1411: $PREPARSER ./calc input ./calc.at:1416: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) | (1 + 1) / (1 - 1) ./calc.at:1408: $PREPARSER ./calc input ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: cat stderr ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 108): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 108): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1413: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) | (#) + (#) = 2222 ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1434: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) input: stderr: ./calc.at:1409: cat stderr ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 2222) Shifting token "number" (1.1: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: cat stderr ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1413: $PREPARSER ./calc input ./calc.at:1408: cat stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token Next token is token '=' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 2222) Shifting token "number" (1.1: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 2222) -> $$ = nterm exp (1.1: 2222) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1414: cat stderr input: input: ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 516. calc.at:1408: ok | 1 + 2 * 3 + !+ ++ ./calc.at:1411: $PREPARSER ./calc input stderr: | (# + 1) = 1111 ./calc.at:1409: $PREPARSER ./calc input stderr: ./calc.at:1416: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 23 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1414: $PREPARSER ./calc input stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) stderr: | 1 = 2 = 3 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1416: $PREPARSER ./calc input ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1413: cat stderr ./calc.at:1411: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) stderr: stderr: ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) input: stderr: ./calc.at:1409: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | error ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1413: $PREPARSER ./calc input ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: cat stderr input: stderr: ./calc.at:1414: cat stderr | (1 + #) = 1111 ./calc.at:1407: $PREPARSER ./calc input input: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) input: ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 527. calc.at:1435: testing Calculator C++ %header %locations parse.error=verbose %name-prefix "calc" %verbose ... ./calc.at:1435: mv calc.y.tmp calc.y | (1 + # + 1) = 1111 ./calc.at:1409: $PREPARSER ./calc input stderr: ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1416: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Error: popping token '+' (1.1: ) Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: cat stderr stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1435: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) | 1 = 2 = 3 ./calc.at:1414: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Error: popping token '+' (1.1: ) Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 + !* ++ ./calc.at:1411: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: cat stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1413: cat stderr ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1416: cat stderr ./calc.at:1435: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS input: | (#) + (#) = 2222 ./calc.at:1411: $PREPARSER ./calc input ./calc.at:1409: cat stderr ./calc.at:1407: cat stderr stderr: ./calc.at:1416: $PREPARSER ./calc /dev/null input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 = 2 = 3 ./calc.at:1413: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) stderr: input: ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stderr: ./calc.at:1431: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (1 + 1) / (1 - 1) ./calc.at:1409: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 108): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | (# + 1) = 1111 ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1414: cat stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1431: $PREPARSER ./calc input stderr: ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 106): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 108): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 28 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1431: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1416: cat stderr input: stderr: ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1414: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) stderr: ./calc.at:1411: cat stderr ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1409: cat stderr input: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) | 1 2 input: ./calc.at:1431: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1416: $PREPARSER ./calc input ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 517. calc.at:1409: ok ./calc.at:1413: cat stderr stderr: input: | (1 + #) = 1111 stderr: ./calc.at:1411: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: syntax error ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) syntax error stderr: input: stderr: | | +1 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1407: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: cat stderr ./calc.at:1411: cat stderr | (1 + # + 1) = 1111 ./calc.at:1407: $PREPARSER ./calc input stderr: ./calc.at:1414: cat stderr Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 83): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Error: popping token '+' (1.1: ) Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1414: $PREPARSER ./calc /dev/null ./calc.at:1431: cat stderr input: stderr: 528. calc.at:1437: testing Calculator C++ %locations parse.error=verbose api.prefix={calc} %verbose ... ./calc.at:1437: mv calc.y.tmp calc.y ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 stderr: ./calc.at:1416: $PREPARSER ./calc input | (# + 1) = 1111 Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1411: $PREPARSER ./calc input stderr: ./calc.at:1437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) Error: popping token '+' (1.1: ) Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token Next token is token '+' (1.1: ) Error: discarding token '+' (1.1: ) Reading a token Next token is token "number" (1.1: 1) Error: discarding token "number" (1.1: 1) Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token Next token is token "number" (1.1: 1111) Shifting token "number" (1.1: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 1111) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: cat stderr ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) | 1//2 ./calc.at:1413: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1431: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1437: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1411: cat stderr stderr: ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1414: cat stderr syntax error Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1407: cat stderr ./calc.at:1416: cat stderr input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1414: $PREPARSER ./calc input input: | (1 + 1) / (1 - 1) ./calc.at:1407: $PREPARSER ./calc input ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (1 + # + 1) = 1111 ./calc.at:1411: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 2) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 2) Entering state 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 29 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 0) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 0) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 0) Entering state 32 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 10 (line 101): $1 = nterm exp (1.1: 2) $2 = token '/' (1.1: ) $3 = nterm exp (1.1: 0) error: null divisor -> $$ = nterm exp (1.1: 2) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (- *) + (1 2) = 1 ./calc.at:1416: $PREPARSER ./calc input stderr: stderr: ./calc.at:1413: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 30 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 2) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 2) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 2) Entering state 8 Reading a token Next token is token '/' (1.1: ) Shifting token '/' (1.1: ) Entering state 23 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token Next token is token '-' (1.1: ) Shifting token '-' (1.1: ) Entering state 20 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 29 Reading a token Next token is token ')' (1.1: ) Reducing stack 0 by rule 8 (line 99): $1 = nterm exp (1.1: 1) $2 = token '-' (1.1: ) $3 = nterm exp (1.1: 1) -> $$ = nterm exp (1.1: 0) Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 27 Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) $2 = nterm exp (1.1: 0) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 0) Entering state 32 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 10 (line 101): $1 = nterm exp (1.1: 2) $2 = token '/' (1.1: ) $3 = nterm exp (1.1: 0) error: null divisor -> $$ = nterm exp (1.1: 2) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 Reducing stack 0 by rule 1 (line 71): $1 = nterm line (1.1: ) -> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (1.1: ) Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1431: cat stderr stderr: ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 input: ./calc.at:1413: $PREPARSER ./calc input | error stderr: ./calc.at:1431: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: cat stderr ./calc.at:1414: cat stderr syntax error ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error input: input: ./calc.at:1416: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1411: $PREPARSER ./calc input | (!!) + (1 2) = 1 ./calc.at:1414: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 21 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 21 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 21 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 22 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 19 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1407: cat stderr stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: 515. calc.at:1407: ok ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (* *) + (*) + (*) ./calc.at:1416: $PREPARSER ./calc input stderr: ./calc.at:1413: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1431: cat stderr ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1432: $PREPARSER ./calc input ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | (!!) + (1 2) = 1 ./calc.at:1413: $PREPARSER ./calc input ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: ./calc.at:1411: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 = 2 = 3 ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: $PREPARSER ./calc input stderr: ./calc.at:1432: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1414: cat stderr stderr: 518. calc.at:1411: ok stderr: syntax error ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: input: syntax error | (- *) + (1 2) = 1 ./calc.at:1416: cat stderr 529. calc.at:1438: testing Calculator C++ %locations parse.error=verbose %debug %name-prefix "calc" %verbose ... | 1 2 ./calc.at:1414: $PREPARSER ./calc input ./calc.at:1432: $PREPARSER ./calc input ./calc.at:1438: mv calc.y.tmp calc.y stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error input: ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1413: cat stderr stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1416: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: 1.3: syntax error ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (- *) + (1 2) = 1 ./calc.at:1413: $PREPARSER ./calc input ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 530. calc.at:1440: testing Calculator C++ %locations parse.error=verbose %debug api.prefix={calc} %verbose ... ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1440: mv calc.y.tmp calc.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1431: cat stderr ./calc.at:1414: cat stderr ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1438: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: input: | 1 + 2 * 3 + !- ++ stderr: ./calc.at:1416: $PREPARSER ./calc input | | +1 input: ./calc.at:1431: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 19 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1432: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (* *) + (*) + (*) stderr: ./calc.at:1414: $PREPARSER ./calc input syntax error ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1432: $PREPARSER ./calc input stderr: ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1413: cat stderr stderr: syntax error Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1440: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS 1.3: syntax error stderr: ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) ./calc.at:1413: $PREPARSER ./calc input 1.3: syntax error stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1416: cat stderr ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !* ++ ./calc.at:1416: $PREPARSER ./calc input ./calc.at:1414: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 21 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1431: cat stderr input: | 1 + 2 * 3 + !+ ++ ./calc.at:1431: $PREPARSER ./calc /dev/null ./calc.at:1414: $PREPARSER ./calc input ./calc.at:1432: cat stderr stderr: ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: syntax error ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1413: cat stderr | error ./calc.at:1432: $PREPARSER ./calc input stderr: stderr: stderr: syntax error Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) 1.1: syntax error ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | 1 + 2 * 3 + !- ++ stderr: ./calc.at:1414: $PREPARSER ./calc input ./calc.at:1416: cat stderr | 1 + 2 * 3 + !+ ++ stderr: ./calc.at:1413: $PREPARSER ./calc input 1.1: syntax error ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: input: | (#) + (#) = 2222 ./calc.at:1416: $PREPARSER ./calc input ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: cat stderr ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1432: cat stderr ./calc.at:1414: cat stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1431: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ ./calc.at:1413: $PREPARSER ./calc input stderr: stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !* ++ ./calc.at:1414: $PREPARSER ./calc input ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 ./calc.at:1432: $PREPARSER ./calc input stderr: ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: 1.7: syntax error ./calc.at:1416: cat stderr ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) syntax error syntax error syntax error syntax error error: 4444 != 1 stderr: ./calc.at:1434: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc input: 1.7: syntax error Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (1 + #) = 1111 ./calc.at:1416: $PREPARSER ./calc input ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1434: $PREPARSER ./calc input ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1414: cat stderr ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1413: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: ./calc.at:1434: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1432: cat stderr | (#) + (#) = 2222 ./calc.at:1414: $PREPARSER ./calc input ./calc.at:1431: cat stderr input: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 + !* ++ ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1413: $PREPARSER ./calc input stderr: | | +1 ./calc.at:1432: $PREPARSER ./calc input input: ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: | 1 2 ./calc.at:1434: $PREPARSER ./calc input | (!!) + (1 2) = 1 ./calc.at:1416: cat stderr ./calc.at:1431: $PREPARSER ./calc input stderr: stderr: 2.1: syntax error ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error error: 2222 != 1 ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 21 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: 2.1: syntax error syntax error error: 2222 != 1 | (# + 1) = 1111 1.3: syntax error ./calc.at:1416: $PREPARSER ./calc input ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1414: cat stderr ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: cat stderr | (1 + #) = 1111 ./calc.at:1414: $PREPARSER ./calc input stderr: ./calc.at:1434: cat stderr stderr: stdout: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1433: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1432: cat stderr ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1432: $PREPARSER ./calc /dev/null input: input: ./calc.at:1431: cat stderr | (#) + (#) = 2222 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 | 1//2 stderr: ./calc.at:1413: $PREPARSER ./calc input ./calc.at:1433: $PREPARSER ./calc input ./calc.at:1434: $PREPARSER ./calc input ./calc.at:1416: cat stderr stderr: stderr: 1.1: syntax error stderr: stderr: ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.3: syntax error ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: input: 1.1: syntax error | (1 + # + 1) = 1111 ./calc.at:1416: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1431: $PREPARSER ./calc input ./calc.at:1433: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.3: syntax error stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 21 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 19 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1414: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) syntax error syntax error error: 2222 != 1 ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1433: $PREPARSER ./calc input input: ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: | (# + 1) = 1111 ./calc.at:1414: $PREPARSER ./calc input 1.3: syntax error stderr: ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error error: 2222 != 1 stderr: ./calc.at:1413: cat stderr ./calc.at:1432: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: cat stderr stderr: 1.3: syntax error ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1432: $PREPARSER ./calc input | (1 + #) = 1111 ./calc.at:1413: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: stderr: ./calc.at:1416: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 | error ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: $PREPARSER ./calc input stderr: ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1431: cat stderr 1.1: syntax error ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 | (1 + 1) / (1 - 1) ./calc.at:1416: $PREPARSER ./calc input stderr: ./calc.at:1414: cat stderr ./calc.at:1433: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.1: syntax error ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) input: ./calc.at:1431: $PREPARSER ./calc input | 1//2 ./calc.at:1433: $PREPARSER ./calc input ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + # + 1) = 1111 ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1414: $PREPARSER ./calc input stderr: stderr: stderr: syntax error syntax error syntax error Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error ./calc.at:1413: cat stderr ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1432: cat stderr ./calc.at:1434: cat stderr stderr: stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (# + 1) = 1111 ./calc.at:1413: $PREPARSER ./calc input syntax error syntax error syntax error ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1416: cat stderr | (!!) + (1 2) = 1 ./calc.at:1432: $PREPARSER ./calc input ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 ./calc.at:1434: $PREPARSER ./calc input stderr: ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1414: cat stderr stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.7: syntax error ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 521. calc.at:1416: ok stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: stderr: 1.7: syntax error 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1433: cat stderr input: | (1 + 1) / (1 - 1) ./calc.at:1414: $PREPARSER ./calc input stdout: ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1431: cat stderr ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1413: cat stderr ./calc.at:1426: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | error ./calc.at:1433: $PREPARSER ./calc input ./calc.at:1434: cat stderr input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1426: $PREPARSER ./calc input stderr: ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: 1.1: syntax error stderr: ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + # + 1) = 1111 ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1413: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 + !+ ++ ./calc.at:1431: $PREPARSER ./calc input input: stderr: stderr: stderr: ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.1: syntax error stderr: | | +1 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stdout: ./calc.at:1432: cat stderr ./calc.at:1434: $PREPARSER ./calc input ./calc.at:1431: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1435: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1426: $EGREP -c -v 'Return for a new token:|LAC:' stderr 531. calc.at:1441: testing Calculator C++ %locations parse.error=verbose %debug api.prefix={calc} api.token.prefix={TOK_} %verbose ... stderr: ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1441: mv calc.y.tmp calc.y 2.1: syntax error ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1441: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1414: cat stderr ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: ./calc.at:1435: $PREPARSER ./calc input | 1 2 ./calc.at:1426: $PREPARSER ./calc input input: | (- *) + (1 2) = 1 2.1: syntax error ./calc.at:1432: $PREPARSER ./calc input stderr: stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1431: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 520. calc.at:1414: ok ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1433: cat stderr stderr: stderr: stderr: ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1435: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1441: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1434: cat stderr ./calc.at:1413: cat stderr input: ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1434: $PREPARSER ./calc /dev/null ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 ./calc.at:1433: $PREPARSER ./calc input stdout: stderr: stderr: input: 1.7: syntax error ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1437: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc 1.1: syntax error | 1 2 ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1435: $PREPARSER ./calc input ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + 1) / (1 - 1) 1.7: syntax error ./calc.at:1413: $PREPARSER ./calc input input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1437: $PREPARSER ./calc input stderr: stderr: stderr: 1.3: syntax error, unexpected number Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1426: cat stderr ./calc.at:1431: cat stderr input: ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error ./calc.at:1432: cat stderr | 1//2 ./calc.at:1426: $PREPARSER ./calc input stderr: 1.3: syntax error, unexpected number input: stderr: stderr: syntax error ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (#) + (#) = 2222 ./calc.at:1431: $PREPARSER ./calc input ./calc.at:1437: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: 532. calc.at:1443: testing Calculator C++ %header %locations parse.error=verbose %debug %name-prefix "calc" %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... stderr: input: ./calc.at:1443: mv calc.y.tmp calc.y syntax error ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) ./calc.at:1432: $PREPARSER ./calc input ./calc.at:1435: cat stderr stderr: stderr: ./calc.at:1443: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1433: cat stderr syntax error: invalid character: '#' syntax error: invalid character: '#' | 1 2 ./calc.at:1434: cat stderr ./calc.at:1437: $PREPARSER ./calc input input: ./calc.at:1413: cat stderr ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: | 1//2 ./calc.at:1435: $PREPARSER ./calc input 1.3: syntax error, unexpected number ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' input: ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 519. calc.at:1413: ok | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 | | +1 ./calc.at:1434: $PREPARSER ./calc input stderr: ./calc.at:1433: $PREPARSER ./calc input ./calc.at:1426: cat stderr stderr: ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.3: syntax error, unexpected number stderr: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 2.1: syntax error ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1443: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS input: stderr: | error ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1426: $PREPARSER ./calc input 2.1: syntax error ./calc.at:1432: cat stderr ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1431: cat stderr stderr: ./calc.at:1437: cat stderr syntax error ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: cat stderr ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !+ ++ ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1432: $PREPARSER ./calc input input: stderr: | (1 + #) = 1111 ./calc.at:1431: $PREPARSER ./calc input input: input: syntax error stderr: stderr: | 1//2 ./calc.at:1437: $PREPARSER ./calc input | error ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1435: $PREPARSER ./calc input ./calc.at:1433: cat stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' 533. calc.at:1445: testing Calculator C++ parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1445: mv calc.y.tmp calc.y ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1434: cat stderr 1.1: syntax error, unexpected invalid token ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1432: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: syntax error: invalid character: '#' ./calc.at:1433: $PREPARSER ./calc /dev/null ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' stderr: 1.1: syntax error ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error, unexpected invalid token input: | (!!) + (1 2) = 1 ./calc.at:1434: $PREPARSER ./calc input stderr: | 1 + 2 * 3 + !- ++ stderr: ./calc.at:1432: $PREPARSER ./calc input 1.1: syntax error ./calc.at:1426: cat stderr stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: cat stderr ./calc.at:1437: cat stderr stderr: stderr: input: ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11: syntax error 1.1-16: error: 2222 != 1 | 1 = 2 = 3 ./calc.at:1445: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1426: $PREPARSER ./calc input stderr: ./calc.at:1431: cat stderr input: ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 syntax error ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: $PREPARSER ./calc input input: stderr: input: ./calc.at:1433: cat stderr 1.7: syntax error, unexpected '=' | (# + 1) = 1111 ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error stderr: ./calc.at:1431: $PREPARSER ./calc input ./calc.at:1437: $PREPARSER ./calc input syntax error ./calc.at:1432: cat stderr stderr: stderr: stderr: syntax error: invalid character: '#' 1.7: syntax error, unexpected '=' input: ./calc.at:1434: cat stderr ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error, unexpected invalid token ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: input: ./calc.at:1433: $PREPARSER ./calc input syntax error: invalid character: '#' input: | (#) + (#) = 2222 stderr: ./calc.at:1432: $PREPARSER ./calc input ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (- *) + (1 2) = 1 ./calc.at:1434: $PREPARSER ./calc input stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error, unexpected invalid token stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1435: cat stderr 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 stderr: ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1426: cat stderr 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 input: ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1435: $PREPARSER ./calc input ./calc.at:1437: cat stderr stderr: ./calc.at:1431: cat stderr ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 2.1: syntax error, unexpected '+' input: ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1426: $PREPARSER ./calc input ./calc.at:1432: cat stderr stderr: input: stderr: ./calc.at:1433: cat stderr | 1 = 2 = 3 2.1: syntax error, unexpected '+' ./calc.at:1437: $PREPARSER ./calc input syntax error ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1434: cat stderr | (1 + # + 1) = 1111 input: ./calc.at:1431: $PREPARSER ./calc input stderr: | (1 + #) = 1111 ./calc.at:1432: $PREPARSER ./calc input stderr: 1.7: syntax error, unexpected '=' input: ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error | (!!) + (1 2) = 1 stderr: ./calc.at:1433: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1435: cat stderr | (* *) + (*) + (*) ./calc.at:1434: $PREPARSER ./calc input stderr: stderr: 1.7: syntax error, unexpected '=' syntax error: invalid character: '#' stderr: stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error 1.6: syntax error: invalid character: '#' ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1435: $PREPARSER ./calc /dev/null ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error, unexpected end of input 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: cat stderr stderr: ./calc.at:1426: cat stderr 1.1: syntax error, unexpected end of input ./calc.at:1426: $PREPARSER ./calc /dev/null ./calc.at:1433: cat stderr ./calc.at:1432: cat stderr input: ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | | +1 ./calc.at:1431: cat stderr ./calc.at:1437: $PREPARSER ./calc input syntax error stderr: ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 2.1: syntax error, unexpected '+' ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: input: | (- *) + (1 2) = 1 stderr: ./calc.at:1433: $PREPARSER ./calc input | (# + 1) = 1111 ./calc.at:1432: $PREPARSER ./calc input ./calc.at:1435: cat stderr syntax error stderr: | (1 + 1) / (1 - 1) stderr: stderr: ./calc.at:1431: $PREPARSER ./calc input 2.1: syntax error, unexpected '+' ./calc.at:1434: cat stderr 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' stderr: ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: error: null divisor ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1435: $PREPARSER ./calc input stderr: input: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 | 1 + 2 * 3 + !+ ++ stderr: stderr: ./calc.at:1434: $PREPARSER ./calc input ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: error: null divisor 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: cat stderr ./calc.at:1434: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1437: $PREPARSER ./calc /dev/null ./calc.at:1426: cat stderr stderr: ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error, unexpected end of input ./calc.at:1433: cat stderr ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: | 1 + 2 * 3 + !- ++ ./calc.at:1434: $PREPARSER ./calc input input: ./calc.at:1438: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1435: cat stderr stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: stderr: ./calc.at:1426: $PREPARSER ./calc input ./calc.at:1432: cat stderr input: stdout: ./calc.at:1431: cat stderr ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1: syntax error, unexpected end of input input: syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1440: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1438: $PREPARSER ./calc input | (* *) + (*) + (*) input: ./calc.at:1433: $PREPARSER ./calc input stderr: stderr: | (!!) + (1 2) = 1 ./calc.at:1435: $PREPARSER ./calc input input: 1.2: syntax error 1.10: syntax error 1.16: syntax error 523. calc.at:1431: ok stderr: ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + # + 1) = 1111 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1432: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1437: cat stderr syntax error syntax error syntax error syntax error error: 4444 != 1 stderr: ./calc.at:1440: $PREPARSER ./calc input 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): input: $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1438: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1437: $PREPARSER ./calc input 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 1.6: syntax error: invalid character: '#' ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: ./calc.at:1440: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1434: cat stderr input: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 ./calc.at:1438: $PREPARSER ./calc input input: input: ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | (#) + (#) = 2222 ./calc.at:1434: $PREPARSER ./calc input ./calc.at:1433: cat stderr | 1 2 ./calc.at:1440: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: cat stderr ./calc.at:1426: cat stderr stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1432: cat stderr 534. calc.at:1446: testing Calculator C++ %header %locations parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... input: ./calc.at:1446: mv calc.y.tmp calc.y input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 input: | 1 + 2 * 3 + !+ ++ ./calc.at:1433: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1435: $PREPARSER ./calc input stderr: stderr: | (!!) + (1 2) = 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1426: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: stderr: input: ./calc.at:1437: cat stderr ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 syntax error error: 2222 != 1 ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + 1) / (1 - 1) ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1432: $PREPARSER ./calc input stderr: ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.11-17: error: null divisor ./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1433: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: input: syntax error error: 2222 != 1 ./calc.at:1438: cat stderr stderr: | (!!) + (1 2) = 1 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1437: $PREPARSER ./calc input ./calc.at:1440: cat stderr stderr: input: stderr: 1.11-17: error: null divisor | 1 + 2 * 3 + !- ++ ./calc.at:1433: $PREPARSER ./calc input 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 input: input: ./calc.at:1434: cat stderr ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1//2 | 1//2 ./calc.at:1438: $PREPARSER ./calc input ./calc.at:1440: $PREPARSER ./calc input ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 stderr: ./calc.at:1446: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS | (1 + #) = 1111 ./calc.at:1434: $PREPARSER ./calc input ./calc.at:1435: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.6: syntax error: invalid character: '#' ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1426: cat stderr stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1432: cat stderr ./calc.at:1437: cat stderr | (* *) + (*) + (*) ./calc.at:1435: $PREPARSER ./calc input stderr: input: ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (- *) + (1 2) = 1 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1426: $PREPARSER ./calc input 524. calc.at:1432: ok input: stderr: ./calc.at:1440: cat stderr syntax error syntax error error: 2222 != 1 ./calc.at:1438: cat stderr ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1437: $PREPARSER ./calc input ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1433: cat stderr input: stderr: input: ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error | error syntax error syntax error error: 2222 != 1 ./calc.at:1438: $PREPARSER ./calc input ./calc.at:1440: $PREPARSER ./calc input stderr: ./calc.at:1434: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1433: $PREPARSER ./calc input 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1435: cat stderr stderr: input: stderr: stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 ./calc.at:1434: $PREPARSER ./calc input ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1435: $PREPARSER ./calc input ./calc.at:1437: cat stderr 1.2: syntax error: invalid character: '#' ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 535. calc.at:1448: testing Calculator C++ %header %locations api.location.file=none ... ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1448: mv calc.y.tmp calc.y stderr: ./calc.at:1426: cat stderr ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1438: cat stderr ./calc.at:1440: cat stderr input: 1.2: syntax error: invalid character: '#' stderr: ./calc.at:1448: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: | (* *) + (*) + (*) ./calc.at:1437: $PREPARSER ./calc input ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1435: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: | (* *) + (*) + (*) ./calc.at:1426: $PREPARSER ./calc input | 1 = 2 = 3 stderr: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' stderr: ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1438: $PREPARSER ./calc input stderr: ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 stdout: ./calc.at:1440: $PREPARSER ./calc input stderr: syntax error syntax error syntax error ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1441: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1433: cat stderr stderr: 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' | 1 + 2 * 3 + !- ++ ./calc.at:1435: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 stderr: ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error syntax error syntax error ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: input: ./calc.at:1434: cat stderr stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1441: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 | (1 + #) = 1111 ./calc.at:1433: $PREPARSER ./calc input ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1437: cat stderr ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + # + 1) = 1111 ./calc.at:1434: $PREPARSER ./calc input stderr: ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1448: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS 1.6: syntax error: invalid character: '#' ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1438: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1440: cat stderr stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1441: $EGREP -c -v 'Return for a new token:|LAC:' stderr 1.6: syntax error: invalid character: '#' | 1 + 2 * 3 + !+ ++ ./calc.at:1437: $PREPARSER ./calc input ./calc.at:1435: cat stderr input: ./calc.at:1426: cat stderr stderr: ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | | +1 ./calc.at:1438: $PREPARSER ./calc input ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 stderr: input: ./calc.at:1440: $PREPARSER ./calc input input: | (#) + (#) = 2222 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1435: $PREPARSER ./calc input ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 2 ./calc.at:1441: $PREPARSER ./calc input input: stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1437: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1426: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1433: cat stderr stderr: stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1434: cat stderr input: stderr: | 1 + 2 * 3 + !- ++ stderr: input: ./calc.at:1437: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 | (# + 1) = 1111 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 stderr: ./calc.at:1433: $PREPARSER ./calc input stderr: ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1426: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1441: cat stderr | (1 + 1) / (1 - 1) input: ./calc.at:1434: $PREPARSER ./calc input | 1//2 ./calc.at:1441: $PREPARSER ./calc input stderr: ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: 1.11-17: error: null divisor ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1435: cat stderr input: stderr: ./calc.at:1440: cat stderr ./calc.at:1438: $PREPARSER ./calc /dev/null ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1426: $PREPARSER ./calc input 1.11-17: error: null divisor input: ./calc.at:1440: $PREPARSER ./calc /dev/null ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1433: cat stderr ./calc.at:1435: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 stderr: ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1441: cat stderr stderr: ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1437: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 input: | (1 + # + 1) = 1111 ./calc.at:1433: $PREPARSER ./calc input ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.6: syntax error: invalid character: '#' input: 1.6: syntax error: invalid character: '#' ./calc.at:1434: cat stderr input: | error ./calc.at:1441: $PREPARSER ./calc input ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1440: cat stderr stderr: ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (#) + (#) = 2222 ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.6: syntax error: invalid character: '#' 526. calc.at:1434: ok stderr: ./calc.at:1438: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' input: ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1435: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1440: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1426: cat stderr stdout: stderr: ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1438: $PREPARSER ./calc input input: stderr: input: input: ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (# + 1) = 1111 ./calc.at:1433: cat stderr ./calc.at:1435: $PREPARSER ./calc input | (#) + (#) = 2222 ./calc.at:1426: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1445: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1441: cat stderr stderr: 1.2: syntax error: invalid character: '#' ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: cat stderr | (1 + 1) / (1 - 1) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1433: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' () Reducing stack by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' () Reducing stack by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' () Reducing stack by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' () Reducing stack by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' () Reducing stack by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: stderr: input: ./calc.at:1440: cat stderr ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' syntax error: invalid character: '#' 1.2: syntax error: invalid character: '#' input: stderr: 1.11-17: error: null divisor | 1 = 2 = 3 ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1441: $PREPARSER ./calc input stderr: | (1 + #) = 1111 ./calc.at:1437: $PREPARSER ./calc input input: 536. calc.at:1449: testing Calculator C++ %header %locations api.location.file="my-location.hh" ... ./calc.at:1449: mv calc.y.tmp calc.y stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' () Reducing stack by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Stack now 0 6 8 Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' () Reducing stack by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' () Reducing stack by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' () Reducing stack by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' () Reducing stack by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' () Reducing stack by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' () Reducing stack by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Stack now 0 6 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Stack now 0 6 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1445: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: | (!!) + (1 2) = 1 stderr: ./calc.at:1438: cat stderr 1.11-17: error: null divisor ./calc.at:1440: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: stderr: | 1 2 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1435: cat stderr ./calc.at:1445: $PREPARSER ./calc input ./calc.at:1449: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 | (!!) + (1 2) = 1 ./calc.at:1438: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Stack now 0 Cleanup: discarding lookahead token number (2) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1426: cat stderr ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + # + 1) = 1111 ./calc.at:1435: $PREPARSER ./calc input ./calc.at:1433: cat stderr ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: stderr: stderr: ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (1 + #) = 1111 ./calc.at:1426: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1437: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Stack now 0 Cleanup: discarding lookahead token number (2) Stack now 0 stderr: ./calc.at:1441: cat stderr 525. calc.at:1433: syntax error: invalid character: '#' ok ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1440: cat stderr stderr: stderr: ./calc.at:1449: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS syntax error: invalid character: '#' 1.6: syntax error: invalid character: '#' input: ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | | +1 input: ./calc.at:1441: $PREPARSER ./calc input | (# + 1) = 1111 ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (- *) + (1 2) = 1 ./calc.at:1440: $PREPARSER ./calc input ./calc.at:1437: $PREPARSER ./calc input stderr: ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1438: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 1.2: syntax error: invalid character: '#' ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1445: cat stderr ./calc.at:1435: cat stderr ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: | (- *) + (1 2) = 1 ./calc.at:1438: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 input: input: 1.2: syntax error: invalid character: '#' ./calc.at:1426: cat stderr stderr: | (1 + 1) / (1 - 1) ./calc.at:1435: $PREPARSER ./calc input | 1//2 ./calc.at:1445: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11-17: error: null divisor ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Stack now 0 8 Error: popping nterm exp (1) Stack now 0 Cleanup: discarding lookahead token '/' () Stack now 0 input: ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1441: cat stderr | (# + 1) = 1111 stderr: ./calc.at:1426: $PREPARSER ./calc input ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1437: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: stderr: syntax error: invalid character: '#' ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11-17: error: null divisor ./calc.at:1440: cat stderr ./calc.at:1441: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Stack now 0 8 Error: popping nterm exp (1) Stack now 0 Cleanup: discarding lookahead token '/' () Stack now 0 537. calc.at:1451: testing Calculator C++ %no-lines %header %locations api.location.file="my-location.hh" ... ./calc.at:1451: mv calc.y.tmp calc.y stderr: stderr: ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + # + 1) = 1111 ./calc.at:1451: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1437: $PREPARSER ./calc input syntax error: invalid character: '#' | (* *) + (*) + (*) ./calc.at:1440: $PREPARSER ./calc input ./calc.at:1438: cat stderr stderr: stderr: ./calc.at:1435: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 stderr: ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 527. calc.at:1435: ok stderr: ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.6: syntax error: invalid character: '#' input: ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: cat stderr | (* *) + (*) + (*) ./calc.at:1438: $PREPARSER ./calc input ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1441: cat stderr stderr: ./calc.at:1426: cat stderr ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1440: cat stderr ./calc.at:1451: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS | error ./calc.at:1445: $PREPARSER ./calc input input: stderr: stderr: ./calc.at:1437: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1441: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () Stack now 0 input: | (1 + # + 1) = 1111 ./calc.at:1426: $PREPARSER ./calc input ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | 1 + 2 * 3 + !+ ++ stderr: ./calc.at:1440: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' stderr: input: ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (1 + 1) / (1 - 1) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1437: $PREPARSER ./calc input stderr: stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () Stack now 0 syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of inp1.11-17: error: null divisor ut (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 538. calc.at:1453: testing Calculator C++ %locations parse.lac=full parse.error=verbose ... stderr: ./calc.at:1438: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1440: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1453: mv calc.y.tmp calc.y stderr: ./calc.at:1453: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !- ++ ./calc.at:1440: $PREPARSER ./calc input 1.11-17: error: null divisor input: ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1426: cat stderr ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1445: cat stderr stderr: ./calc.at:1453: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1441: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: input: ./calc.at:1437: cat stderr stderr: | 1 = 2 = 3 | (1 + 1) / (1 - 1) ./calc.at:1445: $PREPARSER ./calc input ./calc.at:1426: $PREPARSER ./calc input input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1438: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: 528. calc.at:1437: ok | (!!) + (1 2) = 1 ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1441: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Stack now 0 8 18 Error: popping token '=' () Stack now 0 8 Error: popping nterm exp (1) Stack now 0 Cleanup: discarding lookahead token '=' () Stack now 0 error: null divisor stderr: ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1440: cat stderr ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1438: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Stack now 0 8 18 Error: popping token '=' () Stack now 0 8 Error: popping nterm exp (1) Stack now 0 Cleanup: discarding lookahead token '=' () Stack now 0 error: null divisor stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1440: $PREPARSER ./calc input ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1441: cat stderr ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: cat stderr input: | (- *) + (1 2) = 1 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1441: $PREPARSER ./calc input 539. calc.at:1454: testing Calculator C++ %locations parse.lac=full parse.error=detailed ... stderr: ./calc.at:1438: cat stderr ./calc.at:1454: mv calc.y.tmp calc.y input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1445: $PREPARSER ./calc input stderr: ./calc.at:1454: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1426: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Stack now 0 Cleanup: discarding lookahead token '+' () Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (#) + (#) = 2222 ./calc.at:1438: $PREPARSER ./calc input ./calc.at:1440: cat stderr 522. calc.at:1426: stderr: ok stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Stack now 0 Cleanup: discarding lookahead token '+' () Stack now 0 ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + #) = 1111 ./calc.at:1440: $PREPARSER ./calc input ./calc.at:1441: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1454: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS | (* *) + (*) + (*) ./calc.at:1441: $PREPARSER ./calc input stderr: ./calc.at:1445: cat stderr ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1438: cat stderr ./calc.at:1445: $PREPARSER ./calc /dev/null stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input () syntax error, unexpected end of input Cleanup: discarding lookahead token end of input () Stack now 0 input: ./calc.at:1440: cat stderr 540. calc.at:1455: testing Calculator C++ %locations parse.lac=full parse.error=detailed parse.trace ... ./calc.at:1455: mv calc.y.tmp calc.y | (1 + #) = 1111 ./calc.at:1438: $PREPARSER ./calc input ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1455: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (# + 1) = 1111 ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1440: $PREPARSER ./calc input ./calc.at:1441: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input () syntax error, unexpected end of input Cleanup: discarding lookahead token end of input () Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1 + 2 * 3 + !+ ++ ./calc.at:1441: $PREPARSER ./calc input ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: cat stderr ./calc.at:1455: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1441: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1438: cat stderr ./calc.at:1440: cat stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1445: $PREPARSER ./calc input input: input: stderr: | (# + 1) = 1111 ./calc.at:1438: $PREPARSER ./calc input input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Stack now 0 8 20 4 12 Error: popping nterm exp (3) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' () Reducing stack by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Stack now 0 8 20 4 12 Error: popping nterm exp (2) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () | (1 + # + 1) = 1111 ./calc.at:1440: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ ./calc.at:1441: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Stack now 0 8 20 4 12 Error: popping nterm exp (3) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' () Reducing stack by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Stack now 0 8 20 4 12 Error: popping nterm exp (2) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1441: cat stderr stderr: ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: cat stderr stdout: ./calc.at:1440: cat stderr ./calc.at:1443: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1445: cat stderr input: input: | (#) + (#) = 2222 | (1 + # + 1) = 1111 ./calc.at:1438: $PREPARSER ./calc input ./calc.at:1441: $PREPARSER ./calc input input: input: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1443: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (1 + 1) / (1 - 1) ./calc.at:1440: $PREPARSER ./calc input ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (!!) + (1 2) = 1 ./calc.at:1445: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token number (2) Error: discarding token number (2) Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1443: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token number (2) Error: discarding token number (2) Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1438: cat stderr input: ./calc.at:1441: cat stderr | 1 2 ./calc.at:1443: $PREPARSER ./calc input ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 ./calc.at:1440: cat stderr input: | (1 + #) = 1111 | (1 + 1) / (1 - 1) ./calc.at:1441: $PREPARSER ./calc input ./calc.at:1438: $PREPARSER ./calc input stderr: ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1445: cat stderr 530. calc.at:1440: ok stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (- *) + (1 2) = 1 ./calc.at:1443: cat stderr ./calc.at:1445: $PREPARSER ./calc input ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' () $2 = token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token number (2) Error: discarding token number (2) Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1441: cat stderr ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1443: $PREPARSER ./calc input ./calc.at:1438: cat stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' () $2 = token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token number (2) Error: discarding token number (2) Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () 529. calc.at:1438: ok 541. calc.at:1457: testing Calculator C++ parse.error=custom ... | (# + 1) = 1111 ./calc.at:1441: $PREPARSER ./calc input ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1457: mv calc.y.tmp calc.y ./calc.at:1457: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1445: cat stderr ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1457: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (* *) + (*) + (*) ./calc.at:1445: $PREPARSER ./calc input stderr: ./calc.at:1441: cat stderr 542. calc.at:1458: testing Calculator C++ parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1458: mv calc.y.tmp calc.y Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' () Reducing stack by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1443: cat stderr ./calc.at:1458: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | error ./calc.at:1443: $PREPARSER ./calc input stderr: stderr: | (1 + # + 1) = 1111 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' () Reducing stack by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1441: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1458: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1445: cat stderr ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: cat stderr input: | 1 + 2 * 3 + !+ ++ ./calc.at:1441: cat stderr ./calc.at:1445: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Stack now 0 8 20 Cleanup: popping token '+' () Cleanup: popping nterm exp (7) input: ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 ./calc.at:1443: $PREPARSER ./calc input input: | (1 + 1) / (1 - 1) stderr: stderr: ./calc.at:1441: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Stack now 0 8 20 Cleanup: popping token '+' () Cleanup: popping nterm exp (7) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 stderr: ./calc.at:1445: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1445: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Stack now 0 8 20 Cleanup: popping token '+' () Cleanup: popping nterm exp (7) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1441: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' () Reducing stack by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Stack now 0 8 Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Stack now 0 8 20 Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1443: cat stderr 531. calc.at:1441: ok input: | | +1 ./calc.at:1443: $PREPARSER ./calc input ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1445: cat stderr ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (#) + (#) = 2222 ./calc.at:1445: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 543. calc.at:1459: testing Calculator C++ parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} parse.lac=full ... ./calc.at:1459: mv calc.y.tmp calc.y ./calc.at:1459: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: ./calc.at:1443: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1443: $PREPARSER ./calc /dev/null stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1459: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1445: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + #) = 1111 ./calc.at:1445: $PREPARSER ./calc input ./calc.at:1443: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 4 12 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Stack now 0 4 12 Error: popping nterm exp (1) Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () input: ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1443: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 4 12 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Stack now 0 4 12 Error: popping nterm exp (1) Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: cat stderr ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: input: ./calc.at:1443: cat stderr | (# + 1) = 1111 ./calc.at:1446: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1445: $PREPARSER ./calc input stderr: input: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' () Error: discarding token '+' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1) Error: discarding token number (1) Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () | (!!) + (1 2) = 1 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1446: $PREPARSER ./calc input ./calc.at:1443: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' () Error: discarding token '+' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1) Error: discarding token number (1) Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (14.1: ) Shifting token end of input (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1446: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: cat stderr | 1 2 ./calc.at:1446: $PREPARSER ./calc input stderr: ./calc.at:1445: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 stderr: stderr: input: input: stdout: ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1443: $PREPARSER ./calc input | (1 + # + 1) = 1111 ./calc.at:1445: $PREPARSER ./calc input stdout: ./calc.at:1448: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh stderr: stderr: ./calc.at:1453: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 4 12 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Stack now 0 4 12 Error: popping nterm exp (1) Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' () Error: discarding token '+' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1) Error: discarding token number (1) Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1448: $PREPARSER ./calc input input: stderr: ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1453: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 4 12 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Stack now 0 4 12 Error: popping nterm exp (1) Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Next token is token invalid token () Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' () Error: discarding token '+' () Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1) Error: discarding token number (1) Error: popping token error () Stack now 0 4 Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1446: cat stderr stderr: ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1448: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: input: | 1//2 ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1446: $PREPARSER ./calc input ./calc.at:1453: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: input: stdout: stderr: ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1454: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc | 1 2 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1448: $PREPARSER ./calc input ./calc.at:1443: cat stderr input: stderr: ./calc.at:1445: cat stderr 1.3: syntax error | 1 2 input: ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: $PREPARSER ./calc input ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error, unexpected number | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1454: $PREPARSER ./calc input input: input: 1.3: syntax error | (* *) + (*) + (*) | (1 + 1) / (1 - 1) ./calc.at:1445: $PREPARSER ./calc input ./calc.at:1443: $PREPARSER ./calc input stderr: stderr: stderr: stderr: ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Stack now 0 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' () Reducing stack by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' () Reducing stack by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error, unexpected number ./calc.at:1454: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Stack now 0 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' () Reducing stack by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' () Shifting token ')' () Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' () Reducing stack by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Stack now 0 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token Next token is token end of input () Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1448: cat stderr ./calc.at:1446: cat stderr input: ./calc.at:1453: cat stderr input: | 1 2 ./calc.at:1454: $PREPARSER ./calc input ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1//2 ./calc.at:1448: $PREPARSER ./calc input stderr: 1.3: syntax error, unexpected number ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1443: cat stderr stderr: 1.3: syntax error | error ./calc.at:1446: $PREPARSER ./calc input ./calc.at:1445: cat stderr ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.3: syntax error, unexpected number | 1//2 ./calc.at:1453: $PREPARSER ./calc input stderr: input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 533. calc.at:1445: ok | 1 + 2 * 3 + !+ ++ ./calc.at:1443: $PREPARSER ./calc input stderr: ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1454: cat stderr stderr: stderr: ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1448: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 input: stderr: | 1//2 ./calc.at:1454: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: stderr: 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1448: $PREPARSER ./calc input ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1453: cat stderr stderr: stderr: 1.1: syntax error ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: cat stderr 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' input: stderr: 1.1: syntax error input: 544. calc.at:1468: testing Calculator glr.cc ... ./calc.at:1468: mv calc.y.tmp calc.y ./calc.at:1468: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y | error ./calc.at:1453: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ ./calc.at:1443: $PREPARSER ./calc input ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: stderr: ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error, unexpected invalid token ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | 1 = 2 = 3 ./calc.at:1446: $PREPARSER ./calc input ./calc.at:1454: cat stderr ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 stderr: input: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | error ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error, unexpected invalid token ./calc.at:1448: cat stderr ./calc.at:1454: $PREPARSER ./calc input stdout: stderr: stderr: 1.1: syntax error, unexpected invalid token ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./calc.at:1449: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1457: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: stderr: 1.1: syntax error, unexpected invalid token Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1457: $PREPARSER ./calc input | 1 = 2 = 3 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1448: $PREPARSER ./calc input ./calc.at:1449: $PREPARSER ./calc input stderr: ./calc.at:1453: cat stderr stderr: ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1468: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1443: cat stderr stderr: ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1457: $EGREP -c -v 'Return for a new token:|LAC:' stderr 1.7: syntax error ./calc.at:1446: cat stderr ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1454: cat stderr stderr: input: ./calc.at:1449: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: stderr: | 1 = 2 = 3 | (#) + (#) = 2222 ./calc.at:1443: $PREPARSER ./calc input ./calc.at:1453: $PREPARSER ./calc input input: 1.7: syntax error | 1 2 input: ./calc.at:1457: $PREPARSER ./calc input stderr: stderr: input: | 1 = 2 = 3 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.7: syntax error, unexpected '=' ./calc.at:1454: $PREPARSER ./calc input stderr: ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) stderr: ./calc.at:1446: $PREPARSER ./calc input ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 2 ./calc.at:1449: $PREPARSER ./calc input stderr: 1.7: syntax error, unexpected '=' ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 stderr: 1.3: syntax error ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.7: syntax error, unexpected '=' stderr: 1.3: syntax error ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) stderr: 1.7: syntax error, unexpected '=' stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 ./calc.at:1457: cat stderr ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: cat stderr ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1453: cat stderr input: ./calc.at:1454: cat stderr ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1457: $PREPARSER ./calc input input: | | +1 stderr: ./calc.at:1448: $PREPARSER ./calc input | | +1 stderr: ./calc.at:1449: cat stderr ./calc.at:1443: cat stderr ./calc.at:1453: $PREPARSER ./calc input syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) input: stdout: | | +1 ./calc.at:1454: $PREPARSER ./calc input ./calc.at:1446: cat stderr ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: stderr: ./calc.at:1451: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) 2.1: syntax error ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: $PREPARSER ./calc /dev/null 2.1: syntax error, unexpected '+' stderr: ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 2.1: syntax error, unexpected '+' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: 2.1: syntax error input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 | (1 + #) = 1111 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1443: $PREPARSER ./calc input ./calc.at:1451: $PREPARSER ./calc input stderr: stderr: input: 2.1: syntax error, unexpected '+' stderr: 2.1: syntax error, unexpected '+' | 1//2 stderr: ./calc.at:1449: $PREPARSER ./calc input ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1457: cat stderr 1.3: syntax error ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1451: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1454: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of input (1.1: ) 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 ./calc.at:1448: cat stderr stderr: input: 1.3: syntax error stderr: | error ./calc.at:1457: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1454: $PREPARSER ./calc /dev/null ./calc.at:1448: $PREPARSER ./calc /dev/null ./calc.at:1453: cat stderr stderr: input: ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 ./calc.at:1451: $PREPARSER ./calc input syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.1: syntax error, unexpected end of file ./calc.at:1453: $PREPARSER ./calc /dev/null ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: cat stderr 1.1: syntax error ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error stderr: ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error, unexpected end of input syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1443: cat stderr stderr: 1.1: syntax error input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 1.3: syntax error ./calc.at:1446: $PREPARSER ./calc input stdout: 1.1: syntax error, unexpected end of file stderr: ./calc.at:1449: cat stderr ./calc.at:1455: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: 1.1: syntax error, unexpected end of input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1455: $PREPARSER ./calc input input: input: ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 ./calc.at:1443: $PREPARSER ./calc input ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error ./calc.at:1449: $PREPARSER ./calc input ./calc.at:1457: cat stderr stderr: stderr: ./calc.at:1454: cat stderr ./calc.at:1451: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) LAC: initial context established for '=' LAC: checking lookahead '=': R9 G29 R7 G8 S18 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 92): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) LAC: initial context established for '=' LAC: checking lookahead '=': R11 G30 R9 G29 R7 G8 S18 Reducing stack by rule 11 (line 115): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 105): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 92): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 92): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G10 R11 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 115): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 92): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) LAC: initial context established for ')' LAC: checking lookahead ')': R11 G12 S26 Reducing stack by rule 11 (line 115): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 92): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 92): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) LAC: initial context established for '=' LAC: checking lookahead '=': R11 G10 R11 G10 R11 G8 S18 Reducing stack by rule 11 (line 115): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 115): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 115): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 92): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) LAC: initial context established for '-' LAC: checking lookahead '-': R8 G8 S19 Reducing stack by rule 8 (line 104): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) LAC: initial context discarded due to shift Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 92): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) LAC: initial context established for '=' LAC: checking lookahead '=': R8 G8 S18 Reducing stack by rule 8 (line 104): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 92): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 92): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) LAC: initial context established for ')' LAC: checking lookahead ')': R8 G12 S26 Reducing stack by rule 8 (line 104): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) LAC: initial context established for '=' LAC: checking lookahead '=': R8 G8 S18 Reducing stack by rule 8 (line 104): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 92): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 92): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G32 R12 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 116): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 92): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 92): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) LAC: initial context established for ')' LAC: checking lookahead ')': R12 G12 S26 Reducing stack by rule 12 (line 116): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 92): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (14.1: ) Shifting token end of file (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.1: syntax error ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '=' (1.11: ) LAC: initial context established for '=' LAC: checking lookahead '=': R9 G29 R7 G8 S18 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.14-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Stack now 0 6 8 20 29 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 20 29 21 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 20 29 21 2 1 Reducing stack by rule 5 (line 92): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 20 29 21 2 10 Reading a token Next token is token '=' (2.12: ) LAC: initial context established for '=' LAC: checking lookahead '=': R11 G30 R9 G29 R7 G8 S18 Reducing stack by rule 11 (line 115): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Stack now 0 6 8 20 29 21 30 Next token is token '=' (2.12: ) Reducing stack by rule 9 (line 105): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Stack now 0 6 8 20 29 Next token is token '=' (2.12: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Stack now 0 6 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Stack now 0 6 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 Reducing stack by rule 5 (line 92): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Stack now 0 6 2 10 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 23 1 Reducing stack by rule 5 (line 92): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Stack now 0 6 2 10 23 32 Reading a token Next token is token '=' (4.6: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G10 R11 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) Reducing stack by rule 11 (line 115): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 92): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) LAC: initial context established for ')' LAC: checking lookahead ')': R11 G12 S26 Reducing stack by rule 11 (line 115): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 92): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (5.8: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Stack now 0 6 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (5.11-6.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 Reducing stack by rule 5 (line 92): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) LAC: initial context established for '=' LAC: checking lookahead '=': R11 G10 R11 G10 R11 G8 S18 Reducing stack by rule 11 (line 115): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 115): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 115): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Stack now 0 6 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 92): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '-' (9.7: ) LAC: initial context established for '-' LAC: checking lookahead '-': R8 G8 S19 Reducing stack by rule 8 (line 104): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Stack now 0 6 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) LAC: initial context discarded due to shift Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 92): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (9.11: ) LAC: initial context established for '=' LAC: checking lookahead '=': R8 G8 S18 Reducing stack by rule 8 (line 104): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Stack now 0 6 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 18 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 18 2 1 Reducing stack by rule 5 (line 92): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 18 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R11 G27 R6 G8 S24 Reducing stack by rule 11 (line 115): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Stack now 0 6 8 18 27 Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 6 (line 93): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Stack now 0 6 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Stack now 0 6 8 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 19 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 19 4 1 Reducing stack by rule 5 (line 92): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 19 4 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Stack now 0 6 8 19 4 12 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 19 4 12 19 1 Reducing stack by rule 5 (line 92): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Stack now 0 6 8 19 4 12 19 28 Reading a token Next token is token ')' (10.11: ) LAC: initial context established for ')' LAC: checking lookahead ')': R8 G12 S26 Reducing stack by rule 8 (line 104): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Stack now 0 6 8 19 4 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 6 8 19 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '=' (10.13: ) LAC: initial context established for '=' LAC: checking lookahead '=': R8 G8 S18 Reducing stack by rule 8 (line 104): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Stack now 0 6 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (10.16-11.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Stack now 0 6 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 Reducing stack by rule 5 (line 92): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 92): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Stack now 0 6 8 23 32 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 23 32 23 1 Reducing stack by rule 5 (line 92): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Stack now 0 6 8 23 32 23 32 Reading a token Next token is token '=' (12.7: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G32 R12 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Stack now 0 6 8 23 32 Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 116): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Stack now 0 6 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (12.12-13.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Stack now 0 6 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 Reducing stack by rule 5 (line 92): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Stack now 0 6 4 12 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 23 1 Reducing stack by rule 5 (line 92): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Stack now 0 6 4 12 23 32 Reading a token Next token is token ')' (13.5: ) LAC: initial context established for ')' LAC: checking lookahead ')': R12 G12 S26 Reducing stack by rule 12 (line 116): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Stack now 0 6 4 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 6 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Stack now 0 6 8 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 23 1 Reducing stack by rule 5 (line 92): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Stack now 0 6 8 23 32 Reading a token Next token is token '=' (13.9: ) LAC: initial context established for '=' LAC: checking lookahead '=': R12 G8 S18 Reducing stack by rule 12 (line 116): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Stack now 0 6 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 6 8 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Stack now 0 6 8 18 27 Reading a token Next token is token '\n' (13.13-14.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Stack now 0 6 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Stack now 0 6 17 Reducing stack by rule 2 (line 83): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (14.1: ) Shifting token end of file (14.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1453: cat stderr input: 1.1: syntax error ./calc.at:1455: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: | 1//2 ./calc.at:1451: $PREPARSER ./calc input input: ./calc.at:1448: cat stderr | 1 = 2 = 3 ./calc.at:1457: $PREPARSER ./calc input stderr: ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1454: $PREPARSER ./calc input input: 1.3: syntax error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: $PREPARSER ./calc input input: stderr: ./calc.at:1446: cat stderr | 1 2 ./calc.at:1455: $PREPARSER ./calc input stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1448: $PREPARSER ./calc input 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: stderr: 1.3: syntax error 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) LAC: initial context established for number LAC: checking lookahead number: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: Err LAC: checking lookahead '=': S18 LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1449: cat stderr 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 input: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 stderr: stderr: ./calc.at:1443: cat stderr 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 | (!!) + (1 2) = 1 ./calc.at:1446: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token number (1.3: 2) LAC: initial context established for number LAC: checking lookahead number: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: Err LAC: checking lookahead '=': S18 LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 stderr: ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: input: ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1457: cat stderr ./calc.at:1453: cat stderr ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 ./calc.at:1449: $PREPARSER ./calc input ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + # + 1) = 1111 ./calc.at:1443: $PREPARSER ./calc input stderr: stderr: ./calc.at:1454: cat stderr input: ./calc.at:1451: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.7: syntax error input: stderr: ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 | (!!) + (1 2) = 1 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1457: $PREPARSER ./calc input ./calc.at:1448: cat stderr ./calc.at:1453: $PREPARSER ./calc input stderr: stderr: ./calc.at:1455: cat stderr input: stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 1.7: syntax error ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 input: ./calc.at:1454: $PREPARSER ./calc input syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1451: $PREPARSER ./calc input input: stderr: ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1448: $PREPARSER ./calc input stderr: stderr: 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 stderr: 1.1: syntax error ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 stderr: stderr: | 1//2 ./calc.at:1455: $PREPARSER ./calc input 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: stderr: 1.1: syntax error ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) LAC: initial context established for '/' LAC: checking lookahead '/': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 1.11: syntax error, unexpected number 1.1-16: error: 2222 != 1 stderr: ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1449: cat stderr input: ./calc.at:1453: cat stderr | (- *) + (1 2) = 1 ./calc.at:1446: $PREPARSER ./calc input ./calc.at:1443: cat stderr stderr: ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '/' (1.3: ) LAC: initial context established for '/' LAC: checking lookahead '/': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 input: | | +1 ./calc.at:1449: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1457: cat stderr ./calc.at:1453: $PREPARSER ./calc input ./calc.at:1454: cat stderr ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: ./calc.at:1448: cat stderr ./calc.at:1451: cat stderr ./calc.at:1457: $PREPARSER ./calc /dev/null 2.1: syntax error 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (1 + 1) / (1 - 1) ./calc.at:1443: $PREPARSER ./calc input stderr: stderr: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: ./calc.at:1455: cat stderr input: 2.1: syntax error | (- *) + (1 2) = 1 ./calc.at:1454: $PREPARSER ./calc input stderr: | 1 = 2 = 3 ./calc.at:1451: $PREPARSER ./calc input input: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 stderr: | (- *) + (1 2) = 1 stderr: stderr: ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1448: $PREPARSER ./calc input syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 1.7: syntax error ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1455: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': S3 LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 ./calc.at:1446: cat stderr ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.7: syntax error stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1453: cat stderr ./calc.at:1457: cat stderr stderr: ./calc.at:1449: cat stderr input: ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token invalid token (1.1: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': S3 LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) input: ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1446: $PREPARSER ./calc input input: stderr: ./calc.at:1443: cat stderr | (* *) + (*) + (*) ./calc.at:1453: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1449: $PREPARSER ./calc /dev/null ./calc.at:1457: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1454: cat stderr stderr: stderr: stderr: ./calc.at:1451: cat stderr syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) error: 4444 != 1 1.1: syntax error ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 532. calc.at:1443: ./calc.at:1448: cat stderr ok stderr: stderr: stderr: ./calc.at:1455: cat stderr input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.1: syntax error 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) error: 4444 != 1 input: | (* *) + (*) + (*) | | +1 ./calc.at:1454: $PREPARSER ./calc input ./calc.at:1451: $PREPARSER ./calc input input: stderr: stderr: input: 2.1: syntax error 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' | (* *) + (*) + (*) ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1448: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1455: $PREPARSER ./calc input ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error stderr: ./calc.at:1457: cat stderr ./calc.at:1446: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) LAC: checking lookahead '=': Err LAC: checking lookahead end of file: R6 G8 Err LAC: checking lookahead number: R6 G8 Err LAC: checking lookahead '=': Err LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 LAC: checking lookahead NEG: R6 G8 Err LAC: checking lookahead '^': S23 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 2.1: syntax error ./calc.at:1453: cat stderr stderr: input: stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '=' (1.7: ) LAC: checking lookahead '=': Err LAC: checking lookahead end of file: R6 G8 Err LAC: checking lookahead number: R6 G8 Err LAC: checking lookahead '=': Err LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 LAC: checking lookahead NEG: R6 G8 Err LAC: checking lookahead '^': S23 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Stack now 0 8 18 Error: popping token '=' (1.3: ) Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 | (!!) + (1 2) = 1 ./calc.at:1457: $PREPARSER ./calc input ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1449: cat stderr input: | 1 + 2 * 3 + !+ ++ ./calc.at:1446: $PREPARSER ./calc input syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1453: $PREPARSER ./calc input ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1454: cat stderr ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: 545. calc.at:1469: testing Calculator glr2.cc ... input: ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1469: mv calc.y.tmp calc.y syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 ./calc.at:1451: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1449: $PREPARSER ./calc input ./calc.at:1469: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1455: cat stderr stderr: stderr: ./calc.at:1453: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: ./calc.at:1448: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1446: $EGREP -c -v 'Return for a new token:|LAC:' stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1451: $PREPARSER ./calc /dev/null 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 input: ./calc.at:1454: $PREPARSER ./calc input ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | | +1 ./calc.at:1455: $PREPARSER ./calc input stderr: 1.1: syntax error ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1457: cat stderr input: input: stderr: stderr: | 1 + 2 * 3 + !- ++ | 1 + 2 * 3 + !+ ++ ./calc.at:1453: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) LAC: initial context established for '+' LAC: checking lookahead '+': Err LAC: checking lookahead end of file: S16 LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': S3 LAC: checking lookahead '(': S4 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1448: $PREPARSER ./calc input ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error | 1 + 2 * 3 + !- ++ ./calc.at:1446: $PREPARSER ./calc input stderr: stderr: stderr: stderr: ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1454: $EGREP -c -v 'Return for a new token:|LAC:' stderr | (- *) + (1 2) = 1 ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1457: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Stack now 0 3 Reducing stack by rule 3 (line 87): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token '+' (2.1: ) LAC: initial context established for '+' LAC: checking lookahead '+': Err LAC: checking lookahead end of file: S16 LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': S3 LAC: checking lookahead '(': S4 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 stderr: ./calc.at:1469: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: ./calc.at:1448: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stdout: ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 + 2 * 3 + !- ++ Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1454: $PREPARSER ./calc input ./calc.at:1458: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1449: cat stderr ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1451: cat stderr stderr: ./calc.at:1455: cat stderr input: ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) error: 2222 != 1 input: ./calc.at:1453: cat stderr ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1455: $PREPARSER ./calc /dev/null | 1 + 2 * 3 + !- ++ | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 input: ./calc.at:1458: $PREPARSER ./calc input ./calc.at:1448: $PREPARSER ./calc input input: stderr: stderr: stderr: | (!!) + (1 2) = 1 ./calc.at:1449: $PREPARSER ./calc input ./calc.at:1446: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of file (1.1: ) LAC: initial context established for end of file LAC: checking lookahead end of file: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': S3 LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1451: $PREPARSER ./calc input stderr: ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11: syntax error 1.1-16: error: 2222 != 1 input: stderr: stderr: ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stdout: stderr: | (#) + (#) = 2222 ./calc.at:1457: cat stderr ./calc.at:1453: $PREPARSER ./calc input stdout: | (#) + (#) = 2222 ./calc.at:1446: $PREPARSER ./calc input stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 stderr: ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token end of file (1.1: ) LAC: initial context established for end of file LAC: checking lookahead end of file: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': S3 LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 stderr: ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1468: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1459: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc 1.11: syntax error 1.1-16: error: 2222 != 1 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: ./calc.at:1458: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' input: input: ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1454: cat stderr ./calc.at:1455: cat stderr input: ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1459: $PREPARSER ./calc input stderr: input: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1457: $PREPARSER ./calc input | 1 2 ./calc.at:1468: $PREPARSER ./calc input ./calc.at:1458: $PREPARSER ./calc input stderr: ./calc.at:1453: cat stderr ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) stderr: ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./calc.at:1451: cat stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1455: $PREPARSER ./calc input ./calc.at:1448: cat stderr ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1449: cat stderr | (#) + (#) = 2222 stderr: input: ./calc.at:1454: $PREPARSER ./calc input | (1 + #) = 1111 ./calc.at:1453: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) LAC: initial context established for ')' LAC: checking lookahead ')': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G12 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G12 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) LAC: initial context established for ')' LAC: checking lookahead ')': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G8 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G8 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) LAC: initial context established for '*' LAC: checking lookahead '*': R9 G12 S21 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) LAC: initial context discarded due to shift Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1459: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: ./calc.at:1446: cat stderr | (!!) + (1 2) = 1 stderr: ./calc.at:1451: $PREPARSER ./calc input syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) stderr: 1.6: syntax error: invalid character: '#' 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' input: input: | (#) + (#) = 2222 ./calc.at:1448: $PREPARSER ./calc input stderr: input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token ')' (1.2: ) LAC: initial context established for ')' LAC: checking lookahead ')': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.13: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G12 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Stack now 0 8 20 4 12 20 29 Reading a token Next token is token '+' (1.17: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G12 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Stack now 0 8 20 4 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 4 12 20 Reading a token Next token is token ')' (1.18: ) LAC: initial context established for ')' LAC: checking lookahead ')': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.20: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G8 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.23: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.23: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.23: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.23: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.25: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.25: ) Error: popping token error (1.23: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token '*' (1.27: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.27: ) Error: popping token error (1.23-25: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.30: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G8 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Stack now 0 8 20 4 12 21 30 Reading a token Next token is token '*' (1.39: ) LAC: initial context established for '*' LAC: checking lookahead '*': R9 G12 S21 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Stack now 0 8 20 4 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) LAC: initial context discarded due to shift Entering state 21 Stack now 0 8 20 4 12 21 Reading a token Next token is token '*' (1.41: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Stack now 0 8 20 4 12 Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.41: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.41: ) Error: popping token error (1.33-41: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.44: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.47-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: | (1 + #) = 1111 stderr: ./calc.at:1446: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1449: $PREPARSER ./calc input | 1 2 input: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1459: $PREPARSER ./calc input ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.6: syntax error: invalid character: '#' 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1458: cat stderr stderr: | 1 2 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1468: $PREPARSER ./calc input ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1454: cat stderr ./calc.at:1457: cat stderr 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: syntax error ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' input: input: input: stderr: stderr: ./calc.at:1453: cat stderr | (1 + #) = 1111 | 1 + 2 * 3 + !+ ++ ./calc.at:1454: $PREPARSER ./calc input stderr: | 1//2 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) ./calc.at:1457: $PREPARSER ./calc input ./calc.at:1458: $PREPARSER ./calc input ./calc.at:1455: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) syntax error stderr: stderr: stderr: ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.6: syntax error: invalid character: '#' ./calc.at:1451: cat stderr ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: ./calc.at:1459: cat stderr input: ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 1.6: syntax error: invalid character: '#' ./calc.at:1455: $PREPARSER ./calc input ./calc.at:1453: $PREPARSER ./calc input input: stderr: stderr: stderr: ./calc.at:1449: cat stderr stderr: ./calc.at:1457: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 120): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) LAC: initial context established for number LAC: checking lookahead number: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: Err LAC: checking lookahead '=': S18 LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: 1.2: syntax error: invalid character: '#' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 ./calc.at:1446: cat stderr | (- *) + (1 2) = 1 ./calc.at:1459: $PREPARSER ./calc input ./calc.at:1448: cat stderr ./calc.at:1451: $PREPARSER ./calc input stderr: ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: stderr: input: 1.2: syntax error: invalid character: '#' 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Stack now 0 4 5 15 Reducing stack by rule 16 (line 120): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.11: 2) LAC: initial context established for number LAC: checking lookahead number: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: Err LAC: checking lookahead '=': S18 LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.11: 2) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.14: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (* *) + (*) + (*) input: ./calc.at:1454: cat stderr ./calc.at:1449: $PREPARSER ./calc input input: ./calc.at:1468: cat stderr ./calc.at:1458: cat stderr input: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1448: $PREPARSER ./calc input stderr: | 1 + 2 * 3 + !- ++ | (# + 1) = 1111 stderr: stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: $PREPARSER ./calc input ./calc.at:1457: $PREPARSER ./calc input stderr: ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 1.6: syntax error: invalid character: '#' ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 input: stderr: stderr: ./calc.at:1454: $PREPARSER ./calc input input: | error ./calc.at:1458: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1453: cat stderr stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1//2 1.2: syntax error: invalid character: '#' ./calc.at:1468: $PREPARSER ./calc input ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1455: cat stderr stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1459: cat stderr 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: stderr: input: ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error stderr: | (1 + # + 1) = 1111 stderr: ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: $PREPARSER ./calc input input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' stderr: stderr: | (- *) + (1 2) = 1 stderr: ./calc.at:1455: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) syntax error input: stderr: ./calc.at:1451: cat stderr | error ./calc.at:1459: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 119): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) LAC: initial context established for number LAC: checking lookahead number: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: Err LAC: checking lookahead '=': S18 LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1449: cat stderr ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1448: cat stderr stderr: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) 1.6: syntax error: invalid character: '#' ./calc.at:1457: cat stderr ./calc.at:1458: cat stderr stderr: ./calc.at:1454: cat stderr input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 Reading a token Next token is token '*' (1.4: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 Reducing stack by rule 15 (line 119): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.4: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.4: ) Error: popping token error (1.2-4: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token Next token is token number (1.12: 2) LAC: initial context established for number LAC: checking lookahead number: Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: Err LAC: checking lookahead '=': S18 LAC: checking lookahead '-': S19 LAC: checking lookahead '+': S20 LAC: checking lookahead '*': S21 LAC: checking lookahead '/': S22 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token number (1.12: 2) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.15: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1446: cat stderr ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !+ ++ ./calc.at:1449: $PREPARSER ./calc input | (* *) + (*) + (*) ./calc.at:1451: $PREPARSER ./calc input input: ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: input: stderr: | 1 = 2 = 3 | (#) + (#) = 2222 ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1458: $PREPARSER ./calc input stderr: | (# + 1) = 1111 input: ./calc.at:1448: $PREPARSER ./calc input stderr: ./calc.at:1457: $PREPARSER ./calc input | (1 + # + 1) = 1111 ./calc.at:1446: $PREPARSER ./calc input ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1453: cat stderr 1.2: syntax error: invalid character: '#' | (1 + # + 1) = 1111 ./calc.at:1454: $PREPARSER ./calc input ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error stderr: ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1468: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1449: $EGREP -c -v 'Return for a new token:|LAC:' stderr 1.6: syntax error: invalid character: '#' syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1455: cat stderr stderr: ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: ./calc.at:1459: cat stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error 1.2: syntax error: invalid character: '#' input: stderr: 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) stderr: stderr: 1.6: syntax error: invalid character: '#' | (1 + 1) / (1 - 1) input: ./calc.at:1453: $PREPARSER ./calc input | error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1468: $PREPARSER ./calc input syntax error: invalid character: '#' syntax error: invalid character: '#' input: | 1 + 2 * 3 + !- ++ stderr: stderr: ./calc.at:1449: $PREPARSER ./calc input syntax error | (* *) + (*) + (*) ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1455: $PREPARSER ./calc input 1.11-17: error: null divisor ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1458: cat stderr stderr: ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 = 2 = 3 ./calc.at:1459: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G8 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R7 G8 S24 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) stderr: input: ./calc.at:1454: cat stderr ./calc.at:1446: cat stderr 1.11-17: error: null divisor stderr: ./calc.at:1457: cat stderr ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1448: cat stderr stderr: | | +1 ./calc.at:1458: $PREPARSER ./calc input ./calc.at:1451: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token '*' (1.2: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Next token is token '*' (1.2: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '*' (1.4: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.10: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.10: ) Error: popping token error (1.10: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '+' (1.13: ) LAC: initial context established for '+' LAC: checking lookahead '+': R7 G8 S20 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 20 4 Reading a token Next token is token '*' (1.16: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err LAC: checking lookahead end of file: Err LAC: checking lookahead number: S1 LAC: checking lookahead '=': Err LAC: checking lookahead '-': S2 LAC: checking lookahead '+': Err LAC: checking lookahead '*': Err LAC: checking lookahead '/': Err LAC: checking lookahead NEG: Err LAC: checking lookahead '^': Err LAC: checking lookahead '\n': Err LAC: checking lookahead '(': S4 LAC: checking lookahead ')': Err LAC: checking lookahead '!': S5 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' LAC: initial context discarded due to error recovery Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.16: ) LAC: initial context established for '*' LAC: checking lookahead '*': Err Error: discarding token '*' (1.16: ) Error: popping token error (1.16: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.16: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '\n' (1.18-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R7 G8 S24 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) 1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: | (1 + 1) / (1 - 1) input: ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1454: $PREPARSER ./calc input input: input: ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + 1) / (1 - 1) ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (1 + # + 1) = 1111 | (1 + #) = 1111 ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1446: $PREPARSER ./calc input ./calc.at:1448: $PREPARSER ./calc input ./calc.at:1457: $PREPARSER ./calc input 1.11-17: error: null divisor input: ./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1459: cat stderr ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1451: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1453: cat stderr ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1455: cat stderr 1.11-17: error: null divisor ./calc.at:1468: cat stderr input: ./calc.at:1449: cat stderr stderr: stderr: 538. calc.at:1453: | | +1 ok ./calc.at:1459: $PREPARSER ./calc input syntax error: invalid character: '#' stderr: 1.6: syntax error: invalid character: '#' stderr: stderr: ./calc.at:1451: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1458: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) input: input: | (#) + (#) = 2222 ./calc.at:1449: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ | 1 = 2 = 3 ./calc.at:1455: $PREPARSER ./calc input ./calc.at:1454: cat stderr ./calc.at:1458: $PREPARSER ./calc /dev/null ./calc.at:1468: $PREPARSER ./calc input stderr: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: stderr: stderr: ./calc.at:1457: cat stderr ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) LAC: initial context established for '+' LAC: checking lookahead '+': R9 G29 R7 G8 S20 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 121): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ ./calc.at:1451: $PREPARSER ./calc input 539. calc.at:1454: ok stderr: syntax error 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: input: stderr: ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: cat stderr ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: | (# + 1) = 1111 ./calc.at:1448: cat stderr ./calc.at:1457: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' syntax error Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) LAC: initial context established for '+' LAC: checking lookahead '+': R9 G29 R7 G8 S20 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 20 5 14 Reducing stack by rule 17 (line 121): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1455: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: stderr: stderr: 534. calc.at:1446: ok ./calc.at:1459: cat stderr syntax error: invalid character: '#' ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) input: stderr: input: | 1 + 2 * 3 + !- ++ ./calc.at:1455: $PREPARSER ./calc input syntax error: invalid character: '#' | (1 + 1) / (1 - 1) ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1459: $PREPARSER ./calc /dev/null stderr: ./calc.at:1448: $PREPARSER ./calc input 546. calc.at:1476: testing Calculator C++ %glr-parser ... ./calc.at:1476: mv calc.y.tmp calc.y ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) LAC: initial context established for '+' LAC: checking lookahead '+': R9 G29 R7 G8 S20 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 122): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1458: cat stderr ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) 1.11-17: error: null divisor ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1449: cat stderr ./calc.at:1458: $PREPARSER ./calc input ./calc.at:1468: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 92): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Stack now 0 8 20 29 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 92): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Stack now 0 8 20 29 21 30 Reading a token Next token is token '+' (1.11: ) LAC: initial context established for '+' LAC: checking lookahead '+': R9 G29 R7 G8 S20 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) LAC: initial context discarded due to shift Entering state 20 Stack now 0 8 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 20 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 20 5 13 Reducing stack by rule 18 (line 122): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: stderr: ./calc.at:1457: cat stderr ./calc.at:1451: cat stderr stderr: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 1.11-17: error: null divisor 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) 547. calc.at:1476: testing Calculator glr2.cc ... ./calc.at:1476: mv calc.y.tmp calc.y input: ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1468: $PREPARSER ./calc input ./calc.at:1476: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: input: stderr: | (1 + #) = 1111 | (1 + # + 1) = 1111 ./calc.at:1449: $PREPARSER ./calc input ./calc.at:1457: $PREPARSER ./calc input ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1459: cat stderr ./calc.at:1455: cat stderr | (#) + (#) = 2222 stderr: ./calc.at:1451: $PREPARSER ./calc input syntax error stderr: ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' 548. calc.at:1477: testing Calculator C++ %glr-parser %locations ... ./calc.at:1477: mv calc.y.tmp calc.y input: ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1455: $PREPARSER ./calc input ./calc.at:1477: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: ./calc.at:1448: cat stderr stderr: stderr: ./calc.at:1458: cat stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1459: $PREPARSER ./calc input syntax error 1.6: syntax error: invalid character: '#' 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: 535. calc.at:1448: ok stderr: ./calc.at:1476: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS syntax error: invalid character: '#' 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 input: stderr: | (!!) + (1 2) = 1 ./calc.at:1458: $PREPARSER ./calc input ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.1-2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token invalid token (1.8: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.8: ) Error: popping token error (1.1-8: ) Stack now 0 8 20 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.7: ) $2 = token error (1.1-8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token Next token is token '=' (1.11: ) LAC: initial context established for '=' LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.17-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1476: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 stderr: ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1457: cat stderr ./calc.at:1449: cat stderr stderr: ./calc.at:1455: cat stderr 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 ./calc.at:1451: cat stderr ./calc.at:1459: cat stderr input: input: ./calc.at:1477: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1468: cat stderr input: ./calc.at:1458: cat stderr | (# + 1) = 1111 | (1 + #) = 1111 | (1 + 1) / (1 - 1) ./calc.at:1449: $PREPARSER ./calc input ./calc.at:1457: $PREPARSER ./calc input ./calc.at:1455: $PREPARSER ./calc input input: input: stderr: ./calc.at:1468: $PREPARSER ./calc /dev/null stderr: stderr: | (1 + #) = 1111 | (!!) + (1 2) = 1 stderr: ./calc.at:1459: $PREPARSER ./calc input ./calc.at:1451: $PREPARSER ./calc input error: null divisor Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.2: syntax error: invalid character: '#' ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error | (- *) + (1 2) = 1 ./calc.at:1458: $PREPARSER ./calc input ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 549. calc.at:1477: testing Calculator glr2.cc %locations ... ./calc.at:1477: mv calc.y.tmp calc.y 1.6: syntax error: invalid character: '#' stderr: stderr: ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' stderr: error: null divisor syntax error ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: stderr: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.6: syntax error: invalid character: '#' ./calc.at:1459: cat stderr ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1457: cat stderr ./calc.at:1455: cat stderr ./calc.at:1458: cat stderr input: ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1449: cat stderr 541. calc.at:1457: ok ./calc.at:1468: cat stderr | (- *) + (1 2) = 1 input: ./calc.at:1459: $PREPARSER ./calc input | (* *) + (*) + (*) ./calc.at:1458: $PREPARSER ./calc input stderr: input: input: stderr: ./calc.at:1451: cat stderr 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) input: ./calc.at:1477: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS | (# + 1) = 1111 | (1 + # + 1) = 1111 ./calc.at:1449: $PREPARSER ./calc input ./calc.at:1455: $PREPARSER ./calc input ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1468: $PREPARSER ./calc input stderr: input: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) LAC: initial context established for '+' LAC: checking lookahead '+': Err Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 1.6: syntax error: invalid character: '#' ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (# + 1) = 1111 stderr: 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 ./calc.at:1451: $PREPARSER ./calc input stderr: stderr: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.2: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.2: ) Error: popping token error (1.1-2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) LAC: initial context established for '+' LAC: checking lookahead '+': Err Error: discarding token '+' (1.4: ) Error: popping token error (1.1-2: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.6: 1) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.6: 1) Error: popping token error (1.1-4: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.15-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1459: cat stderr ./calc.at:1458: cat stderr 1.2: syntax error: invalid character: '#' ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 550. calc.at:1478: testing Calculator C++ %glr-parser %locations api.location.type={Span} ... ./calc.at:1478: mv calc.y.tmp calc.y input: ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y | 1 + 2 * 3 + !+ ++ ./calc.at:1458: $PREPARSER ./calc input input: ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1455: cat stderr ./calc.at:1449: cat stderr | (* *) + (*) + (*) ./calc.at:1459: $PREPARSER ./calc input stderr: ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) input: stderr: input: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + 1) / (1 - 1) ./calc.at:1458: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1451: cat stderr ./calc.at:1449: $PREPARSER ./calc input | (1 + # + 1) = 1111 ./calc.at:1455: $PREPARSER ./calc input ./calc.at:1468: cat stderr stderr: stderr: stderr: 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.11-17: error: null divisor ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) LAC: initial context established for '+' LAC: checking lookahead '+': Err Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: input: | (!!) + (1 2) = 1 ./calc.at:1459: cat stderr ./calc.at:1468: $PREPARSER ./calc input | (1 + # + 1) = 1111 ./calc.at:1451: $PREPARSER ./calc input stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1458: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Next token is token invalid token (1.6: ) LAC: initial context established for invalid token LAC: checking lookahead invalid token: Err Error: discarding token invalid token (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token '+' (1.8: ) LAC: initial context established for '+' LAC: checking lookahead '+': Err Error: discarding token '+' (1.8: ) Error: popping token error (1.2-6: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token number (1.10: 1) LAC: initial context established for number LAC: checking lookahead number: Err Error: discarding token number (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 LAC: initial context discarded due to error recovery Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 118): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Stack now 0 8 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.19-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1478: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS 1.11-17: error: null divisor stderr: syntax error error: 2222 != 1 ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1459: $PREPARSER ./calc input syntax error error: 2222 != 1 ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1455: cat stderr ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (1 + 1) / (1 - 1) ./calc.at:1455: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) LAC: initial context established for ')' LAC: checking lookahead ')': R7 G12 S26 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 92): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) LAC: initial context established for ')' LAC: checking lookahead ')': R8 G12 S26 Reducing stack by rule 8 (line 104): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R10 G8 S24 Reducing stack by rule 10 (line 106): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Stack now 0 4 12 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 92): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) LAC: initial context established for ')' LAC: checking lookahead ')': R7 G12 S26 Reducing stack by rule 7 (line 103): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Stack now 0 8 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 22 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 Reducing stack by rule 5 (line 92): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 22 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Stack now 0 8 22 4 12 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 Reducing stack by rule 5 (line 92): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) LAC: initial context established for ')' LAC: checking lookahead ')': R8 G12 S26 Reducing stack by rule 8 (line 104): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) LAC: initial context discarded due to shift Entering state 26 Stack now 0 8 22 4 12 26 Reducing stack by rule 13 (line 117): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R10 G8 S24 Reducing stack by rule 10 (line 106): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Next token is token end of file (2.1: ) Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1449: cat stderr ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1459: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1458: cat stderr 536. calc.at:1449: ok ./calc.at:1451: cat stderr ./calc.at:1468: cat stderr ./calc.at:1455: cat stderr input: input: | 1 + 2 * 3 + !- ++ ./calc.at:1459: $PREPARSER ./calc input input: stderr: | (#) + (#) = 2222 ./calc.at:1458: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1468: $PREPARSER ./calc input input: 540. calc.at:1455: ok | (1 + 1) / (1 - 1) ./calc.at:1451: $PREPARSER ./calc input stderr: stderr: stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error error: 2222 != 1 ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11-17: error: null divisor ./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error syntax error error: 2222 != 1 stderr: stderr: 1.11-17: error: null divisor 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1459: cat stderr ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1458: cat stderr ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 551. calc.at:1478: testing Calculator glr2.cc %locations api.location.type={Span} ... ./calc.at:1478: mv calc.y.tmp calc.y input: ./calc.at:1478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y | (#) + (#) = 2222 ./calc.at:1459: $PREPARSER ./calc input stderr: ./calc.at:1451: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' input: ./calc.at:1468: cat stderr 552. calc.at:1479: testing Calculator C++ %glr-parser %header parse.error=verbose %name-prefix "calc" %verbose ... ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 537. calc.at:1451: ok | (1 + #) = 1111 ./calc.at:1479: mv calc.y.tmp calc.y ./calc.at:1458: $PREPARSER ./calc input stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1479: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: | (* *) + (*) + (*) ./calc.at:1459: cat stderr ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1468: $PREPARSER ./calc input stderr: ./calc.at:1478: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: syntax error syntax error syntax error ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.6: syntax error: invalid character: '#' | (1 + #) = 1111 ./calc.at:1459: $PREPARSER ./calc input stderr: stderr: syntax error syntax error syntax error ./calc.at:1458: cat stderr 1.6: syntax error: invalid character: '#' 553. calc.at:1479: testing Calculator glr2.cc %header parse.error=verbose %name-prefix "calc" %verbose ... ./calc.at:1479: mv calc.y.tmp calc.y ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS input: ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 ./calc.at:1458: $PREPARSER ./calc input ./calc.at:1479: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: stderr: 1.6: syntax error: invalid character: '#' 1.2: syntax error: invalid character: '#' ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1468: cat stderr ./calc.at:1459: cat stderr stderr: 1.2: syntax error: invalid character: '#' input: input: | 1 + 2 * 3 + !+ ++ ./calc.at:1468: $PREPARSER ./calc input | (# + 1) = 1111 ./calc.at:1459: $PREPARSER ./calc input ./calc.at:1458: cat stderr stderr: stderr: ./calc.at:1479: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS 1.2: syntax error: invalid character: '#' ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (1 + # + 1) = 1111 ./calc.at:1458: $PREPARSER ./calc input stderr: stderr: 1.2: syntax error: invalid character: '#' input: | 1 + 2 * 3 + !- ++ ./calc.at:1468: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1459: cat stderr ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.6: syntax error: invalid character: '#' stderr: input: | (1 + # + 1) = 1111 ./calc.at:1459: $PREPARSER ./calc input ./calc.at:1458: cat stderr stderr: 1.6: syntax error: invalid character: '#' input: ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + 1) / (1 - 1) ./calc.at:1458: $PREPARSER ./calc input ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: 1.6: syntax error: invalid character: '#' 1.11-17: error: null divisor ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1468: cat stderr ./calc.at:1459: cat stderr input: stderr: | (#) + (#) = 2222 ./calc.at:1468: $PREPARSER ./calc input 1.11-17: error: null divisor stderr: input: syntax error: invalid character: '#' syntax error: invalid character: '#' | (1 + 1) / (1 - 1) ./calc.at:1459: $PREPARSER ./calc input ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.11-17: error: null divisor stderr: ./calc.at:1458: cat stderr syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 542. calc.at:1458: ok 1.11-17: error: null divisor ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1459: cat stderr 543. calc.at:1459: ok ./calc.at:1468: cat stderr input: | (1 + #) = 1111 ./calc.at:1468: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 554. calc.at:1480: testing Calculator C++ %glr-parser parse.error=verbose api.prefix={calc} %verbose ... ./calc.at:1480: mv calc.y.tmp calc.y stderr: ./calc.at:1480: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y syntax error: invalid character: '#' 555. calc.at:1480: testing Calculator glr2.cc parse.error=verbose api.prefix={calc} %verbose ... ./calc.at:1480: mv calc.y.tmp calc.y ./calc.at:1480: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1468: cat stderr stderr: stdout: input: ./calc.at:1477: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc | (# + 1) = 1111 ./calc.at:1468: $PREPARSER ./calc input stderr: input: ./calc.at:1480: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS syntax error: invalid character: '#' ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1480: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: stderr: ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' stderr: input: | 1 2 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.3: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error ./calc.at:1468: cat stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + # + 1) = 1111 ./calc.at:1468: $PREPARSER ./calc input stderr: ./calc.at:1477: cat stderr syntax error: invalid character: '#' ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./calc.at:1476: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: input: input: syntax error: invalid character: '#' | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1476: $PREPARSER ./calc input | 1//2 ./calc.at:1477: $PREPARSER ./calc input stderr: ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | 1 2 1.3: syntax error ./calc.at:1476: $PREPARSER ./calc input stderr: syntax error ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1468: cat stderr stderr: syntax error input: ./calc.at:1477: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1468: $PREPARSER ./calc input stderr: input: error: null divisor | error ./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.1: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: null divisor stderr: ./calc.at:1476: cat stderr 1.1: syntax error input: ./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1476: $PREPARSER ./calc input stderr: syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1468: cat stderr ./calc.at:1477: cat stderr stderr: syntax error 544. calc.at:1468: ok input: | 1 = 2 = 3 ./calc.at:1477: $PREPARSER ./calc input stderr: 1.7: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.7: syntax error ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: cat stderr 556. calc.at:1482: testing Calculator C++ %glr-parser %debug ... ./calc.at:1482: mv calc.y.tmp calc.y ./calc.at:1477: cat stderr ./calc.at:1482: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: | error ./calc.at:1476: $PREPARSER ./calc input input: | | +1 ./calc.at:1477: $PREPARSER ./calc input stderr: stderr: syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 2.1: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error 2.1: syntax error ./calc.at:1482: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stdout: ./calc.at:1477: cat stderr ./calc.at:1478: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1477: $PREPARSER ./calc /dev/null ./calc.at:1476: cat stderr stderr: input: 1.1: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1478: $PREPARSER ./calc input stderr: stderr: ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 1.1: syntax error | 1 = 2 = 3 ./calc.at:1476: $PREPARSER ./calc input stderr: syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: | 1 2 syntax error ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1477: cat stderr stderr: 1.3: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 1.3: syntax error ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1477: $PREPARSER ./calc input stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1476: cat stderr ./calc.at:1478: cat stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | | +1 ./calc.at:1476: $PREPARSER ./calc input input: ./calc.at:1477: cat stderr stderr: | 1//2 ./calc.at:1478: $PREPARSER ./calc input stderr: syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: syntax error | (!!) + (1 2) = 1 stderr: ./calc.at:1477: $PREPARSER ./calc input 1.3: syntax error stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: cat stderr ./calc.at:1476: cat stderr input: ./calc.at:1476: $PREPARSER ./calc /dev/null | error ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1477: cat stderr stderr: stderr: 1.1: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (- *) + (1 2) = 1 stderr: ./calc.at:1477: $PREPARSER ./calc input syntax error 1.1: syntax error stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: cat stderr ./calc.at:1477: cat stderr input: | 1 = 2 = 3 ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1476: cat stderr stderr: 1.7: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (* *) + (*) + (*) input: ./calc.at:1477: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1476: $PREPARSER ./calc input 1.2: syntax error 1.10: syntax error 1.16: syntax error stderr: ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.7: syntax error syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1478: cat stderr stderr: ./calc.at:1477: cat stderr stdout: ./calc.at:1476: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: input: | | +1 ./calc.at:1478: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1477: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1476: $PREPARSER ./calc input stderr: stderr: 2.1: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: cat stderr ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 2.1: syntax error stderr: input: stderr: | (!!) + (1 2) = 1 input: ./calc.at:1476: $PREPARSER ./calc input | 1 2 ./calc.at:1476: $PREPARSER ./calc input stderr: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error error: 2222 != 1 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 + 2 * 3 + !- ++ syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: $PREPARSER ./calc input stderr: stderr: syntax error error: 2222 != 1 ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error ./calc.at:1478: cat stderr stderr: ./calc.at:1478: $PREPARSER ./calc /dev/null stderr: stderr: stdout: ./calc.at:1480: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.1: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1480: $PREPARSER ./calc input 1.1: syntax error ./calc.at:1476: cat stderr stderr: ./calc.at:1476: cat stderr ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: cat stderr stderr: input: | 1 2 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: $PREPARSER ./calc input input: stderr: | (- *) + (1 2) = 1 ./calc.at:1476: $PREPARSER ./calc input input: | 1//2 ./calc.at:1476: $PREPARSER ./calc input syntax error, unexpected number input: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1478: cat stderr stderr: syntax error syntax error error: 2222 != 1 | (#) + (#) = 2222 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: $PREPARSER ./calc input syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stdout: stderr: syntax error, unexpected number ./calc.at:1469: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc syntax error syntax error error: 2222 != 1 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1478: $PREPARSER ./calc input stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: ./calc.at:1469: $PREPARSER ./calc input 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' stderr: ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1480: cat stderr 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: cat stderr input: | 1 2 ./calc.at:1469: $PREPARSER ./calc input ./calc.at:1476: cat stderr input: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1//2 input: ./calc.at:1480: $PREPARSER ./calc input syntax error ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (* *) + (*) + (*) stderr: ./calc.at:1476: $PREPARSER ./calc input syntax error, unexpected '/', expecting number or '-' or '(' or '!' input: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: cat stderr syntax error stderr: | error ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1478: cat stderr syntax error syntax error syntax error stderr: ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error stderr: input: ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + #) = 1111 syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1477: $PREPARSER ./calc input stderr: | (!!) + (1 2) = 1 ./calc.at:1478: $PREPARSER ./calc input syntax error syntax error syntax error stderr: stderr: ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error 1.6: syntax error: invalid character: '#' ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1469: cat stderr stderr: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1480: cat stderr input: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1469: $PREPARSER ./calc input input: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | error stderr: ./calc.at:1480: $PREPARSER ./calc input syntax error ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected invalid token ./calc.at:1476: cat stderr ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: cat stderr ./calc.at:1477: cat stderr ./calc.at:1478: cat stderr stderr: input: syntax error input: stderr: | 1 + 2 * 3 + !+ ++ syntax error, unexpected invalid token ./calc.at:1476: $PREPARSER ./calc input input: | (# + 1) = 1111 stderr: ./calc.at:1477: $PREPARSER ./calc input | 1 = 2 = 3 input: ./calc.at:1476: $PREPARSER ./calc input stderr: ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 stderr: ./calc.at:1478: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 stderr: ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: stderr: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.2: syntax error: invalid character: '#' stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 syntax error | 1 + 2 * 3 + !- ++ ./calc.at:1476: $PREPARSER ./calc input stderr: ./calc.at:1469: cat stderr ./calc.at:1480: cat stderr ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | error ./calc.at:1469: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1478: cat stderr ./calc.at:1477: cat stderr stderr: stderr: syntax error, unexpected '=' ./calc.at:1476: cat stderr ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | (* *) + (*) + (*) ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: $PREPARSER ./calc input | (1 + # + 1) = 1111 stderr: ./calc.at:1477: $PREPARSER ./calc input stderr: input: stderr: stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error, unexpected '=' | | +1 ./calc.at:1476: $PREPARSER ./calc input stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: cat stderr stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error stderr: stderr: input: syntax error ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.6: syntax error: invalid character: '#' ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (#) + (#) = 2222 ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1469: cat stderr ./calc.at:1480: cat stderr ./calc.at:1478: cat stderr stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' syntax error: invalid character: '#' input: input: | 1 = 2 = 3 ./calc.at:1469: $PREPARSER ./calc input | | +1 stderr: ./calc.at:1477: cat stderr ./calc.at:1480: $PREPARSER ./calc input input: stdout: stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1476: cat stderr ./calc.at:1478: $PREPARSER ./calc input syntax error stderr: ./calc.at:1482: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected '+' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: $PREPARSER ./calc /dev/null | (1 + 1) / (1 - 1) stderr: ./calc.at:1477: $PREPARSER ./calc input syntax error input: stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected '+' stderr: 1.11-17: error: null divisor ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: $PREPARSER ./calc input stderr: stderr: stderr: input: syntax error 1.11-17: error: null divisor Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1476: cat stderr stderr: stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stdout: | 1 2 ./calc.at:1477: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1480: cat stderr stderr: input: stderr: | (1 + #) = 1111 ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) ./calc.at:1469: cat stderr ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: cat stderr stderr: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: $PREPARSER ./calc /dev/null | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1477: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' stderr: ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 548. calc.at:1477: ok ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: syntax error, unexpected end of input ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) | | +1 ./calc.at:1469: $PREPARSER ./calc input stderr: stderr: stderr: ./calc.at:1478: cat stderr syntax error: invalid character: '#' stderr: syntax error ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | 1 2 syntax error, unexpected end of input ./calc.at:1477: $PREPARSER ./calc input input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1476: $PREPARSER ./calc input stderr: stderr: syntax error 1.3: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1478: $PREPARSER ./calc input syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: 1.3: syntax error 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stderr: ./calc.at:1482: cat stderr syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1478: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1476: cat stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr input: input: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' | 1//2 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 557. calc.at:1482: testing Calculator glr2.cc %debug ... ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1482: mv calc.y.tmp calc.y ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1480: $PREPARSER ./calc input stderr: ./calc.at:1482: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1477: cat stderr ./calc.at:1469: cat stderr stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: cat stderr stderr: ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (# + 1) = 1111 ./calc.at:1476: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1469: $PREPARSER ./calc /dev/null input: stderr: syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 stderr: stderr: syntax error: invalid character: '#' | 1//2 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: syntax error ./calc.at:1476: cat stderr ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: | (1 + #) = 1111 ./calc.at:1478: $PREPARSER ./calc input input: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () 1.3: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 2 ./calc.at:1478: $PREPARSER ./calc input stderr: stderr: 1.6: syntax error: invalid character: '#' input: ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1482: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS syntax error stderr: stderr: stderr: 1.3: syntax error 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error ./calc.at:1480: cat stderr syntax error error: 2222 != 1 ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.3: syntax error stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error error: 2222 != 1 input: ./calc.at:1482: cat stderr | (!!) + (1 2) = 1 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: $PREPARSER ./calc input stderr: ./calc.at:1476: cat stderr input: syntax error, unexpected number error: 2222 != 1 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1469: cat stderr ./calc.at:1478: cat stderr | error ./calc.at:1477: cat stderr ./calc.at:1482: $PREPARSER ./calc input stderr: stderr: ./calc.at:1478: cat stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected number error: 2222 != 1 Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error Cleanup: discarding lookahead token "invalid token" () input: input: input: ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + # + 1) = 1111 ./calc.at:1476: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1469: $PREPARSER ./calc input | error ./calc.at:1477: $PREPARSER ./calc input | (# + 1) = 1111 ./calc.at:1478: $PREPARSER ./calc input input: stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error Cleanup: discarding lookahead token "invalid token" () ./calc.at:1476: cat stderr stderr: | 1//2 stderr: stderr: syntax error: invalid character: '#' ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: $PREPARSER ./calc input 1.1: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error syntax error syntax error error: 4444 != 1 1.2: syntax error: invalid character: '#' stderr: ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.3: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: syntax error: invalid character: '#' stderr: 1.1: syntax error | (- *) + (1 2) = 1 1.2: syntax error: invalid character: '#' ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error syntax error syntax error syntax error error: 4444 != 1 ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1480: cat stderr stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: input: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (- *) + (1 2) = 1 ./calc.at:1480: $PREPARSER ./calc input 1.3: syntax error stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error syntax error error: 2222 != 1 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr ./calc.at:1477: cat stderr stderr: stderr: syntax error syntax error error: 2222 != 1 input: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1478: cat stderr ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1476: cat stderr stderr: input: input: ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 | 1 = 2 = 3 ./calc.at:1482: $PREPARSER ./calc input input: ./calc.at:1478: cat stderr ./calc.at:1477: $PREPARSER ./calc input input: | (1 + # + 1) = 1111 ./calc.at:1478: $PREPARSER ./calc input | (1 + 1) / (1 - 1) stderr: stderr: stderr: ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () 1.7: syntax error ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1469: cat stderr input: stderr: error: null divisor input: ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' | 1 2 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: $PREPARSER ./calc input | error ./calc.at:1480: cat stderr stderr: ./calc.at:1478: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () input: stderr: stderr: stderr: 1.7: syntax error | (!!) + (1 2) = 1 stderr: ./calc.at:1476: cat stderr error: null divisor syntax error, unexpected number 1.1: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1469: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' stderr: stderr: input: syntax error, unexpected number ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: syntax error error: 2222 != 1 | (* *) + (*) + (*) 1.1: syntax error ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error syntax error syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error error: 2222 != 1 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: cat stderr stderr: stderr: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error syntax error syntax error syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1478: cat stderr ./calc.at:1476: cat stderr ./calc.at:1479: cat stderr ./calc.at:1482: cat stderr ./calc.at:1478: cat stderr ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 546. calc.at:1476: ok | | +1 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: stderr: input: | | +1 input: | 1//2 ./calc.at:1482: $PREPARSER ./calc input 2.1: syntax error ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + 1) / (1 - 1) | 1 = 2 = 3 ./calc.at:1478: $PREPARSER ./calc input stderr: ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1469: cat stderr stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected '/', expecting number or '-' or '(' or '!' stderr: ./calc.at:1480: cat stderr 2.1: syntax error ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11-17: error: null divisor ./calc.at:1476: cat stderr 1.7: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (- *) + (1 2) = 1 ./calc.at:1469: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error Error: popping nterm input () Cleanup: discarding lookahead token '+' () input: stderr: input: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11-17: error: null divisor syntax error, unexpected '/', expecting number or '-' or '(' or '!' | 1 + 2 * 3 + !+ ++ ./calc.at:1476: $PREPARSER ./calc input 1.7: syntax error | 1 + 2 * 3 + !+ ++ syntax error syntax error error: 2222 != 1 ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: $PREPARSER ./calc input stderr: stderr: ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: cat stderr syntax error syntax error error: 2222 != 1 stderr: stderr: 558. calc.at:1485: testing Calculator C++ %glr-parser parse.error=detailed %debug %name-prefix "calc" %verbose ... ./calc.at:1485: mv calc.y.tmp calc.y ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: cat stderr ./calc.at:1477: $PREPARSER ./calc /dev/null ./calc.at:1485: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: stderr: ./calc.at:1478: cat stderr | 1 + 2 * 3 + !- ++ input: ./calc.at:1480: $PREPARSER ./calc input 1.1: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1478: cat stderr | 1 + 2 * 3 + !- ++ ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: cat stderr 1.1: syntax error input: 550. calc.at:1478: ok stderr: input: stderr: | | +1 ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: $PREPARSER ./calc input | error ./calc.at:1482: $PREPARSER ./calc /dev/null ./calc.at:1479: $PREPARSER ./calc input stderr: stderr: stderr: 2.1: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" () stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1469: cat stderr ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected invalid token ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: 2.1: syntax error stderr: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" () ./calc.at:1477: cat stderr input: ./calc.at:1485: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS syntax error, unexpected invalid token | (* *) + (*) + (*) ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1469: $PREPARSER ./calc input stderr: ./calc.at:1480: cat stderr input: syntax error syntax error syntax error ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: ./calc.at:1477: $PREPARSER ./calc input syntax error syntax error syntax error stderr: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: cat stderr | (#) + (#) = 2222 ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1479: cat stderr stderr: ./calc.at:1478: cat stderr 559. calc.at:1485: testing Calculator glr2.cc parse.error=detailed %debug %name-prefix "calc" %verbose ... ./calc.at:1485: mv calc.y.tmp calc.y syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1485: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: ./calc.at:1478: $PREPARSER ./calc /dev/null 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1482: cat stderr ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (#) + (#) = 2222 input: ./calc.at:1476: $PREPARSER ./calc input stderr: | 1 = 2 = 3 stderr: stderr: ./calc.at:1479: $PREPARSER ./calc input syntax error: invalid character: '#' syntax error: invalid character: '#' 1.1: syntax error syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected '=' | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: $PREPARSER ./calc input stderr: ./calc.at:1469: cat stderr syntax error: invalid character: '#' syntax error: invalid character: '#' stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error syntax error, unexpected '=' input: stderr: ./calc.at:1477: cat stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1469: $PREPARSER ./calc input ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1485: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1480: cat stderr ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (!!) + (1 2) = 1 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: input: ./calc.at:1478: cat stderr input: ./calc.at:1479: cat stderr | (1 + #) = 1111 ./calc.at:1480: $PREPARSER ./calc input stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 | 1 + 2 * 3 + !- ++ syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1469: $PREPARSER ./calc input ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1476: cat stderr ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: ./calc.at:1482: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1478: $PREPARSER ./calc input | | +1 ./calc.at:1479: $PREPARSER ./calc input stderr: input: stderr: stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 syntax error, unexpected '+' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: $PREPARSER ./calc input stderr: stderr: ./calc.at:1477: cat stderr input: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 syntax error: invalid character: '#' ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1482: $PREPARSER ./calc input stderr: stderr: syntax error, unexpected '+' Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: ./calc.at:1480: cat stderr ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: syntax error: invalid character: '#' ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (- *) + (1 2) = 1 ./calc.at:1477: $PREPARSER ./calc input stderr: input: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 | (# + 1) = 1111 ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1469: cat stderr stderr: stderr: stderr: ./calc.at:1478: cat stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 stdout: syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (#) + (#) = 2222 ./calc.at:1480: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1469: $PREPARSER ./calc input stderr: input: ./calc.at:1479: cat stderr stderr: syntax error: invalid character: '#' ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1476: cat stderr stderr: input: ./calc.at:1479: $PREPARSER ./calc /dev/null 1.11: syntax error 1.1-16: error: 2222 != 1 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: ./calc.at:1480: $PREPARSER ./calc input stderr: syntax error, unexpected end of input stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' input: ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (# + 1) = 1111 ./calc.at:1482: cat stderr ./calc.at:1476: $PREPARSER ./calc input ./calc.at:1477: cat stderr ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 1.11: syntax error 1.1-16: error: 2222 != 1 stderr: stderr: syntax error: invalid character: '#' ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected end of input input: stderr: stdout: input: | (- *) + (1 2) = 1 ./calc.at:1482: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' input: ./calc.at:1480: cat stderr ./calc.at:1479: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh | (* *) + (*) + (*) stderr: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error, unexpected number ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: ./calc.at:1479: $PREPARSER ./calc input 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1469: cat stderr | (1 + # + 1) = 1111 ./calc.at:1478: cat stderr ./calc.at:1480: $PREPARSER ./calc input stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1479: cat stderr ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected number syntax error: invalid character: '#' input: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: cat stderr input: stderr: | (- *) + (1 2) = 1 ./calc.at:1478: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 input: stderr: ./calc.at:1479: $PREPARSER ./calc input | (1 + #) = 1111 stderr: ./calc.at:1469: $PREPARSER ./calc input stderr: ./calc.at:1477: cat stderr ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 input: syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | 1 2 ./calc.at:1479: $PREPARSER ./calc input syntax error: invalid character: '#' | (1 + # + 1) = 1111 ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1476: $PREPARSER ./calc input stderr: stderr: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected number 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 stderr: ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 syntax error: invalid character: '#' | 1 + 2 * 3 + !+ ++ ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1480: cat stderr ./calc.at:1482: cat stderr stderr: stderr: stderr: syntax error: invalid character: '#' ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected number ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1480: cat stderr syntax error: invalid character: '#' stderr: | 1//2 ./calc.at:1480: $PREPARSER ./calc input input: ./calc.at:1478: cat stderr | (* *) + (*) + (*) stderr: ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: input: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + 1) / (1 - 1) ./calc.at:1480: $PREPARSER ./calc input stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1479: cat stderr input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: stderr: ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: null divisor | (* *) + (*) + (*) ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1479: cat stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () | (!!) + (1 2) = 1 stderr: ./calc.at:1479: $PREPARSER ./calc input error: null divisor ./calc.at:1469: cat stderr stderr: stderr: input: syntax error, unexpected number error: 2222 != 1 ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1//2 ./calc.at:1479: $PREPARSER ./calc input stderr: ./calc.at:1476: cat stderr input: ./calc.at:1480: cat stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 syntax error, unexpected number error: 2222 != 1 syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1469: $PREPARSER ./calc input ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1480: cat stderr stderr: syntax error: invalid character: '#' ./calc.at:1477: cat stderr | error ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected '/', expecting number or '-' or '(' or '!' input: ./calc.at:1480: $PREPARSER ./calc input | (1 + 1) / (1 - 1) ./calc.at:1476: $PREPARSER ./calc input stderr: stderr: syntax error, unexpected invalid token ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: cat stderr 554. calc.at:1480: ok ./calc.at:1482: cat stderr stderr: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 error: null divisor ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected invalid token stderr: input: stderr: syntax error: invalid character: '#' | (#) + (#) = 2222 error: null divisor ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1478: $PREPARSER ./calc input ./calc.at:1479: cat stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1479: cat stderr ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) | error ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: syntax error, unexpected invalid token ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1480: cat stderr ./calc.at:1469: cat stderr ./calc.at:1476: cat stderr stderr: stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 input: ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ ./calc.at:1478: $PREPARSER ./calc input stderr: syntax error, unexpected invalid token input: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) 547. calc.at:1476: ok | (1 + # + 1) = 1111 input: input: stderr: ./calc.at:1469: $PREPARSER ./calc input syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 | 1 = 2 = 3 ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1477: cat stderr stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error, unexpected '=' stderr: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + #) = 1111 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) stderr: ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' syntax error, unexpected '=' 560. calc.at:1486: testing Calculator C++ %glr-parser parse.error=verbose %debug %name-prefix "calc" %verbose ... ./calc.at:1486: mv calc.y.tmp calc.y stderr: ./calc.at:1486: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y 1.6: syntax error: invalid character: '#' ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: cat stderr ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1479: cat stderr ./calc.at:1469: cat stderr input: ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: cat stderr | 1 = 2 = 3 ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: $PREPARSER ./calc input input: ./calc.at:1477: cat stderr | (* *) + (*) + (*) ./calc.at:1479: $PREPARSER ./calc input 561. calc.at:1486: testing Calculator glr2.cc parse.error=verbose %debug %name-prefix "calc" %verbose ... ./calc.at:1486: mv calc.y.tmp calc.y stderr: ./calc.at:1480: cat stderr ./calc.at:1486: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS input: stderr: ./calc.at:1486: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y syntax error, unexpected '=' | (1 + 1) / (1 - 1) ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1469: $PREPARSER ./calc input syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1482: cat stderr stderr: input: stderr: input: | | +1 ./calc.at:1480: $PREPARSER ./calc input syntax error, unexpected '=' | (#) + (#) = 2222 stderr: ./calc.at:1478: $PREPARSER ./calc input error: null divisor | (# + 1) = 1111 ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '+' ./calc.at:1477: $PREPARSER ./calc input ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' stderr: ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' input: ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: | (#) + (#) = 2222 syntax error, unexpected '+' ./calc.at:1482: $PREPARSER ./calc input error: null divisor stderr: 1.2: syntax error: invalid character: '#' stderr: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1479: cat stderr ./calc.at:1479: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !+ ++ input: ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1480: cat stderr | | +1 ./calc.at:1479: $PREPARSER ./calc input stderr: ./calc.at:1478: cat stderr ./calc.at:1469: cat stderr ./calc.at:1477: cat stderr ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected '+' ./calc.at:1480: $PREPARSER ./calc /dev/null ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 545. calc.at:1469: ok stderr: syntax error, unexpected end of input ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: input: | (1 + # + 1) = 1111 ./calc.at:1477: $PREPARSER ./calc input syntax error, unexpected '+' | 1 + 2 * 3 + !- ++ ./calc.at:1479: $PREPARSER ./calc input | (1 + #) = 1111 ./calc.at:1478: $PREPARSER ./calc input stderr: stderr: stderr: stderr: 1.6: syntax error: invalid character: '#' ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected end of input stderr: stderr: ./calc.at:1482: cat stderr stderr: 1.6: syntax error: invalid character: '#' 1.6: syntax error: invalid character: '#' ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1479: cat stderr | (1 + #) = 1111 ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr stderr: ./calc.at:1479: $PREPARSER ./calc /dev/null ./calc.at:1478: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1479: cat stderr syntax error, unexpected end of input ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1477: cat stderr 562. calc.at:1487: testing Calculator glr2.cc parse.error=custom %debug %name-prefix "calc" %verbose ... stderr: input: ./calc.at:1487: mv calc.y.tmp calc.y Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1480: $PREPARSER ./calc input stderr: input: | (# + 1) = 1111 input: stderr: ./calc.at:1478: $PREPARSER ./calc input syntax error, unexpected end of input ./calc.at:1487: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y | (1 + 1) / (1 - 1) ./calc.at:1477: $PREPARSER ./calc input | (#) + (#) = 2222 ./calc.at:1479: $PREPARSER ./calc input stderr: stderr: syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 1.2: syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.11-17: error: null divisor ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 stderr: stderr: 1.11-17: error: null divisor ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: cat stderr syntax error: invalid character: '#' syntax error: invalid character: '#' 1.2: syntax error: invalid character: '#' ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr stderr: ./calc.at:1487: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1479: cat stderr | (# + 1) = 1111 ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1477: cat stderr ./calc.at:1478: cat stderr stderr: input: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1480: $PREPARSER ./calc input input: | (1 + #) = 1111 ./calc.at:1479: $PREPARSER ./calc input stderr: 549. calc.at:1477: input: ok syntax error, unexpected number error: 2222 != 1 stderr: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + # + 1) = 1111 ./calc.at:1478: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: 1.6: syntax error: invalid character: '#' stderr: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected number error: 2222 != 1 syntax error: invalid character: '#' stderr: ./calc.at:1479: cat stderr 1.6: syntax error: invalid character: '#' ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1479: $PREPARSER ./calc input stderr: ./calc.at:1479: cat stderr ./calc.at:1482: cat stderr syntax error, unexpected number error: 2222 != 1 ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 563. calc.at:1489: testing Calculator C++ %glr-parser parse.error=verbose %debug %name-prefix "calc" api.token.prefix={TOK_} %verbose ... ./calc.at:1489: mv calc.y.tmp calc.y ./calc.at:1489: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: stderr: ./calc.at:1480: cat stderr input: syntax error, unexpected number error: 2222 != 1 ./calc.at:1478: cat stderr | (1 + # + 1) = 1111 ./calc.at:1482: $PREPARSER ./calc input | (# + 1) = 1111 ./calc.at:1479: $PREPARSER ./calc input stderr: stderr: input: syntax error: invalid character: '#' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1480: $PREPARSER ./calc input input: ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: | (1 + 1) / (1 - 1) ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' ./calc.at:1478: $PREPARSER ./calc input syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1479: cat stderr 1.11-17: error: null divisor ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1489: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 1.11-17: error: null divisor input: | (- *) + (1 2) = 1 ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1479: cat stderr ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number error: 2222 != 1 input: ./calc.at:1482: cat stderr ./calc.at:1480: cat stderr | (1 + # + 1) = 1111 ./calc.at:1479: $PREPARSER ./calc input stderr: input: syntax error: invalid character: '#' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1478: cat stderr | (* *) + (*) + (*) ./calc.at:1480: $PREPARSER ./calc input | (1 + 1) / (1 - 1) ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: stderr: 551. calc.at:1478: ok syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1479: cat stderr ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () | (* *) + (*) + (*) ./calc.at:1479: $PREPARSER ./calc input syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' stderr: ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: cat stderr stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + 1) / (1 - 1) ./calc.at:1479: $PREPARSER ./calc input ./calc.at:1480: cat stderr stderr: 564. calc.at:1489: testing Calculator glr2.cc parse.error=verbose %debug %name-prefix "calc" api.token.prefix={TOK_} %verbose ... error: null divisor ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1482: cat stderr ./calc.at:1489: mv calc.y.tmp calc.y | 1 + 2 * 3 + !+ ++ ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1479: cat stderr stderr: ./calc.at:1489: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: null divisor 556. calc.at:1482: ok stderr: input: | 1 + 2 * 3 + !+ ++ ./calc.at:1479: $PREPARSER ./calc input input: stderr: | 1 + 2 * 3 + !- ++ ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1479: cat stderr 565. calc.at:1491: testing Calculator C++ %glr-parser %locations %header parse.error=verbose %debug %name-prefix "calc" %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1491: mv calc.y.tmp calc.y stderr: input: ./calc.at:1491: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y | 1 + 2 * 3 + !- ++ ./calc.at:1479: $PREPARSER ./calc input 552. calc.at:1479: ok stderr: ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (#) + (#) = 2222 ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1479: cat stderr stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1491: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 566. calc.at:1491: testing Calculator glr2.cc %locations %header parse.error=verbose %debug %name-prefix "calc" %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1491: mv calc.y.tmp calc.y stderr: input: syntax error: invalid character: '#' syntax error: invalid character: '#' | (#) + (#) = 2222 ./calc.at:1479: $PREPARSER ./calc input stderr: ./calc.at:1491: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./calc.at:1485: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc stderr: ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 syntax error: invalid character: '#' syntax error: invalid character: '#' input: ./calc.at:1480: cat stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1485: $PREPARSER ./calc input input: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1) $2 = token '\n'./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 ./calc.at:1479: cat stderr ./calc.at:1480: $PREPARSER ./calc input stderr: ./calc.at:1491: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 2 input: ./calc.at:1485: $PREPARSER ./calc input stderr: | (1 + #) = 1111 ./calc.at:1479: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) stderr: syntax error: invalid character: '#' ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr ./calc.at:1485: cat stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1479: cat stderr | (# + 1) = 1111 ./calc.at:1480: $PREPARSER ./calc input input: stderr: | 1//2 ./calc.at:1485: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (# + 1) = 1111 ./calc.at:1479: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error: invalid character: '#' ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1480: cat stderr ./calc.at:1485: cat stderr ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + # + 1) = 1111 input: ./calc.at:1480: $PREPARSER ./calc input ./calc.at:1479: cat stderr | error stderr: ./calc.at:1485: $PREPARSER ./calc input syntax error: invalid character: '#' ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: | (1 + # + 1) = 1111 ./calc.at:1479: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: syntax error: invalid character: '#' ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () syntax error: invalid character: '#' ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: cat stderr stderr: ./calc.at:1480: cat stderr ./calc.at:1479: cat stderr stdout: ./calc.at:1482: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc input: | 1 = 2 = 3 input: ./calc.at:1485: $PREPARSER ./calc input | (1 + 1) / (1 - 1) ./calc.at:1479: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () stderr: error: null divisor ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1482: $PREPARSER ./calc input | (1 + 1) / (1 - 1) stderr: ./calc.at:1480: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: null divisor ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: null divisor stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: input: error: null divisor ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1479: cat stderr stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) 553. calc.at:1479: ok ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1485: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () 555. calc.at:1480: ok ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: cat stderr input: 567. calc.at:1492: testing Calculator C++ %glr-parser %locations %header parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1492: mv calc.y.tmp calc.y | 1//2 ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1485: $PREPARSER ./calc /dev/null stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of file Cleanup: discarding lookahead token end of file () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: 568. calc.at:1492: testing Calculator glr2.cc %locations %header parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... stderr: Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of file Cleanup: discarding lookahead token end of file () Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1492: mv calc.y.tmp calc.y ./calc.at:1492: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1485: cat stderr stdout: ./calc.at:1486: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1492: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS ./calc.at:1482: cat stderr input: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1486: $PREPARSER ./calc input | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1485: $PREPARSER ./calc input input: stderr: stderr: ./calc.at:1492: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error Cleanup: discarding lookahead token "invalid token" () Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () input: | 1 2 ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error Cleanup: discarding lookahead token "invalid token" () Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) ./calc.at:1485: cat stderr ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (!!) + (1 2) = 1 ./calc.at:1485: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 120): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1482: cat stderr ./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 120): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () input: | 1 = 2 = 3 input: ./calc.at:1482: $PREPARSER ./calc input | 1//2 ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1485: cat stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (- *) + (1 2) = 1 ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 119): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | error ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 119): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1482: cat stderr Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" () input: ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | | +1 ./calc.at:1482: $PREPARSER ./calc input stderr: ./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: stderr: input: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1489: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1486: cat stderr | (* *) + (*) + (*) ./calc.at:1485: $PREPARSER ./calc input input: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: $PREPARSER ./calc input input: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 stderr: ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1482: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (7) Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (5) Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token "number" (4) Shifting token "number" (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (256) Shifting token "number" (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (64) Shifting token "number" (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 2 ./calc.at:1489: $PREPARSER ./calc input ./calc.at:1482: $PREPARSER ./calc /dev/null stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) stderr: ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) | 1 + 2 * 3 + !+ ++ ./calc.at:1485: $PREPARSER ./calc input stderr: ./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" () stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 121): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) input: ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1486: $PREPARSER ./calc input ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 121): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () input: ./calc.at:1482: cat stderr input: | 1 + 2 * 3 + !- ++ ./calc.at:1485: $PREPARSER ./calc input stderr: | 1//2 ./calc.at:1489: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 122): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1482: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 122): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) stderr: ./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1486: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: cat stderr stderr: ./calc.at:1485: cat stderr ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" () input: | error ./calc.at:1489: $PREPARSER ./calc input input: stderr: | (#) + (#) = 2222 ./calc.at:1482: cat stderr ./calc.at:1485: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" () input: ./calc.at:1486: cat stderr stderr: | (!!) + (1 2) = 1 ./calc.at:1482: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1486: $PREPARSER ./calc input stderr: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: cat stderr stderr: ./calc.at:1485: cat stderr input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () | 1 = 2 = 3 ./calc.at:1489: $PREPARSER ./calc input ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: stderr: | (1 + #) = 1111 ./calc.at:1485: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1486: cat stderr ./calc.at:1482: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () input: | (!!) + (1 2) = 1 ./calc.at:1486: $PREPARSER ./calc input input: stderr: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (- *) + (1 2) = 1 ./calc.at:1482: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1485: cat stderr input: stderr: | | +1 stderr: ./calc.at:1489: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stdout: input: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1485: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 ./calc.at:1485: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: cat stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () input: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1482: cat stderr ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | 1 2 ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1489: $PREPARSER ./calc /dev/null input: | (* *) + (*) + (*) stderr: ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" () stderr: ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" () stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () | (1 + # + 1) = 1111 ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: cat stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (* *) + (*) + (*) ./calc.at:1486: $PREPARSER ./calc input ./calc.at:1485: cat stderr ./calc.at:1489: cat stderr input: | 1//2 ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1482: cat stderr stderr: input: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: $PREPARSER ./calc input stderr: ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1485: cat stderr | 1 + 2 * 3 + !+ ++ stderr: ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (1 + 1) / (1 - 1) ./calc.at:1485: $PREPARSER ./calc input stderr: ./calc.at:1485: cat stderr input: | error stderr: ./calc.at:1485: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 106): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () | 1 + 2 * 3 + !- ++ ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: $PREPARSER ./calc input stderr: ./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 106): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: ./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () input: stderr: | (!!) + (1 2) = 1 input: ./calc.at:1489: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) | 1 + 2 * 3 + !+ ++ ./calc.at:1486: $PREPARSER ./calc input ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1485: cat stderr ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () 558. calc.at:1485: ok stderr: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) input: | 1 + 2 * 3 + !- ++ ./calc.at:1486: $PREPARSER ./calc input ./calc.at:1482: cat stderr input: stderr: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 = 2 = 3 ./calc.at:1485: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: ./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () stderr: ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) | (#) + (#) = 2222 ./calc.at:1482: $PREPARSER ./calc input input: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () | (- *) + (1 2) = 1 ./calc.at:1489: $PREPARSER ./calc input ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 569. calc.at:1494: testing Calculator C++ %glr-parser %no-lines %locations %header parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: mv calc.y.tmp calc.y stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token "number" (2) Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1494: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1485: cat stderr | (#) + (#) = 2222 ./calc.at:1486: $PREPARSER ./calc input ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1489: cat stderr stderr: | | +1 ./calc.at:1485: $PREPARSER ./calc input stdout: stderr: input: stderr: ./calc.at:1487: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc | (* *) + (*) + (*) ./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1494: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1487: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () input: stderr: | (1 + #) = 1111 ./calc.at:1482: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1486: cat stderr input: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () | 1 2 ./calc.at:1487: $PREPARSER ./calc input ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1489: cat stderr | (1 + #) = 1111 ./calc.at:1486: $PREPARSER ./calc input ./calc.at:1485: cat stderr stderr: stderr: ./calc.at:1485: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of file Cleanup: discarding lookahead token end of file () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of file Cleanup: discarding lookahead token end of file () stderr: stdout: Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1486: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc ./calc.at:1482: cat stderr input: | 1 + 2 * 3 + !- ++ ./calc.at:1487: cat stderr input: ./calc.at:1489: $PREPARSER ./calc input stderr: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: $PREPARSER ./calc input | (# + 1) = 1111 ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1486: cat stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () | 1//2 ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1487: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (2) Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token "number" (3) Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) stderr: ./calc.at:1485: cat stderr input: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (# + 1) = 1111 ./calc.at:1486: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: | 1 2 ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) ./calc.at:1489: cat stderr ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1487: cat stderr stderr: stderr: input: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) | (#) + (#) = 2222 ./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () input: stderr: | error ./calc.at:1487: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) Cleanup: discarding lookahead token invalid token () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1482: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (2222) Shifting token "number" (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) Cleanup: discarding lookahead token invalid token () input: stderr: ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (1 + # + 1) = 1111 ./calc.at:1486: $PREPARSER ./calc input stdout: input: ./calc.at:1486: cat stderr ./calc.at:1491: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh | (1 + # + 1) = 1111 stderr: ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1485: cat stderr stderr: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () input: ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1487: cat stderr ./calc.at:1491: $PREPARSER ./calc input input: input: stderr: | 1//2 ./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: stderr: ./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: | (!!) + (1 2) = 1 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1485: $PREPARSER ./calc input input: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | 1 = 2 = 3 ./calc.at:1487: $PREPARSER ./calc input input: stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 120): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () | (1 + #) = 1111 ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 120): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 2 ./calc.at:1491: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: ./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: cat stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: input: ./calc.at:1487: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) input: ./calc.at:1485: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1486: $PREPARSER ./calc input ./calc.at:1486: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1482: $PREPARSER ./calc input ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | | +1 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: cat stderr ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1487: $PREPARSER ./calc input ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (- *) + (1 2) = 1 ./calc.at:1485: $PREPARSER ./calc input input: stderr: stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1491: cat stderr | error ./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 119): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () input: ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: | (# + 1) = 1111 ./calc.at:1489: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 119): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) Error: popping nterm input () Cleanup: discarding lookahead token '+' () input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () | 1//2 ./calc.at:1491: $PREPARSER ./calc input stderr: ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1487: cat stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1487: $PREPARSER ./calc /dev/null ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Now at end of input. syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) Cleanup: discarding lookahead token end of file () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: cat stderr ./calc.at:1482: cat stderr ./calc.at:1486: cat stderr 557. calc.at:1482: ok ./calc.at:1486: cat stderr stderr: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Now at end of input. syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) Cleanup: discarding lookahead token end of file () input: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: cat stderr | (* *) + (*) + (*) input: ./calc.at:1485: $PREPARSER ./calc input | 1 = 2 = 3 ./calc.at:1486: $PREPARSER ./calc input 560. calc.at:1486: ok stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: cat stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () input: | error ./calc.at:1487: cat stderr ./calc.at:1491: $PREPARSER ./calc input input: stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () | (1 + # + 1) = 1111 ./calc.at:1489: $PREPARSER ./calc input ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1487: $PREPARSER ./calc input ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1485: cat stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1491: cat stderr input: | 1 = 2 = 3 stderr: ./calc.at:1486: cat stderr input: ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1487: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token "number" (1) Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token "number" (1111) Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1485: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) input: | | +1 stderr: ./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 121): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) 570. calc.at:1494: testing Calculator glr2.cc %no-lines %locations %header parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... ./calc.at:1494: mv calc.y.tmp calc.y ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (!!) + (1 2) = 1 ./calc.at:1487: $PREPARSER ./calc input stderr: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 120): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 121): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 571. calc.at:1504: testing Calculator lalr1.d ... ./calc.at:1504: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y input: ./calc.at:1494: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y | 1 + 2 * 3 + !- ++ ./calc.at:1485: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 122): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 120): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 122): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) input: ./calc.at:1489: cat stderr 571. calc.at:1504: | | +1 ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 skipped (calc.at:1504) ./calc.at:1487: cat stderr stderr: ./calc.at:1486: cat stderr input: | (1 + 1) / (1 - 1) ./calc.at:1489: $PREPARSER ./calc input ./calc.at:1486: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) stderr: stderr: Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token end of input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token "end of input" () Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1494: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS ./calc.at:1485: cat stderr stderr: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token end of input () | (- *) + (1 2) = 1 | (#) + (#) = 2222 ./calc.at:1487: $PREPARSER ./calc input ./calc.at:1485: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 119): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 119): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1487: cat stderr 572. calc.at:1509: testing Calculator D ... ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1509: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y stderr: 563. calc.at:1489: ok stdout: ./calc.at:1489: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc input: | (* *) + (*) + (*) ./calc.at:1487: $PREPARSER ./calc input ./calc.at:1486: cat stderr ./calc.at:1491: cat stderr input: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1486: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1491: $PREPARSER ./calc /dev/null ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1489: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: cat stderr input: | (1 + #) = 1111 ./calc.at:1485: $PREPARSER ./calc input ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 572. calc.at:1509: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (7) Shifting token number (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) -> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) -> $$ = nterm exp (-5) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (5) Shifting token number (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) -> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) -> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) -> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) -> $$ = nterm exp (-1) Entering state 8 Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-4) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token number (4) Shifting token number (4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () Reducing stack 0 by rule 11 (line 102): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) -> $$ = nterm exp (-4) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) -> $$ = nterm exp (-1) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () -> $$ = nterm exp (-1) Entering state 28 Reading a token Next token is token '=' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) -> $$ = nterm exp (2) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) -> $$ = nterm exp (256) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (256) Shifting token number (256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) -> $$ = nterm exp (256) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (4) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () -> $$ = nterm exp (4) Entering state 8 Reading a token Next token is token '^' () Shifting token '^' () Entering state 23 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (64) Shifting token number (64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) -> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1487: cat stderr stderr: skipped (calc.at:1509) input: input: | 1 2 ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1487: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 121): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: cat stderr stderr: ./calc.at:1491: cat stderr ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: | (!!) + (1 2) = 1 ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 121): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) input: stderr: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1491: $PREPARSER ./calc input 573. calc.at:1510: testing Calculator D %locations ... | 1 + 2 * 3 + !- ++ stderr: ./calc.at:1510: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y input: ./calc.at:1487: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 122): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 ./calc.at:1485: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 122): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1489: cat stderr ./calc.at:1486: cat stderr input: stderr: | 1//2 input: ./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 574. calc.at:1512: testing Calculator D parse.error=detailed api.prefix={calc} %verbose ... ./calc.at:1512: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y ./calc.at:1487: cat stderr | (- *) + (1 2) = 1 ./calc.at:1491: cat stderr ./calc.at:1486: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '/' () syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 573. calc.at:1510: input: skipped (calc.at:1510) input: | (#) + (#) = 2222 stderr: | (!!) + (1 2) = 1 ./calc.at:1487: $PREPARSER ./calc input ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 574. calc.at:1512: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: skipped (calc.at:1512) stderr: ./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: | (1 + # + 1) = 1111 ./calc.at:1485: $PREPARSER ./calc input stdout: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1492: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1486: cat stderr ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () input: input: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1487: cat stderr ./calc.at:1492: $PREPARSER ./calc input stderr: | error ./calc.at:1489: $PREPARSER ./calc input | (- *) + (1 2) = 1 ./calc.at:1491: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) input: stderr: ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1485: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () stderr: ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) input: input: | 1 2 ./calc.at:1492: $PREPARSER ./calc input | (* *) + (*) + (*) ./calc.at:1486: $PREPARSER ./calc input | (1 + #) = 1111 ./calc.at:1487: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) 575. calc.at:1514: testing Calculator D %debug ... ./calc.at:1514: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () | (1 + 1) / (1 - 1) ./calc.at:1485: $PREPARSER ./calc input stderr: stderr: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 576. calc.at:1516: testing Calculator D parse.error=custom ... ./calc.at:1516: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 106): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: stderr: stderr: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 106): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () 575. calc.at:1514: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: cat stderr ./calc.at:1489: cat stderr skipped (calc.at:1514) ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1//2 ./calc.at:1492: $PREPARSER ./calc input ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: cat stderr ./calc.at:1485: cat stderr input: stderr: | 1 = 2 = 3 ./calc.at:1489: $PREPARSER ./calc input ./calc.at:1486: cat stderr 576. calc.at:1516: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) skipped (calc.at:1516) 559. calc.at:1485: ok stderr: ./calc.at:1487: cat stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: | (* *) + (*) + (*) ./calc.at:1491: $PREPARSER ./calc input stderr: input: | 1 + 2 * 3 + !+ ++ ./calc.at:1486: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () syntax error, unexpected '=' Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (# + 1) = 1111 ./calc.at:1487: $PREPARSER ./calc input stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 577. calc.at:1517: testing Calculator D %locations parse.error=custom ... input: ./calc.at:1517: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | 1 + 2 * 3 + !- ++ ./calc.at:1486: $PREPARSER ./calc input stderr: ./calc.at:1492: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 578. calc.at:1518: testing Calculator D %locations parse.error=detailed ... Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1518: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y ./calc.at:1489: cat stderr stderr: input: | error ./calc.at:1491: cat stderr ./calc.at:1492: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) stderr: 577. calc.at:1517: input: skipped (calc.at:1517) input: ./calc.at:1487: cat stderr Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) | | +1 | 1 + 2 * 3 + !+ ++ ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1489: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: 579. calc.at:1519: testing Calculator D %locations parse.error=simple ... ./calc.at:1519: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 578. calc.at:1518: | (1 + # + 1) = 1111 ./calc.at:1487: $PREPARSER ./calc input stderr: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) stderr: skipped (calc.at:1518) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' () Shifting token '\n' () Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Next token is token '+' () syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1486: cat stderr input: stderr: | 1 + 2 * 3 + !- ++ Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: cat stderr 579. calc.at:1519: stderr: skipped (calc.at:1519) input: | (#) + (#) = 2222 ./calc.at:1486: $PREPARSER ./calc input 580. calc.at:1520: testing Calculator D parse.error=detailed %debug %verbose ... stderr: ./calc.at:1520: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () | 1 = 2 = 3 ./calc.at:1487: cat stderr ./calc.at:1492: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) stderr: ./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + 1) / (1 - 1) ./calc.at:1489: $PREPARSER ./calc /dev/null ./calc.at:1487: $PREPARSER ./calc input ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 582. calc.at:1523: testing Calculator D %locations parse.lac=full parse.error=detailed ... ./calc.at:1486: cat stderr stderr: stderr: 581. calc.at:1521: testing Calculator D parse.error=detailed %debug api.symbol.prefix={SYMB_} api.token.prefix={TOK_} %verbose ... ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token end of input () stderr: ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1523: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y stderr: ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 106): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1521: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Now at end of input. syntax error, unexpected end of input Cleanup: discarding lookahead token end of input () input: 580. calc.at:1520: stderr: | (1 + #) = 1111 ./calc.at:1486: $PREPARSER ./calc input skipped (calc.at:1520) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 106): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of file () Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (#) + (#) = 2222 ./calc.at:1492: cat stderr ./calc.at:1491: $PREPARSER ./calc input stderr: stderr: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 582. calc.at:1523: input: skipped (calc.at:1523) ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: cat stderr | | +1 ./calc.at:1492: $PREPARSER ./calc input ./calc.at:1487: cat stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) 581. calc.at:1521: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) skipped (calc.at:1521) input: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 562. calc.at:1487: ok ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1489: $PREPARSER ./calc input ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: cat stderr stderr: stderr: 583. calc.at:1524: testing Calculator D %locations parse.lac=full parse.error=custom ... ./calc.at:1524: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) stderr: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (3) Entering state 12 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token ')' () syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) -> $$ = nterm exp (2) Entering state 12 Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) error: 4444 != 1 -> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () input: | (# + 1) = 1111 ./calc.at:1486: $PREPARSER ./calc input | (1 + #) = 1111 stderr: ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1492: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: $PREPARSER ./calc /dev/null 583. calc.at:1524: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: skipped (calc.at:1524) Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 584. calc.at:1525: testing Calculator D %locations parse.lac=full parse.error=detailed parse.trace ... ./calc.at:1525: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1489: cat stderr 585. calc.at:1530: testing Calculator D api.token.constructor %locations parse.error=custom api.value.type=union ... ./calc.at:1530: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 586. calc.at:1531: testing Calculator D api.token.constructor %locations parse.error=detailed ... ./calc.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1489: $PREPARSER ./calc input ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1486: cat stderr stderr: ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: cat stderr 584. calc.at:1525: stderr: 585. calc.at:1530: input: input: skipped (calc.at:1530) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '!' () Shifting token '!' () Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' () $2 = token '!' () Shifting token error () Entering state 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () skipped (calc.at:1525) 586. calc.at:1531: | (# + 1) = 1111 ./calc.at:1491: $PREPARSER ./calc input | (1 + # + 1) = 1111 ./calc.at:1486: $PREPARSER ./calc input input: stderr: skipped (calc.at:1531) stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1492: $PREPARSER ./calc input 587. calc.at:1532: testing Calculator D api.push-pull=both ... ./calc.at:1532: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 587. calc.at:1532: ./calc.at:1491: cat stderr ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 skipped (calc.at:1532) input: 588. calc.at:1533: testing Calculator D parse.trace parse.error=custom %locations api.push-pull=both parse.lac=full ... ./calc.at:1533: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y | (- *) + (1 2) = 1 ./calc.at:1489: $PREPARSER ./calc input 589. calc.at:1544: testing Calculator Java ... stderr: ./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () input: ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 590. calc.at:1545: testing Calculator Java parse.error=custom ... ./calc.at:1545: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y ./calc.at:1544: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y | (1 + # + 1) = 1111 stderr: ./calc.at:1491: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '-' () Shifting token '-' () Entering state 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' () $2 = token error () Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token number (2) Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | (1 + 1) / (1 - 1) ./calc.at:1492: cat stderr ./calc.at:1486: $PREPARSER ./calc input ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (!!) + (1 2) = 1 588. calc.at:1533: ./calc.at:1492: $PREPARSER ./calc input skipped (calc.at:1533) stderr: stderr: 590. calc.at:1545: stderr: ./calc.at:1489: cat stderr skipped (calc.at:1545) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 589. calc.at:1544: 591. calc.at:1546: testing Calculator Java parse.error=detailed ... ./calc.at:1546: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y skipped (calc.at:1544) input: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () | (* *) + (*) + (*) ./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '\n' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1486: cat stderr ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 591. calc.at:1546: | (1 + 1) / (1 - 1) ./calc.at:1491: $PREPARSER ./calc input skipped (calc.at:1546) 561. calc.at:1486: ok 592. calc.at:1547: testing Calculator Java parse.error=verbose ... stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1547: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y ./calc.at:1492: cat stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 593. calc.at:1548: testing Calculator Java %locations parse.error=custom ... ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: cat stderr ./calc.at:1548: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y 594. calc.at:1549: testing Calculator Java %locations parse.error=detailed ... ./calc.at:1549: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (- *) + (1 2) = 1 input: ./calc.at:1492: $PREPARSER ./calc input stderr: | 1 + 2 * 3 + !+ ++ Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1489: $PREPARSER ./calc input ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: 592. calc.at:1547: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 593. calc.at:1548: skipped (calc.at:1547) stderr: skipped (calc.at:1548) stderr: ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '+' () Shifting token '+' () Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' () $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) 595. calc.at:1550: testing Calculator Java %locations parse.error=verbose ... 594. calc.at:1549: ./calc.at:1550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y skipped (calc.at:1549) input: 565. calc.at:1491: ok | 1 + 2 * 3 + !- ++ ./calc.at:1489: $PREPARSER ./calc input 596. calc.at:1551: testing Calculator Java parse.trace parse.error=verbose ... ./calc.at:1551: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token Next token is token number (3) Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '!' () Shifting token '!' () Entering state 5 Reading a token Next token is token '-' () Shifting token '-' () Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' () $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) 596. calc.at:1551: 595. calc.at:1550: input: | (* *) + (*) + (*) ./calc.at:1492: $PREPARSER ./calc input 598. calc.at:1554: testing Calculator Java api.push-pull=both ... ./calc.at:1554: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y skipped (calc.at:1551) skipped (calc.at:1550) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 599. calc.at:1555: testing Calculator Java api.push-pull=both parse.error=detailed %locations ... ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y ./calc.at:1489: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 597. calc.at:1552: testing Calculator Java parse.trace parse.error=verbose %locations %lex-param {InputStream is} ... ./calc.at:1552: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: 600. calc.at:1556: testing Calculator Java parse.trace parse.error=custom %locations %lex-param {InputStream is} api.push-pull=both ... | (#) + (#) = 2222 ./calc.at:1489: $PREPARSER ./calc input ./calc.at:1556: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y ./calc.at:1492: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (2222) Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () 598. calc.at:1554: 601. calc.at:1557: testing Calculator Java parse.trace parse.error=verbose %locations %lex-param {InputStream is} api.push-pull=both ... skipped (calc.at:1554) 602. calc.at:1560: testing Calculator Java parse.trace parse.error=custom %locations parse.lac=full ... 597. calc.at:1552: ./calc.at:1560: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y ./calc.at:1557: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y input: skipped (calc.at:1552) 599. calc.at:1555: | 1 + 2 * 3 + !+ ++ ./calc.at:1492: $PREPARSER ./calc input skipped (calc.at:1555) stderr: 602. calc.at:1560: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) skipped (calc.at:1560) ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: cat stderr 600. calc.at:1556: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr skipped (calc.at:1556) stderr: input: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | (1 + #) = 1111 ./calc.at:1489: $PREPARSER ./calc input input: stderr: 601. calc.at:1557: | 1 + 2 * 3 + !- ++ skipped (calc.at:1557) ./calc.at:1492: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 603. calc.at:1561: testing Calculator Java parse.trace parse.error=custom %locations api.push-pull=both parse.lac=full ... ./calc.at:1561: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y stderr: 605. torture.at:216: testing Big horizontal ... ./torture.at:230: "$PERL" -w ./gengram.pl 1000 || exit 77 stdout: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) 604. torture.at:132: testing Big triangle ... ./torture.at:138: "$PERL" -w ./gengram.pl 200 || exit 77 stderr: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () %code top { /* -*- c -*- */ /* Adjust to the compiler. We used to do it here, but each time we add a new line, we have to adjust all the line numbers in error messages. It's simpler to use a constant include to a varying file. */ #include } %define parse.error verbose %debug %{ #include #include #define MAX 1000 static int yylex (void); #include /* !POSIX */ static void yyerror (const char *msg); %} %token t1 1 "1" t2 2 "2" t3 3 "3" t4 4 "4" t5 5 "5" t6 6 "6" t7 7 "7" t8 8 "8" t9 9 "9" t10 10 "10" t11 11 "11" t12 12 "12" t13 13 "13" t14 14 "14" t15 15 "15" t16 16 "16" t17 17 "17" t18 18 "18" t19 19 "19" t20 20 "20" t21 21 "21" t22 22 "22" t23 23 "23" t24 24 "24" t25 25 "25" t26 26 "26" t27 27 "27" t28 28 "28" t29 29 "29" t30 30 "30" t31 31 "31" t32 32 "32" t33 33 "33" t34 34 "34" t35 35 "35" t36 36 "36" t37 37 "37" t38 38 "38" t39 39 "39" t40 40 "40" t41 41 "41" t42 42 "42" t43 43 "43" t44 44 "44" t45 45 "45" t46 46 "46" t47 47 "47" t48 48 "48" t49 49 "49" t50 50 "50" t51 51 "51" t52 52 "52" t53 53 "53" t54 54 "54" t55 55 "55" t56 56 "56" t57 57 "57" t58 58 "58" t59 59 "59" t60 60 "60" t61 61 "61" t62 62 "62" t63 63 "63" t64 64 "64" t65 65 "65" t66 66 "66" t67 67 "67" t68 68 "68" t69 69 "69" t70 70 "70" t71 71 "71" t72 72 "72" t73 73 "73" t74 74 "74" t75 75 "75" t76 76 "76" t77 77 "77" t78 78 "78" t79 79 "79" t80 80 "80" t81 81 "81" t82 82 "82" t83 83 "83" t84 84 "84" t85 85 "85" t86 86 "86" t87 87 "87" t88 88 "88" t89 89 "89" t90 90 "90" t91 91 "91" t92 92 "92" t93 93 "93" t94 94 "94" t95 95 "95" t96 96 "96" t97 97 "97" t98 98 "98" t99 99 "99" t100 100 "100" t101 101 "101" t102 102 "102" t103 103 "103" t104 104 "104" t105 105 "105" t106 106 "106" t107 107 "107" t108 108 "108" t109 109 "109" t110 110 "110" t111 111 "111" t112 112 "112" t113 113 "113" t114 114 "114" t115 115 "115" t116 116 "116" t117 117 "117" t118 118 "118" t119 119 "119" t120 120 "120" t121 121 "121" t122 122 "122" t123 123 "123" t124 124 "124" t125 125 "125" t126 126 "126" t127 127 "127" t128 128 "128" t129 129 "129" t130 130 "130" t131 131 "131" t132 132 "132" t133 133 "133" t134 134 "134" t135 135 "135" t136 136 "136" t137 137 "137" t138 138 "138" t139 139 "139" t140 140 "140" t141 141 "141" t142 142 "142" t143 143 "143" t144 144 "144" t145 145 "145" t146 146 "146" t147 147 "147" t148 148 "148" t149 149 "149" t150 150 "150" t151 151 "151" t152 152 "152" t153 153 "153" t154 154 "154" t155 155 "155" t156 156 "156" t157 157 "157" t158 158 "158" t159 159 "159" t160 160 "160" t161 161 "161" t162 162 "162" t163 163 "163" t164 164 "164" t165 165 "165" t166 166 "166" t167 167 "167" t168 168 "168" t169 169 "169" t170 170 "170" t171 171 "171" t172 172 "172" t173 173 "173" t174 174 "174" t175 175 "175" t176 176 "176" t177 177 "177" t178 178 "178" t179 179 "179" t180 180 "180" t181 181 "181" t182 182 "182" t183 183 "183" t184 184 "184" t185 185 "185" t186 186 "186" t187 187 "187" t188 188 "188" t189 189 "189" t190 190 "190" t191 191 "191" t192 192 "192" t193 193 "193" t194 194 "194" t195 195 "195" t196 196 "196" t197 197 "197" t198 198 "198" t199 199 "199" t200 200 "200" t201 201 "201" t202 202 "202" t203 203 "203" t204 204 "204" t205 205 "205" t206 206 "206" t207 207 "207" t208 208 "208" t209 209 "209" t210 210 "210" t211 211 "211" t212 212 "212" t213 213 "213" t214 214 "214" t215 215 "215" t216 216 "216" t217 217 "217" t218 218 "218" t219 219 "219" t220 220 "220" t221 221 "221" t222 222 "222" t223 223 "223" t224 224 "224" t225 225 "225" t226 226 "226" t227 227 "227" t228 228 "228" t229 229 "229" t230 230 "230" t231 231 "231" t232 232 "232" t233 233 "233" t234 234 "234" t235 235 "235" t236 236 "236" t237 237 "237" t238 238 "238" t239 239 "239" t240 240 "240" t241 241 "241" t242 242 "242" t243 243 "243" t244 244 "244" t245 245 "245" t246 246 "246" t247 247 "247" t248 248 "248" t249 249 "249" t250 250 "250" t251 251 "251" t252 252 "252" t253 253 "253" t254 254 "254" t255 255 "255" t256 256 "256" t257 257 "257" t258 258 "258" t259 259 "259" t260 260 "260" t261 261 "261" t262 262 "262" t263 263 "263" t264 264 "264" t265 265 "265" t266 266 "266" t267 267 "267" t268 268 "268" t269 269 "269" t270 270 "270" t271 271 "271" t272 272 "272" t273 273 "273" t274 274 "274" t275 275 "275" t276 276 "276" t277 277 "277" t278 278 "278" t279 279 "279" t280 280 "280" t281 281 "281" t282 282 "282" t283 283 "283" t284 284 "284" t285 285 "285" t286 286 "286" t287 287 "287" t288 288 "288" t289 289 "289" t290 290 "290" t291 291 "291" t292 292 "292" t293 293 "293" t294 294 "294" t295 295 "295" t296 296 "296" t297 297 "297" t298 298 "298" t299 299 "299" t300 300 "300" t301 301 "301" t302 302 "302" t303 303 "303" t304 304 "304" t305 305 "305" t306 306 "306" t307 307 "307" t308 308 "308" t309 309 "309" t310 310 "310" t311 311 "311" t312 312 "312" t313 313 "313" t314 314 "314" t315 315 "315" t316 316 "316" t317 317 "317" t318 318 "318" t319 319 "319" t320 320 "320" t321 321 "321" t322 322 "322" t323 323 "323" t324 324 "324" t325 325 "325" t326 326 "326" t327 327 "327" t328 328 "328" t329 329 "329" t330 330 "330" t331 331 "331" t332 332 "332" t333 333 "333" t334 334 "334" t335 335 "335" t336 336 "336" t337 337 "337" t338 338 "338" t339 339 "339" t340 340 "340" t341 341 "341" t342 342 "342" t343 343 "343" t344 344 "344" t345 345 "345" t346 346 "346" t347 347 "347" t348 348 "348" t349 349 "349" t350 350 "350" t351 351 "351" t352 352 "352" t353 353 "353" t354 354 "354" t355 355 "355" t356 356 "356" t357 357 "357" t358 358 "358" t359 359 "359" t360 360 "360" t361 361 "361" t362 362 "362" t363 363 "363" t364 364 "364" t365 365 "365" t366 366 "366" t367 367 "367" t368 368 "368" t369 369 "369" t370 370 "370" t371 371 "371" t372 372 "372" t373 373 "373" t374 374 "374" t375 375 "375" t376 376 "376" t377 377 "377" t378 378 "378" t379 379 "379" t380 380 "380" t381 381 "381" t382 382 "382" t383 383 "383" t384 384 "384" t385 385 "385" t386 386 "386" t387 387 "387" t388 388 "388" t389 389 "389" t390 390 "390" t391 391 "391" t392 392 "392" t393 393 "393" t394 394 "394" t395 395 "395" t396 396 "396" t397 397 "397" t398 398 "398" t399 399 "399" t400 400 "400" t401 401 "401" t402 402 "402" t403 403 "403" t404 404 "404" t405 405 "405" t406 406 "406" t407 407 "407" t408 408 "408" t409 409 "409" t410 410 "410" t411 411 "411" t412 412 "412" t413 413 "413" t414 414 "414" t415 415 "415" t416 416 "416" t417 417 "417" t418 418 "418" t419 419 "419" t420 420 "420" t421 421 "421" t422 422 "422" t423 423 "423" t424 424 "424" t425 425 "425" t426 426 "426" t427 427 "427" t428 428 "428" t429 429 "429" t430 430 "430" t431 431 "431" t432 432 "432" t433 433 "433" t434 434 "434" t435 435 "435" t436 436 "436" t437 437 "437" t438 438 "438" t439 439 "439" t440 440 "440" t441 441 "441" t442 442 "442" t443 443 "443" t444 444 "444" t445 445 "445" t446 446 "446" t447 447 "447" t448 448 "448" t449 449 "449" t450 450 "450" t451 451 "451" t452 452 "452" t453 453 "453" t454 454 "454" t455 455 "455" t456 456 "456" t457 457 "457" t458 458 "458" t459 459 "459" t460 460 "460" t461 461 "461" t462 462 "462" t463 463 "463" t464 464 "464" t465 465 "465" t466 466 "466" t467 467 "467" t468 468 "468" t469 469 "469" t470 470 "470" t471 471 "471" t472 472 "472" t473 473 "473" t474 474 "474" t475 475 "475" t476 476 "476" t477 477 "477" t478 478 "478" t479 479 "479" t480 480 "480" t481 481 "481" t482 482 "482" t483 483 "483" t484 484 "484" t485 485 "485" t486 486 "486" t487 487 "487" t488 488 "488" t489 489 "489" t490 490 "490" t491 491 "491" t492 492 "492" t493 493 "493" t494 494 "494" t495 495 "495" t496 496 "496" t497 497 "497" t498 498 "498" t499 499 "499" t500 500 "500" t501 501 "501" t502 502 "502" t503 503 "503" t504 504 "504" t505 505 "505" t506 506 "506" t507 507 "507" t508 508 "508" t509 509 "509" t510 510 "510" t511 511 "511" t512 512 "512" t513 513 "513" t514 514 "514" t515 515 "515" t516 516 "516" t517 517 "517" t518 518 "518" t519 519 "519" t520 520 "520" t521 521 "521" t522 522 "522" t523 523 "523" t524 524 "524" t525 525 "525" t526 526 "526" t527 527 "527" t528 528 "528" t529 529 "529" t530 530 "530" t531 531 "531" t532 532 "532" t533 533 "533" t534 534 "534" t535 535 "535" t536 536 "536" t537 537 "537" t538 538 "538" t539 539 "539" t540 540 "540" t541 541 "541" t542 542 "542" t543 543 "543" t544 544 "544" t545 545 "545" t546 546 "546" t547 547 "547" t548 548 "548" t549 549 "549" t550 550 "550" t551 551 "551" t552 552 "552" t553 553 "553" t554 554 "554" t555 555 "555" t556 556 "556" t557 557 "557" t558 558 "558" t559 559 "559" t560 560 "560" t561 561 "561" t562 562 "562" t563 563 "563" t564 564 "564" t565 565 "565" t566 566 "566" t567 567 "567" t568 568 "568" t569 569 "569" t570 570 "570" t571 571 "571" t572 572 "572" t573 573 "573" t574 574 "574" t575 575 "575" t576 576 "576" t577 577 "577" t578 578 "578" t579 579 "579" t580 580 "580" t581 581 "581" t582 582 "582" t583 583 "583" t584 584 "584" t585 585 "585" t586 586 "586" t587 587 "587" t588 588 "588" t589 589 "589" t590 590 "590" t591 591 "591" t592 592 "592" t593 593 "593" t594 594 "594" t595 595 "595" t596 596 "596" t597 597 "597" t598 598 "598" t599 599 "599" t600 600 "600" t601 601 "601" t602 602 "602" t603 603 "603" t604 604 "604" t605 605 "605" t606 606 "606" t607 607 "607" t608 608 "608" t609 609 "609" t610 610 "610" t611 611 "611" t612 612 "612" t613 613 "613" t614 614 "614" t615 615 "615" t616 616 "616" t617 617 "617" t618 618 "618" t619 619 "619" t620 620 "620" t621 621 "621" t622 622 "622" t623 623 "623" t624 624 "624" t625 625 "625" t626 626 "626" t627 627 "627" t628 628 "628" t629 629 "629" t630 630 "630" t631 631 "631" t632 632 "632" t633 633 "633" t634 634 "634" t635 635 "635" t636 636 "636" t637 637 "637" t638 638 "638" t639 639 "639" t640 640 "640" t641 641 "641" t642 642 "642" t643 643 "643" t644 644 "644" t645 645 "645" t646 646 "646" t647 647 "647" t648 648 "648" t649 649 "649" t650 650 "650" t651 651 "651" t652 652 "652" t653 653 "653" t654 654 "654" t655 655 "655" t656 656 "656" t657 657 "657" t658 658 "658" t659 659 "659" t660 660 "660" t661 661 "661" t662 662 "662" t663 663 "663" t664 664 "664" t665 665 "665" t666 666 "666" t667 667 "667" t668 668 "668" t669 669 "669" t670 670 "670" t671 671 "671" t672 672 "672" t673 673 "673" t674 674 "674" t675 675 "675" t676 676 "676" t677 677 "677" t678 678 "678" t679 679 "679" t680 680 "680" t681 681 "681" t682 682 "682" t683 683 "683" t684 684 "684" t685 685 "685" t686 686 "686" t687 687 "687" t688 688 "688" t689 689 "689" t690 690 "690" t691 691 "691" t692 692 "692" t693 693 "693" t694 694 "694" t695 695 "695" t696 696 "696" t697 697 "697" t698 698 "698" t699 699 "699" t700 700 "700" t701 701 "701" t702 702 "702" t703 703 "703" t704 704 "704" t705 705 "705" t706 706 "706" t707 707 "707" t708 708 "708" t709 709 "709" t710 710 "710" t711 711 "711" t712 712 "712" t713 713 "713" t714 714 "714" t715 715 "715" t716 716 "716" t717 717 "717" t718 718 "718" t719 719 "719" t720 720 "720" t721 721 "721" t722 722 "722" t723 723 "723" t724 724 "724" t725 725 "725" t726 726 "726" t727 727 "727" t728 728 "728" t729 729 "729" t730 730 "730" t731 731 "731" t732 732 "732" t733 733 "733" t734 734 "734" t735 735 "735" t736 736 "736" t737 737 "737" t738 738 "738" t739 739 "739" t740 740 "740" t741 741 "741" t742 742 "742" t743 743 "743" t744 744 "744" t745 745 "745" t746 746 "746" t747 747 "747" t748 748 "748" t749 749 "749" t750 750 "750" t751 751 "751" t752 752 "752" t753 753 "753" t754 754 "754" t755 755 "755" t756 756 "756" t757 757 "757" t758 758 "758" t759 759 "759" t760 760 "760" t761 761 "761" t762 762 "762" t763 763 "763" t764 764 "764" t765 765 "765" t766 766 "766" t767 767 "767" t768 768 "768" t769 769 "769" t770 770 "770" t771 771 "771" t772 772 "772" t773 773 "773" t774 774 "774" t775 775 "775" t776 776 "776" t777 777 "777" t778 778 "778" t779 779 "779" t780 780 "780" t781 781 "781" t782 782 "782" t783 783 "783" t784 784 "784" t785 785 "785" t786 786 "786" t787 787 "787" t788 788 "788" t789 789 "789" t790 790 "790" t791 791 "791" t792 792 "792" t793 793 "793" t794 794 "794" t795 795 "795" t796 796 "796" t797 797 "797" t798 798 "798" t799 799 "799" t800 800 "800" t801 801 "801" t802 802 "802" t803 803 "803" t804 804 "804" t805 805 "805" t806 806 "806" t807 807 "807" t808 808 "808" t809 809 "809" t810 810 "810" t811 811 "811" t812 812 "812" t813 813 "813" t814 814 "814" t815 815 "815" t816 816 "816" t817 817 "817" t818 818 "818" t819 819 "819" t820 820 "820" t821 821 "821" t822 822 "822" t823 823 "823" t824 824 "824" t825 825 "825" t826 826 "826" t827 827 "827" t828 828 "828" t829 829 "829" t830 830 "830" t831 831 "831" t832 832 "832" t833 833 "833" t834 834 "834" t835 835 "835" t836 836 "836" t837 837 "837" t838 838 "838" t839 839 "839" t840 840 "840" t841 841 "841" t842 842 "842" t843 843 "843" t844 844 "844" t845 845 "845" t846 846 "846" t847 847 "847" t848 848 "848" t849 849 "849" t850 850 "850" t851 851 "851" t852 852 "852" t853 853 "853" t854 854 "854" t855 855 "855" t856 856 "856" t857 857 "857" t858 858 "858" t859 859 "859" t860 860 "860" t861 861 "861" t862 862 "862" t863 863 "863" t864 864 "864" t865 865 "865" t866 866 "866" t867 867 "867" t868 868 "868" t869 869 "869" t870 870 "870" t871 871 "871" t872 872 "872" t873 873 "873" t874 874 "874" t875 875 "875" t876 876 "876" t877 877 "877" t878 878 "878" t879 879 "879" t880 880 "880" t881 881 "881" t882 882 "882" t883 883 "883" t884 884 "884" t885 885 "885" t886 886 "886" t887 887 "887" t888 888 "888" t889 889 "889" t890 890 "890" t891 891 "891" t892 892 "892" t893 893 "893" t894 894 "894" t895 895 "895" t896 896 "896" t897 897 "897" t898 898 "898" t899 899 "899" t900 900 "900" t901 901 "901" t902 902 "902" t903 903 "903" t904 904 "904" t905 905 "905" t906 906 "906" t907 907 "907" t908 908 "908" t909 909 "909" t910 910 "910" t911 911 "911" t912 912 "912" t913 913 "913" t914 914 "914" t915 915 "915" t916 916 "916" t917 917 "917" t918 918 "918" t919 919 "919" t920 920 "920" t921 921 "921" t922 922 "922" t923 923 "923" t924 924 "924" t925 925 "925" t926 926 "926" t927 927 "927" t928 928 "928" t929 929 "929" t930 930 "930" t931 931 "931" t932 932 "932" t933 933 "933" t934 934 "934" t935 935 "935" t936 936 "936" t937 937 "937" t938 938 "938" t939 939 "939" t940 940 "940" t941 941 "941" t942 942 "942" t943 943 "943" t944 944 "944" t945 945 "945" t946 946 "946" t947 947 "947" t948 948 "948" t949 949 "949" t950 950 "950" t951 951 "951" t952 952 "952" t953 953 "953" t954 954 "954" t955 955 "955" t956 956 "956" t957 957 "957" t958 958 "958" t959 959 "959" t960 960 "960" t961 961 "961" t962 962 "962" t963 963 "963" t964 964 "964" t965 965 "965" t966 966 "966" t967 967 "967" t968 968 "968" t969 969 "969" t970 970 "970" t971 971 "971" t972 972 "972" t973 973 "973" t974 974 "974" t975 975 "975" t976 976 "976" t977 977 "977" t978 978 "978" t979 979 "979" t980 980 "980" t981 981 "981" t982 982 "982" t983 983 "983" t984 984 "984" t985 985 "985" t986 986 "986" t987 987 "987" t988 988 "988" t989 989 "989" t990 990 "990" t991 991 "991" t992 992 "992" t993 993 "993" t994 994 "994" t995 995 "995" t996 996 "996" t997 997 "997" t998 998 "998" t999 999 "999" t1000 1000 "1000" %% exp: "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" "196" "197" "198" "199" "200" "201" "202" "203" "204" "205" "206" "207" "208" "209" "210" "211" "212" "213" "214" "215" "216" "217" "218" "219" "220" "221" "222" "223" "224" "225" "226" "227" "228" "229" "230" "231" "232" "233" "234" "235" "236" "237" "238" "239" "240" "241" "242" "243" "244" "245" "246" "247" "248" "249" "250" "251" "252" "253" "254" "255" "256" "257" "258" "259" "260" "261" "262" "263" "264" "265" "266" "267" "268" "269" "270" "271" "272" "273" "274" "275" "276" "277" "278" "279" "280" "281" "282" "283" "284" "285" "286" "287" "288" "289" "290" "291" "292" "293" "294" "295" "296" "297" "298" "299" "300" "301" "302" "303" "304" "305" "306" "307" "308" "309" "310" "311" "312" "313" "314" "315" "316" "317" "318" "319" "320" "321" "322" "323" "324" "325" "326" "327" "328" "329" "330" "331" "332" "333" "334" "335" "336" "337" "338" "339" "340" "341" "342" "343" "344" "345" "346" "347" "348" "349" "350" "351" "352" "353" "354" "355" "356" "357" "358" "359" "360" "361" "362" "363" "364" "365" "366" "367" "368" "369" "370" "371" "372" "373" "374" "375" "376" "377" "378" "379" "380" "381" "382" "383" "384" "385" "386" "387" "388" "389" "390" "391" "392" "393" "394" "395" "396" "397" "398" "399" "400" "401" "402" "403" "404" "405" "406" "407" "408" "409" "410" "411" "412" "413" "414" "415" "416" "417" "418" "419" "420" "421" "422" "423" "424" "425" "426" "427" "428" "429" "430" "431" "432" "433" "434" "435" "436" "437" "438" "439" "440" "441" "442" "443" "444" "445" "446" "447" "448" "449" "450" "451" "452" "453" "454" "455" "456" "457" "458" "459" "460" "461" "462" "463" "464" "465" "466" "467" "468" "469" "470" "471" "472" "473" "474" "475" "476" "477" "478" "479" "480" "481" "482" "483" "484" "485" "486" "487" "488" "489" "490" "491" "492" "493" "494" "495" "496" "497" "498" "499" "500" "501" "502" "503" "504" "505" "506" "507" "508" "509" "510" "511" "512" "513" "514" "515" "516" "517" "518" "519" "520" "521" "522" "523" "524" "525" "526" "527" "528" "529" "530" "531" "532" "533" "534" "535" "536" "537" "538" "539" "540" "541" "542" "543" "544" "545" "546" "547" "548" "549" "550" "551" "552" "553" "554" "555" "556" "557" "558" "559" "560" "561" "562" "563" "564" "565" "566" "567" "568" "569" "570" "571" "572" "573" "574" "575" "576" "577" "578" "579" "580" "581" "582" "583" "584" "585" "586" "587" "588" "589" "590" "591" "592" "593" "594" "595" "596" "597" "598" "599" "600" "601" "602" "603" "604" "605" "606" "607" "608" "609" "610" "611" "612" "613" "614" "615" "616" "617" "618" "619" "620" "621" "622" "623" "624" "625" "626" "627" "628" "629" "630" "631" "632" "633" "634" "635" "636" "637" "638" "639" "640" "641" "642" "643" "644" "645" "646" "647" "648" "649" "650" "651" "652" "653" "654" "655" "656" "657" "658" "659" "660" "661" "662" "663" "664" "665" "666" "667" "668" "669" "670" "671" "672" "673" "674" "675" "676" "677" "678" "679" "680" "681" "682" "683" "684" "685" "686" "687" "688" "689" "690" "691" "692" "693" "694" "695" "696" "697" "698" "699" "700" "701" "702" "703" "704" "705" "706" "707" "708" "709" "710" "711" "712" "713" "714" "715" "716" "717" "718" "719" "720" "721" "722" "723" "724" "725" "726" "727" "728" "729" "730" "731" "732" "733" "734" "735" "736" "737" "738" "739" "740" "741" "742" "743" "744" "745" "746" "747" "748" "749" "750" "751" "752" "753" "754" "755" "756" "757" "758" "759" "760" "761" "762" "763" "764" "765" "766" "767" "768" "769" "770" "771" "772" "773" "774" "775" "776" "777" "778" "779" "780" "781" "782" "783" "784" "785" "786" "787" "788" "789" "790" "791" "792" "793" "794" "795" "796" "797" "798" "799" "800" "801" "802" "803" "804" "805" "806" "807" "808" "809" "810" "811" "812" "813" "814" "815" "816" "817" "818" "819" "820" "821" "822" "823" "824" "825" "826" "827" "828" "829" "830" "831" "832" "833" "834" "835" "836" "837" "838" "839" "840" "841" "842" "843" "844" "845" "846" "847" "848" "849" "850" "851" "852" "853" "854" "855" "856" "857" "858" "859" "860" "861" "862" "863" "864" "865" "866" "867" "868" "869" "870" "871" "872" "873" "874" "875" "876" "877" "878" "879" "880" "881" "882" "883" "884" "885" "886" "887" "888" "889" "890" "891" "892" "893" "894" "895" "896" "897" "898" "899" "900" "901" "902" "903" "904" "905" "906" "907" "908" "909" "910" "911" "912" "913" "914" "915" "916" "917" "918" "919" "920" "921" "922" "923" "924" "925" "926" "927" "928" "929" "930" "931" "932" "933" "934" "935" "936" "937" "938" "939" "940" "941" "942" "943" "944" "945" "946" "947" "948" "949" "950" "951" "952" "953" "954" "955" "956" "957" "958" "959" "960" "961" "962" "963" "964" "965" "966" "967" "968" "969" "970" "971" "972" "973" "974" "975" "976" "977" "978" "979" "980" "981" "982" "983" "984" "985" "986" "987" "988" "989" "990" "991" "992" "993" "994" "995" "996" "997" "998" "999" "1000" ; %% #include /* A C error reporting function. */ /* !POSIX */ static void yyerror (const char *msg) { fprintf (stderr, "%s\n", msg); } static int yylex (void) { static int counter = 1; if (counter <= MAX) return counter++; assert (counter++ == MAX + 1); return 0; } #include /* getenv. */ #include /* strcmp. */ int main (int argc, char const* argv[]) { (void) argc; (void) argv; return yyparse (); } stderr: 606. torture.at:270: testing State number type: 128 states ... ./torture.at:270: ruby $abs_top_srcdir/tests/linear 128 >input.y || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./torture.at:236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y --- /dev/null 2025-02-20 11:23:24.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/606/stderr 2025-02-22 12:29:30.886843734 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/606/test-source: line 14: ruby: command not found ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 606. torture.at:270: 607. torture.at:271: testing State number type: 129 states ... ./torture.at:271: ruby $abs_top_srcdir/tests/linear 129 >input.y || exit 77 skipped (torture.at:270) ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: cat stderr ./calc.at:1492: cat stderr --- /dev/null 2025-02-20 11:23:24.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/607/stderr 2025-02-22 12:29:30.938844063 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/607/test-source: line 14: ruby: command not found 603. calc.at:1561: 607. torture.at:271: 608. torture.at:272: testing State number type: 256 states ... ./torture.at:272: ruby $abs_top_srcdir/tests/linear 256 >input.y || exit 77 skipped (calc.at:1561) input: skipped (torture.at:271) input: | (# + 1) = 1111 ./calc.at:1489: $PREPARSER ./calc input | (#) + (#) = 2222 ./calc.at:1492: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () --- /dev/null 2025-02-20 11:23:24.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/608/stderr 2025-02-22 12:29:30.990844393 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/608/test-source: line 14: ruby: command not found ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 608. torture.at:272: skipped (torture.at:272) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token syntax error: invalid character: '#' Next token is token error () Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 609. torture.at:273: testing State number type: 257 states ... ./torture.at:273: ruby $abs_top_srcdir/tests/linear 257 >input.y || exit 77 610. torture.at:274: testing State number type: 32768 states ... ./torture.at:274: ruby $abs_top_srcdir/tests/linear 32768 >input.y || exit 77 stdout: --- /dev/null 2025-02-20 11:23:24.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/609/stderr 2025-02-22 12:29:31.126845256 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/609/test-source: line 14: ruby: command not found 609. torture.at:273: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 %code top { /* -*- c -*- */ /* Adjust to the compiler. We used to do it here, but each time we add a new line, we have to adjust all the line numbers in error messages. It's simpler to use a constant include to a varying file. */ #include } %define parse.error verbose %debug %{ #include #include #include #define MAX 200 static int yylex (void); #include /* !POSIX */ static void yyerror (const char *msg); %} %union { int val; }; %token END "end" %type exp input %token t1 1 "1" %token t2 2 "2" %token t3 3 "3" %token t4 4 "4" %token t5 5 "5" %token t6 6 "6" %token t7 7 "7" %token t8 8 "8" %token t9 9 "9" %token t10 10 "10" %token t11 11 "11" %token t12 12 "12" %token t13 13 "13" %token t14 14 "14" %token t15 15 "15" %token t16 16 "16" %token t17 17 "17" %token t18 18 "18" %token t19 19 "19" %token t20 20 "20" %token t21 21 "21" %token t22 22 "22" %token t23 23 "23" %token t24 24 "24" %token t25 25 "25" %token t26 26 "26" %token t27 27 "27" %token t28 28 "28" %token t29 29 "29" %token t30 30 "30" %token t31 31 "31" %token t32 32 "32" %token t33 33 "33" %token t34 34 "34" %token t35 35 "35" %token t36 36 "36" %token t37 37 "37" %token t38 38 "38" %token t39 39 "39" %token t40 40 "40" %token t41 41 "41" %token t42 42 "42" %token t43 43 "43" %token t44 44 "44" %token t45 45 "45" %token t46 46 "46" %token t47 47 "47" %token t48 48 "48" %token t49 49 "49" %token t50 50 "50" %token t51 51 "51" %token t52 52 "52" %token t53 53 "53" %token t54 54 "54" %token t55 55 "55" %token t56 56 "56" %token t57 57 "57" %token t58 58 "58" %token t59 59 "59" %token t60 60 "60" %token t61 61 "61" %token t62 62 "62" %token t63 63 "63" %token t64 64 "64" %token t65 65 "65" %token t66 66 "66" %token t67 67 "67" %token t68 68 "68" %token t69 69 "69" %token t70 70 "70" %token t71 71 "71" %token t72 72 "72" %token t73 73 "73" %token t74 74 "74" %token t75 75 "75" %token t76 76 "76" %token t77 77 "77" %token t78 78 "78" %token t79 79 "79" %token t80 80 "80" %token t81 81 "81" %token t82 82 "82" %token t83 83 "83" %token t84 84 "84" %token t85 85 "85" %token t86 86 "86" %token t87 87 "87" %token t88 88 "88" %token t89 89 "89" %token t90 90 "90" %token t91 91 "91" %token t92 92 "92" %token t93 93 "93" %token t94 94 "94" %token t95 95 "95" %token t96 96 "96" %token t97 97 "97" %token t98 98 "98" %token t99 99 "99" %token t100 100 "100" %token t101 101 "101" %token t102 102 "102" %token t103 103 "103" %token t104 104 "104" %token t105 105 "105" %token t106 106 "106" %token t107 107 "107" %token t108 108 "108" %token t109 109 "109" %token t110 110 "110" %token t111 111 "111" %token t112 112 "112" %token t113 113 "113" %token t114 114 "114" %token t115 115 "115" %token t116 116 "116" %token t117 117 "117" %token t118 118 "118" %token t119 119 "119" %token t120 120 "120" %token t121 121 "121" %token t122 122 "122" %token t123 123 "123" %token t124 124 "124" %token t125 125 "125" %token t126 126 "126" %token t127 127 "127" %token t128 128 "128" %token t129 129 "129" %token t130 130 "130" %token t131 131 "131" %token t132 132 "132" %token t133 133 "133" %token t134 134 "134" %token t135 135 "135" %token t136 136 "136" %token t137 137 "137" %token t138 138 "138" %token t139 139 "139" %token t140 140 "140" %token t141 141 "141" %token t142 142 "142" %token t143 143 "143" %token t144 144 "144" %token t145 145 "145" %token t146 146 "146" %token t147 147 "147" %token t148 148 "148" %token t149 149 "149" %token t150 150 "150" %token t151 151 "151" %token t152 152 "152" %token t153 153 "153" %token t154 154 "154" %token t155 155 "155" %token t156 156 "156" %token t157 157 "157" %token t158 158 "158" %token t159 159 "159" %token t160 160 "160" %token t161 161 "161" %token t162 162 "162" %token t163 163 "163" %token t164 164 "164" %token t165 165 "165" %token t166 166 "166" %token t167 167 "167" %token t168 168 "168" %token t169 169 "169" %token t170 170 "170" %token t171 171 "171" %token t172 172 "172" %token t173 173 "173" %token t174 174 "174" %token t175 175 "175" %token t176 176 "176" %token t177 177 "177" %token t178 178 "178" %token t179 179 "179" %token t180 180 "180" %token t181 181 "181" %token t182 182 "182" %token t183 183 "183" %token t184 184 "184" %token t185 185 "185" %token t186 186 "186" %token t187 187 "187" %token t188 188 "188" %token t189 189 "189" %token t190 190 "190" %token t191 191 "191" %token t192 192 "192" %token t193 193 "193" %token t194 194 "194" %token t195 195 "195" %token t196 196 "196" %token t197 197 "197" %token t198 198 "198" %token t199 199 "199" %token t200 200 "200" %% input: exp { assert ($1 == 0); $$ = $1; } | input exp { assert ($2 == $1 + 1); $$ = $2; } ; exp: END { $$ = 0; } | "1" END { $$ = 1; } | "1" "2" END { $$ = 2; } | "1" "2" "3" END { $$ = 3; } | "1" "2" "3" "4" END { $$ = 4; } | "1" "2" "3" "4" "5" END { $$ = 5; } | "1" "2" "3" "4" "5" "6" END { $$ = 6; } | "1" "2" "3" "4" "5" "6" "7" END { $$ = 7; } | "1" "2" "3" "4" "5" "6" "7" "8" END { $$ = 8; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" END { $$ = 9; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" END { $$ = 10; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" END { $$ = 11; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" END { $$ = 12; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" END { $$ = 13; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" END { $$ = 14; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" END { $$ = 15; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" END { $$ = 16; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" END { $$ = 17; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" END { $$ = 18; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" END { $$ = 19; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" END { $$ = 20; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" END { $$ = 21; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" END { $$ = 22; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" END { $$ = 23; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" END { $$ = 24; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" END { $$ = 25; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" END { $$ = 26; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" END { $$ = 27; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" END { $$ = 28; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" END { $$ = 29; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" END { $$ = 30; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" END { $$ = 31; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" END { $$ = 32; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" END { $$ = 33; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" END { $$ = 34; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" END { $$ = 35; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" END { $$ = 36; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" END { $$ = 37; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" END { $$ = 38; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" END { $$ = 39; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" END { $$ = 40; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" END { $$ = 41; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" END { $$ = 42; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" END { $$ = 43; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" END { $$ = 44; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" END { $$ = 45; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" END { $$ = 46; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" END { $$ = 47; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" END { $$ = 48; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" END { $$ = 49; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" END { $$ = 50; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" END { $$ = 51; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" END { $$ = 52; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" END { $$ = 53; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" END { $$ = 54; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" END { $$ = 55; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" END { $$ = 56; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" END { $$ = 57; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" END { $$ = 58; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" END { $$ = 59; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" END { $$ = 60; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" END { $$ = 61; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" END { $$ = 62; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" END { $$ = 63; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" END { $$ = 64; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" END { $$ = 65; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" END { $$ = 66; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" END { $$ = 67; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" END { $$ = 68; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" END { $$ = 69; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" END { $$ = 70; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" END { $$ = 71; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" END { $$ = 72; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" END { $$ = 73; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" END { $$ = 74; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" END { $$ = 75; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" END { $$ = 76; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" END { $$ = 77; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" END { $$ = 78; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" END { $$ = 79; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" END { $$ = 80; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" END { $$ = 81; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" END { $$ = 82; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" END { $$ = 83; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" END { $$ = 84; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" END { $$ = 85; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" END { $$ = 86; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" END { $$ = 87; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" END { $$ = 88; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" END { $$ = 89; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" END { $$ = 90; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" END { $$ = 91; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" END { $$ = 92; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" END { $$ = 93; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" END { $$ = 94; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" END { $$ = 95; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" END { $$ = 96; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" END { $$ = 97; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" END { $$ = 98; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" END { $$ = 99; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" END { $$ = 100; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" END { $$ = 101; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" END { $$ = 102; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" END { $$ = 103; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" END { $$ = 104; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" END { $$ = 105; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" END { $$ = 106; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" END { $$ = 107; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" END { $$ = 108; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" END { $$ = 109; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" END { $$ = 110; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" END { $$ = 111; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" END { $$ = 112; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" END { $$ = 113; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" END { $$ = 114; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" END { $$ = 115; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" END { $$ = 116; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" END { $$ = 117; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" END { $$ = 118; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" END { $$ = 119; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" END { $$ = 120; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" END { $$ = 121; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" END { $$ = 122; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" END { $$ = 123; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" END { $$ = 124; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" END { $$ = 125; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" END { $$ = 126; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" END { $$ = 127; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" END { $$ = 128; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" END { $$ = 129; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" END { $$ = 130; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" END { $$ = 131; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" END { $$ = 132; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" END { $$ = 133; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" END { $$ = 134; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" END { $$ = 135; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" END { $$ = 136; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" END { $$ = 137; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" END { $$ = 138; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" END { $$ = 139; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" END { $$ = 140; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" END { $$ = 141; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" END { $$ = 142; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" END { $$ = 143; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" END { $$ = 144; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" END { $$ = 145; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" END { $$ = 146; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" END { $$ = 147; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" END { $$ = 148; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" END { $$ = 149; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" END { $$ = 150; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" END { $$ = 151; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" END { $$ = 152; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" END { $$ = 153; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" END { $$ = 154; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" END { $$ = 155; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" END { $$ = 156; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" END { $$ = 157; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" END { $$ = 158; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" END { $$ = 159; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" END { $$ = 160; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" END { $$ = 161; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" END { $$ = 162; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" END { $$ = 163; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" END { $$ = 164; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" END { $$ = 165; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" END { $$ = 166; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" END { $$ = 167; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" END { $$ = 168; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" END { $$ = 169; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" END { $$ = 170; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" END { $$ = 171; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" END { $$ = 172; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" END { $$ = 173; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" END { $$ = 174; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" END { $$ = 175; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" END { $$ = 176; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" END { $$ = 177; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" END { $$ = 178; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" END { $$ = 179; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" END { $$ = 180; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" END { $$ = 181; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" END { $$ = 182; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" END { $$ = 183; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" END { $$ = 184; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" END { $$ = 185; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" END { $$ = 186; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" END { $$ = 187; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" END { $$ = 188; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" END { $$ = 189; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" END { $$ = 190; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" END { $$ = 191; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" END { $$ = 192; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" END { $$ = 193; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" END { $$ = 194; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" END { $$ = 195; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" "196" END { $$ = 196; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" "196" "197" END { $$ = 197; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" "196" "197" "198" END { $$ = 198; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" "196" "197" "198" "199" END { $$ = 199; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" "196" "197" "198" "199" "200" END { $$ = 200; } ; %% /* A C error reporting function. */ /* !POSIX */ static void yyerror (const char *msg) { fprintf (stderr, "%s\n", msg); } static int yylex (void) { static int inner = 1; static int outer = 0; if (outer > MAX) return 0; else if (inner > outer) { inner = 1; ++outer; return END; } return inner++; } #include /* getenv. */ #include /* strcmp. */ int main (int argc, char const* argv[]) { (void) argc; (void) argv; return yyparse (); } skipped (torture.at:273) --- /dev/null 2025-02-20 11:23:24.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/610/stderr 2025-02-22 12:29:31.146845383 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/610/test-source: line 14: ruby: command not found 610. torture.at:274: 611. torture.at:275: testing State number type: 65536 states ... ./torture.at:275: ruby $abs_top_srcdir/tests/linear 65536 >input.y || exit 77 ./torture.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: cat stderr skipped (torture.at:274) input: --- /dev/null 2025-02-20 11:23:24.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/611/stderr 2025-02-22 12:29:31.190845662 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/611/test-source: line 14: ruby: command not found ./calc.at:1489: cat stderr 611. torture.at:275: | (1 + #) = 1111 ./calc.at:1492: $PREPARSER ./calc input stderr: input: skipped (torture.at:275) | (1 + # + 1) = 1111 ./calc.at:1489: $PREPARSER ./calc input 612. torture.at:276: testing State number type: 65537 states ... ./torture.at:276: ruby $abs_top_srcdir/tests/linear 65537 >input.y || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () 613. torture.at:385: testing Many lookahead tokens ... ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) --- /dev/null 2025-02-20 11:23:24.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/612/stderr 2025-02-22 12:29:31.234845941 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/612/test-source: line 14: ruby: command not found 612. torture.at:276: ./torture.at:387: "$PERL" -w ./gengram.pl 1000 || exit 77 stderr: skipped (torture.at:276) Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token syntax error: invalid character: '#' Next token is token error () Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token number (1) Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token Next token is token number (1111) Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) -> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stdout: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 %define parse.error verbose %debug %{ /* Adjust to the compiler. We used to do it here, but each time we add a new line, we have to adjust all the line numbers in error messages. It's simpler to use a constant include to a varying file. */ #include # include # include # include # define MAX 1000 static int yylex (void); #include /* !POSIX */ static void yyerror (const char *msg); %} %union { int val; }; %type input exp %token token %type n1 n2 n3 n4 n5 n6 n7 n8 n9 n10 n11 n12 n13 n14 n15 n16 n17 n18 n19 n20 n21 n22 n23 n24 n25 n26 n27 n28 n29 n30 n31 n32 n33 n34 n35 n36 n37 n38 n39 n40 n41 n42 n43 n44 n45 n46 n47 n48 n49 n50 n51 n52 n53 n54 n55 n56 n57 n58 n59 n60 n61 n62 n63 n64 n65 n66 n67 n68 n69 n70 n71 n72 n73 n74 n75 n76 n77 n78 n79 n80 n81 n82 n83 n84 n85 n86 n87 n88 n89 n90 n91 n92 n93 n94 n95 n96 n97 n98 n99 n100 n101 n102 n103 n104 n105 n106 n107 n108 n109 n110 n111 n112 n113 n114 n115 n116 n117 n118 n119 n120 n121 n122 n123 n124 n125 n126 n127 n128 n129 n130 n131 n132 n133 n134 n135 n136 n137 n138 n139 n140 n141 n142 n143 n144 n145 n146 n147 n148 n149 n150 n151 n152 n153 n154 n155 n156 n157 n158 n159 n160 n161 n162 n163 n164 n165 n166 n167 n168 n169 n170 n171 n172 n173 n174 n175 n176 n177 n178 n179 n180 n181 n182 n183 n184 n185 n186 n187 n188 n189 n190 n191 n192 n193 n194 n195 n196 n197 n198 n199 n200 n201 n202 n203 n204 n205 n206 n207 n208 n209 n210 n211 n212 n213 n214 n215 n216 n217 n218 n219 n220 n221 n222 n223 n224 n225 n226 n227 n228 n229 n230 n231 n232 n233 n234 n235 n236 n237 n238 n239 n240 n241 n242 n243 n244 n245 n246 n247 n248 n249 n250 n251 n252 n253 n254 n255 n256 n257 n258 n259 n260 n261 n262 n263 n264 n265 n266 n267 n268 n269 n270 n271 n272 n273 n274 n275 n276 n277 n278 n279 n280 n281 n282 n283 n284 n285 n286 n287 n288 n289 n290 n291 n292 n293 n294 n295 n296 n297 n298 n299 n300 n301 n302 n303 n304 n305 n306 n307 n308 n309 n310 n311 n312 n313 n314 n315 n316 n317 n318 n319 n320 n321 n322 n323 n324 n325 n326 n327 n328 n329 n330 n331 n332 n333 n334 n335 n336 n337 n338 n339 n340 n341 n342 n343 n344 n345 n346 n347 n348 n349 n350 n351 n352 n353 n354 n355 n356 n357 n358 n359 n360 n361 n362 n363 n364 n365 n366 n367 n368 n369 n370 n371 n372 n373 n374 n375 n376 n377 n378 n379 n380 n381 n382 n383 n384 n385 n386 n387 n388 n389 n390 n391 n392 n393 n394 n395 n396 n397 n398 n399 n400 n401 n402 n403 n404 n405 n406 n407 n408 n409 n410 n411 n412 n413 n414 n415 n416 n417 n418 n419 n420 n421 n422 n423 n424 n425 n426 n427 n428 n429 n430 n431 n432 n433 n434 n435 n436 n437 n438 n439 n440 n441 n442 n443 n444 n445 n446 n447 n448 n449 n450 n451 n452 n453 n454 n455 n456 n457 n458 n459 n460 n461 n462 n463 n464 n465 n466 n467 n468 n469 n470 n471 n472 n473 n474 n475 n476 n477 n478 n479 n480 n481 n482 n483 n484 n485 n486 n487 n488 n489 n490 n491 n492 n493 n494 n495 n496 n497 n498 n499 n500 n501 n502 n503 n504 n505 n506 n507 n508 n509 n510 n511 n512 n513 n514 n515 n516 n517 n518 n519 n520 n521 n522 n523 n524 n525 n526 n527 n528 n529 n530 n531 n532 n533 n534 n535 n536 n537 n538 n539 n540 n541 n542 n543 n544 n545 n546 n547 n548 n549 n550 n551 n552 n553 n554 n555 n556 n557 n558 n559 n560 n561 n562 n563 n564 n565 n566 n567 n568 n569 n570 n571 n572 n573 n574 n575 n576 n577 n578 n579 n580 n581 n582 n583 n584 n585 n586 n587 n588 n589 n590 n591 n592 n593 n594 n595 n596 n597 n598 n599 n600 n601 n602 n603 n604 n605 n606 n607 n608 n609 n610 n611 n612 n613 n614 n615 n616 n617 n618 n619 n620 n621 n622 n623 n624 n625 n626 n627 n628 n629 n630 n631 n632 n633 n634 n635 n636 n637 n638 n639 n640 n641 n642 n643 n644 n645 n646 n647 n648 n649 n650 n651 n652 n653 n654 n655 n656 n657 n658 n659 n660 n661 n662 n663 n664 n665 n666 n667 n668 n669 n670 n671 n672 n673 n674 n675 n676 n677 n678 n679 n680 n681 n682 n683 n684 n685 n686 n687 n688 n689 n690 n691 n692 n693 n694 n695 n696 n697 n698 n699 n700 n701 n702 n703 n704 n705 n706 n707 n708 n709 n710 n711 n712 n713 n714 n715 n716 n717 n718 n719 n720 n721 n722 n723 n724 n725 n726 n727 n728 n729 n730 n731 n732 n733 n734 n735 n736 n737 n738 n739 n740 n741 n742 n743 n744 n745 n746 n747 n748 n749 n750 n751 n752 n753 n754 n755 n756 n757 n758 n759 n760 n761 n762 n763 n764 n765 n766 n767 n768 n769 n770 n771 n772 n773 n774 n775 n776 n777 n778 n779 n780 n781 n782 n783 n784 n785 n786 n787 n788 n789 n790 n791 n792 n793 n794 n795 n796 n797 n798 n799 n800 n801 n802 n803 n804 n805 n806 n807 n808 n809 n810 n811 n812 n813 n814 n815 n816 n817 n818 n819 n820 n821 n822 n823 n824 n825 n826 n827 n828 n829 n830 n831 n832 n833 n834 n835 n836 n837 n838 n839 n840 n841 n842 n843 n844 n845 n846 n847 n848 n849 n850 n851 n852 n853 n854 n855 n856 n857 n858 n859 n860 n861 n862 n863 n864 n865 n866 n867 n868 n869 n870 n871 n872 n873 n874 n875 n876 n877 n878 n879 n880 n881 n882 n883 n884 n885 n886 n887 n888 n889 n890 n891 n892 n893 n894 n895 n896 n897 n898 n899 n900 n901 n902 n903 n904 n905 n906 n907 n908 n909 n910 n911 n912 n913 n914 n915 n916 n917 n918 n919 n920 n921 n922 n923 n924 n925 n926 n927 n928 n929 n930 n931 n932 n933 n934 n935 n936 n937 n938 n939 n940 n941 n942 n943 n944 n945 n946 n947 n948 n949 n950 n951 n952 n953 n954 n955 n956 n957 n958 n959 n960 n961 n962 n963 n964 n965 n966 n967 n968 n969 n970 n971 n972 n973 n974 n975 n976 n977 n978 n979 n980 n981 n982 n983 n984 n985 n986 n987 n988 n989 n990 n991 n992 n993 n994 n995 n996 n997 n998 n999 n1000 %token t1 1 "1" t2 2 "2" t3 3 "3" t4 4 "4" t5 5 "5" t6 6 "6" t7 7 "7" t8 8 "8" t9 9 "9" t10 10 "10" t11 11 "11" t12 12 "12" t13 13 "13" t14 14 "14" t15 15 "15" t16 16 "16" t17 17 "17" t18 18 "18" t19 19 "19" t20 20 "20" t21 21 "21" t22 22 "22" t23 23 "23" t24 24 "24" t25 25 "25" t26 26 "26" t27 27 "27" t28 28 "28" t29 29 "29" t30 30 "30" t31 31 "31" t32 32 "32" t33 33 "33" t34 34 "34" t35 35 "35" t36 36 "36" t37 37 "37" t38 38 "38" t39 39 "39" t40 40 "40" t41 41 "41" t42 42 "42" t43 43 "43" t44 44 "44" t45 45 "45" t46 46 "46" t47 47 "47" t48 48 "48" t49 49 "49" t50 50 "50" t51 51 "51" t52 52 "52" t53 53 "53" t54 54 "54" t55 55 "55" t56 56 "56" t57 57 "57" t58 58 "58" t59 59 "59" t60 60 "60" t61 61 "61" t62 62 "62" t63 63 "63" t64 64 "64" t65 65 "65" t66 66 "66" t67 67 "67" t68 68 "68" t69 69 "69" t70 70 "70" t71 71 "71" t72 72 "72" t73 73 "73" t74 74 "74" t75 75 "75" t76 76 "76" t77 77 "77" t78 78 "78" t79 79 "79" t80 80 "80" t81 81 "81" t82 82 "82" t83 83 "83" t84 84 "84" t85 85 "85" t86 86 "86" t87 87 "87" t88 88 "88" t89 89 "89" t90 90 "90" t91 91 "91" t92 92 "92" t93 93 "93" t94 94 "94" t95 95 "95" t96 96 "96" t97 97 "97" t98 98 "98" t99 99 "99" t100 100 "100" t101 101 "101" t102 102 "102" t103 103 "103" t104 104 "104" t105 105 "105" t106 106 "106" t107 107 "107" t108 108 "108" t109 109 "109" t110 110 "110" t111 111 "111" t112 112 "112" t113 113 "113" t114 114 "114" t115 115 "115" t116 116 "116" t117 117 "117" t118 118 "118" t119 119 "119" t120 120 "120" t121 121 "121" t122 122 "122" t123 123 "123" t124 124 "124" t125 125 "125" t126 126 "126" t127 127 "127" t128 128 "128" t129 129 "129" t130 130 "130" t131 131 "131" t132 132 "132" t133 133 "133" t134 134 "134" t135 135 "135" t136 136 "136" t137 137 "137" t138 138 "138" t139 139 "139" t140 140 "140" t141 141 "141" t142 142 "142" t143 143 "143" t144 144 "144" t145 145 "145" t146 146 "146" t147 147 "147" t148 148 "148" t149 149 "149" t150 150 "150" t151 151 "151" t152 152 "152" t153 153 "153" t154 154 "154" t155 155 "155" t156 156 "156" t157 157 "157" t158 158 "158" t159 159 "159" t160 160 "160" t161 161 "161" t162 162 "162" t163 163 "163" t164 164 "164" t165 165 "165" t166 166 "166" t167 167 "167" t168 168 "168" t169 169 "169" t170 170 "170" t171 171 "171" t172 172 "172" t173 173 "173" t174 174 "174" t175 175 "175" t176 176 "176" t177 177 "177" t178 178 "178" t179 179 "179" t180 180 "180" t181 181 "181" t182 182 "182" t183 183 "183" t184 184 "184" t185 185 "185" t186 186 "186" t187 187 "187" t188 188 "188" t189 189 "189" t190 190 "190" t191 191 "191" t192 192 "192" t193 193 "193" t194 194 "194" t195 195 "195" t196 196 "196" t197 197 "197" t198 198 "198" t199 199 "199" t200 200 "200" t201 201 "201" t202 202 "202" t203 203 "203" t204 204 "204" t205 205 "205" t206 206 "206" t207 207 "207" t208 208 "208" t209 209 "209" t210 210 "210" t211 211 "211" t212 212 "212" t213 213 "213" t214 214 "214" t215 215 "215" t216 216 "216" t217 217 "217" t218 218 "218" t219 219 "219" t220 220 "220" t221 221 "221" t222 222 "222" t223 223 "223" t224 224 "224" t225 225 "225" t226 226 "226" t227 227 "227" t228 228 "228" t229 229 "229" t230 230 "230" t231 231 "231" t232 232 "232" t233 233 "233" t234 234 "234" t235 235 "235" t236 236 "236" t237 237 "237" t238 238 "238" t239 239 "239" t240 240 "240" t241 241 "241" t242 242 "242" t243 243 "243" t244 244 "244" t245 245 "245" t246 246 "246" t247 247 "247" t248 248 "248" t249 249 "249" t250 250 "250" t251 251 "251" t252 252 "252" t253 253 "253" t254 254 "254" t255 255 "255" t256 256 "256" t257 257 "257" t258 258 "258" t259 259 "259" t260 260 "260" t261 261 "261" t262 262 "262" t263 263 "263" t264 264 "264" t265 265 "265" t266 266 "266" t267 267 "267" t268 268 "268" t269 269 "269" t270 270 "270" t271 271 "271" t272 272 "272" t273 273 "273" t274 274 "274" t275 275 "275" t276 276 "276" t277 277 "277" t278 278 "278" t279 279 "279" t280 280 "280" t281 281 "281" t282 282 "282" t283 283 "283" t284 284 "284" t285 285 "285" t286 286 "286" t287 287 "287" t288 288 "288" t289 289 "289" t290 290 "290" t291 291 "291" t292 292 "292" t293 293 "293" t294 294 "294" t295 295 "295" t296 296 "296" t297 297 "297" t298 298 "298" t299 299 "299" t300 300 "300" t301 301 "301" t302 302 "302" t303 303 "303" t304 304 "304" t305 305 "305" t306 306 "306" t307 307 "307" t308 308 "308" t309 309 "309" t310 310 "310" t311 311 "311" t312 312 "312" t313 313 "313" t314 314 "314" t315 315 "315" t316 316 "316" t317 317 "317" t318 318 "318" t319 319 "319" t320 320 "320" t321 321 "321" t322 322 "322" t323 323 "323" t324 324 "324" t325 325 "325" t326 326 "326" t327 327 "327" t328 328 "328" t329 329 "329" t330 330 "330" t331 331 "331" t332 332 "332" t333 333 "333" t334 334 "334" t335 335 "335" t336 336 "336" t337 337 "337" t338 338 "338" t339 339 "339" t340 340 "340" t341 341 "341" t342 342 "342" t343 343 "343" t344 344 "344" t345 345 "345" t346 346 "346" t347 347 "347" t348 348 "348" t349 349 "349" t350 350 "350" t351 351 "351" t352 352 "352" t353 353 "353" t354 354 "354" t355 355 "355" t356 356 "356" t357 357 "357" t358 358 "358" t359 359 "359" t360 360 "360" t361 361 "361" t362 362 "362" t363 363 "363" t364 364 "364" t365 365 "365" t366 366 "366" t367 367 "367" t368 368 "368" t369 369 "369" t370 370 "370" t371 371 "371" t372 372 "372" t373 373 "373" t374 374 "374" t375 375 "375" t376 376 "376" t377 377 "377" t378 378 "378" t379 379 "379" t380 380 "380" t381 381 "381" t382 382 "382" t383 383 "383" t384 384 "384" t385 385 "385" t386 386 "386" t387 387 "387" t388 388 "388" t389 389 "389" t390 390 "390" t391 391 "391" t392 392 "392" t393 393 "393" t394 394 "394" t395 395 "395" t396 396 "396" t397 397 "397" t398 398 "398" t399 399 "399" t400 400 "400" t401 401 "401" t402 402 "402" t403 403 "403" t404 404 "404" t405 405 "405" t406 406 "406" t407 407 "407" t408 408 "408" t409 409 "409" t410 410 "410" t411 411 "411" t412 412 "412" t413 413 "413" t414 414 "414" t415 415 "415" t416 416 "416" t417 417 "417" t418 418 "418" t419 419 "419" t420 420 "420" t421 421 "421" t422 422 "422" t423 423 "423" t424 424 "424" t425 425 "425" t426 426 "426" t427 427 "427" t428 428 "428" t429 429 "429" t430 430 "430" t431 431 "431" t432 432 "432" t433 433 "433" t434 434 "434" t435 435 "435" t436 436 "436" t437 437 "437" t438 438 "438" t439 439 "439" t440 440 "440" t441 441 "441" t442 442 "442" t443 443 "443" t444 444 "444" t445 445 "445" t446 446 "446" t447 447 "447" t448 448 "448" t449 449 "449" t450 450 "450" t451 451 "451" t452 452 "452" t453 453 "453" t454 454 "454" t455 455 "455" t456 456 "456" t457 457 "457" t458 458 "458" t459 459 "459" t460 460 "460" t461 461 "461" t462 462 "462" t463 463 "463" t464 464 "464" t465 465 "465" t466 466 "466" t467 467 "467" t468 468 "468" t469 469 "469" t470 470 "470" t471 471 "471" t472 472 "472" t473 473 "473" t474 474 "474" t475 475 "475" t476 476 "476" t477 477 "477" t478 478 "478" t479 479 "479" t480 480 "480" t481 481 "481" t482 482 "482" t483 483 "483" t484 484 "484" t485 485 "485" t486 486 "486" t487 487 "487" t488 488 "488" t489 489 "489" t490 490 "490" t491 491 "491" t492 492 "492" t493 493 "493" t494 494 "494" t495 495 "495" t496 496 "496" t497 497 "497" t498 498 "498" t499 499 "499" t500 500 "500" t501 501 "501" t502 502 "502" t503 503 "503" t504 504 "504" t505 505 "505" t506 506 "506" t507 507 "507" t508 508 "508" t509 509 "509" t510 510 "510" t511 511 "511" t512 512 "512" t513 513 "513" t514 514 "514" t515 515 "515" t516 516 "516" t517 517 "517" t518 518 "518" t519 519 "519" t520 520 "520" t521 521 "521" t522 522 "522" t523 523 "523" t524 524 "524" t525 525 "525" t526 526 "526" t527 527 "527" t528 528 "528" t529 529 "529" t530 530 "530" t531 531 "531" t532 532 "532" t533 533 "533" t534 534 "534" t535 535 "535" t536 536 "536" t537 537 "537" t538 538 "538" t539 539 "539" t540 540 "540" t541 541 "541" t542 542 "542" t543 543 "543" t544 544 "544" t545 545 "545" t546 546 "546" t547 547 "547" t548 548 "548" t549 549 "549" t550 550 "550" t551 551 "551" t552 552 "552" t553 553 "553" t554 554 "554" t555 555 "555" t556 556 "556" t557 557 "557" t558 558 "558" t559 559 "559" t560 560 "560" t561 561 "561" t562 562 "562" t563 563 "563" t564 564 "564" t565 565 "565" t566 566 "566" t567 567 "567" t568 568 "568" t569 569 "569" t570 570 "570" t571 571 "571" t572 572 "572" t573 573 "573" t574 574 "574" t575 575 "575" t576 576 "576" t577 577 "577" t578 578 "578" t579 579 "579" t580 580 "580" t581 581 "581" t582 582 "582" t583 583 "583" t584 584 "584" t585 585 "585" t586 586 "586" t587 587 "587" t588 588 "588" t589 589 "589" t590 590 "590" t591 591 "591" t592 592 "592" t593 593 "593" t594 594 "594" t595 595 "595" t596 596 "596" t597 597 "597" t598 598 "598" t599 599 "599" t600 600 "600" t601 601 "601" t602 602 "602" t603 603 "603" t604 604 "604" t605 605 "605" t606 606 "606" t607 607 "607" t608 608 "608" t609 609 "609" t610 610 "610" t611 611 "611" t612 612 "612" t613 613 "613" t614 614 "614" t615 615 "615" t616 616 "616" t617 617 "617" t618 618 "618" t619 619 "619" t620 620 "620" t621 621 "621" t622 622 "622" t623 623 "623" t624 624 "624" t625 625 "625" t626 626 "626" t627 627 "627" t628 628 "628" t629 629 "629" t630 630 "630" t631 631 "631" t632 632 "632" t633 633 "633" t634 634 "634" t635 635 "635" t636 636 "636" t637 637 "637" t638 638 "638" t639 639 "639" t640 640 "640" t641 641 "641" t642 642 "642" t643 643 "643" t644 644 "644" t645 645 "645" t646 646 "646" t647 647 "647" t648 648 "648" t649 649 "649" t650 650 "650" t651 651 "651" t652 652 "652" t653 653 "653" t654 654 "654" t655 655 "655" t656 656 "656" t657 657 "657" t658 658 "658" t659 659 "659" t660 660 "660" t661 661 "661" t662 662 "662" t663 663 "663" t664 664 "664" t665 665 "665" t666 666 "666" t667 667 "667" t668 668 "668" t669 669 "669" t670 670 "670" t671 671 "671" t672 672 "672" t673 673 "673" t674 674 "674" t675 675 "675" t676 676 "676" t677 677 "677" t678 678 "678" t679 679 "679" t680 680 "680" t681 681 "681" t682 682 "682" t683 683 "683" t684 684 "684" t685 685 "685" t686 686 "686" t687 687 "687" t688 688 "688" t689 689 "689" t690 690 "690" t691 691 "691" t692 692 "692" t693 693 "693" t694 694 "694" t695 695 "695" t696 696 "696" t697 697 "697" t698 698 "698" t699 699 "699" t700 700 "700" t701 701 "701" t702 702 "702" t703 703 "703" t704 704 "704" t705 705 "705" t706 706 "706" t707 707 "707" t708 708 "708" t709 709 "709" t710 710 "710" t711 711 "711" t712 712 "712" t713 713 "713" t714 714 "714" t715 715 "715" t716 716 "716" t717 717 "717" t718 718 "718" t719 719 "719" t720 720 "720" t721 721 "721" t722 722 "722" t723 723 "723" t724 724 "724" t725 725 "725" t726 726 "726" t727 727 "727" t728 728 "728" t729 729 "729" t730 730 "730" t731 731 "731" t732 732 "732" t733 733 "733" t734 734 "734" t735 735 "735" t736 736 "736" t737 737 "737" t738 738 "738" t739 739 "739" t740 740 "740" t741 741 "741" t742 742 "742" t743 743 "743" t744 744 "744" t745 745 "745" t746 746 "746" t747 747 "747" t748 748 "748" t749 749 "749" t750 750 "750" t751 751 "751" t752 752 "752" t753 753 "753" t754 754 "754" t755 755 "755" t756 756 "756" t757 757 "757" t758 758 "758" t759 759 "759" t760 760 "760" t761 761 "761" t762 762 "762" t763 763 "763" t764 764 "764" t765 765 "765" t766 766 "766" t767 767 "767" t768 768 "768" t769 769 "769" t770 770 "770" t771 771 "771" t772 772 "772" t773 773 "773" t774 774 "774" t775 775 "775" t776 776 "776" t777 777 "777" t778 778 "778" t779 779 "779" t780 780 "780" t781 781 "781" t782 782 "782" t783 783 "783" t784 784 "784" t785 785 "785" t786 786 "786" t787 787 "787" t788 788 "788" t789 789 "789" t790 790 "790" t791 791 "791" t792 792 "792" t793 793 "793" t794 794 "794" t795 795 "795" t796 796 "796" t797 797 "797" t798 798 "798" t799 799 "799" t800 800 "800" t801 801 "801" t802 802 "802" t803 803 "803" t804 804 "804" t805 805 "805" t806 806 "806" t807 807 "807" t808 808 "808" t809 809 "809" t810 810 "810" t811 811 "811" t812 812 "812" t813 813 "813" t814 814 "814" t815 815 "815" t816 816 "816" t817 817 "817" t818 818 "818" t819 819 "819" t820 820 "820" t821 821 "821" t822 822 "822" t823 823 "823" t824 824 "824" t825 825 "825" t826 826 "826" t827 827 "827" t828 828 "828" t829 829 "829" t830 830 "830" t831 831 "831" t832 832 "832" t833 833 "833" t834 834 "834" t835 835 "835" t836 836 "836" t837 837 "837" t838 838 "838" t839 839 "839" t840 840 "840" t841 841 "841" t842 842 "842" t843 843 "843" t844 844 "844" t845 845 "845" t846 846 "846" t847 847 "847" t848 848 "848" t849 849 "849" t850 850 "850" t851 851 "851" t852 852 "852" t853 853 "853" t854 854 "854" t855 855 "855" t856 856 "856" t857 857 "857" t858 858 "858" t859 859 "859" t860 860 "860" t861 861 "861" t862 862 "862" t863 863 "863" t864 864 "864" t865 865 "865" t866 866 "866" t867 867 "867" t868 868 "868" t869 869 "869" t870 870 "870" t871 871 "871" t872 872 "872" t873 873 "873" t874 874 "874" t875 875 "875" t876 876 "876" t877 877 "877" t878 878 "878" t879 879 "879" t880 880 "880" t881 881 "881" t882 882 "882" t883 883 "883" t884 884 "884" t885 885 "885" t886 886 "886" t887 887 "887" t888 888 "888" t889 889 "889" t890 890 "890" t891 891 "891" t892 892 "892" t893 893 "893" t894 894 "894" t895 895 "895" t896 896 "896" t897 897 "897" t898 898 "898" t899 899 "899" t900 900 "900" t901 901 "901" t902 902 "902" t903 903 "903" t904 904 "904" t905 905 "905" t906 906 "906" t907 907 "907" t908 908 "908" t909 909 "909" t910 910 "910" t911 911 "911" t912 912 "912" t913 913 "913" t914 914 "914" t915 915 "915" t916 916 "916" t917 917 "917" t918 918 "918" t919 919 "919" t920 920 "920" t921 921 "921" t922 922 "922" t923 923 "923" t924 924 "924" t925 925 "925" t926 926 "926" t927 927 "927" t928 928 "928" t929 929 "929" t930 930 "930" t931 931 "931" t932 932 "932" t933 933 "933" t934 934 "934" t935 935 "935" t936 936 "936" t937 937 "937" t938 938 "938" t939 939 "939" t940 940 "940" t941 941 "941" t942 942 "942" t943 943 "943" t944 944 "944" t945 945 "945" t946 946 "946" t947 947 "947" t948 948 "948" t949 949 "949" t950 950 "950" t951 951 "951" t952 952 "952" t953 953 "953" t954 954 "954" t955 955 "955" t956 956 "956" t957 957 "957" t958 958 "958" t959 959 "959" t960 960 "960" t961 961 "961" t962 962 "962" t963 963 "963" t964 964 "964" t965 965 "965" t966 966 "966" t967 967 "967" t968 968 "968" t969 969 "969" t970 970 "970" t971 971 "971" t972 972 "972" t973 973 "973" t974 974 "974" t975 975 "975" t976 976 "976" t977 977 "977" t978 978 "978" t979 979 "979" t980 980 "980" t981 981 "981" t982 982 "982" t983 983 "983" t984 984 "984" t985 985 "985" t986 986 "986" t987 987 "987" t988 988 "988" t989 989 "989" t990 990 "990" t991 991 "991" t992 992 "992" t993 993 "993" t994 994 "994" t995 995 "995" t996 996 "996" t997 997 "997" t998 998 "998" t999 999 "999" t1000 1000 "1000" %% input: exp { assert ($1 == 1); $$ = $1; } | input exp { assert ($2 == $1 + 1); $$ = $2; } ; exp: n1 "1" { assert ($1 == 1); $$ = $1; } | n2 "2" { assert ($1 == 2); $$ = $1; } | n3 "3" { assert ($1 == 3); $$ = $1; } | n4 "4" { assert ($1 == 4); $$ = $1; } | n5 "5" { assert ($1 == 5); $$ = $1; } | n6 "6" { assert ($1 == 6); $$ = $1; } | n7 "7" { assert ($1 == 7); $$ = $1; } | n8 "8" { assert ($1 == 8); $$ = $1; } | n9 "9" { assert ($1 == 9); $$ = $1; } | n10 "10" { assert ($1 == 10); $$ = $1; } | n11 "11" { assert ($1 == 11); $$ = $1; } | n12 "12" { assert ($1 == 12); $$ = $1; } | n13 "13" { assert ($1 == 13); $$ = $1; } | n14 "14" { assert ($1 == 14); $$ = $1; } | n15 "15" { assert ($1 == 15); $$ = $1; } | n16 "16" { assert ($1 == 16); $$ = $1; } | n17 "17" { assert ($1 == 17); $$ = $1; } | n18 "18" { assert ($1 == 18); $$ = $1; } | n19 "19" { assert ($1 == 19); $$ = $1; } | n20 "20" { assert ($1 == 20); $$ = $1; } | n21 "21" { assert ($1 == 21); $$ = $1; } | n22 "22" { assert ($1 == 22); $$ = $1; } | n23 "23" { assert ($1 == 23); $$ = $1; } | n24 "24" { assert ($1 == 24); $$ = $1; } | n25 "25" { assert ($1 == 25); $$ = $1; } | n26 "26" { assert ($1 == 26); $$ = $1; } | n27 "27" { assert ($1 == 27); $$ = $1; } | n28 "28" { assert ($1 == 28); $$ = $1; } | n29 "29" { assert ($1 == 29); $$ = $1; } | n30 "30" { assert ($1 == 30); $$ = $1; } | n31 "31" { assert ($1 == 31); $$ = $1; } | n32 "32" { assert ($1 == 32); $$ = $1; } | n33 "33" { assert ($1 == 33); $$ = $1; } | n34 "34" { assert ($1 == 34); $$ = $1; } | n35 "35" { assert ($1 == 35); $$ = $1; } | n36 "36" { assert ($1 == 36); $$ = $1; } | n37 "37" { assert ($1 == 37); $$ = $1; } | n38 "38" { assert ($1 == 38); $$ = $1; } | n39 "39" { assert ($1 == 39); $$ = $1; } | n40 "40" { assert ($1 == 40); $$ = $1; } | n41 "41" { assert ($1 == 41); $$ = $1; } | n42 "42" { assert ($1 == 42); $$ = $1; } | n43 "43" { assert ($1 == 43); $$ = $1; } | n44 "44" { assert ($1 == 44); $$ = $1; } | n45 "45" { assert ($1 == 45); $$ = $1; } | n46 "46" { assert ($1 == 46); $$ = $1; } | n47 "47" { assert ($1 == 47); $$ = $1; } | n48 "48" { assert ($1 == 48); $$ = $1; } | n49 "49" { assert ($1 == 49); $$ = $1; } | n50 "50" { assert ($1 == 50); $$ = $1; } | n51 "51" { assert ($1 == 51); $$ = $1; } | n52 "52" { assert ($1 == 52); $$ = $1; } | n53 "53" { assert ($1 == 53); $$ = $1; } | n54 "54" { assert ($1 == 54); $$ = $1; } | n55 "55" { assert ($1 == 55); $$ = $1; } | n56 "56" { assert ($1 == 56); $$ = $1; } | n57 "57" { assert ($1 == 57); $$ = $1; } | n58 "58" { assert ($1 == 58); $$ = $1; } | n59 "59" { assert ($1 == 59); $$ = $1; } | n60 "60" { assert ($1 == 60); $$ = $1; } | n61 "61" { assert ($1 == 61); $$ = $1; } | n62 "62" { assert ($1 == 62); $$ = $1; } | n63 "63" { assert ($1 == 63); $$ = $1; } | n64 "64" { assert ($1 == 64); $$ = $1; } | n65 "65" { assert ($1 == 65); $$ = $1; } | n66 "66" { assert ($1 == 66); $$ = $1; } | n67 "67" { assert ($1 == 67); $$ = $1; } | n68 "68" { assert ($1 == 68); $$ = $1; } | n69 "69" { assert ($1 == 69); $$ = $1; } | n70 "70" { assert ($1 == 70); $$ = $1; } | n71 "71" { assert ($1 == 71); $$ = $1; } | n72 "72" { assert ($1 == 72); $$ = $1; } | n73 "73" { assert ($1 == 73); $$ = $1; } | n74 "74" { assert ($1 == 74); $$ = $1; } | n75 "75" { assert ($1 == 75); $$ = $1; } | n76 "76" { assert ($1 == 76); $$ = $1; } | n77 "77" { assert ($1 == 77); $$ = $1; } | n78 "78" { assert ($1 == 78); $$ = $1; } | n79 "79" { assert ($1 == 79); $$ = $1; } | n80 "80" { assert ($1 == 80); $$ = $1; } | n81 "81" { assert ($1 == 81); $$ = $1; } | n82 "82" { assert ($1 == 82); $$ = $1; } | n83 "83" { assert ($1 == 83); $$ = $1; } | n84 "84" { assert ($1 == 84); $$ = $1; } | n85 "85" { assert ($1 == 85); $$ = $1; } | n86 "86" { assert ($1 == 86); $$ = $1; } | n87 "87" { assert ($1 == 87); $$ = $1; } | n88 "88" { assert ($1 == 88); $$ = $1; } | n89 "89" { assert ($1 == 89); $$ = $1; } | n90 "90" { assert ($1 == 90); $$ = $1; } | n91 "91" { assert ($1 == 91); $$ = $1; } | n92 "92" { assert ($1 == 92); $$ = $1; } | n93 "93" { assert ($1 == 93); $$ = $1; } | n94 "94" { assert ($1 == 94); $$ = $1; } | n95 "95" { assert ($1 == 95); $$ = $1; } | n96 "96" { assert ($1 == 96); $$ = $1; } | n97 "97" { assert ($1 == 97); $$ = $1; } | n98 "98" { assert ($1 == 98); $$ = $1; } | n99 "99" { assert ($1 == 99); $$ = $1; } | n100 "100" { assert ($1 == 100); $$ = $1; } | n101 "101" { assert ($1 == 101); $$ = $1; } | n102 "102" { assert ($1 == 102); $$ = $1; } | n103 "103" { assert ($1 == 103); $$ = $1; } | n104 "104" { assert ($1 == 104); $$ = $1; } | n105 "105" { assert ($1 == 105); $$ = $1; } | n106 "106" { assert ($1 == 106); $$ = $1; } | n107 "107" { assert ($1 == 107); $$ = $1; } | n108 "108" { assert ($1 == 108); $$ = $1; } | n109 "109" { assert ($1 == 109); $$ = $1; } | n110 "110" { assert ($1 == 110); $$ = $1; } | n111 "111" { assert ($1 == 111); $$ = $1; } | n112 "112" { assert ($1 == 112); $$ = $1; } | n113 "113" { assert ($1 == 113); $$ = $1; } | n114 "114" { assert ($1 == 114); $$ = $1; } | n115 "115" { assert ($1 == 115); $$ = $1; } | n116 "116" { assert ($1 == 116); $$ = $1; } | n117 "117" { assert ($1 == 117); $$ = $1; } | n118 "118" { assert ($1 == 118); $$ = $1; } | n119 "119" { assert ($1 == 119); $$ = $1; } | n120 "120" { assert ($1 == 120); $$ = $1; } | n121 "121" { assert ($1 == 121); $$ = $1; } | n122 "122" { assert ($1 == 122); $$ = $1; } | n123 "123" { assert ($1 == 123); $$ = $1; } | n124 "124" { assert ($1 == 124); $$ = $1; } | n125 "125" { assert ($1 == 125); $$ = $1; } | n126 "126" { assert ($1 == 126); $$ = $1; } | n127 "127" { assert ($1 == 127); $$ = $1; } | n128 "128" { assert ($1 == 128); $$ = $1; } | n129 "129" { assert ($1 == 129); $$ = $1; } | n130 "130" { assert ($1 == 130); $$ = $1; } | n131 "131" { assert ($1 == 131); $$ = $1; } | n132 "132" { assert ($1 == 132); $$ = $1; } | n133 "133" { assert ($1 == 133); $$ = $1; } | n134 "134" { assert ($1 == 134); $$ = $1; } | n135 "135" { assert ($1 == 135); $$ = $1; } | n136 "136" { assert ($1 == 136); $$ = $1; } | n137 "137" { assert ($1 == 137); $$ = $1; } | n138 "138" { assert ($1 == 138); $$ = $1; } | n139 "139" { assert ($1 == 139); $$ = $1; } | n140 "140" { assert ($1 == 140); $$ = $1; } | n141 "141" { assert ($1 == 141); $$ = $1; } | n142 "142" { assert ($1 == 142); $$ = $1; } | n143 "143" { assert ($1 == 143); $$ = $1; } | n144 "144" { assert ($1 == 144); $$ = $1; } | n145 "145" { assert ($1 == 145); $$ = $1; } | n146 "146" { assert ($1 == 146); $$ = $1; } | n147 "147" { assert ($1 == 147); $$ = $1; } | n148 "148" { assert ($1 == 148); $$ = $1; } | n149 "149" { assert ($1 == 149); $$ = $1; } | n150 "150" { assert ($1 == 150); $$ = $1; } | n151 "151" { assert ($1 == 151); $$ = $1; } | n152 "152" { assert ($1 == 152); $$ = $1; } | n153 "153" { assert ($1 == 153); $$ = $1; } | n154 "154" { assert ($1 == 154); $$ = $1; } | n155 "155" { assert ($1 == 155); $$ = $1; } | n156 "156" { assert ($1 == 156); $$ = $1; } | n157 "157" { assert ($1 == 157); $$ = $1; } | n158 "158" { assert ($1 == 158); $$ = $1; } | n159 "159" { assert ($1 == 159); $$ = $1; } | n160 "160" { assert ($1 == 160); $$ = $1; } | n161 "161" { assert ($1 == 161); $$ = $1; } | n162 "162" { assert ($1 == 162); $$ = $1; } | n163 "163" { assert ($1 == 163); $$ = $1; } | n164 "164" { assert ($1 == 164); $$ = $1; } | n165 "165" { assert ($1 == 165); $$ = $1; } | n166 "166" { assert ($1 == 166); $$ = $1; } | n167 "167" { assert ($1 == 167); $$ = $1; } | n168 "168" { assert ($1 == 168); $$ = $1; } | n169 "169" { assert ($1 == 169); $$ = $1; } | n170 "170" { assert ($1 == 170); $$ = $1; } | n171 "171" { assert ($1 == 171); $$ = $1; } | n172 "172" { assert ($1 == 172); $$ = $1; } | n173 "173" { assert ($1 == 173); $$ = $1; } | n174 "174" { assert ($1 == 174); $$ = $1; } | n175 "175" { assert ($1 == 175); $$ = $1; } | n176 "176" { assert ($1 == 176); $$ = $1; } | n177 "177" { assert ($1 == 177); $$ = $1; } | n178 "178" { assert ($1 == 178); $$ = $1; } | n179 "179" { assert ($1 == 179); $$ = $1; } | n180 "180" { assert ($1 == 180); $$ = $1; } | n181 "181" { assert ($1 == 181); $$ = $1; } | n182 "182" { assert ($1 == 182); $$ = $1; } | n183 "183" { assert ($1 == 183); $$ = $1; } | n184 "184" { assert ($1 == 184); $$ = $1; } | n185 "185" { assert ($1 == 185); $$ = $1; } | n186 "186" { assert ($1 == 186); $$ = $1; } | n187 "187" { assert ($1 == 187); $$ = $1; } | n188 "188" { assert ($1 == 188); $$ = $1; } | n189 "189" { assert ($1 == 189); $$ = $1; } | n190 "190" { assert ($1 == 190); $$ = $1; } | n191 "191" { assert ($1 == 191); $$ = $1; } | n192 "192" { assert ($1 == 192); $$ = $1; } | n193 "193" { assert ($1 == 193); $$ = $1; } | n194 "194" { assert ($1 == 194); $$ = $1; } | n195 "195" { assert ($1 == 195); $$ = $1; } | n196 "196" { assert ($1 == 196); $$ = $1; } | n197 "197" { assert ($1 == 197); $$ = $1; } | n198 "198" { assert ($1 == 198); $$ = $1; } | n199 "199" { assert ($1 == 199); $$ = $1; } | n200 "200" { assert ($1 == 200); $$ = $1; } | n201 "201" { assert ($1 == 201); $$ = $1; } | n202 "202" { assert ($1 == 202); $$ = $1; } | n203 "203" { assert ($1 == 203); $$ = $1; } | n204 "204" { assert ($1 == 204); $$ = $1; } | n205 "205" { assert ($1 == 205); $$ = $1; } | n206 "206" { assert ($1 == 206); $$ = $1; } | n207 "207" { assert ($1 == 207); $$ = $1; } | n208 "208" { assert ($1 == 208); $$ = $1; } | n209 "209" { assert ($1 == 209); $$ = $1; } | n210 "210" { assert ($1 == 210); $$ = $1; } | n211 "211" { assert ($1 == 211); $$ = $1; } | n212 "212" { assert ($1 == 212); $$ = $1; } | n213 "213" { assert ($1 == 213); $$ = $1; } | n214 "214" { assert ($1 == 214); $$ = $1; } | n215 "215" { assert ($1 == 215); $$ = $1; } | n216 "216" { assert ($1 == 216); $$ = $1; } | n217 "217" { assert ($1 == 217); $$ = $1; } | n218 "218" { assert ($1 == 218); $$ = $1; } | n219 "219" { assert ($1 == 219); $$ = $1; } | n220 "220" { assert ($1 == 220); $$ = $1; } | n221 "221" { assert ($1 == 221); $$ = $1; } | n222 "222" { assert ($1 == 222); $$ = $1; } | n223 "223" { assert ($1 == 223); $$ = $1; } | n224 "224" { assert ($1 == 224); $$ = $1; } | n225 "225" { assert ($1 == 225); $$ = $1; } | n226 "226" { assert ($1 == 226); $$ = $1; } | n227 "227" { assert ($1 == 227); $$ = $1; } | n228 "228" { assert ($1 == 228); $$ = $1; } | n229 "229" { assert ($1 == 229); $$ = $1; } | n230 "230" { assert ($1 == 230); $$ = $1; } | n231 "231" { assert ($1 == 231); $$ = $1; } | n232 "232" { assert ($1 == 232); $$ = $1; } | n233 "233" { assert ($1 == 233); $$ = $1; } | n234 "234" { assert ($1 == 234); $$ = $1; } | n235 "235" { assert ($1 == 235); $$ = $1; } | n236 "236" { assert ($1 == 236); $$ = $1; } | n237 "237" { assert ($1 == 237); $$ = $1; } | n238 "238" { assert ($1 == 238); $$ = $1; } | n239 "239" { assert ($1 == 239); $$ = $1; } | n240 "240" { assert ($1 == 240); $$ = $1; } | n241 "241" { assert ($1 == 241); $$ = $1; } | n242 "242" { assert ($1 == 242); $$ = $1; } | n243 "243" { assert ($1 == 243); $$ = $1; } | n244 "244" { assert ($1 == 244); $$ = $1; } | n245 "245" { assert ($1 == 245); $$ = $1; } | n246 "246" { assert ($1 == 246); $$ = $1; } | n247 "247" { assert ($1 == 247); $$ = $1; } | n248 "248" { assert ($1 == 248); $$ = $1; } | n249 "249" { assert ($1 == 249); $$ = $1; } | n250 "250" { assert ($1 == 250); $$ = $1; } | n251 "251" { assert ($1 == 251); $$ = $1; } | n252 "252" { assert ($1 == 252); $$ = $1; } | n253 "253" { assert ($1 == 253); $$ = $1; } | n254 "254" { assert ($1 == 254); $$ = $1; } | n255 "255" { assert ($1 == 255); $$ = $1; } | n256 "256" { assert ($1 == 256); $$ = $1; } | n257 "257" { assert ($1 == 257); $$ = $1; } | n258 "258" { assert ($1 == 258); $$ = $1; } | n259 "259" { assert ($1 == 259); $$ = $1; } | n260 "260" { assert ($1 == 260); $$ = $1; } | n261 "261" { assert ($1 == 261); $$ = $1; } | n262 "262" { assert ($1 == 262); $$ = $1; } | n263 "263" { assert ($1 == 263); $$ = $1; } | n264 "264" { assert ($1 == 264); $$ = $1; } | n265 "265" { assert ($1 == 265); $$ = $1; } | n266 "266" { assert ($1 == 266); $$ = $1; } | n267 "267" { assert ($1 == 267); $$ = $1; } | n268 "268" { assert ($1 == 268); $$ = $1; } | n269 "269" { assert ($1 == 269); $$ = $1; } | n270 "270" { assert ($1 == 270); $$ = $1; } | n271 "271" { assert ($1 == 271); $$ = $1; } | n272 "272" { assert ($1 == 272); $$ = $1; } | n273 "273" { assert ($1 == 273); $$ = $1; } | n274 "274" { assert ($1 == 274); $$ = $1; } | n275 "275" { assert ($1 == 275); $$ = $1; } | n276 "276" { assert ($1 == 276); $$ = $1; } | n277 "277" { assert ($1 == 277); $$ = $1; } | n278 "278" { assert ($1 == 278); $$ = $1; } | n279 "279" { assert ($1 == 279); $$ = $1; } | n280 "280" { assert ($1 == 280); $$ = $1; } | n281 "281" { assert ($1 == 281); $$ = $1; } | n282 "282" { assert ($1 == 282); $$ = $1; } | n283 "283" { assert ($1 == 283); $$ = $1; } | n284 "284" { assert ($1 == 284); $$ = $1; } | n285 "285" { assert ($1 == 285); $$ = $1; } | n286 "286" { assert ($1 == 286); $$ = $1; } | n287 "287" { assert ($1 == 287); $$ = $1; } | n288 "288" { assert ($1 == 288); $$ = $1; } | n289 "289" { assert ($1 == 289); $$ = $1; } | n290 "290" { assert ($1 == 290); $$ = $1; } | n291 "291" { assert ($1 == 291); $$ = $1; } | n292 "292" { assert ($1 == 292); $$ = $1; } | n293 "293" { assert ($1 == 293); $$ = $1; } | n294 "294" { assert ($1 == 294); $$ = $1; } | n295 "295" { assert ($1 == 295); $$ = $1; } | n296 "296" { assert ($1 == 296); $$ = $1; } | n297 "297" { assert ($1 == 297); $$ = $1; } | n298 "298" { assert ($1 == 298); $$ = $1; } | n299 "299" { assert ($1 == 299); $$ = $1; } | n300 "300" { assert ($1 == 300); $$ = $1; } | n301 "301" { assert ($1 == 301); $$ = $1; } | n302 "302" { assert ($1 == 302); $$ = $1; } | n303 "303" { assert ($1 == 303); $$ = $1; } | n304 "304" { assert ($1 == 304); $$ = $1; } | n305 "305" { assert ($1 == 305); $$ = $1; } | n306 "306" { assert ($1 == 306); $$ = $1; } | n307 "307" { assert ($1 == 307); $$ = $1; } | n308 "308" { assert ($1 == 308); $$ = $1; } | n309 "309" { assert ($1 == 309); $$ = $1; } | n310 "310" { assert ($1 == 310); $$ = $1; } | n311 "311" { assert ($1 == 311); $$ = $1; } | n312 "312" { assert ($1 == 312); $$ = $1; } | n313 "313" { assert ($1 == 313); $$ = $1; } | n314 "314" { assert ($1 == 314); $$ = $1; } | n315 "315" { assert ($1 == 315); $$ = $1; } | n316 "316" { assert ($1 == 316); $$ = $1; } | n317 "317" { assert ($1 == 317); $$ = $1; } | n318 "318" { assert ($1 == 318); $$ = $1; } | n319 "319" { assert ($1 == 319); $$ = $1; } | n320 "320" { assert ($1 == 320); $$ = $1; } | n321 "321" { assert ($1 == 321); $$ = $1; } | n322 "322" { assert ($1 == 322); $$ = $1; } | n323 "323" { assert ($1 == 323); $$ = $1; } | n324 "324" { assert ($1 == 324); $$ = $1; } | n325 "325" { assert ($1 == 325); $$ = $1; } | n326 "326" { assert ($1 == 326); $$ = $1; } | n327 "327" { assert ($1 == 327); $$ = $1; } | n328 "328" { assert ($1 == 328); $$ = $1; } | n329 "329" { assert ($1 == 329); $$ = $1; } | n330 "330" { assert ($1 == 330); $$ = $1; } | n331 "331" { assert ($1 == 331); $$ = $1; } | n332 "332" { assert ($1 == 332); $$ = $1; } | n333 "333" { assert ($1 == 333); $$ = $1; } | n334 "334" { assert ($1 == 334); $$ = $1; } | n335 "335" { assert ($1 == 335); $$ = $1; } | n336 "336" { assert ($1 == 336); $$ = $1; } | n337 "337" { assert ($1 == 337); $$ = $1; } | n338 "338" { assert ($1 == 338); $$ = $1; } | n339 "339" { assert ($1 == 339); $$ = $1; } | n340 "340" { assert ($1 == 340); $$ = $1; } | n341 "341" { assert ($1 == 341); $$ = $1; } | n342 "342" { assert ($1 == 342); $$ = $1; } | n343 "343" { assert ($1 == 343); $$ = $1; } | n344 "344" { assert ($1 == 344); $$ = $1; } | n345 "345" { assert ($1 == 345); $$ = $1; } | n346 "346" { assert ($1 == 346); $$ = $1; } | n347 "347" { assert ($1 == 347); $$ = $1; } | n348 "348" { assert ($1 == 348); $$ = $1; } | n349 "349" { assert ($1 == 349); $$ = $1; } | n350 "350" { assert ($1 == 350); $$ = $1; } | n351 "351" { assert ($1 == 351); $$ = $1; } | n352 "352" { assert ($1 == 352); $$ = $1; } | n353 "353" { assert ($1 == 353); $$ = $1; } | n354 "354" { assert ($1 == 354); $$ = $1; } | n355 "355" { assert ($1 == 355); $$ = $1; } | n356 "356" { assert ($1 == 356); $$ = $1; } | n357 "357" { assert ($1 == 357); $$ = $1; } | n358 "358" { assert ($1 == 358); $$ = $1; } | n359 "359" { assert ($1 == 359); $$ = $1; } | n360 "360" { assert ($1 == 360); $$ = $1; } | n361 "361" { assert ($1 == 361); $$ = $1; } | n362 "362" { assert ($1 == 362); $$ = $1; } | n363 "363" { assert ($1 == 363); $$ = $1; } | n364 "364" { assert ($1 == 364); $$ = $1; } | n365 "365" { assert ($1 == 365); $$ = $1; } | n366 "366" { assert ($1 == 366); $$ = $1; } | n367 "367" { assert ($1 == 367); $$ = $1; } | n368 "368" { assert ($1 == 368); $$ = $1; } | n369 "369" { assert ($1 == 369); $$ = $1; } | n370 "370" { assert ($1 == 370); $$ = $1; } | n371 "371" { assert ($1 == 371); $$ = $1; } | n372 "372" { assert ($1 == 372); $$ = $1; } | n373 "373" { assert ($1 == 373); $$ = $1; } | n374 "374" { assert ($1 == 374); $$ = $1; } | n375 "375" { assert ($1 == 375); $$ = $1; } | n376 "376" { assert ($1 == 376); $$ = $1; } | n377 "377" { assert ($1 == 377); $$ = $1; } | n378 "378" { assert ($1 == 378); $$ = $1; } | n379 "379" { assert ($1 == 379); $$ = $1; } | n380 "380" { assert ($1 == 380); $$ = $1; } | n381 "381" { assert ($1 == 381); $$ = $1; } | n382 "382" { assert ($1 == 382); $$ = $1; } | n383 "383" { assert ($1 == 383); $$ = $1; } | n384 "384" { assert ($1 == 384); $$ = $1; } | n385 "385" { assert ($1 == 385); $$ = $1; } | n386 "386" { assert ($1 == 386); $$ = $1; } | n387 "387" { assert ($1 == 387); $$ = $1; } | n388 "388" { assert ($1 == 388); $$ = $1; } | n389 "389" { assert ($1 == 389); $$ = $1; } | n390 "390" { assert ($1 == 390); $$ = $1; } | n391 "391" { assert ($1 == 391); $$ = $1; } | n392 "392" { assert ($1 == 392); $$ = $1; } | n393 "393" { assert ($1 == 393); $$ = $1; } | n394 "394" { assert ($1 == 394); $$ = $1; } | n395 "395" { assert ($1 == 395); $$ = $1; } | n396 "396" { assert ($1 == 396); $$ = $1; } | n397 "397" { assert ($1 == 397); $$ = $1; } | n398 "398" { assert ($1 == 398); $$ = $1; } | n399 "399" { assert ($1 == 399); $$ = $1; } | n400 "400" { assert ($1 == 400); $$ = $1; } | n401 "401" { assert ($1 == 401); $$ = $1; } | n402 "402" { assert ($1 == 402); $$ = $1; } | n403 "403" { assert ($1 == 403); $$ = $1; } | n404 "404" { assert ($1 == 404); $$ = $1; } | n405 "405" { assert ($1 == 405); $$ = $1; } | n406 "406" { assert ($1 == 406); $$ = $1; } | n407 "407" { assert ($1 == 407); $$ = $1; } | n408 "408" { assert ($1 == 408); $$ = $1; } | n409 "409" { assert ($1 == 409); $$ = $1; } | n410 "410" { assert ($1 == 410); $$ = $1; } | n411 "411" { assert ($1 == 411); $$ = $1; } | n412 "412" { assert ($1 == 412); $$ = $1; } | n413 "413" { assert ($1 == 413); $$ = $1; } | n414 "414" { assert ($1 == 414); $$ = $1; } | n415 "415" { assert ($1 == 415); $$ = $1; } | n416 "416" { assert ($1 == 416); $$ = $1; } | n417 "417" { assert ($1 == 417); $$ = $1; } | n418 "418" { assert ($1 == 418); $$ = $1; } | n419 "419" { assert ($1 == 419); $$ = $1; } | n420 "420" { assert ($1 == 420); $$ = $1; } | n421 "421" { assert ($1 == 421); $$ = $1; } | n422 "422" { assert ($1 == 422); $$ = $1; } | n423 "423" { assert ($1 == 423); $$ = $1; } | n424 "424" { assert ($1 == 424); $$ = $1; } | n425 "425" { assert ($1 == 425); $$ = $1; } | n426 "426" { assert ($1 == 426); $$ = $1; } | n427 "427" { assert ($1 == 427); $$ = $1; } | n428 "428" { assert ($1 == 428); $$ = $1; } | n429 "429" { assert ($1 == 429); $$ = $1; } | n430 "430" { assert ($1 == 430); $$ = $1; } | n431 "431" { assert ($1 == 431); $$ = $1; } | n432 "432" { assert ($1 == 432); $$ = $1; } | n433 "433" { assert ($1 == 433); $$ = $1; } | n434 "434" { assert ($1 == 434); $$ = $1; } | n435 "435" { assert ($1 == 435); $$ = $1; } | n436 "436" { assert ($1 == 436); $$ = $1; } | n437 "437" { assert ($1 == 437); $$ = $1; } | n438 "438" { assert ($1 == 438); $$ = $1; } | n439 "439" { assert ($1 == 439); $$ = $1; } | n440 "440" { assert ($1 == 440); $$ = $1; } | n441 "441" { assert ($1 == 441); $$ = $1; } | n442 "442" { assert ($1 == 442); $$ = $1; } | n443 "443" { assert ($1 == 443); $$ = $1; } | n444 "444" { assert ($1 == 444); $$ = $1; } | n445 "445" { assert ($1 == 445); $$ = $1; } | n446 "446" { assert ($1 == 446); $$ = $1; } | n447 "447" { assert ($1 == 447); $$ = $1; } | n448 "448" { assert ($1 == 448); $$ = $1; } | n449 "449" { assert ($1 == 449); $$ = $1; } | n450 "450" { assert ($1 == 450); $$ = $1; } | n451 "451" { assert ($1 == 451); $$ = $1; } | n452 "452" { assert ($1 == 452); $$ = $1; } | n453 "453" { assert ($1 == 453); $$ = $1; } | n454 "454" { assert ($1 == 454); $$ = $1; } | n455 "455" { assert ($1 == 455); $$ = $1; } | n456 "456" { assert ($1 == 456); $$ = $1; } | n457 "457" { assert ($1 == 457); $$ = $1; } | n458 "458" { assert ($1 == 458); $$ = $1; } | n459 "459" { assert ($1 == 459); $$ = $1; } | n460 "460" { assert ($1 == 460); $$ = $1; } | n461 "461" { assert ($1 == 461); $$ = $1; } | n462 "462" { assert ($1 == 462); $$ = $1; } | n463 "463" { assert ($1 == 463); $$ = $1; } | n464 "464" { assert ($1 == 464); $$ = $1; } | n465 "465" { assert ($1 == 465); $$ = $1; } | n466 "466" { assert ($1 == 466); $$ = $1; } | n467 "467" { assert ($1 == 467); $$ = $1; } | n468 "468" { assert ($1 == 468); $$ = $1; } | n469 "469" { assert ($1 == 469); $$ = $1; } | n470 "470" { assert ($1 == 470); $$ = $1; } | n471 "471" { assert ($1 == 471); $$ = $1; } | n472 "472" { assert ($1 == 472); $$ = $1; } | n473 "473" { assert ($1 == 473); $$ = $1; } | n474 "474" { assert ($1 == 474); $$ = $1; } | n475 "475" { assert ($1 == 475); $$ = $1; } | n476 "476" { assert ($1 == 476); $$ = $1; } | n477 "477" { assert ($1 == 477); $$ = $1; } | n478 "478" { assert ($1 == 478); $$ = $1; } | n479 "479" { assert ($1 == 479); $$ = $1; } | n480 "480" { assert ($1 == 480); $$ = $1; } | n481 "481" { assert ($1 == 481); $$ = $1; } | n482 "482" { assert ($1 == 482); $$ = $1; } | n483 "483" { assert ($1 == 483); $$ = $1; } | n484 "484" { assert ($1 == 484); $$ = $1; } | n485 "485" { assert ($1 == 485); $$ = $1; } | n486 "486" { assert ($1 == 486); $$ = $1; } | n487 "487" { assert ($1 == 487); $$ = $1; } | n488 "488" { assert ($1 == 488); $$ = $1; } | n489 "489" { assert ($1 == 489); $$ = $1; } | n490 "490" { assert ($1 == 490); $$ = $1; } | n491 "491" { assert ($1 == 491); $$ = $1; } | n492 "492" { assert ($1 == 492); $$ = $1; } | n493 "493" { assert ($1 == 493); $$ = $1; } | n494 "494" { assert ($1 == 494); $$ = $1; } | n495 "495" { assert ($1 == 495); $$ = $1; } | n496 "496" { assert ($1 == 496); $$ = $1; } | n497 "497" { assert ($1 == 497); $$ = $1; } | n498 "498" { assert ($1 == 498); $$ = $1; } | n499 "499" { assert ($1 == 499); $$ = $1; } | n500 "500" { assert ($1 == 500); $$ = $1; } | n501 "501" { assert ($1 == 501); $$ = $1; } | n502 "502" { assert ($1 == 502); $$ = $1; } | n503 "503" { assert ($1 == 503); $$ = $1; } | n504 "504" { assert ($1 == 504); $$ = $1; } | n505 "505" { assert ($1 == 505); $$ = $1; } | n506 "506" { assert ($1 == 506); $$ = $1; } | n507 "507" { assert ($1 == 507); $$ = $1; } | n508 "508" { assert ($1 == 508); $$ = $1; } | n509 "509" { assert ($1 == 509); $$ = $1; } | n510 "510" { assert ($1 == 510); $$ = $1; } | n511 "511" { assert ($1 == 511); $$ = $1; } | n512 "512" { assert ($1 == 512); $$ = $1; } | n513 "513" { assert ($1 == 513); $$ = $1; } | n514 "514" { assert ($1 == 514); $$ = $1; } | n515 "515" { assert ($1 == 515); $$ = $1; } | n516 "516" { assert ($1 == 516); $$ = $1; } | n517 "517" { assert ($1 == 517); $$ = $1; } | n518 "518" { assert ($1 == 518); $$ = $1; } | n519 "519" { assert ($1 == 519); $$ = $1; } | n520 "520" { assert ($1 == 520); $$ = $1; } | n521 "521" { assert ($1 == 521); $$ = $1; } | n522 "522" { assert ($1 == 522); $$ = $1; } | n523 "523" { assert ($1 == 523); $$ = $1; } | n524 "524" { assert ($1 == 524); $$ = $1; } | n525 "525" { assert ($1 == 525); $$ = $1; } | n526 "526" { assert ($1 == 526); $$ = $1; } | n527 "527" { assert ($1 == 527); $$ = $1; } | n528 "528" { assert ($1 == 528); $$ = $1; } | n529 "529" { assert ($1 == 529); $$ = $1; } | n530 "530" { assert ($1 == 530); $$ = $1; } | n531 "531" { assert ($1 == 531); $$ = $1; } | n532 "532" { assert ($1 == 532); $$ = $1; } | n533 "533" { assert ($1 == 533); $$ = $1; } | n534 "534" { assert ($1 == 534); $$ = $1; } | n535 "535" { assert ($1 == 535); $$ = $1; } | n536 "536" { assert ($1 == 536); $$ = $1; } | n537 "537" { assert ($1 == 537); $$ = $1; } | n538 "538" { assert ($1 == 538); $$ = $1; } | n539 "539" { assert ($1 == 539); $$ = $1; } | n540 "540" { assert ($1 == 540); $$ = $1; } | n541 "541" { assert ($1 == 541); $$ = $1; } | n542 "542" { assert ($1 == 542); $$ = $1; } | n543 "543" { assert ($1 == 543); $$ = $1; } | n544 "544" { assert ($1 == 544); $$ = $1; } | n545 "545" { assert ($1 == 545); $$ = $1; } | n546 "546" { assert ($1 == 546); $$ = $1; } | n547 "547" { assert ($1 == 547); $$ = $1; } | n548 "548" { assert ($1 == 548); $$ = $1; } | n549 "549" { assert ($1 == 549); $$ = $1; } | n550 "550" { assert ($1 == 550); $$ = $1; } | n551 "551" { assert ($1 == 551); $$ = $1; } | n552 "552" { assert ($1 == 552); $$ = $1; } | n553 "553" { assert ($1 == 553); $$ = $1; } | n554 "554" { assert ($1 == 554); $$ = $1; } | n555 "555" { assert ($1 == 555); $$ = $1; } | n556 "556" { assert ($1 == 556); $$ = $1; } | n557 "557" { assert ($1 == 557); $$ = $1; } | n558 "558" { assert ($1 == 558); $$ = $1; } | n559 "559" { assert ($1 == 559); $$ = $1; } | n560 "560" { assert ($1 == 560); $$ = $1; } | n561 "561" { assert ($1 == 561); $$ = $1; } | n562 "562" { assert ($1 == 562); $$ = $1; } | n563 "563" { assert ($1 == 563); $$ = $1; } | n564 "564" { assert ($1 == 564); $$ = $1; } | n565 "565" { assert ($1 == 565); $$ = $1; } | n566 "566" { assert ($1 == 566); $$ = $1; } | n567 "567" { assert ($1 == 567); $$ = $1; } | n568 "568" { assert ($1 == 568); $$ = $1; } | n569 "569" { assert ($1 == 569); $$ = $1; } | n570 "570" { assert ($1 == 570); $$ = $1; } | n571 "571" { assert ($1 == 571); $$ = $1; } | n572 "572" { assert ($1 == 572); $$ = $1; } | n573 "573" { assert ($1 == 573); $$ = $1; } | n574 "574" { assert ($1 == 574); $$ = $1; } | n575 "575" { assert ($1 == 575); $$ = $1; } | n576 "576" { assert ($1 == 576); $$ = $1; } | n577 "577" { assert ($1 == 577); $$ = $1; } | n578 "578" { assert ($1 == 578); $$ = $1; } | n579 "579" { assert ($1 == 579); $$ = $1; } | n580 "580" { assert ($1 == 580); $$ = $1; } | n581 "581" { assert ($1 == 581); $$ = $1; } | n582 "582" { assert ($1 == 582); $$ = $1; } | n583 "583" { assert ($1 == 583); $$ = $1; } | n584 "584" { assert ($1 == 584); $$ = $1; } | n585 "585" { assert ($1 == 585); $$ = $1; } | n586 "586" { assert ($1 == 586); $$ = $1; } | n587 "587" { assert ($1 == 587); $$ = $1; } | n588 "588" { assert ($1 == 588); $$ = $1; } | n589 "589" { assert ($1 == 589); $$ = $1; } | n590 "590" { assert ($1 == 590); $$ = $1; } | n591 "591" { assert ($1 == 591); $$ = $1; } | n592 "592" { assert ($1 == 592); $$ = $1; } | n593 "593" { assert ($1 == 593); $$ = $1; } | n594 "594" { assert ($1 == 594); $$ = $1; } | n595 "595" { assert ($1 == 595); $$ = $1; } | n596 "596" { assert ($1 == 596); $$ = $1; } | n597 "597" { assert ($1 == 597); $$ = $1; } | n598 "598" { assert ($1 == 598); $$ = $1; } | n599 "599" { assert ($1 == 599); $$ = $1; } | n600 "600" { assert ($1 == 600); $$ = $1; } | n601 "601" { assert ($1 == 601); $$ = $1; } | n602 "602" { assert ($1 == 602); $$ = $1; } | n603 "603" { assert ($1 == 603); $$ = $1; } | n604 "604" { assert ($1 == 604); $$ = $1; } | n605 "605" { assert ($1 == 605); $$ = $1; } | n606 "606" { assert ($1 == 606); $$ = $1; } | n607 "607" { assert ($1 == 607); $$ = $1; } | n608 "608" { assert ($1 == 608); $$ = $1; } | n609 "609" { assert ($1 == 609); $$ = $1; } | n610 "610" { assert ($1 == 610); $$ = $1; } | n611 "611" { assert ($1 == 611); $$ = $1; } | n612 "612" { assert ($1 == 612); $$ = $1; } | n613 "613" { assert ($1 == 613); $$ = $1; } | n614 "614" { assert ($1 == 614); $$ = $1; } | n615 "615" { assert ($1 == 615); $$ = $1; } | n616 "616" { assert ($1 == 616); $$ = $1; } | n617 "617" { assert ($1 == 617); $$ = $1; } | n618 "618" { assert ($1 == 618); $$ = $1; } | n619 "619" { assert ($1 == 619); $$ = $1; } | n620 "620" { assert ($1 == 620); $$ = $1; } | n621 "621" { assert ($1 == 621); $$ = $1; } | n622 "622" { assert ($1 == 622); $$ = $1; } | n623 "623" { assert ($1 == 623); $$ = $1; } | n624 "624" { assert ($1 == 624); $$ = $1; } | n625 "625" { assert ($1 == 625); $$ = $1; } | n626 "626" { assert ($1 == 626); $$ = $1; } | n627 "627" { assert ($1 == 627); $$ = $1; } | n628 "628" { assert ($1 == 628); $$ = $1; } | n629 "629" { assert ($1 == 629); $$ = $1; } | n630 "630" { assert ($1 == 630); $$ = $1; } | n631 "631" { assert ($1 == 631); $$ = $1; } | n632 "632" { assert ($1 == 632); $$ = $1; } | n633 "633" { assert ($1 == 633); $$ = $1; } | n634 "634" { assert ($1 == 634); $$ = $1; } | n635 "635" { assert ($1 == 635); $$ = $1; } | n636 "636" { assert ($1 == 636); $$ = $1; } | n637 "637" { assert ($1 == 637); $$ = $1; } | n638 "638" { assert ($1 == 638); $$ = $1; } | n639 "639" { assert ($1 == 639); $$ = $1; } | n640 "640" { assert ($1 == 640); $$ = $1; } | n641 "641" { assert ($1 == 641); $$ = $1; } | n642 "642" { assert ($1 == 642); $$ = $1; } | n643 "643" { assert ($1 == 643); $$ = $1; } | n644 "644" { assert ($1 == 644); $$ = $1; } | n645 "645" { assert ($1 == 645); $$ = $1; } | n646 "646" { assert ($1 == 646); $$ = $1; } | n647 "647" { assert ($1 == 647); $$ = $1; } | n648 "648" { assert ($1 == 648); $$ = $1; } | n649 "649" { assert ($1 == 649); $$ = $1; } | n650 "650" { assert ($1 == 650); $$ = $1; } | n651 "651" { assert ($1 == 651); $$ = $1; } | n652 "652" { assert ($1 == 652); $$ = $1; } | n653 "653" { assert ($1 == 653); $$ = $1; } | n654 "654" { assert ($1 == 654); $$ = $1; } | n655 "655" { assert ($1 == 655); $$ = $1; } | n656 "656" { assert ($1 == 656); $$ = $1; } | n657 "657" { assert ($1 == 657); $$ = $1; } | n658 "658" { assert ($1 == 658); $$ = $1; } | n659 "659" { assert ($1 == 659); $$ = $1; } | n660 "660" { assert ($1 == 660); $$ = $1; } | n661 "661" { assert ($1 == 661); $$ = $1; } | n662 "662" { assert ($1 == 662); $$ = $1; } | n663 "663" { assert ($1 == 663); $$ = $1; } | n664 "664" { assert ($1 == 664); $$ = $1; } | n665 "665" { assert ($1 == 665); $$ = $1; } | n666 "666" { assert ($1 == 666); $$ = $1; } | n667 "667" { assert ($1 == 667); $$ = $1; } | n668 "668" { assert ($1 == 668); $$ = $1; } | n669 "669" { assert ($1 == 669); $$ = $1; } | n670 "670" { assert ($1 == 670); $$ = $1; } | n671 "671" { assert ($1 == 671); $$ = $1; } | n672 "672" { assert ($1 == 672); $$ = $1; } | n673 "673" { assert ($1 == 673); $$ = $1; } | n674 "674" { assert ($1 == 674); $$ = $1; } | n675 "675" { assert ($1 == 675); $$ = $1; } | n676 "676" { assert ($1 == 676); $$ = $1; } | n677 "677" { assert ($1 == 677); $$ = $1; } | n678 "678" { assert ($1 == 678); $$ = $1; } | n679 "679" { assert ($1 == 679); $$ = $1; } | n680 "680" { assert ($1 == 680); $$ = $1; } | n681 "681" { assert ($1 == 681); $$ = $1; } | n682 "682" { assert ($1 == 682); $$ = $1; } | n683 "683" { assert ($1 == 683); $$ = $1; } | n684 "684" { assert ($1 == 684); $$ = $1; } | n685 "685" { assert ($1 == 685); $$ = $1; } | n686 "686" { assert ($1 == 686); $$ = $1; } | n687 "687" { assert ($1 == 687); $$ = $1; } | n688 "688" { assert ($1 == 688); $$ = $1; } | n689 "689" { assert ($1 == 689); $$ = $1; } | n690 "690" { assert ($1 == 690); $$ = $1; } | n691 "691" { assert ($1 == 691); $$ = $1; } | n692 "692" { assert ($1 == 692); $$ = $1; } | n693 "693" { assert ($1 == 693); $$ = $1; } | n694 "694" { assert ($1 == 694); $$ = $1; } | n695 "695" { assert ($1 == 695); $$ = $1; } | n696 "696" { assert ($1 == 696); $$ = $1; } | n697 "697" { assert ($1 == 697); $$ = $1; } | n698 "698" { assert ($1 == 698); $$ = $1; } | n699 "699" { assert ($1 == 699); $$ = $1; } | n700 "700" { assert ($1 == 700); $$ = $1; } | n701 "701" { assert ($1 == 701); $$ = $1; } | n702 "702" { assert ($1 == 702); $$ = $1; } | n703 "703" { assert ($1 == 703); $$ = $1; } | n704 "704" { assert ($1 == 704); $$ = $1; } | n705 "705" { assert ($1 == 705); $$ = $1; } | n706 "706" { assert ($1 == 706); $$ = $1; } | n707 "707" { assert ($1 == 707); $$ = $1; } | n708 "708" { assert ($1 == 708); $$ = $1; } | n709 "709" { assert ($1 == 709); $$ = $1; } | n710 "710" { assert ($1 == 710); $$ = $1; } | n711 "711" { assert ($1 == 711); $$ = $1; } | n712 "712" { assert ($1 == 712); $$ = $1; } | n713 "713" { assert ($1 == 713); $$ = $1; } | n714 "714" { assert ($1 == 714); $$ = $1; } | n715 "715" { assert ($1 == 715); $$ = $1; } | n716 "716" { assert ($1 == 716); $$ = $1; } | n717 "717" { assert ($1 == 717); $$ = $1; } | n718 "718" { assert ($1 == 718); $$ = $1; } | n719 "719" { assert ($1 == 719); $$ = $1; } | n720 "720" { assert ($1 == 720); $$ = $1; } | n721 "721" { assert ($1 == 721); $$ = $1; } | n722 "722" { assert ($1 == 722); $$ = $1; } | n723 "723" { assert ($1 == 723); $$ = $1; } | n724 "724" { assert ($1 == 724); $$ = $1; } | n725 "725" { assert ($1 == 725); $$ = $1; } | n726 "726" { assert ($1 == 726); $$ = $1; } | n727 "727" { assert ($1 == 727); $$ = $1; } | n728 "728" { assert ($1 == 728); $$ = $1; } | n729 "729" { assert ($1 == 729); $$ = $1; } | n730 "730" { assert ($1 == 730); $$ = $1; } | n731 "731" { assert ($1 == 731); $$ = $1; } | n732 "732" { assert ($1 == 732); $$ = $1; } | n733 "733" { assert ($1 == 733); $$ = $1; } | n734 "734" { assert ($1 == 734); $$ = $1; } | n735 "735" { assert ($1 == 735); $$ = $1; } | n736 "736" { assert ($1 == 736); $$ = $1; } | n737 "737" { assert ($1 == 737); $$ = $1; } | n738 "738" { assert ($1 == 738); $$ = $1; } | n739 "739" { assert ($1 == 739); $$ = $1; } | n740 "740" { assert ($1 == 740); $$ = $1; } | n741 "741" { assert ($1 == 741); $$ = $1; } | n742 "742" { assert ($1 == 742); $$ = $1; } | n743 "743" { assert ($1 == 743); $$ = $1; } | n744 "744" { assert ($1 == 744); $$ = $1; } | n745 "745" { assert ($1 == 745); $$ = $1; } | n746 "746" { assert ($1 == 746); $$ = $1; } | n747 "747" { assert ($1 == 747); $$ = $1; } | n748 "748" { assert ($1 == 748); $$ = $1; } | n749 "749" { assert ($1 == 749); $$ = $1; } | n750 "750" { assert ($1 == 750); $$ = $1; } | n751 "751" { assert ($1 == 751); $$ = $1; } | n752 "752" { assert ($1 == 752); $$ = $1; } | n753 "753" { assert ($1 == 753); $$ = $1; } | n754 "754" { assert ($1 == 754); $$ = $1; } | n755 "755" { assert ($1 == 755); $$ = $1; } | n756 "756" { assert ($1 == 756); $$ = $1; } | n757 "757" { assert ($1 == 757); $$ = $1; } | n758 "758" { assert ($1 == 758); $$ = $1; } | n759 "759" { assert ($1 == 759); $$ = $1; } | n760 "760" { assert ($1 == 760); $$ = $1; } | n761 "761" { assert ($1 == 761); $$ = $1; } | n762 "762" { assert ($1 == 762); $$ = $1; } | n763 "763" { assert ($1 == 763); $$ = $1; } | n764 "764" { assert ($1 == 764); $$ = $1; } | n765 "765" { assert ($1 == 765); $$ = $1; } | n766 "766" { assert ($1 == 766); $$ = $1; } | n767 "767" { assert ($1 == 767); $$ = $1; } | n768 "768" { assert ($1 == 768); $$ = $1; } | n769 "769" { assert ($1 == 769); $$ = $1; } | n770 "770" { assert ($1 == 770); $$ = $1; } | n771 "771" { assert ($1 == 771); $$ = $1; } | n772 "772" { assert ($1 == 772); $$ = $1; } | n773 "773" { assert ($1 == 773); $$ = $1; } | n774 "774" { assert ($1 == 774); $$ = $1; } | n775 "775" { assert ($1 == 775); $$ = $1; } | n776 "776" { assert ($1 == 776); $$ = $1; } | n777 "777" { assert ($1 == 777); $$ = $1; } | n778 "778" { assert ($1 == 778); $$ = $1; } | n779 "779" { assert ($1 == 779); $$ = $1; } | n780 "780" { assert ($1 == 780); $$ = $1; } | n781 "781" { assert ($1 == 781); $$ = $1; } | n782 "782" { assert ($1 == 782); $$ = $1; } | n783 "783" { assert ($1 == 783); $$ = $1; } | n784 "784" { assert ($1 == 784); $$ = $1; } | n785 "785" { assert ($1 == 785); $$ = $1; } | n786 "786" { assert ($1 == 786); $$ = $1; } | n787 "787" { assert ($1 == 787); $$ = $1; } | n788 "788" { assert ($1 == 788); $$ = $1; } | n789 "789" { assert ($1 == 789); $$ = $1; } | n790 "790" { assert ($1 == 790); $$ = $1; } | n791 "791" { assert ($1 == 791); $$ = $1; } | n792 "792" { assert ($1 == 792); $$ = $1; } | n793 "793" { assert ($1 == 793); $$ = $1; } | n794 "794" { assert ($1 == 794); $$ = $1; } | n795 "795" { assert ($1 == 795); $$ = $1; } | n796 "796" { assert ($1 == 796); $$ = $1; } | n797 "797" { assert ($1 == 797); $$ = $1; } | n798 "798" { assert ($1 == 798); $$ = $1; } | n799 "799" { assert ($1 == 799); $$ = $1; } | n800 "800" { assert ($1 == 800); $$ = $1; } | n801 "801" { assert ($1 == 801); $$ = $1; } | n802 "802" { assert ($1 == 802); $$ = $1; } | n803 "803" { assert ($1 == 803); $$ = $1; } | n804 "804" { assert ($1 == 804); $$ = $1; } | n805 "805" { assert ($1 == 805); $$ = $1; } | n806 "806" { assert ($1 == 806); $$ = $1; } | n807 "807" { assert ($1 == 807); $$ = $1; } | n808 "808" { assert ($1 == 808); $$ = $1; } | n809 "809" { assert ($1 == 809); $$ = $1; } | n810 "810" { assert ($1 == 810); $$ = $1; } | n811 "811" { assert ($1 == 811); $$ = $1; } | n812 "812" { assert ($1 == 812); $$ = $1; } | n813 "813" { assert ($1 == 813); $$ = $1; } | n814 "814" { assert ($1 == 814); $$ = $1; } | n815 "815" { assert ($1 == 815); $$ = $1; } | n816 "816" { assert ($1 == 816); $$ = $1; } | n817 "817" { assert ($1 == 817); $$ = $1; } | n818 "818" { assert ($1 == 818); $$ = $1; } | n819 "819" { assert ($1 == 819); $$ = $1; } | n820 "820" { assert ($1 == 820); $$ = $1; } | n821 "821" { assert ($1 == 821); $$ = $1; } | n822 "822" { assert ($1 == 822); $$ = $1; } | n823 "823" { assert ($1 == 823); $$ = $1; } | n824 "824" { assert ($1 == 824); $$ = $1; } | n825 "825" { assert ($1 == 825); $$ = $1; } | n826 "826" { assert ($1 == 826); $$ = $1; } | n827 "827" { assert ($1 == 827); $$ = $1; } | n828 "828" { assert ($1 == 828); $$ = $1; } | n829 "829" { assert ($1 == 829); $$ = $1; } | n830 "830" { assert ($1 == 830); $$ = $1; } | n831 "831" { assert ($1 == 831); $$ = $1; } | n832 "832" { assert ($1 == 832); $$ = $1; } | n833 "833" { assert ($1 == 833); $$ = $1; } | n834 "834" { assert ($1 == 834); $$ = $1; } | n835 "835" { assert ($1 == 835); $$ = $1; } | n836 "836" { assert ($1 == 836); $$ = $1; } | n837 "837" { assert ($1 == 837); $$ = $1; } | n838 "838" { assert ($1 == 838); $$ = $1; } | n839 "839" { assert ($1 == 839); $$ = $1; } | n840 "840" { assert ($1 == 840); $$ = $1; } | n841 "841" { assert ($1 == 841); $$ = $1; } | n842 "842" { assert ($1 == 842); $$ = $1; } | n843 "843" { assert ($1 == 843); $$ = $1; } | n844 "844" { assert ($1 == 844); $$ = $1; } | n845 "845" { assert ($1 == 845); $$ = $1; } | n846 "846" { assert ($1 == 846); $$ = $1; } | n847 "847" { assert ($1 == 847); $$ = $1; } | n848 "848" { assert ($1 == 848); $$ = $1; } | n849 "849" { assert ($1 == 849); $$ = $1; } | n850 "850" { assert ($1 == 850); $$ = $1; } | n851 "851" { assert ($1 == 851); $$ = $1; } | n852 "852" { assert ($1 == 852); $$ = $1; } | n853 "853" { assert ($1 == 853); $$ = $1; } | n854 "854" { assert ($1 == 854); $$ = $1; } | n855 "855" { assert ($1 == 855); $$ = $1; } | n856 "856" { assert ($1 == 856); $$ = $1; } | n857 "857" { assert ($1 == 857); $$ = $1; } | n858 "858" { assert ($1 == 858); $$ = $1; } | n859 "859" { assert ($1 == 859); $$ = $1; } | n860 "860" { assert ($1 == 860); $$ = $1; } | n861 "861" { assert ($1 == 861); $$ = $1; } | n862 "862" { assert ($1 == 862); $$ = $1; } | n863 "863" { assert ($1 == 863); $$ = $1; } | n864 "864" { assert ($1 == 864); $$ = $1; } | n865 "865" { assert ($1 == 865); $$ = $1; } | n866 "866" { assert ($1 == 866); $$ = $1; } | n867 "867" { assert ($1 == 867); $$ = $1; } | n868 "868" { assert ($1 == 868); $$ = $1; } | n869 "869" { assert ($1 == 869); $$ = $1; } | n870 "870" { assert ($1 == 870); $$ = $1; } | n871 "871" { assert ($1 == 871); $$ = $1; } | n872 "872" { assert ($1 == 872); $$ = $1; } | n873 "873" { assert ($1 == 873); $$ = $1; } | n874 "874" { assert ($1 == 874); $$ = $1; } | n875 "875" { assert ($1 == 875); $$ = $1; } | n876 "876" { assert ($1 == 876); $$ = $1; } | n877 "877" { assert ($1 == 877); $$ = $1; } | n878 "878" { assert ($1 == 878); $$ = $1; } | n879 "879" { assert ($1 == 879); $$ = $1; } | n880 "880" { assert ($1 == 880); $$ = $1; } | n881 "881" { assert ($1 == 881); $$ = $1; } | n882 "882" { assert ($1 == 882); $$ = $1; } | n883 "883" { assert ($1 == 883); $$ = $1; } | n884 "884" { assert ($1 == 884); $$ = $1; } | n885 "885" { assert ($1 == 885); $$ = $1; } | n886 "886" { assert ($1 == 886); $$ = $1; } | n887 "887" { assert ($1 == 887); $$ = $1; } | n888 "888" { assert ($1 == 888); $$ = $1; } | n889 "889" { assert ($1 == 889); $$ = $1; } | n890 "890" { assert ($1 == 890); $$ = $1; } | n891 "891" { assert ($1 == 891); $$ = $1; } | n892 "892" { assert ($1 == 892); $$ = $1; } | n893 "893" { assert ($1 == 893); $$ = $1; } | n894 "894" { assert ($1 == 894); $$ = $1; } | n895 "895" { assert ($1 == 895); $$ = $1; } | n896 "896" { assert ($1 == 896); $$ = $1; } | n897 "897" { assert ($1 == 897); $$ = $1; } | n898 "898" { assert ($1 == 898); $$ = $1; } | n899 "899" { assert ($1 == 899); $$ = $1; } | n900 "900" { assert ($1 == 900); $$ = $1; } | n901 "901" { assert ($1 == 901); $$ = $1; } | n902 "902" { assert ($1 == 902); $$ = $1; } | n903 "903" { assert ($1 == 903); $$ = $1; } | n904 "904" { assert ($1 == 904); $$ = $1; } | n905 "905" { assert ($1 == 905); $$ = $1; } | n906 "906" { assert ($1 == 906); $$ = $1; } | n907 "907" { assert ($1 == 907); $$ = $1; } | n908 "908" { assert ($1 == 908); $$ = $1; } | n909 "909" { assert ($1 == 909); $$ = $1; } | n910 "910" { assert ($1 == 910); $$ = $1; } | n911 "911" { assert ($1 == 911); $$ = $1; } | n912 "912" { assert ($1 == 912); $$ = $1; } | n913 "913" { assert ($1 == 913); $$ = $1; } | n914 "914" { assert ($1 == 914); $$ = $1; } | n915 "915" { assert ($1 == 915); $$ = $1; } | n916 "916" { assert ($1 == 916); $$ = $1; } | n917 "917" { assert ($1 == 917); $$ = $1; } | n918 "918" { assert ($1 == 918); $$ = $1; } | n919 "919" { assert ($1 == 919); $$ = $1; } | n920 "920" { assert ($1 == 920); $$ = $1; } | n921 "921" { assert ($1 == 921); $$ = $1; } | n922 "922" { assert ($1 == 922); $$ = $1; } | n923 "923" { assert ($1 == 923); $$ = $1; } | n924 "924" { assert ($1 == 924); $$ = $1; } | n925 "925" { assert ($1 == 925); $$ = $1; } | n926 "926" { assert ($1 == 926); $$ = $1; } | n927 "927" { assert ($1 == 927); $$ = $1; } | n928 "928" { assert ($1 == 928); $$ = $1; } | n929 "929" { assert ($1 == 929); $$ = $1; } | n930 "930" { assert ($1 == 930); $$ = $1; } | n931 "931" { assert ($1 == 931); $$ = $1; } | n932 "932" { assert ($1 == 932); $$ = $1; } | n933 "933" { assert ($1 == 933); $$ = $1; } | n934 "934" { assert ($1 == 934); $$ = $1; } | n935 "935" { assert ($1 == 935); $$ = $1; } | n936 "936" { assert ($1 == 936); $$ = $1; } | n937 "937" { assert ($1 == 937); $$ = $1; } | n938 "938" { assert ($1 == 938); $$ = $1; } | n939 "939" { assert ($1 == 939); $$ = $1; } | n940 "940" { assert ($1 == 940); $$ = $1; } | n941 "941" { assert ($1 == 941); $$ = $1; } | n942 "942" { assert ($1 == 942); $$ = $1; } | n943 "943" { assert ($1 == 943); $$ = $1; } | n944 "944" { assert ($1 == 944); $$ = $1; } | n945 "945" { assert ($1 == 945); $$ = $1; } | n946 "946" { assert ($1 == 946); $$ = $1; } | n947 "947" { assert ($1 == 947); $$ = $1; } | n948 "948" { assert ($1 == 948); $$ = $1; } | n949 "949" { assert ($1 == 949); $$ = $1; } | n950 "950" { assert ($1 == 950); $$ = $1; } | n951 "951" { assert ($1 == 951); $$ = $1; } | n952 "952" { assert ($1 == 952); $$ = $1; } | n953 "953" { assert ($1 == 953); $$ = $1; } | n954 "954" { assert ($1 == 954); $$ = $1; } | n955 "955" { assert ($1 == 955); $$ = $1; } | n956 "956" { assert ($1 == 956); $$ = $1; } | n957 "957" { assert ($1 == 957); $$ = $1; } | n958 "958" { assert ($1 == 958); $$ = $1; } | n959 "959" { assert ($1 == 959); $$ = $1; } | n960 "960" { assert ($1 == 960); $$ = $1; } | n961 "961" { assert ($1 == 961); $$ = $1; } | n962 "962" { assert ($1 == 962); $$ = $1; } | n963 "963" { assert ($1 == 963); $$ = $1; } | n964 "964" { assert ($1 == 964); $$ = $1; } | n965 "965" { assert ($1 == 965); $$ = $1; } | n966 "966" { assert ($1 == 966); $$ = $1; } | n967 "967" { assert ($1 == 967); $$ = $1; } | n968 "968" { assert ($1 == 968); $$ = $1; } | n969 "969" { assert ($1 == 969); $$ = $1; } | n970 "970" { assert ($1 == 970); $$ = $1; } | n971 "971" { assert ($1 == 971); $$ = $1; } | n972 "972" { assert ($1 == 972); $$ = $1; } | n973 "973" { assert ($1 == 973); $$ = $1; } | n974 "974" { assert ($1 == 974); $$ = $1; } | n975 "975" { assert ($1 == 975); $$ = $1; } | n976 "976" { assert ($1 == 976); $$ = $1; } | n977 "977" { assert ($1 == 977); $$ = $1; } | n978 "978" { assert ($1 == 978); $$ = $1; } | n979 "979" { assert ($1 == 979); $$ = $1; } | n980 "980" { assert ($1 == 980); $$ = $1; } | n981 "981" { assert ($1 == 981); $$ = $1; } | n982 "982" { assert ($1 == 982); $$ = $1; } | n983 "983" { assert ($1 == 983); $$ = $1; } | n984 "984" { assert ($1 == 984); $$ = $1; } | n985 "985" { assert ($1 == 985); $$ = $1; } | n986 "986" { assert ($1 == 986); $$ = $1; } | n987 "987" { assert ($1 == 987); $$ = $1; } | n988 "988" { assert ($1 == 988); $$ = $1; } | n989 "989" { assert ($1 == 989); $$ = $1; } | n990 "990" { assert ($1 == 990); $$ = $1; } | n991 "991" { assert ($1 == 991); $$ = $1; } | n992 "992" { assert ($1 == 992); $$ = $1; } | n993 "993" { assert ($1 == 993); $$ = $1; } | n994 "994" { assert ($1 == 994); $$ = $1; } | n995 "995" { assert ($1 == 995); $$ = $1; } | n996 "996" { assert ($1 == 996); $$ = $1; } | n997 "997" { assert ($1 == 997); $$ = $1; } | n998 "998" { assert ($1 == 998); $$ = $1; } | n999 "999" { assert ($1 == 999); $$ = $1; } | n1000 "1000" { assert ($1 == 1000); $$ = $1; } ; n1: token { $$ = 1; }; n2: token { $$ = 2; }; n3: token { $$ = 3; }; n4: token { $$ = 4; }; n5: token { $$ = 5; }; n6: token { $$ = 6; }; n7: token { $$ = 7; }; n8: token { $$ = 8; }; n9: token { $$ = 9; }; n10: token { $$ = 10; }; n11: token { $$ = 11; }; n12: token { $$ = 12; }; n13: token { $$ = 13; }; n14: token { $$ = 14; }; n15: token { $$ = 15; }; n16: token { $$ = 16; }; n17: token { $$ = 17; }; n18: token { $$ = 18; }; n19: token { $$ = 19; }; n20: token { $$ = 20; }; n21: token { $$ = 21; }; n22: token { $$ = 22; }; n23: token { $$ = 23; }; n24: token { $$ = 24; }; n25: token { $$ = 25; }; n26: token { $$ = 26; }; n27: token { $$ = 27; }; n28: token { $$ = 28; }; n29: token { $$ = 29; }; n30: token { $$ = 30; }; n31: token { $$ = 31; }; n32: token { $$ = 32; }; n33: token { $$ = 33; }; n34: token { $$ = 34; }; n35: token { $$ = 35; }; n36: token { $$ = 36; }; n37: token { $$ = 37; }; n38: token { $$ = 38; }; n39: token { $$ = 39; }; n40: token { $$ = 40; }; n41: token { $$ = 41; }; n42: token { $$ = 42; }; n43: token { $$ = 43; }; n44: token { $$ = 44; }; n45: token { $$ = 45; }; n46: token { $$ = 46; }; n47: token { $$ = 47; }; n48: token { $$ = 48; }; n49: token { $$ = 49; }; n50: token { $$ = 50; }; n51: token { $$ = 51; }; n52: token { $$ = 52; }; n53: token { $$ = 53; }; n54: token { $$ = 54; }; n55: token { $$ = 55; }; n56: token { $$ = 56; }; n57: token { $$ = 57; }; n58: token { $$ = 58; }; n59: token { $$ = 59; }; n60: token { $$ = 60; }; n61: token { $$ = 61; }; n62: token { $$ = 62; }; n63: token { $$ = 63; }; n64: token { $$ = 64; }; n65: token { $$ = 65; }; n66: token { $$ = 66; }; n67: token { $$ = 67; }; n68: token { $$ = 68; }; n69: token { $$ = 69; }; n70: token { $$ = 70; }; n71: token { $$ = 71; }; n72: token { $$ = 72; }; n73: token { $$ = 73; }; n74: token { $$ = 74; }; n75: token { $$ = 75; }; n76: token { $$ = 76; }; n77: token { $$ = 77; }; n78: token { $$ = 78; }; n79: token { $$ = 79; }; n80: token { $$ = 80; }; n81: token { $$ = 81; }; n82: token { $$ = 82; }; n83: token { $$ = 83; }; n84: token { $$ = 84; }; n85: token { $$ = 85; }; n86: token { $$ = 86; }; n87: token { $$ = 87; }; n88: token { $$ = 88; }; n89: token { $$ = 89; }; n90: token { $$ = 90; }; n91: token { $$ = 91; }; n92: token { $$ = 92; }; n93: token { $$ = 93; }; n94: token { $$ = 94; }; n95: token { $$ = 95; }; n96: token { $$ = 96; }; n97: token { $$ = 97; }; n98: token { $$ = 98; }; n99: token { $$ = 99; }; n100: token { $$ = 100; }; n101: token { $$ = 101; }; n102: token { $$ = 102; }; n103: token { $$ = 103; }; n104: token { $$ = 104; }; n105: token { $$ = 105; }; n106: token { $$ = 106; }; n107: token { $$ = 107; }; n108: token { $$ = 108; }; n109: token { $$ = 109; }; n110: token { $$ = 110; }; n111: token { $$ = 111; }; n112: token { $$ = 112; }; n113: token { $$ = 113; }; n114: token { $$ = 114; }; n115: token { $$ = 115; }; n116: token { $$ = 116; }; n117: token { $$ = 117; }; n118: token { $$ = 118; }; n119: token { $$ = 119; }; n120: token { $$ = 120; }; n121: token { $$ = 121; }; n122: token { $$ = 122; }; n123: token { $$ = 123; }; n124: token { $$ = 124; }; n125: token { $$ = 125; }; n126: token { $$ = 126; }; n127: token { $$ = 127; }; n128: token { $$ = 128; }; n129: token { $$ = 129; }; n130: token { $$ = 130; }; n131: token { $$ = 131; }; n132: token { $$ = 132; }; n133: token { $$ = 133; }; n134: token { $$ = 134; }; n135: token { $$ = 135; }; n136: token { $$ = 136; }; n137: token { $$ = 137; }; n138: token { $$ = 138; }; n139: token { $$ = 139; }; n140: token { $$ = 140; }; n141: token { $$ = 141; }; n142: token { $$ = 142; }; n143: token { $$ = 143; }; n144: token { $$ = 144; }; n145: token { $$ = 145; }; n146: token { $$ = 146; }; n147: token { $$ = 147; }; n148: token { $$ = 148; }; n149: token { $$ = 149; }; n150: token { $$ = 150; }; n151: token { $$ = 151; }; n152: token { $$ = 152; }; n153: token { $$ = 153; }; n154: token { $$ = 154; }; n155: token { $$ = 155; }; n156: token { $$ = 156; }; n157: token { $$ = 157; }; n158: token { $$ = 158; }; n159: token { $$ = 159; }; n160: token { $$ = 160; }; n161: token { $$ = 161; }; n162: token { $$ = 162; }; n163: token { $$ = 163; }; n164: token { $$ = 164; }; n165: token { $$ = 165; }; n166: token { $$ = 166; }; n167: token { $$ = 167; }; n168: token { $$ = 168; }; n169: token { $$ = 169; }; n170: token { $$ = 170; }; n171: token { $$ = 171; }; n172: token { $$ = 172; }; n173: token { $$ = 173; }; n174: token { $$ = 174; }; n175: token { $$ = 175; }; n176: token { $$ = 176; }; n177: token { $$ = 177; }; n178: token { $$ = 178; }; n179: token { $$ = 179; }; n180: token { $$ = 180; }; n181: token { $$ = 181; }; n182: token { $$ = 182; }; n183: token { $$ = 183; }; n184: token { $$ = 184; }; n185: token { $$ = 185; }; n186: token { $$ = 186; }; n187: token { $$ = 187; }; n188: token { $$ = 188; }; n189: token { $$ = 189; }; n190: token { $$ = 190; }; n191: token { $$ = 191; }; n192: token { $$ = 192; }; n193: token { $$ = 193; }; n194: token { $$ = 194; }; n195: token { $$ = 195; }; n196: token { $$ = 196; }; n197: token { $$ = 197; }; n198: token { $$ = 198; }; n199: token { $$ = 199; }; n200: token { $$ = 200; }; n201: token { $$ = 201; }; n202: token { $$ = 202; }; n203: token { $$ = 203; }; n204: token { $$ = 204; }; n205: token { $$ = 205; }; n206: token { $$ = 206; }; n207: token { $$ = 207; }; n208: token { $$ = 208; }; n209: token { $$ = 209; }; n210: token { $$ = 210; }; n211: token { $$ = 211; }; n212: token { $$ = 212; }; n213: token { $$ = 213; }; n214: token { $$ = 214; }; n215: token { $$ = 215; }; n216: token { $$ = 216; }; n217: token { $$ = 217; }; n218: token { $$ = 218; }; n219: token { $$ = 219; }; n220: token { $$ = 220; }; n221: token { $$ = 221; }; n222: token { $$ = 222; }; n223: token { $$ = 223; }; n224: token { $$ = 224; }; n225: token { $$ = 225; }; n226: token { $$ = 226; }; n227: token { $$ = 227; }; n228: token { $$ = 228; }; n229: token { $$ = 229; }; n230: token { $$ = 230; }; n231: token { $$ = 231; }; n232: token { $$ = 232; }; n233: token { $$ = 233; }; n234: token { $$ = 234; }; n235: token { $$ = 235; }; n236: token { $$ = 236; }; n237: token { $$ = 237; }; n238: token { $$ = 238; }; n239: token { $$ = 239; }; n240: token { $$ = 240; }; n241: token { $$ = 241; }; n242: token { $$ = 242; }; n243: token { $$ = 243; }; n244: token { $$ = 244; }; n245: token { $$ = 245; }; n246: token { $$ = 246; }; n247: token { $$ = 247; }; n248: token { $$ = 248; }; n249: token { $$ = 249; }; n250: token { $$ = 250; }; n251: token { $$ = 251; }; n252: token { $$ = 252; }; n253: token { $$ = 253; }; n254: token { $$ = 254; }; n255: token { $$ = 255; }; n256: token { $$ = 256; }; n257: token { $$ = 257; }; n258: token { $$ = 258; }; n259: token { $$ = 259; }; n260: token { $$ = 260; }; n261: token { $$ = 261; }; n262: token { $$ = 262; }; n263: token { $$ = 263; }; n264: token { $$ = 264; }; n265: token { $$ = 265; }; n266: token { $$ = 266; }; n267: token { $$ = 267; }; n268: token { $$ = 268; }; n269: token { $$ = 269; }; n270: token { $$ = 270; }; n271: token { $$ = 271; }; n272: token { $$ = 272; }; n273: token { $$ = 273; }; n274: token { $$ = 274; }; n275: token { $$ = 275; }; n276: token { $$ = 276; }; n277: token { $$ = 277; }; n278: token { $$ = 278; }; n279: token { $$ = 279; }; n280: token { $$ = 280; }; n281: token { $$ = 281; }; n282: token { $$ = 282; }; n283: token { $$ = 283; }; n284: token { $$ = 284; }; n285: token { $$ = 285; }; n286: token { $$ = 286; }; n287: token { $$ = 287; }; n288: token { $$ = 288; }; n289: token { $$ = 289; }; n290: token { $$ = 290; }; n291: token { $$ = 291; }; n292: token { $$ = 292; }; n293: token { $$ = 293; }; n294: token { $$ = 294; }; n295: token { $$ = 295; }; n296: token { $$ = 296; }; n297: token { $$ = 297; }; n298: token { $$ = 298; }; n299: token { $$ = 299; }; n300: token { $$ = 300; }; n301: token { $$ = 301; }; n302: token { $$ = 302; }; n303: token { $$ = 303; }; n304: token { $$ = 304; }; n305: token { $$ = 305; }; n306: token { $$ = 306; }; n307: token { $$ = 307; }; n308: token { $$ = 308; }; n309: token { $$ = 309; }; n310: token { $$ = 310; }; n311: token { $$ = 311; }; n312: token { $$ = 312; }; n313: token { $$ = 313; }; n314: token { $$ = 314; }; n315: token { $$ = 315; }; n316: token { $$ = 316; }; n317: token { $$ = 317; }; n318: token { $$ = 318; }; n319: token { $$ = 319; }; n320: token { $$ = 320; }; n321: token { $$ = 321; }; n322: token { $$ = 322; }; n323: token { $$ = 323; }; n324: token { $$ = 324; }; n325: token { $$ = 325; }; n326: token { $$ = 326; }; n327: token { $$ = 327; }; n328: token { $$ = 328; }; n329: token { $$ = 329; }; n330: token { $$ = 330; }; n331: token { $$ = 331; }; n332: token { $$ = 332; }; n333: token { $$ = 333; }; n334: token { $$ = 334; }; n335: token { $$ = 335; }; n336: token { $$ = 336; }; n337: token { $$ = 337; }; n338: token { $$ = 338; }; n339: token { $$ = 339; }; n340: token { $$ = 340; }; n341: token { $$ = 341; }; n342: token { $$ = 342; }; n343: token { $$ = 343; }; n344: token { $$ = 344; }; n345: token { $$ = 345; }; n346: token { $$ = 346; }; n347: token { $$ = 347; }; n348: token { $$ = 348; }; n349: token { $$ = 349; }; n350: token { $$ = 350; }; n351: token { $$ = 351; }; n352: token { $$ = 352; }; n353: token { $$ = 353; }; n354: token { $$ = 354; }; n355: token { $$ = 355; }; n356: token { $$ = 356; }; n357: token { $$ = 357; }; n358: token { $$ = 358; }; n359: token { $$ = 359; }; n360: token { $$ = 360; }; n361: token { $$ = 361; }; n362: token { $$ = 362; }; n363: token { $$ = 363; }; n364: token { $$ = 364; }; n365: token { $$ = 365; }; n366: token { $$ = 366; }; n367: token { $$ = 367; }; n368: token { $$ = 368; }; n369: token { $$ = 369; }; n370: token { $$ = 370; }; n371: token { $$ = 371; }; n372: token { $$ = 372; }; n373: token { $$ = 373; }; n374: token { $$ = 374; }; n375: token { $$ = 375; }; n376: token { $$ = 376; }; n377: token { $$ = 377; }; n378: token { $$ = 378; }; n379: token { $$ = 379; }; n380: token { $$ = 380; }; n381: token { $$ = 381; }; n382: token { $$ = 382; }; n383: token { $$ = 383; }; n384: token { $$ = 384; }; n385: token { $$ = 385; }; n386: token { $$ = 386; }; n387: token { $$ = 387; }; n388: token { $$ = 388; }; n389: token { $$ = 389; }; n390: token { $$ = 390; }; n391: token { $$ = 391; }; n392: token { $$ = 392; }; n393: token { $$ = 393; }; n394: token { $$ = 394; }; n395: token { $$ = 395; }; n396: token { $$ = 396; }; n397: token { $$ = 397; }; n398: token { $$ = 398; }; n399: token { $$ = 399; }; n400: token { $$ = 400; }; n401: token { $$ = 401; }; n402: token { $$ = 402; }; n403: token { $$ = 403; }; n404: token { $$ = 404; }; n405: token { $$ = 405; }; n406: token { $$ = 406; }; n407: token { $$ = 407; }; n408: token { $$ = 408; }; n409: token { $$ = 409; }; n410: token { $$ = 410; }; n411: token { $$ = 411; }; n412: token { $$ = 412; }; n413: token { $$ = 413; }; n414: token { $$ = 414; }; n415: token { $$ = 415; }; n416: token { $$ = 416; }; n417: token { $$ = 417; }; n418: token { $$ = 418; }; n419: token { $$ = 419; }; n420: token { $$ = 420; }; n421: token { $$ = 421; }; n422: token { $$ = 422; }; n423: token { $$ = 423; }; n424: token { $$ = 424; }; n425: token { $$ = 425; }; n426: token { $$ = 426; }; n427: token { $$ = 427; }; n428: token { $$ = 428; }; n429: token { $$ = 429; }; n430: token { $$ = 430; }; n431: token { $$ = 431; }; n432: token { $$ = 432; }; n433: token { $$ = 433; }; n434: token { $$ = 434; }; n435: token { $$ = 435; }; n436: token { $$ = 436; }; n437: token { $$ = 437; }; n438: token { $$ = 438; }; n439: token { $$ = 439; }; n440: token { $$ = 440; }; n441: token { $$ = 441; }; n442: token { $$ = 442; }; n443: token { $$ = 443; }; n444: token { $$ = 444; }; n445: token { $$ = 445; }; n446: token { $$ = 446; }; n447: token { $$ = 447; }; n448: token { $$ = 448; }; n449: token { $$ = 449; }; n450: token { $$ = 450; }; n451: token { $$ = 451; }; n452: token { $$ = 452; }; n453: token { $$ = 453; }; n454: token { $$ = 454; }; n455: token { $$ = 455; }; n456: token { $$ = 456; }; n457: token { $$ = 457; }; n458: token { $$ = 458; }; n459: token { $$ = 459; }; n460: token { $$ = 460; }; n461: token { $$ = 461; }; n462: token { $$ = 462; }; n463: token { $$ = 463; }; n464: token { $$ = 464; }; n465: token { $$ = 465; }; n466: token { $$ = 466; }; n467: token { $$ = 467; }; n468: token { $$ = 468; }; n469: token { $$ = 469; }; n470: token { $$ = 470; }; n471: token { $$ = 471; }; n472: token { $$ = 472; }; n473: token { $$ = 473; }; n474: token { $$ = 474; }; n475: token { $$ = 475; }; n476: token { $$ = 476; }; n477: token { $$ = 477; }; n478: token { $$ = 478; }; n479: token { $$ = 479; }; n480: token { $$ = 480; }; n481: token { $$ = 481; }; n482: token { $$ = 482; }; n483: token { $$ = 483; }; n484: token { $$ = 484; }; n485: token { $$ = 485; }; n486: token { $$ = 486; }; n487: token { $$ = 487; }; n488: token { $$ = 488; }; n489: token { $$ = 489; }; n490: token { $$ = 490; }; n491: token { $$ = 491; }; n492: token { $$ = 492; }; n493: token { $$ = 493; }; n494: token { $$ = 494; }; n495: token { $$ = 495; }; n496: token { $$ = 496; }; n497: token { $$ = 497; }; n498: token { $$ = 498; }; n499: token { $$ = 499; }; n500: token { $$ = 500; }; n501: token { $$ = 501; }; n502: token { $$ = 502; }; n503: token { $$ = 503; }; n504: token { $$ = 504; }; n505: token { $$ = 505; }; n506: token { $$ = 506; }; n507: token { $$ = 507; }; n508: token { $$ = 508; }; n509: token { $$ = 509; }; n510: token { $$ = 510; }; n511: token { $$ = 511; }; n512: token { $$ = 512; }; n513: token { $$ = 513; }; n514: token { $$ = 514; }; n515: token { $$ = 515; }; n516: token { $$ = 516; }; n517: token { $$ = 517; }; n518: token { $$ = 518; }; n519: token { $$ = 519; }; n520: token { $$ = 520; }; n521: token { $$ = 521; }; n522: token { $$ = 522; }; n523: token { $$ = 523; }; n524: token { $$ = 524; }; n525: token { $$ = 525; }; n526: token { $$ = 526; }; n527: token { $$ = 527; }; n528: token { $$ = 528; }; n529: token { $$ = 529; }; n530: token { $$ = 530; }; n531: token { $$ = 531; }; n532: token { $$ = 532; }; n533: token { $$ = 533; }; n534: token { $$ = 534; }; n535: token { $$ = 535; }; n536: token { $$ = 536; }; n537: token { $$ = 537; }; n538: token { $$ = 538; }; n539: token { $$ = 539; }; n540: token { $$ = 540; }; n541: token { $$ = 541; }; n542: token { $$ = 542; }; n543: token { $$ = 543; }; n544: token { $$ = 544; }; n545: token { $$ = 545; }; n546: token { $$ = 546; }; n547: token { $$ = 547; }; n548: token { $$ = 548; }; n549: token { $$ = 549; }; n550: token { $$ = 550; }; n551: token { $$ = 551; }; n552: token { $$ = 552; }; n553: token { $$ = 553; }; n554: token { $$ = 554; }; n555: token { $$ = 555; }; n556: token { $$ = 556; }; n557: token { $$ = 557; }; n558: token { $$ = 558; }; n559: token { $$ = 559; }; n560: token { $$ = 560; }; n561: token { $$ = 561; }; n562: token { $$ = 562; }; n563: token { $$ = 563; }; n564: token { $$ = 564; }; n565: token { $$ = 565; }; n566: token { $$ = 566; }; n567: token { $$ = 567; }; n568: token { $$ = 568; }; n569: token { $$ = 569; }; n570: token { $$ = 570; }; n571: token { $$ = 571; }; n572: token { $$ = 572; }; n573: token { $$ = 573; }; n574: token { $$ = 574; }; n575: token { $$ = 575; }; n576: token { $$ = 576; }; n577: token { $$ = 577; }; n578: token { $$ = 578; }; n579: token { $$ = 579; }; n580: token { $$ = 580; }; n581: token { $$ = 581; }; n582: token { $$ = 582; }; n583: token { $$ = 583; }; n584: token { $$ = 584; }; n585: token { $$ = 585; }; n586: token { $$ = 586; }; n587: token { $$ = 587; }; n588: token { $$ = 588; }; n589: token { $$ = 589; }; n590: token { $$ = 590; }; n591: token { $$ = 591; }; n592: token { $$ = 592; }; n593: token { $$ = 593; }; n594: token { $$ = 594; }; n595: token { $$ = 595; }; n596: token { $$ = 596; }; n597: token { $$ = 597; }; n598: token { $$ = 598; }; n599: token { $$ = 599; }; n600: token { $$ = 600; }; n601: token { $$ = 601; }; n602: token { $$ = 602; }; n603: token { $$ = 603; }; n604: token { $$ = 604; }; n605: token { $$ = 605; }; n606: token { $$ = 606; }; n607: token { $$ = 607; }; n608: token { $$ = 608; }; n609: token { $$ = 609; }; n610: token { $$ = 610; }; n611: token { $$ = 611; }; n612: token { $$ = 612; }; n613: token { $$ = 613; }; n614: token { $$ = 614; }; n615: token { $$ = 615; }; n616: token { $$ = 616; }; n617: token { $$ = 617; }; n618: token { $$ = 618; }; n619: token { $$ = 619; }; n620: token { $$ = 620; }; n621: token { $$ = 621; }; n622: token { $$ = 622; }; n623: token { $$ = 623; }; n624: token { $$ = 624; }; n625: token { $$ = 625; }; n626: token { $$ = 626; }; n627: token { $$ = 627; }; n628: token { $$ = 628; }; n629: token { $$ = 629; }; n630: token { $$ = 630; }; n631: token { $$ = 631; }; n632: token { $$ = 632; }; n633: token { $$ = 633; }; n634: token { $$ = 634; }; n635: token { $$ = 635; }; n636: token { $$ = 636; }; n637: token { $$ = 637; }; n638: token { $$ = 638; }; n639: token { $$ = 639; }; n640: token { $$ = 640; }; n641: token { $$ = 641; }; n642: token { $$ = 642; }; n643: token { $$ = 643; }; n644: token { $$ = 644; }; n645: token { $$ = 645; }; n646: token { $$ = 646; }; n647: token { $$ = 647; }; n648: token { $$ = 648; }; n649: token { $$ = 649; }; n650: token { $$ = 650; }; n651: token { $$ = 651; }; n652: token { $$ = 652; }; n653: token { $$ = 653; }; n654: token { $$ = 654; }; n655: token { $$ = 655; }; n656: token { $$ = 656; }; n657: token { $$ = 657; }; n658: token { $$ = 658; }; n659: token { $$ = 659; }; n660: token { $$ = 660; }; n661: token { $$ = 661; }; n662: token { $$ = 662; }; n663: token { $$ = 663; }; n664: token { $$ = 664; }; n665: token { $$ = 665; }; n666: token { $$ = 666; }; n667: token { $$ = 667; }; n668: token { $$ = 668; }; n669: token { $$ = 669; }; n670: token { $$ = 670; }; n671: token { $$ = 671; }; n672: token { $$ = 672; }; n673: token { $$ = 673; }; n674: token { $$ = 674; }; n675: token { $$ = 675; }; n676: token { $$ = 676; }; n677: token { $$ = 677; }; n678: token { $$ = 678; }; n679: token { $$ = 679; }; n680: token { $$ = 680; }; n681: token { $$ = 681; }; n682: token { $$ = 682; }; n683: token { $$ = 683; }; n684: token { $$ = 684; }; n685: token { $$ = 685; }; n686: token { $$ = 686; }; n687: token { $$ = 687; }; n688: token { $$ = 688; }; n689: token { $$ = 689; }; n690: token { $$ = 690; }; n691: token { $$ = 691; }; n692: token { $$ = 692; }; n693: token { $$ = 693; }; n694: token { $$ = 694; }; n695: token { $$ = 695; }; n696: token { $$ = 696; }; n697: token { $$ = 697; }; n698: token { $$ = 698; }; n699: token { $$ = 699; }; n700: token { $$ = 700; }; n701: token { $$ = 701; }; n702: token { $$ = 702; }; n703: token { $$ = 703; }; n704: token { $$ = 704; }; n705: token { $$ = 705; }; n706: token { $$ = 706; }; n707: token { $$ = 707; }; n708: token { $$ = 708; }; n709: token { $$ = 709; }; n710: token { $$ = 710; }; n711: token { $$ = 711; }; n712: token { $$ = 712; }; n713: token { $$ = 713; }; n714: token { $$ = 714; }; n715: token { $$ = 715; }; n716: token { $$ = 716; }; n717: token { $$ = 717; }; n718: token { $$ = 718; }; n719: token { $$ = 719; }; n720: token { $$ = 720; }; n721: token { $$ = 721; }; n722: token { $$ = 722; }; n723: token { $$ = 723; }; n724: token { $$ = 724; }; n725: token { $$ = 725; }; n726: token { $$ = 726; }; n727: token { $$ = 727; }; n728: token { $$ = 728; }; n729: token { $$ = 729; }; n730: token { $$ = 730; }; n731: token { $$ = 731; }; n732: token { $$ = 732; }; n733: token { $$ = 733; }; n734: token { $$ = 734; }; n735: token { $$ = 735; }; n736: token { $$ = 736; }; n737: token { $$ = 737; }; n738: token { $$ = 738; }; n739: token { $$ = 739; }; n740: token { $$ = 740; }; n741: token { $$ = 741; }; n742: token { $$ = 742; }; n743: token { $$ = 743; }; n744: token { $$ = 744; }; n745: token { $$ = 745; }; n746: token { $$ = 746; }; n747: token { $$ = 747; }; n748: token { $$ = 748; }; n749: token { $$ = 749; }; n750: token { $$ = 750; }; n751: token { $$ = 751; }; n752: token { $$ = 752; }; n753: token { $$ = 753; }; n754: token { $$ = 754; }; n755: token { $$ = 755; }; n756: token { $$ = 756; }; n757: token { $$ = 757; }; n758: token { $$ = 758; }; n759: token { $$ = 759; }; n760: token { $$ = 760; }; n761: token { $$ = 761; }; n762: token { $$ = 762; }; n763: token { $$ = 763; }; n764: token { $$ = 764; }; n765: token { $$ = 765; }; n766: token { $$ = 766; }; n767: token { $$ = 767; }; n768: token { $$ = 768; }; n769: token { $$ = 769; }; n770: token { $$ = 770; }; n771: token { $$ = 771; }; n772: token { $$ = 772; }; n773: token { $$ = 773; }; n774: token { $$ = 774; }; n775: token { $$ = 775; }; n776: token { $$ = 776; }; n777: token { $$ = 777; }; n778: token { $$ = 778; }; n779: token { $$ = 779; }; n780: token { $$ = 780; }; n781: token { $$ = 781; }; n782: token { $$ = 782; }; n783: token { $$ = 783; }; n784: token { $$ = 784; }; n785: token { $$ = 785; }; n786: token { $$ = 786; }; n787: token { $$ = 787; }; n788: token { $$ = 788; }; n789: token { $$ = 789; }; n790: token { $$ = 790; }; n791: token { $$ = 791; }; n792: token { $$ = 792; }; n793: token { $$ = 793; }; n794: token { $$ = 794; }; n795: token { $$ = 795; }; n796: token { $$ = 796; }; n797: token { $$ = 797; }; n798: token { $$ = 798; }; n799: token { $$ = 799; }; n800: token { $$ = 800; }; n801: token { $$ = 801; }; n802: token { $$ = 802; }; n803: token { $$ = 803; }; n804: token { $$ = 804; }; n805: token { $$ = 805; }; n806: token { $$ = 806; }; n807: token { $$ = 807; }; n808: token { $$ = 808; }; n809: token { $$ = 809; }; n810: token { $$ = 810; }; n811: token { $$ = 811; }; n812: token { $$ = 812; }; n813: token { $$ = 813; }; n814: token { $$ = 814; }; n815: token { $$ = 815; }; n816: token { $$ = 816; }; n817: token { $$ = 817; }; n818: token { $$ = 818; }; n819: token { $$ = 819; }; n820: token { $$ = 820; }; n821: token { $$ = 821; }; n822: token { $$ = 822; }; n823: token { $$ = 823; }; n824: token { $$ = 824; }; n825: token { $$ = 825; }; n826: token { $$ = 826; }; n827: token { $$ = 827; }; n828: token { $$ = 828; }; n829: token { $$ = 829; }; n830: token { $$ = 830; }; n831: token { $$ = 831; }; n832: token { $$ = 832; }; n833: token { $$ = 833; }; n834: token { $$ = 834; }; n835: token { $$ = 835; }; n836: token { $$ = 836; }; n837: token { $$ = 837; }; n838: token { $$ = 838; }; n839: token { $$ = 839; }; n840: token { $$ = 840; }; n841: token { $$ = 841; }; n842: token { $$ = 842; }; n843: token { $$ = 843; }; n844: token { $$ = 844; }; n845: token { $$ = 845; }; n846: token { $$ = 846; }; n847: token { $$ = 847; }; n848: token { $$ = 848; }; n849: token { $$ = 849; }; n850: token { $$ = 850; }; n851: token { $$ = 851; }; n852: token { $$ = 852; }; n853: token { $$ = 853; }; n854: token { $$ = 854; }; n855: token { $$ = 855; }; n856: token { $$ = 856; }; n857: token { $$ = 857; }; n858: token { $$ = 858; }; n859: token { $$ = 859; }; n860: token { $$ = 860; }; n861: token { $$ = 861; }; n862: token { $$ = 862; }; n863: token { $$ = 863; }; n864: token { $$ = 864; }; n865: token { $$ = 865; }; n866: token { $$ = 866; }; n867: token { $$ = 867; }; n868: token { $$ = 868; }; n869: token { $$ = 869; }; n870: token { $$ = 870; }; n871: token { $$ = 871; }; n872: token { $$ = 872; }; n873: token { $$ = 873; }; n874: token { $$ = 874; }; n875: token { $$ = 875; }; n876: token { $$ = 876; }; n877: token { $$ = 877; }; n878: token { $$ = 878; }; n879: token { $$ = 879; }; n880: token { $$ = 880; }; n881: token { $$ = 881; }; n882: token { $$ = 882; }; n883: token { $$ = 883; }; n884: token { $$ = 884; }; n885: token { $$ = 885; }; n886: token { $$ = 886; }; n887: token { $$ = 887; }; n888: token { $$ = 888; }; n889: token { $$ = 889; }; n890: token { $$ = 890; }; n891: token { $$ = 891; }; n892: token { $$ = 892; }; n893: token { $$ = 893; }; n894: token { $$ = 894; }; n895: token { $$ = 895; }; n896: token { $$ = 896; }; n897: token { $$ = 897; }; n898: token { $$ = 898; }; n899: token { $$ = 899; }; n900: token { $$ = 900; }; n901: token { $$ = 901; }; n902: token { $$ = 902; }; n903: token { $$ = 903; }; n904: token { $$ = 904; }; n905: token { $$ = 905; }; n906: token { $$ = 906; }; n907: token { $$ = 907; }; n908: token { $$ = 908; }; n909: token { $$ = 909; }; n910: token { $$ = 910; }; n911: token { $$ = 911; }; n912: token { $$ = 912; }; n913: token { $$ = 913; }; n914: token { $$ = 914; }; n915: token { $$ = 915; }; n916: token { $$ = 916; }; n917: token { $$ = 917; }; n918: token { $$ = 918; }; n919: token { $$ = 919; }; n920: token { $$ = 920; }; n921: token { $$ = 921; }; n922: token { $$ = 922; }; n923: token { $$ = 923; }; n924: token { $$ = 924; }; n925: token { $$ = 925; }; n926: token { $$ = 926; }; n927: token { $$ = 927; }; n928: token { $$ = 928; }; n929: token { $$ = 929; }; n930: token { $$ = 930; }; n931: token { $$ = 931; }; n932: token { $$ = 932; }; n933: token { $$ = 933; }; n934: token { $$ = 934; }; n935: token { $$ = 935; }; n936: token { $$ = 936; }; n937: token { $$ = 937; }; n938: token { $$ = 938; }; n939: token { $$ = 939; }; n940: token { $$ = 940; }; n941: token { $$ = 941; }; n942: token { $$ = 942; }; n943: token { $$ = 943; }; n944: token { $$ = 944; }; n945: token { $$ = 945; }; n946: token { $$ = 946; }; n947: token { $$ = 947; }; n948: token { $$ = 948; }; n949: token { $$ = 949; }; n950: token { $$ = 950; }; n951: token { $$ = 951; }; n952: token { $$ = 952; }; n953: token { $$ = 953; }; n954: token { $$ = 954; }; n955: token { $$ = 955; }; n956: token { $$ = 956; }; n957: token { $$ = 957; }; n958: token { $$ = 958; }; n959: token { $$ = 959; }; n960: token { $$ = 960; }; n961: token { $$ = 961; }; n962: token { $$ = 962; }; n963: token { $$ = 963; }; n964: token { $$ = 964; }; n965: token { $$ = 965; }; n966: token { $$ = 966; }; n967: token { $$ = 967; }; n968: token { $$ = 968; }; n969: token { $$ = 969; }; n970: token { $$ = 970; }; n971: token { $$ = 971; }; n972: token { $$ = 972; }; n973: token { $$ = 973; }; n974: token { $$ = 974; }; n975: token { $$ = 975; }; n976: token { $$ = 976; }; n977: token { $$ = 977; }; n978: token { $$ = 978; }; n979: token { $$ = 979; }; n980: token { $$ = 980; }; n981: token { $$ = 981; }; n982: token { $$ = 982; }; n983: token { $$ = 983; }; n984: token { $$ = 984; }; n985: token { $$ = 985; }; n986: token { $$ = 986; }; n987: token { $$ = 987; }; n988: token { $$ = 988; }; n989: token { $$ = 989; }; n990: token { $$ = 990; }; n991: token { $$ = 991; }; n992: token { $$ = 992; }; n993: token { $$ = 993; }; n994: token { $$ = 994; }; n995: token { $$ = 995; }; n996: token { $$ = 996; }; n997: token { $$ = 997; }; n998: token { $$ = 998; }; n999: token { $$ = 999; }; n1000: token { $$ = 1000; }; %% /* A C error reporting function. */ /* !POSIX */ static void yyerror (const char *msg) { fprintf (stderr, "%s\n", msg); } static int yylex (void) { static int return_token = 1; static int counter = 1; if (counter > MAX) { assert (counter++ == MAX + 1); return 0; } if (return_token) { return_token = 0; return token; } return_token = 1; return counter++; } #include /* getenv. */ #include /* strcmp. */ int main (int argc, char const* argv[]) { (void) argc; (void) argv; return yyparse (); } ./calc.at:1492: cat stderr ./torture.at:393: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y 614. torture.at:485: testing Exploding the Stack Size with Alloca ... stderr: stdout: ./torture.at:494: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./calc.at:1491: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh input: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (# + 1) = 1111 ./calc.at:1492: $PREPARSER ./calc input input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 stderr: ./calc.at:1491: $PREPARSER ./calc input stdout: stderr: 616. existing.at:74: testing GNU AWK 3.1.0 Grammar: LALR(1) ... ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (14.1: ) Entering state 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./torture.at:494: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 615. torture.at:531: testing Exploding the Stack Size with Malloc ... ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: ./torture.at:535: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: | (1 + 1) / (1 - 1) ./calc.at:1489: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1494: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (14.1: ) Entering state 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) input: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 2 ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token ')' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) -> $$ = nterm exp (2) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (2) $3 = token ')' () -> $$ = nterm exp (2) Entering state 8 Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token Next token is token '-' () Shifting token '-' () Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 28 Reading a token Next token is token ')' () Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (1) -> $$ = nterm exp (0) Entering state 12 Next token is token ')' () Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' () $2 = nterm exp (0) $3 = token ')' () -> $$ = nterm exp (0) Entering state 31 Reading a token Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (2) $2 = token '/' () $3 = nterm exp (0) error: null divisor -> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. Shifting token end of input () Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token number (1.3: 2) ./calc.at:1492: cat stderr stderr: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13: 7) Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token "number" (2.1: 1) Shifting token "number" (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token "number" (2.5: 2) Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token "number" (2.10: 3) Shifting token "number" (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token "number" (2.15: 5) Shifting token "number" (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token "number" (4.2: 1) Shifting token "number" (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token "number" (4.4: 2) Shifting token "number" (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token "number" (4.9: 1) Shifting token "number" (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token "number" (5.3: 1) Shifting token "number" (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token "number" (5.6: 2) Shifting token "number" (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token "number" (5.10: 1) Shifting token "number" (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token "number" (7.4: 1) Shifting token "number" (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token "number" (7.9: 1) Shifting token "number" (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token "number" (9.1: 1) Shifting token "number" (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token "number" (9.5: 2) Shifting token "number" (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token "number" (9.9: 3) Shifting token "number" (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token "number" (9.14: 4) Shifting token "number" (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token "number" (10.1: 1) Shifting token "number" (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token "number" (10.6: 2) Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token "number" (10.10: 3) Shifting token "number" (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token "number" (10.15: 2) Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token "number" (12.1: 2) Shifting token "number" (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token "number" (12.3: 2) Shifting token "number" (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token "number" (12.5: 3) Shifting token "number" (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token "number" (12.9-11: 256) Shifting token "number" (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token "number" (13.2: 2) Shifting token "number" (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token "number" (13.4: 2) Shifting token "number" (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token "number" (13.7: 3) Shifting token "number" (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token "number" (13.11-12: 64) Shifting token "number" (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (14.1: ) Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./torture.at:535: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS input: stderr: input: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token number (1.3: 2) | (1 + # + 1) = 1111 | 1 2 ./calc.at:1492: $PREPARSER ./calc input ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: cat stderr ./calc.at:1489: cat stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token "number" (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) 564. calc.at:1489: ok input: | 1//2 ./calc.at:1491: $PREPARSER ./calc input stderr: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1492: cat stderr ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: cat stderr input: stderr: | (1 + 1) / (1 - 1) ./calc.at:1492: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) input: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | 1//2 ./calc.at:1494: $PREPARSER ./calc input stderr: stderr: input.y:66.10: error: empty rule without %empty [-Werror=empty-rule] input.y:170.10: error: empty rule without %empty [-Werror=empty-rule] input.y:175.10: error: empty rule without %empty [-Werror=empty-rule] input.y:180.10: error: empty rule without %empty [-Werror=empty-rule] input.y:188.10: error: empty rule without %empty [-Werror=empty-rule] input.y:202.10: error: empty rule without %empty [-Werror=empty-rule] input.y:207.10: error: empty rule without %empty [-Werror=empty-rule] input.y:221.10: error: empty rule without %empty [-Werror=empty-rule] input.y:300.10: error: empty rule without %empty [-Werror=empty-rule] input.y:323.10: error: empty rule without %empty [-Werror=empty-rule] input.y: error: 65 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:39.1-5: error: useless associativity for FUNC_CALL, use %precedence [-Werror=precedence] input.y:44.1-5: error: useless associativity for YNUMBER, use %precedence [-Werror=precedence] input.y:44.1-5: error: useless associativity for YSTRING, use %precedence [-Werror=precedence] input.y:42.1-9: error: useless precedence and associativity for APPEND_OP [-Werror=precedence] input.y:33.1-6: error: useless associativity for ASSIGNOP, use %precedence [-Werror=precedence] input.y:43.1-5: error: useless associativity for CONCAT_OP, use %precedence [-Werror=precedence] input.y:37.1-5: error: useless precedence and associativity for LEX_GETLINE [-Werror=precedence] input.y:38.1-9: error: useless associativity for LEX_IN, use %precedence [-Werror=precedence] input.y:49.1-5: error: useless associativity for INCREMENT, use %precedence [-Werror=precedence] input.y:49.1-5: error: useless associativity for DECREMENT, use %precedence [-Werror=precedence] input.y:39.1-5: error: useless associativity for LEX_BUILTIN, use %precedence [-Werror=precedence] input.y:39.1-5: error: useless associativity for LEX_LENGTH, use %precedence [-Werror=precedence] input.y:40.1-9: error: useless precedence and associativity for ',' [-Werror=precedence] input.y:47.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] input.y:47.1-6: error: useless associativity for UNARY, use %precedence [-Werror=precedence] input.y:50.1-5: error: useless associativity for '$', use %precedence [-Werror=precedence] input.y:51.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] input.y:51.1-5: error: useless precedence and associativity for ')' [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: cat stderr ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./torture.at:497: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 20 stderr: stderr: ./existing.at:74: sed 's,.*/$,,' stderr 1>&2 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./torture.at:497: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: 617. existing.at:74: testing GNU AWK 3.1.0 Grammar: IELR(1) ... ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y | error ./calc.at:1491: $PREPARSER ./calc input ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) ./torture.at:500: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 900 ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: cat stderr ./torture.at:500: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1494: cat stderr stderr: 567. calc.at:1492: Starting parse Entering state 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) ok ./torture.at:504: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 10000 stderr: memory exhausted memory exhausted ./torture.at:504: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | error ./calc.at:1494: $PREPARSER ./calc input memory exhausted memory exhausted ./torture.at:510: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) stderr: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stdout: stderr: input: ./torture.at:538: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 20 Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) stderr: ./calc.at:1492: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh | 1 = 2 = 3 ./calc.at:1491: $PREPARSER ./calc input ./torture.at:538: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./torture.at:510: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./torture.at:541: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 900 ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1492: $PREPARSER ./calc input ./calc.at:1494: cat stderr ./torture.at:541: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (14.1: ) Entering state 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: input: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 618. existing.at:74: testing GNU AWK 3.1.0 Grammar: Canonical LR(1) ... ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./calc.at:1494: $PREPARSER ./calc input ./torture.at:545: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 10000 stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) stderr: memory exhausted memory exhausted ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./torture.at:545: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (14.1: ) Entering state 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: cat stderr stderr: input: memory exhausted memory exhausted | 1 2 stderr: ./calc.at:1492: $PREPARSER ./calc input ./torture.at:548: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none input: stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) | | +1 ./calc.at:1491: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token number (1.3: 2) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token number (1.3: 2) ./torture.at:548: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./calc.at:1494: cat stderr ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: cat stderr input: | | +1 ./calc.at:1494: $PREPARSER ./calc input stderr: ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) stderr: input: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: $PREPARSER ./calc /dev/null input.y:66.10: error: empty rule without %empty [-Werror=empty-rule] input.y:170.10: error: empty rule without %empty [-Werror=empty-rule] input.y:175.10: error: empty rule without %empty [-Werror=empty-rule] input.y:180.10: error: empty rule without %empty [-Werror=empty-rule] input.y:188.10: error: empty rule without %empty [-Werror=empty-rule] input.y:202.10: error: empty rule without %empty [-Werror=empty-rule] input.y:207.10: error: empty rule without %empty [-Werror=empty-rule] input.y:221.10: error: empty rule without %empty [-Werror=empty-rule] input.y:300.10: error: empty rule without %empty [-Werror=empty-rule] input.y:323.10: error: empty rule without %empty [-Werror=empty-rule] input.y: error: 65 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:39.1-5: error: useless associativity for FUNC_CALL, use %precedence [-Werror=precedence] input.y:44.1-5: error: useless associativity for YNUMBER, use %precedence [-Werror=precedence] input.y:44.1-5: error: useless associativity for YSTRING, use %precedence [-Werror=precedence] input.y:42.1-9: error: useless precedence and associativity for APPEND_OP [-Werror=precedence] input.y:33.1-6: error: useless associativity for ASSIGNOP, use %precedence [-Werror=precedence] input.y:43.1-5: error: useless associativity for CONCAT_OP, use %precedence [-Werror=precedence] input.y:37.1-5: error: useless precedence and associativity for LEX_GETLINE [-Werror=precedence] input.y:38.1-9: error: useless associativity for LEX_IN, use %precedence [-Werror=precedence] input.y:49.1-5: error: useless associativity for INCREMENT, use %precedence [-Werror=precedence] input.y:49.1-5: error: useless associativity for DECREMENT, use %precedence [-Werror=precedence] input.y:39.1-5: error: useless associativity for LEX_BUILTIN, use %precedence [-Werror=precedence] input.y:39.1-5: error: useless associativity for LEX_LENGTH, use %precedence [-Werror=precedence] input.y:40.1-9: error: useless precedence and associativity for ',' [-Werror=precedence] input.y:47.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] input.y:47.1-6: error: useless associativity for UNARY, use %precedence [-Werror=precedence] input.y:50.1-5: error: useless associativity for '$', use %precedence [-Werror=precedence] input.y:51.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] input.y:51.1-5: error: useless precedence and associativity for ')' [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] | 1//2 ./calc.at:1492: $PREPARSER ./calc input stderr: ./existing.at:74: sed -n 's/^State //p' input.output | tail -1 stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./existing.at:74: sed 's,.*/$,,' stderr 1>&2 stderr: ./existing.at:74: sed 's/^%define lr.type .*$//' input.y > input-lalr.y stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error ./calc.at:1494: cat stderr ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: $PREPARSER ./calc /dev/null stderr: ./calc.at:1492: cat stderr ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) stderr: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./torture.at:140: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS input: ./torture.at:513: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 20 stderr: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1491: $PREPARSER ./calc input stderr: | error stderr: ./calc.at:1492: $PREPARSER ./calc input ./torture.at:513: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) stderr: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: cat stderr ./torture.at:515: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 900 stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input: ./torture.at:515: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: input-lalr.y: warning: 65 shift/reduce conflicts [-Wconflicts-sr] input-lalr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stdout: ./calc.at:1494: $PREPARSER ./calc input ./existing.at:74: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' stderr: stderr: ./torture.at:517: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 10000 ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none stderr: ./calc.at:1491: cat stderr ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:74: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS memory exhausted memory exhausted ./torture.at:517: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: cat stderr stderr: input: memory exhausted memory exhausted stderr: stderr: | (!!) + (1 2) = 1 ./calc.at:1491: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token "number" (1.7: 1) Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token "number" (1.11: 1) Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token "number" (1.15: 1) Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token "number" (1.33: 1) Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token "number" (1.37: 2) Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token "number" (1.46: 1) Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stdout: stderr: 614. torture.at:485: ok ./torture.at:551: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 20 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stderr: ./torture.at:551: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 = 2 = 3 ./calc.at:1492: $PREPARSER ./calc input ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./torture.at:553: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 900 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: cat stderr stderr: ./torture.at:237: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./torture.at:553: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) | (!!) + (1 2) = 1 ./calc.at:1494: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1491: cat stderr ./torture.at:555: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 10000 ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: memory exhausted memory exhausted ./torture.at:555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: cat stderr ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none stderr: 619. existing.at:808: testing GNU Cim Grammar: LALR(1) ... input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token "number" (1.9: 1) Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token "number" (1.11: 2) Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: | (- *) + (1 2) = 1 ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./calc.at:1491: $PREPARSER ./calc input memory exhausted memory exhausted input: 615. torture.at:531: ok | | +1 ./calc.at:1492: $PREPARSER ./calc input stderr: ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1494: cat stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (- *) + (1 2) = 1 ./calc.at:1494: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: cat stderr ./calc.at:1492: cat stderr ./calc.at:1492: $PREPARSER ./calc /dev/null ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token "number" (1.10: 1) Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token "number" (1.12: 2) Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token "number" (1.17: 1) Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: stdout: | (* *) + (*) + (*) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:74: $PREPARSER ./input ./existing.at:74: sed -n 's/^State //p' input.output | tail -1 ./calc.at:1491: $PREPARSER ./calc input stderr: stderr: 620. existing.at:808: testing GNU Cim Grammar: IELR(1) ... syntax error, unexpected '*', expecting NEWLINE or '{' or ';' ./existing.at:74: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) ./calc.at:1494: cat stderr ./existing.at:74: sed 's/^%define lr.type .*$//' input.y > input-lalr.y ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 616. existing.at:74: ok ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y stderr: input: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (* *) + (*) + (*) ./calc.at:1494: $PREPARSER ./calc input stderr: ./calc.at:1492: cat stderr ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1491: cat stderr ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: input: ./calc.at:1494: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. (eof || $. == 1) && /^\s*$/ # No trailing space. || /\s$/ # No tabs. || /\t/ )' calc.cc calc.hh ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 input: ./calc.at:1492: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1491: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | | -1^2 = -1 | (-1)^2 = 1 | | ---1 = -1 | | 1 - 2 - 3 = -4 | 1 - (2 - 3) = 2 | | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1494: $PREPARSER ./calc input ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (14.1: ) Entering state 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1494: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: 621. existing.at:808: testing GNU Cim Grammar: Canonical LR(1) ... stdout: stderr: input: stderr: input-lalr.y: warning: 65 shift/reduce conflicts [-Wconflicts-sr] input-lalr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y input: ./torture.at:238: $PREPARSER ./input Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) -> $$ = nterm exp (1.1-13: 7) Entering state 8 Next token is token '\n' (1.14-2.0: ) Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 20 Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 21 Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Reading a token Next token is token '=' (2.12: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 30 Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) -> $$ = nterm exp (2.5-10: -6) Entering state 29 Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) -> $$ = nterm exp (2.1-10: -5) Entering state 8 Next token is token '=' (2.12: ) Shifting token '=' (2.12: ) Entering state 18 Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 27 Next token is token '\n' (2.16-3.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) -> $$ = nterm exp (2.1-15: -5) Entering state 8 Next token is token '\n' (2.16-3.0: ) Shifting token '\n' (2.16-3.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) Entering state 6 Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 23 Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 32 Reading a token Next token is token '=' (4.6: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) -> $$ = nterm exp (4.2-4: 1) Entering state 10 Next token is token '=' (4.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) Entering state 8 Next token is token '=' (4.6: ) Shifting token '=' (4.6: ) Entering state 18 Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 27 Next token is token '\n' (4.10-5.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Reading a token Next token is token ')' (5.4: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) Entering state 12 Next token is token ')' (5.4: ) Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 23 Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 32 Reading a token Next token is token '=' (5.8: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) -> $$ = nterm exp (5.1-6: 1) Entering state 8 Next token is token '=' (5.8: ) Shifting token '=' (5.8: ) Entering state 18 Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 27 Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) -> $$ = nterm exp (5.1-10: 1) Entering state 8 Next token is token '\n' (5.11-6.0: ) Shifting token '\n' (5.11-6.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) Entering state 6 Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) Entering state 6 Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Reading a token Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Next token is token '=' (7.6: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) Entering state 8 Next token is token '=' (7.6: ) Shifting token '=' (7.6: ) Entering state 18 Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 27 Next token is token '\n' (7.10-8.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) -> $$ = nterm exp (7.1-9: -1) Entering state 8 Next token is token '\n' (7.10-8.0: ) Shifting token '\n' (7.10-8.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) Entering state 6 Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 19 Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 28 Reading a token Next token is token '-' (9.7: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) -> $$ = nterm exp (9.1-5: -1) Entering state 8 Next token is token '-' (9.7: ) Shifting token '-' (9.7: ) Entering state 19 Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 28 Reading a token Next token is token '=' (9.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) -> $$ = nterm exp (9.1-9: -4) Entering state 8 Next token is token '=' (9.11: ) Shifting token '=' (9.11: ) Entering state 18 Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 11 (line 102): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 27 Next token is token '\n' (9.15-10.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) -> $$ = nterm exp (9.1-14: -4) Entering state 8 Next token is token '\n' (9.15-10.0: ) Shifting token '\n' (9.15-10.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 19 Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 19 Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) -> $$ = nterm exp (10.6-10: -1) Entering state 12 Next token is token ')' (10.11: ) Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token Next token is token '=' (10.13: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) -> $$ = nterm exp (10.1-11: 2) Entering state 8 Next token is token '=' (10.13: ) Shifting token '=' (10.13: ) Entering state 18 Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) -> $$ = nterm exp (10.1-15: 2) Entering state 8 Next token is token '\n' (10.16-11.0: ) Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 23 Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 32 Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 23 Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 32 Reading a token Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) -> $$ = nterm exp (12.3-5: 8) Entering state 32 Next token is token '=' (12.7: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) -> $$ = nterm exp (12.1-5: 256) Entering state 8 Next token is token '=' (12.7: ) Shifting token '=' (12.7: ) Entering state 18 Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 27 Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) -> $$ = nterm exp (12.1-11: 256) Entering state 8 Next token is token '\n' (12.12-13.0: ) Shifting token '\n' (12.12-13.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) Entering state 6 Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 23 Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 32 Reading a token Next token is token ')' (13.5: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) -> $$ = nterm exp (13.2-4: 4) Entering state 12 Next token is token ')' (13.5: ) Shifting token ')' (13.5: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) -> $$ = nterm exp (13.1-5: 4) Entering state 8 Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 23 Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 32 Reading a token Next token is token '=' (13.9: ) Reducing stack 0 by rule 12 (line 103): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) -> $$ = nterm exp (13.1-7: 64) Entering state 8 Next token is token '=' (13.9: ) Shifting token '=' (13.9: ) Entering state 18 Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 27 Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) -> $$ = nterm exp (13.1-12: 64) Entering state 8 Next token is token '\n' (13.13-14.0: ) Shifting token '\n' (13.13-14.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 17 Reducing stack 0 by rule 2 (line 70): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (14.1: ) Entering state 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stdout: | 1 + 2 * 3 + !- ++ ./calc.at:1491: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./existing.at:74: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' ./calc.at:1494: $PREPARSER ./calc input stderr: stderr: | 1 2 ./torture.at:238: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1492: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token number (1.3: 2) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token number (1.3: 2) 605. torture.at:216: ok stderr: ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror stderr: ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./existing.at:74: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: input: ./calc.at:1494: cat stderr | (!!) + (1 2) = 1 ./calc.at:1492: $PREPARSER ./calc input | 1 + 2 * 3 + !- ++ ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) input: ./calc.at:1491: cat stderr | 1//2 ./calc.at:1494: $PREPARSER ./calc input ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (#) + (#) = 2222 ./calc.at:1491: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '/' (1.2: ) Shifting token '/' (1.2: ) Entering state 22 Reading a token Next token is token '/' (1.3: ) 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: cat stderr ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 622. existing.at:1460: testing GNU pic (Groff 1.18.1) Grammar: LALR(1) ... ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stderr: ./calc.at:1494: cat stderr ./calc.at:1494: cat stderr input.y:128.18: error: empty rule without %empty [-Werror=empty-rule] input.y:137.18: error: empty rule without %empty [-Werror=empty-rule] input.y:142.18: error: empty rule without %empty [-Werror=empty-rule] input.y:161.18: error: empty rule without %empty [-Werror=empty-rule] input.y:179.18: error: empty rule without %empty [-Werror=empty-rule] input.y:205.18: error: empty rule without %empty [-Werror=empty-rule] input.y:213.18: error: empty rule without %empty [-Werror=empty-rule] input.y:225.18: error: empty rule without %empty [-Werror=empty-rule] input.y:292.18: error: empty rule without %empty [-Werror=empty-rule] input.y:294.20: error: empty rule without %empty [-Werror=empty-rule] input.y:367.18: error: empty rule without %empty [-Werror=empty-rule] input.y:373.18: error: empty rule without %empty [-Werror=empty-rule] input.y:387.18: error: empty rule without %empty [-Werror=empty-rule] input.y:401.18: error: empty rule without %empty [-Werror=empty-rule] input.y:413.18: error: empty rule without %empty [-Werror=empty-rule] input.y:443.18: error: empty rule without %empty [-Werror=empty-rule] input.y:471.18: error: empty rule without %empty [-Werror=empty-rule] input.y:474.18: error: empty rule without %empty [-Werror=empty-rule] input.y:489.18: error: empty rule without %empty [-Werror=empty-rule] input.y:506.18: error: empty rule without %empty [-Werror=empty-rule] input.y:587.18: error: empty rule without %empty [-Werror=empty-rule] input.y:591.18: error: empty rule without %empty [-Werror=empty-rule] input.y: error: 78 shift/reduce conflicts [-Werror=conflicts-sr] input.y: error: 10 reduce/reduce conflicts [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:72.1-5: error: useless associativity for HQUA, use %precedence [-Werror=precedence] input.y:53.1-6: error: useless associativity for HASSIGN, use %precedence [-Werror=precedence] input.y:54.1-5: error: useless associativity for HORELSE, use %precedence [-Werror=precedence] input.y:55.1-5: error: useless associativity for HANDTHEN, use %precedence [-Werror=precedence] input.y:61.1-5: error: useless associativity for HNOT, use %precedence [-Werror=precedence] input.y:68.1-5: error: useless associativity for UNEAR, use %precedence [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] input: stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 | (- *) + (1 2) = 1 input: ./calc.at:1492: $PREPARSER ./calc input stdout: | error ./calc.at:1494: $PREPARSER ./calc input input: stderr: ./torture.at:141: $PREPARSER ./input stderr: | (#) + (#) = 2222 stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) ./existing.at:808: sed 's,.*/$,,' stderr 1>&2 ./calc.at:1494: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1491: cat stderr stderr: ./torture.at:141: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: 604. torture.at:132: ok stderr: Starting parse Entering state 0 Reading a token Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) | (1 + #) = 1111 stderr: ./calc.at:1491: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token "number" (1.13-16: 2222) Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: cat stderr ./calc.at:1494: cat stderr ./calc.at:1492: cat stderr input: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: | 1 = 2 = 3 ./calc.at:1494: $PREPARSER ./calc input input: stdout: input: ./calc.at:1491: cat stderr ./existing.at:74: $PREPARSER ./input stderr: | (1 + #) = 1111 | (* *) + (*) + (*) ./calc.at:1492: $PREPARSER ./calc input stderr: ./calc.at:1494: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) stderr: stderr: ./existing.at:74: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) | (# + 1) = 1111 ./calc.at:1491: $PREPARSER ./calc input 623. existing.at:1460: testing GNU pic (Groff 1.18.1) Grammar: IELR(1) ... Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stderr: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '=' (1.3: ) Shifting token '=' (1.3: ) Entering state 18 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 27 Reading a token Next token is token '=' (1.7: ) 1.7: syntax error, unexpected '=' Error: popping nterm exp (1.5: 2) Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input.y:66.10: error: empty rule without %empty [-Werror=empty-rule] input.y:170.10: error: empty rule without %empty [-Werror=empty-rule] input.y:175.10: error: empty rule without %empty [-Werror=empty-rule] input.y:180.10: error: empty rule without %empty [-Werror=empty-rule] input.y:188.10: error: empty rule without %empty [-Werror=empty-rule] input.y:202.10: error: empty rule without %empty [-Werror=empty-rule] input.y:207.10: error: empty rule without %empty [-Werror=empty-rule] input.y:221.10: error: empty rule without %empty [-Werror=empty-rule] input.y:300.10: error: empty rule without %empty [-Werror=empty-rule] input.y:323.10: error: empty rule without %empty [-Werror=empty-rule] input.y: error: 265 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:39.1-5: error: useless associativity for FUNC_CALL, use %precedence [-Werror=precedence] input.y:44.1-5: error: useless associativity for YNUMBER, use %precedence [-Werror=precedence] input.y:44.1-5: error: useless associativity for YSTRING, use %precedence [-Werror=precedence] input.y:42.1-9: error: useless precedence and associativity for APPEND_OP [-Werror=precedence] input.y:33.1-6: error: useless associativity for ASSIGNOP, use %precedence [-Werror=precedence] input.y:43.1-5: error: useless associativity for CONCAT_OP, use %precedence [-Werror=precedence] input.y:37.1-5: error: useless precedence and associativity for LEX_GETLINE [-Werror=precedence] input.y:38.1-9: error: useless associativity for LEX_IN, use %precedence [-Werror=precedence] input.y:49.1-5: error: useless associativity for INCREMENT, use %precedence [-Werror=precedence] input.y:49.1-5: error: useless associativity for DECREMENT, use %precedence [-Werror=precedence] input.y:39.1-5: error: useless associativity for LEX_BUILTIN, use %precedence [-Werror=precedence] input.y:39.1-5: error: useless associativity for LEX_LENGTH, use %precedence [-Werror=precedence] input.y:40.1-9: error: useless precedence and associativity for ',' [-Werror=precedence] input.y:47.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] input.y:47.1-6: error: useless associativity for UNARY, use %precedence [-Werror=precedence] input.y:50.1-5: error: useless associativity for '$', use %precedence [-Werror=precedence] input.y:51.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] input.y:51.1-5: error: useless precedence and associativity for ')' [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] 617. existing.at:74: ok input.y:128.18: error: empty rule without %empty [-Werror=empty-rule] input.y:137.18: error: empty rule without %empty [-Werror=empty-rule] input.y:142.18: error: empty rule without %empty [-Werror=empty-rule] input.y:161.18: error: empty rule without %empty [-Werror=empty-rule] input.y:179.18: error: empty rule without %empty [-Werror=empty-rule] input.y:205.18: error: empty rule without %empty [-Werror=empty-rule] input.y:213.18: error: empty rule without %empty [-Werror=empty-rule] input.y:225.18: error: empty rule without %empty [-Werror=empty-rule] input.y:292.18: error: empty rule without %empty [-Werror=empty-rule] input.y:294.20: error: empty rule without %empty [-Werror=empty-rule] input.y:367.18: error: empty rule without %empty [-Werror=empty-rule] input.y:373.18: error: empty rule without %empty [-Werror=empty-rule] input.y:387.18: error: empty rule without %empty [-Werror=empty-rule] input.y:401.18: error: empty rule without %empty [-Werror=empty-rule] input.y:413.18: error: empty rule without %empty [-Werror=empty-rule] input.y:443.18: error: empty rule without %empty [-Werror=empty-rule] input.y:471.18: error: empty rule without %empty [-Werror=empty-rule] input.y:474.18: error: empty rule without %empty [-Werror=empty-rule] input.y:489.18: error: empty rule without %empty [-Werror=empty-rule] input.y:506.18: error: empty rule without %empty [-Werror=empty-rule] input.y:587.18: error: empty rule without %empty [-Werror=empty-rule] input.y:591.18: error: empty rule without %empty [-Werror=empty-rule] input.y: error: 78 shift/reduce conflicts [-Werror=conflicts-sr] input.y: error: 10 reduce/reduce conflicts [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:72.1-5: error: useless associativity for HQUA, use %precedence [-Werror=precedence] input.y:53.1-6: error: useless associativity for HASSIGN, use %precedence [-Werror=precedence] input.y:54.1-5: error: useless associativity for HORELSE, use %precedence [-Werror=precedence] input.y:55.1-5: error: useless associativity for HANDTHEN, use %precedence [-Werror=precedence] input.y:61.1-5: error: useless associativity for HNOT, use %precedence [-Werror=precedence] input.y:68.1-5: error: useless associativity for UNEAR, use %precedence [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] stderr: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./existing.at:74: sed 's,.*/$,,' stderr 1>&2 ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./existing.at:808: sed 's,.*/$,,' stderr 1>&2 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: cat stderr ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error ./calc.at:1494: cat stderr ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | | +1 ./calc.at:1494: $PREPARSER ./calc input ./calc.at:1492: cat stderr stderr: input: ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) | (# + 1) = 1111 ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1494: $PREPARSER ./calc input | 1 + 2 * 3 + !+ ++ input: stderr: ./calc.at:1492: $PREPARSER ./calc input | (1 + # + 1) = 1111 ./calc.at:1491: $PREPARSER ./calc input stderr: 624. existing.at:1460: testing GNU pic (Groff 1.18.1) Grammar: Canonical LR(1) ... ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token '\n' (1.1-2.0: ) Shifting token '\n' (1.1-2.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Next token is token '+' (2.1: ) 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none stderr: stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token "number" (1.6: 1) Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token "number" (1.11-14: 1111) Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | 1 + 2 * 3 + !- ++ ./calc.at:1492: $PREPARSER ./calc input stderr: ./calc.at:1494: cat stderr ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: $PREPARSER ./calc /dev/null ./calc.at:1491: cat stderr stderr: ./calc.at:1494: cat stderr Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: | (1 + # + 1) = 1111 ./calc.at:1494: $PREPARSER ./calc input | (1 + 1) / (1 - 1) ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1491: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input.y:202.20: error: empty rule without %empty [-Werror=empty-rule] input.y:270.7: error: empty rule without %empty [-Werror=empty-rule] input.y:292.13: error: empty rule without %empty [-Werror=empty-rule] input.y:309.18: error: empty rule without %empty [-Werror=empty-rule] input.y:382.14: error: empty rule without %empty [-Werror=empty-rule] input.y:471.11-48: error: rule useless in parser due to conflicts [-Werror=other] input.y:154.1-5: error: useless associativity for LABEL, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for VARIABLE, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for NUMBER, use %precedence [-Werror=precedence] input.y:141.1-5: error: useless associativity for TEXT, use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for ORDINAL, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for LAST, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for UP, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for DOWN, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for BOX, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for CIRCLE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ELLIPSE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ARC, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for LINE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ARROW, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for SPLINE, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for HEIGHT, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for RADIUS, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for WIDTH, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for DIAMETER, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for FROM, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for TO, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for AT, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for SOLID [-Werror=precedence] input.y:153.1-5: error: useless associativity for DOTTED, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for DASHED, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for CHOP, use %precedence [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for LJUST [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for RJUST [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for ABOVE [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for BELOW [-Werror=precedence] input.y:176.1-5: error: useless associativity for OF, use %precedence [-Werror=precedence] input.y:176.1-5: error: useless associativity for BETWEEN, use %precedence [-Werror=precedence] input.y:177.1-5: error: useless associativity for AND, use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for HERE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_N, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_E, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_W, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_S, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_NE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_SE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_NW, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_SW, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_C, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for DOT_START, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for DOT_END, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SIN, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for COS, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for ATAN2, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for LOG, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for EXP, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SQRT, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for K_MAX, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for K_MIN, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for INT, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for RAND, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SRAND, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for TOP, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for BOTTOM, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for UPPER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for LOWER, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for LEFT_CORNER, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for RIGHT_CORNER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for NORTH, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for SOUTH, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for EAST, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for WEST, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for CENTER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for END, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for START, use %precedence [-Werror=precedence] input.y:140.1-5: error: useless associativity for PLOT, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for THICKNESS, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for FILL, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for COLORED [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for OUTLINED [-Werror=precedence] input.y:141.1-5: error: useless associativity for SPRINTF, use %precedence [-Werror=precedence] input.y:137.1-5: error: useless associativity for '.', use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for '`', use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for '[', use %precedence [-Werror=precedence] input.y:170.1-5: error: useless associativity for ',', use %precedence [-Werror=precedence] input.y:181.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: cat stderr ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1494: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror ./existing.at:1460: sed 's,.*/$,,' stderr 1>&2 Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token "number" (1.10: 1) Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token "number" (1.15-18: 1111) Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: | (#) + (#) = 2222 ./calc.at:1492: $PREPARSER ./calc input input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1494: $PREPARSER ./calc input ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: cat stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 20 Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) -> $$ = nterm exp (1.7-11: 2) Entering state 12 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) -> $$ = nterm exp (1.7-15: 3) Entering state 12 Next token is token '+' (1.17: ) Shifting token '+' (1.17: ) Entering state 20 Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' (1.17: ) Error: popping nterm exp (1.7-15: 3) Shifting token error (1.7-18: ) Entering state 11 Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) -> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) -> $$ = nterm exp (1.1-18: 2222) Entering state 8 Next token is token '+' (1.20: ) Shifting token '+' (1.20: ) Entering state 20 Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.23: ) Entering state 11 Next token is token '*' (1.23: ) Error: discarding token '*' (1.23: ) Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) Reading a token Next token is token ')' (1.28: ) Entering state 11 Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) -> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) -> $$ = nterm exp (1.1-28: 3333) Entering state 8 Next token is token '+' (1.30: ) Shifting token '+' (1.30: ) Entering state 20 Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 21 Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) -> $$ = nterm exp (1.33-37: 2) Entering state 12 Next token is token '*' (1.39: ) Shifting token '*' (1.39: ) Entering state 21 Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' (1.39: ) Error: popping nterm exp (1.33-37: 2) Shifting token error (1.33-41: ) Entering state 11 Next token is token '*' (1.41: ) Error: discarding token '*' (1.41: ) Reading a token Next token is token ')' (1.42: ) Entering state 11 Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) -> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) -> $$ = nterm exp (1.1-42: 4444) Entering state 8 Next token is token '=' (1.44: ) Shifting token '=' (1.44: ) Entering state 18 Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -> $$ = nterm exp (1.1-46: 4444) Entering state 8 Next token is token '\n' (1.47-2.0: ) Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 566. calc.at:1491: ok ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: | (1 + 1) / (1 - 1) ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./calc.at:1494: $PREPARSER ./calc input ./calc.at:1492: cat stderr ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: cat stderr input: | (1 + #) = 1111 ./calc.at:1492: $PREPARSER ./calc input ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token "number" (1.2: 1) Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token "number" (1.6: 1) Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token "number" (1.12: 1) Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token "end of input" (2.1: ) Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 ./calc.at:1494: $PREPARSER ./calc input stderr: ./existing.at:808: sed -n 's/^State //p' input.output | tail -1 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 625. regression.at:25: testing Trivial grammars ... ./regression.at:43: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: ./calc.at:1494: cat stderr ./existing.at:808: sed 's/^%define lr.type .*$//' input.y > input-lalr.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 15 Reducing stack 0 by rule 16 (line 107): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) Entering state 11 Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 20 Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 Next token is token number (1.11: 2) Error: discarding token number (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) -> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) -> $$ = nterm exp (1.1-12: 2222) Entering state 8 Next token is token '=' (1.14: ) Shifting token '=' (1.14: ) Entering state 18 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: cat stderr ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 569. calc.at:1494: ok input: ./calc.at:1494: cat stderr | (# + 1) = 1111 ./calc.at:1492: $PREPARSER ./calc input stderr: ./regression.at:44: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1494: $PREPARSER ./calc input stderr: ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none stderr: input.y:202.20: error: empty rule without %empty [-Werror=empty-rule] input.y:270.7: error: empty rule without %empty [-Werror=empty-rule] input.y:292.13: error: empty rule without %empty [-Werror=empty-rule] input.y:309.18: error: empty rule without %empty [-Werror=empty-rule] input.y:382.14: error: empty rule without %empty [-Werror=empty-rule] input.y:471.11-48: error: rule useless in parser due to conflicts [-Werror=other] input.y:154.1-5: error: useless associativity for LABEL, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for VARIABLE, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for NUMBER, use %precedence [-Werror=precedence] input.y:141.1-5: error: useless associativity for TEXT, use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for ORDINAL, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for LAST, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for UP, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for DOWN, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for BOX, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for CIRCLE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ELLIPSE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ARC, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for LINE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ARROW, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for SPLINE, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for HEIGHT, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for RADIUS, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for WIDTH, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for DIAMETER, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for FROM, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for TO, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for AT, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for SOLID [-Werror=precedence] input.y:153.1-5: error: useless associativity for DOTTED, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for DASHED, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for CHOP, use %precedence [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for LJUST [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for RJUST [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for ABOVE [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for BELOW [-Werror=precedence] input.y:176.1-5: error: useless associativity for OF, use %precedence [-Werror=precedence] input.y:176.1-5: error: useless associativity for BETWEEN, use %precedence [-Werror=precedence] input.y:177.1-5: error: useless associativity for AND, use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for HERE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_N, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_E, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_W, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_S, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_NE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_SE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_NW, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_SW, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_C, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for DOT_START, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for DOT_END, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SIN, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for COS, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for ATAN2, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for LOG, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for EXP, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SQRT, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for K_MAX, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for K_MIN, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for INT, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for RAND, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SRAND, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for TOP, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for BOTTOM, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for UPPER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for LOWER, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for LEFT_CORNER, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for RIGHT_CORNER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for NORTH, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for SOUTH, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for EAST, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for WEST, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for CENTER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for END, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for START, use %precedence [-Werror=precedence] input.y:140.1-5: error: useless associativity for PLOT, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for THICKNESS, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for FILL, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for COLORED [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for OUTLINED [-Werror=precedence] input.y:141.1-5: error: useless associativity for SPRINTF, use %precedence [-Werror=precedence] input.y:137.1-5: error: useless associativity for '.', use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for '`', use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for '[', use %precedence [-Werror=precedence] input.y:170.1-5: error: useless associativity for ',', use %precedence [-Werror=precedence] input.y:181.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:1460: sed 's,.*/$,,' stderr 1>&2 stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 Reducing stack 0 by rule 15 (line 106): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) Entering state 11 Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 Next token is token number (1.12: 2) Error: discarding token number (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) -> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) -> $$ = nterm exp (1.1-13: 2222) Entering state 8 Next token is token '=' (1.15: ) Shifting token '=' (1.15: ) Entering state 18 Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -> $$ = nterm exp (1.1-17: 2222) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 626. regression.at:55: testing YYSTYPE typedef ... ./regression.at:73: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./calc.at:1492: cat stderr ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 input: ./calc.at:1494: cat stderr | (1 + # + 1) = 1111 ./calc.at:1492: $PREPARSER ./calc input ./regression.at:74: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c stderr: stderr: input: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stdout: | (* *) + (*) + (*) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: $PREPARSER ./calc input ./regression.at:45: $CC $CFLAGS $CPPFLAGS -c -o input.o -DYYDEBUG -c input.c stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Next token is token '*' (1.2: ) Error: discarding token '*' (1.2: ) Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token Next token is token ')' (1.5: ) Entering state 11 Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 20 Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.10: ) Entering state 11 Next token is token '*' (1.10: ) Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) -> $$ = nterm exp (1.1-11: 2222) Entering state 8 Next token is token '+' (1.13: ) Shifting token '+' (1.13: ) Entering state 20 Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.16: ) Entering state 11 Next token is token '*' (1.16: ) Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) -> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: stdout: 626. regression.at:55: ok ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1492: cat stderr ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./calc.at:1494: cat stderr input: ./torture.at:394: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS | (1 + 1) / (1 - 1) ./calc.at:1492: $PREPARSER ./calc input input: stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1494: $PREPARSER ./calc input ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input-lalr.y: warning: 78 shift/reduce conflicts [-Wconflicts-sr] input-lalr.y: warning: 10 reduce/reduce conflicts [-Wconflicts-rr] input-lalr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stdout: ./existing.at:808: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./existing.at:808: sed -n 's/^State //p' input.output | tail -1 ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./existing.at:808: grep '^State.*conflicts:' input.output stderr: ./existing.at:808: sed 's/^%define lr.type .*$//' input.y > input-lalr.y ./calc.at:1492: cat stderr Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 Reducing stack 0 by rule 17 (line 108): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./existing.at:808: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS input: 568. calc.at:1492: ok 627. regression.at:85: testing Early token definitions with --yacc ... | 1 + 2 * 3 + !- ++ ./calc.at:1494: $PREPARSER ./calc input ./regression.at:115: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --yacc -o input.c input.y ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: 625. regression.at:25: ok stderr: Starting parse Entering state 0 Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 20 Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 21 Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Next token is token '+' (1.11: ) Shifting token '+' (1.11: ) Entering state 20 Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./regression.at:116: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: cat stderr input: 628. regression.at:127: testing Early token definitions without --yacc ... ./regression.at:161: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y | (#) + (#) = 2222 ./calc.at:1494: $PREPARSER ./calc input ./existing.at:1460: sed -n 's/^State //p' input.output | tail -1 stderr: 629. regression.at:173: testing Braces parsing ... Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./regression.at:185: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./existing.at:1460: sed 's/^%define lr.type .*$//' input.y > input-lalr.y stderr: stderr: stderr: input-lalr.y: warning: 78 shift/reduce conflicts [-Wconflicts-sr] input-lalr.y: warning: 10 reduce/reduce conflicts [-Wconflicts-rr] input-lalr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stdout: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token ')' (1.3: ) Entering state 11 Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) -> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token Next token is token '+' (1.5: ) Shifting token '+' (1.5: ) Entering state 20 Reading a token Next token is token '(' (1.7: ) Shifting token '(' (1.7: ) Entering state 4 Reading a token 1.8: syntax error: invalid character: '#' Next token is token error (1.8: ) Shifting token error (1.8: ) Entering state 11 Next token is token error (1.8: ) Error: discarding token error (1.8: ) Reading a token Next token is token ')' (1.9: ) Entering state 11 Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) -> $$ = nterm exp (1.7-9: 1111) Entering state 29 Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) -> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token Next token is token number (1.13-16: 2222) Shifting token number (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: ./existing.at:808: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' ./regression.at:162: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./regression.at:187: grep 'tests = {{{{{{{{{{}}}}}}}}}};' input.c stdout: stdout: ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y { tests = {{{{{{{{{{}}}}}}}}}}; } stdout: 629. regression.at:173: ok ./existing.at:808: $PREPARSER ./input 627. regression.at:85: ok ./existing.at:808: grep '^State.*conflicts:' input.output stderr: ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./existing.at:808: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:808: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./calc.at:1494: cat stderr 619. existing.at:808: ok input: | (1 + #) = 1111 ./calc.at:1494: $PREPARSER ./calc input ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 630. regression.at:196: testing Rule Line Numbers ... ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 631. regression.at:345: testing Mixing %token styles ... ./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -Wall -o input.c input.y ./regression.at:232: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -v input.y stderr: stdout: 632. regression.at:437: testing Token definitions: parse.error=detailed ... ./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o input.c input.y stderr: 628. regression.at:127: ok Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./calc.at:1494: cat stderr stderr: ./regression.at:235: cat input.output ./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -Wall -o input.c input.y -Werror ./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Werror input-lalr.y:471.11-48: warning: rule useless in parser due to conflicts [-Wother] stdout: ./existing.at:1460: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' input: | (# + 1) = 1111 ./calc.at:1494: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 630. regression.at:196: ok stderr: ./existing.at:1460: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 18 Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) -> $$ = nterm exp (1.1-14: 1111) Entering state 8 Next token is token '\n' (1.15-2.0: ) Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: input.y:3.1-5: error: useless precedence and associativity for "||" [-Werror=precedence] input.y:3.1-5: error: useless precedence and associativity for "<=" [-Werror=precedence] stderr: ./regression.at:357: sed 's,.*/$,,' stderr 1>&2 stdout: stderr: ./existing.at:808: $PREPARSER ./input input.y:26.8-14: error: symbol SPECIAL redeclared [-Werror=other] 26 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" | ^~~~~~~ input.y:25.8-14: note: previous declaration 25 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" | ^~~~~~~ input.y:26.16-63: error: symbol "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" used more than once as a literal string [-Werror=other] 26 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ stderr: 633. regression.at:438: testing Token definitions: parse.error=verbose ... ./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o input.c input.y ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./existing.at:808: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./existing.at:1460: sed -n 's/^State //p' input.output | tail -1 ./calc.at:1494: cat stderr ./regression.at:437: sed 's,.*/$,,' stderr 1>&2 ./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -Wall -o input.c input.y --warnings=error 620. existing.at:808: ok ./existing.at:1460: sed 's/^%define lr.type .*$//' input.y > input-lalr.y input: ./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=error | (1 + # + 1) = 1111 ./calc.at:1494: $PREPARSER ./calc input stderr: ./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Werror ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) 634. regression.at:447: testing Characters Escapes ... ./regression.at:465: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -Wall -o input.c input.y -Wnone,none -Werror --trace=none input.y:26.8-14: error: symbol SPECIAL redeclared [-Werror=other] 26 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" | ^~~~~~~ input.y:25.8-14: note: previous declaration 25 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" | ^~~~~~~ input.y:26.16-63: error: symbol "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" used more than once as a literal string [-Werror=other] 26 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ stderr: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token 1.6: syntax error: invalid character: '#' Next token is token error (1.6: ) Error: popping token '+' (1.4: ) Error: popping nterm exp (1.2: 1) Shifting token error (1.2-6: ) Entering state 11 Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 18 Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) -> $$ = nterm exp (1.1-18: 1111) Entering state 8 Next token is token '\n' (1.19-2.0: ) Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./regression.at:466: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Wnone,none -Werror --trace=none ./regression.at:438: sed 's,.*/$,,' stderr 1>&2 ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 ./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=none -Werror --trace=none ./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -Wall -o input.c input.y --warnings=none -Werror --trace=none ./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=error 635. regression.at:480: testing Web2c Report ... ./regression.at:505: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v input.y ./calc.at:1494: cat stderr input: ./regression.at:506: cat input.output | (1 + 1) / (1 - 1) ./calc.at:1494: $PREPARSER ./calc input stderr: ./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Wnone,none -Werror --trace=none 635. regression.at:480: 631. regression.at:345: ok ok Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./regression.at:437: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: stderr: 634. regression.at:447: ok stdout: Starting parse Entering state 0 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 20 Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) -> $$ = nterm exp (1.2-6: 2) Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 22 Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 19 Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Reading a token Next token is token ')' (1.17: ) Reducing stack 0 by rule 8 (line 91): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) -> $$ = nterm exp (1.12-16: 0) Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) -> $$ = nterm exp (1.11-17: 0) Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 10 (line 93): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) 1.11-17: error: null divisor -> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. Shifting token end of input (2.1: ) Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./existing.at:1460: $PREPARSER ./input ./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=none -Werror --trace=none ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; my @exps = $2 =~ /\[(.*?)\]/g; ($#exps && $#exps < 4) ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 stderr: syntax error, unexpected LEFT ./existing.at:1460: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: cat stderr 570. calc.at:1494: ok 622. existing.at:1460: ok ./regression.at:438: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 636. regression.at:661: testing Web2c Actions ... ./regression.at:674: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y 637. regression.at:812: testing Useless Tokens ... ./regression.at:912: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -o input.c input.y 638. regression.at:1143: testing Dancer ... ./regression.at:1143: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o dancer.c dancer.y 640. regression.at:1145: testing Dancer lalr1.cc ... ./regression.at:1145: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o dancer.cc dancer.y ./regression.at:679: cat tables.c stderr: stdout: ./regression.at:437: $PREPARSER ./input stderr: 639. regression.at:1144: testing Dancer %glr-parser ... 636. regression.at:661: ok syntax error, unexpected a, expecting ∃¬∩∪∀ ./regression.at:1144: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o dancer.c dancer.y ./regression.at:437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input-lalr.y:471.11-48: warning: rule useless in parser due to conflicts [-Wother] stdout: 632. regression.at:437: ok ./existing.at:1460: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' ./regression.at:1143: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o dancer dancer.c $LIBS ./regression.at:1145: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o dancer dancer.cc $LIBS ./regression.at:1144: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o dancer dancer.c $LIBS ./existing.at:1460: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror ./regression.at:917: cat tables.c 641. regression.at:1220: testing Expecting two tokens ... ./regression.at:1220: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o expect2.c expect2.y 642. regression.at:1221: testing Expecting two tokens %glr-parser ... 637. regression.at:812: ok ./regression.at:1221: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o expect2.c expect2.y stderr: stdout: ./regression.at:438: $PREPARSER ./input stderr: syntax error, unexpected a, expecting "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" ./regression.at:438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1221: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o expect2 expect2.c $LIBS ./regression.at:1220: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o expect2 expect2.c $LIBS 633. regression.at:438: ok ./existing.at:74: sed -n 's/^State //p' input.output | tail -1 643. regression.at:1222: testing Expecting two tokens lalr1.cc ... ./regression.at:1222: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o expect2.cc expect2.y ./existing.at:74: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./regression.at:1143: $PREPARSER ./dancer stderr: syntax error, unexpected ':' ./regression.at:1143: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1222: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o expect2 expect2.cc $LIBS 644. regression.at:1230: testing Braced code in declaration in rules section ... ./regression.at:1261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 638. regression.at:1143: ok stderr: stdout: ./regression.at:1262: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./existing.at:1460: $PREPARSER ./input stderr: ./existing.at:1460: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 623. existing.at:1460: ok 645. regression.at:1291: testing String alias declared after use ... ./regression.at:1304: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: ./regression.at:1220: $PREPARSER ./expect2 stderr: syntax error, unexpected '+', expecting A or B ./regression.at:1220: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 645. regression.at:1291: ok 641. regression.at:1220: ok 646. regression.at:1314: testing Extra lookahead sets in report ... ./regression.at:1329: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all input.y ./regression.at:1330: sed -n '/^State 1$/,/^State 2$/p' input.output 646. regression.at:1314: ok 648. regression.at:1408: testing parse-gram.y: LALR = IELR ... ./regression.at:1414: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -Dlr.type=lalr input.y 647. regression.at:1355: testing Token number in precedence declaration ... ./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall -o input.c input.y ./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y -Werror stderr: 649. regression.at:1430: testing parse.error=verbose and YYSTACK_USE_ALLOCA ... ./regression.at:1481: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y input.y:24.5-19: error: rule useless in parser due to conflicts [-Werror=other] input.y:28.5-19: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.1-5: error: useless precedence and associativity for TK1 [-Werror=precedence] ./regression.at:1388: sed 's,.*/$,,' stderr 1>&2 stderr: ./regression.at:1482: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: ./existing.at:74: $PREPARSER ./input stderr: ./existing.at:74: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y --warnings=error stderr: stdout: 618. existing.at:74: ok ./regression.at:1144: $PREPARSER ./dancer stderr: syntax error, unexpected ':' ./regression.at:1144: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -Dlr.type=ielr input.y 639. regression.at:1144: ok ./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y -Wnone,none -Werror --trace=none stderr: stdout: ./regression.at:1263: $PREPARSER ./input --debug stderr: stdout: stderr: ./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y --warnings=none -Werror --trace=none 650. regression.at:1504: testing parse.error=verbose overflow ... ./regression.at:1221: $PREPARSER ./expect2 stderr: ./regression.at:1604: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y Starting parse Entering state 0 Stack now 0 Reducing stack by rule 1 (line 20): -> $$ = nterm start () Entering state 1 Stack now 0 1 Reading a token Next token is token 'a' (PRINTER) syntax error, unexpected 'a', expecting end of file Error: popping nterm start () Stack now 0 Cleanup: discarding lookahead token 'a' (PRINTER) DESTRUCTOR Stack now 0 stdout: stderr: ./regression.at:1483: $PREPARSER ./input ./regression.at:1263: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error, unexpected '+', expecting A or B ./regression.at:1221: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: syntax error, unexpected 'a', expecting 123456789112345678921234567893123456789412345678951234567896123A or 123456789112345678921234567893123456789412345678951234567896123B syntax error, unexpected end of file, expecting 123456789112345678921234567893123456789412345678951234567896123A or 123456789112345678921234567893123456789412345678951234567896123B ./regression.at:1483: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 642. regression.at:1221: ok 651. regression.at:1628: testing LAC: Exploratory stack ... 644. regression.at:1230: ok ./regression.at:1713: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full \ -Dparse.lac.es-capacity-initial=1 \ -Dparse.lac.memory-trace=full -o input.c input.y 649. regression.at:1430: ok ./regression.at:1393: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./regression.at:1611: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./regression.at:1713: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 652. regression.at:1739: testing LAC: Memory exhaustion ... ./regression.at:1771: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -Dparse.lac.es-capacity-initial=1 -o input.c input.y 653. regression.at:1874: testing Lex and parse params: yacc.c ... ./regression.at:1420: diff lalr.c ielr.c ./regression.at:1874: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 648. regression.at:1408: ok 654. regression.at:1875: testing Lex and parse params: glr.c ... ./regression.at:1875: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./regression.at:1771: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./regression.at:1874: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./regression.at:1875: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: ./regression.at:1145: $PREPARSER ./dancer stderr: syntax error, unexpected ':' ./regression.at:1145: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 655. regression.at:1876: testing Lex and parse params: lalr1.cc ... ./regression.at:1876: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 640. regression.at:1145: ok ./regression.at:1876: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./regression.at:1394: $PREPARSER ./input stderr: ./regression.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input.y: In function 'yyparse': input.y:59:24: warning: format '%d' expects argument of type 'int', but argument 3 has type 'long int' [-Wformat=] 59 | fprintf (stderr, " yymsg_alloc = %d\n", yymsg_alloc); | ^~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~ | | | long int input.y:60:24: warning: format '%d' expects argument of type 'int', but argument 3 has type 'long int' [-Wformat=] 60 | fprintf (stderr, " YYSTACK_ALLOC_MAXIMUM = %d\n", | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ input.y:62:24: warning: format '%d' expects argument of type 'int', but argument 3 has type 'long int' [-Wformat=] 62 | fprintf (stderr, " YYSIZE_MAXIMUM = %d\n", YYSIZE_MAXIMUM); | ^~~~~~~~~~~~~~~~~~~~~~~~~ stdout: 656. regression.at:1877: testing Lex and parse params: glr.cc ... ./regression.at:1613: $PREPARSER ./input ./regression.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: syntax error, unexpected 'a', expecting 123456789112345678921234567893123456789412345678951234567896123A or 123456789112345678921234567893123456789412345678951234567896123B or 123456789112345678921234567893123456789412345678951234567896123C syntax error, unexpected 'd' syntax error memory exhausted 647. regression.at:1355: ok ./regression.at:1613: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 650. regression.at:1504: ok stderr: stdout: ./regression.at:1877: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./regression.at:1874: $PREPARSER ./input stderr: ./regression.at:1874: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 653. regression.at:1874: ok stderr: 657. regression.at:1878: testing Lex and parse params: glr2.cc ... stdout: ./regression.at:1222: $PREPARSER ./expect2 ./regression.at:1878: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: syntax error, unexpected '+', expecting A or B ./regression.at:1222: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 658. regression.at:1889: testing stdio.h is not needed ... ./regression.at:1906: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 643. regression.at:1222: ok ./regression.at:1878: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./regression.at:1906: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./regression.at:1713: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt 659. push.at:25: testing Memory Leak for Early Deletion ... ./push.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: ./regression.at:1713: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1713: grep 'syntax error,' stderr.txt ./regression.at:1713: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt 660. push.at:84: testing Multiple impure instances ... ./push.at:134: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./push.at:75: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./regression.at:1713: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt stderr: stdout: 658. regression.at:1889: ok stderr: ./regression.at:1713: "$PERL" -0777 -ne 'print s/\(realloc//g;' < stderr.txt ./push.at:134: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: ./regression.at:1771: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./regression.at:1714: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full \ -Dparse.lac.es-capacity-initial=1 \ -Dparse.lac.memory-trace=full -o input.c input.y stderr: input.y:202.20: error: empty rule without %empty [-Werror=empty-rule] input.y:270.7: error: empty rule without %empty [-Werror=empty-rule] input.y:292.13: error: empty rule without %empty [-Werror=empty-rule] input.y:309.18: error: empty rule without %empty [-Werror=empty-rule] input.y:382.14: error: empty rule without %empty [-Werror=empty-rule] input.y:471.11-48: error: rule useless in parser due to conflicts [-Werror=other] input.y:154.1-5: error: useless associativity for LABEL, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for VARIABLE, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for NUMBER, use %precedence [-Werror=precedence] input.y:141.1-5: error: useless associativity for TEXT, use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for ORDINAL, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for LAST, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for UP, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for DOWN, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for BOX, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for CIRCLE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ELLIPSE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ARC, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for LINE, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for ARROW, use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for SPLINE, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for HEIGHT, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for RADIUS, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for WIDTH, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for DIAMETER, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for FROM, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for TO, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for AT, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for SOLID [-Werror=precedence] input.y:153.1-5: error: useless associativity for DOTTED, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for DASHED, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for CHOP, use %precedence [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for LJUST [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for RJUST [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for ABOVE [-Werror=precedence] input.y:147.1-5: error: useless precedence and associativity for BELOW [-Werror=precedence] input.y:176.1-5: error: useless associativity for OF, use %precedence [-Werror=precedence] input.y:176.1-5: error: useless associativity for BETWEEN, use %precedence [-Werror=precedence] input.y:177.1-5: error: useless associativity for AND, use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for HERE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_N, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_E, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_W, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_S, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_NE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_SE, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_NW, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_SW, use %precedence [-Werror=precedence] input.y:166.1-5: error: useless associativity for DOT_C, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for DOT_START, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for DOT_END, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SIN, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for COS, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for ATAN2, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for LOG, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for EXP, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SQRT, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for K_MAX, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for K_MIN, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for INT, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for RAND, use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for SRAND, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for TOP, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for BOTTOM, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for UPPER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for LOWER, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for LEFT_CORNER, use %precedence [-Werror=precedence] input.y:167.1-5: error: useless associativity for RIGHT_CORNER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for NORTH, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for SOUTH, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for EAST, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for WEST, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for CENTER, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for END, use %precedence [-Werror=precedence] input.y:168.1-5: error: useless associativity for START, use %precedence [-Werror=precedence] input.y:140.1-5: error: useless associativity for PLOT, use %precedence [-Werror=precedence] input.y:162.1-5: error: useless associativity for THICKNESS, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless associativity for FILL, use %precedence [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for COLORED [-Werror=precedence] input.y:153.1-5: error: useless precedence and associativity for OUTLINED [-Werror=precedence] input.y:141.1-5: error: useless associativity for SPRINTF, use %precedence [-Werror=precedence] input.y:137.1-5: error: useless associativity for '.', use %precedence [-Werror=precedence] input.y:156.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] input.y:157.1-5: error: useless associativity for '`', use %precedence [-Werror=precedence] input.y:159.1-5: error: useless associativity for '[', use %precedence [-Werror=precedence] input.y:170.1-5: error: useless associativity for ',', use %precedence [-Werror=precedence] input.y:181.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] ./existing.at:1460: sed 's,.*/$,,' stderr 1>&2 ./regression.at:1714: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error 661. push.at:145: testing Unsupported Skeletons ... ./push.at:156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: stdout: ./push.at:76: $PREPARSER ./input stderr: ./push.at:76: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 659. push.at:25: ok 661. push.at:145: ok stderr: stdout: ./push.at:134: $PREPARSER ./input stderr: ./push.at:134: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./push.at:135: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: ./regression.at:1875: $PREPARSER ./input stderr: stderr: stdout: 662. push.at:167: testing Pstate reuse ... ./push.at:276: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./regression.at:1875: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1772: $PREPARSER ./input --debug ./push.at:135: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 654. regression.at:1875: ok 663. c++.at:26: testing C++ Locations Unit Tests ... ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: Starting parse Entering state 0 Stack now 0 Reading a token Now at end of input. LAC: initial context established for "end of file" LAC: checking lookahead "end of file": R2 G3 R2 G5 R2 G6 R2 G7 R2 G8 R2 G9 R2 G10 R2 G11 R2 (max size exceeded) memory exhausted Cleanup: discarding lookahead token "end of file" () Stack now 0 ./regression.at:1772: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./push.at:276: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./regression.at:1787: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -Dparse.lac.es-capacity-initial=1 -o input.c input.y 664. c++.at:107: testing C++ Variant-based Symbols Unit Tests ... ./regression.at:1787: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./c++.at:234: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.yy stderr: stdout: ./regression.at:1714: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt stderr: stdout: stderr: ./push.at:135: $PREPARSER ./input ======== Testing with C++ standard flags: '' ./regression.at:1714: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: ./push.at:135: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1714: grep 'syntax error,' stderr.txt stderr: stdout: 660. push.at:84: ok ./regression.at:1876: $PREPARSER ./input ./regression.at:1714: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt stderr: ./regression.at:1714: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt ./regression.at:1876: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1714: "$PERL" -0777 -ne 'print s/\(realloc//g;' < stderr.txt 655. regression.at:1876: ok stderr: stdout: ./push.at:277: ./input 662. push.at:167: ok ./regression.at:1715: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full \ -Dparse.lac.es-capacity-initial=1 \ -Dparse.lac.memory-trace=full -o input.c input.y 665. c++.at:247: testing Multiple occurrences of $n and api.value.automove ... ./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.yy ./regression.at:1715: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.yy -Werror 667. c++.at:567: testing Variants lalr1.cc parse.assert ... ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y 666. c++.at:566: testing Variants lalr1.cc ... stderr: ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y input.yy:16.33-34: error: multiple occurrences of $2 with api.value.automove [-Werror=other] 16 | | "twice" exp { $$ = $2 + $2; } | ^~ input.yy:17.33-36: error: multiple occurrences of $2 with api.value.automove [-Werror=other] 17 | | "thrice" exp[val] { $$ = $2 + $val + $2; } | ^~~~ input.yy:17.40-41: error: multiple occurrences of $2 with api.value.automove [-Werror=other] 17 | | "thrice" exp[val] { $$ = $2 + $val + $2; } | ^~ ./c++.at:263: sed 's,.*/$,,' stderr 1>&2 ./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.yy --warnings=error ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./regression.at:1787: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.yy -Wnone,none -Werror --trace=none ./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.yy --warnings=none -Werror --trace=none 665. c++.at:247: ok 668. c++.at:568: testing Variants lalr1.cc parse.assert api.value.automove ... ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./regression.at:1715: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt stderr: ./regression.at:1715: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: ./regression.at:1715: grep 'syntax error,' stderr.txt stdout: ./regression.at:1877: $PREPARSER ./input ./regression.at:1715: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt stderr: ./regression.at:1877: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1715: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt 656. regression.at:1877: ok ./regression.at:1715: "$PERL" -0777 -ne 'print s/\(realloc//g;' < stderr.txt ./regression.at:1716: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full \ -Dparse.lac.es-capacity-initial=1 \ -Dparse.lac.memory-trace=full -o input.c input.y ./regression.at:1716: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 669. c++.at:569: testing Variants lalr1.cc parse.assert %locations ... ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: ./regression.at:1788: $PREPARSER ./input --debug stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token "invalid token" () LAC: initial context established for "invalid token" LAC: checking lookahead "invalid token": Always Err Constructing syntax error message LAC: checking lookahead "end of file": R2 G3 R2 G5 R2 G6 R2 G7 R2 G8 R2 G9 R2 G10 R2 G11 R2 (max size exceeded) syntax error memory exhausted Cleanup: discarding lookahead token "invalid token" () Stack now 0 ./regression.at:1788: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 652. regression.at:1739: ok 670. c++.at:570: testing Variants lalr1.cc parse.assert %code {\n#define TWO_STAGE_BUILD\n} ... ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror stderr: stdout: ./regression.at:1716: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt stderr: ./regression.at:1716: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./regression.at:1716: grep 'syntax error,' stderr.txt ./c++.at:92: $PREPARSER ./input stderr: ./regression.at:1716: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1716: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./regression.at:1716: "$PERL" -0777 -ne 'print s/\(realloc//g;' < stderr.txt ./regression.at:1719: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -o input.cc input.y ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./regression.at:1719: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none stderr: stdout: stderr: ./c++.at:235: $PREPARSER ./list stderr: stdout: ./regression.at:1878: $PREPARSER ./input ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./regression.at:1878: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 657. regression.at:1878: ok 671. c++.at:571: testing Variants lalr1.cc parse.assert api.token.constructor ... ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./torture.at:395: $PREPARSER ./input stderr: ./torture.at:395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 613. torture.at:385: ok stderr: stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: 672. c++.at:572: testing Variants lalr1.cc parse.assert api.token.constructor api.token.prefix={TOK_} ... ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:566: $here/modern stdout: Modern C++: 201703 ./c++.at:566: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:567: $here/modern stdout: Modern C++: 201703 ./c++.at:567: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stderr: stdout: stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none stderr: stdout: ./regression.at:1719: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt stderr: ./regression.at:1719: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1719: grep 'syntax error,' stderr.txt ./regression.at:1719: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt ./regression.at:1719: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt ./regression.at:1727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -o input.java input.y 651. regression.at:1628: skipped (regression.at:1727) 673. c++.at:573: testing Variants lalr1.cc parse.assert api.token.constructor api.token.prefix={TOK_} %locations ... ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: stderr: stdout: ./c++.at:92: $PREPARSER ./input ./c++.at:235: $PREPARSER ./list stderr: stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:568: $here/modern stdout: Modern C++: 201703 ./c++.at:568: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:569: $here/modern stdout: Modern C++: 201703 ./c++.at:569: $PREPARSER ./list stderr: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: stderr: ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stdout: ./c++.at:570: $here/modern stdout: Modern C++: 201703 ./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:566: $here/modern stdout: Legac++ ./c++.at:566: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./existing.at:1460: sed -n 's/^State //p' input.output | tail -1 ./existing.at:1460: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./c++.at:571: $here/modern stderr: stdout: input.y:128.18: error: empty rule without %empty [-Werror=empty-rule] input.y:137.18: error: empty rule without %empty [-Werror=empty-rule] input.y:142.18: error: empty rule without %empty [-Werror=empty-rule] input.y:161.18: error: empty rule without %empty [-Werror=empty-rule] input.y:179.18: error: empty rule without %empty [-Werror=empty-rule] input.y:205.18: error: empty rule without %empty [-Werror=empty-rule] input.y:213.18: error: empty rule without %empty [-Werror=empty-rule] input.y:225.18: error: empty rule without %empty [-Werror=empty-rule] input.y:292.18: error: empty rule without %empty [-Werror=empty-rule] input.y:294.20: error: empty rule without %empty [-Werror=empty-rule] input.y:367.18: error: empty rule without %empty [-Werror=empty-rule] input.y:373.18: error: empty rule without %empty [-Werror=empty-rule] input.y:387.18: error: empty rule without %empty [-Werror=empty-rule] input.y:401.18: error: empty rule without %empty [-Werror=empty-rule] input.y:413.18: error: empty rule without %empty [-Werror=empty-rule] input.y:443.18: error: empty rule without %empty [-Werror=empty-rule] input.y:471.18: error: empty rule without %empty [-Werror=empty-rule] input.y:474.18: error: empty rule without %empty [-Werror=empty-rule] input.y:489.18: error: empty rule without %empty [-Werror=empty-rule] input.y:506.18: error: empty rule without %empty [-Werror=empty-rule] input.y:587.18: error: empty rule without %empty [-Werror=empty-rule] input.y:591.18: error: empty rule without %empty [-Werror=empty-rule] input.y: error: 1876 shift/reduce conflicts [-Werror=conflicts-sr] input.y: error: 144 reduce/reduce conflicts [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:72.1-5: error: useless associativity for HQUA, use %precedence [-Werror=precedence] input.y:53.1-6: error: useless associativity for HASSIGN, use %precedence [-Werror=precedence] input.y:54.1-5: error: useless associativity for HORELSE, use %precedence [-Werror=precedence] input.y:55.1-5: error: useless associativity for HANDTHEN, use %precedence [-Werror=precedence] input.y:61.1-5: error: useless associativity for HNOT, use %precedence [-Werror=precedence] input.y:68.1-5: error: useless associativity for UNEAR, use %precedence [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] Modern C++: 201703 ./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./existing.at:808: sed 's,.*/$,,' stderr 1>&2 ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:572: $here/modern stdout: stderr: Modern C++: 201703 ./c++.at:572: $PREPARSER ./list stderr: stdout: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:235: $PREPARSER ./list ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ======== Testing with C++ standard flags: '' ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:567: $here/modern stdout: Legac++ ./c++.at:567: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:566: $here/modern stderr: stdout: Legac++ ./c++.at:566: $PREPARSER ./list stdout: stderr: ./existing.at:1460: $PREPARSER ./input stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./existing.at:1460: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 624. existing.at:1460: ok ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: 674. c++.at:574: testing Variants lalr1.cc parse.assert api.token.constructor api.token.prefix={TOK_} %locations api.value.automove ... ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: stderr: stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:568: $here/modern ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: Legac++ ./c++.at:568: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:570: $here/modern stdout: Legac++ ./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stderr: stdout: stdout: ./c++.at:573: $here/modern ./c++.at:569: $here/modern stdout: Legac++ stdout: ./c++.at:569: $PREPARSER ./list Modern C++: 201703 ./c++.at:573: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:571: $here/modern stdout: Legac++ ./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:235: $PREPARSER ./list stderr: ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:566: $here/modern stdout: Modern C++: 201103 ./c++.at:566: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:572: $here/modern stdout: Legac++ ./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:567: $here/modern stdout: Legac++ ./c++.at:567: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none stderr: stdout: ./c++.at:568: $here/modern stdout: Legac++ ./c++.at:568: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stderr: stdout: stdout: ./c++.at:235: $PREPARSER ./list stderr: ./c++.at:574: $here/modern ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: Modern C++: 201703 ./c++.at:574: $PREPARSER ./list ======== Testing with C++ standard flags: '' ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:573: $here/modern stdout: Legac++ ./c++.at:573: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:570: $here/modern stdout: Legac++ ./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:569: $here/modern stdout: Legac++ ./c++.at:569: $PREPARSER ./list stderr: stdout: stderr: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:571: $here/modern stdout: Legac++ ./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:566: $here/modern stdout: Modern C++: 201402 ./c++.at:566: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:567: $here/modern stdout: Modern C++: 201103 ./c++.at:567: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:572: $here/modern stderr: stdout: stdout: Legac++ ./c++.at:572: $PREPARSER ./list stderr: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) stderr: stdout: ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:235: $PREPARSER ./list stderr: ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ======== Testing with C++ standard flags: '' ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:568: $here/modern stdout: Modern C++: 201103 ./c++.at:568: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:570: $here/modern stdout: Modern C++: 201103 ./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 663. c++.at:26: ok stderr: stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:574: $here/modern stdout: Legac++ ./c++.at:574: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y 675. c++.at:584: testing Variants and Typed Midrule Actions ... ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:569: $here/modern stderr: stdout: stdout: Modern C++: 201103 ./c++.at:573: $here/modern ./c++.at:569: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) stdout: Legac++ ./c++.at:573: $PREPARSER ./list ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:566: $here/modern stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS Modern C++: 201703 ./c++.at:566: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:567: $here/modern stdout: Modern C++: 201402 ./c++.at:567: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:571: $here/modern stdout: Modern C++: 201103 ./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) stderr: ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:572: $here/modern stdout: Modern C++: 201103 ./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:568: $here/modern stdout: Modern C++: 201402 ./c++.at:568: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:235: $PREPARSER ./list stderr: ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:659: $PREPARSER ./input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:573: $here/modern stdout: Modern C++: 201103 ./c++.at:573: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:571: $here/modern stdout: Modern C++: 201402 ./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:570: $here/modern stdout: Modern C++: 201402 ./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stderr: stdout: stdout: ./c++.at:566: $here/modern stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS Modern C++: 202002 ./c++.at:566: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:574: $here/modern stdout: Legac++ ./c++.at:574: $PREPARSER ./list stderr: stderr: stdout: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:567: $here/modern stderr: ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stdout: Modern C++: 201703 ./c++.at:567: $PREPARSER ./list stderr: ./c++.at:659: $PREPARSER ./input Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:568: $here/modern ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: Modern C++: 201703 ./c++.at:568: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:569: $here/modern stdout: Modern C++: 201402 ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:569: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:572: $here/modern stdout: Modern C++: 201402 ./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./existing.at:808: sed -n 's/^State //p' input.output | tail -1 ./existing.at:808: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./c++.at:573: $here/modern stdout: Modern C++: 201402 ./c++.at:573: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:659: $PREPARSER ./input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stderr: stdout: stdout: ./c++.at:235: $PREPARSER ./list ./c++.at:571: $here/modern stdout: stderr: Modern C++: 201703 ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:571: $PREPARSER ./list stderr: ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 664. c++.at:107: ok Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) stderr: stdout: ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:570: $here/modern ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: stdout: Modern C++: 201703 ./c++.at:570: $PREPARSER ./list ./existing.at:808: $PREPARSER ./input stderr: stderr: stderr: ./existing.at:808: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 621. existing.at:808: ok 676. c++.at:794: testing Doxygen Public Documentation ... ./c++.at:794: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:794: doxygen --version || exit 77 --- /dev/null 2025-02-20 11:23:24.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/676/stderr 2025-02-22 12:30:18.427145165 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/676/test-source: line 180: doxygen: command not found stdout: 676. c++.at:794: 677. c++.at:795: testing Doxygen Private Documentation ... ./c++.at:795: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS skipped (c++.at:794) stderr: stdout: ./c++.at:569: $here/modern stdout: ./c++.at:795: doxygen --version || exit 77 Modern C++: 201703 ./c++.at:569: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) --- /dev/null 2025-02-20 11:23:24.000000000 +0000 +++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/677/stderr 2025-02-22 12:30:18.603146281 +0000 @@ -0,0 +1 @@ +/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/677/test-source: line 180: doxygen: command not found stdout: ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 677. c++.at:795: skipped (c++.at:795) 678. c++.at:848: testing Relative namespace references ... ./c++.at:849: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS 679. c++.at:854: testing Absolute namespace references ... ./c++.at:855: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:574: $here/modern stdout: stderr: Modern C++: 201103 ./c++.at:574: $PREPARSER ./list stdout: stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: stderr: stdout: stderr: ./c++.at:849: $PREPARSER ./input stderr: stdout: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:568: $here/modern ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stdout: Modern C++: 202002 ./c++.at:568: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:567: $here/modern stdout: Modern C++: 202002 ./c++.at:567: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:659: $PREPARSER ./input stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:855: $PREPARSER ./input stderr: ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:572: $here/modern stdout: Modern C++: 201703 ./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: stderr: stdout: ./c++.at:566: $here/modern stdout: Modern C++: 202302 ./c++.at:566: $PREPARSER ./list stderr: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 666. c++.at:566: ok stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 680. c++.at:863: testing Syntactically invalid namespace references ... ./c++.at:864: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ./c++.at:865: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ./c++.at:868: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ./c++.at:869: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ./c++.at:870: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy 680. c++.at:863: ok stderr: stdout: ./c++.at:855: $PREPARSER ./input stderr: ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS 681. c++.at:884: testing Syntax error discarding no lookahead ... ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./c++.at:573: $here/modern stdout: ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS Modern C++: 201703 ./c++.at:573: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) stderr: stdout: ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:659: $PREPARSER ./input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' stdout: ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:574: $here/modern stdout: Modern C++: 201402 ./c++.at:574: $PREPARSER ./list stderr: stdout: stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:571: $here/modern stdout: Modern C++: 202002 ./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) stderr: stdout: ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:855: $PREPARSER ./input stderr: ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:570: $here/modern stdout: Modern C++: 202002 ./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' stdout: ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:569: $here/modern stderr: stdout: ./c++.at:941: $PREPARSER ./input stdout: stderr: syntax error Discarding 'a'. Reducing 'a'. Modern C++: 202002 ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:569: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:855: $PREPARSER ./input stderr: stderr: stdout: ./c++.at:659: $PREPARSER ./input ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stderr: stdout: stdout: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:941: $PREPARSER ./input stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:572: $here/modern stdout: Modern C++: 202002 ./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:574: $here/modern stdout: Modern C++: 201703 ./c++.at:574: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:855: $PREPARSER ./input stderr: ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:573: $here/modern stdout: Modern C++: 202002 ./c++.at:573: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:568: $here/modern stdout: Modern C++: 202302 ./c++.at:568: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 668. c++.at:568: ok stderr: stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 682. c++.at:1064: testing Syntax error as exception: lalr1.cc ... ./c++.at:1064: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ======== Testing with C++ standard flags: '' ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stderr: stdout: stdout: ./c++.at:941: $PREPARSER ./input ./c++.at:855: $PREPARSER ./input stderr: stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:659: $PREPARSER ./input stderr: Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:567: $here/modern stdout: Modern C++: 202302 ./c++.at:567: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 667. c++.at:567: ok ======== Testing with C++ standard flags: '' ./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 683. c++.at:1065: testing Syntax error as exception: glr.cc ... ./c++.at:1065: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ======== Testing with C++ standard flags: '' ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:855: $PREPARSER ./input stderr: ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:941: $PREPARSER ./input stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: ./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:574: $here/modern stdout: Modern C++: 202002 ./c++.at:574: $PREPARSER ./list stderr: Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:571: $here/modern stdout: Modern C++: 202302 ./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 671. c++.at:571: ok ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 684. c++.at:1066: testing Syntax error as exception: glr2.cc ... stderr: ./c++.at:1066: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stdout: ./c++.at:850: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:1065: $PREPARSER ./input < in stderr: ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS error: invalid expression ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:941: $PREPARSER ./input ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1066: ./check ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stderr: stdout: stdout: stdout: ./c++.at:570: $here/modern ./c++.at:659: $PREPARSER ./input ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stdout: stderr: Modern C++: 202302 ./c++.at:570: $PREPARSER ./list Starting parse Entering state 0 Stack now 0 Reading a token Next token is token NUMBER (1) Shifting token NUMBER (1) Entering state 1 Stack now 0 1 Reducing stack by rule 1 (line 34): $1 = token NUMBER (1) -> $$ = nterm expr (10) destroy: 1 Entering state 2 Stack now 0 2 Reading a token Next token is token NUMBER (30) Reducing stack by rule 2 (line 35): -> $$ = nterm @1 (20) Entering state 4 Stack now 0 2 4 Next token is token NUMBER (30) Shifting token NUMBER (30) Entering state 5 Stack now 0 2 4 5 Reducing stack by rule 3 (line 35): $1 = nterm expr (10) $2 = nterm @1 (20) $3 = token NUMBER (30) expr: 10 20 30 -> $$ = nterm expr (40) destroy: 30 destroy: 20 destroy: 10 Entering state 2 Stack now 0 2 Reading a token Next token is token EOI () Shifting token EOI () Entering state 3 Stack now 0 2 3 Stack now 0 2 3 Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 675. c++.at:584: ok ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 670. c++.at:570: ok stderr: stderr: stdout: stdout: ./c++.at:855: $PREPARSER ./input ./c++.at:1064: $PREPARSER ./input < in stderr: ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 685. c++.at:1360: testing Exception safety with error recovery ... ./c++.at:1064: $PREPARSER ./input < in ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o exceptions exceptions.cc $LIBS ./c++.at:856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stderr: error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1064: $PREPARSER ./input < in ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 686. c++.at:1361: testing Exception safety without error recovery ... ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o exceptions exceptions.cc $LIBS stderr: error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: ./c++.at:569: $here/modern stdout: Modern C++: 202302 ./c++.at:569: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 669. c++.at:569: ok 687. c++.at:1362: testing Exception safety with error recovery api.value.type=variant ... stderr: ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o exceptions exceptions.cc $LIBS stdout: ./c++.at:572: $here/modern stdout: Modern C++: 202302 ./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) stderr: stdout: ./c++.at:850: $PREPARSER ./input ./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 672. c++.at:572: ok ======== Testing with C++ standard flags: '' ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1360: ./exceptions || exit 77 stderr: Inner caught Outer caught stderr: ./c++.at:1360: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc --report=all input.yy stdout: ./c++.at:1361: ./exceptions || exit 77 688. c++.at:1363: testing Exception safety without error recovery api.value.type=variant ... stderr: ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o exceptions exceptions.cc $LIBS Inner caught Outer caught ./c++.at:1361: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc --report=all input.yy ======== Testing with C++ standard flags: '' ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1362: ./exceptions || exit 77 stderr: Inner caught Outer caught ./c++.at:1362: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc --report=all input.yy stderr: stdout: ./c++.at:941: $PREPARSER ./input stderr: ======== Testing with C++ standard flags: '' syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:573: $here/modern ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stdout: Modern C++: 202302 ./c++.at:573: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" Destroy: 1 Destroy: "1" Destroy: (0) Destroy: "2" Destroy: "2" Destroy: (0, 1) Destroy: "" Destroy: 3 Destroy: (0, 1, 2) Destroy: "4" Destroy: "4" Destroy: (0, 1, 2) Destroy: (0, 1, 2, 4) Destroy: 5 Destroy: (0, 1, 2, 4) Destroy: "6" Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 673. c++.at:573: ok stderr: stderr: stdout: ./c++.at:850: $PREPARSER ./input stdout: stderr: ./c++.at:1363: ./exceptions || exit 77 ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' Inner caught Outer caught ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:1363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc --report=all input.yy stdout: 689. c++.at:1371: testing C++ GLR parser identifier shadowing ... ./c++.at:1410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ./c++.at:856: $PREPARSER ./input stderr: ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: ./c++.at:856: $PREPARSER ./input stderr: ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: stderr: stdout: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:850: $PREPARSER ./input stderr: ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1360: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1360: $PREPARSER ./input i ======== Testing with C++ standard flags: '' stderr: ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS exception caught: initial-action ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaap stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaeb106f40->Object::Object { } Next token is token 'a' (0xaaaaeb106f40 'a') Shifting token 'a' (0xaaaaeb106f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaeb106f40 'a') -> $$ = nterm item (0xaaaaeb106f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaaeb106f90->Object::Object { 0xaaaaeb106f40 } Next token is token 'a' (0xaaaaeb106f90 'a') Shifting token 'a' (0xaaaaeb106f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaeb106f90 'a') -> $$ = nterm item (0xaaaaeb106f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaaeb106fe0->Object::Object { 0xaaaaeb106f40, 0xaaaaeb106f90 } Next token is token 'a' (0xaaaaeb106fe0 'a') Shifting token 'a' (0xaaaaeb106fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaeb106fe0 'a') -> $$ = nterm item (0xaaaaeb106fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaaeb107030->Object::Object { 0xaaaaeb106f40, 0xaaaaeb106f90, 0xaaaaeb106fe0 } Next token is token 'a' (0xaaaaeb107030 'a') Shifting token 'a' (0xaaaaeb107030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaeb107030 'a') -> $$ = nterm item (0xaaaaeb107030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaaeb107080->Object::Object { 0xaaaaeb106f40, 0xaaaaeb106f90, 0xaaaaeb106fe0, 0xaaaaeb107030 } Next token is token 'p' (0xaaaaeb107080 'p'Exception caught: cleaning lookahead and stack 0xaaaaeb107080->Object::~Object { 0xaaaaeb106f40, 0xaaaaeb106f90, 0xaaaaeb106fe0, 0xaaaaeb107030, 0xaaaaeb107080 } 0xaaaaeb107030->Object::~Object { 0xaaaaeb106f40, 0xaaaaeb106f90, 0xaaaaeb106fe0, 0xaaaaeb107030 } 0xaaaaeb106fe0->Object::~Object { 0xaaaaeb106f40, 0xaaaaeb106f90, 0xaaaaeb106fe0 } 0xaaaaeb106f90->Object::~Object { 0xaaaaeb106f40, 0xaaaaeb106f90 } 0xaaaaeb106f40->Object::~Object { 0xaaaaeb106f40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaeb106f40->Object::Object { } Next token is token 'a' (0xaaaaeb106f40 'a') Shifting token 'a' (0xaaaaeb106f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaeb106f40 'a') -> $$ = nterm item (0xaaaaeb106f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaaeb106f90->Object::Object { 0xaaaaeb106f40 } Next token is token 'a' (0xaaaaeb106f90 'a') Shifting token 'a' (0xaaaaeb106f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaeb106f90 'a') -> $$ = nterm item (0xaaaaeb106f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaaeb106fe0->Object::Object { 0xaaaaeb106f40, 0xaaaaeb106f90 } Next token is token 'a' (0xaaaaeb106fe0 'a') Shifting token 'a' (0xaaaaeb106fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaeb106fe0 'a') -> $$ = nterm item (0xaaaaeb106fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaaeb107030->Object::Object { 0xaaaaeb106f40, 0xaaaaeb106f90, 0xaaaaeb106fe0 } Next token is token 'a' (0xaaaaeb107030 'a') Shifting token 'a' (0xaaaaeb107030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaeb107030 'a') -> $$ = nterm item (0xaaaaeb107030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaaeb107080->Object::Object { 0xaaaaeb106f40, 0xaaaaeb106f90, 0xaaaaeb106fe0, 0xaaaaeb107030 } Next token is token 'p' (0xaaaaeb107080 'p'Exception caught: cleaning lookahead and stack 0xaaaaeb107080->Object::~Object { 0xaaaaeb106f40, 0xaaaaeb106f90, 0xaaaaeb106fe0, 0xaaaaeb107030, 0xaaaaeb107080 } 0xaaaaeb107030->Object::~Object { 0xaaaaeb106f40, 0xaaaaeb106f90, 0xaaaaeb106fe0, 0xaaaaeb107030 } 0xaaaaeb106fe0->Object::~Object { 0xaaaaeb106f40, 0xaaaaeb106f90, 0xaaaaeb106fe0 } 0xaaaaeb106f90->Object::~Object { 0xaaaaeb106f40, 0xaaaaeb106f90 } 0xaaaaeb106f40->Object::~Object { 0xaaaaeb106f40 } exception caught: printer end { } ./c++.at:1360: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1360: $PREPARSER ./input aaaaE ./c++.at:1362: $PREPARSER ./input aaaas stderr: stderr: exception caught: reduction exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaT stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaR stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaap ======== Testing with C++ standard flags: '' ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: stdout: stderr: ./c++.at:1065: $PREPARSER ./input < in Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc1b0e9e0->Object::Object { } 0xffffc1b0eae0->Object::Object { 0xffffc1b0e9e0 } 0xffffc1b0e9e0->Object::~Object { 0xffffc1b0e9e0, 0xffffc1b0eae0 } Next token is token 'a' (0xffffc1b0eae0 'a') 0xffffc1b0ea20->Object::Object { 0xffffc1b0eae0 } 0xffffc1b0eae0->Object::~Object { 0xffffc1b0ea20, 0xffffc1b0eae0 } Shifting token 'a' (0xffffc1b0ea20 'a') 0xaaaaf37ff2e0->Object::Object { 0xffffc1b0ea20 } 0xffffc1b0ea20->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0ea20 } Entering state 2 Stack now 0 2 0xffffc1b0eb00->Object::Object { 0xaaaaf37ff2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf37ff2e0 'a') -> $$ = nterm item (0xffffc1b0eb00 'a') 0xaaaaf37ff2e0->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0eb00 } 0xaaaaf37ff2e0->Object::Object { 0xffffc1b0eb00 } 0xffffc1b0eb00->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0eb00 } Entering state 11 Stack now 0 11 Reading a token 0xffffc1b0e9e0->Object::Object { 0xaaaaf37ff2e0 } 0xffffc1b0eae0->Object::Object { 0xaaaaf37ff2e0, 0xffffc1b0e9e0 } 0xffffc1b0e9e0->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0e9e0, 0xffffc1b0eae0 } Next token is token 'a' (0xffffc1b0eae0 'a') 0xffffc1b0ea20->Object::Object { 0xaaaaf37ff2e0, 0xffffc1b0eae0 } 0xffffc1b0eae0->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0ea20, 0xffffc1b0eae0 } Shifting token 'a' (0xffffc1b0ea20 'a') 0xaaaaf37ff300->Object::Object { 0xaaaaf37ff2e0, 0xffffc1b0ea20 } 0xffffc1b0ea20->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0ea20 } Entering state 2 Stack now 0 11 2 0xffffc1b0eb00->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf37ff300 'a') -> $$ = nterm item (0xffffc1b0eb00 'a') 0xaaaaf37ff300->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0eb00 } 0xaaaaf37ff300->Object::Object { 0xaaaaf37ff2e0, 0xffffc1b0eb00 } 0xffffc1b0eb00->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0eb00 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffc1b0e9e0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300 } 0xffffc1b0eae0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0e9e0 } 0xffffc1b0e9e0->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0e9e0, 0xffffc1b0eae0 } Next token is token 'a' (0xffffc1b0eae0 'a') 0xffffc1b0ea20->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0eae0 } 0xffffc1b0eae0->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0ea20, 0xffffc1b0eae0 } Shifting token 'a' (0xffffc1b0ea20 'a') 0xaaaaf37ff320->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0ea20 } 0xffffc1b0ea20->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0ea20 } Entering state 2 Stack now 0 11 11 2 0xffffc1b0eb00->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf37ff320 'a') -> $$ = nterm item (0xffffc1b0eb00 'a') 0xaaaaf37ff320->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0eb00 } 0xaaaaf37ff320->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0eb00 } 0xffffc1b0eb00->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0eb00 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffc1b0e9e0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320 } 0xffffc1b0eae0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0e9e0 } 0xffffc1b0e9e0->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0e9e0, 0xffffc1b0eae0 } Next token is token 'a' (0xffffc1b0eae0 'a') 0xffffc1b0ea20->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0eae0 } 0xffffc1b0eae0->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0ea20, 0xffffc1b0eae0 } Shifting token 'a' (0xffffc1b0ea20 'a') 0xaaaaf37ff340->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0ea20 } 0xffffc1b0ea20->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0ea20 } Entering state 2 Stack now 0 11 11 11 2 0xffffc1b0eb00->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf37ff340 'a') -> $$ = nterm item (0xffffc1b0eb00 'a') 0xaaaaf37ff340->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0eb00 } 0xaaaaf37ff340->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0eb00 } 0xffffc1b0eb00->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0eb00 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffc1b0e9e0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340 } 0xffffc1b0eae0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0e9e0 } 0xffffc1b0e9e0->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0e9e0, 0xffffc1b0eae0 } Next token is token 'p' (0xffffc1b0eae0 'p'Exception caught: cleaning lookahead and stack 0xaaaaf37ff340->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0eae0 } 0xaaaaf37ff320->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0eae0 } 0xaaaaf37ff300->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0eae0 } 0xaaaaf37ff2e0->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0eae0 } 0xffffc1b0eae0->Object::~Object { 0xffffc1b0eae0 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: ./c++.at:941: $PREPARSER ./input stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc1b0e9e0->Object::Object { } 0xffffc1b0eae0->Object::Object { 0xffffc1b0e9e0 } 0xffffc1b0e9e0->Object::~Object { 0xffffc1b0e9e0, 0xffffc1b0eae0 } Next token is token 'a' (0xffffc1b0eae0 'a') 0xffffc1b0ea20->Object::Object { 0xffffc1b0eae0 } 0xffffc1b0eae0->Object::~Object { 0xffffc1b0ea20, 0xffffc1b0eae0 } Shifting token 'a' (0xffffc1b0ea20 'a') 0xaaaaf37ff2e0->Object::Object { 0xffffc1b0ea20 } 0xffffc1b0ea20->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0ea20 } Entering state 2 Stack now 0 2 0xffffc1b0eb00->Object::Object { 0xaaaaf37ff2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf37ff2e0 'a') -> $$ = nterm item (0xffffc1b0eb00 'a') 0xaaaaf37ff2e0->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0eb00 } 0xaaaaf37ff2e0->Object::Object { 0xffffc1b0eb00 } 0xffffc1b0eb00->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0eb00 } Entering state 11 Stack now 0 11 Reading a token 0xffffc1b0e9e0->Object::Object { 0xaaaaf37ff2e0 } 0xffffc1b0eae0->Object::Object { 0xaaaaf37ff2e0, 0xffffc1b0e9e0 } 0xffffc1b0e9e0->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0e9e0, 0xffffc1b0eae0 } Next token is token 'a' (0xffffc1b0eae0 'a') 0xffffc1b0ea20->Object::Object { 0xaaaaf37ff2e0, 0xffffc1b0eae0 } 0xffffc1b0eae0->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0ea20, 0xffffc1b0eae0 } Shifting token 'a' (0xffffc1b0ea20 'a') 0xaaaaf37ff300->Object::Object { 0xaaaaf37ff2e0, 0xffffc1b0ea20 } 0xffffc1b0ea20->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0ea20 } Entering state 2 Stack now 0 11 2 0xffffc1b0eb00->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf37ff300 'a') -> $$ = nterm item (0xffffc1b0eb00 'a') 0xaaaaf37ff300->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0eb00 } 0xaaaaf37ff300->Object::Object { 0xaaaaf37ff2e0, 0xffffc1b0eb00 } 0xffffc1b0eb00->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0eb00 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffc1b0e9e0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300 } 0xffffc1b0eae0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0e9e0 } 0xffffc1b0e9e0->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0e9e0, 0xffffc1b0eae0 } Next token is token 'a' (0xffffc1b0eae0 'a') 0xffffc1b0ea20->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0eae0 } 0xffffc1b0eae0->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0ea20, 0xffffc1b0eae0 } Shifting token 'a' (0xffffc1b0ea20 'a') 0xaaaaf37ff320->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0ea20 } 0xffffc1b0ea20->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0ea20 } Entering state 2 Stack now 0 11 11 2 0xffffc1b0eb00->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf37ff320 'a') -> $$ = nterm item (0xffffc1b0eb00 'a') 0xaaaaf37ff320->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0eb00 } 0xaaaaf37ff320->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0eb00 } 0xffffc1b0eb00->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0eb00 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffc1b0e9e0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320 } 0xffffc1b0eae0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0e9e0 } 0xffffc1b0e9e0->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0e9e0, 0xffffc1b0eae0 } Next token is token 'a' (0xffffc1b0eae0 'a') 0xffffc1b0ea20->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0eae0 } 0xffffc1b0eae0->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0ea20, 0xffffc1b0eae0 } Shifting token 'a' (0xffffc1b0ea20 'a') 0xaaaaf37ff340->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0ea20 } 0xffffc1b0ea20->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0ea20 } Entering state 2 Stack now 0 11 11 11 2 0xffffc1b0eb00->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaaf37ff340 'a') -> $$ = nterm item (0xffffc1b0eb00 'a') 0xaaaaf37ff340->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0eb00 } 0xaaaaf37ff340->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0eb00 } 0xffffc1b0eb00->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0eb00 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffc1b0e9e0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340 } 0xffffc1b0eae0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0e9e0 } 0xffffc1b0e9e0->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0e9e0, 0xffffc1b0eae0 } Next token is token 'p' (0xffffc1b0eae0 'p'Exception caught: cleaning lookahead and stack 0xaaaaf37ff340->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0eae0 } 0xaaaaf37ff320->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0eae0 } 0xaaaaf37ff300->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0eae0 } 0xaaaaf37ff2e0->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0eae0 } 0xffffc1b0eae0->Object::~Object { 0xffffc1b0eae0 } exception caught: printer end { } syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae ./c++.at:1065: $PREPARSER ./input < in stderr: ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: invalid expression ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaE stderr: ./c++.at:1065: $PREPARSER ./input < in exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: ./c++.at:1361: $PREPARSER ./input aaaas error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1362: $PREPARSER ./input aaaaT exception caught: reduction ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ./c++.at:1361: $PREPARSER ./input aaaal ./c++.at:1362: $PREPARSER ./input aaaaR stderr: stderr: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1361: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaap stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaac777ef40->Object::Object { } Next token is token 'a' (0xaaaac777ef40 'a') Shifting token 'a' (0xaaaac777ef40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac777ef40 'a') -> $$ = nterm item (0xaaaac777ef40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaac777ef90->Object::Object { 0xaaaac777ef40 } Next token is token 'a' (0xaaaac777ef90 'a') Shifting token 'a' (0xaaaac777ef90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac777ef90 'a') -> $$ = nterm item (0xaaaac777ef90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaac777efe0->Object::Object { 0xaaaac777ef40, 0xaaaac777ef90 } Next token is token 'a' (0xaaaac777efe0 'a') Shifting token 'a' (0xaaaac777efe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac777efe0 'a') -> $$ = nterm item (0xaaaac777efe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaac777f030->Object::Object { 0xaaaac777ef40, 0xaaaac777ef90, 0xaaaac777efe0 } Next token is token 'a' (0xaaaac777f030 'a') Shifting token 'a' (0xaaaac777f030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac777f030 'a') -> $$ = nterm item (0xaaaac777f030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaac777f080->Object::Object { 0xaaaac777ef40, 0xaaaac777ef90, 0xaaaac777efe0, 0xaaaac777f030 } Next token is token 'p' (0xaaaac777f080 'p'Exception caught: cleaning lookahead and stack 0xaaaac777f080->Object::~Object { 0xaaaac777ef40, 0xaaaac777ef90, 0xaaaac777efe0, 0xaaaac777f030, 0xaaaac777f080 } 0xaaaac777f030->Object::~Object { 0xaaaac777ef40, 0xaaaac777ef90, 0xaaaac777efe0, 0xaaaac777f030 } 0xaaaac777efe0->Object::~Object { 0xaaaac777ef40, 0xaaaac777ef90, 0xaaaac777efe0 } 0xaaaac777ef90->Object::~Object { 0xaaaac777ef40, 0xaaaac777ef90 } 0xaaaac777ef40->Object::~Object { 0xaaaac777ef40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: ./c++.at:856: $PREPARSER ./input Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaac777ef40->Object::Object { } Next token is token 'a' (0xaaaac777ef40 'a') Shifting token 'a' (0xaaaac777ef40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac777ef40 'a') -> $$ = nterm item (0xaaaac777ef40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaac777ef90->Object::Object { 0xaaaac777ef40 } Next token is token 'a' (0xaaaac777ef90 'a') Shifting token 'a' (0xaaaac777ef90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac777ef90 'a') -> $$ = nterm item (0xaaaac777ef90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaac777efe0->Object::Object { 0xaaaac777ef40, 0xaaaac777ef90 } Next token is token 'a' (0xaaaac777efe0 'a') Shifting token 'a' (0xaaaac777efe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac777efe0 'a') -> $$ = nterm item (0xaaaac777efe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaac777f030->Object::Object { 0xaaaac777ef40, 0xaaaac777ef90, 0xaaaac777efe0 } Next token is token 'a' (0xaaaac777f030 'a') Shifting token 'a' (0xaaaac777f030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac777f030 'a') -> $$ = nterm item (0xaaaac777f030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaac777f080->Object::Object { 0xaaaac777ef40, 0xaaaac777ef90, 0xaaaac777efe0, 0xaaaac777f030 } Next token is token 'p' (0xaaaac777f080 'p'Exception caught: cleaning lookahead and stack 0xaaaac777f080->Object::~Object { 0xaaaac777ef40, 0xaaaac777ef90, 0xaaaac777efe0, 0xaaaac777f030, 0xaaaac777f080 } 0xaaaac777f030->Object::~Object { 0xaaaac777ef40, 0xaaaac777ef90, 0xaaaac777efe0, 0xaaaac777f030 } 0xaaaac777efe0->Object::~Object { 0xaaaac777ef40, 0xaaaac777ef90, 0xaaaac777efe0 } 0xaaaac777ef90->Object::~Object { 0xaaaac777ef40, 0xaaaac777ef90 } 0xaaaac777ef40->Object::~Object { 0xaaaac777ef40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr stderr: ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stderr: exception caught: printer stdout: ./c++.at:1361: $PREPARSER ./input aaaae stderr: ======== Testing with C++ standard flags: '' ./c++.at:1066: $PREPARSER ./input < in exception caught: syntax error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stderr: error: invalid expression caught error error: invalid character caught error stdout: ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaE ======== Testing with C++ standard flags: '' stderr: ./c++.at:1066: $PREPARSER ./input < in ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stdout: error: invalid expression ./c++.at:1064: $PREPARSER ./input < in ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaT stderr: stderr: ./c++.at:1066: $PREPARSER ./input < in error: invalid expression caught error error: invalid character caught error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1361: $PREPARSER ./input aaaaR error: invalid character ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1064: $PREPARSER ./input < in ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stderr: stdout: stdout: ./c++.at:1066: ./check ./c++.at:1363: $PREPARSER ./input aaaas -std=c++98 not supported ======== Testing with C++ standard flags: '' stderr: exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./c++.at:1363: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: $PREPARSER ./input aaaap stdout: ./c++.at:1066: ./check stderr: -std=c++03 not supported ======== Testing with C++ standard flags: '' ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input --debug aaaap ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffe49f1430->Object::Object { } 0xffffe49f1530->Object::Object { 0xffffe49f1430 } 0xffffe49f1430->Object::~Object { 0xffffe49f1430, 0xffffe49f1530 } Next token is token 'a' (0xffffe49f1530 'a') 0xffffe49f1470->Object::Object { 0xffffe49f1530 } 0xffffe49f1530->Object::~Object { 0xffffe49f1470, 0xffffe49f1530 } Shifting token 'a' (0xffffe49f1470 'a') 0xaaaac05492e0->Object::Object { 0xffffe49f1470 } 0xffffe49f1470->Object::~Object { 0xaaaac05492e0, 0xffffe49f1470 } Entering state 1 Stack now 0 1 0xffffe49f1550->Object::Object { 0xaaaac05492e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac05492e0 'a') -> $$ = nterm item (0xffffe49f1550 'a') 0xaaaac05492e0->Object::~Object { 0xaaaac05492e0, 0xffffe49f1550 } 0xaaaac05492e0->Object::Object { 0xffffe49f1550 } 0xffffe49f1550->Object::~Object { 0xaaaac05492e0, 0xffffe49f1550 } Entering state 10 Stack now 0 10 Reading a token 0xffffe49f1430->Object::Object { 0xaaaac05492e0 } 0xffffe49f1530->Object::Object { 0xaaaac05492e0, 0xffffe49f1430 } 0xffffe49f1430->Object::~Object { 0xaaaac05492e0, 0xffffe49f1430, 0xffffe49f1530 } Next token is token 'a' (0xffffe49f1530 'a') 0xffffe49f1470->Object::Object { 0xaaaac05492e0, 0xffffe49f1530 } 0xffffe49f1530->Object::~Object { 0xaaaac05492e0, 0xffffe49f1470, 0xffffe49f1530 } Shifting token 'a' (0xffffe49f1470 'a') 0xaaaac0549300->Object::Object { 0xaaaac05492e0, 0xffffe49f1470 } 0xffffe49f1470->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1470 } Entering state 1 Stack now 0 10 1 0xffffe49f1550->Object::Object { 0xaaaac05492e0, 0xaaaac0549300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac0549300 'a') -> $$ = nterm item (0xffffe49f1550 'a') 0xaaaac0549300->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1550 } 0xaaaac0549300->Object::Object { 0xaaaac05492e0, 0xffffe49f1550 } 0xffffe49f1550->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1550 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffe49f1430->Object::Object { 0xaaaac05492e0, 0xaaaac0549300 } 0xffffe49f1530->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1430 } 0xffffe49f1430->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1430, 0xffffe49f1530 } Next token is token 'a' (0xffffe49f1530 'a') 0xffffe49f1470->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1530 } 0xffffe49f1530->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1470, 0xffffe49f1530 } Shifting token 'a' (0xffffe49f1470 'a') 0xaaaac0549320->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1470 } 0xffffe49f1470->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1470 } Entering state 1 Stack now 0 10 10 1 0xffffe49f1550->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac0549320 'a') -> $$ = nterm item (0xffffe49f1550 'a') 0xaaaac0549320->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1550 } 0xaaaac0549320->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1550 } 0xffffe49f1550->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1550 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffe49f1430->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320 } 0xffffe49f1530->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1430 } 0xffffe49f1430->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1430, 0xffffe49f1530 } Next token is token 'a' (0xffffe49f1530 'a') 0xffffe49f1470->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1530 } 0xffffe49f1530->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1470, 0xffffe49f1530 } Shifting token 'a' (0xffffe49f1470 'a') 0xaaaac0549340->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1470 } 0xffffe49f1470->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1470 } Entering state 1 Stack now 0 10 10 10 1 0xffffe49f1550->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac0549340 'a') -> $$ = nterm item (0xffffe49f1550 'a') 0xaaaac0549340->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1550 } 0xaaaac0549340->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1550 } 0xffffe49f1550->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1550 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffe49f1430->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340 } 0xffffe49f1530->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1430 } 0xffffe49f1430->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1430, 0xffffe49f1530 } Next token is token 'p' (0xffffe49f1530 'p'Exception caught: cleaning lookahead and stack 0xaaaac0549340->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1530 } 0xaaaac0549320->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1530 } 0xaaaac0549300->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1530 } 0xaaaac05492e0->Object::~Object { 0xaaaac05492e0, 0xffffe49f1530 } 0xffffe49f1530->Object::~Object { 0xffffe49f1530 } exception caught: printer end { } ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffe49f1430->Object::Object { } 0xffffe49f1530->Object::Object { 0xffffe49f1430 } 0xffffe49f1430->Object::~Object { 0xffffe49f1430, 0xffffe49f1530 } Next token is token 'a' (0xffffe49f1530 'a') 0xffffe49f1470->Object::Object { 0xffffe49f1530 } 0xffffe49f1530->Object::~Object { 0xffffe49f1470, 0xffffe49f1530 } Shifting token 'a' (0xffffe49f1470 'a') 0xaaaac05492e0->Object::Object { 0xffffe49f1470 } 0xffffe49f1470->Object::~Object { 0xaaaac05492e0, 0xffffe49f1470 } Entering state 1 Stack now 0 1 0xffffe49f1550->Object::Object { 0xaaaac05492e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac05492e0 'a') -> $$ = nterm item (0xffffe49f1550 'a') 0xaaaac05492e0->Object::~Object { 0xaaaac05492e0, 0xffffe49f1550 } 0xaaaac05492e0->Object::Object { 0xffffe49f1550 } 0xffffe49f1550->Object::~Object { 0xaaaac05492e0, 0xffffe49f1550 } Entering state 10 Stack now 0 10 Reading a token 0xffffe49f1430->Object::Object { 0xaaaac05492e0 } 0xffffe49f1530->Object::Object { 0xaaaac05492e0, 0xffffe49f1430 } 0xffffe49f1430->Object::~Object { 0xaaaac05492e0, 0xffffe49f1430, 0xffffe49f1530 } Next token is token 'a' (0xffffe49f1530 'a') 0xffffe49f1470->Object::Object { 0xaaaac05492e0, 0xffffe49f1530 } 0xffffe49f1530->Object::~Object { 0xaaaac05492e0, 0xffffe49f1470, 0xffffe49f1530 } Shifting token 'a' (0xffffe49f1470 'a') 0xaaaac0549300->Object::Object { 0xaaaac05492e0, 0xffffe49f1470 } 0xffffe49f1470->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1470 } Entering state 1 Stack now 0 10 1 0xffffe49f1550->Object::Object { 0xaaaac05492e0, 0xaaaac0549300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac0549300 'a') -> $$ = nterm item (0xffffe49f1550 'a') 0xaaaac0549300->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1550 } 0xaaaac0549300->Object::Object { 0xaaaac05492e0, 0xffffe49f1550 } 0xffffe49f1550->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1550 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffe49f1430->Object::Object { 0xaaaac05492e0, 0xaaaac0549300 } 0xffffe49f1530->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1430 } 0xffffe49f1430->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1430, 0xffffe49f1530 } Next token is token 'a' (0xffffe49f1530 'a') 0xffffe49f1470->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1530 } 0xffffe49f1530->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1470, 0xffffe49f1530 } Shifting token 'a' (0xffffe49f1470 'a') 0xaaaac0549320->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1470 } 0xffffe49f1470->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1470 } Entering state 1 Stack now 0 10 10 1 0xffffe49f1550->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac0549320 'a') -> $$ = nterm item (0xffffe49f1550 'a') 0xaaaac0549320->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1550 } 0xaaaac0549320->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1550 } 0xffffe49f1550->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1550 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffe49f1430->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320 } 0xffffe49f1530->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1430 } 0xffffe49f1430->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1430, 0xffffe49f1530 } Next token is token 'a' (0xffffe49f1530 'a') 0xffffe49f1470->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1530 } 0xffffe49f1530->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1470, 0xffffe49f1530 } Shifting token 'a' (0xffffe49f1470 'a') 0xaaaac0549340->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1470 } 0xffffe49f1470->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1470 } Entering state 1 Stack now 0 10 10 10 1 0xffffe49f1550->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac0549340 'a') -> $$ = nterm item (0xffffe49f1550 'a') 0xaaaac0549340->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1550 } 0xaaaac0549340->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1550 } 0xffffe49f1550->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1550 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffe49f1430->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340 } 0xffffe49f1530->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1430 } 0xffffe49f1430->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1430, 0xffffe49f1530 } Next token is token 'p' (0xffffe49f1530 'p'Exception caught: cleaning lookahead and stack 0xaaaac0549340->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1530 } 0xaaaac0549320->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1530 } 0xaaaac0549300->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1530 } 0xaaaac05492e0->Object::~Object { 0xaaaac05492e0, 0xffffe49f1530 } 0xffffe49f1530->Object::~Object { 0xffffe49f1530 } exception caught: printer end { } ./c++.at:1363: grep '^exception caught: printer$' stderr stdout: stderr: exception caught: printer stdout: ./c++.at:1363: $PREPARSER ./input aaaae ./c++.at:850: $PREPARSER ./input stderr: exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: $PREPARSER ./input aaaaE stderr: ======== Testing with C++ standard flags: '' exception caught: syntax error, unexpected end of file, expecting 'a' stdout: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: ./check ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1363: $PREPARSER ./input aaaaT ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaR stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:574: $here/modern stderr: stdout: stdout: ./c++.at:856: $PREPARSER ./input Modern C++: 202302 ./c++.at:574: $PREPARSER ./list stderr: stderr: ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Destroy: "" Destroy: "" Destroy: 1 Destroy: "" Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: "" Destroy: 3 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: () Destroy: 5 Destroy: () Destroy: "" Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 674. c++.at:574: ok 690. c++.at:1422: testing Shared locations ... ./c++.at:1456: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o x1.cc x1.yy ./c++.at:1456: $CXX $CPPFLAGS $CXXFLAGS -Iinclude -c -o x1.o x1.cc stderr: stdout: ./c++.at:850: $PREPARSER ./input stderr: ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:941: $PREPARSER ./input stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 681. c++.at:884: ok stderr: stdout: ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: stderr: ./c++.at:1362: $PREPARSER ./input aaaas stdout: 691. c++.at:1517: testing Default action ... ======== Testing with C++ standard flags: '' stderr: ./c++.at:1360: $PREPARSER ./input aaaas ./c++.at:1065: $PREPARSER ./input < in stderr: exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./c++.at:1360: $PREPARSER ./input aaaal ./c++.at:1362: $PREPARSER ./input aaaal stderr: stderr: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: yylex ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stderr: ./c++.at:1064: $PREPARSER ./input < in error: invalid expression ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input i stderr: stderr: stderr: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1360: $PREPARSER ./input i error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stdout: ./c++.at:1064: $PREPARSER ./input < in ./c++.at:1065: $PREPARSER ./input < in ======== Testing with C++ standard flags: '' ./c++.at:1362: $PREPARSER ./input aaaap ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS exception caught: initial-action stderr: ./c++.at:1361: $PREPARSER ./input aaaas ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: exception caught: reduction ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1555: ./check ./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y ./c++.at:1064: $PREPARSER ./input < in ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ./c++.at:1360: $PREPARSER ./input aaaap ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: stderr: ./c++.at:1361: $PREPARSER ./input aaaal error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffd9be97d0->Object::Object { } 0xffffd9be98b0->Object::Object { 0xffffd9be97d0 } 0xffffd9be97d0->Object::~Object { 0xffffd9be97d0, 0xffffd9be98b0 } Next token is token 'a' (0xffffd9be98b0 'a') 0xffffd9be9810->Object::Object { 0xffffd9be98b0 } 0xffffd9be97c0->Object::Object { 0xffffd9be9810, 0xffffd9be98b0 } 0xffffd9be97c0->Object::~Object { 0xffffd9be97c0, 0xffffd9be9810, 0xffffd9be98b0 } 0xffffd9be98b0->Object::~Object { 0xffffd9be9810, 0xffffd9be98b0 } Shifting token 'a' (0xffffd9be9810 'a') 0xaaaac588c2e0->Object::Object { 0xffffd9be9810 } 0xffffd9be9798->Object::Object { 0xaaaac588c2e0, 0xffffd9be9810 } 0xffffd9be9798->Object::~Object { 0xaaaac588c2e0, 0xffffd9be9798, 0xffffd9be9810 } 0xffffd9be9810->Object::~Object { 0xaaaac588c2e0, 0xffffd9be9810 } Entering state 2 Stack now 0 2 0xffffd9be98d0->Object::Object { 0xaaaac588c2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac588c2e0 'a') -> $$ = nterm item (0xffffd9be98d0 'a') 0xaaaac588c2e0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be98d0 } 0xaaaac588c2e0->Object::Object { 0xffffd9be98d0 } 0xffffd9be9880->Object::Object { 0xaaaac588c2e0, 0xffffd9be98d0 } 0xffffd9be9880->Object::~Object { 0xaaaac588c2e0, 0xffffd9be9880, 0xffffd9be98d0 } 0xffffd9be98d0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be98d0 } Entering state 11 Stack now 0 11 Reading a token 0xffffd9be97d0->Object::Object { 0xaaaac588c2e0 } 0xffffd9be98b0->Object::Object { 0xaaaac588c2e0, 0xffffd9be97d0 } 0xffffd9be97d0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be97d0, 0xffffd9be98b0 } Next token is token 'a' (0xffffd9be98b0 'a') 0xffffd9be9810->Object::Object { 0xaaaac588c2e0, 0xffffd9be98b0 } 0xffffd9be97c0->Object::Object { 0xaaaac588c2e0, 0xffffd9be9810, 0xffffd9be98b0 } 0xffffd9be97c0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be97c0, 0xffffd9be9810, 0xffffd9be98b0 } 0xffffd9be98b0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be9810, 0xffffd9be98b0 } Shifting token 'a' (0xffffd9be9810 'a') 0xaaaac588c300->Object::Object { 0xaaaac588c2e0, 0xffffd9be9810 } 0xffffd9be9798->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9810 } 0xffffd9be9798->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9798, 0xffffd9be9810 } 0xffffd9be9810->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9810 } Entering state 2 Stack now 0 11 2 0xffffd9be98d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac588c300 'a') -> $$ = nterm item (0xffffd9be98d0 'a') 0xaaaac588c300->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98d0 } 0xaaaac588c300->Object::Object { 0xaaaac588c2e0, 0xffffd9be98d0 } 0xffffd9be9880->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98d0 } 0xffffd9be9880->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9880, 0xffffd9be98d0 } 0xffffd9be98d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98d0 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffd9be97d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300 } 0xffffd9be98b0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be97d0 } 0xffffd9be97d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be97d0, 0xffffd9be98b0 } Next token is token 'a' (0xffffd9be98b0 'a') 0xffffd9be9810->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98b0 } 0xffffd9be97c0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9810, 0xffffd9be98b0 } 0xffffd9be97c0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be97c0, 0xffffd9be9810, 0xffffd9be98b0 } 0xffffd9be98b0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9810, 0xffffd9be98b0 } Shifting token 'a' (0xffffd9be9810 'a') 0xaaaac588c320->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9810 } 0xffffd9be9798->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9810 } 0xffffd9be9798->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9798, 0xffffd9be9810 } 0xffffd9be9810->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9810 } Entering state 2 Stack now 0 11 11 2 0xffffd9be98d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac588c320 'a') -> $$ = nterm item (0xffffd9be98d0 'a') 0xaaaac588c320->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98d0 } 0xaaaac588c320->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98d0 } 0xffffd9be9880->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98d0 } 0xffffd9be9880->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9880, 0xffffd9be98d0 } 0xffffd9be98d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98d0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffd9be97d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320 } 0xffffd9be98b0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be97d0 } 0xffffd9be97d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be97d0, 0xffffd9be98b0 } Next token is token 'a' (0xffffd9be98b0 'a') 0xffffd9be9810->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98b0 } 0xffffd9be97c0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9810, 0xffffd9be98b0 } 0xffffd9be97c0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be97c0, 0xffffd9be9810, 0xffffd9be98b0 } 0xffffd9be98b0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9810, 0xffffd9be98b0 } Shifting token 'a' (0xffffd9be9810 'a') 0xaaaac588c340->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9810 } 0xffffd9be9798->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be9810 } 0xffffd9be9798->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be9798, 0xffffd9be9810 } 0xffffd9be9810->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be9810 } Entering state 2 Stack now 0 11 11 11 2 0xffffd9be98d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac588c340 'a') -> $$ = nterm item (0xffffd9be98d0 'a') 0xaaaac588c340->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be98d0 } 0xaaaac588c340->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98d0 } 0xffffd9be9880->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be98d0 } 0xffffd9be9880->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be9880, 0xffffd9be98d0 } 0xffffd9be98d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be98d0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffd9be97d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340 } 0xffffd9be98b0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be97d0 } 0xffffd9be97d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be97d0, 0xffffd9be98b0 } Next token is token 'p' (0xffffd9be98b0 'p'Exception caught: cleaning lookahead and stack 0xaaaac588c340->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be98b0 } 0xaaaac588c320->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98b0 } 0xaaaac588c300->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98b0 } 0xaaaac588c2e0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be98b0 } 0xffffd9be98b0->Object::~Object { 0xffffd9be98b0 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input --debug aaaap exception caught: yylex ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffd9be97d0->Object::Object { } 0xffffd9be98b0->Object::Object { 0xffffd9be97d0 } 0xffffd9be97d0->Object::~Object { 0xffffd9be97d0, 0xffffd9be98b0 } Next token is token 'a' (0xffffd9be98b0 'a') 0xffffd9be9810->Object::Object { 0xffffd9be98b0 } 0xffffd9be97c0->Object::Object { 0xffffd9be9810, 0xffffd9be98b0 } 0xffffd9be97c0->Object::~Object { 0xffffd9be97c0, 0xffffd9be9810, 0xffffd9be98b0 } 0xffffd9be98b0->Object::~Object { 0xffffd9be9810, 0xffffd9be98b0 } Shifting token 'a' (0xffffd9be9810 'a') 0xaaaac588c2e0->Object::Object { 0xffffd9be9810 } 0xffffd9be9798->Object::Object { 0xaaaac588c2e0, 0xffffd9be9810 } 0xffffd9be9798->Object::~Object { 0xaaaac588c2e0, 0xffffd9be9798, 0xffffd9be9810 } 0xffffd9be9810->Object::~Object { 0xaaaac588c2e0, 0xffffd9be9810 } Entering state 2 Stack now 0 2 0xffffd9be98d0->Object::Object { 0xaaaac588c2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac588c2e0 'a') -> $$ = nterm item (0xffffd9be98d0 'a') 0xaaaac588c2e0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be98d0 } 0xaaaac588c2e0->Object::Object { 0xffffd9be98d0 } 0xffffd9be9880->Object::Object { 0xaaaac588c2e0, 0xffffd9be98d0 } 0xffffd9be9880->Object::~Object { 0xaaaac588c2e0, 0xffffd9be9880, 0xffffd9be98d0 } 0xffffd9be98d0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be98d0 } Entering state 11 Stack now 0 11 Reading a token 0xffffd9be97d0->Object::Object { 0xaaaac588c2e0 } 0xffffd9be98b0->Object::Object { 0xaaaac588c2e0, 0xffffd9be97d0 } 0xffffd9be97d0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be97d0, 0xffffd9be98b0 } Next token is token 'a' (0xffffd9be98b0 'a') 0xffffd9be9810->Object::Object { 0xaaaac588c2e0, 0xffffd9be98b0 } 0xffffd9be97c0->Object::Object { 0xaaaac588c2e0, 0xffffd9be9810, 0xffffd9be98b0 } 0xffffd9be97c0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be97c0, 0xffffd9be9810, 0xffffd9be98b0 } 0xffffd9be98b0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be9810, 0xffffd9be98b0 } Shifting token 'a' (0xffffd9be9810 'a') 0xaaaac588c300->Object::Object { 0xaaaac588c2e0, 0xffffd9be9810 } 0xffffd9be9798->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9810 } 0xffffd9be9798->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9798, 0xffffd9be9810 } 0xffffd9be9810->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9810 } Entering state 2 Stack now 0 11 2 0xffffd9be98d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac588c300 'a') -> $$ = nterm item (0xffffd9be98d0 'a') 0xaaaac588c300->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98d0 } 0xaaaac588c300->Object::Object { 0xaaaac588c2e0, 0xffffd9be98d0 } 0xffffd9be9880->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98d0 } 0xffffd9be9880->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9880, 0xffffd9be98d0 } 0xffffd9be98d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98d0 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffd9be97d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300 } 0xffffd9be98b0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be97d0 } 0xffffd9be97d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be97d0, 0xffffd9be98b0 } Next token is token 'a' (0xffffd9be98b0 'a') 0xffffd9be9810->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98b0 } 0xffffd9be97c0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9810, 0xffffd9be98b0 } 0xffffd9be97c0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be97c0, 0xffffd9be9810, 0xffffd9be98b0 } 0xffffd9be98b0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9810, 0xffffd9be98b0 } Shifting token 'a' (0xffffd9be9810 'a') 0xaaaac588c320->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9810 } 0xffffd9be9798->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9810 } 0xffffd9be9798->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9798, 0xffffd9be9810 } 0xffffd9be9810->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9810 } Entering state 2 Stack now 0 11 11 2 0xffffd9be98d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac588c320 'a') -> $$ = nterm item (0xffffd9be98d0 'a') 0xaaaac588c320->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98d0 } 0xaaaac588c320->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98d0 } 0xffffd9be9880->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98d0 } 0xffffd9be9880->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9880, 0xffffd9be98d0 } 0xffffd9be98d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98d0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffd9be97d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320 } 0xffffd9be98b0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be97d0 } 0xffffd9be97d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be97d0, 0xffffd9be98b0 } Next token is token 'a' (0xffffd9be98b0 'a') 0xffffd9be9810->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98b0 } 0xffffd9be97c0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9810, 0xffffd9be98b0 } 0xffffd9be97c0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be97c0, 0xffffd9be9810, 0xffffd9be98b0 } 0xffffd9be98b0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9810, 0xffffd9be98b0 } Shifting token 'a' (0xffffd9be9810 'a') 0xaaaac588c340->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9810 } 0xffffd9be9798->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be9810 } 0xffffd9be9798->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be9798, 0xffffd9be9810 } 0xffffd9be9810->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be9810 } Entering state 2 Stack now 0 11 11 11 2 0xffffd9be98d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac588c340 'a') -> $$ = nterm item (0xffffd9be98d0 'a') 0xaaaac588c340->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be98d0 } 0xaaaac588c340->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98d0 } 0xffffd9be9880->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be98d0 } 0xffffd9be9880->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be9880, 0xffffd9be98d0 } 0xffffd9be98d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be98d0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffd9be97d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340 } 0xffffd9be98b0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be97d0 } 0xffffd9be97d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be97d0, 0xffffd9be98b0 } Next token is token 'p' (0xffffd9be98b0 'p'Exception caught: cleaning lookahead and stack 0xaaaac588c340->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be98b0 } 0xaaaac588c320->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98b0 } 0xaaaac588c300->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98b0 } 0xaaaac588c2e0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be98b0 } 0xffffd9be98b0->Object::~Object { 0xffffd9be98b0 } exception caught: printer end { } ./c++.at:1362: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae stderr: ======== Testing with C++ standard flags: '' stderr: ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS exception caught: syntax error Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaac4531f40->Object::Object { } Next token is token 'a' (0xaaaac4531f40 'a') Shifting token 'a' (0xaaaac4531f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac4531f40 'a') -> $$ = nterm item (0xaaaac4531f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaac4531f90->Object::Object { 0xaaaac4531f40 } Next token is token 'a' (0xaaaac4531f90 'a') Shifting token 'a' (0xaaaac4531f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac4531f90 'a') -> $$ = nterm item (0xaaaac4531f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaac4531fe0->Object::Object { 0xaaaac4531f40, 0xaaaac4531f90 } Next token is token 'a' (0xaaaac4531fe0 'a') Shifting token 'a' (0xaaaac4531fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac4531fe0 'a') -> $$ = nterm item (0xaaaac4531fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaac4532030->Object::Object { 0xaaaac4531f40, 0xaaaac4531f90, 0xaaaac4531fe0 } Next token is token 'a' (0xaaaac4532030 'a') Shifting token 'a' (0xaaaac4532030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac4532030 'a') -> $$ = nterm item (0xaaaac4532030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaac4532080->Object::Object { 0xaaaac4531f40, 0xaaaac4531f90, 0xaaaac4531fe0, 0xaaaac4532030 } Next token is token 'p' (0xaaaac4532080 'p'Exception caught: cleaning lookahead and stack 0xaaaac4532080->Object::~Object { 0xaaaac4531f40, 0xaaaac4531f90, 0xaaaac4531fe0, 0xaaaac4532030, 0xaaaac4532080 } 0xaaaac4532030->Object::~Object { 0xaaaac4531f40, 0xaaaac4531f90, 0xaaaac4531fe0, 0xaaaac4532030 } 0xaaaac4531fe0->Object::~Object { 0xaaaac4531f40, 0xaaaac4531f90, 0xaaaac4531fe0 } 0xaaaac4531f90->Object::~Object { 0xaaaac4531f40, 0xaaaac4531f90 } 0xaaaac4531f40->Object::~Object { 0xaaaac4531f40 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input i ./c++.at:1362: $PREPARSER ./input aaaaE stderr: exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaap stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaac4531f40->Object::Object { } Next token is token 'a' (0xaaaac4531f40 'a') Shifting token 'a' (0xaaaac4531f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac4531f40 'a') -> $$ = nterm item (0xaaaac4531f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaac4531f90->Object::Object { 0xaaaac4531f40 } Next token is token 'a' (0xaaaac4531f90 'a') Shifting token 'a' (0xaaaac4531f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac4531f90 'a') -> $$ = nterm item (0xaaaac4531f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaac4531fe0->Object::Object { 0xaaaac4531f40, 0xaaaac4531f90 } Next token is token 'a' (0xaaaac4531fe0 'a') Shifting token 'a' (0xaaaac4531fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac4531fe0 'a') -> $$ = nterm item (0xaaaac4531fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaac4532030->Object::Object { 0xaaaac4531f40, 0xaaaac4531f90, 0xaaaac4531fe0 } Next token is token 'a' (0xaaaac4532030 'a') Shifting token 'a' (0xaaaac4532030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac4532030 'a') -> $$ = nterm item (0xaaaac4532030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaac4532080->Object::Object { 0xaaaac4531f40, 0xaaaac4531f90, 0xaaaac4531fe0, 0xaaaac4532030 } Next token is token 'p' (0xaaaac4532080 'p'Exception caught: cleaning lookahead and stack 0xaaaac4532080->Object::~Object { 0xaaaac4531f40, 0xaaaac4531f90, 0xaaaac4531fe0, 0xaaaac4532030, 0xaaaac4532080 } 0xaaaac4532030->Object::~Object { 0xaaaac4531f40, 0xaaaac4531f90, 0xaaaac4531fe0, 0xaaaac4532030 } 0xaaaac4531fe0->Object::~Object { 0xaaaac4531f40, 0xaaaac4531f90, 0xaaaac4531fe0 } 0xaaaac4531f90->Object::~Object { 0xaaaac4531f40, 0xaaaac4531f90 } 0xaaaac4531f40->Object::~Object { 0xaaaac4531f40 } exception caught: printer end { } exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: grep '^exception caught: printer$' stderr ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: exception caught: printer stderr: ./c++.at:1360: $PREPARSER ./input aaaae ./c++.at:1361: $PREPARSER ./input --debug aaaap ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./c++.at:1362: $PREPARSER ./input aaaaT stderr: ./c++.at:1463: sed -ne '/INCLUDED/p;/\\file/{p;n;p;}' include/ast/loc.hh stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaab18c6ff40->Object::Object { } Next token is token 'a' (0xaaab18c6ff40 'a') Shifting token 'a' (0xaaab18c6ff40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab18c6ff40 'a') -> $$ = nterm item (0xaaab18c6ff40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaab18c6ff90->Object::Object { 0xaaab18c6ff40 } Next token is token 'a' (0xaaab18c6ff90 'a') Shifting token 'a' (0xaaab18c6ff90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab18c6ff90 'a') -> $$ = nterm item (0xaaab18c6ff90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaab18c6ffe0->Object::Object { 0xaaab18c6ff40, 0xaaab18c6ff90 } Next token is token 'a' (0xaaab18c6ffe0 'a') Shifting token 'a' (0xaaab18c6ffe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab18c6ffe0 'a') -> $$ = nterm item (0xaaab18c6ffe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaab18c70030->Object::Object { 0xaaab18c6ff40, 0xaaab18c6ff90, 0xaaab18c6ffe0 } Next token is token 'a' (0xaaab18c70030 'a') Shifting token 'a' (0xaaab18c70030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab18c70030 'a') -> $$ = nterm item (0xaaab18c70030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaab18c70080->Object::Object { 0xaaab18c6ff40, 0xaaab18c6ff90, 0xaaab18c6ffe0, 0xaaab18c70030 } Next token is token 'p' (0xaaab18c70080 'p'Exception caught: cleaning lookahead and stack 0xaaab18c70080->Object::~Object { 0xaaab18c6ff40, 0xaaab18c6ff90, 0xaaab18c6ffe0, 0xaaab18c70030, 0xaaab18c70080 } 0xaaab18c70030->Object::~Object { 0xaaab18c6ff40, 0xaaab18c6ff90, 0xaaab18c6ffe0, 0xaaab18c70030 } 0xaaab18c6ffe0->Object::~Object { 0xaaab18c6ff40, 0xaaab18c6ff90, 0xaaab18c6ffe0 } 0xaaab18c6ff90->Object::~Object { 0xaaab18c6ff40, 0xaaab18c6ff90 } 0xaaab18c6ff40->Object::~Object { 0xaaab18c6ff40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1471: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o x2.cc x2.yy ./c++.at:1362: $PREPARSER ./input aaaaR ./c++.at:1360: $PREPARSER ./input aaaaE Starting parse Entering state 0 Stack now 0 Reading a token 0xaaab18c6ff40->Object::Object { } Next token is token 'a' (0xaaab18c6ff40 'a') Shifting token 'a' (0xaaab18c6ff40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab18c6ff40 'a') -> $$ = nterm item (0xaaab18c6ff40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaab18c6ff90->Object::Object { 0xaaab18c6ff40 } Next token is token 'a' (0xaaab18c6ff90 'a') Shifting token 'a' (0xaaab18c6ff90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab18c6ff90 'a') -> $$ = nterm item (0xaaab18c6ff90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaab18c6ffe0->Object::Object { 0xaaab18c6ff40, 0xaaab18c6ff90 } Next token is token 'a' (0xaaab18c6ffe0 'a') Shifting token 'a' (0xaaab18c6ffe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab18c6ffe0 'a') -> $$ = nterm item (0xaaab18c6ffe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaab18c70030->Object::Object { 0xaaab18c6ff40, 0xaaab18c6ff90, 0xaaab18c6ffe0 } Next token is token 'a' (0xaaab18c70030 'a') Shifting token 'a' (0xaaab18c70030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab18c70030 'a') -> $$ = nterm item (0xaaab18c70030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaab18c70080->Object::Object { 0xaaab18c6ff40, 0xaaab18c6ff90, 0xaaab18c6ffe0, 0xaaab18c70030 } Next token is token 'p' (0xaaab18c70080 'p'Exception caught: cleaning lookahead and stack 0xaaab18c70080->Object::~Object { 0xaaab18c6ff40, 0xaaab18c6ff90, 0xaaab18c6ffe0, 0xaaab18c70030, 0xaaab18c70080 } 0xaaab18c70030->Object::~Object { 0xaaab18c6ff40, 0xaaab18c6ff90, 0xaaab18c6ffe0, 0xaaab18c70030 } 0xaaab18c6ffe0->Object::~Object { 0xaaab18c6ff40, 0xaaab18c6ff90, 0xaaab18c6ffe0 } 0xaaab18c6ff90->Object::~Object { 0xaaab18c6ff40, 0xaaab18c6ff90 } 0xaaab18c6ff40->Object::~Object { 0xaaab18c6ff40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr stderr: stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: exception caught: syntax error, unexpected end of file, expecting 'a' exception caught: printer stdout: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaae ======== Testing with C++ standard flags: '' ./c++.at:856: $PREPARSER ./input ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stderr: exception caught: syntax error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1471: $CXX $CPPFLAGS $CXXFLAGS -Iinclude -c -o x2.o x2.cc ./c++.at:1360: $PREPARSER ./input aaaaT ./c++.at:1361: $PREPARSER ./input aaaaE stderr: stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaT ./c++.at:1360: $PREPARSER ./input aaaaR stderr: stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaR ======== Testing with C++ standard flags: '' stderr: ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:850: $PREPARSER ./input stderr: ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1501: $CXX $CPPFLAGS $CXXFLAGS -Iinclude $LDFLAGS -o parser x[12].o main.cc $LIBS stderr: stdout: ======== Testing with C++ standard flags: '' ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:856: $PREPARSER ./input stderr: ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1363: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: $PREPARSER ./input aaaap stdout: ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffff6d941c0->Object::Object { } 0xfffff6d942a0->Object::Object { 0xfffff6d941c0 } 0xfffff6d941c0->Object::~Object { 0xfffff6d941c0, 0xfffff6d942a0 } Next token is token 'a' (0xfffff6d942a0 'a') 0xfffff6d94200->Object::Object { 0xfffff6d942a0 } 0xfffff6d941b0->Object::Object { 0xfffff6d94200, 0xfffff6d942a0 } 0xfffff6d941b0->Object::~Object { 0xfffff6d941b0, 0xfffff6d94200, 0xfffff6d942a0 } 0xfffff6d942a0->Object::~Object { 0xfffff6d94200, 0xfffff6d942a0 } Shifting token 'a' (0xfffff6d94200 'a') 0xaaab128012e0->Object::Object { 0xfffff6d94200 } 0xfffff6d94188->Object::Object { 0xaaab128012e0, 0xfffff6d94200 } 0xfffff6d94188->Object::~Object { 0xaaab128012e0, 0xfffff6d94188, 0xfffff6d94200 } 0xfffff6d94200->Object::~Object { 0xaaab128012e0, 0xfffff6d94200 } Entering state 1 Stack now 0 1 0xfffff6d942c0->Object::Object { 0xaaab128012e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab128012e0 'a') -> $$ = nterm item (0xfffff6d942c0 'a') 0xaaab128012e0->Object::~Object { 0xaaab128012e0, 0xfffff6d942c0 } 0xaaab128012e0->Object::Object { 0xfffff6d942c0 } 0xfffff6d94270->Object::Object { 0xaaab128012e0, 0xfffff6d942c0 } 0xfffff6d94270->Object::~Object { 0xaaab128012e0, 0xfffff6d94270, 0xfffff6d942c0 } 0xfffff6d942c0->Object::~Object { 0xaaab128012e0, 0xfffff6d942c0 } Entering state 10 Stack now 0 10 Reading a token 0xfffff6d941c0->Object::Object { 0xaaab128012e0 } 0xfffff6d942a0->Object::Object { 0xaaab128012e0, 0xfffff6d941c0 } 0xfffff6d941c0->Object::~Object { 0xaaab128012e0, 0xfffff6d941c0, 0xfffff6d942a0 } Next token is token 'a' (0xfffff6d942a0 'a') 0xfffff6d94200->Object::Object { 0xaaab128012e0, 0xfffff6d942a0 } 0xfffff6d941b0->Object::Object { 0xaaab128012e0, 0xfffff6d94200, 0xfffff6d942a0 } 0xfffff6d941b0->Object::~Object { 0xaaab128012e0, 0xfffff6d941b0, 0xfffff6d94200, 0xfffff6d942a0 } 0xfffff6d942a0->Object::~Object { 0xaaab128012e0, 0xfffff6d94200, 0xfffff6d942a0 } Shifting token 'a' (0xfffff6d94200 'a') 0xaaab12801300->Object::Object { 0xaaab128012e0, 0xfffff6d94200 } 0xfffff6d94188->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94200 } 0xfffff6d94188->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94188, 0xfffff6d94200 } 0xfffff6d94200->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94200 } Entering state 1 Stack now 0 10 1 0xfffff6d942c0->Object::Object { 0xaaab128012e0, 0xaaab12801300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab12801300 'a') -> $$ = nterm item (0xfffff6d942c0 'a') 0xaaab12801300->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942c0 } 0xaaab12801300->Object::Object { 0xaaab128012e0, 0xfffff6d942c0 } 0xfffff6d94270->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942c0 } 0xfffff6d94270->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94270, 0xfffff6d942c0 } 0xfffff6d942c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942c0 } Entering state 10 Stack now 0 10 10 Reading a token 0xfffff6d941c0->Object::Object { 0xaaab128012e0, 0xaaab12801300 } 0xfffff6d942a0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d941c0 } 0xfffff6d941c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d941c0, 0xfffff6d942a0 } Next token is token 'a' (0xfffff6d942a0 'a') 0xfffff6d94200->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942a0 } 0xfffff6d941b0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94200, 0xfffff6d942a0 } 0xfffff6d941b0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d941b0, 0xfffff6d94200, 0xfffff6d942a0 } 0xfffff6d942a0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94200, 0xfffff6d942a0 } Shifting token 'a' (0xfffff6d94200 'a') 0xaaab12801320->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94200 } 0xfffff6d94188->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94200 } 0xfffff6d94188->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94188, 0xfffff6d94200 } 0xfffff6d94200->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94200 } Entering state 1 Stack now 0 10 10 1 0xfffff6d942c0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab12801320 'a') -> $$ = nterm item (0xfffff6d942c0 'a') 0xaaab12801320->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942c0 } 0xaaab12801320->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942c0 } 0xfffff6d94270->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942c0 } 0xfffff6d94270->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94270, 0xfffff6d942c0 } 0xfffff6d942c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942c0 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xfffff6d941c0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320 } 0xfffff6d942a0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d941c0 } 0xfffff6d941c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d941c0, 0xfffff6d942a0 } Next token is token 'a' (0xfffff6d942a0 'a') 0xfffff6d94200->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942a0 } 0xfffff6d941b0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94200, 0xfffff6d942a0 } 0xfffff6d941b0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d941b0, 0xfffff6d94200, 0xfffff6d942a0 } 0xfffff6d942a0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94200, 0xfffff6d942a0 } Shifting token 'a' (0xfffff6d94200 'a') 0xaaab12801340->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94200 } 0xfffff6d94188->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d94200 } 0xfffff6d94188->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d94188, 0xfffff6d94200 } 0xfffff6d94200->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d94200 } Entering state 1 Stack now 0 10 10 10 1 0xfffff6d942c0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab12801340 'a') -> $$ = nterm item (0xfffff6d942c0 'a') 0xaaab12801340->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d942c0 } 0xaaab12801340->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942c0 } 0xfffff6d94270->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d942c0 } 0xfffff6d94270->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d94270, 0xfffff6d942c0 } 0xfffff6d942c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d942c0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xfffff6d941c0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340 } 0xfffff6d942a0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d941c0 } 0xfffff6d941c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d941c0, 0xfffff6d942a0 } Next token is token 'p' (0xfffff6d942a0 'p'Exception caught: cleaning lookahead and stack 0xaaab12801340->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d942a0 } 0xaaab12801320->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942a0 } 0xaaab12801300->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942a0 } 0xaaab128012e0->Object::~Object { 0xaaab128012e0, 0xfffff6d942a0 } 0xfffff6d942a0->Object::~Object { 0xfffff6d942a0 } exception caught: printer end { } ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffff6d941c0->Object::Object { } 0xfffff6d942a0->Object::Object { 0xfffff6d941c0 } 0xfffff6d941c0->Object::~Object { 0xfffff6d941c0, 0xfffff6d942a0 } Next token is token 'a' (0xfffff6d942a0 'a') 0xfffff6d94200->Object::Object { 0xfffff6d942a0 } 0xfffff6d941b0->Object::Object { 0xfffff6d94200, 0xfffff6d942a0 } 0xfffff6d941b0->Object::~Object { 0xfffff6d941b0, 0xfffff6d94200, 0xfffff6d942a0 } 0xfffff6d942a0->Object::~Object { 0xfffff6d94200, 0xfffff6d942a0 } Shifting token 'a' (0xfffff6d94200 'a') 0xaaab128012e0->Object::Object { 0xfffff6d94200 } 0xfffff6d94188->Object::Object { 0xaaab128012e0, 0xfffff6d94200 } 0xfffff6d94188->Object::~Object { 0xaaab128012e0, 0xfffff6d94188, 0xfffff6d94200 } 0xfffff6d94200->Object::~Object { 0xaaab128012e0, 0xfffff6d94200 } Entering state 1 Stack now 0 1 0xfffff6d942c0->Object::Object { 0xaaab128012e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab128012e0 'a') -> $$ = nterm item (0xfffff6d942c0 'a') 0xaaab128012e0->Object::~Object { 0xaaab128012e0, 0xfffff6d942c0 } 0xaaab128012e0->Object::Object { 0xfffff6d942c0 } 0xfffff6d94270->Object::Object { 0xaaab128012e0, 0xfffff6d942c0 } 0xfffff6d94270->Object::~Object { 0xaaab128012e0, 0xfffff6d94270, 0xfffff6d942c0 } 0xfffff6d942c0->Object::~Object { 0xaaab128012e0, 0xfffff6d942c0 } Entering state 10 Stack now 0 10 Reading a token 0xfffff6d941c0->Object::Object { 0xaaab128012e0 } 0xfffff6d942a0->Object::Object { 0xaaab128012e0, 0xfffff6d941c0 } 0xfffff6d941c0->Object::~Object { 0xaaab128012e0, 0xfffff6d941c0, 0xfffff6d942a0 } Next token is token 'a' (0xfffff6d942a0 'a') 0xfffff6d94200->Object::Object { 0xaaab128012e0, 0xfffff6d942a0 } 0xfffff6d941b0->Object::Object { 0xaaab128012e0, 0xfffff6d94200, 0xfffff6d942a0 } 0xfffff6d941b0->Object::~Object { 0xaaab128012e0, 0xfffff6d941b0, 0xfffff6d94200, 0xfffff6d942a0 } 0xfffff6d942a0->Object::~Object { 0xaaab128012e0, 0xfffff6d94200, 0xfffff6d942a0 } Shifting token 'a' (0xfffff6d94200 'a') 0xaaab12801300->Object::Object { 0xaaab128012e0, 0xfffff6d94200 } 0xfffff6d94188->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94200 } 0xfffff6d94188->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94188, 0xfffff6d94200 } 0xfffff6d94200->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94200 } Entering state 1 Stack now 0 10 1 0xfffff6d942c0->Object::Object { 0xaaab128012e0, 0xaaab12801300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab12801300 'a') -> $$ = nterm item (0xfffff6d942c0 'a') 0xaaab12801300->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942c0 } 0xaaab12801300->Object::Object { 0xaaab128012e0, 0xfffff6d942c0 } 0xfffff6d94270->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942c0 } 0xfffff6d94270->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94270, 0xfffff6d942c0 } 0xfffff6d942c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942c0 } Entering state 10 Stack now 0 10 10 Reading a token 0xfffff6d941c0->Object::Object { 0xaaab128012e0, 0xaaab12801300 } 0xfffff6d942a0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d941c0 } 0xfffff6d941c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d941c0, 0xfffff6d942a0 } Next token is token 'a' (0xfffff6d942a0 'a') 0xfffff6d94200->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942a0 } 0xfffff6d941b0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94200, 0xfffff6d942a0 } 0xfffff6d941b0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d941b0, 0xfffff6d94200, 0xfffff6d942a0 } 0xfffff6d942a0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94200, 0xfffff6d942a0 } Shifting token 'a' (0xfffff6d94200 'a') 0xaaab12801320->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94200 } 0xfffff6d94188->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94200 } 0xfffff6d94188->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94188, 0xfffff6d94200 } 0xfffff6d94200->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94200 } Entering state 1 Stack now 0 10 10 1 0xfffff6d942c0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab12801320 'a') -> $$ = nterm item (0xfffff6d942c0 'a') 0xaaab12801320->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942c0 } 0xaaab12801320->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942c0 } 0xfffff6d94270->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942c0 } 0xfffff6d94270->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94270, 0xfffff6d942c0 } 0xfffff6d942c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942c0 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xfffff6d941c0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320 } 0xfffff6d942a0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d941c0 } 0xfffff6d941c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d941c0, 0xfffff6d942a0 } Next token is token 'a' (0xfffff6d942a0 'a') 0xfffff6d94200->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942a0 } 0xfffff6d941b0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94200, 0xfffff6d942a0 } 0xfffff6d941b0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d941b0, 0xfffff6d94200, 0xfffff6d942a0 } 0xfffff6d942a0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94200, 0xfffff6d942a0 } Shifting token 'a' (0xfffff6d94200 'a') 0xaaab12801340->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94200 } 0xfffff6d94188->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d94200 } 0xfffff6d94188->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d94188, 0xfffff6d94200 } 0xfffff6d94200->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d94200 } Entering state 1 Stack now 0 10 10 10 1 0xfffff6d942c0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab12801340 'a') -> $$ = nterm item (0xfffff6d942c0 'a') 0xaaab12801340->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d942c0 } 0xaaab12801340->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942c0 } 0xfffff6d94270->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d942c0 } 0xfffff6d94270->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d94270, 0xfffff6d942c0 } 0xfffff6d942c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d942c0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xfffff6d941c0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340 } 0xfffff6d942a0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d941c0 } 0xfffff6d941c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d941c0, 0xfffff6d942a0 } Next token is token 'p' (0xfffff6d942a0 'p'Exception caught: cleaning lookahead and stack 0xaaab12801340->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d942a0 } 0xaaab12801320->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942a0 } 0xaaab12801300->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942a0 } 0xaaab128012e0->Object::~Object { 0xaaab128012e0, 0xfffff6d942a0 } 0xfffff6d942a0->Object::~Object { 0xfffff6d942a0 } exception caught: printer end { } ./c++.at:1363: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1363: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: $PREPARSER ./input aaaaE stdout: stderr: ./c++.at:1065: $PREPARSER ./input < in exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaT stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in stderr: ./c++.at:1363: $PREPARSER ./input aaaaR error: invalid expression stderr: ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: ./c++.at:1065: $PREPARSER ./input < in stdout: ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1361: $PREPARSER ./input aaaas stderr: stderr: error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: reduction ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1361: $PREPARSER ./input aaaal ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: exception caught: yylex ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stdout: ./c++.at:1361: $PREPARSER ./input i stdout: ./c++.at:1502: $PREPARSER ./parser ./c++.at:1555: $PREPARSER ./test stderr: stderr: exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1502: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaap 690. c++.at:1422: ok ======== Testing with C++ standard flags: '' stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./c++.at:1361: $PREPARSER ./input --debug aaaap stdout: ./c++.at:850: $PREPARSER ./input stderr: stderr: ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS Starting parse Entering state 0 Stack now 0 Reading a token 0xaaab08058f40->Object::Object { } Next token is token 'a' (0xaaab08058f40 'a') Shifting token 'a' (0xaaab08058f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab08058f40 'a') -> $$ = nterm item (0xaaab08058f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaab08058f90->Object::Object { 0xaaab08058f40 } Next token is token 'a' (0xaaab08058f90 'a') Shifting token 'a' (0xaaab08058f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab08058f90 'a') -> $$ = nterm item (0xaaab08058f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaab08058fe0->Object::Object { 0xaaab08058f40, 0xaaab08058f90 } Next token is token 'a' (0xaaab08058fe0 'a') Shifting token 'a' (0xaaab08058fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab08058fe0 'a') -> $$ = nterm item (0xaaab08058fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaab08059030->Object::Object { 0xaaab08058f40, 0xaaab08058f90, 0xaaab08058fe0 } Next token is token 'a' (0xaaab08059030 'a') Shifting token 'a' (0xaaab08059030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab08059030 'a') -> $$ = nterm item (0xaaab08059030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaab08059080->Object::Object { 0xaaab08058f40, 0xaaab08058f90, 0xaaab08058fe0, 0xaaab08059030 } Next token is token 'p' (0xaaab08059080 'p'Exception caught: cleaning lookahead and stack 0xaaab08059080->Object::~Object { 0xaaab08058f40, 0xaaab08058f90, 0xaaab08058fe0, 0xaaab08059030, 0xaaab08059080 } 0xaaab08059030->Object::~Object { 0xaaab08058f40, 0xaaab08058f90, 0xaaab08058fe0, 0xaaab08059030 } 0xaaab08058fe0->Object::~Object { 0xaaab08058f40, 0xaaab08058f90, 0xaaab08058fe0 } 0xaaab08058f90->Object::~Object { 0xaaab08058f40, 0xaaab08058f90 } 0xaaab08058f40->Object::~Object { 0xaaab08058f40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaab08058f40->Object::Object { } Next token is token 'a' (0xaaab08058f40 'a') Shifting token 'a' (0xaaab08058f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab08058f40 'a') -> $$ = nterm item (0xaaab08058f40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaab08058f90->Object::Object { 0xaaab08058f40 } Next token is token 'a' (0xaaab08058f90 'a') Shifting token 'a' (0xaaab08058f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab08058f90 'a') -> $$ = nterm item (0xaaab08058f90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaab08058fe0->Object::Object { 0xaaab08058f40, 0xaaab08058f90 } Next token is token 'a' (0xaaab08058fe0 'a') Shifting token 'a' (0xaaab08058fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab08058fe0 'a') -> $$ = nterm item (0xaaab08058fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaab08059030->Object::Object { 0xaaab08058f40, 0xaaab08058f90, 0xaaab08058fe0 } Next token is token 'a' (0xaaab08059030 'a') Shifting token 'a' (0xaaab08059030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab08059030 'a') -> $$ = nterm item (0xaaab08059030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaab08059080->Object::Object { 0xaaab08058f40, 0xaaab08058f90, 0xaaab08058fe0, 0xaaab08059030 } Next token is token 'p' (0xaaab08059080 'p'Exception caught: cleaning lookahead and stack 0xaaab08059080->Object::~Object { 0xaaab08058f40, 0xaaab08058f90, 0xaaab08058fe0, 0xaaab08059030, 0xaaab08059080 } 0xaaab08059030->Object::~Object { 0xaaab08058f40, 0xaaab08058f90, 0xaaab08058fe0, 0xaaab08059030 } 0xaaab08058fe0->Object::~Object { 0xaaab08058f40, 0xaaab08058f90, 0xaaab08058fe0 } 0xaaab08058f90->Object::~Object { 0xaaab08058f40, 0xaaab08058f90 } 0xaaab08058f40->Object::~Object { 0xaaab08058f40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1361: $PREPARSER ./input aaaae stderr: stderr: exception caught: syntax error stdout: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1555: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' 692. java.at:25: testing Java invalid directives ... ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./java.at:35: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret YYParser.y ./c++.at:1361: $PREPARSER ./input aaaaE stderr: stderr: stdout: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1066: $PREPARSER ./input < in ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1361: $PREPARSER ./input aaaaT ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1066: $PREPARSER ./input < in ./c++.at:1361: $PREPARSER ./input aaaaR stdout: stderr: stderr: ./c++.at:1555: ./check stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: -std=c++03 not supported ======== Testing with C++ standard flags: '' ./java.at:50: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret YYParser.y error: invalid expression ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' 692. java.at:25: ok ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./c++.at:1555: ./check stderr: -std=c++11 not supported ======== Testing with C++ standard flags: '' stdout: ./c++.at:1360: $PREPARSER ./input aaaas ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1360: $PREPARSER ./input aaaal stdout: ./c++.at:1362: $PREPARSER ./input aaaas stderr: stderr: exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: stderr: exception caught: yylex ./c++.at:1066: ./check ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 693. java.at:186: testing Java parser class and package names ... ./java.at:188: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y ./c++.at:1362: $PREPARSER ./input aaaal stderr: ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input i stderr: stderr: exception caught: initial-action ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1362: $PREPARSER ./input i ./c++.at:1555: ./check stderr: ./java.at:188: grep '[mb]4_' YYParser.y ./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y ./c++.at:1360: $PREPARSER ./input aaaap stdout: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 693. java.at:186: ./c++.at:1360: $PREPARSER ./input --debug aaaap skipped (java.at:188) ./c++.at:1362: $PREPARSER ./input aaaap stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaf0d03f40->Object::Object { } Next token is token 'a' (0xaaaaf0d03f40 'a') Shifting token 'a' (0xaaaaf0d03f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf0d03f40 'a') -> $$ = nterm item (0xaaaaf0d03f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaaf0d03f90->Object::Object { 0xaaaaf0d03f40 } Next token is token 'a' (0xaaaaf0d03f90 'a') Shifting token 'a' (0xaaaaf0d03f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf0d03f90 'a') -> $$ = nterm item (0xaaaaf0d03f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaaf0d03fe0->Object::Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90 } Next token is token 'a' (0xaaaaf0d03fe0 'a') Shifting token 'a' (0xaaaaf0d03fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf0d03fe0 'a') -> $$ = nterm item (0xaaaaf0d03fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaaf0d04030->Object::Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90, 0xaaaaf0d03fe0 } Next token is token 'a' (0xaaaaf0d04030 'a') Shifting token 'a' (0xaaaaf0d04030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf0d04030 'a') -> $$ = nterm item (0xaaaaf0d04030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaaf0d04080->Object::Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90, 0xaaaaf0d03fe0, 0xaaaaf0d04030 } Next token is token 'p' (0xaaaaf0d04080 'p'Exception caught: cleaning lookahead and stack 0xaaaaf0d04080->Object::~Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90, 0xaaaaf0d03fe0, 0xaaaaf0d04030, 0xaaaaf0d04080 } 0xaaaaf0d04030->Object::~Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90, 0xaaaaf0d03fe0, 0xaaaaf0d04030 } 0xaaaaf0d03fe0->Object::~Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90, 0xaaaaf0d03fe0 } 0xaaaaf0d03f90->Object::~Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90 } 0xaaaaf0d03f40->Object::~Object { 0xaaaaf0d03f40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc16e24a0->Object::Object { } 0xffffc16e2580->Object::Object { 0xffffc16e24a0 } 0xffffc16e24a0->Object::~Object { 0xffffc16e24a0, 0xffffc16e2580 } Next token is token 'a' (0xffffc16e2580 'a') 0xffffc16e24e0->Object::Object { 0xffffc16e2580 } 0xffffc16e2490->Object::Object { 0xffffc16e24e0, 0xffffc16e2580 } 0xffffc16e2490->Object::~Object { 0xffffc16e2490, 0xffffc16e24e0, 0xffffc16e2580 } 0xffffc16e2580->Object::~Object { 0xffffc16e24e0, 0xffffc16e2580 } Shifting token 'a' (0xffffc16e24e0 'a') 0xaaaad44a52e0->Object::Object { 0xffffc16e24e0 } 0xffffc16e2468->Object::Object { 0xaaaad44a52e0, 0xffffc16e24e0 } 0xffffc16e2468->Object::~Object { 0xaaaad44a52e0, 0xffffc16e2468, 0xffffc16e24e0 } 0xffffc16e24e0->Object::~Object { 0xaaaad44a52e0, 0xffffc16e24e0 } Entering state 2 Stack now 0 2 0xffffc16e25a0->Object::Object { 0xaaaad44a52e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaad44a52e0 'a') -> $$ = nterm item (0xffffc16e25a0 'a') 0xaaaad44a52e0->Object::~Object { 0xaaaad44a52e0, 0xffffc16e25a0 } 0xaaaad44a52e0->Object::Object { 0xffffc16e25a0 } 0xffffc16e2550->Object::Object { 0xaaaad44a52e0, 0xffffc16e25a0 } 0xffffc16e2550->Object::~Object { 0xaaaad44a52e0, 0xffffc16e2550, 0xffffc16e25a0 } 0xffffc16e25a0->Object::~Object { 0xaaaad44a52e0, 0xffffc16e25a0 } Entering state 11 Stack now 0 11 Reading a token 0xffffc16e24a0->Object::Object { 0xaaaad44a52e0 } 0xffffc16e2580->Object::Object { 0xaaaad44a52e0, 0xffffc16e24a0 } 0xffffc16e24a0->Object::~Object { 0xaaaad44a52e0, 0xffffc16e24a0, 0xffffc16e2580 } Next token is token 'a' (0xffffc16e2580 'a') 0xffffc16e24e0->Object::Object { 0xaaaad44a52e0, 0xffffc16e2580 } 0xffffc16e2490->Object::Object { 0xaaaad44a52e0, 0xffffc16e24e0, 0xffffc16e2580 } 0xffffc16e2490->Object::~Object { 0xaaaad44a52e0, 0xffffc16e2490, 0xffffc16e24e0, 0xffffc16e2580 } 0xffffc16e2580->Object::~Object { 0xaaaad44a52e0, 0xffffc16e24e0, 0xffffc16e2580 } Shifting token 'a' (0xffffc16e24e0 'a') 0xaaaad44a5300->Object::Object { 0xaaaad44a52e0, 0xffffc16e24e0 } 0xffffc16e2468->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24e0 } 0xffffc16e2468->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e2468, 0xffffc16e24e0 } 0xffffc16e24e0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24e0 } Entering state 2 Stack now 0 11 2 0xffffc16e25a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaad44a5300 'a') -> $$ = nterm item (0xffffc16e25a0 'a') 0xaaaad44a5300->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e25a0 } 0xaaaad44a5300->Object::Object { 0xaaaad44a52e0, 0xffffc16e25a0 } 0xffffc16e2550->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e25a0 } 0xffffc16e2550->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e2550, 0xffffc16e25a0 } 0xffffc16e25a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e25a0 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffc16e24a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300 } 0xffffc16e2580->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24a0 } 0xffffc16e24a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24a0, 0xffffc16e2580 } Next token is token 'a' (0xffffc16e2580 'a') 0xffffc16e24e0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e2580 } 0xffffc16e2490->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24e0, 0xffffc16e2580 } 0xffffc16e2490->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e2490, 0xffffc16e24e0, 0xffffc16e2580 } 0xffffc16e2580->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24e0, 0xffffc16e2580 } Shifting token 'a' (0xffffc16e24e0 'a') 0xaaaad44a5320->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24e0 } 0xffffc16e2468->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24e0 } 0xffffc16e2468->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e2468, 0xffffc16e24e0 } 0xffffc16e24e0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24e0 } Entering state 2 Stack now 0 11 11 2 0xffffc16e25a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaad44a5320 'a') -> $$ = nterm item (0xffffc16e25a0 'a') 0xaaaad44a5320->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e25a0 } 0xaaaad44a5320->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e25a0 } 0xffffc16e2550->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e25a0 } 0xffffc16e2550->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e2550, 0xffffc16e25a0 } 0xffffc16e25a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e25a0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffc16e24a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320 } 0xffffc16e2580->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24a0 } 0xffffc16e24a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24a0, 0xffffc16e2580 } Next token is token 'a' (0xffffc16e2580 'a') 0xffffc16e24e0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e2580 } 0xffffc16e2490->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24e0, 0xffffc16e2580 } 0xffffc16e2490->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e2490, 0xffffc16e24e0, 0xffffc16e2580 } 0xffffc16e2580->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24e0, 0xffffc16e2580 } Shifting token 'a' (0xffffc16e24e0 'a') 0xaaaad44a5340->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24e0 } 0xffffc16e2468->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e24e0 } 0xffffc16e2468->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e2468, 0xffffc16e24e0 } 0xffffc16e24e0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e24e0 } Entering state 2 Stack now 0 11 11 11 2 0xffffc16e25a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaad44a5340 'a') -> $$ = nterm item (0xffffc16e25a0 'a') 0xaaaad44a5340->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e25a0 } 0xaaaad44a5340->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e25a0 } 0xffffc16e2550->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e25a0 } 0xffffc16e2550->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e2550, 0xffffc16e25a0 } 0xffffc16e25a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e25a0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffc16e24a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340 } 0xffffc16e2580->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e24a0 } 0xffffc16e24a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e24a0, 0xffffc16e2580 } Next token is token 'p' (0xffffc16e2580 'p'Exception caught: cleaning lookahead and stack 0xaaaad44a5340->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e2580 } 0xaaaad44a5320->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e2580 } 0xaaaad44a5300->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e2580 } 0xaaaad44a52e0->Object::~Object { 0xaaaad44a52e0, 0xffffc16e2580 } 0xffffc16e2580->Object::~Object { 0xffffc16e2580 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc16e24a0->Object::Object { } 0xffffc16e2580->Object::Object { 0xffffc16e24a0 } 0xffffc16e24a0->Object::~Object { 0xffffc16e24a0, 0xffffc16e2580 } Next token is token 'a' (0xffffc16e2580 'a') 0xffffc16e24e0->Object::Object { 0xffffc16e2580 } 0xffffc16e2490->Object::Object { 0xffffc16e24e0, 0xffffc16e2580 } 0xffffc16e2490->Object::~Object { 0xffffc16e2490, 0xffffc16e24e0, 0xffffc16e2580 } 0xffffc16e2580->Object::~Object { 0xffffc16e24e0, 0xffffc16e2580 } Shifting token 'a' (0xffffc16e24e0 'a') 0xaaaad44a52e0->Object::Object { 0xffffc16e24e0 } 0xffffc16e2468->Object::Object { 0xaaaad44a52e0, 0xffffc16e24e0 } 0xffffc16e2468->Object::~Object { 0xaaaad44a52e0, 0xffffc16e2468, 0xffffc16e24e0 } 0xffffc16e24e0->Object::~Object { 0xaaaad44a52e0, 0xffffc16e24e0 } Entering state 2 Stack now 0 2 0xffffc16e25a0->Object::Object { 0xaaaad44a52e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaad44a52e0 'a') -> $$ = nterm item (0xffffc16e25a0 'a') 0xaaaad44a52e0->Object::~Object { 0xaaaad44a52e0, 0xffffc16e25a0 } 0xaaaad44a52e0->Object::Object { 0xffffc16e25a0 } 0xffffc16e2550->Object::Object { 0xaaaad44a52e0, 0xffffc16e25a0 } 0xffffc16e2550->Object::~Object { 0xaaaad44a52e0, 0xffffc16e2550, 0xffffc16e25a0 } 0xffffc16e25a0->Object::~Object { 0xaaaad44a52e0, 0xffffc16e25a0 } Entering state 11 Stack now 0 11 Reading a token 0xffffc16e24a0->Object::Object { 0xaaaad44a52e0 } 0xffffc16e2580->Object::Object { 0xaaaad44a52e0, 0xffffc16e24a0 } 0xffffc16e24a0->Object::~Object { 0xaaaad44a52e0, 0xffffc16e24a0, 0xffffc16e2580 } Next token is token 'a' (0xffffc16e2580 'a') 0xffffc16e24e0->Object::Object { 0xaaaad44a52e0, 0xffffc16e2580 } 0xffffc16e2490->Object::Object { 0xaaaad44a52e0, 0xffffc16e24e0, 0xffffc16e2580 } 0xffffc16e2490->Object::~Object { 0xaaaad44a52e0, 0xffffc16e2490, 0xffffc16e24e0, 0xffffc16e2580 } 0xffffc16e2580->Object::~Object { 0xaaaad44a52e0, 0xffffc16e24e0, 0xffffc16e2580 } Shifting token 'a' (0xffffc16e24e0 'a') 0xaaaad44a5300->Object::Object { 0xaaaad44a52e0, 0xffffc16e24e0 } 0xffffc16e2468->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24e0 } 0xffffc16e2468->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e2468, 0xffffc16e24e0 } 0xffffc16e24e0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24e0 } Entering state 2 Stack now 0 11 2 0xffffc16e25a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaad44a5300 'a') -> $$ = nterm item (0xffffc16e25a0 'a') 0xaaaad44a5300->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e25a0 } 0xaaaad44a5300->Object::Object { 0xaaaad44a52e0, 0xffffc16e25a0 } 0xffffc16e2550->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e25a0 } 0xffffc16e2550->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e2550, 0xffffc16e25a0 } 0xffffc16e25a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e25a0 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffc16e24a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300 } 0xffffc16e2580->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24a0 } 0xffffc16e24a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24a0, 0xffffc16e2580 } Next token is token 'a' (0xffffc16e2580 'a') 0xffffc16e24e0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e2580 } 0xffffc16e2490->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24e0, 0xffffc16e2580 } 0xffffc16e2490->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e2490, 0xffffc16e24e0, 0xffffc16e2580 } 0xffffc16e2580->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24e0, 0xffffc16e2580 } Shifting token 'a' (0xffffc16e24e0 'a') 0xaaaad44a5320->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24e0 } 0xffffc16e2468->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24e0 } 0xffffc16e2468->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e2468, 0xffffc16e24e0 } 0xffffc16e24e0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24e0 } Entering state 2 Stack now 0 11 11 2 0xffffc16e25a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaad44a5320 'a') -> $$ = nterm item (0xffffc16e25a0 'a') 0xaaaad44a5320->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e25a0 } 0xaaaad44a5320->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e25a0 } 0xffffc16e2550->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e25a0 } 0xffffc16e2550->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e2550, 0xffffc16e25a0 } 0xffffc16e25a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e25a0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffc16e24a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320 } 0xffffc16e2580->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24a0 } 0xffffc16e24a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24a0, 0xffffc16e2580 } Next token is token 'a' (0xffffc16e2580 'a') 0xffffc16e24e0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e2580 } 0xffffc16e2490->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24e0, 0xffffc16e2580 } 0xffffc16e2490->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e2490, 0xffffc16e24e0, 0xffffc16e2580 } 0xffffc16e2580->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24e0, 0xffffc16e2580 } Shifting token 'a' (0xffffc16e24e0 'a') 0xaaaad44a5340->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24e0 } 0xffffc16e2468->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e24e0 } 0xffffc16e2468->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e2468, 0xffffc16e24e0 } 0xffffc16e24e0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e24e0 } Entering state 2 Stack now 0 11 11 11 2 0xffffc16e25a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaad44a5340 'a') -> $$ = nterm item (0xffffc16e25a0 'a') 0xaaaad44a5340->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e25a0 } 0xaaaad44a5340->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e25a0 } 0xffffc16e2550->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e25a0 } 0xffffc16e2550->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e2550, 0xffffc16e25a0 } 0xffffc16e25a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e25a0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffc16e24a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340 } 0xffffc16e2580->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e24a0 } 0xffffc16e24a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e24a0, 0xffffc16e2580 } Next token is token 'p' (0xffffc16e2580 'p'Exception caught: cleaning lookahead and stack 0xaaaad44a5340->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e2580 } 0xaaaad44a5320->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e2580 } 0xaaaad44a5300->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e2580 } 0xaaaad44a52e0->Object::~Object { 0xaaaad44a52e0, 0xffffc16e2580 } 0xffffc16e2580->Object::~Object { 0xffffc16e2580 } exception caught: printer end { } ./c++.at:1362: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaf0d03f40->Object::Object { } Next token is token 'a' (0xaaaaf0d03f40 'a') Shifting token 'a' (0xaaaaf0d03f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf0d03f40 'a') -> $$ = nterm item (0xaaaaf0d03f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaaf0d03f90->Object::Object { 0xaaaaf0d03f40 } Next token is token 'a' (0xaaaaf0d03f90 'a') Shifting token 'a' (0xaaaaf0d03f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf0d03f90 'a') -> $$ = nterm item (0xaaaaf0d03f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaaf0d03fe0->Object::Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90 } Next token is token 'a' (0xaaaaf0d03fe0 'a') Shifting token 'a' (0xaaaaf0d03fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf0d03fe0 'a') -> $$ = nterm item (0xaaaaf0d03fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaaf0d04030->Object::Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90, 0xaaaaf0d03fe0 } Next token is token 'a' (0xaaaaf0d04030 'a') Shifting token 'a' (0xaaaaf0d04030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaf0d04030 'a') -> $$ = nterm item (0xaaaaf0d04030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaaf0d04080->Object::Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90, 0xaaaaf0d03fe0, 0xaaaaf0d04030 } Next token is token 'p' (0xaaaaf0d04080 'p'Exception caught: cleaning lookahead and stack 0xaaaaf0d04080->Object::~Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90, 0xaaaaf0d03fe0, 0xaaaaf0d04030, 0xaaaaf0d04080 } 0xaaaaf0d04030->Object::~Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90, 0xaaaaf0d03fe0, 0xaaaaf0d04030 } 0xaaaaf0d03fe0->Object::~Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90, 0xaaaaf0d03fe0 } 0xaaaaf0d03f90->Object::~Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90 } 0xaaaaf0d03f40->Object::~Object { 0xaaaaf0d03f40 } exception caught: printer end { } exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: grep '^exception caught: printer$' stderr ./c++.at:1362: $PREPARSER ./input aaaaE stderr: stdout: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1362: $PREPARSER ./input aaaaT ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1360: $PREPARSER ./input aaaaE ./c++.at:856: $PREPARSER ./input ./c++.at:1362: $PREPARSER ./input aaaaR stderr: stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 694. java.at:217: testing Java parser class modifiers ... stderr: ./java.at:219: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaT ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaR stderr: ./java.at:219: grep '[mb]4_' YYParser.y ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ======== Testing with C++ standard flags: '' 694. java.at:217: ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS skipped (java.at:219) 695. java.at:287: testing Java parser class extends and implements ... ./java.at:289: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y ./java.at:289: grep '[mb]4_' YYParser.y stdout: 695. java.at:287: skipped (java.at:289) 696. java.at:307: testing Java %parse-param and %lex-param ... ./java.at:309: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y ./java.at:309: grep '[mb]4_' YYParser.y stdout: 696. java.at:307: skipped (java.at:309) 697. java.at:381: testing Java throws specifications ... ./java.at:441: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y stderr: stdout: ./c++.at:1065: $PREPARSER ./input < in stderr: ./java.at:441: grep '[mb]4_' YYParser.y error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: 697. java.at:381: ./c++.at:1065: $PREPARSER ./input < in skipped (java.at:441) stderr: error: invalid expression ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 698. java.at:470: testing Java constructor init and init_throws ... ./java.at:475: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y ======== Testing with C++ standard flags: '' ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ./java.at:475: grep '[mb]4_' YYParser.y stderr: stdout: stdout: ./c++.at:1064: $PREPARSER ./input < in 698. java.at:470: skipped (java.at:475) stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: $PREPARSER ./input < in stderr: stdout: stderr: ======== Testing with C++ standard flags: '' error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: ./c++.at:1363: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaal stderr: ./c++.at:1064: $PREPARSER ./input < in exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 699. java.at:497: testing Java value, position, and location types ... ./java.at:499: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y ./c++.at:1363: $PREPARSER ./input i error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stdout: exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaas stderr: ======== Testing with C++ standard flags: '' ./c++.at:1363: $PREPARSER ./input aaaap exception caught: reduction ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./java.at:499: grep '[mb]4_' YYParser.y ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaal 699. java.at:497: ./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: exception caught: yylex skipped (java.at:499) ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffff01188e0->Object::Object { } 0xfffff01189c0->Object::Object { 0xfffff01188e0 } 0xfffff01188e0->Object::~Object { 0xfffff01188e0, 0xfffff01189c0 } Next token is token 'a' (0xfffff01189c0 'a') 0xfffff0118920->Object::Object { 0xfffff01189c0 } 0xfffff01188d0->Object::Object { 0xfffff0118920, 0xfffff01189c0 } 0xfffff01188d0->Object::~Object { 0xfffff01188d0, 0xfffff0118920, 0xfffff01189c0 } 0xfffff01189c0->Object::~Object { 0xfffff0118920, 0xfffff01189c0 } Shifting token 'a' (0xfffff0118920 'a') 0xaaab0b5ab2e0->Object::Object { 0xfffff0118920 } 0xfffff01188a8->Object::Object { 0xaaab0b5ab2e0, 0xfffff0118920 } 0xfffff01188a8->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01188a8, 0xfffff0118920 } 0xfffff0118920->Object::~Object { 0xaaab0b5ab2e0, 0xfffff0118920 } Entering state 1 Stack now 0 1 0xfffff01189e0->Object::Object { 0xaaab0b5ab2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0b5ab2e0 'a') -> $$ = nterm item (0xfffff01189e0 'a') 0xaaab0b5ab2e0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01189e0 } 0xaaab0b5ab2e0->Object::Object { 0xfffff01189e0 } 0xfffff0118990->Object::Object { 0xaaab0b5ab2e0, 0xfffff01189e0 } 0xfffff0118990->Object::~Object { 0xaaab0b5ab2e0, 0xfffff0118990, 0xfffff01189e0 } 0xfffff01189e0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01189e0 } Entering state 10 Stack now 0 10 Reading a token 0xfffff01188e0->Object::Object { 0xaaab0b5ab2e0 } 0xfffff01189c0->Object::Object { 0xaaab0b5ab2e0, 0xfffff01188e0 } 0xfffff01188e0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01188e0, 0xfffff01189c0 } Next token is token 'a' (0xfffff01189c0 'a') 0xfffff0118920->Object::Object { 0xaaab0b5ab2e0, 0xfffff01189c0 } 0xfffff01188d0->Object::Object { 0xaaab0b5ab2e0, 0xfffff0118920, 0xfffff01189c0 } 0xfffff01188d0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01188d0, 0xfffff0118920, 0xfffff01189c0 } 0xfffff01189c0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff0118920, 0xfffff01189c0 } Shifting token 'a' (0xfffff0118920 'a') 0xaaab0b5ab300->Object::Object { 0xaaab0b5ab2e0, 0xfffff0118920 } 0xfffff01188a8->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118920 } 0xfffff01188a8->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01188a8, 0xfffff0118920 } 0xfffff0118920->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118920 } Entering state 1 Stack now 0 10 1 0xfffff01189e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0b5ab300 'a') -> $$ = nterm item (0xfffff01189e0 'a') 0xaaab0b5ab300->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189e0 } 0xaaab0b5ab300->Object::Object { 0xaaab0b5ab2e0, 0xfffff01189e0 } 0xfffff0118990->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189e0 } 0xfffff0118990->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118990, 0xfffff01189e0 } 0xfffff01189e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189e0 } Entering state 10 Stack now 0 10 10 Reading a token 0xfffff01188e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300 } 0xfffff01189c0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01188e0 } 0xfffff01188e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01188e0, 0xfffff01189c0 } Next token is token 'a' (0xfffff01189c0 'a') 0xfffff0118920->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189c0 } 0xfffff01188d0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118920, 0xfffff01189c0 } 0xfffff01188d0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01188d0, 0xfffff0118920, 0xfffff01189c0 } 0xfffff01189c0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118920, 0xfffff01189c0 } Shifting token 'a' (0xfffff0118920 'a') 0xaaab0b5ab320->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118920 } 0xfffff01188a8->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118920 } 0xfffff01188a8->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01188a8, 0xfffff0118920 } 0xfffff0118920->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118920 } Entering state 1 Stack now 0 10 10 1 0xfffff01189e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0b5ab320 'a') -> $$ = nterm item (0xfffff01189e0 'a') 0xaaab0b5ab320->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189e0 } 0xaaab0b5ab320->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189e0 } 0xfffff0118990->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189e0 } 0xfffff0118990->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118990, 0xfffff01189e0 } 0xfffff01189e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189e0 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xfffff01188e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320 } 0xfffff01189c0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01188e0 } 0xfffff01188e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01188e0, 0xfffff01189c0 } Next token is token 'a' (0xfffff01189c0 'a') 0xfffff0118920->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189c0 } 0xfffff01188d0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118920, 0xfffff01189c0 } 0xfffff01188d0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01188d0, 0xfffff0118920, 0xfffff01189c0 } 0xfffff01189c0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118920, 0xfffff01189c0 } Shifting token 'a' (0xfffff0118920 'a') 0xaaab0b5ab340->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118920 } 0xfffff01188a8->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff0118920 } 0xfffff01188a8->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01188a8, 0xfffff0118920 } 0xfffff0118920->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff0118920 } Entering state 1 Stack now 0 10 10 10 1 0xfffff01189e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0b5ab340 'a') -> $$ = nterm item (0xfffff01189e0 'a') 0xaaab0b5ab340->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01189e0 } 0xaaab0b5ab340->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189e0 } 0xfffff0118990->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01189e0 } 0xfffff0118990->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff0118990, 0xfffff01189e0 } 0xfffff01189e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01189e0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xfffff01188e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340 } 0xfffff01189c0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01188e0 } 0xfffff01188e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01188e0, 0xfffff01189c0 } Next token is token 'p' (0xfffff01189c0 'p'Exception caught: cleaning lookahead and stack 0xaaab0b5ab340->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01189c0 } 0xaaab0b5ab320->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189c0 } 0xaaab0b5ab300->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189c0 } 0xaaab0b5ab2e0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01189c0 } 0xfffff01189c0->Object::~Object { 0xfffff01189c0 } exception caught: printer end { } ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input i stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffff01188e0->Object::Object { } 0xfffff01189c0->Object::Object { 0xfffff01188e0 } 0xfffff01188e0->Object::~Object { 0xfffff01188e0, 0xfffff01189c0 } Next token is token 'a' (0xfffff01189c0 'a') 0xfffff0118920->Object::Object { 0xfffff01189c0 } 0xfffff01188d0->Object::Object { 0xfffff0118920, 0xfffff01189c0 } 0xfffff01188d0->Object::~Object { 0xfffff01188d0, 0xfffff0118920, 0xfffff01189c0 } 0xfffff01189c0->Object::~Object { 0xfffff0118920, 0xfffff01189c0 } Shifting token 'a' (0xfffff0118920 'a') 0xaaab0b5ab2e0->Object::Object { 0xfffff0118920 } 0xfffff01188a8->Object::Object { 0xaaab0b5ab2e0, 0xfffff0118920 } 0xfffff01188a8->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01188a8, 0xfffff0118920 } 0xfffff0118920->Object::~Object { 0xaaab0b5ab2e0, 0xfffff0118920 } Entering state 1 Stack now 0 1 0xfffff01189e0->Object::Object { 0xaaab0b5ab2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0b5ab2e0 'a') -> $$ = nterm item (0xfffff01189e0 'a') 0xaaab0b5ab2e0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01189e0 } 0xaaab0b5ab2e0->Object::Object { 0xfffff01189e0 } 0xfffff0118990->Object::Object { 0xaaab0b5ab2e0, 0xfffff01189e0 } 0xfffff0118990->Object::~Object { 0xaaab0b5ab2e0, 0xfffff0118990, 0xfffff01189e0 } 0xfffff01189e0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01189e0 } Entering state 10 Stack now 0 10 Reading a token 0xfffff01188e0->Object::Object { 0xaaab0b5ab2e0 } 0xfffff01189c0->Object::Object { 0xaaab0b5ab2e0, 0xfffff01188e0 } 0xfffff01188e0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01188e0, 0xfffff01189c0 } Next token is token 'a' (0xfffff01189c0 'a') 0xfffff0118920->Object::Object { 0xaaab0b5ab2e0, 0xfffff01189c0 } 0xfffff01188d0->Object::Object { 0xaaab0b5ab2e0, 0xfffff0118920, 0xfffff01189c0 } 0xfffff01188d0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01188d0, 0xfffff0118920, 0xfffff01189c0 } 0xfffff01189c0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff0118920, 0xfffff01189c0 } Shifting token 'a' (0xfffff0118920 'a') 0xaaab0b5ab300->Object::Object { 0xaaab0b5ab2e0, 0xfffff0118920 } 0xfffff01188a8->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118920 } 0xfffff01188a8->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01188a8, 0xfffff0118920 } 0xfffff0118920->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118920 } Entering state 1 Stack now 0 10 1 0xfffff01189e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0b5ab300 'a') -> $$ = nterm item (0xfffff01189e0 'a') 0xaaab0b5ab300->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189e0 } 0xaaab0b5ab300->Object::Object { 0xaaab0b5ab2e0, 0xfffff01189e0 } 0xfffff0118990->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189e0 } 0xfffff0118990->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118990, 0xfffff01189e0 } 0xfffff01189e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189e0 } Entering state 10 Stack now 0 10 10 Reading a token 0xfffff01188e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300 } 0xfffff01189c0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01188e0 } 0xfffff01188e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01188e0, 0xfffff01189c0 } Next token is token 'a' (0xfffff01189c0 'a') 0xfffff0118920->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189c0 } 0xfffff01188d0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118920, 0xfffff01189c0 } 0xfffff01188d0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01188d0, 0xfffff0118920, 0xfffff01189c0 } 0xfffff01189c0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118920, 0xfffff01189c0 } Shifting token 'a' (0xfffff0118920 'a') 0xaaab0b5ab320->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118920 } 0xfffff01188a8->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118920 } 0xfffff01188a8->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01188a8, 0xfffff0118920 } 0xfffff0118920->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118920 } Entering state 1 Stack now 0 10 10 1 0xfffff01189e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0b5ab320 'a') -> $$ = nterm item (0xfffff01189e0 'a') 0xaaab0b5ab320->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189e0 } 0xaaab0b5ab320->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189e0 } 0xfffff0118990->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189e0 } 0xfffff0118990->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118990, 0xfffff01189e0 } 0xfffff01189e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189e0 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xfffff01188e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320 } 0xfffff01189c0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01188e0 } 0xfffff01188e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01188e0, 0xfffff01189c0 } Next token is token 'a' (0xfffff01189c0 'a') 0xfffff0118920->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189c0 } 0xfffff01188d0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118920, 0xfffff01189c0 } 0xfffff01188d0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01188d0, 0xfffff0118920, 0xfffff01189c0 } 0xfffff01189c0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118920, 0xfffff01189c0 } Shifting token 'a' (0xfffff0118920 'a') 0xaaab0b5ab340->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118920 } 0xfffff01188a8->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff0118920 } 0xfffff01188a8->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01188a8, 0xfffff0118920 } 0xfffff0118920->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff0118920 } Entering state 1 Stack now 0 10 10 10 1 0xfffff01189e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab0b5ab340 'a') -> $$ = nterm item (0xfffff01189e0 'a') 0xaaab0b5ab340->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01189e0 } 0xaaab0b5ab340->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189e0 } 0xfffff0118990->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01189e0 } 0xfffff0118990->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff0118990, 0xfffff01189e0 } 0xfffff01189e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01189e0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xfffff01188e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340 } 0xfffff01189c0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01188e0 } 0xfffff01188e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01188e0, 0xfffff01189c0 } Next token is token 'p' (0xfffff01189c0 'p'Exception caught: cleaning lookahead and stack 0xaaab0b5ab340->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01189c0 } 0xaaab0b5ab320->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189c0 } 0xaaab0b5ab300->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189c0 } 0xaaab0b5ab2e0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01189c0 } 0xfffff01189c0->Object::~Object { 0xfffff01189c0 } exception caught: printer end { } ./c++.at:1363: grep '^exception caught: printer$' stderr stdout: exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: printer ./c++.at:1363: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaap stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaE 700. java.at:528: testing Java syntax error handling without error token ... stderr: ./java.at:579: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret YYParser.y ./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: exception caught: syntax error, unexpected end of file, expecting 'a' stdout: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae669ef40->Object::Object { } Next token is token 'a' (0xaaaae669ef40 'a') Shifting token 'a' (0xaaaae669ef40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae669ef40 'a') -> $$ = nterm item (0xaaaae669ef40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaae669ef90->Object::Object { 0xaaaae669ef40 } Next token is token 'a' (0xaaaae669ef90 'a') Shifting token 'a' (0xaaaae669ef90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae669ef90 'a') -> $$ = nterm item (0xaaaae669ef90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaae669efe0->Object::Object { 0xaaaae669ef40, 0xaaaae669ef90 } Next token is token 'a' (0xaaaae669efe0 'a') Shifting token 'a' (0xaaaae669efe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae669efe0 'a') -> $$ = nterm item (0xaaaae669efe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaae669f030->Object::Object { 0xaaaae669ef40, 0xaaaae669ef90, 0xaaaae669efe0 } Next token is token 'a' (0xaaaae669f030 'a') Shifting token 'a' (0xaaaae669f030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae669f030 'a') -> $$ = nterm item (0xaaaae669f030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaae669f080->Object::Object { 0xaaaae669ef40, 0xaaaae669ef90, 0xaaaae669efe0, 0xaaaae669f030 } Next token is token 'p' (0xaaaae669f080 'p'Exception caught: cleaning lookahead and stack 0xaaaae669f080->Object::~Object { 0xaaaae669ef40, 0xaaaae669ef90, 0xaaaae669efe0, 0xaaaae669f030, 0xaaaae669f080 } 0xaaaae669f030->Object::~Object { 0xaaaae669ef40, 0xaaaae669ef90, 0xaaaae669efe0, 0xaaaae669f030 } 0xaaaae669efe0->Object::~Object { 0xaaaae669ef40, 0xaaaae669ef90, 0xaaaae669efe0 } 0xaaaae669ef90->Object::~Object { 0xaaaae669ef40, 0xaaaae669ef90 } 0xaaaae669ef40->Object::~Object { 0xaaaae669ef40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1555: $PREPARSER ./test ./c++.at:1363: $PREPARSER ./input aaaaT stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae669ef40->Object::Object { } Next token is token 'a' (0xaaaae669ef40 'a') Shifting token 'a' (0xaaaae669ef40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae669ef40 'a') -> $$ = nterm item (0xaaaae669ef40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaae669ef90->Object::Object { 0xaaaae669ef40 } Next token is token 'a' (0xaaaae669ef90 'a') Shifting token 'a' (0xaaaae669ef90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae669ef90 'a') -> $$ = nterm item (0xaaaae669ef90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaae669efe0->Object::Object { 0xaaaae669ef40, 0xaaaae669ef90 } Next token is token 'a' (0xaaaae669efe0 'a') Shifting token 'a' (0xaaaae669efe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae669efe0 'a') -> $$ = nterm item (0xaaaae669efe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaae669f030->Object::Object { 0xaaaae669ef40, 0xaaaae669ef90, 0xaaaae669efe0 } Next token is token 'a' (0xaaaae669f030 'a') Shifting token 'a' (0xaaaae669f030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae669f030 'a') -> $$ = nterm item (0xaaaae669f030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaae669f080->Object::Object { 0xaaaae669ef40, 0xaaaae669ef90, 0xaaaae669efe0, 0xaaaae669f030 } Next token is token 'p' (0xaaaae669f080 'p'Exception caught: cleaning lookahead and stack 0xaaaae669f080->Object::~Object { 0xaaaae669ef40, 0xaaaae669ef90, 0xaaaae669efe0, 0xaaaae669f030, 0xaaaae669f080 } 0xaaaae669f030->Object::~Object { 0xaaaae669ef40, 0xaaaae669ef90, 0xaaaae669efe0, 0xaaaae669f030 } 0xaaaae669efe0->Object::~Object { 0xaaaae669ef40, 0xaaaae669ef90, 0xaaaae669efe0 } 0xaaaae669ef90->Object::~Object { 0xaaaae669ef40, 0xaaaae669ef90 } 0xaaaae669ef40->Object::~Object { 0xaaaae669ef40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaR exception caught: printer 700. java.at:528: ./c++.at:1361: $PREPARSER ./input aaaae stderr: ======== Testing with C++ standard flags: '' stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr skipped (java.at:580) exception caught: syntax error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' stderr: ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: ./c++.at:1361: $PREPARSER ./input aaaaE ./c++.at:850: $PREPARSER ./input stderr: stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaT ./c++.at:851: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 701. javapush.at:172: testing Trivial Push Parser with api.push-pull verification ... ./javapush.at:181: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dapi.push-pull=pull -o Main.java input.y stderr: ./c++.at:1361: $PREPARSER ./input aaaaR stderr: stdout: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1555: ./check ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y ======== Testing with C++ standard flags: '' ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./javapush.at:182: grep -c '^.*public boolean parse().*$' Main.java ./javapush.at:187: grep -c '^.*public int push_parse(int yylextoken, Object yylexval).*$' Main.java ./javapush.at:191: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dapi.push-pull=both -o Main.java input.y ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./javapush.at:192: grep -c '^.*public boolean parse().*$' Main.java ./javapush.at:195: grep -c '^.*public int push_parse(int yylextoken, Object yylexval).*$' Main.java ./javapush.at:199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dapi.push-pull=push -o Main.java input.y ./javapush.at:200: grep -c '^.*public boolean parse().*$' Main.java ./javapush.at:203: grep -c '^.*public int push_parse(int yylextoken, Object yylexval).*$' Main.java 701. javapush.at:172: skipped (javapush.at:207) stderr: stdout: ./c++.at:1362: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1362: $PREPARSER ./input i ./c++.at:1360: $PREPARSER ./input aaaas stderr: stderr: 702. javapush.at:217: testing Trivial Push Parser with %initial-action ... exception caught: initial-action exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaal stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./javapush.at:227: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dapi.push-pull=push -o Main.java input.y exception caught: yylex ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaap stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaap ./c++.at:1362: $PREPARSER ./input --debug aaaap ./javapush.at:228: grep -c '^System.err.println("Initial action invoked");$' Main.java stderr: stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token 0xffffdb39e910->Object::Object { } 0xffffdb39e9c0->Object::Object { 0xffffdb39e910 } 0xffffdb39e910->Object::~Object { 0xffffdb39e910, 0xffffdb39e9c0 } Next token is token 'a' (0xffffdb39e9c0 'a') 0xffffdb39e900->Object::Object { 0xffffdb39e9c0 } 0xffffdb39e9c0->Object::~Object { 0xffffdb39e900, 0xffffdb39e9c0 } Shifting token 'a' (0xffffdb39e900 'a') 0xaaaae652d2e0->Object::Object { 0xffffdb39e900 } 0xffffdb39e900->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e900 } Entering state 2 Stack now 0 2 0xffffdb39e9e0->Object::Object { 0xaaaae652d2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae652d2e0 'a') -> $$ = nterm item (0xffffdb39e9e0 'a') 0xaaaae652d2e0->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e9e0 } 0xaaaae652d2e0->Object::Object { 0xffffdb39e9e0 } 0xffffdb39e9e0->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e9e0 } Entering state 11 Stack now 0 11 Reading a token 0xffffdb39e910->Object::Object { 0xaaaae652d2e0 } 0xffffdb39e9c0->Object::Object { 0xaaaae652d2e0, 0xffffdb39e910 } 0xffffdb39e910->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e910, 0xffffdb39e9c0 } Next token is token 'a' (0xffffdb39e9c0 'a') 0xffffdb39e900->Object::Object { 0xaaaae652d2e0, 0xffffdb39e9c0 } 0xffffdb39e9c0->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e900, 0xffffdb39e9c0 } Shifting token 'a' (0xffffdb39e900 'a') 0xaaaae652d300->Object::Object { 0xaaaae652d2e0, 0xffffdb39e900 } 0xffffdb39e900->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e900 } Entering state 2 Stack now 0 11 2 0xffffdb39e9e0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae652d300 'a') -> $$ = nterm item (0xffffdb39e9e0 'a') 0xaaaae652d300->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e9e0 } 0xaaaae652d300->Object::Object { 0xaaaae652d2e0, 0xffffdb39e9e0 } 0xffffdb39e9e0->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e9e0 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffdb39e910->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300 } 0xffffdb39e9c0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e910 } 0xffffdb39e910->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e910, 0xffffdb39e9c0 } Next token is token 'a' (0xffffdb39e9c0 'a') 0xffffdb39e900->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e9c0 } 0xffffdb39e9c0->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e900, 0xffffdb39e9c0 } Shifting token 'a' (0xffffdb39e900 'a') 0xaaaae652d320->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e900 } 0xffffdb39e900->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e900 } Entering state 2 Stack now 0 11 11 2 0xffffdb39e9e0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae652d320 'a') -> $$ = nterm item (0xffffdb39e9e0 'a') 0xaaaae652d320->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e9e0 } 0xaaaae652d320->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e9e0 } 0xffffdb39e9e0->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e9e0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffdb39e910->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320 } 0xffffdb39e9c0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e910 } 0xffffdb39e910->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e910, 0xffffdb39e9c0 } Next token is token 'a' (0xffffdb39e9c0 'a') 0xffffdb39e900->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e9c0 } 0xffffdb39e9c0->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e900, 0xffffdb39e9c0 } Shifting token 'a' (0xffffdb39e900 'a') 0xaaaae652d340->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e900 } 0xffffdb39e900->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e900 } Entering state 2 Stack now 0 11 11 11 2 0xffffdb39e9e0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae652d340 'a') -> $$ = nterm item (0xffffdb39e9e0 'a') 0xaaaae652d340->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e9e0 } 0xaaaae652d340->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e9e0 } 0xffffdb39e9e0->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e9e0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffdb39e910->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340 } 0xffffdb39e9c0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e910 } 0xffffdb39e910->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e910, 0xffffdb39e9c0 } Next token is token 'p' (0xffffdb39e9c0 'p'Exception caught: cleaning lookahead and stack 0xaaaae652d340->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e9c0 } 0xaaaae652d320->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e9c0 } 0xaaaae652d300->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e9c0 } 0xaaaae652d2e0->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e9c0 } 0xffffdb39e9c0->Object::~Object { 0xffffdb39e9c0 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input --debug aaaap stderr: stderr: 702. javapush.at:217: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaac60a2f40->Object::Object { } Next token is token 'a' (0xaaaac60a2f40 'a') Shifting token 'a' (0xaaaac60a2f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac60a2f40 'a') -> $$ = nterm item (0xaaaac60a2f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaac60a2f90->Object::Object { 0xaaaac60a2f40 } Next token is token 'a' (0xaaaac60a2f90 'a') Shifting token 'a' (0xaaaac60a2f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac60a2f90 'a') -> $$ = nterm item (0xaaaac60a2f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaac60a2fe0->Object::Object { 0xaaaac60a2f40, 0xaaaac60a2f90 } Next token is token 'a' (0xaaaac60a2fe0 'a') Shifting token 'a' (0xaaaac60a2fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac60a2fe0 'a') -> $$ = nterm item (0xaaaac60a2fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaac60a3030->Object::Object { 0xaaaac60a2f40, 0xaaaac60a2f90, 0xaaaac60a2fe0 } Next token is token 'a' (0xaaaac60a3030 'a') Shifting token 'a' (0xaaaac60a3030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac60a3030 'a') -> $$ = nterm item (0xaaaac60a3030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaac60a3080->Object::Object { 0xaaaac60a2f40, 0xaaaac60a2f90, 0xaaaac60a2fe0, 0xaaaac60a3030 } Next token is token 'p' (0xaaaac60a3080 'p'Exception caught: cleaning lookahead and stack 0xaaaac60a3080->Object::~Object { 0xaaaac60a2f40, 0xaaaac60a2f90, 0xaaaac60a2fe0, 0xaaaac60a3030, 0xaaaac60a3080 } 0xaaaac60a3030->Object::~Object { 0xaaaac60a2f40, 0xaaaac60a2f90, 0xaaaac60a2fe0, 0xaaaac60a3030 } 0xaaaac60a2fe0->Object::~Object { 0xaaaac60a2f40, 0xaaaac60a2f90, 0xaaaac60a2fe0 } 0xaaaac60a2f90->Object::~Object { 0xaaaac60a2f40, 0xaaaac60a2f90 } 0xaaaac60a2f40->Object::~Object { 0xaaaac60a2f40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token 0xffffdb39e910->Object::Object { } 0xffffdb39e9c0->Object::Object { 0xffffdb39e910 } 0xffffdb39e910->Object::~Object { 0xffffdb39e910, 0xffffdb39e9c0 } Next token is token 'a' (0xffffdb39e9c0 'a') 0xffffdb39e900->Object::Object { 0xffffdb39e9c0 } 0xffffdb39e9c0->Object::~Object { 0xffffdb39e900, 0xffffdb39e9c0 } Shifting token 'a' (0xffffdb39e900 'a') 0xaaaae652d2e0->Object::Object { 0xffffdb39e900 } 0xffffdb39e900->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e900 } Entering state 2 Stack now 0 2 0xffffdb39e9e0->Object::Object { 0xaaaae652d2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae652d2e0 'a') -> $$ = nterm item (0xffffdb39e9e0 'a') 0xaaaae652d2e0->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e9e0 } 0xaaaae652d2e0->Object::Object { 0xffffdb39e9e0 } 0xffffdb39e9e0->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e9e0 } Entering state 11 Stack now 0 11 Reading a token 0xffffdb39e910->Object::Object { 0xaaaae652d2e0 } 0xffffdb39e9c0->Object::Object { 0xaaaae652d2e0, 0xffffdb39e910 } 0xffffdb39e910->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e910, 0xffffdb39e9c0 } Next token is token 'a' (0xffffdb39e9c0 'a') 0xffffdb39e900->Object::Object { 0xaaaae652d2e0, 0xffffdb39e9c0 } 0xffffdb39e9c0->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e900, 0xffffdb39e9c0 } Shifting token 'a' (0xffffdb39e900 'a') 0xaaaae652d300->Object::Object { 0xaaaae652d2e0, 0xffffdb39e900 } 0xffffdb39e900->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e900 } Entering state 2 Stack now 0 11 2 0xffffdb39e9e0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae652d300 'a') -> $$ = nterm item (0xffffdb39e9e0 'a') 0xaaaae652d300->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e9e0 } 0xaaaae652d300->Object::Object { 0xaaaae652d2e0, 0xffffdb39e9e0 } 0xffffdb39e9e0->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e9e0 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffdb39e910->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300 } 0xffffdb39e9c0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e910 } 0xffffdb39e910->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e910, 0xffffdb39e9c0 } Next token is token 'a' (0xffffdb39e9c0 'a') 0xffffdb39e900->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e9c0 } 0xffffdb39e9c0->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e900, 0xffffdb39e9c0 } Shifting token 'a' (0xffffdb39e900 'a') 0xaaaae652d320->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e900 } 0xffffdb39e900->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e900 } Entering state 2 Stack now 0 11 11 2 0xffffdb39e9e0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae652d320 'a') -> $$ = nterm item (0xffffdb39e9e0 'a') 0xaaaae652d320->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e9e0 } 0xaaaae652d320->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e9e0 } 0xffffdb39e9e0->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e9e0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffdb39e910->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320 } 0xffffdb39e9c0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e910 } 0xffffdb39e910->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e910, 0xffffdb39e9c0 } Next token is token 'a' (0xffffdb39e9c0 'a') 0xffffdb39e900->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e9c0 } 0xffffdb39e9c0->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e900, 0xffffdb39e9c0 } Shifting token 'a' (0xffffdb39e900 'a') 0xaaaae652d340->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e900 } 0xffffdb39e900->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e900 } Entering state 2 Stack now 0 11 11 11 2 0xffffdb39e9e0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae652d340 'a') -> $$ = nterm item (0xffffdb39e9e0 'a') 0xaaaae652d340->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e9e0 } 0xaaaae652d340->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e9e0 } 0xffffdb39e9e0->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e9e0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffdb39e910->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340 } 0xffffdb39e9c0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e910 } 0xffffdb39e910->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e910, 0xffffdb39e9c0 } Next token is token 'p' (0xffffdb39e9c0 'p'Exception caught: cleaning lookahead and stack 0xaaaae652d340->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e9c0 } 0xaaaae652d320->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e9c0 } 0xaaaae652d300->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e9c0 } 0xaaaae652d2e0->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e9c0 } 0xffffdb39e9c0->Object::~Object { 0xffffdb39e9c0 } exception caught: printer end { } ./c++.at:1362: grep '^exception caught: printer$' stderr stdout: stderr: skipped (javapush.at:230) exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaac60a2f40->Object::Object { } Next token is token 'a' (0xaaaac60a2f40 'a') Shifting token 'a' (0xaaaac60a2f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac60a2f40 'a') -> $$ = nterm item (0xaaaac60a2f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaac60a2f90->Object::Object { 0xaaaac60a2f40 } Next token is token 'a' (0xaaaac60a2f90 'a') Shifting token 'a' (0xaaaac60a2f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac60a2f90 'a') -> $$ = nterm item (0xaaaac60a2f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaac60a2fe0->Object::Object { 0xaaaac60a2f40, 0xaaaac60a2f90 } Next token is token 'a' (0xaaaac60a2fe0 'a') Shifting token 'a' (0xaaaac60a2fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac60a2fe0 'a') -> $$ = nterm item (0xaaaac60a2fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaac60a3030->Object::Object { 0xaaaac60a2f40, 0xaaaac60a2f90, 0xaaaac60a2fe0 } Next token is token 'a' (0xaaaac60a3030 'a') Shifting token 'a' (0xaaaac60a3030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac60a3030 'a') -> $$ = nterm item (0xaaaac60a3030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaac60a3080->Object::Object { 0xaaaac60a2f40, 0xaaaac60a2f90, 0xaaaac60a2fe0, 0xaaaac60a3030 } Next token is token 'p' (0xaaaac60a3080 'p'Exception caught: cleaning lookahead and stack 0xaaaac60a3080->Object::~Object { 0xaaaac60a2f40, 0xaaaac60a2f90, 0xaaaac60a2fe0, 0xaaaac60a3030, 0xaaaac60a3080 } 0xaaaac60a3030->Object::~Object { 0xaaaac60a2f40, 0xaaaac60a2f90, 0xaaaac60a2fe0, 0xaaaac60a3030 } 0xaaaac60a2fe0->Object::~Object { 0xaaaac60a2f40, 0xaaaac60a2f90, 0xaaaac60a2fe0 } 0xaaaac60a2f90->Object::~Object { 0xaaaac60a2f40, 0xaaaac60a2f90 } 0xaaaac60a2f40->Object::~Object { 0xaaaac60a2f40 } exception caught: printer end { } ./c++.at:1360: grep '^exception caught: printer$' stderr exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaE stderr: ./c++.at:1360: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaT ./c++.at:1360: $PREPARSER ./input aaaaT stderr: stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 703. d.at:103: testing D parser class extends and implements ... ./d.at:106: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y ./c++.at:1362: $PREPARSER ./input aaaaR ./c++.at:1360: $PREPARSER ./input aaaaR stderr: stderr: stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ======== Testing with C++ standard flags: '' ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:856: $PREPARSER ./input ======== Testing with C++ standard flags: '' ./d.at:106: grep '[mb]4_' YYParser.y ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 703. d.at:103: skipped (d.at:106) ./c++.at:857: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ======== Testing with C++ standard flags: '' ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 704. d.at:138: testing D parser class api.token.raw true by default ... ./d.at:141: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y ./d.at:141: grep '[mb]4_' YYParser.y stdout: 704. d.at:138: skipped (d.at:141) 705. cxx-type.at:409: testing GLR: Resolve ambiguity, impure, no locations ... ./cxx-type.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y stderr: types.y:77.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stderr: ./cxx-type.at:410: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS stdout: ./c++.at:851: $PREPARSER ./input stderr: ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1065: $PREPARSER ./input < in ./c++.at:1066: $PREPARSER ./input < in stderr: stdout: stderr: 689. c++.at:1371: ok stderr: error: invalid expression caught error error: invalid character caught error error: invalid expression ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1065: $PREPARSER ./input < in ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid character stderr: ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: invalid expression ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1066: $PREPARSER ./input < in stderr: stderr: stdout: ./c++.at:1555: $PREPARSER ./test error: invalid character ./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./c++.at:1363: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 706. cxx-type.at:415: testing GLR: Resolve ambiguity, impure, locations ... ./c++.at:1363: $PREPARSER ./input aaaal ./cxx-type.at:416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y stderr: exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input i stderr: stderr: types.y:87.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./cxx-type.at:416: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1066: ./check ./c++.at:1363: $PREPARSER ./input aaaap stderr: stderr: stdout: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input --debug aaaap ./c++.at:1555: ./check ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: ./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y Starting parse Entering state 0 Stack now 0 Reading a token 0xfffffd609620->Object::Object { } 0xfffffd609720->Object::Object { 0xfffffd609620 } 0xfffffd609620->Object::~Object { 0xfffffd609620, 0xfffffd609720 } Next token is token 'a' (0xfffffd609720 'a') 0xfffffd609660->Object::Object { 0xfffffd609720 } 0xfffffd609720->Object::~Object { 0xfffffd609660, 0xfffffd609720 } Shifting token 'a' (0xfffffd609660 'a') 0xaaaae93302e0->Object::Object { 0xfffffd609660 } 0xfffffd609660->Object::~Object { 0xaaaae93302e0, 0xfffffd609660 } Entering state 1 Stack now 0 1 0xfffffd609740->Object::Object { 0xaaaae93302e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae93302e0 'a') -> $$ = nterm item (0xfffffd609740 'a') 0xaaaae93302e0->Object::~Object { 0xaaaae93302e0, 0xfffffd609740 } 0xaaaae93302e0->Object::Object { 0xfffffd609740 } 0xfffffd609740->Object::~Object { 0xaaaae93302e0, 0xfffffd609740 } Entering state 10 Stack now 0 10 Reading a token 0xfffffd609620->Object::Object { 0xaaaae93302e0 } 0xfffffd609720->Object::Object { 0xaaaae93302e0, 0xfffffd609620 } 0xfffffd609620->Object::~Object { 0xaaaae93302e0, 0xfffffd609620, 0xfffffd609720 } Next token is token 'a' (0xfffffd609720 'a') 0xfffffd609660->Object::Object { 0xaaaae93302e0, 0xfffffd609720 } 0xfffffd609720->Object::~Object { 0xaaaae93302e0, 0xfffffd609660, 0xfffffd609720 } Shifting token 'a' (0xfffffd609660 'a') 0xaaaae9330300->Object::Object { 0xaaaae93302e0, 0xfffffd609660 } 0xfffffd609660->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609660 } Entering state 1 Stack now 0 10 1 0xfffffd609740->Object::Object { 0xaaaae93302e0, 0xaaaae9330300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae9330300 'a') -> $$ = nterm item (0xfffffd609740 'a') 0xaaaae9330300->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609740 } 0xaaaae9330300->Object::Object { 0xaaaae93302e0, 0xfffffd609740 } 0xfffffd609740->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609740 } Entering state 10 Stack now 0 10 10 Reading a token 0xfffffd609620->Object::Object { 0xaaaae93302e0, 0xaaaae9330300 } 0xfffffd609720->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609620 } 0xfffffd609620->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609620, 0xfffffd609720 } Next token is token 'a' (0xfffffd609720 'a') 0xfffffd609660->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609720 } 0xfffffd609720->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609660, 0xfffffd609720 } Shifting token 'a' (0xfffffd609660 'a') 0xaaaae9330320->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609660 } 0xfffffd609660->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609660 } Entering state 1 Stack now 0 10 10 1 0xfffffd609740->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae9330320 'a') -> $$ = nterm item (0xfffffd609740 'a') 0xaaaae9330320->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609740 } 0xaaaae9330320->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609740 } 0xfffffd609740->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609740 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xfffffd609620->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320 } 0xfffffd609720->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609620 } 0xfffffd609620->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609620, 0xfffffd609720 } Next token is token 'a' (0xfffffd609720 'a') 0xfffffd609660->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609720 } 0xfffffd609720->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609660, 0xfffffd609720 } Shifting token 'a' (0xfffffd609660 'a') 0xaaaae9330340->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609660 } 0xfffffd609660->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609660 } Entering state 1 Stack now 0 10 10 10 1 0xfffffd609740->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae9330340 'a') -> $$ = nterm item (0xfffffd609740 'a') 0xaaaae9330340->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609740 } 0xaaaae9330340->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609740 } 0xfffffd609740->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609740 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xfffffd609620->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340 } 0xfffffd609720->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609620 } 0xfffffd609620->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609620, 0xfffffd609720 } Next token is token 'p' (0xfffffd609720 'p'Exception caught: cleaning lookahead and stack 0xaaaae9330340->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609720 } 0xaaaae9330320->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609720 } 0xaaaae9330300->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609720 } 0xaaaae93302e0->Object::~Object { 0xaaaae93302e0, 0xfffffd609720 } 0xfffffd609720->Object::~Object { 0xfffffd609720 } exception caught: printer end { } ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffffd609620->Object::Object { } 0xfffffd609720->Object::Object { 0xfffffd609620 } 0xfffffd609620->Object::~Object { 0xfffffd609620, 0xfffffd609720 } Next token is token 'a' (0xfffffd609720 'a') 0xfffffd609660->Object::Object { 0xfffffd609720 } 0xfffffd609720->Object::~Object { 0xfffffd609660, 0xfffffd609720 } Shifting token 'a' (0xfffffd609660 'a') 0xaaaae93302e0->Object::Object { 0xfffffd609660 } 0xfffffd609660->Object::~Object { 0xaaaae93302e0, 0xfffffd609660 } Entering state 1 Stack now 0 1 0xfffffd609740->Object::Object { 0xaaaae93302e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae93302e0 'a') -> $$ = nterm item (0xfffffd609740 'a') 0xaaaae93302e0->Object::~Object { 0xaaaae93302e0, 0xfffffd609740 } 0xaaaae93302e0->Object::Object { 0xfffffd609740 } 0xfffffd609740->Object::~Object { 0xaaaae93302e0, 0xfffffd609740 } Entering state 10 Stack now 0 10 Reading a token 0xfffffd609620->Object::Object { 0xaaaae93302e0 } 0xfffffd609720->Object::Object { 0xaaaae93302e0, 0xfffffd609620 } 0xfffffd609620->Object::~Object { 0xaaaae93302e0, 0xfffffd609620, 0xfffffd609720 } Next token is token 'a' (0xfffffd609720 'a') 0xfffffd609660->Object::Object { 0xaaaae93302e0, 0xfffffd609720 } 0xfffffd609720->Object::~Object { 0xaaaae93302e0, 0xfffffd609660, 0xfffffd609720 } Shifting token 'a' (0xfffffd609660 'a') 0xaaaae9330300->Object::Object { 0xaaaae93302e0, 0xfffffd609660 } 0xfffffd609660->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609660 } Entering state 1 Stack now 0 10 1 0xfffffd609740->Object::Object { 0xaaaae93302e0, 0xaaaae9330300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae9330300 'a') -> $$ = nterm item (0xfffffd609740 'a') 0xaaaae9330300->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609740 } 0xaaaae9330300->Object::Object { 0xaaaae93302e0, 0xfffffd609740 } 0xfffffd609740->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609740 } Entering state 10 Stack now 0 10 10 Reading a token 0xfffffd609620->Object::Object { 0xaaaae93302e0, 0xaaaae9330300 } 0xfffffd609720->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609620 } 0xfffffd609620->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609620, 0xfffffd609720 } Next token is token 'a' (0xfffffd609720 'a') 0xfffffd609660->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609720 } 0xfffffd609720->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609660, 0xfffffd609720 } Shifting token 'a' (0xfffffd609660 'a') 0xaaaae9330320->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609660 } 0xfffffd609660->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609660 } Entering state 1 Stack now 0 10 10 1 0xfffffd609740->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae9330320 'a') -> $$ = nterm item (0xfffffd609740 'a') 0xaaaae9330320->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609740 } 0xaaaae9330320->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609740 } 0xfffffd609740->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609740 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xfffffd609620->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320 } 0xfffffd609720->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609620 } 0xfffffd609620->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609620, 0xfffffd609720 } Next token is token 'a' (0xfffffd609720 'a') 0xfffffd609660->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609720 } 0xfffffd609720->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609660, 0xfffffd609720 } Shifting token 'a' (0xfffffd609660 'a') 0xaaaae9330340->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609660 } 0xfffffd609660->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609660 } Entering state 1 Stack now 0 10 10 10 1 0xfffffd609740->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae9330340 'a') -> $$ = nterm item (0xfffffd609740 'a') 0xaaaae9330340->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609740 } 0xaaaae9330340->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609740 } 0xfffffd609740->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609740 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xfffffd609620->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340 } 0xfffffd609720->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609620 } 0xfffffd609620->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609620, 0xfffffd609720 } Next token is token 'p' (0xfffffd609720 'p'Exception caught: cleaning lookahead and stack 0xaaaae9330340->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609720 } 0xaaaae9330320->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609720 } 0xaaaae9330300->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609720 } 0xaaaae93302e0->Object::~Object { 0xaaaae93302e0, 0xfffffd609720 } 0xfffffd609720->Object::~Object { 0xfffffd609720 } exception caught: printer end { } ./c++.at:1363: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1363: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./c++.at:1363: $PREPARSER ./input aaaaE stderr: stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1361: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1363: $PREPARSER ./input aaaaT ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaR stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input i ======== Testing with C++ standard flags: '' stderr: exception caught: initial-action ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaap stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaab042edf40->Object::Object { } Next token is token 'a' (0xaaab042edf40 'a') Shifting token 'a' (0xaaab042edf40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab042edf40 'a') -> $$ = nterm item (0xaaab042edf40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaab042edf90->Object::Object { 0xaaab042edf40 } Next token is token 'a' (0xaaab042edf90 'a') Shifting token 'a' (0xaaab042edf90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab042edf90 'a') -> $$ = nterm item (0xaaab042edf90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaab042edfe0->Object::Object { 0xaaab042edf40, 0xaaab042edf90 } Next token is token 'a' (0xaaab042edfe0 'a') Shifting token 'a' (0xaaab042edfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab042edfe0 'a') -> $$ = nterm item (0xaaab042edfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaab042ee030->Object::Object { 0xaaab042edf40, 0xaaab042edf90, 0xaaab042edfe0 } Next token is token 'a' (0xaaab042ee030 'a') Shifting token 'a' (0xaaab042ee030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab042ee030 'a') -> $$ = nterm item (0xaaab042ee030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaab042ee080->Object::Object { 0xaaab042edf40, 0xaaab042edf90, 0xaaab042edfe0, 0xaaab042ee030 } Next token is token 'p' (0xaaab042ee080 'p'Exception caught: cleaning lookahead and stack 0xaaab042ee080->Object::~Object { 0xaaab042edf40, 0xaaab042edf90, 0xaaab042edfe0, 0xaaab042ee030, 0xaaab042ee080 } 0xaaab042ee030->Object::~Object { 0xaaab042edf40, 0xaaab042edf90, 0xaaab042edfe0, 0xaaab042ee030 } 0xaaab042edfe0->Object::~Object { 0xaaab042edf40, 0xaaab042edf90, 0xaaab042edfe0 } 0xaaab042edf90->Object::~Object { 0xaaab042edf40, 0xaaab042edf90 } 0xaaab042edf40->Object::~Object { 0xaaab042edf40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stdout: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaab042edf40->Object::Object { } Next token is token 'a' (0xaaab042edf40 'a') Shifting token 'a' (0xaaab042edf40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab042edf40 'a') -> $$ = nterm item (0xaaab042edf40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaab042edf90->Object::Object { 0xaaab042edf40 } Next token is token 'a' (0xaaab042edf90 'a') Shifting token 'a' (0xaaab042edf90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab042edf90 'a') -> $$ = nterm item (0xaaab042edf90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaab042edfe0->Object::Object { 0xaaab042edf40, 0xaaab042edf90 } Next token is token 'a' (0xaaab042edfe0 'a') Shifting token 'a' (0xaaab042edfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab042edfe0 'a') -> $$ = nterm item (0xaaab042edfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaab042ee030->Object::Object { 0xaaab042edf40, 0xaaab042edf90, 0xaaab042edfe0 } Next token is token 'a' (0xaaab042ee030 'a') Shifting token 'a' (0xaaab042ee030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaab042ee030 'a') -> $$ = nterm item (0xaaab042ee030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaab042ee080->Object::Object { 0xaaab042edf40, 0xaaab042edf90, 0xaaab042edfe0, 0xaaab042ee030 } Next token is token 'p' (0xaaab042ee080 'p'Exception caught: cleaning lookahead and stack 0xaaab042ee080->Object::~Object { 0xaaab042edf40, 0xaaab042edf90, 0xaaab042edfe0, 0xaaab042ee030, 0xaaab042ee080 } 0xaaab042ee030->Object::~Object { 0xaaab042edf40, 0xaaab042edf90, 0xaaab042edfe0, 0xaaab042ee030 } 0xaaab042edfe0->Object::~Object { 0xaaab042edf40, 0xaaab042edf90, 0xaaab042edfe0 } 0xaaab042edf90->Object::~Object { 0xaaab042edf40, 0xaaab042edf90 } 0xaaab042edf40->Object::~Object { 0xaaab042edf40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:851: $PREPARSER ./input ./c++.at:1361: $PREPARSER ./input aaaae stderr: stderr: exception caught: syntax error stderr: ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./cxx-type.at:412: $PREPARSER ./types test-input ======== Testing with C++ standard flags: '' stderr: syntax error ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1361: $PREPARSER ./input aaaaE ./cxx-type.at:412: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:412: $PREPARSER ./types -p test-input stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () ./c++.at:1361: $PREPARSER ./input aaaaT stderr: stderr: ./cxx-type.at:412: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1361: $PREPARSER ./input aaaaR ./c++.at:857: $PREPARSER ./input stderr: stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 705. cxx-type.at:409: ok ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 707. cxx-type.at:420: testing GLR: Resolve ambiguity, pure, no locations ... ./cxx-type.at:421: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y stderr: types.y:77.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./cxx-type.at:421: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS stderr: stdout: ./cxx-type.at:417: $PREPARSER ./types test-input stderr: 17.5: syntax error ./cxx-type.at:417: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:417: $PREPARSER ./types -p test-input stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) ./cxx-type.at:417: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) 706. cxx-type.at:415: ok 708. cxx-type.at:426: testing GLR: Resolve ambiguity, pure, locations ... ./cxx-type.at:427: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y stderr: stdout: ./c++.at:1360: $PREPARSER ./input aaaas stderr: types.y:87.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stderr: ./cxx-type.at:427: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1362: $PREPARSER ./input aaaas ./c++.at:1360: $PREPARSER ./input aaaal stderr: stderr: exception caught: yylex exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaal ./c++.at:1360: $PREPARSER ./input i stderr: stderr: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: initial-action ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input i ./c++.at:1360: $PREPARSER ./input aaaap stderr: exception caught: initial-action stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaea7dbf40->Object::Object { } Next token is token 'a' (0xaaaaea7dbf40 'a') Shifting token 'a' (0xaaaaea7dbf40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaea7dbf40 'a') -> $$ = nterm item (0xaaaaea7dbf40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaaea7dbf90->Object::Object { 0xaaaaea7dbf40 } Next token is token 'a' (0xaaaaea7dbf90 'a') Shifting token 'a' (0xaaaaea7dbf90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaea7dbf90 'a') -> $$ = nterm item (0xaaaaea7dbf90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaaea7dbfe0->Object::Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90 } Next token is token 'a' (0xaaaaea7dbfe0 'a') Shifting token 'a' (0xaaaaea7dbfe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaea7dbfe0 'a') -> $$ = nterm item (0xaaaaea7dbfe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaaea7dc030->Object::Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90, 0xaaaaea7dbfe0 } Next token is token 'a' (0xaaaaea7dc030 'a') Shifting token 'a' (0xaaaaea7dc030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaea7dc030 'a') -> $$ = nterm item (0xaaaaea7dc030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaaea7dc080->Object::Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90, 0xaaaaea7dbfe0, 0xaaaaea7dc030 } Next token is token 'p' (0xaaaaea7dc080 'p'Exception caught: cleaning lookahead and stack 0xaaaaea7dc080->Object::~Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90, 0xaaaaea7dbfe0, 0xaaaaea7dc030, 0xaaaaea7dc080 } 0xaaaaea7dc030->Object::~Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90, 0xaaaaea7dbfe0, 0xaaaaea7dc030 } 0xaaaaea7dbfe0->Object::~Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90, 0xaaaaea7dbfe0 } 0xaaaaea7dbf90->Object::~Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90 } 0xaaaaea7dbf40->Object::~Object { 0xaaaaea7dbf40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaea7dbf40->Object::Object { } Next token is token 'a' (0xaaaaea7dbf40 'a') Shifting token 'a' (0xaaaaea7dbf40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaea7dbf40 'a') -> $$ = nterm item (0xaaaaea7dbf40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaaea7dbf90->Object::Object { 0xaaaaea7dbf40 } Next token is token 'a' (0xaaaaea7dbf90 'a') Shifting token 'a' (0xaaaaea7dbf90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaea7dbf90 'a') -> $$ = nterm item (0xaaaaea7dbf90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaaea7dbfe0->Object::Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90 } Next token is token 'a' (0xaaaaea7dbfe0 'a') Shifting token 'a' (0xaaaaea7dbfe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaea7dbfe0 'a') -> $$ = nterm item (0xaaaaea7dbfe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaaea7dc030->Object::Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90, 0xaaaaea7dbfe0 } Next token is token 'a' (0xaaaaea7dc030 'a') Shifting token 'a' (0xaaaaea7dc030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaea7dc030 'a') -> $$ = nterm item (0xaaaaea7dc030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaaea7dc080->Object::Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90, 0xaaaaea7dbfe0, 0xaaaaea7dc030 } Next token is token 'p' (0xaaaaea7dc080 'p'Exception caught: cleaning lookahead and stack 0xaaaaea7dc080->Object::~Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90, 0xaaaaea7dbfe0, 0xaaaaea7dc030, 0xaaaaea7dc080 } 0xaaaaea7dc030->Object::~Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90, 0xaaaaea7dbfe0, 0xaaaaea7dc030 } 0xaaaaea7dbfe0->Object::~Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90, 0xaaaaea7dbfe0 } 0xaaaaea7dbf90->Object::~Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90 } 0xaaaaea7dbf40->Object::~Object { 0xaaaaea7dbf40 } exception caught: printer end { } ./c++.at:1362: $PREPARSER ./input aaaap ./c++.at:1360: grep '^exception caught: printer$' stderr stderr: stdout: exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc5d25ab0->Object::Object { } 0xffffc5d25b60->Object::Object { 0xffffc5d25ab0 } 0xffffc5d25ab0->Object::~Object { 0xffffc5d25ab0, 0xffffc5d25b60 } Next token is token 'a' (0xffffc5d25b60 'a') 0xffffc5d25aa0->Object::Object { 0xffffc5d25b60 } 0xffffc5d25b60->Object::~Object { 0xffffc5d25aa0, 0xffffc5d25b60 } Shifting token 'a' (0xffffc5d25aa0 'a') 0xaaaac4d9f2e0->Object::Object { 0xffffc5d25aa0 } 0xffffc5d25aa0->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25aa0 } Entering state 2 Stack now 0 2 0xffffc5d25b80->Object::Object { 0xaaaac4d9f2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac4d9f2e0 'a') -> $$ = nterm item (0xffffc5d25b80 'a') 0xaaaac4d9f2e0->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25b80 } 0xaaaac4d9f2e0->Object::Object { 0xffffc5d25b80 } 0xffffc5d25b80->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25b80 } Entering state 11 Stack now 0 11 Reading a token 0xffffc5d25ab0->Object::Object { 0xaaaac4d9f2e0 } 0xffffc5d25b60->Object::Object { 0xaaaac4d9f2e0, 0xffffc5d25ab0 } 0xffffc5d25ab0->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25ab0, 0xffffc5d25b60 } Next token is token 'a' (0xffffc5d25b60 'a') 0xffffc5d25aa0->Object::Object { 0xaaaac4d9f2e0, 0xffffc5d25b60 } 0xffffc5d25b60->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25aa0, 0xffffc5d25b60 } Shifting token 'a' (0xffffc5d25aa0 'a') 0xaaaac4d9f300->Object::Object { 0xaaaac4d9f2e0, 0xffffc5d25aa0 } 0xffffc5d25aa0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25aa0 } Entering state 2 Stack now 0 11 2 0xffffc5d25b80->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac4d9f300 'a') -> $$ = nterm item (0xffffc5d25b80 'a') 0xaaaac4d9f300->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25b80 } 0xaaaac4d9f300->Object::Object { 0xaaaac4d9f2e0, 0xffffc5d25b80 } 0xffffc5d25b80->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25b80 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffc5d25ab0->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300 } 0xffffc5d25b60->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25ab0 } 0xffffc5d25ab0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25ab0, 0xffffc5d25b60 } Next token is token 'a' (0xffffc5d25b60 'a') 0xffffc5d25aa0->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25b60 } 0xffffc5d25b60->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25aa0, 0xffffc5d25b60 } Shifting token 'a' (0xffffc5d25aa0 'a') 0xaaaac4d9f320->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25aa0 } 0xffffc5d25aa0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25aa0 } Entering state 2 Stack now 0 11 11 2 0xffffc5d25b80->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac4d9f320 'a') -> $$ = nterm item (0xffffc5d25b80 'a') 0xaaaac4d9f320->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25b80 } 0xaaaac4d9f320->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25b80 } 0xffffc5d25b80->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25b80 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffc5d25ab0->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320 } 0xffffc5d25b60->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25ab0 } 0xffffc5d25ab0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25ab0, 0xffffc5d25b60 } Next token is token 'a' (0xffffc5d25b60 'a') 0xffffc5d25aa0->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25b60 } 0xffffc5d25b60->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25aa0, 0xffffc5d25b60 } Shifting token 'a' (0xffffc5d25aa0 'a') 0xaaaac4d9f340->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25aa0 } 0xffffc5d25aa0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25aa0 } Entering state 2 Stack now 0 11 11 11 2 0xffffc5d25b80->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac4d9f340 'a') -> $$ = nterm item (0xffffc5d25b80 'a') 0xaaaac4d9f340->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25b80 } 0xaaaac4d9f340->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25b80 } 0xffffc5d25b80->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25b80 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffc5d25ab0->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340 } 0xffffc5d25b60->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25ab0 } 0xffffc5d25ab0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25ab0, 0xffffc5d25b60 } Next token is token 'p' (0xffffc5d25b60 'p'Exception caught: cleaning lookahead and stack 0xaaaac4d9f340->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25b60 } 0xaaaac4d9f320->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25b60 } 0xaaaac4d9f300->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25b60 } 0xaaaac4d9f2e0->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25b60 } 0xffffc5d25b60->Object::~Object { 0xffffc5d25b60 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaE stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc5d25ab0->Object::Object { } 0xffffc5d25b60->Object::Object { 0xffffc5d25ab0 } 0xffffc5d25ab0->Object::~Object { 0xffffc5d25ab0, 0xffffc5d25b60 } Next token is token 'a' (0xffffc5d25b60 'a') 0xffffc5d25aa0->Object::Object { 0xffffc5d25b60 } 0xffffc5d25b60->Object::~Object { 0xffffc5d25aa0, 0xffffc5d25b60 } Shifting token 'a' (0xffffc5d25aa0 'a') 0xaaaac4d9f2e0->Object::Object { 0xffffc5d25aa0 } 0xffffc5d25aa0->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25aa0 } Entering state 2 Stack now 0 2 0xffffc5d25b80->Object::Object { 0xaaaac4d9f2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac4d9f2e0 'a') -> $$ = nterm item (0xffffc5d25b80 'a') 0xaaaac4d9f2e0->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25b80 } 0xaaaac4d9f2e0->Object::Object { 0xffffc5d25b80 } 0xffffc5d25b80->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25b80 } Entering state 11 Stack now 0 11 Reading a token 0xffffc5d25ab0->Object::Object { 0xaaaac4d9f2e0 } 0xffffc5d25b60->Object::Object { 0xaaaac4d9f2e0, 0xffffc5d25ab0 } 0xffffc5d25ab0->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25ab0, 0xffffc5d25b60 } Next token is token 'a' (0xffffc5d25b60 'a') 0xffffc5d25aa0->Object::Object { 0xaaaac4d9f2e0, 0xffffc5d25b60 } 0xffffc5d25b60->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25aa0, 0xffffc5d25b60 } Shifting token 'a' (0xffffc5d25aa0 'a') 0xaaaac4d9f300->Object::Object { 0xaaaac4d9f2e0, 0xffffc5d25aa0 } 0xffffc5d25aa0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25aa0 } Entering state 2 Stack now 0 11 2 0xffffc5d25b80->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac4d9f300 'a') -> $$ = nterm item (0xffffc5d25b80 'a') 0xaaaac4d9f300->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25b80 } 0xaaaac4d9f300->Object::Object { 0xaaaac4d9f2e0, 0xffffc5d25b80 } 0xffffc5d25b80->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25b80 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffc5d25ab0->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300 } 0xffffc5d25b60->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25ab0 } 0xffffc5d25ab0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25ab0, 0xffffc5d25b60 } Next token is token 'a' (0xffffc5d25b60 'a') 0xffffc5d25aa0->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25b60 } 0xffffc5d25b60->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25aa0, 0xffffc5d25b60 } Shifting token 'a' (0xffffc5d25aa0 'a') 0xaaaac4d9f320->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25aa0 } 0xffffc5d25aa0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25aa0 } Entering state 2 Stack now 0 11 11 2 0xffffc5d25b80->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac4d9f320 'a') -> $$ = nterm item (0xffffc5d25b80 'a') 0xaaaac4d9f320->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25b80 } 0xaaaac4d9f320->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25b80 } 0xffffc5d25b80->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25b80 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffc5d25ab0->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320 } 0xffffc5d25b60->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25ab0 } 0xffffc5d25ab0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25ab0, 0xffffc5d25b60 } Next token is token 'a' (0xffffc5d25b60 'a') 0xffffc5d25aa0->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25b60 } 0xffffc5d25b60->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25aa0, 0xffffc5d25b60 } Shifting token 'a' (0xffffc5d25aa0 'a') 0xaaaac4d9f340->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25aa0 } 0xffffc5d25aa0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25aa0 } Entering state 2 Stack now 0 11 11 11 2 0xffffc5d25b80->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac4d9f340 'a') -> $$ = nterm item (0xffffc5d25b80 'a') 0xaaaac4d9f340->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25b80 } 0xaaaac4d9f340->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25b80 } 0xffffc5d25b80->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25b80 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffc5d25ab0->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340 } 0xffffc5d25b60->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25ab0 } 0xffffc5d25ab0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25ab0, 0xffffc5d25b60 } Next token is token 'p' (0xffffc5d25b60 'p'Exception caught: cleaning lookahead and stack 0xaaaac4d9f340->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25b60 } 0xaaaac4d9f320->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25b60 } 0xaaaac4d9f300->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25b60 } 0xaaaac4d9f2e0->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25b60 } 0xffffc5d25b60->Object::~Object { 0xffffc5d25b60 } exception caught: printer end { } exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: grep '^exception caught: printer$' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1360: $PREPARSER ./input aaaaT ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:857: $PREPARSER ./input ./c++.at:1362: $PREPARSER ./input aaaaE ./c++.at:1360: $PREPARSER ./input aaaaR stderr: stderr: stderr: ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ======== Testing with C++ standard flags: '' stdout: ./c++.at:851: $PREPARSER ./input ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaT ======== Testing with C++ standard flags: '' ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaR stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: ./cxx-type.at:423: $PREPARSER ./types test-input stderr: syntax error ./cxx-type.at:423: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:423: $PREPARSER ./types -p test-input stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () ./cxx-type.at:423: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () 707. cxx-type.at:420: ok stderr: stdout: ./c++.at:1555: $PREPARSER ./test stderr: ./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: 709. cxx-type.at:432: testing GLR: Merge conflicting parses, impure, no locations ... ./cxx-type.at:429: $PREPARSER ./types test-input ./cxx-type.at:433: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y stderr: 17.5: syntax error ./cxx-type.at:429: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:429: $PREPARSER ./types -p test-input stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) stderr: stdout: ./c++.at:1555: ./check ./cxx-type.at:429: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y stderr: types.y:77.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stderr: ./cxx-type.at:433: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) 708. cxx-type.at:426: ok ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 710. cxx-type.at:438: testing GLR: Merge conflicting parses, impure, locations ... ./cxx-type.at:439: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y stderr: types.y:87.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./cxx-type.at:439: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS stderr: stdout: ./c++.at:1363: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaal stderr: stdout: stderr: exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:851: $PREPARSER ./input stderr: ./c++.at:1363: $PREPARSER ./input i ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: ./c++.at:857: $PREPARSER ./input ./c++.at:1363: $PREPARSER ./input aaaap stderr: stderr: ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1363: $PREPARSER ./input --debug aaaap ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc2fd68c0->Object::Object { } 0xffffc2fd69c0->Object::Object { 0xffffc2fd68c0 } 0xffffc2fd68c0->Object::~Object { 0xffffc2fd68c0, 0xffffc2fd69c0 } Next token is token 'a' (0xffffc2fd69c0 'a') 0xffffc2fd6900->Object::Object { 0xffffc2fd69c0 } 0xffffc2fd69c0->Object::~Object { 0xffffc2fd6900, 0xffffc2fd69c0 } Shifting token 'a' (0xffffc2fd6900 'a') 0xaaaafbdb42e0->Object::Object { 0xffffc2fd6900 } 0xffffc2fd6900->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd6900 } Entering state 1 Stack now 0 1 0xffffc2fd69e0->Object::Object { 0xaaaafbdb42e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafbdb42e0 'a') -> $$ = nterm item (0xffffc2fd69e0 'a') 0xaaaafbdb42e0->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd69e0 } 0xaaaafbdb42e0->Object::Object { 0xffffc2fd69e0 } 0xffffc2fd69e0->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd69e0 } Entering state 10 Stack now 0 10 Reading a token 0xffffc2fd68c0->Object::Object { 0xaaaafbdb42e0 } 0xffffc2fd69c0->Object::Object { 0xaaaafbdb42e0, 0xffffc2fd68c0 } 0xffffc2fd68c0->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd68c0, 0xffffc2fd69c0 } Next token is token 'a' (0xffffc2fd69c0 'a') 0xffffc2fd6900->Object::Object { 0xaaaafbdb42e0, 0xffffc2fd69c0 } 0xffffc2fd69c0->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd6900, 0xffffc2fd69c0 } Shifting token 'a' (0xffffc2fd6900 'a') 0xaaaafbdb4300->Object::Object { 0xaaaafbdb42e0, 0xffffc2fd6900 } 0xffffc2fd6900->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd6900 } Entering state 1 Stack now 0 10 1 0xffffc2fd69e0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafbdb4300 'a') -> $$ = nterm item (0xffffc2fd69e0 'a') 0xaaaafbdb4300->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd69e0 } 0xaaaafbdb4300->Object::Object { 0xaaaafbdb42e0, 0xffffc2fd69e0 } 0xffffc2fd69e0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd69e0 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffc2fd68c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300 } 0xffffc2fd69c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd68c0 } 0xffffc2fd68c0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd68c0, 0xffffc2fd69c0 } Next token is token 'a' (0xffffc2fd69c0 'a') 0xffffc2fd6900->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd69c0 } 0xffffc2fd69c0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd6900, 0xffffc2fd69c0 } Shifting token 'a' (0xffffc2fd6900 'a') 0xaaaafbdb4320->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd6900 } 0xffffc2fd6900->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd6900 } Entering state 1 Stack now 0 10 10 1 0xffffc2fd69e0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafbdb4320 'a') -> $$ = nterm item (0xffffc2fd69e0 'a') 0xaaaafbdb4320->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd69e0 } 0xaaaafbdb4320->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd69e0 } 0xffffc2fd69e0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd69e0 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffc2fd68c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320 } 0xffffc2fd69c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd68c0 } 0xffffc2fd68c0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd68c0, 0xffffc2fd69c0 } Next token is token 'a' (0xffffc2fd69c0 'a') 0xffffc2fd6900->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd69c0 } 0xffffc2fd69c0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd6900, 0xffffc2fd69c0 } Shifting token 'a' (0xffffc2fd6900 'a') 0xaaaafbdb4340->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd6900 } 0xffffc2fd6900->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd6900 } Entering state 1 Stack now 0 10 10 10 1 0xffffc2fd69e0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafbdb4340 'a') -> $$ = nterm item (0xffffc2fd69e0 'a') 0xaaaafbdb4340->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd69e0 } 0xaaaafbdb4340->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd69e0 } 0xffffc2fd69e0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd69e0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffc2fd68c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340 } 0xffffc2fd69c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd68c0 } 0xffffc2fd68c0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd68c0, 0xffffc2fd69c0 } Next token is token 'p' (0xffffc2fd69c0 'p'Exception caught: cleaning lookahead and stack 0xaaaafbdb4340->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd69c0 } 0xaaaafbdb4320->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd69c0 } 0xaaaafbdb4300->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd69c0 } 0xaaaafbdb42e0->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd69c0 } 0xffffc2fd69c0->Object::~Object { 0xffffc2fd69c0 } exception caught: printer end { } ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc2fd68c0->Object::Object { } 0xffffc2fd69c0->Object::Object { 0xffffc2fd68c0 } 0xffffc2fd68c0->Object::~Object { 0xffffc2fd68c0, 0xffffc2fd69c0 } Next token is token 'a' (0xffffc2fd69c0 'a') 0xffffc2fd6900->Object::Object { 0xffffc2fd69c0 } 0xffffc2fd69c0->Object::~Object { 0xffffc2fd6900, 0xffffc2fd69c0 } Shifting token 'a' (0xffffc2fd6900 'a') 0xaaaafbdb42e0->Object::Object { 0xffffc2fd6900 } 0xffffc2fd6900->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd6900 } Entering state 1 Stack now 0 1 0xffffc2fd69e0->Object::Object { 0xaaaafbdb42e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafbdb42e0 'a') -> $$ = nterm item (0xffffc2fd69e0 'a') 0xaaaafbdb42e0->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd69e0 } 0xaaaafbdb42e0->Object::Object { 0xffffc2fd69e0 } 0xffffc2fd69e0->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd69e0 } Entering state 10 Stack now 0 10 Reading a token 0xffffc2fd68c0->Object::Object { 0xaaaafbdb42e0 } 0xffffc2fd69c0->Object::Object { 0xaaaafbdb42e0, 0xffffc2fd68c0 } 0xffffc2fd68c0->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd68c0, 0xffffc2fd69c0 } Next token is token 'a' (0xffffc2fd69c0 'a') 0xffffc2fd6900->Object::Object { 0xaaaafbdb42e0, 0xffffc2fd69c0 } 0xffffc2fd69c0->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd6900, 0xffffc2fd69c0 } Shifting token 'a' (0xffffc2fd6900 'a') 0xaaaafbdb4300->Object::Object { 0xaaaafbdb42e0, 0xffffc2fd6900 } 0xffffc2fd6900->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd6900 } Entering state 1 Stack now 0 10 1 0xffffc2fd69e0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafbdb4300 'a') -> $$ = nterm item (0xffffc2fd69e0 'a') 0xaaaafbdb4300->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd69e0 } 0xaaaafbdb4300->Object::Object { 0xaaaafbdb42e0, 0xffffc2fd69e0 } 0xffffc2fd69e0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd69e0 } Entering state 10 Stack now 0 10 10 Reading a token 0xffffc2fd68c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300 } 0xffffc2fd69c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd68c0 } 0xffffc2fd68c0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd68c0, 0xffffc2fd69c0 } Next token is token 'a' (0xffffc2fd69c0 'a') 0xffffc2fd6900->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd69c0 } 0xffffc2fd69c0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd6900, 0xffffc2fd69c0 } Shifting token 'a' (0xffffc2fd6900 'a') 0xaaaafbdb4320->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd6900 } 0xffffc2fd6900->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd6900 } Entering state 1 Stack now 0 10 10 1 0xffffc2fd69e0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafbdb4320 'a') -> $$ = nterm item (0xffffc2fd69e0 'a') 0xaaaafbdb4320->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd69e0 } 0xaaaafbdb4320->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd69e0 } 0xffffc2fd69e0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd69e0 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xffffc2fd68c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320 } 0xffffc2fd69c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd68c0 } 0xffffc2fd68c0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd68c0, 0xffffc2fd69c0 } Next token is token 'a' (0xffffc2fd69c0 'a') 0xffffc2fd6900->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd69c0 } 0xffffc2fd69c0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd6900, 0xffffc2fd69c0 } Shifting token 'a' (0xffffc2fd6900 'a') 0xaaaafbdb4340->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd6900 } 0xffffc2fd6900->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd6900 } Entering state 1 Stack now 0 10 10 10 1 0xffffc2fd69e0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaafbdb4340 'a') -> $$ = nterm item (0xffffc2fd69e0 'a') 0xaaaafbdb4340->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd69e0 } 0xaaaafbdb4340->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd69e0 } 0xffffc2fd69e0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd69e0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xffffc2fd68c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340 } 0xffffc2fd69c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd68c0 } 0xffffc2fd68c0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd68c0, 0xffffc2fd69c0 } Next token is token 'p' (0xffffc2fd69c0 'p'Exception caught: cleaning lookahead and stack 0xaaaafbdb4340->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd69c0 } 0xaaaafbdb4320->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd69c0 } 0xaaaafbdb4300->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd69c0 } 0xaaaafbdb42e0->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd69c0 } 0xffffc2fd69c0->Object::~Object { 0xffffc2fd69c0 } exception caught: printer end { } ./c++.at:1363: grep '^exception caught: printer$' stderr stderr: ./c++.at:1064: $PREPARSER ./input < in stdout: stdout: exception caught: printer ./c++.at:1363: $PREPARSER ./input aaaae ./c++.at:1361: $PREPARSER ./input aaaas stderr: stderr: stderr: exception caught: reduction ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: invalid expression caught error error: invalid character caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaal ./c++.at:1064: $PREPARSER ./input < in ./c++.at:1363: $PREPARSER ./input aaaaE stderr: stderr: stderr: exception caught: yylex exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input i ./c++.at:1064: $PREPARSER ./input < in ./c++.at:1363: $PREPARSER ./input aaaaT stderr: stderr: exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaR stderr: ./c++.at:1361: $PREPARSER ./input aaaap ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 682. c++.at:1064: ok stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaeaddcf40->Object::Object { } Next token is token 'a' (0xaaaaeaddcf40 'a') Shifting token 'a' (0xaaaaeaddcf40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaeaddcf40 'a') -> $$ = nterm item (0xaaaaeaddcf40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaaeaddcf90->Object::Object { 0xaaaaeaddcf40 } Next token is token 'a' (0xaaaaeaddcf90 'a') Shifting token 'a' (0xaaaaeaddcf90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaeaddcf90 'a') -> $$ = nterm item (0xaaaaeaddcf90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaaeaddcfe0->Object::Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90 } Next token is token 'a' (0xaaaaeaddcfe0 'a') Shifting token 'a' (0xaaaaeaddcfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaeaddcfe0 'a') -> $$ = nterm item (0xaaaaeaddcfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaaeaddd030->Object::Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90, 0xaaaaeaddcfe0 } Next token is token 'a' (0xaaaaeaddd030 'a') Shifting token 'a' (0xaaaaeaddd030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaeaddd030 'a') -> $$ = nterm item (0xaaaaeaddd030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaaeaddd080->Object::Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90, 0xaaaaeaddcfe0, 0xaaaaeaddd030 } Next token is token 'p' (0xaaaaeaddd080 'p'Exception caught: cleaning lookahead and stack 0xaaaaeaddd080->Object::~Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90, 0xaaaaeaddcfe0, 0xaaaaeaddd030, 0xaaaaeaddd080 } 0xaaaaeaddd030->Object::~Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90, 0xaaaaeaddcfe0, 0xaaaaeaddd030 } 0xaaaaeaddcfe0->Object::~Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90, 0xaaaaeaddcfe0 } 0xaaaaeaddcf90->Object::~Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90 } 0xaaaaeaddcf40->Object::~Object { 0xaaaaeaddcf40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaaeaddcf40->Object::Object { } Next token is token 'a' (0xaaaaeaddcf40 'a') Shifting token 'a' (0xaaaaeaddcf40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaeaddcf40 'a') -> $$ = nterm item (0xaaaaeaddcf40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaaeaddcf90->Object::Object { 0xaaaaeaddcf40 } Next token is token 'a' (0xaaaaeaddcf90 'a') Shifting token 'a' (0xaaaaeaddcf90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaeaddcf90 'a') -> $$ = nterm item (0xaaaaeaddcf90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaaeaddcfe0->Object::Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90 } Next token is token 'a' (0xaaaaeaddcfe0 'a') Shifting token 'a' (0xaaaaeaddcfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaeaddcfe0 'a') -> $$ = nterm item (0xaaaaeaddcfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaaeaddd030->Object::Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90, 0xaaaaeaddcfe0 } Next token is token 'a' (0xaaaaeaddd030 'a') Shifting token 'a' (0xaaaaeaddd030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaaeaddd030 'a') -> $$ = nterm item (0xaaaaeaddd030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaaeaddd080->Object::Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90, 0xaaaaeaddcfe0, 0xaaaaeaddd030 } Next token is token 'p' (0xaaaaeaddd080 'p'Exception caught: cleaning lookahead and stack 0xaaaaeaddd080->Object::~Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90, 0xaaaaeaddcfe0, 0xaaaaeaddd030, 0xaaaaeaddd080 } 0xaaaaeaddd030->Object::~Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90, 0xaaaaeaddcfe0, 0xaaaaeaddd030 } 0xaaaaeaddcfe0->Object::~Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90, 0xaaaaeaddcfe0 } 0xaaaaeaddcf90->Object::~Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90 } 0xaaaaeaddcf40->Object::~Object { 0xaaaaeaddcf40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr stdout: stderr: exception caught: printer ./c++.at:1361: $PREPARSER ./input aaaae stderr: stdout: exception caught: syntax error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:435: $PREPARSER ./types test-input stderr: syntax error ./cxx-type.at:435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaE stderr: ./cxx-type.at:435: $PREPARSER ./types -p test-input 711. cxx-type.at:444: testing GLR: Merge conflicting parses, pure, no locations ... ./cxx-type.at:445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () ./cxx-type.at:435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaT stderr: stderr: stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () types.y:77.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./cxx-type.at:445: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS 709. cxx-type.at:432: ok ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaR stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 712. cxx-type.at:449: testing GLR: Merge conflicting parses, pure, locations ... ./cxx-type.at:450: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y stderr: types.y:87.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples ./cxx-type.at:450: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS stderr: stdout: ./cxx-type.at:441: $PREPARSER ./types test-input stderr: stdout: ./c++.at:1360: $PREPARSER ./input aaaas stderr: stderr: exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 17.5: syntax error ./c++.at:1360: $PREPARSER ./input aaaal ./cxx-type.at:441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: yylex ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:441: $PREPARSER ./types -p test-input ./c++.at:1360: $PREPARSER ./input i stderr: stdout: stderr: stderr: exception caught: initial-action ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (13.3: ) -> $$ = nterm expr (13.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (13.0: ) $2 = token '(' (13.2: ) $3 = nterm expr (13.3: ) $4 = token ')' (13.4: ) -> $$ = nterm expr (13.0-4: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (13.0-4: ) $2 = token ';' (13.5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.3: ) -> $$ = nterm expr (15.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (15.0: ) $2 = token '(' (15.2: ) $3 = nterm expr (15.3: ) $4 = token ')' (15.4: ) -> $$ = nterm expr (15.0-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 10 (line 94): $1 = nterm expr (15.0-4: ) $2 = token '=' (15.6: ) $3 = nterm expr (15.8-12: ) -> $$ = nterm expr (15.0-12: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (15.0-12: ) $2 = token ';' (15.13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) ./c++.at:851: $PREPARSER ./input stderr: ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaap stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:1360: $PREPARSER ./input --debug aaaap Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (13.3: ) -> $$ = nterm expr (13.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (13.0: ) $2 = token '(' (13.2: ) $3 = nterm expr (13.3: ) $4 = token ')' (13.4: ) -> $$ = nterm expr (13.0-4: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (13.0-4: ) $2 = token ';' (13.5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.3: ) -> $$ = nterm expr (15.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (15.0: ) $2 = token '(' (15.2: ) $3 = nterm expr (15.3: ) $4 = token ')' (15.4: ) -> $$ = nterm expr (15.0-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 10 (line 94): $1 = nterm expr (15.0-4: ) $2 = token '=' (15.6: ) $3 = nterm expr (15.8-12: ) -> $$ = nterm expr (15.0-12: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (15.0-12: ) $2 = token ';' (15.13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) stderr: 710. cxx-type.at:438: ok Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae45fcf40->Object::Object { } Next token is token 'a' (0xaaaae45fcf40 'a') Shifting token 'a' (0xaaaae45fcf40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae45fcf40 'a') -> $$ = nterm item (0xaaaae45fcf40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaae45fcf90->Object::Object { 0xaaaae45fcf40 } Next token is token 'a' (0xaaaae45fcf90 'a') Shifting token 'a' (0xaaaae45fcf90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae45fcf90 'a') -> $$ = nterm item (0xaaaae45fcf90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaae45fcfe0->Object::Object { 0xaaaae45fcf40, 0xaaaae45fcf90 } Next token is token 'a' (0xaaaae45fcfe0 'a') Shifting token 'a' (0xaaaae45fcfe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae45fcfe0 'a') -> $$ = nterm item (0xaaaae45fcfe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaae45fd030->Object::Object { 0xaaaae45fcf40, 0xaaaae45fcf90, 0xaaaae45fcfe0 } Next token is token 'a' (0xaaaae45fd030 'a') Shifting token 'a' (0xaaaae45fd030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae45fd030 'a') -> $$ = nterm item (0xaaaae45fd030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaae45fd080->Object::Object { 0xaaaae45fcf40, 0xaaaae45fcf90, 0xaaaae45fcfe0, 0xaaaae45fd030 } Next token is token 'p' (0xaaaae45fd080 'p'Exception caught: cleaning lookahead and stack 0xaaaae45fd080->Object::~Object { 0xaaaae45fcf40, 0xaaaae45fcf90, 0xaaaae45fcfe0, 0xaaaae45fd030, 0xaaaae45fd080 } 0xaaaae45fd030->Object::~Object { 0xaaaae45fcf40, 0xaaaae45fcf90, 0xaaaae45fcfe0, 0xaaaae45fd030 } 0xaaaae45fcfe0->Object::~Object { 0xaaaae45fcf40, 0xaaaae45fcf90, 0xaaaae45fcfe0 } 0xaaaae45fcf90->Object::~Object { 0xaaaae45fcf40, 0xaaaae45fcf90 } 0xaaaae45fcf40->Object::~Object { 0xaaaae45fcf40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1066: $PREPARSER ./input < in stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae45fcf40->Object::Object { } Next token is token 'a' (0xaaaae45fcf40 'a') Shifting token 'a' (0xaaaae45fcf40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae45fcf40 'a') -> $$ = nterm item (0xaaaae45fcf40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaae45fcf90->Object::Object { 0xaaaae45fcf40 } Next token is token 'a' (0xaaaae45fcf90 'a') Shifting token 'a' (0xaaaae45fcf90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae45fcf90 'a') -> $$ = nterm item (0xaaaae45fcf90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaae45fcfe0->Object::Object { 0xaaaae45fcf40, 0xaaaae45fcf90 } Next token is token 'a' (0xaaaae45fcfe0 'a') Shifting token 'a' (0xaaaae45fcfe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae45fcfe0 'a') -> $$ = nterm item (0xaaaae45fcfe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaae45fd030->Object::Object { 0xaaaae45fcf40, 0xaaaae45fcf90, 0xaaaae45fcfe0 } Next token is token 'a' (0xaaaae45fd030 'a') Shifting token 'a' (0xaaaae45fd030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae45fd030 'a') -> $$ = nterm item (0xaaaae45fd030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaae45fd080->Object::Object { 0xaaaae45fcf40, 0xaaaae45fcf90, 0xaaaae45fcfe0, 0xaaaae45fd030 } Next token is token 'p' (0xaaaae45fd080 'p'Exception caught: cleaning lookahead and stack 0xaaaae45fd080->Object::~Object { 0xaaaae45fcf40, 0xaaaae45fcf90, 0xaaaae45fcfe0, 0xaaaae45fd030, 0xaaaae45fd080 } 0xaaaae45fd030->Object::~Object { 0xaaaae45fcf40, 0xaaaae45fcf90, 0xaaaae45fcfe0, 0xaaaae45fd030 } 0xaaaae45fcfe0->Object::~Object { 0xaaaae45fcf40, 0xaaaae45fcf90, 0xaaaae45fcfe0 } 0xaaaae45fcf90->Object::~Object { 0xaaaae45fcf40, 0xaaaae45fcf90 } 0xaaaae45fcf40->Object::~Object { 0xaaaae45fcf40 } exception caught: printer end { } ./c++.at:1360: grep '^exception caught: printer$' stderr stderr: stdout: stderr: stdout: ./c++.at:857: $PREPARSER ./input stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae stderr: ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $PREPARSER ./input < in 713. cxx-type.at:455: testing GLR: Verbose messages, resolve ambiguity, impure, no locations ... ./c++.at:1360: $PREPARSER ./input aaaaE stderr: stderr: error: invalid expression ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:456: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y ./c++.at:1360: $PREPARSER ./input aaaaT ./c++.at:1066: $PREPARSER ./input < in stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1360: $PREPARSER ./input aaaaR error: invalid character ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stdout: ./c++.at:1362: $PREPARSER ./input aaaas stderr: stderr: types.y:77.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:456: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1362: $PREPARSER ./input aaaal ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1362: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./c++.at:1362: $PREPARSER ./input aaaap stderr: stderr: stdout: ./cxx-type.at:447: $PREPARSER ./types test-input stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error ./cxx-type.at:447: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: ./cxx-type.at:447: $PREPARSER ./types -p test-input Starting parse Entering state 0 Stack now 0 Reading a token 0xffffd2ad09a0->Object::Object { } 0xffffd2ad0aa0->Object::Object { 0xffffd2ad09a0 } 0xffffd2ad09a0->Object::~Object { 0xffffd2ad09a0, 0xffffd2ad0aa0 } Next token is token 'a' (0xffffd2ad0aa0 'a') 0xffffd2ad09e0->Object::Object { 0xffffd2ad0aa0 } 0xffffd2ad0aa0->Object::~Object { 0xffffd2ad09e0, 0xffffd2ad0aa0 } Shifting token 'a' (0xffffd2ad09e0 'a') 0xaaaab96da2e0->Object::Object { 0xffffd2ad09e0 } 0xffffd2ad09e0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad09e0 } Entering state 2 Stack now 0 2 0xffffd2ad0ac0->Object::Object { 0xaaaab96da2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab96da2e0 'a') -> $$ = nterm item (0xffffd2ad0ac0 'a') 0xaaaab96da2e0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad0ac0 } 0xaaaab96da2e0->Object::Object { 0xffffd2ad0ac0 } 0xffffd2ad0ac0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad0ac0 } Entering state 11 Stack now 0 11 Reading a token 0xffffd2ad09a0->Object::Object { 0xaaaab96da2e0 } 0xffffd2ad0aa0->Object::Object { 0xaaaab96da2e0, 0xffffd2ad09a0 } 0xffffd2ad09a0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad09a0, 0xffffd2ad0aa0 } Next token is token 'a' (0xffffd2ad0aa0 'a') 0xffffd2ad09e0->Object::Object { 0xaaaab96da2e0, 0xffffd2ad0aa0 } 0xffffd2ad0aa0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad09e0, 0xffffd2ad0aa0 } Shifting token 'a' (0xffffd2ad09e0 'a') 0xaaaab96da300->Object::Object { 0xaaaab96da2e0, 0xffffd2ad09e0 } 0xffffd2ad09e0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad09e0 } Entering state 2 Stack now 0 11 2 0xffffd2ad0ac0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab96da300 'a') -> $$ = nterm item (0xffffd2ad0ac0 'a') 0xaaaab96da300->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad0ac0 } 0xaaaab96da300->Object::Object { 0xaaaab96da2e0, 0xffffd2ad0ac0 } 0xffffd2ad0ac0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad0ac0 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffd2ad09a0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300 } 0xffffd2ad0aa0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad09a0 } 0xffffd2ad09a0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad09a0, 0xffffd2ad0aa0 } Next token is token 'a' (0xffffd2ad0aa0 'a') 0xffffd2ad09e0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad0aa0 } 0xffffd2ad0aa0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad09e0, 0xffffd2ad0aa0 } Shifting token 'a' (0xffffd2ad09e0 'a') 0xaaaab96da320->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad09e0 } 0xffffd2ad09e0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad09e0 } Entering state 2 Stack now 0 11 11 2 0xffffd2ad0ac0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab96da320 'a') -> $$ = nterm item (0xffffd2ad0ac0 'a') 0xaaaab96da320->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad0ac0 } 0xaaaab96da320->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad0ac0 } 0xffffd2ad0ac0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad0ac0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffd2ad09a0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320 } 0xffffd2ad0aa0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad09a0 } 0xffffd2ad09a0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad09a0, 0xffffd2ad0aa0 } Next token is token 'a' (0xffffd2ad0aa0 'a') 0xffffd2ad09e0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad0aa0 } 0xffffd2ad0aa0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad09e0, 0xffffd2ad0aa0 } Shifting token 'a' (0xffffd2ad09e0 'a') 0xaaaab96da340->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad09e0 } 0xffffd2ad09e0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad09e0 } Entering state 2 Stack now 0 11 11 11 2 0xffffd2ad0ac0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab96da340 'a') -> $$ = nterm item (0xffffd2ad0ac0 'a') 0xaaaab96da340->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad0ac0 } 0xaaaab96da340->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad0ac0 } 0xffffd2ad0ac0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad0ac0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffd2ad09a0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340 } 0xffffd2ad0aa0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad09a0 } 0xffffd2ad09a0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad09a0, 0xffffd2ad0aa0 } Next token is token 'p' (0xffffd2ad0aa0 'p'Exception caught: cleaning lookahead and stack 0xaaaab96da340->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad0aa0 } 0xaaaab96da320->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad0aa0 } 0xaaaab96da300->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad0aa0 } 0xaaaab96da2e0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad0aa0 } 0xffffd2ad0aa0->Object::~Object { 0xffffd2ad0aa0 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -stdout: > $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () ./c++.at:1066: ./check ./cxx-type.at:447: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS 711. cxx-type.at:444: ok Starting parse Entering state 0 Stack now 0 Reading a token 0xffffd2ad09a0->Object::Object { } 0xffffd2ad0aa0->Object::Object { 0xffffd2ad09a0 } 0xffffd2ad09a0->Object::~Object { 0xffffd2ad09a0, 0xffffd2ad0aa0 } Next token is token 'a' (0xffffd2ad0aa0 'a') 0xffffd2ad09e0->Object::Object { 0xffffd2ad0aa0 } 0xffffd2ad0aa0->Object::~Object { 0xffffd2ad09e0, 0xffffd2ad0aa0 } Shifting token 'a' (0xffffd2ad09e0 'a') 0xaaaab96da2e0->Object::Object { 0xffffd2ad09e0 } 0xffffd2ad09e0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad09e0 } Entering state 2 Stack now 0 2 0xffffd2ad0ac0->Object::Object { 0xaaaab96da2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab96da2e0 'a') -> $$ = nterm item (0xffffd2ad0ac0 'a') 0xaaaab96da2e0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad0ac0 } 0xaaaab96da2e0->Object::Object { 0xffffd2ad0ac0 } 0xffffd2ad0ac0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad0ac0 } Entering state 11 Stack now 0 11 Reading a token 0xffffd2ad09a0->Object::Object { 0xaaaab96da2e0 } 0xffffd2ad0aa0->Object::Object { 0xaaaab96da2e0, 0xffffd2ad09a0 } 0xffffd2ad09a0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad09a0, 0xffffd2ad0aa0 } Next token is token 'a' (0xffffd2ad0aa0 'a') 0xffffd2ad09e0->Object::Object { 0xaaaab96da2e0, 0xffffd2ad0aa0 } 0xffffd2ad0aa0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad09e0, 0xffffd2ad0aa0 } Shifting token 'a' (0xffffd2ad09e0 'a') 0xaaaab96da300->Object::Object { 0xaaaab96da2e0, 0xffffd2ad09e0 } 0xffffd2ad09e0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad09e0 } Entering state 2 Stack now 0 11 2 0xffffd2ad0ac0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab96da300 'a') -> $$ = nterm item (0xffffd2ad0ac0 'a') 0xaaaab96da300->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad0ac0 } 0xaaaab96da300->Object::Object { 0xaaaab96da2e0, 0xffffd2ad0ac0 } 0xffffd2ad0ac0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad0ac0 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffd2ad09a0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300 } 0xffffd2ad0aa0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad09a0 } 0xffffd2ad09a0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad09a0, 0xffffd2ad0aa0 } Next token is token 'a' (0xffffd2ad0aa0 'a') 0xffffd2ad09e0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad0aa0 } 0xffffd2ad0aa0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad09e0, 0xffffd2ad0aa0 } Shifting token 'a' (0xffffd2ad09e0 'a') 0xaaaab96da320->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad09e0 } 0xffffd2ad09e0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad09e0 } Entering state 2 Stack now 0 11 11 2 0xffffd2ad0ac0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab96da320 'a') -> $$ = nterm item (0xffffd2ad0ac0 'a') 0xaaaab96da320->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad0ac0 } 0xaaaab96da320->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad0ac0 } 0xffffd2ad0ac0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad0ac0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffd2ad09a0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320 } 0xffffd2ad0aa0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad09a0 } 0xffffd2ad09a0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad09a0, 0xffffd2ad0aa0 } Next token is token 'a' (0xffffd2ad0aa0 'a') 0xffffd2ad09e0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad0aa0 } 0xffffd2ad0aa0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad09e0, 0xffffd2ad0aa0 } Shifting token 'a' (0xffffd2ad09e0 'a') 0xaaaab96da340->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad09e0 } 0xffffd2ad09e0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad09e0 } Entering state 2 Stack now 0 11 11 11 2 0xffffd2ad0ac0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaab96da340 'a') -> $$ = nterm item (0xffffd2ad0ac0 'a') 0xaaaab96da340->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad0ac0 } 0xaaaab96da340->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad0ac0 } 0xffffd2ad0ac0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad0ac0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffd2ad09a0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340 } 0xffffd2ad0aa0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad09a0 } 0xffffd2ad09a0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad09a0, 0xffffd2ad0aa0 } Next token is token 'p' (0xffffd2ad0aa0 'p'Exception caught: cleaning lookahead and stack 0xaaaab96da340->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad0aa0 } 0xaaaab96da320->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad0aa0 } 0xaaaab96da300->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad0aa0 } 0xaaaab96da2e0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad0aa0 } 0xffffd2ad0aa0->Object::~Object { 0xffffd2ad0aa0 } exception caught: printer end { } ./c++.at:1362: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 714. glr-regression.at:205: testing Badly Collapsed GLR States: glr.c ... ./glr-regression.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o glr-regr1.c glr-regr1.y stderr: stdout: ./c++.at:1065: $PREPARSER ./input < in ./c++.at:1362: $PREPARSER ./input aaaaT stderr: ./glr-regression.at:205: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr1 glr-regr1.c $LIBS stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: invalid expression caught error error: invalid character caught error ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaR ./c++.at:1065: $PREPARSER ./input < in stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: error: invalid expression ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1065: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 683. c++.at:1065: ok stderr: stdout: ./cxx-type.at:452: $PREPARSER ./types test-input stderr: 17.5: syntax error ./cxx-type.at:452: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:857: $PREPARSER ./input stderr: ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 715. glr-regression.at:206: testing Badly Collapsed GLR States: glr.cc ... ./glr-regression.at:206: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o glr-regr1.cc glr-regr1.y ======== Testing with C++ standard flags: '' ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./cxx-type.at:452: $PREPARSER ./types -p test-input stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (13.3: ) -> $$ = nterm expr (13.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (13.0: ) $2 = token '(' (13.2: ) $3 = nterm expr (13.3: ) $4 = token ')' (13.4: ) -> $$ = nterm expr (13.0-4: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (13.0-4: ) $2 = token ';' (13.5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.3: ) -> $$ = nterm expr (15.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (15.0: ) $2 = token '(' (15.2: ) $3 = nterm expr (15.3: ) $4 = token ')' (15.4: ) -> $$ = nterm expr (15.0-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 10 (line 94): $1 = nterm expr (15.0-4: ) $2 = token '=' (15.6: ) $3 = nterm expr (15.8-12: ) -> $$ = nterm expr (15.0-12: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (15.0-12: ) $2 = token ';' (15.13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) ./glr-regression.at:206: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr1 glr-regr1.cc $LIBS ./cxx-type.at:452: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): -> $$ = nterm prog (1.1: ) Entering state 1 Reading a token Next token is token ID (3.0: ) Shifting token ID (3.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.0: ) -> $$ = nterm expr (3.0: ) Entering state 8 Reading a token Next token is token '+' (3.2: ) Shifting token '+' (3.2: ) Entering state 15 Reading a token Next token is token ID (3.4: ) Shifting token ID (3.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (3.4: ) -> $$ = nterm expr (3.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (3.0: ) $2 = token '+' (3.2: ) $3 = nterm expr (3.4: ) -> $$ = nterm expr (3.0-4: ) Entering state 8 Reading a token Next token is token ';' (3.5: ) Shifting token ';' (3.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (3.0-4: ) $2 = token ';' (3.5: ) -> $$ = nterm stmt (3.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1: ) $2 = nterm stmt (3.0-5: ) -> $$ = nterm prog (1.1-3.5: ) Entering state 1 Reading a token Next token is token TYPENAME (5.0: ) Shifting token TYPENAME (5.0: ) Entering state 4 Reading a token Next token is token ID (5.2: ) Shifting token ID (5.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (5.2: ) -> $$ = nterm declarator (5.2: ) Entering state 13 Reading a token Next token is token ';' (5.3: ) Shifting token ';' (5.3: ) Entering state 23 Reducing stack 0 by rule 11 (line 97): $1 = token TYPENAME (5.0: ) $2 = nterm declarator (5.2: ) $3 = token ';' (5.3: ) -> $$ = nterm decl (5.0-3: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (5.0-3: ) -> $$ = nterm stmt (5.0-3: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-3.5: ) $2 = nterm stmt (5.0-3: ) -> $$ = nterm prog (1.1-5.3: ) Entering state 1 Reading a token Next token is token TYPENAME (7.0: ) Shifting token TYPENAME (7.0: ) Entering state 4 Reading a token Next token is token ID (7.2: ) Shifting token ID (7.2: ) Entering state 11 Reducing stack 0 by rule 13 (line 104): $1 = token ID (7.2: ) -> $$ = nterm declarator (7.2: ) Entering state 13 Reading a token Next token is token '=' (7.4: ) Shifting token '=' (7.4: ) Entering state 22 Reading a token Next token is token ID (7.6: ) Shifting token ID (7.6: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (7.6: ) -> $$ = nterm expr (7.6: ) Entering state 29 Reading a token Next token is token ';' (7.7: ) Shifting token ';' (7.7: ) Entering state 30 Reducing stack 0 by rule 12 (line 99): $1 = token TYPENAME (7.0: ) $2 = nterm declarator (7.2: ) $3 = token '=' (7.4: ) $4 = nterm expr (7.6: ) $5 = token ';' (7.7: ) -> $$ = nterm decl (7.0-7: ) Entering state 9 Reducing stack 0 by rule 4 (line 85): $1 = nterm decl (7.0-7: ) -> $$ = nterm stmt (7.0-7: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-5.3: ) $2 = nterm stmt (7.0-7: ) -> $$ = nterm prog (1.1-7.7: ) Entering state 1 Reading a token Next token is token ID (9.0: ) Shifting token ID (9.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.0: ) -> $$ = nterm expr (9.0: ) Entering state 8 Reading a token Next token is token '=' (9.2: ) Shifting token '=' (9.2: ) Entering state 14 Reading a token Next token is token ID (9.4: ) Shifting token ID (9.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (9.4: ) -> $$ = nterm expr (9.4: ) Entering state 24 Reading a token Next token is token ';' (9.5: ) Reducing stack 0 by rule 10 (line 94): $1 = nterm expr (9.0: ) $2 = token '=' (9.2: ) $3 = nterm expr (9.4: ) -> $$ = nterm expr (9.0-4: ) Entering state 8 Next token is token ';' (9.5: ) Shifting token ';' (9.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (9.0-4: ) $2 = token ';' (9.5: ) -> $$ = nterm stmt (9.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-7.7: ) $2 = nterm stmt (9.0-5: ) -> $$ = nterm prog (1.1-9.5: ) Entering state 1 Reading a token Next token is token TYPENAME (11.0: ) Shifting token TYPENAME (11.0: ) Entering state 4 Reading a token Next token is token '(' (11.2: ) Shifting token '(' (11.2: ) Entering state 12 Reading a token Next token is token ID (11.3: ) Shifting token ID (11.3: ) Entering state 18 Reading a token Next token is token ')' (11.4: ) Stack 0 Entering state 18 Next token is token ')' (11.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (11.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (11.4: ) Stack 1 Entering state 21 Next token is token ')' (11.4: ) On stack 0, shifting token ')' (11.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (11.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' (11.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' (11.6: ) Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' (11.6: ) Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 90): $1 = token ID (11.3: ) -> $$ = nterm expr (11.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (11.0: ) $2 = token '(' (11.2: ) $3 = nterm expr (11.3: ) $4 = token ')' (11.4: ) -> $$ = nterm expr (11.0-4: ) Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID (11.8: ) Shifting token ID (11.8: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (11.8: ) -> $$ = nterm expr (11.8: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (11.0-4: ) $2 = token '+' (11.6: ) $3 = nterm expr (11.8: ) -> $$ = nterm expr (11.0-8: ) Entering state 8 Reading a token Next token is token ';' (11.9: ) Shifting token ';' (11.9: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (11.0-8: ) $2 = token ';' (11.9: ) -> $$ = nterm stmt (11.0-9: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-9.5: ) $2 = nterm stmt (11.0-9: ) -> $$ = nterm prog (1.1-11.9: ) Entering state 1 Reading a token Next token is token TYPENAME (13.0: ) Shifting token TYPENAME (13.0: ) Entering state 4 Reading a token Next token is token '(' (13.2: ) Shifting token '(' (13.2: ) Entering state 12 Reading a token Next token is token ID (13.3: ) Shifting token ID (13.3: ) Entering state 18 Reading a token Next token is token ')' (13.4: ) Stack 0 Entering state 18 Next token is token ')' (13.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (13.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (13.4: ) Stack 1 Entering state 21 Next token is token ')' (13.4: ) On stack 0, shifting token ')' (13.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (13.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' (13.5: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' (13.5: ) On stack 0, shifting token ';' (13.5: ) Stack 0 now in state 16 On stack 1, shifting token ';' (13.5: ) Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (15.0: ) Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 97); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (15.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (13.3: ) -> $$ = nterm declarator (13.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (13.2: ) $2 = nterm declarator (13.3: ) $3 = token ')' (13.4: ) -> $$ = nterm declarator (13.2-4: ) Reducing stack -1 by rule 11 (line 97): $1 = token TYPENAME (13.0: ) $2 = nterm declarator (13.2-4: ) $3 = token ';' (13.5: ) -> $$ = nterm decl (13.0-5: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (13.0-5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (13.3: ) -> $$ = nterm expr (13.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (13.0: ) $2 = token '(' (13.2: ) $3 = nterm expr (13.3: ) $4 = token ')' (13.4: ) -> $$ = nterm expr (13.0-4: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (13.0-4: ) $2 = token ';' (13.5: ) -> $$ = nterm stmt (13.0-5: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-11.9: ) $2 = nterm stmt (13.0-5: ) -> $$ = nterm prog (1.1-13.5: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (15.2: ) Shifting token '(' (15.2: ) Entering state 12 Reading a token Next token is token ID (15.3: ) Shifting token ID (15.3: ) Entering state 18 Reading a token Next token is token ')' (15.4: ) Stack 0 Entering state 18 Next token is token ')' (15.4: ) Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 104); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' (15.4: ) Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' (15.4: ) Stack 1 Entering state 21 Next token is token ')' (15.4: ) On stack 0, shifting token ')' (15.4: ) Stack 0 now in state 27 On stack 1, shifting token ')' (15.4: ) Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 91); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' (15.6: ) Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 105); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' (15.6: ) On stack 0, shifting token '=' (15.6: ) Stack 0 now in state 14 On stack 1, shifting token '=' (15.6: ) Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID (15.8: ) Stack 1 Entering state 22 Next token is token ID (15.8: ) On stack 0, shifting token ID (15.8: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.8: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' (15.10: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' (15.10: ) On stack 0, shifting token '+' (15.10: ) Stack 0 now in state 15 On stack 1, shifting token '+' (15.10: ) Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID (15.12: ) Stack 1 Entering state 15 Next token is token ID (15.12: ) On stack 0, shifting token ID (15.12: ) Stack 0 now in state 5 On stack 1, shifting token ID (15.12: ) Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 90); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 93); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' (15.13: ) Reduced stack 0 by rule 10 (line 94); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' (15.13: ) Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 90); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 93); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' (15.13: ) On stack 0, shifting token ';' (15.13: ) Stack 0 now in state 16 On stack 1, shifting token ';' (15.13: ) Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 84); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 72); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME (17.0: ) Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 99); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 85); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 72); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME (17.0: ) Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 104): $1 = token ID (15.3: ) -> $$ = nterm declarator (15.3: ) Reducing stack -1 by rule 14 (line 105): $1 = token '(' (15.2: ) $2 = nterm declarator (15.3: ) $3 = token ')' (15.4: ) -> $$ = nterm declarator (15.2-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 12 (line 99): $1 = token TYPENAME (15.0: ) $2 = nterm declarator (15.2-4: ) $3 = token '=' (15.6: ) $4 = nterm expr (15.8-12: ) $5 = token ';' (15.13: ) -> $$ = nterm decl (15.0-13: ) Reducing stack -1 by rule 4 (line 85): $1 = nterm decl (15.0-13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.3: ) -> $$ = nterm expr (15.3: ) Reducing stack -1 by rule 8 (line 91): $1 = token TYPENAME (15.0: ) $2 = token '(' (15.2: ) $3 = nterm expr (15.3: ) $4 = token ')' (15.4: ) -> $$ = nterm expr (15.0-4: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.8: ) -> $$ = nterm expr (15.8: ) Reducing stack -1 by rule 7 (line 90): $1 = token ID (15.12: ) -> $$ = nterm expr (15.12: ) Reducing stack -1 by rule 9 (line 93): $1 = nterm expr (15.8: ) $2 = token '+' (15.10: ) $3 = nterm expr (15.12: ) -> $$ = nterm expr (15.8-12: ) Reducing stack -1 by rule 10 (line 94): $1 = nterm expr (15.0-4: ) $2 = token '=' (15.6: ) $3 = nterm expr (15.8-12: ) -> $$ = nterm expr (15.0-12: ) Reducing stack -1 by rule 3 (line 84): $1 = nterm expr (15.0-12: ) $2 = token ';' (15.13: ) -> $$ = nterm stmt (15.0-13: ) Reducing stack -1 by rule 2 (line 72): $1 = nterm prog (1.1-13.5: ) $2 = nterm stmt (15.0-13: ) -> $$ = nterm prog (1.1-15.13: ) Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' (17.2: ) Shifting token '(' (17.2: ) Entering state 12 Reading a token Next token is token ID (17.3: ) Shifting token ID (17.3: ) Entering state 18 Reading a token Next token is token ID (17.5: ) Reducing stack 0 by rule 7 (line 90): $1 = token ID (17.3: ) -> $$ = nterm expr (17.3: ) Entering state 20 Next token is token ID (17.5: ) 17.5: syntax error Error: popping nterm expr (17.3: ) Error: popping token '(' (17.2: ) Error: popping token TYPENAME (17.0: ) Shifting token error (17.0-5: ) Entering state 3 Next token is token ID (17.5: ) Error: discarding token ID (17.5: ) Reading a token Next token is token ')' (17.6: ) Error: discarding token ')' (17.6: ) Reading a token Next token is token '=' (17.8: ) Error: discarding token '=' (17.8: ) Reading a token Next token is token ID (17.10: ) Error: discarding token ID (17.10: ) Reading a token Next token is token '+' (17.12: ) Error: discarding token '+' (17.12: ) Reading a token Next token is token ID (17.14: ) Error: discarding token ID (17.14: ) Reading a token Next token is token ';' (17.15: ) Entering state 3 Next token is token ';' (17.15: ) Shifting token ';' (17.15: ) Entering state 10 Reducing stack 0 by rule 5 (line 86): $1 = token error (17.0-14: ) $2 = token ';' (17.15: ) -> $$ = nterm stmt (17.0-15: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-15.13: ) $2 = nterm stmt (17.0-15: ) -> $$ = nterm prog (1.1-17.15: ) Entering state 1 Reading a token Next token is token ID (19.0: ) Shifting token ID (19.0: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.0: ) -> $$ = nterm expr (19.0: ) Entering state 8 Reading a token Next token is token '+' (19.2: ) Shifting token '+' (19.2: ) Entering state 15 Reading a token Next token is token ID (19.4: ) Shifting token ID (19.4: ) Entering state 5 Reducing stack 0 by rule 7 (line 90): $1 = token ID (19.4: ) -> $$ = nterm expr (19.4: ) Entering state 25 Reducing stack 0 by rule 9 (line 93): $1 = nterm expr (19.0: ) $2 = token '+' (19.2: ) $3 = nterm expr (19.4: ) -> $$ = nterm expr (19.0-4: ) Entering state 8 Reading a token Next token is token ';' (19.5: ) Shifting token ';' (19.5: ) Entering state 16 Reducing stack 0 by rule 3 (line 84): $1 = nterm expr (19.0-4: ) $2 = token ';' (19.5: ) -> $$ = nterm stmt (19.0-5: ) Entering state 7 Reducing stack 0 by rule 2 (line 72): $1 = nterm prog (1.1-17.15: ) $2 = nterm stmt (19.0-5: ) -> $$ = nterm prog (1.1-19.5: ) Entering state 1 Reading a token Next token is token '@' (21.0: ) Shifting token '@' (21.0: ) Entering state 6 Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) 712. cxx-type.at:449: ok stderr: stderr: stdout: ./c++.at:851: $PREPARSER ./input stdout: stderr: ./c++.at:1555: $PREPARSER ./test ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stdout: ./cxx-type.at:458: $PREPARSER ./types test-input stderr: syntax error, unexpected ID, expecting '=' or '+' or ')' ======== Testing with C++ standard flags: '' ./cxx-type.at:458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:458: $PREPARSER ./types -p test-input stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error, unexpected ID, expecting '=' or '+' or ')' Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () ./cxx-type.at:458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 716. glr-regression.at:207: testing Badly Collapsed GLR States: glr2.cc ... Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token ';' () Shifting token ';' () Entering state 23 Reducing stack 0 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token ID () Shifting token ID () Entering state 11 Reducing stack 0 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Entering state 13 Reading a token Next token is token '=' () Shifting token '=' () Entering state 22 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 29 Reading a token Next token is token ';' () Shifting token ';' () Entering state 30 Reducing stack 0 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Entering state 9 Reducing stack 0 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 14 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 24 Reading a token Next token is token ';' () Reducing stack 0 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '+' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '+' () Stack 1 dies. Removing dead stacks. On stack 0, shifting token '+' () Stack 0 now in state 15 Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Returning to deterministic operation. Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token TYPENAME () Shifting token TYPENAME () Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token ';' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 23 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 23 Reduced stack 1 by rule 11 (line 87); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 11 (line 87): $1 = token TYPENAME () $2 = nterm declarator () $3 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ')' () Stack 0 Entering state 18 Next token is token ')' () Splitting off stack 1 from 0. Reduced stack 1 by rule 13 (line 94); action deferred. Now in state 21. Stack 1 Entering state 21 Next token is token ')' () Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 20. Stack 0 Entering state 20 Next token is token ')' () Stack 1 Entering state 21 Next token is token ')' () On stack 0, shifting token ')' () Stack 0 now in state 27 On stack 1, shifting token ')' () Stack 1 now in state 28 Stack 0 Entering state 27 Reduced stack 0 by rule 8 (line 81); action deferred. Now in state 8. Stack 0 Entering state 8 Reading a token Next token is token '=' () Stack 1 Entering state 28 Reduced stack 1 by rule 14 (line 95); action deferred. Now in state 13. Stack 1 Entering state 13 Next token is token '=' () On stack 0, shifting token '=' () Stack 0 now in state 14 On stack 1, shifting token '=' () Stack 1 now in state 22 Stack 0 Entering state 14 Reading a token Next token is token ID () Stack 1 Entering state 22 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token '+' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token '+' () On stack 0, shifting token '+' () Stack 0 now in state 15 On stack 1, shifting token '+' () Stack 1 now in state 15 Stack 0 Entering state 15 Reading a token Next token is token ID () Stack 1 Entering state 15 Next token is token ID () On stack 0, shifting token ID () Stack 0 now in state 5 On stack 1, shifting token ID () Stack 1 now in state 5 Stack 0 Entering state 5 Reduced stack 0 by rule 7 (line 80); action deferred. Now in state 25. Stack 0 Entering state 25 Reduced stack 0 by rule 9 (line 83); action deferred. Now in state 24. Stack 0 Entering state 24 Reading a token Next token is token ';' () Reduced stack 0 by rule 10 (line 84); action deferred. Now in state 8. Stack 0 Entering state 8 Next token is token ';' () Stack 1 Entering state 5 Reduced stack 1 by rule 7 (line 80); action deferred. Now in state 25. Stack 1 Entering state 25 Reduced stack 1 by rule 9 (line 83); action deferred. Now in state 29. Stack 1 Entering state 29 Next token is token ';' () On stack 0, shifting token ';' () Stack 0 now in state 16 On stack 1, shifting token ';' () Stack 1 now in state 30 Stack 0 Entering state 16 Reduced stack 0 by rule 3 (line 74); action deferred. Now in state 7. Stack 0 Entering state 7 Reduced stack 0 by rule 2 (line 65); action deferred. Now in state 1. Stack 0 Entering state 1 Reading a token Next token is token TYPENAME () Stack 1 Entering state 30 Reduced stack 1 by rule 12 (line 89); action deferred. Now in state 9. Stack 1 Entering state 9 Reduced stack 1 by rule 4 (line 75); action deferred. Now in state 7. Stack 1 Entering state 7 Reduced stack 1 by rule 2 (line 65); action deferred. Now in state 1. Merging stack 1 into stack 0. Removing dead stacks. On stack 0, shifting token TYPENAME () Stack 0 now in state 4 Reducing stack -1 by rule 13 (line 94): $1 = token ID () -> $$ = nterm declarator () Reducing stack -1 by rule 14 (line 95): $1 = token '(' () $2 = nterm declarator () $3 = token ')' () -> $$ = nterm declarator () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 12 (line 89): $1 = token TYPENAME () $2 = nterm declarator () $3 = token '=' () $4 = nterm expr () $5 = token ';' () -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () -> $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 8 (line 81): $1 = token TYPENAME () $2 = token '(' () $3 = nterm expr () $4 = token ')' () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Reducing stack -1 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 10 (line 84): $1 = nterm expr () $2 = token '=' () $3 = nterm expr () -> $$ = nterm expr () Reducing stack -1 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Returning to deterministic operation. Entering state 4 Reading a token Next token is token '(' () Shifting token '(' () Entering state 12 Reading a token Next token is token ID () Shifting token ID () Entering state 18 Reading a token Next token is token ID () Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 20 Next token is token ID () syntax error, unexpected ID, expecting '=' or '+' or ')' Error: popping nterm expr () Error: popping token '(' () Error: popping token TYPENAME () Shifting token error () Entering state 3 Next token is token ID () Error: discarding token ID () Reading a token Next token is token ')' () Error: discarding token ')' () Reading a token Next token is token '=' () Error: discarding token '=' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token '+' () Error: discarding token '+' () Reading a token Next token is token ID () Error: discarding token ID () Reading a token Next token is token ';' () Entering state 3 Next token is token ';' () Shifting token ';' () Entering state 10 Reducing stack 0 by rule 5 (line 76): $1 = token error () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 15 Reading a token Next token is token ID () Shifting token ID () Entering state 5 Reducing stack 0 by rule 7 (line 80): $1 = token ID () -> $$ = nterm expr () Entering state 25 Reducing stack 0 by rule 9 (line 83): $1 = nterm expr () $2 = token '+' () $3 = nterm expr () -> $$ = nterm expr () Entering state 8 Reading a token Next token is token ';' () Shifting token ';' () Entering state 16 Reducing stack 0 by rule 3 (line 74): $1 = nterm expr () $2 = token ';' () -> $$ = nterm stmt () Entering state 7 Reducing stack 0 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () -> $$ = nterm prog () Entering state 1 Reading a token Next token is token '@' () Shifting token '@' () Entering state 6 Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () ./glr-regression.at:207: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o glr-regr1.cc glr-regr1.y 691. c++.at:1517: ok 713. cxx-type.at:455: ok ./glr-regression.at:207: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr1 glr-regr1.cc $LIBS 717. glr-regression.at:354: testing Improper handling of embedded actions and dollar(-N) in GLR parsers: glr.c ... ./glr-regression.at:354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr2a.c glr-regr2a.y stderr: stdout: ./glr-regression.at:205: $PREPARSER ./glr-regr1 BPBPB stderr: 718. glr-regression.at:355: testing Improper handling of embedded actions and dollar(-N) in GLR parsers: glr.cc ... ./glr-regression.at:355: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr2a.cc glr-regr2a.y ./glr-regression.at:205: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:354: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr2a glr-regr2a.c $LIBS stderr: stdout: ./c++.at:1363: $PREPARSER ./input aaaas 714. glr-regression.at:205: ok stderr: exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:355: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr2a glr-regr2a.cc $LIBS ./c++.at:1363: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 719. glr-regression.at:356: testing Improper handling of embedded actions and dollar(-N) in GLR parsers: glr2.cc ... ./glr-regression.at:356: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr2a.cc glr-regr2a.y ./c++.at:1363: $PREPARSER ./input aaaap stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffffb324020->Object::Object { } 0xfffffb324120->Object::Object { 0xfffffb324020 } 0xfffffb324020->Object::~Object { 0xfffffb324020, 0xfffffb324120 } Next token is token 'a' (0xfffffb324120 'a') 0xfffffb324060->Object::Object { 0xfffffb324120 } 0xfffffb324120->Object::~Object { 0xfffffb324060, 0xfffffb324120 } Shifting token 'a' (0xfffffb324060 'a') 0xaaaacc9902e0->Object::Object { 0xfffffb324060 } 0xfffffb324060->Object::~Object { 0xaaaacc9902e0, 0xfffffb324060 } Entering state 1 Stack now 0 1 0xfffffb324140->Object::Object { 0xaaaacc9902e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacc9902e0 'a') -> $$ = nterm item (0xfffffb324140 'a') 0xaaaacc9902e0->Object::~Object { 0xaaaacc9902e0, 0xfffffb324140 } 0xaaaacc9902e0->Object::Object { 0xfffffb324140 } 0xfffffb324140->Object::~Object { 0xaaaacc9902e0, 0xfffffb324140 } Entering state 10 Stack now 0 10 Reading a token 0xfffffb324020->Object::Object { 0xaaaacc9902e0 } 0xfffffb324120->Object::Object { 0xaaaacc9902e0, 0xfffffb324020 } 0xfffffb324020->Object::~Object { 0xaaaacc9902e0, 0xfffffb324020, 0xfffffb324120 } Next token is token 'a' (0xfffffb324120 'a') 0xfffffb324060->Object::Object { 0xaaaacc9902e0, 0xfffffb324120 } 0xfffffb324120->Object::~Object { 0xaaaacc9902e0, 0xfffffb324060, 0xfffffb324120 } Shifting token 'a' (0xfffffb324060 'a') 0xaaaacc990300->Object::Object { 0xaaaacc9902e0, 0xfffffb324060 } 0xfffffb324060->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324060 } Entering state 1 Stack now 0 10 1 0xfffffb324140->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacc990300 'a') -> $$ = nterm item (0xfffffb324140 'a') 0xaaaacc990300->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324140 } 0xaaaacc990300->Object::Object { 0xaaaacc9902e0, 0xfffffb324140 } 0xfffffb324140->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324140 } Entering state 10 Stack now 0 10 10 Reading a token 0xfffffb324020->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300 } 0xfffffb324120->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324020 } 0xfffffb324020->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324020, 0xfffffb324120 } Next token is token 'a' (0xfffffb324120 'a') 0xfffffb324060->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324120 } 0xfffffb324120->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324060, 0xfffffb324120 } Shifting token 'a' (0xfffffb324060 'a') 0xaaaacc990320->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324060 } 0xfffffb324060->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324060 } Entering state 1 Stack now 0 10 10 1 0xfffffb324140->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacc990320 'a') -> $$ = nterm item (0xfffffb324140 'a') 0xaaaacc990320->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324140 } 0xaaaacc990320->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324140 } 0xfffffb324140->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324140 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xfffffb324020->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320 } 0xfffffb324120->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324020 } 0xfffffb324020->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324020, 0xfffffb324120 } Next token is token 'a' (0xfffffb324120 'a') 0xfffffb324060->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324120 } 0xfffffb324120->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324060, 0xfffffb324120 } Shifting token 'a' (0xfffffb324060 'a') 0xaaaacc990340->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324060 } 0xfffffb324060->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324060 } Entering state 1 Stack now 0 10 10 10 1 0xfffffb324140->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacc990340 'a') -> $$ = nterm item (0xfffffb324140 'a') 0xaaaacc990340->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324140 } 0xaaaacc990340->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324140 } 0xfffffb324140->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324140 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xfffffb324020->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340 } 0xfffffb324120->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324020 } 0xfffffb324020->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324020, 0xfffffb324120 } Next token is token 'p' (0xfffffb324120 'p'Exception caught: cleaning lookahead and stack 0xaaaacc990340->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324120 } 0xaaaacc990320->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324120 } 0xaaaacc990300->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324120 } 0xaaaacc9902e0->Object::~Object { 0xaaaacc9902e0, 0xfffffb324120 } 0xfffffb324120->Object::~Object { 0xfffffb324120 } exception caught: printer end { } ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:356: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr2a glr-regr2a.cc $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffffb324020->Object::Object { } 0xfffffb324120->Object::Object { 0xfffffb324020 } 0xfffffb324020->Object::~Object { 0xfffffb324020, 0xfffffb324120 } Next token is token 'a' (0xfffffb324120 'a') 0xfffffb324060->Object::Object { 0xfffffb324120 } 0xfffffb324120->Object::~Object { 0xfffffb324060, 0xfffffb324120 } Shifting token 'a' (0xfffffb324060 'a') 0xaaaacc9902e0->Object::Object { 0xfffffb324060 } 0xfffffb324060->Object::~Object { 0xaaaacc9902e0, 0xfffffb324060 } Entering state 1 Stack now 0 1 0xfffffb324140->Object::Object { 0xaaaacc9902e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacc9902e0 'a') -> $$ = nterm item (0xfffffb324140 'a') 0xaaaacc9902e0->Object::~Object { 0xaaaacc9902e0, 0xfffffb324140 } 0xaaaacc9902e0->Object::Object { 0xfffffb324140 } 0xfffffb324140->Object::~Object { 0xaaaacc9902e0, 0xfffffb324140 } Entering state 10 Stack now 0 10 Reading a token 0xfffffb324020->Object::Object { 0xaaaacc9902e0 } 0xfffffb324120->Object::Object { 0xaaaacc9902e0, 0xfffffb324020 } 0xfffffb324020->Object::~Object { 0xaaaacc9902e0, 0xfffffb324020, 0xfffffb324120 } Next token is token 'a' (0xfffffb324120 'a') 0xfffffb324060->Object::Object { 0xaaaacc9902e0, 0xfffffb324120 } 0xfffffb324120->Object::~Object { 0xaaaacc9902e0, 0xfffffb324060, 0xfffffb324120 } Shifting token 'a' (0xfffffb324060 'a') 0xaaaacc990300->Object::Object { 0xaaaacc9902e0, 0xfffffb324060 } 0xfffffb324060->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324060 } Entering state 1 Stack now 0 10 1 0xfffffb324140->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacc990300 'a') -> $$ = nterm item (0xfffffb324140 'a') 0xaaaacc990300->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324140 } 0xaaaacc990300->Object::Object { 0xaaaacc9902e0, 0xfffffb324140 } 0xfffffb324140->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324140 } Entering state 10 Stack now 0 10 10 Reading a token 0xfffffb324020->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300 } 0xfffffb324120->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324020 } 0xfffffb324020->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324020, 0xfffffb324120 } Next token is token 'a' (0xfffffb324120 'a') 0xfffffb324060->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324120 } 0xfffffb324120->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324060, 0xfffffb324120 } Shifting token 'a' (0xfffffb324060 'a') 0xaaaacc990320->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324060 } 0xfffffb324060->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324060 } Entering state 1 Stack now 0 10 10 1 0xfffffb324140->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacc990320 'a') -> $$ = nterm item (0xfffffb324140 'a') 0xaaaacc990320->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324140 } 0xaaaacc990320->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324140 } 0xfffffb324140->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324140 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xfffffb324020->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320 } 0xfffffb324120->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324020 } 0xfffffb324020->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324020, 0xfffffb324120 } Next token is token 'a' (0xfffffb324120 'a') 0xfffffb324060->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324120 } 0xfffffb324120->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324060, 0xfffffb324120 } Shifting token 'a' (0xfffffb324060 'a') 0xaaaacc990340->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324060 } 0xfffffb324060->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324060 } Entering state 1 Stack now 0 10 10 10 1 0xfffffb324140->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaacc990340 'a') -> $$ = nterm item (0xfffffb324140 'a') 0xaaaacc990340->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324140 } 0xaaaacc990340->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324140 } 0xfffffb324140->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324140 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xfffffb324020->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340 } 0xfffffb324120->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324020 } 0xfffffb324020->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324020, 0xfffffb324120 } Next token is token 'p' (0xfffffb324120 'p'Exception caught: cleaning lookahead and stack 0xaaaacc990340->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324120 } 0xaaaacc990320->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324120 } 0xaaaacc990300->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324120 } 0xaaaacc9902e0->Object::~Object { 0xaaaacc9902e0, 0xfffffb324120 } 0xfffffb324120->Object::~Object { 0xfffffb324120 } exception caught: printer end { } ./c++.at:1363: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1363: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaE stderr: stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./c++.at:1361: $PREPARSER ./input aaaas stderr: ./c++.at:1363: $PREPARSER ./input aaaaT exception caught: reduction ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaR ./c++.at:1361: $PREPARSER ./input aaaal stderr: stderr: exception caught: yylex ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1361: $PREPARSER ./input i ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaap stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae433cf40->Object::Object { } Next token is token 'a' (0xaaaae433cf40 'a') Shifting token 'a' (0xaaaae433cf40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae433cf40 'a') -> $$ = nterm item (0xaaaae433cf40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaae433cf90->Object::Object { 0xaaaae433cf40 } Next token is token 'a' (0xaaaae433cf90 'a') Shifting token 'a' (0xaaaae433cf90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae433cf90 'a') -> $$ = nterm item (0xaaaae433cf90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaae433cfe0->Object::Object { 0xaaaae433cf40, 0xaaaae433cf90 } Next token is token 'a' (0xaaaae433cfe0 'a') Shifting token 'a' (0xaaaae433cfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae433cfe0 'a') -> $$ = nterm item (0xaaaae433cfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaae433d030->Object::Object { 0xaaaae433cf40, 0xaaaae433cf90, 0xaaaae433cfe0 } Next token is token 'a' (0xaaaae433d030 'a') Shifting token 'a' (0xaaaae433d030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae433d030 'a') -> $$ = nterm item (0xaaaae433d030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaae433d080->Object::Object { 0xaaaae433cf40, 0xaaaae433cf90, 0xaaaae433cfe0, 0xaaaae433d030 } Next token is token 'p' (0xaaaae433d080 'p'Exception caught: cleaning lookahead and stack 0xaaaae433d080->Object::~Object { 0xaaaae433cf40, 0xaaaae433cf90, 0xaaaae433cfe0, 0xaaaae433d030, 0xaaaae433d080 } 0xaaaae433d030->Object::~Object { 0xaaaae433cf40, 0xaaaae433cf90, 0xaaaae433cfe0, 0xaaaae433d030 } 0xaaaae433cfe0->Object::~Object { 0xaaaae433cf40, 0xaaaae433cf90, 0xaaaae433cfe0 } 0xaaaae433cf90->Object::~Object { 0xaaaae433cf40, 0xaaaae433cf90 } 0xaaaae433cf40->Object::~Object { 0xaaaae433cf40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaae433cf40->Object::Object { } Next token is token 'a' (0xaaaae433cf40 'a') Shifting token 'a' (0xaaaae433cf40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae433cf40 'a') -> $$ = nterm item (0xaaaae433cf40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaae433cf90->Object::Object { 0xaaaae433cf40 } Next token is token 'a' (0xaaaae433cf90 'a') Shifting token 'a' (0xaaaae433cf90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae433cf90 'a') -> $$ = nterm item (0xaaaae433cf90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaae433cfe0->Object::Object { 0xaaaae433cf40, 0xaaaae433cf90 } Next token is token 'a' (0xaaaae433cfe0 'a') Shifting token 'a' (0xaaaae433cfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae433cfe0 'a') -> $$ = nterm item (0xaaaae433cfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaae433d030->Object::Object { 0xaaaae433cf40, 0xaaaae433cf90, 0xaaaae433cfe0 } Next token is token 'a' (0xaaaae433d030 'a') Shifting token 'a' (0xaaaae433d030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaae433d030 'a') -> $$ = nterm item (0xaaaae433d030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaae433d080->Object::Object { 0xaaaae433cf40, 0xaaaae433cf90, 0xaaaae433cfe0, 0xaaaae433d030 } Next token is token 'p' (0xaaaae433d080 'p'Exception caught: cleaning lookahead and stack 0xaaaae433d080->Object::~Object { 0xaaaae433cf40, 0xaaaae433cf90, 0xaaaae433cfe0, 0xaaaae433d030, 0xaaaae433d080 } 0xaaaae433d030->Object::~Object { 0xaaaae433cf40, 0xaaaae433cf90, 0xaaaae433cfe0, 0xaaaae433d030 } 0xaaaae433cfe0->Object::~Object { 0xaaaae433cf40, 0xaaaae433cf90, 0xaaaae433cfe0 } 0xaaaae433cf90->Object::~Object { 0xaaaae433cf40, 0xaaaae433cf90 } 0xaaaae433cf40->Object::~Object { 0xaaaae433cf40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr stdout: stdout: exception caught: printer ./c++.at:1361: $PREPARSER ./input aaaae ./c++.at:857: $PREPARSER ./input stderr: ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: exception caught: syntax error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaT stderr: stdout: ./glr-regression.at:206: $PREPARSER ./glr-regr1 BPBPB stderr: stderr: ./glr-regression.at:206: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 715. glr-regression.at:206: ok ./c++.at:1361: $PREPARSER ./input aaaaR stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' stdout: ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./glr-regression.at:354: $PREPARSER ./glr-regr2a input1.txt stderr: ./glr-regression.at:354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./glr-regression.at:354: $PREPARSER ./glr-regr2a input2.txt stdout: stderr: ./c++.at:851: $PREPARSER ./input stderr: 720. glr-regression.at:488: testing Improper merging of GLR delayed action sets: glr.c ... ./glr-regression.at:488: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr3.c glr-regr3.y ./glr-regression.at:354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./glr-regression.at:354: $PREPARSER ./glr-regr2a input3.txt stderr: ./glr-regression.at:354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 717. glr-regression.at:354: ok ./glr-regression.at:488: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr3 glr-regr3.c $LIBS 721. glr-regression.at:489: testing Improper merging of GLR delayed action sets: glr.cc ... ./glr-regression.at:489: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr3.cc glr-regr3.y ./glr-regression.at:489: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr3 glr-regr3.cc $LIBS stderr: stdout: ./c++.at:1360: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaap stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaadcedef40->Object::Object { } Next token is token 'a' (0xaaaadcedef40 'a') Shifting token 'a' (0xaaaadcedef40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadcedef40 'a') -> $$ = nterm item (0xaaaadcedef40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaadcedef90->Object::Object { 0xaaaadcedef40 } Next token is token 'a' (0xaaaadcedef90 'a') Shifting token 'a' (0xaaaadcedef90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadcedef90 'a') -> $$ = nterm item (0xaaaadcedef90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaadcedefe0->Object::Object { 0xaaaadcedef40, 0xaaaadcedef90 } Next token is token 'a' (0xaaaadcedefe0 'a') Shifting token 'a' (0xaaaadcedefe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadcedefe0 'a') -> $$ = nterm item (0xaaaadcedefe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaadcedf030->Object::Object { 0xaaaadcedef40, 0xaaaadcedef90, 0xaaaadcedefe0 } Next token is token 'a' (0xaaaadcedf030 'a') Shifting token 'a' (0xaaaadcedf030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadcedf030 'a') -> $$ = nterm item (0xaaaadcedf030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaadcedf080->Object::Object { 0xaaaadcedef40, 0xaaaadcedef90, 0xaaaadcedefe0, 0xaaaadcedf030 } Next token is token 'p' (0xaaaadcedf080 'p'Exception caught: cleaning lookahead and stack 0xaaaadcedf080->Object::~Object { 0xaaaadcedef40, 0xaaaadcedef90, 0xaaaadcedefe0, 0xaaaadcedf030, 0xaaaadcedf080 } 0xaaaadcedf030->Object::~Object { 0xaaaadcedef40, 0xaaaadcedef90, 0xaaaadcedefe0, 0xaaaadcedf030 } 0xaaaadcedefe0->Object::~Object { 0xaaaadcedef40, 0xaaaadcedef90, 0xaaaadcedefe0 } 0xaaaadcedef90->Object::~Object { 0xaaaadcedef40, 0xaaaadcedef90 } 0xaaaadcedef40->Object::~Object { 0xaaaadcedef40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaadcedef40->Object::Object { } Next token is token 'a' (0xaaaadcedef40 'a') Shifting token 'a' (0xaaaadcedef40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadcedef40 'a') -> $$ = nterm item (0xaaaadcedef40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaadcedef90->Object::Object { 0xaaaadcedef40 } Next token is token 'a' (0xaaaadcedef90 'a') Shifting token 'a' (0xaaaadcedef90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadcedef90 'a') -> $$ = nterm item (0xaaaadcedef90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaadcedefe0->Object::Object { 0xaaaadcedef40, 0xaaaadcedef90 } Next token is token 'a' (0xaaaadcedefe0 'a') Shifting token 'a' (0xaaaadcedefe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadcedefe0 'a') -> $$ = nterm item (0xaaaadcedefe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaadcedf030->Object::Object { 0xaaaadcedef40, 0xaaaadcedef90, 0xaaaadcedefe0 } Next token is token 'a' (0xaaaadcedf030 'a') Shifting token 'a' (0xaaaadcedf030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadcedf030 'a') -> $$ = nterm item (0xaaaadcedf030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaadcedf080->Object::Object { 0xaaaadcedef40, 0xaaaadcedef90, 0xaaaadcedefe0, 0xaaaadcedf030 } Next token is token 'p' (0xaaaadcedf080 'p'Exception caught: cleaning lookahead and stack 0xaaaadcedf080->Object::~Object { 0xaaaadcedef40, 0xaaaadcedef90, 0xaaaadcedefe0, 0xaaaadcedf030, 0xaaaadcedf080 } 0xaaaadcedf030->Object::~Object { 0xaaaadcedef40, 0xaaaadcedef90, 0xaaaadcedefe0, 0xaaaadcedf030 } 0xaaaadcedefe0->Object::~Object { 0xaaaadcedef40, 0xaaaadcedef90, 0xaaaadcedefe0 } 0xaaaadcedef90->Object::~Object { 0xaaaadcedef40, 0xaaaadcedef90 } 0xaaaadcedef40->Object::~Object { 0xaaaadcedef40 } exception caught: printer end { } ./c++.at:1360: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1362: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaT stderr: ./c++.at:1362: $PREPARSER ./input aaaal ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input i ./c++.at:1360: $PREPARSER ./input aaaaR stderr: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stdout: stdout: ./c++.at:1362: $PREPARSER ./input aaaap stderr: ./c++.at:857: $PREPARSER ./input ./glr-regression.at:355: $PREPARSER ./glr-regr2a input1.txt stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1362: $PREPARSER ./input --debug aaaap ./glr-regression.at:355: $PREPARSER ./glr-regr2a input2.txt stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffce89cd90->Object::Object { } 0xffffce89ce90->Object::Object { 0xffffce89cd90 } 0xffffce89cd90->Object::~Object { 0xffffce89cd90, 0xffffce89ce90 } Next token is token 'a' (0xffffce89ce90 'a') 0xffffce89cdd0->Object::Object { 0xffffce89ce90 } 0xffffce89ce90->Object::~Object { 0xffffce89cdd0, 0xffffce89ce90 } Shifting token 'a' (0xffffce89cdd0 'a') 0xaaaac93772e0->Object::Object { 0xffffce89cdd0 } 0xffffce89cdd0->Object::~Object { 0xaaaac93772e0, 0xffffce89cdd0 } Entering state 2 Stack now 0 2 0xffffce89ceb0->Object::Object { 0xaaaac93772e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac93772e0 'a') -> $$ = nterm item (0xffffce89ceb0 'a') 0xaaaac93772e0->Object::~Object { 0xaaaac93772e0, 0xffffce89ceb0 } 0xaaaac93772e0->Object::Object { 0xffffce89ceb0 } 0xffffce89ceb0->Object::~Object { 0xaaaac93772e0, 0xffffce89ceb0 } Entering state 11 Stack now 0 11 Reading a token 0xffffce89cd90->Object::Object { 0xaaaac93772e0 } 0xffffce89ce90->Object::Object { 0xaaaac93772e0, 0xffffce89cd90 } 0xffffce89cd90->Object::~Object { 0xaaaac93772e0, 0xffffce89cd90, 0xffffce89ce90 } Next token is token 'a' (0xffffce89ce90 'a') 0xffffce89cdd0->Object::Object { 0xaaaac93772e0, 0xffffce89ce90 } 0xffffce89ce90->Object::~Object { 0xaaaac93772e0, 0xffffce89cdd0, 0xffffce89ce90 } Shifting token 'a' (0xffffce89cdd0 'a') 0xaaaac9377300->Object::Object { 0xaaaac93772e0, 0xffffce89cdd0 } 0xffffce89cdd0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89cdd0 } Entering state 2 Stack now 0 11 2 0xffffce89ceb0->Object::Object { 0xaaaac93772e0, 0xaaaac9377300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac9377300 'a') -> $$ = nterm item (0xffffce89ceb0 'a') 0xaaaac9377300->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89ceb0 } 0xaaaac9377300->Object::Object { 0xaaaac93772e0, 0xffffce89ceb0 } 0xffffce89ceb0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89ceb0 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffce89cd90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300 } 0xffffce89ce90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89cd90 } 0xffffce89cd90->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89cd90, 0xffffce89ce90 } Next token is token 'a' (0xffffce89ce90 'a') 0xffffce89cdd0->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89ce90 } 0xffffce89ce90->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89cdd0, 0xffffce89ce90 } Shifting token 'a' (0xffffce89cdd0 'a') 0xaaaac9377320->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89cdd0 } 0xffffce89cdd0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89cdd0 } Entering state 2 Stack now 0 11 11 2 0xffffce89ceb0->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac9377320 'a') -> $$ = nterm item (0xffffce89ceb0 'a') 0xaaaac9377320->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89ceb0 } 0xaaaac9377320->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89ceb0 } 0xffffce89ceb0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89ceb0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffce89cd90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320 } 0xffffce89ce90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89cd90 } 0xffffce89cd90->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89cd90, 0xffffce89ce90 } Next token is token 'a' (0xffffce89ce90 'a') 0xffffce89cdd0->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89ce90 } 0xffffce89ce90->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89cdd0, 0xffffce89ce90 } Shifting token 'a' (0xffffce89cdd0 'a') 0xaaaac9377340->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89cdd0 } 0xffffce89cdd0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89cdd0 } Entering state 2 Stack now 0 11 11 11 2 0xffffce89ceb0->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac9377340 'a') -> $$ = nterm item (0xffffce89ceb0 'a') 0xaaaac9377340->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89ceb0 } 0xaaaac9377340->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89ceb0 } 0xffffce89ceb0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89ceb0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffce89cd90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340 } 0xffffce89ce90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89cd90 } 0xffffce89cd90->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89cd90, 0xffffce89ce90 } Next token is token 'p' (0xffffce89ce90 'p'Exception caught: cleaning lookahead and stack 0xaaaac9377340->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89ce90 } 0xaaaac9377320->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89ce90 } 0xaaaac9377300->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89ce90 } 0xaaaac93772e0->Object::~Object { 0xaaaac93772e0, 0xffffce89ce90 } 0xffffce89ce90->Object::~Object { 0xffffce89ce90 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffce89cd90->Object::Object { } 0xffffce89ce90->Object::Object { 0xffffce89cd90 } 0xffffce89cd90->Object::~Object { 0xffffce89cd90, 0xffffce89ce90 } Next token is token 'a' (0xffffce89ce90 'a') 0xffffce89cdd0->Object::Object { 0xffffce89ce90 } 0xffffce89ce90->Object::~Object { 0xffffce89cdd0, 0xffffce89ce90 } Shifting token 'a' (0xffffce89cdd0 'a') 0xaaaac93772e0->Object::Object { 0xffffce89cdd0 } 0xffffce89cdd0->Object::~Object { 0xaaaac93772e0, 0xffffce89cdd0 } Entering state 2 Stack now 0 2 0xffffce89ceb0->Object::Object { 0xaaaac93772e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac93772e0 'a') -> $$ = nterm item (0xffffce89ceb0 'a') 0xaaaac93772e0->Object::~Object { 0xaaaac93772e0, 0xffffce89ceb0 } 0xaaaac93772e0->Object::Object { 0xffffce89ceb0 } 0xffffce89ceb0->Object::~Object { 0xaaaac93772e0, 0xffffce89ceb0 } Entering state 11 Stack now 0 11 Reading a token 0xffffce89cd90->Object::Object { 0xaaaac93772e0 } 0xffffce89ce90->Object::Object { 0xaaaac93772e0, 0xffffce89cd90 } 0xffffce89cd90->Object::~Object { 0xaaaac93772e0, 0xffffce89cd90, 0xffffce89ce90 } Next token is token 'a' (0xffffce89ce90 'a') 0xffffce89cdd0->Object::Object { 0xaaaac93772e0, 0xffffce89ce90 } 0xffffce89ce90->Object::~Object { 0xaaaac93772e0, 0xffffce89cdd0, 0xffffce89ce90 } Shifting token 'a' (0xffffce89cdd0 'a') 0xaaaac9377300->Object::Object { 0xaaaac93772e0, 0xffffce89cdd0 } 0xffffce89cdd0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89cdd0 } Entering state 2 Stack now 0 11 2 0xffffce89ceb0->Object::Object { 0xaaaac93772e0, 0xaaaac9377300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac9377300 'a') -> $$ = nterm item (0xffffce89ceb0 'a') 0xaaaac9377300->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89ceb0 } 0xaaaac9377300->Object::Object { 0xaaaac93772e0, 0xffffce89ceb0 } 0xffffce89ceb0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89ceb0 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffce89cd90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300 } 0xffffce89ce90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89cd90 } 0xffffce89cd90->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89cd90, 0xffffce89ce90 } Next token is token 'a' (0xffffce89ce90 'a') 0xffffce89cdd0->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89ce90 } 0xffffce89ce90->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89cdd0, 0xffffce89ce90 } Shifting token 'a' (0xffffce89cdd0 'a') 0xaaaac9377320->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89cdd0 } 0xffffce89cdd0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89cdd0 } Entering state 2 Stack now 0 11 11 2 0xffffce89ceb0->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac9377320 'a') -> $$ = nterm item (0xffffce89ceb0 'a') 0xaaaac9377320->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89ceb0 } 0xaaaac9377320->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89ceb0 } 0xffffce89ceb0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89ceb0 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffce89cd90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320 } 0xffffce89ce90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89cd90 } 0xffffce89cd90->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89cd90, 0xffffce89ce90 } Next token is token 'a' (0xffffce89ce90 'a') 0xffffce89cdd0->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89ce90 } 0xffffce89ce90->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89cdd0, 0xffffce89ce90 } Shifting token 'a' (0xffffce89cdd0 'a') 0xaaaac9377340->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89cdd0 } 0xffffce89cdd0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89cdd0 } Entering state 2 Stack now 0 11 11 11 2 0xffffce89ceb0->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaac9377340 'a') -> $$ = nterm item (0xffffce89ceb0 'a') 0xaaaac9377340->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89ceb0 } 0xaaaac9377340->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89ceb0 } 0xffffce89ceb0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89ceb0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffce89cd90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340 } 0xffffce89ce90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89cd90 } 0xffffce89cd90->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89cd90, 0xffffce89ce90 } Next token is token 'p' (0xffffce89ce90 'p'Exception caught: cleaning lookahead and stack 0xaaaac9377340->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89ce90 } 0xaaaac9377320->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89ce90 } 0xaaaac9377300->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89ce90 } 0xaaaac93772e0->Object::~Object { 0xaaaac93772e0, 0xffffce89ce90 } 0xffffce89ce90->Object::~Object { 0xffffce89ce90 } exception caught: printer end { } ./c++.at:1362: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae ./glr-regression.at:355: $PREPARSER ./glr-regr2a input3.txt stderr: stderr: exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 718. glr-regression.at:355: ok ./c++.at:1362: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1362: $PREPARSER ./input aaaaT stderr: 722. glr-regression.at:490: testing Improper merging of GLR delayed action sets: glr2.cc ... ./glr-regression.at:488: $PREPARSER ./glr-regr3 input.txt ./glr-regression.at:490: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr3.cc glr-regr3.y ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./glr-regression.at:488: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaR stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 720. glr-regression.at:488: ok ======== Testing with C++ standard flags: '' ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./glr-regression.at:490: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr3 glr-regr3.cc $LIBS 723. glr-regression.at:592: testing Duplicate representation of merged trees: %union { char *ptr; } glr.c ... ./glr-regression.at:592: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.c glr-regr4.y ./glr-regression.at:592: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr4 glr-regr4.c $LIBS stderr: stdout: ./glr-regression.at:207: $PREPARSER ./glr-regr1 BPBPB stderr: ./glr-regression.at:207: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 716. glr-regression.at:207: ok 724. glr-regression.at:593: testing Duplicate representation of merged trees: %union { char *ptr; } glr.cc ... ./glr-regression.at:593: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.cc glr-regr4.y stderr: stdout: ./glr-regression.at:489: $PREPARSER ./glr-regr3 input.txt stderr: ./glr-regression.at:489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 721. glr-regression.at:489: ok ./glr-regression.at:593: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr4 glr-regr4.cc $LIBS 725. glr-regression.at:594: testing Duplicate representation of merged trees: %union { char *ptr; } glr2.cc ... ./glr-regression.at:594: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.cc glr-regr4.y ./glr-regression.at:594: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr4 glr-regr4.cc $LIBS stderr: stdout: ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid expression ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1066: $PREPARSER ./input < in stdout: stderr: error: invalid character ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:851: $PREPARSER ./input ======== Testing with C++ standard flags: '' stderr: ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./glr-regression.at:592: $PREPARSER ./glr-regr4 stderr: ./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:592: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 678. c++.at:848: ok 723. glr-regression.at:592: ok stderr: stdout: ./c++.at:1363: $PREPARSER ./input aaaas stderr: stderr: stdout: exception caught: reduction ./c++.at:1066: ./check ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 727. glr-regression.at:597: testing Duplicate representation of merged trees: api.value.type=union glr.cc ... ./glr-regression.at:597: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.cc glr-regr4.y ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS 726. glr-regression.at:596: testing Duplicate representation of merged trees: api.value.type=union glr.c ... ./glr-regression.at:596: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.c glr-regr4.y ./c++.at:1363: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input i stderr: ./glr-regression.at:596: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr4 glr-regr4.c $LIBS ./glr-regression.at:597: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr4 glr-regr4.cc $LIBS exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaap stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffffd95e500->Object::Object { } 0xfffffd95e600->Object::Object { 0xfffffd95e500 } 0xfffffd95e500->Object::~Object { 0xfffffd95e500, 0xfffffd95e600 } Next token is token 'a' (0xfffffd95e600 'a') 0xfffffd95e540->Object::Object { 0xfffffd95e600 } 0xfffffd95e600->Object::~Object { 0xfffffd95e540, 0xfffffd95e600 } Shifting token 'a' (0xfffffd95e540 'a') 0xaaab1306e2e0->Object::Object { 0xfffffd95e540 } 0xfffffd95e540->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e540 } Entering state 1 Stack now 0 1 0xfffffd95e620->Object::Object { 0xaaab1306e2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab1306e2e0 'a') -> $$ = nterm item (0xfffffd95e620 'a') 0xaaab1306e2e0->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e620 } 0xaaab1306e2e0->Object::Object { 0xfffffd95e620 } 0xfffffd95e620->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e620 } Entering state 10 Stack now 0 10 Reading a token 0xfffffd95e500->Object::Object { 0xaaab1306e2e0 } 0xfffffd95e600->Object::Object { 0xaaab1306e2e0, 0xfffffd95e500 } 0xfffffd95e500->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e500, 0xfffffd95e600 } Next token is token 'a' (0xfffffd95e600 'a') 0xfffffd95e540->Object::Object { 0xaaab1306e2e0, 0xfffffd95e600 } 0xfffffd95e600->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e540, 0xfffffd95e600 } Shifting token 'a' (0xfffffd95e540 'a') 0xaaab1306e300->Object::Object { 0xaaab1306e2e0, 0xfffffd95e540 } 0xfffffd95e540->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e540 } Entering state 1 Stack now 0 10 1 0xfffffd95e620->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab1306e300 'a') -> $$ = nterm item (0xfffffd95e620 'a') 0xaaab1306e300->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e620 } 0xaaab1306e300->Object::Object { 0xaaab1306e2e0, 0xfffffd95e620 } 0xfffffd95e620->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e620 } Entering state 10 Stack now 0 10 10 Reading a token 0xfffffd95e500->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300 } 0xfffffd95e600->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e500 } 0xfffffd95e500->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e500, 0xfffffd95e600 } Next token is token 'a' (0xfffffd95e600 'a') 0xfffffd95e540->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e600 } 0xfffffd95e600->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e540, 0xfffffd95e600 } Shifting token 'a' (0xfffffd95e540 'a') 0xaaab1306e320->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e540 } 0xfffffd95e540->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e540 } Entering state 1 Stack now 0 10 10 1 0xfffffd95e620->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab1306e320 'a') -> $$ = nterm item (0xfffffd95e620 'a') 0xaaab1306e320->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e620 } 0xaaab1306e320->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e620 } 0xfffffd95e620->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e620 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xfffffd95e500->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320 } 0xfffffd95e600->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e500 } 0xfffffd95e500->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e500, 0xfffffd95e600 } Next token is token 'a' (0xfffffd95e600 'a') 0xfffffd95e540->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e600 } 0xfffffd95e600->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e540, 0xfffffd95e600 } Shifting token 'a' (0xfffffd95e540 'a') 0xaaab1306e340->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e540 } 0xfffffd95e540->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e540 } Entering state 1 Stack now 0 10 10 10 1 0xfffffd95e620->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab1306e340 'a') -> $$ = nterm item (0xfffffd95e620 'a') 0xaaab1306e340->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e620 } 0xaaab1306e340->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e620 } 0xfffffd95e620->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e620 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xfffffd95e500->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340 } 0xfffffd95e600->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e500 } 0xfffffd95e500->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e500, 0xfffffd95e600 } Next token is token 'p' (0xfffffd95e600 'p'Exception caught: cleaning lookahead and stack 0xaaab1306e340->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e600 } 0xaaab1306e320->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e600 } 0xaaab1306e300->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e600 } 0xaaab1306e2e0->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e600 } 0xfffffd95e600->Object::~Object { 0xfffffd95e600 } exception caught: printer end { } ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffffd95e500->Object::Object { } 0xfffffd95e600->Object::Object { 0xfffffd95e500 } 0xfffffd95e500->Object::~Object { 0xfffffd95e500, 0xfffffd95e600 } Next token is token 'a' (0xfffffd95e600 'a') 0xfffffd95e540->Object::Object { 0xfffffd95e600 } 0xfffffd95e600->Object::~Object { 0xfffffd95e540, 0xfffffd95e600 } Shifting token 'a' (0xfffffd95e540 'a') 0xaaab1306e2e0->Object::Object { 0xfffffd95e540 } 0xfffffd95e540->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e540 } Entering state 1 Stack now 0 1 0xfffffd95e620->Object::Object { 0xaaab1306e2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab1306e2e0 'a') -> $$ = nterm item (0xfffffd95e620 'a') 0xaaab1306e2e0->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e620 } 0xaaab1306e2e0->Object::Object { 0xfffffd95e620 } 0xfffffd95e620->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e620 } Entering state 10 Stack now 0 10 Reading a token 0xfffffd95e500->Object::Object { 0xaaab1306e2e0 } 0xfffffd95e600->Object::Object { 0xaaab1306e2e0, 0xfffffd95e500 } 0xfffffd95e500->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e500, 0xfffffd95e600 } Next token is token 'a' (0xfffffd95e600 'a') 0xfffffd95e540->Object::Object { 0xaaab1306e2e0, 0xfffffd95e600 } 0xfffffd95e600->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e540, 0xfffffd95e600 } Shifting token 'a' (0xfffffd95e540 'a') 0xaaab1306e300->Object::Object { 0xaaab1306e2e0, 0xfffffd95e540 } 0xfffffd95e540->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e540 } Entering state 1 Stack now 0 10 1 0xfffffd95e620->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab1306e300 'a') -> $$ = nterm item (0xfffffd95e620 'a') 0xaaab1306e300->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e620 } 0xaaab1306e300->Object::Object { 0xaaab1306e2e0, 0xfffffd95e620 } 0xfffffd95e620->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e620 } Entering state 10 Stack now 0 10 10 Reading a token 0xfffffd95e500->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300 } 0xfffffd95e600->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e500 } 0xfffffd95e500->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e500, 0xfffffd95e600 } Next token is token 'a' (0xfffffd95e600 'a') 0xfffffd95e540->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e600 } 0xfffffd95e600->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e540, 0xfffffd95e600 } Shifting token 'a' (0xfffffd95e540 'a') 0xaaab1306e320->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e540 } 0xfffffd95e540->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e540 } Entering state 1 Stack now 0 10 10 1 0xfffffd95e620->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab1306e320 'a') -> $$ = nterm item (0xfffffd95e620 'a') 0xaaab1306e320->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e620 } 0xaaab1306e320->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e620 } 0xfffffd95e620->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e620 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xfffffd95e500->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320 } 0xfffffd95e600->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e500 } 0xfffffd95e500->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e500, 0xfffffd95e600 } Next token is token 'a' (0xfffffd95e600 'a') 0xfffffd95e540->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e600 } 0xfffffd95e600->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e540, 0xfffffd95e600 } Shifting token 'a' (0xfffffd95e540 'a') 0xaaab1306e340->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e540 } 0xfffffd95e540->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e540 } Entering state 1 Stack now 0 10 10 10 1 0xfffffd95e620->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaab1306e340 'a') -> $$ = nterm item (0xfffffd95e620 'a') 0xaaab1306e340->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e620 } 0xaaab1306e340->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e620 } 0xfffffd95e620->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e620 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xfffffd95e500->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340 } 0xfffffd95e600->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e500 } 0xfffffd95e500->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e500, 0xfffffd95e600 } Next token is token 'p' (0xfffffd95e600 'p'Exception caught: cleaning lookahead and stack 0xaaab1306e340->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e600 } 0xaaab1306e320->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e600 } 0xaaab1306e300->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e600 } 0xaaab1306e2e0->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e600 } 0xfffffd95e600->Object::~Object { 0xfffffd95e600 } exception caught: printer end { } ./c++.at:1363: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1363: $PREPARSER ./input aaaae stderr: stderr: exception caught: syntax error stdout: ./c++.at:1361: $PREPARSER ./input aaaas ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: reduction ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaE ./c++.at:1361: $PREPARSER ./input aaaal stderr: exception caught: syntax error, unexpected end of file, expecting 'a' stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaT exception caught: yylex stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaR stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:1361: $PREPARSER ./input aaaap stdout: stderr: ./glr-regression.at:356: $PREPARSER ./glr-regr2a input1.txt ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./glr-regression.at:356: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaadb8cdf40->Object::Object { } Next token is token 'a' (0xaaaadb8cdf40 'a') Shifting token 'a' (0xaaaadb8cdf40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadb8cdf40 'a') -> $$ = nterm item (0xaaaadb8cdf40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaadb8cdf90->Object::Object { 0xaaaadb8cdf40 } Next token is token 'a' (0xaaaadb8cdf90 'a') Shifting token 'a' (0xaaaadb8cdf90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadb8cdf90 'a') -> $$ = nterm item (0xaaaadb8cdf90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaadb8cdfe0->Object::Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90 } Next token is token 'a' (0xaaaadb8cdfe0 'a') Shifting token 'a' (0xaaaadb8cdfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadb8cdfe0 'a') -> $$ = nterm item (0xaaaadb8cdfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaadb8ce030->Object::Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90, 0xaaaadb8cdfe0 } Next token is token 'a' (0xaaaadb8ce030 'a') Shifting token 'a' (0xaaaadb8ce030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadb8ce030 'a') -> $$ = nterm item (0xaaaadb8ce030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaadb8ce080->Object::Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90, 0xaaaadb8cdfe0, 0xaaaadb8ce030 } Next token is token 'p' (0xaaaadb8ce080 'p'Exception caught: cleaning lookahead and stack 0xaaaadb8ce080->Object::~Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90, 0xaaaadb8cdfe0, 0xaaaadb8ce030, 0xaaaadb8ce080 } 0xaaaadb8ce030->Object::~Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90, 0xaaaadb8cdfe0, 0xaaaadb8ce030 } 0xaaaadb8cdfe0->Object::~Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90, 0xaaaadb8cdfe0 } 0xaaaadb8cdf90->Object::~Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90 } 0xaaaadb8cdf40->Object::~Object { 0xaaaadb8cdf40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaadb8cdf40->Object::Object { } Next token is token 'a' (0xaaaadb8cdf40 'a') Shifting token 'a' (0xaaaadb8cdf40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadb8cdf40 'a') -> $$ = nterm item (0xaaaadb8cdf40 'a') Entering state 10 Stack now 0 10 Reading a token 0xaaaadb8cdf90->Object::Object { 0xaaaadb8cdf40 } Next token is token 'a' (0xaaaadb8cdf90 'a') Shifting token 'a' (0xaaaadb8cdf90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadb8cdf90 'a') -> $$ = nterm item (0xaaaadb8cdf90 'a') Entering state 10 Stack now 0 10 10 Reading a token 0xaaaadb8cdfe0->Object::Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90 } Next token is token 'a' (0xaaaadb8cdfe0 'a') Shifting token 'a' (0xaaaadb8cdfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadb8cdfe0 'a') -> $$ = nterm item (0xaaaadb8cdfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token 0xaaaadb8ce030->Object::Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90, 0xaaaadb8cdfe0 } Next token is token 'a' (0xaaaadb8ce030 'a') Shifting token 'a' (0xaaaadb8ce030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaadb8ce030 'a') -> $$ = nterm item (0xaaaadb8ce030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xaaaadb8ce080->Object::Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90, 0xaaaadb8cdfe0, 0xaaaadb8ce030 } Next token is token 'p' (0xaaaadb8ce080 'p'Exception caught: cleaning lookahead and stack 0xaaaadb8ce080->Object::~Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90, 0xaaaadb8cdfe0, 0xaaaadb8ce030, 0xaaaadb8ce080 } 0xaaaadb8ce030->Object::~Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90, 0xaaaadb8cdfe0, 0xaaaadb8ce030 } 0xaaaadb8cdfe0->Object::~Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90, 0xaaaadb8cdfe0 } 0xaaaadb8cdf90->Object::~Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90 } 0xaaaadb8cdf40->Object::~Object { 0xaaaadb8cdf40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1361: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaE stderr: ./glr-regression.at:356: $PREPARSER ./glr-regr2a input2.txt exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1361: $PREPARSER ./input aaaaT stderr: stdout: stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:857: $PREPARSER ./input stderr: ./c++.at:1361: $PREPARSER ./input aaaaR ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:356: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:858: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy 686. c++.at:1361: ok ======== Testing with C++ standard flags: '' ./glr-regression.at:356: $PREPARSER ./glr-regr2a input3.txt ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./glr-regression.at:356: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 719. glr-regression.at:356: ok 728. glr-regression.at:598: testing Duplicate representation of merged trees: api.value.type=union glr2.cc ... ./glr-regression.at:598: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.cc glr-regr4.y 729. glr-regression.at:670: testing User destructor for unresolved GLR semantic value: glr.c ... ./glr-regression.at:670: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr5.c glr-regr5.y ./glr-regression.at:670: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr5 glr-regr5.c $LIBS ./glr-regression.at:598: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr4 glr-regr4.cc $LIBS stderr: stdout: ./glr-regression.at:593: $PREPARSER ./glr-regr4 stderr: ./glr-regression.at:593: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 724. glr-regression.at:593: ok stderr: stdout: ./glr-regression.at:596: $PREPARSER ./glr-regr4 stderr: ./glr-regression.at:596: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 726. glr-regression.at:596: ok 730. glr-regression.at:671: testing User destructor for unresolved GLR semantic value: glr.cc ... ./glr-regression.at:671: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr5.cc glr-regr5.y ./glr-regression.at:671: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr5 glr-regr5.cc $LIBS 731. glr-regression.at:672: testing User destructor for unresolved GLR semantic value: glr2.cc ... ./glr-regression.at:672: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr5.cc glr-regr5.y ./glr-regression.at:672: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr5 glr-regr5.cc $LIBS stderr: stdout: ./c++.at:1360: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1360: $PREPARSER ./input aaaal stdout: ./glr-regression.at:597: $PREPARSER ./glr-regr4 stderr: exception caught: yylex ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1360: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:597: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 727. glr-regression.at:597: ok stderr: ./c++.at:1360: $PREPARSER ./input aaaap stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input --debug aaaap stdout: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaac5722f40->Object::Object { } Next token is token 'a' (0xaaaac5722f40 'a') Shifting token 'a' (0xaaaac5722f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac5722f40 'a') -> $$ = nterm item (0xaaaac5722f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaac5722f90->Object::Object { 0xaaaac5722f40 } Next token is token 'a' (0xaaaac5722f90 'a') Shifting token 'a' (0xaaaac5722f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac5722f90 'a') -> $$ = nterm item (0xaaaac5722f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaac5722fe0->Object::Object { 0xaaaac5722f40, 0xaaaac5722f90 } Next token is token 'a' (0xaaaac5722fe0 'a') Shifting token 'a' (0xaaaac5722fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac5722fe0 'a') -> $$ = nterm item (0xaaaac5722fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaac5723030->Object::Object { 0xaaaac5722f40, 0xaaaac5722f90, 0xaaaac5722fe0 } Next token is token 'a' (0xaaaac5723030 'a') Shifting token 'a' (0xaaaac5723030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac5723030 'a') -> $$ = nterm item (0xaaaac5723030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaac5723080->Object::Object { 0xaaaac5722f40, 0xaaaac5722f90, 0xaaaac5722fe0, 0xaaaac5723030 } Next token is token 'p' (0xaaaac5723080 'p'Exception caught: cleaning lookahead and stack 0xaaaac5723080->Object::~Object { 0xaaaac5722f40, 0xaaaac5722f90, 0xaaaac5722fe0, 0xaaaac5723030, 0xaaaac5723080 } 0xaaaac5723030->Object::~Object { 0xaaaac5722f40, 0xaaaac5722f90, 0xaaaac5722fe0, 0xaaaac5723030 } 0xaaaac5722fe0->Object::~Object { 0xaaaac5722f40, 0xaaaac5722f90, 0xaaaac5722fe0 } 0xaaaac5722f90->Object::~Object { 0xaaaac5722f40, 0xaaaac5722f90 } 0xaaaac5722f40->Object::~Object { 0xaaaac5722f40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:858: $PREPARSER ./input stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xaaaac5722f40->Object::Object { } Next token is token 'a' (0xaaaac5722f40 'a') Shifting token 'a' (0xaaaac5722f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac5722f40 'a') -> $$ = nterm item (0xaaaac5722f40 'a') Entering state 11 Stack now 0 11 Reading a token 0xaaaac5722f90->Object::Object { 0xaaaac5722f40 } Next token is token 'a' (0xaaaac5722f90 'a') Shifting token 'a' (0xaaaac5722f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac5722f90 'a') -> $$ = nterm item (0xaaaac5722f90 'a') Entering state 11 Stack now 0 11 11 Reading a token 0xaaaac5722fe0->Object::Object { 0xaaaac5722f40, 0xaaaac5722f90 } Next token is token 'a' (0xaaaac5722fe0 'a') Shifting token 'a' (0xaaaac5722fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac5722fe0 'a') -> $$ = nterm item (0xaaaac5722fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token 0xaaaac5723030->Object::Object { 0xaaaac5722f40, 0xaaaac5722f90, 0xaaaac5722fe0 } Next token is token 'a' (0xaaaac5723030 'a') Shifting token 'a' (0xaaaac5723030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): $1 = token 'a' (0xaaaac5723030 'a') -> $$ = nterm item (0xaaaac5723030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xaaaac5723080->Object::Object { 0xaaaac5722f40, 0xaaaac5722f90, 0xaaaac5722fe0, 0xaaaac5723030 } Next token is token 'p' (0xaaaac5723080 'p'Exception caught: cleaning lookahead and stack 0xaaaac5723080->Object::~Object { 0xaaaac5722f40, 0xaaaac5722f90, 0xaaaac5722fe0, 0xaaaac5723030, 0xaaaac5723080 } 0xaaaac5723030->Object::~Object { 0xaaaac5722f40, 0xaaaac5722f90, 0xaaaac5722fe0, 0xaaaac5723030 } 0xaaaac5722fe0->Object::~Object { 0xaaaac5722f40, 0xaaaac5722f90, 0xaaaac5722fe0 } 0xaaaac5722f90->Object::~Object { 0xaaaac5722f40, 0xaaaac5722f90 } 0xaaaac5722f40->Object::~Object { 0xaaaac5722f40 } exception caught: printer end { } ./c++.at:1360: grep '^exception caught: printer$' stderr stderr: stderr: stdout: exception caught: printer ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaae stdout: ./glr-regression.at:670: $PREPARSER ./glr-regr5 stderr: stderr: ======== Testing with C++ standard flags: '' Ambiguity detected. Option 1, start -> 'a' Option 2, start -> 'a' syntax is ambiguous ./glr-regression.at:670: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaE 729. glr-regression.at:670: ok stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaT stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaaR stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 685. c++.at:1360: ok 732. glr-regression.at:738: testing User destructor after an error during a split parse: glr.c ... ./glr-regression.at:738: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr6.c glr-regr6.y ./glr-regression.at:738: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr6 glr-regr6.c $LIBS 733. glr-regression.at:739: testing User destructor after an error during a split parse: glr.cc ... ./glr-regression.at:739: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr6.cc glr-regr6.y 734. glr-regression.at:740: testing User destructor after an error during a split parse: glr2.cc ... ./glr-regression.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr6.cc glr-regr6.y ./glr-regression.at:739: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr6 glr-regr6.cc $LIBS stderr: stdout: ./glr-regression.at:740: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr6 glr-regr6.cc $LIBS ./glr-regression.at:490: $PREPARSER ./glr-regr3 input.txt stderr: ./glr-regression.at:490: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 722. glr-regression.at:490: ok 735. glr-regression.at:843: testing Duplicated user destructor for lookahead: glr.c ... ./glr-regression.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr7.c glr-regr7.y ./glr-regression.at:843: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr7 glr-regr7.c $LIBS stderr: stdout: ./c++.at:858: $PREPARSER ./input stderr: ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: stderr: ./c++.at:1362: $PREPARSER ./input aaaas stderr: stdout: exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaal stderr: ./glr-regression.at:671: $PREPARSER ./glr-regr5 exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1362: $PREPARSER ./input i stderr: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Ambiguity detected. Option 1, start -> 'a' Option 2, start -> 'a' syntax is ambiguous stderr: ./glr-regression.at:671: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./glr-regression.at:594: $PREPARSER ./glr-regr4 stderr: ./glr-regression.at:594: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaap stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: stderr: stdout: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc6645870->Object::Object { } 0xffffc6645970->Object::Object { 0xffffc6645870 } 0xffffc6645870->Object::~Object { 0xffffc6645870, 0xffffc6645970 } Next token is token 'a' (0xffffc6645970 'a') 0xffffc66458b0->Object::Object { 0xffffc6645970 } 0xffffc6645970->Object::~Object { 0xffffc66458b0, 0xffffc6645970 } Shifting token 'a' (0xffffc66458b0 'a') 0xaaaad63fe2e0->Object::Object { 0xffffc66458b0 } 0xffffc66458b0->Object::~Object { 0xaaaad63fe2e0, 0xffffc66458b0 } Entering state 2 Stack now 0 2 0xffffc6645990->Object::Object { 0xaaaad63fe2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaad63fe2e0 'a') -> $$ = nterm item (0xffffc6645990 'a') 0xaaaad63fe2e0->Object::~Object { 0xaaaad63fe2e0, 0xffffc6645990 } 0xaaaad63fe2e0->Object::Object { 0xffffc6645990 } 0xffffc6645990->Object::~Object { 0xaaaad63fe2e0, 0xffffc6645990 } Entering state 11 Stack now 0 11 Reading a token 0xffffc6645870->Object::Object { 0xaaaad63fe2e0 } 0xffffc6645970->Object::Object { 0xaaaad63fe2e0, 0xffffc6645870 } 0xffffc6645870->Object::~Object { 0xaaaad63fe2e0, 0xffffc6645870, 0xffffc6645970 } Next token is token 'a' (0xffffc6645970 'a') 0xffffc66458b0->Object::Object { 0xaaaad63fe2e0, 0xffffc6645970 } 0xffffc6645970->Object::~Object { 0xaaaad63fe2e0, 0xffffc66458b0, 0xffffc6645970 } Shifting token 'a' (0xffffc66458b0 'a') 0xaaaad63fe300->Object::Object { 0xaaaad63fe2e0, 0xffffc66458b0 } 0xffffc66458b0->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc66458b0 } Entering state 2 Stack now 0 11 2 0xffffc6645990->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaad63fe300 'a') -> $$ = nterm item (0xffffc6645990 'a') 0xaaaad63fe300->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645990 } 0xaaaad63fe300->Object::Object { 0xaaaad63fe2e0, 0xffffc6645990 } 0xffffc6645990->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645990 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffc6645870->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300 } 0xffffc6645970->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645870 } 0xffffc6645870->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645870, 0xffffc6645970 } Next token is token 'a' (0xffffc6645970 'a') 0xffffc66458b0->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645970 } 0xffffc6645970->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc66458b0, 0xffffc6645970 } Shifting token 'a' (0xffffc66458b0 'a') 0xaaaad63fe320->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc66458b0 } 0xffffc66458b0->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc66458b0 } Entering state 2 Stack now 0 11 11 2 0xffffc6645990->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaad63fe320 'a') -> $$ = nterm item (0xffffc6645990 'a') 0xaaaad63fe320->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645990 } 0xaaaad63fe320->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645990 } 0xffffc6645990->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645990 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffc6645870->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320 } 0xffffc6645970->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645870 } 0xffffc6645870->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645870, 0xffffc6645970 } Next token is token 'a' (0xffffc6645970 'a') 0xffffc66458b0->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645970 } 0xffffc6645970->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc66458b0, 0xffffc6645970 } Shifting token 'a' (0xffffc66458b0 'a') 0xaaaad63fe340->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc66458b0 } 0xffffc66458b0->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc66458b0 } Entering state 2 Stack now 0 11 11 11 2 0xffffc6645990->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaad63fe340 'a') -> $$ = nterm item (0xffffc6645990 'a') 0xaaaad63fe340->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc6645990 } 0xaaaad63fe340->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645990 } 0xffffc6645990->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc6645990 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffc6645870->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340 } 0xffffc6645970->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc6645870 } 0xffffc6645870->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc6645870, 0xffffc6645970 } Next token is token 'p' (0xffffc6645970 'p'Exception caught: cleaning lookahead and stack 0xaaaad63fe340->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc6645970 } 0xaaaad63fe320->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645970 } 0xaaaad63fe300->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645970 } 0xaaaad63fe2e0->Object::~Object { 0xaaaad63fe2e0, 0xffffc6645970 } 0xffffc6645970->Object::~Object { 0xffffc6645970 } exception caught: printer end { } ./glr-regression.at:738: $PREPARSER ./glr-regr6 ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xffffc6645870->Object::Object { } 0xffffc6645970->Object::Object { 0xffffc6645870 } 0xffffc6645870->Object::~Object { 0xffffc6645870, 0xffffc6645970 } Next token is token 'a' (0xffffc6645970 'a') 0xffffc66458b0->Object::Object { 0xffffc6645970 } 0xffffc6645970->Object::~Object { 0xffffc66458b0, 0xffffc6645970 } Shifting token 'a' (0xffffc66458b0 'a') 0xaaaad63fe2e0->Object::Object { 0xffffc66458b0 } 0xffffc66458b0->Object::~Object { 0xaaaad63fe2e0, 0xffffc66458b0 } Entering state 2 Stack now 0 2 0xffffc6645990->Object::Object { 0xaaaad63fe2e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaad63fe2e0 'a') -> $$ = nterm item (0xffffc6645990 'a') 0xaaaad63fe2e0->Object::~Object { 0xaaaad63fe2e0, 0xffffc6645990 } 0xaaaad63fe2e0->Object::Object { 0xffffc6645990 } 0xffffc6645990->Object::~Object { 0xaaaad63fe2e0, 0xffffc6645990 } Entering state 11 Stack now 0 11 Reading a token 0xffffc6645870->Object::Object { 0xaaaad63fe2e0 } 0xffffc6645970->Object::Object { 0xaaaad63fe2e0, 0xffffc6645870 } 0xffffc6645870->Object::~Object { 0xaaaad63fe2e0, 0xffffc6645870, 0xffffc6645970 } Next token is token 'a' (0xffffc6645970 'a') 0xffffc66458b0->Object::Object { 0xaaaad63fe2e0, 0xffffc6645970 } 0xffffc6645970->Object::~Object { 0xaaaad63fe2e0, 0xffffc66458b0, 0xffffc6645970 } Shifting token 'a' (0xffffc66458b0 'a') 0xaaaad63fe300->Object::Object { 0xaaaad63fe2e0, 0xffffc66458b0 } 0xffffc66458b0->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc66458b0 } Entering state 2 Stack now 0 11 2 0xffffc6645990->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaad63fe300 'a') -> $$ = nterm item (0xffffc6645990 'a') 0xaaaad63fe300->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645990 } 0xaaaad63fe300->Object::Object { 0xaaaad63fe2e0, 0xffffc6645990 } 0xffffc6645990->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645990 } Entering state 11 Stack now 0 11 11 Reading a token 0xffffc6645870->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300 } 0xffffc6645970->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645870 } 0xffffc6645870->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645870, 0xffffc6645970 } Next token is token 'a' (0xffffc6645970 'a') 0xffffc66458b0->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645970 } 0xffffc6645970->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc66458b0, 0xffffc6645970 } Shifting token 'a' (0xffffc66458b0 'a') 0xaaaad63fe320->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc66458b0 } 0xffffc66458b0->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc66458b0 } Entering state 2 Stack now 0 11 11 2 0xffffc6645990->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaad63fe320 'a') -> $$ = nterm item (0xffffc6645990 'a') 0xaaaad63fe320->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645990 } 0xaaaad63fe320->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645990 } 0xffffc6645990->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645990 } Entering state 11 Stack now 0 11 11 11 Reading a token 0xffffc6645870->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320 } 0xffffc6645970->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645870 } 0xffffc6645870->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645870, 0xffffc6645970 } Next token is token 'a' (0xffffc6645970 'a') 0xffffc66458b0->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645970 } 0xffffc6645970->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc66458b0, 0xffffc6645970 } Shifting token 'a' (0xffffc66458b0 'a') 0xaaaad63fe340->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc66458b0 } 0xffffc66458b0->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc66458b0 } Entering state 2 Stack now 0 11 11 11 2 0xffffc6645990->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaad63fe340 'a') -> $$ = nterm item (0xffffc6645990 'a') 0xaaaad63fe340->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc6645990 } 0xaaaad63fe340->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645990 } 0xffffc6645990->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc6645990 } Entering state 11 Stack now 0 11 11 11 11 Reading a token 0xffffc6645870->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340 } 0xffffc6645970->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc6645870 } 0xffffc6645870->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc6645870, 0xffffc6645970 } Next token is token 'p' (0xffffc6645970 'p'Exception caught: cleaning lookahead and stack 0xaaaad63fe340->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc6645970 } 0xaaaad63fe320->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645970 } 0xaaaad63fe300->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645970 } 0xaaaad63fe2e0->Object::~Object { 0xaaaad63fe2e0, 0xffffc6645970 } 0xffffc6645970->Object::~Object { 0xffffc6645970 } exception caught: printer end { } stderr: ./c++.at:1362: grep '^exception caught: printer$' stderr Ambiguity detected. Option 1, start -> 'a' Option 2, start -> 'a' syntax is ambiguous stdout: 725. glr-regression.at:594: ok ./glr-regression.at:738: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 732. glr-regression.at:738: ok 730. glr-regression.at:671: ok ./c++.at:1362: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaT stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaR stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 736. glr-regression.at:844: testing Duplicated user destructor for lookahead: glr.cc ... ./glr-regression.at:844: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr7.cc glr-regr7.y 687. c++.at:1362: ok 737. glr-regression.at:845: testing Duplicated user destructor for lookahead: glr2.cc ... ./glr-regression.at:845: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr7.cc glr-regr7.y 738. glr-regression.at:944: testing Incorrectly initialized location for empty right-hand side in GLR: glr.c ... ./glr-regression.at:944: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr8.c glr-regr8.y ./glr-regression.at:844: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr7 glr-regr7.cc $LIBS ./glr-regression.at:845: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr7 glr-regr7.cc $LIBS 739. glr-regression.at:945: testing Incorrectly initialized location for empty right-hand side in GLR: glr.cc ... ./glr-regression.at:944: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr8 glr-regr8.c $LIBS ./glr-regression.at:945: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr8.cc glr-regr8.y ./glr-regression.at:945: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr8 glr-regr8.cc $LIBS stderr: stdout: stderr: stdout: ./glr-regression.at:739: $PREPARSER ./glr-regr6 ./glr-regression.at:843: $PREPARSER ./glr-regr7 stderr: stderr: Ambiguity detected. Option 1, start -> 'a' Option 2, start -> 'a' syntax is ambiguous ./glr-regression.at:739: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr memory exhausted ./glr-regression.at:843: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 733. glr-regression.at:739: ok 735. glr-regression.at:843: ok stderr: stdout: ./c++.at:858: $PREPARSER ./input stderr: ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 740. glr-regression.at:946: testing Incorrectly initialized location for empty right-hand side in GLR: glr2.cc ... ./glr-regression.at:946: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr8.cc glr-regr8.y 741. glr-regression.at:1036: testing No users destructors if stack 0 deleted: glr.c ... ./glr-regression.at:1036: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr9.c glr-regr9.y ./glr-regression.at:946: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr8 glr-regr8.cc $LIBS stderr: stdout: ./glr-regression.at:598: $PREPARSER ./glr-regr4 stderr: ./glr-regression.at:598: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1036: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr9 glr-regr9.c $LIBS 728. glr-regression.at:598: ok stderr: stdout: ./c++.at:1363: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 742. glr-regression.at:1037: testing No users destructors if stack 0 deleted: glr.cc ... ./glr-regression.at:1037: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr9.cc glr-regr9.y ./c++.at:1363: $PREPARSER ./input aaaal stderr: stdout: stderr: exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:944: $PREPARSER ./glr-regr8 stderr: ./glr-regression.at:1037: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr9 glr-regr9.cc $LIBS ./c++.at:1363: $PREPARSER ./input i ./glr-regression.at:944: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: initial-action 738. glr-regression.at:944: ok ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaap stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./glr-regression.at:844: $PREPARSER ./glr-regr7 ./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffff252f0a0->Object::Object { } 0xfffff252f1a0->Object::Object { 0xfffff252f0a0 } 0xfffff252f0a0->Object::~Object { 0xfffff252f0a0, 0xfffff252f1a0 } Next token is token 'a' (0xfffff252f1a0 'a') 0xfffff252f0e0->Object::Object { 0xfffff252f1a0 } 0xfffff252f1a0->Object::~Object { 0xfffff252f0e0, 0xfffff252f1a0 } Shifting token 'a' (0xfffff252f0e0 'a') 0xaaaae38f22e0->Object::Object { 0xfffff252f0e0 } 0xfffff252f0e0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f0e0 } Entering state 1 Stack now 0 1 0xfffff252f1c0->Object::Object { 0xaaaae38f22e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae38f22e0 'a') -> $$ = nterm item (0xfffff252f1c0 'a') 0xaaaae38f22e0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f1c0 } 0xaaaae38f22e0->Object::Object { 0xfffff252f1c0 } 0xfffff252f1c0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f1c0 } Entering state 10 Stack now 0 10 Reading a token 0xfffff252f0a0->Object::Object { 0xaaaae38f22e0 } 0xfffff252f1a0->Object::Object { 0xaaaae38f22e0, 0xfffff252f0a0 } 0xfffff252f0a0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f0a0, 0xfffff252f1a0 } Next token is token 'a' (0xfffff252f1a0 'a') 0xfffff252f0e0->Object::Object { 0xaaaae38f22e0, 0xfffff252f1a0 } 0xfffff252f1a0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f0e0, 0xfffff252f1a0 } Shifting token 'a' (0xfffff252f0e0 'a') 0xaaaae38f2300->Object::Object { 0xaaaae38f22e0, 0xfffff252f0e0 } 0xfffff252f0e0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f0e0 } Entering state 1 Stack now 0 10 1 0xfffff252f1c0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae38f2300 'a') -> $$ = nterm item (0xfffff252f1c0 'a') 0xaaaae38f2300->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f1c0 } 0xaaaae38f2300->Object::Object { 0xaaaae38f22e0, 0xfffff252f1c0 } 0xfffff252f1c0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f1c0 } Entering state 10 Stack now 0 10 10 Reading a token 0xfffff252f0a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300 } 0xfffff252f1a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f0a0 } 0xfffff252f0a0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f0a0, 0xfffff252f1a0 } Next token is token 'a' (0xfffff252f1a0 'a') 0xfffff252f0e0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f1a0 } 0xfffff252f1a0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f0e0, 0xfffff252f1a0 } Shifting token 'a' (0xfffff252f0e0 'a') 0xaaaae38f2320->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f0e0 } 0xfffff252f0e0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f0e0 } Entering state 1 Stack now 0 10 10 1 0xfffff252f1c0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae38f2320 'a') -> $$ = nterm item (0xfffff252f1c0 'a') 0xaaaae38f2320->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f1c0 } 0xaaaae38f2320->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f1c0 } 0xfffff252f1c0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f1c0 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xfffff252f0a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320 } 0xfffff252f1a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f0a0 } 0xfffff252f0a0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f0a0, 0xfffff252f1a0 } Next token is token 'a' (0xfffff252f1a0 'a') 0xfffff252f0e0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f1a0 } 0xfffff252f1a0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f0e0, 0xfffff252f1a0 } Shifting token 'a' (0xfffff252f0e0 'a') 0xaaaae38f2340->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f0e0 } 0xfffff252f0e0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f0e0 } Entering state 1 Stack now 0 10 10 10 1 0xfffff252f1c0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae38f2340 'a') -> $$ = nterm item (0xfffff252f1c0 'a') 0xaaaae38f2340->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f1c0 } 0xaaaae38f2340->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f1c0 } 0xfffff252f1c0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f1c0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xfffff252f0a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340 } 0xfffff252f1a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f0a0 } 0xfffff252f0a0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f0a0, 0xfffff252f1a0 } Next token is token 'p' (0xfffff252f1a0 'p'Exception caught: cleaning lookahead and stack 0xaaaae38f2340->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f1a0 } 0xaaaae38f2320->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f1a0 } 0xaaaae38f2300->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f1a0 } 0xaaaae38f22e0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f1a0 } 0xfffff252f1a0->Object::~Object { 0xfffff252f1a0 } exception caught: printer end { } ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr memory exhausted ./glr-regression.at:844: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token 0xfffff252f0a0->Object::Object { } 0xfffff252f1a0->Object::Object { 0xfffff252f0a0 } 0xfffff252f0a0->Object::~Object { 0xfffff252f0a0, 0xfffff252f1a0 } Next token is token 'a' (0xfffff252f1a0 'a') 0xfffff252f0e0->Object::Object { 0xfffff252f1a0 } 0xfffff252f1a0->Object::~Object { 0xfffff252f0e0, 0xfffff252f1a0 } Shifting token 'a' (0xfffff252f0e0 'a') 0xaaaae38f22e0->Object::Object { 0xfffff252f0e0 } 0xfffff252f0e0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f0e0 } Entering state 1 Stack now 0 1 0xfffff252f1c0->Object::Object { 0xaaaae38f22e0 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae38f22e0 'a') -> $$ = nterm item (0xfffff252f1c0 'a') 0xaaaae38f22e0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f1c0 } 0xaaaae38f22e0->Object::Object { 0xfffff252f1c0 } 0xfffff252f1c0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f1c0 } Entering state 10 Stack now 0 10 Reading a token 0xfffff252f0a0->Object::Object { 0xaaaae38f22e0 } 0xfffff252f1a0->Object::Object { 0xaaaae38f22e0, 0xfffff252f0a0 } 0xfffff252f0a0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f0a0, 0xfffff252f1a0 } Next token is token 'a' (0xfffff252f1a0 'a') 0xfffff252f0e0->Object::Object { 0xaaaae38f22e0, 0xfffff252f1a0 } 0xfffff252f1a0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f0e0, 0xfffff252f1a0 } Shifting token 'a' (0xfffff252f0e0 'a') 0xaaaae38f2300->Object::Object { 0xaaaae38f22e0, 0xfffff252f0e0 } 0xfffff252f0e0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f0e0 } Entering state 1 Stack now 0 10 1 0xfffff252f1c0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae38f2300 'a') -> $$ = nterm item (0xfffff252f1c0 'a') 0xaaaae38f2300->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f1c0 } 0xaaaae38f2300->Object::Object { 0xaaaae38f22e0, 0xfffff252f1c0 } 0xfffff252f1c0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f1c0 } Entering state 10 Stack now 0 10 10 Reading a token 0xfffff252f0a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300 } 0xfffff252f1a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f0a0 } 0xfffff252f0a0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f0a0, 0xfffff252f1a0 } Next token is token 'a' (0xfffff252f1a0 'a') 0xfffff252f0e0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f1a0 } 0xfffff252f1a0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f0e0, 0xfffff252f1a0 } Shifting token 'a' (0xfffff252f0e0 'a') 0xaaaae38f2320->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f0e0 } 0xfffff252f0e0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f0e0 } Entering state 1 Stack now 0 10 10 1 0xfffff252f1c0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae38f2320 'a') -> $$ = nterm item (0xfffff252f1c0 'a') 0xaaaae38f2320->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f1c0 } 0xaaaae38f2320->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f1c0 } 0xfffff252f1c0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f1c0 } Entering state 10 Stack now 0 10 10 10 Reading a token 0xfffff252f0a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320 } 0xfffff252f1a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f0a0 } 0xfffff252f0a0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f0a0, 0xfffff252f1a0 } Next token is token 'a' (0xfffff252f1a0 'a') 0xfffff252f0e0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f1a0 } 0xfffff252f1a0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f0e0, 0xfffff252f1a0 } Shifting token 'a' (0xfffff252f0e0 'a') 0xaaaae38f2340->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f0e0 } 0xfffff252f0e0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f0e0 } Entering state 1 Stack now 0 10 10 10 1 0xfffff252f1c0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340 } Reducing stack by rule 4 (line 142): $1 = token 'a' (0xaaaae38f2340 'a') -> $$ = nterm item (0xfffff252f1c0 'a') 0xaaaae38f2340->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f1c0 } 0xaaaae38f2340->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f1c0 } 0xfffff252f1c0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f1c0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token 0xfffff252f0a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340 } 0xfffff252f1a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f0a0 } 0xfffff252f0a0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f0a0, 0xfffff252f1a0 } Next token is token 'p' (0xfffff252f1a0 'p'Exception caught: cleaning lookahead and stack 0xaaaae38f2340->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f1a0 } 0xaaaae38f2320->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f1a0 } 0xaaaae38f2300->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f1a0 } 0xaaaae38f22e0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f1a0 } 0xfffff252f1a0->Object::~Object { 0xfffff252f1a0 } exception caught: printer end { } ./c++.at:1363: grep '^exception caught: printer$' stderr 736. glr-regression.at:844: ok stdout: exception caught: printer ./c++.at:1363: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 743. glr-regression.at:1038: testing No users destructors if stack 0 deleted: glr2.cc ... ./glr-regression.at:1038: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr9.cc glr-regr9.y ./c++.at:1363: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaT stderr: stdout: ./glr-regression.at:672: $PREPARSER ./glr-regr5 stderr: Ambiguity detected. Option 1, start -> 'a' Option 2, start -> 'a' syntax is ambiguous ./glr-regression.at:672: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1038: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr9 glr-regr9.cc $LIBS ./c++.at:1363: $PREPARSER ./input aaaaR stderr: 731. glr-regression.at:672: ok ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 688. c++.at:1363: ok 744. glr-regression.at:1102: testing Corrupted semantic options if user action cuts parse: glr.c ... ./glr-regression.at:1102: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr10.c glr-regr10.y ./glr-regression.at:1102: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr10 glr-regr10.c $LIBS 745. glr-regression.at:1103: testing Corrupted semantic options if user action cuts parse: glr.cc ... ./glr-regression.at:1103: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr10.cc glr-regr10.y 746. glr-regression.at:1104: testing Corrupted semantic options if user action cuts parse: glr2.cc ... ./glr-regression.at:1104: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr10.cc glr-regr10.y stderr: stdout: ./glr-regression.at:1036: $PREPARSER ./glr-regr9 stderr: ./glr-regression.at:1103: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr10 glr-regr10.cc $LIBS memory exhausted ./glr-regression.at:1036: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1104: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr10 glr-regr10.cc $LIBS 741. glr-regression.at:1036: ok stderr: stdout: ./glr-regression.at:945: $PREPARSER ./glr-regr8 stderr: ./glr-regression.at:945: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 747. glr-regression.at:1174: testing Undesirable destructors if user action cuts parse: glr.c ... ./glr-regression.at:1174: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr11.c glr-regr11.y stdout: ./glr-regression.at:1174: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr11 glr-regr11.c $LIBS 739. glr-regression.at:945: ok ./c++.at:858: $PREPARSER ./input stderr: ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 748. glr-regression.at:1175: testing Undesirable destructors if user action cuts parse: glr.cc ... ./glr-regression.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr11.cc glr-regr11.y stderr: ./glr-regression.at:1175: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr11 glr-regr11.cc $LIBS stdout: ./glr-regression.at:740: $PREPARSER ./glr-regr6 stderr: Ambiguity detected. Option 1, start -> 'a' Option 2, start -> 'a' syntax is ambiguous ./glr-regression.at:740: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 734. glr-regression.at:740: ok stderr: stdout: ./glr-regression.at:1037: $PREPARSER ./glr-regr9 stderr: memory exhausted ./glr-regression.at:1037: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 742. glr-regression.at:1037: ok 749. glr-regression.at:1176: testing Undesirable destructors if user action cuts parse: glr2.cc ... ./glr-regression.at:1176: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr11.cc glr-regr11.y stderr: stdout: ./glr-regression.at:1102: $PREPARSER ./glr-regr10 stderr: ./glr-regression.at:1102: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 744. glr-regression.at:1102: ok ./glr-regression.at:1176: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr11 glr-regr11.cc $LIBS 750. glr-regression.at:1310: testing Leaked semantic values if user action cuts parse: glr.c ... ./glr-regression.at:1310: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr12.c glr-regr12.y ./glr-regression.at:1310: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr12 glr-regr12.c $LIBS stderr: stdout: 751. glr-regression.at:1311: testing Leaked semantic values if user action cuts parse: glr.cc ... ./glr-regression.at:1311: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr12.cc glr-regr12.y ./glr-regression.at:845: $PREPARSER ./glr-regr7 stderr: memory exhausted ./glr-regression.at:845: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./glr-regression.at:1174: $PREPARSER ./glr-regr11 737. glr-regression.at:845: ok stderr: ./glr-regression.at:1174: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1311: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr12 glr-regr12.cc $LIBS 747. glr-regression.at:1174: ok 752. glr-regression.at:1312: testing Leaked semantic values if user action cuts parse: glr2.cc ... ./glr-regression.at:1312: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr12.cc glr-regr12.y 753. glr-regression.at:1445: testing Incorrect lookahead during deterministic GLR: glr.c ... ./glr-regression.at:1445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr13.c glr-regr13.y stderr: stdout: ./c++.at:858: $PREPARSER ./input ./glr-regression.at:1312: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr12 glr-regr12.cc $LIBS stderr: ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./glr-regression.at:1445: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr13 glr-regr13.c $LIBS stdout: ./glr-regression.at:1103: $PREPARSER ./glr-regr10 stderr: ======== Testing with C++ standard flags: '' ./glr-regression.at:1103: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 745. glr-regression.at:1103: ok ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1066: $PREPARSER ./input < in 754. glr-regression.at:1446: testing Incorrect lookahead during deterministic GLR: glr.cc ... ./glr-regression.at:1446: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr13.cc glr-regr13.y stderr: error: invalid expression caught error error: invalid character caught error ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $PREPARSER ./input < in ./glr-regression.at:1446: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr13 glr-regr13.cc $LIBS stderr: error: invalid expression ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1066: $PREPARSER ./input < in stderr: stdout: ./glr-regression.at:1310: $PREPARSER ./glr-regr12 stderr: error: invalid character ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./glr-regression.at:1310: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 750. glr-regression.at:1310: ok 684. c++.at:1066: ok stderr: stdout: ./glr-regression.at:1175: $PREPARSER ./glr-regr11 stderr: ./glr-regression.at:1175: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 748. glr-regression.at:1175: ok 755. glr-regression.at:1447: testing Incorrect lookahead during deterministic GLR: glr2.cc ... ./glr-regression.at:1447: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr13.cc glr-regr13.y stderr: stdout: ./glr-regression.at:946: $PREPARSER ./glr-regr8 stderr: 756. glr-regression.at:1678: testing Incorrect lookahead during nondeterministic GLR: glr.c ... ./glr-regression.at:1678: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr14.c glr-regr14.y ./glr-regression.at:946: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1447: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr13 glr-regr13.cc $LIBS 740. glr-regression.at:946: ok 757. glr-regression.at:1679: testing Incorrect lookahead during nondeterministic GLR: glr.cc ... ./glr-regression.at:1679: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr14.cc glr-regr14.y ./glr-regression.at:1678: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr14 glr-regr14.c $LIBS ./glr-regression.at:1679: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr14 glr-regr14.cc $LIBS 758. glr-regression.at:1680: testing Incorrect lookahead during nondeterministic GLR: glr2.cc ... ./glr-regression.at:1680: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr14.cc glr-regr14.y stderr: stdout: ./glr-regression.at:1445: $PREPARSER ./glr-regr13 stderr: ./glr-regression.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1680: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr14 glr-regr14.cc $LIBS 753. glr-regression.at:1445: ok stderr: stdout: 759. glr-regression.at:1785: testing Leaked semantic values when reporting ambiguity: glr.c ... ./glr-regression.at:1785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr15.c glr-regr15.y ./glr-regression.at:1311: $PREPARSER ./glr-regr12 stderr: stderr: stdout: ./glr-regression.at:1311: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:858: $PREPARSER ./input stderr: 751. glr-regression.at:1311: ok ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1785: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr15 glr-regr15.c $LIBS ======== Testing with C++ standard flags: '' ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 760. glr-regression.at:1786: testing Leaked semantic values when reporting ambiguity: glr.cc ... ./glr-regression.at:1786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr15.cc glr-regr15.y ./glr-regression.at:1786: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr15 glr-regr15.cc $LIBS stderr: stderr: stdout: stdout: ./glr-regression.at:1104: $PREPARSER ./glr-regr10 ./glr-regression.at:1038: $PREPARSER ./glr-regr9 stderr: ./glr-regression.at:1104: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: memory exhausted ./glr-regression.at:1038: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 746. glr-regression.at:1104: ok 743. glr-regression.at:1038: ok 761. glr-regression.at:1787: testing Leaked semantic values when reporting ambiguity: glr2.cc ... 762. glr-regression.at:1860: testing Leaked lookahead after nondeterministic parse syntax error: glr.c ... ./glr-regression.at:1860: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr16.c glr-regr16.y ./glr-regression.at:1787: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr15.cc glr-regr15.y ./glr-regression.at:1860: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr16 glr-regr16.c $LIBS ./glr-regression.at:1787: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr15 glr-regr15.cc $LIBS stderr: stdout: ./glr-regression.at:1446: $PREPARSER ./glr-regr13 stderr: stdout: stderr: ./glr-regression.at:1678: $PREPARSER ./glr-regr14 ./glr-regression.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./glr-regression.at:1678: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 754. glr-regression.at:1446: ok 756. glr-regression.at:1678: ok 763. glr-regression.at:1861: testing Leaked lookahead after nondeterministic parse syntax error: glr.cc ... ./glr-regression.at:1861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr16.cc glr-regr16.y 764. glr-regression.at:1862: testing Leaked lookahead after nondeterministic parse syntax error: glr2.cc ... ./glr-regression.at:1862: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr16.cc glr-regr16.y ./glr-regression.at:1861: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr16 glr-regr16.cc $LIBS stderr: stdout: ./glr-regression.at:1785: $PREPARSER ./glr-regr15 stderr: Ambiguity detected. Option 1, ambiguity -> ambiguity1 -> Option 2, ambiguity -> ambiguity2 -> syntax is ambiguous ./glr-regression.at:1785: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 759. glr-regression.at:1785: ok stdout: ./glr-regression.at:1862: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr16 glr-regr16.cc $LIBS ./glr-regression.at:1176: $PREPARSER ./glr-regr11 stderr: ./glr-regression.at:1176: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 749. glr-regression.at:1176: ok 765. glr-regression.at:1964: testing Uninitialized location when reporting ambiguity: glr.c api.pure ... ./glr-regression.at:1964: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr17.c glr-regr17.y 766. glr-regression.at:1965: testing Uninitialized location when reporting ambiguity: glr.cc ... ./glr-regression.at:1965: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr17.cc glr-regr17.y ./glr-regression.at:1964: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr17 glr-regr17.c $LIBS ./glr-regression.at:1965: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr17 glr-regr17.cc $LIBS stderr: stdout: ./glr-regression.at:1860: $PREPARSER ./glr-regr16 stderr: syntax error ./glr-regression.at:1860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: stdout: 762. glr-regression.at:1860: ok ./c++.at:858: $PREPARSER ./input stdout: ./glr-regression.at:1679: $PREPARSER ./glr-regr14 stderr: stderr: ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./glr-regression.at:1679: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 757. glr-regression.at:1679: ok 767. glr-regression.at:1966: testing Uninitialized location when reporting ambiguity: glr2.cc ... ./glr-regression.at:1966: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr17.cc glr-regr17.y stderr: stdout: ./glr-regression.at:1786: $PREPARSER ./glr-regr15 stderr: Ambiguity detected. Option 1, ambiguity -> ambiguity1 -> Option 2, ambiguity -> ambiguity2 -> syntax is ambiguous ./glr-regression.at:1786: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 768. glr-regression.at:2035: testing Missed %merge type warnings when LHS type is declared later: glr.c ... ./glr-regression.at:2035: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o glr-regr18.c -rall -fcaret glr-regr18.y 768. glr-regression.at:2035: ok ./glr-regression.at:1966: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr17 glr-regr17.cc $LIBS 760. glr-regression.at:1786: ok stderr: stdout: ./glr-regression.at:1312: $PREPARSER ./glr-regr12 stderr: ./glr-regression.at:1312: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 770. glr-regression.at:2037: testing Missed %merge type warnings when LHS type is declared later: glr2.cc ... ./glr-regression.at:2037: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o glr-regr18.c -rall -fcaret glr-regr18.y 752. glr-regression.at:1312: ok 769. glr-regression.at:2036: testing Missed %merge type warnings when LHS type is declared later: glr.cc ... ./glr-regression.at:2036: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o glr-regr18.c -rall -fcaret glr-regr18.y 770. glr-regression.at:2037: ok 769. glr-regression.at:2036: ok 771. glr-regression.at:2149: testing Ambiguity reports: glr.c ... ./glr-regression.at:2149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 772. glr-regression.at:2150: testing Ambiguity reports: glr.cc ... ./glr-regression.at:2150: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 773. glr-regression.at:2151: testing Ambiguity reports: glr2.cc ... ./glr-regression.at:2151: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./glr-regression.at:2149: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./glr-regression.at:2150: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./glr-regression.at:2151: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./glr-regression.at:1964: $PREPARSER ./glr-regr17 stderr: Ambiguity detected. Option 1, start -> ambig1 -> sub_ambig2 -> empty2 -> 'a' 'b' empty1 -> Option 2, start -> ambig2 -> sub_ambig2 -> empty2 -> 'a' 'b' empty2 -> 1.1-2.2: syntax is ambiguous ./glr-regression.at:1964: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 765. glr-regression.at:1964: ok 774. glr-regression.at:2229: testing Predicates: glr.c ... ./glr-regression.at:2229: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./glr-regression.at:2229: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./glr-regression.at:1861: $PREPARSER ./glr-regr16 stderr: syntax error ./glr-regression.at:1861: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 763. glr-regression.at:1861: ok stderr: stdout: ./glr-regression.at:2149: $PREPARSER ./input --debug stderr: Starting parse Entering state 0 Reading a token Next token is token 'a' () Shifting token 'a' () Entering state 1 Reading a token Next token is token 'b' () Shifting token 'b' () Entering state 3 Reducing stack 0 by rule 3 (line 30): $1 = token 'b' () -> $$ = nterm b () Entering state 4 Reading a token Next token is token 'c' () Shifting token 'c' () Entering state 6 Reducing stack 0 by rule 4 (line 31): -> $$ = nterm d () Entering state 7 Reading a token Now at end of input. Stack 0 Entering state 7 Now at end of input. Splitting off stack 1 from 0. Reduced stack 1 by rule 2 (line 28); action deferred. Now in state 2. Stack 1 Entering state 2 Now at end of input. Reduced stack 0 by rule 1 (line 27); action deferred. Now in state 2. Merging stack 0 into stack 1. Stack 1 Entering state 2 Now at end of input. Removing dead stacks. Rename stack 1 -> 0. On stack 0, shifting token "end of file" () Stack 0 now in state 5 Ambiguity detected. Option 1, start -> 'a' b 'c' d Option 2, start -> 'a' b 'c' d syntax is ambiguous Cleanup: popping token "end of file" () Cleanup: popping unresolved nterm start () Cleanup: popping nterm d () Cleanup: popping token 'c' () Cleanup: popping nterm b () Cleanup: popping token 'a' () ./glr-regression.at:2149: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 771. glr-regression.at:2149: ok 775. glr-regression.at:2230: testing Predicates: glr.cc ... ./glr-regression.at:2230: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./glr-regression.at:2230: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 776. glr-regression.at:2231: testing Predicates: glr2.cc ... ./glr-regression.at:2231: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: ./glr-regression.at:1680: $PREPARSER ./glr-regr14 stderr: ./glr-regression.at:1680: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2231: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 758. glr-regression.at:1680: ok stderr: stdout: ./glr-regression.at:1965: $PREPARSER ./glr-regr17 stderr: Ambiguity detected. Option 1, start -> ambig1 -> sub_ambig2 -> empty2 -> 'a' 'b' empty1 -> Option 2, start -> ambig2 -> sub_ambig2 -> empty2 -> 'a' 'b' empty2 -> 1.1-2.2: syntax is ambiguous ./glr-regression.at:1965: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 766. glr-regression.at:1965: ok stderr: stdout: ./glr-regression.at:2229: $PREPARSER ./input Nwin stderr: stderr: stdout: ./c++.at:858: $PREPARSER ./input stderr: ./glr-regression.at:2229: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2229: $PREPARSER ./input Owin stderr: syntax error, unexpected 'n', expecting 'o' ./glr-regression.at:2229: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stderr: stdout: ./glr-regression.at:1447: $PREPARSER ./glr-regr13 stderr: ./glr-regression.at:2229: $PREPARSER ./input Owio stderr: ./glr-regression.at:1447: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' 755. glr-regression.at:1447: ok ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./glr-regression.at:2229: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2229: $PREPARSER ./input Nwio stderr: syntax error, unexpected 'o', expecting 'n' ./glr-regression.at:2229: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 774. glr-regression.at:2229: ok stderr: stdout: ./glr-regression.at:2150: $PREPARSER ./input --debug stderr: Starting parse Entering state 0 Reading a token Next token is token 'a' () Shifting token 'a' () Entering state 1 Reading a token Next token is token 'b' () Shifting token 'b' () Entering state 3 Reducing stack 0 by rule 3 (line 30): $1 = token 'b' () -> $$ = nterm b () Entering state 4 Reading a token Next token is token 'c' () Shifting token 'c' () Entering state 6 Reducing stack 0 by rule 4 (line 31): -> $$ = nterm d () Entering state 7 Reading a token Now at end of input. Stack 0 Entering state 7 Now at end of input. Splitting off stack 1 from 0. Reduced stack 1 by rule 2 (line 28); action deferred. Now in state 2. Stack 1 Entering state 2 Now at end of input. Reduced stack 0 by rule 1 (line 27); action deferred. Now in state 2. Merging stack 0 into stack 1. Stack 1 Entering state 2 Now at end of input. Removing dead stacks. Rename stack 1 -> 0. On stack 0, shifting token "end of file" () Stack 0 now in state 5 Ambiguity detected. Option 1, start -> 'a' b 'c' d Option 2, start -> 'a' b 'c' d syntax is ambiguous Cleanup: popping token "end of file" () Cleanup: popping unresolved nterm start () Cleanup: popping nterm d () Cleanup: popping token 'c' () Cleanup: popping nterm b () Cleanup: popping token 'a' () ./glr-regression.at:2150: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 772. glr-regression.at:2150: ok stderr: stdout: ./glr-regression.at:1787: $PREPARSER ./glr-regr15 stderr: Ambiguity detected. Option 1, ambiguity -> ambiguity1 -> Option 2, ambiguity -> ambiguity2 -> syntax is ambiguous ./glr-regression.at:1787: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 761. glr-regression.at:1787: ok stderr: stdout: ./glr-regression.at:1862: $PREPARSER ./glr-regr16 stderr: syntax error ./glr-regression.at:1862: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 764. glr-regression.at:1862: ok stderr: stdout: ./glr-regression.at:2230: $PREPARSER ./input Nwin stderr: ./glr-regression.at:2230: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2230: $PREPARSER ./input Owin stderr: syntax error, unexpected 'n', expecting 'o' ./glr-regression.at:2230: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2230: $PREPARSER ./input Owio stderr: ./glr-regression.at:2230: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2230: $PREPARSER ./input Nwio stderr: syntax error, unexpected 'o', expecting 'n' ./glr-regression.at:2230: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 775. glr-regression.at:2230: ok stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./glr-regression.at:1966: $PREPARSER ./glr-regr17 stderr: Ambiguity detected. Option 1, start -> ambig1 -> sub_ambig2 -> empty2 -> 'a' 'b' empty1 -> Option 2, start -> ambig2 -> sub_ambig2 -> empty2 -> 'a' 'b' empty2 -> 1.1-2.2: syntax is ambiguous ./glr-regression.at:1966: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 767. glr-regression.at:1966: ok stderr: stdout: ./glr-regression.at:2151: $PREPARSER ./input --debug stderr: Starting parse Entering state 0 Reading a token Next token is token 'a' () Shifting token 'a' () Entering state 1 Reading a token Next token is token 'b' () Shifting token 'b' () Entering state 3 Reducing stack 0 by rule 3 (line 30): $1 = token 'b' () -> $$ = nterm b () Entering state 4 Reading a token Next token is token 'c' () Shifting token 'c' () Entering state 6 Reducing stack 0 by rule 4 (line 31): -> $$ = nterm d () Entering state 7 Reading a token Now at end of input. Stack 0 Entering state 7 Now at end of input. Splitting off stack 1 from 0. Reduced stack 1 by rule 2 (line 28); action deferred. Now in state 2. Stack 1 Entering state 2 Now at end of input. Reduced stack 0 by rule 1 (line 27); action deferred. Now in state 2. Merging stack 0 into stack 1. Stack 1 Entering state 2 Now at end of input. Removing dead stacks. Rename stack 1 -> 0. On stack 0, shifting token "end of file" () Stack 0 now in state 5 Ambiguity detected. Option 1, start -> 'a' b 'c' d Option 2, start -> 'a' b 'c' d syntax is ambiguous Cleanup: popping token "end of file" () Cleanup: popping unresolved nterm start () Cleanup: popping nterm d () Cleanup: popping token 'c' () Cleanup: popping nterm b () Cleanup: popping token 'a' () ./glr-regression.at:2151: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 773. glr-regression.at:2151: ok stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./glr-regression.at:2231: $PREPARSER ./input Nwin stderr: ./glr-regression.at:2231: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2231: $PREPARSER ./input Owin stderr: syntax error, unexpected 'n', expecting 'o' ./glr-regression.at:2231: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2231: $PREPARSER ./input Owio stderr: ./glr-regression.at:2231: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2231: $PREPARSER ./input Nwio stderr: syntax error, unexpected 'o', expecting 'n' ./glr-regression.at:2231: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 776. glr-regression.at:2231: ok stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:860: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:860: $PREPARSER ./input stderr: ./c++.at:860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 679. c++.at:854: ok ## ------------- ## ## Test results. ## ## ------------- ## 712 tests were successful. 64 tests were skipped. make[4]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[2]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' create-stamp debian/debhelper-build-stamp dh_prep dh_auto_install make -j12 install DESTDIR=/build/reproducible-path/bison-3.8.2\+dfsg/debian/tmp AM_UPDATE_INFO_DIR=no make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' make install-recursive make[2]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' Making install in po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/po' installing bg.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/bg/LC_MESSAGES/bison.mo installing ca.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ca/LC_MESSAGES/bison.mo installing da.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/da/LC_MESSAGES/bison.mo installing de.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/de/LC_MESSAGES/bison.mo installing el.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/el/LC_MESSAGES/bison.mo installing eo.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/eo/LC_MESSAGES/bison.mo installing es.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/es/LC_MESSAGES/bison.mo installing et.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/et/LC_MESSAGES/bison.mo installing fi.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/fi/LC_MESSAGES/bison.mo installing fr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/fr/LC_MESSAGES/bison.mo installing ga.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ga/LC_MESSAGES/bison.mo installing hr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/hr/LC_MESSAGES/bison.mo installing id.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/id/LC_MESSAGES/bison.mo installing it.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/it/LC_MESSAGES/bison.mo installing ja.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ja/LC_MESSAGES/bison.mo installing ms.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ms/LC_MESSAGES/bison.mo installing nb.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/nb/LC_MESSAGES/bison.mo installing nl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/nl/LC_MESSAGES/bison.mo installing pl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pl/LC_MESSAGES/bison.mo installing pt.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pt/LC_MESSAGES/bison.mo installing pt_BR.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pt_BR/LC_MESSAGES/bison.mo installing ro.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ro/LC_MESSAGES/bison.mo installing ru.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ru/LC_MESSAGES/bison.mo installing sr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sr/LC_MESSAGES/bison.mo installing sv.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sv/LC_MESSAGES/bison.mo installing tr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/tr/LC_MESSAGES/bison.mo installing uk.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/uk/LC_MESSAGES/bison.mo installing vi.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/vi/LC_MESSAGES/bison.mo installing zh_CN.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/zh_CN/LC_MESSAGES/bison.mo installing zh_TW.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/zh_TW/LC_MESSAGES/bison.mo if test "bison" = "gettext-tools"; then \ /usr/bin/mkdir -p /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po; \ for file in Makefile.in.in remove-potcdate.sin quot.sed boldquot.sed en@quot.header en@boldquot.header insert-header.sin Rules-quot Makevars.template; do \ /usr/bin/install -c -m 644 ./$file \ /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po/$file; \ done; \ for file in Makevars; do \ rm -f /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po/$file; \ done; \ else \ : ; \ fi make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/po' Making install in runtime-po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' installing ast.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ast/LC_MESSAGES/bison-runtime.mo installing bg.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/bg/LC_MESSAGES/bison-runtime.mo installing ca.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ca/LC_MESSAGES/bison-runtime.mo installing da.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/da/LC_MESSAGES/bison-runtime.mo installing de.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/de/LC_MESSAGES/bison-runtime.mo installing el.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/el/LC_MESSAGES/bison-runtime.mo installing eo.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/eo/LC_MESSAGES/bison-runtime.mo installing es.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/es/LC_MESSAGES/bison-runtime.mo installing et.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/et/LC_MESSAGES/bison-runtime.mo installing fi.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/fi/LC_MESSAGES/bison-runtime.mo installing fr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/fr/LC_MESSAGES/bison-runtime.mo installing ga.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ga/LC_MESSAGES/bison-runtime.mo installing gl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/gl/LC_MESSAGES/bison-runtime.mo installing hr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/hr/LC_MESSAGES/bison-runtime.mo installing hu.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/hu/LC_MESSAGES/bison-runtime.mo installing ia.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ia/LC_MESSAGES/bison-runtime.mo installing id.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/id/LC_MESSAGES/bison-runtime.mo installing it.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/it/LC_MESSAGES/bison-runtime.mo installing ja.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ja/LC_MESSAGES/bison-runtime.mo installing ky.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ky/LC_MESSAGES/bison-runtime.mo installing lt.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/lt/LC_MESSAGES/bison-runtime.mo installing lv.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/lv/LC_MESSAGES/bison-runtime.mo installing ms.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ms/LC_MESSAGES/bison-runtime.mo installing nb.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/nb/LC_MESSAGES/bison-runtime.mo installing nl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/nl/LC_MESSAGES/bison-runtime.mo installing pl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pl/LC_MESSAGES/bison-runtime.mo installing pt.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pt/LC_MESSAGES/bison-runtime.mo installing pt_BR.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pt_BR/LC_MESSAGES/bison-runtime.mo installing ro.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ro/LC_MESSAGES/bison-runtime.mo installing ru.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ru/LC_MESSAGES/bison-runtime.mo installing sl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sl/LC_MESSAGES/bison-runtime.mo installing sq.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sq/LC_MESSAGES/bison-runtime.mo installing sr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sr/LC_MESSAGES/bison-runtime.mo installing sv.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sv/LC_MESSAGES/bison-runtime.mo installing ta.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ta/LC_MESSAGES/bison-runtime.mo installing th.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/th/LC_MESSAGES/bison-runtime.mo installing tr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/tr/LC_MESSAGES/bison-runtime.mo installing uk.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/uk/LC_MESSAGES/bison-runtime.mo installing vi.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/vi/LC_MESSAGES/bison-runtime.mo installing zh_CN.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/zh_CN/LC_MESSAGES/bison-runtime.mo installing zh_TW.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/zh_TW/LC_MESSAGES/bison-runtime.mo if test "bison" = "gettext-tools"; then \ /usr/bin/mkdir -p /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po; \ for file in Makefile.in.in remove-potcdate.sin quot.sed boldquot.sed en@quot.header en@boldquot.header insert-header.sin Rules-quot Makevars.template; do \ /usr/bin/install -c -m 644 ./$file \ /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po/$file; \ done; \ for file in Makevars; do \ rm -f /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po/$file; \ done; \ else \ : ; \ fi make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/runtime-po' Making install in gnulib-po make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' installing af.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/af/LC_MESSAGES/bison-gnulib.mo installing be.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/be/LC_MESSAGES/bison-gnulib.mo installing bg.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/bg/LC_MESSAGES/bison-gnulib.mo installing ca.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ca/LC_MESSAGES/bison-gnulib.mo installing cs.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/cs/LC_MESSAGES/bison-gnulib.mo installing da.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/da/LC_MESSAGES/bison-gnulib.mo installing de.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/de/LC_MESSAGES/bison-gnulib.mo installing el.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/el/LC_MESSAGES/bison-gnulib.mo installing eo.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/eo/LC_MESSAGES/bison-gnulib.mo installing es.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/es/LC_MESSAGES/bison-gnulib.mo installing et.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/et/LC_MESSAGES/bison-gnulib.mo installing eu.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/eu/LC_MESSAGES/bison-gnulib.mo installing fi.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/fi/LC_MESSAGES/bison-gnulib.mo installing fr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/fr/LC_MESSAGES/bison-gnulib.mo installing ga.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ga/LC_MESSAGES/bison-gnulib.mo installing gl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/gl/LC_MESSAGES/bison-gnulib.mo installing hu.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/hu/LC_MESSAGES/bison-gnulib.mo installing it.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/it/LC_MESSAGES/bison-gnulib.mo installing ja.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ja/LC_MESSAGES/bison-gnulib.mo installing ko.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ko/LC_MESSAGES/bison-gnulib.mo installing ms.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ms/LC_MESSAGES/bison-gnulib.mo installing nb.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/nb/LC_MESSAGES/bison-gnulib.mo installing nl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/nl/LC_MESSAGES/bison-gnulib.mo installing pl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pl/LC_MESSAGES/bison-gnulib.mo installing pt.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pt/LC_MESSAGES/bison-gnulib.mo installing pt_BR.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/pt_BR/LC_MESSAGES/bison-gnulib.mo installing ro.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ro/LC_MESSAGES/bison-gnulib.mo installing ru.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/ru/LC_MESSAGES/bison-gnulib.mo installing rw.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/rw/LC_MESSAGES/bison-gnulib.mo installing sk.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sk/LC_MESSAGES/bison-gnulib.mo installing sl.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sl/LC_MESSAGES/bison-gnulib.mo installing sr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sr/LC_MESSAGES/bison-gnulib.mo installing sv.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/sv/LC_MESSAGES/bison-gnulib.mo installing tr.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/tr/LC_MESSAGES/bison-gnulib.mo installing uk.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/uk/LC_MESSAGES/bison-gnulib.mo installing vi.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/vi/LC_MESSAGES/bison-gnulib.mo installing zh_CN.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/zh_CN/LC_MESSAGES/bison-gnulib.mo installing zh_TW.gmo as /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/locale/zh_TW/LC_MESSAGES/bison-gnulib.mo if test "bison" = "gettext-tools"; then \ /usr/bin/mkdir -p /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po; \ for file in Makefile.in.in remove-potcdate.sin quot.sed boldquot.sed en@quot.header en@boldquot.header insert-header.sin Rules-quot Makevars.template; do \ /usr/bin/install -c -m 644 ./$file \ /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po/$file; \ done; \ for file in Makevars; do \ rm -f /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/gettext/po/$file; \ done; \ else \ : ; \ fi make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' Making install in . make[3]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' /usr/bin/mkdir -p doc LC_ALL=C tests/bison --version >doc/bison.help.tmp LC_ALL=C tests/bison --help | \ sed -e 's,^Usage: .*/bison \[OPTION\],Usage: bison [OPTION],g' \ -e '/translation bugs/d' >>doc/bison.help.tmp ./build-aux/move-if-change doc/bison.help.tmp doc/bison.help make[4]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/lib/aarch64-linux-gnu' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin' /usr/bin/install -c -m 644 lib/liby.a '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/lib/aarch64-linux-gnu' /usr/bin/install -c src/bison '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/aclocal' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++/calc++' /usr/bin/install -c src/yacc '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++' ( cd '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/lib/aarch64-linux-gnu' && ranlib liby.a ) /usr/bin/install -c -m 644 m4/bison-i18n.m4 '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/aclocal' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/bistromathic' /usr/bin/install -c -m 644 examples/c++/simple.yy '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++' /usr/bin/install -c -m 644 examples/c++/calc++/driver.cc examples/c++/calc++/driver.hh examples/c++/calc++/scanner.ll examples/c++/calc++/calc++.cc examples/c++/calc++/parser.yy '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++/calc++' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/calc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d/calc' /usr/bin/install -c -m 644 examples/c/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++/calc++' /usr/bin/install -c -m 644 examples/c/bistromathic/parse.y examples/c/bistromathic/Makefile examples/c/bistromathic/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/bistromathic' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++' /usr/bin/install -c -m 644 examples/c/calc/calc.y examples/c/calc/Makefile examples/c/calc/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/calc' /usr/bin/install -c -m 644 examples/c++/README.md examples/c++/Makefile examples/c++/variant.yy examples/c++/variant-11.yy '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d' /usr/bin/install -c -m 644 examples/c++/calc++/README.md examples/c++/calc++/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++/calc++' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison' /usr/bin/install -c -m 644 examples/d/calc/calc.y examples/d/calc/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d/calc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/glr' /usr/bin/install -c -m 644 examples/d/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java' /usr/bin/install -c -m 644 examples/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java/calc' /usr/bin/install -c -m 644 AUTHORS COPYING NEWS README THANKS TODO '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java/simple' /usr/bin/install -c -m 644 examples/c/glr/c++-types.y examples/c/glr/Makefile examples/c/glr/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/glr' /usr/bin/install -c -m 644 examples/java/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/lexcalc' /usr/bin/install -c -m 644 examples/java/calc/Calc.y examples/java/calc/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java/calc' /usr/bin/install -c -m 644 examples/java/simple/Calc.y examples/java/simple/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java/simple' /usr/bin/install -c -m 644 examples/c/lexcalc/parse.y examples/c/lexcalc/scan.l examples/c/lexcalc/Makefile examples/c/lexcalc/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/lexcalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/m4sugar' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/mfcalc' /usr/bin/install -c -m 644 data/m4sugar/foreach.m4 data/m4sugar/m4sugar.m4 '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/m4sugar' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/pushcalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/reccalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/rpcalc' /usr/bin/install -c -m 644 examples/c/mfcalc/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/mfcalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d/simple' /usr/bin/install -c -m 644 examples/c/pushcalc/calc.y examples/c/pushcalc/Makefile examples/c/pushcalc/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/pushcalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/skeletons' /usr/bin/install -c -m 644 data/README.md data/bison-default.css '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison' /usr/bin/install -c -m 644 examples/d/simple/calc.y examples/d/simple/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d/simple' /usr/bin/install -c -m 644 examples/c/reccalc/parse.y examples/c/reccalc/scan.l examples/c/reccalc/Makefile examples/c/reccalc/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/reccalc' /usr/bin/mkdir -p doc /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/xslt' /usr/bin/install -c -m 644 examples/c/rpcalc/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/rpcalc' LC_ALL=C tests/bison --version >doc/bison.help.tmp /usr/bin/install -c -m 644 data/xslt/bison.xsl data/xslt/xml2dot.xsl data/xslt/xml2text.xsl data/xslt/xml2xhtml.xsl '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/xslt' /usr/bin/install -c -m 644 data/skeletons/bison.m4 data/skeletons/c++-skel.m4 data/skeletons/c++.m4 data/skeletons/c-like.m4 data/skeletons/c-skel.m4 data/skeletons/c.m4 data/skeletons/glr.c data/skeletons/glr.cc data/skeletons/glr2.cc data/skeletons/java-skel.m4 data/skeletons/java.m4 data/skeletons/lalr1.cc data/skeletons/lalr1.java data/skeletons/location.cc data/skeletons/stack.hh data/skeletons/traceon.m4 data/skeletons/variant.hh data/skeletons/yacc.c data/skeletons/d-skel.m4 data/skeletons/d.m4 data/skeletons/lalr1.d '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/skeletons' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/mfcalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/rpcalc' LC_ALL=C tests/bison --help | \ sed -e 's,^Usage: .*/bison \[OPTION\],Usage: bison [OPTION],g' \ -e '/translation bugs/d' >>doc/bison.help.tmp /usr/bin/install -c -m 644 examples/c/rpcalc/rpcalc.y '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/rpcalc' /usr/bin/install -c -m 644 examples/c/mfcalc/calc.h examples/c/mfcalc/mfcalc.y '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/mfcalc' ./build-aux/move-if-change doc/bison.help.tmp doc/bison.help /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/man/man1' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/info' /usr/bin/install -c -m 644 ./doc/bison.1 doc/yacc.1 '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/man/man1' /usr/bin/install -c -m 644 ./doc/bison.info '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/info' make[4]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[3]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[2]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' debian/rules execute_after_dh_auto_install make[1]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' rm -f -R /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/info/ mv /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin/yacc /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin/bison.yacc mv /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/man/man1/yacc.1 \ /build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/man/man1/bison.yacc.1 make[1]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' dh_install dh_installdocs dh_installchangelogs dh_installexamples dh_installman dh_lintian dh_perl dh_link dh_strip_nondeterminism Garbage at end of string in strptime: +02:00 at /usr/lib/aarch64-linux-gnu/perl/5.40/Time/Piece.pm line 598. Normalized debian/bison/usr/share/locale/zh_TW/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/zh_TW/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/zh_TW/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/zh_CN/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/zh_CN/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/zh_CN/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/vi/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/vi/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/vi/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/uk/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ms/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ms/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/lv/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/lt/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ky/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ko/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ja/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ja/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ja/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/it/LC_MESSAGES/bison-gnulib.mo Perhaps a format flag did not match the actual input? at /usr/lib/aarch64-linux-gnu/perl/5.40/Time/Piece.pm line 598. Normalized debian/bison/usr/share/locale/sr/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/sr/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/sr/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/sq/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/sl/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/sl/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/sk/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/rw/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ru/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ru/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/pl/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/pl/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/pl/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/nl/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/nl/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/nl/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/nb/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/nb/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/nb/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/ms/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ca/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ca/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ca/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/bg/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/bg/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/bg/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/be/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ast/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/af/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/gl/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ga/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ga/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ga/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/fr/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/fr/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/fr/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/fi/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/fi/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/fi/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/uk/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/uk/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/tr/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/tr/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/tr/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/th/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ta/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/sv/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/sv/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/sv/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/ru/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/ro/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ro/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ro/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/pt_BR/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/pt_BR/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/pt_BR/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/pt/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/pt/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/pt/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/eu/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/et/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/et/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/et/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/es/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/es/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/es/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/eo/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/eo/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/eo/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/it/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/it/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/id/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/id/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/ia/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/hu/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/hu/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/hr/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/hr/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/gl/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/el/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/el/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/el/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/de/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/de/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/de/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/da/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/da/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/da/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/cs/LC_MESSAGES/bison-gnulib.mo dh_compress dh_fixperms dh_missing dh_dwz dh_strip dh_makeshlibs dh_shlibdeps dpkg-shlibdeps: warning: diversions involved - output may be incorrect diversion by libc6 from: /lib/ld-linux-aarch64.so.1 dpkg-shlibdeps: warning: diversions involved - output may be incorrect diversion by libc6 to: /lib/ld-linux-aarch64.so.1.usr-is-merged dh_installdeb dh_gencontrol dh_md5sums dh_builddeb dpkg-deb: building package 'libbison-dev' in '../libbison-dev_3.8.2+dfsg-1_arm64.deb'. dpkg-deb: building package 'bison-dbgsym' in '../bison-dbgsym_3.8.2+dfsg-1_arm64.deb'. dpkg-deb: building package 'bison' in '../bison_3.8.2+dfsg-1_arm64.deb'. dpkg-genbuildinfo --build=binary -O../bison_3.8.2+dfsg-1_arm64.buildinfo dpkg-genchanges --build=binary -O../bison_3.8.2+dfsg-1_arm64.changes dpkg-genchanges: info: binary-only upload (no source code included) dpkg-source --after-build . dpkg-buildpackage: info: binary-only upload (no source included) dpkg-genchanges: info: including full source code in upload I: copying local configuration I: user script /srv/workspace/pbuilder/900897/tmp/hooks/B01_cleanup starting I: user script /srv/workspace/pbuilder/900897/tmp/hooks/B01_cleanup finished I: unmounting dev/ptmx filesystem I: unmounting dev/pts filesystem I: unmounting dev/shm filesystem I: unmounting proc filesystem I: unmounting sys filesystem I: cleaning the build env I: removing directory /srv/workspace/pbuilder/900897 and its subdirectories I: Current time: Sun Feb 23 02:32:00 +14 2025 I: pbuilder-time-stamp: 1740227520 + false + set +x Sat Feb 22 12:32:00 UTC 2025 I: Signing ./b2/bison_3.8.2+dfsg-1_arm64.buildinfo as bison_3.8.2+dfsg-1_arm64.buildinfo.asc Sat Feb 22 12:32:00 UTC 2025 I: Signed ./b2/bison_3.8.2+dfsg-1_arm64.buildinfo as ./b2/bison_3.8.2+dfsg-1_arm64.buildinfo.asc Sat Feb 22 12:32:00 UTC 2025 - build #2 for bison/trixie/arm64 on codethink04-arm64 done. Starting cleanup. All cleanup done. Sat Feb 22 12:32:00 UTC 2025 - reproducible_build.sh stopped running as /tmp/jenkins-script-3evhjfDU, removing. /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe: total 7896 drwxr-xr-x 2 jenkins jenkins 4096 Feb 22 12:23 b1 drwxr-xr-x 2 jenkins jenkins 4096 Feb 22 12:32 b2 -rw-r--r-- 1 jenkins jenkins 1855 Oct 3 2021 bison_3.8.2+dfsg-1.dsc -rw------- 1 jenkins jenkins 8057841 Feb 22 12:23 rbuildlog.DsrGmeZ /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/b1: total 13052 -rw-r--r-- 1 jenkins jenkins 753140 Feb 22 12:23 bison-dbgsym_3.8.2+dfsg-1_arm64.deb -rw-r--r-- 1 jenkins jenkins 11164 Feb 22 12:23 bison_3.8.2+dfsg-1.debian.tar.xz -rw-r--r-- 1 jenkins jenkins 1855 Feb 22 12:23 bison_3.8.2+dfsg-1.dsc -rw-r--r-- 1 jenkins jenkins 5238 Feb 22 12:23 bison_3.8.2+dfsg-1_arm64.buildinfo -rw-r--r-- 1 jenkins jenkins 6120 Feb 22 12:23 bison_3.8.2+dfsg-1_arm64.buildinfo.asc -rw-r--r-- 1 jenkins jenkins 1667 Feb 22 12:23 bison_3.8.2+dfsg-1_arm64.changes -rw-r--r-- 1 jenkins jenkins 1150004 Feb 22 12:23 bison_3.8.2+dfsg-1_arm64.deb -rw-r--r-- 1 jenkins jenkins 1437 Feb 22 12:23 bison_3.8.2+dfsg-1_source.changes -rw-r--r-- 1 jenkins jenkins 2654920 Feb 22 12:23 bison_3.8.2+dfsg.orig.tar.xz -rw-r--r-- 1 jenkins jenkins 8054565 Feb 22 12:23 build.log -rw-r--r-- 1 jenkins jenkins 671932 Feb 22 12:23 libbison-dev_3.8.2+dfsg-1_arm64.deb /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/b2: total 13024 -rw-r--r-- 1 jenkins jenkins 753140 Feb 22 12:32 bison-dbgsym_3.8.2+dfsg-1_arm64.deb -rw-r--r-- 1 jenkins jenkins 11164 Feb 22 12:32 bison_3.8.2+dfsg-1.debian.tar.xz -rw-r--r-- 1 jenkins jenkins 1855 Feb 22 12:32 bison_3.8.2+dfsg-1.dsc -rw-r--r-- 1 jenkins jenkins 5238 Feb 22 12:32 bison_3.8.2+dfsg-1_arm64.buildinfo -rw-r--r-- 1 jenkins jenkins 6120 Feb 22 12:32 bison_3.8.2+dfsg-1_arm64.buildinfo.asc -rw-r--r-- 1 jenkins jenkins 1667 Feb 22 12:32 bison_3.8.2+dfsg-1_arm64.changes -rw-r--r-- 1 jenkins jenkins 1150004 Feb 22 12:32 bison_3.8.2+dfsg-1_arm64.deb -rw-r--r-- 1 jenkins jenkins 1437 Feb 22 12:32 bison_3.8.2+dfsg-1_source.changes -rw-r--r-- 1 jenkins jenkins 2654920 Feb 22 12:32 bison_3.8.2+dfsg.orig.tar.xz -rw-r--r-- 1 jenkins jenkins 8056455 Feb 22 12:32 build.log -rw-r--r-- 1 jenkins jenkins 671932 Feb 22 12:32 libbison-dev_3.8.2+dfsg-1_arm64.deb Sat Feb 22 12:32:02 UTC 2025 I: Deleting $TMPDIR on codethink04-arm64.debian.net. Sat Feb 22 12:32:03 UTC 2025 I: bison_3.8.2+dfsg-1_arm64.changes: Format: 1.8 Date: Sat, 02 Oct 2021 16:25:58 -0700 Source: bison Binary: bison bison-dbgsym libbison-dev Architecture: arm64 Version: 2:3.8.2+dfsg-1 Distribution: unstable Urgency: medium Maintainer: Chuan-kai Lin Changed-By: Chuan-kai Lin Description: bison - YACC-compatible parser generator libbison-dev - YACC-compatible parser generator - development library Changes: bison (2:3.8.2+dfsg-1) unstable; urgency=medium . * New upstream version 3.8.2+dfsg Checksums-Sha1: 0f515218c63c79ea0073ad50e204235e5f21a963 753140 bison-dbgsym_3.8.2+dfsg-1_arm64.deb 221f922858c43c9e1cf4807d825d771ed2aa5e64 5238 bison_3.8.2+dfsg-1_arm64.buildinfo ffbe5c0b719970d7c140cbf3f0e20caef934b756 1150004 bison_3.8.2+dfsg-1_arm64.deb 4f1f092073089ccb50ee58c5c76d454e574a123f 671932 libbison-dev_3.8.2+dfsg-1_arm64.deb Checksums-Sha256: 4000536b810e11f6c105c9ccb7f708b30cf96720481fc09c9585026db8f01afd 753140 bison-dbgsym_3.8.2+dfsg-1_arm64.deb d5f9eef7c721507dfc364c6e4f23eb004ed67ae5923aa1dffb5ae10103286a53 5238 bison_3.8.2+dfsg-1_arm64.buildinfo 797e174dc8970ccb48afc773814a1355c02716c09d82e342a7f1fdb80cb2b429 1150004 bison_3.8.2+dfsg-1_arm64.deb f3c9de9bad7e33833007d4a7af9797ecf9c02838944a62d82606f2bcd51eab0d 671932 libbison-dev_3.8.2+dfsg-1_arm64.deb Files: baf55e5c8f3131b735b7604005262770 753140 debug optional bison-dbgsym_3.8.2+dfsg-1_arm64.deb b866c2c9a095bb5c9770f6d9bb81099f 5238 devel optional bison_3.8.2+dfsg-1_arm64.buildinfo f4184f423f74ba65e91cd8e96c3426a6 1150004 devel optional bison_3.8.2+dfsg-1_arm64.deb ae25865e2baa00159963798bb20f3670 671932 libdevel optional libbison-dev_3.8.2+dfsg-1_arm64.deb removed '/var/lib/jenkins/userContent/reproducible/debian/rbuild/trixie/arm64/bison_3.8.2+dfsg-1.rbuild.log' removed '/var/lib/jenkins/userContent/reproducible/debian/rbuild/trixie/arm64/bison_3.8.2+dfsg-1.rbuild.log.gz' removed '/var/lib/jenkins/userContent/reproducible/debian/logs/trixie/arm64/bison_3.8.2+dfsg-1.build1.log.gz' removed '/var/lib/jenkins/userContent/reproducible/debian/logs/trixie/arm64/bison_3.8.2+dfsg-1.build2.log.gz' removed '/var/lib/jenkins/userContent/reproducible/debian/buildinfo/trixie/arm64/bison_3.8.2+dfsg-1_arm64.buildinfo' removed '/var/lib/jenkins/userContent/reproducible/debian/logdiffs/trixie/arm64/bison_3.8.2+dfsg-1.diff.gz' Diff of the two buildlogs: -- --- b1/build.log 2025-02-22 12:23:46.301562064 +0000 +++ b2/build.log 2025-02-22 12:32:02.359115577 +0000 @@ -1,6 +1,6 @@ I: pbuilder: network access will be disabled during build -I: Current time: Fri Mar 27 06:39:53 -12 2026 -I: pbuilder-time-stamp: 1774636793 +I: Current time: Sun Feb 23 02:23:49 +14 2025 +I: pbuilder-time-stamp: 1740227029 I: Building the build Environment I: extracting base tarball [/var/cache/pbuilder/trixie-reproducible-base.tgz] I: copying local configuration @@ -25,52 +25,84 @@ dpkg-source: info: applying 02_parse_h_dependency I: using fakeroot in build. I: Installing the build-deps -I: user script /srv/workspace/pbuilder/1898584/tmp/hooks/D02_print_environment starting +I: user script /srv/workspace/pbuilder/900897/tmp/hooks/D01_modify_environment starting +debug: Running on codethink04-arm64. +I: Changing host+domainname to test build reproducibility +I: Adding a custom variable just for the fun of it... +I: Changing /bin/sh to bash +'/bin/sh' -> '/bin/bash' +lrwxrwxrwx 1 root root 9 Feb 22 12:23 /bin/sh -> /bin/bash +I: Setting pbuilder2's login shell to /bin/bash +I: Setting pbuilder2's GECOS to second user,second room,second work-phone,second home-phone,second other +I: user script /srv/workspace/pbuilder/900897/tmp/hooks/D01_modify_environment finished +I: user script /srv/workspace/pbuilder/900897/tmp/hooks/D02_print_environment starting I: set - BUILDDIR='/build/reproducible-path' - BUILDUSERGECOS='first user,first room,first work-phone,first home-phone,first other' - BUILDUSERNAME='pbuilder1' - BUILD_ARCH='arm64' - DEBIAN_FRONTEND='noninteractive' + BASH=/bin/sh + BASHOPTS=checkwinsize:cmdhist:complete_fullquote:extquote:force_fignore:globasciiranges:globskipdots:hostcomplete:interactive_comments:patsub_replacement:progcomp:promptvars:sourcepath + BASH_ALIASES=() + BASH_ARGC=() + BASH_ARGV=() + BASH_CMDS=() + BASH_LINENO=([0]="12" [1]="0") + BASH_LOADABLES_PATH=/usr/local/lib/bash:/usr/lib/bash:/opt/local/lib/bash:/usr/pkg/lib/bash:/opt/pkg/lib/bash:. + BASH_SOURCE=([0]="/tmp/hooks/D02_print_environment" [1]="/tmp/hooks/D02_print_environment") + BASH_VERSINFO=([0]="5" [1]="2" [2]="37" [3]="1" [4]="release" [5]="aarch64-unknown-linux-gnu") + BASH_VERSION='5.2.37(1)-release' + BUILDDIR=/build/reproducible-path + BUILDUSERGECOS='second user,second room,second work-phone,second home-phone,second other' + BUILDUSERNAME=pbuilder2 + BUILD_ARCH=arm64 + DEBIAN_FRONTEND=noninteractive DEB_BUILD_OPTIONS='buildinfo=+all reproducible=+all parallel=12 ' - DISTRIBUTION='trixie' - HOME='/root' - HOST_ARCH='arm64' + DIRSTACK=() + DISTRIBUTION=trixie + EUID=0 + FUNCNAME=([0]="Echo" [1]="main") + GROUPS=() + HOME=/root + HOSTNAME=i-capture-the-hostname + HOSTTYPE=aarch64 + HOST_ARCH=arm64 IFS=' ' - INVOCATION_ID='d67e741296294416be8d489ee5f26057' - LANG='C' - LANGUAGE='en_US:en' - LC_ALL='C' - MAIL='/var/mail/root' - OPTIND='1' - PATH='/usr/sbin:/usr/bin:/sbin:/bin:/usr/games' - PBCURRENTCOMMANDLINEOPERATION='build' - PBUILDER_OPERATION='build' - PBUILDER_PKGDATADIR='/usr/share/pbuilder' - PBUILDER_PKGLIBDIR='/usr/lib/pbuilder' - PBUILDER_SYSCONFDIR='/etc' - PPID='1898584' - PS1='# ' - PS2='> ' + INVOCATION_ID=9ab0a127dcc04df38166a67ffb8e70a7 + LANG=C + LANGUAGE=nl_BE:nl + LC_ALL=C + MACHTYPE=aarch64-unknown-linux-gnu + MAIL=/var/mail/root + OPTERR=1 + OPTIND=1 + OSTYPE=linux-gnu + PATH=/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/i/capture/the/path + PBCURRENTCOMMANDLINEOPERATION=build + PBUILDER_OPERATION=build + PBUILDER_PKGDATADIR=/usr/share/pbuilder + PBUILDER_PKGLIBDIR=/usr/lib/pbuilder + PBUILDER_SYSCONFDIR=/etc + PIPESTATUS=([0]="0") + POSIXLY_CORRECT=y + PPID=900897 PS4='+ ' - PWD='/' - SHELL='/bin/bash' - SHLVL='2' - SUDO_COMMAND='/usr/bin/timeout -k 18.1h 18h /usr/bin/ionice -c 3 /usr/bin/nice /usr/sbin/pbuilder --build --configfile /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/pbuilderrc_ucqW --distribution trixie --hookdir /etc/pbuilder/first-build-hooks --debbuildopts -b --basetgz /var/cache/pbuilder/trixie-reproducible-base.tgz --buildresult /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/b1 --logfile b1/build.log bison_3.8.2+dfsg-1.dsc' - SUDO_GID='109' - SUDO_UID='104' - SUDO_USER='jenkins' - TERM='unknown' - TZ='/usr/share/zoneinfo/Etc/GMT+12' - USER='root' - _='/usr/bin/systemd-run' - http_proxy='http://192.168.101.4:3128' + PWD=/ + SHELL=/bin/bash + SHELLOPTS=braceexpand:errexit:hashall:interactive-comments:posix + SHLVL=3 + SUDO_COMMAND='/usr/bin/timeout -k 24.1h 24h /usr/bin/ionice -c 3 /usr/bin/nice -n 11 /usr/bin/unshare --uts -- /usr/sbin/pbuilder --build --configfile /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/pbuilderrc_u001 --distribution trixie --hookdir /etc/pbuilder/rebuild-hooks --debbuildopts -b --basetgz /var/cache/pbuilder/trixie-reproducible-base.tgz --buildresult /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/b2 --logfile b2/build.log bison_3.8.2+dfsg-1.dsc' + SUDO_GID=109 + SUDO_UID=104 + SUDO_USER=jenkins + TERM=unknown + TZ=/usr/share/zoneinfo/Etc/GMT-14 + UID=0 + USER=root + _='I: set' + http_proxy=http://192.168.101.4:3128 I: uname -a - Linux codethink03-arm64 6.1.0-31-cloud-arm64 #1 SMP Debian 6.1.128-1 (2025-02-07) aarch64 GNU/Linux + Linux i-capture-the-hostname 6.1.0-31-cloud-arm64 #1 SMP Debian 6.1.128-1 (2025-02-07) aarch64 GNU/Linux I: ls -l /bin - lrwxrwxrwx 1 root root 7 Nov 22 2024 /bin -> usr/bin -I: user script /srv/workspace/pbuilder/1898584/tmp/hooks/D02_print_environment finished + lrwxrwxrwx 1 root root 7 Nov 22 14:40 /bin -> usr/bin +I: user script /srv/workspace/pbuilder/900897/tmp/hooks/D02_print_environment finished -> Attempting to satisfy build-dependencies -> Creating pbuilder-satisfydepends-dummy package Package: pbuilder-satisfydepends-dummy @@ -83,7 +115,7 @@ Depends: debhelper-compat (= 12), gettext, flex, m4 (>= 1.4-14), help2man dpkg-deb: building package 'pbuilder-satisfydepends-dummy' in '/tmp/satisfydepends-aptitude/pbuilder-satisfydepends-dummy.deb'. Selecting previously unselected package pbuilder-satisfydepends-dummy. -(Reading database ... 19922 files and directories currently installed.) +(Reading database ... 19972 files and directories currently installed.) Preparing to unpack .../pbuilder-satisfydepends-dummy.deb ... Unpacking pbuilder-satisfydepends-dummy (0.invalid.0) ... dpkg: pbuilder-satisfydepends-dummy: dependency problems, but configuring anyway as you requested: @@ -147,10 +179,10 @@ Get: 31 http://deb.debian.org/debian trixie/main arm64 po-debconf all 1.0.21+nmu1 [248 kB] Get: 32 http://deb.debian.org/debian trixie/main arm64 debhelper all 13.24.1 [920 kB] Get: 33 http://deb.debian.org/debian trixie/main arm64 help2man arm64 1.49.3+b1 [198 kB] -Fetched 20.7 MB in 0s (140 MB/s) +Fetched 20.7 MB in 0s (120 MB/s) Preconfiguring packages ... Selecting previously unselected package m4. -(Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 19922 files and directories currently installed.) +(Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 19972 files and directories currently installed.) Preparing to unpack .../00-m4_1.4.19-5_arm64.deb ... Unpacking m4 (1.4.19-5) ... Selecting previously unselected package flex. @@ -299,7 +331,11 @@ fakeroot is already the newest version (1.37-1). 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. I: Building the package -I: Running cd /build/reproducible-path/bison-3.8.2+dfsg/ && env PATH="/usr/sbin:/usr/bin:/sbin:/bin:/usr/games" HOME="/nonexistent/first-build" dpkg-buildpackage -us -uc -b && env PATH="/usr/sbin:/usr/bin:/sbin:/bin:/usr/games" HOME="/nonexistent/first-build" dpkg-genchanges -S > ../bison_3.8.2+dfsg-1_source.changes +I: user script /srv/workspace/pbuilder/900897/tmp/hooks/A99_set_merged_usr starting +Not re-configuring usrmerge for trixie +I: user script /srv/workspace/pbuilder/900897/tmp/hooks/A99_set_merged_usr finished +hostname: Name or service not known +I: Running cd /build/reproducible-path/bison-3.8.2+dfsg/ && env PATH="/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/i/capture/the/path" HOME="/nonexistent/second-build" dpkg-buildpackage -us -uc -b && env PATH="/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/i/capture/the/path" HOME="/nonexistent/second-build" dpkg-genchanges -S > ../bison_3.8.2+dfsg-1_source.changes dpkg-buildpackage: info: source package bison dpkg-buildpackage: info: source version 2:3.8.2+dfsg-1 dpkg-buildpackage: info: source distribution unstable @@ -955,7 +991,6 @@ } | sed '/""/d' > lib/configmake.h-t && \ mv -f lib/configmake.h-t lib/configmake.h touch examples/c/reccalc/scan.stamp.tmp -flex -oexamples/c/reccalc/scan.c --header=examples/c/reccalc/scan.h ./examples/c/reccalc/scan.l rm -f lib/fcntl.h-t lib/fcntl.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ @@ -982,6 +1017,7 @@ < ./lib/fcntl.in.h; \ } > lib/fcntl.h-t && \ mv lib/fcntl.h-t lib/fcntl.h +flex -oexamples/c/reccalc/scan.c --header=examples/c/reccalc/scan.h ./examples/c/reccalc/scan.l rm -f lib/iconv.h-t lib/iconv.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ @@ -1030,7 +1066,6 @@ < ./lib/inttypes.in.h; \ } > lib/inttypes.h-t && \ mv lib/inttypes.h-t lib/inttypes.h -mv examples/c/reccalc/scan.stamp.tmp examples/c/reccalc/scan.stamp rm -f lib/textstyle.h-t lib/textstyle.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ cat ./lib/textstyle.in.h; \ @@ -1046,6 +1081,7 @@ < ./lib/limits.in.h; \ } > lib/limits.h-t && \ mv lib/limits.h-t lib/limits.h +mv examples/c/reccalc/scan.stamp.tmp examples/c/reccalc/scan.stamp rm -f lib/locale.h-t lib/locale.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ @@ -1386,6 +1422,15 @@ } > lib/sched.h-t && \ mv lib/sched.h-t lib/sched.h /usr/bin/mkdir -p lib/malloc +rm -f lib/malloc/scratch_buffer.gl.h-t lib/malloc/scratch_buffer.gl.h && \ +{ echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ + sed -e 's|__always_inline|inline _GL_ATTRIBUTE_ALWAYS_INLINE|g' \ + -e 's|__glibc_likely|_GL_LIKELY|g' \ + -e 's|__glibc_unlikely|_GL_UNLIKELY|g' \ + -e '/libc_hidden_proto/d' \ + < ./lib/malloc/scratch_buffer.h; \ +} > lib/malloc/scratch_buffer.gl.h-t && \ +mv lib/malloc/scratch_buffer.gl.h-t lib/malloc/scratch_buffer.gl.h rm -f lib/signal.h-t lib/signal.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */' && \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ @@ -1415,15 +1460,6 @@ < ./lib/signal.in.h; \ } > lib/signal.h-t && \ mv lib/signal.h-t lib/signal.h -rm -f lib/malloc/scratch_buffer.gl.h-t lib/malloc/scratch_buffer.gl.h && \ -{ echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ - sed -e 's|__always_inline|inline _GL_ATTRIBUTE_ALWAYS_INLINE|g' \ - -e 's|__glibc_likely|_GL_LIKELY|g' \ - -e 's|__glibc_unlikely|_GL_UNLIKELY|g' \ - -e '/libc_hidden_proto/d' \ - < ./lib/malloc/scratch_buffer.h; \ -} > lib/malloc/scratch_buffer.gl.h-t && \ -mv lib/malloc/scratch_buffer.gl.h-t lib/malloc/scratch_buffer.gl.h rm -f lib/spawn.h-t lib/spawn.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ @@ -1842,7 +1878,6 @@ } > lib/sys/ioctl.h-t && \ mv lib/sys/ioctl.h-t lib/sys/ioctl.h /usr/bin/mkdir -p lib/sys -/usr/bin/mkdir -p lib/sys rm -f lib/sys/resource.h-t lib/sys/resource.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ @@ -1859,6 +1894,7 @@ < ./lib/sys_resource.in.h; \ } > lib/sys/resource.h-t && \ mv -f lib/sys/resource.h-t lib/sys/resource.h +/usr/bin/mkdir -p lib/sys rm -f lib/sys/stat.h-t lib/sys/stat.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ @@ -1918,7 +1954,6 @@ } > lib/sys/stat.h-t && \ mv lib/sys/stat.h-t lib/sys/stat.h /usr/bin/mkdir -p lib/sys -/usr/bin/mkdir -p lib/sys rm -f lib/sys/time.h-t lib/sys/time.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ @@ -1939,6 +1974,8 @@ < ./lib/sys_time.in.h; \ } > lib/sys/time.h-t && \ mv lib/sys/time.h-t lib/sys/time.h +/usr/bin/mkdir -p lib/sys +/usr/bin/mkdir -p lib/sys rm -f lib/sys/times.h-t lib/sys/times.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ @@ -1955,7 +1992,6 @@ < ./lib/sys_times.in.h; \ } > lib/sys/times.h-t && \ mv lib/sys/times.h-t lib/sys/times.h -/usr/bin/mkdir -p lib/sys rm -f lib/sys/types.h-t lib/sys/types.h && \ { echo '/* DO NOT EDIT! GENERATED AUTOMATICALLY! */'; \ sed -e 's|@''GUARD_PREFIX''@|GL|g' \ @@ -2427,30 +2463,30 @@ gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-closeout.o `test -f 'lib/closeout.c' || echo './'`lib/closeout.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-concat-filename.o `test -f 'lib/concat-filename.c' || echo './'`lib/concat-filename.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-dirname.o `test -f 'lib/dirname.c' || echo './'`lib/dirname.c -gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-basename.o `test -f 'lib/basename.c' || echo './'`lib/basename.c lib/careadlinkat.c: In function 'careadlinkat': lib/careadlinkat.c:178:5: warning: #warning "GCC might issue a bogus -Wreturn-local-addr warning here." [-Wcpp] 178 | #warning "GCC might issue a bogus -Wreturn-local-addr warning here." | ^~~~~~~ +gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-basename.o `test -f 'lib/basename.c' || echo './'`lib/basename.c lib/careadlinkat.c:179:5: warning: #warning "See ." [-Wcpp] 179 | #warning "See ." | ^~~~~~~ -gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-dirname-lgpl.o `test -f 'lib/dirname-lgpl.c' || echo './'`lib/dirname-lgpl.c lib/canonicalize.c: In function 'canonicalize_filename_mode': -lib/careadlinkat.c:182:10: warning: function may return address of local variable [-Wreturn-local-addr] - 182 | return readlink_stk (fd, filename, buffer, buffer_size, alloc, - | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - 183 | preadlinkat, stack_buf); - | ~~~~~~~~~~~~~~~~~~~~~~~ lib/canonicalize.c:484:5: warning: #warning "GCC might issue a bogus -Wreturn-local-addr warning here." [-Wcpp] 484 | #warning "GCC might issue a bogus -Wreturn-local-addr warning here." | ^~~~~~~ lib/canonicalize.c:485:5: warning: #warning "See ." [-Wcpp] 485 | #warning "See ." | ^~~~~~~ +lib/careadlinkat.c:182:10: warning: function may return address of local variable [-Wreturn-local-addr] + 182 | return readlink_stk (fd, filename, buffer, buffer_size, alloc, + | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + 183 | preadlinkat, stack_buf); + | ~~~~~~~~~~~~~~~~~~~~~~~ lib/careadlinkat.c:181:8: note: declared here 181 | char stack_buf[STACK_BUF_SIZE]; | ^~~~~~~~~ +gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-dirname-lgpl.o `test -f 'lib/dirname-lgpl.c' || echo './'`lib/dirname-lgpl.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-stripslash.o `test -f 'lib/stripslash.c' || echo './'`lib/stripslash.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-execute.o `test -f 'lib/execute.c' || echo './'`lib/execute.c gcc -DEXEEXT=\"\" -I. -I./lib -I. -I./lib -DDEFAULT_TEXT_DOMAIN=\"bison-gnulib\" -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o lib/libbison_a-exitfail.o `test -f 'lib/exitfail.c' || echo './'`lib/exitfail.c @@ -2616,8 +2652,8 @@ sed -e 's,^Usage: .*/bison \[OPTION\],Usage: bison [OPTION],g' \ -e '/translation bugs/d' >>doc/bison.help.tmp ./build-aux/move-if-change doc/bison.help.tmp doc/bison.help -if /bin/bash '/build/reproducible-path/bison-3.8.2+dfsg/build-aux/missing' help2man --version >/dev/null 2>&1; then \ - /bin/bash '/build/reproducible-path/bison-3.8.2+dfsg/build-aux/missing' help2man \ +if /bin/sh '/build/reproducible-path/bison-3.8.2+dfsg/build-aux/missing' help2man --version >/dev/null 2>&1; then \ + /bin/sh '/build/reproducible-path/bison-3.8.2+dfsg/build-aux/missing' help2man \ --include=./doc/bison.x \ --output=doc/bison.1.tmp tests/bison && \ { sed 's/^\(\.TH[^"]*"[^"]*"[^"]*\)"[^"]*"/\1/' doc/bison.1 >doc/bison.1a.tmp || true; } && \ @@ -2682,88 +2718,87 @@ ./build-aux/move-if-change doc/bison.help.tmp doc/bison.help make examples/c/calc/calc examples/c/glr/c++-types examples/c/lexcalc/lexcalc examples/c/mfcalc/mfcalc examples/c/pushcalc/calc examples/c/reccalc/reccalc examples/c/rpcalc/rpcalc examples/c++/calc++/calc++ examples/c++/glr/c++-types examples/c++/simple examples/c++/variant examples/c++/variant-11 ./tests/bison tests/atconfig tests/atlocal make[4]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' -/bin/bash ./build-aux/ylwrap examples/c/calc/calc.y y.tab.c examples/c/calc/calc.c y.tab.h `echo examples/c/calc/calc.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/calc/calc.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines -/bin/bash ./build-aux/ylwrap examples/c/glr/c++-types.y y.tab.c examples/c/glr/c++-types.c y.tab.h `echo examples/c/glr/c++-types.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/glr/c++-types.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines -/bin/bash ./build-aux/ylwrap examples/c/lexcalc/parse.y y.tab.c examples/c/lexcalc/parse.c y.tab.h `echo examples/c/lexcalc/parse.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/lexcalc/parse.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines +/bin/sh ./build-aux/ylwrap examples/c/calc/calc.y y.tab.c examples/c/calc/calc.c y.tab.h `echo examples/c/calc/calc.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/calc/calc.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines +/bin/sh ./build-aux/ylwrap examples/c/glr/c++-types.y y.tab.c examples/c/glr/c++-types.c y.tab.h `echo examples/c/glr/c++-types.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/glr/c++-types.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines +/bin/sh ./build-aux/ylwrap examples/c/lexcalc/parse.y y.tab.c examples/c/lexcalc/parse.c y.tab.h `echo examples/c/lexcalc/parse.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/lexcalc/parse.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines \ -/bin/bash ./build-aux/ylwrap `test -f 'examples/c/lexcalc/scan.l' || echo './'`examples/c/lexcalc/scan.l lex.yy.c examples/c/lexcalc/scan.c -- flex -/bin/bash ./build-aux/ylwrap examples/c/mfcalc/mfcalc.y y.tab.c examples/c/mfcalc/mfcalc.c y.tab.h `echo examples/c/mfcalc/mfcalc.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/mfcalc/mfcalc.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines -/bin/bash ./build-aux/ylwrap examples/c/pushcalc/calc.y y.tab.c examples/c/pushcalc/calc.c y.tab.h `echo examples/c/pushcalc/calc.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/pushcalc/calc.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines -/bin/bash ./build-aux/ylwrap examples/c/reccalc/parse.y y.tab.c examples/c/reccalc/parse.c y.tab.h `echo examples/c/reccalc/parse.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/reccalc/parse.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines -/bin/bash ./build-aux/ylwrap examples/c/rpcalc/rpcalc.y y.tab.c examples/c/rpcalc/rpcalc.c y.tab.h `echo examples/c/rpcalc/rpcalc.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/rpcalc/rpcalc.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines +/bin/sh ./build-aux/ylwrap `test -f 'examples/c/lexcalc/scan.l' || echo './'`examples/c/lexcalc/scan.l lex.yy.c examples/c/lexcalc/scan.c -- flex +/bin/sh ./build-aux/ylwrap examples/c/mfcalc/mfcalc.y y.tab.c examples/c/mfcalc/mfcalc.c y.tab.h `echo examples/c/mfcalc/mfcalc.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/mfcalc/mfcalc.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines +/bin/sh ./build-aux/ylwrap examples/c/pushcalc/calc.y y.tab.c examples/c/pushcalc/calc.c y.tab.h `echo examples/c/pushcalc/calc.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/pushcalc/calc.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines +/bin/sh ./build-aux/ylwrap examples/c/reccalc/parse.y y.tab.c examples/c/reccalc/parse.c y.tab.h `echo examples/c/reccalc/parse.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/reccalc/parse.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines +/bin/sh ./build-aux/ylwrap examples/c/rpcalc/rpcalc.y y.tab.c examples/c/rpcalc/rpcalc.c y.tab.h `echo examples/c/rpcalc/rpcalc.c | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c/rpcalc/rpcalc.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines rm -f examples/c++/calc++/parser.stamp +\ +/bin/sh ./build-aux/ylwrap `test -f 'examples/c++/calc++/scanner.ll' || echo './'`examples/c++/calc++/scanner.ll lex.yy.c examples/c++/calc++/scanner.cc -- flex touch examples/c++/calc++/parser.stamp.tmp ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines -o examples/c++/calc++/parser.cc examples/c++/calc++/parser.yy -\ -/bin/bash ./build-aux/ylwrap `test -f 'examples/c++/calc++/scanner.ll' || echo './'`examples/c++/calc++/scanner.ll lex.yy.c examples/c++/calc++/scanner.cc -- flex rm -f examples/c++/glr/c++-types.stamp touch examples/c++/glr/c++-types.stamp.tmp ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines -o examples/c++/glr/c++-types.cc examples/c++/glr/c++-types.yy \ -/bin/bash ./build-aux/ylwrap `test -f 'examples/c++/simple.yy' || echo './'`examples/c++/simple.yy y.tab.c examples/c++/simple.cc y.tab.h `echo examples/c++/simple.cc | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c++/simple.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines -updating examples/c/lexcalc/parse.output -updating examples/c/calc/calc.output -updating examples/c/mfcalc/mfcalc.output -mv -f examples/c++/glr/c++-types.stamp.tmp examples/c++/glr/c++-types.stamp +/bin/sh ./build-aux/ylwrap `test -f 'examples/c++/simple.yy' || echo './'`examples/c++/simple.yy y.tab.c examples/c++/simple.cc y.tab.h `echo examples/c++/simple.cc | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c++/simple.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines updating examples/c/glr/c++-types.output mv -f examples/c++/calc++/parser.stamp.tmp examples/c++/calc++/parser.stamp +updating examples/c/lexcalc/parse.output \ -/bin/bash ./build-aux/ylwrap `test -f 'examples/c++/variant.yy' || echo './'`examples/c++/variant.yy y.tab.c examples/c++/variant.cc y.tab.h `echo examples/c++/variant.cc | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c++/variant.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines +/bin/sh ./build-aux/ylwrap `test -f 'examples/c++/variant.yy' || echo './'`examples/c++/variant.yy y.tab.c examples/c++/variant.cc y.tab.h `echo examples/c++/variant.cc | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c++/variant.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines \ -/bin/bash ./build-aux/ylwrap `test -f 'examples/c++/variant-11.yy' || echo './'`examples/c++/variant-11.yy y.tab.c examples/c++/variant-11.cc y.tab.h `echo examples/c++/variant-11.cc | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c++/variant-11.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines +/bin/sh ./build-aux/ylwrap `test -f 'examples/c++/variant-11.yy' || echo './'`examples/c++/variant-11.yy y.tab.c examples/c++/variant-11.cc y.tab.h `echo examples/c++/variant-11.cc | sed -e s/cc$/hh/ -e s/cpp$/hpp/ -e s/cxx$/hxx/ -e s/c++$/h++/ -e s/c$/h/` y.output examples/c++/variant-11.output -- ./tests/bison -o y.tab.c --defines -Werror -Wall,dangling-alias --report=all --no-lines make[4]: 'tests/bison' is up to date. make[4]: Nothing to be done for 'tests/atconfig'. make[4]: 'tests/atlocal' is up to date. -updating examples/c/calc/calc.h -updating examples/c/lexcalc/parse.h updating examples/c/glr/c++-types.h -updating examples/c/mfcalc/mfcalc.h -gcc -DEXEEXT=\"\" -I./examples/c/calc -I./examples/c/calc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/calc/examples_c_calc_calc-calc.o `test -f 'examples/c/calc/calc.c' || echo './'`examples/c/calc/calc.c +updating examples/c/lexcalc/parse.h +updating examples/c/pushcalc/calc.output +mv -f examples/c++/glr/c++-types.stamp.tmp examples/c++/glr/c++-types.stamp gcc -DEXEEXT=\"\" -I./examples/c/glr -I./examples/c/glr -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/glr/examples_c_glr_c___types-c++-types.o `test -f 'examples/c/glr/c++-types.c' || echo './'`examples/c/glr/c++-types.c gcc -DEXEEXT=\"\" -I./examples/c/lexcalc -I./examples/c/lexcalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/lexcalc/examples_c_lexcalc_lexcalc-parse.o `test -f 'examples/c/lexcalc/parse.c' || echo './'`examples/c/lexcalc/parse.c -updating examples/c/pushcalc/calc.output gcc -DEXEEXT=\"\" -I./examples/c/lexcalc -I./examples/c/lexcalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/lexcalc/examples_c_lexcalc_lexcalc-scan.o `test -f 'examples/c/lexcalc/scan.c' || echo './'`examples/c/lexcalc/scan.c -gcc -DEXEEXT=\"\" -I./examples/c/mfcalc -I./examples/c/mfcalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/mfcalc/examples_c_mfcalc_mfcalc-mfcalc.o `test -f 'examples/c/mfcalc/mfcalc.c' || echo './'`examples/c/mfcalc/mfcalc.c g++ -DEXEEXT=\"\" -I./examples/c++/calc++ -I./examples/c++/calc++ -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/calc++/calc__-driver.o `test -f 'examples/c++/calc++/driver.cc' || echo './'`examples/c++/calc++/driver.cc -updating examples/c/reccalc/parse.output +updating examples/c/calc/calc.output +updating examples/c/rpcalc/rpcalc.output +updating examples/c/mfcalc/mfcalc.output updating examples/c/pushcalc/calc.h +updating examples/c/reccalc/parse.output g++ -DEXEEXT=\"\" -I./examples/c++/calc++ -I./examples/c++/calc++ -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/calc++/calc__-scanner.o `test -f 'examples/c++/calc++/scanner.cc' || echo './'`examples/c++/calc++/scanner.cc -updating examples/c/rpcalc/rpcalc.output -updating examples/c/reccalc/parse.h +updating examples/c/mfcalc/mfcalc.h +updating examples/c/calc/calc.h g++ -DEXEEXT=\"\" -I./examples/c++/calc++ -I./examples/c++/calc++ -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/calc++/calc__-calc++.o `test -f 'examples/c++/calc++/calc++.cc' || echo './'`examples/c++/calc++/calc++.cc -updating examples/c/rpcalc/rpcalc.h g++ -DEXEEXT=\"\" -I./examples/c++/calc++ -I./examples/c++/calc++ -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/calc++/calc__-parser.o `test -f 'examples/c++/calc++/parser.cc' || echo './'`examples/c++/calc++/parser.cc +updating examples/c/rpcalc/rpcalc.h +updating examples/c/reccalc/parse.h +gcc -DEXEEXT=\"\" -I./examples/c/calc -I./examples/c/calc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/calc/examples_c_calc_calc-calc.o `test -f 'examples/c/calc/calc.c' || echo './'`examples/c/calc/calc.c +gcc -DEXEEXT=\"\" -I./examples/c/mfcalc -I./examples/c/mfcalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/mfcalc/examples_c_mfcalc_mfcalc-mfcalc.o `test -f 'examples/c/mfcalc/mfcalc.c' || echo './'`examples/c/mfcalc/mfcalc.c updating examples/c++/simple.output -updating examples/c++/simple.hh updating examples/c++/variant.output -g++ -DEXEEXT=\"\" -I./examples/c++/glr -I./examples/c++/glr -Wdate-time -D_FORTIFY_SOURCE=2 -std=c++14 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/glr/examples_c___glr_c___types-c++-types.o `test -f 'examples/c++/glr/c++-types.cc' || echo './'`examples/c++/glr/c++-types.cc updating examples/c++/variant-11.output -g++ -DEXEEXT=\"\" -I. -Wdate-time -D_FORTIFY_SOURCE=2 -std=c++11 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/simple-simple.o `test -f 'examples/c++/simple.cc' || echo './'`examples/c++/simple.cc +updating examples/c++/simple.hh updating examples/c++/variant.hh -gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/calc/calc examples/c/calc/examples_c_calc_calc-calc.o gcc -DEXEEXT=\"\" -I./examples/c/pushcalc -I./examples/c/pushcalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/pushcalc/examples_c_pushcalc_calc-calc.o `test -f 'examples/c/pushcalc/calc.c' || echo './'`examples/c/pushcalc/calc.c gcc -DEXEEXT=\"\" -I./examples/c/reccalc -I./examples/c/reccalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/reccalc/examples_c_reccalc_reccalc-parse.o `test -f 'examples/c/reccalc/parse.c' || echo './'`examples/c/reccalc/parse.c -gcc -DEXEEXT=\"\" -I./examples/c/reccalc -I./examples/c/reccalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/reccalc/examples_c_reccalc_reccalc-scan.o `test -f 'examples/c/reccalc/scan.c' || echo './'`examples/c/reccalc/scan.c updating examples/c++/variant-11.hh +gcc -DEXEEXT=\"\" -I./examples/c/reccalc -I./examples/c/reccalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/reccalc/examples_c_reccalc_reccalc-scan.o `test -f 'examples/c/reccalc/scan.c' || echo './'`examples/c/reccalc/scan.c gcc -DEXEEXT=\"\" -I./examples/c/rpcalc -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c/rpcalc/examples_c_rpcalc_rpcalc-rpcalc.o `test -f 'examples/c/rpcalc/rpcalc.c' || echo './'`examples/c/rpcalc/rpcalc.c +g++ -DEXEEXT=\"\" -I./examples/c++/glr -I./examples/c++/glr -Wdate-time -D_FORTIFY_SOURCE=2 -std=c++14 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/glr/examples_c___glr_c___types-c++-types.o `test -f 'examples/c++/glr/c++-types.cc' || echo './'`examples/c++/glr/c++-types.cc +g++ -DEXEEXT=\"\" -I. -Wdate-time -D_FORTIFY_SOURCE=2 -std=c++11 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/simple-simple.o `test -f 'examples/c++/simple.cc' || echo './'`examples/c++/simple.cc g++ -DEXEEXT=\"\" -I. -Wdate-time -D_FORTIFY_SOURCE=2 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/variant-variant.o `test -f 'examples/c++/variant.cc' || echo './'`examples/c++/variant.cc g++ -DEXEEXT=\"\" -I. -Wdate-time -D_FORTIFY_SOURCE=2 -std=c++11 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -c -o examples/c++/variant_11-variant-11.o `test -f 'examples/c++/variant-11.cc' || echo './'`examples/c++/variant-11.cc +gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/calc/calc examples/c/calc/examples_c_calc_calc-calc.o gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/lexcalc/lexcalc examples/c/lexcalc/examples_c_lexcalc_lexcalc-parse.o examples/c/lexcalc/examples_c_lexcalc_lexcalc-scan.o gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/mfcalc/mfcalc examples/c/mfcalc/examples_c_mfcalc_mfcalc-mfcalc.o -lm -gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/reccalc/reccalc examples/c/reccalc/examples_c_reccalc_reccalc-parse.o examples/c/reccalc/examples_c_reccalc_reccalc-scan.o gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/rpcalc/rpcalc examples/c/rpcalc/examples_c_rpcalc_rpcalc-rpcalc.o -lm +gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/reccalc/reccalc examples/c/reccalc/examples_c_reccalc_reccalc-parse.o examples/c/reccalc/examples_c_reccalc_reccalc-scan.o gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/pushcalc/calc examples/c/pushcalc/examples_c_pushcalc_calc-calc.o gcc -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c/glr/c++-types examples/c/glr/examples_c_glr_c___types-c++-types.o g++ -std=c++11 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c++/simple examples/c++/simple-simple.o -g++ -std=c++11 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c++/variant-11 examples/c++/variant_11-variant-11.o g++ -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c++/calc++/calc++ examples/c++/calc++/calc__-driver.o examples/c++/calc++/calc__-scanner.o examples/c++/calc++/calc__-calc++.o examples/c++/calc++/calc__-parser.o g++ -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c++/variant examples/c++/variant-variant.o +g++ -std=c++11 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c++/variant-11 examples/c++/variant_11-variant-11.o g++ -std=c++14 -g -O2 -ffile-prefix-map=/build/reproducible-path/bison-3.8.2+dfsg=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wl,-z,relro -Wl,-z,now -o examples/c++/glr/c++-types examples/c++/glr/examples_c___glr_c___types-c++-types.o make[4]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' make check-TESTS check-local make[4]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' make all-recursive -make[5]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' rm -f tests/package.m4 tests/package.m4.tmp { \ echo '# Signature of the current package.'; \ @@ -2775,7 +2810,8 @@ } >tests/package.m4.tmp mv tests/package.m4.tmp tests/package.m4 \ - /bin/bash '/build/reproducible-path/bison-3.8.2+dfsg/build-aux/missing' autom4te --language=autotest -I ./tests ./tests/testsuite.at -o tests/testsuite.tmp + /bin/sh '/build/reproducible-path/bison-3.8.2+dfsg/build-aux/missing' autom4te --language=autotest -I ./tests ./tests/testsuite.at -o tests/testsuite.tmp +make[5]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' make[5]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' Making all in po make[6]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg/po' @@ -2791,26 +2827,26 @@ make[6]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg/gnulib-po' Making all in . make[6]: Entering directory '/build/reproducible-path/bison-3.8.2+dfsg' +PASS: examples/c/glr/c++-types.test /usr/bin/mkdir -p doc +PASS: examples/c++/simple.test LC_ALL=C tests/bison --version >doc/bison.help.tmp LC_ALL=C tests/bison --help | \ sed -e 's,^Usage: .*/bison \[OPTION\],Usage: bison [OPTION],g' \ -e '/translation bugs/d' >>doc/bison.help.tmp ./build-aux/move-if-change doc/bison.help.tmp doc/bison.help -make[6]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' -make[5]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' -PASS: examples/c/glr/c++-types.test -PASS: examples/c++/simple.test PASS: examples/c++/glr/c++-types.test PASS: examples/c++/variant.test +make[6]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' +make[5]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' PASS: examples/c++/variant-11.test +PASS: examples/c/lexcalc/lexcalc.test PASS: examples/c/mfcalc/mfcalc.test -PASS: examples/c/rpcalc/rpcalc.test PASS: examples/c/calc/calc.test -PASS: examples/c/lexcalc/lexcalc.test -PASS: examples/c/pushcalc/calc.test PASS: examples/c++/calc++/calc++.test +PASS: examples/c/pushcalc/calc.test PASS: examples/c/reccalc/reccalc.test +PASS: examples/c/rpcalc/rpcalc.test ============================================================================ Testsuite summary for GNU Bison 3.8.2 ============================================================================ @@ -2825,7 +2861,7 @@ make[5]: Leaving directory '/build/reproducible-path/bison-3.8.2+dfsg' "/usr/bin/perl" -pi -e 's/\@tb\@/\t/g' tests/testsuite.tmp mv tests/testsuite.tmp tests/testsuite -/bin/bash ./tests/testsuite -C tests -j12 --verbose +/bin/sh ./tests/testsuite -C tests -j12 --verbose ## --------------------------- ## ## GNU Bison 3.8.2 test suite. ## ## --------------------------- ## @@ -2842,82 +2878,34 @@ 1. m4.at:21: testing Generating Comments ... +./m4.at:53: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -S ./input.m4 input.y +6. input.at:173: testing Yacc warnings on symbols ... +./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wyacc input.y +7. input.at:204: testing Yacc warnings ... 2. input.at:27: testing Invalid number of arguments ... ./input.at:29: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -6. input.at:173: testing Yacc warnings on symbols ... +11. input.at:401: testing Dangling aliases ... +12. input.at:427: testing Symbol declarations ... +8. input.at:238: testing Yacc's %type ... 9. input.at:287: testing Invalid symbol declarations ... -./input.at:34: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y 2.y -./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wyacc input.y -./m4.at:53: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -S ./input.m4 input.y ./input.at:304: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -12. input.at:427: testing Symbol declarations ... -7. input.at:204: testing Yacc warnings ... +4. input.at:83: testing Invalid inputs ... +./input.at:97: "$PERL" -pi -e 's/\\(\d{3})/chr(oct($1))/ge' input.y || exit 77 +./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wyacc input.y 5. input.at:147: testing Invalid inputs with {} ... -./input.at:162: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -3. input.at:58: testing Invalid options ... -./input.at:67: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -ferror=caret input.y 10. input.at:341: testing Redefining the error token ... ./input.at:354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -./input.at:467: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S./dump-symbols.m4 input.y -./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wyacc input.y -4. input.at:83: testing Invalid inputs ... -./input.at:97: "$PERL" -pi -e 's/\\(\d{3})/chr(oct($1))/ge' input.y || exit 77 -11. input.at:401: testing Dangling aliases ... +3. input.at:58: testing Invalid options ... +./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wyacc input.y +./input.at:162: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wdangling input.y -stderr: +./input.at:67: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -ferror=caret input.y +./input.at:99: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y +./input.at:467: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S./dump-symbols.m4 input.y 9. input.at:287: ok -./input.at:390: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -8. input.at:238: testing Yacc's %type ... 5. input.at:147: ok -./input.at:42: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --skeleton -bison: invalid argument 'error=caret' for '--feature' -Valid arguments are: - - 'none' - - 'caret', 'diagnostics-show-caret' - - 'fixit', 'diagnostics-parseable-fixits' - - 'syntax-only' - - 'all' -./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wyacc input.y -./input.at:99: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -./input.at:68: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=error=itemsets input.y -./m4.at:55: cat output.txt -stderr: -bison: option '--skeleton' requires an argument -Try 'bison --help' for more information. -./input.at:43: sed -e \ - "s/requires an argument -- skeleton/'--skeleton' requires an argument/" \ - stderr -./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wdangling input.y -Werror -stderr: -bison: invalid argument 'error=itemsets' for '--report' -Valid arguments are: - - 'none' - - 'states' - - 'itemsets' - - 'lookaheads' - - 'solved' - - 'counterexamples', 'cex' - - 'all' -1. m4.at:21: ./input.at:72: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror?all input.y - ok stderr: stderr: -bison: invalid argument 'error?all' for '--warning' -Valid arguments are: - - 'all' - - 'conflicts-rr' - - 'conflicts-sr' - - 'counterexamples', 'cex' - - 'dangling-alias' - - 'deprecated' - - 'empty-rule' - - 'everything' - - 'midrule-values' - - 'none' - - 'other' - - 'precedence' - - 'yacc' - input.y:1.11: error: invalid null character 1 | %header "ð€ˆ" | ^ @@ -2951,31 +2939,42 @@ input.y:10.1-11.0: error: missing '%}' at end of file 10 | %{ | ^~ - +bison: invalid argument 'error=caret' for '--feature' +Valid arguments are: + - 'none' + - 'caret', 'diagnostics-show-caret' + - 'fixit', 'diagnostics-parseable-fixits' + - 'syntax-only' + - 'all' ./input.at:104: "$PERL" -p -e 's{([\0\200\210\360\377])}{sprintf "\\x%02x", ord($1)}ge' stderr -./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Werror -3. input.at:58: ok -./input.at:468: cat symbols.csv -./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Werror -2. input.at:27: ok -./input.at:390: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./input.at:34: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y 2.y +./input.at:68: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=error=itemsets input.y +4. input.at:83: ok +./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Werror +./input.at:390: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +stderr: +./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Werror +./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wdangling input.y -Werror +./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Werror +./m4.at:55: cat output.txt 13. input.at:528: testing Invalid $n and @n ... -14. input.at:552: testing Type Clashes ... -./input.at:565: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y + +bison: invalid argument 'error=itemsets' for '--report' +Valid arguments are: + - 'none' + - 'states' + - 'itemsets' + - 'lookaheads' + - 'solved' + - 'counterexamples', 'cex' + - 'all' ./input.at:536: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -12. input.at:427: stderr: - ok -input.y:2.13-17: error: string literal "bar" not attached to a symbol [-Werror=dangling-alias] - 2 | %type "bar" - | ^~~~~ -input.y:4.19-23: error: string literal "baz" not attached to a symbol [-Werror=dangling-alias] - 4 | expr: "foo" "bar" "baz" - | ^~~~~ -14. input.at:552: ok -4. input.at:83: ok -15. input.at:774: testing Unused values ... -13. input.at:528: ok +./input.at:72: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror?all input.y +1. m4.at:21: ok +stderr: +./input.at:42: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --skeleton +stderr: stderr: input.y:1.1-11: error: POSIX Yacc does not support %destructor [-Werror=yacc] 1 | %destructor {} @@ -2989,9 +2988,8 @@ input.y:7.4-9: error: POSIX Yacc does not support %empty [-Werror=yacc] 7 | b: %empty { $$ = 42; }; | ^~~~~~ -./input.at:410: sed 's,.*/$,,' stderr 1>&2 -stderr: -./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y +14. input.at:552: testing Type Clashes ... +./input.at:468: cat symbols.csv input.y:1.1-6: error: POSIX Yacc does not support %nterm [-Werror=yacc] 1 | %nterm exp | ^~~~~~ @@ -3004,26 +3002,23 @@ input.y:4.6-13: error: POSIX Yacc does not support string literals [-Werror=yacc] 4 | exp: "number"; | ^~~~~~~~ - -./input.at:216: sed 's,.*/$,,' stderr 1>&2 - - -./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Werror - -./input.at:182: sed 's,.*/$,,' stderr 1>&2 -16. input.at:784: testing Unused values before symbol declarations ... - -17. input.at:794: testing Symbol redeclared ... -./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y -./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y - -./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=error -18. input.at:832: testing EOF redeclared ... -./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y -19. input.at:859: testing Symbol class redefinition ... stderr: -./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wdangling input.y --warnings=error -./input.at:871: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y +bison: invalid argument 'error?all' for '--warning' +Valid arguments are: + - 'all' + - 'conflicts-rr' + - 'conflicts-sr' + - 'counterexamples', 'cex' + - 'dangling-alias' + - 'deprecated' + - 'empty-rule' + - 'everything' + - 'midrule-values' + - 'none' + - 'other' + - 'precedence' + - 'yacc' +./input.at:565: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y input.y:2.1-6: error: POSIX Yacc does not support %nterm [-Werror=yacc] 2 | %nterm nterm1 | ^~~~~~ @@ -3048,29 +3043,73 @@ input.y:10.9-16: error: POSIX Yacc does not support string literals [-Werror=yacc] 10 | nterm3: "TOKEN3" | ^~~~~~~~ +3. input.at:58: ok + +stderr: +./input.at:390: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./input.at:253: sed 's,.*/$,,' stderr 1>&2 +./input.at:216: sed 's,.*/$,,' stderr 1>&2 +bison: option '--skeleton' requires an argument +Try 'bison --help' for more information. +./input.at:43: sed -e \ + "s/requires an argument -- skeleton/'--skeleton' requires an argument/" \ + stderr +./input.at:182: sed 's,.*/$,,' stderr 1>&2 + +12. input.at:427: ok +./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=error +13. input.at:528: ok +./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=error +16. input.at:784: testing Unused values before symbol declarations ... +2. input.at:27: ok +./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=error +14. input.at:552: ok + +./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y +stderr: +input.y:2.13-17: error: string literal "bar" not attached to a symbol [-Werror=dangling-alias] + 2 | %type "bar" + | ^~~~~ +input.y:4.19-23: error: string literal "baz" not attached to a symbol [-Werror=dangling-alias] + 4 | expr: "foo" "bar" "baz" + | ^~~~~ +./input.at:410: sed 's,.*/$,,' stderr 1>&2 + + +15. input.at:774: testing Unused values ... +./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y +./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wdangling input.y --warnings=error + +19. input.at:859: testing Symbol class redefinition ... +./input.at:871: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y +17. input.at:794: testing Symbol redeclared ... +./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y +./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Wnone,none -Werror --trace=none +./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Wnone,none -Werror --trace=none +19. input.at:859: ok +./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Wnone,none -Werror --trace=none + +18. input.at:832: testing EOF redeclared ... 20. input.at:899: testing Default %printer and %destructor redeclared ... +./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wdangling input.y -Wnone,none -Werror --trace=none ./input.at:959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=error +./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y + +./input.at:960: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror -./input.at:253: sed 's,.*/$,,' stderr 1>&2 +./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=none -Werror --trace=none +./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=none -Werror --trace=none +22. input.at:1013: testing Undefined symbols ... +./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wdangling input.y --warnings=none -Werror --trace=none +./input.at:1023: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y 21. input.at:970: testing Per-type %printer and %destructor redeclared ... ./input.at:987: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -./input.at:960: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y +./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=none -Werror --trace=none ./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror -19. input.at:859: ok -./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror -stderr: -stdout: -./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Wnone,none -Werror --trace=none -./input.at:391: $PREPARSER ./input -./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Wnone,none -Werror --trace=none -21. input.at:970: ok -./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wdangling input.y -Wnone,none -Werror --trace=none stderr: -20. input.at:899: stderr: +6. input.at:173: ok +20. input.at:899: 22. input.at:1013: ok ok -./input.at:391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror input.y:1.12-14: error: symbol FOO redeclared [-Werror=other] 1 | %token FOO FOO | ^~~ @@ -3089,27 +3128,60 @@ input.y:3.8-10: note: previous declaration 3 | %token EOF 0 EOF 0 | ^~~ -./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=error - +21. input.at:970: ok +./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror +stderr: +./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror +stdout: +8. input.at:238: ok +./input.at:391: $PREPARSER ./input stderr: ./input.at:804: sed 's,.*/$,,' stderr 1>&2 -./input.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=none -Werror --trace=none +./input.at:391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +11. input.at:401: ok + + +7. input.at:204: ok + +stderr: +10. input.at:341: ok +23. input.at:1045: testing Unassociated types used for a printer or destructor ... +./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y +./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error +26. input.at:1187: testing Unused values with per-type %destructor ... +./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y + + + input.y:1.16-18: error: symbol FOO redeclared [-Werror=other] 1 | %token FOO BAR FOO 0 | ^~~ input.y:1.8-10: note: previous declaration 1 | %token FOO BAR FOO 0 | ^~~ -10. input.at:341: ok -./input.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wdangling input.y --warnings=none -Werror --trace=none - +25. input.at:1139: testing Unused values with default %destructor ... +./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y +24. input.at:1074: testing Useless printers or destructors ... +./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y +29. input.at:1275: testing Incompatible Aliases ... ./input.at:843: sed 's,.*/$,,' stderr 1>&2 -23. input.at:1045: testing Unassociated types used for a printer or destructor ... -./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y -22. input.at:1013: testing Undefined symbols ... -./input.at:216: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=none -Werror --trace=none +27. input.at:1219: testing Duplicate string ... +./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y +./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error +./input.at:1285: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y +28. input.at:1247: testing Token collisions ... +./input.at:1256: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y +28. input.at:1247: ok +./input.at:1299: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y + + +./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror +./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror stderr: +./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -o input.c input.y -Werror +stderr: +./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror input.y:12.10-32: error: unset value: $$ [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~ @@ -3215,21 +3287,8 @@ input.y:26.40-42: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ -./input.at:1023: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y - -./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error -11. input.at:401: ./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y -Wnone,none -Werror --trace=none - ok -./input.at:775: sed 's,.*/$,,' stderr 1>&2 -24. input.at:1074: testing Useless printers or destructors ... -./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y -22. input.at:1013: ok -./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error -25. input.at:1139: testing Unused values with default %destructor ... -./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y -./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror -stderr: -6. input.at:173: ok +./input.at:1313: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y +./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none input.y:12.10-32: error: unset value: $$ [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~ @@ -3335,33 +3394,31 @@ input.y:26.40-42: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ - -./input.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wyacc input.y --warnings=none -Werror --trace=none -./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error -./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none -7. input.at:204: - ok - -./input.at:785: sed 's,.*/$,,' stderr 1>&2 -./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror -./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror +./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror stderr: -26. input.at:1187: testing Unused values with per-type %destructor ... -./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y -27. input.at:1219: testing Duplicate string ... -./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y -input.y:4.22-28: error: type is used, but is not associated to any symbol [-Werror=other] -input.y:5.25-31: error: type is used, but is not associated to any symbol [-Werror=other] -28. input.at:1247: testing Token collisions ... -./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error -8. input.at:238: ok -./input.at:1256: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y +./input.at:785: sed 's,.*/$,,' stderr 1>&2 +31. input.at:1569: testing Typed symbol aliases ... +./input.at:1586: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./input.at:775: sed 's,.*/$,,' stderr 1>&2 +input.y:6.8-22: error: unset value: $$ [-Werror=other] + 6 | start: end end { $1; } ; + | ^~~~~~~~~~~~~~~ +input.y:6.12-14: error: unused value: $2 [-Werror=other] + 6 | start: end end { $1; } ; + | ^~~ +input.y:7.6-8: error: unset value: $$ [-Werror=other] + 7 | end: { } ; + | ^~~ ./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none -./input.at:1062: sed 's,.*/$,,' stderr 1>&2 -./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror - stderr: -./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none +input.y:6.11-14: error: symbol "<=" used more than once as a literal string [-Werror=other] +30. input.at:1400: testing Torturing the Scanner ... +./input.at:1407: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y +./input.at:1327: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y +./input.at:1199: sed 's,.*/$,,' stderr 1>&2 +./input.at:1236: sed 's,.*/$,,' stderr 1>&2 +./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error +stderr: input.y:6.8-45: error: unset value: $$ [-Werror=other] 6 | start: end end tagged tagged { $1; $3; } ; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -3371,136 +3428,90 @@ input.y:7.6-8: error: unset value: $$ [-Werror=other] 7 | end: { } ; | ^~~ +./input.at:804: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none +./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error +./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error +./input.at:1344: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y +./input.at:1554: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -v -o input.c input.y +31. input.at:1569: ok +./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -o input.c input.y --warnings=error +./input.at:1152: sed 's,.*/$,,' stderr 1>&2 +./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none stderr: -28. input.at:1247: ./input.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none - ok +input.y:4.22-28: error: type is used, but is not associated to any symbol [-Werror=other] +input.y:5.25-31: error: type is used, but is not associated to any symbol [-Werror=other] +stderr: +./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error -./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error +./input.at:1062: sed 's,.*/$,,' stderr 1>&2 input.y:16.13-19: error: useless %printer for type [-Werror=other] input.y:17.16-22: error: useless %destructor for type [-Werror=other] -./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -o input.c input.y -Werror -./input.at:1152: sed 's,.*/$,,' stderr 1>&2 -29. input.at:1275: testing Incompatible Aliases ... -./input.at:1285: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -stderr: -input.y:6.8-22: error: unset value: $$ [-Werror=other] - 6 | start: end end { $1; } ; - | ^~~~~~~~~~~~~~~ -input.y:6.12-14: error: unused value: $2 [-Werror=other] - 6 | start: end end { $1; } ; - | ^~~ -input.y:7.6-8: error: unset value: $$ [-Werror=other] - 7 | end: { } ; - | ^~~ -30. input.at:1400: testing Torturing the Scanner ... -./input.at:1407: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -./input.at:1085: sed 's,.*/$,,' stderr 1>&2 +./input.at:1359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y +./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error +./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none +32. input.at:1609: testing Require 1.0 ... +17. input.at:794: ok +./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none +./input.at:1609: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 18. input.at:832: ok -./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none +./input.at:1555: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c +./input.at:1085: sed 's,.*/$,,' stderr 1>&2 +./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -o input.c input.y -Wnone,none -Werror --trace=none +./input.at:1374: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y ./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none +./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none -./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error -./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error -./input.at:1299: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -./input.at:1199: sed 's,.*/$,,' stderr 1>&2 - -./input.at:1554: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -v -o input.c input.y -17. input.at:794: ok +./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none +29. input.at:1275: ok stderr: -input.y:6.11-14: error: symbol "<=" used more than once as a literal string [-Werror=other] -./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error -./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none -32. input.at:1609: testing Require 1.0 ... -./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none -./input.at:1609: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none -./input.at:1313: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -31. input.at:1569: testing Typed symbol aliases ... -./input.at:1586: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./input.at:1236: sed 's,.*/$,,' stderr 1>&2 - -./input.at:1327: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none -./input.at:1555: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c -./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none -./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none +./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none +32. input.at:1609: ok 33. input.at:1610: testing Require 3.8.2 ... -stderr: ./input.at:1610: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -o input.c input.y --warnings=error -32. input.at:1609: ok -stderr: -23. input.at:1045: ok -31. input.at:1569: ok -./input.at:1344: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none -./input.at:1152: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none -33. input.at:1610: ok -./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y - -./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none -./input.at:1359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -./input.at:1199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none -./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y -./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -o input.c input.y -Wnone,none -Werror --trace=none +./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -o input.c input.y --warnings=none -Werror --trace=none +./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error -stderr: -34. input.at:1612: testing Require 100.0 ... -./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror -./input.at:1612: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -stdout: +./input.at:1062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none 35. input.at:1619: testing String aliases for character tokens ... ./input.at:1632: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./input.at:1374: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -./input.at:1556: $CC $CFLAGS $CPPFLAGS -c -o main.o main.c +./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none +./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y 26. input.at:1187: ok +34. input.at:1612: testing Require 100.0 ... +./input.at:1612: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y 36. input.at:1642: testing Symbols ... ./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --yacc input.y -./input.at:1236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -o input.c input.y --warnings=none -Werror --trace=none -37. input.at:1708: testing Numbered tokens ... -stderr: -input.y:3.13-14: error: useless %printer for type <> [-Werror=other] -29. input.at:1275: stderr: - ok -./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror -./input.at:1720: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret redecl.y -input.y:9.10-16: error: require bison 100.0, but have 3.8.2 -34. input.at:1612: 35. input.at:1619: ok -./input.at:1116: sed 's,.*/$,,' stderr 1>&2 - ok stderr: -stdout: -./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error -./input.at:1735: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret too-large.y -./input.at:1557: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.o main.o $LIBS -./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --yacc input.y -Werror - +33. input.at:1610: ok stderr: +27. input.at:1219: ok -input.y:6.23-28: error: unused value: $4 [-Werror=other] -input.y:8.9-11: error: unset value: $$ [-Werror=other] -37. input.at:1708: ok +input.y:9.10-16: error: require bison 100.0, but have 3.8.2 +37. input.at:1708: testing Numbered tokens ... +34. input.at:1612: ok +./input.at:1720: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret redecl.y +./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none -stderr: -stdout: +./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --yacc input.y -Werror +35. input.at:1619: ok +./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror +38. input.at:1750: testing Unclosed constructs ... +23. input.at:1045: ok +./input.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none +./input.at:1779: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y 39. input.at:1805: testing %start after first rule ... ./input.at:1817: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./input.at:1558: $PREPARSER ./input -41. input.at:1895: testing %prec takes a token ... -./input.at:1905: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +38. input.at:1750: ok stderr: -27. input.at:1219: ok -./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none -41. input.at:1895: ./input.at:1175: sed 's,.*/$,,' stderr 1>&2 - ok +./input.at:1735: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret too-large.y +stdout: + +./input.at:1556: $CC $CFLAGS $CPPFLAGS -c -o main.o main.c stderr: -40. input.at:1826: testing Duplicate %start symbol ... -./input.at:1558: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + input.y:1.1-5: error: POSIX Yacc does not support %code [-Werror=yacc] input.y:9.8-16: error: POSIX Yacc forbids dashes in symbol names: WITH-DASH [-Werror=yacc] input.y:10.21-34: error: POSIX Yacc does not support string literals [-Werror=yacc] @@ -3509,32 +3520,44 @@ input.y:20.8-16: error: POSIX Yacc forbids dashes in symbol names: with-dash [-Werror=yacc] input.y:22.15-28: error: POSIX Yacc does not support string literals [-Werror=yacc] input.y:24.17-32: error: POSIX Yacc does not support string literals [-Werror=yacc] -38. input.at:1750: testing Unclosed constructs ... -./input.at:1779: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y +40. input.at:1826: testing Duplicate %start symbol ... ./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y -./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error +37. input.at:1708: ok +./input.at:1666: sed 's,.*/$,,' stderr 1>&2 +stderr: +./input.at:1085: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none -30. input.at:1400: ok +input.y:6.23-28: error: unused value: $4 [-Werror=other] +input.y:8.9-11: error: unset value: $$ [-Werror=other] +./input.at:785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none +42. input.at:1916: testing %prec's token must be defined ... +./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y +41. input.at:1895: testing %prec takes a token ... +./input.at:1905: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --yacc input.y --warnings=error 39. input.at:1805: ok +./input.at:1175: sed 's,.*/$,,' stderr 1>&2 +41. input.at:1895: ok -./input.at:1666: sed 's,.*/$,,' stderr 1>&2 -./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -Werror -38. input.at:1750: ok +stderr: +./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror 43. input.at:1936: testing Reject unused %code qualifiers ... ./input.at:1946: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-c.y +stdout: -./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror -./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --yacc input.y --warnings=error +./input.at:1557: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.o main.o $LIBS +44. input.at:2025: testing Multiple %code ... +./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror +./input.at:2054: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -42. input.at:1916: testing %prec's token must be defined ... -./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none -stderr: -./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y +./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error 45. input.at:2065: testing errors ... +./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y ./input.at:2077: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-redefined.y -./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -Werror -./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none +./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --yacc input.y -Wnone,none -Werror --trace=none +stderr: +46. input.at:2102: testing %define, --define, --force-define ... input.y:1.12-14: error: duplicate directive [-Werror=other] 1 | %start exp exp exp | ^~~ @@ -3548,28 +3571,104 @@ 1 | %start exp exp exp | ^~~ input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] -44. input.at:2025: testing Multiple %code ... -./input.at:2054: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y - -46. input.at:2102: testing %define, --define, --force-define ... -./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --yacc input.y -Wnone,none -Werror --trace=none -./input.at:1960: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-c-glr.y -./input.at:2091: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-unused.y +./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y +stderr: +./input.at:1836: sed 's,.*/$,,' stderr 1>&2 +stdout: ./input.at:2118: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dvar-dd=cmd-d1 -Dvar-dd=cmd-d2 \ -Fvar-ff=cmd-f1 -Fvar-ff=cmd-f2 \ -Dvar-dfg=cmd-d -Fvar-dfg=cmd-f \ -Fvar-fd=cmd-f -Dvar-fd=cmd-d \ --skeleton ./skel.c input.y -./input.at:1836: sed 's,.*/$,,' stderr 1>&2 -./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror -./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none -47. input.at:2170: testing "%define" Boolean variables ... +./input.at:1558: $PREPARSER ./input +./input.at:2091: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-unused.y +stderr: +./input.at:1960: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-c-glr.y +./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error +./input.at:1558: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +30. input.at:1400: stderr: + ok +input.y:2.8-17: error: token for %prec is not defined: PREC [-Werror=other] ./input.at:2054: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./input.at:2180: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret Input.y ./input.at:2123: cat input.tab.c -./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y -stderr: +./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y +./input.at:1925: sed 's,.*/$,,' stderr 1>&2 +./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --yacc input.y --warnings=none -Werror --trace=none + +./input.at:2135: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dvar=cmd-d input-dg.y +./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none +./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error +./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none +./input.at:2146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Dvar=cmd-d input-dg.y 45. input.at:2065: ok +47. input.at:2170: testing "%define" Boolean variables ... +./input.at:2180: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret Input.y +./input.at:2158: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dunused-d -Funused-f input-unused.y +./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror +./input.at:1973: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-c++.y +./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none + +./input.at:1678: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +47. input.at:2170: ok +./input.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none +stderr: +input.y:3.13-14: error: useless %printer for type <> [-Werror=other] +./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y +./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none + +./input.at:1681: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c +./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -Werror +./input.at:1116: sed 's,.*/$,,' stderr 1>&2 +48. input.at:2191: testing "%define" code variables ... +49. input.at:2224: testing "%define" keyword variables ... +./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y +./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.yy +./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error +./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none +./input.at:1986: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-c++-glr.y +./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror +46. input.at:2102: 25. input.at:1139: ok + ok +./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -Werror +./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror + +50. input.at:2257: testing "%define" enum variables ... +./input.at:2269: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y +42. input.at:1916: ok + +stderr: +stderr: +input.y:1.16-18: error: duplicate directive [-Werror=other] + 1 | %start exp foo exp + | ^~~ +input.y:1.8-10: note: previous declaration + 1 | %start exp foo exp + | ^~~ +input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] +stdout: +stderr: +./input.at:1694: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y +./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none + +./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy -Werror +stdout: +./input.at:1859: sed 's,.*/$,,' stderr 1>&2 +51. input.at:2320: testing "%define" file variables ... +./input.at:2284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y +./input.at:2329: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y +./input.at:2055: $PREPARSER ./input +stderr: +./input.at:2055: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +36. input.at:1642: ./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error + ok +./input.at:2303: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y +52. input.at:2342: testing "%define" backward compatibility ... +./input.at:2355: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y +44. input.at:2025: ./input.at:1999: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret special-char-@@.y + ok +52. input.at:2342: ok +./input.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none +stderr: input.y:12.10-32: error: unset value: $$ [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~ @@ -3699,11 +3798,27 @@ input.y:26.40-42: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ -./input.at:2135: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dvar=cmd-d input-dg.y -./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error -./input.at:2146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Dvar=cmd-d input-dg.y + +stderr: + + +./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none +54. input.at:2429: testing C++ namespace reference errors ... +./input.at:2450: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:776: sed 's,.*/$,,' stderr 1>&2 +input.y:5.1-40: error: %define variable 'lr.type' requires keyword values [-Werror=deprecated] +input.y:3.1-40: error: %define variable 'lr.default-reduction' requires keyword values [-Werror=deprecated] +input.y:4.1-40: error: %define variable 'lr.keep-unreachable-state' requires keyword values [-Werror=deprecated] +input.y:1.1-38: error: %define variable 'api.pure' requires keyword values [-Werror=deprecated] +input.y:2.1-40: error: %define variable 'api.push-pull' requires keyword values [-Werror=deprecated] +stderr: +input.yy:2.1-30: error: %define variable 'api.location.type' requires '{...}' values [-Werror=deprecated] +input.yy:4.1-30: error: %define variable 'api.prefix' requires '{...}' values [-Werror=deprecated] +input.yy:5.1-30: error: %define variable 'api.token.prefix' requires '{...}' values [-Werror=deprecated] +input.yy:3.1-30: error: %define variable 'api.namespace' requires '{...}' values [-Werror=deprecated] +55. input.at:2482: testing Bad character literals ... stderr: +51. input.at:2320: ok input.y:12.10-32: error: unset value: $$ [-Werror=other] 12 | a: INT | INT { } INT { } INT { }; | ^~~~~~~~~~~~~~~~~~~~~~~ @@ -3833,228 +3948,116 @@ input.y:26.40-42: error: unset value: $$ [-Werror=other] 26 | o: INT | INT { } INT { } INT { $$ = $1 + $2 + $3 + $4 + $5; }; | ^~~ -./input.at:1666: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --yacc input.y --warnings=none -Werror --trace=none -25. input.at:1139: ok -stderr: -input.y:2.8-17: error: token for %prec is not defined: PREC [-Werror=other] -./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y --warnings=error -./input.at:2158: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dunused-d -Funused-f input-unused.y -./input.at:786: sed 's,.*/$,,' stderr 1>&2 -./input.at:1925: sed 's,.*/$,,' stderr 1>&2 - - -./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror -47. input.at:2170: ok -./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none -./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y --warnings=error -48. input.at:2191: testing "%define" code variables ... -./input.at:1973: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-c++.y -./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error -./input.at:1678: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.yy -49. input.at:2224: testing "%define" keyword variables ... -stderr: -./input.at:1836: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none -./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y - -46. input.at:2102: ok -input.y:2.16-18: error: useless %printer for type <*> [-Werror=other] -./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -Wnone,none -Werror --trace=none -./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none -50. input.at:2257: testing "%define" enum variables ... -./input.at:2269: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -./input.at:1681: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c -./input.at:2284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -stderr: -./input.at:1124: sed 's,.*/$,,' stderr 1>&2 -./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y - -./input.at:2303: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -stdout: -./input.at:1925: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none -./input.at:2055: $PREPARSER ./input -stderr: -./input.at:1986: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-c++-glr.y -./input.at:2055: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror -./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy -Werror -./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error -44. input.at:2025: ok -stderr: -51. input.at:2320: testing "%define" file variables ... -./input.at:2329: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -stdout: -42. input.at:1916: ok -./input.at:1694: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y --warnings=none -Werror --trace=none -stderr: -./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -Wnone,none -Werror --trace=none -input.y:5.1-40: error: %define variable 'lr.type' requires keyword values [-Werror=deprecated] -input.y:3.1-40: error: %define variable 'lr.default-reduction' requires keyword values [-Werror=deprecated] -input.y:4.1-40: error: %define variable 'lr.keep-unreachable-state' requires keyword values [-Werror=deprecated] -input.y:1.1-38: error: %define variable 'api.pure' requires keyword values [-Werror=deprecated] -input.y:2.1-40: error: %define variable 'api.push-pull' requires keyword values [-Werror=deprecated] - -36. input.at:1642: 50. input.at:2257: ok - ok -./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror -./input.at:2246: sed 's,.*/$,,' stderr 1>&2 -51. input.at:2320: ./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none - ok - -52. input.at:2342: testing "%define" backward compatibility ... - -stderr: -input.y:1.16-18: error: duplicate directive [-Werror=other] - 1 | %start exp foo exp - | ^~~ -input.y:1.8-10: note: previous declaration - 1 | %start exp foo exp - | ^~~ -input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] - -./input.at:2355: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -./input.at:1999: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret special-char-@@.y -./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error -53. input.at:2393: testing Unused api.pure ... -54. input.at:2429: testing C++ namespace reference errors ... -./input.at:2450: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -55. input.at:2482: testing Bad character literals ... ./input.at:2484: set x `LC_ALL=C ls -l 'empty.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='empty.y'; } || exit 77 -./input.at:1859: sed 's,.*/$,,' stderr 1>&2 +53. input.at:2393: testing Unused api.pure ... ./input.at:2413: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y + +./input.at:2213: sed 's,.*/$,,' stderr 1>&2 +./input.at:2246: sed 's,.*/$,,' stderr 1>&2 +./input.at:786: sed 's,.*/$,,' stderr 1>&2 stderr: 0+0 records in 0+0 records out -0 bytes copied, 2.724e-05 s, 0.0 kB/s -./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y --warnings=none -Werror --trace=none +0 bytes copied, 2.664e-05 s, 0.0 kB/s stdout: -52. input.at:2342: ok - +50. input.at:2257: ok +./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y +./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy --warnings=error +./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y --warnings=error ./input.at:2490: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret empty.y -./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none -./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error 56. input.at:2543: testing Bad escapes in literals ... -stderr: -input.yy:2.1-30: error: %define variable 'api.location.type' requires '{...}' values [-Werror=deprecated] -input.yy:4.1-30: error: %define variable 'api.prefix' requires '{...}' values [-Werror=deprecated] -input.yy:5.1-30: error: %define variable 'api.token.prefix' requires '{...}' values [-Werror=deprecated] -input.yy:3.1-30: error: %define variable 'api.namespace' requires '{...}' values [-Werror=deprecated] +./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none +./input.at:2556: "$PERL" -e 'print "start: \"\\\t\\\f\\\0\\\1\" ;";' >> input.y || exit 77 +./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y --warnings=error +./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error + ./input.at:2508: set x `LC_ALL=C ls -l 'two.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='two.y'; } || exit 77 -./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none -15. input.at:774: ok -./input.at:2556: "$PERL" -e 'print "start: \"\\\t\\\f\\\0\\\1\" ;";' >> input.y || exit 77 - -./input.at:2452: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2558: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./input.at:2414: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -./input.at:2213: sed 's,.*/$,,' stderr 1>&2 -56. input.at:2543: ok +./input.at:2012: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret special-char-].y stderr: 57. input.at:2582: testing Unexpected end of file ... ./input.at:2586: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -24. input.at:1074: ok - -./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy --warnings=error -0+0 records in -0+0 records out -0 bytes copied, 2.388e-05 s, 0.0 kB/s -./input.at:2012: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret special-char-].y -stdout: -./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none -./input.at:2514: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret two.y -./input.at:1859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none -58. input.at:2675: testing LAC: Errors for %define ... +./input.at:2452: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2591: set x `LC_ALL=C ls -l 'char.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='char.y'; } || exit 77 -./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Syacc.c -Dparse.lac=none input.y -./input.at:2415: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y - - -./input.at:2522: -set x `LC_ALL=C ls -l 'three.y'` && - size=$6 && - { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='three.y'; } || exit 77 -./input.at:2454: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -stderr: -./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Syacc.c -Dparse.lac=full input.y -59. input.at:2719: testing -Werror combinations ... -60. input.at:2764: testing %name-prefix and api.prefix are incompatible ... -./input.at:2779: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-deprecated input.y +56. input.at:2543: ok 0+0 records in 0+0 records out -0 bytes copied, 2.848e-05 s, 0.0 kB/s +0 bytes copied, 2.548e-05 s, 0.0 kB/s stdout: -./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y -./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall input.y stderr: -16. input.at:784: ./input.at:2594: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret char.y +./input.at:2514: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret two.y 0+0 records in 0+0 records out -0 bytes copied, 2.512e-05 s, 0.0 kB/s - ok +0 bytes copied, 2.5e-05 s, 0 B/s stdout: -./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Syacc.c -Dparse.lac=unsupported input.y -./input.at:2528: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret three.y -./input.at:2416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -./input.at:2780: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dapi.prefix={foo} -p bar -Wno-deprecated input.y -43. input.at:1936: ok +./input.at:2594: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret char.y +./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror +./input.at:2522: +set x `LC_ALL=C ls -l 'three.y'` && + size=$6 && + { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='three.y'; } || exit 77 +./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y + ./input.at:2604: set x `LC_ALL=C ls -l 'escape-in-char.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='escape-in-char.y'; } || exit 77 -./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y -./input.at:2456: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -55. input.at:2482: ok -./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y -Werror ./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy -Wnone,none -Werror --trace=none - +./input.at:2415: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: 0+0 records in 0+0 records out -0 bytes copied, 2.648e-05 s, 0.0 kB/s +0 bytes copied, 2.5e-05 s, 0 B/s +stdout: +./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none +43. input.at:1936: ./input.at:2528: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret three.y +stderr: + ok +0+0 records in +0+0 records out +0 bytes copied, 2.312e-05 s, 0.0 kB/s stdout: -./input.at:2781: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dapi.prefix={foo} -Wno-deprecated input.y - ./input.at:2607: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret escape-in-char.y -61. input.at:2793: testing Redefined %union name ... -./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y +55. input.at:2482: ok +58. input.at:2675: testing LAC: Errors for %define ... +./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Syacc.c -Dparse.lac=none input.y stderr: -input.y:2.15: error: stray '$' [-Werror=other] -62. input.at:2840: testing Stray $ or @ ... -./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.cc -Dparse.lac=none input.y -./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall input.y - +input.y:2.16-18: error: useless %printer for type <*> [-Werror=other] ./input.at:2617: set x `LC_ALL=C ls -l 'string.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='string.y'; } || exit 77 -./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror -./input.at:2458: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -./input.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror -./input.at:2782: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -p bar -Wno-deprecated input.y -./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror -./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.cc -Dparse.lac=full input.y -./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy --warnings=none -Werror --trace=none -./input.at:2727: sed 's,.*/$,,' stderr 1>&2 -stderr: -63. input.at:2883: testing Code injection ... -./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S yacc.c -d input.y + +./input.at:2454: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +./input.at:1124: sed 's,.*/$,,' stderr 1>&2 stderr: -./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y -Werror +./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror 0+0 records in 0+0 records out -0 bytes copied, 2.448e-05 s, 0.0 kB/s +0 bytes copied, 2.62e-05 s, 0.0 kB/s +stdout: + +59. input.at:2719: testing -Werror combinations ... +./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall input.y +./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -Wnone,none -Werror --trace=none +./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error +./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y -Wnone,none -Werror --trace=none +./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Syacc.c -Dparse.lac=full input.y +./input.at:2620: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret string.y +./input.at:2246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none +./input.at:2213: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy --warnings=none -Werror --trace=none +./input.at:2416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +stderr: input.y:2.8-10: error: duplicate directive [-Werror=other] 2 | %start exp | ^~~ @@ -4062,567 +4065,599 @@ 1 | %start exp foo | ^~~ input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] -stdout: -./input.at:2620: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret string.y -./input.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y --warnings=error -./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr.c -d input.y -./input.at:2460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -stderr: -input.y:3.8-10: error: %define variable 'api.value.union.name' redefined [-Werror=other] -input.y:1.8-10: note: previous definition -input.y:4.1-32: error: %define variable 'api.value.union.name' redefined [-Werror=other] -input.y:3.8-10: note: previous definition -input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] +60. input.at:2764: testing %name-prefix and api.prefix are incompatible ... +./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Syacc.c -Dparse.lac=unsupported input.y +./input.at:2456: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +./input.at:2779: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-deprecated input.y +./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y -Werror +./input.at:1877: sed 's,.*/$,,' stderr 1>&2 ./input.at:2630: set x `LC_ALL=C ls -l 'escape-in-string.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='escape-in-string.y'; } || exit 77 -60. input.at:2764: ok -./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.cc -Dparse.lac=unsupported input.y -./input.at:1877: sed 's,.*/$,,' stderr 1>&2 -stderr: +./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none stderr: -input.y:11.19: error: stray '$' [-Werror=other] -input.y:11.23: error: stray '@' [-Werror=other] -input.y:12.19: error: stray '$' [-Werror=other] -input.y:12.23: error: stray '@' [-Werror=other] -input.y:13.19: error: stray '$' [-Werror=other] -input.y:13.23: error: stray '@' [-Werror=other] -input.y:16.19: error: stray '$' [-Werror=other] -input.y:16.23: error: stray '@' [-Werror=other] -input.y:17.19: error: stray '$' [-Werror=other] +./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error +./input.at:2780: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dapi.prefix={foo} -p bar -Wno-deprecated input.y +./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.yy +./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.cc -Dparse.lac=none input.y stderr: -input.y:5.1-40: error: %define variable 'lr.type' requires keyword values [-Werror=deprecated] -input.y:3.1-40: error: %define variable 'lr.default-reduction' requires keyword values [-Werror=deprecated] -input.y:4.1-40: error: %define variable 'lr.keep-unreachable-state' requires keyword values [-Werror=deprecated] -input.y:1.1-38: error: %define variable 'api.pure' requires keyword values [-Werror=deprecated] -input.y:2.1-40: error: %define variable 'api.push-pull' requires keyword values [-Werror=deprecated] -./input.at:2808: sed 's,.*/$,,' stderr 1>&2 -./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.cc -d input.y +input.y:2.15: error: stray '$' [-Werror=other] 0+0 records in 0+0 records out -0 bytes copied, 2.452e-05 s, 0.0 kB/s +0 bytes copied, 2.556e-05 s, 0.0 kB/s stdout: -./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.yy -./input.at:2861: sed 's,.*/$,,' stderr 1>&2 ./input.at:2633: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret escape-in-string.y -./input.at:2247: sed 's,.*/$,,' stderr 1>&2 -./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error -./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y --warnings=error +./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y +./input.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +./input.at:2458: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +./input.at:1124: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none ./input.at:2643: set x `LC_ALL=C ls -l 'tstring.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='tstring.y'; } || exit 77 - -53. input.at:2393: ok -./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error -./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr.cc -d input.y -./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error -./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y -Wnone,none -Werror --trace=none -./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.d -Dparse.lac=none input.y -64. input.at:2946: testing Deprecated directives ... +./input.at:2727: sed 's,.*/$,,' stderr 1>&2 +./input.at:786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y --warnings=none -Werror --trace=none +./input.at:776: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --warnings=midrule-values -fcaret input.y --warnings=none -Werror --trace=none stderr: +./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.cc -Dparse.lac=full input.y +./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y --warnings=error 0+0 records in 0+0 records out -0 bytes copied, 2.688e-05 s, 0.0 kB/s +0 bytes copied, 2.436e-05 s, 0.0 kB/s +./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none stdout: -./input.at:3019: cp errors-all experr -./input.at:3020: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -ffixit input.y -./input.at:2462: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:2646: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret tstring.y -./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none -./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y -Wnone,none -Werror --trace=none -./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr2.cc -d input.y - -./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none -./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y --warnings=none -Werror --trace=none -./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.d -Dparse.lac=full input.y -./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y --warnings=none -Werror --trace=none -./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none +./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror +./input.at:2460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.cc -Dparse.lac=unsupported input.y +./input.at:2781: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dapi.prefix={foo} -Wno-deprecated input.y +./input.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy -Werror +24. input.at:1074: ok +./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y -Wnone,none -Werror --trace=none +./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./input.at:2656: set x `LC_ALL=C ls -l 'escape-in-tstring.y'` && size=$6 && { test $size -eq 0 || dd obs=1 seek=`expr $size - 1` if=/dev/null of='escape-in-tstring.y'; } || exit 77 -./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy -Werror -./input.at:2465: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none -65. input.at:3077: testing Unput's effect on locations ... -./input.at:3092: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -62. input.at:2840: ok -./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -W input.y -./input.at:3022: sed -e '/^fix-it:/d' errors-all >experr -65. input.at:3077: ok -./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.d -Dparse.lac=unsupported input.y -./input.at:2820: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: -./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.d input.y -./input.at:3023: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y +stderr: + 0+0 records in 0+0 records out -0 bytes copied, 2.488e-05 s, 0.0 kB/s +0 bytes copied, 2.284e-05 s, 0.0 kB/s stdout: -./input.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none - ./input.at:2659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret escape-in-tstring.y -./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.java input.y -./input.at:2467: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +input.y:5.1-40: error: %define variable 'lr.type' requires keyword values [-Werror=deprecated] +input.y:3.1-40: error: %define variable 'lr.default-reduction' requires keyword values [-Werror=deprecated] +input.y:4.1-40: error: %define variable 'lr.keep-unreachable-state' requires keyword values [-Werror=deprecated] +input.y:1.1-38: error: %define variable 'api.pure' requires keyword values [-Werror=deprecated] +input.y:2.1-40: error: %define variable 'api.push-pull' requires keyword values [-Werror=deprecated] +./input.at:2727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y --warnings=none -Werror --trace=none +61. input.at:2793: testing Redefined %union name ... +53. input.at:2393: ./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y + ok +./input.at:2782: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -p bar -Wno-deprecated input.y +./input.at:2462: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 57. input.at:2582: ok - -66. input.at:3113: testing Non-deprecated directives ... -./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y -./input.at:3027: rm -f output.c -./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none -./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S yacc.c -d input.y -./input.at:2469: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -W input.y -Werror -./input.at:3028: cp input.y input.y.orig +./input.at:2247: sed 's,.*/$,,' stderr 1>&2 stderr: -./input.at:3029: sed -e '/fix-it/d' experr input.yy:2.1-32: error: %define variable 'api.location.type' requires '{...}' values [-Werror=deprecated] input.yy:4.1-32: error: %define variable 'api.prefix' requires '{...}' values [-Werror=deprecated] input.yy:5.1-32: error: %define variable 'api.token.prefix' requires '{...}' values [-Werror=deprecated] input.yy:3.1-32: error: %define variable 'api.namespace' requires '{...}' values [-Werror=deprecated] -./input.at:3030: echo "bison: file 'input.y' was updated (backup: 'input.y~')" >>experr -40. input.at:1826: ./input.at:3031: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --update input.y -./input.at:2825: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +16. input.at:784: ok +./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error +./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.d -Dparse.lac=none input.y + +15. input.at:774: ./input.at:2214: sed 's,.*/$,,' stderr 1>&2 ok +./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror +40. input.at:1826: ok +./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -W input.y -./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror +./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy --warnings=error +62. input.at:2840: testing Stray $ or @ ... +./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall input.y + +./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.d -Dparse.lac=full input.y + +60. input.at:2764: ok +64. input.at:2946: testing Deprecated directives ... +63. input.at:2883: testing Code injection ... + +stderr: +./input.at:3019: cp errors-all experr +input.y:3.8-10: error: %define variable 'api.value.union.name' redefined [-Werror=other] +input.y:1.8-10: note: previous definition +input.y:4.1-32: error: %define variable 'api.value.union.name' redefined [-Werror=other] +input.y:3.8-10: note: previous definition +input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] +./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S yacc.c -d input.y +65. input.at:3077: testing Unput's effect on locations ... + +./input.at:3020: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -ffixit input.y +./input.at:3092: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +./input.at:2808: sed 's,.*/$,,' stderr 1>&2 +./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.d -Dparse.lac=unsupported input.y +66. input.at:3113: testing Non-deprecated directives ... +./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y +./input.at:2465: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +65. input.at:3077: ok 67. input.at:3148: testing Cannot type action ... ./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y +./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none + +./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -W input.y -Werror +./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error +./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y -Werror +./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy -Wnone,none -Werror --trace=none +68. input.at:3171: testing Character literals and api.token.raw ... +./input.at:3181: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y +./input.at:3022: sed -e '/^fix-it:/d' errors-all >experr +./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr.c -d input.y +./input.at:3023: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y +./input.at:2467: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror +68. input.at:3171: ok stderr: +input.y:11.19: error: stray '$' [-Werror=other] +input.y:11.23: error: stray '@' [-Werror=other] +input.y:12.19: error: stray '$' [-Werror=other] +input.y:12.23: error: stray '@' [-Werror=other] +input.y:13.19: error: stray '$' [-Werror=other] +input.y:13.23: error: stray '@' [-Werror=other] +input.y:16.19: error: stray '$' [-Werror=other] +input.y:16.23: error: stray '@' [-Werror=other] +input.y:17.19: error: stray '$' [-Werror=other] +./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror ./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.java -Dparse.lac=none input.y +stderr: input.y:2.15: error: stray '$' [-Werror=other] -./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr.c -d input.y -./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.java -Dparse.lac=full input.y -./input.at:2214: sed 's,.*/$,,' stderr 1>&2 -./input.at:3034: diff input.y.orig input.y~ -./input.at:3037: test ! -f output.c -68. input.at:3171: testing Character literals and api.token.raw ... -./input.at:3181: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -./input.at:2730: sed 's,.*/$,,' stderr 1>&2 -54. input.at:2429: ./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy --warnings=error - ok -./input.at:3040: sed -e '1,8d' input.y +./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none -./input.at:3062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y -./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.java -Dparse.lac=unsupported input.y -./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.cc -d input.y -./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -W input.y --warnings=error +./input.at:2247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none +./input.at:3027: rm -f output.c +stderr: +./input.at:3028: cp input.y input.y.orig +./input.at:2861: sed 's,.*/$,,' stderr 1>&2 +input.y:10.6-13: error: only midrule actions can be typed: int [-Werror=other] + 10 | exp: {} + | ^~~~~~~~ +./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.cc -d input.y +./input.at:2730: sed 's,.*/$,,' stderr 1>&2 +./input.at:2469: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +./input.at:3156: sed 's,.*/$,,' stderr 1>&2 +./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y --warnings=error 69. input.at:3205: testing %token-table and parse.error ... +./input.at:3220: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +./input.at:3029: sed -e '/fix-it/d' experr +./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Slalr1.java -Dparse.lac=full input.y +./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error +./input.at:3030: echo "bison: file 'input.y' was updated (backup: 'input.y~')" >>experr +./input.at:3031: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --update input.y +./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -W input.y --warnings=error +./input.at:2808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none stderr: +./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy --warnings=none -Werror --trace=none input.y:14.1-15.5: error: duplicate directive: '%file-prefix' [-Werror=other] input.y:13.1-18: note: previous declaration input.y: error: %expect-rr applies only to GLR parsers [-Werror=other] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] -49. input.at:2224: ok -./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror -./input.at:3220: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y - -68. input.at:3171: ok -61. input.at:2793: ok -./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr.cc -d input.y -64. input.at:2946: ok +./input.at:3034: diff input.y.orig input.y~ +./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr.cc -d input.y +./input.at:2685: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.java -Dparse.lac=unsupported input.y ./input.at:3133: sed 's,.*/$,,' stderr 1>&2 -70. input.at:3231: testing Invalid file prefix mapping arguments ... -./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -W input.y -Wnone,none -Werror --trace=none -./input.at:3246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -M foo input.y -stderr: -./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr2.cc -d input.y +./input.at:3037: test ! -f output.c +54. input.at:2429: ./input.at:3040: sed -e '1,8d' input.y + ok +./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y -Wnone,none -Werror --trace=none +./input.at:3221: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error -./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy -Wnone,none -Werror --trace=none - +./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none +./input.at:3062: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y +./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -W input.y -Wnone,none -Werror --trace=none +./input.at:2820: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -input.y:10.6-13: error: only midrule actions can be typed: int [-Werror=other] - 10 | exp: {} - | ^~~~~~~~ +70. input.at:3231: testing Invalid file prefix mapping arguments ... +./input.at:3246: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -M foo input.y +69. input.at:3205: ok +./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr2.cc -d input.y +./input.at:2861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall input.y --warnings=none -Werror --trace=none +./input.at:3247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --file-prefix-map foo input.y +64. input.at:2946: ok +./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none +./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -W input.y --warnings=none -Werror --trace=none +./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none +./input.at:3248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -M foo=bar -M baz input.y +49. input.at:2224: ok ./input.at:2697: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dparse.lac.es-capacity-initial=1 -Dparse.lac.memory-trace=full input.y -./input.at:3247: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --file-prefix-map foo input.y -74. named-refs.at:316: testing Many kinds of errors ... -./named-refs.at:384: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y -./input.at:3156: sed 's,.*/$,,' stderr 1>&2 +./input.at:3249: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -M foo= -M baz input.y +./input.at:2825: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +71. named-refs.at:22: testing Tutorial calculator ... 72. named-refs.at:196: testing Undefined and ambiguous references ... ./named-refs.at:254: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o test.c test.y -./named-refs.at:426: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o test.c test.y -./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.d input.y -72. named-refs.at:196: ok -./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none -71. named-refs.at:22: testing Tutorial calculator ... ./named-refs.at:184: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y -74. named-refs.at:316: ok +62. input.at:2840: ok +67. input.at:3148: + ok +./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-none input.y +48. input.at:2191: ok +./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none +70. input.at:3231: ok +./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.d input.y +./input.at:2704: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.cc -Dparse.lac=full -Dparse.lac.es-capacity-initial=1 -Dparse.lac.memory-trace=full input.y + + +72. named-refs.at:196: ok 73. named-refs.at:297: testing Misleading references ... -./input.at:2730: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -W input.y --warnings=none -Werror --trace=none ./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y -./input.at:3221: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.java input.y -./input.at:3248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -M foo=bar -M baz input.y -./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error -./input.at:2704: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.cc -Dparse.lac=full -Dparse.lac.es-capacity-initial=1 -Dparse.lac.memory-trace=full input.y -./input.at:2214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.yy --warnings=none -Werror --trace=none -./input.at:3133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none -./named-refs.at:184: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS -63. input.at:2883: ok +./input.at:2934: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.java input.y 75. named-refs.at:551: testing Missing identifiers in brackets ... ./named-refs.at:559: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y -./input.at:3249: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -M foo= -M baz input.y -75. named-refs.at:551: ok -69. input.at:3205: ok -70. input.at:3231: ok -./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none -./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y -Werror -./input.at:2704: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.java -Dparse.lac=full -Dparse.lac.es-capacity-initial=1 -Dparse.lac.memory-trace=full input.y +74. named-refs.at:316: testing Many kinds of errors ... +./named-refs.at:384: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y + +./named-refs.at:426: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o test.c test.y +77. named-refs.at:583: testing Comments in brackets ... 76. named-refs.at:567: testing Redundant words in brackets ... ./named-refs.at:575: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y -66. input.at:3113: - ok -./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-none input.y - +./named-refs.at:591: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y +61. input.at:2793: ok 78. named-refs.at:599: testing Stray symbols in brackets ... -stderr: -test.y:11.22-29: error: misleading reference: '$foo.bar' [-Werror=other] -test.y:11.8-10: note: refers to: $foo at $1 -test.y:11.12-18: note: possibly meant: $[foo.bar] at $2 +./named-refs.at:184: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./named-refs.at:607: "$PERL" -pi -e 's/\\(\d{3})/chr(oct($1))/ge' test.y || exit 77 +./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y -Werror +./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-none input.y -Werror +66. input.at:3113: ok +76. named-refs.at:567: ok +75. named-refs.at:551: ok +77. named-refs.at:583: ok ./named-refs.at:608: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y +74. named-refs.at:316: ok -./named-refs.at:306: sed 's,.*/$,,' stderr 1>&2 -76. named-refs.at:567: ok +./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S yacc.c -d input.y -77. named-refs.at:583: testing Comments in brackets ... -./named-refs.at:591: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y -78. named-refs.at:599: ok -./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y --warnings=error -./input.at:3156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none -77. named-refs.at:583: ok +./input.at:2704: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Slalr1.java -Dparse.lac=full -Dparse.lac.es-capacity-initial=1 -Dparse.lac.memory-trace=full input.y + 79. named-refs.at:618: testing Redundant words in LHS brackets ... ./named-refs.at:625: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y -81. named-refs.at:648: testing Unresolved references ... -./named-refs.at:676: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y -58. input.at:2675: ok -48. input.at:2191: ok 80. named-refs.at:635: testing Factored LHS ... -./named-refs.at:642: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y -./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-none input.y -Werror - -81. named-refs.at:648: ok -./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y -Wnone,none -Werror --trace=none -79. named-refs.at:618: ok +78. named-refs.at:599: ok +./named-refs.at:642: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: -67. input.at:3148: ok - -input.y:2.15: error: stray '$' [-Werror=other] - +test.y:11.22-29: error: misleading reference: '$foo.bar' [-Werror=other] +test.y:11.8-10: note: refers to: $foo at $1 +test.y:11.12-18: note: possibly meant: $[foo.bar] at $2 +81. named-refs.at:648: testing Unresolved references ... +./named-refs.at:676: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y +stderr: 82. named-refs.at:715: testing $ or @ followed by . or - ... -80. named-refs.at:635: ok +input.y:2.15: error: stray '$' [-Werror=other] ./named-refs.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y -./input.at:2733: sed 's,.*/$,,' stderr 1>&2 83. output.at:68: testing Output files: -dv ... - - +./named-refs.at:306: sed 's,.*/$,,' stderr 1>&2 ./output.at:68: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv foo.y -85. output.at:81: testing Output files: -dv -o foo.c ... -./output.at:81: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -o foo.c foo.y - -./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y --warnings=none -Werror --trace=none -87. output.at:87: testing Output files: api.header.include={"./foo.h"} -dv -y ... +./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr.c -d input.y +79. named-refs.at:618: ok 84. output.at:74: testing Output files: -dv >&- ... ./output.at:74: case "$PREBISON" in *valgrind*) exit 77;; esac -stderr: -89. output.at:95: testing Output files: --fixed-output-files -dv -g --html ... +./input.at:2733: sed 's,.*/$,,' stderr 1>&2 +81. named-refs.at:648: ok + +./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y --warnings=error ./output.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv >&- foo.y ./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret test.y -stdout: - -89. output.at:95: 88. output.at:92: testing Output files: -dv -o foo.tab.c ... -./output.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -o foo.tab.c foo.y -./named-refs.at:185: $PREPARSER ./test input.txt -stderr: - skipped (output.at:95) -86. output.at:84: testing Output files: -dv -y ... -./output.at:84: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -y foo.y ./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-none input.y --warnings=error -./named-refs.at:185: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./output.at:87: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -y foo.y -stderr: +85. output.at:81: testing Output files: -dv -o foo.c ... +58. input.at:2675: ok + +./output.at:81: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -o foo.c foo.y stderr: -./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y -Werror -./output.at:81: find . -type f | +./output.at:68: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 +80. named-refs.at:635: ok -90. output.at:97: testing Output files: -Hfoo.header -v -gfoo.gv --html=foo.html ... +86. output.at:84: testing Output files: -dv -y ... +./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y -Wnone,none -Werror --trace=none +./output.at:84: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -y foo.y stderr: -71. named-refs.at:22: ok -90. output.at:97: skipped (output.at:97) -./output.at:68: find . -type f | +./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.cc -d input.y +83. output.at:68: ok +./output.at:74: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 +./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-none input.y -Wnone,none -Werror --trace=none +87. output.at:87: testing Output files: api.header.include={"./foo.h"} -dv -y ... +./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y -Werror stderr: -stderr: -./output.at:84: find . -type f | +./output.at:81: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 + +./output.at:87: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -y foo.y + +./named-refs.at:306: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o test.c test.y --warnings=none -Werror --trace=none stderr: -./output.at:74: find . -type f | +84. output.at:74: ok +./output.at:84: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 -./output.at:81: grep '#include "foo.h"' foo.c -stdout: -91. output.at:100: testing Output files: -dv -g --xml --fixed-output-files ... -#include "foo.h" -./output.at:92: find . -type f | +./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr.cc -d input.y +89. output.at:95: testing Output files: --fixed-output-files -dv -g --html ... +89. output.at:95: ./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-none input.y --warnings=none -Werror --trace=none +88. output.at:92: testing Output files: -dv -o foo.tab.c ... + skipped (output.at:95) +stderr: +foo.y:1.1-7: warning: POSIX Yacc does not support %define [-Wyacc] +./output.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -o foo.tab.c foo.y +./output.at:87: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 + stderr: -73. named-refs.at:297: ok -85. output.at:81: ok -./output.at:100: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g --xml --fixed-output-files foo.y test.y:4.9: error: stray '$' [-Werror=other] test.y:5.9: error: stray '@' [-Werror=other] - -83. output.at:68: ok - +./output.at:81: grep '#include "foo.h"' foo.c ./output.at:84: grep '#include "y.tab.h"' y.tab.c -./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-none input.y -Wnone,none -Werror --trace=none stdout: -93. output.at:104: testing Output files: %require "3.4" -dv -g --xml -y ... -stderr: -84. output.at:74: ok +./output.at:87: grep '#include "./foo.h"' y.tab.c +#include "foo.h" +stdout: +stdout: +85. output.at:81: ok +86. output.at:84: #include "./foo.h" + ok +90. output.at:97: testing Output files: -Hfoo.header -v -gfoo.gv --html=foo.html ... +87. output.at:87: ok ./named-refs.at:740: sed 's,.*/$,,' stderr 1>&2 +90. output.at:97: skipped (output.at:97) + -:6: warning: deprecated option: '--fixed-output-files', use '-o y.tab.c' [-Wdeprecated] -./output.at:100: find . -type f | - "$PERL" -ne ' - s,\./,,; chomp; - push @file, $_ unless m{^(foo.y|testsuite.log)$}; - END { print join (" ", sort @file), "\n" }' || exit 77 -./output.at:104: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g --xml -y foo.y stderr: -foo.y:1.1-7: warning: POSIX Yacc does not support %define [-Wyacc] -./output.at:87: find . -type f | +./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y --warnings=error +./output.at:92: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 -86. output.at:84: ok -92. output.at:102: testing Output files: -dv -g --xml -y ... +./input.at:2738: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror,none,other input.y + -./input.at:2733: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-none input.y --warnings=none -Werror --trace=none + +91. output.at:100: testing Output files: -dv -g --xml --fixed-output-files ... +./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S glr2.cc -d input.y +73. named-refs.at:297: +92. output.at:102: testing Output files: -dv -g --xml -y ... + ok 88. output.at:92: ok -94. output.at:107: testing Output files: -dv -g --xml -o y.tab.c ... -./output.at:107: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g --xml -o y.tab.c foo.y -91. output.at:100: ok -./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y --warnings=error +./output.at:100: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g --xml --fixed-output-files foo.y ./output.at:102: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g --xml -y foo.y - +94. output.at:107: testing Output files: -dv -g --xml -o y.tab.c ... +96. output.at:112: testing Output files: -dv -g -o foo.c ... 95. output.at:110: testing Output files: -dv -b bar ... ./output.at:110: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -b bar foo.y +./output.at:107: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g --xml -o y.tab.c foo.y +./output.at:112: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g -o foo.c foo.y +93. output.at:104: testing Output files: %require "3.4" -dv -g --xml -y ... +./output.at:104: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g --xml -y foo.y + +./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y -Wnone,none -Werror --trace=none +./input.at:2741: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror,no-all,other input.y stderr: -./output.at:87: grep '#include "./foo.h"' y.tab.c -foo.y:1.1-8: warning: POSIX Yacc does not support %require [-Wyacc] -foo.y:1.10-14: warning: POSIX Yacc does not support string literals [-Wyacc] -./output.at:104: find . -type f | +./output.at:110: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 -./input.at:2738: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror,none,other input.y +97. output.at:116: testing Output files: %header %verbose ... stderr: -./output.at:107: find . -type f | +98. output.at:118: testing Output files: %header %verbose %yacc ... +stderr: +./output.at:102: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 - stderr: -stdout: - -#include "./foo.h" -96. output.at:112: testing Output files: -dv -g -o foo.c ... -./output.at:110: find . -type f | +stderr: +./output.at:107: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 -87. output.at:87: ok - -94. output.at:107: ok -97. output.at:116: testing Output files: %header %verbose ... -./output.at:116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y -stderr: -./output.at:102: find . -type f | +:6: warning: deprecated option: '--fixed-output-files', use '-o y.tab.c' [-Wdeprecated] +./output.at:100: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 -./output.at:112: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -dv -g -o foo.c foo.y -99. output.at:121: testing Output files: %header %verbose %yacc ... -./input.at:2741: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror,no-all,other input.y -./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y -Wnone,none -Werror --trace=none -98. output.at:118: testing Output files: %header %verbose %yacc ... -./output.at:121: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy -100. output.at:125: testing Output files: %file-prefix "bar" %header %verbose ... -./output.at:118: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y -93. output.at:104: ok +./output.at:112: find . -type f | + "$PERL" -ne ' + s,\./,,; chomp; + push @file, $_ unless m{^(foo.y|testsuite.log)$}; + END { print join (" ", sort @file), "\n" }' || exit 77 +./output.at:116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y +./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.d input.y 95. output.at:110: ok - - -./output.at:125: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y 92. output.at:102: ok -./input.at:2746: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror -Wno-error=other input.y -stderr: +./output.at:118: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y stderr: -102. output.at:129: testing Output files: %file-prefix "baz" %output "bar.c" %header %verbose %yacc ... -./output.at:121: find . -type f | +96. output.at:112: ok +foo.y:1.1-8: warning: POSIX Yacc does not support %require [-Wyacc] +foo.y:1.10-14: warning: POSIX Yacc does not support string literals [-Wyacc] +./output.at:104: find . -type f | "$PERL" -ne ' s,\./,,; chomp; - push @file, $_ unless m{^(foo.yy|testsuite.log)$}; + push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 ./named-refs.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret test.y --warnings=none -Werror --trace=none +94. output.at:107: ok +93. output.at:104: ok + stderr: -./output.at:129: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y -./output.at:112: find . -type f | +91. output.at:100: ok +stdout: +stderr: +./named-refs.at:185: $PREPARSER ./test input.txt +./output.at:116: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 -./output.at:116: find . -type f | +./input.at:2935: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -S lalr1.java input.y + +stderr: +./input.at:2746: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror -Wno-error=other input.y +100. output.at:125: testing Output files: %file-prefix "bar" %header %verbose ... +./named-refs.at:185: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./output.at:125: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y +97. output.at:116: stderr: + + ok +stderr: + +71. named-refs.at:22: ok +./output.at:118: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 +99. output.at:121: testing Output files: %header %verbose %yacc ... +102. output.at:129: testing Output files: %file-prefix "baz" %output "bar.c" %header %verbose %yacc ... + 101. output.at:127: testing Output files: %output "bar.c" %header %verbose %yacc ... -stderr: -stderr: -97. output.at:116: ok -103. output.at:136: testing Output files: %header %verbose ... -99. output.at:121: - ok +./output.at:127: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y +82. named-refs.at:715: ok +98. output.at:118: ok +stderr: +./output.at:121: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy +./output.at:129: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y ./output.at:125: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 -./output.at:118: find . -type f | +103. output.at:136: testing Output files: %header %verbose ... +./output.at:136: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy +./input.at:2750: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-error=other -Werror input.y +63. input.at:2883: ok +105. output.at:142: testing Output files: --header=foo.hpp -o foo.c++ ... + + +104. output.at:139: testing Output files: %header %verbose -o foo.c ... + +./output.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c foo.yy +stderr: +./output.at:142: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --header=foo.hpp -o foo.c++ foo.yy +./output.at:127: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 -82. named-refs.at:715: ok -./output.at:127: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.y -96. output.at:112: ok +107. output.at:150: testing Output files: %header "foo.hpp" -o foo.c++ ... +100. output.at:125: ok +108. output.at:154: testing Output files: -o foo.c++ --graph=foo.gph ... +./output.at:150: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c++ foo.yy +106. output.at:146: testing Output files: --header=foo.hpp -o foo.c++ ... stderr: -./output.at:136: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy +stderr: +./output.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --header=foo.hpp -o foo.c++ foo.yy ./output.at:129: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 -./input.at:2750: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-error=other -Werror input.y - -100. output.at:125: ok -104. output.at:139: testing Output files: %header %verbose -o foo.c ... - -105. output.at:142: testing Output files: --header=foo.hpp -o foo.c++ ... -stderr: -./output.at:136: find . -type f | +./output.at:154: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c++ --graph=foo.gph foo.yy +./output.at:121: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 -102. output.at:129: ok -98. output.at:118: ok -./output.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c foo.yy -./output.at:142: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --header=foo.hpp -o foo.c++ foo.yy -106. output.at:146: testing Output files: --header=foo.hpp -o foo.c++ ... -./output.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --header=foo.hpp -o foo.c++ foo.yy +101. output.at:127: ok ./input.at:2754: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror=other -Wno-other input.y stderr: -103. output.at:136: ok -107. output.at:150: testing Output files: %header "foo.hpp" -o foo.c++ ... -./output.at:150: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c++ foo.yy -./output.at:127: find . -type f | +./output.at:136: find . -type f | "$PERL" -ne ' s,\./,,; chomp; - push @file, $_ unless m{^(foo.y|testsuite.log)$}; + push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 - stderr: -108. output.at:154: testing Output files: -o foo.c++ --graph=foo.gph ... -./output.at:154: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c++ --graph=foo.gph foo.yy stderr: -./output.at:142: find . -type f | +./output.at:139: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 -./output.at:139: find . -type f | +99. output.at:121: ok +./output.at:142: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 +110. output.at:167: testing Output files: useless=--header --graph --xml --report=all -Wall -Werror ... 109. output.at:160: testing Output files: %type useless --header --graph --xml --report=all -Wall -Werror ... -101. output.at:127: ok +./output.at:167: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header --graph --xml --report=all -Wall -Werror foo.y +104. output.at:139: ok +stderr: ./output.at:160: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header --graph --xml --report=all -Wall -Werror foo.y - stderr: - -59. input.at:2719: ok ./output.at:154: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 -110. output.at:167: testing Output files: useless=--header --graph --xml --report=all -Wall -Werror ... -./output.at:167: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header --graph --xml --report=all -Wall -Werror foo.y -stderr: +102. output.at:129: ok stderr: +103. output.at:136: ok ./output.at:146: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 -108. output.at:154: ok -111. output.at:173: testing Output files: %defines -o foo.c++ ... ./output.at:150: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 -104. output.at:139: ok +105. output.at:142: ok +111. output.at:173: testing Output files: %defines -o foo.c++ ... + ./output.at:173: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c++ foo.yy -113. output.at:191: testing Output files: lalr1.cc ... -112. output.at:176: testing Output files: %defines "foo.hpp" -o foo.c++ ... -107. output.at:150: ok +108. output.at:154: ok 106. output.at:146: ok -./output.at:191: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy -./output.at:176: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c++ foo.yy -105. output.at:142: ok +107. output.at:150: ok + + + +112. output.at:176: testing Output files: %defines "foo.hpp" -o foo.c++ ... +./output.at:176: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o foo.c++ foo.yy stderr: foo.y:1.13-19: error: symbol 'useless' is used, but is not defined as a token and has no rules [-Werror=other] foo.y: error: 1 nonterminal useless in grammar [-Werror=other] @@ -4632,399 +4667,401 @@ s,\./,,; chomp; push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 -stderr: - -./output.at:191: find . -type f | - "$PERL" -ne ' - s,\./,,; chomp; - push @file, $_ unless m{^(foo.yy|testsuite.log)$}; - END { print join (" ", sort @file), "\n" }' || exit 77 +113. output.at:191: testing Output files: lalr1.cc ... +stderr: +59. input.at:2719: + ok +./output.at:191: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy +foo.y:1.1-15: error: %define variable 'useless' is not used +116. output.at:200: testing Output files: lalr1.cc %verbose %locations ... +115. output.at:197: testing Output files: lalr1.cc %header %verbose ... 114. output.at:194: testing Output files: lalr1.cc %verbose ... -./output.at:194: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy +./output.at:200: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy stderr: -./output.at:176: find . -type f | +109. output.at:160: ./output.at:194: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy + ok +./output.at:197: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy +./output.at:167: find . -type f | "$PERL" -ne ' s,\./,,; chomp; - push @file, $_ unless m{^(foo.yy|testsuite.log)$}; + push @file, $_ unless m{^(foo.y|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 - -109. output.at:160: ok -stderr: -stderr: 118. output.at:206: testing Output files: lalr1.cc %header %verbose ... - -115. output.at:197: testing Output files: lalr1.cc %header %verbose ... -./output.at:197: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy -foo.y:1.1-15: error: %define variable 'useless' is not used -./output.at:167: find . -type f | +./output.at:173: find . -type f | "$PERL" -ne ' s,\./,,; chomp; - push @file, $_ unless m{^(foo.y|testsuite.log)$}; + push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 117. output.at:203: testing Output files: lalr1.cc %header %verbose %locations ... -116. output.at:200: testing Output files: lalr1.cc %verbose %locations ... ./output.at:203: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy -./output.at:173: find . -type f | +stderr: +./output.at:176: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 +119. output.at:210: testing Output files: lalr1.cc %header %verbose %locations -o subdir/foo.cc ... stderr: -./output.at:194: find . -type f | +111. output.at:173: ok + + +./output.at:206: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret subdir/foo.yy +./output.at:191: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 -./output.at:200: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy 112. output.at:176: ok - -./output.at:206: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret subdir/foo.yy -114. output.at:194: ok -110. output.at:167: ok -113. output.at:191: ok -119. output.at:210: testing Output files: lalr1.cc %header %verbose %locations -o subdir/foo.cc ... - stderr: -./output.at:203: find . -type f | +stderr: +110. output.at:167: ok +113. output.at:191: ./output.at:197: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 -stderr: -./output.at:197: find . -type f | +./output.at:194: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 - -111. output.at:173: ok + ok 121. output.at:220: testing Output files: lalr1.cc %header %locations %verbose %file-prefix "output_dir/foo" ... - -stderr: -117. output.at:203: ok 120. output.at:215: testing Output files: lalr1.cc %header %verbose %file-prefix "output_dir/foo" ... - stderr: ./output.at:200: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 +115. output.at:197: ok + + +114. output.at:194: ok + +stderr: ./output.at:206: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(subdir/foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 -115. output.at:197: ok - +116. output.at:200: ok +stderr: +./output.at:203: find . -type f | + "$PERL" -ne ' + s,\./,,; chomp; + push @file, $_ unless m{^(foo.yy|testsuite.log)$}; + END { print join (" ", sort @file), "\n" }' || exit 77 122. output.at:226: testing Output files: lalr1.cc %header %locations api.location.file=none %require "3.2" ... -./output.at:226: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy 124. output.at:237: testing Output files: lalr1.cc %header %locations api.location.file="$at_dir/foo.loc.hh" %require "3.2" ... +123. output.at:231: testing Output files: lalr1.cc %header %locations api.location.file="foo.loc.hh" %require "3.2" ... +./output.at:226: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy ./output.at:237: "$PERL" -pi -e 's{\$at_dir}'"{$at_group_dir}g" foo.yy || exit 77 -./output.at:237: rm -f foo.yy.bak -123. output.at:231: testing Output files: lalr1.cc %header %locations api.location.file="foo.loc.hh" %require "3.2" ... -./output.at:231: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy -126. output.at:272: testing Conflicting output files: %header "foo.output" -v ... -116. output.at:200: ok -./output.at:237: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy ./output.at:206: grep 'include .subdir/' foo.tab.cc +./output.at:231: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy +./output.at:206: grep 'include .subdir/' foo.tab.hh 125. output.at:267: testing Conflicting output files: --graph="foo.tab.c" ... ./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y +./output.at:237: rm -f foo.yy.bak + +117. output.at:203: +./output.at:237: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret foo.yy + ok +126. output.at:272: testing Conflicting output files: %header "foo.output" -v ... +118. output.at:206: ok ./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v foo.y + + stderr: -./output.at:206: grep 'include .subdir/' foo.tab.hh ./output.at:226: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 - stderr: +128. output.at:282: testing Conflicting output files: -o foo.y ... +./output.at:282: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o foo.y foo.y ./output.at:231: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 127. output.at:277: testing Conflicting output files: lalr1.cc %header %locations --graph="location.hh" ... -./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --graph="location.hh" foo.y -122. output.at:226: 118. output.at:206: ok - ok ./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y -Werror -./output.at:210: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o subdir/foo.cc subdir/foo.yy - -128. output.at:282: testing Conflicting output files: -o foo.y ... +129. output.at:328: testing Output file name: `~!@#$%^&*()-=_+{}[]|\:;<>, .' ... +./output.at:328: touch "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.tmp" || exit 77 stderr: +./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --graph="location.hh" foo.y ./output.at:237: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 -./output.at:282: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o foo.y foo.y +130. output.at:335: testing Output file name: ( ... +./output.at:335: touch "(.tmp" || exit 77 +123. output.at:231: ok ./output.at:215: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret gram_dir/foo.yy -stderr: +./output.at:335: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "(.c" --header="(.h" glr.y +124. output.at:237: ok +./output.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.c" --header="\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.h" glr.y +./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v foo.y -Werror +122. output.at:226: ok +./output.at:282: cat foo.y -123. output.at:231: ok +./output.at:210: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o subdir/foo.cc subdir/foo.yy +128. output.at:282: ok stderr: -./output.at:210: find . -type f | - "$PERL" -ne ' - s,\./,,; chomp; - push @file, $_ unless m{^(subdir/foo.yy|testsuite.log)$}; - END { print join (" ", sort @file), "\n" }' || exit 77 -foo.y: error: conflicting outputs to file 'foo.tab.c' [-Werror=other] -./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v foo.y -Werror -129. output.at:328: testing Output file name: `~!@#$%^&*()-=_+{}[]|\:;<>, .' ... -./output.at:328: touch "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.tmp" || exit 77 -./output.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.c" --header="\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.h" glr.y -124. output.at:237: ok ./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="location.hh" foo.y -Werror +foo.y: error: conflicting outputs to file 'foo.tab.c' [-Werror=other] stderr: -./output.at:267: sed 's,.*/$,,' stderr 1>&2 + +./output.at:335: ls "(.c" "(.h" +131. output.at:336: testing Output file name: ) ... +./output.at:336: touch ").tmp" || exit 77 ./output.at:215: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(gram_dir/foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 - -./output.at:210: grep 'include .subdir/' subdir/foo.cc -./output.at:282: cat foo.y +./output.at:336: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o ").c" --header=").h" glr.y +stdout: +132. output.at:337: testing Output file name: # ... +./output.at:337: touch "#.tmp" || exit 77 ./output.at:328: ls "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.c" "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.h" +(.c +(.h +stderr: stderr: -./output.at:210: grep 'include .subdir/' subdir/foo.hh -foo.y: error: conflicting outputs to file 'foo.output' [-Werror=other] -./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y --warnings=error stdout: -130. output.at:335: testing Output file name: ( ... -./output.at:335: touch "(.tmp" || exit 77 -131. output.at:336: testing Output file name: ) ... -./output.at:336: touch ").tmp" || exit 77 +./output.at:335: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "(.c" +foo.y: error: conflicting outputs to file 'foo.output' [-Werror=other] + `~!@#$%^&*()-=_+{}[]|\:;<>, .'.c `~!@#$%^&*()-=_+{}[]|\:;<>, .'.h - +./output.at:210: find . -type f | + "$PERL" -ne ' + s,\./,,; chomp; + push @file, $_ unless m{^(subdir/foo.yy|testsuite.log)$}; + END { print join (" ", sort @file), "\n" }' || exit 77 ./output.at:328: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.c" -132. output.at:337: testing Output file name: # ... -./output.at:337: touch "#.tmp" || exit 77 -119. output.at:210: ok -stderr: -foo.y: error: conflicting outputs to file 'location.hh' [-Werror=other] -./output.at:335: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "(.c" --header="(.h" glr.y -128. output.at:282: ok -./output.at:337: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "#.c" --header="#.h" glr.y +./output.at:267: sed 's,.*/$,,' stderr 1>&2 ./output.at:220: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret gram_dir/foo.yy 120. output.at:215: ok ./output.at:272: sed 's,.*/$,,' stderr 1>&2 -./output.at:277: sed 's,.*/$,,' stderr 1>&2 -./output.at:336: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o ").c" --header=").h" glr.y +stderr: 133. output.at:338: testing Output file name: @@ ... ./output.at:338: touch "@@.tmp" || exit 77 +./output.at:338: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@@.c" --header="@@.h" glr.y +foo.y: error: conflicting outputs to file 'location.hh' [-Werror=other] +./output.at:337: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "#.c" --header="#.h" glr.y ./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v foo.y --warnings=error -./output.at:337: ls "#.c" "#.h" -./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y -Wnone,none -Werror --trace=none +./output.at:210: grep 'include .subdir/' subdir/foo.cc +134. output.at:339: testing Output file name: @{ ... +./output.at:339: touch "@{.tmp" || exit 77 +./output.at:339: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@{.c" --header="@{.h" glr.y +./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y --warnings=error +./output.at:210: grep 'include .subdir/' subdir/foo.hh +./output.at:277: sed 's,.*/$,,' stderr 1>&2 +119. output.at:210: ok +./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="location.hh" foo.y --warnings=error +./output.at:336: ls ").c" ").h" stdout: +).c +).h stderr: -./output.at:338: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@@.c" --header="@@.h" glr.y -#.c -#.h + ./output.at:220: find . -type f | "$PERL" -ne ' s,\./,,; chomp; push @file, $_ unless m{^(gram_dir/foo.yy|testsuite.log)$}; END { print join (" ", sort @file), "\n" }' || exit 77 -./output.at:337: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "#.c" - -./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="location.hh" foo.y --warnings=error -./output.at:335: ls "(.c" "(.h" - - -./output.at:336: ls ").c" ").h" -121. output.at:220: stdout: - ok -stdout: -(.c -(.h -./output.at:335: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "(.c" -).c -).h -./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="location.hh" foo.y -Wnone,none -Werror --trace=none -./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v foo.y -Wnone,none -Werror --trace=none +./output.at:339: ls "@{.c" "@{.h" ./output.at:336: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c ").c" -134. output.at:339: testing Output file name: @{ ... -./output.at:339: touch "@{.tmp" || exit 77 -135. output.at:340: testing Output file name: @} ... -./output.at:340: touch "@}.tmp" || exit 77 -./output.at:339: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@{.c" --header="@{.h" glr.y -136. output.at:341: testing Output file name: [ ... -./output.at:341: touch "[.tmp" || exit 77 -./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y --warnings=none -Werror --trace=none +121. output.at:220: ok ./output.at:338: ls "@@.c" "@@.h" - stdout: +@{.c +@{.h +stdout: +135. output.at:340: testing Output file name: @} ... +./output.at:340: touch "@}.tmp" || exit 77 @@.c @@.h + +./output.at:339: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "@{.c" +./output.at:338: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "@@.c" +./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y -Wnone,none -Werror --trace=none +./output.at:337: ls "#.c" "#.h" ./output.at:340: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@}.c" --header="@}.h" glr.y + +./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="location.hh" foo.y -Wnone,none -Werror --trace=none +stdout: +#.c +#.h +./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v foo.y -Wnone,none -Werror --trace=none +./output.at:337: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "#.c" +136. output.at:341: testing Output file name: [ ... +./output.at:341: touch "[.tmp" || exit 77 ./output.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "[.c" --header="[.h" glr.y -./output.at:338: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "@@.c" -./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v foo.y --warnings=none -Werror --trace=none -./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="location.hh" foo.y --warnings=none -Werror --trace=none -./output.at:339: ls "@{.c" "@{.h" 137. output.at:342: testing Output file name: ] ... ./output.at:342: touch "].tmp" || exit 77 -stdout: -@{.c -@{.h -./output.at:339: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "@{.c" +./output.at:277: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="location.hh" foo.y --warnings=none -Werror --trace=none +./output.at:267: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --graph="foo.tab.c" foo.y --warnings=none -Werror --trace=none +./output.at:272: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v foo.y --warnings=none -Werror --trace=none ./output.at:340: ls "@}.c" "@}.h" -./output.at:342: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "].c" --header="].h" glr.y -./output.at:267: cat foo.y -./output.at:341: ls "[.c" "[.h" stdout: @}.c @}.h -stdout: -125. output.at:267: ok -./output.at:272: cat foo.y +./output.at:342: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "].c" --header="].h" glr.y ./output.at:340: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "@}.c" +./output.at:341: ls "[.c" "[.h" +./output.at:272: cat foo.y +./output.at:277: cat foo.y +stdout: [.c [.h -./output.at:277: cat foo.y +./output.at:267: cat foo.y ./output.at:341: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "[.c" -126. output.at:272: ok 127. output.at:277: ok +125. output.at:267: ok +126. output.at:272: ok ./output.at:342: ls "].c" "].h" stdout: + + ].c ].h - ./output.at:342: $CC $CFLAGS $CPPFLAGS -c -o glr.o -c "].c" - 138. output.at:363: testing Graph with no conflicts ... ./output.at:363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y -139. output.at:403: testing Graph with unsolved S/R ... -./output.at:403: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y 140. output.at:473: testing Graph with solved S/R ... +139. output.at:403: testing Graph with unsolved S/R ... ./output.at:473: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y +./output.at:403: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y stderr: -./output.at:363: grep -v // input.gv stderr: -138. output.at:363: ok +stderr: +./output.at:363: grep -v // input.gv +input.y:6.5-7: warning: rule useless in parser due to conflicts [-Wother] +input.y:14.10-18: warning: rule useless in parser due to conflicts [-Wother] +input.y:15.10-18: warning: rule useless in parser due to conflicts [-Wother] +./output.at:473: grep -v // input.gv input.y: warning: 3 shift/reduce conflicts [-Wconflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:10.10-18: warning: rule useless in parser due to conflicts [-Wother] input.y:11.10-18: warning: rule useless in parser due to conflicts [-Wother] input.y:12.10-18: warning: rule useless in parser due to conflicts [-Wother] ./output.at:403: grep -v // input.gv -stderr: -input.y:6.5-7: warning: rule useless in parser due to conflicts [-Wother] -input.y:14.10-18: warning: rule useless in parser due to conflicts [-Wother] -input.y:15.10-18: warning: rule useless in parser due to conflicts [-Wother] -./output.at:473: grep -v // input.gv -139. output.at:403: ok +138. output.at:363: ok 140. output.at:473: ok -stderr: +139. output.at:403: ok + -stdout: stderr: + stderr: stdout: stdout: - ./output.at:335: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "(.cc" --header="(.hh" cxx.y - -./output.at:336: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o ").cc" --header=").hh" cxx.y -./output.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.cc" --header="\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.hh" cxx.y 141. output.at:538: testing Graph with R/R ... ./output.at:538: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y -./output.at:328: ls "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.cc" "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.hh" 143. output.at:641: testing Graph with a reduction rule both enabled and disabled ... -stdout: -`~!@#$%^&*()-=_+{}[]|\:;<>, .'.cc -`~!@#$%^&*()-=_+{}[]|\:;<>, .'.hh -./output.at:328: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.cc" -142. output.at:576: testing Graph with reductions with multiple LAT ... -./output.at:576: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y ./output.at:641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y +./output.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.cc" --header="\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.hh" cxx.y ./output.at:335: ls "(.cc" "(.hh" -./output.at:336: ls ").cc" ").hh" -stdout: +142. output.at:576: testing Graph with reductions with multiple LAT ... stdout: -stderr: -).cc -).hh -stderr: +./output.at:576: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall --graph input.y (.cc (.hh +./output.at:335: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "(.cc" +stderr: +./output.at:328: ls "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.cc" "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.hh" +stderr: stderr: -./output.at:336: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c ").cc" -stdout: input.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:4.3: warning: rule useless in parser due to conflicts [-Wother] -stdout: -./output.at:335: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "(.cc" ./output.at:538: grep -v // input.gv +stdout: +stdout: +stderr: stderr: ./output.at:338: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@@.cc" --header="@@.hh" cxx.y +stdout: +stdout: +stdout: ./output.at:337: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "#.cc" --header="#.hh" cxx.y +141. output.at:538: ok +`~!@#$%^&*()-=_+{}[]|\:;<>, .'.cc +`~!@#$%^&*()-=_+{}[]|\:;<>, .'.hh +./output.at:339: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@{.cc" --header="@{.hh" cxx.y +./output.at:336: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o ").cc" --header=").hh" cxx.y +./output.at:328: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "\`~!@#\$%^&*()-=_+{}[]|\\:;<>, .'.cc" +stderr: input.y: warning: 3 reduce/reduce conflicts [-Wconflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:2.14-18: warning: rule useless in parser due to conflicts [-Wother] input.y:5.3: warning: rule useless in parser due to conflicts [-Wother] ./output.at:576: grep -v // input.gv -141. output.at:538: ok + 142. output.at:576: ok -./output.at:338: ls "@@.cc" "@@.hh" ./output.at:337: ls "#.cc" "#.hh" +./output.at:338: ls "@@.cc" "@@.hh" +./output.at:339: ls "@{.cc" "@{.hh" stdout: stdout: - -stderr: -@@.cc -@@.hh #.cc #.hh -stdout: +@{.cc +@{.hh ./output.at:337: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "#.cc" +./output.at:339: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "@{.cc" +144. output.at:744: testing C++ Output File Prefix Mapping ... +stdout: +@@.cc +@@.hh +./output.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o out/x1.cc -M out/=bar/ x1.yy ./output.at:338: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "@@.cc" -./output.at:339: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@{.cc" --header="@{.hh" cxx.y +./output.at:336: ls ").cc" ").hh" -144. output.at:744: testing C++ Output File Prefix Mapping ... -stderr: -stderr: stderr: stdout: -./output.at:775: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o out/x1.cc -M out/=bar/ x1.yy -input.y: warning: 4 shift/reduce conflicts [-Wconflicts-sr] -input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stdout: -./output.at:641: grep -v // input.gv -./output.at:339: ls "@{.cc" "@{.hh" -./output.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "[.cc" --header="[.hh" cxx.y +).cc +).hh +./output.at:336: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c ").cc" ./output.at:340: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "@}.cc" --header="@}.hh" cxx.y 145. diagnostics.at:84: testing Warnings ... +stderr: stdout: -143. output.at:641: ok -@{.cc -@{.hh -./diagnostics.at:84: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y -./output.at:339: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "@{.cc" ./output.at:775: $CXX $CPPFLAGS $CXXFLAGS -Iout/include -c -o out/x1.o out/x1.cc - -./output.at:341: ls "[.cc" "[.hh" +./output.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "[.cc" --header="[.hh" cxx.y +./diagnostics.at:84: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./output.at:340: ls "@}.cc" "@}.hh" stdout: -146. diagnostics.at:133: testing Single point locations ... +stderr: +@}.cc +@}.hh +input.y: warning: 4 shift/reduce conflicts [-Wconflicts-sr] +input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +./output.at:641: grep -v // input.gv +./output.at:340: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "@}.cc" +./output.at:341: ls "[.cc" "[.hh" stdout: [.cc [.hh -@}.cc -@}.hh +stderr: +stdout: ./output.at:341: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "[.cc" -./output.at:340: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "@}.cc" +143. output.at:641: ok +./output.at:342: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "].cc" --header="].hh" cxx.y ./diagnostics.at:84: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) @@ -5034,11 +5071,16 @@ } ' experr || exit 77 ./diagnostics.at:84: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y -./diagnostics.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y -stderr: + +./output.at:342: ls "].cc" "].hh" stdout: +].cc +].hh +146. diagnostics.at:133: testing Single point locations ... +./output.at:342: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "].cc" 145. diagnostics.at:84: ok -./output.at:342: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o "].cc" --header="].hh" cxx.y + +./diagnostics.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:133: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) @@ -5047,17 +5089,10 @@ $_ = "" if $example % 2 == 0; } ' experr || exit 77 -./output.at:342: ls "].cc" "].hh" -stdout: -].cc -].hh -./diagnostics.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y -./output.at:342: $CXX $CPPFLAGS $CXXFLAGS -c -o cxx.o -c "].cc" - 147. diagnostics.at:182: testing Line is too short, and then you die ... +./diagnostics.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y 146. diagnostics.at:133: ok ./diagnostics.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y - ./diagnostics.at:182: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) @@ -5066,10 +5101,13 @@ $_ = "" if $example % 2 == 0; } ' experr || exit 77 -148. diagnostics.at:217: testing Zero-width characters ... + ./diagnostics.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y 147. diagnostics.at:182: ok +148. diagnostics.at:217: testing Zero-width characters ... + ./diagnostics.at:217: "$PERL" -pi -e 's{\^M}{\r}g;s{\\(\d{3}|.)}{$v = $1; $v =~ /\A\d+\z/ ? chr($v) : $v}ge' input.y experr || exit 77 +149. diagnostics.at:235: testing Tabulations and multibyte characters ... ./diagnostics.at:217: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:217: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; @@ -5079,22 +5117,10 @@ $_ = "" if $example % 2 == 0; } ' experr || exit 77 - ./diagnostics.at:217: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y +./diagnostics.at:235: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y 148. diagnostics.at:217: ok -149. diagnostics.at:235: testing Tabulations and multibyte characters ... -stderr: -stdout: -129. output.at:328: ok -stderr: -stdout: - -131. output.at:336: ok -./diagnostics.at:235: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y -151. diagnostics.at:303: testing Special files ... -150. diagnostics.at:282: testing Tabulations and multibyte characters ... -./diagnostics.at:303: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:235: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) @@ -5103,22 +5129,17 @@ $_ = "" if $example % 2 == 0; } ' experr || exit 77 - +150. diagnostics.at:282: testing Tabulations and multibyte characters ... ./diagnostics.at:235: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y -./diagnostics.at:303: "$PERL" -pi -e ' - s{()}{ $1 eq "" ? $1 : "" }ge; - if (/Example/) - { - ++$example; - $_ = "" if $example % 2 == 0; - } -' experr || exit 77 -./diagnostics.at:303: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y +stderr: ./diagnostics.at:282: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y -152. diagnostics.at:328: testing Complaints from M4 ... -./diagnostics.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y -151. diagnostics.at:303: ok -149. diagnostics.at:235: ok +stdout: +130. output.at:335: ok +stderr: +stdout: +stderr: +133. output.at:338: ok +stdout: ./diagnostics.at:282: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) @@ -5127,8 +5148,41 @@ $_ = "" if $example % 2 == 0; } ' experr || exit 77 -./diagnostics.at:282: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y -./diagnostics.at:328: "$PERL" -pi -e ' +149. diagnostics.at:235: 129. output.at:328: ./diagnostics.at:282: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y + ok + ok + +stderr: +stdout: +stderr: +132. output.at:337: ok +stdout: + +134. output.at:339: ok + +151. diagnostics.at:303: testing Special files ... + +150. diagnostics.at:282: ok + +153. diagnostics.at:351: testing Carriage return ... +154. diagnostics.at:372: testing CR NL ... + +stderr: + +./diagnostics.at:303: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y +stdout: +152. diagnostics.at:328: testing Complaints from M4 ... +131. output.at:336: 157. diagnostics.at:465: testing Screen width: 60 columns ... + ok +./diagnostics.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y +./diagnostics.at:372: "$PERL" -pi -e 's{\^M}{\r}g;s{\\(\d{3}|.)}{$v = $1; $v =~ /\A\d+\z/ ? chr($v) : $v}ge' input.y experr || exit 77 +155. diagnostics.at:399: testing Screen width: 200 columns ... +156. diagnostics.at:432: testing Screen width: 80 columns ... +./diagnostics.at:465: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=60 bison -fcaret --color=debug -Wall,cex input.y +./diagnostics.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y +./diagnostics.at:351: "$PERL" -pi -e 's{\^M}{\r}g;s{\\(\d{3}|.)}{$v = $1; $v =~ /\A\d+\z/ ? chr($v) : $v}ge' input.y experr || exit 77 +./diagnostics.at:399: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=200 bison -fcaret --color=debug -Wall,cex input.y +./diagnostics.at:303: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { @@ -5136,20 +5190,12 @@ $_ = "" if $example % 2 == 0; } ' experr || exit 77 - -./diagnostics.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y - -153. diagnostics.at:351: testing Carriage return ... -154. diagnostics.at:372: testing CR NL ... +./diagnostics.at:351: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y stderr: stdout: -150. diagnostics.at:282: ok -133. output.at:338: ok -./diagnostics.at:351: "$PERL" -pi -e 's{\^M}{\r}g;s{\\(\d{3}|.)}{$v = $1; $v =~ /\A\d+\z/ ? chr($v) : $v}ge' input.y experr || exit 77 - -./diagnostics.at:351: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y -./diagnostics.at:372: "$PERL" -pi -e 's{\^M}{\r}g;s{\\(\d{3}|.)}{$v = $1; $v =~ /\A\d+\z/ ? chr($v) : $v}ge' input.y experr || exit 77 +136. output.at:341: ok +./diagnostics.at:303: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y ./diagnostics.at:351: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) @@ -5158,16 +5204,8 @@ $_ = "" if $example % 2 == 0; } ' experr || exit 77 -155. diagnostics.at:399: testing Screen width: 200 columns ... -./diagnostics.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y -152. diagnostics.at:328: ok ./diagnostics.at:351: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y -156. diagnostics.at:432: testing Screen width: 80 columns ... stderr: -stdout: -153. diagnostics.at:351: 130. output.at:335: ok - ok -./diagnostics.at:399: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=200 bison -fcaret --color=debug -Wall,cex input.y ./diagnostics.at:372: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) @@ -5176,17 +5214,21 @@ $_ = "" if $example % 2 == 0; } ' experr || exit 77 - - -stderr: - -./diagnostics.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y stdout: +153. diagnostics.at:351: ok + ./diagnostics.at:432: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=80 bison -fcaret --color=debug -Wall,cex input.y -137. output.at:342: ok -159. diagnostics.at:527: testing Counterexamples ... -157. diagnostics.at:465: testing Screen width: 60 columns ... +./diagnostics.at:328: "$PERL" -pi -e ' + s{()}{ $1 eq "" ? $1 : "" }ge; + if (/Example/) + { + ++$example; + $_ = "" if $example % 2 == 0; + } +' experr || exit 77 158. diagnostics.at:504: testing Suggestions ... +135. output.at:340: ./diagnostics.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y + ok ./diagnostics.at:399: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) @@ -5195,12 +5237,12 @@ $_ = "" if $example % 2 == 0; } ' experr || exit 77 - -154. diagnostics.at:372: ok +./diagnostics.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y +159. diagnostics.at:527: testing Counterexamples ... ./diagnostics.at:399: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=200 bison -fcaret -Wall,cex input.y -./diagnostics.at:465: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=60 bison -fcaret --color=debug -Wall,cex input.y -./diagnostics.at:527: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y -./diagnostics.at:432: "$PERL" -pi -e ' +151. diagnostics.at:303: ok + +./diagnostics.at:465: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { @@ -5208,10 +5250,8 @@ $_ = "" if $example % 2 == 0; } ' experr || exit 77 -160. diagnostics.at:645: testing Deep Counterexamples ... -./diagnostics.at:504: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y -./diagnostics.at:432: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=80 bison -fcaret -Wall,cex input.y -./diagnostics.at:504: "$PERL" -pi -e ' +./diagnostics.at:465: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=60 bison -fcaret -Wall,cex input.y +./diagnostics.at:432: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { @@ -5220,8 +5260,19 @@ } ' experr || exit 77 +./diagnostics.at:527: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y +./diagnostics.at:504: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y +154. diagnostics.at:372: ok +160. diagnostics.at:645: testing Deep Counterexamples ... +./diagnostics.at:432: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=80 bison -fcaret -Wall,cex input.y +161. diagnostics.at:713: testing Indentation with message suppression ... + +./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wno-other input.y +./diagnostics.at:645: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y 155. diagnostics.at:399: ok -./diagnostics.at:465: "$PERL" -pi -e ' +152. diagnostics.at:328: + ok +./diagnostics.at:504: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { @@ -5230,7 +5281,11 @@ } ' experr || exit 77 ./diagnostics.at:504: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y -./diagnostics.at:527: "$PERL" -pi -e ' +162. skeletons.at:25: testing Relative skeleton file names ... +./skeletons.at:27: mkdir tmp + + +./diagnostics.at:645: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { @@ -5238,17 +5293,16 @@ $_ = "" if $example % 2 == 0; } ' experr || exit 77 -stderr: -stdout: -./diagnostics.at:645: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret --color=debug -Wall,cex input.y -161. diagnostics.at:713: testing Indentation with message suppression ... -./diagnostics.at:465: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" COLUMNS=60 bison -fcaret -Wall,cex input.y -./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wno-other input.y -132. output.at:337: ok -156. diagnostics.at:432: ok -./diagnostics.at:527: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y 158. diagnostics.at:504: ok -./diagnostics.at:645: "$PERL" -pi -e ' +./diagnostics.at:645: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y +157. diagnostics.at:465: ok +165. skeletons.at:166: testing Complaining during macro argument expansion ... +163. skeletons.at:85: testing Installed skeleton file names ... +./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wno-other input.y -Werror +./skeletons.at:189: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input1.y +./skeletons.at:63: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret tmp/input-gram.y +./skeletons.at:120: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --skeleton=yacc.c -o input-cmd-line.c input-cmd-line.y +./diagnostics.at:527: "$PERL" -pi -e ' s{()}{ $1 eq "" ? $1 : "" }ge; if (/Example/) { @@ -5257,25 +5311,29 @@ } ' experr || exit 77 stderr: +160. diagnostics.at:645: ok stdout: -./output.at:782: sed -ne 's/#line [0-9][0-9]* "/#line "/p;/INCLUDED/p;/\\file/{p;n;p;}' out/include/ast/loc.hh -./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wno-other input.y -Werror -157. diagnostics.at:465: ok -./diagnostics.at:645: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y +./output.at:782: sed -ne 's/#line [0-9][0-9]* "/#line "/p;/INCLUDED/p;/\\file/{p;n;p;}' out/include/ast/loc.hh +./diagnostics.at:527: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; LC_ALL="$locale" bison -fcaret -Wall,cex input.y +164. skeletons.at:142: testing Boolean=variables: invalid skeleton defaults ... +./skeletons.at:155: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y ./output.at:794: sed -ne 's/^#line [0-9][0-9]* "/#line "/p;/INCLUDED/p;/\\file/{p;n;p;}' out/x1.hh +156. diagnostics.at:432: ok +./skeletons.at:64: cat input-gram.tab.c +./skeletons.at:68: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input-gram.y ./output.at:806: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o out/x2.cc -M out/=bar/ x2.yy +166. skeletons.at:248: testing Fatal errors make M4 exit immediately ... -162. skeletons.at:25: testing Relative skeleton file names ... -./skeletons.at:27: mkdir tmp - -165. skeletons.at:166: testing Complaining during macro argument expansion ... +./skeletons.at:69: cat input-gram.tab.c +./skeletons.at:262: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input1.y +167. skeletons.at:302: testing Fatal errors but M4 continues producing output ... +./skeletons.at:314: "$PERL" gen-skel.pl > skel.c || exit 77 +./skeletons.at:121: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input-cmd-line input-cmd-line.c $LIBS +./skeletons.at:322: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -./skeletons.at:189: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input1.y stderr: -160. diagnostics.at:645: 159. diagnostics.at:527: ok - ok input.y:2.1-12: error: deprecated directive: '%pure-parser', use '%define api.pure' [-Werror=deprecated] 2 | %pure-parser | ^~~~~~~~~~~~ @@ -5284,25 +5342,21 @@ 3 | %error-verbose | ^~~~~~~~~~~~~~ | %define parse.error verbose +168. sets.at:27: testing Nullable ... +./sets.at:42: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=sets input.y ./output.at:806: $CXX $CPPFLAGS $CXXFLAGS -Iout/include -c -o out/x2.o out/x2.cc -164. skeletons.at:142: testing Boolean=variables: invalid skeleton defaults ... -163. skeletons.at:85: testing Installed skeleton file names ... -./skeletons.at:155: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +./skeletons.at:73: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --skeleton=tmp/skel.c tmp/input-cmd-line.y +./skeletons.at:209: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input2.y +159. diagnostics.at:527: ok ./diagnostics.at:725: sed 's,.*/$,,' stderr 1>&2 -166. skeletons.at:248: testing Fatal errors make M4 exit immediately ... -./skeletons.at:262: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input1.y -./skeletons.at:120: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --skeleton=yacc.c -o input-cmd-line.c input-cmd-line.y -./skeletons.at:63: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret tmp/input-gram.y -./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wno-other input.y --warnings=error -./skeletons.at:121: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input-cmd-line input-cmd-line.c $LIBS - +164. skeletons.at:142: ok +169. sets.at:111: testing Broken Closure ... +167. skeletons.at:302: ok +./sets.at:125: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=sets input.y +./skeletons.at:74: cat input-cmd-line.tab.c -./skeletons.at:64: cat input-gram.tab.c -167. skeletons.at:302: testing Fatal errors but M4 continues producing output ... -./skeletons.at:314: "$PERL" gen-skel.pl > skel.c || exit 77 -168. sets.at:27: testing Nullable ... -./sets.at:42: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=sets input.y stderr: +./skeletons.at:223: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input3.y bison (GNU Bison) 3.8.2 RITEM 0: e $end (rule 0) @@ -5374,197 +5428,16 @@ State 3: rule 0: -./skeletons.at:68: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input-gram.y -./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wno-other input.y -Wnone,none -Werror --trace=none ./sets.at:43: sed -f extract.sed stderr -164. skeletons.at:142: ok -./skeletons.at:322: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wno-other input.y --warnings=error ./skeletons.at:279: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input2.y -./skeletons.at:209: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input2.y -168. sets.at:27: ok -./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wno-other input.y --warnings=none -Werror --trace=none -stderr: -./skeletons.at:69: cat input-gram.tab.c -stdout: -stderr: -134. output.at:339: ok -stdout: -./skeletons.at:73: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --skeleton=tmp/skel.c tmp/input-cmd-line.y - -./skeletons.at:223: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input3.y -135. output.at:340: ok -167. skeletons.at:302: ok - +162. skeletons.at:25: ok -161. diagnostics.at:713: ok -169. sets.at:111: testing Broken Closure ... -./skeletons.at:74: cat input-cmd-line.tab.c -stderr: -171. sets.at:228: testing Accept ... -./sets.at:240: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y -./sets.at:125: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=sets input.y -162. skeletons.at:25: - ok -166. skeletons.at:248: ok -stdout: +168. sets.at:27: ok 170. sets.at:153: testing Firsts ... - ./sets.at:171: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=sets input.y -./skeletons.at:237: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input4.y -136. output.at:341: ok -172. sets.at:269: testing Build relations ... -./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y - -./sets.at:243: sed -n 's/.*define YYFINAL *\([0-9][0-9]*\)/final state \1/p' input.c - -173. sets.at:315: testing Reduced Grammar ... -./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=grammar -o input.c input.y -stdout: -./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror -stderr: -175. reduce.at:26: testing Useless Terminals ... -stdout: -final state 6 -stderr: -./reduce.at:47: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y -./skeletons.at:122: $PREPARSER ./input-cmd-line - -stderr: -bison (GNU Bison) 3.8.2 -RITEM - 0: exp $end (rule 0) - 3: exp '<' exp (rule 1) - 7: exp '>' exp (rule 2) - 11: exp '+' exp (rule 3) - 15: exp '-' exp (rule 4) - 19: exp '^' exp (rule 5) - 23: exp '=' exp (rule 6) - 27: "exp" (rule 7) - - -DERIVES - $accept derives - 0 exp $end - exp derives - 1 exp '<' exp - 2 exp '>' exp - 3 exp '+' exp - 4 exp '-' exp - 5 exp '^' exp - 6 exp '=' exp - 7 "exp" - - -NULLABLE - $accept: no - exp: no - - -RTC: Firsts Input BEGIN - - 01 - .--. - 0| 1| - 1| 1| - `--' -RTC: Firsts Input END - -RTC: Firsts Output BEGIN - - 01 - .--. - 0|11| - 1| 1| - `--' -RTC: Firsts Output END - -FIRSTS - $accept firsts - $accept - exp - exp firsts - exp - - -FDERIVES - $accept derives - 0 exp $end - 1 exp '<' exp - 2 exp '>' exp - 3 exp '+' exp - 4 exp '-' exp - 5 exp '^' exp - 6 exp '=' exp - 7 "exp" - exp derives - 1 exp '<' exp - 2 exp '>' exp - 3 exp '+' exp - 4 exp '-' exp - 5 exp '^' exp - 6 exp '=' exp - 7 "exp" - - -relation_transpose: - 0: 1 2 3 4 5 6 - 1: 1 2 3 4 5 6 - 2: 1 2 3 4 5 6 - 3: 1 2 3 4 5 6 - 4: 1 2 3 4 5 6 - 5: 1 2 3 4 5 6 - 6: 1 2 3 4 5 6 - -relation_transpose: output: - 1: 0 1 2 3 4 5 6 - 2: 0 1 2 3 4 5 6 - 3: 0 1 2 3 4 5 6 - 4: 0 1 2 3 4 5 6 - 5: 0 1 2 3 4 5 6 - 6: 0 1 2 3 4 5 6 - -follows after includes: - FOLLOWS[goto[0] = (0, exp, 2)] = $end '<' '>' '+' '-' '^' '=' - FOLLOWS[goto[1] = (4, exp, 10)] = $end '<' '>' '+' '-' '^' '=' - FOLLOWS[goto[2] = (5, exp, 11)] = $end '<' '>' '+' '-' '^' '=' - FOLLOWS[goto[3] = (6, exp, 12)] = $end '<' '>' '+' '-' '^' '=' - FOLLOWS[goto[4] = (7, exp, 13)] = $end '<' '>' '+' '-' '^' '=' - FOLLOWS[goto[5] = (8, exp, 14)] = $end '<' '>' '+' '-' '^' '=' - FOLLOWS[goto[6] = (9, exp, 15)] = $end '<' '>' '+' '-' '^' '=' - -Lookaheads: - State 1: - rule 7: - State 3: - rule 0: - State 10: - rule 1: $end '<' '>' '+' '-' '^' '=' - State 11: - rule 2: $end '<' '>' '+' '-' '^' '=' - State 12: - rule 3: $end '<' '>' '+' '-' '^' '=' - State 13: - rule 4: $end '<' '>' '+' '-' '^' '=' - State 14: - rule 5: $end '<' '>' '+' '-' '^' '=' - State 15: - rule 6: $end '<' '>' '+' '-' '^' '=' - stderr: -./sets.at:248: sed -n ' - /^State \(.*\)/{ - s//final state \1/ - x - } - / accept/{ - x - p - q - } - ' input.output -174. sets.at:394: testing Reduced Grammar with prec and assoc ... -syntax error, unexpected 'a', expecting end of file bison (GNU Bison) 3.8.2 RITEM 0: a $end (rule 0) @@ -5805,10 +5678,175 @@ State 10: rule 0: + ./sets.at:127: sed -n 's/[ ]*$//;/^RTC: Firsts Output BEGIN/,/^RTC: Firsts Output END/p' stderr -./skeletons.at:122: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +172. sets.at:269: testing Build relations ... +./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y +169. sets.at:111: ok +166. skeletons.at:248: ok +./skeletons.at:237: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input4.y +171. sets.at:228: testing Accept ... +173. sets.at:315: testing Reduced Grammar ... +stderr: +bison (GNU Bison) 3.8.2 +RITEM + 0: exp $end (rule 0) + 3: exp '<' exp (rule 1) + 7: exp '>' exp (rule 2) + 11: exp '+' exp (rule 3) + 15: exp '-' exp (rule 4) + 19: exp '^' exp (rule 5) + 23: exp '=' exp (rule 6) + 27: "exp" (rule 7) + + +DERIVES + $accept derives + 0 exp $end + exp derives + 1 exp '<' exp + 2 exp '>' exp + 3 exp '+' exp + 4 exp '-' exp + 5 exp '^' exp + 6 exp '=' exp + 7 "exp" + + +NULLABLE + $accept: no + exp: no + + +RTC: Firsts Input BEGIN + + 01 + .--. + 0| 1| + 1| 1| + `--' +RTC: Firsts Input END + +RTC: Firsts Output BEGIN + + 01 + .--. + 0|11| + 1| 1| + `--' +RTC: Firsts Output END + +FIRSTS + $accept firsts + $accept + exp + exp firsts + exp + + +FDERIVES + $accept derives + 0 exp $end + 1 exp '<' exp + 2 exp '>' exp + 3 exp '+' exp + 4 exp '-' exp + 5 exp '^' exp + 6 exp '=' exp + 7 "exp" + exp derives + 1 exp '<' exp + 2 exp '>' exp + 3 exp '+' exp + 4 exp '-' exp + 5 exp '^' exp + 6 exp '=' exp + 7 "exp" + + +relation_transpose: + 0: 1 2 3 4 5 6 + 1: 1 2 3 4 5 6 + 2: 1 2 3 4 5 6 + 3: 1 2 3 4 5 6 + 4: 1 2 3 4 5 6 + 5: 1 2 3 4 5 6 + 6: 1 2 3 4 5 6 + +relation_transpose: output: + 1: 0 1 2 3 4 5 6 + 2: 0 1 2 3 4 5 6 + 3: 0 1 2 3 4 5 6 + 4: 0 1 2 3 4 5 6 + 5: 0 1 2 3 4 5 6 + 6: 0 1 2 3 4 5 6 + +follows after includes: + FOLLOWS[goto[0] = (0, exp, 2)] = $end '<' '>' '+' '-' '^' '=' + FOLLOWS[goto[1] = (4, exp, 10)] = $end '<' '>' '+' '-' '^' '=' + FOLLOWS[goto[2] = (5, exp, 11)] = $end '<' '>' '+' '-' '^' '=' + FOLLOWS[goto[3] = (6, exp, 12)] = $end '<' '>' '+' '-' '^' '=' + FOLLOWS[goto[4] = (7, exp, 13)] = $end '<' '>' '+' '-' '^' '=' + FOLLOWS[goto[5] = (8, exp, 14)] = $end '<' '>' '+' '-' '^' '=' + FOLLOWS[goto[6] = (9, exp, 15)] = $end '<' '>' '+' '-' '^' '=' + +Lookaheads: + State 1: + rule 7: + State 3: + rule 0: + State 10: + rule 1: $end '<' '>' '+' '-' '^' '=' + State 11: + rule 2: $end '<' '>' '+' '-' '^' '=' + State 12: + rule 3: $end '<' '>' '+' '-' '^' '=' + State 13: + rule 4: $end '<' '>' '+' '-' '^' '=' + State 14: + rule 5: $end '<' '>' '+' '-' '^' '=' + State 15: + rule 6: $end '<' '>' '+' '-' '^' '=' + +./sets.at:172: sed -f extract.sed stderr + +./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=grammar -o input.c input.y +./sets.at:240: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y + +170. sets.at:153: ok +stderr: +stdout: + +174. sets.at:394: testing Reduced Grammar with prec and assoc ... +./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wno-other input.y -Wnone,none -Werror --trace=none +./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror +137. output.at:342: ok ./sets.at:412: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=grammar -o input.c input.y +176. reduce.at:70: testing Useless Nonterminals ... +./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y + +175. reduce.at:26: testing Useless Terminals ... +165. skeletons.at:166: ok +./sets.at:243: sed -n 's/.*define YYFINAL *\([0-9][0-9]*\)/final state \1/p' input.c +./reduce.at:47: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y +stdout: +final state 6 + +./sets.at:248: sed -n ' + /^State \(.*\)/{ + s//final state \1/ + x + } + / accept/{ + x + p + q + } + ' input.output +177. reduce.at:120: testing Useless Rules ... + stderr: +./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y input.y: error: 5 reduce/reduce conflicts [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:2.14-17: error: rule useless in parser due to conflicts [-Werror=other] @@ -5826,38 +5864,19 @@ input.y:2.42-45: error: rule useless in parser due to conflicts [-Werror=other] 2 | expr: term | term | term | term | term | term | ^~~~ -./sets.at:172: sed -f extract.sed stderr -165. skeletons.at:166: ok -./sets.at:286: sed 's,.*/$,,' stderr 1>&2 -176. reduce.at:70: testing Useless Nonterminals ... -170. sets.at:153: ok -./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input.y -171. sets.at:228: ok -177. reduce.at:120: testing Useless Rules ... -./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y -./skeletons.at:126: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input-gram.c input-gram.y -./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error ./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=grammar -o input.c input.y -Werror -169. sets.at:111: ok -./reduce.at:49: sed -n '/^Grammar/q;/^$/!p' input.output - -175. reduce.at:26: ok +178. reduce.at:224: testing Useless Parts ... +./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y +171. sets.at:228: ok +./diagnostics.at:725: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wno-other input.y --warnings=none -Werror --trace=none ./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Werror - - - 179. reduce.at:312: testing Reduced Automaton ... +./sets.at:286: sed 's,.*/$,,' stderr 1>&2 174. sets.at:394: ok -180. reduce.at:406: testing Underivable Rules ... -./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y -./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror - ./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret not-reduced.y -178. reduce.at:224: testing Useless Parts ... -./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y -./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none -./skeletons.at:127: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input-gram input-gram.c $LIBS -stderr: +./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error +./reduce.at:49: sed -n '/^Grammar/q;/^$/!p' input.output + stderr: bison (GNU Bison) 3.8.2 input.y: error: 1 nonterminal useless in grammar [-Werror=other] @@ -5916,6 +5935,15 @@ reduced input.y defines 7 terminals, 4 nonterminals, and 6 productions. +161. diagnostics.at:713: 175. reduce.at:26: ok + ok +180. reduce.at:406: testing Underivable Rules ... +./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.y + +./sets.at:325: sed 's,.*/$,,' stderr 1>&2 +./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror +./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret not-reduced.y -Werror +stderr: input.y: error: 3 nonterminals useless in grammar [-Werror=other] input.y: error: 3 rules useless in grammar [-Werror=other] input.y:11.1-8: error: nonterminal useless in grammar: useless1 [-Werror=other] @@ -5923,20 +5951,26 @@ input.y:13.1-8: error: nonterminal useless in grammar: useless3 [-Werror=other] 181. reduce.at:452: testing Bad start symbols ... ./reduce.at:467: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none -./sets.at:325: sed 's,.*/$,,' stderr 1>&2 + +./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y -Werror +./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none + +stderr: +./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=grammar -o input.c input.y --warnings=error +stdout: ./reduce.at:89: sed 's,.*/$,,' stderr 1>&2 182. reduce.at:550: testing no lr.type: Single State Split ... +./skeletons.at:122: $PREPARSER ./input-cmd-line ./reduce.at:550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret not-reduced.y -Werror ./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Werror - -./reduce.at:550: sed -n '/^State 0$/,$p' input.output -./reduce.at:473: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y -Werror stderr: -172. sets.at:269: ./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=grammar -o input.c input.y --warnings=error - ok +stderr: +syntax error, unexpected 'a', expecting end of file +./skeletons.at:122: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +183. reduce.at:550: testing lr.type=lalr: Single State Split ... +./reduce.at:550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y +stderr: +./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error input.y: error: 9 nonterminals useless in grammar [-Werror=other] input.y: error: 9 rules useless in grammar [-Werror=other] input.y:10.1-8: error: nonterminal useless in grammar: useless1 [-Werror=other] @@ -5966,9 +6000,7 @@ input.y:18.1-8: error: nonterminal useless in grammar: useless9 [-Werror=other] 18 | useless9: '9'; | ^~~~~~~~ -./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=error -stderr: -./reduce.at:550: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./reduce.at:473: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y not-reduced.y: error: 2 nonterminals useless in grammar [-Werror=other] not-reduced.y: error: 3 rules useless in grammar [-Werror=other] not-reduced.y:14.1-13: error: nonterminal useless in grammar: not_reachable [-Werror=other] @@ -5980,10 +6012,12 @@ not-reduced.y:11.6-57: error: rule useless in grammar [-Werror=other] 11 | | non_productive { /* A non productive action. */ } | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -./reduce.at:480: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +./skeletons.at:126: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input-gram.c input-gram.y stderr: -./reduce.at:146: sed 's,.*/$,,' stderr 1>&2 -183. reduce.at:550: testing lr.type=lalr: Single State Split ... +./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=grammar -o input.c input.y -Wnone,none -Werror --trace=none +stderr: +./sets.at:286: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none +./reduce.at:550: sed -n '/^State 0$/,$p' input.output input.y: error: 2 nonterminals useless in grammar [-Werror=other] input.y: error: 3 rules useless in grammar [-Werror=other] input.y:6.1-11: error: nonterminal useless in grammar: underivable [-Werror=other] @@ -5995,337 +6029,354 @@ input.y:5.15-25: error: rule useless in grammar [-Werror=other] 5 | exp: useful | underivable; | ^~~~~~~~~~~ -stderr: -./reduce.at:550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y +./reduce.at:341: sed 's,.*/$,,' stderr 1>&2 input.y: error: 1 nonterminal useless in grammar [-Werror=other] input.y: error: 1 rule useless in grammar [-Werror=other] input.y:18.1-6: error: nonterminal useless in grammar: unused [-Werror=other] 18 | unused | ^~~~~~ -./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=grammar -o input.c input.y -Wnone,none -Werror --trace=none -./reduce.at:341: sed 's,.*/$,,' stderr 1>&2 +./reduce.at:550: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./reduce.at:550: sed -n '/^State 0$/,$p' input.output +./reduce.at:146: sed 's,.*/$,,' stderr 1>&2 ./reduce.at:420: sed 's,.*/$,,' stderr 1>&2 - -./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none -./reduce.at:488: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +./reduce.at:480: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret not-reduced.y --warnings=error +./reduce.at:550: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:261: sed 's,.*/$,,' stderr 1>&2 ./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error -./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret not-reduced.y --warnings=error -./reduce.at:550: sed -n '/^State 0$/,$p' input.output ./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=error -./reduce.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -Wnone,none -Werror --trace=none ./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y --warnings=error -184. reduce.at:550: testing lr.type=ielr: Single State Split ... -./reduce.at:550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -./reduce.at:550: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none -./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none +./skeletons.at:127: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input-gram input-gram.c $LIBS ./sets.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=grammar -o input.c input.y --warnings=none -Werror --trace=none -./reduce.at:505: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +./reduce.at:488: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +172. sets.at:269: ok +./reduce.at:89: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y --warnings=none -Werror --trace=none +./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret not-reduced.y -Wnone,none -Werror --trace=none -stderr: -./reduce.at:550: sed -n '/^State 0$/,$p' input.output -stdout: -181. reduce.at:452: ok -./skeletons.at:128: $PREPARSER ./input-gram +./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none ./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y -Wnone,none -Werror --trace=none ./reduce.at:97: sed -n '/^Grammar/q;/^$/!p' input.output -./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y -Wnone,none -Werror --trace=none -stderr: -./reduce.at:550: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -syntax error, unexpected 'a', expecting end of file -./skeletons.at:128: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none -stdout: -./reduce.at:109: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c -173. sets.at:315: ok -./reduce.at:550: $PREPARSER ./input ./reduce.at:341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret not-reduced.y --warnings=none -Werror --trace=none -./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y --warnings=none -Werror --trace=none - -stderr: -163. skeletons.at:85: ok -syntax error -./reduce.at:550: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: -./reduce.at:550: $PREPARSER ./input -stderr: +./reduce.at:109: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c +./reduce.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +173. sets.at:315: + ok +./reduce.at:146: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none ./reduce.at:420: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.y --warnings=none -Werror --trace=none -syntax error -./reduce.at:179: sed -n '/^Grammar/q;/^$/!p' input.output +./reduce.at:261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -rall -o input.c input.y --warnings=none -Werror --trace=none +./reduce.at:505: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -182. reduce.at:550: ok -./reduce.at:550: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./reduce.at:355: sed -n '/^Grammar/q;/^$/!p' not-reduced.output +181. reduce.at:452: ok 185. reduce.at:550: testing lr.type=canonical-lr: Single State Split ... -./reduce.at:270: sed -n '/^State 0/q;/^$/!p' input.output +184. reduce.at:550: testing lr.type=ielr: Single State Split ... ./reduce.at:550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -./reduce.at:213: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c -186. reduce.at:783: testing no lr.type: Lane Split ... -./reduce.at:783: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y +./reduce.at:550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y +./reduce.at:434: sed -n '/^Grammar/q;/^$/!p' input.output ./reduce.at:392: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret reduced.y -183. reduce.at:550: ok +./reduce.at:270: sed -n '/^State 0/q;/^$/!p' input.output +180. reduce.at:406: ok +./reduce.at:179: sed -n '/^Grammar/q;/^$/!p' input.output ./reduce.at:298: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c -./reduce.at:434: sed -n '/^Grammar/q;/^$/!p' input.output stderr: +186. reduce.at:783: testing no lr.type: Lane Split ... +./reduce.at:783: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y +stdout: +./reduce.at:213: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c +./reduce.at:550: $PREPARSER ./input +stderr: +./reduce.at:550: sed -n '/^State 0$/,$p' input.output +syntax error +./reduce.at:550: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./reduce.at:550: sed -n '/^State 0$/,$p' input.output +./reduce.at:550: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS + +./reduce.at:783: sed -n '/^State 0$/,$p' input.output 187. reduce.at:783: testing lr.type=lalr: Lane Split ... ./reduce.at:783: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y - +183. reduce.at:550: stderr: + ok +stdout: ./reduce.at:396: sed 's/not-reduced/reduced/g' not-reduced.c +stderr: stdout: -179. reduce.at:312: ok 176. reduce.at:70: ok -180. reduce.at:406: ok +./reduce.at:550: $PREPARSER ./input +./reduce.at:550: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +stderr: +syntax error +./reduce.at:550: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +179. reduce.at:312: ok -./reduce.at:783: sed -n '/^State 0$/,$p' input.output -./reduce.at:783: sed -n '/^State 0$/,$p' input.output -188. reduce.at:783: testing lr.type=ielr: Lane Split ... ./reduce.at:783: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: -./reduce.at:783: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -./reduce.at:550: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: -./reduce.at:783: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS - +./skeletons.at:128: $PREPARSER ./input-gram +182. reduce.at:550: ok +./reduce.at:783: sed -n '/^State 0$/,$p' input.output +stderr: +syntax error, unexpected 'a', expecting end of file +./skeletons.at:128: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./reduce.at:550: $PREPARSER ./input -189. reduce.at:783: testing lr.type=canonical-lr: Lane Split ... +188. reduce.at:783: testing lr.type=ielr: Lane Split ... ./reduce.at:783: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y +./reduce.at:783: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +163. skeletons.at:85: ok +189. reduce.at:783: testing lr.type=canonical-lr: Lane Split ... -stderr: -./reduce.at:550: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -190. reduce.at:1027: testing no lr.type: Complex Lane Split ... -stderr: +./reduce.at:783: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stderr: ./reduce.at:783: sed -n '/^State 0$/,$p' input.output -184. reduce.at:550: ok stdout: + +stderr: +./reduce.at:783: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +178. reduce.at:224: 190. reduce.at:1027: testing no lr.type: Complex Lane Split ... ./reduce.at:1027: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stdout: -192. reduce.at:1027: testing lr.type=ielr: Complex Lane Split ... -191. reduce.at:1027: testing lr.type=lalr: Complex Lane Split ... + ok 177. reduce.at:120: ok + +191. reduce.at:1027: testing lr.type=lalr: Complex Lane Split ... ./reduce.at:1027: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -178. reduce.at:224: ok -./reduce.at:1027: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y +192. reduce.at:1027: testing lr.type=ielr: Complex Lane Split ... ./reduce.at:783: sed -n '/^State 0$/,$p' input.output -./reduce.at:783: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./reduce.at:1027: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -./reduce.at:783: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:1027: sed -n '/^State 0$/,$p' input.output ./reduce.at:1027: sed -n '/^State 0$/,$p' input.output - -./reduce.at:1027: sed -n '/^State 0$/,$p' input.output -stderr: -stdout: ./reduce.at:1027: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -stderr: ./reduce.at:1027: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -stdout: -194. reduce.at:1296: testing no lr.type: Split During Added Lookahead Propagation ... -./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y +./reduce.at:783: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 193. reduce.at:1027: testing lr.type=canonical-lr: Complex Lane Split ... -./output.at:835: $CXX $CPPFLAGS $CXXFLAGS -Iout/ $LDFLAGS -o parser out/x[12].o main.cc $LIBS -./reduce.at:1027: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -195. reduce.at:1296: testing lr.type=lalr: Split During Added Lookahead Propagation ... -./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -./reduce.at:783: $PREPARSER ./input ./reduce.at:1027: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -stderr: -syntax error -./reduce.at:783: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +194. reduce.at:1296: testing no lr.type: Split During Added Lookahead Propagation ... +./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y +./reduce.at:1027: sed -n '/^State 0$/,$p' input.output stderr: stdout: ./reduce.at:550: $PREPARSER ./input stderr: +./reduce.at:1027: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:550: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./reduce.at:1027: sed -n '/^State 0$/,$p' input.output -./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror -186. reduce.at:783: ok +184. reduce.at:550: ok stderr: -./reduce.at:1027: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: -./reduce.at:783: $PREPARSER ./input -185. reduce.at:550: ok +./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror +./reduce.at:550: $PREPARSER ./input +./reduce.at:1027: sed -n '/^State 0$/,$p' input.output +stderr: +./reduce.at:550: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./reduce.at:783: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +185. reduce.at:550: ok +stdout: +./reduce.at:783: $PREPARSER ./input +./reduce.at:1027: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: -188. reduce.at:783: ok ./reduce.at:783: $PREPARSER ./input stderr: -stdout: -./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror + stderr: -./reduce.at:783: $PREPARSER ./input syntax error -stderr: ./reduce.at:783: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +187. reduce.at:783: ok +syntax error ./reduce.at:783: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -189. reduce.at:783: ok +stderr: +input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] +input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +195. reduce.at:1296: testing lr.type=lalr: Split During Added Lookahead Propagation ... 196. reduce.at:1296: testing lr.type=ielr: Split During Added Lookahead Propagation ... ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y - -187. reduce.at:783: ok - +./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y 197. reduce.at:1296: testing lr.type=canonical-lr: Split During Added Lookahead Propagation ... stderr: -input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] -input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -stderr: ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] -input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -./reduce.at:1296: sed -n '/^State 0$/,$p' input.output -./reduce.at:1296: sed 's,.*/$,,' stderr 1>&2 -198. reduce.at:1627: testing no lr.default-reduction ... -./reduce.at:1627: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -./reduce.at:1296: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +stdout: ./reduce.at:1296: sed 's,.*/$,,' stderr 1>&2 -./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error +./reduce.at:783: $PREPARSER ./input +186. reduce.at:783: ok +stderr: +./reduce.at:783: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +188. reduce.at:783: ok +stderr: +stdout: +./reduce.at:1027: $PREPARSER ./input +./reduce.at:1296: sed -n '/^State 0$/,$p' input.output -199. reduce.at:1627: testing lr.default-reduction=most ... +./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error +stderr: +syntax error +./reduce.at:1027: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror +198. reduce.at:1627: testing no lr.default-reduction ... ./reduce.at:1296: sed -n '/^State 0$/,$p' input.output ./reduce.at:1627: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y stderr: +stderr: stdout: -200. reduce.at:1627: testing lr.default-reduction=consistent ... +stdout: + +191. reduce.at:1027: ./reduce.at:783: $PREPARSER ./input + ok +./reduce.at:1027: $PREPARSER ./input +./reduce.at:1296: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: -./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error stderr: +./reduce.at:783: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +./reduce.at:1027: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./reduce.at:1296: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./reduce.at:1027: $PREPARSER ./input +./reduce.at:1627: sed -n '/^State 0$/,$p' input.output stderr: +190. reduce.at:1027: ok stderr: -./reduce.at:1627: sed -n '/^State 0$/,$p' input.output -stdout: -stdout: -./reduce.at:1627: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -./reduce.at:1027: $PREPARSER ./input +189. reduce.at:783: ok stdout: +199. reduce.at:1627: testing lr.default-reduction=most ... ./reduce.at:1027: $PREPARSER ./input + stderr: -syntax error -syntax error -./reduce.at:1027: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./reduce.at:1627: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./reduce.at:1027: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] +input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +./reduce.at:1627: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y +192. reduce.at:1027: ok stderr: -./reduce.at:1027: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./reduce.at:1627: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none +stdout: ./reduce.at:1027: $PREPARSER ./input -./reduce.at:1627: sed -n '/^State 0$/,$p' input.output -193. reduce.at:1027: ok stderr: ./reduce.at:1027: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none -./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none + + +200. reduce.at:1627: testing lr.default-reduction=consistent ... +./reduce.at:1627: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y +./reduce.at:1296: sed 's,.*/$,,' stderr 1>&2 +193. reduce.at:1027: ok + ./reduce.at:1627: sed -n '/^State 0$/,$p' input.output +./reduce.at:1627: sed -n '/^State 0$/,$p' input.output +./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error ./reduce.at:1627: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -191. reduce.at:1027: ok -192. reduce.at:1027: ok -190. reduce.at:1027: ok -./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none - -./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none +203. report.at:3123: testing Reports with conflicts ... ./reduce.at:1627: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +201. reduce.at:1627: testing lr.default-reduction=accepting ... +./reduce.at:1627: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y +203. report.at:3123: ./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none +202. report.at:37: testing Reports ... + skipped (report.at:3132) +204. conflicts.at:28: testing Token declaration order ... +202. report.at:37: ./conflicts.at:81: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y + skipped (report.at:75) +./reduce.at:1627: sed -n '/^State 0$/,$p' input.output + +./reduce.at:1627: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none +./reduce.at:1296: sed -n '/^State 0$/,$p' input.output +206. conflicts.at:183: testing Useless associativity warning ... +./conflicts.at:82: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wprecedence input.y stderr: stdout: -./reduce.at:1296: $PREPARSER ./input -stderr: -./reduce.at:1296: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./reduce.at:1296: sed -n '/^State 0$/,$p' input.output - ./reduce.at:1296: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -202. report.at:37: testing Reports ... -201. reduce.at:1627: testing lr.default-reduction=accepting ... -./reduce.at:1627: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -196. reduce.at:1296: ok -203. report.at:3123: testing Reports with conflicts ... -./reduce.at:1296: sed -n '/^State 0$/,$p' input.output +./reduce.at:1627: $PREPARSER ./input +205. conflicts.at:101: testing Token declaration order: literals vs. identifiers ... +stderr: +./reduce.at:1627: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -202. report.at:37: ./reduce.at:1627: sed -n '/^State 0$/,$p' input.output stdout: - skipped (report.at:75) +stderr: +./conflicts.at:130: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all -o input.c input.y +198. reduce.at:1627: ok +./output.at:835: $CXX $CPPFLAGS $CXXFLAGS -Iout/ $LDFLAGS -o parser out/x[12].o main.cc $LIBS +stderr: +stdout: +./reduce.at:1296: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./reduce.at:1296: $PREPARSER ./input stderr: -./reduce.at:1627: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +stdout: ./reduce.at:1296: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./reduce.at:1296: $PREPARSER ./input +./reduce.at:1296: sed -n '/^State 0$/,$p' input.output +196. reduce.at:1296: ok stderr: -197. reduce.at:1296: 204. conflicts.at:28: testing Token declaration order ... -./conflicts.at:81: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y - ok - -stdout: ./reduce.at:1296: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS - -203. report.at:3123: ./reduce.at:1627: $PREPARSER ./input - skipped (report.at:3132) stderr: -./reduce.at:1627: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - -./conflicts.at:82: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -205. conflicts.at:101: testing Token declaration order: literals vs. identifiers ... -./conflicts.at:130: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all -o input.c input.y -198. reduce.at:1627: 206. conflicts.at:183: testing Useless associativity warning ... -./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wprecedence input.y - ok -207. conflicts.at:218: testing Useless precedence warning ... -./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y +./conflicts.at:131: cat input.output | sed -n '/^State 0$/,/^State 1$/p' +./reduce.at:1296: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./reduce.at:1627: $PREPARSER ./input -stderr: -./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence input.y -Werror -./reduce.at:1627: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +197. reduce.at:1296: ./reduce.at:1627: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + ok +./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence input.y -Werror 208. conflicts.at:275: testing S/R in initial ... ./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +207. conflicts.at:218: testing Useless precedence warning ... +./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y + +205. conflicts.at:101: 200. reduce.at:1627: ok + ok stderr: stdout: -stdout: -./reduce.at:1627: $PREPARSER ./input -200. reduce.at:1627: ok -./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y -Werror ./reduce.at:1627: $PREPARSER ./input stderr: -stderr: +209. conflicts.at:301: testing %nonassoc and eof ... +./conflicts.at:368: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./reduce.at:1627: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y -Werror +./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror stderr: stderr: -./reduce.at:1627: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: -stderr: -201. reduce.at:1627: ok + +input.y:2.1-9: error: useless precedence and associativity for "=" [-Werror=precedence] +input.y:4.1-5: error: useless associativity for "*", use %precedence [-Werror=precedence] +input.y:5.1-11: error: useless precedence for "(" [-Werror=precedence] 199. reduce.at:1627: ok -stdout: ./conflicts.at:84: $PREPARSER ./input -./conflicts.at:131: cat input.output | sed -n '/^State 0$/,/^State 1$/p' -stderr: stderr: -209. conflicts.at:301: testing %nonassoc and eof ... -./conflicts.at:368: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./conflicts.at:84: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input.y:2.1-9: error: useless precedence and associativity for "=" [-Werror=precedence] -input.y:4.1-5: error: useless associativity for "*", use %precedence [-Werror=precedence] -input.y:5.1-11: error: useless precedence for "(" [-Werror=precedence] -./reduce.at:1296: $PREPARSER ./input -./conflicts.at:205: sed 's,.*/$,,' stderr 1>&2 +./conflicts.at:205: sed 's,.*/$,,' stderr 1>&2 +stderr: +stdout: +./reduce.at:1627: $PREPARSER ./input +204. conflicts.at:28: ok +stderr: +stderr: +210. conflicts.at:509: testing parse.error=verbose and consistent errors: lr.type=ielr ... +input.y:4.10-15: error: rule useless in parser due to conflicts [-Werror=other] +./reduce.at:1627: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./conflicts.at:509: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./conflicts.at:368: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +201. reduce.at:1627: ok +212. conflicts.at:518: testing parse.error=verbose and consistent errors: lr.type=ielr c++ ... +stderr: +211. conflicts.at:513: testing parse.error=verbose and consistent errors: lr.type=ielr %glr-parser ... +./conflicts.at:513: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./conflicts.at:518: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +./conflicts.at:284: sed 's,.*/$,,' stderr 1>&2 +stdout: +./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence input.y --warnings=error +./reduce.at:1296: $PREPARSER ./input +stderr: +./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error stderr: -205. conflicts.at:101: stderr: - ok input.y:7.1-9: error: useless precedence and associativity for U [-Werror=precedence] 7 | %nonassoc U | ^~~~~~~~~ @@ -6338,585 +6389,543 @@ input.y:2.1-11: error: useless precedence for Z [-Werror=precedence] 2 | %precedence Z | ^~~~~~~~~~~ -204. conflicts.at:28: ok -stderr: -./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence input.y --warnings=error -./conflicts.at:368: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -stdout: -./conflicts.at:248: sed 's,.*/$,,' stderr 1>&2 -211. conflicts.at:513: testing parse.error=verbose and consistent errors: lr.type=ielr %glr-parser ... -./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror -210. conflicts.at:509: testing parse.error=verbose and consistent errors: lr.type=ielr ... -./conflicts.at:513: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -syntax error -./reduce.at:1296: $PREPARSER ./input -./reduce.at:1296: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./conflicts.at:509: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y --warnings=error + syntax error ./reduce.at:1296: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./conflicts.at:248: sed 's,.*/$,,' stderr 1>&2 - -195. reduce.at:1296: ok - -stderr: +./conflicts.at:509: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 194. reduce.at:1296: ok -input.y:4.10-15: error: rule useless in parser due to conflicts [-Werror=other] +./conflicts.at:518: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./conflicts.at:513: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +213. conflicts.at:523: testing parse.error=verbose and consistent errors: lr.type=ielr java ... ./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence input.y -Wnone,none -Werror --trace=none -212. conflicts.at:518: testing parse.error=verbose and consistent errors: lr.type=ielr c++ ... - -./conflicts.at:509: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./conflicts.at:518: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +./conflicts.at:523: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.java input.y +./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none +stderr: +stdout: +./reduce.at:1296: $PREPARSER ./input +./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y --warnings=error +stderr: 214. conflicts.at:530: testing parse.error=verbose and consistent errors: lr.type=ielr lr.default-reduction=consistent ... ./conflicts.at:530: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -213. conflicts.at:523: testing parse.error=verbose and consistent errors: lr.type=ielr java ... -./conflicts.at:284: sed 's,.*/$,,' stderr 1>&2 -./conflicts.at:523: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.java input.y -./conflicts.at:513: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y -Wnone,none -Werror --trace=none -./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence input.y --warnings=none -Werror --trace=none -./conflicts.at:530: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +syntax error +./reduce.at:1296: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 215. conflicts.at:535: testing parse.error=verbose and consistent errors: lr.type=ielr lr.default-reduction=accepting ... ./conflicts.at:535: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./conflicts.at:518: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none +./conflicts.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence input.y --warnings=none -Werror --trace=none +213. conflicts.at:523: 195. reduce.at:1296: ok +./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y -Wnone,none -Werror --trace=none + skipped (conflicts.at:523) + +./conflicts.at:530: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./conflicts.at:535: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o input.c input.y +206. conflicts.at:183: ok 216. conflicts.at:540: testing parse.error=verbose and consistent errors: lr.type=canonical-lr ... + ./conflicts.at:540: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error -./conflicts.at:535: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -213. conflicts.at:523: 206. conflicts.at:183: skipped (conflicts.at:523) - ok ./conflicts.at:248: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wprecedence -fcaret -o input.c input.y --warnings=none -Werror --trace=none - -./conflicts.at:540: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none - 217. conflicts.at:546: testing parse.error=verbose and consistent errors: lr.type=canonical-lr parse.lac=full ... ./conflicts.at:546: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -207. conflicts.at:218: ok -./conflicts.at:284: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none -218. conflicts.at:551: testing parse.error=verbose and consistent errors: lr.type=ielr parse.lac=full ... -./conflicts.at:551: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Werror +207. conflicts.at:218: ./conflicts.at:540: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS + ok + +stderr: +input.y:4.10-15: error: rule useless in parser due to conflicts [-Werror=other] + 4 | e: 'e' | %empty; + | ^~~~~~ stderr: stdout: +./conflicts.at:546: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +218. conflicts.at:551: testing parse.error=verbose and consistent errors: lr.type=ielr parse.lac=full ... ./conflicts.at:368: $PREPARSER ./input '0<0' -stderr: -./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:368: $PREPARSER ./input '0<0<0' +./conflicts.at:551: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./conflicts.at:288: sed 's,.*/$,,' stderr 1>&2 stderr: -syntax error, unexpected '<' ./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:546: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./conflicts.at:368: $PREPARSER ./input '0>0' -./conflicts.at:551: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o input.c input.y 219. conflicts.at:558: testing parse.error=verbose and consistent errors: c++ lr.type=canonical-lr parse.lac=full ... +./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=error +./conflicts.at:368: $PREPARSER ./input '0<0<0' ./conflicts.at:558: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +./conflicts.at:551: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: +syntax error, unexpected '<' ./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:368: $PREPARSER ./input '0>0>0' -stderr: -syntax error, unexpected '>' -./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:558: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./conflicts.at:368: $PREPARSER ./input '0<0>0' -stderr: stderr: stdout: -syntax error, unexpected '>' -./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:509: $PREPARSER ./input +./conflicts.at:368: $PREPARSER ./input '0>0' stderr: -./conflicts.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.default-reduction=consistent -o input.c input.y -./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Werror +stderr: +./conflicts.at:558: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Wnone,none -Werror --trace=none syntax error, unexpected end of file ./conflicts.at:509: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./conflicts.at:368: $PREPARSER ./input '0>0>0' +stdout: +./conflicts.at:535: $PREPARSER ./input +./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=none -Werror --trace=none +stderr: +syntax error, unexpected end of file, expecting 'a' or 'b' +stderr: +./conflicts.at:535: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error, unexpected '>' 210. conflicts.at:509: ok +./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: stdout: ./conflicts.at:530: $PREPARSER ./input stderr: syntax error, unexpected end of file, expecting 'a' or 'b' ./conflicts.at:530: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +215. conflicts.at:535: ok 214. conflicts.at:530: ok -input.y:4.10-15: error: rule useless in parser due to conflicts [-Werror=other] - 4 | e: 'e' | %empty; - | ^~~~~~ -./conflicts.at:372: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./conflicts.at:288: sed 's,.*/$,,' stderr 1>&2 +./conflicts.at:368: $PREPARSER ./input '0<0>0' + +stderr: +syntax error, unexpected '>' +./conflicts.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +208. conflicts.at:275: ok +./conflicts.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.default-reduction=consistent -o input.c input.y +221. conflicts.at:622: testing parse.error=verbose and consistent errors: ... +./conflicts.at:622: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +222. conflicts.at:626: testing parse.error=verbose and consistent errors: %glr-parser ... +./conflicts.at:626: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: -./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=error 220. conflicts.at:564: testing parse.error=verbose and consistent errors: c++ lr.type=ielr parse.lac=full ... -stderr: +./conflicts.at:564: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stdout: ./conflicts.at:540: $PREPARSER ./input -stdout: -221. conflicts.at:622: testing parse.error=verbose and consistent errors: ... -./conflicts.at:622: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./conflicts.at:626: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: -./conflicts.at:535: $PREPARSER ./input + +./conflicts.at:564: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stderr: +stdout: +./conflicts.at:372: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./output.at:836: $PREPARSER ./parser syntax error, unexpected end of file, expecting 'a' or 'b' ./conflicts.at:540: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:564: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -stderr: +./conflicts.at:622: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: -stdout: +./output.at:836: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +223. conflicts.at:632: testing parse.error=verbose and consistent errors: lr.default-reduction=consistent ... +./conflicts.at:632: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: -syntax error, unexpected end of file, expecting 'a' or 'b' -./conflicts.at:535: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +144. output.at:744: ok stdout: -./output.at:836: $PREPARSER ./parser ./conflicts.at:546: $PREPARSER ./input -stderr: +216. conflicts.at:540: ok stderr: syntax error, unexpected end of file, expecting 'b' -216. conflicts.at:540: ok ./conflicts.at:546: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:622: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./output.at:836: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Wnone,none -Werror --trace=none -215. conflicts.at:535: ok -144. output.at:744: ok -217. conflicts.at:546: ok -./conflicts.at:564: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS - -./conflicts.at:288: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=none -Werror --trace=none - -222. conflicts.at:626: testing parse.error=verbose and consistent errors: %glr-parser ... -./conflicts.at:626: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./conflicts.at:632: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +217. conflicts.at:546: ok -stderr: -stdout: 224. conflicts.at:638: testing parse.error=verbose and consistent errors: lr.default-reduction=accepting ... +stderr: ./conflicts.at:638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +stdout: +225. conflicts.at:642: testing parse.error=verbose and consistent errors: lr.type=canonical-lr ... ./conflicts.at:551: $PREPARSER ./input -223. conflicts.at:632: testing parse.error=verbose and consistent errors: lr.default-reduction=consistent ... -stderr: +./conflicts.at:642: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: syntax error, unexpected end of file, expecting 'b' ./conflicts.at:551: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:632: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -stdout: + +./conflicts.at:638: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: +./conflicts.at:642: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +stdout: +218. conflicts.at:551: ok ./conflicts.at:513: $PREPARSER ./input +226. conflicts.at:647: testing parse.error=verbose and consistent errors: parse.lac=full ... +./conflicts.at:647: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +stderr: stdout: -./conflicts.at:626: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:372: $PREPARSER ./input '0<0' stderr: -stderr: -225. conflicts.at:642: testing parse.error=verbose and consistent errors: lr.type=canonical-lr ... syntax error, unexpected end of file -./conflicts.at:513: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:642: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./conflicts.at:638: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +stderr: ./conflicts.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -208. conflicts.at:275: ok +./conflicts.at:513: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:372: $PREPARSER ./input '0<0<0' stderr: +211. conflicts.at:513: ok syntax error, unexpected '<', expecting end of file ./conflicts.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -218. conflicts.at:551: ok -211. conflicts.at:513: ok -./conflicts.at:632: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./conflicts.at:647: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS + ./conflicts.at:372: $PREPARSER ./input '0>0' stderr: -./conflicts.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:642: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS - +./conflicts.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stdout: ./conflicts.at:372: $PREPARSER ./input '0>0>0' - stderr: +./conflicts.at:622: $PREPARSER ./input syntax error, unexpected '>', expecting end of file ./conflicts.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -226. conflicts.at:647: testing parse.error=verbose and consistent errors: parse.lac=full ... -./conflicts.at:647: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./conflicts.at:372: $PREPARSER ./input '0<0>0' 227. conflicts.at:651: testing parse.error=verbose and consistent errors: parse.lac=full lr.default-reduction=accepting ... -./conflicts.at:651: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./conflicts.at:372: $PREPARSER ./input '0<0>0' +stderr: stderr: -228. conflicts.at:676: testing LAC: %nonassoc requires splitting canonical LR states ... syntax error, unexpected '>', expecting end of file ./conflicts.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y -./conflicts.at:647: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./conflicts.at:381: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y -./conflicts.at:651: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y -Werror -./conflicts.at:381: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -stderr: -input.y: error: 2 shift/reduce conflicts [-Werror=conflicts-sr] -input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -./conflicts.at:726: sed 's,.*/$,,' stderr 1>&2 -stderr: -stdout: -./conflicts.at:622: $PREPARSER ./input -stderr: -./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y --warnings=error +./conflicts.at:651: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y syntax error, unexpected 'b' ./conflicts.at:622: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./conflicts.at:381: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y +228. conflicts.at:676: testing LAC: %nonassoc requires splitting canonical LR states ... +./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y 221. conflicts.at:622: ok +./conflicts.at:651: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./conflicts.at:381: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS + +./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y -Werror stderr: -./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y -Wnone,none -Werror --trace=none stdout: ./conflicts.at:638: $PREPARSER ./input - stderr: -syntax error, unexpected end of file, expecting 'a' -./conflicts.at:638: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 229. conflicts.at:764: testing Unresolved SR Conflicts ... ./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c --report=all input.y +syntax error, unexpected end of file, expecting 'a' +./conflicts.at:638: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y --warnings=none -Werror --trace=none +stderr: +input.y: error: 2 shift/reduce conflicts [-Werror=conflicts-sr] +input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stdout: 224. conflicts.at:638: ok +./conflicts.at:726: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:632: $PREPARSER ./input +./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y -Werror stderr: -stderr: -stdout: syntax error, unexpected 'b' ./conflicts.at:632: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:381: $PREPARSER ./input '0<0' +./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y --warnings=error stderr: -./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] +input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +./conflicts.at:774: sed 's,.*/$,,' stderr 1>&2 223. conflicts.at:632: ok -./conflicts.at:381: $PREPARSER ./input '0<0<0' -./conflicts.at:731: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -stderr: -./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y -Werror -syntax error, unexpected '<', expecting end of file -./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y -Wnone,none -Werror --trace=none +./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y --warnings=error stderr: +stdout: 230. conflicts.at:887: testing Resolved SR Conflicts ... +./conflicts.at:626: $PREPARSER ./input +stderr: ./conflicts.at:898: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c --report=all input.y -./conflicts.at:381: $PREPARSER ./input '0>0' -stdout: +syntax error, unexpected 'b' +./conflicts.at:626: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./conflicts.at:726: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -o input.c input.y --warnings=none -Werror --trace=none stderr: -./conflicts.at:642: $PREPARSER ./input -./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error, unexpected end of file, expecting 'a' -./conflicts.at:642: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./conflicts.at:381: $PREPARSER ./input '0>0>0' -input.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] -input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -225. conflicts.at:642: ok +./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y -Wnone,none -Werror --trace=none +stdout: +./conflicts.at:647: $PREPARSER ./input stderr: -./conflicts.at:901: cat input.output -syntax error, unexpected '>', expecting end of file -./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:774: sed 's,.*/$,,' stderr 1>&2 +222. conflicts.at:626: ok +syntax error, unexpected 'b' +./conflicts.at:647: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 231. conflicts.at:989: testing %precedence suffices ... ./conflicts.at:1006: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -230. conflicts.at:887: ok -./conflicts.at:381: $PREPARSER ./input '0<0>0' -./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y --warnings=error +./conflicts.at:901: cat input.output +226. conflicts.at:647: ok +./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y --warnings=none -Werror --trace=none stderr: +stdout: -syntax error, unexpected '>', expecting end of file -./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -231. conflicts.at:989: ok - +./conflicts.at:642: $PREPARSER ./input +230. conflicts.at:887: ok +stderr: stderr: -./conflicts.at:388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -o input.c input.y -232. conflicts.at:1015: testing %precedence does not suffice ... -./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stdout: +./conflicts.at:651: $PREPARSER ./input +syntax error, unexpected end of file, expecting 'a' +./conflicts.at:642: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./conflicts.at:647: $PREPARSER ./input +syntax error, unexpected end of file +./conflicts.at:651: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./conflicts.at:731: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +231. conflicts.at:989: ok +227. conflicts.at:651: ok +232. conflicts.at:1015: testing %precedence does not suffice ... +./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: -./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y -Wnone,none -Werror --trace=none -stderr: -syntax error, unexpected 'b' -./conflicts.at:647: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:518: $PREPARSER ./input -stdout: -./conflicts.at:651: $PREPARSER ./input stderr: -233. conflicts.at:1096: testing Syntax error in consistent error state: yacc.c ... -./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./conflicts.at:780: cat input.output stderr: +stdout: syntax error, unexpected end of file -./conflicts.at:388: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:518: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error, unexpected end of file -./conflicts.at:651: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -226. conflicts.at:647: ok -./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror -234. conflicts.at:1096: testing Syntax error in consistent error state: glr.c ... -212. conflicts.at:518: ok -./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -227. conflicts.at:651: ok -./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror -./conflicts.at:774: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y --warnings=none -Werror --trace=none - +./conflicts.at:381: $PREPARSER ./input '0<0' stderr: -input.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] -input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -input.y:12.3-18: error: rule useless in parser due to conflicts [-Werror=other] +./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror +212. conflicts.at:518: ok +./conflicts.at:381: $PREPARSER ./input '0<0<0' + +233. conflicts.at:1096: testing Syntax error in consistent error state: yacc.c ... +229. conflicts.at:764: ok +stderr: +./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror +syntax error, unexpected '<', expecting end of file +./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +225. conflicts.at:642: ok 235. conflicts.at:1096: testing Syntax error in consistent error state: lalr1.cc ... ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./conflicts.at:780: cat input.output -./conflicts.at:1033: sed 's,.*/$,,' stderr 1>&2 +./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +234. conflicts.at:1096: testing Syntax error in consistent error state: glr.c ... +./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./conflicts.at:381: $PREPARSER ./input '0>0' stderr: +./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 236. conflicts.at:1096: testing Syntax error in consistent error state: glr.cc ... ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -input.y:17.5-25: error: rule useless in parser due to conflicts [-Werror=other] -input.y:18.5-29: error: rule useless in parser due to conflicts [-Werror=other] -229. conflicts.at:764: ok + +./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Werror + + +./conflicts.at:381: $PREPARSER ./input '0>0>0' +./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror +stderr: 237. conflicts.at:1096: testing Syntax error in consistent error state: glr2.cc ... ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 +syntax error, unexpected '>', expecting end of file +./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Werror -./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error +./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror +239. conflicts.at:1264: testing %expect not enough ... +./conflicts.at:1273: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y +stderr: +input.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] +input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +input.y:12.3-18: error: rule useless in parser due to conflicts [-Werror=other] stderr: input.y:17.5-25: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.5-29: error: rule useless in parser due to conflicts [-Werror=other] -stderr: -stderr: ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Werror -./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error +./conflicts.at:381: $PREPARSER ./input '0<0>0' +./conflicts.at:1033: sed 's,.*/$,,' stderr 1>&2 +stderr: input.y:17.5-25: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.5-29: error: rule useless in parser due to conflicts [-Werror=other] -stderr: -stdout: -./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 -stdout: - -./conflicts.at:558: $PREPARSER ./input -./conflicts.at:626: $PREPARSER ./input -stderr: -stderr: -stderr: -stdout: -syntax error, unexpected end of file, expecting 'b' -./conflicts.at:558: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:732: $PREPARSER ./input -syntax error, unexpected 'b' -./conflicts.at:626: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 -./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error -stderr: -syntax error, unexpected 'a', expecting 'b' -./conflicts.at:732: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 238. conflicts.at:1127: testing Defaulted Conflicted Reduction ... ./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c --report=all input.y +239. conflicts.at:1264: ok stderr: -./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Werror -./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none -stdout: -./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none -./conflicts.at:388: $PREPARSER ./input '0<0' -219. conflicts.at:558: ok -stderr: -222. conflicts.at:626: ok -./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ - -o input.c input.y -./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=error stderr: input.y:17.5-25: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.5-29: error: rule useless in parser due to conflicts [-Werror=other] -./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 -./conflicts.at:388: $PREPARSER ./input '0<0<0' -./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none -stderr: +syntax error, unexpected '>', expecting end of file +./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error +./conflicts.at:381: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - -syntax error, unexpected '<', expecting end of file -./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 input.y:17.5-25: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.5-29: error: rule useless in parser due to conflicts [-Werror=other] -./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none +./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error +stderr: +input.y:17.5-25: error: rule useless in parser due to conflicts [-Werror=other] +input.y:18.5-29: error: rule useless in parser due to conflicts [-Werror=other] +./conflicts.at:388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -o input.c input.y +./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 +./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y -Werror -./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none -./conflicts.at:388: $PREPARSER ./input '0>0' ./conflicts.at:1096: sed 's,.*/$,,' stderr 1>&2 ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=error -stderr: -./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none -./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -239. conflicts.at:1264: testing %expect not enough ... -./conflicts.at:1273: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Wnone,none -Werror --trace=none +./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none +./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=error 240. conflicts.at:1284: testing %expect right ... -./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ - -o input.c input.y -Werror +./conflicts.at:388: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:1293: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error stderr: -./conflicts.at:388: $PREPARSER ./input '0>0>0' -239. conflicts.at:1264: ok input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y:4.6-8: error: rule useless in parser due to conflicts [-Werror=other] +./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=error -stderr: -syntax error, unexpected '>', expecting end of file -./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -232. conflicts.at:1015: ok ./conflicts.at:1138: sed 's,.*/$,,' stderr 1>&2 -./conflicts.at:1096: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./conflicts.at:388: $PREPARSER ./input '0<0>0' -./conflicts.at:1096: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y --warnings=error +./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none +./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Wnone,none -Werror --trace=none +./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Wnone,none -Werror --trace=none +stderr: +stdout: +./conflicts.at:732: $PREPARSER ./input stderr: +syntax error, unexpected 'a', expecting 'b' +./conflicts.at:732: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none +./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ + -o input.c input.y +240. conflicts.at:1284: ok +./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y --warnings=error +./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=none -Werror --trace=none +./conflicts.at:1096: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y -Wnone,none -Werror --trace=none +./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Wnone,none -Werror --trace=none ./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=none -Werror --trace=none -syntax error, unexpected '>', expecting end of file -./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -240. conflicts.at:1284: ok +./conflicts.at:1033: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none +./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none +./conflicts.at:1096: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ + -o input.c input.y -Werror +241. conflicts.at:1301: testing %expect too much ... +./conflicts.at:1310: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y +./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y --warnings=none -Werror --trace=none +./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=none -Werror --trace=none +241. conflicts.at:1301: ok +./conflicts.at:1096: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./conflicts.at:1096: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +232. conflicts.at:1015: ok stderr: -./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Wnone,none -Werror --trace=none input.y: error: 2 shift/reduce conflicts [-Werror=conflicts-sr] input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -209. conflicts.at:301: ok -./conflicts.at:737: sed 's,.*/$,,' stderr 1>&2 -241. conflicts.at:1301: testing %expect too much ... -./conflicts.at:1310: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y -Wnone,none -Werror --trace=none -./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y -Wnone,none -Werror --trace=none +./conflicts.at:737: sed 's,.*/$,,' stderr 1>&2 +./conflicts.at:1145: cat input.output 242. conflicts.at:1321: testing %expect with reduce conflicts ... -./conflicts.at:1330: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=none -Werror --trace=none -./conflicts.at:1096: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ -o input.c input.y --warnings=error -241. conflicts.at:1301: ok - -242. conflicts.at:1321: ok 243. conflicts.at:1341: testing %expect in grammar rule not enough ... ./conflicts.at:1350: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -./conflicts.at:1096: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.cc input.y --warnings=none -Werror --trace=none -./conflicts.at:1138: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c --report=all input.y --warnings=none -Werror --trace=none -244. conflicts.at:1360: testing %expect in grammar rule right ... -./conflicts.at:1369: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y - +./conflicts.at:1330: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y +./conflicts.at:1096: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +238. conflicts.at:1127: ok +242. conflicts.at:1321: ok 243. conflicts.at:1341: ok + ./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ -o input.c input.y -Wnone,none -Werror --trace=none -./conflicts.at:1096: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +244. conflicts.at:1360: testing %expect in grammar rule right ... +./conflicts.at:1369: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y + -./conflicts.at:1096: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 244. conflicts.at:1360: ok -./conflicts.at:1145: cat input.output +stderr: +stderr: +stdout: +stdout: +./conflicts.at:388: $PREPARSER ./input '0<0' +stderr: +./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 245. conflicts.at:1377: testing %expect in grammar rules ... ./conflicts.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -rall input.y +./conflicts.at:558: $PREPARSER ./input +246. conflicts.at:1396: testing %expect in grammar rule too much ... +./conflicts.at:388: $PREPARSER ./input '0<0<0' ./conflicts.at:737: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=canonical-lr -Dparse.lac=full \ -o input.c input.y --warnings=none -Werror --trace=none -238. conflicts.at:1127: ok -246. conflicts.at:1396: testing %expect in grammar rule too much ... +stderr: ./conflicts.at:1405: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y +stderr: +syntax error, unexpected end of file, expecting 'b' +./conflicts.at:558: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error, unexpected '<', expecting end of file +./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +245. conflicts.at:1377: ok +./conflicts.at:388: $PREPARSER ./input '0>0' +246. conflicts.at:1396: ok +./conflicts.at:742: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +219. conflicts.at:558: ok +stderr: +./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 247. conflicts.at:1415: testing %expect-rr in grammar rule ... ./conflicts.at:1432: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -246. conflicts.at:1396: ok +247. conflicts.at:1415: ok +./conflicts.at:388: $PREPARSER ./input '0>0>0' +stderr: +syntax error, unexpected '>', expecting end of file +./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + +./conflicts.at:388: $PREPARSER ./input '0<0>0' +stderr: +syntax error, unexpected '>', expecting end of file +stderr: +./conflicts.at:388: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 248. conflicts.at:1440: testing %expect-rr too much in grammar rule ... -245. conflicts.at:1377: ok ./conflicts.at:1457: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y +stdout: -247. conflicts.at:1415: ok +./conflicts.at:564: $PREPARSER ./input +stderr: +syntax error, unexpected end of file, expecting 'b' 249. conflicts.at:1469: testing %expect-rr not enough in grammar rule ... -248. conflicts.at:1440: ok ./conflicts.at:1486: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -./conflicts.at:742: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS - -249. conflicts.at:1469: ok -stderr: - +./conflicts.at:564: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +209. conflicts.at:301: ok 250. conflicts.at:1498: testing %prec with user string ... ./conflicts.at:1507: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -stdout: -./conflicts.at:1096: $PREPARSER ./input -stderr: +220. conflicts.at:564: ok +250. conflicts.at:1498: ok +248. conflicts.at:1440: ok 251. conflicts.at:1515: testing %no-default-prec without %prec ... ./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall -o input.c input.y +stderr: +249. conflicts.at:1469: ok +stdout: +./conflicts.at:1096: $PREPARSER ./input +stderr: syntax error ./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -250. conflicts.at:1498: ok + +253. conflicts.at:1568: testing %default-prec ... +233. conflicts.at:1096: ok + + 252. conflicts.at:1544: testing %no-default-prec with %prec ... ./conflicts.at:1560: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -233. conflicts.at:1096: ok -253. conflicts.at:1568: testing %default-prec ... ./conflicts.at:1584: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y - -./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y -Werror 254. conflicts.at:1592: testing Unreachable States After Conflict Resolution ... ./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all input.y -252. conflicts.at:1544: ok - -253. conflicts.at:1568: ok 255. conflicts.at:1855: testing Solved conflicts report for multiple reductions in a state ... ./conflicts.at:1881: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all -o input.c input.y -./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=all input.y -Werror -stderr: +252. conflicts.at:1544: ok 256. conflicts.at:1935: testing %nonassoc error actions for multiple reductions in a state ... ./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y -input.y: error: 4 shift/reduce conflicts [-Werror=conflicts-sr] -input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -input.y:1.1-5: error: useless precedence and associativity for '+' [-Werror=precedence] -input.y:2.1-5: error: useless precedence and associativity for '*' [-Werror=precedence] -stderr: -./conflicts.at:1531: sed 's,.*/$,,' stderr 1>&2 -stdout: -stderr: +253. conflicts.at:1568: ok +stderr: +./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y -Werror input.y:7.5-7: warning: rule useless in parser due to conflicts [-Wother] input.y:11.5-7: warning: rule useless in parser due to conflicts [-Wother] input.y:17.11-26: warning: rule useless in parser due to conflicts [-Wother] input.y:18.11-26: warning: rule useless in parser due to conflicts [-Wother] input.y:19.11-26: warning: rule useless in parser due to conflicts [-Wother] ./conflicts.at:1882: cat input.output | sed -n '/^State 0$/,/^State 1$/p' -./conflicts.at:564: $PREPARSER ./input -stderr: -stderr: -syntax error, unexpected end of file, expecting 'b' -input.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] -input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] -input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -input.y:12.5-20: error: rule useless in parser due to conflicts [-Werror=other] -input.y:20.5-20: error: rule useless in parser due to conflicts [-Werror=other] -input.y:21.4: error: rule useless in parser due to conflicts [-Werror=other] -input.y:25.14: error: rule useless in parser due to conflicts [-Werror=other] -input.y:25.16: error: rule useless in parser due to conflicts [-Werror=other] -input.y:31.5-7: error: rule useless in parser due to conflicts [-Werror=other] -input.y:32.4: error: rule useless in parser due to conflicts [-Werror=other] -./conflicts.at:564: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -255. conflicts.at:1855: ok -./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y --warnings=error -220. conflicts.at:564: ok -./conflicts.at:1638: sed 's,.*/$,,' stderr 1>&2 -257. conflicts.at:2299: testing %expect-rr non GLR ... -./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret 1.y -258. conflicts.at:2331: testing -W versus %expect and %expect-rr ... ./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y -Werror -./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret sr-rr.y -./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=all input.y --warnings=error - -./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y -Wnone,none -Werror --trace=none -./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y -Werror +./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=all input.y -Werror +stderr: stderr: bison (GNU Bison) 3.8.2 init: 0.000000 @@ -7196,24 +7205,35 @@ `-> 13: %empty . -./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret sr-rr.y -Werror +257. conflicts.at:2299: testing %expect-rr non GLR ... +./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret 1.y +255. conflicts.at:1855: ok +input.y: error: 4 shift/reduce conflicts [-Werror=conflicts-sr] +input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +input.y:1.1-5: error: useless precedence and associativity for '+' [-Werror=precedence] +input.y:2.1-5: error: useless precedence and associativity for '*' [-Werror=precedence] +stderr: +input.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] +input.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] +input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +input.y:12.5-20: error: rule useless in parser due to conflicts [-Werror=other] +input.y:20.5-20: error: rule useless in parser due to conflicts [-Werror=other] +input.y:21.4: error: rule useless in parser due to conflicts [-Werror=other] +input.y:25.14: error: rule useless in parser due to conflicts [-Werror=other] +input.y:25.16: error: rule useless in parser due to conflicts [-Werror=other] +input.y:31.5-7: error: rule useless in parser due to conflicts [-Werror=other] +input.y:32.4: error: rule useless in parser due to conflicts [-Werror=other] +./conflicts.at:1531: sed 's,.*/$,,' stderr 1>&2 +258. conflicts.at:2331: testing -W versus %expect and %expect-rr ... +./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret sr-rr.y +./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y --warnings=error 259. counterexample.at:43: testing Unifying S/R ... -260. counterexample.at:83: testing Deep Unifying S/R ... -./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=all input.y -Wnone,none -Werror --trace=none ./counterexample.at:55: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y +./conflicts.at:1638: sed 's,.*/$,,' stderr 1>&2 +./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=all input.y --warnings=error stderr: -./counterexample.at:95: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y -1.y: error: %expect-rr applies only to GLR parsers [-Werror=other] -./conflicts.at:1959: sed 's,.*/$,,' stderr 1>&2 -./conflicts.at:2307: sed 's,.*/$,,' stderr 1>&2 -stderr: -./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y --warnings=none -Werror --trace=none + stderr: -./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y --warnings=error -sr-rr.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] -sr-rr.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] -sr-rr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=all input.y --warnings=none -Werror --trace=none input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: A . B C @@ -7227,10 +7247,40 @@ `-> 3: A . `-> 6: B C input.y:4.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:55: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr -./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y --warnings=error +stdout: +./conflicts.at:1959: sed 's,.*/$,,' stderr 1>&2 +./conflicts.at:743: $PREPARSER ./input stderr: -./conflicts.at:2354: sed 's,.*/$,,' stderr 1>&2 +syntax error, unexpected 'a', expecting 'b' or 'c' +./conflicts.at:743: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./counterexample.at:55: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y +./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret sr-rr.y -Werror +./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y +./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y -Wnone,none -Werror --trace=none +./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y --warnings=error +./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y -Werror +260. counterexample.at:83: testing Deep Unifying S/R ... +./counterexample.at:95: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y +./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=all input.y -Wnone,none -Werror --trace=none +stderr: +./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y -Wnone,none -Werror --trace=none +input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] +input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] + Example A . B C + Shift derivation s -> [ y -> [ A . B ] c -> [ C ] ] + Reduce derivation s -> [ a -> [ A . ] x -> [ B C ] ] +input.y:4.4: warning: rule useless in parser due to conflicts [-Wother] +./counterexample.at:55: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr +stderr: +stderr: +sr-rr.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] +sr-rr.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] +sr-rr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +1.y: error: %expect-rr applies only to GLR parsers [-Werror=other] +./conflicts.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y --warnings=none -Werror --trace=none +./conflicts.at:1638: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --report=all input.y --warnings=none -Werror --trace=none +stderr: +./conflicts.at:2354: sed 's,.*/$,,' stderr 1>&2 input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: A . B C @@ -7260,25 +7310,30 @@ `-> 8: A a `-> 9: B bc C `-> 7: A . `-> 10: B C input.y:6.4: warning: rule useless in parser due to conflicts [-Wother] +./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y --warnings=none -Werror --trace=none +./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y -Werror +259. counterexample.at:43: ok +./conflicts.at:2307: sed 's,.*/$,,' stderr 1>&2 ./counterexample.at:95: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr + +./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret sr-rr.y --warnings=error +stderr: +input.y: error: 2 shift/reduce conflicts [-Werror=conflicts-sr] +input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +251. conflicts.at:1515: ./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y --warnings=error + ok ./counterexample.at:95: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y +./conflicts.at:748: sed 's,.*/$,,' stderr 1>&2 +261. counterexample.at:144: testing S/R Conflict with Nullable Symbols ... +./counterexample.at:157: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y +./conflicts.at:2239: cat input.output | sed -n '/^State 0$/,/^State 1$/p' +./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y --warnings=error ./conflicts.at:1651: cat input.output -./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y -Wnone,none -Werror --trace=none -./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret sr-rr.y --warnings=error +256. conflicts.at:1935: ok +./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret sr-rr.y -Wnone,none -Werror --trace=none stderr: -input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] -input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] - Example A . B C - Shift derivation s -> [ y -> [ A . B ] c -> [ C ] ] - Reduce derivation s -> [ a -> [ A . ] x -> [ B C ] ] -input.y:4.4: warning: rule useless in parser due to conflicts [-Wother] -./conflicts.at:1836: cat input.y >> input-keep.y -251. conflicts.at:1515: ok -./counterexample.at:55: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr -./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y -Wnone,none -Werror --trace=none -./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input-keep.y + stderr: -259. counterexample.at:43: ok input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example A . B C @@ -7290,34 +7345,16 @@ Reduce derivation s -> [ a -> [ A a -> [ A . ] ] bc -> [ B bc -> [ B C ] C ] ] input.y:6.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:95: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr -stderr: -./conflicts.at:1959: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --trace=cex -fcaret --report=all -o input.c input.y --warnings=none -Werror --trace=none - -./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret sr-rr.y -Wnone,none -Werror --trace=none stdout: -260. counterexample.at:83: ok -./conflicts.at:743: $PREPARSER ./input -./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y --warnings=none -Werror --trace=none -stderr: - -syntax error, unexpected 'a', expecting 'b' or 'c' -./conflicts.at:743: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret sr-rr.y --warnings=none -Werror --trace=none -261. counterexample.at:144: testing S/R Conflict with Nullable Symbols ... -./counterexample.at:157: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y -./conflicts.at:2239: cat input.output | sed -n '/^State 0$/,/^State 1$/p' -./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y -./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-keep.y -Werror -256. conflicts.at:1935: ok -262. counterexample.at:207: testing Non-unifying Ambiguous S/R ... -./counterexample.at:220: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y -./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret 2.y -./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y -263. counterexample.at:254: testing Non-unifying Unambiguous S/R ... -./counterexample.at:265: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y +./conflicts.at:1096: $PREPARSER ./input +260. counterexample.at:83: ok stderr: +./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y -Wnone,none -Werror --trace=none +syntax error +./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./conflicts.at:1836: cat input.y >> input-keep.y input.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: A . B @@ -7347,37 +7384,18 @@ `-> 5: X x `-> 4: %empty . input.y:5.4-9: warning: rule useless in parser due to conflicts [-Wother] +262. counterexample.at:207: testing Non-unifying Ambiguous S/R ... ./counterexample.at:157: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr -input-keep.y: error: 2 shift/reduce conflicts [-Werror=conflicts-sr] -input-keep.y: error: 2 reduce/reduce conflicts [-Werror=conflicts-rr] -input-keep.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -input-keep.y:22.4: error: rule useless in parser due to conflicts [-Werror=other] -input-keep.y:26.16: error: rule useless in parser due to conflicts [-Werror=other] -input-keep.y:32.5-7: error: rule useless in parser due to conflicts [-Werror=other] -input-keep.y:33.4: error: rule useless in parser due to conflicts [-Werror=other] +263. counterexample.at:254: testing Non-unifying Unambiguous S/R ... +./counterexample.at:220: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y +./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y -Wnone,none -Werror --trace=none +./conflicts.at:2354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret sr-rr.y --warnings=none -Werror --trace=none +./counterexample.at:265: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y +./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret input-keep.y +234. conflicts.at:1096: ok ./counterexample.at:157: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: -stderr: -input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] -input.y: warning: shift/reduce conflict on token C [-Wcounterexamples] - First example: B . C $end - Shift derivation - $accept - `-> 0: g $end - `-> 2: x - `-> 6: bc - `-> 9: B . C - Second example: B . C D $end - Reduce derivation - $accept - `-> 0: g $end - `-> 2: x - `-> 5: b cd - `-> 7: B . `-> 8: C D -input.y:6.4: warning: rule useless in parser due to conflicts [-Wother] -./conflicts.at:1838: sed 's,.*/$,,' stderr 1>&2 -./counterexample.at:220: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] First example: A . A B $end @@ -7395,12 +7413,14 @@ `-> 1: t `-> 3: x `-> 3: x `-> 5: A `-> 5: A . +./conflicts.at:2307: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 1.y --warnings=none -Werror --trace=none ./counterexample.at:265: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr -264. counterexample.at:298: testing S/R after first token ... -./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y -Werror -./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y -Werror -./counterexample.at:220: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: +./counterexample.at:265: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y + +stderr: +264. counterexample.at:298: testing S/R after first token ... +./counterexample.at:314: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y input.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example A . B @@ -7413,41 +7433,65 @@ Reduce derivation $accept -> [ s -> [ ax -> [ A x -> [ X x -> [ . ] ] ] by -> [ B y ] ] $end ] input.y:5.4-9: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:157: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr -./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-keep.y --warnings=error -./counterexample.at:265: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y -./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 2.y -Werror -./counterexample.at:314: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y -261. counterexample.at:144: ok -stderr: -stderr: -stderr: -sr-rr.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] -sr-rr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token C [-Wcounterexamples] - First example B . C $end - Shift derivation $accept -> [ g -> [ x -> [ bc -> [ B . C ] ] ] $end ] - Second example B . C D $end - Reduce derivation $accept -> [ g -> [ x -> [ b -> [ B . ] cd -> [ C D ] ] ] $end ] + First example: B . C $end + Shift derivation + $accept + `-> 0: g $end + `-> 2: x + `-> 6: bc + `-> 9: B . C + Second example: B . C D $end + Reduce derivation + $accept + `-> 0: g $end + `-> 2: x + `-> 5: b cd + `-> 7: B . `-> 8: C D input.y:6.4: warning: rule useless in parser due to conflicts [-Wother] -input.y: error: 2 shift/reduce conflicts [-Werror=conflicts-sr] -input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -./counterexample.at:220: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr -stderr: +./counterexample.at:220: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr +./counterexample.at:220: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y +./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y --warnings=none -Werror --trace=none +265. counterexample.at:363: testing Unifying R/R counterexample ... +./counterexample.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y +261. counterexample.at:144: ok +./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y +./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret 2.y +./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-keep.y -Werror stderr: -2.y: error: %expect-rr applies only to GLR parsers [-Werror=other] -2.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] -2.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -2.y:3.12-14: error: rule useless in parser due to conflicts [-Werror=other] input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] First example A . A B $end Shift derivation $accept -> [ s -> [ t -> [ y -> [ A . A B ] ] ] $end ] Second example A . A $end Reduce derivation $accept -> [ s -> [ s -> [ t -> [ x -> [ A . ] ] ] t -> [ x -> [ A ] ] ] $end ] +./counterexample.at:265: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr +stderr: +263. counterexample.at:254: ok stderr: -./counterexample.at:265: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr +input.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] +input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] + Example: A b . + First reduce derivation + a + `-> 1: A b . + Second reduce derivation + a + `-> 1: A b + `-> 3: b . +input.y:4.9: warning: rule useless in parser due to conflicts [-Wother] +stderr: +./counterexample.at:372: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr +input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] +input.y: warning: shift/reduce conflict on token C [-Wcounterexamples] + First example B . C $end + Shift derivation $accept -> [ g -> [ x -> [ bc -> [ B . C ] ] ] $end ] + Second example B . C D $end + Reduce derivation $accept -> [ g -> [ x -> [ b -> [ B . ] cd -> [ C D ] ] ] $end ] +input.y:6.4: warning: rule useless in parser due to conflicts [-Wother] +./counterexample.at:220: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr input.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] Example: b . A X X Y @@ -7475,42 +7519,37 @@ `-> 8: X . `-> 6: X xy input.y:4.4: warning: rule useless in parser due to conflicts [-Wother] input.y:8.4: warning: rule useless in parser due to conflicts [-Wother] -./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-keep.y -Wnone,none -Werror --trace=none ./counterexample.at:314: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr -262. counterexample.at:207: ok -./conflicts.at:748: sed 's,.*/$,,' stderr 1>&2 -./counterexample.at:314: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y -./conflicts.at:2359: sed 's,.*/$,,' stderr 1>&2 -stderr: -263. counterexample.at:254: ./conflicts.at:2317: sed 's,.*/$,,' stderr 1>&2 - ok -stdout: -./conflicts.at:1096: $PREPARSER ./input -265. counterexample.at:363: testing Unifying R/R counterexample ... -stderr: -./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y --warnings=error -./counterexample.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y -syntax error -./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y --warnings=error -./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 2.y --warnings=error - -./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-keep.y --warnings=none -Werror --trace=none +./conflicts.at:753: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./counterexample.at:372: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y -234. conflicts.at:1096: ok stderr: +./counterexample.at:314: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y +input-keep.y: error: 2 shift/reduce conflicts [-Werror=conflicts-sr] +input-keep.y: error: 2 reduce/reduce conflicts [-Werror=conflicts-rr] +input-keep.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +input-keep.y:22.4: error: rule useless in parser due to conflicts [-Werror=other] +input-keep.y:26.16: error: rule useless in parser due to conflicts [-Werror=other] +input-keep.y:32.5-7: error: rule useless in parser due to conflicts [-Werror=other] +input-keep.y:33.4: error: rule useless in parser due to conflicts [-Werror=other] +262. counterexample.at:207: ok +./conflicts.at:1838: sed 's,.*/$,,' stderr 1>&2 +266. counterexample.at:399: testing Non-unifying R/R LR(1) conflict ... +./counterexample.at:409: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y +./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 2.y -Werror +./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y -Werror stderr: input.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] - Example: A b . - First reduce derivation - a - `-> 1: A b . - Second reduce derivation - a - `-> 1: A b - `-> 3: b . + Example A b . + First reduce derivation a -> [ A b . ] + Second reduce derivation a -> [ A b -> [ b . ] ] input.y:4.9: warning: rule useless in parser due to conflicts [-Wother] +./counterexample.at:372: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr +267. counterexample.at:441: testing Non-unifying R/R LR(2) conflict ... +./counterexample.at:451: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y +./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-keep.y --warnings=error +stderr: input.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] Example b . A X X Y @@ -7524,23 +7563,10 @@ input.y:4.4: warning: rule useless in parser due to conflicts [-Wother] input.y:8.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:314: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr -./counterexample.at:372: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr -./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y -Wnone,none -Werror --trace=none -./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 2.y -Wnone,none -Werror --trace=none -267. counterexample.at:441: testing Non-unifying R/R LR(2) conflict ... -./counterexample.at:451: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y -266. counterexample.at:399: testing Non-unifying R/R LR(1) conflict ... -./counterexample.at:372: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y -264. counterexample.at:298: ok - -./counterexample.at:409: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y -./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y -Wnone,none -Werror --trace=none -254. conflicts.at:1592: ok -./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 2.y --warnings=none -Werror --trace=none -./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y --warnings=none -Werror --trace=none +265. counterexample.at:363: ok +264. counterexample.at:298: ok stderr: -268. counterexample.at:488: testing Cex Search Prepend ... input.y: warning: 2 reduce/reduce conflicts [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on tokens A, C [-Wcounterexamples] First example: D . A $end @@ -7557,25 +7583,24 @@ `-> 6: D . input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:409: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr -./counterexample.at:499: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y -stderr: -input.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] -input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] - Example A b . - First reduce derivation a -> [ A b . ] - Second reduce derivation a -> [ A b -> [ b . ] ] -input.y:4.9: warning: rule useless in parser due to conflicts [-Wother] -./counterexample.at:372: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr ./counterexample.at:409: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y - -265. counterexample.at:363: ok -./conflicts.at:748: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Dlr.type=ielr -Dparse.lac=full -o input.c input.y --warnings=none -Werror --trace=none -257. conflicts.at:2299: ok -269. counterexample.at:550: testing R/R cex with prec ... stderr: +sr-rr.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] +sr-rr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +stderr: +./conflicts.at:2359: sed 's,.*/$,,' stderr 1>&2 +2.y: error: %expect-rr applies only to GLR parsers [-Werror=other] +2.y: error: 1 reduce/reduce conflict [-Werror=conflicts-rr] +2.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +2.y:3.12-14: error: rule useless in parser due to conflicts [-Werror=other] +268. counterexample.at:488: testing Cex Search Prepend ... +./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y --warnings=error + +./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-keep.y -Wnone,none -Werror --trace=none +./counterexample.at:499: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y +./conflicts.at:2317: sed 's,.*/$,,' stderr 1>&2 stderr: -./counterexample.at:562: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y -270. counterexample.at:610: testing Null nonterminals ... + input.y: warning: 2 reduce/reduce conflicts [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on tokens A, C [-Wcounterexamples] First example D . A $end @@ -7584,8 +7609,12 @@ Second reduce derivation $accept -> [ s -> [ B b -> [ D . ] A ] $end ] input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:409: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr -./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y - +269. counterexample.at:550: testing R/R cex with prec ... +./counterexample.at:562: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y +266. counterexample.at:399: ok +./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 2.y --warnings=error +./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y -Wnone,none -Werror --trace=none +stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] Example: N A . B C @@ -7615,17 +7644,30 @@ `-> 7: A . input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:499: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr - -./counterexample.at:621: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y -266. counterexample.at:399: ok +./conflicts.at:1838: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input-keep.y --warnings=none -Werror --trace=none ./counterexample.at:499: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y -271. counterexample.at:797: testing Non-unifying Prefix Share ... -./counterexample.at:810: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y -stderr: +270. counterexample.at:610: testing Null nonterminals ... +./counterexample.at:621: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: -272. counterexample.at:842: testing Deep Null Unifying ... -./counterexample.at:854: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y +input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] +input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] + Example N A . B C + Shift derivation s -> [ n -> [ N b -> [ A . B C ] ] ] + Reduce derivation s -> [ n -> [ N a -> [ A . ] B ] C ] +input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] + Example N N A . B D C + Shift derivation s -> [ n -> [ N n -> [ N b -> [ A . B D ] ] C ] ] + Reduce derivation s -> [ n -> [ N n -> [ N a -> [ A . ] B ] D ] C ] +input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] +./counterexample.at:499: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr +./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 2.y -Wnone,none -Werror --trace=none +./conflicts.at:2359: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-sr sr-rr.y --warnings=none -Werror --trace=none +254. conflicts.at:1592: ok +271. counterexample.at:797: testing Non-unifying Prefix Share ... +./counterexample.at:810: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y +268. counterexample.at:488: ok +stderr: input.y: warning: 4 reduce/reduce conflicts [-Wconflicts-rr] input.y: warning: reduce/reduce conflict on tokens b, c [-Wcounterexamples] Example: B . b c @@ -7655,21 +7697,9 @@ `-> 4: C `-> 6: %empty `-> 7: A c A `-> 5: %empty . `-> 7: %empty -./conflicts.at:753: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./counterexample.at:562: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr -input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] -input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] - Example N A . B C - Shift derivation s -> [ n -> [ N b -> [ A . B C ] ] ] - Reduce derivation s -> [ n -> [ N a -> [ A . ] B ] C ] -input.y: warning: shift/reduce conflict on token B [-Wcounterexamples] - Example N N A . B D C - Shift derivation s -> [ n -> [ N n -> [ N b -> [ A . B D ] ] C ] ] - Reduce derivation s -> [ n -> [ N n -> [ N a -> [ A . ] B ] D ] C ] -input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] -./counterexample.at:499: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr -268. counterexample.at:488: ok -./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y -Werror +./conflicts.at:2317: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret 2.y --warnings=none -Werror --trace=none + ./counterexample.at:562: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] @@ -7687,9 +7717,33 @@ input.y:5.13-15: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:810: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr ./counterexample.at:810: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y -273. counterexample.at:884: testing Deep Null Non-unifying ... -./counterexample.at:896: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y + +257. conflicts.at:2299: ok +272. counterexample.at:842: testing Deep Null Unifying ... +./counterexample.at:854: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y +./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y +stderr: +input.y: warning: 4 reduce/reduce conflicts [-Wconflicts-rr] +input.y: warning: reduce/reduce conflict on tokens b, c [-Wcounterexamples] + Example B . b c + First reduce derivation S -> [ B -> [ A -> [ B . ] b A -> [ ] ] C -> [ A -> [ ] c A -> [ ] ] ] + Second reduce derivation S -> [ B C -> [ A -> [ B -> [ A -> [ . ] b A -> [ ] ] ] c A -> [ ] ] ] +input.y: warning: reduce/reduce conflict on tokens b, c [-Wcounterexamples] + Example C . c b + First reduce derivation S -> [ C -> [ A -> [ C . ] c A -> [ ] ] B -> [ A -> [ ] b A -> [ ] ] ] + Second reduce derivation S -> [ C B -> [ A -> [ C -> [ A -> [ . ] c A -> [ ] ] ] b A -> [ ] ] ] +./counterexample.at:562: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr +stderr: +input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] +input.y: warning: shift/reduce conflict on token J [-Wcounterexamples] + Example H i J . J J + Shift derivation s -> [ a -> [ H i J . J ] J ] + Reduce derivation s -> [ a -> [ H i -> [ i J . ] J J ] ] +input.y:5.13-15: warning: rule useless in parser due to conflicts [-Wother] + +./counterexample.at:810: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr stderr: +271. counterexample.at:797: ok input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token D [-Wcounterexamples] Example: A a . D @@ -7704,11 +7758,21 @@ `-> 4: c `-> 5: %empty . ./counterexample.at:854: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr +269. counterexample.at:550: ok +273. counterexample.at:884: testing Deep Null Non-unifying ... +./counterexample.at:896: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y +274. synclines.at:194: testing Prologue syncline ... -stderr: -sr-rr.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] +./synclines.at:194: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: ./counterexample.at:854: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y +stdout: +./conflicts.at:754: $PREPARSER ./input +275. synclines.at:214: testing %union syncline ... +./synclines.at:214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +stderr: +stderr: +./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y -Werror input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token D [-Wcounterexamples] First example: A a . D $end @@ -7727,39 +7791,62 @@ `-> 5: %empty . ./counterexample.at:896: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr stderr: -stderr: -./conflicts.at:2363: sed 's,.*/$,,' stderr 1>&2 -input.y: warning: 4 reduce/reduce conflicts [-Wconflicts-rr] -input.y: warning: reduce/reduce conflict on tokens b, c [-Wcounterexamples] - Example B . b c - First reduce derivation S -> [ B -> [ A -> [ B . ] b A -> [ ] ] C -> [ A -> [ ] c A -> [ ] ] ] - Second reduce derivation S -> [ B C -> [ A -> [ B -> [ A -> [ . ] b A -> [ ] ] ] c A -> [ ] ] ] -input.y: warning: reduce/reduce conflict on tokens b, c [-Wcounterexamples] - Example C . c b - First reduce derivation S -> [ C -> [ A -> [ C . ] c A -> [ ] ] B -> [ A -> [ ] b A -> [ ] ] ] - Second reduce derivation S -> [ C B -> [ A -> [ C -> [ A -> [ . ] c A -> [ ] ] ] b A -> [ ] ] ] -input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] -input.y: warning: shift/reduce conflict on token J [-Wcounterexamples] - Example H i J . J J - Shift derivation s -> [ a -> [ H i J . J ] J ] - Reduce derivation s -> [ a -> [ H i -> [ i J . ] J J ] ] -input.y:5.13-15: warning: rule useless in parser due to conflicts [-Wother] -./counterexample.at:562: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr +syntax error, unexpected 'a', expecting 'b' or 'c' ./counterexample.at:896: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y -./counterexample.at:810: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr -274. synclines.at:194: testing Prologue syncline ... -./synclines.at:194: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -271. counterexample.at:797: ok -269. counterexample.at:550: ok -./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y --warnings=error +./conflicts.at:754: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +stdout: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token D [-Wcounterexamples] Example A a . D Shift derivation s -> [ A a d -> [ . D ] ] Reduce derivation s -> [ A a a -> [ b -> [ c -> [ . ] ] ] d -> [ D ] ] ./counterexample.at:854: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr +./conflicts.at:1096: $PREPARSER ./input + +228. conflicts.at:676: ok +stderr: +./synclines.at:214: $CC $CFLAGS $CPPFLAGS -c syncline.c +272. counterexample.at:842: ok +syntax error +./synclines.at:194: $CC $CFLAGS $CPPFLAGS -c syncline.c +./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: + +syncline.c: In function 'foo': +syncline.c:4:2: error: #error "4" + 4 | #error "4" + | ^~~~~ +./synclines.at:214: "$PERL" -p -0777 - stderr <<\EOF || exit 77 + # Remove left-hand margin. + s/^[\d ]{6}\| //gm; + + # 1. Remove useless lines. + + # distcc clutter. + s/^distcc\[\d+\] .*\n//gm; + # c vs. c++. + s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; + # Function context. + s/^[^:]*: In function '[^']+':\n//gm; + # Caret error (with possible '~' to underline). + s/^ *#error.*\n *\^~*\n//gm; + # Number of errors. + s/^1 error generated\.\n//gm; + + # 2. Normalize the lines we kept. + + # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). + s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; + # Remove column. + s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; + # Map all combinations of "error: " and "#error: " to "#error ". + s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; +EOF + stderr: +276. synclines.at:237: testing %union name syncline ... input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token D [-Wcounterexamples] First example A a . D $end @@ -7767,18 +7854,17 @@ Second example A a . D E $end Reduce derivation $accept -> [ s -> [ A a a -> [ b -> [ c -> [ . ] ] ] d -> [ D ] E ] $end ] ./counterexample.at:896: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr -272. counterexample.at:842: ok - -./synclines.at:194: $CC $CFLAGS $CPPFLAGS -c syncline.c -273. counterexample.at:884: ok -./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y -Wnone,none -Werror --trace=none - +sr-rr.y: error: 1 shift/reduce conflict [-Werror=conflicts-sr] +stdout: +./synclines.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: -275. synclines.at:214: testing %union syncline ... syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ +syncline.c:4: #error "4" +./synclines.at:214: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 +273. counterexample.at:884: ok ./synclines.at:194: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; @@ -7806,30 +7892,28 @@ s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF -./synclines.at:214: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -276. synclines.at:237: testing %union name syncline ... +235. conflicts.at:1096: ok + +./conflicts.at:2363: sed 's,.*/$,,' stderr 1>&2 stdout: syncline.c:4: #error "4" - ./synclines.at:194: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 -./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y --warnings=none -Werror --trace=none -./synclines.at:253: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y - -stderr: -stdout: -./synclines.at:194: $CC $CFLAGS $CPPFLAGS -c input.c -./conflicts.at:754: $PREPARSER ./input -stderr: 277. synclines.at:264: testing Postprologue syncline ... -syntax error, unexpected 'a', expecting 'b' or 'c' +./synclines.at:194: $CC $CFLAGS $CPPFLAGS -c input.c +./synclines.at:214: $CC $CFLAGS $CPPFLAGS -c input.c ./synclines.at:264: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./conflicts.at:754: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y --warnings=error +./synclines.at:254: $CC $CFLAGS $CPPFLAGS -c syncline.c +278. synclines.at:291: testing Action syncline ... + +./synclines.at:291: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: -./synclines.at:214: $CC $CFLAGS $CPPFLAGS -c syncline.c input.y:2:2: error: #error "2" 2 | #error "2" | ^~~~~ -./synclines.at:194: "$PERL" -p -0777 - stderr <<\EOF || exit 77 +stderr: +stderr: +./synclines.at:214: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; @@ -7856,19 +7940,14 @@ s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF -278. synclines.at:291: testing Action syncline ... -./synclines.at:254: $CC $CFLAGS $CPPFLAGS -c syncline.c -./synclines.at:291: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -stdout: -stderr: -228. conflicts.at:676: ok -input.y:2: #error "2" -./synclines.at:194: cat stdout +input.y:2:2: error: #error "2" + 2 | #error "2" + | ^~~~~ syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ -./synclines.at:214: "$PERL" -p -0777 - stderr <<\EOF || exit 77 +./synclines.at:194: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; @@ -7895,13 +7974,6 @@ s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -./synclines.at:264: $CC $CFLAGS $CPPFLAGS -c syncline.c -stderr: -syncline.c: In function 'foo': -syncline.c:4:2: error: #error "4" - 4 | #error "4" - | ^~~~~ ./synclines.at:254: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; @@ -7929,10 +8001,25 @@ s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF -274. synclines.at:194: ok stdout: -stderr: +input.y:2: #error "2" + +./synclines.at:194: cat stdout +stdout: +stdout: +input.y:2: #error "2" syncline.c:4: #error "4" +./synclines.at:264: $CC $CFLAGS $CPPFLAGS -c syncline.c +./synclines.at:254: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 +274. synclines.at:194: ok +./synclines.at:214: cat stdout +./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y -Wnone,none -Werror --trace=none +279. synclines.at:310: testing Epilogue syncline ... +./synclines.at:310: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +280. synclines.at:327: testing %code top syncline ... +./synclines.at:254: $CC $CFLAGS $CPPFLAGS -c input.c +275. synclines.at:214: ok +stderr: syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" @@ -7964,26 +8051,14 @@ s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -stdout: -./synclines.at:254: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 -syncline.c:4: #error "4" -./synclines.at:214: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 +./synclines.at:327: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./synclines.at:291: $CC $CFLAGS $CPPFLAGS -c syncline.c -stdout: - -syncline.c:4: #error "4" -./synclines.at:254: $CC $CFLAGS $CPPFLAGS -c input.c -./synclines.at:264: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 - -./synclines.at:214: $CC $CFLAGS $CPPFLAGS -c input.c -./synclines.at:264: $CC $CFLAGS $CPPFLAGS -c input.c +./synclines.at:310: $CC $CFLAGS $CPPFLAGS -c syncline.c stderr: syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ -stderr: ./synclines.at:291: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; @@ -8011,10 +8086,15 @@ s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF -input.y:2:2: error: #error "2" - 2 | #error "2" +stdout: +syncline.c:4: #error "4" +stderr: +./synclines.at:264: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 +syncline.c: In function 'foo': +syncline.c:4:2: error: #error "4" + 4 | #error "4" | ^~~~~ -./synclines.at:214: "$PERL" -p -0777 - stderr <<\EOF || exit 77 +./synclines.at:310: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; @@ -8041,23 +8121,15 @@ s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF +./synclines.at:264: $CC $CFLAGS $CPPFLAGS -c input.c +./conflicts.at:2363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wno-conflicts-rr sr-rr.y --warnings=none -Werror --trace=none + stdout: -279. synclines.at:310: testing Epilogue syncline ... -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -280. synclines.at:327: testing %code top syncline ... syncline.c:4: #error "4" -./synclines.at:327: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -stdout: -./synclines.at:291: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 -stderr: -./synclines.at:310: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -input.y:2: #error "2" +./synclines.at:310: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 + +./synclines.at:327: $CC $CFLAGS $CPPFLAGS -c syncline.c stderr: -./synclines.at:214: cat stdout -./synclines.at:291: $CC $CFLAGS $CPPFLAGS -c input.c -input.y:13:2: error: #error "13" - 13 | #error "13" - | ^~~~~ input.y:1:7: error: expected '{' before 'break' 1 | %union break | ^~~~~ @@ -8199,6 +8271,42 @@ input.c:1162:11: error: implicit declaration of function 'yydestruct' [-Wimplicit-function-declaration] 1162 | yydestruct ("Error: discarding", | ^~~~~~~~~~ +282. synclines.at:370: testing %printer syncline ... +stdout: +./synclines.at:254: "$PERL" -p -0777 - stderr <<\EOF || exit 77 + # Remove left-hand margin. + s/^[\d ]{6}\| //gm; + + # 1. Remove useless lines. + + # distcc clutter. + s/^distcc\[\d+\] .*\n//gm; + # c vs. c++. + s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; + # Function context. + s/^[^:]*: In function '[^']+':\n//gm; + # Caret error (with possible '~' to underline). + s/^ *#error.*\n *\^~*\n//gm; + # Number of errors. + s/^1 error generated\.\n//gm; + + # 2. Normalize the lines we kept. + + # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). + s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; + # Remove column. + s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; + # Map all combinations of "error: " and "#error: " to "#error ". + s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; +EOF + +./synclines.at:370: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +syncline.c:4: #error "4" +./synclines.at:291: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 +stderr: +input.y:13:2: error: #error "13" + 13 | #error "13" + | ^~~~~ ./synclines.at:264: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; @@ -8226,7 +8334,17 @@ s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF -./synclines.at:254: "$PERL" -p -0777 - stderr <<\EOF || exit 77 +./synclines.at:310: $CC $CFLAGS $CPPFLAGS -c input.c +281. synclines.at:346: testing %destructor syncline ... +./synclines.at:346: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +stderr: +./synclines.at:291: $CC $CFLAGS $CPPFLAGS -c input.c +syncline.c: In function 'foo': +syncline.c:4:2: error: #error "4" + 4 | #error "4" + | ^~~~~ +stdout: +./synclines.at:327: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; @@ -8253,12 +8371,46 @@ s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stdout: +syncline.c:4: #error "4" +./synclines.at:327: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 stdout: -275. synclines.at:214: ok input.y:13: #error "13" +stderr: +stderr: +./synclines.at:327: $CC $CFLAGS $CPPFLAGS -c input.c ./synclines.at:264: cat stdout +input.y:8:2: error: #error "8" + 8 | #error "8" + | ^~~~~ +stdout: +./synclines.at:310: "$PERL" -p -0777 - stderr <<\EOF || exit 77 + # Remove left-hand margin. + s/^[\d ]{6}\| //gm; + + # 1. Remove useless lines. + + # distcc clutter. + s/^distcc\[\d+\] .*\n//gm; + # c vs. c++. + s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; + # Function context. + s/^[^:]*: In function '[^']+':\n//gm; + # Caret error (with possible '~' to underline). + s/^ *#error.*\n *\^~*\n//gm; + # Number of errors. + s/^1 error generated\.\n//gm; + + # 2. Normalize the lines we kept. + + # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). + s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; + # Remove column. + s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; + # Map all combinations of "error: " and "#error: " to "#error ". + s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; +EOF + input.y:1: #error expected '{' before 'break' %union break ^~~~~ @@ -8397,96 +8549,30 @@ input.c:1162: #error implicit declaration of function 'yydestruct' [-Wimplicit-function-declaration] yydestruct ("Error: discarding", ^~~~~~~~~~ +./conflicts.at:1096: $PREPARSER ./input ./synclines.at:255: grep '^input.y:1' stdout -stderr: -input.y: In function 'yyparse': -input.y:8:2: error: #error "8" - 8 | #error "8" - | ^~~~~ -stderr: -stdout: -./synclines.at:291: "$PERL" -p -0777 - stderr <<\EOF || exit 77 - # Remove left-hand margin. - s/^[\d ]{6}\| //gm; - - # 1. Remove useless lines. - - # distcc clutter. - s/^distcc\[\d+\] .*\n//gm; - # c vs. c++. - s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; - # Function context. - s/^[^:]*: In function '[^']+':\n//gm; - # Caret error (with possible '~' to underline). - s/^ *#error.*\n *\^~*\n//gm; - # Number of errors. - s/^1 error generated\.\n//gm; - - # 2. Normalize the lines we kept. - - # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). - s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; - # Remove column. - s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; - # Map all combinations of "error: " and "#error: " to "#error ". - s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; -EOF - -277. synclines.at:264: ok -./synclines.at:327: $CC $CFLAGS $CPPFLAGS -c syncline.c -input.y:1: #error expected '{' before 'break' -input.y:1: #error expected '{' before 'break' -276. synclines.at:237: ok -./synclines.at:310: $CC $CFLAGS $CPPFLAGS -c syncline.c stdout: stdout: -./conflicts.at:1096: $PREPARSER ./input stderr: -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file input.y:8: #error "8" -./synclines.at:291: cat stdout -stderr: -syncline.c: In function 'foo': -syncline.c:4:2: error: #error "4" - 4 | #error "4" - | ^~~~~ -./synclines.at:327: "$PERL" -p -0777 - stderr <<\EOF || exit 77 - # Remove left-hand margin. - s/^[\d ]{6}\| //gm; - - # 1. Remove useless lines. - - # distcc clutter. - s/^distcc\[\d+\] .*\n//gm; - # c vs. c++. - s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; - # Function context. - s/^[^:]*: In function '[^']+':\n//gm; - # Caret error (with possible '~' to underline). - s/^ *#error.*\n *\^~*\n//gm; - # Number of errors. - s/^1 error generated\.\n//gm; - - # 2. Normalize the lines we kept. - - # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). - s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; - # Remove column. - s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; - # Map all combinations of "error: " and "#error: " to "#error ". - s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; -EOF - +./synclines.at:310: cat stdout syntax error -stderr: ./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -278. synclines.at:291: ok -syncline.c: In function 'foo': -syncline.c:4:2: error: #error "4" - 4 | #error "4" +input.y:1: #error expected '{' before 'break' +input.y:1: #error expected '{' before 'break' +279. synclines.at:310: ok +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +276. synclines.at:237: ok +stderr: +277. synclines.at:264: ok +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file +input.y: In function 'yyparse': +input.y:8:2: error: #error "8" + 8 | #error "8" | ^~~~~ - -./synclines.at:310: "$PERL" -p -0777 - stderr <<\EOF || exit 77 +./synclines.at:370: $CC $CFLAGS $CPPFLAGS -c syncline.c +./synclines.at:346: $CC $CFLAGS $CPPFLAGS -c syncline.c +./synclines.at:291: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; @@ -8513,28 +8599,10 @@ s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF -stdout: -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -syncline.c:4: #error "4" +stderr: -./synclines.at:327: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 -stdout: -236. conflicts.at:1096: ok -syncline.c:4: #error "4" -./synclines.at:310: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -./synclines.at:327: $CC $CFLAGS $CPPFLAGS -c input.c -282. synclines.at:370: testing %printer syncline ... -./synclines.at:370: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -283. synclines.at:440: testing syncline escapes: yacc.c ... -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -281. synclines.at:346: testing %destructor syncline ... -./synclines.at:346: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./synclines.at:310: $CC $CFLAGS $CPPFLAGS -c input.c -./synclines.at:440: $CC $CFLAGS $CPPFLAGS \"\\\"\".c -o \"\\\"\" || exit 77 -stderr: input.y:2:2: error: #error "2" 2 | #error "2" | ^~~~~ @@ -8565,60 +8633,22 @@ s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF - -stderr: -284. synclines.at:440: testing syncline escapes: glr.c ... -input.y:8:2: error: #error "8" - 8 | #error "8" - | ^~~~~ -./synclines.at:310: "$PERL" -p -0777 - stderr <<\EOF || exit 77 - # Remove left-hand margin. - s/^[\d ]{6}\| //gm; - - # 1. Remove useless lines. - - # distcc clutter. - s/^distcc\[\d+\] .*\n//gm; - # c vs. c++. - s/^clang: warning: treating 'c' input as 'c\+\+'.*\n//gm; - # Function context. - s/^[^:]*: In function '[^']+':\n//gm; - # Caret error (with possible '~' to underline). - s/^ *#error.*\n *\^~*\n//gm; - # Number of errors. - s/^1 error generated\.\n//gm; - - # 2. Normalize the lines we kept. - - # xlc messages. Remove also error identifier (e.g., "1540-0218 (S)"). - s/^"(.*?)", line ([\w.]*): \d+-\d+ \(.\) /$1:$2: /gm; - # Remove column. - s/^([^:]+:\d+)[.:][^:]+:(.+)$/$1:$2/gm; - # Map all combinations of "error: " and "#error: " to "#error ". - s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; -EOF - stdout: -input.y:8: #error "8" -./synclines.at:310: cat stdout stdout: +stderr: +stderr: input.y:2: #error "2" +236. conflicts.at:1096: ok ./synclines.at:327: cat stdout -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -./synclines.at:440: $CC $CFLAGS $CPPFLAGS \"\\\"\".c -o \"\\\"\" || exit 77 -./synclines.at:346: $CC $CFLAGS $CPPFLAGS -c syncline.c -./synclines.at:370: $CC $CFLAGS $CPPFLAGS -c syncline.c -279. synclines.at:310: ok -285. synclines.at:440: testing syncline escapes: lalr1.cc ... -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -stderr: -280. synclines.at:327: ok -./synclines.at:440: $CXX $CXXFLAGS $CPPFLAGS \"\\\"\".cc -o \"\\\"\" || exit 77 syncline.c: In function 'foo': syncline.c:4:2: error: #error "4" 4 | #error "4" | ^~~~~ -./synclines.at:346: "$PERL" -p -0777 - stderr <<\EOF || exit 77 +syncline.c: In function 'foo': +syncline.c:4:2: error: #error "4" + 4 | #error "4" + | ^~~~~ +./synclines.at:370: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; @@ -8645,16 +8675,7 @@ s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF -stdout: -stderr: - -syncline.c:4: #error "4" -syncline.c: In function 'foo': -syncline.c:4:2: error: #error "4" - 4 | #error "4" - | ^~~~~ -./synclines.at:346: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 -./synclines.at:370: "$PERL" -p -0777 - stderr <<\EOF || exit 77 +./synclines.at:346: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; @@ -8681,11 +8702,28 @@ s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF -./synclines.at:346: $CC $CFLAGS $CPPFLAGS -c input.c +283. synclines.at:440: testing syncline escapes: yacc.c ... +input.y:8: #error "8" +./synclines.at:291: cat stdout +280. synclines.at:327: ok +stdout: stdout: +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file syncline.c:4: #error "4" ./synclines.at:370: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +./synclines.at:440: $CC $CFLAGS $CPPFLAGS \"\\\"\".c -o \"\\\"\" || exit 77 +syncline.c:4: #error "4" +./synclines.at:346: test "`cat stdout`" = 'syncline.c:4: #error "4"' || exit 77 +278. synclines.at:291: 285. synclines.at:440: testing syncline escapes: lalr1.cc ... +./synclines.at:440: $CXX $CXXFLAGS $CPPFLAGS \"\\\"\".cc -o \"\\\"\" || exit 77 + ok +./synclines.at:370: $CC $CFLAGS $CPPFLAGS -c input.c +./synclines.at:346: $CC $CFLAGS $CPPFLAGS -c input.c +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file +284. synclines.at:440: testing syncline escapes: glr.c ... +./synclines.at:440: $CC $CFLAGS $CPPFLAGS \"\\\"\".c -o \"\\\"\" || exit 77 + + stderr: stderr: input.y: In function 'yydestruct': @@ -8719,26 +8757,10 @@ s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF - -stdout: -./synclines.at:370: $CC $CFLAGS $CPPFLAGS -c input.c -stdout: -input.y:2: #error "2" -./synclines.at:346: cat stdout -./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".c \"\\\"\".y -stderr: -286. synclines.at:440: testing syncline escapes: glr.cc ... -287. synclines.at:440: testing syncline escapes: glr2.cc ... -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -stderr: -stderr: -./synclines.at:440: $CXX $CXXFLAGS $CPPFLAGS \"\\\"\".cc -o \"\\\"\" || exit 77 input.y: In function 'yy_symbol_value_print': input.y:2:2: error: #error "2" 2 | #error "2" | ^~~~~ -./synclines.at:440: $CXX $CXXFLAGS $CPPFLAGS \"\\\"\".cc -o \"\\\"\" || exit 77 -stdout: ./synclines.at:370: "$PERL" -p -0777 - stderr <<\EOF || exit 77 # Remove left-hand margin. s/^[\d ]{6}\| //gm; @@ -8766,390 +8788,406 @@ s/^([^:]+:\d+):( |#error|error|:)+/$1: #error /gm; EOF +287. synclines.at:440: testing syncline escapes: glr2.cc ... +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stdout: -281. synclines.at:346: ok -./conflicts.at:1096: $PREPARSER ./input +input.y:2: #error "2" stdout: +./synclines.at:346: cat stdout input.y:2: #error "2" ./synclines.at:370: cat stdout -./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".c \"\\\"\".y -stderr: -syntax error -./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +./synclines.at:440: $CXX $CXXFLAGS $CPPFLAGS \"\\\"\".cc -o \"\\\"\" || exit 77 +286. synclines.at:440: testing syncline escapes: glr.cc ... +./synclines.at:440: $CXX $CXXFLAGS $CPPFLAGS \"\\\"\".cc -o \"\\\"\" || exit 77 -./synclines.at:440: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".c $LIBS +281. synclines.at:346: ok 282. synclines.at:370: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: -235. conflicts.at:1096: ok 288. synclines.at:497: testing %no-lines: yacc.c ... -stderr: -stderr: -stdout: -./synclines.at:440: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".c $LIBS -stdout: ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.c -d input.y stdout: +stderr: +stdout: +./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".c \"\\\"\".y +./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".c \"\\\"\".y -./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".cc \"\\\"\".y -./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".cc \"\\\"\".y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".cc \"\\\"\".y -289. synclines.at:497: testing %no-lines: glr.c ... -./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.c -d input.y -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file +stderr: ./synclines.at:497: mv input.c without.c +stdout: +stderr: ./synclines.at:497: mv input.h without.h ./synclines.at:497: grep '#line' *.c *.h +stdout: +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file +289. synclines.at:497: testing %no-lines: glr.c ... +./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -d input.y +./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.c -d input.y +./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".cc \"\\\"\".y +./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".cc \"\\\"\".y 290. synclines.at:497: testing %no-lines: lalr1.cc ... ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.cc -d input.y -./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -d input.y -./synclines.at:440: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".cc $LIBS -stderr: ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -stdout: -./synclines.at:440: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".cc $LIBS -./synclines.at:440: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".cc $LIBS -283. synclines.at:440: ok +./synclines.at:440: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".c $LIBS ./synclines.at:497: mv input.c without.c -./synclines.at:497: mv input.c with.c -./synclines.at:497: mv input.h with.h -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./synclines.at:497: mv input.h without.h ./synclines.at:497: mv input.cc without.cc -./synclines.at:497: grep -v '#line' with.c >expout ./synclines.at:497: grep '#line' *.c *.h -./synclines.at:497: mv input.hh without.hh +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file +stderr: ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -d input.y +stdout: +./synclines.at:497: mv input.hh without.hh ./synclines.at:497: grep '#line' *.cc *.hh - -./synclines.at:497: cat without.c -./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file ./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc -d input.y -./synclines.at:497: grep -v '#line' with.h >expout -./synclines.at:497: cat without.h +./synclines.at:440: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".cc $LIBS +./synclines.at:440: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".c $LIBS +./synclines.at:440: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".cc $LIBS +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +./synclines.at:440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o \"\\\"\".cc \"\\\"\".y ./synclines.at:497: mv input.c with.c -288. synclines.at:497: ok +./synclines.at:497: mv input.c with.c +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./synclines.at:497: mv input.h with.h -291. synclines.at:497: testing %no-lines: glr.cc ... -./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.cc -d input.y -./synclines.at:497: mv input.cc with.cc ./synclines.at:497: grep -v '#line' with.c >expout +./synclines.at:497: mv input.h with.h +./synclines.at:497: cat without.c +./synclines.at:497: grep -v '#line' with.c >expout +./synclines.at:497: grep -v '#line' with.h >expout +./synclines.at:497: cat without.c +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +./synclines.at:497: cat without.h +./synclines.at:497: mv input.cc with.cc ./synclines.at:497: mv input.hh with.hh -./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file ./synclines.at:497: grep -v '#line' with.cc >expout -./synclines.at:497: cat without.c - ./synclines.at:497: cat without.cc -./synclines.at:497: grep -v '#line' with.h >expout ./synclines.at:497: grep -v '#line' with.hh >expout -./synclines.at:497: mv input.cc without.cc -./synclines.at:497: cat without.h -./synclines.at:497: mv input.hh without.hh +./synclines.at:497: grep -v '#line' with.h >expout +./synclines.at:440: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o \"\\\"\" \"\\\"\".cc $LIBS ./synclines.at:497: cat without.hh -./synclines.at:497: grep '#line' *.cc *.hh -292. synclines.at:497: testing %no-lines: glr2.cc ... -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.cc -d input.y +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 289. synclines.at:497: ok -./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc -d input.y +./synclines.at:497: cat without.h 290. synclines.at:497: ok -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file +288. synclines.at:497: ok -./synclines.at:497: mv input.cc with.cc -./synclines.at:497: mv input.hh with.hh + +292. synclines.at:497: testing %no-lines: glr2.cc ... +./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.cc -d input.y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -./synclines.at:497: mv input.cc without.cc +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file +291. synclines.at:497: testing %no-lines: glr.cc ... +./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --no-lines -o input.cc -d input.y +./synclines.at:497: mv input.cc without.cc +./synclines.at:497: mv input.hh without.hh +./synclines.at:497: grep '#line' *.cc *.hh +./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc -d input.y +stderr: +stdout: +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file 293. synclines.at:507: testing Output columns ... ./synclines.at:540: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./synclines.at:497: mv input.cc with.cc +./synclines.at:497: mv input.hh with.hh +283. synclines.at:440: ok ./synclines.at:497: grep -v '#line' with.cc >expout -./synclines.at:497: mv input.hh without.hh -./synclines.at:497: grep '#line' *.cc *.hh +./synclines.at:497: mv input.cc without.cc ./synclines.at:497: cat without.cc ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc -d input.y -294. headers.at:56: testing Invalid CPP guards: --defines=input/input.h ... +./synclines.at:497: mv input.hh without.hh ./synclines.at:497: grep -v '#line' with.hh >expout +./synclines.at:497: grep '#line' *.cc *.hh + +./synclines.at:497: cat without.hh +./synclines.at:497: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc -d input.y ./synclines.at:541: sed -ne '/--BEGIN/,/--END/{' \ -e '/input.c/s/ [0-9]* / LINE /;' \ -e 'p;}' \ input.c -./synclines.at:497: cat without.hh -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -./headers.at:56: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --defines=input/input.h --output=input/input.c input/input.y -291. synclines.at:497: ok +./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file +292. synclines.at:497: ok +294. headers.at:56: testing Invalid CPP guards: --defines=input/input.h ... +293. synclines.at:507: ok ./synclines.at:497: mv input.cc with.cc ./synclines.at:497: mv input.hh with.hh -293. synclines.at:507: ok ./synclines.at:497: grep -v '#line' with.cc >expout -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./synclines.at:497: cat without.cc -stderr: - -stdout: -./headers.at:56: $CC $CFLAGS $CPPFLAGS -c -o input/input.o -I. -c input/input.c +./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file +./headers.at:56: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --defines=input/input.h --output=input/input.c input/input.y ./synclines.at:497: grep -v '#line' with.hh >expout -284. synclines.at:440: ok -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./synclines.at:497: cat without.hh + +291. synclines.at:497: ok 295. headers.at:57: testing Invalid CPP guards: --defines=9foo.h ... -292. synclines.at:497: ok -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -296. headers.at:58: testing Invalid CPP guards: %glr-parser --defines=input/input.h ... ./headers.at:57: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --defines=9foo.h --output=9foo.c 9foo.y +./headers.at:56: $CC $CFLAGS $CPPFLAGS -c -o input/input.o -I. -c input/input.c +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +296. headers.at:58: testing Invalid CPP guards: %glr-parser --defines=input/input.h ... +./headers.at:57: $CC $CFLAGS $CPPFLAGS -c -o 9foo.o -I. -c 9foo.c +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:58: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --defines=input/input.h --output=input/input.c input/input.y - -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -297. headers.at:59: testing Invalid CPP guards: %glr-parser --defines=9foo.h ... stderr: -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -./headers.at:57: $CC $CFLAGS $CPPFLAGS -c -o 9foo.o -I. -c 9foo.c stdout: -./headers.at:59: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --defines=9foo.h --output=9foo.c 9foo.y -298. headers.at:67: testing export YYLTYPE ... -./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --header -o input.c input.y -294. headers.at:56: ok +297. headers.at:59: testing Invalid CPP guards: %glr-parser --defines=9foo.h ... ./headers.at:58: $CC $CFLAGS $CPPFLAGS -c -o input/input.o -I. -c input/input.c ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -./headers.at:59: $CC $CFLAGS $CPPFLAGS -c -o 9foo.o -I. -c 9foo.c +294. headers.at:56: ok +./headers.at:59: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --defines=9foo.h --output=9foo.c 9foo.y +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file +stderr: +./headers.at:59: $CC $CFLAGS $CPPFLAGS -c -o 9foo.o -I. -c 9foo.c +stderr: +stdout: +stdout: +284. synclines.at:440: ok +298. headers.at:67: testing export YYLTYPE ... +295. headers.at:57: ok +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --header -o input.c input.y ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header -o input.c input.y -Werror + + 299. headers.at:177: testing Sane headers: ... ./headers.at:177: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y -stderr: -stdout: +./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header -o input.c input.y -Werror ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +300. headers.at:178: testing Sane headers: %locations %debug ... +./headers.at:178: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y stderr: -295. headers.at:57: input.y:11.1-18: error: deprecated directive: '%name-prefix "my_"', use '%define api.prefix {my_}' [-Werror=deprecated] -input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] - ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file +stderr: +stdout: +./conflicts.at:1096: $PREPARSER ./input +input.y:11.1-18: error: deprecated directive: '%name-prefix "my_"', use '%define api.prefix {my_}' [-Werror=deprecated] +input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] +stderr: +syntax error +./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./headers.at:177: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c +237. conflicts.at:1096: ok ./headers.at:85: sed 's,.*/$,,' stderr 1>&2 - ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header -o input.c input.y --warnings=error +./headers.at:178: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c + ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -300. headers.at:178: testing Sane headers: %locations %debug ... -./headers.at:178: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y +./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header -o input.c input.y --warnings=error +301. headers.at:180: testing Sane headers: %glr-parser ... +./headers.at:180: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y ./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header -o input.c input.y -Wnone,none -Werror --trace=none ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -./headers.at:178: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c +./headers.at:180: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:85: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret --header -o input.c input.y --warnings=none -Werror --trace=none stderr: stdout: -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:177: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -./headers.at:102: $CC $CFLAGS $CPPFLAGS -c -o caller.o caller.c stderr: +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stdout: -299. headers.at:177: ok +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: stdout: -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +299. headers.at:177: ok 296. headers.at:58: ok -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -stderr: +./headers.at:102: $CC $CFLAGS $CPPFLAGS -c -o caller.o caller.c stderr: stdout: -stderr: -stdout: -286. synclines.at:440: ok -stdout: -./headers.at:103: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c -301. headers.at:180: testing Sane headers: %glr-parser ... -./headers.at:180: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y -./conflicts.at:1096: $PREPARSER ./input +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +297. headers.at:59: ok +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: -syntax error -./conflicts.at:1096: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -./headers.at:180: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c 302. headers.at:181: testing Sane headers: %locations %debug %glr-parser ... -./headers.at:181: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y stderr: stdout: -237. conflicts.at:1096: ok -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -297. headers.at:59: ok -stderr: -303. headers.at:183: testing Sane headers: api.pure ... +./headers.at:181: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y stdout: -./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file -./headers.at:181: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c 285. synclines.at:440: ok +304. headers.at:184: testing Sane headers: api.push-pull=both ... +./headers.at:184: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y +303. headers.at:183: testing Sane headers: api.pure ... +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./headers.at:183: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y +./headers.at:103: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c +./headers.at:181: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file +./headers.at:184: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c +./headers.at:183: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c -./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file - +stderr: +stdout: +286. synclines.at:440: ok +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -./headers.at:183: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c -304. headers.at:184: testing Sane headers: api.push-pull=both ... -./headers.at:184: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y 305. headers.at:185: testing Sane headers: api.pure api.push-pull=both ... ./headers.at:185: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.c input.y -./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: -306. headers.at:187: testing Sane headers: c++ ... -stdout: -./headers.at:187: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.cc input.y -./headers.at:104: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o caller caller.o input.o $LIBS stderr: -./headers.at:184: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c stdout: -./headers.at:185: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c -./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file +stdout: +./headers.at:104: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o caller caller.o input.o $LIBS ./headers.at:178: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c -./headers.at:187: $CXX $CPPFLAGS $CXXFLAGS -c -o input.o input.cc +306. headers.at:187: testing Sane headers: c++ ... +./headers.at:187: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.cc input.y +./headers.at:185: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c stderr: +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stdout: +./headers.at:187: $CXX $CPPFLAGS $CXXFLAGS -c -o input.o input.cc ./headers.at:105: $PREPARSER ./caller stderr: -stderr: ./headers.at:105: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -300. headers.at:178: ok 298. headers.at:67: ok +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +stderr: +stdout: stderr: stdout: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -./headers.at:183: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c +300. headers.at:178: ok +./headers.at:184: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c +./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file +stderr: +stdout: +304. headers.at:184: ok -stderr: +./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file + +308. headers.at:189: testing Sane headers: c++ api.value.type=variant parse.assert ... +./headers.at:189: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.cc input.y +307. headers.at:188: testing Sane headers: %locations %debug c++ ... +./headers.at:188: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.cc input.y +./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file +309. headers.at:191: testing Sane headers: %locations c++ %glr-parser ... +./headers.at:191: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.cc input.y +./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file +./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o input.o input.cc ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file +./headers.at:189: $CXX $CPPFLAGS $CXXFLAGS -c -o input.o input.cc stderr: stdout: +./headers.at:183: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c +stderr: stdout: -308. headers.at:189: testing Sane headers: c++ api.value.type=variant parse.assert ... -303. headers.at:183: ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file - ok -307. headers.at:188: testing Sane headers: %locations %debug c++ ... -./headers.at:189: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.cc input.y -./headers.at:188: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.cc input.y -./headers.at:184: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c +./headers.at:191: $CXX $CPPFLAGS $CXXFLAGS -c -o input.o input.cc ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file - stderr: stdout: -./headers.at:189: $CXX $CPPFLAGS $CXXFLAGS -c -o input.o input.cc stderr: -./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o input.o input.cc +./headers.at:185: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c +./headers.at:180: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c stdout: -304. headers.at:184: ok +303. headers.at:183: ok ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -./headers.at:185: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c -309. headers.at:191: testing Sane headers: %locations c++ %glr-parser ... -./headers.at:191: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o input.cc input.y stderr: -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file - +stderr: +stdout: stdout: 305. headers.at:185: ok + +301. headers.at:180: ok +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file + ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -./headers.at:191: $CXX $CPPFLAGS $CXXFLAGS -c -o input.o input.cc 310. headers.at:199: testing Several parsers ... ./headers.at:320: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x1.c x1.y -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 311. actions.at:24: testing Midrule actions ... ./actions.at:59: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -v -o input.c input.y -./headers.at:320: $CC $CFLAGS $CPPFLAGS -c -o x1.o x1.c ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -stderr: -./actions.at:60: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +312. actions.at:72: testing Typed midrule actions ... +./actions.at:109: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -v -o input.c input.y +./headers.at:320: $CC $CFLAGS $CPPFLAGS -c -o x1.o x1.c ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -stdout: -./headers.at:180: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c +./actions.at:60: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -stderr: -stdout: +./actions.at:110: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: stdout: ./headers.at:181: $CC $CFLAGS $CPPFLAGS -c -o $h.o $h.c -./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file -301. headers.at:180: ok stderr: stdout: -./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file - -302. headers.at:181: ok -312. actions.at:72: testing Typed midrule actions ... -./actions.at:109: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -v -o input.c input.y ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file - -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -stderr: -313. actions.at:122: testing Implicitly empty rule ... -stdout: -./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y +302. headers.at:181: ok stderr: -./actions.at:110: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: ./headers.at:320: echo "x1" >>expout -287. synclines.at:440: ok -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./headers.at:321: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x2.c x2.y + +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +./headers.at:321: $CC $CFLAGS $CPPFLAGS -c -o x2.o x2.c +313. actions.at:122: testing Implicitly empty rule ... +./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file +./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file ./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y -Werror stderr: stdout: -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file - -./actions.at:61: $PREPARSER ./input -./headers.at:321: $CC $CFLAGS $CPPFLAGS -c -o x2.o x2.c -stderr: +287. synclines.at:440: ok stderr: 1.y:11.17-18: error: empty rule without %empty [-Werror=empty-rule] 11 | a: /* empty. */ {}; | ^~ | %empty 1.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] -./actions.at:61: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./actions.at:133: sed 's,.*/$,,' stderr 1>&2 +./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file + +stderr: +stdout: +./actions.at:111: $PREPARSER ./input +stderr: +./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y --warnings=error +./actions.at:111: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 314. actions.at:172: testing Invalid uses of %empty ... +312. actions.at:72: ok +stderr: ./actions.at:182: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret one.y +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +stdout: ./actions.at:192: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -u one.y -311. actions.at:24: ok -./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file -./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y --warnings=error ./actions.at:202: sed -e '1,8d' one.y - -./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file -./actions.at:219: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret two.y ./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y -Wnone,none -Werror --trace=none +./actions.at:219: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret two.y +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file +314. actions.at:172: ./headers.at:187: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc + ok + ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 315. actions.at:240: testing Valid uses of %empty ... ./actions.at:259: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -314. actions.at:172: ok -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -stderr: -stdout: - ./actions.at:133: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -Wempty-rule 1.y --warnings=none -Werror --trace=none -./headers.at:187: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc -./actions.at:259: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS + ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +./actions.at:259: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +stderr: +stdout: +stderr: +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 316. actions.at:270: testing Add missing %empty ... ./actions.at:285: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --update -Wall input.y -./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret 2.y -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file +stdout: +./actions.at:61: $PREPARSER ./input +./headers.at:321: echo "x2" >>expout stderr: +./headers.at:322: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x3.c x3.y +stderr: +./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret 2.y input.y:3.4-5: warning: empty rule without %empty [-Wempty-rule] input.y:4.3-5.1: warning: empty rule without %empty [-Wempty-rule] input.y:6.3: warning: empty rule without %empty [-Wempty-rule] @@ -9157,23 +9195,15 @@ input.y:9.3: warning: empty rule without %empty [-Wempty-rule] bison: file 'input.y' was updated (backup: 'input.y~') ./actions.at:286: cat input.y +./actions.at:61: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./conflicts.at:2417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wnone $file ./actions.at:300: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall input.y -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret 2.y -Werror -stderr: -stdout: -./actions.at:111: $PREPARSER ./input -stderr: -./actions.at:111: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -stderr: -stdout: -./headers.at:189: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc -312. actions.at:72: ok +311. actions.at:24: ok +./headers.at:322: $CC $CFLAGS $CPPFLAGS -c -o x3.o x3.c 316. actions.at:270: ok -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +./conflicts.at:2418: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Werror $file stderr: - 2.y:11.17-18: error: empty rule without %empty [-Werror=empty-rule] 11 | a: /* empty. */ {}; | ^~ @@ -9183,151 +9213,172 @@ | ^~ | %empty 2.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./actions.at:149: sed 's,.*/$,,' stderr 1>&2 -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -318. actions.at:366: testing Initial location: yacc.c api.pure=full ... -./actions.at:366: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -317. actions.at:365: testing Initial location: yacc.c ... -./actions.at:365: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret 2.y --warnings=error -./actions.at:365: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret 2.y -Wnone,none -Werror --trace=none -./actions.at:366: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: + stdout: +./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret 2.y -Wnone,none -Werror --trace=none +317. actions.at:365: testing Initial location: yacc.c ... +./actions.at:365: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: -./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret 2.y --warnings=none -Werror --trace=none +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stdout: ./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -./headers.at:321: echo "x2" >>expout -./headers.at:322: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x3.c x3.y -stderr: +./actions.at:365: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./actions.at:149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret 2.y --warnings=none -Werror --trace=none ./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file +318. actions.at:366: testing Initial location: yacc.c api.pure=full ... +./actions.at:366: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +stderr: +./headers.at:191: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc stdout: +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file ./actions.at:260: $PREPARSER ./input -stderr: ./actions.at:161: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -Wno-empty-rule 2.y -./actions.at:260: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +./actions.at:260: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:366: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 315. actions.at:240: ok +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +313. actions.at:122: ok +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file + + stderr: +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file stdout: - +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file +319. actions.at:367: testing Initial location: yacc.c api.pure %parse-param { int x } ... +./actions.at:367: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./headers.at:187: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc +320. actions.at:368: testing Initial location: yacc.c api.push-pull=both ... +./actions.at:368: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./actions.at:367: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: +./actions.at:368: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: -./headers.at:322: $CC $CFLAGS $CPPFLAGS -c -o x3.o x3.c +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +stderr: ./actions.at:365: $PREPARSER ./input +stdout: stderr: +306. headers.at:187: ok 1.1 1.1: syntax error -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./actions.at:365: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -313. actions.at:122: ok -./headers.at:187: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc -stderr: -319. actions.at:367: testing Initial location: yacc.c api.pure %parse-param { int x } ... -./actions.at:367: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: -stdout: + 317. actions.at:365: ok stdout: stderr: -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -./actions.at:366: $PREPARSER ./input stdout: - +./actions.at:366: $PREPARSER ./input +./headers.at:189: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc stderr: -./actions.at:367: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 1.1 1.1: syntax error ./actions.at:366: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -306. headers.at:187: ok -./headers.at:189: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +321. actions.at:369: testing Initial location: yacc.c api.push-pull=both api.pure=full ... +./actions.at:369: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 318. actions.at:366: ok +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file stderr: stdout: - -308. headers.at:189: ok -./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file -320. actions.at:368: testing Initial location: yacc.c api.push-pull=both ... -./actions.at:368: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -321. actions.at:369: testing Initial location: yacc.c api.push-pull=both api.pure=full ... -./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file -./actions.at:368: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 322. actions.at:370: testing Initial location: glr.c ... ./actions.at:370: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./actions.at:369: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y - - -323. actions.at:371: testing Initial location: glr.c api.pure ... -258. conflicts.at:2331: ok +./headers.at:322: echo "x3" >>expout +./headers.at:323: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x4.c x4.y +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +stderr: +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file ./actions.at:369: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./actions.at:371: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./actions.at:370: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +stdout: -324. actions.at:372: testing Initial location: lalr1.cc ... -./actions.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./actions.at:371: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -325. actions.at:373: testing Initial location: glr.cc ... -./actions.at:373: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./actions.at:372: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: +./actions.at:370: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: ./actions.at:367: $PREPARSER ./input +./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc stderr: +323. actions.at:371: testing Initial location: glr.c api.pure ... +./actions.at:371: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./conflicts.at:2444: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wnone $file +./conflicts.at:2445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Werror $file 1.1 1.1: syntax error ./actions.at:367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +258. conflicts.at:2331: ok +stderr: 319. actions.at:367: ok -./actions.at:373: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stdout: +./headers.at:323: $CC $CFLAGS $CPPFLAGS -c -o x4.o x4.c stderr: +./actions.at:371: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: +./actions.at:368: $PREPARSER ./input -./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc +./headers.at:191: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc stderr: +1.1 +1.1: syntax error +./actions.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + +324. actions.at:372: testing Initial location: lalr1.cc ... +./actions.at:372: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +320. actions.at:368: ok +325. actions.at:373: testing Initial location: glr.cc ... +./actions.at:373: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +./actions.at:372: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS + +./actions.at:373: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 326. actions.at:374: testing Initial location: glr2.cc ... ./actions.at:374: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +stderr: +stdout: +stderr: stdout: ./actions.at:369: $PREPARSER ./input +./headers.at:189: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc stderr: 1.1 1.1: syntax error ./actions.at:369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:374: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: 321. actions.at:369: ok -./actions.at:368: $PREPARSER ./input -./actions.at:374: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -1.1 -1.1: syntax error -./actions.at:368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +308. headers.at:189: ok stderr: stdout: +./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc -stderr: -320. actions.at:368: ok -./headers.at:191: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc -stdout: -./headers.at:322: echo "x3" >>expout 327. actions.at:383: testing Initial location: yacc.c api.pure=full ... ./actions.at:383: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./headers.at:323: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x4.c x4.y -./actions.at:383: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +stderr: +stdout: 328. actions.at:394: testing Initial location: yacc.c api.pure=full ... ./actions.at:394: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./headers.at:323: $CC $CFLAGS $CPPFLAGS -c -o x4.o x4.c +./actions.at:383: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./headers.at:191: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc ./actions.at:394: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: -./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc +./actions.at:370: $PREPARSER ./input +stderr: +1.1 +1.1: syntax error +./actions.at:370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +322. actions.at:370: ok + stderr: stdout: ./actions.at:371: $PREPARSER ./input @@ -9335,114 +9386,110 @@ 1.1 1.1: syntax error ./actions.at:371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +329. actions.at:478: testing Location print: yacc.c ... +./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +323. actions.at:371: ok +./actions.at:478: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: + +stderr: +./headers.at:323: echo "x4" >>expout +stdout: +./headers.at:324: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x5.cc x5.y ./actions.at:383: $PREPARSER ./input stderr: : syntax error ./actions.at:383: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -323. actions.at:371: ok +330. actions.at:478: testing Location print: glr.c ... +./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +327. actions.at:383: ok +./headers.at:324: $CXX $CPPFLAGS $CXXFLAGS -c -o x5.o x5.cc +./actions.at:478: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: -./actions.at:370: $PREPARSER ./input +./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc stderr: -1.1 -1.1: syntax error -./actions.at:370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -327. actions.at:383: ok -322. actions.at:370: ok -329. actions.at:478: testing Location print: yacc.c ... -./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -stderr: - stdout: +stderr: ./actions.at:394: $PREPARSER ./input +stdout: +331. actions.at:478: testing Location print: lalr1.cc ... +./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: -./actions.at:478: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 0 0: syntax error ./actions.at:394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -330. actions.at:478: testing Location print: glr.c ... -./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y - +307. headers.at:188: ok stderr: stdout: -./headers.at:191: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc -328. actions.at:394: ok -./actions.at:478: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -331. actions.at:478: testing Location print: lalr1.cc ... -./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +./actions.at:478: $PREPARSER ./input +stderr: +./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:478: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +329. actions.at:478: ok +328. actions.at:394: ok 332. actions.at:478: testing Location print: glr.cc ... ./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y + + stderr: stdout: -./headers.at:188: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc +333. actions.at:478: testing Location print: glr2.cc ... +./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +309. headers.at:191: ok +334. actions.at:488: testing Exotic Dollars ... +./actions.at:532: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -v -o input.c input.y ./actions.at:478: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stderr: -stdout: -stdout: -./actions.at:478: $PREPARSER ./input -307. headers.at:188: ok -stderr: + +./actions.at:478: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +335. actions.at:1047: testing Printers and Destructors ... +./actions.at:1047: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./actions.at:533: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./actions.at:1047: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./actions.at:372: $PREPARSER ./input -./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: 1.1 1.1: syntax error ./actions.at:372: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: 324. actions.at:372: ok -stdout: -329. actions.at:478: ok +stderr: +stdout: ./actions.at:373: $PREPARSER ./input stderr: - - 1.1 1.1: syntax error ./actions.at:373: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -333. actions.at:478: testing Location print: glr2.cc ... -./actions.at:478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 325. actions.at:373: ok -334. actions.at:488: testing Exotic Dollars ... -./actions.at:532: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -v -o input.c input.y -335. actions.at:1047: testing Printers and Destructors ... -./actions.at:1047: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y - -./actions.at:478: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./actions.at:533: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 336. actions.at:1048: testing Printers and Destructors with union ... ./actions.at:1048: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./actions.at:1047: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -stderr: -stdout: -./headers.at:191: $CXX $CPPFLAGS $CXXFLAGS -c -o $h.o $h.cc + ./actions.at:1048: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +337. actions.at:1050: testing Printers and Destructors: %glr-parser ... +./actions.at:1050: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: stdout: -./headers.at:323: echo "x4" >>expout -./headers.at:324: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x5.cc x5.y stderr: stdout: +./actions.at:534: $PREPARSER ./input +stderr: ./actions.at:478: $PREPARSER ./input stderr: -./headers.at:324: $CXX $CPPFLAGS $CXXFLAGS -c -o x5.o x5.cc +./actions.at:1050: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: -./actions.at:534: $PREPARSER ./input +./actions.at:534: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 330. actions.at:478: ok -stderr: +./actions.at:562: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y + stderr: stdout: +./actions.at:562: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1047: $PREPARSER ./input '(x)' stderr: sending: '(' (0@0-9) @@ -9457,8 +9504,8 @@ Freeing nterm input (2@0-29) Successful parse. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./actions.at:534: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - +338. actions.at:1051: testing Printers and Destructors with union: %glr-parser ... +./actions.at:1051: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1047: $PREPARSER ./input '!' stderr: sending: '!' (0@0-9) @@ -9481,8 +9528,7 @@ Freeing nterm input (5@0-29) Successful parse. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./actions.at:562: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -337. actions.at:1050: testing Printers and Destructors: %glr-parser ... +./actions.at:1051: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1047: $PREPARSER ./input '(y)' stderr: sending: '(' (0@0-9) @@ -9498,8 +9544,11 @@ Freeing nterm input (2@0-29) Successful parse. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./actions.at:1050: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +stderr: +stdout: ./actions.at:1047: $PREPARSER ./input '(xxxxx)(x)(x)y' +./actions.at:563: $PREPARSER ./input +stderr: stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) @@ -9537,9 +9586,10 @@ Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./actions.at:562: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./actions.at:563: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1047: $PREPARSER ./input '(x)(x)x' stderr: +334. actions.at:488: ok sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) @@ -9560,30 +9610,13 @@ Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./actions.at:1050: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -stderr: -stdout: ./actions.at:1047: $PREPARSER ./input '(x)(x)(x)(x)(x)(x)(x)' -./actions.at:1048: $PREPARSER ./input '(x)' -stderr: stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) -sending: END (3@30-39) -input (0@29-29): /* Nothing */ -input (2@0-29): line (0@0-29) input (0@29-29) -Freeing token END (3@30-39) -Freeing nterm input (2@0-29) -Successful parse. -./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -sending: '(' (0@0-9) -sending: 'x' (1@10-19) -thing (1@10-19): 'x' (1@10-19) -sending: ')' (2@20-29) -line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) sending: '(' (3@30-39) sending: 'x' (4@40-49) thing (4@40-49): 'x' (4@40-49) @@ -9623,9 +9656,32 @@ Freeing nterm line (0@0-29) Parsing FAILED (status 2). ./actions.at:1047: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./actions.at:1048: $PREPARSER ./input '!' 335. actions.at:1047: ok + + +stderr: +stdout: +./actions.at:1048: $PREPARSER ./input '(x)' +339. actions.at:1053: testing Printers and Destructors: %header lalr1.cc ... +./actions.at:1053: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +stderr: +340. actions.at:1054: testing Printers and Destructors with union: %header lalr1.cc ... +./actions.at:1054: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +sending: '(' (0@0-9) +sending: 'x' (1@10-19) +thing (1@10-19): 'x' (1@10-19) +sending: ')' (2@20-29) +line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) +sending: END (3@30-39) +input (0@29-29): /* Nothing */ +input (2@0-29): line (0@0-29) input (0@29-29) +Freeing token END (3@30-39) +Freeing nterm input (2@0-29) +Successful parse. +./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1048: $PREPARSER ./input '!' stderr: +./actions.at:1053: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty @@ -9634,29 +9690,8 @@ Freeing nterm input (5@0-19) Successful parse. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - -338. actions.at:1051: testing Printers and Destructors with union: %glr-parser ... -./actions.at:1051: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1048: $PREPARSER ./input '!!!' stderr: -stderr: -input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] -input.y: warning: shift/reduce conflict on token J [-Wcounterexamples] -time limit exceeded: 6.000000 - First example: H i . J K $end - Shift derivation - $accept - `-> 0: a $end - `-> 2: H i - `-> 4: i . J K - Second example: H i . J $end - Reduce derivation - $accept - `-> 0: s $end - `-> 1: a J - `-> 2: H i . -input.y:4.4-6: warning: rule useless in parser due to conflicts [-Wother] -./counterexample.at:451: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) @@ -9667,10 +9702,9 @@ Freeing nterm input (5@0-29) Successful parse. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1054: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./actions.at:1048: $PREPARSER ./input '(y)' stderr: -stderr: -./counterexample.at:451: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' @@ -9684,20 +9718,12 @@ Freeing nterm input (2@0-29) Successful parse. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -stderr: -./actions.at:563: $PREPARSER ./input stderr: stdout: -./actions.at:1051: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./actions.at:563: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./actions.at:478: $PREPARSER ./input -stderr: -./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -334. actions.at:488: ok +./headers.at:324: echo "x5" >>expout ./actions.at:1048: $PREPARSER ./input '(xxxxx)(x)(x)y' -331. actions.at:478: ok stderr: +./headers.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x6.c x6.y sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) @@ -9734,10 +9760,7 @@ Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: ./actions.at:1048: $PREPARSER ./input '(x)(x)x' - stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) @@ -9759,11 +9782,12 @@ Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - -309. headers.at:191: ok -339. actions.at:1053: testing Printers and Destructors: %header lalr1.cc ... -./actions.at:1053: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +stderr: +./headers.at:325: $CC $CFLAGS $CPPFLAGS -c -o x6.o x6.c +stdout: ./actions.at:1048: $PREPARSER ./input '(x)(x)(x)(x)(x)(x)(x)' +./actions.at:478: $PREPARSER ./input +stderr: stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) @@ -9809,40 +9833,36 @@ Freeing nterm line (0@0-29) Parsing FAILED (status 2). ./actions.at:1048: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +331. actions.at:478: ok 336. actions.at:1048: ok -340. actions.at:1054: testing Printers and Destructors with union: %header lalr1.cc ... + + +342. actions.at:1057: testing Printers and Destructors with union: %header glr.cc ... +./actions.at:1057: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +341. actions.at:1056: testing Printers and Destructors: %header glr.cc ... +./actions.at:1056: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +./actions.at:1057: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./actions.at:1056: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: -./actions.at:1054: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stdout: - +./headers.at:325: echo "x6" >>expout +stderr: +stdout: +./headers.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x7.c x7.y ./actions.at:478: $PREPARSER ./input stderr: ./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - -./actions.at:1053: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 332. actions.at:478: ok -341. actions.at:1056: testing Printers and Destructors: %header glr.cc ... -./actions.at:1056: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./actions.at:1054: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -342. actions.at:1057: testing Printers and Destructors with union: %header glr.cc ... -./actions.at:1057: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +./headers.at:326: $CC $CFLAGS $CPPFLAGS -c -o x7.o x7.c -./actions.at:1056: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 343. actions.at:1059: testing Printers and Destructors: %header glr2.cc ... ./actions.at:1059: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./actions.at:1057: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./actions.at:1059: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: -./headers.at:324: echo "x5" >>expout -./headers.at:325: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x6.c x6.y -stderr: -stdout: -./actions.at:374: $PREPARSER ./input -stderr: -1.1 -1.1: syntax error -./actions.at:374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./headers.at:326: echo "x7" >>expout +./headers.at:327: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x8.c x8.y stderr: stdout: ./actions.at:1050: $PREPARSER ./input '(x)' @@ -9859,9 +9879,8 @@ Freeing nterm input (2@0-29) Successful parse. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -326. actions.at:374: ok -./headers.at:325: $CC $CFLAGS $CPPFLAGS -c -o x6.o x6.c ./actions.at:1050: $PREPARSER ./input '!' +./headers.at:327: $CC $CFLAGS $CPPFLAGS -c -o x8.o x8.c stderr: sending: '!' (0@0-9) sending: END (1@10-19) @@ -9871,7 +9890,6 @@ Freeing nterm input (5@0-19) Successful parse. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - ./actions.at:1050: $PREPARSER ./input '!!!' stderr: sending: '!' (0@0-9) @@ -9884,8 +9902,6 @@ Freeing nterm input (5@0-29) Successful parse. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -344. actions.at:1060: testing Printers and Destructors with union: %header glr2.cc ... -./actions.at:1060: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./actions.at:1050: $PREPARSER ./input '(y)' stderr: sending: '(' (0@0-9) @@ -9939,12 +9955,7 @@ Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: -./headers.at:325: echo "x6" >>expout -./headers.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x7.c x7.y ./actions.at:1050: $PREPARSER ./input '(x)(x)x' -./actions.at:1060: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) @@ -9966,10 +9977,17 @@ Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1050: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./headers.at:326: $CC $CFLAGS $CPPFLAGS -c -o x7.o x7.c 337. actions.at:1050: ok stderr: stdout: +./headers.at:327: echo "x8" >>expout + +./headers.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x9.cc x9.y +344. actions.at:1060: testing Printers and Destructors with union: %header glr2.cc ... +./actions.at:1060: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +./headers.at:328: $CXX $CPPFLAGS $CXXFLAGS -c -o x9.o x9.cc +stderr: +stdout: ./actions.at:1051: $PREPARSER ./input '(x)' stderr: sending: '(' (0@0-9) @@ -9984,9 +10002,11 @@ Freeing nterm input (2@0-29) Successful parse. ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - +./actions.at:1060: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./actions.at:1051: $PREPARSER ./input '!' stderr: +stderr: +stdout: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty @@ -9994,11 +10014,15 @@ Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. +./actions.at:374: $PREPARSER ./input ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -345. actions.at:1071: testing Default tagless %printer and %destructor ... -./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +stderr: +1.1 +1.1: syntax error +./actions.at:374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1051: $PREPARSER ./input '!!!' stderr: +326. actions.at:374: ok sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) @@ -10024,12 +10048,8 @@ Freeing nterm input (2@0-29) Successful parse. ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: -./headers.at:326: echo "x7" >>expout -./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror + ./actions.at:1051: $PREPARSER ./input '(xxxxx)(x)(x)y' -./headers.at:327: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x8.c x8.y stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) @@ -10067,14 +10087,28 @@ Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./headers.at:327: $CC $CFLAGS $CPPFLAGS -c -o x8.o x8.c -./actions.at:1051: $PREPARSER ./input '(x)(x)x' -stderr: -input.y:30.3-5: error: useless %destructor for type <*> [-Werror=other] -input.y:30.3-5: error: useless %printer for type <*> [-Werror=other] stderr: +345. actions.at:1071: testing Default tagless %printer and %destructor ... +input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] +input.y: warning: shift/reduce conflict on token J [-Wcounterexamples] +time limit exceeded: 6.000000 + First example: H i . J K $end + Shift derivation + $accept + `-> 0: a $end + `-> 2: H i + `-> 4: i . J K + Second example: H i . J $end + Reduce derivation + $accept + `-> 0: s $end + `-> 1: a J + `-> 2: H i . +input.y:4.4-6: warning: rule useless in parser due to conflicts [-Wother] +./actions.at:1051: $PREPARSER ./input '(x)(x)x' +./counterexample.at:451: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr +./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: -stdout: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) @@ -10095,9 +10129,21 @@ Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1051: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./actions.at:1053: $PREPARSER ./input '(x)' +./counterexample.at:451: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y +338. actions.at:1051: ok +./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror + stderr: +input.y:30.3-5: error: useless %destructor for type <*> [-Werror=other] +input.y:30.3-5: error: useless %printer for type <*> [-Werror=other] +346. actions.at:1174: testing Default tagged and per-type %printer and %destructor ... +./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1116: sed 's,.*/$,,' stderr 1>&2 +stderr: +stdout: +./actions.at:1057: $PREPARSER ./input '(x)' +stderr: +./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) @@ -10109,10 +10155,12 @@ Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. -./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error -./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./actions.at:1053: $PREPARSER ./input '!' +./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror +./actions.at:1057: $PREPARSER ./input '!' +stderr: stderr: +stdout: sending: '!' (0@0-9) sending: END (1@10-19) raise (4@9-9): %empty @@ -10120,10 +10168,25 @@ Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. +./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1053: $PREPARSER ./input '(x)' +stderr: +./actions.at:1057: $PREPARSER ./input '!!!' +stderr: +sending: '(' (0@0-9) +sending: 'x' (1@10-19) +thing (1@10-19): 'x' (1@10-19) +sending: ')' (2@20-29) +line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) +sending: END (3@30-39) +input (0@29-29): /* Nothing */ +input (2@0-29): line (0@0-29) input (0@29-29) +Freeing token END (3@30-39) +Freeing nterm input (2@0-29) +Successful parse. ./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -338. actions.at:1051: ok -./actions.at:1053: $PREPARSER ./input '!!!' stderr: +stdout: sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) @@ -10133,14 +10196,38 @@ Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. -./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1056: $PREPARSER ./input '(x)' ./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none stderr: -stdout: -./actions.at:1053: $PREPARSER ./input '(y)' -./actions.at:478: $PREPARSER ./input +./actions.at:1053: $PREPARSER ./input '!' +sending: '(' (0@0-9) +sending: 'x' (1@10-19) +thing (1@10-19): 'x' (1@10-19) +sending: ')' (2@20-29) +line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) +sending: END (3@30-39) +input (0@29-29): /* Nothing */ +input (2@0-29): line (0@0-29) input (0@29-29) +Freeing token END (3@30-39) +Freeing nterm input (2@0-29) +Successful parse. stderr: stderr: +./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +sending: '!' (0@0-9) +sending: END (1@10-19) +raise (4@9-9): %empty +check-spontaneous-errors (5@9-19): error (@9-19) +Freeing token END (1@10-19) +Freeing nterm input (5@0-19) +Successful parse. +./actions.at:1057: $PREPARSER ./input '(y)' +./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input.y:22.3-4: error: useless %destructor for type <> [-Werror=other] +input.y:22.3-4: error: useless %printer for type <> [-Werror=other] +stderr: +./actions.at:1056: $PREPARSER ./input '!' sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' @@ -10153,13 +10240,32 @@ Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. -./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./actions.at:1053: $PREPARSER ./input '(xxxxx)(x)(x)y' +./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1233: sed 's,.*/$,,' stderr 1>&2 +./actions.at:1053: $PREPARSER ./input '!!!' stderr: - -stdout: -./actions.at:1054: $PREPARSER ./input '(x)' +stderr: +sending: '!' (0@0-9) +sending: '!' (1@10-19) +sending: '!' (2@20-29) +raise (5@10-29): ! (1@20-29) ! (2@20-29) +check-spontaneous-errors (5@10-29): error (@10-29) +sending: END (3@30-39) +Freeing token END (3@30-39) +Freeing nterm input (5@0-29) +Successful parse. +sending: '!' (0@0-9) +sending: END (1@10-19) +raise (4@9-9): %empty +check-spontaneous-errors (5@9-19): error (@9-19) +Freeing token END (1@10-19) +Freeing nterm input (5@0-19) +Successful parse. +./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none +./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error +./actions.at:1057: $PREPARSER ./input '(xxxxx)(x)(x)y' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) @@ -10196,23 +10302,37 @@ Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. -./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./actions.at:1116: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none +./actions.at:1056: $PREPARSER ./input '!!!' +./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1053: $PREPARSER ./input '(y)' stderr: +stderr: +sending: '!' (0@0-9) +sending: '!' (1@10-19) +sending: '!' (2@20-29) +raise (5@10-29): ! (1@20-29) ! (2@20-29) +check-spontaneous-errors (5@10-29): error (@10-29) +sending: END (3@30-39) +Freeing token END (3@30-39) +Freeing nterm input (5@0-29) +Successful parse. sending: '(' (0@0-9) -sending: 'x' (1@10-19) -thing (1@10-19): 'x' (1@10-19) +sending: 'y' (1@10-19) +10.10-19.18: syntax error, unexpected 'y', expecting 'x' +Freeing token 'y' (1@10-19) sending: ')' (2@20-29) -line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) +line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) sending: END (3@30-39) input (0@29-29): /* Nothing */ -input (2@0-29): line (0@0-29) input (0@29-29) +input (2@0-29): line (-1@0-29) input (0@29-29) Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. -./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -333. actions.at:478: ok -./actions.at:1053: $PREPARSER ./input '(x)(x)x' +./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1057: $PREPARSER ./input '(x)(x)x' +./actions.at:1056: $PREPARSER ./input '(y)' +stderr: stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) @@ -10233,44 +10353,11 @@ Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. -./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -346. actions.at:1174: testing Default tagged and per-type %printer and %destructor ... -./actions.at:1054: $PREPARSER ./input '!' -339. actions.at:1053: ok -./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -stderr: -stderr: -stdout: -sending: '!' (0@0-9) -sending: END (1@10-19) -raise (4@9-9): %empty -check-spontaneous-errors (5@9-19): error (@9-19) -Freeing token END (1@10-19) -Freeing nterm input (5@0-19) -Successful parse. -./headers.at:327: echo "x8" >>expout +./actions.at:1053: $PREPARSER ./input '(xxxxx)(x)(x)y' +./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1120: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - -./headers.at:328: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o x9.cc x9.y - -./actions.at:1054: $PREPARSER ./input '!!!' -stderr: -stderr: -sending: '!' (0@0-9) -sending: '!' (1@10-19) -sending: '!' (2@20-29) -raise (5@10-29): ! (1@20-29) ! (2@20-29) -check-spontaneous-errors (5@10-29): error (@10-29) -sending: END (3@30-39) -Freeing token END (3@30-39) -Freeing nterm input (5@0-29) -Successful parse. -stdout: -./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./actions.at:1054: $PREPARSER ./input '(y)' -./actions.at:1057: $PREPARSER ./input '(x)' stderr: +./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' @@ -10283,27 +10370,67 @@ Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. -./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -348. actions.at:1429: testing Default %printer and %destructor are not for error or $undefined ... +sending: '(' (0@0-9) +sending: 'x' (1@10-19) +thing (1@10-19): 'x' (1@10-19) +sending: 'x' (2@20-29) +thing (2@20-29): 'x' (2@20-29) +sending: 'x' (3@30-39) +30.30-39.38: syntax error, unexpected 'x', expecting ')' +Freeing nterm thing (2@20-29) +Freeing nterm thing (1@10-19) +Freeing token 'x' (3@30-39) +sending: 'x' (4@40-49) +Freeing token 'x' (4@40-49) +sending: 'x' (5@50-59) +Freeing token 'x' (5@50-59) +sending: ')' (6@60-69) +line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) +sending: '(' (7@70-79) +sending: 'x' (8@80-89) +thing (8@80-89): 'x' (8@80-89) +sending: ')' (9@90-99) +line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) +sending: '(' (10@100-109) +sending: 'x' (11@110-119) +thing (11@110-119): 'x' (11@110-119) +sending: ')' (12@120-129) +line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) +sending: 'y' (13@130-139) +input (0@129-129): /* Nothing */ +input (2@100-129): line (10@100-129) input (0@129-129) +input (2@70-129): line (7@70-99) input (2@100-129) +input (2@0-129): line (-1@0-69) input (2@70-129) +130.130-139.138: syntax error, unexpected 'y', expecting END +Freeing nterm input (2@0-129) +Freeing token 'y' (13@130-139) +Parsing FAILED. +./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +342. actions.at:1057: ok +./actions.at:1053: $PREPARSER ./input '(x)(x)x' +./actions.at:1056: $PREPARSER ./input '(xxxxx)(x)(x)y' +stderr: stderr: -./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) sending: ')' (2@20-29) line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) -sending: END (3@30-39) -input (0@29-29): /* Nothing */ -input (2@0-29): line (0@0-29) input (0@29-29) -Freeing token END (3@30-39) -Freeing nterm input (2@0-29) -Successful parse. -./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -347. actions.at:1307: testing Default %printer and %destructor for user-defined end token ... -./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input0.c input0.y -./actions.at:1054: $PREPARSER ./input '(xxxxx)(x)(x)y' -./headers.at:328: $CXX $CPPFLAGS $CXXFLAGS -c -o x9.o x9.cc -stderr: +sending: '(' (3@30-39) +sending: 'x' (4@40-49) +thing (4@40-49): 'x' (4@40-49) +sending: ')' (5@50-59) +line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) +sending: 'x' (6@60-69) +thing (6@60-69): 'x' (6@60-69) +sending: END (7@70-79) +70.70-79.78: syntax error, unexpected END, expecting 'x' +Freeing nterm thing (6@60-69) +Freeing nterm line (3@30-59) +Freeing nterm line (0@0-29) +Freeing token END (7@70-79) +Parsing FAILED. sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) @@ -10339,24 +10466,12 @@ Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. -./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror -./actions.at:1057: $PREPARSER ./input '!' -./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror -stderr: -./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input0.c input0.y -Werror -sending: '!' (0@0-9) -sending: END (1@10-19) -raise (4@9-9): %empty -check-spontaneous-errors (5@9-19): error (@9-19) -Freeing token END (1@10-19) -Freeing nterm input (5@0-19) -Successful parse. -./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./actions.at:1054: $PREPARSER ./input '(x)(x)x' -stderr: -input.y:22.3-4: error: useless %destructor for type <> [-Werror=other] -input.y:22.3-4: error: useless %printer for type <> [-Werror=other] +./actions.at:1053: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none + +339. actions.at:1053: ok +./actions.at:1056: $PREPARSER ./input '(x)(x)x' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) @@ -10377,12 +10492,64 @@ Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. +./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stdout: + +./actions.at:478: $PREPARSER ./input +341. actions.at:1056: ok +stderr: +347. actions.at:1307: testing Default %printer and %destructor for user-defined end token ... +./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input0.c input0.y +./actions.at:1237: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./actions.at:478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +333. actions.at:478: ok +348. actions.at:1429: testing Default %printer and %destructor are not for error or $undefined ... +./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y + +./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input0.c input0.y -Werror +stderr: +stdout: +./actions.at:1054: $PREPARSER ./input '(x)' + +stderr: +349. actions.at:1532: testing Default %printer and %destructor are not for $accept ... +sending: '(' (0@0-9) +sending: 'x' (1@10-19) +thing (1@10-19): 'x' (1@10-19) +sending: ')' (2@20-29) +line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) +sending: END (3@30-39) +input (0@29-29): /* Nothing */ +input (2@0-29): line (0@0-29) input (0@29-29) +Freeing token END (3@30-39) +Freeing nterm input (2@0-29) +Successful parse. +./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input0.y:30.3-5: error: useless %destructor for type <*> [-Werror=other] input0.y:30.3-5: error: useless %printer for type <*> [-Werror=other] -./actions.at:1057: $PREPARSER ./input '!!!' -./actions.at:1233: sed 's,.*/$,,' stderr 1>&2 +./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror +./actions.at:1054: $PREPARSER ./input '!' +350. actions.at:1596: testing Default %printer and %destructor for midrule values ... +./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +stderr: +./actions.at:1416: sed 's,.*/$,,' stderr 1>&2 +sending: '!' (0@0-9) +sending: END (1@10-19) +raise (4@9-9): %empty +check-spontaneous-errors (5@9-19): error (@9-19) +Freeing token END (1@10-19) +Freeing nterm input (5@0-19) +Successful parse. +./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror +stderr: +input.y:23.6-8: error: useless %destructor for type <*> [-Werror=other] +input.y:23.6-8: error: useless %printer for type <*> [-Werror=other] +./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input0.c input0.y --warnings=error +./actions.at:1054: $PREPARSER ./input '!!!' stderr: sending: '!' (0@0-9) sending: '!' (1@10-19) @@ -10393,18 +10560,14 @@ Freeing token END (3@30-39) Freeing nterm input (5@0-29) Successful parse. -./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./actions.at:1416: sed 's,.*/$,,' stderr 1>&2 -340. actions.at:1054: ok -./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input0.c input0.y --warnings=error +./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1474: sed 's,.*/$,,' stderr 1>&2 stderr: -./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error -input.y:23.6-8: error: useless %destructor for type <*> [-Werror=other] -input.y:23.6-8: error: useless %printer for type <*> [-Werror=other] -./actions.at:1057: $PREPARSER ./input '(y)' +./actions.at:1054: $PREPARSER ./input '(y)' +input.y:24.3-4: error: useless %destructor for type <> [-Werror=other] +input.y:24.3-4: error: useless %printer for type <> [-Werror=other] +./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror stderr: - -./actions.at:1474: sed 's,.*/$,,' stderr 1>&2 sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' @@ -10417,13 +10580,11 @@ Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. -./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none +./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error +./actions.at:1582: sed 's,.*/$,,' stderr 1>&2 ./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input0.c input0.y -Wnone,none -Werror --trace=none -./actions.at:1057: $PREPARSER ./input '(xxxxx)(x)(x)y' -349. actions.at:1532: testing Default %printer and %destructor are not for $accept ... -./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./actions.at:1054: $PREPARSER ./input '(xxxxx)(x)(x)y' stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) @@ -10460,13 +10621,16 @@ Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. -./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error +stderr: +./actions.at:1054: $PREPARSER ./input '(x)(x)x' ./actions.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input0.c input0.y --warnings=none -Werror --trace=none -./actions.at:1233: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none -./actions.at:1416: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input0 input0.c $LIBS -./actions.at:1057: $PREPARSER ./input '(x)(x)x' -./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror ./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none +input.y:24.57-59: error: useless %destructor for type <*> [-Werror=other] +input.y:24.57-59: error: useless %printer for type <*> [-Werror=other] +input.y:33.3-23: error: unset value: $$ [-Werror=other] +input.y:32.3-23: error: unused value: $3 [-Werror=other] stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) @@ -10487,18 +10651,21 @@ Freeing nterm line (0@0-29) Freeing token END (7@70-79) Parsing FAILED. -./actions.at:1237: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./actions.at:1057: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1054: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1634: sed 's,.*/$,,' stderr 1>&2 +340. actions.at:1054: ok stderr: -input.y:24.3-4: error: useless %destructor for type <> [-Werror=other] -input.y:24.3-4: error: useless %printer for type <> [-Werror=other] +stdout: +./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none +./headers.at:328: echo "x9" >>expout +./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none +./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error +./actions.at:1416: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input0 input0.c $LIBS stderr: -342. actions.at:1057: ok stdout: -./actions.at:1582: sed 's,.*/$,,' stderr 1>&2 +./headers.at:329: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o xa.cc xa.y ./actions.at:1121: $PREPARSER ./input --debug -./actions.at:1474: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none -./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error + stderr: Starting parse Entering state 0 @@ -10536,105 +10703,19 @@ Stack now 0 Cleanup: discarding lookahead token "end of file" (1.5: ) Stack now 0 +./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none ./actions.at:1121: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - -345. actions.at:1071: ok ./actions.at:1478: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -stderr: -./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none -stdout: -./actions.at:1056: $PREPARSER ./input '(x)' -stderr: -350. actions.at:1596: testing Default %printer and %destructor for midrule values ... -./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -sending: '(' (0@0-9) -sending: 'x' (1@10-19) -thing (1@10-19): 'x' (1@10-19) -sending: ')' (2@20-29) -line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) -sending: END (3@30-39) -input (0@29-29): /* Nothing */ -input (2@0-29): line (0@0-29) input (0@29-29) -Freeing token END (3@30-39) -Freeing nterm input (2@0-29) -Successful parse. - -./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none 351. actions.at:1743: testing @$ in %initial-action implies %locations ... ./actions.at:1743: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./actions.at:1582: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none -./actions.at:1056: $PREPARSER ./input '!' -stderr: -sending: '!' (0@0-9) -sending: END (1@10-19) -raise (4@9-9): %empty -check-spontaneous-errors (5@9-19): error (@9-19) -Freeing token END (1@10-19) -Freeing nterm input (5@0-19) -Successful parse. -./actions.at:1743: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Werror -./actions.at:1586: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -stderr: -stdout: -./actions.at:1416: $PREPARSER ./input0 --debug -./actions.at:1056: $PREPARSER ./input '!!!' -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reducing stack by rule 1 (line 49): --> $$ = nterm start (1.1: <> for 'S' @ 1) -Entering state 1 -Stack now 0 1 -Reading a token -Now at end of input. -Shifting token END (1.1: <> for 'E' @ 1) -Entering state 2 -Stack now 0 1 2 -Stack now 0 1 2 -Cleanup: popping token END (1.1: <> for 'E' @ 1) -Cleanup: popping nterm start (1.1: <> for 'S' @ 1) -./actions.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -sending: '!' (0@0-9) -sending: '!' (1@10-19) -sending: '!' (2@20-29) -raise (5@10-29): ! (1@20-29) ! (2@20-29) -check-spontaneous-errors (5@10-29): error (@10-29) -sending: END (3@30-39) -Freeing token END (3@30-39) -Freeing nterm input (5@0-29) -Successful parse. -./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input.y:24.57-59: error: useless %destructor for type <*> [-Werror=other] -input.y:24.57-59: error: useless %printer for type <*> [-Werror=other] -input.y:33.3-23: error: unset value: $$ [-Werror=other] -input.y:32.3-23: error: unused value: $3 [-Werror=other] -./actions.at:1056: $PREPARSER ./input '(y)' -./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input1.c input1.y -stderr: +345. actions.at:1071: ok stderr: -sending: '(' (0@0-9) -sending: 'y' (1@10-19) -10.10-19.18: syntax error, unexpected 'y', expecting 'x' -Freeing token 'y' (1@10-19) -sending: ')' (2@20-29) -line (-1@0-29): '(' (0@0-9) error (@10-19) ')' (2@20-29) -sending: END (3@30-39) -input (0@29-29): /* Nothing */ -input (2@0-29): line (-1@0-29) input (0@29-29) -Freeing token END (3@30-39) -Freeing nterm input (2@0-29) -Successful parse. -./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./headers.at:329: $CXX $CPPFLAGS $CXXFLAGS -c -o xa.o xa.cc stdout: -./actions.at:1634: sed 's,.*/$,,' stderr 1>&2 ./actions.at:1238: $PREPARSER ./input --debug +./actions.at:1586: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: -./actions.at:1056: $PREPARSER ./input '(xxxxx)(x)(x)y' Starting parse Entering state 0 Stack now 0 @@ -10685,73 +10766,40 @@ Stack now 0 Cleanup: discarding lookahead token "end of file" () Stack now 0 -stderr: -sending: '(' (0@0-9) -sending: 'x' (1@10-19) -thing (1@10-19): 'x' (1@10-19) -sending: 'x' (2@20-29) -thing (2@20-29): 'x' (2@20-29) -sending: 'x' (3@30-39) -30.30-39.38: syntax error, unexpected 'x', expecting ')' -Freeing nterm thing (2@20-29) -Freeing nterm thing (1@10-19) -Freeing token 'x' (3@30-39) -sending: 'x' (4@40-49) -Freeing token 'x' (4@40-49) -sending: 'x' (5@50-59) -Freeing token 'x' (5@50-59) -sending: ')' (6@60-69) -line (-1@0-69): '(' (0@0-9) error (@10-59) ')' (6@60-69) -sending: '(' (7@70-79) -sending: 'x' (8@80-89) -thing (8@80-89): 'x' (8@80-89) -sending: ')' (9@90-99) -line (7@70-99): '(' (7@70-79) thing (8@80-89) ')' (9@90-99) -sending: '(' (10@100-109) -sending: 'x' (11@110-119) -thing (11@110-119): 'x' (11@110-119) -sending: ')' (12@120-129) -line (10@100-129): '(' (10@100-109) thing (11@110-119) ')' (12@120-129) -sending: 'y' (13@130-139) -input (0@129-129): /* Nothing */ -input (2@100-129): line (10@100-129) input (0@129-129) -input (2@70-129): line (7@70-99) input (2@100-129) -input (2@0-129): line (-1@0-69) input (2@70-129) -130.130-139.138: syntax error, unexpected 'y', expecting END -Freeing nterm input (2@0-129) -Freeing token 'y' (13@130-139) -Parsing FAILED. -./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./actions.at:1056: $PREPARSER ./input '(x)(x)x' -./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=error -stderr: -sending: '(' (0@0-9) -sending: 'x' (1@10-19) -thing (1@10-19): 'x' (1@10-19) -sending: ')' (2@20-29) -line (0@0-29): '(' (0@0-9) thing (1@10-19) ')' (2@20-29) -sending: '(' (3@30-39) -sending: 'x' (4@40-49) -thing (4@40-49): 'x' (4@40-49) -sending: ')' (5@50-59) -line (3@30-59): '(' (3@30-39) thing (4@40-49) ')' (5@50-59) -sending: 'x' (6@60-69) -thing (6@60-69): 'x' (6@60-69) -sending: END (7@70-79) -70.70-79.78: syntax error, unexpected END, expecting 'x' -Freeing nterm thing (6@60-69) -Freeing nterm line (3@30-59) -Freeing nterm line (0@0-29) -Freeing token END (7@70-79) -Parsing FAILED. -./actions.at:1056: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1238: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y -Wnone,none -Werror --trace=none +./actions.at:1743: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none + +346. actions.at:1174: ok +352. actions.at:1744: testing @$ in %destructor implies %locations ... +./actions.at:1744: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o input.c input.y + +./actions.at:1744: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +353. actions.at:1745: testing @$ in %printer implies %locations ... +./actions.at:1745: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Werror +stderr: +./actions.at:1745: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +input.y:24.57-59: error: useless %destructor for type <*> [-Werror=other] + 24 | %printer { #error "<*> printer should not be used" } <*> + | ^~~ +input.y:24.57-59: error: useless %printer for type <*> [-Werror=other] + 24 | %printer { #error "<*> printer should not be used" } <*> + | ^~~ +input.y:33.3-23: error: unset value: $$ [-Werror=other] + 33 | { @$ = 4; } // Only used. + | ^~~~~~~~~~~~~~~~~~~~~ +input.y:32.3-23: error: unused value: $3 [-Werror=other] + 32 | { USE ($$); @$ = 3; } // Only set. + | ^~~~~~~~~~~~~~~~~~~~~ +./actions.at:1641: sed 's,.*/$,,' stderr 1>&2 stderr: stdout: ./actions.at:1479: $PREPARSER ./input --debug +./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=error +stderr: stderr: -341. actions.at:1056: ok Starting parse Entering state 0 Stack now 0 @@ -10795,75 +10843,75 @@ Cleanup: popping token 'a' ('a') DESTROY 'a' ./actions.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -346. actions.at:1174: ok -./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input1.c input1.y -Werror -./actions.at:1634: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input.c input.y --warnings=none -Werror --trace=none +stdout: +349. actions.at:1532: ok +stderr: 348. actions.at:1429: ok +stdout: +./actions.at:1416: $PREPARSER ./input0 --debug stderr: -input1.y:30.3-4: error: useless %destructor for type <> [-Werror=other] -input1.y:30.3-4: error: useless %printer for type <> [-Werror=other] - -./actions.at:1417: sed 's,.*/$,,' stderr 1>&2 +Starting parse +Entering state 0 +Stack now 0 +Reducing stack by rule 1 (line 49): +-> $$ = nterm start (1.1: <> for 'S' @ 1) +Entering state 1 +Stack now 0 1 +Reading a token +Now at end of input. +Shifting token END (1.1: <> for 'E' @ 1) +Entering state 2 +Stack now 0 1 2 +Stack now 0 1 2 +Cleanup: popping token END (1.1: <> for 'E' @ 1) +Cleanup: popping nterm start (1.1: <> for 'S' @ 1) +./actions.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Wnone,none -Werror --trace=none -./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o input.c input.y +./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input1.c input1.y +354. actions.at:1856: testing Qualified $$ in actions: yacc.c ... +./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=none -Werror --trace=none +355. actions.at:1856: testing Qualified $$ in actions: glr.c ... +./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: +stdout: +352. actions.at:1744: ok stderr: stdout: 351. actions.at:1743: ok -stdout: -352. actions.at:1744: testing @$ in %destructor implies %locations ... -./actions.at:1744: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input1.c input1.y --warnings=error -349. actions.at:1532: ok -353. actions.at:1745: testing @$ in %printer implies %locations ... -./actions.at:1745: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./actions.at:1744: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -354. actions.at:1856: testing Qualified $$ in actions: yacc.c ... -./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input1.c input1.y -Werror +./actions.at:1856: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./actions.at:1856: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./actions.at:1656: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Werror -./actions.at:1745: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./actions.at:1856: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input1.c input1.y -Wnone,none -Werror --trace=none -355. actions.at:1856: testing Qualified $$ in actions: glr.c ... +stderr: +input1.y:30.3-4: error: useless %destructor for type <> [-Werror=other] +input1.y:30.3-4: error: useless %printer for type <> [-Werror=other] 356. actions.at:1856: testing Qualified $$ in actions: lalr1.cc ... -./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -stderr: -input.y:24.57-59: error: useless %destructor for type <*> [-Werror=other] - 24 | %printer { #error "<*> printer should not be used" } <*> - | ^~~ -input.y:24.57-59: error: useless %printer for type <*> [-Werror=other] - 24 | %printer { #error "<*> printer should not be used" } <*> - | ^~~ -input.y:33.3-23: error: unset value: $$ [-Werror=other] - 33 | { @$ = 4; } // Only used. - | ^~~~~~~~~~~~~~~~~~~~~ -input.y:32.3-23: error: unused value: $3 [-Werror=other] - 32 | { USE ($$); @$ = 3; } // Only set. - | ^~~~~~~~~~~~~~~~~~~~~ -./actions.at:1641: sed 's,.*/$,,' stderr 1>&2 -./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input1.c input1.y --warnings=none -Werror --trace=none -./actions.at:1856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=error -./actions.at:1856: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -stderr: -stdout: -./headers.at:328: echo "x9" >>expout -./actions.at:1417: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input1 input1.c $LIBS -./headers.at:329: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o xa.cc xa.y -./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Wnone,none -Werror --trace=none +357. actions.at:1856: testing Qualified $$ in actions: glr.cc ... +./actions.at:1417: sed 's,.*/$,,' stderr 1>&2 +./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: -./headers.at:329: $CXX $CPPFLAGS $CXXFLAGS -c -o xa.o xa.cc +./actions.at:1856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input1.c input1.y --warnings=error +353. actions.at:1745: ok +./actions.at:1856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS + +./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input1.c input1.y -Wnone,none -Werror --trace=none +358. actions.at:1856: testing Qualified $$ in actions: glr2.cc ... +./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +./actions.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o input1.c input1.y --warnings=none -Werror --trace=none +./actions.at:1856: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: -352. actions.at:1744: ok ./actions.at:1856: $PREPARSER ./input --debug +./actions.at:1417: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input1 input1.c $LIBS stderr: -./actions.at:1641: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=none -Werror --trace=none Starting parse Entering state 0 Stack now 0 @@ -10893,7 +10941,9 @@ Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +stdout: stderr: +./actions.at:1657: $PREPARSER ./input --debug Starting parse Entering state 0 Stack now 0 @@ -10922,58 +10972,6 @@ Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed -ne '/ival:/p' stderr -stdout: - -353. actions.at:1745: ok -354. actions.at:1856: ok -357. actions.at:1856: testing Qualified $$ in actions: glr.cc ... -./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y - - -./actions.at:1656: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./actions.at:1856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -358. actions.at:1856: testing Qualified $$ in actions: glr2.cc ... -./actions.at:1856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -359. actions.at:1863: testing Destroying lookahead assigned by semantic action ... -./actions.at:1905: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./actions.at:1856: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./actions.at:1906: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -stderr: -stdout: -./actions.at:1417: $PREPARSER ./input1 --debug -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reducing stack by rule 1 (line 49): --> $$ = nterm start (1.1: <*> for 'S' @ 1) -Entering state 1 -Stack now 0 1 -Reading a token -Now at end of input. -Shifting token END (1.1: <*> for 'E' @ 1) -Entering state 2 -Stack now 0 1 2 -Stack now 0 1 2 -Cleanup: popping token END (1.1: <*> for 'E' @ 1) -Cleanup: popping nterm start (1.1: <*> for 'S' @ 1) -./actions.at:1417: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -347. actions.at:1307: ok -stderr: -stdout: -./actions.at:1907: $PREPARSER ./input - -stderr: -'b' destructor -'a' destructor -./actions.at:1907: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -359. actions.at:1863: ok -360. actions.at:1918: testing YYBACKUP ... -./actions.at:1953: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -stderr: -stdout: - -./actions.at:1657: $PREPARSER ./input --debug stderr: Starting parse Entering state 0 @@ -11010,26 +11008,67 @@ Stack now 0 Cleanup: discarding lookahead token "end of file" (: ) Stack now 0 -./actions.at:1954: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./actions.at:1657: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +354. actions.at:1856: ok 350. actions.at:1596: ok + + +359. actions.at:1863: testing Destroying lookahead assigned by semantic action ... +./actions.at:1905: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +360. actions.at:1918: testing YYBACKUP ... +./actions.at:1953: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./actions.at:1906: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./actions.at:1954: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +stderr: +stdout: +./actions.at:1417: $PREPARSER ./input1 --debug +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reducing stack by rule 1 (line 49): +-> $$ = nterm start (1.1: <*> for 'S' @ 1) +Entering state 1 +Stack now 0 1 +Reading a token +Now at end of input. +Shifting token END (1.1: <*> for 'E' @ 1) +Entering state 2 +Stack now 0 1 2 +Stack now 0 1 2 +Cleanup: popping token END (1.1: <*> for 'E' @ 1) +Cleanup: popping nterm start (1.1: <*> for 'S' @ 1) +./actions.at:1417: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stdout: +347. actions.at:1307: ./actions.at:1907: $PREPARSER ./input + ok +stderr: +'b' destructor +'a' destructor +./actions.at:1907: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +359. actions.at:1863: ok + 361. types.at:25: testing %union vs. api.value.type ... ./types.at:34: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y -361. types.at:25: ok 362. types.at:44: testing %yacc vs. api.value.type=union ... ./types.at:53: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y +361. types.at:25: ok -363. types.at:139: testing yacc.c api.value.type={double} ... 362. types.at:44: ok -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y - -./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS +stderr: +stderr: stderr: stdout: +./headers.at:329: echo "xa" >>expout +./headers.at:330: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o xb.cc xb.y +stdout: +stdout: ./actions.at:1856: $PREPARSER ./input --debug -364. types.at:139: testing yacc.c api.value.type={double} %header ... -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y +363. types.at:139: testing yacc.c api.value.type={double} ... +./actions.at:1955: $PREPARSER ./input +stderr: stderr: Starting parse Entering state 0 @@ -11053,7 +11092,10 @@ Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y + stderr: +./actions.at:1955: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -11076,36 +11118,33 @@ Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed -ne '/ival:/p' stderr -./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS +360. actions.at:1918: ok 355. actions.at:1856: ok +364. types.at:139: testing yacc.c api.value.type={double} %header ... +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y +./headers.at:330: $CXX $CPPFLAGS $CXXFLAGS -c -o xb.o xb.cc +./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS + +./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS +366. types.at:139: testing yacc.c api.value.type={variant} %header ... +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y 365. types.at:139: testing yacc.c api.value.type={variant} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS +./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: stdout: -stderr: -stdout: -./actions.at:1955: $PREPARSER ./input -stderr: ./types.at:139: $PREPARSER ./test stderr: -./actions.at:1955: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: -./headers.at:329: echo "xa" >>expout -360. actions.at:1918: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - ok -./headers.at:330: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o xb.cc xb.y -363. types.at:139: ok - +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./actions.at:1856: $PREPARSER ./input --debug -366. types.at:139: testing yacc.c api.value.type={variant} %header ... -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: - +364. types.at:139: ok +stderr: +stdout: Starting parse Entering state 0 Stack now 0 @@ -11134,8 +11173,9 @@ Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $PREPARSER ./test +stderr: stderr: -./headers.at:330: $CXX $CPPFLAGS $CXXFLAGS -c -o xb.o xb.cc Starting parse Entering state 0 Stack now 0 @@ -11164,21 +11204,41 @@ Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed -ne '/ival:/p' stderr -367. types.at:139: testing yacc.c api.value.type={struct foo} ... -stderr: -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + 356. actions.at:1856: ok +363. types.at:139: ok +stderr: stdout: -./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $PREPARSER ./test stderr: -stderr: +367. types.at:139: testing yacc.c api.value.type={struct foo} ... + +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +366. types.at:139: ok + +368. types.at:139: testing yacc.c api.value.type={struct foo} %header ... +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y +./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS + +369. types.at:139: testing yacc.c api.value.type={struct bar} ... +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y +./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS +370. types.at:139: testing yacc.c api.value.type={struct bar} %header ... +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y +./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS +./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS +stderr: +stdout: +stderr: +./types.at:139: $PREPARSER ./test stdout: +stderr: ./actions.at:1059: $PREPARSER ./input '(x)' -./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: -364. types.at:139: ok +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) @@ -11191,7 +11251,33 @@ Freeing nterm input (2@0-29) Successful parse. ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +365. types.at:139: ok +./actions.at:1856: $PREPARSER ./input --debug +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token UNTYPED (ival: 10, fval: 0.1) +Shifting token UNTYPED (ival: 10, fval: 0.1) +Entering state 1 +Reading a token +Next token is token INT (ival: 20, fval: 0.2) +Shifting token INT (ival: 20, fval: 0.2) +Entering state 3 +Reducing stack 0 by rule 1 (line 55): + $1 = token UNTYPED (ival: 10, fval: 0.1) + $2 = token INT (ival: 20, fval: 0.2) +-> $$ = nterm float (ival: 30, fval: 0.3) +Entering state 2 +Reading a token +Now at end of input. +Shifting token "end of file" () +Entering state 4 +Cleanup: popping token "end of file" () +Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1059: $PREPARSER ./input '!' +./actions.at:1856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: sending: '!' (0@0-9) sending: END (1@10-19) @@ -11201,9 +11287,33 @@ Freeing nterm input (5@0-19) Successful parse. ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token UNTYPED (ival: 10, fval: 0.1) +Shifting token UNTYPED (ival: 10, fval: 0.1) +Entering state 1 +Reading a token +Next token is token INT (ival: 20, fval: 0.2) +Shifting token INT (ival: 20, fval: 0.2) +Entering state 3 +Reducing stack 0 by rule 1 (line 55): + $1 = token UNTYPED (ival: 10, fval: 0.1) + $2 = token INT (ival: 20, fval: 0.2) +-> $$ = nterm float (ival: 30, fval: 0.3) +Entering state 2 +Reading a token +Now at end of input. +Shifting token "end of file" () +Entering state 4 +Cleanup: popping token "end of file" () +Cleanup: popping nterm float (ival: 30, fval: 0.3) +./actions.at:1856: sed -ne '/ival:/p' stderr ./actions.at:1059: $PREPARSER ./input '!!!' stderr: +357. actions.at:1856: ok sending: '!' (0@0-9) sending: '!' (1@10-19) sending: '!' (2@20-29) @@ -11214,11 +11324,13 @@ Freeing nterm input (5@0-29) Successful parse. ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - -368. types.at:139: testing yacc.c api.value.type={struct foo} %header ... +stderr: +371. types.at:139: testing yacc.c api.value.type={union foo} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y +stdout: ./actions.at:1059: $PREPARSER ./input '(y)' stderr: +./types.at:139: $PREPARSER ./test sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' @@ -11232,12 +11344,13 @@ Freeing nterm input (2@0-29) Successful parse. ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + stderr: -stdout: -./actions.at:1059: $PREPARSER ./input '(xxxxx)(x)(x)y' +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS +./actions.at:1059: $PREPARSER ./input '(xxxxx)(x)(x)y' +stderr: stderr: -369. types.at:139: testing yacc.c api.value.type={struct bar} ... sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) @@ -11273,13 +11386,16 @@ Freeing nterm input (2@0-129) Freeing token 'y' (13@130-139) Parsing FAILED. +367. types.at:139: ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + ok +stdout: +372. types.at:139: testing yacc.c api.value.type={union foo} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y -./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: ./actions.at:1059: $PREPARSER ./input '(x)(x)x' -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) @@ -11300,150 +11416,57 @@ Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1059: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -343. actions.at:1059: ok -./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS -365. types.at:139: ok - - -stderr: -stdout: -./types.at:139: $PREPARSER ./test -stderr: -371. types.at:139: testing yacc.c api.value.type={union foo} ... -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y -370. types.at:139: testing yacc.c api.value.type={struct bar} %header ... -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y -stderr: -367. types.at:139: ok -stdout: -./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS -./types.at:139: $PREPARSER ./test -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +368. types.at:139: ok ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS -366. types.at:139: ok -372. types.at:139: testing yacc.c api.value.type={union foo} %header ... -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y - stderr: +343. actions.at:1059: ok stdout: -./actions.at:1856: $PREPARSER ./input --debug -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token UNTYPED (ival: 10, fval: 0.1) -Shifting token UNTYPED (ival: 10, fval: 0.1) -Entering state 1 -Reading a token -Next token is token INT (ival: 20, fval: 0.2) -Shifting token INT (ival: 20, fval: 0.2) -Entering state 3 -Reducing stack 0 by rule 1 (line 55): - $1 = token UNTYPED (ival: 10, fval: 0.1) - $2 = token INT (ival: 20, fval: 0.2) --> $$ = nterm float (ival: 30, fval: 0.3) -Entering state 2 -Reading a token -Now at end of input. -Shifting token "end of file" () -Entering state 4 -Cleanup: popping token "end of file" () -Cleanup: popping nterm float (ival: 30, fval: 0.3) -./actions.at:1856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token UNTYPED (ival: 10, fval: 0.1) -Shifting token UNTYPED (ival: 10, fval: 0.1) -Entering state 1 -Reading a token -Next token is token INT (ival: 20, fval: 0.2) -Shifting token INT (ival: 20, fval: 0.2) -Entering state 3 -Reducing stack 0 by rule 1 (line 55): - $1 = token UNTYPED (ival: 10, fval: 0.1) - $2 = token INT (ival: 20, fval: 0.2) --> $$ = nterm float (ival: 30, fval: 0.3) -Entering state 2 -Reading a token -Now at end of input. -Shifting token "end of file" () -Entering state 4 -Cleanup: popping token "end of file" () -Cleanup: popping nterm float (ival: 30, fval: 0.3) -./actions.at:1856: sed -ne '/ival:/p' stderr -./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: -357. actions.at:1856: ok +./types.at:139: $PREPARSER ./test stdout: - ./types.at:139: $PREPARSER ./test -stderr: 373. types.at:139: testing yacc.c %union { float fval; int ival; }; ... +stderr: +stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y + ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + +369. types.at:139: ok +370. types.at:139: ok 374. types.at:139: testing yacc.c %union { float fval; int ival; }; %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS -stderr: -stdout: -368. types.at:139: ok -./types.at:139: $PREPARSER ./test -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -369. types.at:139: ok +375. types.at:139: testing yacc.c %union foo { float fval; int ival; }; ... -./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS -stderr: -stdout: -./types.at:139: $PREPARSER ./test -stderr: -375. types.at:139: testing yacc.c %union foo { float fval; int ival; }; ... -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y -stderr: +377. types.at:139: testing yacc.c api.value.union.name=foo; %union { float fval; int ival; }; ... 376. types.at:139: testing yacc.c %union foo { float fval; int ival; }; %header ... +./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y -stdout: -371. types.at:139: ok -./types.at:139: $PREPARSER ./test -stderr: ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -370. types.at:139: ok - -377. types.at:139: testing yacc.c api.value.union.name=foo; %union { float fval; int ival; }; ... -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y +./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: - stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -372. types.at:139: ok -./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: -378. types.at:139: testing yacc.c api.value.union.name=foo; %union { float fval; int ival; }; %header ... stdout: -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $PREPARSER ./test stderr: -stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +371. types.at:139: ok +372. types.at:139: ok stderr: stdout: -stdout: - -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./actions.at:1060: $PREPARSER ./input '(x)' -./types.at:139: $PREPARSER ./test stderr: -373. types.at:139: ok sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) @@ -11456,11 +11479,9 @@ Freeing nterm input (2@0-29) Successful parse. ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./actions.at:1060: $PREPARSER ./input '!' -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS + +./actions.at:1060: $PREPARSER ./input '!' stderr: sending: '!' (0@0-9) sending: END (1@10-19) @@ -11469,10 +11490,15 @@ Freeing token END (1@10-19) Freeing nterm input (5@0-19) Successful parse. -374. types.at:139: ok ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -379. types.at:139: testing yacc.c api.value.type=union ... +stderr: +378. types.at:139: testing yacc.c api.value.union.name=foo; %union { float fval; int ival; }; %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y +stdout: +./types.at:139: $PREPARSER ./test +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +376. types.at:139: ok ./actions.at:1060: $PREPARSER ./input '!!!' stderr: sending: '!' (0@0-9) @@ -11485,9 +11511,12 @@ Freeing nterm input (5@0-29) Successful parse. ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: ./actions.at:1060: $PREPARSER ./input '(y)' stderr: +379. types.at:139: testing yacc.c api.value.type=union ... +stderr: +stdout: +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y sending: '(' (0@0-9) sending: 'y' (1@10-19) 10.10-19.18: syntax error, unexpected 'y', expecting 'x' @@ -11500,12 +11529,13 @@ Freeing token END (3@30-39) Freeing nterm input (2@0-29) Successful parse. +stderr: ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - stdout: ./types.at:139: $PREPARSER ./test ./actions.at:1060: $PREPARSER ./input '(xxxxx)(x)(x)y' stderr: +stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) thing (1@10-19): 'x' (1@10-19) @@ -11542,12 +11572,9 @@ Freeing token 'y' (13@130-139) Parsing FAILED. ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS +./types.at:139: $PREPARSER ./test ./actions.at:1060: $PREPARSER ./input '(x)(x)x' -stderr: -380. types.at:139: testing yacc.c api.value.type=union %header ... -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y -stderr: + stderr: sending: '(' (0@0-9) sending: 'x' (1@10-19) @@ -11569,75 +11596,70 @@ Freeing token END (7@70-79) Parsing FAILED. ./actions.at:1060: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -381. types.at:139: testing glr.c api.value.type={double} ... -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y -stdout: -375. types.at:139: ok -./types.at:139: $PREPARSER ./test stderr: +./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 344. actions.at:1060: ok - stderr: +373. types.at:139: ok stdout: -./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS +375. types.at:139: ok ./headers.at:330: echo "xb" >>expout -./headers.at:331: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o xc.cc xc.y -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +380. types.at:139: testing yacc.c api.value.type=union %header ... ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS -376. types.at:139: ok - -382. types.at:139: testing glr.c api.value.type={double} %header ... -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y -./headers.at:331: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS -c -o xc.o xc.cc -383. types.at:139: testing glr.c api.value.type={variant} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y +./headers.at:331: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o xc.cc xc.y -./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS -384. types.at:139: testing glr.c api.value.type={variant} %header ... -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y + + +stderr: stderr: stdout: +stdout: +381. types.at:139: testing glr.c api.value.type={double} ... ./types.at:139: $PREPARSER ./test +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: -stderr: -stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS -./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +382. types.at:139: testing glr.c api.value.type={double} %header ... +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y +383. types.at:139: testing glr.c api.value.type={variant} ... +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 377. types.at:139: ok +./headers.at:331: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS -c -o xc.o xc.cc +374. types.at:139: ok +./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS +./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: -./types.at:139: $PREPARSER ./test -stderr: -378. types.at:139: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - ok +./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS +384. types.at:139: testing glr.c api.value.type={variant} %header ... +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y 385. types.at:139: testing glr.c api.value.type={struct foo} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: stdout: -379. types.at:139: ok -386. types.at:139: testing glr.c api.value.type={struct foo} %header ... ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -380. types.at:139: ok - ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS -387. types.at:139: testing glr.c api.value.type={struct bar} ... -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y +378. types.at:139: ok +stderr: +stdout: +./types.at:139: $PREPARSER ./test stderr: +stderr: stdout: ./actions.at:1856: $PREPARSER ./input --debug stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -11660,10 +11682,11 @@ Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS -388. types.at:139: testing glr.c api.value.type={struct bar} %header ... +386. types.at:139: testing glr.c api.value.type={struct foo} %header ... +stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: +379. types.at:139: ok Starting parse Entering state 0 Reading a token @@ -11686,68 +11709,61 @@ Cleanup: popping token "end of file" () Cleanup: popping nterm float (ival: 30, fval: 0.3) ./actions.at:1856: sed -ne '/ival:/p' stderr +stdout: +./types.at:139: $PREPARSER ./test +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 358. actions.at:1856: ok + +380. types.at:139: ok ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS +387. types.at:139: testing glr.c api.value.type={struct bar} ... +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y + +388. types.at:139: testing glr.c api.value.type={struct bar} %header ... +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y 389. types.at:139: testing glr.c api.value.type={union foo} ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS +./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS +./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -381. types.at:139: ok stderr: - +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: +385. types.at:139: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -382. types.at:139: ok +381. types.at:139: ok + + 390. types.at:139: testing glr.c api.value.type={union foo} %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y +391. types.at:139: testing glr.c %union { float fval; int ival; }; ... +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: - -stdout: -stderr: -./types.at:139: $PREPARSER ./test -stderr: ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: -391. types.at:139: testing glr.c %union { float fval; int ival; }; ... -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y +382. types.at:139: ok stdout: -383. types.at:139: ok ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS -384. types.at:139: ok -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - -385. types.at:139: ok - +383. types.at:139: ok 392. types.at:139: testing glr.c %union { float fval; int ival; }; %header ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: -393. types.at:139: testing glr.c %union foo { float fval; int ival; }; ... -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y -stdout: -./types.at:139: $PREPARSER ./test -stderr: -394. types.at:139: testing glr.c %union foo { float fval; int ival; }; %header ... -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y -./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS -386. types.at:139: ok -stderr: input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] input.y: warning: shift/reduce conflict on token J [-Wcounterexamples] time limit exceeded: 6.000000 @@ -11757,148 +11773,176 @@ Reduce derivation $accept -> [ s -> [ a -> [ H i . ] J ] $end ] input.y:4.4-6: warning: rule useless in parser due to conflicts [-Wother] ./counterexample.at:451: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr + +393. types.at:139: testing glr.c %union foo { float fval; int ival; }; ... 267. counterexample.at:441: ok +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: stdout: - ./types.at:139: $PREPARSER ./test +stderr: + +./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +389. types.at:139: ok +394. types.at:139: testing glr.c %union foo { float fval; int ival; }; %header ... +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stderr: +stdout: +./types.at:139: $PREPARSER ./test +stderr: +./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS +395. types.at:139: testing glr.c api.value.union.name=foo; %union { float fval; int ival; }; ... +stderr: +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -387. types.at:139: ok +stdout: +386. types.at:139: ok +./types.at:139: $PREPARSER ./test +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS +384. types.at:139: ok + + 396. types.at:139: testing glr.c api.value.union.name=foo; %union { float fval; int ival; }; %header ... -395. types.at:139: testing glr.c api.value.union.name=foo; %union { float fval; int ival; }; ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y +397. types.at:139: testing glr.c api.value.type=union ... ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y - ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS stderr: -397. types.at:139: testing glr.c api.value.type=union ... -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y stdout: -./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -388. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test +387. types.at:139: ok stderr: - ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -389. types.at:139: ok +388. types.at:139: ok + 398. types.at:139: testing glr.c api.value.type=union %header ... -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.c test.y +399. types.at:139: testing lalr1.cc api.value.type={double} ... +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o test test.c $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test -390. types.at:139: ok -399. types.at:139: testing lalr1.cc api.value.type={double} ... -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +393. types.at:139: ok stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 391. types.at:139: ok 400. types.at:139: testing lalr1.cc api.value.type={double} %header ... -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -401. types.at:139: testing lalr1.cc api.value.type={variant} ... stderr: stdout: -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test stderr: +401. types.at:139: testing lalr1.cc api.value.type={variant} ... +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 392. types.at:139: ok +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test + stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -393. types.at:139: ok -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS - - -402. types.at:139: testing lalr1.cc api.value.type={variant} %header ... +390. types.at:139: 402. types.at:139: testing lalr1.cc api.value.type={variant} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y + ok + +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 403. types.at:139: testing lalr1.cc api.value.type={struct foo} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: +stdout: +./types.at:139: $PREPARSER ./test +stderr: stderr: stdout: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: +395. types.at:139: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 394. types.at:139: ok -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS + 404. types.at:139: testing lalr1.cc api.value.type={struct foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: -stderr: -stdout: ./types.at:139: $PREPARSER ./test -./types.at:139: $PREPARSER ./test -stderr: +405. types.at:139: testing lalr1.cc api.value.type={struct bar} ... +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -397. types.at:139: ok stdout: +./types.at:139: $PREPARSER ./test +stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stdout: +397. types.at:139: ok ./types.at:139: $PREPARSER ./test +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: 396. types.at:139: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -395. types.at:139: ok +398. types.at:139: ok -405. types.at:139: testing lalr1.cc api.value.type={struct bar} ... +406. types.at:139: testing lalr1.cc api.value.type={struct bar} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -406. types.at:139: testing lalr1.cc api.value.type={struct bar} %header ... +407. types.at:139: testing lalr1.cc api.value.type={union foo} ... +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +408. types.at:139: testing lalr1.cc api.value.type={union foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -407. types.at:139: testing lalr1.cc api.value.type={union foo} ... -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./headers.at:331: echo "xc" >>expout ./headers.at:332: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -d -o xd.cc xd.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./headers.at:332: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS -c -o xd.o xd.cc stderr: stdout: ./types.at:139: $PREPARSER ./test -./headers.at:332: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS -c -o xd.o xd.cc stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -398. types.at:139: ok - -408. types.at:139: testing lalr1.cc api.value.type={union foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS @@ -11914,26 +11958,18 @@ stdout: ./types.at:139: $PREPARSER ./test stderr: -stdout: -./types.at:139: $PREPARSER ./test -stderr: -stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: stdout: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test @@ -11941,106 +11977,138 @@ ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stderr: +stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $PREPARSER ./test +stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stderr: ./types.at:139: $PREPARSER ./test +stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stdout: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $PREPARSER ./test stderr: +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -stdout: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: +stdout: ./types.at:139: $PREPARSER ./test stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: +stdout: +./types.at:139: $PREPARSER ./test +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stderr: +stdout: +./types.at:139: $PREPARSER ./test +stderr: +stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: stdout: -./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: +./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./types.at:139: $PREPARSER ./test +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: +stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $PREPARSER ./test +stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y @@ -12092,11 +12160,11 @@ } } ' -- *.hh *.h -./headers.at:387: $CC $CFLAGS $CPPFLAGS -c -o c-only.o c-only.c stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: +./headers.at:387: $CC $CFLAGS $CPPFLAGS -c -o c-only.o c-only.c ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y @@ -12106,17 +12174,9 @@ ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -stderr: -stdout: -./types.at:139: $PREPARSER ./test ./headers.at:387: $CXX $CXXFLAGS $CPPFLAGS $LDFLAGS c-only.o cxx-only.o -o c-and-cxx || exit 77 stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: stdout: ./headers.at:387: $PREPARSER ./c-and-cxx stderr: @@ -12124,29 +12184,144 @@ ./headers.at:392: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o parser x[1-9a-d].o -DCC_IS_CXX=$CC_IS_CXX main.cc $LIBS stderr: stdout: +stderr: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: +stdout: +./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] +input.y: warning: 6 reduce/reduce conflicts [-Wconflicts-rr] +input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] + First example: . c A A $end + First reduce derivation + $accept + `-> 0: a $end + `-> 1: b d + `-> 3: %empty . `-> 6: c A A + Second example: . c A A $end + Second reduce derivation + $accept + `-> 0: a $end + `-> 2: c d + `-> 4: %empty . `-> 6: c A A +input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] +time limit exceeded: 6.000000 + First example: b . c A A $end + First reduce derivation + $accept + `-> 0: a $end + `-> 1: b d + `-> 5: a + `-> 1: b d + `-> 3: %empty . `-> 6: c A A + Second example: b . A $end + Second reduce derivation + $accept + `-> 0: a $end + `-> 1: b d + `-> 6: c A + `-> 4: %empty . +input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] +time limit exceeded: 6.000000 + First example: c . c A A $end + First reduce derivation + $accept + `-> 0: a $end + `-> 2: c d + `-> 5: a + `-> 1: b d + `-> 3: %empty . `-> 6: c A A + Second example: c . A $end + Second reduce derivation + $accept + `-> 0: a $end + `-> 2: c d + `-> 6: c A + `-> 4: %empty . +input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] +time limit exceeded: 6.000000 + First example: b c . A + Shift derivation + a + `-> 1: b d + `-> 6: c . A + Second example: b c . c A A $end + Reduce derivation + $accept + `-> 0: a $end + `-> 1: b d + `-> 5: a + `-> 2: c d + `-> 5: a + `-> 1: b d + `-> 3: %empty . `-> 6: c A A +input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] + First example: b c . c A A $end + First reduce derivation + $accept + `-> 0: a $end + `-> 1: b d + `-> 5: a + `-> 2: c d + `-> 5: a + `-> 1: b d + `-> 3: %empty . `-> 6: c A A + Second example: b c . A $end + Second reduce derivation + $accept + `-> 0: a $end + `-> 1: b d + `-> 5: a + `-> 2: c d + `-> 6: c A + `-> 4: %empty . +input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] + First example: b c . A + Shift derivation + a + `-> 1: b d + `-> 6: c . A + Second example: b c . A $end + Reduce derivation + $accept + `-> 0: a $end + `-> 1: b d + `-> 5: a + `-> 2: c d + `-> 6: c A + `-> 4: %empty . +input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] + Example: b d . + First reduce derivation + a + `-> 1: b d . + Second reduce derivation + a + `-> 1: b d + `-> 7: d . +input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] + Example: c d . + First reduce derivation + a + `-> 2: c d . + Second reduce derivation + a + `-> 2: c d + `-> 7: d . +input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] +input.y:6.15: warning: rule useless in parser due to conflicts [-Wother] +./counterexample.at:621: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr +stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stdout: -./types.at:139: $PREPARSER ./test -stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: -./types.at:139: $PREPARSER ./test -stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./counterexample.at:621: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y @@ -12154,49 +12329,29 @@ ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./types.at:139: $PREPARSER ./test -stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: -./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stdout: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test -stderr: stdout: -./headers.at:394: $PREPARSER ./parser stderr: -./headers.at:394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $PREPARSER ./test +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: -310. headers.at:199: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS - +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -409. types.at:139: testing lalr1.cc %union { float fval; int ival; }; ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test @@ -12207,13 +12362,14 @@ ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: @@ -12221,19 +12377,18 @@ ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -./types.at:139: $PREPARSER ./test +./headers.at:394: $PREPARSER ./parser stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./headers.at:394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +310. headers.at:199: ok + +409. types.at:139: testing lalr1.cc %union { float fval; int ival; }; ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stdout: -./types.at:139: $PREPARSER ./test -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test @@ -12241,14 +12396,11 @@ ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y @@ -12260,55 +12412,55 @@ ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -./types.at:139: $PREPARSER ./test -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./types.at:139: $PREPARSER ./test stdout: ./types.at:139: $PREPARSER ./test stderr: +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test -stderr: -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test @@ -12330,25 +12482,17 @@ ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: -stdout: -./types.at:139: $PREPARSER ./test -stderr: -stderr: stdout: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test @@ -12361,26 +12505,34 @@ stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: +stdout: stderr: +./types.at:139: $PREPARSER ./test stdout: +stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test @@ -12390,40 +12542,60 @@ ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: +stderr: ./types.at:139: $PREPARSER ./test +stdout: stderr: +./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test +stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: -stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $PREPARSER ./test +stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: +stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stderr: stdout: @@ -12431,161 +12603,33 @@ ./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: -input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] -input.y: warning: 6 reduce/reduce conflicts [-Wconflicts-rr] -input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] - First example: . c A A $end - First reduce derivation - $accept - `-> 0: a $end - `-> 1: b d - `-> 3: %empty . `-> 6: c A A - Second example: . c A A $end - Second reduce derivation - $accept - `-> 0: a $end - `-> 2: c d - `-> 4: %empty . `-> 6: c A A -input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] -time limit exceeded: 6.000000 - First example: b . c A A $end - First reduce derivation - $accept - `-> 0: a $end - `-> 1: b d - `-> 5: a - `-> 1: b d - `-> 3: %empty . `-> 6: c A A - Second example: b . A $end - Second reduce derivation - $accept - `-> 0: a $end - `-> 1: b d - `-> 6: c A - `-> 4: %empty . -input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] -time limit exceeded: 6.000000 - First example: c . c A A $end - First reduce derivation - $accept - `-> 0: a $end - `-> 2: c d - `-> 5: a - `-> 1: b d - `-> 3: %empty . `-> 6: c A A - Second example: c . A $end - Second reduce derivation - $accept - `-> 0: a $end - `-> 2: c d - `-> 6: c A - `-> 4: %empty . -input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] -time limit exceeded: 6.000000 - First example: b c . A - Shift derivation - a - `-> 1: b d - `-> 6: c . A - Second example: b c . c A A $end - Reduce derivation - $accept - `-> 0: a $end - `-> 1: b d - `-> 5: a - `-> 2: c d - `-> 5: a - `-> 1: b d - `-> 3: %empty . `-> 6: c A A -input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] - First example: b c . c A A $end - First reduce derivation - $accept - `-> 0: a $end - `-> 1: b d - `-> 5: a - `-> 2: c d - `-> 5: a - `-> 1: b d - `-> 3: %empty . `-> 6: c A A - Second example: b c . A $end - Second reduce derivation - $accept - `-> 0: a $end - `-> 1: b d - `-> 5: a - `-> 2: c d - `-> 6: c A - `-> 4: %empty . -input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] - First example: b c . A - Shift derivation - a - `-> 1: b d - `-> 6: c . A - Second example: b c . A $end - Reduce derivation - $accept - `-> 0: a $end - `-> 1: b d - `-> 5: a - `-> 2: c d - `-> 6: c A - `-> 4: %empty . -input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] - Example: b d . - First reduce derivation - a - `-> 1: b d . - Second reduce derivation - a - `-> 1: b d - `-> 7: d . -input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] - Example: c d . - First reduce derivation - a - `-> 2: c d . - Second reduce derivation - a - `-> 2: c d - `-> 7: d . -input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] -input.y:6.15: warning: rule useless in parser due to conflicts [-Wother] -./counterexample.at:621: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g;s/ *$//;' stderr -./counterexample.at:621: YYFLAT=1; export YYFLAT;COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wcounterexamples input.y -stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: @@ -12597,29 +12641,38 @@ stdout: ./types.at:139: $PREPARSER ./test stderr: +stderr: +stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $PREPARSER ./test +stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: -stdout: stderr: -./types.at:139: $PREPARSER ./test stdout: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: +stdout: +./types.at:139: $PREPARSER ./test +stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y @@ -12632,43 +12685,61 @@ stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stdout: +./types.at:139: $PREPARSER ./test +stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +399. types.at:139: ok + +410. types.at:139: testing lalr1.cc %union { float fval; int ival; }; %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: +stdout: +./types.at:139: $PREPARSER ./test +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y @@ -12678,14 +12749,20 @@ ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +408. types.at:139: ok + +411. types.at:139: testing lalr1.cc api.value.type=union ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +401. types.at:139: ok + +412. types.at:139: testing lalr1.cc api.value.type=union %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS @@ -12694,6 +12771,9 @@ ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +400. types.at:139: ok + +413. types.at:139: testing lalr1.cc api.value.type=variant ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS @@ -12710,65 +12790,48 @@ ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -405. types.at:139: ok stderr: +403. types.at:139: ok stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +407. types.at:139: ok + -401. types.at:139: ok stderr: +414. types.at:139: testing lalr1.cc api.value.type=variant %header ... +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -410. types.at:139: testing lalr1.cc %union { float fval; int ival; }; %header ... +415. types.at:139: testing lalr1.cc api.value.type=variant ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -403. types.at:139: ok +405. types.at:139: ok +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: - - ./types.at:139: $PREPARSER ./test stderr: stderr: -stderr: + stdout: ./types.at:139: $PREPARSER ./test stderr: -411. types.at:139: testing lalr1.cc api.value.type=union ... -412. types.at:139: testing lalr1.cc api.value.type=union %header ... ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +416. types.at:139: testing lalr1.cc api.value.type=variant %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $PREPARSER ./test -399. types.at:139: ok -stderr: -404. types.at:139: ok - -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -402. types.at:139: ok - -413. types.at:139: testing lalr1.cc api.value.type=variant ... -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y - -414. types.at:139: testing lalr1.cc api.value.type=variant %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -415. types.at:139: testing lalr1.cc api.value.type=variant ... -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: @@ -12776,18 +12839,15 @@ ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -400. types.at:139: ok - -416. types.at:139: testing lalr1.cc api.value.type=variant %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -406. types.at:139: ok +402. types.at:139: ok 417. types.at:139: testing lalr1.cc api.value.type=variant api.token.constructor ... ======== Testing with C++ standard flags: '' @@ -12795,45 +12855,52 @@ ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -stderr: -./types.at:139: $PREPARSER ./test -stdout: -stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +406. types.at:139: ok + stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -408. types.at:139: ok +418. types.at:139: testing lalr1.cc api.value.type=variant api.token.constructor %header ... +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +404. types.at:139: ok +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS + +419. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant ... ======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stderr: +stdout: +./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: +stderr: +stdout: stdout: ./types.at:139: $PREPARSER ./test +./types.at:139: $PREPARSER ./test +stderr: stderr: - +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -418. types.at:139: testing lalr1.cc api.value.type=variant api.token.constructor %header ... -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: @@ -12843,8 +12910,8 @@ ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: @@ -12856,61 +12923,38 @@ stdout: ./types.at:139: $PREPARSER ./test stderr: -stderr: -stdout: -./types.at:139: $PREPARSER ./test -stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -407. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS - -419. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant ... -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: -stderr: ./types.at:139: $PREPARSER ./test stderr: -stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $PREPARSER ./test -stderr: stderr: stdout: -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS @@ -12922,9 +12966,9 @@ ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr @@ -12934,108 +12978,177 @@ stdout: ./types.at:139: $PREPARSER ./test stderr: +stderr: +stdout: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $PREPARSER ./test +======== Testing with C++ standard flags: '' +stderr: +stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stdout: +./types.at:139: $PREPARSER ./test +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -./types.at:139: $PREPARSER ./test +./types.at:139: ./check +-std=c++98 not supported +======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -409. types.at:139: ok +stdout: +./types.at:139: ./check +-std=c++03 not supported +======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: +stdout: +./types.at:139: ./check +-std=c++11 not supported +======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: - stdout: +./types.at:139: ./check +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: stdout: -420. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant %header ... +stderr: ./types.at:139: $PREPARSER ./test +stdout: stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: -stderr: -stdout: -./types.at:139: $PREPARSER ./test -stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +409. types.at:139: ok stderr: stdout: + ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +420. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant %header ... ======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] +input.y: warning: 6 reduce/reduce conflicts [-Wconflicts-rr] +input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] + First example . c A A $end + First reduce derivation $accept -> [ a -> [ b -> [ . ] d -> [ c A A ] ] $end ] + Second example . c A A $end + Second reduce derivation $accept -> [ a -> [ c -> [ . ] d -> [ c A A ] ] $end ] +input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] +time limit exceeded: 6.000000 + First example b . c A A $end + First reduce derivation $accept -> [ a -> [ b d -> [ a -> [ b -> [ . ] d -> [ c A A ] ] ] ] $end ] + Second example b . A $end + Second reduce derivation $accept -> [ a -> [ b d -> [ c -> [ . ] A ] ] $end ] +input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] +time limit exceeded: 6.000000 + First example c . c A A $end + First reduce derivation $accept -> [ a -> [ c d -> [ a -> [ b -> [ . ] d -> [ c A A ] ] ] ] $end ] + Second example c . A $end + Second reduce derivation $accept -> [ a -> [ c d -> [ c -> [ . ] A ] ] $end ] +input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] +time limit exceeded: 6.000000 + First example b c . A + Shift derivation a -> [ b d -> [ c . A ] ] + Second example b c . c A A $end + Reduce derivation $accept -> [ a -> [ b d -> [ a -> [ c d -> [ a -> [ b -> [ . ] d -> [ c A A ] ] ] ] ] ] $end ] +input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] + First example b c . c A A $end + First reduce derivation $accept -> [ a -> [ b d -> [ a -> [ c d -> [ a -> [ b -> [ . ] d -> [ c A A ] ] ] ] ] ] $end ] + Second example b c . A $end + Second reduce derivation $accept -> [ a -> [ b d -> [ a -> [ c d -> [ c -> [ . ] A ] ] ] ] $end ] +input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] + First example b c . A + Shift derivation a -> [ b d -> [ c . A ] ] + Second example b c . A $end + Reduce derivation $accept -> [ a -> [ b d -> [ a -> [ c d -> [ c -> [ . ] A ] ] ] ] $end ] +input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] + Example b d . + First reduce derivation a -> [ b d . ] + Second reduce derivation a -> [ b d -> [ d . ] ] +input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] + Example c d . + First reduce derivation a -> [ c d . ] + Second reduce derivation a -> [ c d -> [ d . ] ] +input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] +input.y:6.15: warning: rule useless in parser due to conflicts [-Wother] +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./counterexample.at:621: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +270. counterexample.at:610: ok +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: + ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +421. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant api.token.constructor ... +======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: ./check -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS --std=c++98 not supported +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -stderr: -stdout: -./types.at:139: ./check --std=c++03 not supported -======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test @@ -13043,22 +13156,15 @@ ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: -stdout: -./types.at:139: ./check --std=c++11 not supported -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test @@ -13068,27 +13174,34 @@ stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: ./types.at:139: $PREPARSER ./test -stdout: -./types.at:139: ./check stderr: -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: +======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stdout: +./types.at:139: $PREPARSER ./test +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stderr: +stdout: +./types.at:139: ./check +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: @@ -13103,113 +13216,151 @@ ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -stderr: -stdout: stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: ./check --std=c++98 not supported +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: +stderr: stdout: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: +======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stderr: +stdout: +./types.at:139: ./check +-std=c++98 not supported +======== Testing with C++ standard flags: '' +stderr: +stdout: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: ./check +-std=c++98 not supported +======== Testing with C++ standard flags: '' +stderr: stderr: stdout: +stdout: +./types.at:139: $PREPARSER ./test +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stderr: ./types.at:139: $PREPARSER ./test +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: +stdout: +./types.at:139: $PREPARSER ./test +./types.at:139: ./check +stderr: +-std=c++03 not supported +======== Testing with C++ standard flags: '' +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stderr: +stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -stdout: ./types.at:139: ./check -./types.at:139: $PREPARSER ./test -std=c++11 not supported ======== Testing with C++ standard flags: '' stderr: -stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: -./types.at:139: $PREPARSER ./test +./types.at:139: ./check +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +-std=c++11 not supported ======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: -./types.at:139: $PREPARSER ./test -stderr: +./types.at:139: ./check stderr: +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: +stdout: +./types.at:139: $PREPARSER ./test +stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stdout: ======== Testing with C++ standard flags: '' +./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test @@ -13221,28 +13372,36 @@ stdout: ./types.at:139: $PREPARSER ./test stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: +stderr: stdout: +stdout: +./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: @@ -13264,53 +13423,73 @@ stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: +stderr: +stdout: +./types.at:139: ./check ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: +stderr: +stdout: +./types.at:139: $PREPARSER ./test +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: +======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: +stdout: +./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test -stdout: stderr: -./types.at:139: $PREPARSER ./test +stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: -./types.at:139: ./check +./types.at:139: $PREPARSER ./test +stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS @@ -13321,37 +13500,41 @@ ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: +stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stderr: +stdout: +./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: @@ -13366,169 +13549,186 @@ ./types.at:139: $PREPARSER ./test stderr: stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: +stderr: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +./types.at:139: $PREPARSER ./test +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stderr: stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +411. types.at:139: ok + stderr: stdout: -./types.at:139: $PREPARSER ./test -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $PREPARSER ./test +422. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant api.token.constructor %header ... ======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $PREPARSER ./test -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +412. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: -stdout: + ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $PREPARSER ./test -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: -stdout: -./types.at:139: $PREPARSER ./test -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +423. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant api.token.constructor ... ======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stdout: +./types.at:139: ./check stdout: +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $PREPARSER ./test +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -411. types.at:139: ok ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +410. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -421. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant api.token.constructor ... +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +424. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant api.token.constructor %header ... ======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -stderr: -stdout: -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +419. types.at:139: ok + +stderr: +stdout: +425. types.at:139: testing glr.cc api.value.type={double} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: ./check +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -412. types.at:139: ok -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +417. types.at:139: ok -422. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant api.token.constructor %header ... +stderr: +stdout: +426. types.at:139: testing glr.cc api.value.type={double} %header ... +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $PREPARSER ./test +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -410. types.at:139: ok stderr: +stderr: +stdout: +./types.at:139: $PREPARSER ./test stdout: +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: ./check +stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y - -423. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant api.token.constructor ... +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $PREPARSER ./test stderr: stdout: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -./types.at:139: $PREPARSER ./test -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -417. types.at:139: ok - -stderr: -424. types.at:139: testing lalr1.cc %code requires { #include } api.value.type=variant api.token.constructor %header ... +./types.at:139: ./check +-std=c++98 not supported ======== Testing with C++ standard flags: '' +stderr: stdout: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test @@ -13541,115 +13741,72 @@ stderr: stdout: ./types.at:139: ./check -stderr: -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stdout: -./types.at:139: ./check --std=c++98 not supported +-std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -425. types.at:139: testing glr.cc api.value.type={double} ... +stderr: +427. types.at:139: testing glr.cc api.value.type={variant} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stdout: -stderr: stdout: -./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -418. types.at:139: ok ./types.at:139: $PREPARSER ./test -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: stderr: stdout: ./types.at:139: ./check ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr --std=c++03 not supported +-std=c++98 not supported ======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -419. types.at:139: ok - -426. types.at:139: testing glr.cc api.value.type={double} %header ... ======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: -stdout: -./types.at:139: $PREPARSER ./test - -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -414. types.at:139: ok -427. types.at:139: testing glr.cc api.value.type={variant} ... -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: ./check -std=c++11 not supported ======== Testing with C++ standard flags: '' -stderr: -stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./types.at:139: $PREPARSER ./test -stderr: - -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -428. types.at:139: testing glr.cc api.value.type={variant} %header ... -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: +-std=c++03 not supported +======== Testing with C++ standard flags: '' stdout: -./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' +./types.at:139: ./check ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -stderr: stdout: -./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' +./types.at:139: ./check stderr: +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -stderr: -stdout: -./types.at:139: ./check --std=c++98 not supported -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +418. types.at:139: ok +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check + -std=c++03 not supported ======== Testing with C++ standard flags: '' stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: ./check -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS --std=c++03 not supported +-std=c++11 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +428. types.at:139: testing glr.cc api.value.type={variant} %header ... +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check @@ -13657,33 +13814,39 @@ ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: ./check --std=c++11 not supported -======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -stderr: ./types.at:139: $PREPARSER ./test -stdout: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +414. types.at:139: ok +stderr: +stdout: +./types.at:139: $PREPARSER ./test +stderr: + +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +429. types.at:139: testing glr.cc api.value.type={struct foo} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS @@ -13693,232 +13856,225 @@ ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +420. types.at:139: ok + +430. types.at:139: testing glr.cc api.value.type={struct foo} %header ... ======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -420. types.at:139: ok -stderr: -stdout: -./types.at:139: ./check --std=c++98 not supported ======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: - ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +415. types.at:139: ok + stderr: stdout: +./types.at:139: $PREPARSER ./test +stderr: +431. types.at:139: testing glr.cc api.value.type={struct bar} ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: ./check -429. types.at:139: testing glr.cc api.value.type={struct foo} ... -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y --std=c++03 not supported -======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -./types.at:139: ./check --std=c++11 not supported +./types.at:139: $PREPARSER ./test +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: -stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test -./types.at:139: ./check stderr: -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +416. types.at:139: ok stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y + ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +432. types.at:139: testing glr.cc api.value.type={struct bar} %header ... +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -415. types.at:139: ok - -stderr: -stdout: -./types.at:139: $PREPARSER ./test -stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stderr: +./types.at:139: $PREPARSER ./test +stdout: ./types.at:139: $PREPARSER ./test stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -430. types.at:139: testing glr.cc api.value.type={struct foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: -stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: +stderr: +./types.at:139: ./check stdout: ./types.at:139: $PREPARSER ./test -./types.at:139: $PREPARSER ./test -stderr: +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test stderr: +421. types.at:139: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y + ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: -stdout: -./types.at:139: ./check +433. types.at:139: testing glr.cc api.value.type={union foo} ... +======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -416. types.at:139: ok -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS - -stderr: -stdout: -./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test -431. types.at:139: testing glr.cc api.value.type={struct bar} ... +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: stdout: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -======== Testing with C++ standard flags: '' stdout: ./types.at:139: $PREPARSER ./test -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: +stderr: stdout: +stdout: +./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: ./check +./types.at:139: $PREPARSER ./test +stderr: +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: +======== Testing with C++ standard flags: '' ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -stderr: ./types.at:139: $PREPARSER ./test -stdout: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: -./types.at:139: $PREPARSER ./test stderr: +stdout: +./types.at:139: ./check ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS @@ -13928,23 +14084,33 @@ stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' +stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stdout: stderr: +./types.at:139: $PREPARSER ./test stdout: +stderr: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: -./types.at:139: $PREPARSER ./test +./types.at:139: ./check +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: +stdout: +./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test @@ -13953,8 +14119,6 @@ ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test @@ -13968,25 +14132,29 @@ stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: -stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: +stdout: ./types.at:139: $PREPARSER ./test +stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./types.at:139: ./check +stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stdout: +./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS @@ -14000,40 +14168,21 @@ stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: -stdout: -./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: -stdout: -./types.at:139: $PREPARSER ./test -stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: -stderr: -stderr: -stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: $PREPARSER ./test stdout: +stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' @@ -14042,7 +14191,6 @@ ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test @@ -14052,95 +14200,54 @@ ./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./types.at:139: $PREPARSER ./test -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' +stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: +./types.at:139: $PREPARSER ./test stdout: -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: -stdout: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: stdout: +======== Testing with C++ standard flags: '' +./types.at:139: ./check stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stdout: ./types.at:139: $PREPARSER ./test +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: -stderr: -input.y: warning: 1 shift/reduce conflict [-Wconflicts-sr] -input.y: warning: 6 reduce/reduce conflicts [-Wconflicts-rr] -input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] - First example . c A A $end - First reduce derivation $accept -> [ a -> [ b -> [ . ] d -> [ c A A ] ] $end ] - Second example . c A A $end - Second reduce derivation $accept -> [ a -> [ c -> [ . ] d -> [ c A A ] ] $end ] -input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] -time limit exceeded: 6.000000 - First example b . c A A $end - First reduce derivation $accept -> [ a -> [ b d -> [ a -> [ b -> [ . ] d -> [ c A A ] ] ] ] $end ] - Second example b . A $end - Second reduce derivation $accept -> [ a -> [ b d -> [ c -> [ . ] A ] ] $end ] -input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] -time limit exceeded: 6.000000 - First example c . c A A $end - First reduce derivation $accept -> [ a -> [ c d -> [ a -> [ b -> [ . ] d -> [ c A A ] ] ] ] $end ] - Second example c . A $end - Second reduce derivation $accept -> [ a -> [ c d -> [ c -> [ . ] A ] ] $end ] -input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] -time limit exceeded: 6.000000 - First example b c . A - Shift derivation a -> [ b d -> [ c . A ] ] - Second example b c . c A A $end - Reduce derivation $accept -> [ a -> [ b d -> [ a -> [ c d -> [ a -> [ b -> [ . ] d -> [ c A A ] ] ] ] ] ] $end ] -input.y: warning: reduce/reduce conflict on token A [-Wcounterexamples] - First example b c . c A A $end - First reduce derivation $accept -> [ a -> [ b d -> [ a -> [ c d -> [ a -> [ b -> [ . ] d -> [ c A A ] ] ] ] ] ] $end ] - Second example b c . A $end - Second reduce derivation $accept -> [ a -> [ b d -> [ a -> [ c d -> [ c -> [ . ] A ] ] ] ] $end ] -input.y: warning: shift/reduce conflict on token A [-Wcounterexamples] - First example b c . A - Shift derivation a -> [ b d -> [ c . A ] ] - Second example b c . A $end - Reduce derivation $accept -> [ a -> [ b d -> [ a -> [ c d -> [ c -> [ . ] A ] ] ] ] $end ] -input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] - Example b d . - First reduce derivation a -> [ b d . ] - Second reduce derivation a -> [ b d -> [ d . ] ] -input.y: warning: reduce/reduce conflict on token $end [-Wcounterexamples] - Example c d . - First reduce derivation a -> [ c d . ] - Second reduce derivation a -> [ c d -> [ d . ] ] -input.y:5.4: warning: rule useless in parser due to conflicts [-Wother] -input.y:6.15: warning: rule useless in parser due to conflicts [-Wother] -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./counterexample.at:621: sed -e 's/time limit exceeded: [0-9][.0-9]*/time limit exceeded: XXX/g' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -270. counterexample.at:610: ok -======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stderr: +stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS - -432. types.at:139: testing glr.cc api.value.type={struct bar} %header ... -======== Testing with C++ standard flags: '' +./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: ./check +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS @@ -14155,28 +14262,40 @@ stdout: ./types.at:139: $PREPARSER ./test stderr: +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +./types.at:139: $PREPARSER ./test +stderr: +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stderr: stdout: +stdout: +./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: -stdout: -./types.at:139: ./check +======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS @@ -14187,8 +14306,8 @@ ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: @@ -14198,8 +14317,8 @@ stderr: stdout: ./types.at:139: $PREPARSER ./test -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y @@ -14211,37 +14330,36 @@ ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: -stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stderr: stdout: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -421. types.at:139: ok -stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS - stderr: stdout: -stdout: -./types.at:139: $PREPARSER ./test -stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -433. types.at:139: testing glr.cc api.value.type={union foo} ... -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: +stdout: +./types.at:139: $PREPARSER ./test +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: @@ -14253,16 +14371,11 @@ ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -422. types.at:139: ok - -434. types.at:139: testing glr.cc api.value.type={union foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS @@ -14271,20 +14384,47 @@ ./types.at:139: $PREPARSER ./test stderr: stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: -./types.at:139: $PREPARSER ./test stdout: +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $PREPARSER ./test +stderr: ./types.at:139: $PREPARSER ./test stderr: stderr: +stdout: +./types.at:139: $PREPARSER ./test +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stdout: +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +423. types.at:139: ok +./types.at:139: $PREPARSER ./test +422. types.at:139: ok +stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + +424. types.at:139: ok +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS + +434. types.at:139: testing glr.cc api.value.type={union foo} %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +435. types.at:139: testing glr.cc %union { float fval; int ival; }; ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y + +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +436. types.at:139: testing glr.cc %union { float fval; int ival; }; %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS @@ -14293,11 +14433,8 @@ ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test @@ -14310,6 +14447,7 @@ stdout: ./types.at:139: $PREPARSER ./test stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y @@ -14318,40 +14456,33 @@ stdout: ./types.at:139: $PREPARSER ./test stderr: -stdout: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: -./types.at:139: $PREPARSER ./test +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: +stderr: +stderr: +stdout: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -423. types.at:139: ok -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y - -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -435. types.at:139: testing glr.cc %union { float fval; int ival; }; ... +stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stdout: -./types.at:139: $PREPARSER ./test -stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -424. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS - -436. types.at:139: testing glr.cc %union { float fval; int ival; }; %header ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test @@ -14360,6 +14491,7 @@ ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test @@ -14375,56 +14507,56 @@ ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: +stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $PREPARSER ./test stderr: -stdout: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./types.at:139: $PREPARSER ./test stdout: -stderr: +425. types.at:139: ok ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +437. types.at:139: testing glr.cc api.value.type=union ... ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: -stderr: -stdout: stdout: ./types.at:139: $PREPARSER ./test -./types.at:139: $PREPARSER ./test -stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -426. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +426. types.at:139: ok +438. types.at:139: testing glr.cc api.value.type=union %header ... +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -427. types.at:139: ok ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y @@ -14432,26 +14564,26 @@ stderr: stdout: ./types.at:139: $PREPARSER ./test -437. types.at:139: testing glr.cc api.value.type=union ... -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y - ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -438. types.at:139: testing glr.cc api.value.type=union %header ... +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: +stderr: +./types.at:139: $PREPARSER ./test +stdout: +stderr: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -425. types.at:139: ok +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +428. types.at:139: ok +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 439. types.at:139: testing glr2.cc api.value.type={double} ... ======== Testing with C++ standard flags: '' @@ -14462,96 +14594,110 @@ ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: -stdout: -./types.at:139: $PREPARSER ./test -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test +stdout: stderr: +./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./types.at:139: $PREPARSER ./test -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +430. types.at:139: ok + +stderr: +440. types.at:139: testing glr2.cc api.value.type={double} %header ... +stdout: ======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: +./types.at:139: $PREPARSER ./test +stderr: +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +431. types.at:139: ok + ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: +441. types.at:139: testing glr2.cc api.value.type={variant} ... stdout: +./types.at:139: ./check +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: +stdout: +./types.at:139: ./check +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -./types.at:139: $PREPARSER ./test ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -429. types.at:139: ok -stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: - ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -428. types.at:139: ok -440. types.at:139: testing glr2.cc api.value.type={double} %header ... -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +427. types.at:139: ok +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: - stdout: + ./types.at:139: $PREPARSER ./test stderr: -441. types.at:139: testing glr2.cc api.value.type={variant} ... ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +442. types.at:139: testing glr2.cc api.value.type={variant} %header ... ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stderr: +stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: $PREPARSER ./test +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +429. types.at:139: ok stderr: stdout: + ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +443. types.at:139: testing glr2.cc api.value.type={struct foo} ... +======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS @@ -14562,62 +14708,31 @@ ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: -stderr: -stdout: -stdout: -./types.at:139: $PREPARSER ./test -./types.at:139: $PREPARSER ./test -stderr: -stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -430. types.at:139: ok stderr: -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stdout: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $PREPARSER ./test -stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS - ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -442. types.at:139: testing glr2.cc api.value.type={variant} %header ... -======== Testing with C++ standard flags: '' ./types.at:139: $PREPARSER ./test -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: -stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test @@ -14636,187 +14751,169 @@ stderr: stdout: ./types.at:139: ./check +stderr: -std=c++98 not supported ======== Testing with C++ standard flags: '' -stderr: stdout: ./types.at:139: $PREPARSER ./test -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: -stdout: -./types.at:139: $PREPARSER ./test -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: -stderr: -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: -stdout: -./types.at:139: $PREPARSER ./test ./types.at:139: ./check -stderr: -std=c++03 not supported ======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stdout: -./types.at:139: $PREPARSER ./test -stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +432. types.at:139: ok + +444. types.at:139: testing glr2.cc api.value.type={struct foo} %header ... ======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stderr: stderr: stdout: ./types.at:139: $PREPARSER ./test +stdout: stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' +./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: -stdout: -./types.at:139: $PREPARSER ./test +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +======== Testing with C++ standard flags: '' stdout: ./types.at:139: $PREPARSER ./test stderr: -stderr: +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -431. types.at:139: ok - stderr: stdout: -./types.at:139: $PREPARSER ./test -stderr: -443. types.at:139: testing glr2.cc api.value.type={struct foo} ... +./types.at:139: ./check +-std=c++98 not supported ======== Testing with C++ standard flags: '' -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stderr: +stdout: +./types.at:139: ./check +-std=c++03 not supported ======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stdout: +stderr: +stderr: +./types.at:139: ./check +stdout: +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $PREPARSER ./test ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: -stderr: -stderr: -stderr: stdout: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: ./types.at:139: $PREPARSER ./test -stdout: stderr: -./types.at:139: ./check -stdout: -./types.at:139: ./check +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' --std=c++98 not supported -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stderr: +stdout: ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $PREPARSER ./test +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +433. types.at:139: ok stderr: stdout: ./types.at:139: ./check +stderr: -std=c++98 not supported ======== Testing with C++ standard flags: '' -stderr: stdout: +./types.at:139: $PREPARSER ./test + +stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./types.at:139: ./check --std=c++03 not supported +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +445. types.at:139: testing glr2.cc api.value.type={struct bar} ... ======== Testing with C++ standard flags: '' +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' stderr: -stderr: -stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: -stderr: ./types.at:139: ./check -./types.at:139: $PREPARSER ./test +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: stdout: +./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: +stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: -stdout: -stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: ./check -std=c++98 not supported @@ -14826,59 +14923,52 @@ stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: ./check --std=c++03 not supported +-std=c++98 not supported ======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: -./types.at:139: $PREPARSER ./test -stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: ./check +-std=c++03 not supported +======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -./types.at:139: $PREPARSER ./test -stderr: stderr: +./types.at:139: ./check stdout: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $PREPARSER ./test -stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' stderr: +./types.at:139: ./check stdout: ./types.at:139: $PREPARSER ./test -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +-std=c++03 not supported +======== Testing with C++ standard flags: '' stderr: +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: @@ -14892,10 +14982,10 @@ ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' @@ -14908,54 +14998,66 @@ ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: -./types.at:139: $PREPARSER ./test -stderr: +./types.at:139: ./check +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: -./types.at:139: ./check ======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: +stderr: +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stdout: stdout: ./types.at:139: ./check +./types.at:139: $PREPARSER ./test -std=c++98 not supported ======== Testing with C++ standard flags: '' +stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stderr: +stdout: +./types.at:139: $PREPARSER ./test stderr: +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stdout: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: ./check +./types.at:139: ./check +======== Testing with C++ standard flags: '' +-std=c++98 not supported +======== Testing with C++ standard flags: '' -std=c++03 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test @@ -14966,82 +15068,76 @@ stderr: stdout: ./types.at:139: ./check -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: -./types.at:139: $PREPARSER ./test -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -432. types.at:139: ok - -444. types.at:139: testing glr2.cc api.value.type={struct foo} %header ... +stdout: +./types.at:139: ./check +./types.at:139: ./check +-std=c++03 not supported ======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test -stderr: -stderr: -stdout: -./types.at:139: $PREPARSER ./test +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stderr: stdout: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -======== Testing with C++ standard flags: '' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -433. types.at:139: ok +======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stderr: stdout: ./types.at:139: ./check +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y - ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -445. types.at:139: testing glr2.cc api.value.type={struct bar} ... -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test -./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: +./types.at:139: $PREPARSER ./test +stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check @@ -15052,135 +15148,108 @@ ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -434. types.at:139: ok +======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: -./types.at:139: $PREPARSER ./test +./types.at:139: ./check +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: - stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: -446. types.at:139: testing glr2.cc api.value.type={struct bar} %header ... ./types.at:139: $PREPARSER ./test -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stdout: +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: +./types.at:139: $PREPARSER ./test +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: -stdout: -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +435. types.at:139: ok stderr: stdout: + ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: stdout: -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -435. types.at:139: ok -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: -stdout: - ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -447. types.at:139: testing glr2.cc api.value.type={union foo} ... +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +446. types.at:139: testing glr2.cc api.value.type={struct bar} %header ... ======== Testing with C++ standard flags: '' ======== Testing with C++ standard flags: '' +434. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS + +447. types.at:139: testing glr2.cc api.value.type={union foo} ... +======== Testing with C++ standard flags: '' stderr: stdout: -./types.at:139: $PREPARSER ./test -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: -stdout: -436. types.at:139: stderr: - ok +./types.at:139: ./check stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y - ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -448. types.at:139: testing glr2.cc api.value.type={union foo} %header ... -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stderr: +stdout: +./types.at:139: ./check +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -437. types.at:139: ok - +438. types.at:139: ok stderr: + stdout: ./types.at:139: $PREPARSER ./test stderr: -stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +448. types.at:139: testing glr2.cc api.value.type={union foo} %header ... ======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -449. types.at:139: testing glr2.cc %union { float fval; int ival; }; ... -stdout: ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: -stdout: -./types.at:139: ./check --std=c++98 not supported -======== Testing with C++ standard flags: '' -stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -stdout: stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: ./check ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: -stdout: -./types.at:139: ./check stderr: --std=c++03 not supported -======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: +stdout: +./types.at:139: ./check ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: @@ -15191,48 +15260,36 @@ ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +436. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: -stdout: -./types.at:139: ./check --std=c++98 not supported + +449. types.at:139: testing glr2.cc %union { float fval; int ival; }; ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: -stdout: -./types.at:139: ./check --std=c++03 not supported -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: -./types.at:139: $PREPARSER ./test -stderr: -stderr: stdout: +./types.at:139: ./check ./types.at:139: $PREPARSER ./test +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -438. types.at:139: ok +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS - stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -450. types.at:139: testing glr2.cc %union { float fval; int ival; }; %header ... -======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $PREPARSER ./test +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check @@ -15242,80 +15299,78 @@ stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $PREPARSER ./test stderr: +======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +======== Testing with C++ standard flags: '' stderr: stdout: -======== Testing with C++ standard flags: '' -./types.at:139: ./check --std=c++98 not supported -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: $PREPARSER ./test +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +437. types.at:139: ok stderr: stdout: ./types.at:139: ./check + ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: +450. types.at:139: testing glr2.cc %union { float fval; int ival; }; %header ... +======== Testing with C++ standard flags: '' ./types.at:139: ./check --std=c++03 not supported +-std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: stderr: -./types.at:139: $PREPARSER ./test -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: stdout: ./types.at:139: $PREPARSER ./test +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: ./check +-std=c++03 not supported ======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -stderr: -stdout: -./types.at:139: $PREPARSER ./test -stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check +stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: +stdout: +./types.at:139: $PREPARSER ./test +stderr: ./types.at:139: ./check -std=c++98 not supported ======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: $PREPARSER ./test +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +======== Testing with C++ standard flags: '' stderr: +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: @@ -15325,59 +15380,41 @@ ======== Testing with C++ standard flags: '' stderr: stdout: -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stderr: ./types.at:139: ./check --std=c++98 not supported -======== Testing with C++ standard flags: '' +stdout: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: ./check +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -./types.at:139: $PREPARSER ./test -stderr: +./types.at:139: ./check +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: +./types.at:139: $PREPARSER ./test +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./types.at:139: ./check -./types.at:139: ./check --std=c++03 not supported ======== Testing with C++ standard flags: '' -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test stderr: -stdout: -./types.at:139: $PREPARSER ./test -stderr: -stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +-std=c++98 not supported ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: -stderr: -stdout: -stdout: -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: stdout: ./types.at:139: ./check -std=c++98 not supported @@ -15388,66 +15425,54 @@ ./types.at:139: ./check -std=c++03 not supported ======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +-std=c++03 not supported +======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -stderr: stdout: +stderr: ./types.at:139: $PREPARSER ./test stderr: +stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +./types.at:139: ./check stderr: +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' stdout: ./types.at:139: ./check ======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: -stdout: -./types.at:139: $PREPARSER ./test -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check stderr: +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: ./check --std=c++98 not supported -======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: -stdout: -./types.at:139: ./check --std=c++03 not supported -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: ./types.at:139: ./check @@ -15456,7 +15481,6 @@ stderr: stdout: ./types.at:139: $PREPARSER ./test -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' @@ -15467,75 +15491,76 @@ ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: -stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stderr: +stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -stdout: -stderr: -./types.at:139: $PREPARSER ./test -stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' stderr: stdout: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: ./check -======== Testing with C++ standard flags: '' +stderr: ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stdout: +./types.at:139: $PREPARSER ./test +stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: -stderr: -stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stderr: +stdout: ./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stdout: +-std=c++98 not supported +======== Testing with C++ standard flags: '' ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +======== Testing with C++ standard flags: '' stderr: stdout: ./types.at:139: $PREPARSER ./test +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' @@ -15543,7 +15568,18 @@ stderr: stdout: ./types.at:139: ./check +-std=c++03 not supported +======== Testing with C++ standard flags: '' +stderr: +stdout: +./types.at:139: ./check +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stderr: +stdout: +./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check @@ -15582,32 +15618,29 @@ ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: -stderr: -stdout: stdout: +stderr: ./types.at:139: $PREPARSER ./test +stdout: stderr: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -439. types.at:139: ok -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS - -451. types.at:139: testing glr2.cc api.value.type=union ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: +./types.at:139: ./check +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test -./types.at:139: ./check stderr: -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check @@ -15622,74 +15655,71 @@ ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: -./types.at:139: $PREPARSER ./test -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: ./check +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: -======== Testing with C++ standard flags: '' stdout: ./types.at:139: $PREPARSER ./test stderr: -stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./types.at:139: $PREPARSER ./test ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: -stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: +stdout: +./types.at:139: $PREPARSER ./test +stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' stderr: stdout: -./types.at:139: ./check +./types.at:139: $PREPARSER ./test ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: -stdout: -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' stderr: +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stdout: ./types.at:139: $PREPARSER ./test -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stderr: stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -440. types.at:139: ok -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stdout: +./types.at:139: ./check +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +======== Testing with C++ standard flags: '' stderr: stderr: stdout: -stdout: ./types.at:139: $PREPARSER ./test -stderr: +stdout: +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./types.at:139: ./check +stderr: +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y - -452. types.at:139: testing glr2.cc api.value.type=union %header ... ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -======== Testing with C++ standard flags: '' -stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stderr: stdout: +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr @@ -15705,18 +15735,36 @@ ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +439. types.at:139: ok + +451. types.at:139: testing glr2.cc api.value.type=union ... ======== Testing with C++ standard flags: '' ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +441. types.at:139: ok +stderr: stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -441. types.at:139: ok + +452. types.at:139: testing glr2.cc api.value.type=union %header ... +======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stderr: +stdout: +./types.at:139: $PREPARSER ./test +stderr: +stderr: +stdout: +./types.at:139: ./check +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +440. types.at:139: ok ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS 453. types.at:377: testing lalr1.cc: Named %union ... @@ -15726,133 +15774,83 @@ 454. types.at:377: testing glr.cc: Named %union ... ./types.at:377: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y 454. types.at:377: ok + +455. scanner.at:326: testing Token numbers: yacc.c ... +./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./scanner.at:326: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' - -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +442. types.at:139: ok stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -455. scanner.at:326: testing Token numbers: yacc.c ... + ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' +456. scanner.at:326: testing Token numbers: yacc.c api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./scanner.at:326: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -stderr: -stdout: -./types.at:139: ./check --std=c++98 not supported -======== Testing with C++ standard flags: '' -stderr: -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -stdout: -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: -stdout: -./types.at:139: ./check --std=c++03 not supported -======== Testing with C++ standard flags: '' -stderr: stderr: -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -stdout: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.c -./types.at:139: $PREPARSER ./test -stderr: +./scanner.at:326: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./scanner.at:326: $PREPARSER ./input -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -stderr: -stdout: -======== Testing with C++ standard flags: '' ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $PREPARSER ./test -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: -455. scanner.at:326: stderr: - ok +455. scanner.at:326: ok stdout: ./types.at:139: ./check ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' +457. scanner.at:326: testing Token numbers: glr.c ... +./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./scanner.at:326: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: -./types.at:139: ./check -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: -stdout: -./types.at:139: $PREPARSER ./test -stderr: -stderr: -stdout: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -456. scanner.at:326: testing Token numbers: yacc.c api.token.raw ... -./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./types.at:139: $PREPARSER ./test stderr: -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./scanner.at:326: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -stderr: ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -stdout: -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: stdout: -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $PREPARSER ./test stderr: -stdout: -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.c +443. types.at:139: ok ./scanner.at:326: $PREPARSER ./input stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: -./types.at:139: $PREPARSER ./test -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + 456. scanner.at:326: ok -442. types.at:139: ok +./types.at:139: ./check +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +458. scanner.at:326: testing Token numbers: glr.c api.token.raw ... +./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +459. scanner.at:326: testing Token numbers: lalr1.cc ... +./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: +./scanner.at:326: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./types.at:139: $PREPARSER ./test stderr: - ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -457. scanner.at:326: testing Token numbers: glr.c ... -./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./scanner.at:326: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ======== Testing with C++ standard flags: '' -458. scanner.at:326: testing Token numbers: glr.c api.token.raw ... -./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./scanner.at:326: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./scanner.at:326: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stderr: stdout: @@ -15860,225 +15858,222 @@ ./types.at:139: $PREPARSER ./test ./types.at:139: ./check stderr: --std=c++98 not supported -======== Testing with C++ standard flags: '' +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -443. types.at:139: ok +444. types.at:139: ok +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: -stdout: -./types.at:139: ./check --std=c++03 not supported -======== Testing with C++ standard flags: '' -459. scanner.at:326: testing Token numbers: lalr1.cc ... +460. scanner.at:326: testing Token numbers: lalr1.cc api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./scanner.at:326: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: -stdout: -./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.c -./scanner.at:326: $PREPARSER ./input +./types.at:139: $PREPARSER ./test stderr: -./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -458. scanner.at:326: ok +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' stderr: stdout: -stderr: - ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.c -stdout: -./types.at:139: $PREPARSER ./test +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./scanner.at:326: $PREPARSER ./input stderr: stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -457. scanner.at:326: ok -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -stderr: stdout: -460. scanner.at:326: testing Token numbers: lalr1.cc api.token.raw ... -./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +457. scanner.at:326: ok ./types.at:139: $PREPARSER ./test stderr: -./scanner.at:326: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS - ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +======== Testing with C++ standard flags: '' stdout: + ./types.at:139: ./check -======== Testing with C++ standard flags: '' ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -461. scanner.at:326: testing Token numbers: glr.cc ... -./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./scanner.at:326: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +461. scanner.at:326: testing Token numbers: glr.cc ... +./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.c +./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: -stdout: -./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc ./scanner.at:326: $PREPARSER ./input stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -459. scanner.at:326: ok +458. scanner.at:326: ok +./scanner.at:326: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: -./types.at:139: $PREPARSER ./test stderr: +stdout: +./types.at:139: $PREPARSER ./test +./types.at:139: ./check +stderr: +-std=c++98 not supported +======== Testing with C++ standard flags: '' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 462. scanner.at:326: testing Token numbers: glr.cc api.token.raw ... -======== Testing with C++ standard flags: '' ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./scanner.at:326: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +445. types.at:139: ok + stderr: stdout: ./types.at:139: $PREPARSER ./test stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./scanner.at:326: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: -./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc -./scanner.at:326: $PREPARSER ./input -======== Testing with C++ standard flags: '' -stderr: -./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -460. scanner.at:326: ok -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS - 463. scanner.at:326: testing Token numbers: glr2.cc ... +./types.at:139: ./check +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +-std=c++03 not supported +======== Testing with C++ standard flags: '' +======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./scanner.at:326: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: +./types.at:139: ./check stderr: +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stdout: ./types.at:139: ./check -./types.at:139: $PREPARSER ./test ./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./scanner.at:326: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc ./scanner.at:326: $PREPARSER ./input -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -461. scanner.at:326: ok -stderr: -stdout: -./types.at:139: $PREPARSER ./test -stderr: -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +459. scanner.at:326: ok -======== Testing with C++ standard flags: '' -stdout: -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 464. scanner.at:326: testing Token numbers: glr2.cc api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: -stdout: -./types.at:139: ./check ./scanner.at:326: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: -stdout: -./types.at:139: $PREPARSER ./test -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -======== Testing with C++ standard flags: '' -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -stderr: -stdout: -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: ./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc ./scanner.at:326: $PREPARSER ./input stderr: ./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -462. scanner.at:326: ok +460. scanner.at:326: ok +stderr: +stdout: +./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc +./scanner.at:326: $PREPARSER ./input 465. scanner.at:326: testing Token numbers: lalr1.d ... +stderr: ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.d input.y +./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +461. scanner.at:326: ok stderr: stdout: ./types.at:139: $PREPARSER ./test -stderr: +465. scanner.at:326: stderr: + + skipped (scanner.at:326) ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + ======== Testing with C++ standard flags: '' +466. scanner.at:326: testing Token numbers: lalr1.d api.token.raw ... +./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.d input.y ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -465. scanner.at:326: skipped (scanner.at:326) - +467. scanner.at:326: testing Token numbers: lalr1.java ... +./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.java input.y +466. scanner.at:326: stderr: +stdout: + skipped (scanner.at:326) +./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc +467. scanner.at:326: + skipped (scanner.at:326) +./scanner.at:326: $PREPARSER ./input stderr: stderr: +./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: -stdout: -466. scanner.at:326: testing Token numbers: lalr1.d api.token.raw ... -./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.d input.y -./types.at:139: $PREPARSER ./test ./types.at:139: ./check -stderr: -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -444. types.at:139: ok -466. scanner.at:326: skipped (scanner.at:326) -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS - -467. scanner.at:326: testing Token numbers: lalr1.java ... -./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.java input.y 468. scanner.at:326: testing Token numbers: lalr1.java api.token.raw ... ./scanner.at:326: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.java input.y -467. scanner.at:326: skipped (scanner.at:326) -468. scanner.at:326: skipped (scanner.at:326) - - +-std=c++98 not supported +======== Testing with C++ standard flags: '' +462. scanner.at:326: ok +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS 469. scanner.at:330: testing Token numbers: lalr1.cc api.token.raw api.value.type=variant api.token.constructor ... ./scanner.at:330: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y + +468. scanner.at:326: skipped (scanner.at:326) + 470. calc.at:1334: testing Calculator parse.trace ... ./calc.at:1334: mv calc.y.tmp calc.y ./calc.at:1334: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +stderr: +stdout: +./types.at:139: ./check +-std=c++03 not supported +======== Testing with C++ standard flags: '' ./scanner.at:330: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +471. calc.at:1336: testing Calculator %header ... +./calc.at:1336: mv calc.y.tmp calc.y + +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./calc.at:1336: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1334: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +./calc.at:1336: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS +stderr: +stdout: +./types.at:139: ./check +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: stdout: +stderr: ./types.at:139: $PREPARSER ./test +stdout: stderr: +./calc.at:1336: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' +./calc.at:1336: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c calc.h + stderr: +input: +======== Testing with C++ standard flags: '' + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1336: $PREPARSER ./calc input stdout: +stderr: ./calc.at:1334: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./calc.at:1334: "$PERL" -ne ' chomp; @@ -16091,6 +16086,8 @@ || /\t/ )' calc.c +stderr: +./calc.at:1336: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 @@ -17125,6 +17122,9 @@ Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | 1 2 +./calc.at:1336: $PREPARSER ./calc input stderr: Starting parse Entering state 0 @@ -18145,13 +18145,14 @@ Cleanup: popping nterm input (1.1: ) ./calc.at:1334: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: -stdout: +syntax error +./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: +stderr: | 1 2 ./calc.at:1334: $PREPARSER ./calc input -./types.at:139: ./check +syntax error stderr: -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y Starting parse Entering state 0 Stack now 0 @@ -18174,6 +18175,7 @@ Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +stderr: Starting parse Entering state 0 Stack now 0 @@ -18194,6 +18196,22 @@ Stack now 0 Cleanup: discarding lookahead token "number" (1.1: 2) Stack now 0 +stdout: +stderr: +./types.at:139: ./check +./calc.at:1336: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stdout: +./types.at:139: $PREPARSER ./test ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -18204,16 +18222,23 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./calc.at:1334: cat stderr stderr: +./calc.at:1336: cat stderr +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1334: cat stderr +======== Testing with C++ standard flags: '' +input: input: -stdout: -./types.at:139: $PREPARSER ./test | 1//2 -./calc.at:1334: $PREPARSER ./calc input +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./calc.at:1336: $PREPARSER ./calc input +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS + | 1//2 stderr: +./calc.at:1334: $PREPARSER ./calc input stderr: +syntax error +./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -18243,6 +18268,8 @@ Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +stderr: +syntax error Starting parse Entering state 0 Stack now 0 @@ -18270,8 +18297,16 @@ Stack now 0 Cleanup: discarding lookahead token '/' (1.1: ) Stack now 0 -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -445. types.at:139: ok +./calc.at:1336: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -18282,22 +18317,17 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1336: cat stderr stderr: -stdout: -./types.at:139: $PREPARSER ./test -stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' ./calc.at:1334: cat stderr - -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stdout: +input: +./types.at:139: ./check input: -471. calc.at:1336: testing Calculator %header ... -./calc.at:1336: mv calc.y.tmp calc.y - | error ./calc.at:1334: $PREPARSER ./calc input stderr: +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y Starting parse Entering state 0 Stack now 0 @@ -18307,12 +18337,12 @@ Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1336: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y + | error +./calc.at:1336: $PREPARSER ./calc input stderr: -stdout: stderr: -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +syntax error +./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -18321,7 +18351,8 @@ syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 -./calc.at:1336: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS +stderr: +syntax error ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -18333,8 +18364,19 @@ }eg ' expout || exit 77 ./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./calc.at:1336: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1334: cat stderr input: +./calc.at:1336: cat stderr | 1 = 2 = 3 ./calc.at:1334: $PREPARSER ./calc input stderr: @@ -18378,6 +18420,10 @@ Cleanup: discarding lookahead token '=' (1.1: ) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | 1 = 2 = 3 +./calc.at:1336: $PREPARSER ./calc input +stderr: stderr: Starting parse Entering state 0 @@ -18418,6 +18464,10 @@ Stack now 0 Cleanup: discarding lookahead token '=' (1.1: ) Stack now 0 +syntax error +./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +syntax error ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -18428,16 +18478,32 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +stderr: +stdout: +stderr: +./types.at:139: $PREPARSER ./test +./calc.at:1336: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1334: cat stderr +stdout: +stderr: +./scanner.at:330: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc input: +./calc.at:1336: cat stderr +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | | +1 ./calc.at:1334: $PREPARSER ./calc input +./scanner.at:330: $PREPARSER ./input stderr: -stderr: -stdout: -./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc -./scanner.at:326: $PREPARSER ./input Starting parse Entering state 0 Stack now 0 @@ -18465,11 +18531,14 @@ Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -464. scanner.at:326: ok +======== Testing with C++ standard flags: '' +input: stderr: + | + | +1 +./calc.at:1336: $PREPARSER ./calc input +./scanner.at:330: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - Starting parse Entering state 0 Stack now 0 @@ -18495,12 +18564,23 @@ Stack now 0 Cleanup: discarding lookahead token '+' (1.1: ) Stack now 0 -stdout: -./calc.at:1336: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -472. calc.at:1337: testing Calculator %debug %locations ... -./calc.at:1337: mv calc.y.tmp calc.y +syntax error +./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +469. scanner.at:330: ok +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stderr: +syntax error -./calc.at:1337: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +./calc.at:1336: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -18511,20 +18591,21 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1336: cat stderr ./calc.at:1334: cat stderr -./calc.at:1336: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c calc.h +./calc.at:1336: $PREPARSER ./calc /dev/null +472. calc.at:1337: testing Calculator %debug %locations ... +./calc.at:1337: mv calc.y.tmp calc.y +./calc.at:1337: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +stderr: +stderr: ./calc.at:1334: $PREPARSER ./calc /dev/null +syntax error +stdout: +./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./types.at:139: ./check Starting parse Entering state 0 Stack now 0 @@ -18534,8 +18615,10 @@ Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: -input: +stderr: +syntax error Starting parse Entering state 0 Stack now 0 @@ -18544,25 +18627,8 @@ syntax error Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1336: $PREPARSER ./calc input ./calc.at:1337: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS -stderr: -./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1334: "$PERL" -pi -e 'use strict; +./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -18572,29 +18638,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1336: $EGREP -c -v 'Return for a new token:|LAC:' stderr -input: - | 1 2 -./calc.at:1336: $PREPARSER ./calc input -./calc.at:1334: cat stderr -stderr: -stderr: -syntax error -./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc -input: -stderr: -syntax error -stderr: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -stdout: -./calc.at:1334: $PREPARSER ./calc input -./scanner.at:326: $PREPARSER ./input -stderr: -./scanner.at:330: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc -stderr: -./calc.at:1336: "$PERL" -pi -e 'use strict; +./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -18604,7 +18648,23 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./calc.at:1336: cat stderr +./calc.at:1334: cat stderr +input: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1336: $PREPARSER ./calc input +input: +stderr: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1334: $PREPARSER ./calc input +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 +./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: Starting parse Entering state 0 Stack now 0 @@ -18923,10 +18983,13 @@ Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1336: cat stderr stderr: -463. scanner.at:326: ok -./scanner.at:330: $PREPARSER ./input +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 +stderr: Starting parse Entering state 0 Stack now 0 @@ -19244,16 +19307,7 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) -stderr: -input: - | 1//2 -./calc.at:1336: $PREPARSER ./calc input -./scanner.at:330: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: - -syntax error -./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1334: "$PERL" -pi -e 'use strict; +./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -19263,17 +19317,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -469. scanner.at:330: ok -syntax error -473. calc.at:1338: testing Calculator %locations api.location.type={Span} ... -./calc.at:1338: mv calc.y.tmp calc.y - -./calc.at:1338: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -./calc.at:1334: cat stderr -input: - -./calc.at:1336: "$PERL" -pi -e 'use strict; +./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -19283,10 +19327,21 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1336: cat stderr +./calc.at:1334: cat stderr +input: +input: + | (!!) + (1 2) = 1 +./calc.at:1336: $PREPARSER ./calc input +stderr: | (!!) + (1 2) = 1 -./calc.at:1338: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1334: $PREPARSER ./calc input +syntax error +error: 2222 != 1 stderr: +./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stdout: Starting parse Entering state 0 Stack now 0 @@ -19427,11 +19482,12 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) +./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -stdout: +syntax error +error: 2222 != 1 stderr: -./calc.at:1336: cat stderr Starting parse Entering state 0 Stack now 0 @@ -19572,25 +19628,359 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) -./types.at:139: $PREPARSER ./test +./scanner.at:326: $PREPARSER ./input stderr: +./calc.at:1336: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1334: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +463. scanner.at:326: ok +./calc.at:1336: cat stderr +./calc.at:1334: cat stderr input: - | error + | (- *) + (1 2) = 1 ./calc.at:1336: $PREPARSER ./calc input -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: + +input: +syntax error syntax error +error: 2222 != 1 ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -446. types.at:139: ok -474. calc.at:1340: testing Calculator %name-prefix "calc" ... -./calc.at:1340: mv calc.y.tmp calc.y - stderr: -./calc.at:1340: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y + | (- *) + (1 2) = 1 +stdout: +./calc.at:1334: $PREPARSER ./calc input +stderr: +stderr: +syntax error +syntax error +error: 2222 != 1 +./scanner.at:326: $EGREP -c 'yytranslate\[\]|translate_table\[\]|translate_table =|translate_table_ =' input.cc +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '-' (1.1: ) +Shifting token '-' (1.1: ) +Entering state 2 +Stack now 0 4 2 +Reading a token +Next token is token '*' (1.1: ) +syntax error +Shifting token error (1.1: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 120): + $1 = token '-' (1.1: ) + $2 = token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token "number" (1.1: 2) +syntax error +Error: popping nterm exp (1.1: 1) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token "number" (1.1: 2) +Error: discarding token "number" (1.1: 2) +Error: popping token error (1.1: ) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1111) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.1: ) +Reducing stack by rule 6 (line 82): + $1 = nterm exp (1.1: 2222) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 1) +error: 2222 != 1 +-> $$ = nterm exp (1.1: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 2222) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token "end of input" (1.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) +./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./scanner.at:326: $PREPARSER ./input +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '-' (1.1: ) +Shifting token '-' (1.1: ) +Entering state 2 +Stack now 0 4 2 +Reading a token +Next token is token '*' (1.1: ) +syntax error +Shifting token error (1.1: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 120): + $1 = token '-' (1.1: ) + $2 = token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token "number" (1.1: 2) +syntax error +Error: popping nterm exp (1.1: 1) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token "number" (1.1: 2) +Error: discarding token "number" (1.1: 2) +Error: popping token error (1.1: ) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1111) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.1: ) +Reducing stack by rule 6 (line 82): + $1 = nterm exp (1.1: 2222) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 1) +error: 2222 != 1 +-> $$ = nterm exp (1.1: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 2222) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token "end of input" (1.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) +stderr: +473. calc.at:1338: testing Calculator %locations api.location.type={Span} ... +./calc.at:1338: mv calc.y.tmp calc.y + stderr: +./calc.at:1338: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stdout: -./calc.at:1337: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -./calc.at:1334: "$PERL" -pi -e 'use strict; +./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -19600,8 +19990,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -syntax error - +./calc.at:1337: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +./scanner.at:326: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" @@ -19613,7 +20003,7 @@ || /\t/ )' calc.c -./calc.at:1336: "$PERL" -pi -e 'use strict; +./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -19623,8 +20013,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +464. scanner.at:326: ok +./calc.at:1336: cat stderr input: -./calc.at:1334: cat stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -19639,9 +20030,7 @@ | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1337: $PREPARSER ./calc input -./calc.at:1336: cat stderr stderr: -input: Starting parse Entering state 0 Stack now 0 @@ -20659,164 +21048,15 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) +./calc.at:1334: cat stderr ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (- *) + (1 2) = 1 -./calc.at:1334: $PREPARSER ./calc input +input: + | (* *) + (*) + (*) +./calc.at:1336: $PREPARSER ./calc input +./calc.at:1338: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS + stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '-' (1.1: ) -Shifting token '-' (1.1: ) -Entering state 2 -Stack now 0 4 2 -Reading a token -Next token is token '*' (1.1: ) -syntax error -Shifting token error (1.1: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 120): - $1 = token '-' (1.1: ) - $2 = token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token "number" (1.1: 2) -syntax error -Error: popping nterm exp (1.1: 1) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token "number" (1.1: 2) -Error: discarding token "number" (1.1: 2) -Error: popping token error (1.1: ) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1111) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 6 (line 82): - $1 = nterm exp (1.1: 2222) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1) -error: 2222 != 1 --> $$ = nterm exp (1.1: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 2222) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) -./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -475. calc.at:1341: testing Calculator %verbose ... -./calc.at:1340: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: -./calc.at:1341: mv calc.y.tmp calc.y - Starting parse Entering state 0 Stack now 0 @@ -21834,313 +22074,17 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -stderr: -./calc.at:1337: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '-' (1.1: ) -Shifting token '-' (1.1: ) -Entering state 2 -Stack now 0 4 2 -Reading a token -Next token is token '*' (1.1: ) +./calc.at:1337: $EGREP -c -v 'Return for a new token:|LAC:' stderr syntax error -Shifting token error (1.1: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 120): - $1 = token '-' (1.1: ) - $2 = token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token "number" (1.1: 2) syntax error -Error: popping nterm exp (1.1: 1) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token "number" (1.1: 2) -Error: discarding token "number" (1.1: 2) -Error: popping token error (1.1: ) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1111) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 6 (line 82): - $1 = nterm exp (1.1: 2222) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1) -error: 2222 != 1 --> $$ = nterm exp (1.1: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 2222) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) -./calc.at:1341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y - | 1 = 2 = 3 -./calc.at:1336: $PREPARSER ./calc input -stderr: -input: syntax error ./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1334: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | 1 2 -./calc.at:1337: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token "number" (1.3: 2) -1.3: syntax error -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token "number" (1.3: 2) -Stack now 0 -./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1341: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS -stderr: -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token "number" (1.3: 2) -1.3: syntax error -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token "number" (1.3: 2) -Stack now 0 -syntax error -./calc.at:1334: cat stderr -./calc.at:1336: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1337: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1337: cat stderr -input: -./calc.at:1336: cat stderr - | 1//2 -./calc.at:1337: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Stack now 0 8 23 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error -Error: popping token '/' (1.2: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) -Stack now 0 -./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: | (* *) + (*) + (*) -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Stack now 0 8 23 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error -Error: popping token '/' (1.2: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) -Stack now 0 ./calc.at:1334: $PREPARSER ./calc input stderr: +stderr: input: - | - | +1 -./calc.at:1336: $PREPARSER ./calc input stderr: Starting parse Entering state 0 @@ -22293,25 +22237,18 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) -./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error -./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1337: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: syntax error -stderr: +syntax error +./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: -./calc.at:1337: cat stderr stderr: + | 1 2 +./calc.at:1337: $PREPARSER ./calc input +474. calc.at:1340: testing Calculator %name-prefix "calc" ... +./types.at:139: $PREPARSER ./test +./calc.at:1340: mv calc.y.tmp calc.y + Starting parse Entering state 0 Stack now 0 @@ -22463,66 +22400,8 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) -input: - | error -./calc.at:1338: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -./calc.at:1337: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error -Cleanup: discarding lookahead token "invalid token" (1.1: ) -Stack now 0 -./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1340: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error -Cleanup: discarding lookahead token "invalid token" (1.1: ) -Stack now 0 -./calc.at:1336: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1338: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c - -./calc.at:1337: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1337: cat stderr -input: -input: - | 1 = 2 = 3 -./calc.at:1337: $PREPARSER ./calc input -./calc.at:1336: cat stderr stderr: Starting parse Entering state 0 @@ -22538,34 +22417,14 @@ Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error -Error: popping nterm exp (1.5: 2) -Stack now 0 8 19 -Error: popping token '=' (1.3: ) -Stack now 0 8 +Next token is token "number" (1.3: 2) +1.3: syntax error Error: popping nterm exp (1.1: 1) Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) +Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1334: "$PERL" -pi -e 'use strict; +./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -22575,22 +22434,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1336: $PREPARSER ./calc /dev/null - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1338: $PREPARSER ./calc input -stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 @@ -22606,45 +22450,14 @@ Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error -Error: popping nterm exp (1.5: 2) -Stack now 0 8 19 -Error: popping token '=' (1.3: ) -Stack now 0 8 +Next token is token "number" (1.3: 2) +1.3: syntax error Error: popping nterm exp (1.1: 1) Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) +Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 -stderr: -stdout: -syntax error -./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: -stderr: -./calc.at:1334: cat stderr -syntax error -./types.at:139: $PREPARSER ./test -./calc.at:1340: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1337: "$PERL" -pi -e 'use strict; +======== Testing with C++ standard flags: '' +./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -22654,9 +22467,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1336: "$PERL" -pi -e 'use strict; +./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -22666,38 +22477,24 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1336: cat stderr +./calc.at:1340: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./calc.at:1334: cat stderr +./calc.at:1337: cat stderr +input: + | 1 + 2 * 3 + !+ ++ +./calc.at:1336: $PREPARSER ./calc input +input: +stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1334: $PREPARSER ./calc input -./calc.at:1337: cat stderr -449. types.at:139: ok -./calc.at:1340: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c - +input: +./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1//2 stderr: +./calc.at:1337: $PREPARSER ./calc input stderr: -./calc.at:1338: $EGREP -c -v 'Return for a new token:|LAC:' stderr -input: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 Starting parse Entering state 0 Stack now 0 @@ -22778,106 +22575,41 @@ Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) -input: -./calc.at:1340: $PREPARSER ./calc input -./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1336: cat stderr -./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | - | +1 -./calc.at:1337: $PREPARSER ./calc input - | 1 2 -./calc.at:1338: $PREPARSER ./calc input -stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 83): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) -Stack now 0 -./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.3: syntax error -./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 83): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Stack now 0 8 23 Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error -Error: popping nterm input (1.1-2.0: ) +Next token is token '/' (1.3: ) +1.3: syntax error +Error: popping token '/' (1.2: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) +Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1336: $PREPARSER ./calc input -stderr: +./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 -./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1337: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - +./calc.at:1336: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: -1.3: syntax error stderr: stderr: -./calc.at:1340: $EGREP -c -v 'Return for a new token:|LAC:' stderr -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 +stdout: Starting parse Entering state 0 Stack now 0 @@ -22959,20 +22691,37 @@ Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) ./calc.at:1334: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1337: cat stderr -./calc.at:1337: $PREPARSER ./calc /dev/null -./calc.at:1336: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1338: "$PERL" -pi -e 'use strict; +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Stack now 0 8 23 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error +Error: popping token '/' (1.2: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '/' (1.3: ) +Stack now 0 +./types.at:139: ./check +input: +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -22982,47 +22731,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Now at end of input. -1.1: syntax error -Cleanup: discarding lookahead token "end of input" (1.1: ) -Stack now 0 -./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -stderr: - | 1 2 -./calc.at:1340: $PREPARSER ./calc input + | 1 + 2 * 3 + !- ++ +./calc.at:1336: $PREPARSER ./calc input stderr: -syntax error -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Now at end of input. -1.1: syntax error -Cleanup: discarding lookahead token "end of input" (1.1: ) -Stack now 0 -./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -./calc.at:1336: cat stderr -476. calc.at:1342: testing Calculator %yacc ... -./calc.at:1342: - if "$POSIXLY_CORRECT_IS_EXPORTED"; then - sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y - else - mv calc.y.tmp calc.y - fi - - -./calc.at:1342: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | 1 + 2 * 3 + !- ++ ./calc.at:1334: $PREPARSER ./calc input stderr: -stderr: -stderr: +./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -23103,44 +22819,10 @@ Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) -syntax error ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -stdout: -./calc.at:1337: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: - | (!!) + (1 2) = 1 -./calc.at:1336: $PREPARSER ./calc input -./calc.at:1341: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -stderr: -./calc.at:1338: cat stderr -syntax error -error: 2222 != 1 -./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1341: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c - stderr: -syntax error -error: 2222 != 1 ./calc.at:1337: cat stderr +stderr: Starting parse Entering state 0 Stack now 0 @@ -23221,25 +22903,21 @@ Stack now 0 8 21 Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS input: -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 + | error ./calc.at:1337: $PREPARSER ./calc input -./calc.at:1341: $PREPARSER ./calc input -./calc.at:1340: "$PERL" -pi -e 'use strict; +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token "invalid token" (1.1: ) +1.1: syntax error +Cleanup: discarding lookahead token "invalid token" (1.1: ) +Stack now 0 +./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -23250,649 +22928,355 @@ }eg ' expout || exit 77 stderr: -stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 +Next token is token "invalid token" (1.1: ) +1.1: syntax error +Cleanup: discarding lookahead token "invalid token" (1.1: ) +Stack now 0 +./calc.at:1334: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1337: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1336: cat stderr +input: + | 1 + 2 * 3 + !* ++ +./calc.at:1334: cat stderr +./calc.at:1336: $PREPARSER ./calc input +stderr: +./calc.at:1337: cat stderr +memory exhausted +./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +input: +stdout: +stdout: +input: +./calc.at:1340: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +./calc.at:1338: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' + | 1 = 2 = 3 + | 1 + 2 * 3 + !* ++ +stderr: +./calc.at:1337: $PREPARSER ./calc input +./calc.at:1334: $PREPARSER ./calc input +memory exhausted +stderr: +stderr: +./calc.at:1338: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c + +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 126): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token "number" (1.7: 1) -Shifting token "number" (1.7: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Reading a token -Next token is token "number" (1.11: 1) -Shifting token "number" (1.11: 1) +Next token is token "number" (1.1: 2) +Shifting token "number" (1.1: 2) Entering state 1 -Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.11: 1) --> $$ = nterm exp (1.11: 1) +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 2) +-> $$ = nterm exp (1.1: 2) Entering state 30 -Stack now 0 8 21 4 12 21 30 +Stack now 0 8 21 30 Reading a token -Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 105): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Stack now 0 8 21 4 12 21 +Next token is token '*' (1.1: ) +Shifting token '*' (1.1: ) +Entering state 22 +Stack now 0 8 21 30 22 Reading a token -Next token is token "number" (1.15: 1) -Shifting token "number" (1.15: 1) +Next token is token "number" (1.1: 3) +Shifting token "number" (1.1: 3) Entering state 1 -Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 30 -Stack now 0 8 21 4 12 21 30 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack by rule 7 (line 105): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 21 -Stack now 0 8 21 4 12 21 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 3) +-> $$ = nterm exp (1.1: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error -Error: popping token '+' (1.17: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.7-15: 3) -Stack now 0 8 21 4 -Shifting token error (1.7-18: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 126): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) +Next token is token '+' (1.1: ) +Reducing stack by rule 9 (line 100): + $1 = nterm exp (1.1: 2) + $2 = token '*' (1.1: ) + $3 = nterm exp (1.1: 3) +-> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 -Reading a token -Next token is token '+' (1.20: ) -Reducing stack by rule 7 (line 105): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) +Next token is token '+' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 6) +-> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Error: popping token error (1.23: ) -Stack now 0 8 21 4 -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Error: popping token error (1.23: ) -Stack now 0 8 21 4 -Shifting token error (1.23-25: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) -Error: popping token error (1.23-25: ) -Stack now 0 8 21 4 -Shifting token error (1.23-27: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 126): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 30 -Stack now 0 8 21 30 +Next token is token '!' (1.1: ) +Shifting token '!' (1.1: ) +Entering state 5 +Stack now 0 8 21 5 Reading a token -Next token is token '+' (1.30: ) -Reducing stack by rule 7 (line 105): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) -Entering state 21 +Next token is token '*' (1.1: ) +Shifting token '*' (1.1: ) +Entering state 15 +Stack now 0 8 21 5 15 +Reducing stack by rule 19 (line 124): + $1 = token '!' (1.1: ) + $2 = token '*' (1.1: ) +memory exhausted Stack now 0 8 21 +Cleanup: popping token '+' (1.1: ) +Cleanup: popping nterm exp (1.1: 7) +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token "number" (1.33: 1) -Shifting token "number" (1.33: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 22 -Stack now 0 8 21 4 12 22 -Reading a token -Next token is token "number" (1.37: 2) -Shifting token "number" (1.37: 2) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Stack now 0 8 21 4 12 22 1 +Stack now 0 1 Reducing stack by rule 5 (line 88): - $1 = token "number" (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 31 -Stack now 0 8 21 4 12 22 31 -Reading a token -Next token is token '*' (1.39: ) -Reducing stack by rule 9 (line 107): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 22 -Stack now 0 8 21 4 12 22 -Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error -Error: popping token '*' (1.39: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.33-37: 2) -Stack now 0 8 21 4 -Shifting token error (1.33-41: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Error: popping token error (1.33-41: ) -Stack now 0 8 21 4 -Shifting token error (1.33-41: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 126): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.44: ) -Reducing stack by rule 7 (line 105): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token "number" (1.46: 1) -Shifting token "number" (1.46: 1) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): - $1 = token "number" (1.46: 1) --> $$ = nterm exp (1.46: 1) + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.47-2.0: ) -Reducing stack by rule 6 (line 89): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) -Entering state 8 +Next token is token '=' (1.7: ) +1.7: syntax error +Error: popping nterm exp (1.5: 2) +Stack now 0 8 19 +Error: popping token '=' (1.3: ) Stack now 0 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 +./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1340: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c + stderr: -./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +input: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 126): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token "number" (1.7: 1) -Shifting token "number" (1.7: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Reading a token -Next token is token "number" (1.11: 1) -Shifting token "number" (1.11: 1) +Next token is token "number" (1.1: 2) +Shifting token "number" (1.1: 2) Entering state 1 -Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.11: 1) --> $$ = nterm exp (1.11: 1) +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 2) +-> $$ = nterm exp (1.1: 2) Entering state 30 -Stack now 0 8 21 4 12 21 30 +Stack now 0 8 21 30 Reading a token -Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 105): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Stack now 0 8 21 4 12 21 +Next token is token '*' (1.1: ) +Shifting token '*' (1.1: ) +Entering state 22 +Stack now 0 8 21 30 22 Reading a token -Next token is token "number" (1.15: 1) -Shifting token "number" (1.15: 1) +Next token is token "number" (1.1: 3) +Shifting token "number" (1.1: 3) Entering state 1 -Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 30 -Stack now 0 8 21 4 12 21 30 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack by rule 7 (line 105): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 21 -Stack now 0 8 21 4 12 21 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 3) +-> $$ = nterm exp (1.1: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error -Error: popping token '+' (1.17: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.7-15: 3) -Stack now 0 8 21 4 -Shifting token error (1.7-18: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 126): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) +Next token is token '+' (1.1: ) +Reducing stack by rule 9 (line 100): + $1 = nterm exp (1.1: 2) + $2 = token '*' (1.1: ) + $3 = nterm exp (1.1: 3) +-> $$ = nterm exp (1.1: 6) Entering state 30 Stack now 0 8 21 30 -Reading a token -Next token is token '+' (1.20: ) -Reducing stack by rule 7 (line 105): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) +Next token is token '+' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 6) +-> $$ = nterm exp (1.1: 7) Entering state 8 Stack now 0 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Error: popping token error (1.23: ) -Stack now 0 8 21 4 -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Error: popping token error (1.23: ) -Stack now 0 8 21 4 -Shifting token error (1.23-25: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) -Error: popping token error (1.23-25: ) -Stack now 0 8 21 4 -Shifting token error (1.23-27: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 126): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 30 -Stack now 0 8 21 30 +Next token is token '!' (1.1: ) +Shifting token '!' (1.1: ) +Entering state 5 +Stack now 0 8 21 5 Reading a token -Next token is token '+' (1.30: ) -Reducing stack by rule 7 (line 105): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) -Entering state 21 +Next token is token '*' (1.1: ) +Shifting token '*' (1.1: ) +Entering state 15 +Stack now 0 8 21 5 15 +Reducing stack by rule 19 (line 124): + $1 = token '!' (1.1: ) + $2 = token '*' (1.1: ) +memory exhausted Stack now 0 8 21 +Cleanup: popping token '+' (1.1: ) +Cleanup: popping nterm exp (1.1: 7) + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token "number" (1.33: 1) -Shifting token "number" (1.33: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 22 -Stack now 0 8 21 4 12 22 -Reading a token -Next token is token "number" (1.37: 2) -Shifting token "number" (1.37: 2) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Stack now 0 8 21 4 12 22 1 +Stack now 0 1 Reducing stack by rule 5 (line 88): - $1 = token "number" (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 31 -Stack now 0 8 21 4 12 22 31 -Reading a token -Next token is token '*' (1.39: ) -Reducing stack by rule 9 (line 107): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 22 -Stack now 0 8 21 4 12 22 -Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error -Error: popping token '*' (1.39: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.33-37: 2) -Stack now 0 8 21 4 -Shifting token error (1.33-41: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Error: popping token error (1.33-41: ) -Stack now 0 8 21 4 -Shifting token error (1.33-41: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 126): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.44: ) -Reducing stack by rule 7 (line 105): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token "number" (1.46: 1) -Shifting token "number" (1.46: 1) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): - $1 = token "number" (1.46: 1) --> $$ = nterm exp (1.46: 1) + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.47-2.0: ) -Reducing stack by rule 6 (line 89): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) -Entering state 8 +Next token is token '=' (1.7: ) +1.7: syntax error +Error: popping nterm exp (1.5: 2) +Stack now 0 8 19 +Error: popping token '=' (1.3: ) Stack now 0 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 +./calc.at:1338: $PREPARSER ./calc input input: stderr: - | 1//2 -./calc.at:1341: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1340: cat stderr + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 ./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -23903,7 +23287,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1338: $PREPARSER ./calc input +./calc.at:1340: $PREPARSER ./calc input +./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -23914,11 +23303,13 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./types.at:139: $PREPARSER ./test +stderr: +stderr: +./calc.at:1336: cat stderr +./calc.at:1340: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1338: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: -./calc.at:1342: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS -1.3: syntax error -input: - | 1 2 ./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -23929,29 +23320,108 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1341: $PREPARSER ./calc input -./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1337: cat stderr +input: +input: + | (#) + (#) = 2222 +input: +./calc.at:1336: $PREPARSER ./calc input + | 1 2 +./calc.at:1340: $PREPARSER ./calc input stderr: + | 1 2 input: -./calc.at:1337: cat stderr +./calc.at:1338: $PREPARSER ./calc input +======== Testing with C++ standard flags: '' +./calc.at:1334: cat stderr +syntax error: invalid character: '#' +syntax error: invalid character: '#' +stderr: + | + | +1 +./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1337: $PREPARSER ./calc input syntax error stderr: - | 1//2 -./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.3: syntax error -./calc.at:1340: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 83): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error +Error: popping nterm input (1.1-2.0: ) +Stack now 0 +Cleanup: discarding lookahead token '+' (2.1: ) +Stack now 0 +./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stderr: syntax error -./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error input: -./calc.at:1336: cat stderr stderr: - | (!!) + (1 2) = 1 -input: -./calc.at:1337: $PREPARSER ./calc input +syntax error: invalid character: '#' +syntax error: invalid character: '#' +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 83): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error +Error: popping nterm input (1.1-2.0: ) +Stack now 0 +Cleanup: discarding lookahead token '+' (2.1: ) +Stack now 0 + | (#) + (#) = 2222 +./calc.at:1334: $PREPARSER ./calc input +1.3: syntax error stderr: +./calc.at:1337: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Stack now 0 @@ -23961,34 +23431,1542 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Stack now 0 4 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 16 -Stack now 0 4 5 16 -Reducing stack by rule 16 (line 128): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) +syntax error: invalid character: '#' +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Next token is token "invalid token" (1.1: ) +Error: discarding token "invalid token" (1.1: ) +Error: popping token error (1.1: ) Stack now 0 4 -Shifting token error (1.2-3: ) +Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 126): +Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) -Entering state 8 -Stack now 0 8 + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +syntax error: invalid character: '#' +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token "invalid token" (1.1: ) +Error: discarding token "invalid token" (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1111) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token "number" (1.1: 2222) +Shifting token "number" (1.1: 2222) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 2222) +-> $$ = nterm exp (1.1: 2222) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.1: ) +Reducing stack by rule 6 (line 82): + $1 = nterm exp (1.1: 2222) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 2222) +-> $$ = nterm exp (1.1: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 2222) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token "end of input" (1.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) +./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1338: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1336: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +syntax error: invalid character: '#' +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Next token is token "invalid token" (1.1: ) +Error: discarding token "invalid token" (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +syntax error: invalid character: '#' +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token "invalid token" (1.1: ) +Error: discarding token "invalid token" (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1111) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token "number" (1.1: 2222) +Shifting token "number" (1.1: 2222) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 2222) +-> $$ = nterm exp (1.1: 2222) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.1: ) +Reducing stack by rule 6 (line 82): + $1 = nterm exp (1.1: 2222) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 2222) +-> $$ = nterm exp (1.1: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 2222) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token "end of input" (1.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) +./calc.at:1340: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1337: cat stderr +./calc.at:1336: cat stderr +./calc.at:1337: $PREPARSER ./calc /dev/null +stderr: +./calc.at:1338: cat stderr +./calc.at:1340: cat stderr +./calc.at:1334: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +stdout: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Now at end of input. +1.1: syntax error +Cleanup: discarding lookahead token "end of input" (1.1: ) +Stack now 0 +./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./types.at:139: ./check + | (1 + #) = 1111 +./calc.at:1336: $PREPARSER ./calc input +input: +input: +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +stderr: +stderr: + | 1//2 + | 1//2 +./calc.at:1338: $PREPARSER ./calc input +syntax error: invalid character: '#' +./calc.at:1340: $PREPARSER ./calc input +./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +./calc.at:1334: cat stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Now at end of input. +1.1: syntax error +Cleanup: discarding lookahead token "end of input" (1.1: ) +Stack now 0 +1.3: syntax error +stderr: +./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +syntax error: invalid character: '#' +./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1337: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +input: +stderr: + | (1 + #) = 1111 +./calc.at:1334: $PREPARSER ./calc input +1.3: syntax error +syntax error +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +syntax error: invalid character: '#' +Error: popping token '+' (1.1: ) +Stack now 0 4 12 +Error: popping nterm exp (1.1: 1) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Next token is token "invalid token" (1.1: ) +Error: discarding token "invalid token" (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token "number" (1.1: 1111) +Shifting token "number" (1.1: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.1: ) +Reducing stack by rule 6 (line 82): + $1 = nterm exp (1.1: 1111) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 1111) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token "end of input" (1.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1337: cat stderr +./calc.at:1338: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1336: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +syntax error: invalid character: '#' +Error: popping token '+' (1.1: ) +Stack now 0 4 12 +Error: popping nterm exp (1.1: 1) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Next token is token "invalid token" (1.1: ) +Error: discarding token "invalid token" (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token "number" (1.1: 1111) +Shifting token "number" (1.1: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.1: ) +Reducing stack by rule 6 (line 82): + $1 = nterm exp (1.1: 1111) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 1111) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token "end of input" (1.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) +input: +./calc.at:1340: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1337: $PREPARSER ./calc input +./calc.at:1338: cat stderr +stdout: +stderr: +./calc.at:1336: cat stderr +./types.at:139: $PREPARSER ./test +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token ')' (1.2: ) +1.2: syntax error +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token "number" (1.7: 1) +Shifting token "number" (1.7: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.7: 1) +-> $$ = nterm exp (1.7: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token "number" (1.11: 1) +Shifting token "number" (1.11: 1) +Entering state 1 +Stack now 0 8 21 4 12 21 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 30 +Stack now 0 8 21 4 12 21 30 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 105): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token "number" (1.15: 1) +Shifting token "number" (1.15: 1) +Entering state 1 +Stack now 0 8 21 4 12 21 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 30 +Stack now 0 8 21 4 12 21 30 +Reading a token +Next token is token '+' (1.17: ) +Reducing stack by rule 7 (line 105): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error +Error: popping token '+' (1.17: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.7-15: 3) +Stack now 0 8 21 4 +Shifting token error (1.7-18: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 126): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.20: ) +Reducing stack by rule 7 (line 105): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token '*' (1.23: ) +1.23: syntax error +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) +Error: popping token error (1.23: ) +Stack now 0 8 21 4 +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Error: popping token error (1.23: ) +Stack now 0 8 21 4 +Shifting token error (1.23-25: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Error: popping token error (1.23-25: ) +Stack now 0 8 21 4 +Shifting token error (1.23-27: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 126): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.30: ) +Reducing stack by rule 7 (line 105): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token "number" (1.33: 1) +Shifting token "number" (1.33: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 22 +Stack now 0 8 21 4 12 22 +Reading a token +Next token is token "number" (1.37: 2) +Shifting token "number" (1.37: 2) +Entering state 1 +Stack now 0 8 21 4 12 22 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 31 +Stack now 0 8 21 4 12 22 31 +Reading a token +Next token is token '*' (1.39: ) +Reducing stack by rule 9 (line 107): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 22 +Stack now 0 8 21 4 12 22 +Reading a token +Next token is token '*' (1.41: ) +1.41: syntax error +Error: popping token '*' (1.39: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.33-37: 2) +Stack now 0 8 21 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) +Error: popping token error (1.33-41: ) +Stack now 0 8 21 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 126): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.44: ) +Reducing stack by rule 7 (line 105): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token "number" (1.46: 1) +Shifting token "number" (1.46: 1) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.46: 1) +-> $$ = nterm exp (1.46: 1) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.47-2.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1334: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +./calc.at:1340: cat stderr +stderr: +input: + | error +./calc.at:1338: $PREPARSER ./calc input +stderr: +stderr: + | (# + 1) = 1111 +./calc.at:1336: $PREPARSER ./calc input +input: +1.1: syntax error +./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token ')' (1.2: ) +1.2: syntax error +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token "number" (1.7: 1) +Shifting token "number" (1.7: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.7: 1) +-> $$ = nterm exp (1.7: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token "number" (1.11: 1) +Shifting token "number" (1.11: 1) +Entering state 1 +Stack now 0 8 21 4 12 21 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 30 +Stack now 0 8 21 4 12 21 30 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 105): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token "number" (1.15: 1) +Shifting token "number" (1.15: 1) +Entering state 1 +Stack now 0 8 21 4 12 21 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 30 +Stack now 0 8 21 4 12 21 30 +Reading a token +Next token is token '+' (1.17: ) +Reducing stack by rule 7 (line 105): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error +Error: popping token '+' (1.17: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.7-15: 3) +Stack now 0 8 21 4 +Shifting token error (1.7-18: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 126): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.20: ) +Reducing stack by rule 7 (line 105): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token '*' (1.23: ) +1.23: syntax error +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) +Error: popping token error (1.23: ) +Stack now 0 8 21 4 +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Error: popping token error (1.23: ) +Stack now 0 8 21 4 +Shifting token error (1.23-25: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Error: popping token error (1.23-25: ) +Stack now 0 8 21 4 +Shifting token error (1.23-27: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 126): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.30: ) +Reducing stack by rule 7 (line 105): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token "number" (1.33: 1) +Shifting token "number" (1.33: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 22 +Stack now 0 8 21 4 12 22 +Reading a token +Next token is token "number" (1.37: 2) +Shifting token "number" (1.37: 2) +Entering state 1 +Stack now 0 8 21 4 12 22 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 31 +Stack now 0 8 21 4 12 22 31 +Reading a token +Next token is token '*' (1.39: ) +Reducing stack by rule 9 (line 107): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 22 +Stack now 0 8 21 4 12 22 +Reading a token +Next token is token '*' (1.41: ) +1.41: syntax error +Error: popping token '*' (1.39: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.33-37: 2) +Stack now 0 8 21 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) +Error: popping token error (1.33-41: ) +Stack now 0 8 21 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 126): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.44: ) +Reducing stack by rule 7 (line 105): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token "number" (1.46: 1) +Shifting token "number" (1.46: 1) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.46: 1) +-> $$ = nterm exp (1.46: 1) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.47-2.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) + | error +./calc.at:1340: $PREPARSER ./calc input +stderr: +./calc.at:1334: cat stderr +syntax error: invalid character: '#' +======== Testing with C++ standard flags: '' +stderr: +./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +syntax error +./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.1: syntax error +./calc.at:1337: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +stderr: +stderr: + | (# + 1) = 1111 +./calc.at:1334: $PREPARSER ./calc input +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +syntax error: invalid character: '#' +syntax error +stderr: +./calc.at:1338: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +syntax error: invalid character: '#' +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Next token is token "invalid token" (1.1: ) +Error: discarding token "invalid token" (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '+' (1.1: ) +Error: discarding token '+' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token "number" (1.1: 1) +Error: discarding token "number" (1.1: 1) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token "number" (1.1: 1111) +Shifting token "number" (1.1: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.1: ) +Reducing stack by rule 6 (line 82): + $1 = nterm exp (1.1: 1111) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 1111) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token "end of input" (1.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) +./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1337: cat stderr +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +syntax error: invalid character: '#' +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Next token is token "invalid token" (1.1: ) +Error: discarding token "invalid token" (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '+' (1.1: ) +Error: discarding token '+' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token "number" (1.1: 1) +Error: discarding token "number" (1.1: 1) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token "number" (1.1: 1111) +Shifting token "number" (1.1: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.1: ) +Reducing stack by rule 6 (line 82): + $1 = nterm exp (1.1: 1111) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 1111) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token "end of input" (1.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) +./calc.at:1340: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1336: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +./calc.at:1338: cat stderr + | (!!) + (1 2) = 1 +./calc.at:1337: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Stack now 0 4 5 +Reading a token +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 16 +Stack now 0 4 5 16 +Reducing stack by rule 16 (line 128): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Stack now 0 4 +Shifting token error (1.2-3: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) +Entering state 8 +Stack now 0 8 Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) @@ -24092,12 +25070,27 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1334: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (- *) + (1 2) = 1 -./calc.at:1334: cat stderr -./calc.at:1336: $PREPARSER ./calc input +./calc.at:1340: cat stderr +./calc.at:1336: cat stderr +input: + | 1 = 2 = 3 +./calc.at:1338: $PREPARSER ./calc input stderr: stderr: +stderr: +1.7: syntax error +./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -24238,18 +25231,20 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -syntax error -syntax error -error: 2222 != 1 -./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -syntax error - | 1 + 2 * 3 + !* ++ +stdout: + | 1 = 2 = 3 +./types.at:139: ./check +input: +./calc.at:1340: $PREPARSER ./calc input stderr: -./calc.at:1334: $PREPARSER ./calc input -syntax error +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y + | (1 + # + 1) = 1111 +stderr: +./calc.at:1336: $PREPARSER ./calc input +1.7: syntax error +./calc.at:1334: cat stderr syntax error -error: 2222 != 1 ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -24261,89 +25256,149 @@ }eg ' expout || exit 77 stderr: +./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error: invalid character: '#' +./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1338: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +syntax error +input: +./calc.at:1337: cat stderr +stderr: + | (1 + # + 1) = 1111 +./calc.at:1334: $PREPARSER ./calc input +syntax error: invalid character: '#' +stderr: +./calc.at:1338: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 -Stack now 0 1 +Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 +Entering state 12 +Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 -Stack now 0 8 21 +Stack now 0 4 12 21 Reading a token -Next token is token "number" (1.1: 2) -Shifting token "number" (1.1: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 2) --> $$ = nterm exp (1.1: 2) -Entering state 30 -Stack now 0 8 21 30 +syntax error: invalid character: '#' +Error: popping token '+' (1.1: ) +Stack now 0 4 12 +Error: popping nterm exp (1.1: 1) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Next token is token "invalid token" (1.1: ) +Error: discarding token "invalid token" (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) -Entering state 22 -Stack now 0 8 21 30 22 +Next token is token '+' (1.1: ) +Error: discarding token '+' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token "number" (1.1: 3) -Shifting token "number" (1.1: 3) +Next token is token "number" (1.1: 1) +Error: discarding token "number" (1.1: 1) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token "number" (1.1: 1111) +Shifting token "number" (1.1: 1111) Entering state 1 -Stack now 0 8 21 30 22 1 +Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 3) --> $$ = nterm exp (1.1: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 + $1 = token "number" (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) +Entering state 28 +Stack now 0 8 19 28 Reading a token -Next token is token '+' (1.1: ) -Reducing stack by rule 9 (line 100): - $1 = nterm exp (1.1: 2) - $2 = token '*' (1.1: ) - $3 = nterm exp (1.1: 3) --> $$ = nterm exp (1.1: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 6) --> $$ = nterm exp (1.1: 7) +Next token is token '\n' (1.1: ) +Reducing stack by rule 6 (line 82): + $1 = nterm exp (1.1: 1111) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.1: ) -Shifting token '!' (1.1: ) -Entering state 5 -Stack now 0 8 21 5 +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 1111) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) -Entering state 15 -Stack now 0 8 21 5 15 -Reducing stack by rule 19 (line 124): - $1 = token '!' (1.1: ) - $2 = token '*' (1.1: ) -memory exhausted -Stack now 0 8 21 -Cleanup: popping token '+' (1.1: ) -Cleanup: popping nterm exp (1.1: 7) +Now at end of input. +Shifting token "end of input" (1.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) +input: ./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS + | (- *) + (1 2) = 1 +./calc.at:1337: $PREPARSER ./calc input +input: ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -24354,153 +25409,125 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1338: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1340: cat stderr +stderr: +stderr: + | + | +1 +./calc.at:1338: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 -Stack now 0 1 +Stack now 0 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 +Entering state 12 +Stack now 0 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 -Stack now 0 8 21 +Stack now 0 4 12 21 Reading a token -Next token is token "number" (1.1: 2) -Shifting token "number" (1.1: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 2) --> $$ = nterm exp (1.1: 2) -Entering state 30 -Stack now 0 8 21 30 +syntax error: invalid character: '#' +Error: popping token '+' (1.1: ) +Stack now 0 4 12 +Error: popping nterm exp (1.1: 1) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Next token is token "invalid token" (1.1: ) +Error: discarding token "invalid token" (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) -Entering state 22 -Stack now 0 8 21 30 22 +Next token is token '+' (1.1: ) +Error: discarding token '+' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token "number" (1.1: 3) -Shifting token "number" (1.1: 3) +Next token is token "number" (1.1: 1) +Error: discarding token "number" (1.1: 1) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token "number" (1.1: 1111) +Shifting token "number" (1.1: 1111) Entering state 1 -Stack now 0 8 21 30 22 1 +Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 3) --> $$ = nterm exp (1.1: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 + $1 = token "number" (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) +Entering state 28 +Stack now 0 8 19 28 Reading a token -Next token is token '+' (1.1: ) -Reducing stack by rule 9 (line 100): - $1 = nterm exp (1.1: 2) - $2 = token '*' (1.1: ) - $3 = nterm exp (1.1: 3) --> $$ = nterm exp (1.1: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 6) --> $$ = nterm exp (1.1: 7) +Next token is token '\n' (1.1: ) +Reducing stack by rule 6 (line 82): + $1 = nterm exp (1.1: 1111) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.1: ) -Shifting token '!' (1.1: ) -Entering state 5 -Stack now 0 8 21 5 +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 1111) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) -Entering state 15 -Stack now 0 8 21 5 15 -Reducing stack by rule 19 (line 124): - $1 = token '!' (1.1: ) - $2 = token '*' (1.1: ) -memory exhausted -Stack now 0 8 21 -Cleanup: popping token '+' (1.1: ) -Cleanup: popping nterm exp (1.1: 7) -./calc.at:1336: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1341: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1338: cat stderr -input: - | error -./calc.at:1340: $PREPARSER ./calc input -stderr: -syntax error -./calc.at:1341: cat stderr -./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1337: cat stderr -./calc.at:1334: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -syntax error -input: - | error -./calc.at:1336: cat stderr -./calc.at:1338: $PREPARSER ./calc input -input: -stderr: -1.1: syntax error -./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (- *) + (1 2) = 1 -./calc.at:1337: $PREPARSER ./calc input -stderr: -./calc.at:1334: cat stderr -1.1: syntax error -stderr: +Now at end of input. +Shifting token "end of input" (1.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Stack now 0 @@ -24649,12 +25676,9 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -input: -input: ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1//2 - | (* *) + (*) + (*) -./calc.at:1338: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -24664,9 +25688,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1336: $PREPARSER ./calc input -./calc.at:1341: $PREPARSER ./calc input -stderr: +2.1: syntax error +./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 @@ -24816,15 +25839,9 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -syntax error -syntax error -syntax error -./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1338: cat stderr +./calc.at:1340: cat stderr stderr: -syntax error -syntax error -syntax error +2.1: syntax error ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -24836,137 +25853,8 @@ }eg ' expout || exit 77 input: -stderr: -syntax error -./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (#) + (#) = 2222 -./calc.at:1334: $PREPARSER ./calc input -stderr: -stderr: -syntax error -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -syntax error: invalid character: '#' -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Next token is token "invalid token" (1.1: ) -Error: discarding token "invalid token" (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -syntax error: invalid character: '#' -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token "invalid token" (1.1: ) -Error: discarding token "invalid token" (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1111) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.1: 2222) -Shifting token "number" (1.1: 2222) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 2222) --> $$ = nterm exp (1.1: 2222) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 6 (line 82): - $1 = nterm exp (1.1: 2222) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 2222) --> $$ = nterm exp (1.1: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 2222) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) -./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1340: "$PERL" -pi -e 'use strict; +./calc.at:1336: cat stderr +./calc.at:1334: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -24976,9 +25864,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1337: cat stderr + | + | +1 +./calc.at:1340: $PREPARSER ./calc input stderr: -./calc.at:1336: "$PERL" -pi -e 'use strict; +./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -24988,156 +25878,27 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -syntax error: invalid character: '#' -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Next token is token "invalid token" (1.1: ) -Error: discarding token "invalid token" (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -syntax error: invalid character: '#' -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token "invalid token" (1.1: ) -Error: discarding token "invalid token" (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1111) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.1: 2222) -Shifting token "number" (1.1: 2222) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 2222) --> $$ = nterm exp (1.1: 2222) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 6 (line 82): - $1 = nterm exp (1.1: 2222) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 2222) --> $$ = nterm exp (1.1: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 2222) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) +syntax error +./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: - | 1 = 2 = 3 + | (1 + 1) / (1 - 1) +./calc.at:1336: $PREPARSER ./calc input stderr: -stdout: -./calc.at:1338: $PREPARSER ./calc input -./types.at:139: $PREPARSER ./test stderr: +./calc.at:1337: cat stderr +./calc.at:1334: cat stderr +syntax error +error: null divisor +./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1338: cat stderr input: -stderr: -./calc.at:1341: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.7: syntax error | (* *) + (*) + (*) -./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: $PREPARSER ./calc input -./calc.at:1336: cat stderr stderr: -1.7: syntax error +error: null divisor +input: stderr: -./calc.at:1340: cat stderr -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1338: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Stack now 0 @@ -25289,20 +26050,14 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) + | (1 + 1) / (1 - 1) +./calc.at:1334: $PREPARSER ./calc input ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -input: -./calc.at:1334: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1338: "$PERL" -pi -e 'use strict; +1.1: syntax error +stderr: +./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -25312,6 +26067,150 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +stderr: +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 4 12 21 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 30 +Stack now 0 4 12 21 30 +Reading a token +Next token is token ')' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1) +-> $$ = nterm exp (1.1: 2) +Entering state 12 +Stack now 0 4 12 +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 27 +Stack now 0 4 12 27 +Reducing stack by rule 13 (line 118): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.1: 2) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 2) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '/' (1.1: ) +Shifting token '/' (1.1: ) +Entering state 23 +Stack now 0 8 23 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 8 23 4 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 8 23 4 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 +Stack now 0 8 23 4 12 +Reading a token +Next token is token '-' (1.1: ) +Shifting token '-' (1.1: ) +Entering state 20 +Stack now 0 8 23 4 12 20 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 8 23 4 12 20 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 29 +Stack now 0 8 23 4 12 20 29 +Reading a token +Next token is token ')' (1.1: ) +Reducing stack by rule 8 (line 99): + $1 = nterm exp (1.1: 1) + $2 = token '-' (1.1: ) + $3 = nterm exp (1.1: 1) +-> $$ = nterm exp (1.1: 0) +Entering state 12 +Stack now 0 8 23 4 12 +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 27 +Stack now 0 8 23 4 12 27 +Reducing stack by rule 13 (line 118): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.1: 0) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 0) +Entering state 32 +Stack now 0 8 23 32 +Reading a token +Next token is token '\n' (1.1: ) +Reducing stack by rule 10 (line 101): + $1 = nterm exp (1.1: 2) + $2 = token '/' (1.1: ) + $3 = nterm exp (1.1: 0) +error: null divisor +-> $$ = nterm exp (1.1: 2) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 2) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token "end of input" (1.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) +./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -25463,63 +26362,9 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | 1 = 2 = 3 -input: -./calc.at:1340: $PREPARSER ./calc input - | 1 + 2 * 3 + !+ ++ -./calc.at:1341: cat stderr -./calc.at:1336: $PREPARSER ./calc input -447. types.at:139: ok -stderr: -stderr: -./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error -./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | error -stderr: -./calc.at:1341: $PREPARSER ./calc input -./calc.at:1338: cat stderr -syntax error -stderr: -syntax error -./calc.at:1337: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1336: $EGREP -c -v 'Return for a new token:|LAC:' stderr -stderr: -input: -syntax error -./calc.at:1334: cat stderr -./calc.at:1340: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | - | +1 -./calc.at:1338: $PREPARSER ./calc input +1.1: syntax error stderr: -2.1: syntax error -input: -./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1340: cat stderr -input: -./calc.at:1341: "$PERL" -pi -e 'use strict; +./calc.at:1336: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -25529,19 +26374,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: - - | (1 + #) = 1111 - | 1 + 2 * 3 + !- ++ -stdout: -stderr: -./calc.at:1336: $PREPARSER ./calc input -./calc.at:1337: cat stderr -./calc.at:1334: $PREPARSER ./calc input -2.1: syntax error -./types.at:139: $PREPARSER ./test -input: -stderr: Starting parse Entering state 0 Stack now 0 @@ -25566,162 +26398,98 @@ Entering state 21 Stack now 0 4 12 21 Reading a token -syntax error: invalid character: '#' -Error: popping token '+' (1.1: ) -Stack now 0 4 12 -Error: popping nterm exp (1.1: 1) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Next token is token "invalid token" (1.1: ) -Error: discarding token "invalid token" (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 4 12 21 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 30 +Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1) +-> $$ = nterm exp (1.1: 2) +Entering state 12 +Stack now 0 4 12 +Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 119): +Entering state 27 +Stack now 0 4 12 27 +Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) - $2 = token error (1.1: ) + $2 = nterm exp (1.1: 2) $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.1: 1111) -Shifting token "number" (1.1: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1111) --> $$ = nterm exp (1.1: 1111) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 6 (line 82): - $1 = nterm exp (1.1: 1111) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 1111) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Stack now 0 6 Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) -input: -./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: - | 1 + 2 * 3 + !+ ++ -./calc.at:1337: $PREPARSER ./calc input - | - | +1 -stderr: -Starting parse -Entering state 0 -Stack now 0 +Next token is token '/' (1.1: ) +Shifting token '/' (1.1: ) +Entering state 23 +Stack now 0 8 23 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 -Stack now 0 4 +Stack now 0 8 23 4 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 -Stack now 0 4 1 +Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 -Stack now 0 4 12 +Stack now 0 8 23 4 12 Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 4 12 21 +Next token is token '-' (1.1: ) +Shifting token '-' (1.1: ) +Entering state 20 +Stack now 0 8 23 4 12 20 Reading a token -syntax error: invalid character: '#' -Error: popping token '+' (1.1: ) -Stack now 0 4 12 -Error: popping nterm exp (1.1: 1) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Next token is token "invalid token" (1.1: ) -Error: discarding token "invalid token" (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 8 23 4 12 20 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 29 +Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.1: ) +Reducing stack by rule 8 (line 99): + $1 = nterm exp (1.1: 1) + $2 = token '-' (1.1: ) + $3 = nterm exp (1.1: 1) +-> $$ = nterm exp (1.1: 0) +Entering state 12 +Stack now 0 8 23 4 12 +Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 119): +Entering state 27 +Stack now 0 8 23 4 12 27 +Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) - $2 = token error (1.1: ) + $2 = nterm exp (1.1: 0) $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.1: 1111) -Shifting token "number" (1.1: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1111) --> $$ = nterm exp (1.1: 1111) -Entering state 28 -Stack now 0 8 19 28 +-> $$ = nterm exp (1.1: 0) +Entering state 32 +Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.1: ) -Reducing stack by rule 6 (line 82): - $1 = nterm exp (1.1: 1111) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 1111) +Reducing stack by rule 10 (line 101): + $1 = nterm exp (1.1: 2) + $2 = token '/' (1.1: ) + $3 = nterm exp (1.1: 0) +error: null divisor +-> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) @@ -25729,7 +26497,7 @@ Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 1111) + $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 @@ -25747,8 +26515,52 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) -./calc.at:1340: $PREPARSER ./calc input +./calc.at:1337: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1340: cat stderr +./calc.at:1338: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1340: $PREPARSER ./calc /dev/null +./calc.at:1336: cat stderr +stderr: +syntax error +./calc.at:1337: cat stderr +./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +471. calc.at:1336: ok +./calc.at:1334: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: +syntax error +./calc.at:1338: cat stderr +input: + | 1 + 2 * 3 + !+ ++ +./calc.at:1337: $PREPARSER ./calc input +stderr: +./calc.at:1334: cat stderr Starting parse Entering state 0 Stack now 0 @@ -25830,10 +26642,22 @@ Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +470. calc.at:1334: ok +./calc.at:1340: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1338: $PREPARSER ./calc input + stderr: -stderr: -syntax error -./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -25915,59 +26739,29 @@ Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1337: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1341: cat stderr stderr: -./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1334: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 +./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1338: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error -input: -477. calc.at:1343: testing Calculator parse.error=detailed ... -input: -./calc.at:1343: mv calc.y.tmp calc.y +./calc.at:1340: cat stderr +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 +input: | 1 + 2 * 3 + !- ++ ./calc.at:1337: $PREPARSER ./calc input - | 1 = 2 = 3 -./calc.at:1341: $PREPARSER ./calc input -./calc.at:1343: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -======== Testing with C++ standard flags: '' -./calc.at:1334: cat stderr -stderr: -./calc.at:1338: cat stderr +475. calc.at:1341: testing Calculator %verbose ... stderr: -./calc.at:1336: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error -./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1341: mv calc.y.tmp calc.y + +input: Starting parse Entering state 0 Stack now 0 @@ -26048,18 +26842,11 @@ Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1338: $PREPARSER ./calc /dev/null -input: +./calc.at:1341: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: - | (# + 1) = 1111 -syntax error -./calc.at:1334: $PREPARSER ./calc input -1.1: syntax error -./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1340: "$PERL" -pi -e 'use strict; +./calc.at:1340: $PREPARSER ./calc input +./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -26070,103 +26857,7 @@ }eg ' expout || exit 77 stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -syntax error: invalid character: '#' -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Next token is token "invalid token" (1.1: ) -Error: discarding token "invalid token" (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.1: ) -Error: discarding token '+' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token "number" (1.1: 1) -Error: discarding token "number" (1.1: 1) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.1: 1111) -Shifting token "number" (1.1: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1111) --> $$ = nterm exp (1.1: 1111) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 6 (line 82): - $1 = nterm exp (1.1: 1111) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 1111) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) stderr: -./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -26247,211 +26938,28 @@ Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -1.1: syntax error -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -syntax error: invalid character: '#' -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Next token is token "invalid token" (1.1: ) -Error: discarding token "invalid token" (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.1: ) -Error: discarding token '+' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token "number" (1.1: 1) -Error: discarding token "number" (1.1: 1) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.1: 1111) -Shifting token "number" (1.1: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1111) --> $$ = nterm exp (1.1: 1111) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 6 (line 82): - $1 = nterm exp (1.1: 1111) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 1111) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./calc.at:1341: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1338: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1336: cat stderr -stderr: -./calc.at:1340: cat stderr -./calc.at:1341: cat stderr -./calc.at:1340: $PREPARSER ./calc /dev/null -input: - | 1 + 2 * 3 + !* ++ -stdout: -./calc.at:1336: $PREPARSER ./calc input -stderr: -./calc.at:1342: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -stderr: syntax error -memory exhausted -input: +syntax error +syntax error +syntax error +error: 4444 != 1 ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1334: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1343: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS -./calc.at:1342: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c +476. calc.at:1342: testing Calculator %yacc ... +./calc.at:1342: + if "$POSIXLY_CORRECT_IS_EXPORTED"; then + sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y + else + mv calc.y.tmp calc.y + fi + -./calc.at:1338: cat stderr -memory exhausted - | - | +1 -input: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -input: -./calc.at:1342: $PREPARSER ./calc input -./calc.at:1341: $PREPARSER ./calc input stderr: syntax error -./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1336: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -stderr: -./calc.at:1338: $PREPARSER ./calc input syntax error -stderr: -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 -./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1336: cat stderr +syntax error +syntax error +error: 4444 != 1 +./calc.at:1338: cat stderr ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -26462,28 +26970,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1334: cat stderr -stderr: -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 -stderr: -./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1341: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error +./calc.at:1342: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +./calc.at:1341: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +input: + | (!!) + (1 2) = 1 +./calc.at:1338: $PREPARSER ./calc input stderr: -./calc.at:1338: "$PERL" -pi -e 'use strict; +1.11: syntax error +1.1-16: error: 2222 != 1 +./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -26493,37 +26988,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -./calc.at:1342: $EGREP -c -v 'Return for a new token:|LAC:' stderr - | (#) + (#) = 2222 +./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1337: cat stderr -./calc.at:1336: $PREPARSER ./calc input -stderr: -syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1341: cat stderr -input: stderr: +1.11: syntax error +1.1-16: error: 2222 != 1 input: -input: - | 1 2 -syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1342: $PREPARSER ./calc input -./calc.at:1341: $PREPARSER ./calc /dev/null -stderr: - | (1 + # + 1) = 1111 -stderr: -stderr: -./calc.at:1338: cat stderr -stdout: +./calc.at:1340: cat stderr | 1 + 2 * 3 + !* ++ -./calc.at:1337: $PREPARSER ./calc input -syntax error -syntax error -./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1340: "$PERL" -pi -e 'use strict; +./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -26533,13 +27006,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: ./check -./calc.at:1334: $PREPARSER ./calc input -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -stderr: +./calc.at:1337: $PREPARSER ./calc input stderr: input: +./calc.at:1342: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS Starting parse Entering state 0 Stack now 0 @@ -26621,18 +27091,15 @@ Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) + | (!!) + (1 2) = 1 +./calc.at:1340: $PREPARSER ./calc input ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1338: cat stderr +stderr: syntax error -./calc.at:1336: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +error: 2222 != 1 +./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: stderr: stderr: Starting parse @@ -26717,139 +27184,14 @@ Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) syntax error - | (!!) + (1 2) = 1 -stderr: +error: 2222 != 1 + | (- *) + (1 2) = 1 ./calc.at:1338: $PREPARSER ./calc input stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 4 12 21 -Reading a token -syntax error: invalid character: '#' -Error: popping token '+' (1.1: ) -Stack now 0 4 12 -Error: popping nterm exp (1.1: 1) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Next token is token "invalid token" (1.1: ) -Error: discarding token "invalid token" (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.1: ) -Error: discarding token '+' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token "number" (1.1: 1) -Error: discarding token "number" (1.1: 1) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.1: 1111) -Shifting token "number" (1.1: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1111) --> $$ = nterm exp (1.1: 1111) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 6 (line 82): - $1 = nterm exp (1.1: 1111) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 1111) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) -./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.11: syntax error -1.1-16: error: 2222 != 1 +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1340: cat stderr -./calc.at:1341: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -26860,139 +27202,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -stderr: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1340: $PREPARSER ./calc input -./calc.at:1342: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 4 12 21 -Reading a token -syntax error: invalid character: '#' -Error: popping token '+' (1.1: ) -Stack now 0 4 12 -Error: popping nterm exp (1.1: 1) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Next token is token "invalid token" (1.1: ) -Error: discarding token "invalid token" (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.1: ) -Error: discarding token '+' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token "number" (1.1: 1) -Error: discarding token "number" (1.1: 1) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.1: 1111) -Shifting token "number" (1.1: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1111) --> $$ = nterm exp (1.1: 1111) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 6 (line 82): - $1 = nterm exp (1.1: 1111) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 1111) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) stderr: -1.11: syntax error -1.1-16: error: 2222 != 1 -./calc.at:1341: cat stderr -./calc.at:1338: "$PERL" -pi -e 'use strict; +./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -27002,23 +27213,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 stderr: -./calc.at:1342: cat stderr -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 -input: -./calc.at:1336: cat stderr - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1341: $PREPARSER ./calc input +stdout: ./calc.at:1337: cat stderr +./types.at:139: $PREPARSER ./test stderr: -./calc.at:1338: cat stderr -input: -./calc.at:1334: "$PERL" -pi -e 'use strict; +./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -27028,38 +27231,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1//2 -stderr: -./calc.at:1342: $PREPARSER ./calc input -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 -input: -stderr: -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 - | (1 + #) = 1111 -syntax error -./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1336: $PREPARSER ./calc input input: -./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1340: cat stderr | (#) + (#) = 2222 ./calc.at:1337: $PREPARSER ./calc input +======== Testing with C++ standard flags: '' stderr: -stderr: -syntax error - | (- *) + (1 2) = 1 -./calc.at:1338: $PREPARSER ./calc input -stderr: -stderr: +input: Starting parse Entering state 0 Stack now 0 @@ -27181,31 +27360,14 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: +./calc.at:1338: cat stderr ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 -syntax error: invalid character: '#' -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 -./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS + | (- *) + (1 2) = 1 +./calc.at:1340: $PREPARSER ./calc input stderr: -./calc.at:1340: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 stderr: +input: Starting parse Entering state 0 Stack now 0 @@ -27327,21 +27489,22 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 +syntax error +syntax error +error: 2222 != 1 +./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (* *) + (*) + (*) +./calc.at:1338: $PREPARSER ./calc input +stderr: +stderr: +1.2: syntax error +1.10: syntax error +1.16: syntax error +./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +syntax error +error: 2222 != 1 stderr: -./calc.at:1334: cat stderr -./calc.at:1342: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -27352,8 +27515,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1340: cat stderr -syntax error: invalid character: '#' +1.2: syntax error +1.10: syntax error +1.16: syntax error +stderr: +stdout: +./calc.at:1341: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -27364,8 +27531,19 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -./calc.at:1341: "$PERL" -pi -e 'use strict; +./calc.at:1341: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c + +./calc.at:1337: cat stderr +./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -27375,26 +27553,35 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (!!) + (1 2) = 1 -./calc.at:1340: $PREPARSER ./calc input -./calc.at:1337: cat stderr -stderr: input: -./calc.at:1342: cat stderr -syntax error -error: 2222 != 1 -./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1341: $PREPARSER ./calc input +./calc.at:1338: cat stderr +stderr: +stderr: input: +./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: | (1 + #) = 1111 ./calc.at:1337: $PREPARSER ./calc input +./calc.at:1340: cat stderr stderr: -./calc.at:1338: cat stderr -syntax error -error: 2222 != 1 - | (1 + 1) / (1 - 1) -stderr: -./calc.at:1334: $PREPARSER ./calc input +./types.at:139: ./check input: +stderr: +stderr: Starting parse Entering state 0 Stack now 0 @@ -27494,152 +27681,30 @@ Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | error -./calc.at:1342: $PREPARSER ./calc input +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y + | 1 + 2 * 3 + !+ ++ +stdout: +./calc.at:1338: $PREPARSER ./calc input +./calc.at:1342: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +input: +./calc.at:1341: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 4 12 21 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 4 12 21 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 30 -Stack now 0 4 12 21 30 -Reading a token -Next token is token ')' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1) --> $$ = nterm exp (1.1: 2) -Entering state 12 -Stack now 0 4 12 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 27 -Stack now 0 4 12 27 -Reducing stack by rule 13 (line 118): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.1: 2) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 2) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.1: ) -Shifting token '/' (1.1: ) -Entering state 23 -Stack now 0 8 23 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 23 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 23 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 8 23 4 12 -Reading a token -Next token is token '-' (1.1: ) -Shifting token '-' (1.1: ) -Entering state 20 -Stack now 0 8 23 4 12 20 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 23 4 12 20 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 29 -Stack now 0 8 23 4 12 20 29 -Reading a token -Next token is token ')' (1.1: ) -Reducing stack by rule 8 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '-' (1.1: ) - $3 = nterm exp (1.1: 1) --> $$ = nterm exp (1.1: 0) -Entering state 12 -Stack now 0 8 23 4 12 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 27 -Stack now 0 8 23 4 12 27 -Reducing stack by rule 13 (line 118): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.1: 0) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 0) -Entering state 32 -Stack now 0 8 23 32 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 10 (line 101): - $1 = nterm exp (1.1: 2) - $2 = token '/' (1.1: ) - $3 = nterm exp (1.1: 0) -error: null divisor --> $$ = nterm exp (1.1: 2) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 2) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) + | (* *) + (*) + (*) +./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1340: $PREPARSER ./calc input stderr: +./calc.at:1342: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c + Starting parse Entering state 0 Stack now 0 @@ -27738,23 +27803,31 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +input: +syntax error syntax error +syntax error +./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: + | 1 2 +./calc.at:1341: $PREPARSER ./calc input +./calc.at:1338: $EGREP -c -v 'Return for a new token:|LAC:' stderr +stderr: input: -./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (* *) + (*) + (*) -./calc.at:1338: $PREPARSER ./calc input -./calc.at:1340: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1334: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1336: "$PERL" -pi -e 'use strict; + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -27764,173 +27837,30 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1342: $PREPARSER ./calc input stderr: syntax error -./calc.at:1337: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 stderr: -./calc.at:1341: cat stderr -1.2: syntax error -1.10: syntax error -1.16: syntax error -./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +syntax error +syntax error +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +input: + | 1 + 2 * 3 + !- ++ +./calc.at:1338: $PREPARSER ./calc input +./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: ./calc.at:1337: cat stderr -1.2: syntax error -1.10: syntax error -1.16: syntax error -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 4 12 21 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 4 12 21 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 30 -Stack now 0 4 12 21 30 -Reading a token -Next token is token ')' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1) --> $$ = nterm exp (1.1: 2) -Entering state 12 -Stack now 0 4 12 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 27 -Stack now 0 4 12 27 -Reducing stack by rule 13 (line 118): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.1: 2) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 2) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.1: ) -Shifting token '/' (1.1: ) -Entering state 23 -Stack now 0 8 23 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 23 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 23 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 8 23 4 12 -Reading a token -Next token is token '-' (1.1: ) -Shifting token '-' (1.1: ) -Entering state 20 -Stack now 0 8 23 4 12 20 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 23 4 12 20 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 29 -Stack now 0 8 23 4 12 20 29 -Reading a token -Next token is token ')' (1.1: ) -Reducing stack by rule 8 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '-' (1.1: ) - $3 = nterm exp (1.1: 1) --> $$ = nterm exp (1.1: 0) -Entering state 12 -Stack now 0 8 23 4 12 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 27 -Stack now 0 8 23 4 12 27 -Reducing stack by rule 13 (line 118): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.1: 0) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 0) -Entering state 32 -Stack now 0 8 23 32 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 10 (line 101): - $1 = nterm exp (1.1: 2) - $2 = token '/' (1.1: ) - $3 = nterm exp (1.1: 0) -error: null divisor --> $$ = nterm exp (1.1: 2) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 2) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) -./calc.at:1340: cat stderr -./calc.at:1342: "$PERL" -pi -e 'use strict; +syntax error +stderr: +./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1342: $EGREP -c -v 'Return for a new token:|LAC:' stderr +stderr: +input: + | (# + 1) = 1111 +./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -27940,11 +27870,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1337: $PREPARSER ./calc input input: -./calc.at:1336: cat stderr - | (!!) + (1 2) = 1 -./calc.at:1341: $PREPARSER ./calc input -./calc.at:1338: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -27954,16 +27883,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | (# + 1) = 1111 -stderr: -./calc.at:1337: $PREPARSER ./calc input -syntax error -error: 2222 != 1 -stderr: -./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1342: cat stderr + | 1 2 +./calc.at:1342: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -28059,12 +27980,22 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1338: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1338: cat stderr -stderr: syntax error -error: 2222 != 1 +stderr: +./calc.at:1340: cat stderr +./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -28160,30 +28091,14 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | (- *) + (1 2) = 1 -./calc.at:1340: $PREPARSER ./calc input +./calc.at:1341: cat stderr stderr: +syntax error +./calc.at:1338: cat stderr input: -./calc.at:1334: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -syntax error -syntax error -error: 2222 != 1 input: - | (# + 1) = 1111 -./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !+ ++ -./calc.at:1338: $PREPARSER ./calc input -./calc.at:1336: $PREPARSER ./calc input +./calc.at:1340: $PREPARSER ./calc input ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -28194,30 +28109,18 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1 = 2 = 3 -stderr: -./calc.at:1342: $PREPARSER ./calc input -stderr: + | 1//2 stderr: -syntax error: invalid character: '#' -./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1341: $PREPARSER ./calc input +./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +input: + | 1 + 2 * 3 + !* ++ +./calc.at:1338: $PREPARSER ./calc input syntax error -syntax error -error: 2222 != 1 -syntax error -./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: ./calc.at:1337: cat stderr -./calc.at:1338: $EGREP -c -v 'Return for a new token:|LAC:' stderr -stderr: -./calc.at:1334: cat stderr -stderr: -syntax error -syntax error: invalid character: '#' -input: -./calc.at:1341: "$PERL" -pi -e 'use strict; +./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -28227,14 +28130,22 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +stderr: +1.14: memory exhausted +stderr: +./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1340: $EGREP -c -v 'Return for a new token:|LAC:' stderr +stderr: +stderr: +1.14: memory exhausted +syntax error input: | (1 + # + 1) = 1111 ./calc.at:1337: $PREPARSER ./calc input - | 1 + 2 * 3 + !- ++ -./calc.at:1338: $PREPARSER ./calc input -stderr: +input: +./calc.at:1342: cat stderr stderr: -./calc.at:1342: "$PERL" -pi -e 'use strict; +./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -28358,11 +28269,15 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) + | 1 + 2 * 3 + !- ++ +./calc.at:1340: $PREPARSER ./calc input ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -470. calc.at:1334: ok stderr: -./calc.at:1341: cat stderr +input: +stderr: +./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1//2 +./calc.at:1342: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -28477,7 +28392,7 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1340: "$PERL" -pi -e 'use strict; +./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -28488,10 +28403,10 @@ }eg ' expout || exit 77 stderr: -stdout: -./types.at:139: $PREPARSER ./test -./calc.at:1342: cat stderr stderr: +syntax error +./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1338: cat stderr ./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -28504,12 +28419,10 @@ ' expout || exit 77 stderr: input: - | (- *) + (1 2) = 1 -./calc.at:1341: $PREPARSER ./calc input -./calc.at:1337: cat stderr -./calc.at:1340: cat stderr -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1336: "$PERL" -pi -e 'use strict; +./calc.at:1341: cat stderr +syntax error + | (#) + (#) = 2222 +./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -28519,20 +28432,16 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1338: $PREPARSER ./calc input stderr: +./calc.at:1337: cat stderr input: - -syntax error -syntax error -error: 2222 != 1 - | - | +1 -./calc.at:1342: $PREPARSER ./calc input -input: -448. types.at:139: ok -./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (* *) + (*) + (*) -./calc.at:1338: "$PERL" -pi -e 'use strict; +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' + | error +./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1341: $PREPARSER ./calc input +./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -28542,22 +28451,18 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1340: $PREPARSER ./calc input -input: -stderr: stderr: +input: +./calc.at:1340: cat stderr | (1 + 1) / (1 - 1) ./calc.at:1337: $PREPARSER ./calc input -syntax error -syntax error -error: 2222 != 1 stderr: syntax error -syntax error -syntax error +./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +input: Starting parse Entering state 0 Stack now 0 @@ -28701,8 +28606,20 @@ Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1337: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - -./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 + !* ++ +./calc.at:1342: cat stderr +./calc.at:1340: $PREPARSER ./calc input +syntax error +./calc.at:1338: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: Starting parse Entering state 0 @@ -28846,12 +28763,12 @@ Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: -syntax error -478. calc.at:1344: testing Calculator parse.error=verbose ... -./calc.at:1344: mv calc.y.tmp calc.y - -./calc.at:1336: cat stderr -./calc.at:1341: "$PERL" -pi -e 'use strict; +memory exhausted +./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +input: +memory exhausted +./calc.at:1337: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -28861,15 +28778,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1344: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -syntax error -syntax error -syntax error + | error ./calc.at:1338: cat stderr -input: - | (1 + # + 1) = 1111 -./calc.at:1336: $PREPARSER ./calc input -./calc.at:1337: "$PERL" -pi -e 'use strict; +./calc.at:1342: $PREPARSER ./calc input +stderr: +syntax error +./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -28879,16 +28793,13 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -stderr: -479. calc.at:1346: testing Calculator api.pure=full %locations ... -./calc.at:1341: cat stderr -syntax error: invalid character: '#' - | 1 + 2 * 3 + !* ++ -./calc.at:1346: mv calc.y.tmp calc.y - -./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1337: cat stderr + | (1 + #) = 1111 ./calc.at:1338: $PREPARSER ./calc input +stderr: +stderr: ./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -28899,11 +28810,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -./calc.at:1346: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -1.14: memory exhausted +1.6: syntax error: invalid character: '#' ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +472. calc.at:1337: ok +./calc.at:1341: cat stderr stderr: +1.6: syntax error: invalid character: '#' +./calc.at:1340: cat stderr +input: ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -28914,16 +28829,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -syntax error: invalid character: '#' -./calc.at:1340: cat stderr -stdout: -./calc.at:1343: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -stderr: -1.14: memory exhausted -./calc.at:1337: cat stderr -input: - | (* *) + (*) + (*) + | 1 = 2 = 3 ./calc.at:1341: $PREPARSER ./calc input ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} @@ -28935,38 +28841,39 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + input: -./calc.at:1342: cat stderr stderr: + | (#) + (#) = 2222 syntax error -syntax error -syntax error - | 1 + 2 * 3 + !+ ++ ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -472. calc.at:1337: ok ./calc.at:1340: $PREPARSER ./calc input -./calc.at:1342: $PREPARSER ./calc /dev/null stderr: stderr: -./calc.at:1343: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c - -syntax error -syntax error -syntax error -./calc.at:1344: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +syntax error: invalid character: '#' +syntax error: invalid character: '#' ./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +./calc.at:1342: cat stderr +./calc.at:1338: cat stderr +stderr: +syntax error: invalid character: '#' +syntax error: invalid character: '#' +input: +477. calc.at:1343: testing Calculator parse.error=detailed ... +./calc.at:1343: mv calc.y.tmp calc.y + +input: + | 1 = 2 = 3 +./calc.at:1343: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +./calc.at:1342: $PREPARSER ./calc input + | (# + 1) = 1111 +./calc.at:1338: $PREPARSER ./calc input stderr: syntax error -./calc.at:1336: "$PERL" -pi -e 'use strict; +./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -28976,10 +28883,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1338: cat stderr -input: -./calc.at:1341: "$PERL" -pi -e 'use strict; +stderr: +1.2: syntax error: invalid character: '#' +./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -28990,44 +28898,8 @@ }eg ' expout || exit 77 stderr: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1343: $PREPARSER ./calc input -stderr: -./calc.at:1340: $EGREP -c -v 'Return for a new token:|LAC:' stderr -syntax error -input: -stderr: - - | (#) + (#) = 2222 -./calc.at:1338: $PREPARSER ./calc input -./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1336: cat stderr -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -./calc.at:1346: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1341: cat stderr -input: 1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1343: $EGREP -c -v 'Return for a new token:|LAC:' stderr - | 1 + 2 * 3 + !- ++ -./calc.at:1340: $PREPARSER ./calc input ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -29038,7 +28910,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: +./calc.at:1343: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +input: +./calc.at:1340: cat stderr ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -29049,67 +28923,37 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | + | +1 +./calc.at:1341: $PREPARSER ./calc input stderr: +syntax error +./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1342: cat stderr input: - | (1 + 1) / (1 - 1) -./calc.at:1336: $PREPARSER ./calc input -input: -480. calc.at:1347: testing Calculator api.push-pull=both api.pure=full %locations ... -./calc.at:1347: mv calc.y.tmp calc.y - ./calc.at:1338: cat stderr -./calc.at:1342: cat stderr -stderr: -error: null divisor -./calc.at:1336: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 + 2 * 3 + !+ ++ -./calc.at:1341: $PREPARSER ./calc input stderr: - | 1 2 -error: null divisor -input: -./calc.at:1343: $PREPARSER ./calc input -./calc.at:1347: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | (1 + #) = 1111 -stderr: -./calc.at:1338: $PREPARSER ./calc input -syntax error, unexpected number -./calc.at:1340: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1340: $PREPARSER ./calc input +syntax error stderr: input: -stderr: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -1.6: syntax error: invalid character: '#' + | + | +1 +input: ./calc.at:1342: $PREPARSER ./calc input +syntax error: invalid character: '#' + | (1 + # + 1) = 1111 +./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1338: $PREPARSER ./calc input +stderr: stderr: -./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error, unexpected number stderr: -./calc.at:1340: cat stderr -./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error -syntax error -syntax error syntax error -error: 4444 != 1 ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: 1.6: syntax error: invalid character: '#' -stderr: -stderr: -./calc.at:1343: "$PERL" -pi -e 'use strict; +./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29119,20 +28963,17 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +syntax error: invalid character: '#' +stderr: +stderr: +stdout: +stderr: syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 -input: - | 1 + 2 * 3 + !* ++ -./calc.at:1341: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1340: $PREPARSER ./calc input -./calc.at:1343: cat stderr +1.6: syntax error: invalid character: '#' +./types.at:139: $PREPARSER ./test stderr: -memory exhausted -./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1336: "$PERL" -pi -e 'use strict; +./calc.at:1341: cat stderr +./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29152,14 +28993,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1341: $PREPARSER ./calc /dev/null stderr: -memory exhausted -input: - | 1//2 -./calc.at:1343: $PREPARSER ./calc input -stderr: -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -29170,45 +29007,32 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1336: cat stderr +./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +447. types.at:139: ./calc.at:1340: cat stderr ./calc.at:1338: cat stderr -input: + ok stderr: -./calc.at:1340: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | 1 + 2 * 3 + !- ++ +syntax error +input: input: -./calc.at:1341: $PREPARSER ./calc input - | (# + 1) = 1111 ./calc.at:1342: cat stderr + | (1 + 1) / (1 - 1) ./calc.at:1338: $PREPARSER ./calc input -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1347: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS + | (# + 1) = 1111 +./calc.at:1340: $PREPARSER ./calc input stderr: -471. calc.at:1336: ok stderr: -1.2: syntax error: invalid character: '#' -./calc.at:1340: cat stderr + +1.11-17: error: null divisor ./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (!!) + (1 2) = 1 -./calc.at:1342: $PREPARSER ./calc input -stderr: +./calc.at:1342: $PREPARSER ./calc /dev/null +syntax error: invalid character: '#' +./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -input: +syntax error +./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.2: syntax error: invalid character: '#' - | (#) + (#) = 2222 -./calc.at:1343: "$PERL" -pi -e 'use strict; +./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29218,21 +29042,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1340: $PREPARSER ./calc input -syntax error -error: 2222 != 1 -./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1343: cat stderr +1.11-17: error: null divisor stderr: stderr: -syntax error: invalid character: '#' -syntax error: invalid character: '#' syntax error -error: 2222 != 1 +syntax error: invalid character: '#' ./calc.at:1338: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -29243,19 +29057,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | error -./calc.at:1340: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1343: $PREPARSER ./calc input +./calc.at:1341: cat stderr +478. calc.at:1344: testing Calculator parse.error=verbose ... +./calc.at:1344: mv calc.y.tmp calc.y + +./calc.at:1344: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +./calc.at:1338: cat stderr ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -29266,16 +29073,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -syntax error, unexpected invalid token -./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1338: cat stderr -./calc.at:1340: cat stderr -stderr: -syntax error, unexpected invalid token -./calc.at:1342: cat stderr input: -./calc.at:1341: "$PERL" -pi -e 'use strict; +473. calc.at:1338: ok +./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29285,45 +29085,51 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (1 + #) = 1111 -./calc.at:1340: $PREPARSER ./calc input + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1341: $PREPARSER ./calc input stderr: +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 +./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1342: cat stderr input: -input: -syntax error: invalid character: '#' -./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (- *) + (1 2) = 1 - | (1 + # + 1) = 1111 + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1342: $PREPARSER ./calc input -./calc.at:1338: $PREPARSER ./calc input stderr: stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +./calc.at:1340: cat stderr syntax error syntax error -error: 2222 != 1 -syntax error: invalid character: '#' - +syntax error +syntax error +error: 4444 != 1 ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1343: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: +./calc.at:1344: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS syntax error syntax error -error: 2222 != 1 -./calc.at:1343: cat stderr +syntax error +syntax error +error: 4444 != 1 + +stderr: input: -./calc.at:1340: "$PERL" -pi -e 'use strict; +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 + | (1 + # + 1) = 1111 +./calc.at:1340: $PREPARSER ./calc input +479. calc.at:1346: testing Calculator api.pure=full %locations ... +./calc.at:1346: mv calc.y.tmp calc.y + +./calc.at:1346: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +stderr: +stderr: +./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29333,15 +29139,30 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +stdout: +syntax error: invalid character: '#' +./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1341: cat stderr - | 1 = 2 = 3 -./calc.at:1343: $PREPARSER ./calc input +input: +./types.at:139: $PREPARSER ./test + | (!!) + (1 2) = 1 +./calc.at:1341: $PREPARSER ./calc input stderr: -1.6: syntax error: invalid character: '#' stderr: -syntax error, unexpected '=' -./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1338: "$PERL" -pi -e 'use strict; +syntax error +error: 2222 != 1 +./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +syntax error: invalid character: '#' +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +./calc.at:1346: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +stderr: +syntax error +error: 2222 != 1 +./calc.at:1343: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29351,11 +29172,20 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -syntax error, unexpected '=' -481. calc.at:1348: testing Calculator parse.error=detailed %locations ... -input: -./calc.at:1342: "$PERL" -pi -e 'use strict; +======== Testing with C++ standard flags: '' +./calc.at:1343: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c + +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29365,16 +29195,23 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1 + 2 * 3 + !* ++ -./calc.at:1340: cat stderr -./calc.at:1341: $PREPARSER ./calc input -./calc.at:1348: mv calc.y.tmp calc.y - input: - | (# + 1) = 1111 -./calc.at:1348: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -./calc.at:1340: $PREPARSER ./calc input -./calc.at:1343: "$PERL" -pi -e 'use strict; + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1343: $PREPARSER ./calc input +./calc.at:1342: cat stderr +./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29386,43 +29223,54 @@ ' expout || exit 77 stderr: stderr: -memory exhausted -./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1341: cat stderr +stdout: +./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $PREPARSER ./test stderr: -./calc.at:1342: cat stderr -memory exhausted -./calc.at:1343: cat stderr -syntax error: invalid character: '#' -./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | (!!) + (1 2) = 1 +./calc.at:1342: $PREPARSER ./calc input stderr: -syntax error: invalid character: '#' +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1340: cat stderr input: +stderr: +./calc.at:1343: $EGREP -c -v 'Return for a new token:|LAC:' stderr + | (- *) + (1 2) = 1 +./calc.at:1341: $PREPARSER ./calc input +syntax error +error: 2222 != 1 +./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' input: -./calc.at:1338: cat stderr - | - | +1 +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS + | (1 + 1) / (1 - 1) +./calc.at:1340: $PREPARSER ./calc input +input: +stderr: + | 1 2 +stderr: ./calc.at:1343: $PREPARSER ./calc input stderr: - | (* *) + (*) + (*) -./calc.at:1342: $PREPARSER ./calc input -syntax error, unexpected '+' +syntax error +syntax error +error: 2222 != 1 +syntax error +error: 2222 != 1 +./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +error: null divisor stderr: +./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error, unexpected number ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: syntax error syntax error -syntax error -./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1341: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1340: "$PERL" -pi -e 'use strict; +error: 2222 != 1 +stderr: +./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29432,30 +29280,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | (1 + 1) / (1 - 1) -./calc.at:1338: $PREPARSER ./calc input -stderr: -stderr: -1.11-17: error: null divisor -./calc.at:1338: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error, unexpected '+' -stderr: -./calc.at:1348: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS -1.11-17: error: null divisor -./calc.at:1340: cat stderr -input: - | (1 + # + 1) = 1111 -./calc.at:1340: $PREPARSER ./calc input stderr: -syntax error: invalid character: '#' -./calc.at:1341: cat stderr +stdout: +error: null divisor +./types.at:139: ./check +syntax error, unexpected number +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./calc.at:1342: cat stderr stderr: -./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error -syntax error -syntax error -./calc.at:1338: "$PERL" -pi -e 'use strict; +./calc.at:1340: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29465,16 +29298,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | (#) + (#) = 2222 -./calc.at:1341: $PREPARSER ./calc input -stderr: -stderr: -stdout: -syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1343: "$PERL" -pi -e 'use strict; +./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29484,12 +29308,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: +stdout: ./calc.at:1346: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -syntax error: invalid character: '#' -stderr: -syntax error: invalid character: '#' -syntax error: invalid character: '#' ./calc.at:1346: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" @@ -29501,52 +29321,7 @@ || /\t/ )' calc.c -./calc.at:1338: cat stderr -./calc.at:1343: cat stderr -stderr: -input: -stdout: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1344: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -./calc.at:1346: $PREPARSER ./calc input -473. calc.at:1338: ok -stderr: -./calc.at:1344: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c - -./calc.at:1340: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1343: $PREPARSER ./calc /dev/null -./calc.at:1342: "$PERL" -pi -e 'use strict; +./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29556,21 +29331,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -./calc.at:1346: $EGREP -c -v 'Return for a new token:|LAC:' stderr -stderr: +./calc.at:1343: cat stderr input: -./calc.at:1341: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error, unexpected end of file | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -29584,64 +29346,55 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1340: cat stderr -stderr: -./calc.at:1344: $PREPARSER ./calc input -input: -syntax error, unexpected end of file -stderr: -./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 2 ./calc.at:1346: $PREPARSER ./calc input -input: -./calc.at:1341: cat stderr - | (1 + 1) / (1 - 1) -./calc.at:1342: cat stderr -./calc.at:1340: $PREPARSER ./calc input stderr: +input: stderr: +./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - -./calc.at:1344: $EGREP -c -v 'Return for a new token:|LAC:' stderr -error: null divisor -./calc.at:1340: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: +stdout: +./calc.at:1346: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: - | (1 + #) = 1111 -./calc.at:1341: $PREPARSER ./calc input + | 1 2 +./calc.at:1346: $PREPARSER ./calc input +./calc.at:1341: cat stderr stderr: 1.3: syntax error ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -error: null divisor -input: -stderr: - | 1 + 2 * 3 + !+ ++ -syntax error: invalid character: '#' + | (- *) + (1 2) = 1 ./calc.at:1342: $PREPARSER ./calc input -./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 2 -./calc.at:1344: $PREPARSER ./calc input +./types.at:139: ./check +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./calc.at:1340: cat stderr + | 1//2 +./calc.at:1343: $PREPARSER ./calc input stderr: -syntax error, unexpected number -./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: -./calc.at:1343: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 stderr: +input: +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.3: syntax error +syntax error +syntax error +error: 2222 != 1 + | (* *) + (*) + (*) ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1341: $PREPARSER ./calc input +474. calc.at:1340: ok stderr: stderr: -1.3: syntax error -syntax error, unexpected number +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +stderr: +syntax error +syntax error +error: 2222 != 1 +syntax error +syntax error +syntax error +./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -29652,9 +29405,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -syntax error: invalid character: '#' stderr: -./calc.at:1340: "$PERL" -pi -e 'use strict; +./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29664,17 +29416,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1343: cat stderr -482. calc.at:1350: testing Calculator parse.error=detailed %locations %header api.prefix={calc} %verbose %yacc ... -./calc.at:1350: - if "$POSIXLY_CORRECT_IS_EXPORTED"; then - sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y - else - mv calc.y.tmp calc.y - fi - - -./calc.at:1344: "$PERL" -pi -e 'use strict; +syntax error +syntax error +syntax error +./calc.at:1346: cat stderr +./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29684,13 +29430,17 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1342: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS + +stderr: +./calc.at:1343: cat stderr input: -./calc.at:1346: cat stderr - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1343: $PREPARSER ./calc input -./calc.at:1344: cat stderr -./calc.at:1350: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +stdout: + | 1//2 +./calc.at:1344: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +./calc.at:1346: $PREPARSER ./calc input +./calc.at:1342: cat stderr +stderr: ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -29702,38 +29452,8 @@ }eg ' expout || exit 77 input: -./calc.at:1340: cat stderr - | 1 + 2 * 3 + !- ++ -./calc.at:1342: $PREPARSER ./calc input -input: -stderr: -stderr: -input: -./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -error: 4444 != 1 -./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -474. calc.at:1340: ok - | 1//2 -./calc.at:1346: $PREPARSER ./calc input -stderr: -./calc.at:1341: cat stderr -stderr: 1.3: syntax error - | 1//2 -./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1344: $PREPARSER ./calc input -stderr: -stderr: -stdout: -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1347: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -stderr: -./calc.at:1347: "$PERL" -ne ' +./calc.at:1344: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. @@ -29744,27 +29464,17 @@ || /\t/ )' calc.c -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -stderr: -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -error: 4444 != 1 +./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | error input: -./calc.at:1342: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1343: $PREPARSER ./calc input stderr: -1.3: syntax error + | (* *) + (*) + (*) +./calc.at:1342: $PREPARSER ./calc input input: +stderr: +stderr: +syntax error, unexpected invalid token | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -29778,7 +29488,27 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -./calc.at:1343: "$PERL" -pi -e 'use strict; +syntax error +syntax error +syntax error +./calc.at:1344: $PREPARSER ./calc input +./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.3: syntax error +./calc.at:1341: cat stderr +480. calc.at:1347: testing Calculator api.push-pull=both api.pure=full %locations ... +./calc.at:1347: mv calc.y.tmp calc.y + +stderr: +./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1347: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +stderr: +stderr: +stderr: +syntax error +syntax error +syntax error +./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29788,15 +29518,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1342: cat stderr -./calc.at:1347: $PREPARSER ./calc input - -stderr: - | (# + 1) = 1111 +input: +syntax error, unexpected invalid token + | 1 + 2 * 3 + !+ ++ +./calc.at:1344: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1341: $PREPARSER ./calc input -./calc.at:1343: cat stderr stderr: -./calc.at:1346: "$PERL" -pi -e 'use strict; +./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1346: cat stderr +./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29807,7 +29537,10 @@ }eg ' expout || exit 77 input: -./calc.at:1344: "$PERL" -pi -e 'use strict; + | 1 2 +stderr: +./calc.at:1344: $PREPARSER ./calc input +./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29817,47 +29550,43 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -syntax error: invalid character: '#' -input: - | 1 + 2 * 3 + !* ++ - | (!!) + (1 2) = 1 -./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1343: $PREPARSER ./calc input -./calc.at:1344: cat stderr -./calc.at:1342: $PREPARSER ./calc input -./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1347: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +./calc.at:1341: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1343: cat stderr stderr: syntax error, unexpected number -error: 2222 != 1 -./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | error +./calc.at:1346: $PREPARSER ./calc input +./calc.at:1342: cat stderr +input: stderr: -memory exhausted -./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: stderr: -./calc.at:1346: cat stderr + | 1 = 2 = 3 +./calc.at:1343: $PREPARSER ./calc input syntax error, unexpected number -error: 2222 != 1 -483. calc.at:1351: testing Calculator parse.error=detailed %locations %header %name-prefix "calc" api.token.prefix={TOK_} %verbose %yacc ... -./calc.at:1351: - if "$POSIXLY_CORRECT_IS_EXPORTED"; then - sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y - else - mv calc.y.tmp calc.y - fi - - + | 1 + 2 * 3 + !- ++ stderr: -memory exhausted +1.1: syntax error +./calc.at:1341: $PREPARSER ./calc input +./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -syntax error: invalid character: '#' -./calc.at:1350: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS -./calc.at:1351: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +syntax error, unexpected '=' +./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: - | error -./calc.at:1344: $PREPARSER ./calc input +./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: + | 1 + 2 * 3 + !+ ++ stderr: -./calc.at:1343: "$PERL" -pi -e 'use strict; +./calc.at:1342: $PREPARSER ./calc input +stderr: +1.1: syntax error +stderr: +syntax error, unexpected '=' +./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29867,11 +29596,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -syntax error, unexpected invalid token -./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1347: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1342: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29881,9 +29607,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | error -./calc.at:1346: $PREPARSER ./calc input -./calc.at:1342: cat stderr +./calc.at:1344: cat stderr ./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -29894,29 +29618,58 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1343: cat stderr -stderr: -1.1: syntax error +./calc.at:1342: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1343: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 input: -./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (- *) + (1 2) = 1 +input: +./calc.at:1343: cat stderr +./calc.at:1341: cat stderr + | 1//2 + | 1 + 2 * 3 + !- ++ +./calc.at:1344: $PREPARSER ./calc input +./calc.at:1342: $PREPARSER ./calc input stderr: -./calc.at:1343: $PREPARSER ./calc input stderr: +./calc.at:1346: cat stderr +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -syntax error, unexpected invalid token - | (#) + (#) = 2222 -./calc.at:1342: $PREPARSER ./calc input +input: + | + | +1 +./calc.at:1343: $PREPARSER ./calc input input: stderr: -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected number -error: 2222 != 1 +stderr: + | 1 = 2 = 3 +stderr: +./calc.at:1346: $PREPARSER ./calc input +stderr: +syntax error, unexpected '+' +syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 + !* ++ +1.7: syntax error +./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1341: $PREPARSER ./calc input stderr: stderr: -1.1: syntax error -./calc.at:1341: cat stderr +memory exhausted +stderr: +./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.7: syntax error +syntax error, unexpected '+' +stderr: ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -29927,27 +29680,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1 2 -syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1347: $PREPARSER ./calc input -stderr: -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected number -error: 2222 != 1 -syntax error: invalid character: '#' -syntax error: invalid character: '#' -stderr: -./calc.at:1351: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS -1.3: syntax error -./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -stderr: -1.3: syntax error - | (1 + # + 1) = 1111 -./calc.at:1341: $PREPARSER ./calc input -./calc.at:1342: "$PERL" -pi -e 'use strict; +./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29957,9 +29690,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -./calc.at:1344: cat stderr -./calc.at:1347: "$PERL" -pi -e 'use strict; +./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29969,8 +29700,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -syntax error: invalid character: '#' -./calc.at:1346: "$PERL" -pi -e 'use strict; +memory exhausted +./calc.at:1344: cat stderr +./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -29980,20 +29712,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error: invalid character: '#' -./calc.at:1346: cat stderr -input: input: +./calc.at:1346: cat stderr ./calc.at:1342: cat stderr - | 1 = 2 = 3 -./calc.at:1346: $PREPARSER ./calc input - | 1 = 2 = 3 -stderr: -./calc.at:1344: $PREPARSER ./calc input -./calc.at:1347: cat stderr -./calc.at:1343: "$PERL" -pi -e 'use strict; +./calc.at:1343: cat stderr +./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30003,26 +29726,34 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.7: syntax error -./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | error +./calc.at:1344: $PREPARSER ./calc input +stderr: +syntax error, unexpected invalid token +./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: - | (1 + #) = 1111 -./calc.at:1343: cat stderr +syntax error, unexpected invalid token +./calc.at:1343: $PREPARSER ./calc /dev/null +input: + | 1 + 2 * 3 + !* ++ ./calc.at:1342: $PREPARSER ./calc input + | + | +1 stderr: -1.7: syntax error +./calc.at:1341: cat stderr stderr: -syntax error: invalid character: '#' -syntax error, unexpected '=' +syntax error, unexpected end of file +./calc.at:1346: $PREPARSER ./calc input +./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +memory exhausted ./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -input: -./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error: invalid character: '#' - | 1//2 -./calc.at:1347: $PREPARSER ./calc input -./calc.at:1341: "$PERL" -pi -e 'use strict; +stderr: +stderr: +memory exhausted +syntax error, unexpected end of file +./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30032,9 +29763,16 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +2.1: syntax error +./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.3: syntax error -./calc.at:1346: "$PERL" -pi -e 'use strict; +input: +./calc.at:1344: cat stderr +2.1: syntax error + | (#) + (#) = 2222 +./calc.at:1341: $PREPARSER ./calc input +stderr: +./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30044,16 +29782,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -stderr: -stderr: -1.3: syntax error -stdout: -./calc.at:1346: cat stderr -stderr: -./calc.at:1348: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -./calc.at:1342: "$PERL" -pi -e 'use strict; +syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 = 2 = 3 +./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30063,13 +29797,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | (* *) + (*) + (*) -./calc.at:1343: $PREPARSER ./calc input - | - | +1 -./calc.at:1346: $PREPARSER ./calc input -./calc.at:1347: "$PERL" -pi -e 'use strict; +./calc.at:1344: $PREPARSER ./calc input +./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30079,7 +29808,33 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1348: "$PERL" -ne ' +stderr: +stderr: +stderr: +./calc.at:1343: cat stderr +syntax error, unexpected '=' +stderr: +stdout: +./calc.at:1342: cat stderr +stdout: +syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +syntax error, unexpected '=' +./types.at:139: $PREPARSER ./test +./calc.at:1346: cat stderr +./calc.at:1347: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +stderr: +input: +input: +./calc.at:1346: $PREPARSER ./calc /dev/null + | (#) + (#) = 2222 +./calc.at:1342: $PREPARSER ./calc input +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1343: $PREPARSER ./calc input +./calc.at:1347: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. @@ -30090,20 +29845,47 @@ || /\t/ )' calc.c -syntax error, unexpected '=' stderr: stderr: -2.1: syntax error +1.1: syntax error ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +446. types.at:139: ok +./calc.at:1341: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1344: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -./calc.at:1342: cat stderr +error: 4444 != 1 ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: input: -2.1: syntax error -./calc.at:1341: cat stderr +stderr: +1.1: syntax error +syntax error: invalid character: '#' +syntax error: invalid character: '#' | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -30117,13 +29899,16 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -./calc.at:1348: $PREPARSER ./calc input -./calc.at:1347: cat stderr stderr: +./calc.at:1344: cat stderr +./calc.at:1347: $PREPARSER ./calc input stderr: +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' +error: 4444 != 1 +./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -30134,18 +29919,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (# + 1) = 1111 -input: -./calc.at:1342: $PREPARSER ./calc input - | error -stderr: -./calc.at:1347: $PREPARSER ./calc input -syntax error: invalid character: '#' +./calc.at:1341: cat stderr + stderr: -./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1344: "$PERL" -pi -e 'use strict; +./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30155,14 +29932,13 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.1: syntax error -stderr: -./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1348: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1347: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: -./calc.at:1346: cat stderr -stderr: + | + | +1 +./calc.at:1344: $PREPARSER ./calc input stderr: +syntax error, unexpected '+' ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -30173,28 +29949,52 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (1 + 1) / (1 - 1) +./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1346: cat stderr +input: + | 1 2 +./calc.at:1347: $PREPARSER ./calc input + | (1 + #) = 1111 +./calc.at:1342: cat stderr +stderr: ./calc.at:1341: $PREPARSER ./calc input -./calc.at:1344: cat stderr -1.1: syntax error -syntax error: invalid character: '#' ./calc.at:1343: cat stderr stderr: -./calc.at:1346: $PREPARSER ./calc /dev/null -input: -error: null divisor +481. calc.at:1348: testing Calculator parse.error=detailed %locations ... +./calc.at:1348: mv calc.y.tmp calc.y + +./calc.at:1348: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +stderr: +1.3: syntax error +./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error, unexpected '+' +syntax error: invalid character: '#' input: ./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 2 -./calc.at:1348: $PREPARSER ./calc input + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +input: +stderr: +./calc.at:1346: $PREPARSER ./calc input + | (1 + #) = 1111 +stderr: +./calc.at:1342: $PREPARSER ./calc input +syntax error: invalid character: '#' +stderr: +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 stderr: - | 1 + 2 * 3 + !+ ++ -./calc.at:1343: $PREPARSER ./calc input -1.1: syntax error ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error: invalid character: '#' +./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -stderr: -./calc.at:1347: "$PERL" -pi -e 'use strict; +1.3: syntax error + | (!!) + (1 2) = 1 +./calc.at:1343: $PREPARSER ./calc input +./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30205,15 +30005,17 @@ }eg ' expout || exit 77 stderr: -./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.3: syntax error, unexpected number -./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | - | +1 -./calc.at:1344: $PREPARSER ./calc input stderr: stderr: -./calc.at:1342: "$PERL" -pi -e 'use strict; +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 +syntax error, unexpected number +error: 2222 != 1 +syntax error: invalid character: '#' +./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30223,17 +30025,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -error: null divisor -stderr: -1.1: syntax error -stderr: -./calc.at:1343: $EGREP -c -v 'Return for a new token:|LAC:' stderr -stderr: -syntax error, unexpected '+' -./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.3: syntax error, unexpected number -input: -./calc.at:1341: "$PERL" -pi -e 'use strict; +./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30243,12 +30035,13 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1347: cat stderr - | 1 + 2 * 3 + !- ++ -./calc.at:1343: $PREPARSER ./calc input -./calc.at:1342: cat stderr -stderr: ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1344: cat stderr +./calc.at:1344: $PREPARSER ./calc /dev/null +stderr: +syntax error, unexpected number +error: 2222 != 1 +./calc.at:1341: cat stderr stderr: ./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} @@ -30260,9 +30053,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1341: cat stderr -stderr: -./calc.at:1348: "$PERL" -pi -e 'use strict; +syntax error, unexpected end of input +./calc.at:1348: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30272,16 +30066,13 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -syntax error, unexpected '+' -./calc.at:1346: cat stderr -input: -475. calc.at:1341: ok - | (1 + # + 1) = 1111 -./calc.at:1342: $PREPARSER ./calc input -input: +./calc.at:1347: cat stderr stderr: -./calc.at:1348: cat stderr - | 1 = 2 = 3 +syntax error, unexpected end of input +input: + | (# + 1) = 1111 +./calc.at:1341: $PREPARSER ./calc input +./calc.at:1346: cat stderr ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -30292,13 +30083,19 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +input: +stderr: syntax error: invalid character: '#' -./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1//2 +./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1347: $PREPARSER ./calc input -input: ./calc.at:1343: cat stderr +./calc.at:1342: cat stderr stderr: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +stderr: +syntax error: invalid character: '#' +1.3: syntax error +./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -30309,26 +30106,30 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -syntax error: invalid character: '#' -stderr: +input: + | (!!) + (1 2) = 1 ./calc.at:1346: $PREPARSER ./calc input -1.7: syntax error +input: ./calc.at:1344: cat stderr input: + | (- *) + (1 2) = 1 +stderr: stderr: -./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 + 2 * 3 + !* ++ ./calc.at:1343: $PREPARSER ./calc input -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 stderr: +1.3: syntax error + | (# + 1) = 1111 +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected number +error: 2222 != 1 +./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1342: $PREPARSER ./calc input +1.11: syntax error +1.1-16: error: 2222 != 1 ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: stderr: -memory exhausted -./calc.at:1342: "$PERL" -pi -e 'use strict; +./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30338,30 +30139,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | 1//2 -./calc.at:1344: $PREPARSER ./calc /dev/null -./calc.at:1348: $PREPARSER ./calc input -stderr: -stderr: -syntax error, unexpected end of input -memory exhausted -stderr: -./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -stderr: -./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - -1.7: syntax error -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 -stderr: stderr: -./calc.at:1346: "$PERL" -pi -e 'use strict; + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1344: $PREPARSER ./calc input +./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30371,9 +30152,31 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1342: cat stderr -syntax error, unexpected end of input -./calc.at:1347: "$PERL" -pi -e 'use strict; +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected number +error: 2222 != 1 +stderr: +stderr: +syntax error: invalid character: '#' +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +error: 4444 != 1 +./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.11: syntax error +1.1-16: error: 2222 != 1 +stderr: +stderr: +syntax error: invalid character: '#' +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +error: 4444 != 1 +./calc.at:1341: cat stderr +./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30383,8 +30186,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1346: cat stderr -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +./calc.at:1347: cat stderr ./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -30396,7 +30198,13 @@ }eg ' expout || exit 77 input: -./calc.at:1348: "$PERL" -pi -e 'use strict; + | (1 + # + 1) = 1111 +./calc.at:1341: $PREPARSER ./calc input +stderr: +input: +./calc.at:1343: cat stderr + | error +./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30406,13 +30214,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -./calc.at:1343: cat stderr - | (1 + 1) / (1 - 1) - | (!!) + (1 2) = 1 -./calc.at:1347: cat stderr -./calc.at:1342: $PREPARSER ./calc input -./calc.at:1346: $PREPARSER ./calc input +./calc.at:1346: cat stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -30423,41 +30225,50 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -484. calc.at:1353: testing Calculator %debug ... -stderr: -./calc.at:1353: mv calc.y.tmp calc.y - -1.11: syntax error -1.1-16: error: 2222 != 1 -stderr: -./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -error: null divisor -stderr: -./calc.at:1353: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.11: syntax error -1.1-16: error: 2222 != 1 -input: - | - | +1 -./calc.at:1344: cat stderr ./calc.at:1347: $PREPARSER ./calc input +syntax error: invalid character: '#' +./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -2.1: syntax error -./calc.at:1348: cat stderr +1.1: syntax error ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -stderr: -error: null divisor - | (#) + (#) = 2222 +./calc.at:1344: cat stderr + | (- *) + (1 2) = 1 +./calc.at:1346: $PREPARSER ./calc input input: +./calc.at:1342: cat stderr +stderr: +stderr: + | (* *) + (*) + (*) ./calc.at:1343: $PREPARSER ./calc input +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 +syntax error: invalid character: '#' +stderr: +./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: +1.1: syntax error stderr: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1346: "$PERL" -pi -e 'use strict; + | (!!) + (1 2) = 1 +stderr: +./calc.at:1344: $PREPARSER ./calc input +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 +stderr: + | (1 + # + 1) = 1111 +./calc.at:1342: $PREPARSER ./calc input +syntax error, unexpected number +error: 2222 != 1 +stderr: +./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30467,40 +30278,22 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1344: $PREPARSER ./calc input - | error -./calc.at:1348: $PREPARSER ./calc input stderr: -stderr: -1.1: syntax error, unexpected invalid token -stderr: -./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1346: cat stderr -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' -error: 4444 != 1 -./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -2.1: syntax error -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected ')', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '*', expecting number or '-' or '(' or '!' -error: 4444 != 1 -input: -syntax error: invalid character: '#' +./calc.at:1346: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 syntax error: invalid character: '#' - | (- *) + (1 2) = 1 -./calc.at:1346: $PREPARSER ./calc input -stderr: -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 -./calc.at:1347: "$PERL" -pi -e 'use strict; +./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30510,13 +30303,38 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1353: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS -./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 +syntax error, unexpected number +error: 2222 != 1 +stderr: +syntax error: invalid character: '#' +./calc.at:1341: cat stderr +./calc.at:1346: cat stderr ./calc.at:1347: cat stderr +./calc.at:1343: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1344: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +input: +input: ./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -30527,14 +30345,51 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + | (1 + 1) / (1 - 1) + | 1 = 2 = 3 +./calc.at:1347: $PREPARSER ./calc input +./calc.at:1343: cat stderr +./calc.at:1341: $PREPARSER ./calc input + | (* *) + (*) + (*) +./calc.at:1344: cat stderr +./calc.at:1346: $PREPARSER ./calc input stderr: -./calc.at:1342: cat stderr -./calc.at:1347: $PREPARSER ./calc /dev/null -1.1: syntax error, unexpected invalid token stderr: -1.1: syntax error +stderr: +1.7: syntax error ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1344: "$PERL" -pi -e 'use strict; +1.2: syntax error +1.10: syntax error +1.16: syntax error +./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +error: null divisor +input: +./calc.at:1341: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | 1 + 2 * 3 + !+ ++ + | (- *) + (1 2) = 1 +./calc.at:1344: $PREPARSER ./calc input +stderr: +./calc.at:1342: cat stderr +./calc.at:1343: $PREPARSER ./calc input +stderr: +1.2: syntax error +1.10: syntax error +1.16: syntax error +stderr: +stderr: +stderr: +error: null divisor +./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.7: syntax error +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected number +error: 2222 != 1 +./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +input: +./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30544,11 +30399,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -476. calc.at:1342: ok -stderr: -1.1: syntax error -stderr: -stdout: + | (1 + 1) / (1 - 1) +./calc.at:1343: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1342: $PREPARSER ./calc input ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -30559,9 +30412,16 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1344: cat stderr -./calc.at:1350: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -./calc.at:1343: "$PERL" -pi -e 'use strict; +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected number +error: 2222 != 1 +stderr: +error: null divisor +./calc.at:1342: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1347: cat stderr +input: + | 1 + 2 * 3 + !- ++ +./calc.at:1341: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30571,7 +30431,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1346: "$PERL" -pi -e 'use strict; +./calc.at:1343: $PREPARSER ./calc input +./calc.at:1346: cat stderr +./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30581,8 +30443,30 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +stderr: +stderr: +stderr: +error: null divisor +./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1344: cat stderr input: -./calc.at:1350: "$PERL" -ne ' +stdout: +input: + | + | +1 +./calc.at:1347: $PREPARSER ./calc input +./calc.at:1348: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +stderr: +stderr: + | 1 + 2 * 3 + !+ ++ +./calc.at:1341: cat stderr +2.1: syntax error +./calc.at:1346: $PREPARSER ./calc input +input: +./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (* *) + (*) + (*) +./calc.at:1344: $PREPARSER ./calc input +./calc.at:1348: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. @@ -30591,13 +30475,19 @@ || /\s$/ # No tabs. || /\t/ - )' calc.c calc.h + )' calc.c -./calc.at:1347: cat stderr - | (!!) + (1 2) = 1 -./calc.at:1344: $PREPARSER ./calc input stderr: -./calc.at:1348: "$PERL" -pi -e 'use strict; +stderr: +stderr: +stdout: +./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1342: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30607,11 +30497,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -syntax error, unexpected number -error: 2222 != 1 +2.1: syntax error +475. calc.at:1341: ./types.at:139: $PREPARSER ./test + ok input: -./calc.at:1343: cat stderr -./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -30625,40 +30515,10 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -./calc.at:1350: $PREPARSER ./calc input -stderr: -./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - -stderr: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1347: $PREPARSER ./calc input -stderr: -./calc.at:1348: cat stderr -syntax error, unexpected number -error: 2222 != 1 -./calc.at:1350: $EGREP -c -v 'Return for a new token:|LAC:' stderr -input: -stderr: -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 - | (1 + #) = 1111 -./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1343: $PREPARSER ./calc input stderr: stderr: -syntax error: invalid character: '#' -./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 -./calc.at:1346: cat stderr -./calc.at:1344: "$PERL" -pi -e 'use strict; +./calc.at:1348: $PREPARSER ./calc input +./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30668,16 +30528,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | 1 2 -./calc.at:1344: cat stderr -./calc.at:1350: $PREPARSER ./calc input -stderr: -stderr: -485. calc.at:1354: testing Calculator parse.error=detailed %debug %locations %header %name-prefix "calc" %verbose %yacc ... -1.3: syntax error, unexpected number -./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error: invalid character: '#' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1346: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -30688,19 +30542,54 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +stderr: +./calc.at:1343: cat stderr +./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1342: cat stderr +stderr: input: - | 1 = 2 = 3 input: -./calc.at:1348: $PREPARSER ./calc input - | (* *) + (*) + (*) +./calc.at:1347: cat stderr + + | 1 + 2 * 3 + !* ++ + | 1 + 2 * 3 + !- ++ +./calc.at:1348: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1343: $PREPARSER ./calc input +./calc.at:1346: $PREPARSER ./calc input +476. calc.at:1342: ./calc.at:1344: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +======== Testing with C++ standard flags: '' + ok +./calc.at:1347: $PREPARSER ./calc /dev/null +stderr: +stderr: +stderr: +./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +memory exhausted +1.1: syntax error +./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1344: cat stderr +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS input: stderr: - | (- *) + (1 2) = 1 -./calc.at:1344: $PREPARSER ./calc input -1.3: syntax error, unexpected number -./calc.at:1346: $PREPARSER ./calc input + | 1 2 stderr: -./calc.at:1354: +./calc.at:1348: $PREPARSER ./calc input +stderr: +482. calc.at:1350: testing Calculator parse.error=detailed %locations %header api.prefix={calc} %verbose %yacc ... +1.1: syntax error +stderr: +./calc.at:1350: if "$POSIXLY_CORRECT_IS_EXPORTED"; then sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y else @@ -30708,21 +30597,40 @@ fi -1.7: syntax error, unexpected '=' +memory exhausted +1.3: syntax error, unexpected number + ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | 1 + 2 * 3 + !+ ++ +./calc.at:1344: $PREPARSER ./calc input +./calc.at:1347: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: +./calc.at:1346: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected number -error: 2222 != 1 ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -1.7: syntax error, unexpected '=' +1.3: syntax error, unexpected number +./calc.at:1350: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: -1.2: syntax error -1.10: syntax error -1.16: syntax error -./calc.at:1350: "$PERL" -pi -e 'use strict; +./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30732,8 +30640,19 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1343: "$PERL" -pi -e 'use strict; +./calc.at:1347: cat stderr +483. calc.at:1351: testing Calculator parse.error=detailed %locations %header %name-prefix "calc" api.token.prefix={TOK_} %verbose %yacc ... +./calc.at:1344: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1346: cat stderr +./calc.at:1351: + if "$POSIXLY_CORRECT_IS_EXPORTED"; then + sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y + else + mv calc.y.tmp calc.y + fi + + +./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30743,21 +30662,61 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1350: cat stderr +./calc.at:1343: cat stderr +input: +input: +./calc.at:1348: cat stderr +input: + | 1 + 2 * 3 + !* ++ + | 1 + 2 * 3 + !- ++ +stderr: +./calc.at:1346: $PREPARSER ./calc input +./calc.at:1344: $PREPARSER ./calc input +./calc.at:1351: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +input: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1347: $PREPARSER ./calc input stderr: stderr: +stdout: +stderr: + | (#) + (#) = 2222 +./calc.at:1343: $PREPARSER ./calc input +1.14: memory exhausted +./types.at:139: ./check +./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error -1.10: syntax error -1.16: syntax error -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected number -error: 2222 != 1 +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 +./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: +./calc.at:1350: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS +stderr: +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +syntax error: invalid character: '#' +syntax error: invalid character: '#' stderr: -./calc.at:1347: cat stderr | 1//2 -stdout: -./calc.at:1348: "$PERL" -pi -e 'use strict; +./calc.at:1348: $PREPARSER ./calc input +stderr: +./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 +stderr: +stderr: +1.14: memory exhausted +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30767,13 +30726,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1350: $PREPARSER ./calc input -./types.at:139: $PREPARSER ./test -stderr: -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1346: "$PERL" -pi -e 'use strict; +./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30784,10 +30737,8 @@ }eg ' expout || exit 77 stderr: -./calc.at:1348: cat stderr -./calc.at:1343: cat stderr +./calc.at:1351: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS 1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -30798,9 +30749,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -======== Testing with C++ standard flags: '' -input: -./calc.at:1350: "$PERL" -pi -e 'use strict; +./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30810,88 +30759,113 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1347: cat stderr ./calc.at:1346: cat stderr +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./calc.at:1344: cat stderr +./calc.at:1343: cat stderr +input: +./calc.at:1348: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 | (!!) + (1 2) = 1 ./calc.at:1347: $PREPARSER ./calc input input: -./calc.at:1350: cat stderr - | - | +1 -./calc.at:1348: $PREPARSER ./calc input +input: +input: stderr: + | (#) + (#) = 2222 + | (1 + #) = 1111 1.11: syntax error 1.1-16: error: 2222 != 1 -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -stderr: -2.1: syntax error, unexpected '+' -./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1344: cat stderr +./calc.at:1343: $PREPARSER ./calc input +./calc.at:1346: $PREPARSER ./calc input ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: + | 1 + 2 * 3 + !* ++ stderr: -input: -stdout: - | (* *) + (*) + (*) +./calc.at:1348: cat stderr ./calc.at:1344: $PREPARSER ./calc input -./calc.at:1351: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' - | error -input: -./calc.at:1350: $PREPARSER ./calc input - | 1 + 2 * 3 + !+ ++ -./calc.at:1346: $PREPARSER ./calc input +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' stderr: -./calc.at:1354: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -2.1: syntax error, unexpected '+' -stderr: -1.1: syntax error, unexpected invalid token -./calc.at:1346: $EGREP -c -v 'Return for a new token:|LAC:' stderr -input: -stderr: - | (# + 1) = 1111 -./calc.at:1343: $PREPARSER ./calc input -./calc.at:1351: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c calc.h - -stderr: -stderr: -./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' ./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +memory exhausted +stdout: 1.11: syntax error 1.1-16: error: 2222 != 1 -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error: invalid character: '#' -input: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 +./types.at:139: $PREPARSER ./test +stderr: input: -./calc.at:1351: $PREPARSER ./calc input +stderr: +stderr: +stderr: + | error +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1348: $PREPARSER ./calc input +memory exhausted +./calc.at:1347: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.1: syntax error, unexpected invalid token +./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +448. types.at:139: ok +./calc.at:1346: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +1.1: syntax error, unexpected invalid token +./calc.at:1347: cat stderr +./calc.at:1344: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1343: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -30902,21 +30876,54 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +input: +./calc.at:1346: cat stderr +./calc.at:1344: cat stderr +./calc.at:1343: cat stderr + | (- *) + (1 2) = 1 +./calc.at:1347: $PREPARSER ./calc input +./calc.at:1348: cat stderr + stderr: - | 1 + 2 * 3 + !- ++ +input: +input: +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 +./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +input: + | (#) + (#) = 2222 +./calc.at:1344: $PREPARSER ./calc input + | (# + 1) = 1111 + | (1 + #) = 1111 +./calc.at:1343: $PREPARSER ./calc input ./calc.at:1346: $PREPARSER ./calc input + | 1 = 2 = 3 +./calc.at:1348: $PREPARSER ./calc input +stderr: stderr: -./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' stderr: +syntax error: invalid character: '#' +syntax error: invalid character: '#' +syntax error: invalid character: '#' +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 +./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +1.6: syntax error: invalid character: '#' ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1351: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1348: cat stderr -1.1: syntax error, unexpected invalid token +1.7: syntax error, unexpected '=' +484. calc.at:1353: testing Calculator %debug ... +./calc.at:1353: mv calc.y.tmp calc.y + +./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +syntax error: invalid character: '#' ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -30927,7 +30934,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1343: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1353: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +syntax error: invalid character: '#' +syntax error: invalid character: '#' +1.6: syntax error: invalid character: '#' +stderr: +1.7: syntax error, unexpected '=' +./calc.at:1347: cat stderr +./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30937,13 +30952,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1348: $PREPARSER ./calc /dev/null -stderr: -./calc.at:1343: cat stderr -stderr: -1.1: syntax error, unexpected end of file -./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1350: "$PERL" -pi -e 'use strict; +./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30953,7 +30962,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1346: "$PERL" -pi -e 'use strict; +./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -30963,16 +30972,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1348: cat stderr input: - | 1 2 -./calc.at:1351: $PREPARSER ./calc input -./calc.at:1350: cat stderr -./calc.at:1347: cat stderr -stderr: -./calc.at:1346: cat stderr -input: - | (1 + # + 1) = 1111 -./calc.at:1343: $PREPARSER ./calc input ./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -30983,57 +30984,48 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: +./calc.at:1346: cat stderr + | (* *) + (*) + (*) +./calc.at:1347: $PREPARSER ./calc input +./calc.at:1343: cat stderr +./calc.at:1353: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: ./calc.at:1344: cat stderr input: input: -1.3: syntax error, unexpected number -./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 = 2 = 3 - | 1 + 2 * 3 + !* ++ -./calc.at:1346: $PREPARSER ./calc input -input: -./calc.at:1350: $PREPARSER ./calc input -1.1: syntax error, unexpected end of file - | (- *) + (1 2) = 1 +1.2: syntax error +1.10: syntax error +1.16: syntax error +./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | + | +1 +./calc.at:1348: $PREPARSER ./calc input input: -./calc.at:1347: $PREPARSER ./calc input -stderr: -syntax error: invalid character: '#' -./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: - | 1 + 2 * 3 + !+ ++ -./calc.at:1344: $PREPARSER ./calc input -stderr: + | (# + 1) = 1111 stderr: -1.7: syntax error, unexpected '=' -syntax error: invalid character: '#' +./calc.at:1346: $PREPARSER ./calc input stderr: stderr: -1.14: memory exhausted -./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +2.1: syntax error, unexpected '+' +./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + # + 1) = 1111 +./calc.at:1343: $PREPARSER ./calc input +1.2: syntax error +1.10: syntax error +1.16: syntax error +1.2: syntax error: invalid character: '#' ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 -./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: +input: +syntax error: invalid character: '#' +./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + #) = 1111 +./calc.at:1344: $PREPARSER ./calc input +2.1: syntax error, unexpected '+' stderr: -./types.at:139: ./check -1.3: syntax error, unexpected number -stderr: -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 -1.7: syntax error, unexpected '=' -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y stderr: -./calc.at:1344: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1343: "$PERL" -pi -e 'use strict; +./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -31043,6 +31035,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +syntax error: invalid character: '#' +stderr: +1.2: syntax error: invalid character: '#' +./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error: invalid character: '#' ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -31053,8 +31050,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.14: memory exhausted -./calc.at:1351: "$PERL" -pi -e 'use strict; +./calc.at:1348: cat stderr +stderr: +./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -31064,11 +31062,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1343: cat stderr -./calc.at:1348: cat stderr -./calc.at:1351: cat stderr -input: -./calc.at:1347: "$PERL" -pi -e 'use strict; +syntax error: invalid character: '#' +./calc.at:1347: cat stderr +./calc.at:1348: $PREPARSER ./calc /dev/null +./calc.at:1343: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -31078,8 +31075,19 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1 + 2 * 3 + !- ++ -./calc.at:1350: "$PERL" -pi -e 'use strict; +stderr: +1.1: syntax error, unexpected end of file +./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1343: cat stderr +input: + | 1 + 2 * 3 + !+ ++ +./calc.at:1346: cat stderr +stderr: +./calc.at:1347: $PREPARSER ./calc input +stderr: +1.1: syntax error, unexpected end of file +./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -31089,10 +31097,29 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1344: $PREPARSER ./calc input input: +./calc.at:1344: cat stderr input: -./calc.at:1346: "$PERL" -pi -e 'use strict; + | (1 + 1) / (1 - 1) +./calc.at:1343: $PREPARSER ./calc input + | (1 + # + 1) = 1111 +stderr: +./calc.at:1346: $PREPARSER ./calc input +stderr: +stderr: +stderr: +stderr: +stdout: +./calc.at:1347: $EGREP -c -v 'Return for a new token:|LAC:' stderr +input: +stdout: +error: null divisor +1.6: syntax error: invalid character: '#' +./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1350: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (# + 1) = 1111 +./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -31102,41 +31129,115 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1348: $PREPARSER ./calc input -input: -./calc.at:1350: cat stderr - | (1 + 1) / (1 - 1) - | 1//2 +./calc.at:1351: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +./calc.at:1344: $PREPARSER ./calc input +./calc.at:1351: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c calc.h + stderr: -./calc.at:1343: $PREPARSER ./calc input stderr: +input: +input: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 ./calc.at:1351: $PREPARSER ./calc input -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.1-46: error: 4444 != 1 -./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1346: cat stderr +1.6: syntax error: invalid character: '#' stderr: +./calc.at:1350: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c calc.h + + | 1 + 2 * 3 + !- ++ +./calc.at:1348: cat stderr stderr: +./calc.at:1347: $PREPARSER ./calc input +error: null divisor +syntax error: invalid character: '#' ./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -error: null divisor -./calc.at:1343: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1347: cat stderr stderr: +./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1346: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +stderr: +syntax error: invalid character: '#' +input: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1351: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1350: $PREPARSER ./calc input +stderr: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +stderr: +./calc.at:1348: $PREPARSER ./calc input stderr: +./calc.at:1343: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 -stderr: -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1348: "$PERL" -pi -e 'use strict; +./calc.at:1346: cat stderr +./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -31146,8 +31247,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./calc.at:1351: "$PERL" -pi -e 'use strict; + | 1 2 +./calc.at:1351: $PREPARSER ./calc input +stderr: +./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -31157,14 +31260,28 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +stderr: +stderr: +./calc.at:1343: cat stderr +./calc.at:1344: cat stderr +1.3: syntax error, unexpected number +./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -./calc.at:1348: cat stderr -input: -./calc.at:1351: cat stderr -input: - | (#) + (#) = 2222 +./calc.at:1350: $EGREP -c -v 'Return for a new token:|LAC:' stderr +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.1-46: error: 4444 != 1 + | (1 + 1) / (1 - 1) ./calc.at:1346: $PREPARSER ./calc input -./calc.at:1344: "$PERL" -pi -e 'use strict; +477. calc.at:1343: input: + ok +stderr: +./calc.at:1347: cat stderr +stderr: + | (1 + # + 1) = 1111 +./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -31174,53 +31291,25 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +1.3: syntax error, unexpected number +./calc.at:1344: $PREPARSER ./calc input input: +1.11-17: error: null divisor + | 1 2 stderr: - | (* *) + (*) + (*) -error: null divisor -./calc.at:1347: $PREPARSER ./calc input -stderr: -stderr: - | error - | - | +1 -1.2: syntax error -1.10: syntax error -1.16: syntax error -./calc.at:1351: $PREPARSER ./calc input ./calc.at:1350: $PREPARSER ./calc input -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | (!!) + (1 2) = 1 -./calc.at:1348: $PREPARSER ./calc input -stderr: -stderr: -stderr: -1.1: syntax error, unexpected invalid token -2.1: syntax error, unexpected '+' +syntax error: invalid character: '#' +./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1348: cat stderr stderr: -./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.2: syntax error -1.10: syntax error -1.16: syntax error -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 +input: +1.3: syntax error, unexpected number + | 1 + 2 * 3 + !* ++ ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1344: cat stderr -1.1: syntax error, unexpected invalid token -stderr: -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 -stderr: +./calc.at:1347: $PREPARSER ./calc input stderr: -2.1: syntax error, unexpected '+' -input: -./calc.at:1347: "$PERL" -pi -e 'use strict; +./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -31230,11 +31319,24 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' - | 1 + 2 * 3 + !* ++ -./calc.at:1344: $PREPARSER ./calc input -./calc.at:1351: "$PERL" -pi -e 'use strict; +stderr: +stderr: +1.11-17: error: null divisor +syntax error: invalid character: '#' +input: + | (!!) + (1 2) = 1 +./calc.at:1348: $PREPARSER ./calc input +./calc.at:1351: cat stderr +stderr: +1.14: memory exhausted +./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.3: syntax error, unexpected number +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 + +./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1346: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -31244,7 +31346,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1348: "$PERL" -pi -e 'use strict; +stderr: +input: +1.14: memory exhausted +stderr: +./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -31254,11 +31360,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -memory exhausted -./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1351: cat stderr -./calc.at:1343: "$PERL" -pi -e 'use strict; +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 + | 1//2 +./calc.at:1351: $PREPARSER ./calc input +./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -31268,11 +31374,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1348: cat stderr stderr: -memory exhausted -input: -./calc.at:1346: "$PERL" -pi -e 'use strict; +./calc.at:1346: cat stderr +./calc.at:1344: cat stderr +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -31282,9 +31389,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1 = 2 = 3 -./calc.at:1351: $PREPARSER ./calc input -./calc.at:1350: "$PERL" -pi -e 'use strict; +./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -31294,12 +31399,29 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -1.7: syntax error, unexpected '=' +479. calc.at:1346: ok ./calc.at:1350: cat stderr -./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1343: cat stderr -./calc.at:1344: "$PERL" -pi -e 'use strict; +input: +stderr: +485. calc.at:1354: testing Calculator parse.error=detailed %debug %locations %header %name-prefix "calc" %verbose %yacc ... +./calc.at:1354: + if "$POSIXLY_CORRECT_IS_EXPORTED"; then + sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y + else + mv calc.y.tmp calc.y + fi + + +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +./calc.at:1348: cat stderr + | (1 + 1) / (1 - 1) +./calc.at:1344: $PREPARSER ./calc input +stderr: +input: +error: null divisor +./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1347: cat stderr +./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -31309,37 +31431,39 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + | 1//2 +./calc.at:1350: $PREPARSER ./calc input + stderr: -input: -./calc.at:1350: $PREPARSER ./calc /dev/null -1.7: syntax error, unexpected '=' -./calc.at:1347: cat stderr -./calc.at:1346: cat stderr stderr: -./calc.at:1344: cat stderr - | (- *) + (1 2) = 1 -1.1: syntax error, unexpected end of file +./calc.at:1354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +./calc.at:1351: cat stderr +input: +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +error: null divisor ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (- *) + (1 2) = 1 ./calc.at:1348: $PREPARSER ./calc input input: stderr: -1.1: syntax error, unexpected end of file - | 1 + 2 * 3 + !+ ++ + | (#) + (#) = 2222 ./calc.at:1347: $PREPARSER ./calc input +input: stderr: stderr: -stderr: -input: 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 - | (#) + (#) = 2222 +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' + | error +./calc.at:1351: $PREPARSER ./calc input ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1344: $PREPARSER ./calc input +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' ./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./calc.at:1350: "$PERL" -pi -e 'use strict; +stderr: +1.1: syntax error, unexpected invalid token +./calc.at:1344: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -31349,12 +31473,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (1 + #) = 1111 -./calc.at:1346: $PREPARSER ./calc input -stderr: +./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +486. calc.at:1355: testing Calculator parse.error=detailed %debug %locations %header api.prefix={calc} %verbose %yacc ... stderr: -./calc.at:1351: "$PERL" -pi -e 'use strict; +./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -31364,42 +31487,23 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1355: + if "$POSIXLY_CORRECT_IS_EXPORTED"; then + sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y + else + mv calc.y.tmp calc.y + fi + + 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 -./calc.at:1353: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -./calc.at:1347: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: -syntax error: invalid character: '#' -syntax error: invalid character: '#' -477. calc.at:1343: ok -./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.6: syntax error: invalid character: '#' -./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.1: syntax error, unexpected invalid token +./calc.at:1344: cat stderr +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' ./calc.at:1350: cat stderr -./calc.at:1351: cat stderr -stderr: -./calc.at:1353: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c - -syntax error: invalid character: '#' -syntax error: invalid character: '#' -stderr: -input: -input: -input: -1.6: syntax error: invalid character: '#' - | - | +1 - | 1 + 2 * 3 + !- ++ ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -31410,16 +31514,19 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1347: $PREPARSER ./calc input -./calc.at:1351: $PREPARSER ./calc input - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -stderr: -stderr: -./calc.at:1350: $PREPARSER ./calc input -stderr: -input: -./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1346: "$PERL" -pi -e 'use strict; +478. calc.at:1344: ./calc.at:1354: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS +./calc.at:1347: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + ok +./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -31429,15 +31536,54 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1355: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +input: ./calc.at:1348: cat stderr -2.1: syntax error, unexpected '+' -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.1-46: error: 4444 != 1 -./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | error +./calc.at:1350: $PREPARSER ./calc input +stderr: +./calc.at:1351: cat stderr +stderr: +stdout: +./calc.at:1347: cat stderr +./calc.at:1353: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +1.1: syntax error, unexpected invalid token ./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +input: + | (* *) + (*) + (*) + | 1 = 2 = 3 +./calc.at:1348: $PREPARSER ./calc input +./calc.at:1351: $PREPARSER ./calc input +stderr: +stderr: +input: +stderr: +./calc.at:1353: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c + + +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + #) = 1111 +1.1: syntax error, unexpected invalid token +./calc.at:1347: $PREPARSER ./calc input +1.7: syntax error, unexpected '=' +./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +input: +stderr: +1.6: syntax error: invalid character: '#' | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -31451,38 +31597,12 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -input: -stderr: stderr: -./calc.at:1344: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -2.1: syntax error, unexpected '+' -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.1-46: error: 4444 != 1 - | (* *) + (*) + (*) ./calc.at:1353: $PREPARSER ./calc input -./calc.at:1348: $PREPARSER ./calc input -./calc.at:1346: cat stderr -stderr: - -./calc.at:1344: cat stderr +./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -input: -./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -31493,8 +31613,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (# + 1) = 1111 -./calc.at:1346: $PREPARSER ./calc input +1.7: syntax error, unexpected '=' +stderr: +stderr: Starting parse Entering state 0 Stack now 0 @@ -32512,7 +32633,11 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) -./calc.at:1351: "$PERL" -pi -e 'use strict; +./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.6: syntax error: invalid character: '#' +./calc.at:1355: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS +./calc.at:1350: cat stderr +./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -32523,15 +32648,15 @@ }eg ' expout || exit 77 stderr: -stderr: -./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1350: cat stderr -./calc.at:1351: cat stderr -stderr: -stderr: -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +487. calc.at:1357: testing Calculator api.pure=full parse.error=detailed %debug %locations %header %name-prefix "calc" %verbose %yacc ... +./calc.at:1357: + if "$POSIXLY_CORRECT_IS_EXPORTED"; then + sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y + else + mv calc.y.tmp calc.y + fi + + Starting parse Entering state 0 Stack now 0 @@ -33549,8 +33674,8 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) -input: ./calc.at:1353: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1348: cat stderr ./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -33561,26 +33686,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (!!) + (1 2) = 1 -1.2: syntax error: invalid character: '#' -./calc.at:1350: $PREPARSER ./calc input -./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.2: syntax error: invalid character: '#' -stderr: -input: -input: - | (1 + #) = 1111 - | 1 2 -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 -./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1347: cat stderr -./calc.at:1353: $PREPARSER ./calc input -486. calc.at:1355: testing Calculator parse.error=detailed %debug %locations %header api.prefix={calc} %verbose %yacc ... -./calc.at:1344: $PREPARSER ./calc input -./calc.at:1351: $PREPARSER ./calc /dev/null -./calc.at:1346: "$PERL" -pi -e 'use strict; +./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -33590,16 +33696,21 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +input: + | 1 = 2 = 3 +./calc.at:1351: cat stderr +./calc.at:1350: $PREPARSER ./calc input +input: +input: +./calc.at:1357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: -./calc.at:1355: - if "$POSIXLY_CORRECT_IS_EXPORTED"; then - sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y - else - mv calc.y.tmp calc.y - fi - - -stderr: + | 1 2 + | 1 + 2 * 3 + !+ ++ +1.7: syntax error, unexpected '=' +./calc.at:1353: $PREPARSER ./calc input +./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1348: $PREPARSER ./calc input +./calc.at:1347: cat stderr stderr: Starting parse Entering state 0 @@ -33621,24 +33732,17 @@ Stack now 0 Cleanup: discarding lookahead token "number" (1.1: 2) Stack now 0 +stderr: +input: ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 stderr: -syntax error: invalid character: '#' -./calc.at:1355: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | + | +1 +input: stderr: -./calc.at:1348: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1351: $PREPARSER ./calc input +1.7: syntax error, unexpected '=' stderr: Starting parse Entering state 0 @@ -33660,8 +33764,15 @@ Stack now 0 Cleanup: discarding lookahead token "number" (1.1: 2) Stack now 0 -syntax error: invalid character: '#' -./calc.at:1346: cat stderr + | (# + 1) = 1111 +./calc.at:1347: $PREPARSER ./calc input +stderr: +stderr: +2.1: syntax error, unexpected '+' +./calc.at:1348: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error: invalid character: '#' +./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -33672,12 +33783,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1348: cat stderr -input: +stderr: +stderr: +1.2: syntax error: invalid character: '#' +2.1: syntax error, unexpected '+' input: -1.1: syntax error, unexpected end of file - | 1 + 2 * 3 + !* ++ -./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1350: cat stderr + | 1 + 2 * 3 + !- ++ +./calc.at:1348: $PREPARSER ./calc input +./calc.at:1357: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -33688,9 +33802,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1347: $PREPARSER ./calc input -stderr: -./calc.at:1344: "$PERL" -pi -e 'use strict; +./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -33701,23 +33813,7 @@ }eg ' expout || exit 77 stderr: -1.1: syntax error, unexpected end of file -1.14: memory exhausted - | 1 + 2 * 3 + !+ ++ -./calc.at:1350: cat stderr -input: -./calc.at:1348: $PREPARSER ./calc input -./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (1 + # + 1) = 1111 -./calc.at:1346: $PREPARSER ./calc input -stderr: -stderr: ./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.6: syntax error: invalid character: '#' -./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -./calc.at:1348: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -33728,12 +33824,21 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.6: syntax error: invalid character: '#' +input: ./calc.at:1351: cat stderr + | + | +1 +stderr: +./calc.at:1350: $PREPARSER ./calc input ./calc.at:1353: cat stderr -./calc.at:1344: cat stderr stderr: -./calc.at:1346: "$PERL" -pi -e 'use strict; +./calc.at:1347: cat stderr +./calc.at:1351: $PREPARSER ./calc /dev/null +2.1: syntax error, unexpected '+' +stderr: +./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -33743,25 +33848,19 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | 1 + 2 * 3 + !- ++ -./calc.at:1348: $PREPARSER ./calc input -stderr: -./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: +1.1: syntax error, unexpected end of file +./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - | (# + 1) = 1111 -./calc.at:1344: $PREPARSER ./calc input -input: -1.14: memory exhausted input: - | (- *) + (1 2) = 1 -stderr: | 1//2 ./calc.at:1353: $PREPARSER ./calc input -syntax error: invalid character: '#' -./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +stderr: +./calc.at:1348: cat stderr +2.1: syntax error, unexpected '+' + | (1 + # + 1) = 1111 +./calc.at:1347: $PREPARSER ./calc input +1.1: syntax error, unexpected end of file Starting parse Entering state 0 Stack now 0 @@ -33789,17 +33888,32 @@ Stack now 0 Cleanup: discarding lookahead token '/' (1.1: ) Stack now 0 -./calc.at:1350: $PREPARSER ./calc input -./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.6: syntax error: invalid character: '#' +./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.12: syntax error, unexpected number -1.1-17: error: 2222 != 1 -syntax error: invalid character: '#' +./calc.at:1351: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 input: -stderr: -./calc.at:1355: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS +./calc.at:1350: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Stack now 0 @@ -33827,8 +33941,22 @@ Stack now 0 Cleanup: discarding lookahead token '/' (1.1: ) Stack now 0 - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1347: "$PERL" -pi -e 'use strict; + | 1 + 2 * 3 + !* ++ +./calc.at:1348: $PREPARSER ./calc input +stderr: +stderr: +1.6: syntax error: invalid character: '#' +./calc.at:1350: cat stderr +1.14: memory exhausted +./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1351: cat stderr +stderr: +./calc.at:1350: $PREPARSER ./calc /dev/null +stderr: +1.14: memory exhausted +input: +1.1: syntax error, unexpected end of file +./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -33838,16 +33966,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1351: $PREPARSER ./calc input -stderr: -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.1-46: error: 4444 != 1 -./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1348: "$PERL" -pi -e 'use strict; +./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -33857,15 +33976,19 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1346: cat stderr -input: +./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1351: $PREPARSER ./calc input +stderr: stderr: 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 -./calc.at:1353: "$PERL" -pi -e 'use strict; +./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.1: syntax error, unexpected end of file +./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -33875,35 +33998,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: - | (1 + 1) / (1 - 1) -./calc.at:1346: $PREPARSER ./calc input -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.12: syntax error, unexpected number -1.1-17: error: 2222 != 1 +./calc.at:1353: cat stderr ./calc.at:1347: cat stderr -./calc.at:1351: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +stderr: ./calc.at:1348: cat stderr -./calc.at:1351: cat stderr -./calc.at:1344: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.1-46: error: 4444 != 1 ./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -33914,53 +34017,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: input: -1.11-17: error: null divisor -./calc.at:1344: cat stderr input: | (#) + (#) = 2222 -./calc.at:1346: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (!!) + (1 2) = 1 ./calc.at:1350: cat stderr -./calc.at:1351: $PREPARSER ./calc input -./calc.at:1347: $PREPARSER ./calc input -./calc.at:1353: cat stderr -stderr: -input: -1.11-17: error: null divisor -input: -stderr: - | (1 + # + 1) = 1111 -stderr: -./calc.at:1344: $PREPARSER ./calc input -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 - | 1 + 2 * 3 + !* ++ -./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1348: $PREPARSER ./calc input -input: -stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' - | (* *) + (*) + (*) -./calc.at:1350: $PREPARSER ./calc input -./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -syntax error: invalid character: '#' -./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.14: memory exhausted -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 -stderr: -./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1346: "$PERL" -pi -e 'use strict; +./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -33970,30 +34032,16 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + | (1 + 1) / (1 - 1) +input: +stderr: +./calc.at:1347: $PREPARSER ./calc input | error ./calc.at:1353: $PREPARSER ./calc input -stderr: -stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' -./calc.at:1351: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.14: memory exhausted -stderr: -stderr: -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 @@ -34002,9 +34050,17 @@ syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 -./calc.at:1351: cat stderr +stderr: ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: +./calc.at:1351: cat stderr + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +stderr: +1.11-17: error: null divisor +./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1350: $PREPARSER ./calc input +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' stderr: Starting parse Entering state 0 @@ -34014,8 +34070,19 @@ syntax error Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 - | (- *) + (1 2) = 1 +stderr: +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.1-46: error: 4444 != 1 +stderr: +input: +./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (!!) + (1 2) = 1 +1.11-17: error: null divisor ./calc.at:1351: $PREPARSER ./calc input +stderr: ./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -34026,10 +34093,17 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.1-46: error: 4444 != 1 stderr: +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 +./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1348: cat stderr -./calc.at:1346: cat stderr -./calc.at:1350: "$PERL" -pi -e 'use strict; +./calc.at:1347: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -34039,7 +34113,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1344: "$PERL" -pi -e 'use strict; +./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -34049,7 +34123,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1347: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -34059,17 +34134,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1344: cat stderr -./calc.at:1350: cat stderr -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.12: syntax error, unexpected number -1.1-17: error: 2222 != 1 -./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -479. calc.at:1346: ok +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 input: - | (1 + 1) / (1 - 1) -./calc.at:1344: $PREPARSER ./calc input -./calc.at:1353: "$PERL" -pi -e 'use strict; + | (1 + #) = 1111 +./calc.at:1348: $PREPARSER ./calc input +./calc.at:1350: cat stderr +./calc.at:1347: cat stderr +./calc.at:1353: cat stderr +./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -34080,96 +34153,17 @@ }eg ' expout || exit 77 stderr: -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.12: syntax error, unexpected number -1.1-17: error: 2222 != 1 +480. calc.at:1347: ok +1.6: syntax error: invalid character: '#' +./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: -stderr: - | (#) + (#) = 2222 -./calc.at:1348: $PREPARSER ./calc input - | 1 + 2 * 3 + !+ ++ + | (!!) + (1 2) = 1 ./calc.at:1350: $PREPARSER ./calc input -error: null divisor -./calc.at:1344: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -error: null divisor -./calc.at:1351: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 stderr: - ./calc.at:1351: cat stderr -./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -stderr: - | (* *) + (*) + (*) -./calc.at:1344: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1347: cat stderr -./calc.at:1351: $PREPARSER ./calc input -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -stderr: -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -./calc.at:1353: cat stderr -./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1344: cat stderr -stderr: -./calc.at:1350: $EGREP -c -v 'Return for a new token:|LAC:' stderr -stderr: -input: -./calc.at:1348: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -478. calc.at:1344: ok -./calc.at:1348: cat stderr | 1 = 2 = 3 -input: ./calc.at:1353: $PREPARSER ./calc input -487. calc.at:1357: testing Calculator api.pure=full parse.error=detailed %debug %locations %header %name-prefix "calc" %verbose %yacc ... - | (1 + #) = 1111 -./calc.at:1357: - if "$POSIXLY_CORRECT_IS_EXPORTED"; then - sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y - else - mv calc.y.tmp calc.y - fi - - -./calc.at:1347: $PREPARSER ./calc input -stderr: stderr: Starting parse Entering state 0 @@ -34210,23 +34204,12 @@ Stack now 0 Cleanup: discarding lookahead token '=' (1.1: ) Stack now 0 -1.6: syntax error: invalid character: '#' ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1351: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -./calc.at:1351: cat stderr +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 +./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: stderr: -input: Starting parse Entering state 0 Stack now 0 @@ -34266,14 +34249,9 @@ Stack now 0 Cleanup: discarding lookahead token '=' (1.1: ) Stack now 0 - | (1 + #) = 1111 -./calc.at:1348: $PREPARSER ./calc input -stderr: +input: 1.6: syntax error: invalid character: '#' - | 1 + 2 * 3 + !- ++ -./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1350: $PREPARSER ./calc input -./calc.at:1357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y + ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -34284,27 +34262,65 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | 1 + 2 * 3 + !+ ++ + | (- *) + (1 2) = 1 ./calc.at:1351: $PREPARSER ./calc input +./calc.at:1348: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: stderr: -stderr: +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.12: syntax error, unexpected number +1.1-17: error: 2222 != 1 ./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: - -stderr: -./calc.at:1351: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1348: cat stderr ./calc.at:1353: cat stderr stderr: -1.6: syntax error: invalid character: '#' -1.6: syntax error: invalid character: '#' +488. calc.at:1358: testing Calculator api.push-pull=both api.pure=full parse.error=detailed %debug %locations %header api.prefix={calc} %verbose %yacc ... +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.12: syntax error, unexpected number +1.1-17: error: 2222 != 1 +./calc.at:1350: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +./calc.at:1358: + if "$POSIXLY_CORRECT_IS_EXPORTED"; then + sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y + else + mv calc.y.tmp calc.y + fi + + input: + | (# + 1) = 1111 +./calc.at:1348: $PREPARSER ./calc input +stderr: | | +1 ./calc.at:1353: $PREPARSER ./calc input +./calc.at:1350: cat stderr +1.2: syntax error: invalid character: '#' +./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: stderr: +stdout: Starting parse Entering state 0 Stack now 0 @@ -34330,8 +34346,7 @@ Stack now 0 Cleanup: discarding lookahead token '+' (1.1: ) Stack now 0 -./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1347: "$PERL" -pi -e 'use strict; +./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -34341,6 +34356,29 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1354: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +stderr: +./calc.at:1358: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +./calc.at:1351: cat stderr + | (- *) + (1 2) = 1 +./calc.at:1350: $PREPARSER ./calc input +stderr: +1.2: syntax error: invalid character: '#' +stderr: +stdout: +./calc.at:1354: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c calc.h + stderr: Starting parse Entering state 0 @@ -34367,59 +34405,13 @@ Stack now 0 Cleanup: discarding lookahead token '+' (1.1: ) Stack now 0 -stderr: -./calc.at:1350: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1348: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.12: syntax error, unexpected number +1.1-17: error: 2222 != 1 +./calc.at:1357: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -./calc.at:1350: cat stderr - | 1 + 2 * 3 + !- ++ -./calc.at:1351: $PREPARSER ./calc input -stderr: -./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./calc.at:1347: cat stderr -./calc.at:1357: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS -stderr: -./calc.at:1354: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -./calc.at:1354: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c calc.h - -488. calc.at:1358: testing Calculator api.push-pull=both api.pure=full parse.error=detailed %debug %locations %header api.prefix={calc} %verbose %yacc ... -./calc.at:1358: - if "$POSIXLY_CORRECT_IS_EXPORTED"; then - sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y - else - mv calc.y.tmp calc.y - fi - - -./calc.at:1353: "$PERL" -pi -e 'use strict; +./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -34429,18 +34421,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1348: cat stderr -input: -input: - | (# + 1) = 1111 - | 1 + 2 * 3 + !* ++ -./calc.at:1347: $PREPARSER ./calc input -./calc.at:1350: $PREPARSER ./calc input -stderr: -1.2: syntax error: invalid character: '#' input: -./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: + | (* *) + (*) + (*) | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -34454,39 +34437,25 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 +./calc.at:1351: $PREPARSER ./calc input ./calc.at:1354: $PREPARSER ./calc input -./calc.at:1353: cat stderr -input: -stderr: -./calc.at:1351: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (# + 1) = 1111 +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.12: syntax error, unexpected number +1.1-17: error: 2222 != 1 stderr: -./calc.at:1353: $PREPARSER ./calc /dev/null -1.2: syntax error: invalid character: '#' -./calc.at:1348: $PREPARSER ./calc input -./calc.at:1358: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +./calc.at:1348: cat stderr stderr: -1.14: memory exhausted -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Now at end of input. -syntax error -Cleanup: discarding lookahead token "end of input" (1.1: ) -Stack now 0 -./calc.at:1351: cat stderr -./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1357: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c calc.h + Starting parse Entering state 0 Stack now 0 @@ -35504,7 +35473,22 @@ Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1347: "$PERL" -pi -e 'use strict; +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1350: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -35514,30 +35498,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: -1.2: syntax error: invalid character: '#' - | 1 + 2 * 3 + !* ++ -./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1351: $PREPARSER ./calc input -stderr: -1.14: memory exhausted -stderr: -./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1347: cat stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Now at end of input. -syntax error -Cleanup: discarding lookahead token "end of input" (1.1: ) -Stack now 0 -stderr: -stderr: -1.14: memory exhausted +input: Starting parse Entering state 0 Stack now 0 @@ -36555,98 +36518,35 @@ Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -input: - | (1 + # + 1) = 1111 -./calc.at:1347: $PREPARSER ./calc input ./calc.at:1354: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.14: memory exhausted -stderr: -1.2: syntax error: invalid character: '#' -./calc.at:1353: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1350: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1351: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1347: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: - | 1 2 + | (1 + # + 1) = 1111 +./calc.at:1348: $PREPARSER ./calc input ./calc.at:1350: cat stderr -./calc.at:1354: $PREPARSER ./calc input -./calc.at:1348: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1358: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1357: $PREPARSER ./calc input +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token number (1.3: 2) -Stack now 0 -./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.6: syntax error: invalid character: '#' stderr: -./calc.at:1351: cat stderr +./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: input: +./calc.at:1353: cat stderr Starting parse Entering state 0 Stack now 0 @@ -36661,1942 +36561,73 @@ Entering state 8 Stack now 0 8 Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token number (1.3: 2) -Stack now 0 - | (#) + (#) = 2222 -./calc.at:1351: $PREPARSER ./calc input -stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1353: cat stderr -./calc.at:1354: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1348: cat stderr -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1354: cat stderr -./calc.at:1347: cat stderr -input: -./calc.at:1351: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (#) + (#) = 2222 -./calc.at:1350: $PREPARSER ./calc input -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1351: cat stderr -stderr: -./calc.at:1353: $PREPARSER ./calc input -input: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | (1 + # + 1) = 1111 -./calc.at:1348: $PREPARSER ./calc input -stderr: -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token ')' (1.1: ) -syntax error -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 30 -Stack now 0 8 21 4 12 21 30 -Reading a token -Next token is token '+' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1) --> $$ = nterm exp (1.1: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 -Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 30 -Stack now 0 8 21 4 12 21 30 -Reading a token -Next token is token '+' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 2) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1) --> $$ = nterm exp (1.1: 3) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Reading a token -Next token is token ')' (1.1: ) -syntax error -Error: popping token '+' (1.1: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.1: 3) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '+' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1111) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.1: ) -syntax error -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token -Next token is token '+' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 2222) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 3333) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) Entering state 22 -Stack now 0 8 21 4 12 22 +Stack now 0 8 21 30 22 Reading a token -Next token is token "number" (1.1: 2) -Shifting token "number" (1.1: 2) +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) Entering state 1 -Stack now 0 8 21 4 12 22 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 2) --> $$ = nterm exp (1.1: 2) +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) Entering state 31 -Stack now 0 8 21 4 12 22 31 -Reading a token -Next token is token '*' (1.1: ) -Reducing stack by rule 9 (line 100): - $1 = nterm exp (1.1: 1) - $2 = token '*' (1.1: ) - $3 = nterm exp (1.1: 2) --> $$ = nterm exp (1.1: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) -Entering state 22 -Stack now 0 8 21 4 12 22 -Reading a token -Next token is token '*' (1.1: ) -syntax error -Error: popping token '*' (1.1: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.1: 2) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 +Stack now 0 8 21 30 22 31 Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) +Next token is token '=' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 3333) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 4444) +Next token is token '=' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token number (1.13: 7) +Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (1.13: 7) +-> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 6 (line 82): - $1 = nterm exp (1.1: 4444) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1) -error: 4444 != 1 --> $$ = nterm exp (1.1: 4444) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 4444) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) -1.6: syntax error: invalid character: '#' -input: -./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (1 + #) = 1111 -./calc.at:1351: $PREPARSER ./calc input -./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -stderr: - | 1//2 -./calc.at:1354: $PREPARSER ./calc input - | (1 + 1) / (1 - 1) -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token ')' (1.1: ) -syntax error -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 30 -Stack now 0 8 21 4 12 21 30 -Reading a token -Next token is token '+' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1) --> $$ = nterm exp (1.1: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 30 -Stack now 0 8 21 4 12 21 30 -Reading a token -Next token is token '+' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 2) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1) --> $$ = nterm exp (1.1: 3) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Reading a token -Next token is token ')' (1.1: ) -syntax error -Error: popping token '+' (1.1: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.1: 3) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '+' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1111) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.1: ) -syntax error -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '+' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 2222) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 3333) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) -Entering state 22 -Stack now 0 8 21 4 12 22 -Reading a token -Next token is token "number" (1.1: 2) -Shifting token "number" (1.1: 2) -Entering state 1 -Stack now 0 8 21 4 12 22 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 2) --> $$ = nterm exp (1.1: 2) -Entering state 31 -Stack now 0 8 21 4 12 22 31 -Reading a token -Next token is token '*' (1.1: ) -Reducing stack by rule 9 (line 100): - $1 = nterm exp (1.1: 1) - $2 = token '*' (1.1: ) - $3 = nterm exp (1.1: 2) --> $$ = nterm exp (1.1: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) -Entering state 22 -Stack now 0 8 21 4 12 22 -Reading a token -Next token is token '*' (1.1: ) -syntax error -Error: popping token '*' (1.1: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.1: 2) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 3333) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 4444) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 6 (line 82): - $1 = nterm exp (1.1: 4444) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1) -error: 4444 != 1 --> $$ = nterm exp (1.1: 4444) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 4444) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) -stderr: -./calc.at:1347: $PREPARSER ./calc input -stderr: -1.6: syntax error: invalid character: '#' -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Stack now 0 8 23 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) -Stack now 0 -stderr: -1.11-17: error: null divisor -./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1347: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1351: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1351: cat stderr -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1350: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: - | (# + 1) = 1111 -stderr: -stderr: -./calc.at:1351: $PREPARSER ./calc input -stderr: -./calc.at:1350: cat stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Stack now 0 8 23 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) -Stack now 0 -./calc.at:1353: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -1.2: syntax error: invalid character: '#' -./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.11-17: error: null divisor -1.6: syntax error: invalid character: '#' -1.2: syntax error: invalid character: '#' -./calc.at:1354: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: - | (1 + #) = 1111 -./calc.at:1350: $PREPARSER ./calc input -./calc.at:1353: cat stderr -./calc.at:1347: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1354: cat stderr -1.6: syntax error: invalid character: '#' -./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1351: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -input: -1.6: syntax error: invalid character: '#' -./calc.at:1347: cat stderr -./calc.at:1351: cat stderr -./calc.at:1350: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1348: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -480. calc.at:1347: ok - | error -./calc.at:1354: $PREPARSER ./calc input - | (!!) + (1 2) = 1 -stderr: -./calc.at:1353: $PREPARSER ./calc input -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -Stack now 0 -./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '!' (1.1: ) -Shifting token '!' (1.1: ) -Entering state 5 -Stack now 0 4 5 -Reading a token -Next token is token '!' (1.1: ) -Shifting token '!' (1.1: ) -Entering state 16 -Stack now 0 4 5 16 -Reducing stack by rule 16 (line 121): - $1 = token '!' (1.1: ) - $2 = token '!' (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token "number" (1.1: 2) -syntax error -Error: popping nterm exp (1.1: 1) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token "number" (1.1: 2) -Error: discarding token "number" (1.1: 2) -Error: popping token error (1.1: ) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1111) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 6 (line 82): - $1 = nterm exp (1.1: 2222) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1) -error: 2222 != 1 --> $$ = nterm exp (1.1: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 2222) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -Stack now 0 -./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - -./calc.at:1350: cat stderr -input: -./calc.at:1348: cat stderr - | (1 + # + 1) = 1111 -stderr: -./calc.at:1351: $PREPARSER ./calc input -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '!' (1.1: ) -Shifting token '!' (1.1: ) -Entering state 5 -Stack now 0 4 5 -Reading a token -Next token is token '!' (1.1: ) -Shifting token '!' (1.1: ) -Entering state 16 -Stack now 0 4 5 16 -Reducing stack by rule 16 (line 121): - $1 = token '!' (1.1: ) - $2 = token '!' (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token "number" (1.1: 2) -syntax error -Error: popping nterm exp (1.1: 1) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token "number" (1.1: 2) -Error: discarding token "number" (1.1: 2) -Error: popping token error (1.1: ) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1111) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 6 (line 82): - $1 = nterm exp (1.1: 2222) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1) -error: 2222 != 1 --> $$ = nterm exp (1.1: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 2222) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) -input: - | (# + 1) = 1111 -./calc.at:1354: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1350: $PREPARSER ./calc input -input: - | (1 + 1) / (1 - 1) -stderr: -./calc.at:1348: $PREPARSER ./calc input -./calc.at:1354: cat stderr -stderr: -stderr: -1.2: syntax error: invalid character: '#' -1.6: syntax error: invalid character: '#' -./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.11-17: error: null divisor -./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -1.2: syntax error: invalid character: '#' -1.6: syntax error: invalid character: '#' -./calc.at:1350: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: - | 1 = 2 = 3 -./calc.at:1351: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1354: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 19 -Error: popping token '=' (1.3: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) -Stack now 0 -./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1353: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1350: cat stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 19 -Error: popping token '=' (1.3: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) -Stack now 0 -489. calc.at:1360: testing Calculator api.pure parse.error=detailed %debug %locations %header api.prefix={calc} %verbose %yacc %parse-param {semantic_value *result}{int *count}{int *nerrs} ... -./calc.at:1360: - if "$POSIXLY_CORRECT_IS_EXPORTED"; then - sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y - else - mv calc.y.tmp calc.y - fi - - -stderr: -./calc.at:1351: cat stderr -./calc.at:1354: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -1.11-17: error: null divisor -input: - | (1 + 1) / (1 - 1) -./calc.at:1351: $PREPARSER ./calc input - | (1 + # + 1) = 1111 -./calc.at:1350: $PREPARSER ./calc input -stderr: -./calc.at:1353: cat stderr -1.6: syntax error: invalid character: '#' -./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1354: cat stderr -1.6: syntax error: invalid character: '#' -stderr: -./calc.at:1350: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1350: cat stderr -./calc.at:1360: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -./calc.at:1348: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.11-17: error: null divisor -./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1348: cat stderr - | - | +1 -./calc.at:1354: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 96): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) -Stack now 0 -./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.11-17: error: null divisor -481. calc.at:1348: ok -input: -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 96): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) -Stack now 0 -input: -./calc.at:1351: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1354: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (- *) + (1 2) = 1 -./calc.at:1353: $PREPARSER ./calc input - - | (1 + 1) / (1 - 1) -./calc.at:1351: cat stderr -./calc.at:1350: $PREPARSER ./calc input -./calc.at:1360: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '-' (1.1: ) -Shifting token '-' (1.1: ) -Entering state 2 -Stack now 0 4 2 -Reading a token -Next token is token '*' (1.1: ) -syntax error -Shifting token error (1.1: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 120): - $1 = token '-' (1.1: ) - $2 = token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token "number" (1.1: 2) -syntax error -Error: popping nterm exp (1.1: 1) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token "number" (1.1: 2) -Error: discarding token "number" (1.1: 2) -Error: popping token error (1.1: ) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1111) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 6 (line 82): - $1 = nterm exp (1.1: 2222) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1) -error: 2222 != 1 --> $$ = nterm exp (1.1: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 2222) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) -./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1354: cat stderr -stderr: -./calc.at:1354: $PREPARSER ./calc /dev/null -483. calc.at:1351: ok -stdout: -stderr: -1.11-17: error: null divisor -./calc.at:1355: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.11-17: error: null divisor -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Now at end of input. -1.1: syntax error, unexpected end of file -Cleanup: discarding lookahead token end of file (1.1: ) -Stack now 0 -stderr: -./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '-' (1.1: ) -Shifting token '-' (1.1: ) -Entering state 2 -Stack now 0 4 2 -Reading a token -Next token is token '*' (1.1: ) -syntax error -Shifting token error (1.1: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 120): - $1 = token '-' (1.1: ) - $2 = token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token "number" (1.1: 2) -syntax error -Error: popping nterm exp (1.1: 1) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token "number" (1.1: 2) -Error: discarding token "number" (1.1: 2) -Error: popping token error (1.1: ) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1111) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 6 (line 82): - $1 = nterm exp (1.1: 2222) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1) -error: 2222 != 1 --> $$ = nterm exp (1.1: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 2222) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) - -./calc.at:1355: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c calc.h - -./calc.at:1353: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1350: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1355: $PREPARSER ./calc input -490. calc.at:1362: testing Calculator %no-lines api.pure parse.error=detailed %debug %locations %header api.prefix={calc} %verbose %yacc %parse-param {semantic_value *result}{int *count}{int *nerrs} ... -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack by rule 9 (line 120): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.13: 7) -Shifting token number (1.13: 7) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.13: 7) --> $$ = nterm exp (1.13: 7) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.14-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-9: 7) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13: 7) --> $$ = nterm exp (1.1-13: 7) +Next token is token '\n' (1.14-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-9: 7) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13: 7) +-> $$ = nterm exp (1.1-13: 7) Entering state 8 Stack now 0 8 Next token is token '\n' (1.14-2.0: ) @@ -38661,14 +36692,14 @@ Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) -Reducing stack by rule 11 (line 136): +Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) -Reducing stack by rule 9 (line 120): +Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) @@ -38676,7 +36707,7 @@ Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) -Reducing stack by rule 7 (line 118): +Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) @@ -38704,7 +36735,7 @@ Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) -Reducing stack by rule 11 (line 136): +Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) @@ -38782,7 +36813,7 @@ Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) -Reducing stack by rule 12 (line 137): +Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) @@ -38790,7 +36821,7 @@ Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) -Reducing stack by rule 11 (line 136): +Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) @@ -38817,7 +36848,7 @@ Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) -Reducing stack by rule 11 (line 136): +Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) @@ -38869,7 +36900,7 @@ Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) -Reducing stack by rule 11 (line 136): +Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) @@ -38879,7 +36910,7 @@ Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 -Reducing stack by rule 13 (line 138): +Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) @@ -38903,7 +36934,7 @@ Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) -Reducing stack by rule 12 (line 137): +Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) @@ -38992,21 +37023,21 @@ Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 136): +Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 136): +Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 136): +Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) @@ -39033,7 +37064,7 @@ Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) -Reducing stack by rule 11 (line 136): +Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) @@ -39106,7 +37137,7 @@ Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) -Reducing stack by rule 8 (line 119): +Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) @@ -39129,7 +37160,7 @@ Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) -Reducing stack by rule 8 (line 119): +Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) @@ -39157,7 +37188,7 @@ Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) -Reducing stack by rule 11 (line 136): +Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) @@ -39234,7 +37265,7 @@ Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) -Reducing stack by rule 8 (line 119): +Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) @@ -39245,7 +37276,7 @@ Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 -Reducing stack by rule 13 (line 138): +Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) @@ -39254,7 +37285,7 @@ Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) -Reducing stack by rule 8 (line 119): +Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) @@ -39358,7 +37389,7 @@ Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) -Reducing stack by rule 12 (line 137): +Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) @@ -39366,7 +37397,7 @@ Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) -Reducing stack by rule 12 (line 137): +Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) @@ -39444,7 +37475,7 @@ Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) -Reducing stack by rule 12 (line 137): +Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) @@ -39455,7 +37486,7 @@ Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 -Reducing stack by rule 13 (line 138): +Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) @@ -39479,7 +37510,7 @@ Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) -Reducing stack by rule 12 (line 137): +Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) @@ -39533,36 +37564,16 @@ Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1350: cat stderr -./calc.at:1362: - if "$POSIXLY_CORRECT_IS_EXPORTED"; then - sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y - else - mv calc.y.tmp calc.y - fi - - +./calc.at:1358: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS +./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 2 +./calc.at:1354: $PREPARSER ./calc input + | (* *) + (*) + (*) +./calc.at:1350: $PREPARSER ./calc input +./calc.at:1353: $PREPARSER ./calc /dev/null stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Now at end of input. -1.1: syntax error, unexpected end of file -Cleanup: discarding lookahead token end of file (1.1: ) -Stack now 0 -./calc.at:1353: cat stderr -491. calc.at:1363: testing Calculator %no-lines api.pure parse.error=verbose %debug %locations %header api.prefix={calc} %verbose %yacc %parse-param {semantic_value *result}{int *count}{int *nerrs} ... -./calc.at:1363: - if "$POSIXLY_CORRECT_IS_EXPORTED"; then - sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y - else - mv calc.y.tmp calc.y - fi - - -./calc.at:1354: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -39572,8 +37583,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -./calc.at:1354: cat stderr stderr: Starting parse Entering state 0 @@ -39589,6 +37598,33 @@ Entering state 8 Stack now 0 8 Reading a token +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token number (1.3: 2) +Stack now 0 +stderr: +./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.6: syntax error: invalid character: '#' +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 @@ -39620,7 +37656,7 @@ Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) -Reducing stack by rule 9 (line 120): +Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) @@ -39628,7 +37664,7 @@ Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 118): +Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) @@ -39720,14 +37756,14 @@ Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) -Reducing stack by rule 11 (line 136): +Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) -Reducing stack by rule 9 (line 120): +Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) @@ -39735,7 +37771,7 @@ Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) -Reducing stack by rule 7 (line 118): +Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) @@ -39763,7 +37799,7 @@ Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) -Reducing stack by rule 11 (line 136): +Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) @@ -39841,7 +37877,7 @@ Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) -Reducing stack by rule 12 (line 137): +Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) @@ -39849,7 +37885,7 @@ Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) -Reducing stack by rule 11 (line 136): +Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) @@ -39876,7 +37912,7 @@ Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) -Reducing stack by rule 11 (line 136): +Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) @@ -39928,7 +37964,7 @@ Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) -Reducing stack by rule 11 (line 136): +Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) @@ -39938,7 +37974,7 @@ Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 -Reducing stack by rule 13 (line 138): +Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) @@ -39962,7 +37998,7 @@ Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) -Reducing stack by rule 12 (line 137): +Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) @@ -40051,21 +38087,21 @@ Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 136): +Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 136): +Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 136): +Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) @@ -40092,7 +38128,7 @@ Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) -Reducing stack by rule 11 (line 136): +Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) @@ -40165,7 +38201,7 @@ Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) -Reducing stack by rule 8 (line 119): +Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) @@ -40188,7 +38224,7 @@ Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) -Reducing stack by rule 8 (line 119): +Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) @@ -40216,7 +38252,7 @@ Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) -Reducing stack by rule 11 (line 136): +Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) @@ -40293,7 +38329,7 @@ Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) -Reducing stack by rule 8 (line 119): +Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) @@ -40304,7 +38340,7 @@ Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 -Reducing stack by rule 13 (line 138): +Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) @@ -40313,7 +38349,7 @@ Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) -Reducing stack by rule 8 (line 119): +Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) @@ -40417,7 +38453,7 @@ Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) -Reducing stack by rule 12 (line 137): +Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) @@ -40425,7 +38461,7 @@ Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) -Reducing stack by rule 12 (line 137): +Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) @@ -40503,7 +38539,7 @@ Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) -Reducing stack by rule 12 (line 137): +Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) @@ -40514,7 +38550,7 @@ Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 -Reducing stack by rule 13 (line 138): +Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) @@ -40538,7 +38574,7 @@ Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) -Reducing stack by rule 12 (line 137): +Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) @@ -40592,972 +38628,26 @@ Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1355: $EGREP -c -v 'Return for a new token:|LAC:' stderr -482. calc.at:1350: ok -./calc.at:1362: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -input: -./calc.at:1363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y - | (* *) + (*) + (*) -./calc.at:1353: $PREPARSER ./calc input - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1354: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '*' (1.1: ) -syntax error -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.1: ) -syntax error -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '+' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1111) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.1: ) -syntax error -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 2222) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 3333) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 3333) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) -input: -./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 2 -./calc.at:1355: $PREPARSER ./calc input +./calc.at:1357: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: stderr: +./calc.at:1351: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token number (1.7: 1) -Shifting token number (1.7: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Reading a token -Next token is token number (1.11: 1) -Shifting token number (1.11: 1) -Entering state 1 -Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.11: 1) --> $$ = nterm exp (1.11: 1) -Entering state 30 -Stack now 0 8 21 4 12 21 30 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Reading a token -Next token is token number (1.15: 1) -Shifting token number (1.15: 1) -Entering state 1 -Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 30 -Stack now 0 8 21 4 12 21 30 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.7-15: 3) -Stack now 0 8 21 4 -Shifting token error (1.7-18: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '+' (1.20: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Error: popping token error (1.23: ) -Stack now 0 8 21 4 -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Error: popping token error (1.23: ) -Stack now 0 8 21 4 -Shifting token error (1.23-25: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) -Error: popping token error (1.23-25: ) -Stack now 0 8 21 4 -Shifting token error (1.23-27: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '+' (1.30: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token number (1.33: 1) -Shifting token number (1.33: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 22 -Stack now 0 8 21 4 12 22 -Reading a token -Next token is token number (1.37: 2) -Shifting token number (1.37: 2) -Entering state 1 -Stack now 0 8 21 4 12 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 31 -Stack now 0 8 21 4 12 22 31 -Reading a token -Next token is token '*' (1.39: ) -Reducing stack by rule 9 (line 120): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 22 -Stack now 0 8 21 4 12 22 -Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.33-37: 2) -Stack now 0 8 21 4 -Shifting token error (1.33-41: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Error: popping token error (1.33-41: ) -Stack now 0 8 21 4 -Shifting token error (1.33-41: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.44: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.46: 1) -Shifting token number (1.46: 1) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.46: 1) --> $$ = nterm exp (1.46: 1) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.47-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +Cleanup: discarding lookahead token "end of input" (1.1: ) +Stack now 0 +./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +./calc.at:1355: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token number (1.7: 1) -Shifting token number (1.7: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Reading a token -Next token is token number (1.11: 1) -Shifting token number (1.11: 1) -Entering state 1 -Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.11: 1) --> $$ = nterm exp (1.11: 1) -Entering state 30 -Stack now 0 8 21 4 12 21 30 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Reading a token -Next token is token number (1.15: 1) -Shifting token number (1.15: 1) -Entering state 1 -Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 30 -Stack now 0 8 21 4 12 21 30 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.7-15: 3) -Stack now 0 8 21 4 -Shifting token error (1.7-18: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '+' (1.20: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Error: popping token error (1.23: ) -Stack now 0 8 21 4 -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Error: popping token error (1.23: ) -Stack now 0 8 21 4 -Shifting token error (1.23-25: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) -Error: popping token error (1.23-25: ) -Stack now 0 8 21 4 -Shifting token error (1.23-27: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '+' (1.30: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token number (1.33: 1) -Shifting token number (1.33: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 22 -Stack now 0 8 21 4 12 22 -Reading a token -Next token is token number (1.37: 2) -Shifting token number (1.37: 2) -Entering state 1 -Stack now 0 8 21 4 12 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 31 -Stack now 0 8 21 4 12 22 31 -Reading a token -Next token is token '*' (1.39: ) -Reducing stack by rule 9 (line 120): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 22 -Stack now 0 8 21 4 12 22 -Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.33-37: 2) -Stack now 0 8 21 4 -Shifting token error (1.33-41: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Error: popping token error (1.33-41: ) -Stack now 0 8 21 4 -Shifting token error (1.33-41: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.44: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.46: 1) -Shifting token number (1.46: 1) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.46: 1) --> $$ = nterm exp (1.46: 1) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.47-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1354: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '*' (1.1: ) -syntax error -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.1: ) -syntax error -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '+' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1111) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.1: ) -syntax error -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 8 21 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 2222) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 3333) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 3333) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) - +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Starting parse Entering state 0 Stack now 0 @@ -41578,301 +38668,20 @@ Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 -./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1354: cat stderr +./calc.at:1355: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c calc.h + stderr: -./calc.at:1363: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS input: -stdout: - | (!!) + (1 2) = 1 -./calc.at:1354: $PREPARSER ./calc input -./types.at:139: $PREPARSER ./test -stderr: -stderr: -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Stack now 0 4 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 16 -Stack now 0 4 5 16 -Reducing stack by rule 16 (line 141): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Stack now 0 4 -Shifting token error (1.2-3: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token number (1.9: 1) -Shifting token number (1.9: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 1) --> $$ = nterm exp (1.9: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token number (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Stack now 0 8 21 4 -Shifting token error (1.9-11: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token number (1.11: 2) -Error: discarding token number (1.11: 2) -Error: popping token error (1.9-11: ) -Stack now 0 8 21 4 -Shifting token error (1.9-11: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.14: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Stack now 0 4 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 16 -Stack now 0 4 5 16 -Reducing stack by rule 16 (line 141): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Stack now 0 4 -Shifting token error (1.2-3: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token number (1.9: 1) -Shifting token number (1.9: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 1) --> $$ = nterm exp (1.9: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token number (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Stack now 0 8 21 4 -Shifting token error (1.9-11: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token number (1.11: 2) -Error: discarding token number (1.11: 2) -Error: popping token error (1.9-11: ) -Stack now 0 8 21 4 -Shifting token error (1.9-11: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.14: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1353: "$PERL" -pi -e 'use strict; +./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -41882,50 +38691,20 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + | 1 + 2 * 3 + !+ ++ +input: +./calc.at:1351: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token number (1.3: 2) +Now at end of input. +syntax error +Cleanup: discarding lookahead token "end of input" (1.1: ) Stack now 0 -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1354: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1353: cat stderr -./calc.at:1362: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS -492. calc.at:1364: testing Calculator %no-lines api.pure parse.error=verbose %debug %locations %defines api.prefix={calc} %verbose %yacc %parse-param {semantic_value *result}{int *count}{int *nerrs} ... -./calc.at:1364: - if "$POSIXLY_CORRECT_IS_EXPORTED"; then - sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y - else - mv calc.y.tmp calc.y - fi - - -./calc.at:1364: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -./calc.at:1355: "$PERL" -pi -e 'use strict; + | 1 2 +./calc.at:1357: $PREPARSER ./calc input +./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -41935,397 +38714,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -450. types.at:139: ok -./calc.at:1354: cat stderr -input: -input: - | (- *) + (1 2) = 1 -./calc.at:1354: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Stack now 0 4 2 -Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 140): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2-4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token number (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Stack now 0 8 21 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token number (1.12: 2) -Error: discarding token number (1.12: 2) -Error: popping token error (1.10-12: ) -Stack now 0 8 21 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.15: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.17: 1) --> $$ = nterm exp (1.17: 1) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 + 2 * 3 + !+ ++ -./calc.at:1353: $PREPARSER ./calc input -./calc.at:1355: cat stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Stack now 0 4 2 -Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 140): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2-4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token number (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Stack now 0 8 21 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token number (1.12: 2) -Error: discarding token number (1.12: 2) -Error: popping token error (1.10-12: ) -Stack now 0 8 21 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.15: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.17: 1) --> $$ = nterm exp (1.17: 1) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token "number" (1.1: 2) -Shifting token "number" (1.1: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 2) --> $$ = nterm exp (1.1: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token "number" (1.1: 3) -Shifting token "number" (1.1: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 3) --> $$ = nterm exp (1.1: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '+' (1.1: ) -Reducing stack by rule 9 (line 100): - $1 = nterm exp (1.1: 2) - $2 = token '*' (1.1: ) - $3 = nterm exp (1.1: 3) --> $$ = nterm exp (1.1: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 6) --> $$ = nterm exp (1.1: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.1: ) -Shifting token '!' (1.1: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 14 -Stack now 0 8 21 5 14 -Reducing stack by rule 17 (line 122): - $1 = token '!' (1.1: ) - $2 = token '+' (1.1: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.1: ) -Cleanup: popping nterm exp (1.1: 7) -./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -42336,282 +38725,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1//2 -./calc.at:1364: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS -./calc.at:1355: $PREPARSER ./calc input -./calc.at:1354: cat stderr stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Stack now 0 8 23 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) -Stack now 0 -./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -stderr: - | (* *) + (*) + (*) -./calc.at:1354: $PREPARSER ./calc input -stderr: - -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token "number" (1.1: 2) -Shifting token "number" (1.1: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 2) --> $$ = nterm exp (1.1: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token "number" (1.1: 3) -Shifting token "number" (1.1: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 3) --> $$ = nterm exp (1.1: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '+' (1.1: ) -Reducing stack by rule 9 (line 100): - $1 = nterm exp (1.1: 2) - $2 = token '*' (1.1: ) - $3 = nterm exp (1.1: 3) --> $$ = nterm exp (1.1: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 6) --> $$ = nterm exp (1.1: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.1: ) -Shifting token '!' (1.1: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 14 -Stack now 0 8 21 5 14 -Reducing stack by rule 17 (line 122): - $1 = token '!' (1.1: ) - $2 = token '+' (1.1: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.1: ) -Cleanup: popping nterm exp (1.1: 7) -stderr: -stdout: -./calc.at:1353: $EGREP -c -v 'Return for a new token:|LAC:' stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) -Error: popping token error (1.10: ) -Stack now 0 8 21 4 -Shifting token error (1.10: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) -Error: popping token error (1.16: ) -Stack now 0 8 21 4 -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1357: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -stderr: +./calc.at:1348: cat stderr +./calc.at:1350: cat stderr Starting parse Entering state 0 Stack now 0 @@ -42626,205 +38744,13 @@ Entering state 8 Stack now 0 8 Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Stack now 0 8 23 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Stack now 0 8 +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) -Stack now 0 -./calc.at:1357: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c calc.h - -stderr: -Starting parse -Entering state 0 +Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) -Error: popping token error (1.10: ) -Stack now 0 8 21 4 -Shifting token error (1.10: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) -Error: popping token error (1.16: ) -Stack now 0 8 21 4 -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1355: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1354: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1354: cat stderr -./calc.at:1355: cat stderr -input: +./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -42838,102 +38764,46 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -./calc.at:1357: $PREPARSER ./calc input -input: -input: - | 1 + 2 * 3 + !- ++ - | 1 + 2 * 3 + !+ ++ +stderr: +./calc.at:1355: $PREPARSER ./calc input +./calc.at:1354: cat stderr +./calc.at:1351: $EGREP -c -v 'Return for a new token:|LAC:' stderr +stderr: +./calc.at:1353: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: input: -./calc.at:1353: $PREPARSER ./calc input -./calc.at:1354: $PREPARSER ./calc input stderr: +input: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token "number" (1.1: 2) -Shifting token "number" (1.1: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 2) --> $$ = nterm exp (1.1: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token "number" (1.1: 3) -Shifting token "number" (1.1: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 3) --> $$ = nterm exp (1.1: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '+' (1.1: ) -Reducing stack by rule 9 (line 100): - $1 = nterm exp (1.1: 2) - $2 = token '*' (1.1: ) - $3 = nterm exp (1.1: 3) --> $$ = nterm exp (1.1: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 6) --> $$ = nterm exp (1.1: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.1: ) -Shifting token '!' (1.1: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '-' (1.1: ) -Shifting token '-' (1.1: ) -Entering state 13 -Stack now 0 8 21 5 13 -Reducing stack by rule 18 (line 123): - $1 = token '!' (1.1: ) - $2 = token '-' (1.1: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.1: ) -Cleanup: popping nterm exp (1.1: 7) -./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -493. calc.at:1367: testing Calculator parse.error=custom ... -stderr: -stderr: -stderr: -./calc.at:1367: mv calc.y.tmp calc.y - +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token number (1.3: 2) +Stack now 0 + | 1 + 2 * 3 + !+ ++ Starting parse Entering state 0 Stack now 0 @@ -42979,7 +38849,7 @@ Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) -Reducing stack by rule 9 (line 114): +Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) @@ -42987,7 +38857,7 @@ Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) @@ -43079,14 +38949,14 @@ Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) -Reducing stack by rule 11 (line 124): +Reducing stack by rule 11 (line 136): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) -Reducing stack by rule 9 (line 114): +Reducing stack by rule 9 (line 120): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) @@ -43094,7 +38964,7 @@ Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 118): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) @@ -43122,7 +38992,7 @@ Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) -Reducing stack by rule 11 (line 124): +Reducing stack by rule 11 (line 136): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) @@ -43200,7 +39070,7 @@ Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) -Reducing stack by rule 12 (line 125): +Reducing stack by rule 12 (line 137): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) @@ -43208,7 +39078,7 @@ Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) -Reducing stack by rule 11 (line 124): +Reducing stack by rule 11 (line 136): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) @@ -43235,7 +39105,7 @@ Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) -Reducing stack by rule 11 (line 124): +Reducing stack by rule 11 (line 136): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) @@ -43287,7 +39157,7 @@ Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) -Reducing stack by rule 11 (line 124): +Reducing stack by rule 11 (line 136): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) @@ -43297,7 +39167,7 @@ Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 -Reducing stack by rule 13 (line 126): +Reducing stack by rule 13 (line 138): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) @@ -43321,7 +39191,7 @@ Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) -Reducing stack by rule 12 (line 125): +Reducing stack by rule 12 (line 137): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) @@ -43410,21 +39280,21 @@ Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 124): +Reducing stack by rule 11 (line 136): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 124): +Reducing stack by rule 11 (line 136): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 124): +Reducing stack by rule 11 (line 136): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) @@ -43451,7 +39321,7 @@ Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) -Reducing stack by rule 11 (line 124): +Reducing stack by rule 11 (line 136): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) @@ -43524,7 +39394,7 @@ Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) -Reducing stack by rule 8 (line 113): +Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) @@ -43547,7 +39417,7 @@ Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) -Reducing stack by rule 8 (line 113): +Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) @@ -43575,7 +39445,7 @@ Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) -Reducing stack by rule 11 (line 124): +Reducing stack by rule 11 (line 136): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) @@ -43652,7 +39522,7 @@ Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) -Reducing stack by rule 8 (line 113): +Reducing stack by rule 8 (line 119): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) @@ -43663,7 +39533,7 @@ Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 -Reducing stack by rule 13 (line 126): +Reducing stack by rule 13 (line 138): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) @@ -43672,7 +39542,7 @@ Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) -Reducing stack by rule 8 (line 113): +Reducing stack by rule 8 (line 119): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) @@ -43776,7 +39646,7 @@ Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) -Reducing stack by rule 12 (line 125): +Reducing stack by rule 12 (line 137): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) @@ -43784,7 +39654,7 @@ Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) -Reducing stack by rule 12 (line 125): +Reducing stack by rule 12 (line 137): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) @@ -43862,7 +39732,7 @@ Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) -Reducing stack by rule 12 (line 125): +Reducing stack by rule 12 (line 137): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) @@ -43873,7 +39743,7 @@ Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 -Reducing stack by rule 13 (line 126): +Reducing stack by rule 13 (line 138): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) @@ -43897,7 +39767,7 @@ Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) -Reducing stack by rule 12 (line 125): +Reducing stack by rule 12 (line 137): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) @@ -43951,100 +39821,27 @@ Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token "number" (1.1: 2) -Shifting token "number" (1.1: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 2) --> $$ = nterm exp (1.1: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token "number" (1.1: 3) -Shifting token "number" (1.1: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 3) --> $$ = nterm exp (1.1: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '+' (1.1: ) -Reducing stack by rule 9 (line 100): - $1 = nterm exp (1.1: 2) - $2 = token '*' (1.1: ) - $3 = nterm exp (1.1: 3) --> $$ = nterm exp (1.1: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 6) --> $$ = nterm exp (1.1: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.1: ) -Shifting token '!' (1.1: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '-' (1.1: ) -Shifting token '-' (1.1: ) -Entering state 13 -Stack now 0 8 21 5 13 -Reducing stack by rule 18 (line 123): - $1 = token '!' (1.1: ) - $2 = token '-' (1.1: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.1: ) -Cleanup: popping nterm exp (1.1: 7) -./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | error -./calc.at:1367: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -./calc.at:1355: $PREPARSER ./calc input + | (1 + 1) / (1 - 1) +./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1348: $PREPARSER ./calc input +./calc.at:1350: $PREPARSER ./calc input +stdout: +input: stderr: stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -Stack now 0 + | 1//2 +./calc.at:1354: $PREPARSER ./calc input +./types.at:139: $PREPARSER ./test +./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +1.11-17: error: null divisor +stderr: +./calc.at:1348: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +stderr: + | 1 + 2 * 3 + !- ++ +./calc.at:1351: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -44090,7 +39887,7 @@ Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) -Reducing stack by rule 9 (line 114): +Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) @@ -44098,7 +39895,7 @@ Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) @@ -44190,14 +39987,14 @@ Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) -Reducing stack by rule 11 (line 124): +Reducing stack by rule 11 (line 136): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) -Reducing stack by rule 9 (line 114): +Reducing stack by rule 9 (line 120): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) @@ -44205,7 +40002,7 @@ Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 118): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) @@ -44233,7 +40030,7 @@ Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) -Reducing stack by rule 11 (line 124): +Reducing stack by rule 11 (line 136): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) @@ -44311,7 +40108,7 @@ Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) -Reducing stack by rule 12 (line 125): +Reducing stack by rule 12 (line 137): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) @@ -44319,7 +40116,7 @@ Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) -Reducing stack by rule 11 (line 124): +Reducing stack by rule 11 (line 136): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) @@ -44346,7 +40143,7 @@ Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) -Reducing stack by rule 11 (line 124): +Reducing stack by rule 11 (line 136): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) @@ -44398,7 +40195,7 @@ Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) -Reducing stack by rule 11 (line 124): +Reducing stack by rule 11 (line 136): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) @@ -44408,7 +40205,7 @@ Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 -Reducing stack by rule 13 (line 126): +Reducing stack by rule 13 (line 138): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) @@ -44432,7 +40229,7 @@ Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) -Reducing stack by rule 12 (line 125): +Reducing stack by rule 12 (line 137): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) @@ -44521,21 +40318,21 @@ Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 124): +Reducing stack by rule 11 (line 136): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 124): +Reducing stack by rule 11 (line 136): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 124): +Reducing stack by rule 11 (line 136): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) @@ -44562,7 +40359,7 @@ Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) -Reducing stack by rule 11 (line 124): +Reducing stack by rule 11 (line 136): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) @@ -44635,7 +40432,7 @@ Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) -Reducing stack by rule 8 (line 113): +Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) @@ -44658,7 +40455,7 @@ Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) -Reducing stack by rule 8 (line 113): +Reducing stack by rule 8 (line 119): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) @@ -44686,7 +40483,7 @@ Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) -Reducing stack by rule 11 (line 124): +Reducing stack by rule 11 (line 136): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) @@ -44763,7 +40560,7 @@ Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) -Reducing stack by rule 8 (line 113): +Reducing stack by rule 8 (line 119): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) @@ -44774,7 +40571,7 @@ Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 -Reducing stack by rule 13 (line 126): +Reducing stack by rule 13 (line 138): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) @@ -44783,7 +40580,7 @@ Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) -Reducing stack by rule 8 (line 113): +Reducing stack by rule 8 (line 119): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) @@ -44887,7 +40684,7 @@ Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) -Reducing stack by rule 12 (line 125): +Reducing stack by rule 12 (line 137): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) @@ -44895,7 +40692,7 @@ Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) -Reducing stack by rule 12 (line 125): +Reducing stack by rule 12 (line 137): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) @@ -44973,7 +40770,7 @@ Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) -Reducing stack by rule 12 (line 125): +Reducing stack by rule 12 (line 137): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) @@ -44984,7 +40781,7 @@ Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 -Reducing stack by rule 13 (line 126): +Reducing stack by rule 13 (line 138): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) @@ -44997,7 +40794,17 @@ Entering state 24 Stack now 0 6 8 24 Reading a token -Next token is token number (13.7: 3) +Next toke./calc.at:1357: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +n is token number (13.7: 3) Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 @@ -45008,7 +40815,7 @@ Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) -Reducing stack by rule 12 (line 125): +Reducing stack by rule 12 (line 137): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) @@ -45076,88 +40883,34 @@ Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Stack now 0 8 23 Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 120): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Stack now 0 8 21 5 14 -Reducing stack by rule 17 (line 142): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '/' (1.3: ) +Stack now 0 +./calc.at:1353: cat stderr +./calc.at:1355: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1350: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1357: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1357: cat stderr +./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.11-17: error: null divisor input: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -Stack now 0 - | 1 2 -./calc.at:1357: $PREPARSER ./calc input stderr: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1353: $PREPARSER ./calc input +449. types.at:139: ok Starting parse Entering state 0 Stack now 0 @@ -45172,14 +40925,30 @@ Entering state 8 Stack now 0 8 Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Stack now 0 8 23 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 -Cleanup: discarding lookahead token number (1.3: 2) +Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 -./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1353: "$PERL" -pi -e 'use strict; +stderr: +input: +input: +input: + | 1 + 2 * 3 + !- ++ + | 1 2 +stderr: +./calc.at:1350: $PREPARSER ./calc input +./calc.at:1355: $PREPARSER ./calc input + | 1//2 +./calc.at:1348: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -45189,87 +40958,326 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1357: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token ')' (1.1: ) +syntax error +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 8 21 4 12 21 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 30 -Stack now 0 8 21 30 +Stack now 0 8 21 4 12 21 30 Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 +Next token is token '+' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1) +-> $$ = nterm exp (1.1: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 4 12 21 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 +Stack now 0 8 21 4 12 21 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 30 +Stack now 0 8 21 4 12 21 30 Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 120): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) +Next token is token '+' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 2) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1) +-> $$ = nterm exp (1.1: 3) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token ')' (1.1: ) +syntax error +Error: popping token '+' (1.1: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.1: 3) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) +Reading a token +Next token is token '+' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1111) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 8 21 4 Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Stack now 0 8 21 5 14 -Reducing stack by rule 17 (line 142): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) +Next token is token '*' (1.1: ) +syntax error +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 2222) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token '*' (1.1: ) +Shifting token '*' (1.1: ) +Entering state 22 +Stack now 0 8 21 4 12 22 +Reading a token +Next token is token "number" (1.1: 2) +Shifting token "number" (1.1: 2) +Entering state 1 +Stack now 0 8 21 4 12 22 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 2) +-> $$ = nterm exp (1.1: 2) +Entering state 31 +Stack now 0 8 21 4 12 22 31 +Reading a token +Next token is token '*' (1.1: ) +Reducing stack by rule 9 (line 100): + $1 = nterm exp (1.1: 1) + $2 = token '*' (1.1: ) + $3 = nterm exp (1.1: 2) +-> $$ = nterm exp (1.1: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '*' (1.1: ) +Shifting token '*' (1.1: ) +Entering state 22 +Stack now 0 8 21 4 12 22 +Reading a token +Next token is token '*' (1.1: ) +syntax error +Error: popping token '*' (1.1: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.1: 2) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 3333) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 4444) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.1: ) +Reducing stack by rule 6 (line 82): + $1 = nterm exp (1.1: 4444) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 1) +error: 4444 != 1 +-> $$ = nterm exp (1.1: 4444) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 4444) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token "end of input" (1.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) +./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 @@ -45291,8 +41299,9 @@ Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 -./calc.at:1354: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1355: "$PERL" -pi -e 'use strict; +./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -45302,95 +41311,37 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1353: cat stderr -./calc.at:1355: cat stderr -input: - | 1 + 2 * 3 + !* ++ -./calc.at:1353: $PREPARSER ./calc input -stderr: +./calc.at:1348: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token "number" (1.1: 2) -Shifting token "number" (1.1: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 2) --> $$ = nterm exp (1.1: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token "number" (1.1: 3) -Shifting token "number" (1.1: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 3) --> $$ = nterm exp (1.1: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Stack now 0 8 23 Reading a token -Next token is token '+' (1.1: ) -Reducing stack by rule 9 (line 100): - $1 = nterm exp (1.1: 2) - $2 = token '*' (1.1: ) - $3 = nterm exp (1.1: 3) --> $$ = nterm exp (1.1: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.1: ) -Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 6) --> $$ = nterm exp (1.1: 7) -Entering state 8 +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) Stack now 0 8 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.1: ) -Shifting token '!' (1.1: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) -Entering state 15 -Stack now 0 8 21 5 15 -Reducing stack by rule 19 (line 124): - $1 = token '!' (1.1: ) - $2 = token '*' (1.1: ) -memory exhausted -Stack now 0 8 21 -Cleanup: popping token '+' (1.1: ) -Cleanup: popping nterm exp (1.1: 7) -./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1357: "$PERL" -pi -e 'use strict; +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '/' (1.3: ) +Stack now 0 +./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -45401,64 +41352,132 @@ }eg ' expout || exit 77 stderr: +stderr: +stderr: Starting parse Entering state 0 Stack now 0 Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token ')' (1.1: ) +syntax error +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 -Stack now 0 1 +Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 +Entering state 12 +Stack now 0 8 21 4 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 -Stack now 0 8 21 +Stack now 0 8 21 4 12 21 Reading a token -Next token is token "number" (1.1: 2) -Shifting token "number" (1.1: 2) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Stack now 0 8 21 1 +Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 2) --> $$ = nterm exp (1.1: 2) + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 30 -Stack now 0 8 21 30 +Stack now 0 8 21 4 12 21 30 Reading a token -Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) -Entering state 22 -Stack now 0 8 21 30 22 +Next token is token '+' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1) +-> $$ = nterm exp (1.1: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 4 12 21 Reading a token -Next token is token "number" (1.1: 3) -Shifting token "number" (1.1: 3) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Stack now 0 8 21 30 22 1 +Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 3) --> $$ = nterm exp (1.1: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 30 +Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.1: ) -Reducing stack by rule 9 (line 100): +Reducing stack by rule 7 (line 98): $1 = nterm exp (1.1: 2) - $2 = token '*' (1.1: ) - $3 = nterm exp (1.1: 3) --> $$ = nterm exp (1.1: 6) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1) +-> $$ = nterm exp (1.1: 3) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token ')' (1.1: ) +syntax error +Error: popping token '+' (1.1: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.1: 3) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 +Reading a token Next token is token '+' (1.1: ) Reducing stack by rule 7 (line 98): - $1 = nterm exp (1.1: 1) + $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 6) --> $$ = nterm exp (1.1: 7) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '+' (1.1: ) @@ -45466,155 +41485,194 @@ Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '!' (1.1: ) -Shifting token '!' (1.1: ) -Entering state 5 -Stack now 0 8 21 5 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 8 21 4 Reading a token Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) -Entering state 15 -Stack now 0 8 21 5 15 -Reducing stack by rule 19 (line 124): - $1 = token '!' (1.1: ) - $2 = token '*' (1.1: ) -memory exhausted -Stack now 0 8 21 -Cleanup: popping token '+' (1.1: ) -Cleanup: popping nterm exp (1.1: 7) -input: -./calc.at:1357: cat stderr - | 1 + 2 * 3 + !- ++ -input: -./calc.at:1354: $PREPARSER ./calc input - | 1 = 2 = 3 -./calc.at:1355: $PREPARSER ./calc input -stderr: -./calc.at:1367: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS -Starting parse -Entering state 0 -Stack now 0 +syntax error +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 2222) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 +Stack now 0 8 21 4 12 Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) +Next token is token '*' (1.1: ) +Shifting token '*' (1.1: ) Entering state 22 -Stack now 0 8 21 30 22 +Stack now 0 8 21 4 12 22 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token "number" (1.1: 2) +Shifting token "number" (1.1: 2) Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) +Stack now 0 8 21 4 12 22 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 2) +-> $$ = nterm exp (1.1: 2) Entering state 31 -Stack now 0 8 21 30 22 31 +Stack now 0 8 21 4 12 22 31 Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 120): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 118): +Next token is token '*' (1.1: ) +Reducing stack by rule 9 (line 100): $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 + $2 = token '*' (1.1: ) + $3 = nterm exp (1.1: 2) +-> $$ = nterm exp (1.1: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '*' (1.1: ) +Shifting token '*' (1.1: ) +Entering state 22 +Stack now 0 8 21 4 12 22 Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 +Next token is token '*' (1.1: ) +syntax error +Error: popping token '*' (1.1: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.1: 2) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Stack now 0 8 21 5 13 -Reducing stack by rule 18 (line 143): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -stderr: -./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Stack now 0 +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 30 +Stack now 0 8 21 30 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) +Next token is token '=' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 3333) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 4444) Entering state 8 Stack now 0 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 19 -Error: popping token '=' (1.3: ) +Next token is token '\n' (1.1: ) +Reducing stack by rule 6 (line 82): + $1 = nterm exp (1.1: 4444) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 1) +error: 4444 != 1 +-> $$ = nterm exp (1.1: 4444) +Entering state 8 Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) -Stack now 0 -./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 4444) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token "end of input" (1.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) stderr: +./calc.at:1354: cat stderr Starting parse Entering state 0 Stack now 0 @@ -45629,34 +41687,13 @@ Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 19 -Error: popping token '=' (1.3: ) -Stack now 0 8 +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) +Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 - | 1//2 -./calc.at:1357: $PREPARSER ./calc input -stderr: +./calc.at:1351: cat stderr Starting parse Entering state 0 Stack now 0 @@ -45684,89 +41721,8 @@ Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 -./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 120): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Stack now 0 8 21 5 13 -Reducing stack by rule 18 (line 143): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -stderr: + +481. calc.at:1348: ok ./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -45777,34 +41733,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Stack now 0 8 23 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) -Stack now 0 -./calc.at:1354: "$PERL" -pi -e 'use strict; +input: +./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -45814,9 +41744,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1354: cat stderr -./calc.at:1355: cat stderr -./calc.at:1353: "$PERL" -pi -e 'use strict; + | 1 + 2 * 3 + !* ++ +./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -45826,7 +41755,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1357: "$PERL" -pi -e 'use strict; +./calc.at:1351: $PREPARSER ./calc input +input: +stderr: +./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -45836,101 +41768,58 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | 1 + 2 * 3 + !* ++ -./calc.at:1354: $PREPARSER ./calc input +./calc.at:1355: cat stderr + | error +1.14: memory exhausted +./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: cat stderr +./calc.at:1354: $PREPARSER ./calc input +./calc.at:1350: cat stderr +489. calc.at:1360: testing Calculator api.pure parse.error=detailed %debug %locations %header api.prefix={calc} %verbose %yacc %parse-param {semantic_value *result}{int *count}{int *nerrs} ... +stderr: + stderr: +1.14: memory exhausted +./calc.at:1360: + if "$POSIXLY_CORRECT_IS_EXPORTED"; then + sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y + else + mv calc.y.tmp calc.y + fi + + Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 120): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Stack now 0 8 21 5 15 -Reducing stack by rule 19 (line 144): - $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -input: +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) +Stack now 0 ./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | - | +1 -./calc.at:1355: $PREPARSER ./calc input input: ./calc.at:1353: cat stderr +input: + | 1//2 +input: +./calc.at:1355: $PREPARSER ./calc input + | error +./calc.at:1357: $PREPARSER ./calc input +./calc.at:1351: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: stderr: + | 1 + 2 * 3 + !* ++ +stderr: +./calc.at:1350: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -45945,101 +41834,30 @@ Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Stack now 0 8 23 Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 120): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Stack now 0 8 21 5 15 -Reducing stack by rule 19 (line 144): - $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) - | error -./calc.at:1357: $PREPARSER ./calc input +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '/' (1.3: ) +Stack now 0 +./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 96): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 -./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1351: cat stderr +input: stderr: Starting parse Entering state 0 @@ -46049,11 +41867,50 @@ 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 +./calc.at:1360: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y ./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | (#) + (#) = 2222 + | (!!) + (1 2) = 1 ./calc.at:1353: $PREPARSER ./calc input stderr: +1.14: memory exhausted +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Stack now 0 8 23 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '/' (1.3: ) +Stack now 0 +./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +490. calc.at:1362: testing Calculator %no-lines api.pure parse.error=detailed %debug %locations %header api.prefix={calc} %verbose %yacc %parse-param {semantic_value *result}{int *count}{int *nerrs} ... +./calc.at:1362: + if "$POSIXLY_CORRECT_IS_EXPORTED"; then + sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y + else + mv calc.y.tmp calc.y + fi + + stderr: ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} @@ -46074,13 +41931,18 @@ Entering state 4 Stack now 0 4 Reading a token -syntax error: invalid character: '#' -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Next token is token "invalid token" (1.1: ) -Error: discarding token "invalid token" (1.1: ) -Error: popping token error (1.1: ) +Next token is token '!' (1.1: ) +Shifting token '!' (1.1: ) +Entering state 5 +Stack now 0 4 5 +Reading a token +Next token is token '!' (1.1: ) +Shifting token '!' (1.1: ) +Entering state 16 +Stack now 0 4 5 16 +Reducing stack by rule 16 (line 121): + $1 = token '!' (1.1: ) + $2 = token '!' (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 @@ -46108,12 +41970,25 @@ Entering state 4 Stack now 0 8 21 4 Reading a token -syntax error: invalid character: '#' +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token "number" (1.1: 2) +syntax error +Error: popping nterm exp (1.1: 1) +Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 -Next token is token "invalid token" (1.1: ) -Error: discarding token "invalid token" (1.1: ) +Next token is token "number" (1.1: 2) +Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) @@ -46145,13 +42020,13 @@ Entering state 19 Stack now 0 8 19 Reading a token -Next token is token "number" (1.1: 2222) -Shifting token "number" (1.1: 2222) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 2222) --> $$ = nterm exp (1.1: 2222) + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token @@ -46159,7 +42034,8 @@ Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 2222) + $3 = nterm exp (1.1: 1) +error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 @@ -46187,6 +42063,7 @@ Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: Starting parse Entering state 0 Stack now 0 @@ -46195,9 +42072,25 @@ 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 -./calc.at:1354: cat stderr +stderr: +1.14: memory exhausted + | (#) + (#) = 2222 +./calc.at:1355: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1351: $PREPARSER ./calc input stderr: stderr: +./calc.at:1354: cat stderr +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 @@ -46207,13 +42100,18 @@ Entering state 4 Stack now 0 4 Reading a token -syntax error: invalid character: '#' -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Next token is token "invalid token" (1.1: ) -Error: discarding token "invalid token" (1.1: ) -Error: popping token error (1.1: ) +Next token is token '!' (1.1: ) +Shifting token '!' (1.1: ) +Entering state 5 +Stack now 0 4 5 +Reading a token +Next token is token '!' (1.1: ) +Shifting token '!' (1.1: ) +Entering state 16 +Stack now 0 4 5 16 +Reducing stack by rule 16 (line 121): + $1 = token '!' (1.1: ) + $2 = token '!' (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 @@ -46241,12 +42139,25 @@ Entering state 4 Stack now 0 8 21 4 Reading a token -syntax error: invalid character: '#' +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token "number" (1.1: 2) +syntax error +Error: popping nterm exp (1.1: 1) +Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 -Next token is token "invalid token" (1.1: ) -Error: discarding token "invalid token" (1.1: ) +Next token is token "number" (1.1: 2) +Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) Stack now 0 8 21 4 Shifting token error (1.1: ) @@ -46278,13 +42189,13 @@ Entering state 19 Stack now 0 8 19 Reading a token -Next token is token "number" (1.1: 2222) -Shifting token "number" (1.1: 2222) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 2222) --> $$ = nterm exp (1.1: 2222) + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token @@ -46292,7 +42203,8 @@ Reducing stack by rule 6 (line 82): $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 2222) + $3 = nterm exp (1.1: 1) +error: 2222 != 1 -> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 @@ -46319,34 +42231,7 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 96): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) -Stack now 0 -input: - | (#) + (#) = 2222 -./calc.at:1354: $PREPARSER ./calc input +./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -46357,7 +42242,72 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1350: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1362: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +./calc.at:1355: cat stderr +./calc.at:1350: cat stderr +input: +./calc.at:1357: cat stderr + | 1 = 2 = 3 +./calc.at:1354: $PREPARSER ./calc input stderr: +stderr: +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 19 +Error: popping token '=' (1.3: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 +input: +input: +./calc.at:1360: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS +./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | (#) + (#) = 2222 ./calc.at:1353: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -46368,7 +42318,18 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1355: "$PERL" -pi -e 'use strict; +./calc.at:1350: $PREPARSER ./calc input + | 1 = 2 = 3 + | error +stderr: +./calc.at:1357: $PREPARSER ./calc input +./calc.at:1355: $PREPARSER ./calc input +stderr: +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1351: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -46382,128 +42343,199 @@ Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 19 +Error: popping token '=' (1.3: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 21 -Stack now 0 8 21 +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Stack now 0 8 21 4 +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 28 +Stack now 0 8 19 28 Reading a token -1.8: syntax error: invalid character: '#' -Shifting token error (1.8: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token invalid token (1.8: ) -Error: discarding token invalid token (1.8: ) -Error: popping token error (1.8: ) -Stack now 0 8 21 4 -Shifting token error (1.8: ) -Entering state 11 -Stack now 0 8 21 4 11 +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 19 +Error: popping token '=' (1.3: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 +./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 30 -Stack now 0 8 21 30 +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) +Stack now 0 +./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1351: cat stderr +stderr: +stderr: +./calc.at:1353: cat stderr +./calc.at:1362: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS +stderr: +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.13-16: 2222) -Shifting token number (1.13-16: 2222) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 19 +Error: popping token '=' (1.3: ) Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1354: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Stack now 0 Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1357: cat stderr -./calc.at:1355: cat stderr -./calc.at:1353: cat stderr +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) +Stack now 0 +./calc.at:1354: cat stderr +input: +./calc.at:1350: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1357: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +./calc.at:1355: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (1 + #) = 1111 + | (- *) + (1 2) = 1 +./calc.at:1353: $PREPARSER ./calc input +./calc.at:1351: $PREPARSER ./calc input +stderr: stderr: +input: +./calc.at:1357: cat stderr +./calc.at:1350: cat stderr +1.6: syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 @@ -46513,134 +42545,184 @@ Entering state 4 Stack now 0 4 Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) +Next token is token '-' (1.1: ) +Shifting token '-' (1.1: ) +Entering state 2 +Stack now 0 4 2 +Reading a token +Next token is token '*' (1.1: ) +syntax error +Shifting token error (1.1: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 120): + $1 = token '-' (1.1: ) + $2 = token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.2: ) +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) +Error: popping token error (1.1: ) Stack now 0 4 -Shifting token error (1.2: ) +Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): +Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 21 4 Reading a token -1.8: syntax error: invalid character: '#' -Shifting token error (1.8: ) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token "number" (1.1: 2) +syntax error +Error: popping nterm exp (1.1: 1) +Stack now 0 8 21 4 +Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 -Next token is token invalid token (1.8: ) -Error: discarding token invalid token (1.8: ) -Error: popping token error (1.8: ) +Next token is token "number" (1.1: 2) +Error: discarding token "number" (1.1: 2) +Error: popping token error (1.1: ) Stack now 0 8 21 4 -Shifting token error (1.8: ) +Shifting token error (1.1: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token -Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) +Next token is token '=' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1111) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.13-16: 2222) -Shifting token number (1.13-16: 2222) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) +Next token is token '\n' (1.1: ) +Reducing stack by rule 6 (line 82): + $1 = nterm exp (1.1: 2222) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 1) +error: 2222 != 1 +-> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 2222) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1355: $PREPARSER ./calc /dev/null -stderr: +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) +./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1355: cat stderr + | + | +1 +./calc.at:1354: $PREPARSER ./calc input input: +stderr: | (1 + #) = 1111 -./calc.at:1353: $PREPARSER ./calc input -./calc.at:1354: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1350: $PREPARSER ./calc input +stderr: +1.6: syntax error: invalid character: '#' stderr: +input: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 96): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Stack now 0 +Cleanup: discarding lookahead token '+' (2.1: ) +Stack now 0 Starting parse Entering state 0 Stack now 0 @@ -46650,70 +42732,120 @@ Entering state 4 Stack now 0 4 Reading a token +Next token is token '-' (1.1: ) +Shifting token '-' (1.1: ) +Entering state 2 +Stack now 0 4 2 +Reading a token +Next token is token '*' (1.1: ) +syntax error +Shifting token error (1.1: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 120): + $1 = token '-' (1.1: ) + $2 = token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 -Stack now 0 4 1 +Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 4 12 21 +Stack now 0 8 21 4 12 Reading a token -syntax error: invalid character: '#' -Error: popping token '+' (1.1: ) -Stack now 0 4 12 +Next token is token "number" (1.1: 2) +syntax error Error: popping nterm exp (1.1: 1) -Stack now 0 4 +Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 -Stack now 0 4 11 -Next token is token "invalid token" (1.1: ) -Error: discarding token "invalid token" (1.1: ) +Stack now 0 8 21 4 11 +Next token is token "number" (1.1: 2) +Error: discarding token "number" (1.1: 2) Error: popping token error (1.1: ) -Stack now 0 4 +Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 -Stack now 0 4 11 +Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 -Stack now 0 4 11 26 +Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1111) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 -Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token "number" (1.1: 1111) -Shifting token "number" (1.1: 1111) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1111) --> $$ = nterm exp (1.1: 1111) + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): - $1 = nterm exp (1.1: 1111) + $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 1111) + $3 = nterm exp (1.1: 1) +error: 2222 != 1 +-> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) @@ -46721,7 +42853,7 @@ Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 1111) + $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 @@ -46739,24 +42871,58 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) +stderr: +./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.6: syntax error: invalid character: '#' + | + | +1 +./calc.at:1357: $PREPARSER ./calc input +./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1351: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: + | 1 = 2 = 3 +./calc.at:1355: $PREPARSER ./calc input +stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Now at end of input. -1.1: syntax error, unexpected end of file -Cleanup: discarding lookahead token end of file (1.1: ) +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 96): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) Stack now 0 -./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: +Cleanup: discarding lookahead token '+' (2.1: ) +Stack now 0 +./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1367: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -input: - | 1 = 2 = 3 -./calc.at:1357: $PREPARSER ./calc input stderr: +1.6: syntax error: invalid character: '#' +./calc.at:1351: cat stderr Starting parse Entering state 0 Stack now 0 @@ -46796,115 +42962,68 @@ Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 -./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Now at end of input. -1.1: syntax error, unexpected end of file -Cleanup: discarding lookahead token end of file (1.1: ) +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 96): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Stack now 0 +Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 4 12 21 -Reading a token -syntax error: invalid character: '#' -Error: popping token '+' (1.1: ) -Stack now 0 4 12 -Error: popping nterm exp (1.1: 1) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Next token is token "invalid token" (1.1: ) -Error: discarding token "invalid token" (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.1: 1111) -Shifting token "number" (1.1: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1111) --> $$ = nterm exp (1.1: 1111) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 6 (line 82): - $1 = nterm exp (1.1: 1111) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 1111) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 96): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) -./calc.at:1354: cat stderr +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Stack now 0 +Cleanup: discarding lookahead token '+' (2.1: ) +Stack now 0 +./calc.at:1353: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: Starting parse Entering state 0 @@ -46945,18 +43064,8 @@ Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 -./calc.at:1367: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c - -./calc.at:1355: "$PERL" -pi -e 'use strict; +input: +./calc.at:1350: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -46966,8 +43075,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -./calc.at:1353: "$PERL" -pi -e 'use strict; + | (# + 1) = 1111 +./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -46987,50 +43096,91 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1367: $PREPARSER ./calc input -./calc.at:1355: cat stderr -stdout: +./calc.at:1351: $PREPARSER ./calc input +./calc.at:1355: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1350: cat stderr stderr: -input: +./calc.at:1354: cat stderr +1.2: syntax error: invalid character: '#' +./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1357: cat stderr -./calc.at:1360: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1353: cat stderr - | (1 + #) = 1111 -./calc.at:1354: $PREPARSER ./calc input -./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +./calc.at:1355: cat stderr input: +./calc.at:1354: $PREPARSER ./calc /dev/null +stderr: +stderr: +./calc.at:1357: $PREPARSER ./calc /dev/null + | (# + 1) = 1111 +./calc.at:1350: $PREPARSER ./calc input +1.2: syntax error: invalid character: '#' input: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Now at end of input. +1.1: syntax error, unexpected end of file +Cleanup: discarding lookahead token end of file (1.1: ) +Stack now 0 +./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: -./calc.at:1360: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c calc.h - - | (# + 1) = 1111 -./calc.at:1367: $EGREP -c -v 'Return for a new token:|LAC:' stderr +stderr: + | + | +1 +./calc.at:1355: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Now at end of input. +1.1: syntax error, unexpected end of file +Cleanup: discarding lookahead token end of file (1.1: ) +Stack now 0 +./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (* *) + (*) + (*) +stderr: ./calc.at:1353: $PREPARSER ./calc input +1.2: syntax error: invalid character: '#' +stderr: +./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 96): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Stack now 0 +Cleanup: discarding lookahead token '+' (2.1: ) +Stack now 0 +./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -47040,103 +43190,216 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 -Reading a token -1.6: syntax error: invalid character: '#' -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) +Next token is token '*' (1.1: ) +syntax error +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) +Error: popping token error (1.1: ) Stack now 0 4 -Shifting token error (1.2-6: ) +Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) +Reading a token +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) +Error: popping token error (1.1: ) Stack now 0 4 -Shifting token error (1.2-6: ) +Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): +Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Stack now 0 8 19 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Stack now 0 8 19 28 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 8 21 4 Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) +Next token is token '*' (1.1: ) +syntax error +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1111) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token '*' (1.1: ) +syntax error +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '\n' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 2222) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 3333) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - | - | +1 -./calc.at:1357: $PREPARSER ./calc input -./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1355: $PREPARSER ./calc input +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Now at end of input. +1.1: syntax error, unexpected end of file +Cleanup: discarding lookahead token end of file (1.1: ) +Stack now 0 +./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1351: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Now at end of input. +1.1: syntax error, unexpected end of file +Cleanup: discarding lookahead token end of file (1.1: ) +Stack now 0 stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 96): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Stack now 0 +Cleanup: discarding lookahead token '+' (2.1: ) +Stack now 0 stderr: +./calc.at:1351: cat stderr +1.2: syntax error: invalid character: '#' +./calc.at:1354: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Stack now 0 @@ -47146,67 +43409,123 @@ Entering state 4 Stack now 0 4 Reading a token -syntax error: invalid character: '#' +Next token is token '*' (1.1: ) +syntax error Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 -Next token is token "invalid token" (1.1: ) -Error: discarding token "invalid token" (1.1: ) +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token '+' (1.1: ) -Error: discarding token '+' (1.1: ) +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token "number" (1.1: 1) -Error: discarding token "number" (1.1: 1) +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token '*' (1.1: ) +syntax error +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) Error: popping token error (1.1: ) -Stack now 0 4 +Stack now 0 8 21 4 Shifting token error (1.1: ) Entering state 11 -Stack now 0 4 11 +Stack now 0 8 21 4 11 Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 -Stack now 0 4 11 26 +Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1111) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 -Stack now 0 8 19 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 8 21 4 Reading a token -Next token is token "number" (1.1: 1111) -Shifting token "number" (1.1: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1111) +Next token is token '*' (1.1: ) +syntax error +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) -Entering state 28 -Stack now 0 8 19 28 +Entering state 30 +Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.1: ) -Reducing stack by rule 6 (line 82): - $1 = nterm exp (1.1: 1111) - $2 = token '=' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 2222) + $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) @@ -47214,7 +43533,7 @@ Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 1111) + $1 = nterm exp (1.1: 3333) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 @@ -47232,6 +43551,63 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) +./calc.at:1357: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1354: cat stderr +./calc.at:1355: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +./calc.at:1350: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1357: cat stderr + | (1 + # + 1) = 1111 +./calc.at:1353: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1351: $PREPARSER ./calc input +./calc.at:1355: cat stderr +./calc.at:1350: cat stderr +stderr: +input: +1.6: syntax error: invalid character: '#' +./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1354: $PREPARSER ./calc input +./calc.at:1355: $PREPARSER ./calc /dev/null +stderr: +stderr: +input: input: Starting parse Entering state 0 @@ -47550,113 +43926,327 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1360: $PREPARSER ./calc input +./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1357: $PREPARSER ./calc input +1.6: syntax error: invalid character: '#' +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Now at end of input. +1.1: syntax error, unexpected end of file +Cleanup: discarding lookahead token end of file (1.1: ) +Stack now 0 ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + # + 1) = 1111 +./calc.at:1353: cat stderr +stderr: +./calc.at:1350: $PREPARSER ./calc input +stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token number (1.7: 1) +Shifting token number (1.7: 1) Entering state 1 -Stack now 0 8 21 1 +Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) + $1 = token number (1.7: 1) +-> $$ = nterm exp (1.7: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token number (1.11: 1) +Shifting token number (1.11: 1) +Entering state 1 +Stack now 0 8 21 4 12 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 30 +Stack now 0 8 21 4 12 21 30 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token number (1.15: 1) +Shifting token number (1.15: 1) +Entering state 1 +Stack now 0 8 21 4 12 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 30 +Stack now 0 8 21 4 12 21 30 +Reading a token +Next token is token '+' (1.17: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.7-15: 3) +Stack now 0 8 21 4 +Shifting token error (1.7-18: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) +Next token is token '+' (1.20: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) +Error: popping token error (1.23: ) +Stack now 0 8 21 4 +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Error: popping token error (1.23: ) +Stack now 0 8 21 4 +Shifting token error (1.23-25: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Error: popping token error (1.23-25: ) +Stack now 0 8 21 4 +Shifting token error (1.23-27: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.30: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token number (1.33: 1) +Shifting token number (1.33: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) Entering state 22 -Stack now 0 8 21 30 22 +Stack now 0 8 21 4 12 22 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token number (1.37: 2) +Shifting token number (1.37: 2) Entering state 1 -Stack now 0 8 21 30 22 1 +Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) + $1 = token number (1.37: 2) +-> $$ = nterm exp (1.37: 2) Entering state 31 -Stack now 0 8 21 30 22 31 +Stack now 0 8 21 4 12 22 31 Reading a token -Next token is token '=' (1.11: ) +Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 22 +Stack now 0 8 21 4 12 22 +Reading a token +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.33-37: 2) +Stack now 0 8 21 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) +Error: popping token error (1.33-41: ) +Stack now 0 8 21 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 -Next token is token '=' (1.11: ) +Reading a token +Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.13: 7) -Shifting token number (1.13: 7) +Next token is token number (1.46: 1) +Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.13: 7) --> $$ = nterm exp (1.13: 7) + $1 = token number (1.46: 1) +-> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.14-2.0: ) +Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-9: 7) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13: 7) --> $$ = nterm exp (1.1-13: 7) + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.14-2.0: ) -Shifting token '\n' (1.14-2.0: ) +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-13: 7) - $2 = token '\n' (1.14-2.0: ) + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -47666,926 +44256,2515 @@ Entering state 6 Stack now 0 6 Reading a token -Next token is token number (2.1: 1) -Shifting token number (2.1: 1) +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: +./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1351: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +stdout: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Now at end of input. +1.1: syntax error, unexpected end of file +Cleanup: discarding lookahead token end of file (1.1: ) +Stack now 0 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token number (1.7: 1) +Shifting token number (1.7: 1) Entering state 1 -Stack now 0 6 1 +Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (2.1: 1) --> $$ = nterm exp (2.1: 1) -Entering state 8 -Stack now 0 6 8 + $1 = token number (1.7: 1) +-> $$ = nterm exp (1.7: 1) +Entering state 12 +Stack now 0 8 21 4 12 Reading a token -Next token is token '+' (2.3: ) -Shifting token '+' (2.3: ) +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) Entering state 21 -Stack now 0 6 8 21 +Stack now 0 8 21 4 12 21 Reading a token -Next token is token number (2.5: 2) -Shifting token number (2.5: 2) +Next token is token number (1.11: 1) +Shifting token number (1.11: 1) Entering state 1 -Stack now 0 6 8 21 1 +Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): - $1 = token number (2.5: 2) --> $$ = nterm exp (2.5: 2) + $1 = token number (1.11: 1) +-> $$ = nterm exp (1.11: 1) Entering state 30 -Stack now 0 6 8 21 30 -Reading a token -Next token is token '*' (2.7: ) -Shifting token '*' (2.7: ) -Entering state 22 -Stack now 0 6 8 21 30 22 +Stack now 0 8 21 4 12 21 30 Reading a token -Next token is token '-' (2.9: ) -Shifting token '-' (2.9: ) -Entering state 2 -Stack now 0 6 8 21 30 22 2 +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Stack now 0 8 21 4 12 21 Reading a token -Next token is token number (2.10: 3) -Shifting token number (2.10: 3) +Next token is token number (1.15: 1) +Shifting token number (1.15: 1) Entering state 1 -Stack now 0 6 8 21 30 22 2 1 +Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): - $1 = token number (2.10: 3) --> $$ = nterm exp (2.10: 3) -Entering state 10 -Stack now 0 6 8 21 30 22 2 10 + $1 = token number (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 30 +Stack now 0 8 21 4 12 21 30 Reading a token -Next token is token '=' (2.12: ) -Reducing stack by rule 11 (line 124): - $1 = token '-' (2.9: ) - $2 = nterm exp (2.10: 3) --> $$ = nterm exp (2.9-10: -3) -Entering state 31 -Stack now 0 6 8 21 30 22 31 -Next token is token '=' (2.12: ) -Reducing stack by rule 9 (line 114): - $1 = nterm exp (2.5: 2) - $2 = token '*' (2.7: ) - $3 = nterm exp (2.9-10: -3) --> $$ = nterm exp (2.5-10: -6) +Next token is token '+' (1.17: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.7-15: 3) +Stack now 0 8 21 4 +Shifting token error (1.7-18: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) Entering state 30 -Stack now 0 6 8 21 30 -Next token is token '=' (2.12: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (2.1: 1) - $2 = token '+' (2.3: ) - $3 = nterm exp (2.5-10: -6) --> $$ = nterm exp (2.1-10: -5) +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.20: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (2.12: ) -Shifting token '=' (2.12: ) -Entering state 19 -Stack now 0 6 8 19 +Stack now 0 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token '-' (2.14: ) -Shifting token '-' (2.14: ) -Entering state 2 -Stack now 0 6 8 19 2 +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 +Stack now 0 8 21 4 Reading a token -Next token is token number (2.15: 5) -Shifting token number (2.15: 5) -Entering state 1 -Stack now 0 6 8 19 2 1 -Reducing stack by rule 5 (line 101): - $1 = token number (2.15: 5) --> $$ = nterm exp (2.15: 5) -Entering state 10 -Stack now 0 6 8 19 2 10 +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) +Error: popping token error (1.23: ) +Stack now 0 8 21 4 +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 21 4 11 Reading a token -Next token is token '\n' (2.16-3.0: ) -Reducing stack by rule 11 (line 124): - $1 = token '-' (2.14: ) - $2 = nterm exp (2.15: 5) --> $$ = nterm exp (2.14-15: -5) -Entering state 28 -Stack now 0 6 8 19 28 -Next token is token '\n' (2.16-3.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (2.1-10: -5) - $2 = token '=' (2.12: ) - $3 = nterm exp (2.14-15: -5) --> $$ = nterm exp (2.1-15: -5) -Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (2.16-3.0: ) -Shifting token '\n' (2.16-3.0: ) -Entering state 25 -Stack now 0 6 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (2.1-15: -5) - $2 = token '\n' (2.16-3.0: ) --> $$ = nterm line (2.1-3.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-2.0: ) - $2 = nterm line (2.1-3.0: ) --> $$ = nterm input (1.1-3.0: ) -Entering state 6 -Stack now 0 6 +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Error: popping token error (1.23: ) +Stack now 0 8 21 4 +Shifting token error (1.23-25: ) +Entering state 11 +Stack now 0 8 21 4 11 Reading a token -Next token is token '\n' (3.1-4.0: ) -Shifting token '\n' (3.1-4.0: ) -Entering state 3 -Stack now 0 6 3 -Reducing stack by rule 3 (line 96): - $1 = token '\n' (3.1-4.0: ) --> $$ = nterm line (3.1-4.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-3.0: ) - $2 = nterm line (3.1-4.0: ) --> $$ = nterm input (1.1-4.0: ) -Entering state 6 -Stack now 0 6 +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Error: popping token error (1.23-25: ) +Stack now 0 8 21 4 +Shifting token error (1.23-27: ) +Entering state 11 +Stack now 0 8 21 4 11 Reading a token -Next token is token '-' (4.1: ) -Shifting token '-' (4.1: ) -Entering state 2 -Stack now 0 6 2 +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 30 +Stack now 0 8 21 30 Reading a token -Next token is token number (4.2: 1) -Shifting token number (4.2: 1) +Next token is token '+' (1.30: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token number (1.33: 1) +Shifting token number (1.33: 1) Entering state 1 -Stack now 0 6 2 1 +Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (4.2: 1) --> $$ = nterm exp (4.2: 1) -Entering state 10 -Stack now 0 6 2 10 + $1 = token number (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 +Stack now 0 8 21 4 12 Reading a token -Next token is token '^' (4.3: ) -Shifting token '^' (4.3: ) -Entering state 24 -Stack now 0 6 2 10 24 +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 22 +Stack now 0 8 21 4 12 22 Reading a token -Next token is token number (4.4: 2) -Shifting token number (4.4: 2) +Next token is token number (1.37: 2) +Shifting token number (1.37: 2) Entering state 1 -Stack now 0 6 2 10 24 1 +Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): - $1 = token number (4.4: 2) --> $$ = nterm exp (4.4: 2) -Entering state 33 -Stack now 0 6 2 10 24 33 + $1 = token number (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 31 +Stack now 0 8 21 4 12 22 31 Reading a token -Next token is token '=' (4.6: ) -Reducing stack by rule 12 (line 125): - $1 = nterm exp (4.2: 1) - $2 = token '^' (4.3: ) - $3 = nterm exp (4.4: 2) --> $$ = nterm exp (4.2-4: 1) -Entering state 10 -Stack now 0 6 2 10 -Next token is token '=' (4.6: ) -Reducing stack by rule 11 (line 124): - $1 = token '-' (4.1: ) - $2 = nterm exp (4.2-4: 1) --> $$ = nterm exp (4.1-4: -1) +Next token is token '*' (1.39: ) +Reducing stack by rule 9 (line 120): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 22 +Stack now 0 8 21 4 12 22 +Reading a token +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.33-37: 2) +Stack now 0 8 21 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) +Error: popping token error (1.33-41: ) +Stack now 0 8 21 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.44: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (4.6: ) -Shifting token '=' (4.6: ) +Stack now 0 8 +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) Entering state 19 -Stack now 0 6 8 19 -Reading a token -Next token is token '-' (4.8: ) -Shifting token '-' (4.8: ) -Entering state 2 -Stack now 0 6 8 19 2 +Stack now 0 8 19 Reading a token -Next token is token number (4.9: 1) -Shifting token number (4.9: 1) +Next token is token number (1.46: 1) +Shifting token number (1.46: 1) Entering state 1 -Stack now 0 6 8 19 2 1 +Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (4.9: 1) --> $$ = nterm exp (4.9: 1) -Entering state 10 -Stack now 0 6 8 19 2 10 -Reading a token -Next token is token '\n' (4.10-5.0: ) -Reducing stack by rule 11 (line 124): - $1 = token '-' (4.8: ) - $2 = nterm exp (4.9: 1) --> $$ = nterm exp (4.8-9: -1) + $1 = token number (1.46: 1) +-> $$ = nterm exp (1.46: 1) Entering state 28 -Stack now 0 6 8 19 28 -Next token is token '\n' (4.10-5.0: ) +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (4.1-4: -1) - $2 = token '=' (4.6: ) - $3 = nterm exp (4.8-9: -1) --> $$ = nterm exp (4.1-9: -1) + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (4.10-5.0: ) -Shifting token '\n' (4.10-5.0: ) +Stack now 0 8 +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) Entering state 25 -Stack now 0 6 8 25 +Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (4.1-9: -1) - $2 = token '\n' (4.10-5.0: ) --> $$ = nterm line (4.1-5.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-4.0: ) - $2 = nterm line (4.1-5.0: ) --> $$ = nterm input (1.1-5.0: ) + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token '(' (5.1: ) -Shifting token '(' (5.1: ) +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +input: +1.6: syntax error: invalid character: '#' +./types.at:139: $PREPARSER ./test +./calc.at:1351: cat stderr + | 1 + 2 * 3 + !+ ++ +./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1353: $PREPARSER ./calc input +stderr: +stderr: +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 -Stack now 0 6 4 +Stack now 0 4 Reading a token -Next token is token '-' (5.2: ) -Shifting token '-' (5.2: ) -Entering state 2 -Stack now 0 6 4 2 +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 +Stack now 0 8 Reading a token -Next token is token number (5.3: 1) -Shifting token number (5.3: 1) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token number (1.7: 1) +Shifting token number (1.7: 1) Entering state 1 -Stack now 0 6 4 2 1 +Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (5.3: 1) --> $$ = nterm exp (5.3: 1) -Entering state 10 -Stack now 0 6 4 2 10 -Reading a token -Next token is token ')' (5.4: ) -Reducing stack by rule 11 (line 124): - $1 = token '-' (5.2: ) - $2 = nterm exp (5.3: 1) --> $$ = nterm exp (5.2-3: -1) + $1 = token number (1.7: 1) +-> $$ = nterm exp (1.7: 1) Entering state 12 -Stack now 0 6 4 12 -Next token is token ')' (5.4: ) -Shifting token ')' (5.4: ) -Entering state 27 -Stack now 0 6 4 12 27 -Reducing stack by rule 13 (line 126): - $1 = token '(' (5.1: ) - $2 = nterm exp (5.2-3: -1) - $3 = token ')' (5.4: ) --> $$ = nterm exp (5.1-4: -1) -Entering state 8 -Stack now 0 6 8 +Stack now 0 8 21 4 12 Reading a token -Next token is token '^' (5.5: ) -Shifting token '^' (5.5: ) -Entering state 24 -Stack now 0 6 8 24 +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 21 +Stack now 0 8 21 4 12 21 Reading a token -Next token is token number (5.6: 2) -Shifting token number (5.6: 2) +Next token is token number (1.11: 1) +Shifting token number (1.11: 1) Entering state 1 -Stack now 0 6 8 24 1 +Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): - $1 = token number (5.6: 2) --> $$ = nterm exp (5.6: 2) -Entering state 33 -Stack now 0 6 8 24 33 + $1 = token number (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 30 +Stack now 0 8 21 4 12 21 30 Reading a token -Next token is token '=' (5.8: ) -Reducing stack by rule 12 (line 125): - $1 = nterm exp (5.1-4: -1) - $2 = token '^' (5.5: ) - $3 = nterm exp (5.6: 2) --> $$ = nterm exp (5.1-6: 1) -Entering state 8 -Stack now 0 6 8 -Next token is token '=' (5.8: ) -Shifting token '=' (5.8: ) -Entering state 19 -Stack now 0 6 8 19 +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Stack now 0 8 21 4 12 21 Reading a token -Next token is token number (5.10: 1) -Shifting token number (5.10: 1) +Next token is token number (1.15: 1) +Shifting token number (1.15: 1) Entering state 1 -Stack now 0 6 8 19 1 +Stack now 0 8 21 4 12 21 1 Reducing stack by rule 5 (line 101): - $1 = token number (5.10: 1) --> $$ = nterm exp (5.10: 1) -Entering state 28 -Stack now 0 6 8 19 28 + $1 = token number (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 30 +Stack now 0 8 21 4 12 21 30 Reading a token -Next token is token '\n' (5.11-6.0: ) +Next token is token '+' (1.17: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.7-15: 3) +Stack now 0 8 21 4 +Shifting token error (1.7-18: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.20: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) +Error: popping token error (1.23: ) +Stack now 0 8 21 4 +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Error: popping token error (1.23: ) +Stack now 0 8 21 4 +Shifting token error (1.23-25: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Error: popping token error (1.23-25: ) +Stack now 0 8 21 4 +Shifting token error (1.23-27: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.30: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token number (1.33: 1) +Shifting token number (1.33: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 22 +Stack now 0 8 21 4 12 22 +Reading a token +Next token is token number (1.37: 2) +Shifting token number (1.37: 2) +Entering state 1 +Stack now 0 8 21 4 12 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 31 +Stack now 0 8 21 4 12 22 31 +Reading a token +Next token is token '*' (1.39: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 22 +Stack now 0 8 21 4 12 22 +Reading a token +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.33-37: 2) +Stack now 0 8 21 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) +Error: popping token error (1.33-41: ) +Stack now 0 8 21 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.44: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.46: 1) +Shifting token number (1.46: 1) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.46: 1) +-> $$ = nterm exp (1.46: 1) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (5.1-6: 1) - $2 = token '=' (5.8: ) - $3 = nterm exp (5.10: 1) --> $$ = nterm exp (5.1-10: 1) + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (5.11-6.0: ) -Shifting token '\n' (5.11-6.0: ) +Stack now 0 8 +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) Entering state 25 -Stack now 0 6 8 25 +Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (5.1-10: 1) - $2 = token '\n' (5.11-6.0: ) --> $$ = nterm line (5.1-6.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-5.0: ) - $2 = nterm line (5.1-6.0: ) --> $$ = nterm input (1.1-6.0: ) + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token '\n' (6.1-7.0: ) -Shifting token '\n' (6.1-7.0: ) -Entering state 3 -Stack now 0 6 3 -Reducing stack by rule 3 (line 96): - $1 = token '\n' (6.1-7.0: ) --> $$ = nterm line (6.1-7.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-6.0: ) - $2 = nterm line (6.1-7.0: ) --> $$ = nterm input (1.1-7.0: ) -Entering state 6 -Stack now 0 6 +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token '-' (7.1: ) -Shifting token '-' (7.1: ) -Entering state 2 -Stack now 0 6 2 +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 Reading a token -Next token is token '-' (7.2: ) -Shifting token '-' (7.2: ) -Entering state 2 -Stack now 0 6 2 2 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token '-' (7.3: ) -Shifting token '-' (7.3: ) -Entering state 2 -Stack now 0 6 2 2 2 +Next token is token "number" (1.1: 2) +Shifting token "number" (1.1: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 2) +-> $$ = nterm exp (1.1: 2) +Entering state 30 +Stack now 0 8 21 30 Reading a token -Next token is token number (7.4: 1) -Shifting token number (7.4: 1) +Next token is token '*' (1.1: ) +Shifting token '*' (1.1: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token "number" (1.1: 3) +Shifting token "number" (1.1: 3) Entering state 1 -Stack now 0 6 2 2 2 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 3) +-> $$ = nterm exp (1.1: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.1: ) +Reducing stack by rule 9 (line 100): + $1 = nterm exp (1.1: 2) + $2 = token '*' (1.1: ) + $3 = nterm exp (1.1: 3) +-> $$ = nterm exp (1.1: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 6) +-> $$ = nterm exp (1.1: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '!' (1.1: ) +Shifting token '!' (1.1: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 14 +Stack now 0 8 21 5 14 +Reducing stack by rule 17 (line 122): + $1 = token '!' (1.1: ) + $2 = token '+' (1.1: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.1: ) +Cleanup: popping nterm exp (1.1: 7) +./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1354: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +./calc.at:1355: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.6: syntax error: invalid character: '#' +./calc.at:1354: cat stderr + | (1 + 1) / (1 - 1) +./calc.at:1357: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1351: $PREPARSER ./calc input +./calc.at:1355: cat stderr +stderr: +======== Testing with C++ standard flags: '' +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token "number" (1.1: 2) +Shifting token "number" (1.1: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 2) +-> $$ = nterm exp (1.1: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.1: ) +Shifting token '*' (1.1: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token "number" (1.1: 3) +Shifting token "number" (1.1: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 3) +-> $$ = nterm exp (1.1: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.1: ) +Reducing stack by rule 9 (line 100): + $1 = nterm exp (1.1: 2) + $2 = token '*' (1.1: ) + $3 = nterm exp (1.1: 3) +-> $$ = nterm exp (1.1: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 6) +-> $$ = nterm exp (1.1: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '!' (1.1: ) +Shifting token '!' (1.1: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 14 +Stack now 0 8 21 5 14 +Reducing stack by rule 17 (line 122): + $1 = token '!' (1.1: ) + $2 = token '+' (1.1: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.1: ) +Cleanup: popping nterm exp (1.1: 7) +./calc.at:1350: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1353: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1357: cat stderr +1.11-17: error: null divisor +./calc.at:1351: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +input: +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./calc.at:1350: cat stderr + | (!!) + (1 2) = 1 +stderr: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1355: $PREPARSER ./calc input +input: +./calc.at:1354: $PREPARSER ./calc input +input: +1.11-17: error: null divisor +stderr: + | (!!) + (1 2) = 1 +stderr: +./calc.at:1357: $PREPARSER ./calc input + | 1 + 2 * 3 + !- ++ +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token number (1.7: 1) +Shifting token number (1.7: 1) +Entering state 1 +Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (7.4: 1) --> $$ = nterm exp (7.4: 1) -Entering state 10 -Stack now 0 6 2 2 2 10 + $1 = token number (1.7: 1) +-> $$ = nterm exp (1.7: 1) +Entering state 12 +Stack now 0 8 21 4 12 Reading a token -Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 124): - $1 = token '-' (7.3: ) - $2 = nterm exp (7.4: 1) --> $$ = nterm exp (7.3-4: -1) -Entering state 10 -Stack now 0 6 2 2 10 -Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 124): - $1 = token '-' (7.2: ) - $2 = nterm exp (7.3-4: -1) --> $$ = nterm exp (7.2-4: 1) -Entering state 10 -Stack now 0 6 2 10 -Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 124): - $1 = token '-' (7.1: ) - $2 = nterm exp (7.2-4: 1) --> $$ = nterm exp (7.1-4: -1) +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token number (1.11: 1) +Shifting token number (1.11: 1) +Entering state 1 +Stack now 0 8 21 4 12 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 30 +Stack now 0 8 21 4 12 21 30 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token number (1.15: 1) +Shifting token number (1.15: 1) +Entering state 1 +Stack now 0 8 21 4 12 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 30 +Stack now 0 8 21 4 12 21 30 +Reading a token +Next token is token '+' (1.17: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.7-15: 3) +Stack now 0 8 21 4 +Shifting token error (1.7-18: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.20: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (7.6: ) -Shifting token '=' (7.6: ) -Entering state 19 -Stack now 0 6 8 19 +Stack now 0 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token '-' (7.8: ) -Shifting token '-' (7.8: ) -Entering state 2 -Stack now 0 6 8 19 2 +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 +Stack now 0 8 21 4 Reading a token -Next token is token number (7.9: 1) -Shifting token number (7.9: 1) +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) +Error: popping token error (1.23: ) +Stack now 0 8 21 4 +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Error: popping token error (1.23: ) +Stack now 0 8 21 4 +Shifting token error (1.23-25: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Error: popping token error (1.23-25: ) +Stack now 0 8 21 4 +Shifting token error (1.23-27: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.30: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token number (1.33: 1) +Shifting token number (1.33: 1) Entering state 1 -Stack now 0 6 8 19 2 1 +Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (7.9: 1) --> $$ = nterm exp (7.9: 1) -Entering state 10 -Stack now 0 6 8 19 2 10 + $1 = token number (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 +Stack now 0 8 21 4 12 Reading a token -Next token is token '\n' (7.10-8.0: ) -Reducing stack by rule 11 (line 124): - $1 = token '-' (7.8: ) - $2 = nterm exp (7.9: 1) --> $$ = nterm exp (7.8-9: -1) +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 22 +Stack now 0 8 21 4 12 22 +Reading a token +Next token is token number (1.37: 2) +Shifting token number (1.37: 2) +Entering state 1 +Stack now 0 8 21 4 12 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 31 +Stack now 0 8 21 4 12 22 31 +Reading a token +Next token is token '*' (1.39: ) +Reducing stack by rule 9 (line 120): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 22 +Stack now 0 8 21 4 12 22 +Reading a token +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.33-37: 2) +Stack now 0 8 21 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) +Error: popping token error (1.33-41: ) +Stack now 0 8 21 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.44: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.46: 1) +Shifting token number (1.46: 1) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.46: 1) +-> $$ = nterm exp (1.46: 1) Entering state 28 -Stack now 0 6 8 19 28 -Next token is token '\n' (7.10-8.0: ) +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (7.1-4: -1) - $2 = token '=' (7.6: ) - $3 = nterm exp (7.8-9: -1) --> $$ = nterm exp (7.1-9: -1) + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (7.10-8.0: ) -Shifting token '\n' (7.10-8.0: ) +Stack now 0 8 +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) Entering state 25 -Stack now 0 6 8 25 +Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (7.1-9: -1) - $2 = token '\n' (7.10-8.0: ) --> $$ = nterm line (7.1-8.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-7.0: ) - $2 = nterm line (7.1-8.0: ) --> $$ = nterm input (1.1-8.0: ) + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token '\n' (8.1-9.0: ) -Shifting token '\n' (8.1-9.0: ) -Entering state 3 -Stack now 0 6 3 -Reducing stack by rule 3 (line 96): - $1 = token '\n' (8.1-9.0: ) --> $$ = nterm line (8.1-9.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-8.0: ) - $2 = nterm line (8.1-9.0: ) --> $$ = nterm input (1.1-9.0: ) -Entering state 6 -Stack now 0 6 +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1353: $PREPARSER ./calc input +./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token number (9.1: 1) -Shifting token number (9.1: 1) -Entering state 1 -Stack now 0 6 1 -Reducing stack by rule 5 (line 101): - $1 = token number (9.1: 1) --> $$ = nterm exp (9.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Stack now 0 4 5 +Reading a token +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 16 +Stack now 0 4 5 16 +Reducing stack by rule 16 (line 141): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Stack now 0 4 +Shifting token error (1.2-3: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) Entering state 8 -Stack now 0 6 8 +Stack now 0 8 Reading a token -Next token is token '-' (9.3: ) -Shifting token '-' (9.3: ) -Entering state 20 -Stack now 0 6 8 20 +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token number (9.5: 2) -Shifting token number (9.5: 2) +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token number (1.9: 1) +Shifting token number (1.9: 1) Entering state 1 -Stack now 0 6 8 20 1 +Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (9.5: 2) --> $$ = nterm exp (9.5: 2) -Entering state 29 -Stack now 0 6 8 20 29 + $1 = token number (1.9: 1) +-> $$ = nterm exp (1.9: 1) +Entering state 12 +Stack now 0 8 21 4 12 Reading a token -Next token is token '-' (9.7: ) -Reducing stack by rule 8 (line 113): - $1 = nterm exp (9.1: 1) - $2 = token '-' (9.3: ) - $3 = nterm exp (9.5: 2) --> $$ = nterm exp (9.1-5: -1) +Next token is token number (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Stack now 0 8 21 4 +Shifting token error (1.9-11: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token number (1.11: 2) +Error: discarding token number (1.11: 2) +Error: popping token error (1.9-11: ) +Stack now 0 8 21 4 +Shifting token error (1.9-11: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.14: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) Entering state 8 -Stack now 0 6 8 -Next token is token '-' (9.7: ) -Shifting token '-' (9.7: ) -Entering state 20 -Stack now 0 6 8 20 +Stack now 0 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token number (9.9: 3) -Shifting token number (9.9: 3) +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) Entering state 1 -Stack now 0 6 8 20 1 +Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (9.9: 3) --> $$ = nterm exp (9.9: 3) -Entering state 29 -Stack now 0 6 8 20 29 + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 +Stack now 0 8 19 28 Reading a token -Next token is token '=' (9.11: ) -Reducing stack by rule 8 (line 113): - $1 = nterm exp (9.1-5: -1) - $2 = token '-' (9.7: ) - $3 = nterm exp (9.9: 3) --> $$ = nterm exp (9.1-9: -4) +Next token is token '\n' (1.17-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (9.11: ) -Shifting token '=' (9.11: ) -Entering state 19 -Stack now 0 6 8 19 +Stack now 0 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token '-' (9.13: ) -Shifting token '-' (9.13: ) -Entering state 2 -Stack now 0 6 8 19 2 +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token number (9.14: 4) -Shifting token number (9.14: 4) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Stack now 0 4 5 +Reading a token +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 16 +Stack now 0 4 5 16 +Reducing stack by rule 16 (line 129): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Stack now 0 4 +Shifting token error (1.2-3: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token number (1.9: 1) +Shifting token number (1.9: 1) Entering state 1 -Stack now 0 6 8 19 2 1 +Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (9.14: 4) --> $$ = nterm exp (9.14: 4) -Entering state 10 -Stack now 0 6 8 19 2 10 + $1 = token number (1.9: 1) +-> $$ = nterm exp (1.9: 1) +Entering state 12 +Stack now 0 8 21 4 12 Reading a token -Next token is token '\n' (9.15-10.0: ) -Reducing stack by rule 11 (line 124): - $1 = token '-' (9.13: ) - $2 = nterm exp (9.14: 4) --> $$ = nterm exp (9.13-14: -4) +Next token is token number (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Stack now 0 8 21 4 +Shifting token error (1.9-11: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token number (1.11: 2) +Error: discarding token number (1.11: 2) +Error: popping token error (1.9-11: ) +Stack now 0 8 21 4 +Shifting token error (1.9-11: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.14: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) Entering state 28 -Stack now 0 6 8 19 28 -Next token is token '\n' (9.15-10.0: ) +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (9.1-9: -4) - $2 = token '=' (9.11: ) - $3 = nterm exp (9.13-14: -4) --> $$ = nterm exp (9.1-14: -4) + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (9.15-10.0: ) -Shifting token '\n' (9.15-10.0: ) +Stack now 0 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 25 -Stack now 0 6 8 25 +Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (9.1-14: -4) - $2 = token '\n' (9.15-10.0: ) --> $$ = nterm line (9.1-10.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-9.0: ) - $2 = nterm line (9.1-10.0: ) --> $$ = nterm input (1.1-10.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token number (10.1: 1) -Shifting token number (10.1: 1) +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: +./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +stdout: +./calc.at:1351: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Stack now 0 6 1 +Stack now 0 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token "number" (1.1: 2) +Shifting token "number" (1.1: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 2) +-> $$ = nterm exp (1.1: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.1: ) +Shifting token '*' (1.1: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token "number" (1.1: 3) +Shifting token "number" (1.1: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 3) +-> $$ = nterm exp (1.1: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.1: ) +Reducing stack by rule 9 (line 100): + $1 = nterm exp (1.1: 2) + $2 = token '*' (1.1: ) + $3 = nterm exp (1.1: 3) +-> $$ = nterm exp (1.1: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 6) +-> $$ = nterm exp (1.1: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '!' (1.1: ) +Shifting token '!' (1.1: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '-' (1.1: ) +Shifting token '-' (1.1: ) +Entering state 13 +Stack now 0 8 21 5 13 +Reducing stack by rule 18 (line 123): + $1 = token '!' (1.1: ) + $2 = token '-' (1.1: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.1: ) +Cleanup: popping nterm exp (1.1: 7) + | (1 + 1) / (1 - 1) +./calc.at:1350: $PREPARSER ./calc input +./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $PREPARSER ./test +stderr: +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token number (1.7: 1) +Shifting token number (1.7: 1) +Entering state 1 +Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (10.1: 1) --> $$ = nterm exp (10.1: 1) + $1 = token number (1.7: 1) +-> $$ = nterm exp (1.7: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token number (1.11: 1) +Shifting token number (1.11: 1) +Entering state 1 +Stack now 0 8 21 4 12 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 30 +Stack now 0 8 21 4 12 21 30 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token number (1.15: 1) +Shifting token number (1.15: 1) +Entering state 1 +Stack now 0 8 21 4 12 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 30 +Stack now 0 8 21 4 12 21 30 +Reading a token +Next token is token '+' (1.17: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.7-15: 3) +Stack now 0 8 21 4 +Shifting token error (1.7-18: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.20: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) Entering state 8 -Stack now 0 6 8 +Stack now 0 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token '-' (10.3: ) -Shifting token '-' (10.3: ) -Entering state 20 -Stack now 0 6 8 20 +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 +Stack now 0 8 21 4 Reading a token -Next token is token '(' (10.5: ) -Shifting token '(' (10.5: ) +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) +Error: popping token error (1.23: ) +Stack now 0 8 21 4 +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Error: popping token error (1.23: ) +Stack now 0 8 21 4 +Shifting token error (1.23-25: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Error: popping token error (1.23-25: ) +Stack now 0 8 21 4 +Shifting token error (1.23-27: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.30: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) Entering state 4 -Stack now 0 6 8 20 4 +Stack now 0 8 21 4 Reading a token -Next token is token number (10.6: 2) -Shifting token number (10.6: 2) +Next token is token number (1.33: 1) +Shifting token number (1.33: 1) Entering state 1 -Stack now 0 6 8 20 4 1 +Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (10.6: 2) --> $$ = nterm exp (10.6: 2) + $1 = token number (1.33: 1) +-> $$ = nterm exp (1.33: 1) Entering state 12 -Stack now 0 6 8 20 4 12 +Stack now 0 8 21 4 12 Reading a token -Next token is token '-' (10.8: ) -Shifting token '-' (10.8: ) -Entering state 20 -Stack now 0 6 8 20 4 12 20 +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 22 +Stack now 0 8 21 4 12 22 Reading a token -Next token is token number (10.10: 3) -Shifting token number (10.10: 3) +Next token is token number (1.37: 2) +Shifting token number (1.37: 2) Entering state 1 -Stack now 0 6 8 20 4 12 20 1 +Stack now 0 8 21 4 12 22 1 Reducing stack by rule 5 (line 101): - $1 = token number (10.10: 3) --> $$ = nterm exp (10.10: 3) -Entering state 29 -Stack now 0 6 8 20 4 12 20 29 + $1 = token number (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 31 +Stack now 0 8 21 4 12 22 31 Reading a token -Next token is token ')' (10.11: ) -Reducing stack by rule 8 (line 113): - $1 = nterm exp (10.6: 2) - $2 = token '-' (10.8: ) - $3 = nterm exp (10.10: 3) --> $$ = nterm exp (10.6-10: -1) +Next token is token '*' (1.39: ) +Reducing stack by rule 9 (line 120): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) Entering state 12 -Stack now 0 6 8 20 4 12 -Next token is token ')' (10.11: ) -Shifting token ')' (10.11: ) -Entering state 27 -Stack now 0 6 8 20 4 12 27 -Reducing stack by rule 13 (line 126): - $1 = token '(' (10.5: ) - $2 = nterm exp (10.6-10: -1) - $3 = token ')' (10.11: ) --> $$ = nterm exp (10.5-11: -1) -Entering state 29 -Stack now 0 6 8 20 29 +Stack now 0 8 21 4 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 22 +Stack now 0 8 21 4 12 22 Reading a token -Next token is token '=' (10.13: ) -Reducing stack by rule 8 (line 113): - $1 = nterm exp (10.1: 1) - $2 = token '-' (10.3: ) - $3 = nterm exp (10.5-11: -1) --> $$ = nterm exp (10.1-11: 2) +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.33-37: 2) +Stack now 0 8 21 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) +Error: popping token error (1.33-41: ) +Stack now 0 8 21 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.44: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (10.13: ) -Shifting token '=' (10.13: ) +Stack now 0 8 +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) Entering state 19 -Stack now 0 6 8 19 +Stack now 0 8 19 Reading a token -Next token is token number (10.15: 2) -Shifting token number (10.15: 2) +Next token is token number (1.46: 1) +Shifting token number (1.46: 1) Entering state 1 -Stack now 0 6 8 19 1 +Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (10.15: 2) --> $$ = nterm exp (10.15: 2) + $1 = token number (1.46: 1) +-> $$ = nterm exp (1.46: 1) Entering state 28 -Stack now 0 6 8 19 28 +Stack now 0 8 19 28 Reading a token -Next token is token '\n' (10.16-11.0: ) +Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (10.1-11: 2) - $2 = token '=' (10.13: ) - $3 = nterm exp (10.15: 2) --> $$ = nterm exp (10.1-15: 2) + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (10.16-11.0: ) -Shifting token '\n' (10.16-11.0: ) +Stack now 0 8 +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) Entering state 25 -Stack now 0 6 8 25 +Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (10.1-15: 2) - $2 = token '\n' (10.16-11.0: ) --> $$ = nterm line (10.1-11.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-10.0: ) - $2 = nterm line (10.1-11.0: ) --> $$ = nterm input (1.1-11.0: ) + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token '\n' (11.1-12.0: ) -Shifting token '\n' (11.1-12.0: ) -Entering state 3 -Stack now 0 6 3 -Reducing stack by rule 3 (line 96): - $1 = token '\n' (11.1-12.0: ) --> $$ = nterm line (11.1-12.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-11.0: ) - $2 = nterm line (11.1-12.0: ) --> $$ = nterm input (1.1-12.0: ) -Entering state 6 -Stack now 0 6 +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: +stderr: +./calc.at:1351: cat stderr +stderr: +stderr: +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token number (12.1: 2) -Shifting token number (12.1: 2) -Entering state 1 -Stack now 0 6 1 -Reducing stack by rule 5 (line 101): - $1 = token number (12.1: 2) --> $$ = nterm exp (12.1: 2) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Stack now 0 4 5 +Reading a token +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 16 +Stack now 0 4 5 16 +Reducing stack by rule 16 (line 141): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Stack now 0 4 +Shifting token error (1.2-3: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) Entering state 8 -Stack now 0 6 8 +Stack now 0 8 Reading a token -Next token is token '^' (12.2: ) -Shifting token '^' (12.2: ) -Entering state 24 -Stack now 0 6 8 24 +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token number (12.3: 2) -Shifting token number (12.3: 2) +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token number (1.9: 1) +Shifting token number (1.9: 1) Entering state 1 -Stack now 0 6 8 24 1 +Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (12.3: 2) --> $$ = nterm exp (12.3: 2) -Entering state 33 -Stack now 0 6 8 24 33 + $1 = token number (1.9: 1) +-> $$ = nterm exp (1.9: 1) +Entering state 12 +Stack now 0 8 21 4 12 Reading a token -Next token is token '^' (12.4: ) -Shifting token '^' (12.4: ) -Entering state 24 -Stack now 0 6 8 24 33 24 +Next token is token number (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Stack now 0 8 21 4 +Shifting token error (1.9-11: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token number (1.11: 2) +Error: discarding token number (1.11: 2) +Error: popping token error (1.9-11: ) +Stack now 0 8 21 4 +Shifting token error (1.9-11: ) +Entering state 11 +Stack now 0 8 21 4 11 Reading a token -Next token is token number (12.5: 3) -Shifting token number (12.5: 3) -Entering state 1 -Stack now 0 6 8 24 33 24 1 -Reducing stack by rule 5 (line 101): - $1 = token number (12.5: 3) --> $$ = nterm exp (12.5: 3) -Entering state 33 -Stack now 0 6 8 24 33 24 33 +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) +Entering state 30 +Stack now 0 8 21 30 Reading a token -Next token is token '=' (12.7: ) -Reducing stack by rule 12 (line 125): - $1 = nterm exp (12.3: 2) - $2 = token '^' (12.4: ) - $3 = nterm exp (12.5: 3) --> $$ = nterm exp (12.3-5: 8) -Entering state 33 -Stack now 0 6 8 24 33 -Next token is token '=' (12.7: ) -Reducing stack by rule 12 (line 125): - $1 = nterm exp (12.1: 2) - $2 = token '^' (12.2: ) - $3 = nterm exp (12.3-5: 8) --> $$ = nterm exp (12.1-5: 256) +Next token is token '=' (1.14: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (12.7: ) -Shifting token '=' (12.7: ) +Stack now 0 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) Entering state 19 -Stack now 0 6 8 19 +Stack now 0 8 19 Reading a token -Next token is token number (12.9-11: 256) -Shifting token number (12.9-11: 256) +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) Entering state 1 -Stack now 0 6 8 19 1 +Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (12.9-11: 256) --> $$ = nterm exp (12.9-11: 256) + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) Entering state 28 -Stack now 0 6 8 19 28 +Stack now 0 8 19 28 Reading a token -Next token is token '\n' (12.12-13.0: ) +Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (12.1-5: 256) - $2 = token '=' (12.7: ) - $3 = nterm exp (12.9-11: 256) --> $$ = nterm exp (12.1-11: 256) + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (12.12-13.0: ) -Shifting token '\n' (12.12-13.0: ) +Stack now 0 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 25 -Stack now 0 6 8 25 +Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (12.1-11: 256) - $2 = token '\n' (12.12-13.0: ) --> $$ = nterm line (12.1-13.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-12.0: ) - $2 = nterm line (12.1-13.0: ) --> $$ = nterm input (1.1-13.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token '(' (13.1: ) -Shifting token '(' (13.1: ) +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token "number" (1.1: 2) +Shifting token "number" (1.1: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 2) +-> $$ = nterm exp (1.1: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.1: ) +Shifting token '*' (1.1: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token "number" (1.1: 3) +Shifting token "number" (1.1: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 3) +-> $$ = nterm exp (1.1: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.1: ) +Reducing stack by rule 9 (line 100): + $1 = nterm exp (1.1: 2) + $2 = token '*' (1.1: ) + $3 = nterm exp (1.1: 3) +-> $$ = nterm exp (1.1: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 6) +-> $$ = nterm exp (1.1: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '!' (1.1: ) +Shifting token '!' (1.1: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '-' (1.1: ) +Shifting token '-' (1.1: ) +Entering state 13 +Stack now 0 8 21 5 13 +Reducing stack by rule 18 (line 123): + $1 = token '!' (1.1: ) + $2 = token '-' (1.1: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.1: ) +Cleanup: popping nterm exp (1.1: 7) +1.11-17: error: null divisor +./calc.at:1350: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 -Stack now 0 6 4 +Stack now 0 4 Reading a token -Next token is token number (13.2: 2) -Shifting token number (13.2: 2) +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Stack now 0 4 5 +Reading a token +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 16 +Stack now 0 4 5 16 +Reducing stack by rule 16 (line 129): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Stack now 0 4 +Shifting token error (1.2-3: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token number (1.9: 1) +Shifting token number (1.9: 1) Entering state 1 -Stack now 0 6 4 1 +Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (13.2: 2) --> $$ = nterm exp (13.2: 2) + $1 = token number (1.9: 1) +-> $$ = nterm exp (1.9: 1) Entering state 12 -Stack now 0 6 4 12 +Stack now 0 8 21 4 12 Reading a token -Next token is token '^' (13.3: ) -Shifting token '^' (13.3: ) -Entering state 24 -Stack now 0 6 4 12 24 +Next token is token number (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Stack now 0 8 21 4 +Shifting token error (1.9-11: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token number (1.11: 2) +Error: discarding token number (1.11: 2) +Error: popping token error (1.9-11: ) +Stack now 0 8 21 4 +Shifting token error (1.9-11: ) +Entering state 11 +Stack now 0 8 21 4 11 Reading a token -Next token is token number (13.4: 2) -Shifting token number (13.4: 2) +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.14: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) Entering state 1 -Stack now 0 6 4 12 24 1 +Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (13.4: 2) --> $$ = nterm exp (13.4: 2) -Entering state 33 -Stack now 0 6 4 12 24 33 + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 +Stack now 0 8 19 28 Reading a token -Next token is token ')' (13.5: ) -Reducing stack by rule 12 (line 125): - $1 = nterm exp (13.2: 2) - $2 = token '^' (13.3: ) - $3 = nterm exp (13.4: 2) --> $$ = nterm exp (13.2-4: 4) -Entering state 12 -Stack now 0 6 4 12 -Next token is token ')' (13.5: ) -Shifting token ')' (13.5: ) -Entering state 27 -Stack now 0 6 4 12 27 -Reducing stack by rule 13 (line 126): - $1 = token '(' (13.1: ) - $2 = nterm exp (13.2-4: 4) - $3 = token ')' (13.5: ) --> $$ = nterm exp (13.1-5: 4) +Next token is token '\n' (1.17-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 -Stack now 0 6 8 +Stack now 0 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token '^' (13.6: ) -Shifting token '^' (13.6: ) -Entering state 24 -Stack now 0 6 8 24 +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +483. calc.at:1351: ok +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1355: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1354: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1357: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +======== Testing with C++ standard flags: '' +stderr: +1.11-17: error: null divisor +./calc.at:1355: cat stderr +./calc.at:1357: cat stderr +./calc.at:1353: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1354: cat stderr +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./calc.at:1350: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +input: +input: +stdout: +input: +./calc.at:1350: cat stderr + | (!!) + (1 2) = 1 +./calc.at:1355: $PREPARSER ./calc input +./calc.at:1353: cat stderr + | (- *) + (1 2) = 1 +./calc.at:1354: $PREPARSER ./calc input + | (- *) + (1 2) = 1 +./calc.at:1357: $PREPARSER ./calc input +./types.at:139: ./check +stderr: + +stderr: +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token number (13.7: 3) -Shifting token number (13.7: 3) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Stack now 0 4 5 +Reading a token +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 16 +Stack now 0 4 5 16 +Reducing stack by rule 16 (line 141): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Stack now 0 4 +Shifting token error (1.2-3: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token number (1.9: 1) +Shifting token number (1.9: 1) Entering state 1 -Stack now 0 6 8 24 1 +Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (13.7: 3) --> $$ = nterm exp (13.7: 3) -Entering state 33 -Stack now 0 6 8 24 33 + $1 = token number (1.9: 1) +-> $$ = nterm exp (1.9: 1) +Entering state 12 +Stack now 0 8 21 4 12 Reading a token -Next token is token '=' (13.9: ) -Reducing stack by rule 12 (line 125): - $1 = nterm exp (13.1-5: 4) - $2 = token '^' (13.6: ) - $3 = nterm exp (13.7: 3) --> $$ = nterm exp (13.1-7: 64) +Next token is token number (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Stack now 0 8 21 4 +Shifting token error (1.9-11: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token number (1.11: 2) +Error: discarding token number (1.11: 2) +Error: popping token error (1.9-11: ) +Stack now 0 8 21 4 +Shifting token error (1.9-11: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.14: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (13.9: ) -Shifting token '=' (13.9: ) +Stack now 0 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) Entering state 19 -Stack now 0 6 8 19 +Stack now 0 8 19 Reading a token -Next token is token number (13.11-12: 64) -Shifting token number (13.11-12: 64) +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) Entering state 1 -Stack now 0 6 8 19 1 +Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (13.11-12: 64) --> $$ = nterm exp (13.11-12: 64) + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) Entering state 28 -Stack now 0 6 8 19 28 +Stack now 0 8 19 28 Reading a token -Next token is token '\n' (13.13-14.0: ) +Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (13.1-7: 64) - $2 = token '=' (13.9: ) - $3 = nterm exp (13.11-12: 64) --> $$ = nterm exp (13.1-12: 64) + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (13.13-14.0: ) -Shifting token '\n' (13.13-14.0: ) +Stack now 0 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 25 -Stack now 0 6 8 25 +Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (13.1-12: 64) - $2 = token '\n' (13.13-14.0: ) --> $$ = nterm line (13.1-14.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-13.0: ) - $2 = nterm line (13.1-14.0: ) --> $$ = nterm input (1.1-14.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (14.1: ) +Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (14.1: ) -Cleanup: popping nterm input (1.1-14.0: ) -stderr: -stderr: +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 @@ -48596,93 +46775,300 @@ Entering state 4 Stack now 0 4 Reading a token -syntax error: invalid character: '#' -Shifting token error (1.1: ) +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Stack now 0 4 2 +Reading a token +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 140): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 -Next token is token "invalid token" (1.1: ) -Error: discarding token "invalid token" (1.1: ) -Error: popping token error (1.1: ) +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2-4: ) Stack now 0 4 -Shifting token error (1.1: ) +Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token '+' (1.1: ) -Error: discarding token '+' (1.1: ) -Error: popping token error (1.1: ) +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token number (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Stack now 0 8 21 4 +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token number (1.12: 2) +Error: discarding token number (1.12: 2) +Error: popping token error (1.10-12: ) +Stack now 0 8 21 4 +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.15: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.17: 1) +-> $$ = nterm exp (1.17: 1) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 Stack now 0 4 -Shifting token error (1.1: ) +Reading a token +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Stack now 0 4 2 +Reading a token +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 128): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 -Reading a token -Next token is token "number" (1.1: 1) -Error: discarding token "number" (1.1: 1) -Error: popping token error (1.1: ) +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2-4: ) Stack now 0 4 -Shifting token error (1.1: ) +Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 119): +Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token number (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Stack now 0 8 21 4 +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token number (1.12: 2) +Error: discarding token number (1.12: 2) +Error: popping token error (1.10-12: ) +Stack now 0 8 21 4 +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.15: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token "number" (1.1: 1111) -Shifting token "number" (1.1: 1111) +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1111) --> $$ = nterm exp (1.1: 1111) +Reducing stack by rule 5 (line 101): + $1 = token number (1.17: 1) +-> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 6 (line 82): - $1 = nterm exp (1.1: 1111) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 1111) +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 1111) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token "end of input" (1.1: ) +Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: stderr: +482. calc.at:1350: ok +input: Starting parse Entering state 0 Stack now 0 @@ -48692,79 +47078,129 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Stack now 0 4 2 Reading a token -1.6: syntax error: invalid character: '#' -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 140): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) Stack now 0 4 -Shifting token error (1.2-6: ) +Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2-4: ) Stack now 0 4 -Shifting token error (1.2-6: ) +Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token number (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Stack now 0 8 21 4 +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token number (1.12: 2) +Error: discarding token number (1.12: 2) +Error: popping token error (1.10-12: ) +Stack now 0 8 21 4 +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.15: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) + $1 = token number (1.17: 1) +-> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.15-2.0: ) +Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -48781,19 +47217,130 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -input: - | 1 2 -stdout: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 96): - $1 = token '\n' (1.1-2.0: ) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Stack now 0 4 5 +Reading a token +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 16 +Stack now 0 4 5 16 +Reducing stack by rule 16 (line 141): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Stack now 0 4 +Shifting token error (1.2-3: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token number (1.9: 1) +Shifting token number (1.9: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 1) +-> $$ = nterm exp (1.9: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token number (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Stack now 0 8 21 4 +Shifting token error (1.9-11: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token number (1.11: 2) +Error: discarding token number (1.11: 2) +Error: popping token error (1.9-11: ) +Stack now 0 8 21 4 +Shifting token error (1.9-11: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.14: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.17-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -48803,26 +47350,150 @@ Entering state 6 Stack now 0 6 Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) -Stack now 0 -./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1367: $PREPARSER ./calc input +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) + | 1 + 2 * 3 + !* ++ +./calc.at:1353: $PREPARSER ./calc input +stderr: +stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 96): - $1 = token '\n' (1.1-2.0: ) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Stack now 0 4 2 +Reading a token +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 128): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2-4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token number (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Stack now 0 8 21 4 +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token number (1.12: 2) +Error: discarding token number (1.12: 2) +Error: popping token error (1.10-12: ) +Stack now 0 8 21 4 +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.15: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.17: 1) +-> $$ = nterm exp (1.17: 1) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -48832,12 +47503,106 @@ Entering state 6 Stack now 0 6 Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +Starting parse +Entering state 0 Stack now 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token "number" (1.1: 2) +Shifting token "number" (1.1: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 2) +-> $$ = nterm exp (1.1: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.1: ) +Shifting token '*' (1.1: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token "number" (1.1: 3) +Shifting token "number" (1.1: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 3) +-> $$ = nterm exp (1.1: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.1: ) +Reducing stack by rule 9 (line 100): + $1 = nterm exp (1.1: 2) + $2 = token '*' (1.1: ) + $3 = nterm exp (1.1: 3) +-> $$ = nterm exp (1.1: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 6) +-> $$ = nterm exp (1.1: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '!' (1.1: ) +Shifting token '!' (1.1: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '*' (1.1: ) +Shifting token '*' (1.1: ) +Entering state 15 +Stack now 0 8 21 5 15 +Reducing stack by rule 19 (line 124): + $1 = token '!' (1.1: ) + $2 = token '*' (1.1: ) +memory exhausted +Stack now 0 8 21 +Cleanup: popping token '+' (1.1: ) +Cleanup: popping nterm exp (1.1: 7) +./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +491. calc.at:1363: testing Calculator %no-lines api.pure parse.error=verbose %debug %locations %header api.prefix={calc} %verbose %yacc %parse-param {semantic_value *result}{int *count}{int *nerrs} ... +./calc.at:1363: + if "$POSIXLY_CORRECT_IS_EXPORTED"; then + sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y + else + mv calc.y.tmp calc.y + fi + + +stdout: +./calc.at:1358: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' ./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -48853,6 +47618,476 @@ Entering state 0 Stack now 0 Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token "number" (1.1: 2) +Shifting token "number" (1.1: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 2) +-> $$ = nterm exp (1.1: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.1: ) +Shifting token '*' (1.1: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token "number" (1.1: 3) +Shifting token "number" (1.1: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 3) +-> $$ = nterm exp (1.1: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.1: ) +Reducing stack by rule 9 (line 100): + $1 = nterm exp (1.1: 2) + $2 = token '*' (1.1: ) + $3 = nterm exp (1.1: 3) +-> $$ = nterm exp (1.1: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 6) +-> $$ = nterm exp (1.1: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '!' (1.1: ) +Shifting token '!' (1.1: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '*' (1.1: ) +Shifting token '*' (1.1: ) +Entering state 15 +Stack now 0 8 21 5 15 +Reducing stack by rule 19 (line 124): + $1 = token '!' (1.1: ) + $2 = token '*' (1.1: ) +memory exhausted +Stack now 0 8 21 +Cleanup: popping token '+' (1.1: ) +Cleanup: popping nterm exp (1.1: 7) +./calc.at:1355: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + +stderr: +stdout: +./calc.at:1357: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1354: cat stderr +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./calc.at:1358: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c calc.h + +./types.at:139: ./check +./calc.at:1363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +./calc.at:1355: cat stderr +./calc.at:1357: cat stderr +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y +./calc.at:1353: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +input: + | (* *) + (*) + (*) +input: +./calc.at:1354: $PREPARSER ./calc input + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1358: $PREPARSER ./calc input +stderr: + | (* *) + (*) + (*) +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) +Error: popping token error (1.10: ) +Stack now 0 8 21 4 +Shifting token error (1.10: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) +Error: popping token error (1.16: ) +Stack now 0 8 21 4 +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1357: $PREPARSER ./calc input +stderr: +492. calc.at:1364: testing Calculator %no-lines api.pure parse.error=verbose %debug %locations %defines api.prefix={calc} %verbose %yacc %parse-param {semantic_value *result}{int *count}{int *nerrs} ... +./calc.at:1364: + if "$POSIXLY_CORRECT_IS_EXPORTED"; then + sed -e '/\/\* !POSIX \*\//d' calc.y.tmp >calc.y + else + mv calc.y.tmp calc.y + fi + + +stderr: +input: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) +Error: popping token error (1.10: ) +Stack now 0 8 21 4 +Shifting token error (1.10: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) +Error: popping token error (1.16: ) +Stack now 0 8 21 4 +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1353: cat stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token Next token is token number (1.1: 1) Shifting token number (1.1: 1) Entering state 1 @@ -48862,11 +48097,13 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 +Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 +Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) @@ -48877,11 +48114,13 @@ -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 +Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 +Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) @@ -48892,6 +48131,7 @@ -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 +Return for a new token: Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): @@ -48913,6 +48153,7 @@ Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 +Return for a new token: Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) @@ -48923,6 +48164,7 @@ -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 +Return for a new token: Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): @@ -48947,6 +48189,7 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) @@ -48957,11 +48200,13 @@ -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 +Return for a new token: Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 +Return for a new token: Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) @@ -48972,16 +48217,19 @@ -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 +Return for a new token: Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 +Return for a new token: Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 +Return for a new token: Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) @@ -48992,6 +48240,7 @@ -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 +Return for a new token: Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): @@ -49020,11 +48269,13 @@ Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 +Return for a new token: Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 +Return for a new token: Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) @@ -49035,6 +48286,7 @@ -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 +Return for a new token: Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): @@ -49067,6 +48319,7 @@ -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) @@ -49083,11 +48336,13 @@ -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 +Return for a new token: Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) @@ -49098,11 +48353,13 @@ -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 +Return for a new token: Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 +Return for a new token: Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) @@ -49113,6 +48370,7 @@ -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 +Return for a new token: Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): @@ -49133,11 +48391,13 @@ Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 +Return for a new token: Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 +Return for a new token: Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) @@ -49148,6 +48408,7 @@ -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 +Return for a new token: Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): @@ -49180,16 +48441,19 @@ -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 +Return for a new token: Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 +Return for a new token: Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) @@ -49200,6 +48464,7 @@ -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 +Return for a new token: Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): @@ -49219,11 +48484,13 @@ -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 +Return for a new token: Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 +Return for a new token: Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) @@ -49234,6 +48501,7 @@ -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 +Return for a new token: Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): @@ -49247,6 +48515,7 @@ Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 +Return for a new token: Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) @@ -49257,6 +48526,7 @@ -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 +Return for a new token: Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): @@ -49282,6 +48552,7 @@ -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) @@ -49298,21 +48569,25 @@ -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 +Return for a new token: Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 +Return for a new token: Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 +Return for a new token: Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) @@ -49323,6 +48598,7 @@ -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 +Return for a new token: Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): @@ -49349,11 +48625,13 @@ Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 +Return for a new token: Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 +Return for a new token: Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) @@ -49364,6 +48642,7 @@ -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 +Return for a new token: Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): @@ -49396,6 +48675,7 @@ -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) @@ -49412,6 +48692,7 @@ -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) @@ -49422,11 +48703,13 @@ -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 +Return for a new token: Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 +Return for a new token: Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) @@ -49437,6 +48720,7 @@ -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 +Return for a new token: Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): @@ -49450,6 +48734,7 @@ Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 +Return for a new token: Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) @@ -49460,6 +48745,7 @@ -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 +Return for a new token: Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): @@ -49473,11 +48759,13 @@ Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 +Return for a new token: Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 +Return for a new token: Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) @@ -49488,6 +48776,7 @@ -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 +Return for a new token: Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): @@ -49520,6 +48809,7 @@ -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) @@ -49530,16 +48820,19 @@ -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 +Return for a new token: Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 +Return for a new token: Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 +Return for a new token: Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) @@ -49550,11 +48843,13 @@ -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 +Return for a new token: Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 +Return for a new token: Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) @@ -49565,6 +48860,7 @@ -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 +Return for a new token: Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): @@ -49585,6 +48881,7 @@ -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 +Return for a new token: Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): @@ -49598,6 +48895,7 @@ Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 +Return for a new token: Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) @@ -49608,6 +48906,7 @@ -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 +Return for a new token: Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): @@ -49633,6 +48932,7 @@ -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) @@ -49649,6 +48949,7 @@ -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) @@ -49659,11 +48960,13 @@ -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 +Return for a new token: Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 +Return for a new token: Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) @@ -49674,11 +48977,13 @@ -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 +Return for a new token: Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 +Return for a new token: Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) @@ -49689,6 +48994,7 @@ -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 +Return for a new token: Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): @@ -49710,6 +49016,7 @@ Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 +Return for a new token: Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) @@ -49720,6 +49027,7 @@ -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 +Return for a new token: Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): @@ -49745,11 +49053,13 @@ -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 +Return for a new token: Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) @@ -49760,11 +49070,13 @@ -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 +Return for a new token: Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 +Return for a new token: Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) @@ -49775,6 +49087,7 @@ -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 +Return for a new token: Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): @@ -49795,11 +49108,13 @@ -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 +Return for a new token: Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 +Return for a new token: Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) @@ -49810,6 +49125,7 @@ -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 +Return for a new token: Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): @@ -49823,6 +49139,7 @@ Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 +Return for a new token: Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) @@ -49833,6 +49150,7 @@ -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 +Return for a new token: Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): @@ -49858,6 +49176,7 @@ -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Now at end of input. Shifting token end of file (14.1: ) @@ -49866,20 +49185,11 @@ Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1360: $EGREP -c -v 'Return for a new token:|LAC:' stderr -stderr: +./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (- *) + (1 2) = 1 +./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1355: $PREPARSER ./calc input stderr: -syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) -./calc.at:1357: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 Starting parse Entering state 0 Stack now 0 @@ -49889,444 +49199,282 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token -Next token is token number (1.7: 1) -Shifting token number (1.7: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Reading a token -Next token is token number (1.11: 1) -Shifting token number (1.11: 1) -Entering state 1 -Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.11: 1) --> $$ = nterm exp (1.11: 1) -Entering state 30 -Stack now 0 8 21 4 12 21 30 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Reading a token -Next token is token number (1.15: 1) -Shifting token number (1.15: 1) -Entering state 1 -Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 30 -Stack now 0 8 21 4 12 21 30 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.7-15: 3) +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) +Error: popping token error (1.10: ) Stack now 0 8 21 4 -Shifting token error (1.7-18: ) +Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) +Reading a token +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token -Next token is token '+' (1.20: ) +Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Error: popping token error (1.23: ) -Stack now 0 8 21 4 -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Error: popping token error (1.23: ) -Stack now 0 8 21 4 -Shifting token error (1.23-25: ) +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 -Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) -Error: popping token error (1.23-25: ) +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) +Error: popping token error (1.16: ) Stack now 0 8 21 4 -Shifting token error (1.23-27: ) +Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token -Next token is token '+' (1.30: ) +Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Stack now 0 4 2 +Reading a token +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 140): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2-4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token -Next token is token number (1.33: 1) -Shifting token number (1.33: 1) +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.33: 1) --> $$ = nterm exp (1.33: 1) + $1 = token number (1.10: 1) +-> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 22 -Stack now 0 8 21 4 12 22 +Next token is token number (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Stack now 0 8 21 4 +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token number (1.12: 2) +Error: discarding token number (1.12: 2) +Error: popping token error (1.10-12: ) +Stack now 0 8 21 4 +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 21 4 11 Reading a token -Next token is token number (1.37: 2) -Shifting token number (1.37: 2) -Entering state 1 -Stack now 0 8 21 4 12 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 31 -Stack now 0 8 21 4 12 22 31 -Reading a token -Next token is token '*' (1.39: ) -Reducing stack by rule 9 (line 120): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 22 -Stack now 0 8 21 4 12 22 -Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.33-37: 2) -Stack now 0 8 21 4 -Shifting token error (1.33-41: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Error: popping token error (1.33-41: ) -Stack now 0 8 21 4 -Shifting token error (1.33-41: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token -Next token is token '=' (1.44: ) +Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.46: 1) -Shifting token number (1.46: 1) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.46: 1) --> $$ = nterm exp (1.46: 1) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.47-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1353: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1358: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -./calc.at:1357: cat stderr -./calc.at:1354: cat stderr -./calc.at:1358: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c calc.h - -stderr: -input: -input: -syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) - | 1 2 - | (# + 1) = 1111 -./calc.at:1354: $PREPARSER ./calc input -./calc.at:1353: cat stderr -./calc.at:1360: $PREPARSER ./calc input -input: -stderr: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -stderr: -./calc.at:1358: $PREPARSER ./calc input -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1.6: 1) -Error: discarding token number (1.6: 1) -Error: popping token error (1.2-4: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) + $1 = token number (1.17: 1) +-> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.15-2.0: ) +Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -50343,41 +49491,8 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token number (1.3: 2) -Stack now 0 -./calc.at:1355: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1355: cat stderr -./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1357: $PREPARSER ./calc /dev/null +./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -51479,47 +50594,163 @@ Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +./calc.at:1363: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS +./calc.at:1364: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y Starting parse Entering state 0 Stack now 0 Reading a token -Now at end of input. -1.1: syntax error, unexpected end of file -Cleanup: discarding lookahead token end of file (1.1: ) -Stack now 0 -stderr: -./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | (!!) + (1 2) = 1 -./calc.at:1355: $PREPARSER ./calc input -input: - | (1 + # + 1) = 1111 -./calc.at:1353: $PREPARSER ./calc input -Starting parse -Entering state 0 -Stack now 0 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token number (1.3: 2) -Stack now 0 -stderr: -stderr: +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) +Error: popping token error (1.10: ) +Stack now 0 8 21 4 +Shifting token error (1.10: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) +Error: popping token error (1.16: ) +Stack now 0 8 21 4 +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./calc.at:1358: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: +input: Starting parse Entering state 0 Stack now 0 @@ -51529,121 +50760,129 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Stack now 0 4 5 +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Stack now 0 4 2 Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 16 -Stack now 0 4 5 16 -Reducing stack by rule 16 (line 141): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 140): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) Stack now 0 4 -Shifting token error (1.2-3: ) +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2-4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Reading a token -Next token is token number (1.9: 1) -Shifting token number (1.9: 1) +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 1) --> $$ = nterm exp (1.9: 1) + $1 = token number (1.10: 1) +-> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token -Next token is token number (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) +Next token is token number (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 -Shifting token error (1.9-11: ) +Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 -Next token is token number (1.11: 2) -Error: discarding token number (1.11: 2) -Error: popping token error (1.9-11: ) +Next token is token number (1.12: 2) +Error: discarding token number (1.12: 2) +Error: popping token error (1.10-12: ) Stack now 0 8 21 4 -Shifting token error (1.9-11: ) +Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token -Next token is token '=' (1.14: ) +Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) + $1 = token number (1.17: 1) +-> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.17-2.0: ) +Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -51660,8 +50899,30 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) + | (#) + (#) = 2222 +./calc.at:1354: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1353: $PREPARSER ./calc input stderr: -./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1357: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: Starting parse Entering state 0 Stack now 0 @@ -51671,26 +50932,7 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 4 12 21 -Reading a token syntax error: invalid character: '#' -Error: popping token '+' (1.1: ) -Stack now 0 4 12 -Error: popping nterm exp (1.1: 1) -Stack now 0 4 Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 @@ -51702,16 +50944,136 @@ Entering state 11 Stack now 0 4 11 Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 +Stack now 0 8 +Reading a token Next token is token '+' (1.1: ) -Error: discarding token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +syntax error: invalid character: '#' +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token "invalid token" (1.1: ) +Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1111) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token "number" (1.1: 2222) +Shifting token "number" (1.1: 2222) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 2222) +-> $$ = nterm exp (1.1: 2222) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.1: ) +Reducing stack by rule 6 (line 82): + $1 = nterm exp (1.1: 2222) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 2222) +-> $$ = nterm exp (1.1: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 2222) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token "end of input" (1.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) +./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1354: cat stderr + | 1 2 +./calc.at:1355: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1358: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 Stack now 0 4 +Reading a token +syntax error: invalid character: '#' Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 -Reading a token -Next token is token "number" (1.1: 1) -Error: discarding token "number" (1.1: 1) +Next token is token "invalid token" (1.1: ) +Error: discarding token "invalid token" (1.1: ) Error: popping token error (1.1: ) Stack now 0 4 Shifting token error (1.1: ) @@ -51730,27 +51092,69 @@ Entering state 8 Stack now 0 8 Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +syntax error: invalid character: '#' +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token "invalid token" (1.1: ) +Error: discarding token "invalid token" (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 8 21 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1111) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 2222) +Entering state 8 +Stack now 0 8 Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token "number" (1.1: 1111) -Shifting token "number" (1.1: 1111) +Next token is token "number" (1.1: 2222) +Shifting token "number" (1.1: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1111) --> $$ = nterm exp (1.1: 1111) + $1 = token "number" (1.1: 2222) +-> $$ = nterm exp (1.1: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack by rule 6 (line 82): - $1 = nterm exp (1.1: 1111) + $1 = nterm exp (1.1: 2222) $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 1111) + $3 = nterm exp (1.1: 2222) +-> $$ = nterm exp (1.1: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.1: ) @@ -51758,7 +51162,7 @@ Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 1111) + $1 = nterm exp (1.1: 2222) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 @@ -51776,11 +51180,252 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) -./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1357: cat stderr +./calc.at:1355: cat stderr +stderr: +input: +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Return for a new token: +Reading a token +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token number (1.3: 2) +Stack now 0 +./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: +input: + | 1 + 2 * 3 + !+ ++ +./calc.at:1354: $PREPARSER ./calc input +./calc.at:1360: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: + | 1 + 2 * 3 + !+ ++ +./calc.at:1357: $PREPARSER ./calc input +stderr: +input: +./calc.at:1353: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 120): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Stack now 0 8 21 5 14 +Reducing stack by rule 17 (line 142): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Return for a new token: +Reading a token +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token number (1.3: 2) +Stack now 0 +./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1360: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c calc.h + +./calc.at:1364: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS + | (* *) + (*) + (*) +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Stack now 0 8 21 5 14 +Reducing stack by rule 17 (line 130): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1355: $PREPARSER ./calc input stderr: -./calc.at:1363: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' stderr: Starting parse Entering state 0 @@ -51791,76 +51436,475 @@ Entering state 4 Stack now 0 4 Reading a token -1.2: syntax error: invalid character: '#' +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token number (1.6: 1) -Error: discarding token number (1.6: 1) -Error: popping token error (1.2-4: ) +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) +Error: popping token error (1.10: ) +Stack now 0 8 21 4 +Shifting token error (1.10: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) +Error: popping token error (1.16: ) +Stack now 0 8 21 4 +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +stderr: +./calc.at:1358: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1353: cat stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 120): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Stack now 0 8 21 5 14 +Reducing stack by rule 17 (line 142): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1354: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1360: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Stack now 0 8 21 5 14 +Reducing stack by rule 17 (line 130): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1357: $EGREP -c -v 'Return for a new token:|LAC:' stderr +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 Stack now 0 4 -Shifting token error (1.2-6: ) +Reading a token +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Stack now 0 8 19 +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Stack now 0 8 19 28 +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Stack now 0 8 21 4 Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) +Error: popping token error (1.10: ) +Stack now 0 8 21 4 +Shifting token error (1.10: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) +Error: popping token error (1.16: ) +Stack now 0 8 21 4 +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -51877,6 +51921,7 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1358: cat stderr Starting parse Entering state 0 Stack now 0 @@ -51890,13 +51935,11 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 -Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 -Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) @@ -51907,13 +51950,11 @@ -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 -Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 -Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) @@ -51924,7 +51965,6 @@ -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 -Return for a new token: Reading a token Next token is token '=' (1.11: ) Reducing stack by rule 9 (line 114): @@ -51946,7 +51986,6 @@ Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 -Return for a new token: Reading a token Next token is token number (1.13: 7) Shifting token number (1.13: 7) @@ -51957,7 +51996,6 @@ -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 -Return for a new token: Reading a token Next token is token '\n' (1.14-2.0: ) Reducing stack by rule 6 (line 102): @@ -51982,7 +52020,6 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Next token is token number (2.1: 1) Shifting token number (2.1: 1) @@ -51993,13 +52030,11 @@ -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 -Return for a new token: Reading a token Next token is token '+' (2.3: ) Shifting token '+' (2.3: ) Entering state 21 Stack now 0 6 8 21 -Return for a new token: Reading a token Next token is token number (2.5: 2) Shifting token number (2.5: 2) @@ -52010,19 +52045,16 @@ -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 -Return for a new token: Reading a token Next token is token '*' (2.7: ) Shifting token '*' (2.7: ) Entering state 22 Stack now 0 6 8 21 30 22 -Return for a new token: Reading a token Next token is token '-' (2.9: ) Shifting token '-' (2.9: ) Entering state 2 Stack now 0 6 8 21 30 22 2 -Return for a new token: Reading a token Next token is token number (2.10: 3) Shifting token number (2.10: 3) @@ -52033,7 +52065,6 @@ -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 -Return for a new token: Reading a token Next token is token '=' (2.12: ) Reducing stack by rule 11 (line 124): @@ -52062,13 +52093,11 @@ Shifting token '=' (2.12: ) Entering state 19 Stack now 0 6 8 19 -Return for a new token: Reading a token Next token is token '-' (2.14: ) Shifting token '-' (2.14: ) Entering state 2 Stack now 0 6 8 19 2 -Return for a new token: Reading a token Next token is token number (2.15: 5) Shifting token number (2.15: 5) @@ -52079,7 +52108,6 @@ -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 -Return for a new token: Reading a token Next token is token '\n' (2.16-3.0: ) Reducing stack by rule 11 (line 124): @@ -52112,7 +52140,6 @@ -> $$ = nterm input (1.1-3.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Next token is token '\n' (3.1-4.0: ) Shifting token '\n' (3.1-4.0: ) @@ -52129,13 +52156,11 @@ -> $$ = nterm input (1.1-4.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Next token is token '-' (4.1: ) Shifting token '-' (4.1: ) Entering state 2 Stack now 0 6 2 -Return for a new token: Reading a token Next token is token number (4.2: 1) Shifting token number (4.2: 1) @@ -52146,13 +52171,11 @@ -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 -Return for a new token: Reading a token Next token is token '^' (4.3: ) Shifting token '^' (4.3: ) Entering state 24 Stack now 0 6 2 10 24 -Return for a new token: Reading a token Next token is token number (4.4: 2) Shifting token number (4.4: 2) @@ -52163,7 +52186,6 @@ -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 -Return for a new token: Reading a token Next token is token '=' (4.6: ) Reducing stack by rule 12 (line 125): @@ -52184,13 +52206,11 @@ Shifting token '=' (4.6: ) Entering state 19 Stack now 0 6 8 19 -Return for a new token: Reading a token Next token is token '-' (4.8: ) Shifting token '-' (4.8: ) Entering state 2 Stack now 0 6 8 19 2 -Return for a new token: Reading a token Next token is token number (4.9: 1) Shifting token number (4.9: 1) @@ -52201,7 +52221,6 @@ -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 -Return for a new token: Reading a token Next token is token '\n' (4.10-5.0: ) Reducing stack by rule 11 (line 124): @@ -52234,19 +52253,16 @@ -> $$ = nterm input (1.1-5.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Next token is token '(' (5.1: ) Shifting token '(' (5.1: ) Entering state 4 Stack now 0 6 4 -Return for a new token: Reading a token Next token is token '-' (5.2: ) Shifting token '-' (5.2: ) Entering state 2 Stack now 0 6 4 2 -Return for a new token: Reading a token Next token is token number (5.3: 1) Shifting token number (5.3: 1) @@ -52257,7 +52273,6 @@ -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 -Return for a new token: Reading a token Next token is token ')' (5.4: ) Reducing stack by rule 11 (line 124): @@ -52277,13 +52292,11 @@ -> $$ = nterm exp (5.1-4: -1) Entering state 8 Stack now 0 6 8 -Return for a new token: Reading a token Next token is token '^' (5.5: ) Shifting token '^' (5.5: ) Entering state 24 Stack now 0 6 8 24 -Return for a new token: Reading a token Next token is token number (5.6: 2) Shifting token number (5.6: 2) @@ -52294,7 +52307,6 @@ -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 -Return for a new token: Reading a token Next token is token '=' (5.8: ) Reducing stack by rule 12 (line 125): @@ -52308,7 +52320,6 @@ Shifting token '=' (5.8: ) Entering state 19 Stack now 0 6 8 19 -Return for a new token: Reading a token Next token is token number (5.10: 1) Shifting token number (5.10: 1) @@ -52319,7 +52330,6 @@ -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 -Return for a new token: Reading a token Next token is token '\n' (5.11-6.0: ) Reducing stack by rule 6 (line 102): @@ -52345,7 +52355,6 @@ -> $$ = nterm input (1.1-6.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Next token is token '\n' (6.1-7.0: ) Shifting token '\n' (6.1-7.0: ) @@ -52362,25 +52371,21 @@ -> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Next token is token '-' (7.1: ) Shifting token '-' (7.1: ) Entering state 2 Stack now 0 6 2 -Return for a new token: Reading a token Next token is token '-' (7.2: ) Shifting token '-' (7.2: ) Entering state 2 Stack now 0 6 2 2 -Return for a new token: Reading a token Next token is token '-' (7.3: ) Shifting token '-' (7.3: ) Entering state 2 Stack now 0 6 2 2 2 -Return for a new token: Reading a token Next token is token number (7.4: 1) Shifting token number (7.4: 1) @@ -52391,7 +52396,6 @@ -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 -Return for a new token: Reading a token Next token is token '=' (7.6: ) Reducing stack by rule 11 (line 124): @@ -52418,13 +52422,11 @@ Shifting token '=' (7.6: ) Entering state 19 Stack now 0 6 8 19 -Return for a new token: Reading a token Next token is token '-' (7.8: ) Shifting token '-' (7.8: ) Entering state 2 Stack now 0 6 8 19 2 -Return for a new token: Reading a token Next token is token number (7.9: 1) Shifting token number (7.9: 1) @@ -52435,7 +52437,6 @@ -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 -Return for a new token: Reading a token Next token is token '\n' (7.10-8.0: ) Reducing stack by rule 11 (line 124): @@ -52468,7 +52469,6 @@ -> $$ = nterm input (1.1-8.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Next token is token '\n' (8.1-9.0: ) Shifting token '\n' (8.1-9.0: ) @@ -52485,7 +52485,6 @@ -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Next token is token number (9.1: 1) Shifting token number (9.1: 1) @@ -52496,13 +52495,11 @@ -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 -Return for a new token: Reading a token Next token is token '-' (9.3: ) Shifting token '-' (9.3: ) Entering state 20 Stack now 0 6 8 20 -Return for a new token: Reading a token Next token is token number (9.5: 2) Shifting token number (9.5: 2) @@ -52513,7 +52510,6 @@ -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 -Return for a new token: Reading a token Next token is token '-' (9.7: ) Reducing stack by rule 8 (line 113): @@ -52527,7 +52523,6 @@ Shifting token '-' (9.7: ) Entering state 20 Stack now 0 6 8 20 -Return for a new token: Reading a token Next token is token number (9.9: 3) Shifting token number (9.9: 3) @@ -52538,7 +52533,6 @@ -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 -Return for a new token: Reading a token Next token is token '=' (9.11: ) Reducing stack by rule 8 (line 113): @@ -52552,13 +52546,11 @@ Shifting token '=' (9.11: ) Entering state 19 Stack now 0 6 8 19 -Return for a new token: Reading a token Next token is token '-' (9.13: ) Shifting token '-' (9.13: ) Entering state 2 Stack now 0 6 8 19 2 -Return for a new token: Reading a token Next token is token number (9.14: 4) Shifting token number (9.14: 4) @@ -52569,7 +52561,6 @@ -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 -Return for a new token: Reading a token Next token is token '\n' (9.15-10.0: ) Reducing stack by rule 11 (line 124): @@ -52602,7 +52593,6 @@ -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Next token is token number (10.1: 1) Shifting token number (10.1: 1) @@ -52613,19 +52603,16 @@ -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 -Return for a new token: Reading a token Next token is token '-' (10.3: ) Shifting token '-' (10.3: ) Entering state 20 Stack now 0 6 8 20 -Return for a new token: Reading a token Next token is token '(' (10.5: ) Shifting token '(' (10.5: ) Entering state 4 Stack now 0 6 8 20 4 -Return for a new token: Reading a token Next token is token number (10.6: 2) Shifting token number (10.6: 2) @@ -52636,13 +52623,11 @@ -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 -Return for a new token: Reading a token Next token is token '-' (10.8: ) Shifting token '-' (10.8: ) Entering state 20 Stack now 0 6 8 20 4 12 20 -Return for a new token: Reading a token Next token is token number (10.10: 3) Shifting token number (10.10: 3) @@ -52653,7 +52638,6 @@ -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 -Return for a new token: Reading a token Next token is token ')' (10.11: ) Reducing stack by rule 8 (line 113): @@ -52674,7 +52658,6 @@ -> $$ = nterm exp (10.5-11: -1) Entering state 29 Stack now 0 6 8 20 29 -Return for a new token: Reading a token Next token is token '=' (10.13: ) Reducing stack by rule 8 (line 113): @@ -52688,7 +52671,6 @@ Shifting token '=' (10.13: ) Entering state 19 Stack now 0 6 8 19 -Return for a new token: Reading a token Next token is token number (10.15: 2) Shifting token number (10.15: 2) @@ -52699,7 +52681,6 @@ -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 -Return for a new token: Reading a token Next token is token '\n' (10.16-11.0: ) Reducing stack by rule 6 (line 102): @@ -52725,7 +52706,6 @@ -> $$ = nterm input (1.1-11.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Next token is token '\n' (11.1-12.0: ) Shifting token '\n' (11.1-12.0: ) @@ -52742,7 +52722,6 @@ -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Next token is token number (12.1: 2) Shifting token number (12.1: 2) @@ -52753,13 +52732,11 @@ -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 -Return for a new token: Reading a token Next token is token '^' (12.2: ) Shifting token '^' (12.2: ) Entering state 24 Stack now 0 6 8 24 -Return for a new token: Reading a token Next token is token number (12.3: 2) Shifting token number (12.3: 2) @@ -52770,13 +52747,11 @@ -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 -Return for a new token: Reading a token Next token is token '^' (12.4: ) Shifting token '^' (12.4: ) Entering state 24 Stack now 0 6 8 24 33 24 -Return for a new token: Reading a token Next token is token number (12.5: 3) Shifting token number (12.5: 3) @@ -52787,7 +52762,6 @@ -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 -Return for a new token: Reading a token Next token is token '=' (12.7: ) Reducing stack by rule 12 (line 125): @@ -52809,7 +52783,6 @@ Shifting token '=' (12.7: ) Entering state 19 Stack now 0 6 8 19 -Return for a new token: Reading a token Next token is token number (12.9-11: 256) Shifting token number (12.9-11: 256) @@ -52820,7 +52793,6 @@ -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 -Return for a new token: Reading a token Next token is token '\n' (12.12-13.0: ) Reducing stack by rule 6 (line 102): @@ -52846,13 +52818,11 @@ -> $$ = nterm input (1.1-13.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Next token is token '(' (13.1: ) Shifting token '(' (13.1: ) Entering state 4 Stack now 0 6 4 -Return for a new token: Reading a token Next token is token number (13.2: 2) Shifting token number (13.2: 2) @@ -52863,13 +52833,11 @@ -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 -Return for a new token: Reading a token Next token is token '^' (13.3: ) Shifting token '^' (13.3: ) Entering state 24 Stack now 0 6 4 12 24 -Return for a new token: Reading a token Next token is token number (13.4: 2) Shifting token number (13.4: 2) @@ -52880,7 +52848,6 @@ -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 -Return for a new token: Reading a token Next token is token ')' (13.5: ) Reducing stack by rule 12 (line 125): @@ -52901,13 +52868,11 @@ -> $$ = nterm exp (13.1-5: 4) Entering state 8 Stack now 0 6 8 -Return for a new token: Reading a token Next token is token '^' (13.6: ) Shifting token '^' (13.6: ) Entering state 24 Stack now 0 6 8 24 -Return for a new token: Reading a token Next token is token number (13.7: 3) Shifting token number (13.7: 3) @@ -52918,7 +52883,6 @@ -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 -Return for a new token: Reading a token Next token is token '=' (13.9: ) Reducing stack by rule 12 (line 125): @@ -52932,7 +52896,6 @@ Shifting token '=' (13.9: ) Entering state 19 Stack now 0 6 8 19 -Return for a new token: Reading a token Next token is token number (13.11-12: 64) Shifting token number (13.11-12: 64) @@ -52943,7 +52906,6 @@ -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 -Return for a new token: Reading a token Next token is token '\n' (13.13-14.0: ) Reducing stack by rule 6 (line 102): @@ -52969,7 +52931,6 @@ -> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Now at end of input. Shifting token end of file (14.1: ) @@ -52978,169 +52939,17 @@ Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1358: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1363: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c calc.h - +input: +input: + | (1 + #) = 1111 +input: + | 1 + 2 * 3 + !- ++ +./calc.at:1354: $PREPARSER ./calc input +./calc.at:1353: $PREPARSER ./calc input +./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Stack now 0 4 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 16 -Stack now 0 4 5 16 -Reducing stack by rule 16 (line 141): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Stack now 0 4 -Shifting token error (1.2-3: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token number (1.9: 1) -Shifting token number (1.9: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 1) --> $$ = nterm exp (1.9: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token number (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Stack now 0 8 21 4 -Shifting token error (1.9-11: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token number (1.11: 2) -Error: discarding token number (1.11: 2) -Error: popping token error (1.9-11: ) -Stack now 0 8 21 4 -Shifting token error (1.9-11: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.14: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Now at end of input. -1.1: syntax error, unexpected end of file -Cleanup: discarding lookahead token end of file (1.1: ) -Stack now 0 -./calc.at:1367: cat stderr -./calc.at:1360: "$PERL" -pi -e 'use strict; + | 1 + 2 * 3 + !- ++ +./calc.at:1355: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -53150,6 +52959,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1357: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -53190,22 +53000,6 @@ Entering state 11 Stack now 0 4 11 Reading a token -Next token is token '+' (1.1: ) -Error: discarding token '+' (1.1: ) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token "number" (1.1: 1) -Error: discarding token "number" (1.1: 1) -Error: popping token error (1.1: ) -Stack now 0 4 -Shifting token error (1.1: ) -Entering state 11 -Stack now 0 4 11 -Reading a token Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) Entering state 26 @@ -53264,243 +53058,101 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) -input: -./calc.at:1355: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | 1//2 -./calc.at:1367: $PREPARSER ./calc input -./calc.at:1354: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1355: cat stderr -syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) -input: -./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 2 -./calc.at:1358: $PREPARSER ./calc input -./calc.at:1354: cat stderr -stderr: -./calc.at:1353: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: +./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -stdout: - | (- *) + (1 2) = 1 stderr: -./calc.at:1355: $PREPARSER ./calc input -input: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1357: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1363: $PREPARSER ./calc input -syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) input: -stderr: -stderr: - | (1 + # + 1) = 1111 -./calc.at:1354: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Stack now 0 4 2 -Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 140): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2-4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 -Stack now 0 8 21 4 1 +Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token number (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Stack now 0 8 21 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token number (1.12: 2) -Error: discarding token number (1.12: 2) -Error: popping token error (1.10-12: ) -Stack now 0 8 21 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token -Next token is token '=' (1.15: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) -Entering state 19 -Stack now 0 8 19 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) Entering state 1 -Stack now 0 8 19 1 +Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.17: 1) --> $$ = nterm exp (1.17: 1) -Entering state 28 -Stack now 0 8 19 28 + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 120): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Stack now 0 8 21 5 13 +Reducing stack by rule 18 (line 143): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 @@ -53510,12 +53162,12 @@ Entering state 21 Stack now 0 8 21 Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.5: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 @@ -53525,18 +53177,18 @@ Entering state 22 Stack now 0 8 21 30 22 Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.9: 3) +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) -Reducing stack by rule 9 (line 101): +Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) @@ -53544,7 +53196,7 @@ Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 99): +Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) @@ -53556,18 +53208,18 @@ Entering state 19 Stack now 0 8 19 Reading a token -Next token is token "number" (1.13: 7) -Shifting token "number" (1.13: 7) +Next token is token number (1.13: 7) +Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.13: 7) +Reducing stack by rule 5 (line 101): + $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) -Reducing stack by rule 6 (line 89): +Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) @@ -53578,24 +53230,24 @@ Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 84): +Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 78): +Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token "number" (2.1: 1) -Shifting token "number" (2.1: 1) +Next token is token number (2.1: 1) +Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (2.1: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 @@ -53605,12 +53257,12 @@ Entering state 21 Stack now 0 6 8 21 Reading a token -Next token is token "number" (2.5: 2) -Shifting token "number" (2.5: 2) +Next token is token number (2.5: 2) +Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (2.5: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 @@ -53625,25 +53277,25 @@ Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token -Next token is token "number" (2.10: 3) -Shifting token "number" (2.10: 3) +Next token is token number (2.10: 3) +Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (2.10: 3) +Reducing stack by rule 5 (line 101): + $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) -Reducing stack by rule 11 (line 111): +Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) -Reducing stack by rule 9 (line 101): +Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) @@ -53651,7 +53303,7 @@ Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) -Reducing stack by rule 7 (line 99): +Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) @@ -53668,25 +53320,25 @@ Entering state 2 Stack now 0 6 8 19 2 Reading a token -Next token is token "number" (2.15: 5) -Shifting token "number" (2.15: 5) +Next token is token number (2.15: 5) +Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (2.15: 5) +Reducing stack by rule 5 (line 101): + $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) -Reducing stack by rule 11 (line 111): +Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) -Reducing stack by rule 6 (line 89): +Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) @@ -53697,13 +53349,13 @@ Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 -Reducing stack by rule 4 (line 84): +Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) @@ -53714,12 +53366,12 @@ Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 -Reducing stack by rule 3 (line 83): +Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) @@ -53731,12 +53383,12 @@ Entering state 2 Stack now 0 6 2 Reading a token -Next token is token "number" (4.2: 1) -Shifting token "number" (4.2: 1) +Next token is token number (4.2: 1) +Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (4.2: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 @@ -53746,18 +53398,18 @@ Entering state 24 Stack now 0 6 2 10 24 Reading a token -Next token is token "number" (4.4: 2) -Shifting token "number" (4.4: 2) +Next token is token number (4.4: 2) +Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (4.4: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) -Reducing stack by rule 12 (line 112): +Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) @@ -53765,7 +53417,7 @@ Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) -Reducing stack by rule 11 (line 111): +Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) @@ -53781,25 +53433,25 @@ Entering state 2 Stack now 0 6 8 19 2 Reading a token -Next token is token "number" (4.9: 1) -Shifting token "number" (4.9: 1) +Next token is token number (4.9: 1) +Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (4.9: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) -Reducing stack by rule 11 (line 111): +Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) -Reducing stack by rule 6 (line 89): +Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) @@ -53810,13 +53462,13 @@ Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 -Reducing stack by rule 4 (line 84): +Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) @@ -53833,18 +53485,18 @@ Entering state 2 Stack now 0 6 4 2 Reading a token -Next token is token "number" (5.3: 1) -Shifting token "number" (5.3: 1) +Next token is token number (5.3: 1) +Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (5.3: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) -Reducing stack by rule 11 (line 111): +Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) @@ -53854,7 +53506,7 @@ Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 -Reducing stack by rule 13 (line 113): +Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) @@ -53867,18 +53519,18 @@ Entering state 24 Stack now 0 6 8 24 Reading a token -Next token is token "number" (5.6: 2) -Shifting token "number" (5.6: 2) +Next token is token number (5.6: 2) +Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (5.6: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) -Reducing stack by rule 12 (line 112): +Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) @@ -53890,18 +53542,18 @@ Entering state 19 Stack now 0 6 8 19 Reading a token -Next token is token "number" (5.10: 1) -Shifting token "number" (5.10: 1) +Next token is token number (5.10: 1) +Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (5.10: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) -Reducing stack by rule 6 (line 89): +Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) @@ -53912,13 +53564,13 @@ Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 -Reducing stack by rule 4 (line 84): +Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) @@ -53929,12 +53581,12 @@ Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 -Reducing stack by rule 3 (line 83): +Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) @@ -53956,32 +53608,32 @@ Entering state 2 Stack now 0 6 2 2 2 Reading a token -Next token is token "number" (7.4: 1) -Shifting token "number" (7.4: 1) +Next token is token number (7.4: 1) +Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (7.4: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 111): +Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 111): +Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 111): +Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) @@ -53997,25 +53649,25 @@ Entering state 2 Stack now 0 6 8 19 2 Reading a token -Next token is token "number" (7.9: 1) -Shifting token "number" (7.9: 1) +Next token is token number (7.9: 1) +Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (7.9: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) -Reducing stack by rule 11 (line 111): +Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) -Reducing stack by rule 6 (line 89): +Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) @@ -54026,13 +53678,13 @@ Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 -Reducing stack by rule 4 (line 84): +Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) @@ -54043,24 +53695,24 @@ Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 -Reducing stack by rule 3 (line 83): +Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token "number" (9.1: 1) -Shifting token "number" (9.1: 1) +Next token is token number (9.1: 1) +Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (9.1: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 @@ -54070,18 +53722,18 @@ Entering state 20 Stack now 0 6 8 20 Reading a token -Next token is token "number" (9.5: 2) -Shifting token "number" (9.5: 2) +Next token is token number (9.5: 2) +Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (9.5: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) -Reducing stack by rule 8 (line 100): +Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) @@ -54093,18 +53745,18 @@ Entering state 20 Stack now 0 6 8 20 Reading a token -Next token is token "number" (9.9: 3) -Shifting token "number" (9.9: 3) +Next token is token number (9.9: 3) +Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (9.9: 3) +Reducing stack by rule 5 (line 101): + $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) -Reducing stack by rule 8 (line 100): +Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) @@ -54121,25 +53773,25 @@ Entering state 2 Stack now 0 6 8 19 2 Reading a token -Next token is token "number" (9.14: 4) -Shifting token "number" (9.14: 4) +Next token is token number (9.14: 4) +Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (9.14: 4) +Reducing stack by rule 5 (line 101): + $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) -Reducing stack by rule 11 (line 111): +Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) -Reducing stack by rule 6 (line 89): +Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) @@ -54150,25 +53802,25 @@ Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 -Reducing stack by rule 4 (line 84): +Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token "number" (10.1: 1) -Shifting token "number" (10.1: 1) +Next token is token number (10.1: 1) +Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (10.1: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 @@ -54183,12 +53835,12 @@ Entering state 4 Stack now 0 6 8 20 4 Reading a token -Next token is token "number" (10.6: 2) -Shifting token "number" (10.6: 2) +Next token is token number (10.6: 2) +Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (10.6: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 @@ -54198,18 +53850,18 @@ Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token -Next token is token "number" (10.10: 3) -Shifting token "number" (10.10: 3) +Next token is token number (10.10: 3) +Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (10.10: 3) +Reducing stack by rule 5 (line 101): + $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) -Reducing stack by rule 8 (line 100): +Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) @@ -54220,7 +53872,7 @@ Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 -Reducing stack by rule 13 (line 113): +Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) @@ -54229,7 +53881,7 @@ Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) -Reducing stack by rule 8 (line 100): +Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) @@ -54241,18 +53893,18 @@ Entering state 19 Stack now 0 6 8 19 Reading a token -Next token is token "number" (10.15: 2) -Shifting token "number" (10.15: 2) +Next token is token number (10.15: 2) +Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (10.15: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) -Reducing stack by rule 6 (line 89): +Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) @@ -54263,13 +53915,13 @@ Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 -Reducing stack by rule 4 (line 84): +Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) @@ -54280,24 +53932,24 @@ Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 -Reducing stack by rule 3 (line 83): +Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token "number" (12.1: 2) -Shifting token "number" (12.1: 2) +Next token is token number (12.1: 2) +Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (12.1: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 @@ -54307,12 +53959,12 @@ Entering state 24 Stack now 0 6 8 24 Reading a token -Next token is token "number" (12.3: 2) -Shifting token "number" (12.3: 2) +Next token is token number (12.3: 2) +Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (12.3: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 @@ -54322,18 +53974,18 @@ Entering state 24 Stack now 0 6 8 24 33 24 Reading a token -Next token is token "number" (12.5: 3) -Shifting token "number" (12.5: 3) +Next token is token number (12.5: 3) +Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (12.5: 3) +Reducing stack by rule 5 (line 101): + $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) -Reducing stack by rule 12 (line 112): +Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) @@ -54341,7 +53993,7 @@ Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) -Reducing stack by rule 12 (line 112): +Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) @@ -54353,18 +54005,18 @@ Entering state 19 Stack now 0 6 8 19 Reading a token -Next token is token "number" (12.9-11: 256) -Shifting token "number" (12.9-11: 256) +Next token is token number (12.9-11: 256) +Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (12.9-11: 256) +Reducing stack by rule 5 (line 101): + $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) -Reducing stack by rule 6 (line 89): +Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) @@ -54375,13 +54027,13 @@ Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 -Reducing stack by rule 4 (line 84): +Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) @@ -54393,12 +54045,12 @@ Entering state 4 Stack now 0 6 4 Reading a token -Next token is token "number" (13.2: 2) -Shifting token "number" (13.2: 2) +Next token is token number (13.2: 2) +Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (13.2: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 @@ -54408,18 +54060,18 @@ Entering state 24 Stack now 0 6 4 12 24 Reading a token -Next token is token "number" (13.4: 2) -Shifting token "number" (13.4: 2) +Next token is token number (13.4: 2) +Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (13.4: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) -Reducing stack by rule 12 (line 112): +Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) @@ -54430,7 +54082,7 @@ Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 -Reducing stack by rule 13 (line 113): +Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) @@ -54443,18 +54095,18 @@ Entering state 24 Stack now 0 6 8 24 Reading a token -Next token is token "number" (13.7: 3) -Shifting token "number" (13.7: 3) +Next token is token number (13.7: 3) +Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (13.7: 3) +Reducing stack by rule 5 (line 101): + $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) -Reducing stack by rule 12 (line 112): +Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) @@ -54466,18 +54118,18 @@ Entering state 19 Stack now 0 6 8 19 Reading a token -Next token is token "number" (13.11-12: 64) -Shifting token "number" (13.11-12: 64) +Next token is token number (13.11-12: 64) +Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (13.11-12: 64) +Reducing stack by rule 5 (line 101): + $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) -Reducing stack by rule 6 (line 89): +Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) @@ -54488,13 +54140,13 @@ Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 -Reducing stack by rule 4 (line 84): +Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) @@ -54502,17 +54154,101 @@ Stack now 0 6 Reading a token Now at end of input. -Shifting token "end of input" (14.1: ) +Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token "end of input" (14.1: ) +Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1360: cat stderr -./calc.at:1362: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -./calc.at:1353: cat stderr +./calc.at:1360: $EGREP -c -v 'Return for a new token:|LAC:' stderr + | 1//2 +./calc.at:1358: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Stack now 0 8 21 5 13 +Reducing stack by rule 18 (line 131): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +stderr: +./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1355: cat stderr +stderr: Starting parse Entering state 0 Stack now 0 @@ -54528,15 +54264,21 @@ Stack now 0 8 Return for a new token: Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Stack now 0 8 23 +Return for a new token: +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 -Cleanup: discarding lookahead token number (1.3: 2) +Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: Starting parse Entering state 0 Stack now 0 @@ -54546,276 +54288,265 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Stack now 0 4 2 +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 +Stack now 0 4 12 Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 140): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +syntax error: invalid character: '#' +Error: popping token '+' (1.1: ) +Stack now 0 4 12 +Error: popping nterm exp (1.1: 1) Stack now 0 4 -Shifting token error (1.2-4: ) +Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2-4: ) +Next token is token "invalid token" (1.1: ) +Error: discarding token "invalid token" (1.1: ) +Error: popping token error (1.1: ) Stack now 0 4 -Shifting token error (1.2-4: ) +Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): +Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token number (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Stack now 0 8 21 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token number (1.12: 2) -Error: discarding token number (1.12: 2) -Error: popping token error (1.10-12: ) -Stack now 0 8 21 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.15: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) +Next token is token "number" (1.1: 1111) +Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.17: 1) --> $$ = nterm exp (1.17: 1) +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) +Next token is token '\n' (1.1: ) +Reducing stack by rule 6 (line 82): + $1 = nterm exp (1.1: 1111) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 1111) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - | (1 + 1) / (1 - 1) -./calc.at:1367: cat stderr -./calc.at:1353: $PREPARSER ./calc input +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) stderr: stderr: -./calc.at:1362: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c calc.h - Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 4 1 +Stack now 0 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 21 -Stack now 0 4 12 21 +Stack now 0 8 21 Reading a token -1.6: syntax error: invalid character: '#' -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-8: ) -Entering state 11 -Stack now 0 4 11 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 Reading a token -Next token is token number (1.10: 1) -Error: discarding token number (1.10: 1) -Error: popping token error (1.2-8: ) -Stack now 0 4 -Shifting token error (1.2-10: ) -Entering state 11 -Stack now 0 4 11 +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 120): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) -Entering state 19 -Stack now 0 8 19 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 Reading a token -Next token is token number (1.15-18: 1111) -Shifting token number (1.15-18: 1111) +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Stack now 0 8 21 5 13 +Reducing stack by rule 18 (line 143): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 8 19 1 +Stack now 0 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) -Entering state 28 -Stack now 0 8 19 28 + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 Reading a token -Next token is token '\n' (1.19-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1357: cat stderr +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Stack now 0 8 21 5 13 +Reducing stack by rule 18 (line 131): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +stdout: +stderr: +input: +./calc.at:1362: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' + | 1 2 +input: +./calc.at:1360: $PREPARSER ./calc input +stderr: Starting parse Entering state 0 Stack now 0 @@ -54831,171 +54562,228 @@ Stack now 0 8 Return for a new token: Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Stack now 0 8 23 +Return for a new token: +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '/' (1.3: ) +Stack now 0 + | 1 + 2 * 3 + !+ ++ +./calc.at:1355: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token Next token is token number (1.3: 2) 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 -./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1362: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c calc.h + +./calc.at:1353: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1354: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: +./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1357: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1358: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 4 12 +Entering state 8 +Stack now 0 8 Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 21 -Stack now 0 4 12 21 +Stack now 0 8 21 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 -Stack now 0 4 12 21 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 30 -Stack now 0 4 12 21 30 +Stack now 0 8 21 30 Reading a token -Next token is token ')' (1.1: ) -Reducing stack by rule 7 (line 98): +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 120): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1) --> $$ = nterm exp (1.1: 2) -Entering state 12 -Stack now 0 4 12 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 27 -Stack now 0 4 12 27 -Reducing stack by rule 13 (line 118): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.1: 2) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 2) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token '/' (1.1: ) -Shifting token '/' (1.1: ) -Entering state 23 -Stack now 0 8 23 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 23 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 23 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 8 23 4 12 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 Reading a token -Next token is token '-' (1.1: ) -Shifting token '-' (1.1: ) -Entering state 20 -Stack now 0 8 23 4 12 20 +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Stack now 0 8 21 5 14 +Reducing stack by rule 17 (line 142): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1362: $PREPARSER ./calc input +./calc.at:1354: cat stderr +stderr: +./calc.at:1357: cat stderr +./calc.at:1353: cat stderr +stderr: +stderr: +./calc.at:1358: cat stderr +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 8 23 4 12 20 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) -Entering state 29 -Stack now 0 8 23 4 12 20 29 -Reading a token -Next token is token ')' (1.1: ) -Reducing stack by rule 8 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '-' (1.1: ) - $3 = nterm exp (1.1: 1) --> $$ = nterm exp (1.1: 0) -Entering state 12 -Stack now 0 8 23 4 12 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 27 -Stack now 0 8 23 4 12 27 -Reducing stack by rule 13 (line 118): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.1: 0) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 0) -Entering state 32 -Stack now 0 8 23 32 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 10 (line 101): - $1 = nterm exp (1.1: 2) - $2 = token '/' (1.1: ) - $3 = nterm exp (1.1: 0) -error: null divisor --> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 2) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Stack now 0 6 Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) -stderr: -stdout: -./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token number (1.3: 2) +Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 @@ -55005,12 +54793,12 @@ Entering state 21 Stack now 0 8 21 Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.5: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 @@ -55020,18 +54808,18 @@ Entering state 22 Stack now 0 8 21 30 22 Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.9: 3) +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '=' (1.11: ) -Reducing stack by rule 9 (line 101): +Reducing stack by rule 9 (line 114): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) @@ -55039,7 +54827,7 @@ Entering state 30 Stack now 0 8 21 30 Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 99): +Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) @@ -55051,18 +54839,18 @@ Entering state 19 Stack now 0 8 19 Reading a token -Next token is token "number" (1.13: 7) -Shifting token "number" (1.13: 7) +Next token is token number (1.13: 7) +Shifting token number (1.13: 7) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.13: 7) +Reducing stack by rule 5 (line 101): + $1 = token number (1.13: 7) -> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.14-2.0: ) -Reducing stack by rule 6 (line 89): +Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-9: 7) $2 = token '=' (1.11: ) $3 = nterm exp (1.13: 7) @@ -55073,24 +54861,24 @@ Shifting token '\n' (1.14-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 84): +Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-13: 7) $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 78): +Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token "number" (2.1: 1) -Shifting token "number" (2.1: 1) +Next token is token number (2.1: 1) +Shifting token number (2.1: 1) Entering state 1 Stack now 0 6 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (2.1: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (2.1: 1) -> $$ = nterm exp (2.1: 1) Entering state 8 Stack now 0 6 8 @@ -55100,12 +54888,12 @@ Entering state 21 Stack now 0 6 8 21 Reading a token -Next token is token "number" (2.5: 2) -Shifting token "number" (2.5: 2) +Next token is token number (2.5: 2) +Shifting token number (2.5: 2) Entering state 1 Stack now 0 6 8 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (2.5: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (2.5: 2) -> $$ = nterm exp (2.5: 2) Entering state 30 Stack now 0 6 8 21 30 @@ -55120,25 +54908,25 @@ Entering state 2 Stack now 0 6 8 21 30 22 2 Reading a token -Next token is token "number" (2.10: 3) -Shifting token "number" (2.10: 3) +Next token is token number (2.10: 3) +Shifting token number (2.10: 3) Entering state 1 Stack now 0 6 8 21 30 22 2 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (2.10: 3) +Reducing stack by rule 5 (line 101): + $1 = token number (2.10: 3) -> $$ = nterm exp (2.10: 3) Entering state 10 Stack now 0 6 8 21 30 22 2 10 Reading a token Next token is token '=' (2.12: ) -Reducing stack by rule 11 (line 111): +Reducing stack by rule 11 (line 124): $1 = token '-' (2.9: ) $2 = nterm exp (2.10: 3) -> $$ = nterm exp (2.9-10: -3) Entering state 31 Stack now 0 6 8 21 30 22 31 Next token is token '=' (2.12: ) -Reducing stack by rule 9 (line 101): +Reducing stack by rule 9 (line 114): $1 = nterm exp (2.5: 2) $2 = token '*' (2.7: ) $3 = nterm exp (2.9-10: -3) @@ -55146,7 +54934,7 @@ Entering state 30 Stack now 0 6 8 21 30 Next token is token '=' (2.12: ) -Reducing stack by rule 7 (line 99): +Reducing stack by rule 7 (line 112): $1 = nterm exp (2.1: 1) $2 = token '+' (2.3: ) $3 = nterm exp (2.5-10: -6) @@ -55163,25 +54951,25 @@ Entering state 2 Stack now 0 6 8 19 2 Reading a token -Next token is token "number" (2.15: 5) -Shifting token "number" (2.15: 5) +Next token is token number (2.15: 5) +Shifting token number (2.15: 5) Entering state 1 Stack now 0 6 8 19 2 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (2.15: 5) +Reducing stack by rule 5 (line 101): + $1 = token number (2.15: 5) -> $$ = nterm exp (2.15: 5) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (2.16-3.0: ) -Reducing stack by rule 11 (line 111): +Reducing stack by rule 11 (line 124): $1 = token '-' (2.14: ) $2 = nterm exp (2.15: 5) -> $$ = nterm exp (2.14-15: -5) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (2.16-3.0: ) -Reducing stack by rule 6 (line 89): +Reducing stack by rule 6 (line 102): $1 = nterm exp (2.1-10: -5) $2 = token '=' (2.12: ) $3 = nterm exp (2.14-15: -5) @@ -55192,13 +54980,13 @@ Shifting token '\n' (2.16-3.0: ) Entering state 25 Stack now 0 6 8 25 -Reducing stack by rule 4 (line 84): +Reducing stack by rule 4 (line 97): $1 = nterm exp (2.1-15: -5) $2 = token '\n' (2.16-3.0: ) -> $$ = nterm line (2.1-3.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-2.0: ) $2 = nterm line (2.1-3.0: ) -> $$ = nterm input (1.1-3.0: ) @@ -55209,12 +54997,12 @@ Shifting token '\n' (3.1-4.0: ) Entering state 3 Stack now 0 6 3 -Reducing stack by rule 3 (line 83): +Reducing stack by rule 3 (line 96): $1 = token '\n' (3.1-4.0: ) -> $$ = nterm line (3.1-4.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-3.0: ) $2 = nterm line (3.1-4.0: ) -> $$ = nterm input (1.1-4.0: ) @@ -55226,12 +55014,12 @@ Entering state 2 Stack now 0 6 2 Reading a token -Next token is token "number" (4.2: 1) -Shifting token "number" (4.2: 1) +Next token is token number (4.2: 1) +Shifting token number (4.2: 1) Entering state 1 Stack now 0 6 2 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (4.2: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (4.2: 1) -> $$ = nterm exp (4.2: 1) Entering state 10 Stack now 0 6 2 10 @@ -55241,18 +55029,18 @@ Entering state 24 Stack now 0 6 2 10 24 Reading a token -Next token is token "number" (4.4: 2) -Shifting token "number" (4.4: 2) +Next token is token number (4.4: 2) +Shifting token number (4.4: 2) Entering state 1 Stack now 0 6 2 10 24 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (4.4: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (4.4: 2) -> $$ = nterm exp (4.4: 2) Entering state 33 Stack now 0 6 2 10 24 33 Reading a token Next token is token '=' (4.6: ) -Reducing stack by rule 12 (line 112): +Reducing stack by rule 12 (line 125): $1 = nterm exp (4.2: 1) $2 = token '^' (4.3: ) $3 = nterm exp (4.4: 2) @@ -55260,7 +55048,7 @@ Entering state 10 Stack now 0 6 2 10 Next token is token '=' (4.6: ) -Reducing stack by rule 11 (line 111): +Reducing stack by rule 11 (line 124): $1 = token '-' (4.1: ) $2 = nterm exp (4.2-4: 1) -> $$ = nterm exp (4.1-4: -1) @@ -55276,25 +55064,25 @@ Entering state 2 Stack now 0 6 8 19 2 Reading a token -Next token is token "number" (4.9: 1) -Shifting token "number" (4.9: 1) +Next token is token number (4.9: 1) +Shifting token number (4.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (4.9: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (4.9: 1) -> $$ = nterm exp (4.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (4.10-5.0: ) -Reducing stack by rule 11 (line 111): +Reducing stack by rule 11 (line 124): $1 = token '-' (4.8: ) $2 = nterm exp (4.9: 1) -> $$ = nterm exp (4.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (4.10-5.0: ) -Reducing stack by rule 6 (line 89): +Reducing stack by rule 6 (line 102): $1 = nterm exp (4.1-4: -1) $2 = token '=' (4.6: ) $3 = nterm exp (4.8-9: -1) @@ -55305,13 +55093,13 @@ Shifting token '\n' (4.10-5.0: ) Entering state 25 Stack now 0 6 8 25 -Reducing stack by rule 4 (line 84): +Reducing stack by rule 4 (line 97): $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-4.0: ) $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) @@ -55328,18 +55116,18 @@ Entering state 2 Stack now 0 6 4 2 Reading a token -Next token is token "number" (5.3: 1) -Shifting token "number" (5.3: 1) +Next token is token number (5.3: 1) +Shifting token number (5.3: 1) Entering state 1 Stack now 0 6 4 2 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (5.3: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (5.3: 1) -> $$ = nterm exp (5.3: 1) Entering state 10 Stack now 0 6 4 2 10 Reading a token Next token is token ')' (5.4: ) -Reducing stack by rule 11 (line 111): +Reducing stack by rule 11 (line 124): $1 = token '-' (5.2: ) $2 = nterm exp (5.3: 1) -> $$ = nterm exp (5.2-3: -1) @@ -55349,7 +55137,7 @@ Shifting token ')' (5.4: ) Entering state 27 Stack now 0 6 4 12 27 -Reducing stack by rule 13 (line 113): +Reducing stack by rule 13 (line 126): $1 = token '(' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) @@ -55362,18 +55150,18 @@ Entering state 24 Stack now 0 6 8 24 Reading a token -Next token is token "number" (5.6: 2) -Shifting token "number" (5.6: 2) +Next token is token number (5.6: 2) +Shifting token number (5.6: 2) Entering state 1 Stack now 0 6 8 24 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (5.6: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (5.6: 2) -> $$ = nterm exp (5.6: 2) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (5.8: ) -Reducing stack by rule 12 (line 112): +Reducing stack by rule 12 (line 125): $1 = nterm exp (5.1-4: -1) $2 = token '^' (5.5: ) $3 = nterm exp (5.6: 2) @@ -55385,18 +55173,18 @@ Entering state 19 Stack now 0 6 8 19 Reading a token -Next token is token "number" (5.10: 1) -Shifting token "number" (5.10: 1) +Next token is token number (5.10: 1) +Shifting token number (5.10: 1) Entering state 1 Stack now 0 6 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (5.10: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (5.10: 1) -> $$ = nterm exp (5.10: 1) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (5.11-6.0: ) -Reducing stack by rule 6 (line 89): +Reducing stack by rule 6 (line 102): $1 = nterm exp (5.1-6: 1) $2 = token '=' (5.8: ) $3 = nterm exp (5.10: 1) @@ -55407,13 +55195,13 @@ Shifting token '\n' (5.11-6.0: ) Entering state 25 Stack now 0 6 8 25 -Reducing stack by rule 4 (line 84): +Reducing stack by rule 4 (line 97): $1 = nterm exp (5.1-10: 1) $2 = token '\n' (5.11-6.0: ) -> $$ = nterm line (5.1-6.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-5.0: ) $2 = nterm line (5.1-6.0: ) -> $$ = nterm input (1.1-6.0: ) @@ -55424,12 +55212,12 @@ Shifting token '\n' (6.1-7.0: ) Entering state 3 Stack now 0 6 3 -Reducing stack by rule 3 (line 83): +Reducing stack by rule 3 (line 96): $1 = token '\n' (6.1-7.0: ) -> $$ = nterm line (6.1-7.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-6.0: ) $2 = nterm line (6.1-7.0: ) -> $$ = nterm input (1.1-7.0: ) @@ -55451,32 +55239,32 @@ Entering state 2 Stack now 0 6 2 2 2 Reading a token -Next token is token "number" (7.4: 1) -Shifting token "number" (7.4: 1) +Next token is token number (7.4: 1) +Shifting token number (7.4: 1) Entering state 1 Stack now 0 6 2 2 2 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (7.4: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (7.4: 1) -> $$ = nterm exp (7.4: 1) Entering state 10 Stack now 0 6 2 2 2 10 Reading a token Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 111): +Reducing stack by rule 11 (line 124): $1 = token '-' (7.3: ) $2 = nterm exp (7.4: 1) -> $$ = nterm exp (7.3-4: -1) Entering state 10 Stack now 0 6 2 2 10 Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 111): +Reducing stack by rule 11 (line 124): $1 = token '-' (7.2: ) $2 = nterm exp (7.3-4: -1) -> $$ = nterm exp (7.2-4: 1) Entering state 10 Stack now 0 6 2 10 Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 111): +Reducing stack by rule 11 (line 124): $1 = token '-' (7.1: ) $2 = nterm exp (7.2-4: 1) -> $$ = nterm exp (7.1-4: -1) @@ -55492,25 +55280,25 @@ Entering state 2 Stack now 0 6 8 19 2 Reading a token -Next token is token "number" (7.9: 1) -Shifting token "number" (7.9: 1) +Next token is token number (7.9: 1) +Shifting token number (7.9: 1) Entering state 1 Stack now 0 6 8 19 2 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (7.9: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (7.9: 1) -> $$ = nterm exp (7.9: 1) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (7.10-8.0: ) -Reducing stack by rule 11 (line 111): +Reducing stack by rule 11 (line 124): $1 = token '-' (7.8: ) $2 = nterm exp (7.9: 1) -> $$ = nterm exp (7.8-9: -1) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (7.10-8.0: ) -Reducing stack by rule 6 (line 89): +Reducing stack by rule 6 (line 102): $1 = nterm exp (7.1-4: -1) $2 = token '=' (7.6: ) $3 = nterm exp (7.8-9: -1) @@ -55521,13 +55309,13 @@ Shifting token '\n' (7.10-8.0: ) Entering state 25 Stack now 0 6 8 25 -Reducing stack by rule 4 (line 84): +Reducing stack by rule 4 (line 97): $1 = nterm exp (7.1-9: -1) $2 = token '\n' (7.10-8.0: ) -> $$ = nterm line (7.1-8.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-7.0: ) $2 = nterm line (7.1-8.0: ) -> $$ = nterm input (1.1-8.0: ) @@ -55538,24 +55326,24 @@ Shifting token '\n' (8.1-9.0: ) Entering state 3 Stack now 0 6 3 -Reducing stack by rule 3 (line 83): +Reducing stack by rule 3 (line 96): $1 = token '\n' (8.1-9.0: ) -> $$ = nterm line (8.1-9.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-8.0: ) $2 = nterm line (8.1-9.0: ) -> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token "number" (9.1: 1) -Shifting token "number" (9.1: 1) +Next token is token number (9.1: 1) +Shifting token number (9.1: 1) Entering state 1 Stack now 0 6 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (9.1: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (9.1: 1) -> $$ = nterm exp (9.1: 1) Entering state 8 Stack now 0 6 8 @@ -55565,18 +55353,18 @@ Entering state 20 Stack now 0 6 8 20 Reading a token -Next token is token "number" (9.5: 2) -Shifting token "number" (9.5: 2) +Next token is token number (9.5: 2) +Shifting token number (9.5: 2) Entering state 1 Stack now 0 6 8 20 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (9.5: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (9.5: 2) -> $$ = nterm exp (9.5: 2) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '-' (9.7: ) -Reducing stack by rule 8 (line 100): +Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1: 1) $2 = token '-' (9.3: ) $3 = nterm exp (9.5: 2) @@ -55588,18 +55376,18 @@ Entering state 20 Stack now 0 6 8 20 Reading a token -Next token is token "number" (9.9: 3) -Shifting token "number" (9.9: 3) +Next token is token number (9.9: 3) +Shifting token number (9.9: 3) Entering state 1 Stack now 0 6 8 20 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (9.9: 3) +Reducing stack by rule 5 (line 101): + $1 = token number (9.9: 3) -> $$ = nterm exp (9.9: 3) Entering state 29 Stack now 0 6 8 20 29 Reading a token Next token is token '=' (9.11: ) -Reducing stack by rule 8 (line 100): +Reducing stack by rule 8 (line 113): $1 = nterm exp (9.1-5: -1) $2 = token '-' (9.7: ) $3 = nterm exp (9.9: 3) @@ -55616,25 +55404,25 @@ Entering state 2 Stack now 0 6 8 19 2 Reading a token -Next token is token "number" (9.14: 4) -Shifting token "number" (9.14: 4) +Next token is token number (9.14: 4) +Shifting token number (9.14: 4) Entering state 1 Stack now 0 6 8 19 2 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (9.14: 4) +Reducing stack by rule 5 (line 101): + $1 = token number (9.14: 4) -> $$ = nterm exp (9.14: 4) Entering state 10 Stack now 0 6 8 19 2 10 Reading a token Next token is token '\n' (9.15-10.0: ) -Reducing stack by rule 11 (line 111): +Reducing stack by rule 11 (line 124): $1 = token '-' (9.13: ) $2 = nterm exp (9.14: 4) -> $$ = nterm exp (9.13-14: -4) Entering state 28 Stack now 0 6 8 19 28 Next token is token '\n' (9.15-10.0: ) -Reducing stack by rule 6 (line 89): +Reducing stack by rule 6 (line 102): $1 = nterm exp (9.1-9: -4) $2 = token '=' (9.11: ) $3 = nterm exp (9.13-14: -4) @@ -55645,25 +55433,25 @@ Shifting token '\n' (9.15-10.0: ) Entering state 25 Stack now 0 6 8 25 -Reducing stack by rule 4 (line 84): +Reducing stack by rule 4 (line 97): $1 = nterm exp (9.1-14: -4) $2 = token '\n' (9.15-10.0: ) -> $$ = nterm line (9.1-10.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-9.0: ) $2 = nterm line (9.1-10.0: ) -> $$ = nterm input (1.1-10.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token "number" (10.1: 1) -Shifting token "number" (10.1: 1) +Next token is token number (10.1: 1) +Shifting token number (10.1: 1) Entering state 1 Stack now 0 6 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (10.1: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (10.1: 1) -> $$ = nterm exp (10.1: 1) Entering state 8 Stack now 0 6 8 @@ -55678,12 +55466,12 @@ Entering state 4 Stack now 0 6 8 20 4 Reading a token -Next token is token "number" (10.6: 2) -Shifting token "number" (10.6: 2) +Next token is token number (10.6: 2) +Shifting token number (10.6: 2) Entering state 1 Stack now 0 6 8 20 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (10.6: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (10.6: 2) -> $$ = nterm exp (10.6: 2) Entering state 12 Stack now 0 6 8 20 4 12 @@ -55693,18 +55481,18 @@ Entering state 20 Stack now 0 6 8 20 4 12 20 Reading a token -Next token is token "number" (10.10: 3) -Shifting token "number" (10.10: 3) +Next token is token number (10.10: 3) +Shifting token number (10.10: 3) Entering state 1 Stack now 0 6 8 20 4 12 20 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (10.10: 3) +Reducing stack by rule 5 (line 101): + $1 = token number (10.10: 3) -> $$ = nterm exp (10.10: 3) Entering state 29 Stack now 0 6 8 20 4 12 20 29 Reading a token Next token is token ')' (10.11: ) -Reducing stack by rule 8 (line 100): +Reducing stack by rule 8 (line 113): $1 = nterm exp (10.6: 2) $2 = token '-' (10.8: ) $3 = nterm exp (10.10: 3) @@ -55715,7 +55503,7 @@ Shifting token ')' (10.11: ) Entering state 27 Stack now 0 6 8 20 4 12 27 -Reducing stack by rule 13 (line 113): +Reducing stack by rule 13 (line 126): $1 = token '(' (10.5: ) $2 = nterm exp (10.6-10: -1) $3 = token ')' (10.11: ) @@ -55724,7 +55512,7 @@ Stack now 0 6 8 20 29 Reading a token Next token is token '=' (10.13: ) -Reducing stack by rule 8 (line 100): +Reducing stack by rule 8 (line 113): $1 = nterm exp (10.1: 1) $2 = token '-' (10.3: ) $3 = nterm exp (10.5-11: -1) @@ -55736,18 +55524,18 @@ Entering state 19 Stack now 0 6 8 19 Reading a token -Next token is token "number" (10.15: 2) -Shifting token "number" (10.15: 2) +Next token is token number (10.15: 2) +Shifting token number (10.15: 2) Entering state 1 Stack now 0 6 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (10.15: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (10.15: 2) -> $$ = nterm exp (10.15: 2) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (10.16-11.0: ) -Reducing stack by rule 6 (line 89): +Reducing stack by rule 6 (line 102): $1 = nterm exp (10.1-11: 2) $2 = token '=' (10.13: ) $3 = nterm exp (10.15: 2) @@ -55758,13 +55546,13 @@ Shifting token '\n' (10.16-11.0: ) Entering state 25 Stack now 0 6 8 25 -Reducing stack by rule 4 (line 84): +Reducing stack by rule 4 (line 97): $1 = nterm exp (10.1-15: 2) $2 = token '\n' (10.16-11.0: ) -> $$ = nterm line (10.1-11.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-10.0: ) $2 = nterm line (10.1-11.0: ) -> $$ = nterm input (1.1-11.0: ) @@ -55775,24 +55563,24 @@ Shifting token '\n' (11.1-12.0: ) Entering state 3 Stack now 0 6 3 -Reducing stack by rule 3 (line 83): +Reducing stack by rule 3 (line 96): $1 = token '\n' (11.1-12.0: ) -> $$ = nterm line (11.1-12.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-11.0: ) $2 = nterm line (11.1-12.0: ) -> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token "number" (12.1: 2) -Shifting token "number" (12.1: 2) +Next token is token number (12.1: 2) +Shifting token number (12.1: 2) Entering state 1 Stack now 0 6 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (12.1: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (12.1: 2) -> $$ = nterm exp (12.1: 2) Entering state 8 Stack now 0 6 8 @@ -55802,12 +55590,12 @@ Entering state 24 Stack now 0 6 8 24 Reading a token -Next token is token "number" (12.3: 2) -Shifting token "number" (12.3: 2) +Next token is token number (12.3: 2) +Shifting token number (12.3: 2) Entering state 1 Stack now 0 6 8 24 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (12.3: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (12.3: 2) -> $$ = nterm exp (12.3: 2) Entering state 33 Stack now 0 6 8 24 33 @@ -55817,18 +55605,18 @@ Entering state 24 Stack now 0 6 8 24 33 24 Reading a token -Next token is token "number" (12.5: 3) -Shifting token "number" (12.5: 3) +Next token is token number (12.5: 3) +Shifting token number (12.5: 3) Entering state 1 Stack now 0 6 8 24 33 24 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (12.5: 3) +Reducing stack by rule 5 (line 101): + $1 = token number (12.5: 3) -> $$ = nterm exp (12.5: 3) Entering state 33 Stack now 0 6 8 24 33 24 33 Reading a token Next token is token '=' (12.7: ) -Reducing stack by rule 12 (line 112): +Reducing stack by rule 12 (line 125): $1 = nterm exp (12.3: 2) $2 = token '^' (12.4: ) $3 = nterm exp (12.5: 3) @@ -55836,7 +55624,7 @@ Entering state 33 Stack now 0 6 8 24 33 Next token is token '=' (12.7: ) -Reducing stack by rule 12 (line 112): +Reducing stack by rule 12 (line 125): $1 = nterm exp (12.1: 2) $2 = token '^' (12.2: ) $3 = nterm exp (12.3-5: 8) @@ -55848,18 +55636,18 @@ Entering state 19 Stack now 0 6 8 19 Reading a token -Next token is token "number" (12.9-11: 256) -Shifting token "number" (12.9-11: 256) +Next token is token number (12.9-11: 256) +Shifting token number (12.9-11: 256) Entering state 1 Stack now 0 6 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (12.9-11: 256) +Reducing stack by rule 5 (line 101): + $1 = token number (12.9-11: 256) -> $$ = nterm exp (12.9-11: 256) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (12.12-13.0: ) -Reducing stack by rule 6 (line 89): +Reducing stack by rule 6 (line 102): $1 = nterm exp (12.1-5: 256) $2 = token '=' (12.7: ) $3 = nterm exp (12.9-11: 256) @@ -55870,13 +55658,13 @@ Shifting token '\n' (12.12-13.0: ) Entering state 25 Stack now 0 6 8 25 -Reducing stack by rule 4 (line 84): +Reducing stack by rule 4 (line 97): $1 = nterm exp (12.1-11: 256) $2 = token '\n' (12.12-13.0: ) -> $$ = nterm line (12.1-13.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-12.0: ) $2 = nterm line (12.1-13.0: ) -> $$ = nterm input (1.1-13.0: ) @@ -55888,12 +55676,12 @@ Entering state 4 Stack now 0 6 4 Reading a token -Next token is token "number" (13.2: 2) -Shifting token "number" (13.2: 2) +Next token is token number (13.2: 2) +Shifting token number (13.2: 2) Entering state 1 Stack now 0 6 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (13.2: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (13.2: 2) -> $$ = nterm exp (13.2: 2) Entering state 12 Stack now 0 6 4 12 @@ -55903,18 +55691,18 @@ Entering state 24 Stack now 0 6 4 12 24 Reading a token -Next token is token "number" (13.4: 2) -Shifting token "number" (13.4: 2) +Next token is token number (13.4: 2) +Shifting token number (13.4: 2) Entering state 1 Stack now 0 6 4 12 24 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (13.4: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (13.4: 2) -> $$ = nterm exp (13.4: 2) Entering state 33 Stack now 0 6 4 12 24 33 Reading a token Next token is token ')' (13.5: ) -Reducing stack by rule 12 (line 112): +Reducing stack by rule 12 (line 125): $1 = nterm exp (13.2: 2) $2 = token '^' (13.3: ) $3 = nterm exp (13.4: 2) @@ -55925,7 +55713,7 @@ Shifting token ')' (13.5: ) Entering state 27 Stack now 0 6 4 12 27 -Reducing stack by rule 13 (line 113): +Reducing stack by rule 13 (line 126): $1 = token '(' (13.1: ) $2 = nterm exp (13.2-4: 4) $3 = token ')' (13.5: ) @@ -55938,18 +55726,18 @@ Entering state 24 Stack now 0 6 8 24 Reading a token -Next token is token "number" (13.7: 3) -Shifting token "number" (13.7: 3) +Next token is token number (13.7: 3) +Shifting token number (13.7: 3) Entering state 1 Stack now 0 6 8 24 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (13.7: 3) +Reducing stack by rule 5 (line 101): + $1 = token number (13.7: 3) -> $$ = nterm exp (13.7: 3) Entering state 33 Stack now 0 6 8 24 33 Reading a token Next token is token '=' (13.9: ) -Reducing stack by rule 12 (line 112): +Reducing stack by rule 12 (line 125): $1 = nterm exp (13.1-5: 4) $2 = token '^' (13.6: ) $3 = nterm exp (13.7: 3) @@ -55961,18 +55749,18 @@ Entering state 19 Stack now 0 6 8 19 Reading a token -Next token is token "number" (13.11-12: 64) -Shifting token "number" (13.11-12: 64) +Next token is token number (13.11-12: 64) +Shifting token number (13.11-12: 64) Entering state 1 Stack now 0 6 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (13.11-12: 64) +Reducing stack by rule 5 (line 101): + $1 = token number (13.11-12: 64) -> $$ = nterm exp (13.11-12: 64) Entering state 28 Stack now 0 6 8 19 28 Reading a token Next token is token '\n' (13.13-14.0: ) -Reducing stack by rule 6 (line 89): +Reducing stack by rule 6 (line 102): $1 = nterm exp (13.1-7: 64) $2 = token '=' (13.9: ) $3 = nterm exp (13.11-12: 64) @@ -55983,13 +55771,13 @@ Shifting token '\n' (13.13-14.0: ) Entering state 25 Stack now 0 6 8 25 -Reducing stack by rule 4 (line 84): +Reducing stack by rule 4 (line 97): $1 = nterm exp (13.1-12: 64) $2 = token '\n' (13.13-14.0: ) -> $$ = nterm line (13.1-14.0: ) Entering state 18 Stack now 0 6 18 -Reducing stack by rule 2 (line 79): +Reducing stack by rule 2 (line 92): $1 = nterm input (1.1-13.0: ) $2 = nterm line (13.1-14.0: ) -> $$ = nterm input (1.1-14.0: ) @@ -55997,325 +55785,101 @@ Stack now 0 6 Reading a token Now at end of input. -Shifting token "end of input" (14.1: ) +Shifting token end of file (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token "end of input" (14.1: ) +Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 4 1 +Stack now 0 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 -Reading a token -1.6: syntax error: invalid character: '#' -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-8: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1.10: 1) -Error: discarding token number (1.10: 1) -Error: popping token error (1.2-8: ) -Stack now 0 4 -Shifting token error (1.2-10: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) -Entering state 19 -Stack now 0 8 19 +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token number (1.15-18: 1111) -Shifting token number (1.15-18: 1111) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 -Stack now 0 8 19 1 +Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.19-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1363: $EGREP -c -v 'Return for a new token:|LAC:' stderr -stderr: -input: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1362: $PREPARSER ./calc input - | error -Starting parse -Entering state 0 -Stack now 0 + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Stack now 0 4 12 21 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 4 12 21 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 120): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) Entering state 30 -Stack now 0 4 12 21 30 -Reading a token -Next token is token ')' (1.1: ) -Reducing stack by rule 7 (line 98): +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1) --> $$ = nterm exp (1.1: 2) -Entering state 12 -Stack now 0 4 12 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 27 -Stack now 0 4 12 27 -Reducing stack by rule 13 (line 118): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.1: 2) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 2) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token '/' (1.1: ) -Shifting token '/' (1.1: ) -Entering state 23 -Stack now 0 8 23 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 8 23 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 23 4 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Stack now 0 8 23 4 12 -Reading a token -Next token is token '-' (1.1: ) -Shifting token '-' (1.1: ) -Entering state 20 -Stack now 0 8 23 4 12 20 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 8 23 4 12 20 1 -Reducing stack by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 29 -Stack now 0 8 23 4 12 20 29 -Reading a token -Next token is token ')' (1.1: ) -Reducing stack by rule 8 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '-' (1.1: ) - $3 = nterm exp (1.1: 1) --> $$ = nterm exp (1.1: 0) -Entering state 12 -Stack now 0 8 23 4 12 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 27 -Stack now 0 8 23 4 12 27 -Reducing stack by rule 13 (line 118): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.1: 0) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 0) -Entering state 32 -Stack now 0 8 23 32 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack by rule 10 (line 101): - $1 = nterm exp (1.1: 2) - $2 = token '/' (1.1: ) - $3 = nterm exp (1.1: 0) -error: null divisor --> $$ = nterm exp (1.1: 2) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 77): - $1 = nterm exp (1.1: 2) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Stack now 0 6 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) -./calc.at:1355: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1367: $PREPARSER ./calc input -input: +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Stack now 0 8 21 5 14 +Reducing stack by rule 17 (line 142): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1355: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: -./calc.at:1358: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 input: stderr: -./calc.at:1354: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1357: $PREPARSER ./calc input -./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 + !* ++ +input: +./calc.at:1354: $PREPARSER ./calc input +input: Starting parse Entering state 0 Stack now 0 @@ -57333,48 +56897,13 @@ Stack now 0 6 17 Cleanup: popping token end of file (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -./types.at:139: $PREPARSER ./test - | 1 2 -./calc.at:1363: $PREPARSER ./calc input -./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1//2 -stderr: -./calc.at:1360: $PREPARSER ./calc input -stderr: -./calc.at:1354: cat stderr -syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1358: cat stderr -stderr: + | (# + 1) = 1111 stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Stack now 0 8 23 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) -Stack now 0 -./calc.at:1355: cat stderr -./calc.at:1353: "$PERL" -pi -e 'use strict; +./calc.at:1353: $PREPARSER ./calc input +./calc.at:1362: $EGREP -c -v 'Return for a new token:|LAC:' stderr + | error +./calc.at:1358: $PREPARSER ./calc input +./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -57384,7 +56913,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + | 1 + 2 * 3 + !* ++ stderr: +stderr: +./calc.at:1357: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -57394,336 +56926,372 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) +syntax error: invalid character: '#' +Shifting token error (1.1: ) Entering state 11 Stack now 0 4 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) +Next token is token "invalid token" (1.1: ) +Error: discarding token "invalid token" (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '+' (1.1: ) +Error: discarding token '+' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token "number" (1.1: 1) +Error: discarding token "number" (1.1: 1) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 119): $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 8 21 +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Stack now 0 8 21 4 +Next token is token "number" (1.1: 1111) +Shifting token "number" (1.1: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) +Entering state 28 +Stack now 0 8 19 28 Reading a token -Next token is token number (1.7: 1) -Shifting token number (1.7: 1) +Next token is token '\n' (1.1: ) +Reducing stack by rule 6 (line 82): + $1 = nterm exp (1.1: 1111) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 1111) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token "end of input" (1.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) +input: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 8 21 4 1 +Stack now 0 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Stack now 0 8 21 4 12 + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 21 -Stack now 0 8 21 4 12 21 +Stack now 0 8 21 Reading a token -Next token is token number (1.11: 1) -Shifting token number (1.11: 1) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 -Stack now 0 8 21 4 12 21 1 +Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.11: 1) --> $$ = nterm exp (1.11: 1) + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 30 -Stack now 0 8 21 4 12 21 30 +Stack now 0 8 21 30 Reading a token -Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Stack now 0 8 21 4 12 21 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 Reading a token -Next token is token number (1.15: 1) -Shifting token number (1.15: 1) +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) Entering state 1 -Stack now 0 8 21 4 12 21 1 +Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 30 -Stack now 0 8 21 4 12 21 30 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 21 -Stack now 0 8 21 4 12 21 + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.7-15: 3) -Stack now 0 8 21 4 -Shifting token error (1.7-18: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 120): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 -Reading a token -Next token is token '+' (1.20: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Error: popping token error (1.23: ) -Stack now 0 8 21 4 -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Error: popping token error (1.23: ) -Stack now 0 8 21 4 -Shifting token error (1.23-25: ) -Entering state 11 -Stack now 0 8 21 4 11 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) -Error: popping token error (1.23-25: ) -Stack now 0 8 21 4 -Shifting token error (1.23-27: ) -Entering state 11 -Stack now 0 8 21 4 11 +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Stack now 0 8 21 5 15 +Reducing stack by rule 19 (line 144): + $1 = token '!' (1.13: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 + !- ++ +./calc.at:1355: $PREPARSER ./calc input +./calc.at:1360: cat stderr +stderr: +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 30 -Stack now 0 8 21 30 +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) +Stack now 0 +./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token '+' (1.30: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token number (1.33: 1) -Shifting token number (1.33: 1) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 -Stack now 0 8 21 4 1 +Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Stack now 0 8 21 4 12 + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) Entering state 22 -Stack now 0 8 21 4 12 22 +Stack now 0 8 21 30 22 Reading a token -Next token is token number (1.37: 2) -Shifting token number (1.37: 2) +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) Entering state 1 -Stack now 0 8 21 4 12 22 1 +Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.37: 2) --> $$ = nterm exp (1.37: 2) + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) Entering state 31 -Stack now 0 8 21 4 12 22 31 +Stack now 0 8 21 30 22 31 Reading a token -Next token is token '*' (1.39: ) +Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 22 -Stack now 0 8 21 4 12 22 + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.33-37: 2) -Stack now 0 8 21 4 -Shifting token error (1.33-41: ) +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Stack now 0 8 21 5 15 +Reducing stack by rule 19 (line 132): + $1 = token '!' (1.13: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +input: +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +syntax error: invalid character: '#' +Shifting token error (1.1: ) Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Error: popping token error (1.33-41: ) -Stack now 0 8 21 4 -Shifting token error (1.33-41: ) +Stack now 0 4 11 +Next token is token "invalid token" (1.1: ) +Error: discarding token "invalid token" (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) Entering state 11 -Stack now 0 8 21 4 11 +Stack now 0 4 11 Reading a token -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) -Entering state 30 -Stack now 0 8 21 30 +Next token is token '+' (1.1: ) +Error: discarding token '+' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token '=' (1.44: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) +Next token is token "number" (1.1: 1) +Error: discarding token "number" (1.1: 1) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) +Reading a token +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.46: 1) -Shifting token number (1.46: 1) +Next token is token "number" (1.1: 1111) +Shifting token "number" (1.1: 1111) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.46: 1) --> $$ = nterm exp (1.46: 1) +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.47-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) +Next token is token '\n' (1.1: ) +Reducing stack by rule 6 (line 82): + $1 = nterm exp (1.1: 1111) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) --> $$ = nterm line (1.1-2.0: ) +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 1111) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token "number" (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token "number" (1.3: 2) -Stack now 0 -./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) + | 1 2 +./calc.at:1362: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -57768,999 +57336,784 @@ Entering state 31 Stack now 0 8 21 30 22 31 Reading a token -Next token is token '=' (1.11: ) -Reducing stack by rule 9 (line 114): +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 120): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 -Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 112): +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 118): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 19 -Stack now 0 8 19 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token number (1.13: 7) -Shifting token number (1.13: 7) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.13: 7) --> $$ = nterm exp (1.13: 7) -Entering state 28 -Stack now 0 8 19 28 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 Reading a token -Next token is token '\n' (1.14-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-9: 7) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13: 7) --> $$ = nterm exp (1.1-13: 7) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.14-2.0: ) -Shifting token '\n' (1.14-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-13: 7) - $2 = token '\n' (1.14-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Stack now 0 8 21 5 15 +Reducing stack by rule 19 (line 144): + $1 = token '!' (1.13: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +stderr: +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token number (2.1: 1) -Shifting token number (2.1: 1) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 6 1 +Stack now 0 1 Reducing stack by rule 5 (line 101): - $1 = token number (2.1: 1) --> $$ = nterm exp (2.1: 1) + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 -Stack now 0 6 8 +Stack now 0 8 Reading a token -Next token is token '+' (2.3: ) -Shifting token '+' (2.3: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 21 -Stack now 0 6 8 21 +Stack now 0 8 21 Reading a token -Next token is token number (2.5: 2) -Shifting token number (2.5: 2) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 -Stack now 0 6 8 21 1 +Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): - $1 = token number (2.5: 2) --> $$ = nterm exp (2.5: 2) + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 30 -Stack now 0 6 8 21 30 +Stack now 0 8 21 30 Reading a token -Next token is token '*' (2.7: ) -Shifting token '*' (2.7: ) +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) Entering state 22 -Stack now 0 6 8 21 30 22 -Reading a token -Next token is token '-' (2.9: ) -Shifting token '-' (2.9: ) -Entering state 2 -Stack now 0 6 8 21 30 22 2 +Stack now 0 8 21 30 22 Reading a token -Next token is token number (2.10: 3) -Shifting token number (2.10: 3) +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) Entering state 1 -Stack now 0 6 8 21 30 22 2 1 +Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): - $1 = token number (2.10: 3) --> $$ = nterm exp (2.10: 3) -Entering state 10 -Stack now 0 6 8 21 30 22 2 10 -Reading a token -Next token is token '=' (2.12: ) -Reducing stack by rule 11 (line 124): - $1 = token '-' (2.9: ) - $2 = nterm exp (2.10: 3) --> $$ = nterm exp (2.9-10: -3) + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) Entering state 31 -Stack now 0 6 8 21 30 22 31 -Next token is token '=' (2.12: ) -Reducing stack by rule 9 (line 114): - $1 = nterm exp (2.5: 2) - $2 = token '*' (2.7: ) - $3 = nterm exp (2.9-10: -3) --> $$ = nterm exp (2.5-10: -6) +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 120): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) Entering state 30 -Stack now 0 6 8 21 30 -Next token is token '=' (2.12: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (2.1: 1) - $2 = token '+' (2.3: ) - $3 = nterm exp (2.5-10: -6) --> $$ = nterm exp (2.1-10: -5) +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (2.12: ) -Shifting token '=' (2.12: ) -Entering state 19 -Stack now 0 6 8 19 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token '-' (2.14: ) -Shifting token '-' (2.14: ) -Entering state 2 -Stack now 0 6 8 19 2 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 Reading a token -Next token is token number (2.15: 5) -Shifting token number (2.15: 5) +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Stack now 0 8 21 5 13 +Reducing stack by rule 18 (line 143): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 6 8 19 2 1 +Stack now 0 1 Reducing stack by rule 5 (line 101): - $1 = token number (2.15: 5) --> $$ = nterm exp (2.15: 5) -Entering state 10 -Stack now 0 6 8 19 2 10 -Reading a token -Next token is token '\n' (2.16-3.0: ) -Reducing stack by rule 11 (line 124): - $1 = token '-' (2.14: ) - $2 = nterm exp (2.15: 5) --> $$ = nterm exp (2.14-15: -5) -Entering state 28 -Stack now 0 6 8 19 28 -Next token is token '\n' (2.16-3.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (2.1-10: -5) - $2 = token '=' (2.12: ) - $3 = nterm exp (2.14-15: -5) --> $$ = nterm exp (2.1-15: -5) + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (2.16-3.0: ) -Shifting token '\n' (2.16-3.0: ) -Entering state 25 -Stack now 0 6 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (2.1-15: -5) - $2 = token '\n' (2.16-3.0: ) --> $$ = nterm line (2.1-3.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-2.0: ) - $2 = nterm line (2.1-3.0: ) --> $$ = nterm input (1.1-3.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '\n' (3.1-4.0: ) -Shifting token '\n' (3.1-4.0: ) -Entering state 3 -Stack now 0 6 3 -Reducing stack by rule 3 (line 96): - $1 = token '\n' (3.1-4.0: ) --> $$ = nterm line (3.1-4.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-3.0: ) - $2 = nterm line (3.1-4.0: ) --> $$ = nterm input (1.1-4.0: ) -Entering state 6 -Stack now 0 6 +Stack now 0 8 Reading a token -Next token is token '-' (4.1: ) -Shifting token '-' (4.1: ) -Entering state 2 -Stack now 0 6 2 +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token number (4.2: 1) -Shifting token number (4.2: 1) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 -Stack now 0 6 2 1 +Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): - $1 = token number (4.2: 1) --> $$ = nterm exp (4.2: 1) -Entering state 10 -Stack now 0 6 2 10 + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 Reading a token -Next token is token '^' (4.3: ) -Shifting token '^' (4.3: ) -Entering state 24 -Stack now 0 6 2 10 24 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 Reading a token -Next token is token number (4.4: 2) -Shifting token number (4.4: 2) +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) Entering state 1 -Stack now 0 6 2 10 24 1 +Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): - $1 = token number (4.4: 2) --> $$ = nterm exp (4.4: 2) -Entering state 33 -Stack now 0 6 2 10 24 33 + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 Reading a token -Next token is token '=' (4.6: ) -Reducing stack by rule 12 (line 125): - $1 = nterm exp (4.2: 1) - $2 = token '^' (4.3: ) - $3 = nterm exp (4.4: 2) --> $$ = nterm exp (4.2-4: 1) -Entering state 10 -Stack now 0 6 2 10 -Next token is token '=' (4.6: ) -Reducing stack by rule 11 (line 124): - $1 = token '-' (4.1: ) - $2 = nterm exp (4.2-4: 1) --> $$ = nterm exp (4.1-4: -1) +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (4.6: ) -Shifting token '=' (4.6: ) -Entering state 19 -Stack now 0 6 8 19 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token '-' (4.8: ) -Shifting token '-' (4.8: ) -Entering state 2 -Stack now 0 6 8 19 2 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 Reading a token -Next token is token number (4.9: 1) -Shifting token number (4.9: 1) +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Stack now 0 8 21 5 15 +Reducing stack by rule 19 (line 132): + $1 = token '!' (1.13: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) +Stack now 0 +input: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 6 8 19 2 1 +Stack now 0 1 Reducing stack by rule 5 (line 101): - $1 = token number (4.9: 1) --> $$ = nterm exp (4.9: 1) -Entering state 10 -Stack now 0 6 8 19 2 10 -Reading a token -Next token is token '\n' (4.10-5.0: ) -Reducing stack by rule 11 (line 124): - $1 = token '-' (4.8: ) - $2 = nterm exp (4.9: 1) --> $$ = nterm exp (4.8-9: -1) -Entering state 28 -Stack now 0 6 8 19 28 -Next token is token '\n' (4.10-5.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (4.1-4: -1) - $2 = token '=' (4.6: ) - $3 = nterm exp (4.8-9: -1) --> $$ = nterm exp (4.1-9: -1) + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (4.10-5.0: ) -Shifting token '\n' (4.10-5.0: ) -Entering state 25 -Stack now 0 6 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (4.1-9: -1) - $2 = token '\n' (4.10-5.0: ) --> $$ = nterm line (4.1-5.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-4.0: ) - $2 = nterm line (4.1-5.0: ) --> $$ = nterm input (1.1-5.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '(' (5.1: ) -Shifting token '(' (5.1: ) -Entering state 4 -Stack now 0 6 4 +Stack now 0 8 Reading a token -Next token is token '-' (5.2: ) -Shifting token '-' (5.2: ) -Entering state 2 -Stack now 0 6 4 2 +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token number (1.3: 2) +Stack now 0 + | 1//2 +stderr: +./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1360: $PREPARSER ./calc input +./calc.at:1354: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token number (5.3: 1) -Shifting token number (5.3: 1) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 6 4 2 1 +Stack now 0 1 Reducing stack by rule 5 (line 101): - $1 = token number (5.3: 1) --> $$ = nterm exp (5.3: 1) -Entering state 10 -Stack now 0 6 4 2 10 -Reading a token -Next token is token ')' (5.4: ) -Reducing stack by rule 11 (line 124): - $1 = token '-' (5.2: ) - $2 = nterm exp (5.3: 1) --> $$ = nterm exp (5.2-3: -1) -Entering state 12 -Stack now 0 6 4 12 -Next token is token ')' (5.4: ) -Shifting token ')' (5.4: ) -Entering state 27 -Stack now 0 6 4 12 27 -Reducing stack by rule 13 (line 126): - $1 = token '(' (5.1: ) - $2 = nterm exp (5.2-3: -1) - $3 = token ')' (5.4: ) --> $$ = nterm exp (5.1-4: -1) + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 -Stack now 0 6 8 +Stack now 0 8 Reading a token -Next token is token '^' (5.5: ) -Shifting token '^' (5.5: ) -Entering state 24 -Stack now 0 6 8 24 +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token number (5.6: 2) -Shifting token number (5.6: 2) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 -Stack now 0 6 8 24 1 +Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): - $1 = token number (5.6: 2) --> $$ = nterm exp (5.6: 2) -Entering state 33 -Stack now 0 6 8 24 33 + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 Reading a token -Next token is token '=' (5.8: ) -Reducing stack by rule 12 (line 125): - $1 = nterm exp (5.1-4: -1) - $2 = token '^' (5.5: ) - $3 = nterm exp (5.6: 2) --> $$ = nterm exp (5.1-6: 1) -Entering state 8 -Stack now 0 6 8 -Next token is token '=' (5.8: ) -Shifting token '=' (5.8: ) -Entering state 19 -Stack now 0 6 8 19 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 Reading a token -Next token is token number (5.10: 1) -Shifting token number (5.10: 1) +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) Entering state 1 -Stack now 0 6 8 19 1 +Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): - $1 = token number (5.10: 1) --> $$ = nterm exp (5.10: 1) -Entering state 28 -Stack now 0 6 8 19 28 + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 Reading a token -Next token is token '\n' (5.11-6.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (5.1-6: 1) - $2 = token '=' (5.8: ) - $3 = nterm exp (5.10: 1) --> $$ = nterm exp (5.1-10: 1) +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 120): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (5.11-6.0: ) -Shifting token '\n' (5.11-6.0: ) -Entering state 25 -Stack now 0 6 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (5.1-10: 1) - $2 = token '\n' (5.11-6.0: ) --> $$ = nterm line (5.1-6.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-5.0: ) - $2 = nterm line (5.1-6.0: ) --> $$ = nterm input (1.1-6.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '\n' (6.1-7.0: ) -Shifting token '\n' (6.1-7.0: ) -Entering state 3 -Stack now 0 6 3 -Reducing stack by rule 3 (line 96): - $1 = token '\n' (6.1-7.0: ) --> $$ = nterm line (6.1-7.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-6.0: ) - $2 = nterm line (6.1-7.0: ) --> $$ = nterm input (1.1-7.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '-' (7.1: ) -Shifting token '-' (7.1: ) -Entering state 2 -Stack now 0 6 2 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token '-' (7.2: ) -Shifting token '-' (7.2: ) -Entering state 2 -Stack now 0 6 2 2 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 Reading a token -Next token is token '-' (7.3: ) -Shifting token '-' (7.3: ) -Entering state 2 -Stack now 0 6 2 2 2 +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Stack now 0 8 21 5 13 +Reducing stack by rule 18 (line 143): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token number (7.4: 1) -Shifting token number (7.4: 1) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 6 2 2 2 1 +Stack now 0 1 Reducing stack by rule 5 (line 101): - $1 = token number (7.4: 1) --> $$ = nterm exp (7.4: 1) -Entering state 10 -Stack now 0 6 2 2 2 10 -Reading a token -Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 124): - $1 = token '-' (7.3: ) - $2 = nterm exp (7.4: 1) --> $$ = nterm exp (7.3-4: -1) -Entering state 10 -Stack now 0 6 2 2 10 -Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 124): - $1 = token '-' (7.2: ) - $2 = nterm exp (7.3-4: -1) --> $$ = nterm exp (7.2-4: 1) -Entering state 10 -Stack now 0 6 2 10 -Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 124): - $1 = token '-' (7.1: ) - $2 = nterm exp (7.2-4: 1) --> $$ = nterm exp (7.1-4: -1) + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (7.6: ) -Shifting token '=' (7.6: ) -Entering state 19 -Stack now 0 6 8 19 -Reading a token -Next token is token '-' (7.8: ) -Shifting token '-' (7.8: ) -Entering state 2 -Stack now 0 6 8 19 2 -Reading a token -Next token is token number (7.9: 1) -Shifting token number (7.9: 1) -Entering state 1 -Stack now 0 6 8 19 2 1 -Reducing stack by rule 5 (line 101): - $1 = token number (7.9: 1) --> $$ = nterm exp (7.9: 1) -Entering state 10 -Stack now 0 6 8 19 2 10 +Stack now 0 8 Reading a token -Next token is token '\n' (7.10-8.0: ) -Reducing stack by rule 11 (line 124): - $1 = token '-' (7.8: ) - $2 = nterm exp (7.9: 1) --> $$ = nterm exp (7.8-9: -1) -Entering state 28 -Stack now 0 6 8 19 28 -Next token is token '\n' (7.10-8.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (7.1-4: -1) - $2 = token '=' (7.6: ) - $3 = nterm exp (7.8-9: -1) --> $$ = nterm exp (7.1-9: -1) -Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (7.10-8.0: ) -Shifting token '\n' (7.10-8.0: ) -Entering state 25 -Stack now 0 6 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (7.1-9: -1) - $2 = token '\n' (7.10-8.0: ) --> $$ = nterm line (7.1-8.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-7.0: ) - $2 = nterm line (7.1-8.0: ) --> $$ = nterm input (1.1-8.0: ) -Entering state 6 -Stack now 0 6 +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Stack now 0 8 23 Reading a token -Next token is token '\n' (8.1-9.0: ) -Shifting token '\n' (8.1-9.0: ) -Entering state 3 -Stack now 0 6 3 -Reducing stack by rule 3 (line 96): - $1 = token '\n' (8.1-9.0: ) --> $$ = nterm line (8.1-9.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-8.0: ) - $2 = nterm line (8.1-9.0: ) --> $$ = nterm input (1.1-9.0: ) -Entering state 6 -Stack now 0 6 +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '/' (1.3: ) +Stack now 0 +./calc.at:1357: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1353: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1358: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1354: cat stderr +stderr: +./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1357: cat stderr +./calc.at:1355: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token number (9.1: 1) -Shifting token number (9.1: 1) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 6 1 +Stack now 0 1 Reducing stack by rule 5 (line 101): - $1 = token number (9.1: 1) --> $$ = nterm exp (9.1: 1) + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 -Stack now 0 6 8 +Stack now 0 8 Reading a token -Next token is token '-' (9.3: ) -Shifting token '-' (9.3: ) -Entering state 20 -Stack now 0 6 8 20 +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token number (1.3: 2) +Stack now 0 +./calc.at:1358: cat stderr +stderr: +./calc.at:1355: cat stderr +./calc.at:1353: cat stderr +input: +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token number (9.5: 2) -Shifting token number (9.5: 2) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 6 8 20 1 +Stack now 0 1 Reducing stack by rule 5 (line 101): - $1 = token number (9.5: 2) --> $$ = nterm exp (9.5: 2) -Entering state 29 -Stack now 0 6 8 20 29 -Reading a token -Next token is token '-' (9.7: ) -Reducing stack by rule 8 (line 113): - $1 = nterm exp (9.1: 1) - $2 = token '-' (9.3: ) - $3 = nterm exp (9.5: 2) --> $$ = nterm exp (9.1-5: -1) + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 -Stack now 0 6 8 -Next token is token '-' (9.7: ) -Shifting token '-' (9.7: ) -Entering state 20 -Stack now 0 6 8 20 -Reading a token -Next token is token number (9.9: 3) -Shifting token number (9.9: 3) -Entering state 1 -Stack now 0 6 8 20 1 -Reducing stack by rule 5 (line 101): - $1 = token number (9.9: 3) --> $$ = nterm exp (9.9: 3) -Entering state 29 -Stack now 0 6 8 20 29 +Stack now 0 8 Reading a token -Next token is token '=' (9.11: ) -Reducing stack by rule 8 (line 113): - $1 = nterm exp (9.1-5: -1) - $2 = token '-' (9.7: ) - $3 = nterm exp (9.9: 3) --> $$ = nterm exp (9.1-9: -4) -Entering state 8 -Stack now 0 6 8 -Next token is token '=' (9.11: ) -Shifting token '=' (9.11: ) -Entering state 19 -Stack now 0 6 8 19 +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Stack now 0 8 23 Reading a token -Next token is token '-' (9.13: ) -Shifting token '-' (9.13: ) -Entering state 2 -Stack now 0 6 8 19 2 +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '/' (1.3: ) +Stack now 0 +input: +./calc.at:1362: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (#) + (#) = 2222 +./calc.at:1354: $PREPARSER ./calc input + | 1 = 2 = 3 +./calc.at:1358: $PREPARSER ./calc input +input: +stderr: +./calc.at:1362: cat stderr + | (#) + (#) = 2222 +stderr: +./calc.at:1357: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token number (9.14: 4) -Shifting token number (9.14: 4) -Entering state 1 -Stack now 0 6 8 19 2 1 -Reducing stack by rule 5 (line 101): - $1 = token number (9.14: 4) --> $$ = nterm exp (9.14: 4) -Entering state 10 -Stack now 0 6 8 19 2 10 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 Reading a token -Next token is token '\n' (9.15-10.0: ) -Reducing stack by rule 11 (line 124): - $1 = token '-' (9.13: ) - $2 = nterm exp (9.14: 4) --> $$ = nterm exp (9.13-14: -4) -Entering state 28 -Stack now 0 6 8 19 28 -Next token is token '\n' (9.15-10.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (9.1-9: -4) - $2 = token '=' (9.11: ) - $3 = nterm exp (9.13-14: -4) --> $$ = nterm exp (9.1-14: -4) -Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (9.15-10.0: ) -Shifting token '\n' (9.15-10.0: ) -Entering state 25 -Stack now 0 6 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (9.1-14: -4) - $2 = token '\n' (9.15-10.0: ) --> $$ = nterm line (9.1-10.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-9.0: ) - $2 = nterm line (9.1-10.0: ) --> $$ = nterm input (1.1-10.0: ) -Entering state 6 -Stack now 0 6 +1.2: syntax error: invalid character: '#' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token number (10.1: 1) -Shifting token number (10.1: 1) -Entering state 1 -Stack now 0 6 1 -Reducing stack by rule 5 (line 101): - $1 = token number (10.1: 1) --> $$ = nterm exp (10.1: 1) +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) Entering state 8 -Stack now 0 6 8 +Stack now 0 8 Reading a token -Next token is token '-' (10.3: ) -Shifting token '-' (10.3: ) -Entering state 20 -Stack now 0 6 8 20 +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token '(' (10.5: ) -Shifting token '(' (10.5: ) +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) Entering state 4 -Stack now 0 6 8 20 4 -Reading a token -Next token is token number (10.6: 2) -Shifting token number (10.6: 2) -Entering state 1 -Stack now 0 6 8 20 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (10.6: 2) --> $$ = nterm exp (10.6: 2) -Entering state 12 -Stack now 0 6 8 20 4 12 -Reading a token -Next token is token '-' (10.8: ) -Shifting token '-' (10.8: ) -Entering state 20 -Stack now 0 6 8 20 4 12 20 +Stack now 0 8 21 4 Reading a token -Next token is token number (10.10: 3) -Shifting token number (10.10: 3) -Entering state 1 -Stack now 0 6 8 20 4 12 20 1 -Reducing stack by rule 5 (line 101): - $1 = token number (10.10: 3) --> $$ = nterm exp (10.10: 3) -Entering state 29 -Stack now 0 6 8 20 4 12 20 29 +1.8: syntax error: invalid character: '#' +Shifting token error (1.8: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token invalid token (1.8: ) +Error: discarding token invalid token (1.8: ) +Error: popping token error (1.8: ) +Stack now 0 8 21 4 +Shifting token error (1.8: ) +Entering state 11 +Stack now 0 8 21 4 11 Reading a token -Next token is token ')' (10.11: ) -Reducing stack by rule 8 (line 113): - $1 = nterm exp (10.6: 2) - $2 = token '-' (10.8: ) - $3 = nterm exp (10.10: 3) --> $$ = nterm exp (10.6-10: -1) -Entering state 12 -Stack now 0 6 8 20 4 12 -Next token is token ')' (10.11: ) -Shifting token ')' (10.11: ) -Entering state 27 -Stack now 0 6 8 20 4 12 27 -Reducing stack by rule 13 (line 126): - $1 = token '(' (10.5: ) - $2 = nterm exp (10.6-10: -1) - $3 = token ')' (10.11: ) --> $$ = nterm exp (10.5-11: -1) -Entering state 29 -Stack now 0 6 8 20 29 +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 30 +Stack now 0 8 21 30 Reading a token -Next token is token '=' (10.13: ) -Reducing stack by rule 8 (line 113): - $1 = nterm exp (10.1: 1) - $2 = token '-' (10.3: ) - $3 = nterm exp (10.5-11: -1) --> $$ = nterm exp (10.1-11: 2) +Next token is token '=' (1.11: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (10.13: ) -Shifting token '=' (10.13: ) +Stack now 0 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) Entering state 19 -Stack now 0 6 8 19 +Stack now 0 8 19 Reading a token -Next token is token number (10.15: 2) -Shifting token number (10.15: 2) +Next token is token number (1.13-16: 2222) +Shifting token number (1.13-16: 2222) Entering state 1 -Stack now 0 6 8 19 1 +Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (10.15: 2) --> $$ = nterm exp (10.15: 2) + $1 = token number (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) Entering state 28 -Stack now 0 6 8 19 28 +Stack now 0 8 19 28 Reading a token -Next token is token '\n' (10.16-11.0: ) +Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (10.1-11: 2) - $2 = token '=' (10.13: ) - $3 = nterm exp (10.15: 2) --> $$ = nterm exp (10.1-15: 2) + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (10.16-11.0: ) -Shifting token '\n' (10.16-11.0: ) +Stack now 0 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 25 -Stack now 0 6 8 25 +Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (10.1-15: 2) - $2 = token '\n' (10.16-11.0: ) --> $$ = nterm line (10.1-11.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-10.0: ) - $2 = nterm line (10.1-11.0: ) --> $$ = nterm input (1.1-11.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token '\n' (11.1-12.0: ) -Shifting token '\n' (11.1-12.0: ) -Entering state 3 -Stack now 0 6 3 -Reducing stack by rule 3 (line 96): - $1 = token '\n' (11.1-12.0: ) --> $$ = nterm line (11.1-12.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-11.0: ) - $2 = nterm line (11.1-12.0: ) --> $$ = nterm input (1.1-12.0: ) -Entering state 6 -Stack now 0 6 +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +input: +./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token number (12.1: 2) -Shifting token number (12.1: 2) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 6 1 +Stack now 0 1 Reducing stack by rule 5 (line 101): - $1 = token number (12.1: 2) --> $$ = nterm exp (12.1: 2) + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 -Stack now 0 6 8 -Reading a token -Next token is token '^' (12.2: ) -Shifting token '^' (12.2: ) -Entering state 24 -Stack now 0 6 8 24 -Reading a token -Next token is token number (12.3: 2) -Shifting token number (12.3: 2) -Entering state 1 -Stack now 0 6 8 24 1 -Reducing stack by rule 5 (line 101): - $1 = token number (12.3: 2) --> $$ = nterm exp (12.3: 2) -Entering state 33 -Stack now 0 6 8 24 33 -Reading a token -Next token is token '^' (12.4: ) -Shifting token '^' (12.4: ) -Entering state 24 -Stack now 0 6 8 24 33 24 -Reading a token -Next token is token number (12.5: 3) -Shifting token number (12.5: 3) -Entering state 1 -Stack now 0 6 8 24 33 24 1 -Reducing stack by rule 5 (line 101): - $1 = token number (12.5: 3) --> $$ = nterm exp (12.5: 3) -Entering state 33 -Stack now 0 6 8 24 33 24 33 +Stack now 0 8 +Return for a new token: Reading a token -Next token is token '=' (12.7: ) -Reducing stack by rule 12 (line 125): - $1 = nterm exp (12.3: 2) - $2 = token '^' (12.4: ) - $3 = nterm exp (12.5: 3) --> $$ = nterm exp (12.3-5: 8) -Entering state 33 -Stack now 0 6 8 24 33 -Next token is token '=' (12.7: ) -Reducing stack by rule 12 (line 125): - $1 = nterm exp (12.1: 2) - $2 = token '^' (12.2: ) - $3 = nterm exp (12.3-5: 8) --> $$ = nterm exp (12.1-5: 256) -Entering state 8 -Stack now 0 6 8 -Next token is token '=' (12.7: ) -Shifting token '=' (12.7: ) +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) Entering state 19 -Stack now 0 6 8 19 +Stack now 0 8 19 +Return for a new token: Reading a token -Next token is token number (12.9-11: 256) -Shifting token number (12.9-11: 256) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 -Stack now 0 6 8 19 1 +Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (12.9-11: 256) --> $$ = nterm exp (12.9-11: 256) + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 28 -Stack now 0 6 8 19 28 +Stack now 0 8 19 28 +Return for a new token: Reading a token -Next token is token '\n' (12.12-13.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (12.1-5: 256) - $2 = token '=' (12.7: ) - $3 = nterm exp (12.9-11: 256) --> $$ = nterm exp (12.1-11: 256) -Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (12.12-13.0: ) -Shifting token '\n' (12.12-13.0: ) -Entering state 25 -Stack now 0 6 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (12.1-11: 256) - $2 = token '\n' (12.12-13.0: ) --> $$ = nterm line (12.1-13.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-12.0: ) - $2 = nterm line (12.1-13.0: ) --> $$ = nterm input (1.1-13.0: ) -Entering state 6 -Stack now 0 6 +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 19 +Error: popping token '=' (1.3: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 +./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | 1 + 2 * 3 + !* ++ +./calc.at:1360: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1355: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token '(' (13.1: ) -Shifting token '(' (13.1: ) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 -Stack now 0 6 4 +Stack now 0 4 Reading a token -Next token is token number (13.2: 2) -Shifting token number (13.2: 2) -Entering state 1 -Stack now 0 6 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (13.2: 2) --> $$ = nterm exp (13.2: 2) -Entering state 12 -Stack now 0 6 4 12 +1.2: syntax error: invalid character: '#' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token '^' (13.3: ) -Shifting token '^' (13.3: ) -Entering state 24 -Stack now 0 6 4 12 24 +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) +Entering state 8 +Stack now 0 8 Reading a token -Next token is token number (13.4: 2) -Shifting token number (13.4: 2) -Entering state 1 -Stack now 0 6 4 12 24 1 -Reducing stack by rule 5 (line 101): - $1 = token number (13.4: 2) --> $$ = nterm exp (13.4: 2) -Entering state 33 -Stack now 0 6 4 12 24 33 +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token ')' (13.5: ) -Reducing stack by rule 12 (line 125): - $1 = nterm exp (13.2: 2) - $2 = token '^' (13.3: ) - $3 = nterm exp (13.4: 2) --> $$ = nterm exp (13.2-4: 4) -Entering state 12 -Stack now 0 6 4 12 -Next token is token ')' (13.5: ) -Shifting token ')' (13.5: ) -Entering state 27 -Stack now 0 6 4 12 27 -Reducing stack by rule 13 (line 126): - $1 = token '(' (13.1: ) - $2 = nterm exp (13.2-4: 4) - $3 = token ')' (13.5: ) --> $$ = nterm exp (13.1-5: 4) -Entering state 8 -Stack now 0 6 8 +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Stack now 0 8 21 4 Reading a token -Next token is token '^' (13.6: ) -Shifting token '^' (13.6: ) -Entering state 24 -Stack now 0 6 8 24 +1.8: syntax error: invalid character: '#' +Shifting token error (1.8: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token invalid token (1.8: ) +Error: discarding token invalid token (1.8: ) +Error: popping token error (1.8: ) +Stack now 0 8 21 4 +Shifting token error (1.8: ) +Entering state 11 +Stack now 0 8 21 4 11 Reading a token -Next token is token number (13.7: 3) -Shifting token number (13.7: 3) -Entering state 1 -Stack now 0 6 8 24 1 -Reducing stack by rule 5 (line 101): - $1 = token number (13.7: 3) --> $$ = nterm exp (13.7: 3) -Entering state 33 -Stack now 0 6 8 24 33 +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 30 +Stack now 0 8 21 30 Reading a token -Next token is token '=' (13.9: ) -Reducing stack by rule 12 (line 125): - $1 = nterm exp (13.1-5: 4) - $2 = token '^' (13.6: ) - $3 = nterm exp (13.7: 3) --> $$ = nterm exp (13.1-7: 64) +Next token is token '=' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (13.9: ) -Shifting token '=' (13.9: ) +Stack now 0 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) Entering state 19 -Stack now 0 6 8 19 +Stack now 0 8 19 Reading a token -Next token is token number (13.11-12: 64) -Shifting token number (13.11-12: 64) +Next token is token number (1.13-16: 2222) +Shifting token number (1.13-16: 2222) Entering state 1 -Stack now 0 6 8 19 1 +Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (13.11-12: 64) --> $$ = nterm exp (13.11-12: 64) + $1 = token number (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) Entering state 28 -Stack now 0 6 8 19 28 +Stack now 0 8 19 28 Reading a token -Next token is token '\n' (13.13-14.0: ) +Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (13.1-7: 64) - $2 = token '=' (13.9: ) - $3 = nterm exp (13.11-12: 64) --> $$ = nterm exp (13.1-12: 64) + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (13.13-14.0: ) -Shifting token '\n' (13.13-14.0: ) +Stack now 0 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 25 -Stack now 0 6 8 25 +Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (13.1-12: 64) - $2 = token '\n' (13.13-14.0: ) --> $$ = nterm line (13.1-14.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 92): - $1 = nterm input (1.1-13.0: ) - $2 = nterm line (13.1-14.0: ) --> $$ = nterm input (1.1-14.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (14.1: ) +Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (14.1: ) -Cleanup: popping nterm input (1.1-14.0: ) -stderr: -./calc.at:1362: $EGREP -c -v 'Return for a new token:|LAC:' stderr -stdout: -./calc.at:1367: cat stderr -stderr: -./calc.at:1364: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1353: cat stderr -./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 2 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + # + 1) = 1111 input: -./calc.at:1362: $PREPARSER ./calc input stderr: -input: +./calc.at:1353: $PREPARSER ./calc input stderr: - | 1//2 stderr: -======== Testing with C++ standard flags: '' Starting parse Entering state 0 Stack now 0 @@ -58774,12 +58127,34 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 +Return for a new token: Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 19 +Stack now 0 8 19 +Return for a new token: +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 28 +Stack now 0 8 19 28 +Return for a new token: +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 19 +Error: popping token '=' (1.3: ) +Stack now 0 8 Error: popping nterm exp (1.1: 1) Stack now 0 -Cleanup: discarding lookahead token number (1.3: 2) +Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 Starting parse Entering state 0 @@ -58790,298 +58165,453 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token -Next token is token number (1.7: 1) -Shifting token number (1.7: 1) +1.8: syntax error: invalid character: '#' +Shifting token error (1.8: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token invalid token (1.8: ) +Error: discarding token invalid token (1.8: ) +Error: popping token error (1.8: ) +Stack now 0 8 21 4 +Shifting token error (1.8: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.13-16: 2222) +Shifting token number (1.13-16: 2222) Entering state 1 -Stack now 0 8 21 4 1 +Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Stack now 0 8 21 4 12 + $1 = token number (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) +Entering state 28 +Stack now 0 8 19 28 Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 21 -Stack now 0 8 21 4 12 21 +Next token is token '\n' (1.17-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token number (1.11: 1) -Shifting token number (1.11: 1) +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 8 21 4 12 21 1 +Stack now 0 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.11: 1) --> $$ = nterm exp (1.11: 1) -Entering state 30 -Stack now 0 8 21 4 12 21 30 + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 Reading a token -Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 21 -Stack now 0 8 21 4 12 21 +Stack now 0 8 21 Reading a token -Next token is token number (1.15: 1) -Shifting token number (1.15: 1) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 -Stack now 0 8 21 4 12 21 1 +Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.15: 1) --> $$ = nterm exp (1.15: 1) + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 30 -Stack now 0 8 21 4 12 21 30 +Stack now 0 8 21 30 Reading a token -Next token is token '+' (1.17: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 21 -Stack now 0 8 21 4 12 21 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.7-15: 3) -Stack now 0 8 21 4 -Shifting token error (1.7-18: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 120): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 -Reading a token -Next token is token '+' (1.20: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Stack now 0 8 21 5 15 +Reducing stack by rule 19 (line 144): + $1 = token '!' (1.13: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +stderr: + | 1//2 +./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1362: $PREPARSER ./calc input +./calc.at:1360: cat stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 -Stack now 0 8 21 4 +Stack now 0 4 Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +syntax error: invalid character: '#' +Error: popping token '+' (1.1: ) +Stack now 0 4 12 +Error: popping nterm exp (1.1: 1) +Stack now 0 4 +Shifting token error (1.1: ) Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Error: popping token error (1.23: ) -Stack now 0 8 21 4 -Shifting token error (1.23: ) +Stack now 0 4 11 +Next token is token "invalid token" (1.1: ) +Error: discarding token "invalid token" (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) Entering state 11 -Stack now 0 8 21 4 11 +Stack now 0 4 11 Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Error: popping token error (1.23: ) -Stack now 0 8 21 4 -Shifting token error (1.23-25: ) +Next token is token '+' (1.1: ) +Error: discarding token '+' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) Entering state 11 -Stack now 0 8 21 4 11 +Stack now 0 4 11 Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) -Error: popping token error (1.23-25: ) -Stack now 0 8 21 4 -Shifting token error (1.23-27: ) +Next token is token "number" (1.1: 1) +Error: discarding token "number" (1.1: 1) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) Entering state 11 -Stack now 0 8 21 4 11 +Stack now 0 4 11 Reading a token -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '+' (1.30: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) -Entering state 21 -Stack now 0 8 21 Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) -Entering state 4 -Stack now 0 8 21 4 +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token number (1.33: 1) -Shifting token number (1.33: 1) +Next token is token "number" (1.1: 1111) +Shifting token "number" (1.1: 1111) Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Stack now 0 8 21 4 12 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) +Entering state 28 +Stack now 0 8 19 28 Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 22 -Stack now 0 8 21 4 12 22 +Next token is token '\n' (1.1: ) +Reducing stack by rule 6 (line 82): + $1 = nterm exp (1.1: 1111) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 1111) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token number (1.37: 2) -Shifting token number (1.37: 2) +Now at end of input. +Shifting token "end of input" (1.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) +stderr: +stderr: +./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 8 21 4 12 22 1 +Stack now 0 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 31 -Stack now 0 8 21 4 12 22 31 + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 Reading a token -Next token is token '*' (1.39: ) -Reducing stack by rule 9 (line 114): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 22 -Stack now 0 8 21 4 12 22 +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Stack now 0 8 23 Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.33-37: 2) +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '/' (1.3: ) +Stack now 0 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +1.2: syntax error: invalid character: '#' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 Stack now 0 8 21 4 -Shifting token error (1.33-41: ) +Reading a token +1.8: syntax error: invalid character: '#' +Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Error: popping token error (1.33-41: ) +Next token is token invalid token (1.8: ) +Error: discarding token invalid token (1.8: ) +Error: popping token error (1.8: ) Stack now 0 8 21 4 -Shifting token error (1.33-41: ) +Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token -Next token is token '=' (1.44: ) +Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.46: 1) -Shifting token number (1.46: 1) +Next token is token number (1.13-16: 2222) +Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.46: 1) --> $$ = nterm exp (1.46: 1) + $1 = token number (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.47-2.0: ) +Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -59098,83 +58628,234 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1358: $PREPARSER ./calc input -./calc.at:1364: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c calc.h - +stderr: +stderr: +./calc.at:1358: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +./calc.at:1354: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token -Next token is token "number" (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token "number" (1.3: 2) -Stack now 0 - | 1 = 2 = 3 -./calc.at:1367: $PREPARSER ./calc input -484. calc.at:1353: ok -./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -input: +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 120): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Stack now 0 8 21 5 15 +Reducing stack by rule 19 (line 144): + $1 = token '!' (1.13: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./types.at:139: $PREPARSER ./test stderr: - | (1 + 1) / (1 - 1) +./calc.at:1358: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) +Stack now 0 4 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +syntax error: invalid character: '#' +Error: popping token '+' (1.1: ) +Stack now 0 4 12 +Error: popping nterm exp (1.1: 1) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Next token is token "invalid token" (1.1: ) +Error: discarding token "invalid token" (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '+' (1.1: ) +Error: discarding token '+' (1.1: ) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token "number" (1.1: 1) +Error: discarding token "number" (1.1: 1) +Error: popping token error (1.1: ) +Stack now 0 4 +Shifting token error (1.1: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) Entering state 8 Stack now 0 8 -Return for a new token: Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Stack now 0 8 23 -Return for a new token: +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) +Next token is token "number" (1.1: 1111) +Shifting token "number" (1.1: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.1: ) +Reducing stack by rule 6 (line 82): + $1 = nterm exp (1.1: 1111) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) -Stack now 0 +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 1111) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token "end of input" (1.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) stderr: -./calc.at:1354: $PREPARSER ./calc input -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) input: -./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (* *) + (*) + (*) +stderr: +./calc.at:1354: cat stderr + | error +./calc.at:1360: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -59202,7 +58883,7 @@ Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 -./calc.at:1363: "$PERL" -pi -e 'use strict; +./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -59212,22 +58893,59 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1355: $PREPARSER ./calc input - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 +stderr: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1362: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) +Stack now 0 +input: +input: +450. types.at:139: ./calc.at:1355: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + ok +./calc.at:1355: cat stderr +./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1364: $PREPARSER ./calc input + | +1 +./calc.at:1358: $PREPARSER ./calc input +./calc.at:1353: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (1 + #) = 1111 +./calc.at:1354: $PREPARSER ./calc input stderr: +./calc.at:1362: cat stderr +./calc.at:1357: cat stderr stderr: Starting parse Entering state 0 @@ -59253,107 +58971,203 @@ Entering state 21 Stack now 0 4 12 21 Reading a token -Next token is token number (1.6: 1) -Shifting token number (1.6: 1) -Entering state 1 -Stack now 0 4 12 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 30 -Stack now 0 4 12 21 30 -Reading a token -Next token is token ')' (1.7: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 +1.6: syntax error: invalid character: '#' +Error: popping token '+' (1.4: ) Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) -Entering state 27 -Stack now 0 4 12 27 -Reducing stack by rule 13 (line 138): +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) + $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 23 -Stack now 0 8 23 +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 96): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Return for a new token: +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Stack now 0 +Cleanup: discarding lookahead token '+' (2.1: ) +Stack now 0 +./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) +Stack now 0 +input: +stderr: +./calc.at:1353: cat stderr +input: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 -Stack now 0 8 23 4 +Stack now 0 4 Reading a token -Next token is token number (1.12: 1) -Shifting token number (1.12: 1) +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 -Stack now 0 8 23 4 1 +Stack now 0 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.12: 1) --> $$ = nterm exp (1.12: 1) + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) Entering state 12 -Stack now 0 8 23 4 12 +Stack now 0 4 12 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 20 -Stack now 0 8 23 4 12 20 +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) +1.6: syntax error: invalid character: '#' +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 -Stack now 0 8 23 4 12 20 1 +Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 29 -Stack now 0 8 23 4 12 20 29 -Reading a token -Next token is token ')' (1.17: ) -Reducing stack by rule 8 (line 119): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Stack now 0 8 23 4 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 27 -Stack now 0 8 23 4 12 27 -Reducing stack by rule 13 (line 138): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 32 -Stack now 0 8 23 32 + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 10 (line 121): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -59370,49 +59184,54 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1363: cat stderr stderr: -./calc.at:1357: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +input: + | error + + | (#) + (#) = 2222 +./calc.at:1355: $PREPARSER ./calc input +./calc.at:1362: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Return for a new token: -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Stack now 0 8 23 +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 96): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 Return for a new token: Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) +Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 + | (1 + #) = 1111 +stderr: +./calc.at:1357: $PREPARSER ./calc input stderr: +input: +./calc.at:1360: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Stack now 0 @@ -59422,132 +59241,102 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) +1.8: syntax error: invalid character: '#' +Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) -Error: popping token error (1.10: ) +Next token is token invalid token (1.8: ) +Error: discarding token invalid token (1.8: ) +Error: popping token error (1.8: ) Stack now 0 8 21 4 -Shifting token error (1.10: ) +Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 139): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token -Next token is token '+' (1.13: ) +Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) -Error: popping token error (1.16: ) -Stack now 0 8 21 4 -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 21 4 11 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 30 -Stack now 0 8 21 30 +Next token is token number (1.13-16: 2222) +Shifting token number (1.13-16: 2222) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) +Entering state 28 +Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) +Next token is token '\n' (1.17-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -59565,7 +59354,27 @@ Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) +Stack now 0 + | (1 + 1) / (1 - 1) +./calc.at:1354: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: +./calc.at:1353: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -59590,181 +59399,310 @@ Entering state 21 Stack now 0 4 12 21 Reading a token -Next token is token number (1.6: 1) -Shifting token number (1.6: 1) +1.6: syntax error: invalid character: '#' +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 -Stack now 0 4 12 21 1 +Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.6: 1) --> $$ = nterm exp (1.6: 1) + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: +./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1358: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1354: cat stderr +./calc.at:1360: cat stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 4 12 21 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token -Next token is token ')' (1.7: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) +Next token is token ')' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1) +-> $$ = nterm exp (1.1: 2) Entering state 12 Stack now 0 4 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) Entering state 27 Stack now 0 4 12 27 -Reducing stack by rule 13 (line 138): +Reducing stack by rule 13 (line 118): $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) + $2 = nterm exp (1.1: 2) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) +Next token is token '/' (1.1: ) +Shifting token '/' (1.1: ) Entering state 23 Stack now 0 8 23 Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Stack now 0 8 23 4 Reading a token -Next token is token number (1.12: 1) -Shifting token number (1.12: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.12: 1) --> $$ = nterm exp (1.12: 1) +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 12 Stack now 0 8 23 4 12 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) +Next token is token '-' (1.1: ) +Shifting token '-' (1.1: ) Entering state 20 Stack now 0 8 23 4 12 20 Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token -Next token is token ')' (1.17: ) -Reducing stack by rule 8 (line 119): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) +Next token is token ')' (1.1: ) +Reducing stack by rule 8 (line 99): + $1 = nterm exp (1.1: 1) + $2 = token '-' (1.1: ) + $3 = nterm exp (1.1: 1) +-> $$ = nterm exp (1.1: 0) Entering state 12 Stack now 0 8 23 4 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) Entering state 27 Stack now 0 8 23 4 12 27 -Reducing stack by rule 13 (line 138): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) +Reducing stack by rule 13 (line 118): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.1: 0) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 0) Entering state 32 Stack now 0 8 23 32 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 10 (line 121): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) +Next token is token '\n' (1.1: ) +Reducing stack by rule 10 (line 101): + $1 = nterm exp (1.1: 2) + $2 = token '/' (1.1: ) + $3 = nterm exp (1.1: 0) +error: null divisor +-> $$ = nterm exp (1.1: 2) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 2) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (1.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +1.2: syntax error: invalid character: '#' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Stack now 0 8 21 4 Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 +1.8: syntax error: invalid character: '#' +Shifting token error (1.8: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token invalid token (1.8: ) +Error: discarding token invalid token (1.8: ) +Error: popping token error (1.8: ) +Stack now 0 8 21 4 +Shifting token error (1.8: ) +Entering state 11 +Stack now 0 8 21 4 11 Reading a token -Next token is token '=' (1.11: ) -Reducing stack by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 +Reading a token Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 Next token is token '=' (1.11: ) @@ -59772,259 +59710,2665 @@ Entering state 19 Stack now 0 8 19 Reading a token -Next token is token "number" (1.13: 7) -Shifting token "number" (1.13: 7) +Next token is token number (1.13-16: 2222) +Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.13: 7) --> $$ = nterm exp (1.13: 7) +Reducing stack by rule 5 (line 101): + $1 = token number (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.14-2.0: ) -Reducing stack by rule 6 (line 89): - $1 = nterm exp (1.1-9: 7) +Next token is token '\n' (1.17-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) - $3 = nterm exp (1.13: 7) --> $$ = nterm exp (1.1-13: 7) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.14-2.0: ) -Shifting token '\n' (1.14-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-13: 7) - $2 = token '\n' (1.14-2.0: ) +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 78): +Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token "number" (2.1: 1) -Shifting token "number" (2.1: 1) -Entering state 1 -Stack now 0 6 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (2.1: 1) --> $$ = nterm exp (2.1: 1) -Entering state 8 -Stack now 0 6 8 +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1353: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +./calc.at:1358: cat stderr +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token '+' (2.3: ) -Shifting token '+' (2.3: ) -Entering state 21 -Stack now 0 6 8 21 +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) +Stack now 0 +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token "number" (2.5: 2) -Shifting token "number" (2.5: 2) -Entering state 1 -Stack now 0 6 8 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (2.5: 2) --> $$ = nterm exp (2.5: 2) -Entering state 30 -Stack now 0 6 8 21 30 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 Reading a token -Next token is token '*' (2.7: ) -Shifting token '*' (2.7: ) -Entering state 22 -Stack now 0 6 8 21 30 22 +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 Reading a token -Next token is token '-' (2.9: ) -Shifting token '-' (2.9: ) -Entering state 2 -Stack now 0 6 8 21 30 22 2 +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 Reading a token -Next token is token "number" (2.10: 3) -Shifting token "number" (2.10: 3) -Entering state 1 -Stack now 0 6 8 21 30 22 2 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (2.10: 3) --> $$ = nterm exp (2.10: 3) -Entering state 10 -Stack now 0 6 8 21 30 22 2 10 +1.6: syntax error: invalid character: '#' +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token '=' (2.12: ) -Reducing stack by rule 11 (line 111): - $1 = token '-' (2.9: ) - $2 = nterm exp (2.10: 3) --> $$ = nterm exp (2.9-10: -3) -Entering state 31 -Stack now 0 6 8 21 30 22 31 -Next token is token '=' (2.12: ) -Reducing stack by rule 9 (line 101): - $1 = nterm exp (2.5: 2) - $2 = token '*' (2.7: ) - $3 = nterm exp (2.9-10: -3) --> $$ = nterm exp (2.5-10: -6) -Entering state 30 -Stack now 0 6 8 21 30 -Next token is token '=' (2.12: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (2.1: 1) - $2 = token '+' (2.3: ) - $3 = nterm exp (2.5-10: -6) --> $$ = nterm exp (2.1-10: -5) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (2.12: ) -Shifting token '=' (2.12: ) -Entering state 19 -Stack now 0 6 8 19 +Stack now 0 8 Reading a token -Next token is token '-' (2.14: ) -Shifting token '-' (2.14: ) -Entering state 2 -Stack now 0 6 8 19 2 +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token "number" (2.15: 5) -Shifting token "number" (2.15: 5) +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 -Stack now 0 6 8 19 2 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (2.15: 5) --> $$ = nterm exp (2.15: 5) -Entering state 10 -Stack now 0 6 8 19 2 10 -Reading a token -Next token is token '\n' (2.16-3.0: ) -Reducing stack by rule 11 (line 111): - $1 = token '-' (2.14: ) - $2 = nterm exp (2.15: 5) --> $$ = nterm exp (2.14-15: -5) +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 28 -Stack now 0 6 8 19 28 -Next token is token '\n' (2.16-3.0: ) -Reducing stack by rule 6 (line 89): - $1 = nterm exp (2.1-10: -5) - $2 = token '=' (2.12: ) - $3 = nterm exp (2.14-15: -5) --> $$ = nterm exp (2.1-15: -5) +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (2.16-3.0: ) -Shifting token '\n' (2.16-3.0: ) +Stack now 0 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 25 -Stack now 0 6 8 25 -Reducing stack by rule 4 (line 84): - $1 = nterm exp (2.1-15: -5) - $2 = token '\n' (2.16-3.0: ) --> $$ = nterm line (2.1-3.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 79): - $1 = nterm input (1.1-2.0: ) - $2 = nterm line (2.1-3.0: ) --> $$ = nterm input (1.1-3.0: ) +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token '\n' (3.1-4.0: ) -Shifting token '\n' (3.1-4.0: ) -Entering state 3 -Stack now 0 6 3 -Reducing stack by rule 3 (line 83): - $1 = token '\n' (3.1-4.0: ) --> $$ = nterm line (3.1-4.0: ) -Entering state 18 -Stack now 0 6 18 -Reducing stack by rule 2 (line 79): - $1 = nterm input (1.1-3.0: ) - $2 = nterm line (3.1-4.0: ) --> $$ = nterm input (1.1-4.0: ) -Entering state 6 -Stack now 0 6 +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +493. calc.at:1367: testing Calculator parse.error=custom ... +./calc.at:1367: mv calc.y.tmp calc.y + +./calc.at:1358: $PREPARSER ./calc /dev/null +stderr: +./calc.at:1367: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +stderr: +input: +input: +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token '-' (4.1: ) -Shifting token '-' (4.1: ) -Entering state 2 -Stack now 0 6 2 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 Reading a token -Next token is token "number" (4.2: 1) -Shifting token "number" (4.2: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Stack now 0 6 2 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (4.2: 1) --> $$ = nterm exp (4.2: 1) -Entering state 10 -Stack now 0 6 2 10 +Stack now 0 4 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 +Stack now 0 4 12 Reading a token -Next token is token '^' (4.3: ) -Shifting token '^' (4.3: ) -Entering state 24 -Stack now 0 6 2 10 24 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Stack now 0 4 12 21 Reading a token -Next token is token "number" (4.4: 2) -Shifting token "number" (4.4: 2) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Stack now 0 6 2 10 24 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (4.4: 2) --> $$ = nterm exp (4.4: 2) -Entering state 33 -Stack now 0 6 2 10 24 33 +Stack now 0 4 12 21 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 30 +Stack now 0 4 12 21 30 Reading a token -Next token is token '=' (4.6: ) -Reducing stack by rule 12 (line 112): - $1 = nterm exp (4.2: 1) - $2 = token '^' (4.3: ) - $3 = nterm exp (4.4: 2) --> $$ = nterm exp (4.2-4: 1) -Entering state 10 -Stack now 0 6 2 10 -Next token is token '=' (4.6: ) -Reducing stack by rule 11 (line 111): - $1 = token '-' (4.1: ) - $2 = nterm exp (4.2-4: 1) --> $$ = nterm exp (4.1-4: -1) +Next token is token ')' (1.1: ) +Reducing stack by rule 7 (line 98): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1) +-> $$ = nterm exp (1.1: 2) +Entering state 12 +Stack now 0 4 12 +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 27 +Stack now 0 4 12 27 +Reducing stack by rule 13 (line 118): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.1: 2) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 2) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (4.6: ) -Shifting token '=' (4.6: ) -Entering state 19 -Stack now 0 6 8 19 +Stack now 0 8 Reading a token -Next token is token '-' (4.8: ) -Shifting token '-' (4.8: ) -Entering state 2 -Stack now 0 6 8 19 2 +Next token is token '/' (1.1: ) +Shifting token '/' (1.1: ) +Entering state 23 +Stack now 0 8 23 Reading a token -Next token is token "number" (4.9: 1) -Shifting token "number" (4.9: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 8 23 4 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Stack now 0 6 8 19 2 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (4.9: 1) --> $$ = nterm exp (4.9: 1) -Entering state 10 -Stack now 0 6 8 19 2 10 +Stack now 0 8 23 4 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 +Stack now 0 8 23 4 12 Reading a token -Next token is token '\n' (4.10-5.0: ) -Reducing stack by rule 11 (line 111): - $1 = token '-' (4.8: ) - $2 = nterm exp (4.9: 1) --> $$ = nterm exp (4.8-9: -1) -Entering state 28 -Stack now 0 6 8 19 28 -Next token is token '\n' (4.10-5.0: ) -Reducing stack by rule 6 (line 89): - $1 = nterm exp (4.1-4: -1) - $2 = token '=' (4.6: ) - $3 = nterm exp (4.8-9: -1) +Next token is token '-' (1.1: ) +Shifting token '-' (1.1: ) +Entering state 20 +Stack now 0 8 23 4 12 20 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 8 23 4 12 20 1 +Reducing stack by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 29 +Stack now 0 8 23 4 12 20 29 +Reading a token +Next token is token ')' (1.1: ) +Reducing stack by rule 8 (line 99): + $1 = nterm exp (1.1: 1) + $2 = token '-' (1.1: ) + $3 = nterm exp (1.1: 1) +-> $$ = nterm exp (1.1: 0) +Entering state 12 +Stack now 0 8 23 4 12 +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 27 +Stack now 0 8 23 4 12 27 +Reducing stack by rule 13 (line 118): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.1: 0) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 0) +Entering state 32 +Stack now 0 8 23 32 +Reading a token +Next token is token '\n' (1.1: ) +Reducing stack by rule 10 (line 101): + $1 = nterm exp (1.1: 2) + $2 = token '/' (1.1: ) + $3 = nterm exp (1.1: 0) +error: null divisor +-> $$ = nterm exp (1.1: 2) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 77): + $1 = nterm exp (1.1: 2) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token "end of input" (1.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) + | (# + 1) = 1111 +./calc.at:1354: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Now at end of input. +1.1: syntax error, unexpected end of file +Cleanup: discarding lookahead token end of file (1.1: ) +Stack now 0 + | 1 = 2 = 3 +./calc.at:1360: $PREPARSER ./calc input +./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1357: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1362: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +stderr: +./calc.at:1355: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +1.2: syntax error: invalid character: '#' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token number (1.6: 1) +Error: discarding token number (1.6: 1) +Error: popping token error (1.2-4: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 19 +Error: popping token '=' (1.3: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 +./calc.at:1357: cat stderr +stderr: +./calc.at:1355: cat stderr +stderr: +./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Now at end of input. +1.1: syntax error, unexpected end of file +Cleanup: discarding lookahead token end of file (1.1: ) +Stack now 0 +./calc.at:1362: cat stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +1.2: syntax error: invalid character: '#' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token number (1.6: 1) +Error: discarding token number (1.6: 1) +Error: popping token error (1.2-4: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +input: +stderr: + | (# + 1) = 1111 +./calc.at:1357: $PREPARSER ./calc input +./calc.at:1353: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 19 +Error: popping token '=' (1.3: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 +input: +./calc.at:1354: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1367: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +stderr: + | 1 = 2 = 3 +./calc.at:1362: $PREPARSER ./calc input + | (1 + #) = 1111 +./calc.at:1355: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +1.2: syntax error: invalid character: '#' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token number (1.6: 1) +Error: discarding token number (1.6: 1) +Error: popping token error (1.2-4: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1358: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 19 +Error: popping token '=' (1.3: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 +./calc.at:1354: cat stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +1.6: syntax error: invalid character: '#' +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1360: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +1.2: syntax error: invalid character: '#' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token number (1.6: 1) +Error: discarding token number (1.6: 1) +Error: popping token error (1.2-4: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1358: cat stderr +./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1353: cat stderr +./calc.at:1360: cat stderr +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +1.6: syntax error: invalid character: '#' +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1357: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +stderr: + | (1 + # + 1) = 1111 +./calc.at:1354: $PREPARSER ./calc input +484. calc.at:1353: ok +input: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 19 +Error: popping token '=' (1.3: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 +stderr: +input: +./calc.at:1357: cat stderr +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +1.6: syntax error: invalid character: '#' +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-8: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token number (1.10: 1) +Error: discarding token number (1.10: 1) +Error: popping token error (1.2-8: ) +Stack now 0 4 +Shifting token error (1.2-10: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.15-18: 1111) +Shifting token number (1.15-18: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.19-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 + | + | +1 +./calc.at:1360: $PREPARSER ./calc input +stdout: +./calc.at:1358: $PREPARSER ./calc input +stderr: +./calc.at:1364: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +./calc.at:1355: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 96): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Stack now 0 +Cleanup: discarding lookahead token '+' (2.1: ) +Stack now 0 +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Return for a new token: +Reading a token +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 +Stack now 0 8 +Return for a new token: +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 8 21 +Return for a new token: +Reading a token +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Stack now 0 8 21 4 +Return for a new token: +Reading a token +Next token is token number (1.7: 1) +Shifting token number (1.7: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.7: 1) +-> $$ = nterm exp (1.7: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Return for a new token: +Reading a token +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Return for a new token: +Reading a token +Next token is token number (1.11: 1) +Shifting token number (1.11: 1) +Entering state 1 +Stack now 0 8 21 4 12 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 30 +Stack now 0 8 21 4 12 21 30 +Return for a new token: +Reading a token +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Return for a new token: +Reading a token +Next token is token number (1.15: 1) +Shifting token number (1.15: 1) +Entering state 1 +Stack now 0 8 21 4 12 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 30 +Stack now 0 8 21 4 12 21 30 +Return for a new token: +Reading a token +Next token is token '+' (1.17: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Return for a new token: +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.7-15: 3) +Stack now 0 8 21 4 +Shifting token error (1.7-18: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 30 +Stack now 0 8 21 30 +Return for a new token: +Reading a token +Next token is token '+' (1.20: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 21 +Stack now 0 8 21 +Return for a new token: +Reading a token +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 +Stack now 0 8 21 4 +Return for a new token: +Reading a token +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) +Error: popping token error (1.23: ) +Stack now 0 8 21 4 +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 21 4 11 +Return for a new token: +Reading a token +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Error: popping token error (1.23: ) +Stack now 0 8 21 4 +Shifting token error (1.23-25: ) +Entering state 11 +Stack now 0 8 21 4 11 +Return for a new token: +Reading a token +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Error: popping token error (1.23-25: ) +Stack now 0 8 21 4 +Shifting token error (1.23-27: ) +Entering state 11 +Stack now 0 8 21 4 11 +Return for a new token: +Reading a token +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 30 +Stack now 0 8 21 30 +Return for a new token: +Reading a token +Next token is token '+' (1.30: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +Entering state 21 +Stack now 0 8 21 +Return for a new token: +Reading a token +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) +Entering state 4 +Stack now 0 8 21 4 +Return for a new token: +Reading a token +Next token is token number (1.33: 1) +Shifting token number (1.33: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Return for a new token: +Reading a token +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 22 +Stack now 0 8 21 4 12 22 +Return for a new token: +Reading a token +Next token is token number (1.37: 2) +Shifting token number (1.37: 2) +Entering state 1 +Stack now 0 8 21 4 12 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 31 +Stack now 0 8 21 4 12 22 31 +Return for a new token: +Reading a token +Next token is token '*' (1.39: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 22 +Stack now 0 8 21 4 12 22 +Return for a new token: +Reading a token +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.33-37: 2) +Stack now 0 8 21 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) +Error: popping token error (1.33-41: ) +Stack now 0 8 21 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 21 4 11 +Return for a new token: +Reading a token +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) +Entering state 30 +Stack now 0 8 21 30 +Return for a new token: +Reading a token +Next token is token '=' (1.44: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) +Entering state 19 +Stack now 0 8 19 +Return for a new token: +Reading a token +Next token is token number (1.46: 1) +Shifting token number (1.46: 1) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.46: 1) +-> $$ = nterm exp (1.46: 1) +Entering state 28 +Stack now 0 8 19 28 +Return for a new token: +Reading a token +Next token is token '\n' (1.47-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Return for a new token: +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1364: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c calc.h + +./calc.at:1362: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +1.6: syntax error: invalid character: '#' +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-8: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token number (1.10: 1) +Error: discarding token number (1.10: 1) +Error: popping token error (1.2-8: ) +Stack now 0 4 +Shifting token error (1.2-10: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.15-18: 1111) +Shifting token number (1.15-18: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.19-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1355: cat stderr + +./calc.at:1362: cat stderr + | (1 + # + 1) = 1111 +./calc.at:1357: $PREPARSER ./calc input +input: +stderr: +stderr: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1364: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Return for a new token: +Reading a token +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 +Stack now 0 8 +Return for a new token: +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 8 21 +Return for a new token: +Reading a token +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Stack now 0 8 21 4 +Return for a new token: +Reading a token +Next token is token number (1.7: 1) +Shifting token number (1.7: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.7: 1) +-> $$ = nterm exp (1.7: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Return for a new token: +Reading a token +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Return for a new token: +Reading a token +Next token is token number (1.11: 1) +Shifting token number (1.11: 1) +Entering state 1 +Stack now 0 8 21 4 12 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 30 +Stack now 0 8 21 4 12 21 30 +Return for a new token: +Reading a token +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Return for a new token: +Reading a token +Next token is token number (1.15: 1) +Shifting token number (1.15: 1) +Entering state 1 +Stack now 0 8 21 4 12 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 30 +Stack now 0 8 21 4 12 21 30 +Return for a new token: +Reading a token +Next token is token '+' (1.17: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Return for a new token: +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.7-15: 3) +Stack now 0 8 21 4 +Shifting token error (1.7-18: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 30 +Stack now 0 8 21 30 +Return for a new token: +Reading a token +Next token is token '+' (1.20: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 21 +Stack now 0 8 21 +Return for a new token: +Reading a token +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 +Stack now 0 8 21 4 +Return for a new token: +Reading a token +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) +Error: popping token error (1.23: ) +Stack now 0 8 21 4 +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 21 4 11 +Return for a new token: +Reading a token +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Error: popping token error (1.23: ) +Stack now 0 8 21 4 +Shifting token error (1.23-25: ) +Entering state 11 +Stack now 0 8 21 4 11 +Return for a new token: +Reading a token +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Error: popping token error (1.23-25: ) +Stack now 0 8 21 4 +Shifting token error (1.23-27: ) +Entering state 11 +Stack now 0 8 21 4 11 +Return for a new token: +Reading a token +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 30 +Stack now 0 8 21 30 +Return for a new token: +Reading a token +Next token is token '+' (1.30: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +Entering state 21 +Stack now 0 8 21 +Return for a new token: +Reading a token +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) +Entering state 4 +Stack now 0 8 21 4 +Return for a new token: +Reading a token +Next token is token number (1.33: 1) +Shifting token number (1.33: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Return for a new token: +Reading a token +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 22 +Stack now 0 8 21 4 12 22 +Return for a new token: +Reading a token +Next token is token number (1.37: 2) +Shifting token number (1.37: 2) +Entering state 1 +Stack now 0 8 21 4 12 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 31 +Stack now 0 8 21 4 12 22 31 +Return for a new token: +Reading a token +Next token is token '*' (1.39: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 22 +Stack now 0 8 21 4 12 22 +Return for a new token: +Reading a token +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.33-37: 2) +Stack now 0 8 21 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) +Error: popping token error (1.33-41: ) +Stack now 0 8 21 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 21 4 11 +Return for a new token: +Reading a token +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) +Entering state 30 +Stack now 0 8 21 30 +Return for a new token: +Reading a token +Next token is token '=' (1.44: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) +Entering state 19 +Stack now 0 8 19 +Return for a new token: +Reading a token +Next token is token number (1.46: 1) +Shifting token number (1.46: 1) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.46: 1) +-> $$ = nterm exp (1.46: 1) +Entering state 28 +Stack now 0 8 19 28 +Return for a new token: +Reading a token +Next token is token '\n' (1.47-2.0: Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 96): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Stack now 0 +Cleanup: discarding lookahead token '+' (2.1: ) +Stack now 0 +) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Return for a new token: +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +input: +stderr: +./calc.at:1354: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +1.6: syntax error: invalid character: '#' +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-8: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token number (1.10: 1) +Error: discarding token number (1.10: 1) +Error: popping token error (1.2-8: ) +Stack now 0 4 +Shifting token error (1.2-10: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.15-18: 1111) +Shifting token number (1.15-18: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.19-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (# + 1) = 1111 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack by rule 9 (line 101): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '=' (1.11: ) +Reducing stack by rule 7 (line 99): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token "number" (1.13: 7) +Shifting token "number" (1.13: 7) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.13: 7) +-> $$ = nterm exp (1.13: 7) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.14-2.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (1.1-9: 7) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13: 7) +-> $$ = nterm exp (1.1-13: 7) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.14-2.0: ) +Shifting token '\n' (1.14-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (1.1-13: 7) + $2 = token '\n' (1.14-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token "number" (2.1: 1) +Shifting token "number" (2.1: 1) +Entering state 1 +Stack now 0 6 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (2.1: 1) +-> $$ = nterm exp (2.1: 1) +Entering state 8 +Stack now 0 6 8 +Reading a token +Next token is token '+' (2.3: ) +Shifting token '+' (2.3: ) +Entering state 21 +Stack now 0 6 8 21 +Reading a token +Next token is token "number" (2.5: 2) +Shifting token "number" (2.5: 2) +Entering state 1 +Stack now 0 6 8 21 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (2.5: 2) +-> $$ = nterm exp (2.5: 2) +Entering state 30 +Stack now 0 6 8 21 30 +Reading a token +Next token is token '*' (2.7: ) +Shifting token '*' (2.7: ) +Entering state 22 +Stack now 0 6 8 21 30 22 +Reading a token +Next token is token '-' (2.9: ) +Shifting token '-' (2.9: ) +Entering state 2 +Stack now 0 6 8 21 30 22 2 +Reading a token +Next token is token "number" (2.10: 3) +Shifting token "number" (2.10: 3) +Entering state 1 +Stack now 0 6 8 21 30 22 2 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (2.10: 3) +-> $$ = nterm exp (2.10: 3) +Entering state 10 +Stack now 0 6 8 21 30 22 2 10 +Reading a token +Next token is token '=' (2.12: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (2.9: ) + $2 = nterm exp (2.10: 3) +-> $$ = nterm exp (2.9-10: -3) +Entering state 31 +Stack now 0 6 8 21 30 22 31 +Next token is token '=' (2.12: ) +Reducing stack by rule 9 (line 101): + $1 = nterm exp (2.5: 2) + $2 = token '*' (2.7: ) + $3 = nterm exp (2.9-10: -3) +-> $$ = nterm exp (2.5-10: -6) +Entering state 30 +Stack now 0 6 8 21 30 +Next token is token '=' (2.12: ) +Reducing stack by rule 7 (line 99): + $1 = nterm exp (2.1: 1) + $2 = token '+' (2.3: ) + $3 = nterm exp (2.5-10: -6) +-> $$ = nterm exp (2.1-10: -5) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (2.12: ) +Shifting token '=' (2.12: ) +Entering state 19 +Stack now 0 6 8 19 +Reading a token +Next token is token '-' (2.14: ) +Shifting token '-' (2.14: ) +Entering state 2 +Stack now 0 6 8 19 2 +Reading a token +Next token is token "number" (2.15: 5) +Shifting token "number" (2.15: 5) +Entering state 1 +Stack now 0 6 8 19 2 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (2.15: 5) +-> $$ = nterm exp (2.15: 5) +Entering state 10 +Stack now 0 6 8 19 2 10 +Reading a token +Next token is token '\n' (2.16-3.0: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (2.14: ) + $2 = nterm exp (2.15: 5) +-> $$ = nterm exp (2.14-15: -5) +Entering state 28 +Stack now 0 6 8 19 28 +Next token is token '\n' (2.16-3.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (2.1-10: -5) + $2 = token '=' (2.12: ) + $3 = nterm exp (2.14-15: -5) +-> $$ = nterm exp (2.1-15: -5) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (2.16-3.0: ) +Shifting token '\n' (2.16-3.0: ) +Entering state 25 +Stack now 0 6 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (2.1-15: -5) + $2 = token '\n' (2.16-3.0: ) +-> $$ = nterm line (2.1-3.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-2.0: ) + $2 = nterm line (2.1-3.0: ) +-> $$ = nterm input (1.1-3.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '\n' (3.1-4.0: ) +Shifting token '\n' (3.1-4.0: ) +Entering state 3 +Stack now 0 6 3 +Reducing stack by rule 3 (line 83): + $1 = token '\n' (3.1-4.0: ) +-> $$ = nterm line (3.1-4.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-3.0: ) + $2 = nterm line (3.1-4.0: ) +-> $$ = nterm input (1.1-4.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '-' (4.1: ) +Shifting token '-' (4.1: ) +Entering state 2 +Stack now 0 6 2 +Reading a token +Next token is token "number" (4.2: 1) +Shifting token "number" (4.2: 1) +Entering state 1 +Stack now 0 6 2 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (4.2: 1) +-> $$ = nterm exp (4.2: 1) +Entering state 10 +Stack now 0 6 2 10 +Reading a token +Next token is token '^' (4.3: ) +Shifting token '^' (4.3: ) +Entering state 24 +Stack now 0 6 2 10 24 +Reading a token +Next token is token "number" (4.4: 2) +Shifting token "number" (4.4: 2) +Entering state 1 +Stack now 0 6 2 10 24 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (4.4: 2) +-> $$ = nterm exp (4.4: 2) +Entering state 33 +Stack now 0 6 2 10 24 33 +Reading a token +Next token is token '=' (4.6: ) +Reducing stack by rule 12 (line 112): + $1 = nterm exp (4.2: 1) + $2 = token '^' (4.3: ) + $3 = nterm exp (4.4: 2) +-> $$ = nterm exp (4.2-4: 1) +Entering state 10 +Stack now 0 6 2 10 +Next token is token '=' (4.6: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (4.1: ) + $2 = nterm exp (4.2-4: 1) +-> $$ = nterm exp (4.1-4: -1) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (4.6: ) +Shifting token '=' (4.6: ) +Entering state 19 +Stack now 0 6 8 19 +Reading a token +Next token is token '-' (4.8: ) +Shifting token '-' (4.8: ) +Entering state 2 +Stack now 0 6 8 19 2 +Reading a token +Next token is token "number" (4.9: 1) +Shifting token "number" (4.9: 1) +Entering state 1 +Stack now 0 6 8 19 2 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (4.9: 1) +-> $$ = nterm exp (4.9: 1) +Entering state 10 +Stack now 0 6 8 19 2 10 +Reading a token +Next token is token '\n' (4.10-5.0: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (4.8: ) + $2 = nterm exp (4.9: 1) +-> $$ = nterm exp (4.8-9: -1) +Entering state 28 +Stack now 0 6 8 19 28 +Next token is token '\n' (4.10-5.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (4.1-4: -1) + $2 = token '=' (4.6: ) + $3 = nterm exp (4.8-9: -1) -> $$ = nterm exp (4.1-9: -1) Entering state 8 Stack now 0 6 8 Next token is token '\n' (4.10-5.0: ) Shifting token '\n' (4.10-5.0: ) -Entering state 25 +Enter./calc.at:1355: $PREPARSER ./calc input +ing state 25 Stack now 0 6 8 25 Reducing stack by rule 4 (line 84): $1 = nterm exp (4.1-9: -1) @@ -60724,18 +63068,10 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1358: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 input: -./calc.at:1360: "$PERL" -pi -e 'use strict; +./calc.at:1354: cat stderr +./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -60746,7 +63082,12 @@ }eg ' expout || exit 77 stderr: -./calc.at:1354: "$PERL" -pi -e 'use strict; + | + | +1 +stderr: +./calc.at:1362: $PREPARSER ./calc input +stdout: +./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -60756,10 +63097,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1//2 -./calc.at:1363: $PREPARSER ./calc input -stderr: -./calc.at:1358: cat stderr Starting parse Entering state 0 Stack now 0 @@ -60769,132 +63106,76 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) -Error: popping token error (1.10: ) -Stack now 0 8 21 4 -Shifting token error (1.10: ) +Next token is token number (1.6: 1) +Error: discarding token number (1.6: 1) +Error: popping token error (1.2-4: ) +Stack now 0 4 +Shifting token error (1.2-6: ) Entering state 11 -Stack now 0 8 21 4 11 +Stack now 0 4 11 Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 26 -Stack now 0 8 21 4 11 26 +Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 -Stack now 0 8 21 4 Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) -Error: popping token error (1.16: ) -Stack now 0 8 21 4 -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 21 4 11 +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 30 -Stack now 0 8 21 30 +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -60911,86 +63192,126 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +stderr: +./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1363: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +stderr: +stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 -Stack now 0 1 +Stack now 0 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token number (1.3: 2) -Stack now 0 -./calc.at:1357: cat stderr -./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1360: cat stderr -./calc.at:1354: cat stderr - -stderr: -syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) -input: - | error -./calc.at:1358: $PREPARSER ./calc input -./calc.at:1355: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -Starting parse -Entering state 0 -Stack now 0 +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -Stack now 0 -./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1355: cat stderr -Starting parse -Entering state 0 -Stack now 0 +1.6: syntax error: invalid character: '#' +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-8: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token number (1.10: 1) +Error: discarding token number (1.10: 1) +Error: popping token error (1.2-8: ) +Stack now 0 4 +Shifting token error (1.2-10: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Stack now 0 8 23 +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) +Next token is token number (1.15-18: 1111) +Shifting token number (1.15-18: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.19-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) +Entering state 8 Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) -Stack now 0 -stderr: +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1358: cat stderr Starting parse Entering state 0 Stack now 0 @@ -62008,138 +64329,41 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: ./calc.at:1364: $EGREP -c -v 'Return for a new token:|LAC:' stderr -stderr: +./calc.at:1360: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Stack now 0 8 23 +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 96): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) +Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 - | 1 + 2 * 3 + !+ ++ -./calc.at:1355: $PREPARSER ./calc input -./calc.at:1367: cat stderr +494. calc.at:1368: testing Calculator parse.error=custom %locations api.prefix={calc} ... input: - | (!!) + (1 2) = 1 -stderr: -./calc.at:1357: $PREPARSER ./calc input -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 120): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Stack now 0 8 21 5 14 -Reducing stack by rule 17 (line 142): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +./calc.at:1368: mv calc.y.tmp calc.y + stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -Stack now 0 -input: -input: -485. calc.at:1354: ok + | (1 + 1) / (1 - 1) +./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1354: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -62149,121 +64373,76 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Stack now 0 4 5 +1.2: syntax error: invalid character: '#' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 16 -Stack now 0 4 5 16 -Reducing stack by rule 16 (line 129): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Error: popping token error (1.2: ) Stack now 0 4 -Shifting token error (1.2-3: ) +Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) +Next token is token number (1.6: 1) +Error: discarding token number (1.6: 1) +Error: popping token error (1.2-4: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 139): $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token number (1.9: 1) -Shifting token number (1.9: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 1) --> $$ = nterm exp (1.9: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token number (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Stack now 0 8 21 4 -Shifting token error (1.9-11: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token number (1.11: 2) -Error: discarding token number (1.11: 2) -Error: popping token error (1.9-11: ) -Stack now 0 8 21 4 -Shifting token error (1.9-11: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.14: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.17-2.0: ) +Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -62280,12 +64459,7 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | - | +1 -./calc.at:1367: $PREPARSER ./calc input - | error -./calc.at:1363: "$PERL" -pi -e 'use strict; +./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -62295,96 +64469,232 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1363: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c calc.h + +./calc.at:1360: $PREPARSER ./calc /dev/null +./calc.at:1368: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: -494. calc.at:1368: testing Calculator parse.error=custom %locations api.prefix={calc} ... +input: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 -Stack now 0 1 +Stack now 0 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) Entering state 21 -Stack now 0 8 21 +Stack now 0 4 12 21 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token number (1.6: 1) +Shifting token number (1.6: 1) Entering state 1 -Stack now 0 8 21 1 +Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) + $1 = token number (1.6: 1) +-> $$ = nterm exp (1.6: 1) Entering state 30 -Stack now 0 8 21 30 +Stack now 0 4 12 21 30 Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 +Next token is token ')' (1.7: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Stack now 0 4 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 27 +Stack now 0 4 12 27 +Reducing stack by rule 13 (line 138): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) +Entering state 8 +Stack now 0 8 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 23 +Stack now 0 8 23 +Reading a token +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Stack now 0 8 23 4 +Reading a token +Next token is token number (1.12: 1) +Shifting token number (1.12: 1) Entering state 1 -Stack now 0 8 21 30 22 1 +Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 + $1 = token number (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Stack now 0 8 23 4 12 Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 120): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 20 +Stack now 0 8 23 4 12 20 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Stack now 0 8 23 4 12 20 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 29 +Stack now 0 8 23 4 12 20 29 +Reading a token +Next token is token ')' (1.17: ) +Reducing stack by rule 8 (line 119): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Stack now 0 8 23 4 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 27 +Stack now 0 8 23 4 12 27 +Reducing stack by rule 13 (line 138): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 32 +Stack now 0 8 23 32 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 10 (line 121): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Stack now 0 8 21 5 14 -Reducing stack by rule 17 (line 142): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) stderr: +./calc.at:1354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -./calc.at:1355: $EGREP -c -v 'Return for a new token:|LAC:' stderr -syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1368: mv calc.y.tmp calc.y - -./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./calc.at:1357: cat stderr + | (!!) + (1 2) = 1 +./calc.at:1358: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Now at end of input. +1.1: syntax error, unexpected end of file +Cleanup: discarding lookahead token end of file (1.1: ) +Stack now 0 +./calc.at:1355: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 96): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Stack now 0 +Cleanup: discarding lookahead token '+' (2.1: ) +Stack now 0 + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1363: $PREPARSER ./calc input +stderr: +./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1355: cat stderr + | 1 2 Starting parse Entering state 0 Stack now 0 @@ -62393,11 +64703,13 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 +Return for a new token: Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 +Return for a new token: Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) @@ -62410,6 +64722,7 @@ Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 +Return for a new token: Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) @@ -62422,16 +64735,19 @@ -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 +Return for a new token: Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 +Return for a new token: Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 +Return for a new token: Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) @@ -62442,6 +64758,7 @@ -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 +Return for a new token: Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number @@ -62457,6 +64774,7 @@ Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 +Return for a new token: Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) @@ -62469,6 +64787,7 @@ -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 +Return for a new token: Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): @@ -62482,6 +64801,7 @@ Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 +Return for a new token: Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) @@ -62492,6 +64812,7 @@ -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 +Return for a new token: Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): @@ -62517,6 +64838,7 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -62525,197 +64847,152 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1360: $PREPARSER ./calc input - | 1 2 +input: +./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: $PREPARSER ./calc input -./calc.at:1363: cat stderr -./calc.at:1362: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1368: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -stderr: stderr: -./calc.at:1358: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -Stack now 0 -input: -./calc.at:1362: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token "number" (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token "number" (1.3: 2) -Stack now 0 - | 1 + 2 * 3 + !- ++ -./calc.at:1355: $PREPARSER ./calc input -input: - | error -./calc.at:1363: $PREPARSER ./calc input -./calc.at:1358: cat stderr -stderr: -./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 -Stack now 0 1 +Stack now 0 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) Entering state 21 -Stack now 0 8 21 +Stack now 0 4 12 21 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token number (1.6: 1) +Shifting token number (1.6: 1) Entering state 1 -Stack now 0 8 21 1 +Stack now 0 4 12 21 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) + $1 = token number (1.6: 1) +-> $$ = nterm exp (1.6: 1) Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 +Stack now 0 4 12 21 30 Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 120): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) +Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Stack now 0 4 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 27 +Stack now 0 4 12 27 +Reducing stack by rule 13 (line 138): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 23 +Stack now 0 8 23 +Reading a token +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Stack now 0 8 23 4 +Reading a token +Next token is token number (1.12: 1) +Shifting token number (1.12: 1) +Entering state 1 +Stack now 0 8 23 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Stack now 0 8 23 4 12 Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) -Entering state 13 -Stack now 0 8 21 5 13 -Reducing stack by rule 18 (line 143): - $1 = token '!' (1.13: ) +Entering state 20 +Stack now 0 8 23 4 12 20 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Stack now 0 8 23 4 12 20 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 29 +Stack now 0 8 23 4 12 20 29 +Reading a token +Next token is token ')' (1.17: ) +Reducing stack by rule 8 (line 119): + $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1357: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - -input: - | 1//2 -./calc.at:1362: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 -Stack now 0 + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Stack now 0 8 23 4 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 27 +Stack now 0 8 23 4 12 27 +Reducing stack by rule 13 (line 138): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 32 +Stack now 0 8 23 32 Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" (1.1: ) -Stack now 0 -stderr: -stderr: -./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1367: cat stderr -Starting parse -Entering state 0 -Stack now 0 +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 10 (line 121): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -Stack now 0 -stderr: - | 1 = 2 = 3 -./calc.at:1357: cat stderr +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) stderr: -./calc.at:1358: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -62730,38 +65007,17 @@ Entering state 8 Stack now 0 8 Reading a token -Next token is token "number" (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token "number" (1.3: 2) -Stack now 0 -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 @@ -62771,501 +65027,1035 @@ Entering state 22 Stack now 0 8 21 30 22 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 120): +Next token is token '=' (1.11: ) +Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 118): +Next token is token '=' (1.11: ) +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Stack now 0 8 21 5 13 -Reducing stack by rule 18 (line 143): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Return for a new token: -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 -Return for a new token: Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token "number" (1.13: 7) +Shifting token "number" (1.13: 7) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.13: 7) +-> $$ = nterm exp (1.13: 7) Entering state 28 Stack now 0 8 19 28 -Return for a new token: Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 19 -Error: popping token '=' (1.3: ) +Next token is token '\n' (1.14-2.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (1.1-9: 7) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13: 7) +-> $$ = nterm exp (1.1-13: 7) +Entering state 8 Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) -Stack now 0 -stdout: -./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Stack now 0 +Next token is token '\n' (1.14-2.0: ) +Shifting token '\n' (1.14-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (1.1-13: 7) + $2 = token '\n' (1.14-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token "number" (2.1: 1) +Shifting token "number" (2.1: 1) Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) +Stack now 0 6 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (2.1: 1) +-> $$ = nterm exp (2.1: 1) Entering state 8 -Stack now 0 8 +Stack now 0 6 8 Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Stack now 0 8 23 +Next token is token '+' (2.3: ) +Shifting token '+' (2.3: ) +Entering state 21 +Stack now 0 6 8 21 Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) -Stack now 0 -./calc.at:1360: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./types.at:139: ./check -./calc.at:1367: $PREPARSER ./calc /dev/null -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -./calc.at:1360: cat stderr -stderr: -stderr: -Starting parse -Entering state 0 -Stack now 0 +Next token is token "number" (2.5: 2) +Shifting token "number" (2.5: 2) +Entering state 1 +Stack now 0 6 8 21 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (2.5: 2) +-> $$ = nterm exp (2.5: 2) +Entering state 30 +Stack now 0 6 8 21 30 Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" (1.1: ) -Stack now 0 -./calc.at:1355: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1364: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | (- *) + (1 2) = 1 -./calc.at:1357: $PREPARSER ./calc input -stderr: -input: -stderr: - | 1 = 2 = 3 -./calc.at:1364: cat stderr -495. calc.at:1369: testing Calculator parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} ... -./calc.at:1369: mv calc.y.tmp calc.y - -./calc.at:1360: $PREPARSER ./calc input -Starting parse -Entering state 0 -Stack now 0 +Next token is token '*' (2.7: ) +Shifting token '*' (2.7: ) +Entering state 22 +Stack now 0 6 8 21 30 22 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token '-' (2.9: ) +Shifting token '-' (2.9: ) +Entering state 2 +Stack now 0 6 8 21 30 22 2 +Reading a token +Next token is token "number" (2.10: 3) +Shifting token "number" (2.10: 3) Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 +Stack now 0 6 8 21 30 22 2 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (2.10: 3) +-> $$ = nterm exp (2.10: 3) +Entering state 10 +Stack now 0 6 8 21 30 22 2 10 Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Stack now 0 8 23 +Next token is token '=' (2.12: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (2.9: ) + $2 = nterm exp (2.10: 3) +-> $$ = nterm exp (2.9-10: -3) +Entering state 31 +Stack now 0 6 8 21 30 22 31 +Next token is token '=' (2.12: ) +Reducing stack by rule 9 (line 101): + $1 = nterm exp (2.5: 2) + $2 = token '*' (2.7: ) + $3 = nterm exp (2.9-10: -3) +-> $$ = nterm exp (2.5-10: -6) +Entering state 30 +Stack now 0 6 8 21 30 +Next token is token '=' (2.12: ) +Reducing stack by rule 7 (line 99): + $1 = nterm exp (2.1: 1) + $2 = token '+' (2.3: ) + $3 = nterm exp (2.5-10: -6) +-> $$ = nterm exp (2.1-10: -5) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (2.12: ) +Shifting token '=' (2.12: ) +Entering state 19 +Stack now 0 6 8 19 Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) -Stack now 0 -syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) -stderr: -Starting parse -Entering state 0 -Stack now 0 +Next token is token '-' (2.14: ) +Shifting token '-' (2.14: ) +Entering state 2 +Stack now 0 6 8 19 2 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token "number" (2.15: 5) +Shifting token "number" (2.15: 5) Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) +Stack now 0 6 8 19 2 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (2.15: 5) +-> $$ = nterm exp (2.15: 5) +Entering state 10 +Stack now 0 6 8 19 2 10 +Reading a token +Next token is token '\n' (2.16-3.0: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (2.14: ) + $2 = nterm exp (2.15: 5) +-> $$ = nterm exp (2.14-15: -5) +Entering state 28 +Stack now 0 6 8 19 28 +Next token is token '\n' (2.16-3.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (2.1-10: -5) + $2 = token '=' (2.12: ) + $3 = nterm exp (2.14-15: -5) +-> $$ = nterm exp (2.1-15: -5) Entering state 8 -Stack now 0 8 +Stack now 0 6 8 +Next token is token '\n' (2.16-3.0: ) +Shifting token '\n' (2.16-3.0: ) +Entering state 25 +Stack now 0 6 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (2.1-15: -5) + $2 = token '\n' (2.16-3.0: ) +-> $$ = nterm line (2.1-3.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-2.0: ) + $2 = nterm line (2.1-3.0: ) +-> $$ = nterm input (1.1-3.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 19 -Stack now 0 8 19 +Next token is token '\n' (3.1-4.0: ) +Shifting token '\n' (3.1-4.0: ) +Entering state 3 +Stack now 0 6 3 +Reducing stack by rule 3 (line 83): + $1 = token '\n' (3.1-4.0: ) +-> $$ = nterm line (3.1-4.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-3.0: ) + $2 = nterm line (3.1-4.0: ) +-> $$ = nterm input (1.1-4.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token '-' (4.1: ) +Shifting token '-' (4.1: ) +Entering state 2 +Stack now 0 6 2 +Reading a token +Next token is token "number" (4.2: 1) +Shifting token "number" (4.2: 1) Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 28 -Stack now 0 8 19 28 +Stack now 0 6 2 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (4.2: 1) +-> $$ = nterm exp (4.2: 1) +Entering state 10 +Stack now 0 6 2 10 Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 19 -Error: popping token '=' (1.3: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) -Stack now 0 -./calc.at:1363: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1355: cat stderr -./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1368: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS -input: -./calc.at:1369: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -stderr: -stderr: -Starting parse -Entering state 0 -Stack now 0 +Next token is token '^' (4.3: ) +Shifting token '^' (4.3: ) +Entering state 24 +Stack now 0 6 2 10 24 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token "number" (4.4: 2) +Shifting token "number" (4.4: 2) Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Return for a new token: +Stack now 0 6 2 10 24 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (4.4: 2) +-> $$ = nterm exp (4.4: 2) +Entering state 33 +Stack now 0 6 2 10 24 33 Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) +Next token is token '=' (4.6: ) +Reducing stack by rule 12 (line 112): + $1 = nterm exp (4.2: 1) + $2 = token '^' (4.3: ) + $3 = nterm exp (4.4: 2) +-> $$ = nterm exp (4.2-4: 1) +Entering state 10 +Stack now 0 6 2 10 +Next token is token '=' (4.6: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (4.1: ) + $2 = nterm exp (4.2-4: 1) +-> $$ = nterm exp (4.1-4: -1) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (4.6: ) +Shifting token '=' (4.6: ) Entering state 19 -Stack now 0 8 19 -Return for a new token: +Stack now 0 6 8 19 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token '-' (4.8: ) +Shifting token '-' (4.8: ) +Entering state 2 +Stack now 0 6 8 19 2 +Reading a token +Next token is token "number" (4.9: 1) +Shifting token "number" (4.9: 1) Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 28 -Stack now 0 8 19 28 -Return for a new token: +Stack now 0 6 8 19 2 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (4.9: 1) +-> $$ = nterm exp (4.9: 1) +Entering state 10 +Stack now 0 6 8 19 2 10 Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 19 -Error: popping token '=' (1.3: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) -Stack now 0 -input: -Starting parse -Entering state 0 -Stack now 0 +Next token is token '\n' (4.10-5.0: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (4.8: ) + $2 = nterm exp (4.9: 1) +-> $$ = nterm exp (4.8-9: -1) +Entering state 28 +Stack now 0 6 8 19 28 +Next token is token '\n' (4.10-5.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (4.1-4: -1) + $2 = token '=' (4.6: ) + $3 = nterm exp (4.8-9: -1) +-> $$ = nterm exp (4.1-9: -1) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (4.10-5.0: ) +Shifting token '\n' (4.10-5.0: ) +Enter | (1 + 1) / (1 - 1) +./calc.at:1357: $PREPARSER ./calc input +ing state 25 +Stack now 0 6 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (4.1-9: -1) + $2 = token '\n' (4.10-5.0: ) +-> $$ = nterm line (4.1-5.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-4.0: ) + $2 = nterm line (4.1-5.0: ) +-> $$ = nterm input (1.1-5.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) +Next token is token '(' (5.1: ) +Shifting token '(' (5.1: ) Entering state 4 -Stack now 0 4 +Stack now 0 6 4 Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) +Next token is token '-' (5.2: ) +Shifting token '-' (5.2: ) Entering state 2 -Stack now 0 4 2 +Stack now 0 6 4 2 Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 128): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2-4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 +Next token is token "number" (5.3: 1) +Shifting token "number" (5.3: 1) +Entering state 1 +Stack now 0 6 4 2 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (5.3: 1) +-> $$ = nterm exp (5.3: 1) +Entering state 10 +Stack now 0 6 4 2 10 Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) +Next token is token ')' (5.4: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (5.2: ) + $2 = nterm exp (5.3: 1) +-> $$ = nterm exp (5.2-3: -1) +Entering state 12 +Stack now 0 6 4 12 +Next token is token ')' (5.4: ) +Shifting token ')' (5.4: ) +Entering state 27 +Stack now 0 6 4 12 27 +Reducing stack by rule 13 (line 113): + $1 = token '(' (5.1: ) + $2 = nterm exp (5.2-3: -1) + $3 = token ')' (5.4: ) +-> $$ = nterm exp (5.1-4: -1) Entering state 8 -Stack now 0 8 +Stack now 0 6 8 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 21 -Stack now 0 8 21 +Next token is token '^' (5.5: ) +Shifting token '^' (5.5: ) +Entering state 24 +Stack now 0 6 8 24 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) +Next token is token "number" (5.6: 2) +Shifting token "number" (5.6: 2) +Entering state 1 +Stack now 0 6 8 24 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (5.6: 2) +-> $$ = nterm exp (5.6: 2) +Entering state 33 +Stack now 0 6 8 24 33 +Reading a token +Next token is token '=' (5.8: ) +Reducing stack by rule 12 (line 112): + $1 = nterm exp (5.1-4: -1) + $2 = token '^' (5.5: ) + $3 = nterm exp (5.6: 2) +-> $$ = nterm exp (5.1-6: 1) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (5.8: ) +Shifting token '=' (5.8: ) +Entering state 19 +Stack now 0 6 8 19 +Reading a token +Next token is token "number" (5.10: 1) +Shifting token "number" (5.10: 1) +Entering state 1 +Stack now 0 6 8 19 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (5.10: 1) +-> $$ = nterm exp (5.10: 1) +Entering state 28 +Stack now 0 6 8 19 28 +Reading a token +Next token is token '\n' (5.11-6.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (5.1-6: 1) + $2 = token '=' (5.8: ) + $3 = nterm exp (5.10: 1) +-> $$ = nterm exp (5.1-10: 1) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (5.11-6.0: ) +Shifting token '\n' (5.11-6.0: ) +Entering state 25 +Stack now 0 6 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (5.1-10: 1) + $2 = token '\n' (5.11-6.0: ) +-> $$ = nterm line (5.1-6.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-5.0: ) + $2 = nterm line (5.1-6.0: ) +-> $$ = nterm input (1.1-6.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '\n' (6.1-7.0: ) +Shifting token '\n' (6.1-7.0: ) +Entering state 3 +Stack now 0 6 3 +Reducing stack by rule 3 (line 83): + $1 = token '\n' (6.1-7.0: ) +-> $$ = nterm line (6.1-7.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-6.0: ) + $2 = nterm line (6.1-7.0: ) +-> $$ = nterm input (1.1-7.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '-' (7.1: ) +Shifting token '-' (7.1: ) +Entering state 2 +Stack now 0 6 2 +Reading a token +Next token is token '-' (7.2: ) +Shifting token '-' (7.2: ) +Entering state 2 +Stack now 0 6 2 2 +Reading a token +Next token is token '-' (7.3: ) +Shifting token '-' (7.3: ) +Entering state 2 +Stack now 0 6 2 2 2 +Reading a token +Next token is token "number" (7.4: 1) +Shifting token "number" (7.4: 1) +Entering state 1 +Stack now 0 6 2 2 2 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (7.4: 1) +-> $$ = nterm exp (7.4: 1) +Entering state 10 +Stack now 0 6 2 2 2 10 +Reading a token +Next token is token '=' (7.6: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (7.3: ) + $2 = nterm exp (7.4: 1) +-> $$ = nterm exp (7.3-4: -1) +Entering state 10 +Stack now 0 6 2 2 10 +Next token is token '=' (7.6: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (7.2: ) + $2 = nterm exp (7.3-4: -1) +-> $$ = nterm exp (7.2-4: 1) +Entering state 10 +Stack now 0 6 2 10 +Next token is token '=' (7.6: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (7.1: ) + $2 = nterm exp (7.2-4: 1) +-> $$ = nterm exp (7.1-4: -1) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (7.6: ) +Shifting token '=' (7.6: ) +Entering state 19 +Stack now 0 6 8 19 +Reading a token +Next token is token '-' (7.8: ) +Shifting token '-' (7.8: ) +Entering state 2 +Stack now 0 6 8 19 2 +Reading a token +Next token is token "number" (7.9: 1) +Shifting token "number" (7.9: 1) +Entering state 1 +Stack now 0 6 8 19 2 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (7.9: 1) +-> $$ = nterm exp (7.9: 1) +Entering state 10 +Stack now 0 6 8 19 2 10 +Reading a token +Next token is token '\n' (7.10-8.0: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (7.8: ) + $2 = nterm exp (7.9: 1) +-> $$ = nterm exp (7.8-9: -1) +Entering state 28 +Stack now 0 6 8 19 28 +Next token is token '\n' (7.10-8.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (7.1-4: -1) + $2 = token '=' (7.6: ) + $3 = nterm exp (7.8-9: -1) +-> $$ = nterm exp (7.1-9: -1) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (7.10-8.0: ) +Shifting token '\n' (7.10-8.0: ) +Entering state 25 +Stack now 0 6 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (7.1-9: -1) + $2 = token '\n' (7.10-8.0: ) +-> $$ = nterm line (7.1-8.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-7.0: ) + $2 = nterm line (7.1-8.0: ) +-> $$ = nterm input (1.1-8.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '\n' (8.1-9.0: ) +Shifting token '\n' (8.1-9.0: ) +Entering state 3 +Stack now 0 6 3 +Reducing stack by rule 3 (line 83): + $1 = token '\n' (8.1-9.0: ) +-> $$ = nterm line (8.1-9.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-8.0: ) + $2 = nterm line (8.1-9.0: ) +-> $$ = nterm input (1.1-9.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token "number" (9.1: 1) +Shifting token "number" (9.1: 1) +Entering state 1 +Stack now 0 6 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (9.1: 1) +-> $$ = nterm exp (9.1: 1) +Entering state 8 +Stack now 0 6 8 +Reading a token +Next token is token '-' (9.3: ) +Shifting token '-' (9.3: ) +Entering state 20 +Stack now 0 6 8 20 +Reading a token +Next token is token "number" (9.5: 2) +Shifting token "number" (9.5: 2) +Entering state 1 +Stack now 0 6 8 20 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (9.5: 2) +-> $$ = nterm exp (9.5: 2) +Entering state 29 +Stack now 0 6 8 20 29 +Reading a token +Next token is token '-' (9.7: ) +Reducing stack by rule 8 (line 100): + $1 = nterm exp (9.1: 1) + $2 = token '-' (9.3: ) + $3 = nterm exp (9.5: 2) +-> $$ = nterm exp (9.1-5: -1) +Entering state 8 +Stack now 0 6 8 +Next token is token '-' (9.7: ) +Shifting token '-' (9.7: ) +Entering state 20 +Stack now 0 6 8 20 +Reading a token +Next token is token "number" (9.9: 3) +Shifting token "number" (9.9: 3) +Entering state 1 +Stack now 0 6 8 20 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (9.9: 3) +-> $$ = nterm exp (9.9: 3) +Entering state 29 +Stack now 0 6 8 20 29 +Reading a token +Next token is token '=' (9.11: ) +Reducing stack by rule 8 (line 100): + $1 = nterm exp (9.1-5: -1) + $2 = token '-' (9.7: ) + $3 = nterm exp (9.9: 3) +-> $$ = nterm exp (9.1-9: -4) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (9.11: ) +Shifting token '=' (9.11: ) +Entering state 19 +Stack now 0 6 8 19 +Reading a token +Next token is token '-' (9.13: ) +Shifting token '-' (9.13: ) +Entering state 2 +Stack now 0 6 8 19 2 +Reading a token +Next token is token "number" (9.14: 4) +Shifting token "number" (9.14: 4) +Entering state 1 +Stack now 0 6 8 19 2 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (9.14: 4) +-> $$ = nterm exp (9.14: 4) +Entering state 10 +Stack now 0 6 8 19 2 10 +Reading a token +Next token is token '\n' (9.15-10.0: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (9.13: ) + $2 = nterm exp (9.14: 4) +-> $$ = nterm exp (9.13-14: -4) +Entering state 28 +Stack now 0 6 8 19 28 +Next token is token '\n' (9.15-10.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (9.1-9: -4) + $2 = token '=' (9.11: ) + $3 = nterm exp (9.13-14: -4) +-> $$ = nterm exp (9.1-14: -4) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (9.15-10.0: ) +Shifting token '\n' (9.15-10.0: ) +Entering state 25 +Stack now 0 6 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (9.1-14: -4) + $2 = token '\n' (9.15-10.0: ) +-> $$ = nterm line (9.1-10.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-9.0: ) + $2 = nterm line (9.1-10.0: ) +-> $$ = nterm input (1.1-10.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token "number" (10.1: 1) +Shifting token "number" (10.1: 1) +Entering state 1 +Stack now 0 6 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (10.1: 1) +-> $$ = nterm exp (10.1: 1) +Entering state 8 +Stack now 0 6 8 +Reading a token +Next token is token '-' (10.3: ) +Shifting token '-' (10.3: ) +Entering state 20 +Stack now 0 6 8 20 +Reading a token +Next token is token '(' (10.5: ) +Shifting token '(' (10.5: ) Entering state 4 -Stack now 0 8 21 4 +Stack now 0 6 8 20 4 Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) +Next token is token "number" (10.6: 2) +Shifting token "number" (10.6: 2) Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.10: 1) --> $$ = nterm exp (1.10: 1) +Stack now 0 6 8 20 4 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (10.6: 2) +-> $$ = nterm exp (10.6: 2) Entering state 12 -Stack now 0 8 21 4 12 +Stack now 0 6 8 20 4 12 Reading a token -Next token is token number (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Stack now 0 8 21 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token number (1.12: 2) -Error: discarding token number (1.12: 2) -Error: popping token error (1.10-12: ) -Stack now 0 8 21 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 21 4 11 +Next token is token '-' (10.8: ) +Shifting token '-' (10.8: ) +Entering state 20 +Stack now 0 6 8 20 4 12 20 Reading a token -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) -Entering state 30 -Stack now 0 8 21 30 +Next token is token "number" (10.10: 3) +Shifting token "number" (10.10: 3) +Entering state 1 +Stack now 0 6 8 20 4 12 20 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (10.10: 3) +-> $$ = nterm exp (10.10: 3) +Entering state 29 +Stack now 0 6 8 20 4 12 20 29 Reading a token -Next token is token '=' (1.15: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) +Next token is token ')' (10.11: ) +Reducing stack by rule 8 (line 100): + $1 = nterm exp (10.6: 2) + $2 = token '-' (10.8: ) + $3 = nterm exp (10.10: 3) +-> $$ = nterm exp (10.6-10: -1) +Entering state 12 +Stack now 0 6 8 20 4 12 +Next token is token ')' (10.11: ) +Shifting token ')' (10.11: ) +Entering state 27 +Stack now 0 6 8 20 4 12 27 +Reducing stack by rule 13 (line 113): + $1 = token '(' (10.5: ) + $2 = nterm exp (10.6-10: -1) + $3 = token ')' (10.11: ) +-> $$ = nterm exp (10.5-11: -1) +Entering state 29 +Stack now 0 6 8 20 29 +Reading a token +Next token is token '=' (10.13: ) +Reducing stack by rule 8 (line 100): + $1 = nterm exp (10.1: 1) + $2 = token '-' (10.3: ) + $3 = nterm exp (10.5-11: -1) +-> $$ = nterm exp (10.1-11: 2) Entering state 8 -Stack now 0 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) +Stack now 0 6 8 +Next token is token '=' (10.13: ) +Shifting token '=' (10.13: ) Entering state 19 -Stack now 0 8 19 +Stack now 0 6 8 19 Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) +Next token is token "number" (10.15: 2) +Shifting token "number" (10.15: 2) Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.17: 1) --> $$ = nterm exp (1.17: 1) +Stack now 0 6 8 19 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (10.15: 2) +-> $$ = nterm exp (10.15: 2) Entering state 28 -Stack now 0 8 19 28 +Stack now 0 6 8 19 28 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) +Next token is token '\n' (10.16-11.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (10.1-11: 2) + $2 = token '=' (10.13: ) + $3 = nterm exp (10.15: 2) +-> $$ = nterm exp (10.1-15: 2) Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Stack now 0 6 8 +Next token is token '\n' (10.16-11.0: ) +Shifting token '\n' (10.16-11.0: ) Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) +Stack now 0 6 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (10.1-15: 2) + $2 = token '\n' (10.16-11.0: ) +-> $$ = nterm line (10.1-11.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-10.0: ) + $2 = nterm line (10.1-11.0: ) +-> $$ = nterm input (1.1-11.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '\n' (11.1-12.0: ) +Shifting token '\n' (11.1-12.0: ) +Entering state 3 +Stack now 0 6 3 +Reducing stack by rule 3 (line 83): + $1 = token '\n' (11.1-12.0: ) +-> $$ = nterm line (11.1-12.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-11.0: ) + $2 = nterm line (11.1-12.0: ) +-> $$ = nterm input (1.1-12.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token "number" (12.1: 2) +Shifting token "number" (12.1: 2) +Entering state 1 +Stack now 0 6 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (12.1: 2) +-> $$ = nterm exp (12.1: 2) +Entering state 8 +Stack now 0 6 8 +Reading a token +Next token is token '^' (12.2: ) +Shifting token '^' (12.2: ) +Entering state 24 +Stack now 0 6 8 24 +Reading a token +Next token is token "number" (12.3: 2) +Shifting token "number" (12.3: 2) +Entering state 1 +Stack now 0 6 8 24 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (12.3: 2) +-> $$ = nterm exp (12.3: 2) +Entering state 33 +Stack now 0 6 8 24 33 +Reading a token +Next token is token '^' (12.4: ) +Shifting token '^' (12.4: ) +Entering state 24 +Stack now 0 6 8 24 33 24 +Reading a token +Next token is token "number" (12.5: 3) +Shifting token "number" (12.5: 3) +Entering state 1 +Stack now 0 6 8 24 33 24 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (12.5: 3) +-> $$ = nterm exp (12.5: 3) +Entering state 33 +Stack now 0 6 8 24 33 24 33 +Reading a token +Next token is token '=' (12.7: ) +Reducing stack by rule 12 (line 112): + $1 = nterm exp (12.3: 2) + $2 = token '^' (12.4: ) + $3 = nterm exp (12.5: 3) +-> $$ = nterm exp (12.3-5: 8) +Entering state 33 +Stack now 0 6 8 24 33 +Next token is token '=' (12.7: ) +Reducing stack by rule 12 (line 112): + $1 = nterm exp (12.1: 2) + $2 = token '^' (12.2: ) + $3 = nterm exp (12.3-5: 8) +-> $$ = nterm exp (12.1-5: 256) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (12.7: ) +Shifting token '=' (12.7: ) +Entering state 19 +Stack now 0 6 8 19 +Reading a token +Next token is token "number" (12.9-11: 256) +Shifting token "number" (12.9-11: 256) +Entering state 1 +Stack now 0 6 8 19 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (12.9-11: 256) +-> $$ = nterm exp (12.9-11: 256) +Entering state 28 +Stack now 0 6 8 19 28 +Reading a token +Next token is token '\n' (12.12-13.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (12.1-5: 256) + $2 = token '=' (12.7: ) + $3 = nterm exp (12.9-11: 256) +-> $$ = nterm exp (12.1-11: 256) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (12.12-13.0: ) +Shifting token '\n' (12.12-13.0: ) +Entering state 25 +Stack now 0 6 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (12.1-11: 256) + $2 = token '\n' (12.12-13.0: ) +-> $$ = nterm line (12.1-13.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-12.0: ) + $2 = nterm line (12.1-13.0: ) +-> $$ = nterm input (1.1-13.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '(' (13.1: ) +Shifting token '(' (13.1: ) +Entering state 4 +Stack now 0 6 4 +Reading a token +Next token is token "number" (13.2: 2) +Shifting token "number" (13.2: 2) +Entering state 1 +Stack now 0 6 4 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (13.2: 2) +-> $$ = nterm exp (13.2: 2) +Entering state 12 +Stack now 0 6 4 12 +Reading a token +Next token is token '^' (13.3: ) +Shifting token '^' (13.3: ) +Entering state 24 +Stack now 0 6 4 12 24 +Reading a token +Next token is token "number" (13.4: 2) +Shifting token "number" (13.4: 2) +Entering state 1 +Stack now 0 6 4 12 24 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (13.4: 2) +-> $$ = nterm exp (13.4: 2) +Entering state 33 +Stack now 0 6 4 12 24 33 +Reading a token +Next token is token ')' (13.5: ) +Reducing stack by rule 12 (line 112): + $1 = nterm exp (13.2: 2) + $2 = token '^' (13.3: ) + $3 = nterm exp (13.4: 2) +-> $$ = nterm exp (13.2-4: 4) +Entering state 12 +Stack now 0 6 4 12 +Next token is token ')' (13.5: ) +Shifting token ')' (13.5: ) +Entering state 27 +Stack now 0 6 4 12 27 +Reducing stack by rule 13 (line 113): + $1 = token '(' (13.1: ) + $2 = nterm exp (13.2-4: 4) + $3 = token ')' (13.5: ) +-> $$ = nterm exp (13.1-5: 4) +Entering state 8 +Stack now 0 6 8 +Reading a token +Next token is token '^' (13.6: ) +Shifting token '^' (13.6: ) +Entering state 24 +Stack now 0 6 8 24 +Reading a token +Next token is token "number" (13.7: 3) +Shifting token "number" (13.7: 3) +Entering state 1 +Stack now 0 6 8 24 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (13.7: 3) +-> $$ = nterm exp (13.7: 3) +Entering state 33 +Stack now 0 6 8 24 33 +Reading a token +Next token is token '=' (13.9: ) +Reducing stack by rule 12 (line 112): + $1 = nterm exp (13.1-5: 4) + $2 = token '^' (13.6: ) + $3 = nterm exp (13.7: 3) +-> $$ = nterm exp (13.1-7: 64) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (13.9: ) +Shifting token '=' (13.9: ) +Entering state 19 +Stack now 0 6 8 19 +Reading a token +Next token is token "number" (13.11-12: 64) +Shifting token "number" (13.11-12: 64) +Entering state 1 +Stack now 0 6 8 19 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (13.11-12: 64) +-> $$ = nterm exp (13.11-12: 64) +Entering state 28 +Stack now 0 6 8 19 28 +Reading a token +Next token is token '\n' (13.13-14.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (13.1-7: 64) + $2 = token '=' (13.9: ) + $3 = nterm exp (13.11-12: 64) +-> $$ = nterm exp (13.1-12: 64) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (13.13-14.0: ) +Shifting token '\n' (13.13-14.0: ) +Entering state 25 +Stack now 0 6 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (13.1-12: 64) + $2 = token '\n' (13.13-14.0: ) +-> $$ = nterm line (13.1-14.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-13.0: ) + $2 = nterm line (13.1-14.0: ) +-> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +Cleanup: popping token "end of input" (14.1: ) +Cleanup: popping nterm input (1.1-14.0: ) +./calc.at:1362: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: - | 1 + 2 * 3 + !* ++ Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 19 -Error: popping token '=' (1.3: ) -Stack now 0 8 +Next token is token "number" (1.3: 2) +1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) +Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 -./calc.at:1355: $PREPARSER ./calc input -./calc.at:1362: "$PERL" -pi -e 'use strict; +./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Now at end of input. +1.1: syntax error, unexpected end of file +Cleanup: discarding lookahead token end of file (1.1: ) +Stack now 0 +stderr: +stderr: +./calc.at:1362: cat stderr +./calc.at:1354: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -63275,42 +66065,149 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -./calc.at:1363: cat stderr -./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1362: cat stderr - | 1//2 -./calc.at:1364: $PREPARSER ./calc input -stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) +Stack now 0 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +Next token is token number (1.6: 1) +Shifting token number (1.6: 1) +Entering state 1 +Stack now 0 4 12 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 30 +Stack now 0 4 12 21 30 +Reading a token +Next token is token ')' (1.7: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Stack now 0 4 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 27 +Stack now 0 4 12 27 +Reducing stack by rule 13 (line 126): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Stack now 0 8 23 4 +Reading a token +Next token is token number (1.12: 1) +Shifting token number (1.12: 1) +Entering state 1 +Stack now 0 8 23 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Stack now 0 8 23 4 12 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 20 +Stack now 0 8 23 4 12 20 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Stack now 0 8 23 4 12 20 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 29 +Stack now 0 8 23 4 12 20 29 +Reading a token +Next token is token ')' (1.17: ) +Reducing stack by rule 8 (line 113): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Stack now 0 8 23 4 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 27 +Stack now 0 8 23 4 12 27 +Reducing stack by rule 13 (line 126): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 32 +Stack now 0 8 23 32 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 10 (line 115): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) +Entering state 8 Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) -Stack now 0 -stderr: +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) input: +./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 @@ -63320,130 +66217,133 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 +Return for a new token: Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Stack now 0 4 2 +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Stack now 0 4 5 +Return for a new token: Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 128): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2-4: ) +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 16 +Stack now 0 4 5 16 +Reducing stack by rule 16 (line 129): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) Stack now 0 4 -Shifting token error (1.2-4: ) +Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 +Return for a new token: Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 +Return for a new token: Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 +Return for a new token: Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 +Return for a new token: Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) +Next token is token number (1.9: 1) +Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.10: 1) --> $$ = nterm exp (1.10: 1) + $1 = token number (1.9: 1) +-> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 +Return for a new token: Reading a token -Next token is token number (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) +Next token is token number (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 -Shifting token error (1.10-12: ) +Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 -Next token is token number (1.12: 2) -Error: discarding token number (1.12: 2) -Error: popping token error (1.10-12: ) +Next token is token number (1.11: 2) +Error: discarding token number (1.11: 2) +Error: popping token error (1.9-11: ) Stack now 0 8 21 4 -Shifting token error (1.10-12: ) +Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 +Return for a new token: Reading a token -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 +Return for a new token: Reading a token -Next token is token '=' (1.15: ) +Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 +Return for a new token: Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.17: 1) --> $$ = nterm exp (1.17: 1) + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 +Return for a new token: Reading a token -Next token is token '\n' (1.18-2.0: ) +Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -63452,6 +66352,7 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -63460,8 +66361,12 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | 1 = 2 = 3 -./calc.at:1358: "$PERL" -pi -e 'use strict; + | (1 + # + 1) = 1111 +stderr: +./calc.at:1355: $PREPARSER ./calc input +./calc.at:1368: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +./calc.at:1362: $PREPARSER ./calc /dev/null +./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -63471,18 +66376,17 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1363: $PREPARSER ./calc input -./calc.at:1367: cat stderr +./calc.at:1354: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 @@ -63492,12 +66396,12 @@ Entering state 21 Stack now 0 8 21 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 @@ -63507,663 +66411,1024 @@ Entering state 22 Stack now 0 8 21 30 22 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 120): +Next token is token '=' (1.11: ) +Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 118): +Next token is token '=' (1.11: ) +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 +Next token is token "number" (1.13: 7) +Shifting token "number" (1.13: 7) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.13: 7) +-> $$ = nterm exp (1.13: 7) +Entering state 28 +Stack now 0 8 19 28 Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Stack now 0 8 21 5 15 -Reducing stack by rule 19 (line 144): - $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./calc.at:1360: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 +Next token is token '\n' (1.14-2.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (1.1-9: 7) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13: 7) +-> $$ = nterm exp (1.1-13: 7) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.14-2.0: ) +Shifting token '\n' (1.14-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (1.1-13: 7) + $2 = token '\n' (1.14-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token "number" (2.1: 1) +Shifting token "number" (2.1: 1) Entering state 1 -Stack now 0 1 +Stack now 0 6 1 Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) + $1 = token "number" (2.1: 1) +-> $$ = nterm exp (2.1: 1) Entering state 8 -Stack now 0 8 +Stack now 0 6 8 Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Stack now 0 8 23 +Next token is token '+' (2.3: ) +Shifting token '+' (2.3: ) +Entering state 21 +Stack now 0 6 8 21 Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) -Stack now 0 -stderr: -Starting parse -Entering state 0 -Stack now 0 +Next token is token "number" (2.5: 2) +Shifting token "number" (2.5: 2) +Entering state 1 +Stack now 0 6 8 21 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (2.5: 2) +-> $$ = nterm exp (2.5: 2) +Entering state 30 +Stack now 0 6 8 21 30 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token '*' (2.7: ) +Shifting token '*' (2.7: ) +Entering state 22 +Stack now 0 6 8 21 30 22 +Reading a token +Next token is token '-' (2.9: ) +Shifting token '-' (2.9: ) +Entering state 2 +Stack now 0 6 8 21 30 22 2 +Reading a token +Next token is token "number" (2.10: 3) +Shifting token "number" (2.10: 3) Entering state 1 -Stack now 0 1 +Stack now 0 6 8 21 30 22 2 1 Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 + $1 = token "number" (2.10: 3) +-> $$ = nterm exp (2.10: 3) +Entering state 10 +Stack now 0 6 8 21 30 22 2 10 Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) +Next token is token '=' (2.12: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (2.9: ) + $2 = nterm exp (2.10: 3) +-> $$ = nterm exp (2.9-10: -3) +Entering state 31 +Stack now 0 6 8 21 30 22 31 +Next token is token '=' (2.12: ) +Reducing stack by rule 9 (line 101): + $1 = nterm exp (2.5: 2) + $2 = token '*' (2.7: ) + $3 = nterm exp (2.9-10: -3) +-> $$ = nterm exp (2.5-10: -6) +Entering state 30 +Stack now 0 6 8 21 30 +Next token is token '=' (2.12: ) +Reducing stack by rule 7 (line 99): + $1 = nterm exp (2.1: 1) + $2 = token '+' (2.3: ) + $3 = nterm exp (2.5-10: -6) +-> $$ = nterm exp (2.1-10: -5) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (2.12: ) +Shifting token '=' (2.12: ) Entering state 19 -Stack now 0 8 19 +Stack now 0 6 8 19 Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) +Next token is token '-' (2.14: ) +Shifting token '-' (2.14: ) +Entering state 2 +Stack now 0 6 8 19 2 +Reading a token +Next token is token "number" (2.15: 5) +Shifting token "number" (2.15: 5) Entering state 1 -Stack now 0 8 19 1 +Stack now 0 6 8 19 2 1 Reducing stack by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) + $1 = token "number" (2.15: 5) +-> $$ = nterm exp (2.15: 5) +Entering state 10 +Stack now 0 6 8 19 2 10 +Reading a token +Next token is token '\n' (2.16-3.0: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (2.14: ) + $2 = nterm exp (2.15: 5) +-> $$ = nterm exp (2.14-15: -5) Entering state 28 -Stack now 0 8 19 28 +Stack now 0 6 8 19 28 +Next token is token '\n' (2.16-3.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (2.1-10: -5) + $2 = token '=' (2.12: ) + $3 = nterm exp (2.14-15: -5) +-> $$ = nterm exp (2.1-15: -5) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (2.16-3.0: ) +Shifting token '\n' (2.16-3.0: ) +Entering state 25 +Stack now 0 6 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (2.1-15: -5) + $2 = token '\n' (2.16-3.0: ) +-> $$ = nterm line (2.1-3.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-2.0: ) + $2 = nterm line (2.1-3.0: ) +-> $$ = nterm input (1.1-3.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 19 -Error: popping token '=' (1.3: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) -Stack now 0 -./calc.at:1358: cat stderr -input: -./calc.at:1357: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1360: cat stderr -stderr: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -Starting parse -Entering state 0 -Stack now 0 +Next token is token '\n' (3.1-4.0: ) +Shifting token '\n' (3.1-4.0: ) +Entering state 3 +Stack now 0 6 3 +Reducing stack by rule 3 (line 83): + $1 = token '\n' (3.1-4.0: ) +-> $$ = nterm line (3.1-4.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-3.0: ) + $2 = nterm line (3.1-4.0: ) +-> $$ = nterm input (1.1-4.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token '-' (4.1: ) +Shifting token '-' (4.1: ) +Entering state 2 +Stack now 0 6 2 +Reading a token +Next token is token "number" (4.2: 1) +Shifting token "number" (4.2: 1) Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 +Stack now 0 6 2 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (4.2: 1) +-> $$ = nterm exp (4.2: 1) +Entering state 10 +Stack now 0 6 2 10 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 +Next token is token '^' (4.3: ) +Shifting token '^' (4.3: ) +Entering state 24 +Stack now 0 6 2 10 24 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token "number" (4.4: 2) +Shifting token "number" (4.4: 2) Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 +Stack now 0 6 2 10 24 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (4.4: 2) +-> $$ = nterm exp (4.4: 2) +Entering state 33 +Stack now 0 6 2 10 24 33 Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 +Next token is token '=' (4.6: ) +Reducing stack by rule 12 (line 112): + $1 = nterm exp (4.2: 1) + $2 = token '^' (4.3: ) + $3 = nterm exp (4.4: 2) +-> $$ = nterm exp (4.2-4: 1) +Entering state 10 +Stack now 0 6 2 10 +Next token is token '=' (4.6: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (4.1: ) + $2 = nterm exp (4.2-4: 1) +-> $$ = nterm exp (4.1-4: -1) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (4.6: ) +Shifting token '=' (4.6: ) +Entering state 19 +Stack now 0 6 8 19 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token '-' (4.8: ) +Shifting token '-' (4.8: ) +Entering state 2 +Stack now 0 6 8 19 2 +Reading a token +Next token is token "number" (4.9: 1) +Shifting token "number" (4.9: 1) Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 +Stack now 0 6 8 19 2 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (4.9: 1) +-> $$ = nterm exp (4.9: 1) +Entering state 10 +Stack now 0 6 8 19 2 10 Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 120): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) +Next token is token '\n' (4.10-5.0: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (4.8: ) + $2 = nterm exp (4.9: 1) +-> $$ = nterm exp (4.8-9: -1) +Entering state 28 +Stack now 0 6 8 19 28 +Next token is token '\n' (4.10-5.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (4.1-4: -1) + $2 = token '=' (4.6: ) + $3 = nterm exp (4.8-9: -1) +-> $$ = nterm exp (4.1-9: -1) Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 +Stack now 0 6 8 +Next token is token '\n' (4.10-5.0: ) +Shifting token '\n' (4.10-5.0: ) +Entering state 25 +Stack now 0 6 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (4.1-9: -1) + $2 = token '\n' (4.10-5.0: ) +-> $$ = nterm line (4.1-5.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-4.0: ) + $2 = nterm line (4.1-5.0: ) +-> $$ = nterm input (1.1-5.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 +Next token is token '(' (5.1: ) +Shifting token '(' (5.1: ) +Entering state 4 +Stack now 0 6 4 Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Stack now 0 8 21 5 15 -Reducing stack by rule 19 (line 144): - $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1367: $PREPARSER ./calc input -stderr: -syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -error: 4444 != 1 -./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1355: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -error: 4444 != 1 - | error -./calc.at:1362: $PREPARSER ./calc input -./calc.at:1355: cat stderr -input: -./calc.at:1364: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | - | +1 -./calc.at:1358: $PREPARSER ./calc input -stderr: -./calc.at:1357: cat stderr -./calc.at:1369: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS -Starting parse -Entering state 0 -Stack now 0 +Next token is token '-' (5.2: ) +Shifting token '-' (5.2: ) +Entering state 2 +Stack now 0 6 4 2 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token "number" (5.3: 1) +Shifting token "number" (5.3: 1) Entering state 1 -Stack now 0 1 +Stack now 0 6 4 2 1 Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) + $1 = token "number" (5.3: 1) +-> $$ = nterm exp (5.3: 1) +Entering state 10 +Stack now 0 6 4 2 10 +Reading a token +Next token is token ')' (5.4: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (5.2: ) + $2 = nterm exp (5.3: 1) +-> $$ = nterm exp (5.2-3: -1) +Entering state 12 +Stack now 0 6 4 12 +Next token is token ')' (5.4: ) +Shifting token ')' (5.4: ) +Entering state 27 +Stack now 0 6 4 12 27 +Reducing stack by rule 13 (line 113): + $1 = token '(' (5.1: ) + $2 = nterm exp (5.2-3: -1) + $3 = token ')' (5.4: ) +-> $$ = nterm exp (5.1-4: -1) Entering state 8 -Stack now 0 8 +Stack now 0 6 8 Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) +Next token is token '^' (5.5: ) +Shifting token '^' (5.5: ) +Entering state 24 +Stack now 0 6 8 24 +Reading a token +Next token is token "number" (5.6: 2) +Shifting token "number" (5.6: 2) +Entering state 1 +Stack now 0 6 8 24 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (5.6: 2) +-> $$ = nterm exp (5.6: 2) +Entering state 33 +Stack now 0 6 8 24 33 +Reading a token +Next token is token '=' (5.8: ) +Reducing stack by rule 12 (line 112): + $1 = nterm exp (5.1-4: -1) + $2 = token '^' (5.5: ) + $3 = nterm exp (5.6: 2) +-> $$ = nterm exp (5.1-6: 1) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (5.8: ) +Shifting token '=' (5.8: ) Entering state 19 -Stack now 0 8 19 +Stack now 0 6 8 19 Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) +Next token is token "number" (5.10: 1) +Shifting token "number" (5.10: 1) Entering state 1 -Stack now 0 8 19 1 +Stack now 0 6 8 19 1 Reducing stack by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) + $1 = token "number" (5.10: 1) +-> $$ = nterm exp (5.10: 1) Entering state 28 -Stack now 0 8 19 28 +Stack now 0 6 8 19 28 Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 19 -Error: popping token '=' (1.3: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) -Stack now 0 -stderr: -Starting parse -Entering state 0 -Stack now 0 +Next token is token '\n' (5.11-6.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (5.1-6: 1) + $2 = token '=' (5.8: ) + $3 = nterm exp (5.10: 1) +-> $$ = nterm exp (5.1-10: 1) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (5.11-6.0: ) +Shifting token '\n' (5.11-6.0: ) +Entering state 25 +Stack now 0 6 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (5.1-10: 1) + $2 = token '\n' (5.11-6.0: ) +-> $$ = nterm line (5.1-6.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-5.0: ) + $2 = nterm line (5.1-6.0: ) +-> $$ = nterm input (1.1-6.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) +Next token is token '\n' (6.1-7.0: ) +Shifting token '\n' (6.1-7.0: ) Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 96): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) +Stack now 0 6 3 +Reducing stack by rule 3 (line 83): + $1 = token '\n' (6.1-7.0: ) +-> $$ = nterm line (6.1-7.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-6.0: ) + $2 = nterm line (6.1-7.0: ) +-> $$ = nterm input (1.1-7.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) -Stack now 0 -./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -./calc.at:1363: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Stack now 0 +Next token is token '-' (7.1: ) +Shifting token '-' (7.1: ) +Entering state 2 +Stack now 0 6 2 Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) +Next token is token '-' (7.2: ) +Shifting token '-' (7.2: ) +Entering state 2 +Stack now 0 6 2 2 +Reading a token +Next token is token '-' (7.3: ) +Shifting token '-' (7.3: ) +Entering state 2 +Stack now 0 6 2 2 2 +Reading a token +Next token is token "number" (7.4: 1) +Shifting token "number" (7.4: 1) +Entering state 1 +Stack now 0 6 2 2 2 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (7.4: 1) +-> $$ = nterm exp (7.4: 1) +Entering state 10 +Stack now 0 6 2 2 2 10 +Reading a token +Next token is token '=' (7.6: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (7.3: ) + $2 = nterm exp (7.4: 1) +-> $$ = nterm exp (7.3-4: -1) +Entering state 10 +Stack now 0 6 2 2 10 +Next token is token '=' (7.6: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (7.2: ) + $2 = nterm exp (7.3-4: -1) +-> $$ = nterm exp (7.2-4: 1) +Entering state 10 +Stack now 0 6 2 10 +Next token is token '=' (7.6: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (7.1: ) + $2 = nterm exp (7.2-4: 1) +-> $$ = nterm exp (7.1-4: -1) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (7.6: ) +Shifting token '=' (7.6: ) +Entering state 19 +Stack now 0 6 8 19 +Reading a token +Next token is token '-' (7.8: ) +Shifting token '-' (7.8: ) +Entering state 2 +Stack now 0 6 8 19 2 +Reading a token +Next token is token "number" (7.9: 1) +Shifting token "number" (7.9: 1) +Entering state 1 +Stack now 0 6 8 19 2 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (7.9: 1) +-> $$ = nterm exp (7.9: 1) +Entering state 10 +Stack now 0 6 8 19 2 10 +Reading a token +Next token is token '\n' (7.10-8.0: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (7.8: ) + $2 = nterm exp (7.9: 1) +-> $$ = nterm exp (7.8-9: -1) +Entering state 28 +Stack now 0 6 8 19 28 +Next token is token '\n' (7.10-8.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (7.1-4: -1) + $2 = token '=' (7.6: ) + $3 = nterm exp (7.8-9: -1) +-> $$ = nterm exp (7.1-9: -1) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (7.10-8.0: ) +Shifting token '\n' (7.10-8.0: ) +Entering state 25 +Stack now 0 6 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (7.1-9: -1) + $2 = token '\n' (7.10-8.0: ) +-> $$ = nterm line (7.1-8.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-7.0: ) + $2 = nterm line (7.1-8.0: ) +-> $$ = nterm input (1.1-8.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '\n' (8.1-9.0: ) +Shifting token '\n' (8.1-9.0: ) Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 96): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) +Stack now 0 6 3 +Reducing stack by rule 3 (line 83): + $1 = token '\n' (8.1-9.0: ) +-> $$ = nterm line (8.1-9.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-8.0: ) + $2 = nterm line (8.1-9.0: ) +-> $$ = nterm input (1.1-9.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) -Stack now 0 -input: -./calc.at:1363: cat stderr - | - | +1 -input: -./calc.at:1360: $PREPARSER ./calc input - | (* *) + (*) + (*) -./calc.at:1367: cat stderr -./calc.at:1358: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -./calc.at:1357: $PREPARSER ./calc input - | - | +1 -./calc.at:1363: $PREPARSER ./calc input -./calc.at:1358: cat stderr -./calc.at:1364: cat stderr -stderr: -stderr: -input: -Starting parse -Entering state 0 -Stack now 0 +Next token is token "number" (9.1: 1) +Shifting token "number" (9.1: 1) +Entering state 1 +Stack now 0 6 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (9.1: 1) +-> $$ = nterm exp (9.1: 1) +Entering state 8 +Stack now 0 6 8 Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) +Next token is token '-' (9.3: ) +Shifting token '-' (9.3: ) +Entering state 20 +Stack now 0 6 8 20 +Reading a token +Next token is token "number" (9.5: 2) +Shifting token "number" (9.5: 2) +Entering state 1 +Stack now 0 6 8 20 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (9.5: 2) +-> $$ = nterm exp (9.5: 2) +Entering state 29 +Stack now 0 6 8 20 29 +Reading a token +Next token is token '-' (9.7: ) +Reducing stack by rule 8 (line 100): + $1 = nterm exp (9.1: 1) + $2 = token '-' (9.3: ) + $3 = nterm exp (9.5: 2) +-> $$ = nterm exp (9.1-5: -1) +Entering state 8 +Stack now 0 6 8 +Next token is token '-' (9.7: ) +Shifting token '-' (9.7: ) +Entering state 20 +Stack now 0 6 8 20 +Reading a token +Next token is token "number" (9.9: 3) +Shifting token "number" (9.9: 3) +Entering state 1 +Stack now 0 6 8 20 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (9.9: 3) +-> $$ = nterm exp (9.9: 3) +Entering state 29 +Stack now 0 6 8 20 29 +Reading a token +Next token is token '=' (9.11: ) +Reducing stack by rule 8 (line 100): + $1 = nterm exp (9.1-5: -1) + $2 = token '-' (9.7: ) + $3 = nterm exp (9.9: 3) +-> $$ = nterm exp (9.1-9: -4) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (9.11: ) +Shifting token '=' (9.11: ) +Entering state 19 +Stack now 0 6 8 19 +Reading a token +Next token is token '-' (9.13: ) +Shifting token '-' (9.13: ) +Entering state 2 +Stack now 0 6 8 19 2 +Reading a token +Next token is token "number" (9.14: 4) +Shifting token "number" (9.14: 4) +Entering state 1 +Stack now 0 6 8 19 2 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (9.14: 4) +-> $$ = nterm exp (9.14: 4) +Entering state 10 +Stack now 0 6 8 19 2 10 +Reading a token +Next token is token '\n' (9.15-10.0: ) +Reducing stack by rule 11 (line 111): + $1 = token '-' (9.13: ) + $2 = nterm exp (9.14: 4) +-> $$ = nterm exp (9.13-14: -4) +Entering state 28 +Stack now 0 6 8 19 28 +Next token is token '\n' (9.15-10.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (9.1-9: -4) + $2 = token '=' (9.11: ) + $3 = nterm exp (9.13-14: -4) +-> $$ = nterm exp (9.1-14: -4) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (9.15-10.0: ) +Shifting token '\n' (9.15-10.0: ) +Entering state 25 +Stack now 0 6 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (9.1-14: -4) + $2 = token '\n' (9.15-10.0: ) +-> $$ = nterm line (9.1-10.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-9.0: ) + $2 = nterm line (9.1-10.0: ) +-> $$ = nterm input (1.1-10.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token "number" (10.1: 1) +Shifting token "number" (10.1: 1) +Entering state 1 +Stack now 0 6 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (10.1: 1) +-> $$ = nterm exp (10.1: 1) +Entering state 8 +Stack now 0 6 8 +Reading a token +Next token is token '-' (10.3: ) +Shifting token '-' (10.3: ) +Entering state 20 +Stack now 0 6 8 20 +Reading a token +Next token is token '(' (10.5: ) +Shifting token '(' (10.5: ) +Entering state 4 +Stack now 0 6 8 20 4 +Reading a token +Next token is token "number" (10.6: 2) +Shifting token "number" (10.6: 2) +Entering state 1 +Stack now 0 6 8 20 4 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (10.6: 2) +-> $$ = nterm exp (10.6: 2) +Entering state 12 +Stack now 0 6 8 20 4 12 +Reading a token +Next token is token '-' (10.8: ) +Shifting token '-' (10.8: ) +Entering state 20 +Stack now 0 6 8 20 4 12 20 +Reading a token +Next token is token "number" (10.10: 3) +Shifting token "number" (10.10: 3) +Entering state 1 +Stack now 0 6 8 20 4 12 20 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (10.10: 3) +-> $$ = nterm exp (10.10: 3) +Entering state 29 +Stack now 0 6 8 20 4 12 20 29 +Reading a token +Next token is token ')' (10.11: ) +Reducing stack by rule 8 (line 100): + $1 = nterm exp (10.6: 2) + $2 = token '-' (10.8: ) + $3 = nterm exp (10.10: 3) +-> $$ = nterm exp (10.6-10: -1) +Entering state 12 +Stack now 0 6 8 20 4 12 +Next token is token ')' (10.11: ) +Shifting token ')' (10.11: ) +Entering state 27 +Stack now 0 6 8 20 4 12 27 +Reducing stack by rule 13 (line 113): + $1 = token '(' (10.5: ) + $2 = nterm exp (10.6-10: -1) + $3 = token ')' (10.11: ) +-> $$ = nterm exp (10.5-11: -1) +Entering state 29 +Stack now 0 6 8 20 29 +Reading a token +Next token is token '=' (10.13: ) +Reducing stack by rule 8 (line 100): + $1 = nterm exp (10.1: 1) + $2 = token '-' (10.3: ) + $3 = nterm exp (10.5-11: -1) +-> $$ = nterm exp (10.1-11: 2) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (10.13: ) +Shifting token '=' (10.13: ) +Entering state 19 +Stack now 0 6 8 19 +Reading a token +Next token is token "number" (10.15: 2) +Shifting token "number" (10.15: 2) +Entering state 1 +Stack now 0 6 8 19 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (10.15: 2) +-> $$ = nterm exp (10.15: 2) +Entering state 28 +Stack now 0 6 8 19 28 +Reading a token +Next token is token '\n' (10.16-11.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (10.1-11: 2) + $2 = token '=' (10.13: ) + $3 = nterm exp (10.15: 2) +-> $$ = nterm exp (10.1-15: 2) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (10.16-11.0: ) +Shifting token '\n' (10.16-11.0: ) +Entering state 25 +Stack now 0 6 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (10.1-15: 2) + $2 = token '\n' (10.16-11.0: ) +-> $$ = nterm line (10.1-11.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-10.0: ) + $2 = nterm line (10.1-11.0: ) +-> $$ = nterm input (1.1-11.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '\n' (11.1-12.0: ) +Shifting token '\n' (11.1-12.0: ) Entering state 3 -Stack now 0 3 +Stack now 0 6 3 Reducing stack by rule 3 (line 83): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) + $1 = token '\n' (11.1-12.0: ) +-> $$ = nterm line (11.1-12.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-11.0: ) + $2 = nterm line (11.1-12.0: ) +-> $$ = nterm input (1.1-12.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) -Stack now 0 -Starting parse -Entering state 0 -Stack now 0 +Next token is token "number" (12.1: 2) +Shifting token "number" (12.1: 2) +Entering state 1 +Stack now 0 6 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (12.1: 2) +-> $$ = nterm exp (12.1: 2) +Entering state 8 +Stack now 0 6 8 Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -Stack now 0 -Starting parse -Entering state 0 -Stack now 0 +Next token is token '^' (12.2: ) +Shifting token '^' (12.2: ) +Entering state 24 +Stack now 0 6 8 24 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 +Next token is token "number" (12.3: 2) +Shifting token "number" (12.3: 2) +Entering state 1 +Stack now 0 6 8 24 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (12.3: 2) +-> $$ = nterm exp (12.3: 2) +Entering state 33 +Stack now 0 6 8 24 33 Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 +Next token is token '^' (12.4: ) +Shifting token '^' (12.4: ) +Entering state 24 +Stack now 0 6 8 24 33 24 Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 +Next token is token "number" (12.5: 3) +Shifting token "number" (12.5: 3) +Entering state 1 +Stack now 0 6 8 24 33 24 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (12.5: 3) +-> $$ = nterm exp (12.5: 3) +Entering state 33 +Stack now 0 6 8 24 33 24 33 Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) +Next token is token '=' (12.7: ) +Reducing stack by rule 12 (line 112): + $1 = nterm exp (12.3: 2) + $2 = token '^' (12.4: ) + $3 = nterm exp (12.5: 3) +-> $$ = nterm exp (12.3-5: 8) +Entering state 33 +Stack now 0 6 8 24 33 +Next token is token '=' (12.7: ) +Reducing stack by rule 12 (line 112): + $1 = nterm exp (12.1: 2) + $2 = token '^' (12.2: ) + $3 = nterm exp (12.3-5: 8) +-> $$ = nterm exp (12.1-5: 256) Entering state 8 -Stack now 0 8 +Stack now 0 6 8 +Next token is token '=' (12.7: ) +Shifting token '=' (12.7: ) +Entering state 19 +Stack now 0 6 8 19 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 21 -Stack now 0 8 21 +Next token is token "number" (12.9-11: 256) +Shifting token "number" (12.9-11: 256) +Entering state 1 +Stack now 0 6 8 19 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (12.9-11: 256) +-> $$ = nterm exp (12.9-11: 256) +Entering state 28 +Stack now 0 6 8 19 28 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) +Next token is token '\n' (12.12-13.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (12.1-5: 256) + $2 = token '=' (12.7: ) + $3 = nterm exp (12.9-11: 256) +-> $$ = nterm exp (12.1-11: 256) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (12.12-13.0: ) +Shifting token '\n' (12.12-13.0: ) +Entering state 25 +Stack now 0 6 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (12.1-11: 256) + $2 = token '\n' (12.12-13.0: ) +-> $$ = nterm line (12.1-13.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-12.0: ) + $2 = nterm line (12.1-13.0: ) +-> $$ = nterm input (1.1-13.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '(' (13.1: ) +Shifting token '(' (13.1: ) Entering state 4 -Stack now 0 8 21 4 +Stack now 0 6 4 Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) -Error: popping token error (1.10: ) -Stack now 0 8 21 4 -Shifting token error (1.10: ) -Entering state 11 -Stack now 0 8 21 4 11 +Next token is token "number" (13.2: 2) +Shifting token "number" (13.2: 2) +Entering state 1 +Stack now 0 6 4 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (13.2: 2) +-> $$ = nterm exp (13.2: 2) +Entering state 12 +Stack now 0 6 4 12 Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) -Entering state 30 -Stack now 0 8 21 30 +Next token is token '^' (13.3: ) +Shifting token '^' (13.3: ) +Entering state 24 +Stack now 0 6 4 12 24 Reading a token -Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) +Next token is token "number" (13.4: 2) +Shifting token "number" (13.4: 2) +Entering state 1 +Stack now 0 6 4 12 24 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (13.4: 2) +-> $$ = nterm exp (13.4: 2) +Entering state 33 +Stack now 0 6 4 12 24 33 +Reading a token +Next token is token ')' (13.5: ) +Reducing stack by rule 12 (line 112): + $1 = nterm exp (13.2: 2) + $2 = token '^' (13.3: ) + $3 = nterm exp (13.4: 2) +-> $$ = nterm exp (13.2-4: 4) +Entering state 12 +Stack now 0 6 4 12 +Next token is token ')' (13.5: ) +Shifting token ')' (13.5: ) +Entering state 27 +Stack now 0 6 4 12 27 +Reducing stack by rule 13 (line 113): + $1 = token '(' (13.1: ) + $2 = nterm exp (13.2-4: 4) + $3 = token ')' (13.5: ) +-> $$ = nterm exp (13.1-5: 4) Entering state 8 -Stack now 0 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Stack now 0 8 21 +Stack now 0 6 8 Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 -Stack now 0 8 21 4 +Next token is token '^' (13.6: ) +Shifting token '^' (13.6: ) +Entering state 24 +Stack now 0 6 8 24 Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) -Error: popping token error (1.16: ) -Stack now 0 8 21 4 -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 21 4 11 +Next token is token "number" (13.7: 3) +Shifting token "number" (13.7: 3) +Entering state 1 +Stack now 0 6 8 24 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (13.7: 3) +-> $$ = nterm exp (13.7: 3) +Entering state 33 +Stack now 0 6 8 24 33 Reading a token -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 30 -Stack now 0 8 21 30 +Next token is token '=' (13.9: ) +Reducing stack by rule 12 (line 112): + $1 = nterm exp (13.1-5: 4) + $2 = token '^' (13.6: ) + $3 = nterm exp (13.7: 3) +-> $$ = nterm exp (13.1-7: 64) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (13.9: ) +Shifting token '=' (13.9: ) +Entering state 19 +Stack now 0 6 8 19 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) +Next token is token "number" (13.11-12: 64) +Shifting token "number" (13.11-12: 64) +Entering state 1 +Stack now 0 6 8 19 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (13.11-12: 64) +-> $$ = nterm exp (13.11-12: 64) +Entering state 28 +Stack now 0 6 8 19 28 +Reading a token +Next token is token '\n' (13.13-14.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (13.1-7: 64) + $2 = token '=' (13.9: ) + $3 = nterm exp (13.11-12: 64) +-> $$ = nterm exp (13.1-12: 64) Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Stack now 0 6 8 +Next token is token '\n' (13.13-14.0: ) +Shifting token '\n' (13.13-14.0: ) Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) +Stack now 0 6 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (13.1-12: 64) + $2 = token '\n' (13.13-14.0: ) +-> $$ = nterm line (13.1-14.0: ) +Entering state 18 +Stack now 0 6 18 +Reducing stack by rule 2 (line 79): + $1 = nterm input (1.1-13.0: ) + $2 = nterm line (13.1-14.0: ) +-> $$ = nterm input (1.1-14.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (14.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +Cleanup: popping token "end of input" (14.1: ) +Cleanup: popping nterm input (1.1-14.0: ) +stderr: +./calc.at:1363: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: -input: -./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (#) + (#) = 2222 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 96): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) -Stack now 0 -./calc.at:1358: $PREPARSER ./calc /dev/null -./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Now at end of input. -1.1: syntax error, unexpected end of file -Cleanup: discarding lookahead token end of file (1.1: ) -Stack now 0 -./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1355: $PREPARSER ./calc input -input: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 96): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) +Next token is token "number" (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) +Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 -./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +./calc.at:1358: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Stack now 0 @@ -64172,8 +67437,6 @@ 1.1: syntax error, unexpected end of file Cleanup: discarding lookahead token end of file (1.1: ) Stack now 0 -stderr: - | error Starting parse Entering state 0 Stack now 0 @@ -64183,102 +67446,122 @@ Entering state 4 Stack now 0 4 Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 Reading a token -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +Next token is token number (1.6: 1) +Shifting token number (1.6: 1) +Entering state 1 +Stack now 0 4 12 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 30 +Stack now 0 4 12 21 30 +Reading a token +Next token is token ')' (1.7: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Stack now 0 4 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 27 +Stack now 0 4 12 27 +Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 21 -Stack now 0 8 21 +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 23 +Stack now 0 8 23 Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) Entering state 4 -Stack now 0 8 21 4 -Reading a token -1.8: syntax error: invalid character: '#' -Shifting token error (1.8: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token invalid token (1.8: ) -Error: discarding token invalid token (1.8: ) -Error: popping token error (1.8: ) -Stack now 0 8 21 4 -Shifting token error (1.8: ) -Entering state 11 -Stack now 0 8 21 4 11 +Stack now 0 8 23 4 Reading a token -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 30 -Stack now 0 8 21 30 +Next token is token number (1.12: 1) +Shifting token number (1.12: 1) +Entering state 1 +Stack now 0 8 23 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Stack now 0 8 23 4 12 Reading a token -Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 19 -Stack now 0 8 19 +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 20 +Stack now 0 8 23 4 12 20 Reading a token -Next token is token number (1.13-16: 2222) -Shifting token number (1.13-16: 2222) +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) Entering state 1 -Stack now 0 8 19 1 +Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 28 -Stack now 0 8 19 28 + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 29 +Stack now 0 8 23 4 12 20 29 Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) +Next token is token ')' (1.17: ) +Reducing stack by rule 8 (line 113): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Stack now 0 8 23 4 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 27 +Stack now 0 8 23 4 12 27 +Reducing stack by rule 13 (line 126): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 32 +Stack now 0 8 23 32 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 10 (line 115): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -64295,36 +67578,6 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1364: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" (1.1: ) -Stack now 0 -stderr: -./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (!!) + (1 2) = 1 -./calc.at:1367: $PREPARSER ./calc input -./calc.at:1360: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -error: 2222 != 1 -stderr: -./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -64334,132 +67587,95 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +1.6: syntax error: invalid character: '#' +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) -Error: popping token error (1.2: ) +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) Stack now 0 4 -Shifting token error (1.2: ) +Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2: ) +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Error: popping token error (1.2-6: ) Stack now 0 4 -Shifting token error (1.2-4: ) +Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) -Error: popping token error (1.10: ) -Stack now 0 8 21 4 -Shifting token error (1.10: ) +Next token is token number (1.10: 1) +Error: discarding token number (1.10: 1) +Error: popping token error (1.2-8: ) +Stack now 0 4 +Shifting token error (1.2-10: ) Entering state 11 -Stack now 0 8 21 4 11 +Stack now 0 4 11 Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 139): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) +-> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 -Stack now 0 8 21 4 Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) -Error: popping token error (1.16: ) -Stack now 0 8 21 4 -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 21 4 11 +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 30 -Stack now 0 8 21 30 +Next token is token number (1.15-18: 1111) +Shifting token number (1.15-18: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) +Entering state 28 +Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) +Next token is token '\n' (1.19-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -64476,55 +67692,14 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +485. calc.at:1354: ok ./calc.at:1360: cat stderr +./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1358: cat stderr +input: stderr: -./calc.at:1360: $PREPARSER ./calc /dev/null -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 83): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) -Stack now 0 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -Stack now 0 -./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Now at end of input. -1.1: syntax error, unexpected end of file -Cleanup: discarding lookahead token end of file (1.1: ) -Stack now 0 -stderr: -./calc.at:1358: "$PERL" -pi -e 'use strict; +./calc.at:1357: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -64534,14 +67709,19 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" (1.1: ) -Stack now 0 + | 1 2 +./calc.at:1363: $PREPARSER ./calc input +./calc.at:1364: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: Starting parse Entering state 0 Stack now 0 @@ -64551,102 +67731,95 @@ Entering state 4 Stack now 0 4 Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +1.6: syntax error: invalid character: '#' +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.2: ) +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) Stack now 0 4 -Shifting token error (1.2: ) +Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -1.8: syntax error: invalid character: '#' -Shifting token error (1.8: ) +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-8: ) Entering state 11 -Stack now 0 8 21 4 11 -Next token is token invalid token (1.8: ) -Error: discarding token invalid token (1.8: ) -Error: popping token error (1.8: ) -Stack now 0 8 21 4 -Shifting token error (1.8: ) +Stack now 0 4 11 +Reading a token +Next token is token number (1.10: 1) +Error: discarding token number (1.10: 1) +Error: popping token error (1.2-8: ) +Stack now 0 4 +Shifting token error (1.2-10: ) Entering state 11 -Stack now 0 8 21 4 11 +Stack now 0 4 11 Reading a token -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) Entering state 26 -Stack now 0 8 21 4 11 26 +Stack now 0 4 11 26 Reducing stack by rule 14 (line 139): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) +Reading a token +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.13-16: 2222) -Shifting token number (1.13-16: 2222) +Next token is token number (1.15-18: 1111) +Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) + $1 = token number (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.17-2.0: ) +Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -64663,196 +67836,46 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1363: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1357: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -error: 2222 != 1 -./calc.at:1364: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1363: cat stderr -./calc.at:1357: cat stderr -./calc.at:1362: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1363: $PREPARSER ./calc /dev/null -./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1355: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1367: cat stderr -stderr: -./calc.at:1358: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token -Now at end of input. -1.1: syntax error, unexpected end of file -Cleanup: discarding lookahead token end of file (1.1: ) -Stack now 0 -./calc.at:1362: cat stderr -./calc.at:1364: cat stderr -input: -./calc.at:1355: cat stderr - | 1 + 2 * 3 + !+ ++ -Starting parse -Entering state 0 -Stack now 0 +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 Reading a token -Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" (1.1: ) +Next token is token "number" (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 input: -./calc.at:1357: $PREPARSER ./calc input - | (- *) + (1 2) = 1 -./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1367: $PREPARSER ./calc input -./calc.at:1360: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -stderr: -stderr: stderr: input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1358: $PREPARSER ./calc input +./calc.at:1360: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Stack now 0 8 21 5 14 -Reducing stack by rule 17 (line 130): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -input: -./calc.at:1360: cat stderr -./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | 1 = 2 = 3 +Now at end of input. +1.1: syntax error, unexpected end of file +Cleanup: discarding lookahead token end of file (1.1: ) +Stack now 0 +./calc.at:1357: cat stderr + | (- *) + (1 2) = 1 +./calc.at:1358: $PREPARSER ./calc input +./calc.at:1364: cat stderr stderr: +./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + Starting parse Entering state 0 Stack now 0 @@ -64861,7 +67884,6 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 -Return for a new token: Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' @@ -64879,19 +67901,16 @@ -> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 -Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 8 21 -Return for a new token: Reading a token Next token is token '(' (1.6: ) Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 21 4 -Return for a new token: Reading a token Next token is token number (1.7: 1) Shifting token number (1.7: 1) @@ -64902,13 +67921,11 @@ -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 -Return for a new token: Reading a token Next token is token '+' (1.9: ) Shifting token '+' (1.9: ) Entering state 21 Stack now 0 8 21 4 12 21 -Return for a new token: Reading a token Next token is token number (1.11: 1) Shifting token number (1.11: 1) @@ -64919,7 +67936,6 @@ -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 -Return for a new token: Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): @@ -64933,7 +67949,6 @@ Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 4 12 21 -Return for a new token: Reading a token Next token is token number (1.15: 1) Shifting token number (1.15: 1) @@ -64944,7 +67959,6 @@ -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 -Return for a new token: Reading a token Next token is token '+' (1.17: ) Reducing stack by rule 7 (line 112): @@ -64958,7 +67972,6 @@ Shifting token '+' (1.17: ) Entering state 21 Stack now 0 8 21 4 12 21 -Return for a new token: Reading a token Next token is token ')' (1.18: ) 1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' @@ -64980,7 +67993,6 @@ -> $$ = nterm exp (1.6-18: 1111) Entering state 30 Stack now 0 8 21 30 -Return for a new token: Reading a token Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 112): @@ -64994,13 +68006,11 @@ Shifting token '+' (1.20: ) Entering state 21 Stack now 0 8 21 -Return for a new token: Reading a token Next token is token '(' (1.22: ) Shifting token '(' (1.22: ) Entering state 4 Stack now 0 8 21 4 -Return for a new token: Reading a token Next token is token '*' (1.23: ) 1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' @@ -65014,7 +68024,6 @@ Shifting token error (1.23: ) Entering state 11 Stack now 0 8 21 4 11 -Return for a new token: Reading a token Next token is token '*' (1.25: ) Error: discarding token '*' (1.25: ) @@ -65023,7 +68032,6 @@ Shifting token error (1.23-25: ) Entering state 11 Stack now 0 8 21 4 11 -Return for a new token: Reading a token Next token is token '*' (1.27: ) Error: discarding token '*' (1.27: ) @@ -65032,7 +68040,6 @@ Shifting token error (1.23-27: ) Entering state 11 Stack now 0 8 21 4 11 -Return for a new token: Reading a token Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) @@ -65045,7 +68052,6 @@ -> $$ = nterm exp (1.22-28: 1111) Entering state 30 Stack now 0 8 21 30 -Return for a new token: Reading a token Next token is token '+' (1.30: ) Reducing stack by rule 7 (line 112): @@ -65059,13 +68065,11 @@ Shifting token '+' (1.30: ) Entering state 21 Stack now 0 8 21 -Return for a new token: Reading a token Next token is token '(' (1.32: ) Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 21 4 -Return for a new token: Reading a token Next token is token number (1.33: 1) Shifting token number (1.33: 1) @@ -65076,13 +68080,11 @@ -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 -Return for a new token: Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) Entering state 22 Stack now 0 8 21 4 12 22 -Return for a new token: Reading a token Next token is token number (1.37: 2) Shifting token number (1.37: 2) @@ -65093,7 +68095,6 @@ -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 -Return for a new token: Reading a token Next token is token '*' (1.39: ) Reducing stack by rule 9 (line 114): @@ -65107,7 +68108,6 @@ Shifting token '*' (1.39: ) Entering state 22 Stack now 0 8 21 4 12 22 -Return for a new token: Reading a token Next token is token '*' (1.41: ) 1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' @@ -65125,7 +68125,6 @@ Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 21 4 11 -Return for a new token: Reading a token Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) @@ -65138,7 +68137,6 @@ -> $$ = nterm exp (1.32-42: 1111) Entering state 30 Stack now 0 8 21 30 -Return for a new token: Reading a token Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 112): @@ -65152,7 +68150,6 @@ Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 -Return for a new token: Reading a token Next token is token number (1.46: 1) Shifting token number (1.46: 1) @@ -65163,7 +68160,6 @@ -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 -Return for a new token: Reading a token Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 102): @@ -65189,7 +68185,6 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -65198,237 +68193,161 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | 1 = 2 = 3 -./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (1 + #) = 1111 -./calc.at:1364: $PREPARSER ./calc input -./calc.at:1355: $PREPARSER ./calc input -./calc.at:1362: $PREPARSER ./calc input -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -error: 2222 != 1 -./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: stderr: +487. calc.at:1357: ok +./calc.at:1355: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 28 -Stack now 0 8 19 28 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Return for a new token: Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 19 -Error: popping token '=' (1.3: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) -Stack now 0 -Starting parse -Entering state 0 -Stack now 0 +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Stack now 0 4 2 +Return for a new token: Reading a token -Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" (1.1: ) -Stack now 0 -stderr: -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -Starting parse -Entering state 0 -Stack now 0 +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 128): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2-4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Return for a new token: Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 +Return for a new token: Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 +Return for a new token: Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Stack now 0 8 21 5 14 -Reducing stack by rule 17 (line 130): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -error: 2222 != 1 -./calc.at:1360: $PREPARSER ./calc input -./calc.at:1357: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) Entering state 4 -Stack now 0 4 +Stack now 0 8 21 4 +Return for a new token: Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) Entering state 1 -Stack now 0 4 1 +Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) + $1 = token number (1.10: 1) +-> $$ = nterm exp (1.10: 1) Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 +Stack now 0 8 21 4 12 +Return for a new token: Reading a token -1.6: syntax error: invalid character: '#' -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) +Next token is token number (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Stack now 0 8 21 4 +Shifting token error (1.10-12: ) Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-6: ) +Stack now 0 8 21 4 11 +Next token is token number (1.12: 2) +Error: discarding token number (1.12: 2) +Error: popping token error (1.10-12: ) +Stack now 0 8 21 4 +Shifting token error (1.10-12: ) Entering state 11 -Stack now 0 4 11 +Stack now 0 8 21 4 11 +Return for a new token: Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 30 +Stack now 0 8 21 30 +Return for a new token: +Reading a token +Next token is token '=' (1.15: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 +Return for a new token: Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) + $1 = token number (1.17: 1) +-> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 +Return for a new token: Reading a token -Next token is token '\n' (1.15-2.0: ) +Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -65437,6 +68356,7 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -65445,47 +68365,41 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./calc.at:1362: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1355: cat stderr +input: stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 19 -Error: popping token '=' (1.3: ) -Stack now 0 8 +Next token is token "number" (1.3: 2) +1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) +Cleanup: discarding lookahead token "number" (1.3: 2) Stack now 0 Starting parse Entering state 0 @@ -65804,10 +68718,9 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: stderr: + | 1//2 +./calc.at:1364: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -65818,324 +68731,351 @@ Stack now 0 4 Return for a new token: Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Stack now 0 4 2 +Return for a new token: +Reading a token +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 128): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2-4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Return for a new token: +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token -Next token is token number (1.7: 1) -Shifting token number (1.7: 1) +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Return for a new token: -Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Return for a new token: -Reading a token -Next token is token number (1.11: 1) -Shifting token number (1.11: 1) -Entering state 1 -Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.11: 1) --> $$ = nterm exp (1.11: 1) -Entering state 30 -Stack now 0 8 21 4 12 21 30 -Return for a new token: -Reading a token -Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Return for a new token: -Reading a token -Next token is token number (1.15: 1) -Shifting token number (1.15: 1) -Entering state 1 -Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 30 -Stack now 0 8 21 4 12 21 30 -Return for a new token: -Reading a token -Next token is token '+' (1.17: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) + $1 = token number (1.10: 1) +-> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Return for a new token: -Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.7-15: 3) -Stack now 0 8 21 4 -Shifting token error (1.7-18: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) -Entering state 30 -Stack now 0 8 21 30 -Return for a new token: -Reading a token -Next token is token '+' (1.20: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) -Entering state 21 -Stack now 0 8 21 -Return for a new token: -Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Stack now 0 8 21 4 -Return for a new token: -Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Error: popping token error (1.23: ) -Stack now 0 8 21 4 -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 21 4 11 Return for a new token: Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Error: popping token error (1.23: ) +Next token is token number (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 -Shifting token error (1.23-25: ) +Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 -Return for a new token: -Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) -Error: popping token error (1.23-25: ) +Next token is token number (1.12: 2) +Error: discarding token number (1.12: 2) +Error: popping token error (1.10-12: ) Stack now 0 8 21 4 -Shifting token error (1.23-27: ) +Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token -Next token is token '+' (1.30: ) +Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) -Entering state 21 -Stack now 0 8 21 -Return for a new token: -Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) -Entering state 4 -Stack now 0 8 21 4 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) +Entering state 19 +Stack now 0 8 19 Return for a new token: Reading a token -Next token is token number (1.33: 1) -Shifting token number (1.33: 1) +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) Entering state 1 -Stack now 0 8 21 4 1 +Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Stack now 0 8 21 4 12 + $1 = token number (1.17: 1) +-> $$ = nterm exp (1.17: 1) +Entering state 28 +Stack now 0 8 19 28 Return for a new token: Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 22 -Stack now 0 8 21 4 12 22 +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 Return for a new token: Reading a token -Next token is token number (1.37: 2) -Shifting token number (1.37: 2) +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: +./calc.at:1362: cat stderr +input: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Stack now 0 8 21 4 12 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 31 -Stack now 0 8 21 4 12 22 31 -Return for a new token: +Stack now 0 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 Reading a token -Next token is token '*' (1.39: ) -Reducing stack by rule 9 (line 114): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Stack now 0 8 23 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '/' (1.3: ) +Stack now 0 + | (1 + 1) / (1 - 1) +./calc.at:1363: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1355: $PREPARSER ./calc input +./calc.at:1360: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1363: cat stderr +input: +495. calc.at:1369: testing Calculator parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} ... +./calc.at:1369: mv calc.y.tmp calc.y + + +./calc.at:1358: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 22 -Stack now 0 8 21 4 12 22 -Return for a new token: +Stack now 0 4 12 Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.33-37: 2) -Stack now 0 8 21 4 -Shifting token error (1.33-41: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Error: popping token error (1.33-41: ) -Stack now 0 8 21 4 -Shifting token error (1.33-41: ) -Entering state 11 -Stack now 0 8 21 4 11 -Return for a new token: +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 Reading a token -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) +Next token is token number (1.6: 1) +Shifting token number (1.6: 1) +Entering state 1 +Stack now 0 4 12 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.6: 1) +-> $$ = nterm exp (1.6: 1) Entering state 30 -Stack now 0 8 21 30 -Return for a new token: +Stack now 0 4 12 21 30 Reading a token -Next token is token '=' (1.44: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) +Next token is token ')' (1.7: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Stack now 0 4 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 27 +Stack now 0 4 12 27 +Reducing stack by rule 13 (line 138): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) -Entering state 19 -Stack now 0 8 19 -Return for a new token: Reading a token -Next token is token number (1.46: 1) -Shifting token number (1.46: 1) +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 23 +Stack now 0 8 23 +Reading a token +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Stack now 0 8 23 4 +Reading a token +Next token is token number (1.12: 1) +Shifting token number (1.12: 1) Entering state 1 -Stack now 0 8 19 1 +Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.46: 1) --> $$ = nterm exp (1.46: 1) -Entering state 28 -Stack now 0 8 19 28 -Return for a new token: + $1 = token number (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Stack now 0 8 23 4 12 Reading a token -Next token is token '\n' (1.47-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 20 +Stack now 0 8 23 4 12 20 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Stack now 0 8 23 4 12 20 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 29 +Stack now 0 8 23 4 12 20 29 +Reading a token +Next token is token ')' (1.17: ) +Reducing stack by rule 8 (line 119): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Stack now 0 8 23 4 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 27 +Stack now 0 8 23 4 12 27 +Reducing stack by rule 13 (line 138): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 32 +Stack now 0 8 23 32 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 10 (line 121): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -66144,7 +69084,6 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -66153,6 +69092,40 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1369: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1362: $PREPARSER ./calc input +./calc.at:1360: cat stderr +stderr: +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Stack now 0 8 23 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '/' (1.3: ) +Stack now 0 Starting parse Entering state 0 Stack now 0 @@ -66470,80 +69443,10 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1363: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 19 -Error: popping token '=' (1.3: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) -Stack now 0 -./calc.at:1360: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1363: cat stderr -./calc.at:1364: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1358: cat stderr stderr: -./calc.at:1367: cat stderr +./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: Starting parse Entering state 0 Stack now 0 @@ -66568,64 +69471,107 @@ Entering state 21 Stack now 0 4 12 21 Reading a token -1.6: syntax error: invalid character: '#' -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 +Next token is token number (1.6: 1) +Shifting token number (1.6: 1) +Entering state 1 +Stack now 0 4 12 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 30 +Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) +Reducing stack by rule 7 (line 118): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Stack now 0 4 12 +Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): +Entering state 27 +Stack now 0 4 12 27 +Reducing stack by rule 13 (line 138): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) + $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) +-> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Stack now 0 8 19 +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 23 +Stack now 0 8 23 Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Stack now 0 8 23 4 +Reading a token +Next token is token number (1.12: 1) +Shifting token number (1.12: 1) Entering state 1 -Stack now 0 8 19 1 +Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Stack now 0 8 19 28 + $1 = token number (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Stack now 0 8 23 4 12 Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 20 +Stack now 0 8 23 4 12 20 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Stack now 0 8 23 4 12 20 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 29 +Stack now 0 8 23 4 12 20 29 +Reading a token +Next token is token ')' (1.17: ) +Reducing stack by rule 8 (line 119): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Stack now 0 8 23 4 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 27 +Stack now 0 8 23 4 12 27 +Reducing stack by rule 13 (line 138): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 32 +Stack now 0 8 23 32 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 10 (line 121): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -66642,133 +69588,60 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | 1 + 2 * 3 + !- ++ -./calc.at:1357: $PREPARSER ./calc input -./calc.at:1364: cat stderr -./calc.at:1360: cat stderr input: -stderr: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 + | 1//2 ./calc.at:1363: $PREPARSER ./calc input + | (!!) + (1 2) = 1 +./calc.at:1360: $PREPARSER ./calc input +stderr: +./calc.at:1364: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Stack now 0 8 23 Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Stack now 0 8 21 5 13 -Reducing stack by rule 18 (line 131): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -input: +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '/' (1.3: ) +Stack now 0 stderr: -./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1358: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 input: +stdout: +496. calc.at:1370: testing Calculator parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} api.push-pull=both api.pure=full ... +./calc.at:1370: mv calc.y.tmp calc.y + +./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (* *) + (*) + (*) -./calc.at:1355: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (!!) + (1 2) = 1 -./calc.at:1367: $PREPARSER ./calc input -input: -stderr: -./calc.at:1358: cat stderr -./calc.at:1360: $PREPARSER ./calc input - | - | +1 -stderr: -./calc.at:1364: $PREPARSER ./calc input -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -stderr: +./calc.at:1358: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -66787,7 +69660,7 @@ Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 114): +Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) @@ -66805,12 +69678,12 @@ Entering state 4 Stack now 0 8 21 4 Reading a token -Next token is token "number" (1.7: 1) -Shifting token "number" (1.7: 1) +Next token is token number (1.7: 1) +Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.7: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 @@ -66820,18 +69693,18 @@ Entering state 21 Stack now 0 8 21 4 12 21 Reading a token -Next token is token "number" (1.11: 1) -Shifting token "number" (1.11: 1) +Next token is token number (1.11: 1) +Shifting token number (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.11: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 99): +Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) @@ -66843,18 +69716,18 @@ Entering state 21 Stack now 0 8 21 4 12 21 Reading a token -Next token is token "number" (1.15: 1) -Shifting token "number" (1.15: 1) +Next token is token number (1.15: 1) +Shifting token number (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.15: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) -Reducing stack by rule 7 (line 99): +Reducing stack by rule 7 (line 112): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) @@ -66879,7 +69752,7 @@ Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): +Reducing stack by rule 14 (line 127): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) @@ -66888,7 +69761,7 @@ Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) -Reducing stack by rule 7 (line 99): +Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) @@ -66938,7 +69811,7 @@ Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): +Reducing stack by rule 14 (line 127): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) @@ -66947,7 +69820,7 @@ Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) -Reducing stack by rule 7 (line 99): +Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) @@ -66964,12 +69837,12 @@ Entering state 4 Stack now 0 8 21 4 Reading a token -Next token is token "number" (1.33: 1) -Shifting token "number" (1.33: 1) +Next token is token number (1.33: 1) +Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.33: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 @@ -66979,18 +69852,18 @@ Entering state 22 Stack now 0 8 21 4 12 22 Reading a token -Next token is token "number" (1.37: 2) -Shifting token "number" (1.37: 2) +Next token is token number (1.37: 2) +Shifting token number (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.37: 2) +Reducing stack by rule 5 (line 101): + $1 = token number (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) -Reducing stack by rule 9 (line 101): +Reducing stack by rule 9 (line 114): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) @@ -67023,7 +69896,7 @@ Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): +Reducing stack by rule 14 (line 127): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) @@ -67032,7 +69905,7 @@ Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) -Reducing stack by rule 7 (line 99): +Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) @@ -67044,18 +69917,18 @@ Entering state 19 Stack now 0 8 19 Reading a token -Next token is token "number" (1.46: 1) -Shifting token "number" (1.46: 1) +Next token is token number (1.46: 1) +Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.46: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) -Reducing stack by rule 6 (line 89): +Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) @@ -67067,26 +69940,28 @@ Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 84): +Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 78): +Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) +Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1367: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +./calc.at:1370: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +stderr: Starting parse Entering state 0 Stack now 0 @@ -67227,136 +70102,16 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 19 -Error: popping token '=' (1.3: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) -Stack now 0 -./calc.at:1355: cat stderr -stderr: -./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Stack now 0 8 21 5 13 -Reducing stack by rule 18 (line 131): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -stderr: -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -input: -stderr: +./calc.at:1355: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Stack now 0 @@ -67365,317 +70120,216 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 +Return for a new token: Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Return for a new token: +Reading a token +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Return for a new token: +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 114): +Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 +Return for a new token: Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token "number" (1.7: 1) -Shifting token "number" (1.7: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Reading a token -Next token is token "number" (1.11: 1) -Shifting token "number" (1.11: 1) -Entering state 1 -Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.11: 1) --> $$ = nterm exp (1.11: 1) -Entering state 30 -Stack now 0 8 21 4 12 21 30 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Reading a token -Next token is token "number" (1.15: 1) -Shifting token "number" (1.15: 1) -Entering state 1 -Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 30 -Stack now 0 8 21 4 12 21 30 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.7-15: 3) -Stack now 0 8 21 4 -Shifting token error (1.7-18: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '+' (1.20: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 +Return for a new token: Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 +Return for a new token: Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Error: popping token error (1.23: ) -Stack now 0 8 21 4 -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Error: popping token error (1.23: ) -Stack now 0 8 21 4 -Shifting token error (1.23-25: ) +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 -Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) -Error: popping token error (1.23-25: ) +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) +Error: popping token error (1.10: ) Stack now 0 8 21 4 -Shifting token error (1.23-27: ) +Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 +Return for a new token: Reading a token -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 +Return for a new token: Reading a token -Next token is token '+' (1.30: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 +Return for a new token: Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 +Return for a new token: Reading a token -Next token is token "number" (1.33: 1) -Shifting token "number" (1.33: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 22 -Stack now 0 8 21 4 12 22 -Reading a token -Next token is token "number" (1.37: 2) -Shifting token "number" (1.37: 2) -Entering state 1 -Stack now 0 8 21 4 12 22 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 31 -Stack now 0 8 21 4 12 22 31 -Reading a token -Next token is token '*' (1.39: ) -Reducing stack by rule 9 (line 101): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 22 -Stack now 0 8 21 4 12 22 -Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.33-37: 2) -Stack now 0 8 21 4 -Shifting token error (1.33-41: ) +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Error: popping token error (1.33-41: ) +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) +Error: popping token error (1.16: ) Stack now 0 8 21 4 -Shifting token error (1.33-41: ) +Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 +Return for a new token: Reading a token -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 +Return for a new token: Reading a token -Next token is token '=' (1.44: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.46: 1) -Shifting token "number" (1.46: 1) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.46: 1) --> $$ = nterm exp (1.46: 1) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.47-2.0: ) -Reducing stack by rule 6 (line 89): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 78): +Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) +Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | (!!) + (1 2) = 1 -./calc.at:1358: $PREPARSER ./calc input +./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1364: cat stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Stack now 0 8 23 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '/' (1.3: ) +Stack now 0 +./calc.at:1369: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +./calc.at:1362: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1355: cat stderr +./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1367: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c + stderr: Starting parse Entering state 0 @@ -67687,131 +70341,143 @@ Stack now 0 4 Return for a new token: Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Stack now 0 4 5 +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 Return for a new token: Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 16 -Stack now 0 4 5 16 -Reducing stack by rule 16 (line 129): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2: ) Stack now 0 4 -Shifting token error (1.2-3: ) +Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Return for a new token: Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Return for a new token: Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 Return for a new token: Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 Return for a new token: Reading a token -Next token is token number (1.9: 1) -Shifting token number (1.9: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 1) --> $$ = nterm exp (1.9: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Return for a new token: -Reading a token -Next token is token number (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Stack now 0 8 21 4 -Shifting token error (1.9-11: ) +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 -Next token is token number (1.11: 2) -Error: discarding token number (1.11: 2) -Error: popping token error (1.9-11: ) +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) +Error: popping token error (1.10: ) Stack now 0 8 21 4 -Shifting token error (1.9-11: ) +Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Return for a new token: Reading a token -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Return for a new token: Reading a token -Next token is token '=' (1.14: ) +Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) -Entering state 19 -Stack now 0 8 19 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Stack now 0 8 21 Return for a new token: Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 28 -Stack now 0 8 19 28 +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 +Stack now 0 8 21 4 Return for a new token: Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) +Error: popping token error (1.16: ) +Stack now 0 8 21 4 +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 21 4 11 +Return for a new token: +Reading a token +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 30 +Stack now 0 8 21 30 +Return for a new token: +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -67829,45 +70495,11 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 83): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) -Stack now 0 -./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1363: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +486. calc.at:1355: ok +./calc.at:1362: cat stderr +input: stderr: -./calc.at:1367: cat stderr +input: Starting parse Entering state 0 Stack now 0 @@ -67876,13 +70508,11 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 -Return for a new token: Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 Stack now 0 4 5 -Return for a new token: Reading a token Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) @@ -67895,7 +70525,6 @@ Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 -Return for a new token: Reading a token Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) @@ -67908,19 +70537,16 @@ -> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 -Return for a new token: Reading a token Next token is token '+' (1.6: ) Shifting token '+' (1.6: ) Entering state 21 Stack now 0 8 21 -Return for a new token: Reading a token Next token is token '(' (1.8: ) Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 21 4 -Return for a new token: Reading a token Next token is token number (1.9: 1) Shifting token number (1.9: 1) @@ -67931,7 +70557,6 @@ -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 -Return for a new token: Reading a token Next token is token number (1.11: 2) 1.11: syntax error, unexpected number @@ -67947,7 +70572,6 @@ Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 -Return for a new token: Reading a token Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) @@ -67960,7 +70584,6 @@ -> $$ = nterm exp (1.8-12: 1111) Entering state 30 Stack now 0 8 21 30 -Return for a new token: Reading a token Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 112): @@ -67974,7 +70597,6 @@ Shifting token '=' (1.14: ) Entering state 19 Stack now 0 8 19 -Return for a new token: Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) @@ -67985,7 +70607,6 @@ -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 -Return for a new token: Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 102): @@ -68011,7 +70632,6 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -68020,8 +70640,21 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -input: -./calc.at:1362: "$PERL" -pi -e 'use strict; + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1367: $PREPARSER ./calc input +./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -68031,36 +70664,37 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1363: cat stderr - | (# + 1) = 1111 + | error +./calc.at:1364: $PREPARSER ./calc input stderr: +./calc.at:1358: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1370: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: +input: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 83): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) +Next token is token "invalid token" (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 -./calc.at:1357: "$PERL" -pi -e 'use strict; +./calc.at:1363: cat stderr + | (!!) + (1 2) = 1 +./calc.at:1362: $PREPARSER ./calc input +./calc.at:1358: cat stderr +stderr: +./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -68070,7 +70704,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1355: $PREPARSER ./calc input +stderr: + +./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1367: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 @@ -68211,133 +70848,114 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: -./calc.at:1358: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: input: -./calc.at:1357: cat stderr +stderr: + | 1 + 2 * 3 + !+ ++ +./calc.at:1358: $PREPARSER ./calc input +./calc.at:1360: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1.6: 1) -Error: discarding token number (1.6: 1) -Error: popping token error (1.2-4: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 +Next token is token "invalid token" (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" (1.1: ) +Stack now 0 +stderr: +stderr: + | error +./calc.at:1363: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 +Return for a new token: Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Stack now 0 8 19 +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 +Return for a new token: Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 -Stack now 0 8 19 1 +Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Stack now 0 8 19 28 + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 +Return for a new token: Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Return for a new token: +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Return for a new token: +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 +Return for a new token: Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - | (!!) + (1 2) = 1 -./calc.at:1363: $PREPARSER ./calc input - | 1 + 2 * 3 + !+ ++ -./calc.at:1367: $PREPARSER ./calc input -./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1362: cat stderr -./calc.at:1358: cat stderr -./calc.at:1364: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Return for a new token: +Reading a token +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Stack now 0 8 21 5 14 +Reducing stack by rule 17 (line 130): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: stderr: Starting parse Entering state 0 @@ -68357,7 +70975,7 @@ Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 -Reducing stack by rule 16 (line 116): +Reducing stack by rule 16 (line 129): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 @@ -68369,7 +70987,7 @@ Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 114): +Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) @@ -68387,25 +71005,25 @@ Entering state 4 Stack now 0 8 21 4 Reading a token -Next token is token "number" (1.9: 1) -Shifting token "number" (1.9: 1) +Next token is token number (1.9: 1) +Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.9: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token -Next token is token "number" (1.11: 2) +Next token is token number (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 -Next token is token "number" (1.11: 2) -Error: discarding token "number" (1.11: 2) +Next token is token number (1.11: 2) +Error: discarding token number (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) @@ -68416,7 +71034,7 @@ Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): +Reducing stack by rule 14 (line 127): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) @@ -68425,7 +71043,7 @@ Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) -Reducing stack by rule 7 (line 99): +Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) @@ -68437,18 +71055,18 @@ Entering state 19 Stack now 0 8 19 Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.16: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 89): +Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) @@ -68460,138 +71078,35 @@ Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 84): +Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 78): +Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) +Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1360: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1.6: 1) -Error: discarding token number (1.6: 1) -Error: popping token error (1.2-4: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -input: -./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: - | (- *) + (1 2) = 1 -./calc.at:1355: "$PERL" -pi -e 'use strict; +Next token is token "invalid token" (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" (1.1: ) +Stack now 0 + | 1 2 +./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -68601,161 +71116,108 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1358: $PREPARSER ./calc input +./calc.at:1367: $PREPARSER ./calc input +input: + | (- *) + (1 2) = 1 +./calc.at:1360: $PREPARSER ./calc input +./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Stack now 0 4 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 16 -Stack now 0 4 5 16 -Reducing stack by rule 16 (line 116): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Stack now 0 4 -Shifting token error (1.2-3: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 +Return for a new token: Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 +Return for a new token: Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token "number" (1.9: 1) -Shifting token "number" (1.9: 1) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.9: 1) --> $$ = nterm exp (1.9: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token "number" (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Stack now 0 8 21 4 -Shifting token error (1.9-11: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token "number" (1.11: 2) -Error: discarding token "number" (1.11: 2) -Error: popping token error (1.9-11: ) -Stack now 0 8 21 4 -Shifting token error (1.9-11: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 +Return for a new token: Reading a token -Next token is token '=' (1.14: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) -Entering state 19 -Stack now 0 8 19 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Return for a new token: Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 28 -Stack now 0 8 19 28 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Return for a new token: Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 89): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 +Return for a new token: Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Return for a new token: +Reading a token +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Stack now 0 8 21 5 14 +Reducing stack by rule 17 (line 130): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +497. calc.at:1371: testing Calculator parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} api.push-pull=both api.pure=full parse.lac=full ... +./calc.at:1371: mv calc.y.tmp calc.y + +./calc.at:1358: $EGREP -c -v 'Return for a new token:|LAC:' stderr +syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) +./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1364: cat stderr -./calc.at:1363: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1360: cat stderr -stderr: -stderr: Starting parse Entering state 0 Stack now 0 @@ -68764,13 +71226,11 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 -Return for a new token: Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 -Return for a new token: Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' @@ -68791,7 +71251,6 @@ Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 -Return for a new token: Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) @@ -68804,19 +71263,16 @@ -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 -Return for a new token: Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 -Return for a new token: Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 -Return for a new token: Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) @@ -68827,7 +71283,6 @@ -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 -Return for a new token: Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number @@ -68843,7 +71298,6 @@ Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 -Return for a new token: Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) @@ -68856,7 +71310,6 @@ -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 -Return for a new token: Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): @@ -68870,7 +71323,6 @@ Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 -Return for a new token: Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) @@ -68881,7 +71333,6 @@ -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 -Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): @@ -68907,7 +71358,6 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -68916,251 +71366,46 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | 1 + 2 * 3 + !* ++ -./calc.at:1357: $PREPARSER ./calc input -./calc.at:1363: cat stderr -./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: -./calc.at:1367: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1355: cat stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Stack now 0 8 21 5 15 -Reducing stack by rule 19 (line 132): - $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) - | - | +1 -./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1364: $PREPARSER ./calc /dev/null -./calc.at:1362: $PREPARSER ./calc input -input: +./calc.at:1371: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: -input: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 96): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) +Next token is token "invalid token" (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" (1.1: ) Stack now 0 - | 1 + 2 * 3 + !- ++ -./calc.at:1367: $PREPARSER ./calc input - | (1 + # + 1) = 1111 -./calc.at:1355: $PREPARSER ./calc input +./calc.at:1362: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 -Reading a token -1.6: syntax error: invalid character: '#' -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-8: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1.10: 1) -Error: discarding token number (1.10: 1) -Error: popping token error (1.2-8: ) -Stack now 0 4 -Shifting token error (1.2-10: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.15-18: 1111) -Shifting token number (1.15-18: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.19-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -stderr: -./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) +input: +./calc.at:1363: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | 1 + 2 * 3 + !- ++ +./calc.at:1358: $PREPARSER ./calc input + | 1 = 2 = 3 +./calc.at:1364: $PREPARSER ./calc input +./calc.at:1362: cat stderr stderr: stderr: stderr: @@ -69172,13 +71417,11 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 -Return for a new token: Reading a token Next token is token '-' (1.2: ) Shifting token '-' (1.2: ) Entering state 2 Stack now 0 4 2 -Return for a new token: Reading a token Next token is token '*' (1.4: ) 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' @@ -69199,7 +71442,6 @@ Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 -Return for a new token: Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) @@ -69212,19 +71454,16 @@ -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 -Return for a new token: Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 -Return for a new token: Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 -Return for a new token: Reading a token Next token is token number (1.10: 1) Shifting token number (1.10: 1) @@ -69235,7 +71474,6 @@ -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 -Return for a new token: Reading a token Next token is token number (1.12: 2) 1.12: syntax error, unexpected number @@ -69251,7 +71489,6 @@ Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 -Return for a new token: Reading a token Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) @@ -69264,7 +71501,6 @@ -> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 -Return for a new token: Reading a token Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 112): @@ -69278,7 +71514,6 @@ Shifting token '=' (1.15: ) Entering state 19 Stack now 0 8 19 -Return for a new token: Reading a token Next token is token number (1.17: 1) Shifting token number (1.17: 1) @@ -69289,7 +71524,6 @@ -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 -Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 102): @@ -69315,7 +71549,6 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -69324,157 +71557,45 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" (1.1: ) -Stack now 0 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 96): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) -Stack now 0 Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 -Reading a token -1.6: syntax error: invalid character: '#' -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-8: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1.10: 1) -Error: discarding token number (1.10: 1) -Error: popping token error (1.2-8: ) -Stack now 0 4 -Shifting token error (1.2-10: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 139): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) +Stack now 0 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.15-18: 1111) -Shifting token number (1.15-18: 1111) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.19-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) -Entering state 8 +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 19 +Error: popping token '=' (1.3: ) Stack now 0 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -stderr: -stderr: +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 Starting parse Entering state 0 Stack now 0 @@ -69488,11 +71609,13 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 +Return for a new token: Reading a token Next token is token '+' (1.3: ) Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 +Return for a new token: Reading a token Next token is token number (1.5: 2) Shifting token number (1.5: 2) @@ -69503,11 +71626,13 @@ -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 +Return for a new token: Reading a token Next token is token '*' (1.7: ) Shifting token '*' (1.7: ) Entering state 22 Stack now 0 8 21 30 22 +Return for a new token: Reading a token Next token is token number (1.9: 3) Shifting token number (1.9: 3) @@ -69518,6 +71643,7 @@ -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 +Return for a new token: Reading a token Next token is token '+' (1.11: ) Reducing stack by rule 9 (line 114): @@ -69539,30 +71665,33 @@ Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 +Return for a new token: Reading a token Next token is token '!' (1.13: ) Shifting token '!' (1.13: ) Entering state 5 Stack now 0 8 21 5 +Return for a new token: Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Stack now 0 8 21 5 15 -Reducing stack by rule 19 (line 132): +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Stack now 0 8 21 5 13 +Reducing stack by rule 18 (line 131): $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted + $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1363: cat stderr +./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 - | (- *) + (1 2) = 1 -./calc.at:1363: $PREPARSER ./calc input -./calc.at:1360: $PREPARSER ./calc input -./calc.at:1355: "$PERL" -pi -e 'use strict; +./calc.at:1362: $PREPARSER ./calc input +./calc.at:1367: cat stderr +stderr: +./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -69573,155 +71702,137 @@ }eg ' expout || exit 77 stderr: -stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Stack now 0 4 2 -Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 128): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2-4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 +Return for a new token: Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 +Return for a new token: Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 -Stack now 0 8 21 4 1 +Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Stack now 0 8 21 4 12 + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 +Return for a new token: Reading a token -Next token is token number (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Stack now 0 8 21 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token number (1.12: 2) -Error: discarding token number (1.12: 2) -Error: popping token error (1.10-12: ) -Stack now 0 8 21 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 21 4 11 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Return for a new token: Reading a token -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Return for a new token: +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.15: ) +Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 +Return for a new token: +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Return for a new token: +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Stack now 0 8 21 5 13 +Reducing stack by rule 18 (line 131): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +input: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.17: 1) --> $$ = nterm exp (1.17: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) -Entering state 8 +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 19 +Error: popping token '=' (1.3: ) Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 +stderr: +./calc.at:1360: cat stderr + | 1 = 2 = 3 +./calc.at:1363: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -69741,7 +71852,7 @@ Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 -Reducing stack by rule 15 (line 115): +Reducing stack by rule 15 (line 128): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 @@ -69760,7 +71871,7 @@ Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 114): +Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) @@ -69778,25 +71889,25 @@ Entering state 4 Stack now 0 8 21 4 Reading a token -Next token is token "number" (1.10: 1) -Shifting token "number" (1.10: 1) +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.10: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token -Next token is token "number" (1.12: 2) +Next token is token number (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 -Next token is token "number" (1.12: 2) -Error: discarding token "number" (1.12: 2) +Next token is token number (1.12: 2) +Error: discarding token number (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) @@ -69807,7 +71918,7 @@ Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): +Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) @@ -69816,7 +71927,7 @@ Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) -Reducing stack by rule 7 (line 99): +Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) @@ -69828,18 +71939,18 @@ Entering state 19 Stack now 0 8 19 Reading a token -Next token is token "number" (1.17: 1) -Shifting token "number" (1.17: 1) +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.17: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 6 (line 89): +Reducing stack by rule 6 (line 102): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) @@ -69851,25 +71962,27 @@ Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 84): +Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 78): +Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) +Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1371: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +stderr: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -69881,33 +71994,52 @@ }eg ' expout || exit 77 stderr: -./calc.at:1355: cat stderr -./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +stdout: +./calc.at:1368: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' + | 1//2 +./calc.at:1367: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token -Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" (1.1: ) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 19 +Error: popping token '=' (1.3: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) Stack now 0 -./calc.at:1362: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: - | (1 + 1) / (1 - 1) -./calc.at:1358: cat stderr -stderr: -./calc.at:1355: $PREPARSER ./calc input -./calc.at:1357: "$PERL" -pi -e 'use strict; +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 +./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -69919,149 +72051,20 @@ ' expout || exit 77 stderr: stderr: -./calc.at:1367: cat stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 -Reading a token -Next token is token number (1.6: 1) -Shifting token number (1.6: 1) -Entering state 1 -Stack now 0 4 12 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 30 -Stack now 0 4 12 21 30 -Reading a token -Next token is token ')' (1.7: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Stack now 0 4 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 27 -Stack now 0 4 12 27 -Reducing stack by rule 13 (line 138): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 23 -Stack now 0 8 23 -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Stack now 0 8 23 4 -Reading a token -Next token is token number (1.12: 1) -Shifting token number (1.12: 1) -Entering state 1 -Stack now 0 8 23 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Stack now 0 8 23 4 12 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 20 -Stack now 0 8 23 4 12 20 -Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) -Entering state 1 -Stack now 0 8 23 4 12 20 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 29 -Stack now 0 8 23 4 12 20 29 -Reading a token -Next token is token ')' (1.17: ) -Reducing stack by rule 8 (line 119): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Stack now 0 8 23 4 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 27 -Stack now 0 8 23 4 12 27 -Reducing stack by rule 13 (line 138): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 32 -Stack now 0 8 23 32 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 10 (line 121): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) +./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1368: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c + Starting parse Entering state 0 Stack now 0 @@ -70210,6 +72213,14 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) + | (* *) + (*) + (*) +./calc.at:1358: cat stderr +./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1364: cat stderr +./calc.at:1360: $PREPARSER ./calc input +input: +stderr: +stderr: Starting parse Entering state 0 Stack now 0 @@ -70219,26 +72230,22 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Stack now 0 4 2 -Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 115): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) +Error: popping token error (1.2: ) Stack now 0 4 -Shifting token error (1.2-4: ) +Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 +Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) -Error: popping token error (1.2-4: ) +Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 @@ -70248,7 +72255,7 @@ Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 114): +Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) @@ -70266,247 +72273,299 @@ Entering state 4 Stack now 0 8 21 4 Reading a token -Next token is token "number" (1.10: 1) -Shifting token "number" (1.10: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token "number" (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Stack now 0 8 21 4 -Shifting token error (1.10-12: ) +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 -Next token is token "number" (1.12: 2) -Error: discarding token "number" (1.12: 2) -Error: popping token error (1.10-12: ) +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) +Error: popping token error (1.10: ) Stack now 0 8 21 4 -Shifting token error (1.10-12: ) +Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): +Reducing stack by rule 14 (line 127): $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token -Next token is token '=' (1.15: ) -Reducing stack by rule 7 (line 99): +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 112): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) -Entering state 19 -Stack now 0 8 19 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token "number" (1.17: 1) -Shifting token "number" (1.17: 1) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.17: 1) --> $$ = nterm exp (1.17: 1) -Entering state 28 -Stack now 0 8 19 28 +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) +Error: popping token error (1.16: ) +Stack now 0 8 21 4 +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 30 +Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 6 (line 89): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-17: 2222) +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 78): +Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) +Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) +input: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1368: $PREPARSER ./calc input stderr: -./calc.at:1357: cat stderr + | 1 + 2 * 3 + !* ++ +./calc.at:1358: $PREPARSER ./calc input +./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 28 +Stack now 0 8 19 28 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 19 +Error: popping token '=' (1.3: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 +./calc.at:1362: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +stderr: +input: +stderr: +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token number (1.6: 1) -Shifting token number (1.6: 1) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 4 12 21 1 +Stack now 0 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 30 -Stack now 0 4 12 21 30 -Reading a token -Next token is token ')' (1.7: ) -Reducing stack by rule 7 (line 118): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Stack now 0 4 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 27 -Stack now 0 4 12 27 -Reducing stack by rule 13 (line 138): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 +Return for a new token: Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 23 -Stack now 0 8 23 -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Stack now 0 8 23 4 +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 +Return for a new token: Reading a token -Next token is token number (1.12: 1) -Shifting token number (1.12: 1) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 -Stack now 0 8 23 4 1 +Stack now 0 8 21 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Stack now 0 8 23 4 12 + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 +Return for a new token: Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 20 -Stack now 0 8 23 4 12 20 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Return for a new token: Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) Entering state 1 -Stack now 0 8 23 4 12 20 1 +Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 29 -Stack now 0 8 23 4 12 20 29 -Reading a token -Next token is token ')' (1.17: ) -Reducing stack by rule 8 (line 119): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Stack now 0 8 23 4 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 27 -Stack now 0 8 23 4 12 27 -Reducing stack by rule 13 (line 138): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 32 -Stack now 0 8 23 32 + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Return for a new token: Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 10 (line 121): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 +Return for a new token: +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Return for a new token: +Reading a token +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Stack now 0 8 21 5 15 +Reducing stack by rule 19 (line 132): + $1 = token '!' (1.13: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) + | + | +1 +./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1364: $PREPARSER ./calc input +stderr: +stdout: +./calc.at:1362: cat stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 83): + $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): +Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1362: cat stderr -input: - | (* *) + (*) + (*) -./calc.at:1358: $PREPARSER ./calc input -input: -./calc.at:1364: "$PERL" -pi -e 'use strict; +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Stack now 0 +Cleanup: discarding lookahead token '+' (2.1: ) +Stack now 0 +./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -70516,9 +72575,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (#) + (#) = 2222 stderr: -./calc.at:1357: $PREPARSER ./calc input +./calc.at:1369: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' Starting parse Entering state 0 Stack now 0 @@ -70527,7 +72585,6 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 -Return for a new token: Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' @@ -70541,7 +72598,6 @@ Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 -Return for a new token: Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) @@ -70550,7 +72606,6 @@ Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 -Return for a new token: Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) @@ -70563,19 +72618,16 @@ -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 -Return for a new token: Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 -Return for a new token: Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 -Return for a new token: Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' @@ -70589,7 +72641,6 @@ Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 -Return for a new token: Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) @@ -70602,7 +72653,6 @@ -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 -Return for a new token: Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): @@ -70616,13 +72666,11 @@ Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 -Return for a new token: Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 -Return for a new token: Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' @@ -70636,7 +72684,6 @@ Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 -Return for a new token: Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) @@ -70649,7 +72696,6 @@ -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 -Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): @@ -70674,7 +72720,6 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -70683,165 +72728,115 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1363: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1362: $PREPARSER ./calc /dev/null -./calc.at:1360: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 stderr: -input: +./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1363: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 +Return for a new token: Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 +Return for a new token: Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -1.8: syntax error: invalid character: '#' -Shifting token error (1.8: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token invalid token (1.8: ) -Error: discarding token invalid token (1.8: ) -Error: popping token error (1.8: ) -Stack now 0 8 21 4 -Shifting token error (1.8: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 +Return for a new token: Reading a token -Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 19 -Stack now 0 8 19 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Return for a new token: Reading a token -Next token is token number (1.13-16: 2222) -Shifting token number (1.13-16: 2222) +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) Entering state 1 -Stack now 0 8 19 1 +Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 28 -Stack now 0 8 19 28 + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Return for a new token: Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 +Return for a new token: Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Return for a new token: +Reading a token +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Stack now 0 8 21 5 15 +Reducing stack by rule 19 (line 132): + $1 = token '!' (1.13: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1367: cat stderr +./calc.at:1369: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c + +input: stderr: - | 1 + 2 * 3 + !* ++ + | (* *) + (*) + (*) +./calc.at:1362: $PREPARSER ./calc input stderr: -./calc.at:1367: $PREPARSER ./calc input -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Now at end of input. -1.1: syntax error, unexpected end of file -Cleanup: discarding lookahead token end of file (1.1: ) -Stack now 0 -./calc.at:1363: cat stderr -./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -70850,7 +72845,6 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 -Return for a new token: Reading a token Next token is token '*' (1.2: ) 1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' @@ -70864,7 +72858,6 @@ Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 -Return for a new token: Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) @@ -70873,7 +72866,6 @@ Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 -Return for a new token: Reading a token Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) @@ -70886,19 +72878,16 @@ -> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 -Return for a new token: Reading a token Next token is token '+' (1.7: ) Shifting token '+' (1.7: ) Entering state 21 Stack now 0 8 21 -Return for a new token: Reading a token Next token is token '(' (1.9: ) Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 21 4 -Return for a new token: Reading a token Next token is token '*' (1.10: ) 1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' @@ -70912,7 +72901,6 @@ Shifting token error (1.10: ) Entering state 11 Stack now 0 8 21 4 11 -Return for a new token: Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) @@ -70925,7 +72913,6 @@ -> $$ = nterm exp (1.9-11: 1111) Entering state 30 Stack now 0 8 21 30 -Return for a new token: Reading a token Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 112): @@ -70939,13 +72926,11 @@ Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 -Return for a new token: Reading a token Next token is token '(' (1.15: ) Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 -Return for a new token: Reading a token Next token is token '*' (1.16: ) 1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' @@ -70959,7 +72944,6 @@ Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 -Return for a new token: Reading a token Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) @@ -70972,7 +72956,6 @@ -> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 -Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 7 (line 112): @@ -70997,7 +72980,6 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -71006,136 +72988,34 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1360: cat stderr -stderr: -memory exhausted -./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -1.8: syntax error: invalid character: '#' -Shifting token error (1.8: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token invalid token (1.8: ) -Error: discarding token invalid token (1.8: ) -Error: popping token error (1.8: ) -Stack now 0 8 21 4 -Shifting token error (1.8: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.13-16: 2222) -Shifting token number (1.13-16: 2222) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 83): + $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): +Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -stdout: +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Stack now 0 +Cleanup: discarding lookahead token '+' (2.1: ) +Stack now 0 stderr: -./calc.at:1355: "$PERL" -pi -e 'use strict; +./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -71145,25 +73025,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -memory exhausted input: -./calc.at:1368: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -stderr: - | (* *) + (*) + (*) input: -./calc.at:1364: cat stderr -./calc.at:1363: $PREPARSER ./calc input -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Now at end of input. -1.1: syntax error, unexpected end of file -Cleanup: discarding lookahead token end of file (1.1: ) -Stack now 0 - | (* *) + (*) + (*) -./calc.at:1360: $PREPARSER ./calc input +stderr: ./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -71174,32 +73038,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1368: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c - -./calc.at:1358: cat stderr -input: -./calc.at:1357: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -./calc.at:1367: cat stderr -stderr: + | error +./calc.at:1367: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -71213,10 +73053,16 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1368: $PREPARSER ./calc input +./calc.at:1368: $EGREP -c -v 'Return for a new token:|LAC:' stderr +input: +./calc.at:1369: $PREPARSER ./calc input stderr: -./calc.at:1364: $PREPARSER ./calc input +syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | + | +1 +./calc.at:1363: $PREPARSER ./calc input +./calc.at:1360: cat stderr Starting parse Entering state 0 Stack now 0 @@ -71368,319 +73214,343 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1357: cat stderr -./calc.at:1355: cat stderr -stderr: -./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 83): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Stack now 0 +Cleanup: discarding lookahead token '+' (2.1: ) +Stack now 0 stderr: - | (1 + #) = 1111 + | 1 + 2 * 3 + !+ ++ +./calc.at:1360: $PREPARSER ./calc input +input: +./calc.at:1358: cat stderr +./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1364: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -./calc.at:1357: $PREPARSER ./calc input + | 1 2 +./calc.at:1368: $PREPARSER ./calc input +stderr: +./calc.at:1362: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1369: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token "number" (1.7: 1) -Shifting token "number" (1.7: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 21 -Stack now 0 8 21 4 12 21 -Reading a token -Next token is token "number" (1.11: 1) -Shifting token "number" (1.11: 1) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 -Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.11: 1) --> $$ = nterm exp (1.11: 1) +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 30 -Stack now 0 8 21 4 12 21 30 +Stack now 0 8 21 30 Reading a token -Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Stack now 0 8 21 4 12 21 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 Reading a token -Next token is token "number" (1.15: 1) -Shifting token "number" (1.15: 1) +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) Entering state 1 -Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.15: 1) --> $$ = nterm exp (1.15: 1) +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) Entering state 30 -Stack now 0 8 21 4 12 21 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token '+' (1.17: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 21 -Stack now 0 8 21 4 12 21 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.7-15: 3) -Stack now 0 8 21 4 -Shifting token error (1.7-18: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) -Entering state 30 -Stack now 0 8 21 30 +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Stack now 0 8 21 5 14 +Reducing stack by rule 17 (line 130): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) +stderr: +input: +1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) +./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (#) + (#) = 2222 +./calc.at:1358: $PREPARSER ./calc input +input: +./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1362: cat stderr +stderr: + | 1 2 +./calc.at:1369: $PREPARSER ./calc input +./calc.at:1364: cat stderr +stderr: +1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) +stderr: +1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) +stderr: +./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | 1 + 2 * 3 + !+ ++ +./calc.at:1362: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token '+' (1.20: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Error: popping token error (1.23: ) -Stack now 0 8 21 4 -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 21 4 11 +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Error: popping token error (1.23: ) -Stack now 0 8 21 4 -Shifting token error (1.23-25: ) -Entering state 11 -Stack now 0 8 21 4 11 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) -Error: popping token error (1.23-25: ) -Stack now 0 8 21 4 -Shifting token error (1.23-27: ) -Entering state 11 -Stack now 0 8 21 4 11 +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 Reading a token -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 -Reading a token -Next token is token '+' (1.30: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) -Entering state 4 -Stack now 0 8 21 4 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 Reading a token -Next token is token "number" (1.33: 1) -Shifting token "number" (1.33: 1) +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Stack now 0 8 21 5 14 +Reducing stack by rule 17 (line 130): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1360: $EGREP -c -v 'Return for a new token:|LAC:' stderr +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Stack now 0 8 21 4 12 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 22 -Stack now 0 8 21 4 12 22 +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token "number" (1.37: 2) -Shifting token "number" (1.37: 2) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 -Stack now 0 8 21 4 12 22 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 31 -Stack now 0 8 21 4 12 22 31 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 Reading a token -Next token is token '*' (1.39: ) -Reducing stack by rule 9 (line 101): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) -Entering state 12 -Stack now 0 8 21 4 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) Entering state 22 -Stack now 0 8 21 4 12 22 +Stack now 0 8 21 30 22 Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Stack now 0 8 21 4 12 -Error: popping nterm exp (1.33-37: 2) -Stack now 0 8 21 4 -Shifting token error (1.33-41: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Error: popping token error (1.33-41: ) -Stack now 0 8 21 4 -Shifting token error (1.33-41: ) -Entering state 11 -Stack now 0 8 21 4 11 +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 Reading a token -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) Entering state 30 Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.44: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) -Entering state 19 -Stack now 0 8 19 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token "number" (1.46: 1) -Shifting token "number" (1.46: 1) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.46: 1) --> $$ = nterm exp (1.46: 1) -Entering state 28 -Stack now 0 8 19 28 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 Reading a token -Next token is token '\n' (1.47-2.0: ) -Reducing stack by rule 6 (line 89): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Stack now 0 8 21 5 14 +Reducing stack by rule 17 (line 130): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 83): + $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -71690,13 +73560,12 @@ Entering state 6 Stack now 0 6 Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Stack now 0 +Cleanup: discarding lookahead token '+' (2.1: ) +Stack now 0 Starting parse Entering state 0 Stack now 0 @@ -71705,133 +73574,112 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 +Return for a new token: +1.2: syntax error: invalid character: '#' Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 +Return for a new token: Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 +Return for a new token: Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 +Return for a new token: Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 +Return for a new token: +1.8: syntax error: invalid character: '#' Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) +Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) -Error: popping token error (1.10: ) +Next token is token invalid token (1.8: ) +Error: discarding token invalid token (1.8: ) +Error: popping token error (1.8: ) Stack now 0 8 21 4 -Shifting token error (1.10: ) +Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 +Return for a new token: Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 127): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 +Return for a new token: Reading a token -Next token is token '+' (1.13: ) +Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) -Error: popping token error (1.16: ) -Stack now 0 8 21 4 -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 21 4 11 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 19 +Stack now 0 8 19 +Return for a new token: Reading a token -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 30 -Stack now 0 8 21 30 +Next token is token number (1.13-16: 2222) +Shifting token number (1.13-16: 2222) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) +Entering state 28 +Stack now 0 8 19 28 +Return for a new token: Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) +Next token is token '\n' (1.17-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -71840,6 +73688,7 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -71848,7 +73697,93 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -486. calc.at:1355: ok +./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1367: cat stderr +stderr: +stderr: +./calc.at:1364: $PREPARSER ./calc /dev/null +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Stack now 0 8 21 5 14 +Reducing stack by rule 17 (line 130): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +input: +./calc.at:1362: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: Starting parse Entering state 0 @@ -71858,149 +73793,544 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 +Return for a new token: +1.2: syntax error: invalid character: '#' Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 +Return for a new token: Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 114): +Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 +Return for a new token: Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 +Return for a new token: Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 21 4 +Return for a new token: +1.8: syntax error: invalid character: '#' Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) +Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) -Error: popping token error (1.10: ) +Next token is token invalid token (1.8: ) +Error: discarding token invalid token (1.8: ) +Error: popping token error (1.8: ) Stack now 0 8 21 4 -Shifting token error (1.10: ) +Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 +Return for a new token: Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 +Return for a new token: Reading a token -Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) +Next token is token '=' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) -Error: popping token error (1.16: ) -Stack now 0 8 21 4 -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 21 4 11 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 19 +Stack now 0 8 19 +Return for a new token: Reading a token -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 30 -Stack now 0 8 21 30 +Next token is token number (1.13-16: 2222) +Shifting token number (1.13-16: 2222) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) +Entering state 28 +Stack now 0 8 19 28 +Return for a new token: Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) +Next token is token '\n' (1.17-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 78): +Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) +Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1368: cat stderr +1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) +stderr: + | 1 + 2 * 3 + !- ++ +./calc.at:1360: $PREPARSER ./calc input +input: + | 1 + 2 * 3 + !- ++ +./calc.at:1362: $PREPARSER ./calc input +./calc.at:1363: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Now at end of input. +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token "end of input" (1.1: ) +Stack now 0 +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Stack now 0 8 21 5 13 +Reducing stack by rule 18 (line 131): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1369: cat stderr +input: +./calc.at:1358: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1363: cat stderr +./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 = 2 = 3 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Stack now 0 8 21 5 13 +Reducing stack by rule 18 (line 131): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1//2 +./calc.at:1368: $PREPARSER ./calc input +./calc.at:1367: $PREPARSER ./calc input +stderr: +./calc.at:1358: cat stderr +stderr: +./calc.at:1363: $PREPARSER ./calc /dev/null +./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +stderr: +syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) +./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) +./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Stack now 0 8 21 5 13 +Reducing stack by rule 18 (line 131): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Now at end of input. +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token "end of input" (1.1: ) +Stack now 0 +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Now at end of input. +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token "end of input" (1.1: ) +Stack now 0 +syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) + | 1//2 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Stack now 0 8 21 5 13 +Reducing stack by rule 18 (line 131): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1369: $PREPARSER ./calc input +./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +input: +./calc.at:1364: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -72011,7 +74341,26 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stdout: + | (1 + #) = 1111 +1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) +./calc.at:1358: $PREPARSER ./calc input +./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1360: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +stderr: +1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) +stderr: +stderr: +1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) Starting parse Entering state 0 Stack now 0 @@ -72020,6 +74369,7 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 +Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) @@ -72030,13 +74380,15 @@ -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 +Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 -Reading a token +Return for a new token: 1.6: syntax error: invalid character: '#' +Reading a token Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) @@ -72051,6 +74403,7 @@ Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 +Return for a new token: Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) @@ -72063,11 +74416,13 @@ -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 +Return for a new token: Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 +Return for a new token: Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) @@ -72078,6 +74433,7 @@ -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 +Return for a new token: Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): @@ -72102,6 +74458,7 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -72110,16 +74467,19 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 + 2 * 3 + !+ ++ -./calc.at:1368: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1358: $PREPARSER ./calc input -stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Now at end of input. +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token "end of input" (1.1: ) +Stack now 0 +./calc.at:1364: cat stderr +./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1362: cat stderr stderr: +./calc.at:1367: cat stderr Starting parse Entering state 0 Stack now 0 @@ -72128,6 +74488,7 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 +Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) @@ -72138,13 +74499,15 @@ -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 +Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 -Reading a token +Return for a new token: 1.6: syntax error: invalid character: '#' +Reading a token Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) @@ -72159,6 +74522,7 @@ Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 +Return for a new token: Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) @@ -72171,11 +74535,13 @@ -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 +Return for a new token: Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 +Return for a new token: Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) @@ -72186,6 +74552,7 @@ -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 +Return for a new token: Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): @@ -72210,6 +74577,7 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -72218,7 +74586,33 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1360: cat stderr +./calc.at:1369: cat stderr +input: +stderr: +input: +./calc.at:1363: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1368: cat stderr +stdout: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1364: $PREPARSER ./calc input + | + | +1 +./calc.at:1367: $PREPARSER ./calc input +./calc.at:1370: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +stderr: input: +stderr: + | 1 + 2 * 3 + !* ++ Starting parse Entering state 0 Stack now 0 @@ -72536,100 +74930,16 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +stdout: +./calc.at:1363: cat stderr +./calc.at:1362: $PREPARSER ./calc input +./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1371: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +input: + | 1 + 2 * 3 + !* ++ +./calc.at:1360: $PREPARSER ./calc input stderr: - | (#) + (#) = 2222 -./calc.at:1369: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -./calc.at:1367: $PREPARSER ./calc input -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Return for a new token: -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Return for a new token: -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Return for a new token: -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Return for a new token: -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Return for a new token: -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Return for a new token: -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Return for a new token: -Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Stack now 0 8 21 5 14 -Reducing stack by rule 17 (line 130): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1360: "$PERL" -pi -e 'use strict; +./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -72639,285 +74949,24 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1362: $PREPARSER ./calc input -./calc.at:1357: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1364: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: - | 1 2 -./calc.at:1368: $PREPARSER ./calc input -./calc.at:1360: cat stderr +./calc.at:1370: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c + stderr: -syntax error: invalid character: '#' -syntax error: invalid character: '#' -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) -Error: popping token error (1.10: ) -Stack now 0 8 21 4 -Shifting token error (1.10: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) -Error: popping token error (1.16: ) -Stack now 0 8 21 4 -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) + | error stderr: -1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Return for a new token: -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Return for a new token: -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Return for a new token: -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Return for a new token: -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Return for a new token: -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Return for a new token: -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Return for a new token: -Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Stack now 0 8 21 5 14 -Reducing stack by rule 17 (line 130): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) +input: stderr: -./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1358: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1364: cat stderr +./calc.at:1368: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -72936,7 +74985,7 @@ Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) @@ -72954,12 +75003,12 @@ Entering state 4 Stack now 0 8 21 4 Reading a token -Next token is token number (1.7: 1) -Shifting token number (1.7: 1) +Next token is token "number" (1.7: 1) +Shifting token "number" (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.7: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 @@ -72969,18 +75018,18 @@ Entering state 21 Stack now 0 8 21 4 12 21 Reading a token -Next token is token number (1.11: 1) -Shifting token number (1.11: 1) +Next token is token "number" (1.11: 1) +Shifting token "number" (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.11: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) @@ -72992,18 +75041,18 @@ Entering state 21 Stack now 0 8 21 4 12 21 Reading a token -Next token is token number (1.15: 1) -Shifting token number (1.15: 1) +Next token is token "number" (1.15: 1) +Shifting token "number" (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.15: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) @@ -73028,7 +75077,7 @@ Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) @@ -73037,7 +75086,7 @@ Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) @@ -73087,7 +75136,7 @@ Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) @@ -73096,7 +75145,7 @@ Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) @@ -73113,12 +75162,12 @@ Entering state 4 Stack now 0 8 21 4 Reading a token -Next token is token number (1.33: 1) -Shifting token number (1.33: 1) +Next token is token "number" (1.33: 1) +Shifting token "number" (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.33: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 @@ -73128,18 +75177,18 @@ Entering state 22 Stack now 0 8 21 4 12 22 Reading a token -Next token is token number (1.37: 2) -Shifting token number (1.37: 2) +Next token is token "number" (1.37: 2) +Shifting token "number" (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.37: 2) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) -Reducing stack by rule 9 (line 114): +Reducing stack by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) @@ -73172,7 +75221,7 @@ Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) @@ -73181,7 +75230,7 @@ Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) @@ -73193,18 +75242,18 @@ Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.46: 1) -Shifting token number (1.46: 1) +Next token is token "number" (1.46: 1) +Shifting token "number" (1.46: 1) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.46: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) -Reducing stack by rule 6 (line 102): +Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) @@ -73216,27 +75265,124 @@ Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 97): +Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): +Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1357: cat stderr -./calc.at:1369: "$PERL" -ne ' +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Stack now 0 8 21 5 15 +Reducing stack by rule 19 (line 132): + $1 = token '!' (1.13: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1358: cat stderr +syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) +stderr: + | error +./calc.at:1364: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1369: $PREPARSER ./calc input +./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1371: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. @@ -73247,18 +75393,418 @@ || /\t/ )' calc.c +1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Stack now 0 8 21 5 15 +Reducing stack by rule 19 (line 132): + $1 = token '!' (1.13: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) stderr: -./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) - | 1 + 2 * 3 + !+ ++ -./calc.at:1360: $PREPARSER ./calc input + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +stderr: +./calc.at:1370: $PREPARSER ./calc input +./calc.at:1364: cat stderr +stderr: +1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) +stderr: input: - +./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Stack now 0 8 21 5 15 +Reducing stack by rule 19 (line 132): + $1 = token '!' (1.13: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +input: +./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1363: $PREPARSER ./calc input | (# + 1) = 1111 +./calc.at:1358: $PREPARSER ./calc input +syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: -./calc.at:1357: $PREPARSER ./calc input stderr: +./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1371: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 114): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Stack now 0 8 21 5 15 +Reducing stack by rule 19 (line 132): + $1 = token '!' (1.13: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +stderr: +./calc.at:1362: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Return for a new token: +1.2: syntax error: invalid character: '#' +Reading a token +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Return for a new token: +Reading a token +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Return for a new token: +Reading a token +Next token is token number (1.6: 1) +Error: discarding token number (1.6: 1) +Error: popping token error (1.2-4: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Return for a new token: +Reading a token +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Stack now 0 8 +Return for a new token: +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Stack now 0 8 19 +Return for a new token: +Reading a token +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Stack now 0 8 19 28 +Return for a new token: +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Return for a new token: +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -73277,7 +75823,7 @@ Shifting token ')' (1.2: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) @@ -73295,12 +75841,12 @@ Entering state 4 Stack now 0 8 21 4 Reading a token -Next token is token number (1.7: 1) -Shifting token number (1.7: 1) +Next token is token "number" (1.7: 1) +Shifting token "number" (1.7: 1) Entering state 1 Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.7: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 21 4 12 @@ -73310,18 +75856,18 @@ Entering state 21 Stack now 0 8 21 4 12 21 Reading a token -Next token is token number (1.11: 1) -Shifting token number (1.11: 1) +Next token is token "number" (1.11: 1) +Shifting token "number" (1.11: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.11: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) @@ -73333,18 +75879,18 @@ Entering state 21 Stack now 0 8 21 4 12 21 Reading a token -Next token is token number (1.15: 1) -Shifting token number (1.15: 1) +Next token is token "number" (1.15: 1) +Shifting token "number" (1.15: 1) Entering state 1 Stack now 0 8 21 4 12 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.15: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 30 Stack now 0 8 21 4 12 21 30 Reading a token Next token is token '+' (1.17: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) @@ -73369,7 +75915,7 @@ Shifting token ')' (1.18: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) @@ -73378,7 +75924,7 @@ Stack now 0 8 21 30 Reading a token Next token is token '+' (1.20: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) @@ -73428,7 +75974,7 @@ Shifting token ')' (1.28: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) @@ -73437,7 +75983,7 @@ Stack now 0 8 21 30 Reading a token Next token is token '+' (1.30: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) @@ -73454,12 +76000,12 @@ Entering state 4 Stack now 0 8 21 4 Reading a token -Next token is token number (1.33: 1) -Shifting token number (1.33: 1) +Next token is token "number" (1.33: 1) +Shifting token "number" (1.33: 1) Entering state 1 Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.33: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 21 4 12 @@ -73469,18 +76015,18 @@ Entering state 22 Stack now 0 8 21 4 12 22 Reading a token -Next token is token number (1.37: 2) -Shifting token number (1.37: 2) +Next token is token "number" (1.37: 2) +Shifting token "number" (1.37: 2) Entering state 1 Stack now 0 8 21 4 12 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.37: 2) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 31 Stack now 0 8 21 4 12 22 31 Reading a token Next token is token '*' (1.39: ) -Reducing stack by rule 9 (line 114): +Reducing stack by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) @@ -73513,7 +76059,7 @@ Shifting token ')' (1.42: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) @@ -73522,7 +76068,7 @@ Stack now 0 8 21 30 Reading a token Next token is token '=' (1.44: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) @@ -73534,18 +76080,18 @@ Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.46: 1) -Shifting token number (1.46: 1) +Next token is token "number" (1.46: 1) +Shifting token "number" (1.46: 1) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.46: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.47-2.0: ) -Reducing stack by rule 6 (line 102): +Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-42: 4444) $2 = token '=' (1.44: ) $3 = nterm exp (1.46: 1) @@ -73557,124 +76103,33 @@ Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 97): +Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-46: 4444) $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): +Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: -input: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Stack now 0 8 21 5 14 -Reducing stack by rule 17 (line 130): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1370: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 +stderr: +./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1368: cat stderr +./calc.at:1362: cat stderr | (!!) + (1 2) = 1 -./calc.at:1369: $PREPARSER ./calc input -./calc.at:1364: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -73683,8 +76138,9 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 -Reading a token +Return for a new token: 1.2: syntax error: invalid character: '#' +Reading a token Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 @@ -73695,6 +76151,7 @@ Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 +Return for a new token: Reading a token Next token is token '+' (1.4: ) Error: discarding token '+' (1.4: ) @@ -73703,6 +76160,7 @@ Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 +Return for a new token: Reading a token Next token is token number (1.6: 1) Error: discarding token number (1.6: 1) @@ -73711,6 +76169,7 @@ Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 +Return for a new token: Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) @@ -73723,11 +76182,13 @@ -> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 +Return for a new token: Reading a token Next token is token '=' (1.9: ) Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 +Return for a new token: Reading a token Next token is token number (1.11-14: 1111) Shifting token number (1.11-14: 1111) @@ -73738,6 +76199,7 @@ -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 +Return for a new token: Reading a token Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): @@ -73762,6 +76224,7 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -73770,8 +76233,11 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1363: "$PERL" -pi -e 'use strict; +./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1364: $PREPARSER ./calc input +stderr: +./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -73781,8 +76247,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -stderr: Starting parse Entering state 0 Stack now 0 @@ -73924,8 +76388,22 @@ Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: -./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1362: "$PERL" -pi -e 'use strict; +input: +./calc.at:1367: cat stderr +input: + | 1 = 2 = 3 +./calc.at:1368: $PREPARSER ./calc input + | 1 2 +./calc.at:1371: $EGREP -c -v 'Return for a new token:|LAC:' stderr +stderr: +./calc.at:1360: cat stderr +./calc.at:1370: $PREPARSER ./calc input +input: +stderr: +./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) +stderr: +./calc.at:1358: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -73935,6 +76413,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -73944,101 +76423,319 @@ Entering state 4 Stack now 0 4 Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 114): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 +Stack now 0 8 Reading a token Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2-4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token "number" (1.7: 1) +Shifting token "number" (1.7: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.7: 1) +-> $$ = nterm exp (1.7: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token "number" (1.11: 1) +Shifting token "number" (1.11: 1) +Entering state 1 +Stack now 0 8 21 4 12 21 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 30 +Stack now 0 8 21 4 12 21 30 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 99): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token "number" (1.15: 1) +Shifting token "number" (1.15: 1) +Entering state 1 +Stack now 0 8 21 4 12 21 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 30 +Stack now 0 8 21 4 12 21 30 +Reading a token +Next token is token '+' (1.17: ) +Reducing stack by rule 7 (line 99): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 21 +Stack now 0 8 21 4 12 21 +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.7-15: 3) +Stack now 0 8 21 4 +Shifting token error (1.7-18: ) Entering state 11 -Stack now 0 4 11 +Stack now 0 8 21 4 11 +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 114): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 30 +Stack now 0 8 21 30 Reading a token -Next token is token number (1.6: 1) -Error: discarding token number (1.6: 1) -Error: popping token error (1.2-4: ) -Stack now 0 4 -Shifting token error (1.2-6: ) +Next token is token '+' (1.20: ) +Reducing stack by rule 7 (line 99): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) Entering state 11 -Stack now 0 4 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) +Error: popping token error (1.23: ) +Stack now 0 8 21 4 +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 21 4 11 Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Error: popping token error (1.23: ) +Stack now 0 8 21 4 +Shifting token error (1.23-25: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Error: popping token error (1.23-25: ) +Stack now 0 8 21 4 +Shifting token error (1.23-27: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 114): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.30: ) +Reducing stack by rule 7 (line 99): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +Next token is token "number" (1.33: 1) +Shifting token "number" (1.33: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 22 +Stack now 0 8 21 4 12 22 +Reading a token +Next token is token "number" (1.37: 2) +Shifting token "number" (1.37: 2) +Entering state 1 +Stack now 0 8 21 4 12 22 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 31 +Stack now 0 8 21 4 12 22 31 +Reading a token +Next token is token '*' (1.39: ) +Reducing stack by rule 9 (line 101): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Stack now 0 8 21 4 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 22 +Stack now 0 8 21 4 12 22 +Reading a token +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Stack now 0 8 21 4 12 +Error: popping nterm exp (1.33-37: 2) +Stack now 0 8 21 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) +Error: popping token error (1.33-41: ) +Stack now 0 8 21 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 114): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.44: ) +Reducing stack by rule 7 (line 99): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) +Next token is token "number" (1.46: 1) +Shifting token "number" (1.46: 1) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.46: 1) +-> $$ = nterm exp (1.46: 1) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) +Next token is token '\n' (1.47-2.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) +Reducing stack by rule 4 (line 84): + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): +Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1363: cat stderr -./calc.at:1368: cat stderr -./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1367: cat stderr -input: -stderr: + | (#) + (#) = 2222 stderr: - | 1 + 2 * 3 + !- ++ -./calc.at:1358: $PREPARSER ./calc input +./calc.at:1362: $PREPARSER ./calc input +1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) +./calc.at:1369: cat stderr Starting parse Entering state 0 Stack now 0 @@ -74179,15 +76876,17 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1369: $EGREP -c -v 'Return for a new token:|LAC:' stderr -input: -./calc.at:1362: cat stderr - | 1 + 2 * 3 + !+ ++ +./calc.at:1367: $PREPARSER ./calc /dev/null +./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1363: $PREPARSER ./calc input -./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1358: cat stderr stderr: -./calc.at:1357: "$PERL" -pi -e 'use strict; +stderr: +syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) +1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) +input: +./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -74198,270 +76897,417 @@ }eg ' expout || exit 77 input: + | (#) + (#) = 2222 + | 1 2 stderr: +./calc.at:1363: cat stderr +./calc.at:1360: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +1.2: syntax error: invalid character: '#' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +1.8: syntax error: invalid character: '#' +Shifting token error (1.8: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token invalid token (1.8: ) +Error: discarding token invalid token (1.8: ) +Error: popping token error (1.8: ) +Stack now 0 8 21 4 +Shifting token error (1.8: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 +Next token is token '=' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) +Next token is token number (1.13-16: 2222) +Shifting token number (1.13-16: 2222) Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) +Entering state 28 +Stack now 0 8 19 28 Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) +Next token is token '\n' (1.17-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Stack now 0 8 21 5 14 -Reducing stack by rule 17 (line 117): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) - | (!!) + (1 2) = 1 +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1371: $PREPARSER ./calc input +1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) +input: +stderr: +stderr: +./calc.at:1364: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | 1 = 2 = 3 +./calc.at:1369: $PREPARSER ./calc input +./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +1.2: syntax error: invalid character: '#' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +1.8: syntax error: invalid character: '#' +Shifting token error (1.8: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token invalid token (1.8: ) +Error: discarding token invalid token (1.8: ) +Error: popping token error (1.8: ) +Stack now 0 8 21 4 +Shifting token error (1.8: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 +Next token is token '=' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token number (1.13-16: 2222) +Shifting token number (1.13-16: 2222) Entering state 1 -Stack now 0 8 21 30 22 1 +Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 + $1 = token number (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) +Entering state 28 +Stack now 0 8 19 28 Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) +Next token is token '\n' (1.17-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Stack now 0 8 21 5 14 -Reducing stack by rule 17 (line 130): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1360: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1362: $PREPARSER ./calc input +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: +input: +1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) +stderr: +./calc.at:1368: cat stderr +./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) input: +input: + | (!!) + (1 2) = 1 +./calc.at:1363: $PREPARSER ./calc input +./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + # + 1) = 1111 +./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | + | +1 Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +1.2: syntax error: invalid character: '#' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 -Return for a new token: Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) Entering state 21 Stack now 0 8 21 -Return for a new token: Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +1.8: syntax error: invalid character: '#' +Shifting token error (1.8: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token invalid token (1.8: ) +Error: discarding token invalid token (1.8: ) +Error: popping token error (1.8: ) +Stack now 0 8 21 4 +Shifting token error (1.8: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) Entering state 30 Stack now 0 8 21 30 -Return for a new token: Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Return for a new token: +Next token is token '=' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token number (1.13-16: 2222) +Shifting token number (1.13-16: 2222) Entering state 1 -Stack now 0 8 21 30 22 1 +Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Return for a new token: + $1 = token number (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) +Entering state 28 +Stack now 0 8 19 28 Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) +Next token is token '\n' (1.17-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Return for a new token: -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Return for a new token: +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Stack now 0 8 21 5 13 -Reducing stack by rule 18 (line 131): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -stderr: -./calc.at:1357: cat stderr - | 1//2 -input: -./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1358: $PREPARSER ./calc input ./calc.at:1368: $PREPARSER ./calc input - | 1 2 -./calc.at:1369: $PREPARSER ./calc input stderr: - | (1 + #) = 1111 +stderr: +stderr: +stderr: +./calc.at:1364: cat stderr Starting parse Entering state 0 Stack now 0 @@ -74480,7 +77326,7 @@ Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 -Reducing stack by rule 16 (line 129): +Reducing stack by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 @@ -74492,7 +77338,7 @@ Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) @@ -74510,25 +77356,25 @@ Entering state 4 Stack now 0 8 21 4 Reading a token -Next token is token number (1.9: 1) -Shifting token number (1.9: 1) +Next token is token "number" (1.9: 1) +Shifting token "number" (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token -Next token is token number (1.11: 2) +Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 -Next token is token number (1.11: 2) -Error: discarding token number (1.11: 2) +Next token is token "number" (1.11: 2) +Error: discarding token "number" (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) @@ -74539,7 +77385,7 @@ Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) @@ -74548,7 +77394,7 @@ Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) @@ -74560,18 +77406,18 @@ Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.16: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 102): +Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) @@ -74583,225 +77429,28 @@ Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 97): +Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): +Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1367: $PREPARSER ./calc input -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Return for a new token: -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Return for a new token: -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Return for a new token: -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Return for a new token: -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Return for a new token: -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Return for a new token: -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Return for a new token: -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Stack now 0 8 21 5 13 -Reducing stack by rule 18 (line 131): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -stderr: -stderr: -496. calc.at:1370: testing Calculator parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} api.push-pull=both api.pure=full ... -1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) +2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: 1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) -input: -./calc.at:1370: mv calc.y.tmp calc.y - -./calc.at:1364: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (1 + # + 1) = 1111 -syntax error: invalid character: '#' -stderr: -./calc.at:1370: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -./calc.at:1357: $PREPARSER ./calc input -./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1364: cat stderr -1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Stack now 0 8 21 5 14 -Reducing stack by rule 17 (line 117): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) Starting parse Entering state 0 Stack now 0 @@ -74810,6 +77459,7 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 +Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) @@ -74820,134 +77470,15 @@ -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 +Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 -Reading a token +Return for a new token: 1.6: syntax error: invalid character: '#' -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-8: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1.10: 1) -Error: discarding token number (1.10: 1) -Error: popping token error (1.2-8: ) -Stack now 0 4 -Shifting token error (1.2-10: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.15-18: 1111) -Shifting token number (1.15-18: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.19-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1363: $EGREP -c -v 'Return for a new token:|LAC:' stderr -stderr: -./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) -input: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 -Reading a token -1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) @@ -74962,6 +77493,7 @@ Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 +Return for a new token: Reading a token Next token is token '+' (1.8: ) Error: discarding token '+' (1.8: ) @@ -74970,6 +77502,7 @@ Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 +Return for a new token: Reading a token Next token is token number (1.10: 1) Error: discarding token number (1.10: 1) @@ -74978,6 +77511,7 @@ Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 +Return for a new token: Reading a token Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) @@ -74990,11 +77524,13 @@ -> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 +Return for a new token: Reading a token Next token is token '=' (1.13: ) Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 +Return for a new token: Reading a token Next token is token number (1.15-18: 1111) Shifting token number (1.15-18: 1111) @@ -75005,6 +77541,7 @@ -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 +Return for a new token: Reading a token Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): @@ -75029,6 +77566,7 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -75037,9 +77575,9 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | 1 + 2 * 3 + !- ++ -./calc.at:1360: $PREPARSER ./calc input -./calc.at:1358: "$PERL" -pi -e 'use strict; +./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -75049,9 +77587,16 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1369: cat stderr input: stderr: +2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) + | (- *) + (1 2) = 1 +./calc.at:1364: $PREPARSER ./calc input +stderr: +stderr: +stderr: +stderr: +./calc.at:1370: cat stderr Starting parse Entering state 0 Stack now 0 @@ -75070,7 +77615,7 @@ Shifting token '!' (1.3: ) Entering state 16 Stack now 0 4 5 16 -Reducing stack by rule 16 (line 129): +Reducing stack by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Stack now 0 4 @@ -75082,7 +77627,7 @@ Shifting token ')' (1.4: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) @@ -75100,25 +77645,25 @@ Entering state 4 Stack now 0 8 21 4 Reading a token -Next token is token number (1.9: 1) -Shifting token number (1.9: 1) +Next token is token "number" (1.9: 1) +Shifting token "number" (1.9: 1) Entering state 1 Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token -Next token is token number (1.11: 2) +Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Stack now 0 8 21 4 Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 21 4 11 -Next token is token number (1.11: 2) -Error: discarding token number (1.11: 2) +Next token is token "number" (1.11: 2) +Error: discarding token "number" (1.11: 2) Error: popping token error (1.9-11: ) Stack now 0 8 21 4 Shifting token error (1.9-11: ) @@ -75129,7 +77674,7 @@ Shifting token ')' (1.12: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) @@ -75138,7 +77683,7 @@ Stack now 0 8 21 30 Reading a token Next token is token '=' (1.14: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) @@ -75150,18 +77695,18 @@ Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.16: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 102): +Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-12: 2222) $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) @@ -75173,6 +77718,127 @@ Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 +Reducing stack by rule 4 (line 84): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +1.2: syntax error: invalid character: '#' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +1.8: syntax error: invalid character: '#' +Shifting token error (1.8: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token invalid token (1.8: ) +Error: discarding token invalid token (1.8: ) +Error: popping token error (1.8: ) +Stack now 0 8 21 4 +Shifting token error (1.8: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.13-16: 2222) +Shifting token number (1.13-16: 2222) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.17-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 25 +Stack now 0 8 25 Reducing stack by rule 4 (line 97): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) @@ -75192,28 +77858,136 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1357: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error: invalid character: '#' -input: - | 1 + 2 * 3 + !- ++ - | (- *) + (1 2) = 1 -./calc.at:1363: $PREPARSER ./calc input -./calc.at:1358: cat stderr -./calc.at:1364: $PREPARSER ./calc input -./calc.at:1357: cat stderr +./calc.at:1362: cat stderr +1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Return for a new token: +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Return for a new token: +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 +Return for a new token: +1.6: syntax error: invalid character: '#' +Reading a token +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Return for a new token: +Reading a token +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-8: ) +Entering state 11 +Stack now 0 4 11 +Return for a new token: +Reading a token +Next token is token number (1.10: 1) +Error: discarding token number (1.10: 1) +Error: popping token error (1.2-8: ) +Stack now 0 4 +Shifting token error (1.2-10: ) +Entering state 11 +Stack now 0 4 11 +Return for a new token: +Reading a token +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) +Entering state 8 +Stack now 0 8 +Return for a new token: +Reading a token +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) +Entering state 19 +Stack now 0 8 19 +Return for a new token: +Reading a token +Next token is token number (1.15-18: 1111) +Shifting token number (1.15-18: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) +Entering state 28 +Stack now 0 8 19 28 +Return for a new token: +Reading a token +Next token is token '\n' (1.19-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Return for a new token: +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1371: cat stderr stderr: +./calc.at:1368: cat stderr input: - | 1//2 -./calc.at:1367: cat stderr Starting parse Entering state 0 Stack now 0 @@ -75362,102 +78136,159 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1369: $PREPARSER ./calc input +input: + | (1 + #) = 1111 +./calc.at:1362: $PREPARSER ./calc input +./calc.at:1368: $PREPARSER ./calc /dev/null stderr: +1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1367: cat stderr + | 1//2 +./calc.at:1363: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +./calc.at:1370: $PREPARSER ./calc input +./calc.at:1360: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -./calc.at:1368: cat stderr +1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1358: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: +./calc.at:1358: cat stderr ./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1//2 +./calc.at:1371: $PREPARSER ./calc input +stderr: 1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) -input: +./calc.at:1369: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 -Stack now 0 1 +Stack now 0 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) Entering state 21 -Stack now 0 8 21 +Stack now 0 4 12 21 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 +1.6: syntax error: invalid character: '#' +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Stack now 0 8 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 -Stack now 0 8 21 30 22 1 +Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Stack now 0 8 19 28 Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Stack now 0 8 21 5 13 -Reducing stack by rule 18 (line 131): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -input: -input: - | (1 + 1) / (1 - 1) -./calc.at:1357: $PREPARSER ./calc input -./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (# + 1) = 1111 +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: +./calc.at:1363: cat stderr +./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1367: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -75606,20 +78437,26 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1360: cat stderr +input: +./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1367: $PREPARSER ./calc input +1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) stderr: + | (1 + 1) / (1 - 1) +input: +./calc.at:1358: $PREPARSER ./calc input + | (1 + #) = 1111 +syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +error: 4444 != 1 +./calc.at:1360: $PREPARSER ./calc input +./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1362: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 @@ -75628,6 +78465,7 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 +Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) @@ -75638,11 +78476,13 @@ -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 +Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 +Return for a new token: Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) @@ -75653,6 +78493,7 @@ -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 +Return for a new token: Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): @@ -75673,16 +78514,19 @@ -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 +Return for a new token: Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 +Return for a new token: Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 +Return for a new token: Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) @@ -75693,11 +78537,13 @@ -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 +Return for a new token: Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 +Return for a new token: Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) @@ -75708,6 +78554,7 @@ -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 +Return for a new token: Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): @@ -75728,6 +78575,7 @@ -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 +Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): @@ -75753,6 +78601,7 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -75761,93 +78610,206 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) +Stack now 0 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +1.6: syntax error: invalid character: '#' +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Stack now 0 8 19 28 Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 +Stack now 0 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +1.6: syntax error: invalid character: '#' +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Stack now 0 8 21 5 13 -Reducing stack by rule 18 (line 118): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1357: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: - | 1 + 2 * 3 + !* ++ -./calc.at:1358: $PREPARSER ./calc input -1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) -./calc.at:1370: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -75859,10 +78821,6 @@ }eg ' expout || exit 77 stderr: -stderr: -syntax error: invalid character: '#' -stderr: -./calc.at:1362: cat stderr Starting parse Entering state 0 Stack now 0 @@ -75871,6 +78829,7 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 +Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) @@ -75881,11 +78840,13 @@ -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 +Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 +Return for a new token: Reading a token Next token is token number (1.6: 1) Shifting token number (1.6: 1) @@ -75896,6 +78857,7 @@ -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 +Return for a new token: Reading a token Next token is token ')' (1.7: ) Reducing stack by rule 7 (line 112): @@ -75916,16 +78878,19 @@ -> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 +Return for a new token: Reading a token Next token is token '/' (1.9: ) Shifting token '/' (1.9: ) Entering state 23 Stack now 0 8 23 +Return for a new token: Reading a token Next token is token '(' (1.11: ) Shifting token '(' (1.11: ) Entering state 4 Stack now 0 8 23 4 +Return for a new token: Reading a token Next token is token number (1.12: 1) Shifting token number (1.12: 1) @@ -75936,11 +78901,13 @@ -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 +Return for a new token: Reading a token Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 20 Stack now 0 8 23 4 12 20 +Return for a new token: Reading a token Next token is token number (1.16: 1) Shifting token number (1.16: 1) @@ -75951,6 +78918,7 @@ -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 +Return for a new token: Reading a token Next token is token ')' (1.17: ) Reducing stack by rule 8 (line 113): @@ -75971,6 +78939,7 @@ -> $$ = nterm exp (1.11-17: 0) Entering state 32 Stack now 0 8 23 32 +Return for a new token: Reading a token Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 10 (line 115): @@ -75996,6 +78965,7 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 +Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -76004,201 +78974,125 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: input: +./calc.at:1368: cat stderr +stderr: +stderr: +syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +error: 4444 != 1 + | (- *) + (1 2) = 1 +./calc.at:1364: cat stderr +./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1363: $PREPARSER ./calc input +1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) +stderr: +stderr: +1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) +stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 -Stack now 0 8 21 30 22 1 +Stack now 0 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 +Stack now 0 4 12 21 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Stack now 0 8 21 5 13 -Reducing stack by rule 18 (line 131): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -Starting parse -Entering state 0 -Stack now 0 +1.6: syntax error: invalid character: '#' +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 -Return for a new token: -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Return for a new token: Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Return for a new token: -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Return for a new token: +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 -Stack now 0 8 21 30 22 1 +Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Return for a new token: + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Stack now 0 8 19 28 Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Return for a new token: -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Return for a new token: +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Stack now 0 8 21 5 15 -Reducing stack by rule 19 (line 132): - $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) - | error -./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1368: $PREPARSER ./calc input -./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1369: cat stderr -./calc.at:1364: cat stderr -1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1367: cat stderr -stderr: -./calc.at:1357: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) input: input: -./calc.at:1360: "$PERL" -pi -e 'use strict; +./calc.at:1362: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -76208,110 +79102,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Return for a new token: -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Return for a new token: -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Return for a new token: -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Return for a new token: -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Return for a new token: -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Return for a new token: -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Return for a new token: -Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Stack now 0 8 21 5 15 -Reducing stack by rule 19 (line 132): - $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -input: - | error - | (* *) + (*) + (*) -./calc.at:1369: $PREPARSER ./calc input -./calc.at:1364: $PREPARSER ./calc input - | (- *) + (1 2) = 1 -./calc.at:1357: cat stderr -input: -1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1362: $PREPARSER ./calc input -stderr: - | (1 + # + 1) = 1111 -./calc.at:1367: $PREPARSER ./calc input -stderr: -./calc.at:1360: cat stderr -1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 Starting parse Entering state 0 Stack now 0 @@ -76321,22 +79112,26 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) -Error: popping token error (1.2: ) +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Stack now 0 4 2 +Reading a token +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 115): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) Stack now 0 4 -Shifting token error (1.2: ) +Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 -Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) -Error: popping token error (1.2: ) +Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 @@ -76364,80 +79159,73 @@ Entering state 4 Stack now 0 8 21 4 Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) +Next token is token "number" (1.10: 1) +Shifting token "number" (1.10: 1) +Entering state 1 +Stack now 0 8 21 4 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Stack now 0 8 21 4 12 +Reading a token +Next token is token "number" (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Stack now 0 8 21 4 +Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) -Error: popping token error (1.10: ) +Next token is token "number" (1.12: 2) +Error: discarding token "number" (1.12: 2) +Error: popping token error (1.10-12: ) Stack now 0 8 21 4 -Shifting token error (1.10: ) +Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token -Next token is token '+' (1.13: ) +Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) -Error: popping token error (1.16: ) -Stack now 0 8 21 4 -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 21 4 11 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 30 -Stack now 0 8 21 30 +Next token is token "number" (1.17: 1) +Shifting token "number" (1.17: 1) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.17: 1) +-> $$ = nterm exp (1.17: 1) +Entering state 28 +Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) @@ -76445,7 +79233,7 @@ Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-17: 3333) + $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 @@ -76463,12 +79251,50 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1358: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1368: $PREPARSER ./calc input +./calc.at:1371: cat stderr + | + | +1 +./calc.at:1369: $PREPARSER ./calc input +./calc.at:1370: cat stderr +stderr: +./calc.at:1358: cat stderr +./calc.at:1367: cat stderr +1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.1-46: error: 4444 != 1 +./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1362: cat stderr stderr: +2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) +stderr: +input: +1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.1-46: error: 4444 != 1 + | error +./calc.at:1371: $PREPARSER ./calc input +input: +./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -syntax error: invalid character: '#' ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1358: "$PERL" -pi -e 'use strict; + | (# + 1) = 1111 +./calc.at:1362: $PREPARSER ./calc input +./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -76478,7 +79304,118 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +488. calc.at:1358: ok +stderr: +2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) +input: +stderr: +1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +1.2: syntax error: invalid character: '#' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token number (1.6: 1) +Error: discarding token number (1.6: 1) +Error: popping token error (1.2-4: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Stack now 0 8 19 +Reading a token +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) +Entering state 1 +Stack now 0 8 19 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Stack now 0 8 19 28 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 25 +Stack now 0 8 25 +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 91): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Now at end of input. +Shifting token end of file (2.1: ) +Entering state 17 +Stack now 0 6 17 +Stack now 0 6 17 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +input: +./calc.at:1360: cat stderr + | (* *) + (*) + (*) + | error +./calc.at:1370: $PREPARSER ./calc input +./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1368: cat stderr +stderr: +./calc.at:1364: $PREPARSER ./calc input +stderr: Starting parse Entering state 0 Stack now 0 @@ -76498,7 +79435,7 @@ Shifting token error (1.4: ) Entering state 9 Stack now 0 4 2 9 -Reducing stack by rule 15 (line 128): +Reducing stack by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Stack now 0 4 @@ -76517,7 +79454,7 @@ Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) @@ -76535,25 +79472,25 @@ Entering state 4 Stack now 0 8 21 4 Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) +Next token is token "number" (1.10: 1) +Shifting token "number" (1.10: 1) Entering state 1 Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.10: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 21 4 12 Reading a token -Next token is token number (1.12: 2) +Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Stack now 0 8 21 4 Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 21 4 11 -Next token is token number (1.12: 2) -Error: discarding token number (1.12: 2) +Next token is token "number" (1.12: 2) +Error: discarding token "number" (1.12: 2) Error: popping token error (1.10-12: ) Stack now 0 8 21 4 Shifting token error (1.10-12: ) @@ -76564,7 +79501,7 @@ Shifting token ')' (1.13: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) @@ -76573,7 +79510,7 @@ Stack now 0 8 21 30 Reading a token Next token is token '=' (1.15: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) @@ -76585,18 +79522,18 @@ Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) +Next token is token "number" (1.17: 1) +Shifting token "number" (1.17: 1) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.17: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 6 (line 102): +Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-13: 2222) $2 = token '=' (1.15: ) $3 = nterm exp (1.17: 1) @@ -76608,31 +79545,33 @@ Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 97): +Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): +Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) + | (!!) + (1 2) = 1 +./calc.at:1367: $PREPARSER ./calc input stderr: -stderr: +input: +./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (# + 1) = 1111 +./calc.at:1360: $PREPARSER ./calc input 1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) -stderr: -stderr: -./calc.at:1358: cat stderr Starting parse Entering state 0 Stack now 0 @@ -76784,91 +79723,7 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -syntax error: invalid character: '#' -./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Stack now 0 8 21 5 13 -Reducing stack by rule 18 (line 118): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) stderr: -input: -input: Starting parse Entering state 0 Stack now 0 @@ -76878,129 +79733,76 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Stack now 0 4 2 +1.2: syntax error: invalid character: '#' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 128): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) +Reading a token +Next token is token number (1.6: 1) +Error: discarding token number (1.6: 1) Error: popping token error (1.2-4: ) Stack now 0 4 -Shifting token error (1.2-4: ) +Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) -Entering state 1 -Stack now 0 8 21 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Stack now 0 8 21 4 12 -Reading a token -Next token is token number (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Stack now 0 8 21 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token number (1.12: 2) -Error: discarding token number (1.12: 2) -Error: popping token error (1.10-12: ) -Stack now 0 8 21 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.15: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.17: 1) --> $$ = nterm exp (1.17: 1) + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.18-2.0: ) +Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -77017,14 +79819,20 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | (#) + (#) = 2222 - | 1 + 2 * 3 + !* ++ -./calc.at:1358: $PREPARSER ./calc input -487. calc.at:1357: ok -./calc.at:1369: cat stderr -./calc.at:1360: $PREPARSER ./calc input stderr: -./calc.at:1368: cat stderr +1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1363: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -77033,9 +79841,8 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 -Return for a new token: -1.2: syntax error: invalid character: '#' Reading a token +1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 @@ -77046,99 +79853,65 @@ Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 -Return for a new token: -Reading a token -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Stack now 0 8 -Return for a new token: -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 21 -Stack now 0 8 21 -Return for a new token: -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Stack now 0 8 21 4 -Return for a new token: -1.8: syntax error: invalid character: '#' Reading a token -Shifting token error (1.8: ) +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2-4: ) Entering state 11 -Stack now 0 8 21 4 11 -Next token is token invalid token (1.8: ) -Error: discarding token invalid token (1.8: ) -Error: popping token error (1.8: ) -Stack now 0 8 21 4 -Shifting token error (1.8: ) +Stack now 0 4 11 +Reading a token +Next token is token number (1.6: 1) +Error: discarding token number (1.6: 1) +Error: popping token error (1.2-4: ) +Stack now 0 4 +Shifting token error (1.2-6: ) Entering state 11 -Stack now 0 8 21 4 11 -Return for a new token: +Stack now 0 4 11 Reading a token -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 26 -Stack now 0 8 21 4 11 26 +Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 30 -Stack now 0 8 21 30 -Return for a new token: -Reading a token -Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 -Return for a new token: Reading a token -Next token is token number (1.13-16: 2222) -Shifting token number (1.13-16: 2222) +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 -Return for a new token: Reading a token -Next token is token '\n' (1.17-2.0: ) +Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -77147,7 +79920,6 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -77156,120 +79928,19 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1364: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1363: cat stderr stderr: -./calc.at:1362: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Stack now 0 8 21 5 15 -Reducing stack by rule 19 (line 132): - $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1363: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1371: cat stderr +./calc.at:1369: cat stderr +stderr: +syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +error: 2222 != 1 +./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: stderr: +1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) Starting parse Entering state 0 Stack now 0 @@ -77278,9 +79949,8 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 -Return for a new token: -1.2: syntax error: invalid character: '#' Reading a token +1.2: syntax error: invalid character: '#' Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 @@ -77291,99 +79961,65 @@ Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 -Return for a new token: -Reading a token -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Stack now 0 8 -Return for a new token: -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 21 -Stack now 0 8 21 -Return for a new token: -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Stack now 0 8 21 4 -Return for a new token: -1.8: syntax error: invalid character: '#' Reading a token -Shifting token error (1.8: ) +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2-4: ) Entering state 11 -Stack now 0 8 21 4 11 -Next token is token invalid token (1.8: ) -Error: discarding token invalid token (1.8: ) -Error: popping token error (1.8: ) -Stack now 0 8 21 4 -Shifting token error (1.8: ) +Stack now 0 4 11 +Reading a token +Next token is token number (1.6: 1) +Error: discarding token number (1.6: 1) +Error: popping token error (1.2-4: ) +Stack now 0 4 +Shifting token error (1.2-6: ) Entering state 11 -Stack now 0 8 21 4 11 -Return for a new token: +Stack now 0 4 11 Reading a token -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 26 -Stack now 0 8 21 4 11 26 +Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 30 -Stack now 0 8 21 30 -Return for a new token: -Reading a token -Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 -Return for a new token: Reading a token -Next token is token number (1.13-16: 2222) -Shifting token number (1.13-16: 2222) +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 -Return for a new token: Reading a token -Next token is token '\n' (1.17-2.0: ) +Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -77392,7 +80028,6 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -77401,209 +80036,7 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -input: -input: - | 1 = 2 = 3 -./calc.at:1364: cat stderr - -./calc.at:1369: $PREPARSER ./calc input -./calc.at:1363: cat stderr - | 1 = 2 = 3 -./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1368: $PREPARSER ./calc input -./calc.at:1358: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) -stderr: -./calc.at:1362: cat stderr -./calc.at:1367: cat stderr -stderr: -./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Stack now 0 8 21 5 15 -Reducing stack by rule 19 (line 132): - $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) -./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -input: - | 1 + 2 * 3 + !* ++ -./calc.at:1363: $PREPARSER ./calc input -stderr: - | (* *) + (*) + (*) -stderr: -./calc.at:1362: $PREPARSER ./calc input -stderr: -1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Stack now 0 8 21 5 15 -Reducing stack by rule 19 (line 119): - $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) stderr: -./calc.at:1358: cat stderr Starting parse Entering state 0 Stack now 0 @@ -77638,7 +80071,7 @@ Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) @@ -77673,7 +80106,7 @@ Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) @@ -77682,7 +80115,7 @@ Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) @@ -77716,7 +80149,7 @@ Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) @@ -77725,7 +80158,7 @@ Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) @@ -77736,32 +80169,39 @@ Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 97): +Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): +Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) -input: input: -stderr: - | (1 + #) = 1111 +./calc.at:1362: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1369: $PREPARSER ./calc /dev/null + | (!!) + (1 2) = 1 +./calc.at:1368: $PREPARSER ./calc input ./calc.at:1360: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -77772,175 +80212,36 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1 + 2 * 3 + !+ ++ -./calc.at:1364: $PREPARSER ./calc input -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Stack now 0 8 21 5 15 -Reducing stack by rule 19 (line 119): - $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) stderr: -./calc.at:1369: cat stderr -input: stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Stack now 0 8 21 5 14 -Reducing stack by rule 17 (line 117): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) +stderr: +input: + | (* *) + (*) + (*) +./calc.at:1363: $PREPARSER ./calc input +1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) +1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-16: error: 2222 != 1 +./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +error: 2222 != 1 + ./calc.at:1360: cat stderr -./calc.at:1358: $PREPARSER ./calc input +./calc.at:1370: cat stderr +./calc.at:1364: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1362: cat stderr + | 1 = 2 = 3 +./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1371: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -77975,7 +80276,7 @@ Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) @@ -78010,7 +80311,7 @@ Shifting token ')' (1.11: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) @@ -78019,7 +80320,7 @@ Stack now 0 8 21 30 Reading a token Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) @@ -78053,7 +80354,7 @@ Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) @@ -78062,7 +80363,7 @@ Stack now 0 8 21 30 Reading a token Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) @@ -78073,64 +80374,48 @@ Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 97): +Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): +Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -497. calc.at:1371: testing Calculator parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} api.push-pull=both api.pure=full parse.lac=full ... - | (1 + 1) / (1 - 1) -./calc.at:1367: $PREPARSER ./calc input -./calc.at:1371: mv calc.y.tmp calc.y - stderr: -error: null divisor -./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1362: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1368: cat stderr -./calc.at:1371: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +stderr: +1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-16: error: 2222 != 1 +1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) +stderr: +./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1364: cat stderr +1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) input: - | (#) + (#) = 2222 -./calc.at:1360: $PREPARSER ./calc input -./calc.at:1362: cat stderr -./calc.at:1363: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 = 2 = 3 +input: +./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1370: $PREPARSER ./calc input +stderr: input: + | (1 + # + 1) = 1111 +stderr: + | (1 + # + 1) = 1111 +./calc.at:1362: $PREPARSER ./calc input +./calc.at:1360: $PREPARSER ./calc input +1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) stderr: - | - | +1 Starting parse Entering state 0 Stack now 0 @@ -78139,239 +80424,156 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 -Return for a new token: -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Return for a new token: -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 -Return for a new token: -1.6: syntax error: invalid character: '#' Reading a token -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) +Error: popping token error (1.2: ) Stack now 0 4 -Shifting token error (1.2-6: ) +Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) +Reading a token +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2: ) Stack now 0 4 -Shifting token error (1.2-6: ) +Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 -Return for a new token: Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Stack now 0 8 -Return for a new token: -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Stack now 0 8 19 -Return for a new token: -Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Stack now 0 8 19 28 -Return for a new token: -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Return for a new token: Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1369: $PREPARSER ./calc input -stderr: -2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -error: null divisor -./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) Entering state 4 -Stack now 0 4 +Stack now 0 8 21 4 Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) +Stack now 0 8 21 4 11 +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) +Error: popping token error (1.10: ) +Stack now 0 8 21 4 +Shifting token error (1.10: ) Entering state 11 -Stack now 0 4 11 +Stack now 0 8 21 4 11 Reading a token -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 114): + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 99): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) Entering state 4 Stack now 0 8 21 4 Reading a token -1.8: syntax error: invalid character: '#' -Shifting token error (1.8: ) +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 -Next token is token invalid token (1.8: ) -Error: discarding token invalid token (1.8: ) -Error: popping token error (1.8: ) +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) +Error: popping token error (1.16: ) Stack now 0 8 21 4 -Shifting token error (1.8: ) +Shifting token error (1.16: ) Entering state 11 Stack now 0 8 21 4 11 Reading a token -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) +Reducing stack by rule 14 (line 114): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) Entering state 30 Stack now 0 8 21 30 Reading a token -Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.13-16: 2222) -Shifting token number (1.13-16: 2222) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 7 (line 99): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) +Reducing stack by rule 4 (line 84): + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): +Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1363: cat stderr -input: +./calc.at:1367: cat stderr input: - | 1 + 2 * 3 + !+ ++ stderr: +stderr: +./calc.at:1368: cat stderr +./calc.at:1369: cat stderr +1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) Starting parse Entering state 0 Stack now 0 @@ -78381,102 +80583,95 @@ Entering state 4 Stack now 0 4 Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +1.6: syntax error: invalid character: '#' +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.2: ) +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) Stack now 0 4 -Shifting token error (1.2: ) +Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -1.8: syntax error: invalid character: '#' -Shifting token error (1.8: ) +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-8: ) Entering state 11 -Stack now 0 8 21 4 11 -Next token is token invalid token (1.8: ) -Error: discarding token invalid token (1.8: ) -Error: popping token error (1.8: ) -Stack now 0 8 21 4 -Shifting token error (1.8: ) +Stack now 0 4 11 +Reading a token +Next token is token number (1.10: 1) +Error: discarding token number (1.10: 1) +Error: popping token error (1.2-8: ) +Stack now 0 4 +Shifting token error (1.2-10: ) Entering state 11 -Stack now 0 8 21 4 11 +Stack now 0 4 11 Reading a token -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) Entering state 26 -Stack now 0 8 21 4 11 26 +Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) +Reading a token +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.13-16: 2222) -Shifting token number (1.13-16: 2222) +Next token is token number (1.15-18: 1111) +Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) + $1 = token number (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.17-2.0: ) +Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -78493,90 +80688,9 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | - | +1 -stderr: -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Stack now 0 8 21 5 14 -Reducing stack by rule 17 (line 117): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) + | 1 + 2 * 3 + !+ ++ +./calc.at:1364: $PREPARSER ./calc input +./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -78585,7 +80699,6 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 -Return for a new token: Reading a token Next token is token number (1.2: 1) Shifting token number (1.2: 1) @@ -78596,15 +80709,13 @@ -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 -Return for a new token: Reading a token Next token is token '+' (1.4: ) Shifting token '+' (1.4: ) Entering state 21 Stack now 0 4 12 21 -Return for a new token: -1.6: syntax error: invalid character: '#' Reading a token +1.6: syntax error: invalid character: '#' Error: popping token '+' (1.4: ) Stack now 0 4 12 Error: popping nterm exp (1.2: 1) @@ -78619,53 +80730,65 @@ Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 -Return for a new token: Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-8: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token number (1.10: 1) +Error: discarding token number (1.10: 1) +Error: popping token error (1.2-8: ) +Stack now 0 4 +Shifting token error (1.2-10: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 -Return for a new token: Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 -Return for a new token: Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) +Next token is token number (1.15-18: 1111) +Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) + $1 = token number (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 -Return for a new token: Reading a token -Next token is token '\n' (1.15-2.0: ) +Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -78674,7 +80797,6 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -78683,35 +80805,31 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1362: $PREPARSER ./calc input -stderr: -./calc.at:1364: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1368: $PREPARSER ./calc input -2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1360: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +498. calc.at:1374: testing Calculator %start input exp NUM api.value.type=union ... +./calc.at:1374: mv calc.y.tmp calc.y + +./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1374: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +input: stderr: + | (- *) + (1 2) = 1 +./calc.at:1367: $PREPARSER ./calc input stderr: -./calc.at:1369: cat stderr -2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +error: 2222 != 1 +./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 @@ -78721,12 +80839,12 @@ Entering state 21 Stack now 0 8 21 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 @@ -78736,18 +80854,18 @@ Entering state 22 Stack now 0 8 21 30 22 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): +Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) @@ -78755,7 +80873,7 @@ Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) @@ -78776,19 +80894,14 @@ Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 -Reducing stack by rule 17 (line 130): +Reducing stack by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1360: cat stderr -input: -./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1369: $PREPARSER ./calc /dev/null -./calc.at:1367: cat stderr stderr: -./calc.at:1358: "$PERL" -pi -e 'use strict; +./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -78798,21 +80911,20 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1371: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS -./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (#) + (#) = 2222 -./calc.at:1363: $PREPARSER ./calc input +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +error: 2222 != 1 +./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: + | (- *) + (1 2) = 1 stderr: -1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) - | (1 + #) = 1111 -./calc.at:1360: $PREPARSER ./calc input +./calc.at:1368: $PREPARSER ./calc input +1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) +stderr: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1369: $PREPARSER ./calc input +./calc.at:1371: cat stderr stderr: -./calc.at:1358: cat stderr -input: -./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -493. calc.at:1367: ok Starting parse Entering state 0 Stack now 0 @@ -78822,119 +80934,124 @@ Entering state 4 Stack now 0 4 Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +1.6: syntax error: invalid character: '#' +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 -Next token is token "invalid token" (1.2: ) -Error: discarding token "invalid token" (1.2: ) -Error: popping token error (1.2: ) +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) Stack now 0 4 -Shifting token error (1.2: ) +Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -1.8: syntax error: invalid character: '#' -Shifting token error (1.8: ) +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-8: ) Entering state 11 -Stack now 0 8 21 4 11 -Next token is token "invalid token" (1.8: ) -Error: discarding token "invalid token" (1.8: ) -Error: popping token error (1.8: ) -Stack now 0 8 21 4 -Shifting token error (1.8: ) +Stack now 0 4 11 +Reading a token +Next token is token number (1.10: 1) +Error: discarding token number (1.10: 1) +Error: popping token error (1.2-8: ) +Stack now 0 4 +Shifting token error (1.2-10: ) Entering state 11 -Stack now 0 8 21 4 11 +Stack now 0 4 11 Reading a token -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 127): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) +Reading a token +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token "number" (1.13-16: 2222) -Shifting token "number" (1.13-16: 2222) +Next token is token number (1.15-18: 1111) +Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) +Reducing stack by rule 5 (line 101): + $1 = token number (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 89): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) +Next token is token '\n' (1.19-2.0: ) +Reducing stack by rule 6 (line 102): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 78): +Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) +Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: +./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-17: error: 2222 != 1 +./calc.at:1363: cat stderr +./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.1-46: error: 4444 != 1 Starting parse Entering state 0 Stack now 0 @@ -78975,48 +81092,64 @@ Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-8: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token number (1.10: 1) +Error: discarding token number (1.10: 1) +Error: popping token error (1.2-8: ) +Stack now 0 4 +Shifting token error (1.2-10: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 127): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) +Next token is token number (1.15-18: 1111) +Shifting token number (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) + $1 = token number (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.15-2.0: ) +Next token is token '\n' (1.19-2.0: ) Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -79033,11 +81166,18 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | 1 + 2 * 3 + !- ++ -./calc.at:1364: $PREPARSER ./calc input -./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1370: cat stderr stderr: +./calc.at:1367: cat stderr +./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +input: +1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-17: error: 2222 != 1 + | + | +1 +./calc.at:1371: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -79108,128 +81248,71 @@ Entering state 5 Stack now 0 8 21 5 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Stack now 0 8 21 5 13 -Reducing stack by rule 18 (line 118): +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Stack now 0 8 21 5 14 +Reducing stack by rule 17 (line 117): $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) + $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 -Reading a token -1.6: syntax error: invalid character: '#' -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +input: +./calc.at:1364: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1360: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 + !+ ++ +./calc.at:1363: $PREPARSER ./calc input +2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) +1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.1-46: error: 4444 != 1 +input: +input: + | + | +1 +./calc.at:1362: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (* *) + (*) + (*) +./calc.at:1370: $PREPARSER ./calc input +stderr: +./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1367: $PREPARSER ./calc input +./calc.at:1360: cat stderr +./calc.at:1368: cat stderr +input: +stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 @@ -79239,12 +81322,12 @@ Entering state 21 Stack now 0 8 21 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 @@ -79254,18 +81337,18 @@ Entering state 22 Stack now 0 8 21 30 22 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): +Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) @@ -79273,7 +81356,7 @@ Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) @@ -79294,136 +81377,31 @@ Shifting token '+' (1.14: ) Entering state 14 Stack now 0 8 21 5 14 -Reducing stack by rule 17 (line 130): +Reducing stack by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) +2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1362: cat stderr + | 1 + 2 * 3 + !- ++ stderr: -./calc.at:1362: $EGREP -c -v 'Return for a new token:|LAC:' stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token "invalid token" (1.2: ) -Error: discarding token "invalid token" (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -1.8: syntax error: invalid character: '#' -Shifting token error (1.8: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token "invalid token" (1.8: ) -Error: discarding token "invalid token" (1.8: ) -Error: popping token error (1.8: ) -Stack now 0 8 21 4 -Shifting token error (1.8: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.13-16: 2222) -Shifting token "number" (1.13-16: 2222) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 89): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1364: $PREPARSER ./calc input +stderr: +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) +input: +./calc.at:1374: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +./calc.at:1369: cat stderr stderr: +input: Starting parse Entering state 0 Stack now 0 @@ -79504,51 +81482,18 @@ Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1369: cat stderr -input: -./calc.at:1360: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (# + 1) = 1111 -2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1360: cat stderr -./calc.at:1358: $PREPARSER ./calc input -input: - | 1 + 2 * 3 + !- ++ -./calc.at:1364: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1362: $PREPARSER ./calc input -input: -stderr: - | (# + 1) = 1111 -./calc.at:1368: cat stderr -./calc.at:1364: cat stderr + | (1 + 1) / (1 - 1) ./calc.at:1360: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 @@ -79558,12 +81503,12 @@ Entering state 21 Stack now 0 8 21 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 @@ -79573,18 +81518,18 @@ Entering state 22 Stack now 0 8 21 30 22 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): +Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) @@ -79592,7 +81537,7 @@ Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) @@ -79609,18 +81554,31 @@ Entering state 5 Stack now 0 8 21 5 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Stack now 0 8 21 5 13 -Reducing stack by rule 18 (line 131): +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Stack now 0 8 21 5 14 +Reducing stack by rule 17 (line 117): $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) + $2 = token '+' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1363: $EGREP -c -v 'Return for a new token:|LAC:' stderr + | (* *) + (*) + (*) +./calc.at:1368: $PREPARSER ./calc input +stderr: stderr: +./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +input: +2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) + | (1 + 1) / (1 - 1) +./calc.at:1371: cat stderr +./calc.at:1362: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -79630,76 +81588,122 @@ Entering state 4 Stack now 0 4 Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) -Error: discarding token number (1.6: 1) -Error: popping token error (1.2-4: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 +Shifting token number (1.6: 1) +Entering state 1 +Stack now 0 4 12 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 30 +Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Stack now 0 4 12 +Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): +Entering state 27 +Stack now 0 4 12 27 +Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) + $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) +-> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Stack now 0 8 19 +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 23 +Stack now 0 8 23 Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Stack now 0 8 23 4 +Reading a token +Next token is token number (1.12: 1) +Shifting token number (1.12: 1) Entering state 1 -Stack now 0 8 19 1 +Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Stack now 0 8 19 28 + $1 = token number (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Stack now 0 8 23 4 12 Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 20 +Stack now 0 8 23 4 12 20 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Stack now 0 8 23 4 12 20 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 29 +Stack now 0 8 23 4 12 20 29 +Reading a token +Next token is token ')' (1.17: ) +Reducing stack by rule 8 (line 113): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Stack now 0 8 23 4 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 27 +Stack now 0 8 23 4 12 27 +Reducing stack by rule 13 (line 126): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 32 +Stack now 0 8 23 32 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 10 (line 115): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -79717,7 +81721,11 @@ Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: -./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: + | (!!) + (1 2) = 1 +./calc.at:1369: $PREPARSER ./calc input +stderr: Starting parse Entering state 0 Stack now 0 @@ -79726,84 +81734,123 @@ Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 -Return for a new token: -1.2: syntax error: invalid character: '#' Reading a token -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Return for a new token: +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Return for a new token: +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 Reading a token Next token is token number (1.6: 1) -Error: discarding token number (1.6: 1) -Error: popping token error (1.2-4: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Return for a new token: +Shifting token number (1.6: 1) +Entering state 1 +Stack now 0 4 12 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 30 +Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Stack now 0 4 12 +Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): +Entering state 27 +Stack now 0 4 12 27 +Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) + $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) +-> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 -Return for a new token: Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Stack now 0 8 19 -Return for a new token: +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 23 +Stack now 0 8 23 Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Stack now 0 8 23 4 +Reading a token +Next token is token number (1.12: 1) +Shifting token number (1.12: 1) Entering state 1 -Stack now 0 8 19 1 +Stack now 0 8 23 4 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Stack now 0 8 19 28 -Return for a new token: + $1 = token number (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Stack now 0 8 23 4 12 Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 20 +Stack now 0 8 23 4 12 20 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Stack now 0 8 23 4 12 20 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 29 +Stack now 0 8 23 4 12 20 29 +Reading a token +Next token is token ')' (1.17: ) +Reducing stack by rule 8 (line 113): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Stack now 0 8 23 4 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 27 +Stack now 0 8 23 4 12 27 +Reducing stack by rule 13 (line 126): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 32 +Stack now 0 8 23 32 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 10 (line 115): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -79812,7 +81859,6 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -79821,33 +81867,14 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1369: $PREPARSER ./calc input -input: -./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 + 2 * 3 + !* ++ -stderr: -./calc.at:1364: $PREPARSER ./calc input ./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.1-46: error: 4444 != 1 -stderr: -./calc.at:1363: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1368: $PREPARSER ./calc /dev/null -stderr: +./calc.at:1371: $PREPARSER ./calc /dev/null +1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +input: Starting parse Entering state 0 Stack now 0 @@ -79918,136 +81945,54 @@ Entering state 5 Stack now 0 8 21 5 Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Stack now 0 8 21 5 15 -Reducing stack by rule 19 (line 119): +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Stack now 0 8 21 5 13 +Reducing stack by rule 18 (line 118): $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted + $2 = token '-' (1.14: ) Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1.6: 1) -Error: discarding token number (1.6: 1) -Error: popping token error (1.2-4: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: - +./calc.at:1370: cat stderr stderr: -./calc.at:1363: cat stderr +1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-16: error: 2222 != 1 + | 1 + 2 * 3 + !- ++ +./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1363: $PREPARSER ./calc input 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: -./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.1-46: error: 4444 != 1 +stderr: +./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +./calc.at:1370: $PREPARSER ./calc /dev/null +./calc.at:1364: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 @@ -80057,12 +82002,12 @@ Entering state 21 Stack now 0 8 21 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 @@ -80072,18 +82017,18 @@ Entering state 22 Stack now 0 8 21 30 22 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): +Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) @@ -80091,7 +82036,7 @@ Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) @@ -80112,7 +82057,7 @@ Shifting token '-' (1.14: ) Entering state 13 Stack now 0 8 21 5 13 -Reducing stack by rule 18 (line 131): +Reducing stack by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Stack now 0 8 21 @@ -80122,182 +82067,127 @@ Entering state 0 Stack now 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 +Stack now 0 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) Entering state 21 -Stack now 0 8 21 +Stack now 0 4 12 21 Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) +Next token is token number (1.6: 1) +Shifting token number (1.6: 1) Entering state 1 -Stack now 0 8 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) +Stack now 0 4 12 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.6: 1) +-> $$ = nterm exp (1.6: 1) Entering state 30 -Stack now 0 8 21 30 +Stack now 0 4 12 21 30 Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Stack now 0 8 21 30 22 +Next token is token ')' (1.7: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Stack now 0 4 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 27 +Stack now 0 4 12 27 +Reducing stack by rule 13 (line 126): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) +Entering state 8 +Stack now 0 8 Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Stack now 0 8 21 30 22 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Stack now 0 8 21 30 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 21 5 -Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Stack now 0 8 21 5 15 -Reducing stack by rule 19 (line 119): - $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted -Stack now 0 8 21 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1360: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -stderr: -1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) -Starting parse -Entering state 0 -Stack now 0 +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 23 +Stack now 0 8 23 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) Entering state 4 -Stack now 0 4 -Return for a new token: -1.2: syntax error: invalid character: '#' -Reading a token -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Return for a new token: -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Return for a new token: -Reading a token -Next token is token number (1.6: 1) -Error: discarding token number (1.6: 1) -Error: popping token error (1.2-4: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Return for a new token: +Stack now 0 8 23 4 Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Stack now 0 8 -Return for a new token: +Next token is token number (1.12: 1) +Shifting token number (1.12: 1) +Entering state 1 +Stack now 0 8 23 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Stack now 0 8 23 4 12 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Stack now 0 8 19 -Return for a new token: +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 20 +Stack now 0 8 23 4 12 20 Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) Entering state 1 -Stack now 0 8 19 1 +Stack now 0 8 23 4 12 20 1 Reducing stack by rule 5 (line 101): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Stack now 0 8 19 28 -Return for a new token: + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 29 +Stack now 0 8 23 4 12 20 29 Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) +Next token is token ')' (1.17: ) +Reducing stack by rule 8 (line 113): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Stack now 0 8 23 4 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 27 +Stack now 0 8 23 4 12 27 +Reducing stack by rule 13 (line 126): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 32 +Stack now 0 8 23 32 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 10 (line 115): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -80306,7 +82196,6 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 -Return for a new token: Reading a token Now at end of input. Shifting token end of file (2.1: ) @@ -80315,48 +82204,8 @@ Stack now 0 6 17 Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1362: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1360: cat stderr -./calc.at:1364: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -./calc.at:1364: cat stderr -input: - | (#) + (#) = 2222 -./calc.at:1364: $PREPARSER ./calc input -./calc.at:1369: cat stderr -./calc.at:1358: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (1 + #) = 1111 -./calc.at:1363: $PREPARSER ./calc input -stderr: +./calc.at:1367: cat stderr stderr: -./calc.at:1362: cat stderr Starting parse Entering state 0 Stack now 0 @@ -80366,12 +82215,12 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.2: 1) +Reducing stack by rule 5 (line 101): + $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 @@ -80381,437 +82230,338 @@ Entering state 21 Stack now 0 4 12 21 Reading a token -1.6: syntax error: invalid character: '#' -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token "invalid token" (1.6: ) -Error: discarding token "invalid token" (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 +Next token is token number (1.6: 1) +Shifting token number (1.6: 1) +Entering state 1 +Stack now 0 4 12 21 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 30 +Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) +Reducing stack by rule 7 (line 112): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Stack now 0 4 12 +Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 114): +Entering state 27 +Stack now 0 4 12 27 +Reducing stack by rule 13 (line 126): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) + $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) +-> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Stack now 0 8 19 +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 23 +Stack now 0 8 23 Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Stack now 0 8 23 4 +Reading a token +Next token is token number (1.12: 1) +Shifting token number (1.12: 1) Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Stack now 0 8 19 28 +Stack now 0 8 23 4 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Stack now 0 8 23 4 12 Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 89): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 20 +Stack now 0 8 23 4 12 20 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Stack now 0 8 23 4 12 20 1 +Reducing stack by rule 5 (line 101): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 29 +Stack now 0 8 23 4 12 20 29 +Reading a token +Next token is token ')' (1.17: ) +Reducing stack by rule 8 (line 113): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Stack now 0 8 23 4 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 27 +Stack now 0 8 23 4 12 27 +Reducing stack by rule 13 (line 126): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 32 +Stack now 0 8 23 32 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 10 (line 115): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) +Reducing stack by rule 4 (line 97): + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 78): +Reducing stack by rule 1 (line 91): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) +Shifting token end of file (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +stderr: +1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1364: cat stderr +1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-16: error: 2222 != 1 +./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1368: cat stderr +stderr: +./calc.at:1362: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) +input: +./calc.at:1369: cat stderr +./calc.at:1360: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token "invalid token" (1.2: ) -Error: discarding token "invalid token" (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -1.8: syntax error: invalid character: '#' -Shifting token error (1.8: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token "invalid token" (1.8: ) -Error: discarding token "invalid token" (1.8: ) -Error: popping token error (1.8: ) -Stack now 0 8 21 4 -Shifting token error (1.8: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token -Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 19 -Stack now 0 8 19 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 Reading a token -Next token is token "number" (1.13-16: 2222) -Shifting token "number" (1.13-16: 2222) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 -Stack now 0 8 19 1 +Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): - $1 = token "number" (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 28 -Stack now 0 8 19 28 + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 89): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 101): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 99): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -498. calc.at:1374: testing Calculator %start input exp NUM api.value.type=union ... -./calc.at:1358: cat stderr +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Stack now 0 8 21 5 13 +Reducing stack by rule 18 (line 118): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +input: + | 1 + 2 * 3 + !+ ++ +./calc.at:1367: $PREPARSER ./calc input stderr: +1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) + | 1 + 2 * 3 + !* ++ +./calc.at:1362: cat stderr +./calc.at:1364: $PREPARSER ./calc input +input: +./calc.at:1360: cat stderr +./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 + !+ ++ stderr: -./calc.at:1374: mv calc.y.tmp calc.y - +./calc.at:1368: $PREPARSER ./calc input +./calc.at:1371: cat stderr input: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 -Reading a token -1.6: syntax error: invalid character: '#' -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token "invalid token" (1.6: ) -Error: discarding token "invalid token" (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Stack now 0 8 19 1 +Stack now 0 1 Reducing stack by rule 5 (line 88): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 89): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - | (1 + # + 1) = 1111 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token "invalid token" (1.2: ) -Error: discarding token "invalid token" (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 21 Stack now 0 8 21 Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -1.8: syntax error: invalid character: '#' -Shifting token error (1.8: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token "invalid token" (1.8: ) -Error: discarding token "invalid token" (1.8: ) -Error: popping token error (1.8: ) -Stack now 0 8 21 4 -Shifting token error (1.8: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 114): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 Reading a token -Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 19 -Stack now 0 8 19 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 Reading a token -Next token is token "number" (1.13-16: 2222) -Shifting token "number" (1.13-16: 2222) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 -Stack now 0 8 19 1 +Stack now 0 8 21 30 22 1 Reducing stack by rule 5 (line 88): - $1 = token "number" (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 28 -Stack now 0 8 19 28 + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 89): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 101): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 99): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1374: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -./calc.at:1360: $PREPARSER ./calc input -input: - | (!!) + (1 2) = 1 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Stack now 0 8 21 5 15 +Reducing stack by rule 19 (line 119): + $1 = token '!' (1.13: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) + | (- *) + (1 2) = 1 +stderr: ./calc.at:1369: $PREPARSER ./calc input -./calc.at:1364: "$PERL" -pi -e 'use strict; +./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -80821,24 +82571,36 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -input: stderr: +./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +490. calc.at:1362: 489. calc.at:1360: ok + ok +./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1370: cat stderr +./calc.at:1367: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: - | 1 + 2 * 3 + !* ++ -./calc.at:1364: cat stderr -./calc.at:1362: $PREPARSER ./calc input +./calc.at:1363: cat stderr +1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-17: error: 2222 != 1 stderr: +stderr: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +input: +./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1371: $PREPARSER ./calc input +./calc.at:1368: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 @@ -80848,12 +82610,12 @@ Entering state 21 Stack now 0 8 21 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 @@ -80863,18 +82625,18 @@ Entering state 22 Stack now 0 8 21 30 22 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): +Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) @@ -80882,7 +82644,7 @@ Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) @@ -80903,14 +82665,32 @@ Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 -Reducing stack by rule 19 (line 132): +Reducing stack by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1363: "$PERL" -pi -e 'use strict; +input: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1370: $PREPARSER ./calc input + | 1 + 2 * 3 + !- ++ +./calc.at:1367: $PREPARSER ./calc input +stderr: +stderr: +1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-17: error: 2222 != 1 +stderr: +stderr: +1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.1-46: error: 4444 != 1 +input: +./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -80920,418 +82700,147 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 - | (1 + # + 1) = 1111 -stderr: -./calc.at:1363: cat stderr -1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-16: error: 2222 != 1 -./calc.at:1368: $PREPARSER ./calc input -stderr: -./calc.at:1358: $PREPARSER ./calc input -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 -Reading a token -1.6: syntax error: invalid character: '#' -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-8: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1.10: 1) -Error: discarding token number (1.10: 1) -Error: popping token error (1.2-8: ) -Stack now 0 4 -Shifting token error (1.2-10: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.15-18: 1111) -Shifting token number (1.15-18: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.19-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 -./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + + | 1 + 2 * 3 + !* ++ +./calc.at:1363: $PREPARSER ./calc input + | 1 + 2 * 3 + !- ++ + +./calc.at:1368: $PREPARSER ./calc input +stderr: +./calc.at:1364: cat stderr +./calc.at:1369: cat stderr +stderr: +./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Return for a new token: -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Return for a new token: +Stack now 0 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 21 -Stack now 0 4 12 21 -Return for a new token: -1.6: syntax error: invalid character: '#' -Reading a token -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Return for a new token: -Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-8: ) -Entering state 11 -Stack now 0 4 11 -Return for a new token: -Reading a token -Next token is token number (1.10: 1) -Error: discarding token number (1.10: 1) -Error: popping token error (1.2-8: ) -Stack now 0 4 -Shifting token error (1.2-10: ) -Entering state 11 -Stack now 0 4 11 -Return for a new token: +Stack now 0 8 21 Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) -Entering state 8 -Stack now 0 8 -Return for a new token: +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Stack now 0 8 21 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Stack now 0 8 21 30 Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) -Entering state 19 -Stack now 0 8 19 -Return for a new token: +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Stack now 0 8 21 30 22 Reading a token -Next token is token number (1.15-18: 1111) -Shifting token number (1.15-18: 1111) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) -Entering state 28 -Stack now 0 8 19 28 -Return for a new token: +Stack now 0 8 21 30 22 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Stack now 0 8 21 30 22 31 Reading a token -Next token is token '\n' (1.19-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 101): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Stack now 0 8 21 30 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 99): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Return for a new token: +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 21 5 +Reading a token +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Stack now 0 8 21 5 15 +Reducing stack by rule 19 (line 119): + $1 = token '!' (1.13: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted +Stack now 0 8 21 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) stderr: +./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 -./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: +stderr: input: + | (* *) + (*) + (*) +./calc.at:1369: $PREPARSER ./calc input +1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.1-46: error: 4444 != 1 stderr: -./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (# + 1) = 1111 -./calc.at:1363: $PREPARSER ./calc input -1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-16: error: 2222 != 1 + | (#) + (#) = 2222 +./calc.at:1364: $PREPARSER ./calc input stderr: stderr: +499. calc.at:1375: testing Calculator %start input exp NUM api.value.type=union %locations parse.error=detailed ... +./calc.at:1375: mv calc.y.tmp calc.y + +1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +500. calc.at:1387: testing Calculator %glr-parser ... Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Return for a new token: -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Return for a new token: -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 -Return for a new token: -1.6: syntax error: invalid character: '#' -Reading a token -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Return for a new token: -Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-8: ) -Entering state 11 -Stack now 0 4 11 -Return for a new token: -Reading a token -Next token is token number (1.10: 1) -Error: discarding token number (1.10: 1) -Error: popping token error (1.2-8: ) -Stack now 0 4 -Shifting token error (1.2-10: ) -Entering state 11 -Stack now 0 4 11 -Return for a new token: -Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) -Entering state 8 -Stack now 0 8 -Return for a new token: -Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) -Entering state 19 -Stack now 0 8 19 -Return for a new token: -Reading a token -Next token is token number (1.15-18: 1111) -Shifting token number (1.15-18: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) -Entering state 28 -Stack now 0 8 19 28 -Return for a new token: -Reading a token -Next token is token '\n' (1.19-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Return for a new token: -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1368: cat stderr - | (1 + #) = 1111 -./calc.at:1374: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS -./calc.at:1369: cat stderr -./calc.at:1364: $PREPARSER ./calc input -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Stack now 0 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.1: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 @@ -81341,12 +82850,12 @@ Entering state 21 Stack now 0 8 21 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Stack now 0 8 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.5: 2) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 30 Stack now 0 8 21 30 @@ -81356,18 +82865,18 @@ Entering state 22 Stack now 0 8 21 30 22 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 Stack now 0 8 21 30 22 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.9: 3) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 31 Stack now 0 8 21 30 22 31 Reading a token Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 114): +Reducing stack by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) @@ -81375,7 +82884,7 @@ Entering state 30 Stack now 0 8 21 30 Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) @@ -81396,24 +82905,18 @@ Shifting token '*' (1.14: ) Entering state 15 Stack now 0 8 21 5 15 -Reducing stack by rule 19 (line 132): +Reducing stack by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Stack now 0 8 21 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1371: cat stderr stderr: -./calc.at:1358: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1375: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +./calc.at:1387: mv calc.y.tmp calc.y + Starting parse Entering state 0 Stack now 0 @@ -81435,198 +82938,113 @@ Entering state 11 Stack now 0 4 11 Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token "number" (1.6: 1) -Error: discarding token "number" (1.6: 1) -Error: popping token error (1.2-4: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 89): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -stderr: -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) Entering state 21 -Stack now 0 4 12 21 +Stack now 0 8 21 Reading a token -1.6: syntax error: invalid character: '#' -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Stack now 0 8 21 4 Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-8: ) +1.8: syntax error: invalid character: '#' +Shifting token error (1.8: ) Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1.10: 1) -Error: discarding token number (1.10: 1) -Error: popping token error (1.2-8: ) -Stack now 0 4 -Shifting token error (1.2-10: ) +Stack now 0 8 21 4 11 +Next token is token "invalid token" (1.8: ) +Error: discarding token "invalid token" (1.8: ) +Error: popping token error (1.8: ) +Stack now 0 8 21 4 +Shifting token error (1.8: ) Entering state 11 -Stack now 0 4 11 +Stack now 0 8 21 4 11 Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 114): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack by rule 7 (line 99): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 -Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.15-18: 1111) -Shifting token number (1.15-18: 1111) +Next token is token "number" (1.13-16: 2222) +Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.19-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) +Next token is token '\n' (1.17-2.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) +Reducing stack by rule 4 (line 84): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): +Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -input: -./calc.at:1360: "$PERL" -pi -e 'use strict; +./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1387: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +./calc.at:1370: cat stderr +./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1368: cat stderr +./calc.at:1367: cat stderr +./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -81636,6 +83054,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +stderr: +input: Starting parse Entering state 0 Stack now 0 @@ -81645,79 +83065,102 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 -Reading a token -1.6: syntax error: invalid character: '#' -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) +1.2: syntax error: invalid character: '#' +Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 -Next token is token "invalid token" (1.6: ) -Error: discarding token "invalid token" (1.6: ) -Error: popping token error (1.2-6: ) +Next token is token "invalid token" (1.2: ) +Error: discarding token "invalid token" (1.2: ) +Error: popping token error (1.2: ) Stack now 0 4 -Shifting token error (1.2-6: ) +Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) +Entering state 21 +Stack now 0 8 21 +Reading a token +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Stack now 0 8 21 4 +Reading a token +1.8: syntax error: invalid character: '#' +Shifting token error (1.8: ) +Entering state 11 +Stack now 0 8 21 4 11 +Next token is token "invalid token" (1.8: ) +Error: discarding token "invalid token" (1.8: ) +Error: popping token error (1.8: ) +Stack now 0 8 21 4 +Shifting token error (1.8: ) +Entering state 11 +Stack now 0 8 21 4 11 +Reading a token +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 26 +Stack now 0 8 21 4 11 26 +Reducing stack by rule 14 (line 114): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack by rule 7 (line 99): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) +Next token is token "number" (1.13-16: 2222) +Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) + $1 = token "number" (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.15-2.0: ) +Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -81734,7 +83177,31 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1362: "$PERL" -pi -e 'use strict; +input: +stderr: + | (!!) + (1 2) = 1 +./calc.at:1371: $PREPARSER ./calc input +./calc.at:1363: cat stderr + | (!!) + (1 2) = 1 +./calc.at:1370: $PREPARSER ./calc input +input: +1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +stderr: +stderr: + | 1 + 2 * 3 + !* ++ +./calc.at:1368: $PREPARSER ./calc input +1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-16: error: 2222 != 1 +input: +stderr: +1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-16: error: 2222 != 1 +1.14: memory exhausted +./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 + !* ++ +./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -81744,27 +83211,25 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1367: $PREPARSER ./calc input +./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: - | (!!) + (1 2) = 1 -./calc.at:1368: $PREPARSER ./calc input - | (- *) + (1 2) = 1 +./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1369: $PREPARSER ./calc input -1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-16: error: 2222 != 1 -./calc.at:1358: cat stderr -./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1360: cat stderr + | (#) + (#) = 2222 +./calc.at:1369: cat stderr +./calc.at:1363: $PREPARSER ./calc input +./calc.at:1387: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +./calc.at:1364: cat stderr +memory exhausted stderr: -./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-17: error: 2222 != 1 -./calc.at:1362: cat stderr +./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: -./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-16: error: 2222 != 1 +1.14: memory exhausted Starting parse Entering state 0 Stack now 0 @@ -81786,162 +83251,90 @@ Entering state 11 Stack now 0 4 11 Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token "number" (1.6: 1) -Error: discarding token "number" (1.6: 1) -Error: popping token error (1.2-4: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 89): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -Starting parse -Entering state 0 -Stack now 0 +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) +Entering state 21 +Stack now 0 8 21 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) Entering state 4 -Stack now 0 4 -Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 +Stack now 0 8 21 4 Reading a token -1.6: syntax error: invalid character: '#' -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) +1.8: syntax error: invalid character: '#' +Shifting token error (1.8: ) Entering state 11 -Stack now 0 4 11 -Next token is token "invalid token" (1.6: ) -Error: discarding token "invalid token" (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-6: ) +Stack now 0 8 21 4 11 +Next token is token "invalid token" (1.8: ) +Error: discarding token "invalid token" (1.8: ) +Error: popping token error (1.8: ) +Stack now 0 8 21 4 +Shifting token error (1.8: ) Entering state 11 -Stack now 0 4 11 +Stack now 0 8 21 4 11 Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) Entering state 26 -Stack now 0 4 11 26 +Stack now 0 8 21 4 11 26 Reducing stack by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 30 +Stack now 0 8 21 30 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack by rule 7 (line 99): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) +Next token is token "number" (1.13-16: 2222) +Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) + $1 = token "number" (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.15-2.0: ) +Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 89): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -81958,654 +83351,22 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: -1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-17: error: 2222 != 1 -input: -input: -stderr: -input: - | (1 + 1) / (1 - 1) - | (1 + 1) / (1 - 1) +./calc.at:1375: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 -./calc.at:1360: $PREPARSER ./calc input -./calc.at:1363: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1358: $PREPARSER ./calc input stderr: +input: +./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 + !+ ++ +./calc.at:1369: $PREPARSER ./calc input +memory exhausted ./calc.at:1368: cat stderr -./calc.at:1369: cat stderr -./calc.at:1363: cat stderr -./calc.at:1364: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 -Reading a token -Next token is token number (1.6: 1) -Shifting token number (1.6: 1) -Entering state 1 -Stack now 0 4 12 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 30 -Stack now 0 4 12 21 30 -Reading a token -Next token is token ')' (1.7: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Stack now 0 4 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 27 -Stack now 0 4 12 27 -Reducing stack by rule 13 (line 126): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 23 -Stack now 0 8 23 -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Stack now 0 8 23 4 -Reading a token -Next token is token number (1.12: 1) -Shifting token number (1.12: 1) -Entering state 1 -Stack now 0 8 23 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Stack now 0 8 23 4 12 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 20 -Stack now 0 8 23 4 12 20 -Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) -Entering state 1 -Stack now 0 8 23 4 12 20 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 29 -Stack now 0 8 23 4 12 20 29 -Reading a token -Next token is token ')' (1.17: ) -Reducing stack by rule 8 (line 113): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Stack now 0 8 23 4 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 27 -Stack now 0 8 23 4 12 27 -Reducing stack by rule 13 (line 126): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 32 -Stack now 0 8 23 32 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 10 (line 115): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Return for a new token: -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Return for a new token: -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 -Return for a new token: -Reading a token -Next token is token number (1.6: 1) -Shifting token number (1.6: 1) -Entering state 1 -Stack now 0 4 12 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 30 -Stack now 0 4 12 21 30 -Return for a new token: -Reading a token -Next token is token ')' (1.7: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Stack now 0 4 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 27 -Stack now 0 4 12 27 -Reducing stack by rule 13 (line 126): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) -Entering state 8 -Stack now 0 8 -Return for a new token: -Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 23 -Stack now 0 8 23 -Return for a new token: -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Stack now 0 8 23 4 -Return for a new token: -Reading a token -Next token is token number (1.12: 1) -Shifting token number (1.12: 1) -Entering state 1 -Stack now 0 8 23 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Stack now 0 8 23 4 12 -Return for a new token: -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 20 -Stack now 0 8 23 4 12 20 -Return for a new token: -Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) -Entering state 1 -Stack now 0 8 23 4 12 20 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 29 -Stack now 0 8 23 4 12 20 29 -Return for a new token: -Reading a token -Next token is token ')' (1.17: ) -Reducing stack by rule 8 (line 113): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Stack now 0 8 23 4 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 27 -Stack now 0 8 23 4 12 27 -Reducing stack by rule 13 (line 126): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 32 -Stack now 0 8 23 32 -Return for a new token: -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 10 (line 115): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Return for a new token: -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1358: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1364: cat stderr -./calc.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (#) + (#) = 2222 -./calc.at:1362: $PREPARSER ./calc input input: +./calc.at:1371: cat stderr stderr: - | (- *) + (1 2) = 1 -stderr: -./calc.at:1368: $PREPARSER ./calc input -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 -Reading a token -Next token is token number (1.6: 1) -Shifting token number (1.6: 1) -Entering state 1 -Stack now 0 4 12 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 30 -Stack now 0 4 12 21 30 -Reading a token -Next token is token ')' (1.7: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Stack now 0 4 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 27 -Stack now 0 4 12 27 -Reducing stack by rule 13 (line 126): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 23 -Stack now 0 8 23 -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Stack now 0 8 23 4 -Reading a token -Next token is token number (1.12: 1) -Shifting token number (1.12: 1) -Entering state 1 -Stack now 0 8 23 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Stack now 0 8 23 4 12 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 20 -Stack now 0 8 23 4 12 20 -Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) -Entering state 1 -Stack now 0 8 23 4 12 20 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 29 -Stack now 0 8 23 4 12 20 29 -Reading a token -Next token is token ')' (1.17: ) -Reducing stack by rule 8 (line 113): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Stack now 0 8 23 4 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 27 -Stack now 0 8 23 4 12 27 -Reducing stack by rule 13 (line 126): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 32 -Stack now 0 8 23 32 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 10 (line 115): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) stderr: + | (1 + #) = 1111 stderr: -1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-17: error: 2222 != 1 -input: -./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Return for a new token: -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Return for a new token: -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 -Return for a new token: -Reading a token -Next token is token number (1.6: 1) -Shifting token number (1.6: 1) -Entering state 1 -Stack now 0 4 12 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 30 -Stack now 0 4 12 21 30 -Return for a new token: -Reading a token -Next token is token ')' (1.7: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Stack now 0 4 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 27 -Stack now 0 4 12 27 -Reducing stack by rule 13 (line 126): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) -Entering state 8 -Stack now 0 8 -Return for a new token: -Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 23 -Stack now 0 8 23 -Return for a new token: -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Stack now 0 8 23 4 -Return for a new token: -Reading a token -Next token is token number (1.12: 1) -Shifting token number (1.12: 1) -Entering state 1 -Stack now 0 8 23 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Stack now 0 8 23 4 12 -Return for a new token: -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 20 -Stack now 0 8 23 4 12 20 -Return for a new token: -Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) -Entering state 1 -Stack now 0 8 23 4 12 20 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 29 -Stack now 0 8 23 4 12 20 29 -Return for a new token: -Reading a token -Next token is token ')' (1.17: ) -Reducing stack by rule 8 (line 113): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Stack now 0 8 23 4 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 27 -Stack now 0 8 23 4 12 27 -Reducing stack by rule 13 (line 126): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 32 -Stack now 0 8 23 32 -Return for a new token: -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 10 (line 115): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Return for a new token: -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - | (1 + # + 1) = 1111 -./calc.at:1363: $PREPARSER ./calc input -input: -input: Starting parse Entering state 0 Stack now 0 @@ -82619,8 +83380,8 @@ Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) +Next token is token "invalid token" (1.2: ) +Error: discarding token "invalid token" (1.2: ) Error: popping token error (1.2: ) Stack now 0 4 Shifting token error (1.2: ) @@ -82631,7 +83392,7 @@ Shifting token ')' (1.3: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) @@ -82653,8 +83414,8 @@ Shifting token error (1.8: ) Entering state 11 Stack now 0 8 21 4 11 -Next token is token invalid token (1.8: ) -Error: discarding token invalid token (1.8: ) +Next token is token "invalid token" (1.8: ) +Error: discarding token "invalid token" (1.8: ) Error: popping token error (1.8: ) Stack now 0 8 21 4 Shifting token error (1.8: ) @@ -82665,7 +83426,7 @@ Shifting token ')' (1.9: ) Entering state 26 Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) @@ -82674,7 +83435,7 @@ Stack now 0 8 21 30 Reading a token Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) @@ -82686,18 +83447,18 @@ Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.13-16: 2222) -Shifting token number (1.13-16: 2222) +Next token is token "number" (1.13-16: 2222) +Shifting token "number" (1.13-16: 2222) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.13-16: 2222) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.13-16: 2222) -> $$ = nterm exp (1.13-16: 2222) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 102): +Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) $3 = nterm exp (1.13-16: 2222) @@ -82708,27 +83469,35 @@ Shifting token '\n' (1.17-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 97): +Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-16: 2222) $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): +Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1364: $PREPARSER ./calc input +./calc.at:1370: cat stderr +stdout: +./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -stderr: +input: +./calc.at:1374: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +input: + | (#) + (#) = 2222 +./calc.at:1368: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -82769,64 +83538,48 @@ Entering state 11 Stack now 0 4 11 Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-8: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token "number" (1.10: 1) -Error: discarding token "number" (1.10: 1) -Error: popping token error (1.2-8: ) -Stack now 0 4 -Shifting token error (1.2-10: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token "number" (1.15-18: 1111) -Shifting token "number" (1.15-18: 1111) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): - $1 = token "number" (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.19-2.0: ) +Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -82843,8 +83596,7 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | (* *) + (*) + (*) -./calc.at:1360: "$PERL" -pi -e 'use strict; +./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -82854,14 +83606,43 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1369: $PREPARSER ./calc input + | (- *) + (1 2) = 1 +./calc.at:1371: $PREPARSER ./calc input +./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +input: +stderr: +stderr: +./calc.at:1367: cat stderr + | (- *) + (1 2) = 1 +./calc.at:1374: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c + 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 -./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1369: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1370: $PREPARSER ./calc input +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1363: cat stderr stderr: +./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1360: cat stderr +stderr: +1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-17: error: 2222 != 1 +input: Starting parse Entering state 0 Stack now 0 @@ -82902,64 +83683,48 @@ Entering state 11 Stack now 0 4 11 Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-8: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token "number" (1.10: 1) -Error: discarding token "number" (1.10: 1) -Error: popping token error (1.2-8: ) -Stack now 0 4 -Shifting token error (1.2-10: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token "number" (1.15-18: 1111) -Shifting token "number" (1.15-18: 1111) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): - $1 = token "number" (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.19-2.0: ) +Next token is token '\n' (1.15-2.0: ) Reducing stack by rule 6 (line 89): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -82976,24 +83741,42 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -./calc.at:1368: cat stderr - | (# + 1) = 1111 -./calc.at:1358: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1364: $PREPARSER ./calc input -./calc.at:1363: "$PERL" -pi -e 'use strict; +input: +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' + | (#) + (#) = 2222 +input: +./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1367: $PREPARSER ./calc input + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1374: $PREPARSER ./calc input +stderr: +input: +stderr: +stderr: + | (1 + #) = 1111 +./calc.at:1363: $PREPARSER ./calc input +1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-17: error: 2222 != 1 +syntax error: invalid character: '#' +syntax error: invalid character: '#' + | 1 + 2 * 3 + !- ++ +./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1369: $PREPARSER ./calc input +./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -83005,9 +83788,7 @@ ' expout || exit 77 stderr: stderr: -489. calc.at:1360: ok -./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1363: cat stderr +stderr: Starting parse Entering state 0 Stack now 0 @@ -83017,150 +83798,32 @@ Entering state 4 Stack now 0 4 Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 21 -Stack now 0 8 21 -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Stack now 0 8 21 4 -Reading a token -1.8: syntax error: invalid character: '#' -Shifting token error (1.8: ) -Entering state 11 -Stack now 0 8 21 4 11 -Next token is token invalid token (1.8: ) -Error: discarding token invalid token (1.8: ) -Error: popping token error (1.8: ) -Stack now 0 8 21 4 -Shifting token error (1.8: ) -Entering state 11 -Stack now 0 8 21 4 11 -Reading a token -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 26 -Stack now 0 8 21 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 30 -Stack now 0 8 21 30 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 112): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.13-16: 2222) -Shifting token number (1.13-16: 2222) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token "invalid token" (1.2: ) -Error: discarding token "invalid token" (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 +Stack now 0 4 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 Reading a token Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Error: popping token error (1.2: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +1.6: syntax error: invalid character: '#' +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) Stack now 0 4 -Shifting token error (1.2-4: ) +Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 -Reading a token -Next token is token "number" (1.6: 1) -Error: discarding token "number" (1.6: 1) -Error: popping token error (1.2-4: ) +Next token is token "invalid token" (1.6: ) +Error: discarding token "invalid token" (1.6: ) +Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 @@ -83224,18 +83887,26 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1358: cat stderr -input: +./calc.at:1368: cat stderr +./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-17: error: 2222 != 1 +./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +stderr: +./calc.at:1364: cat stderr +syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1374: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1371: cat stderr input: -1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) - | (1 + 1) / (1 - 1) -./calc.at:1363: $PREPARSER ./calc input - +./calc.at:1370: cat stderr stderr: -./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: + | (1 + #) = 1111 +./calc.at:1368: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -83260,107 +83931,64 @@ Entering state 21 Stack now 0 4 12 21 Reading a token -Next token is token "number" (1.6: 1) -Shifting token "number" (1.6: 1) -Entering state 1 -Stack now 0 4 12 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 30 -Stack now 0 4 12 21 30 -Reading a token -Next token is token ')' (1.7: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 +1.6: syntax error: invalid character: '#' +Error: popping token '+' (1.4: ) Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token "invalid token" (1.6: ) +Error: discarding token "invalid token" (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) -Entering state 27 -Stack now 0 4 12 27 -Reducing stack by rule 13 (line 113): +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) + $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 23 -Stack now 0 8 23 -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Stack now 0 8 23 4 -Reading a token -Next token is token "number" (1.12: 1) -Shifting token "number" (1.12: 1) -Entering state 1 -Stack now 0 8 23 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Stack now 0 8 23 4 12 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 20 -Stack now 0 8 23 4 12 20 +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 -Stack now 0 8 23 4 12 20 1 +Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 29 -Stack now 0 8 23 4 12 20 29 -Reading a token -Next token is token ')' (1.17: ) -Reducing stack by rule 8 (line 100): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Stack now 0 8 23 4 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 27 -Stack now 0 8 23 4 12 27 -Reducing stack by rule 13 (line 113): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 32 -Stack now 0 8 23 32 + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 10 (line 102): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -83377,17 +84005,29 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +input: stderr: -./calc.at:1362: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +input: +1.6: syntax error: invalid character: '#' +./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | (* *) + (*) + (*) +./calc.at:1371: $PREPARSER ./calc input + | 1 2 + | (# + 1) = 1111 +./calc.at:1364: $PREPARSER ./calc input +./calc.at:1374: $PREPARSER ./calc input +stderr: +stderr: +stderr: +./calc.at:1367: cat stderr +1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +input: +stderr: + | (* *) + (*) + (*) +1.6: syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 @@ -83483,31 +84123,40 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1369: cat stderr +./calc.at:1363: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1370: $PREPARSER ./calc input +syntax error +./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +input: +./calc.at:1363: cat stderr stderr: - | (* *) + (*) + (*) -stdout: -./calc.at:1368: $PREPARSER ./calc input -./calc.at:1370: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -488. calc.at:1358: ok -./calc.at:1362: cat stderr -./calc.at:1370: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c - stderr: input: +./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (1 + #) = 1111 -./calc.at:1362: $PREPARSER ./calc input +./calc.at:1368: cat stderr +syntax error +1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) stderr: -./calc.at:1369: cat stderr +./calc.at:1367: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -83517,32 +84166,29 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 +1.2: syntax error: invalid character: '#' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token "invalid token" (1.2: ) +Error: discarding token "invalid token" (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 -Reading a token -1.6: syntax error: invalid character: '#' -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) +Error: discarding token '+' (1.4: ) +Error: popping token error (1.2: ) Stack now 0 4 -Shifting token error (1.2-6: ) +Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) +Reading a token +Next token is token "number" (1.6: 1) +Error: discarding token "number" (1.6: 1) +Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 @@ -83552,7 +84198,7 @@ Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) @@ -83565,18 +84211,18 @@ Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.11-14: 1111) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 102): +Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) @@ -83587,28 +84233,40 @@ Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 97): +Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): +Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +stderr: + | 1 + 2 * 3 + !* ++ +./calc.at:1369: $PREPARSER ./calc input +stderr: +input: +syntax error: invalid character: '#' +stderr: +./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.14: memory exhausted +input: + | (# + 1) = 1111 +./calc.at:1363: $PREPARSER ./calc input stderr: ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} @@ -83620,6 +84278,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1371: cat stderr + | (# + 1) = 1111 +./calc.at:1368: $PREPARSER ./calc input +stderr: Starting parse Entering state 0 Stack now 0 @@ -83629,122 +84292,76 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 +1.2: syntax error: invalid character: '#' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token "invalid token" (1.2: ) +Error: discarding token "invalid token" (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 +Error: discarding token '+' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 Reading a token Next token is token "number" (1.6: 1) -Shifting token "number" (1.6: 1) -Entering state 1 -Stack now 0 4 12 21 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 30 -Stack now 0 4 12 21 30 +Error: discarding token "number" (1.6: 1) +Error: popping token error (1.2-4: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 Reading a token Next token is token ')' (1.7: ) -Reducing stack by rule 7 (line 99): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Stack now 0 4 12 -Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) -Entering state 27 -Stack now 0 4 12 27 -Reducing stack by rule 13 (line 113): +Entering state 26 +Stack now 0 4 11 26 +Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) + $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 23 -Stack now 0 8 23 -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Stack now 0 8 23 4 -Reading a token -Next token is token "number" (1.12: 1) -Shifting token "number" (1.12: 1) -Entering state 1 -Stack now 0 8 23 4 1 -Reducing stack by rule 5 (line 88): - $1 = token "number" (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Stack now 0 8 23 4 12 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 20 -Stack now 0 8 23 4 12 20 +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Stack now 0 8 19 Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 -Stack now 0 8 23 4 12 20 1 +Stack now 0 8 19 1 Reducing stack by rule 5 (line 88): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 29 -Stack now 0 8 23 4 12 20 29 -Reading a token -Next token is token ')' (1.17: ) -Reducing stack by rule 8 (line 100): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Stack now 0 8 23 4 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 27 -Stack now 0 8 23 4 12 27 -Reducing stack by rule 13 (line 113): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 32 -Stack now 0 8 23 32 + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 10 (line 102): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 Reducing stack by rule 4 (line 84): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -83761,27 +84378,33 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +syntax error: invalid character: '#' +stderr: +./calc.at:1374: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error: invalid character: '#' ./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1370: cat stderr stderr: +./calc.at:1364: cat stderr +1.14: memory exhausted input: stderr: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1370: $PREPARSER ./calc input - +stderr: + | 1 + 2 * 3 + !+ ++ +1.2: syntax error: invalid character: '#' +./calc.at:1371: $PREPARSER ./calc input +stderr: +./calc.at:1369: cat stderr Starting parse Entering state 0 Stack now 0 @@ -83791,32 +84414,29 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 +1.2: syntax error: invalid character: '#' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token "invalid token" (1.2: ) +Error: discarding token "invalid token" (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 -Reading a token -1.6: syntax error: invalid character: '#' -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) +Error: discarding token '+' (1.4: ) +Error: popping token error (1.2: ) Stack now 0 4 -Shifting token error (1.2-6: ) +Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) +Reading a token +Next token is token "number" (1.6: 1) +Error: discarding token "number" (1.6: 1) +Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-6: ) Entering state 11 @@ -83826,7 +84446,7 @@ Shifting token ')' (1.7: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) @@ -83839,18 +84459,18 @@ Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.11-14: 1111) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.11-14: 1111) -> $$ = nterm exp (1.11-14: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 102): +Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-7: 1111) $2 = token '=' (1.9: ) $3 = nterm exp (1.11-14: 1111) @@ -83861,75 +84481,41 @@ Shifting token '\n' (1.15-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 97): +Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-14: 1111) $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): +Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | 1 + 2 * 3 + !+ ++ -./calc.at:1369: $PREPARSER ./calc input -1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -./calc.at:1363: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1364: cat stderr -499. calc.at:1375: testing Calculator %start input exp NUM api.value.type=union %locations parse.error=detailed ... -./calc.at:1375: mv calc.y.tmp calc.y - -./calc.at:1375: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -stderr: -./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1370: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1368: cat stderr -./calc.at:1363: cat stderr -./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1362: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -491. calc.at:1363: ok - | (1 + # + 1) = 1111 input: +./calc.at:1374: cat stderr input: -./calc.at:1364: $PREPARSER ./calc input - | 1 2 +./calc.at:1367: cat stderr + | 1 + 2 * 3 + !+ ++ + | (1 + # + 1) = 1111 ./calc.at:1370: $PREPARSER ./calc input +./calc.at:1364: $PREPARSER ./calc input stderr: +./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: stderr: +input: +./calc.at:1368: cat stderr stderr: -./calc.at:1369: $EGREP -c -v 'Return for a new token:|LAC:' stderr + | (#) + (#) = 2222 Starting parse Entering state 0 Stack now 0 @@ -84044,23 +84630,40 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | 1 + 2 * 3 + !+ ++ -./calc.at:1368: $PREPARSER ./calc input +input: +./calc.at:1369: $PREPARSER ./calc input + | (# + 1) = 1111 +./calc.at:1363: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | 1//2 +./calc.at:1367: $PREPARSER ./calc input stderr: -1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) -./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1375: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS -500. calc.at:1387: testing Calculator %glr-parser ... -./calc.at:1387: mv calc.y.tmp calc.y - -./calc.at:1387: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -./calc.at:1362: cat stderr -./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1374: $PREPARSER ./calc input ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1371: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +stderr: +syntax error: invalid character: '#' input: +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + # + 1) = 1111 stderr: - | (# + 1) = 1111 +stderr: +./calc.at:1368: $PREPARSER ./calc input +./calc.at:1363: cat stderr Starting parse Entering state 0 Stack now 0 @@ -84175,112 +84778,19 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - stderr: -./calc.at:1362: $PREPARSER ./calc input stderr: +./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1370: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: input: -./calc.at:1368: $EGREP -c -v 'Return for a new token:|LAC:' stderr +syntax error +syntax error: invalid character: '#' | 1 + 2 * 3 + !- ++ -1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1.6: 1) -Error: discarding token number (1.6: 1) -Error: popping token error (1.2-4: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1369: $PREPARSER ./calc input -./calc.at:1387: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +./calc.at:1371: $PREPARSER ./calc input +1.6: syntax error: invalid character: '#' +./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: ./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -84291,14 +84801,24 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +input: stderr: -stdout: stderr: -./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./calc.at:1374: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +input: ./calc.at:1364: cat stderr + | (1 + # + 1) = 1111 +./calc.at:1363: $PREPARSER ./calc input +./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.6: syntax error: invalid character: '#' + | 1 + 2 * 3 + !- ++ +./calc.at:1370: $PREPARSER ./calc input +stderr: +./calc.at:1367: cat stderr +stderr: stderr: +./calc.at:1369: cat stderr Starting parse Entering state 0 Stack now 0 @@ -84308,106 +84828,113 @@ Entering state 4 Stack now 0 4 Reading a token -1.2: syntax error: invalid character: '#' -Shifting token error (1.2: ) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Stack now 0 4 12 21 +Reading a token +1.6: syntax error: invalid character: '#' +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.2: ) +Next token is token "invalid token" (1.6: ) +Error: discarding token "invalid token" (1.6: ) +Error: popping token error (1.2-6: ) Stack now 0 4 -Shifting token error (1.2: ) +Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Error: popping token error (1.2: ) +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Error: popping token error (1.2-6: ) Stack now 0 4 -Shifting token error (1.2-4: ) +Shifting token error (1.2-8: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token number (1.6: 1) -Error: discarding token number (1.6: 1) -Error: popping token error (1.2-4: ) +Next token is token "number" (1.10: 1) +Error: discarding token "number" (1.10: 1) +Error: popping token error (1.2-8: ) Stack now 0 4 -Shifting token error (1.2-6: ) +Shifting token error (1.2-10: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) +Next token is token "number" (1.15-18: 1111) +Shifting token "number" (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) +Next token is token '\n' (1.19-2.0: ) +Reducing stack by rule 6 (line 89): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) +Reducing stack by rule 4 (line 84): + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): +Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1370: cat stderr -./calc.at:1374: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c - -./calc.at:1371: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' -./calc.at:1362: "$PERL" -pi -e 'use strict; +input: +./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -84417,55 +84944,22 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1368: cat stderr + | (1 + 1) / (1 - 1) input: -./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | 1 + 2 * 3 + !- ++ -./calc.at:1368: $PREPARSER ./calc input +./calc.at:1364: $PREPARSER ./calc input + | (1 + # + 1) = 1111 +./calc.at:1367: $PREPARSER ./calc input +./calc.at:1371: cat stderr stderr: -./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: - | (1 + 1) / (1 - 1) -stderr: -501. calc.at:1389: testing Calculator %glr-parser %header ... -./calc.at:1389: mv calc.y.tmp calc.y - -./calc.at:1364: $PREPARSER ./calc input - | 1//2 -./calc.at:1370: $PREPARSER ./calc input stderr: -input: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1389: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y + | (1 + #) = 1111 +./calc.at:1369: $PREPARSER ./calc input stderr: -./calc.at:1371: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c - -./calc.at:1374: $PREPARSER ./calc input -./calc.at:1362: cat stderr -1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) -./calc.at:1369: cat stderr Starting parse Entering state 0 Stack now 0 @@ -84607,32 +85101,6 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1368: cat stderr -input: - | (1 + # + 1) = 1111 -./calc.at:1362: $PREPARSER ./calc input -./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -input: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1371: $PREPARSER ./calc input -./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: Starting parse Entering state 0 Stack now 0 @@ -84642,12 +85110,12 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 @@ -84665,8 +85133,8 @@ Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) +Next token is token "invalid token" (1.6: ) +Error: discarding token "invalid token" (1.6: ) Error: popping token error (1.2-6: ) Stack now 0 4 Shifting token error (1.2-6: ) @@ -84681,8 +85149,8 @@ Entering state 11 Stack now 0 4 11 Reading a token -Next token is token number (1.10: 1) -Error: discarding token number (1.10: 1) +Next token is token "number" (1.10: 1) +Error: discarding token "number" (1.10: 1) Error: popping token error (1.2-8: ) Stack now 0 4 Shifting token error (1.2-10: ) @@ -84693,7 +85161,7 @@ Shifting token ')' (1.11: ) Entering state 26 Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): +Reducing stack by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) @@ -84706,18 +85174,18 @@ Entering state 19 Stack now 0 8 19 Reading a token -Next token is token number (1.15-18: 1111) -Shifting token number (1.15-18: 1111) +Next token is token "number" (1.15-18: 1111) +Shifting token "number" (1.15-18: 1111) Entering state 1 Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.15-18: 1111) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.15-18: 1111) -> $$ = nterm exp (1.15-18: 1111) Entering state 28 Stack now 0 8 19 28 Reading a token Next token is token '\n' (1.19-2.0: ) -Reducing stack by rule 6 (line 102): +Reducing stack by rule 6 (line 89): $1 = nterm exp (1.1-11: 1111) $2 = token '=' (1.13: ) $3 = nterm exp (1.15-18: 1111) @@ -84728,25 +85196,42 @@ Shifting token '\n' (1.19-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 97): +Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-18: 1111) $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): +Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +syntax error: invalid character: '#' +./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1374: cat stderr +stderr: +./calc.at:1364: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +1.6: syntax error: invalid character: '#' +input: + | 1 + 2 * 3 + !* ++ +./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + 1) / (1 - 1) +./calc.at:1371: $PREPARSER ./calc input +stderr: +./calc.at:1368: $PREPARSER ./calc input +stderr: +syntax error: invalid character: '#' +./calc.at:1370: cat stderr Starting parse Entering state 0 Stack now 0 @@ -84888,25 +85373,10 @@ Stack now 0 6 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -input: -1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) -input: -stderr: - | 1 + 2 * 3 + !* ++ -./calc.at:1368: $PREPARSER ./calc input -./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 + 2 * 3 + !* ++ -stderr: -./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1369: $PREPARSER ./calc input -1.14: memory exhausted -stderr: -./calc.at:1389: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS -./calc.at:1371: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: -./calc.at:1364: "$PERL" -pi -e 'use strict; +input: +./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -84916,145 +85386,19 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +1.11-17: error: null divisor +./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.14: memory exhausted -input: - | 1 2 -./calc.at:1374: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1371: $PREPARSER ./calc input -stderr: + | error +./calc.at:1374: $PREPARSER ./calc input stderr: -./calc.at:1364: cat stderr -1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Stack now 0 4 12 21 -Reading a token -1.6: syntax error: invalid character: '#' -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-8: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1.10: 1) -Error: discarding token number (1.10: 1) -Error: popping token error (1.2-8: ) -Stack now 0 4 -Shifting token error (1.2-10: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 26 -Stack now 0 4 11 26 -Reducing stack by rule 14 (line 127): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) -Entering state 19 -Stack now 0 8 19 -Reading a token -Next token is token number (1.15-18: 1111) -Shifting token number (1.15-18: 1111) -Entering state 1 -Stack now 0 8 19 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) -Entering state 28 -Stack now 0 8 19 28 -Reading a token -Next token is token '\n' (1.19-2.0: ) -Reducing stack by rule 6 (line 102): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) -Entering state 25 -Stack now 0 8 25 -Reducing stack by rule 4 (line 97): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 91): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Now at end of input. -Shifting token end of file (2.1: ) -Entering state 17 -Stack now 0 6 17 -Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1370: cat stderr -./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -1.14: memory exhausted -1.14: memory exhausted input: - | 1 2 -1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) -./calc.at:1374: $PREPARSER ./calc input -492. calc.at:1364: ok -./calc.at:1369: cat stderr stderr: -./calc.at:1362: "$PERL" -pi -e 'use strict; +./calc.at:1363: cat stderr +1.6: syntax error: invalid character: '#' +./calc.at:1364: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -85064,57 +85408,52 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1368: cat stderr -input: -input: - | error syntax error + | 1 + 2 * 3 + !* ++ +stderr: ./calc.at:1370: $PREPARSER ./calc input +stdout: ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1371: cat stderr - | (#) + (#) = 2222 -./calc.at:1369: $PREPARSER ./calc input +1.11-17: error: null divisor stderr: +./calc.at:1375: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +./calc.at:1367: cat stderr +1.14: memory exhausted +./calc.at:1369: cat stderr stderr: +input: stderr: -./calc.at:1362: cat stderr -1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error -stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) -input: +./calc.at:1375: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c - | (#) + (#) = 2222 -./calc.at:1368: $PREPARSER ./calc input -input: -stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' +1.14: memory exhausted +./calc.at:1364: cat stderr +./calc.at:1368: cat stderr input: -./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1370: cat stderr - | 1//2 -./calc.at:1374: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1371: $PREPARSER ./calc input +syntax error | (1 + 1) / (1 - 1) -./calc.at:1362: $PREPARSER ./calc input stderr: -1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) +./calc.at:1363: $PREPARSER ./calc input + | (1 + 1) / (1 - 1) +./calc.at:1367: $PREPARSER ./calc input +input: +1.14: memory exhausted stderr: stderr: +494. calc.at:1368: ok +492. calc.at:1364: ok + | (# + 1) = 1111 +input: +./calc.at:1369: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -85124,12 +85463,12 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 @@ -85139,18 +85478,18 @@ Entering state 21 Stack now 0 4 12 21 Reading a token -Next token is token number (1.6: 1) -Shifting token number (1.6: 1) +Next token is token "number" (1.6: 1) +Shifting token "number" (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.6: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) @@ -85161,7 +85500,7 @@ Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 -Reducing stack by rule 13 (line 126): +Reducing stack by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) @@ -85179,12 +85518,12 @@ Entering state 4 Stack now 0 8 23 4 Reading a token -Next token is token number (1.12: 1) -Shifting token number (1.12: 1) +Next token is token "number" (1.12: 1) +Shifting token "number" (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.12: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 @@ -85194,18 +85533,18 @@ Entering state 20 Stack now 0 8 23 4 12 20 Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.16: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) -Reducing stack by rule 8 (line 113): +Reducing stack by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) @@ -85216,7 +85555,7 @@ Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 -Reducing stack by rule 13 (line 126): +Reducing stack by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) @@ -85225,7 +85564,7 @@ Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 10 (line 115): +Reducing stack by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) @@ -85237,49 +85576,67 @@ Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 97): +Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): +Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' +./calc.at:1371: cat stderr +error: null divisor +./calc.at:1367: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1375: $PREPARSER ./calc input +./calc.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1370: cat stderr stderr: 1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) -input: -./calc.at:1374: cat stderr - | 1 = 2 = 3 -./calc.at:1370: $PREPARSER ./calc input -502. calc.at:1390: testing Calculator %glr-parser %locations ... -./calc.at:1390: mv calc.y.tmp calc.y - -./calc.at:1390: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -./calc.at:1371: cat stderr -./calc.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: -./calc.at:1368: cat stderr -./calc.at:1369: cat stderr +./calc.at:1374: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +error: null divisor stderr: -1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) + | (#) + (#) = 2222 +input: +./calc.at:1371: $PREPARSER ./calc input + Starting parse Entering state 0 Stack now 0 @@ -85289,12 +85646,12 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) Entering state 1 Stack now 0 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.2: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Stack now 0 4 12 @@ -85304,18 +85661,18 @@ Entering state 21 Stack now 0 4 12 21 Reading a token -Next token is token number (1.6: 1) -Shifting token number (1.6: 1) +Next token is token "number" (1.6: 1) +Shifting token "number" (1.6: 1) Entering state 1 Stack now 0 4 12 21 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.6: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 30 Stack now 0 4 12 21 30 Reading a token Next token is token ')' (1.7: ) -Reducing stack by rule 7 (line 112): +Reducing stack by rule 7 (line 99): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) @@ -85326,7 +85683,7 @@ Shifting token ')' (1.7: ) Entering state 27 Stack now 0 4 12 27 -Reducing stack by rule 13 (line 126): +Reducing stack by rule 13 (line 113): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) @@ -85344,12 +85701,12 @@ Entering state 4 Stack now 0 8 23 4 Reading a token -Next token is token number (1.12: 1) -Shifting token number (1.12: 1) +Next token is token "number" (1.12: 1) +Shifting token "number" (1.12: 1) Entering state 1 Stack now 0 8 23 4 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.12: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 Stack now 0 8 23 4 12 @@ -85359,18 +85716,18 @@ Entering state 20 Stack now 0 8 23 4 12 20 Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) Entering state 1 Stack now 0 8 23 4 12 20 1 -Reducing stack by rule 5 (line 101): - $1 = token number (1.16: 1) +Reducing stack by rule 5 (line 88): + $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 29 Stack now 0 8 23 4 12 20 29 Reading a token Next token is token ')' (1.17: ) -Reducing stack by rule 8 (line 113): +Reducing stack by rule 8 (line 100): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) @@ -85381,7 +85738,7 @@ Shifting token ')' (1.17: ) Entering state 27 Stack now 0 8 23 4 12 27 -Reducing stack by rule 13 (line 126): +Reducing stack by rule 13 (line 113): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) @@ -85390,7 +85747,7 @@ Stack now 0 8 23 32 Reading a token Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 10 (line 115): +Reducing stack by rule 10 (line 102): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) @@ -85402,35 +85759,40 @@ Shifting token '\n' (1.18-2.0: ) Entering state 25 Stack now 0 8 25 -Reducing stack by rule 4 (line 97): +Reducing stack by rule 4 (line 84): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 91): +Reducing stack by rule 1 (line 78): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token Now at end of input. -Shifting token end of file (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 17 Stack now 0 6 17 Stack now 0 6 17 -Cleanup: popping token end of file (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | error -./calc.at:1371: $PREPARSER ./calc input -input: - | 1//2 -./calc.at:1374: $PREPARSER ./calc input -./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (#) + (#) = 2222 stderr: -1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) -input: -./calc.at:1362: "$PERL" -pi -e 'use strict; +./calc.at:1370: $PREPARSER ./calc input +stderr: + +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +stderr: +stderr: +1.2: syntax error: invalid character: '#' +./calc.at:1375: $EGREP -c -v 'Return for a new token:|LAC:' stderr +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1363: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -85440,49 +85802,89 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (1 + #) = 1111 +./calc.at:1374: cat stderr +./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1367: cat stderr +./calc.at:1363: cat stderr +stderr: +stderr: +./calc.at:1369: cat stderr +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +input: +stdout: + | 1 2 +./calc.at:1375: $PREPARSER ./calc input +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./types.at:139: $PREPARSER ./test +stderr: +493. calc.at:1367: ok +501. calc.at:1389: testing Calculator %glr-parser %header ... +./calc.at:1389: mv calc.y.tmp calc.y + +1.3: syntax error, unexpected number +./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1389: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +491. calc.at:1363: ok +input: +stderr: + | 1 = 2 = 3 +./calc.at:1371: cat stderr +502. calc.at:1390: testing Calculator %glr-parser %locations ... +./calc.at:1390: mv calc.y.tmp calc.y + +./calc.at:1390: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +./calc.at:1374: $PREPARSER ./calc input stderr: -./calc.at:1362: cat stderr syntax error input: - | (1 + #) = 1111 ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1368: $PREPARSER ./calc input +./calc.at:1370: cat stderr stderr: + | (1 + # + 1) = 1111 +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1369: $PREPARSER ./calc input +input: + | (1 + #) = 1111 stderr: -490. calc.at:1362: ok -1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) -stderr: -stderr: -1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) +./calc.at:1371: $PREPARSER ./calc input stderr: -1.6: syntax error: invalid character: '#' +1.3: syntax error, unexpected number +======== Testing with C++ standard flags: '' syntax error -stderr: -stdout: +input: + 1.6: syntax error: invalid character: '#' -./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: $PREPARSER ./test -./calc.at:1390: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS -stderr: stderr: + + | (1 + #) = 1111 +./calc.at:1370: $PREPARSER ./calc input ./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1375: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 1.6: syntax error: invalid character: '#' -./calc.at:1371: cat stderr -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1370: cat stderr +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: +./calc.at:1375: cat stderr 1.6: syntax error: invalid character: '#' -./calc.at:1368: cat stderr -======== Testing with C++ standard flags: '' -input: - | 1 = 2 = 3 -./calc.at:1371: $PREPARSER ./calc input +./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) -input: +./calc.at:1389: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS +stderr: +1.6: syntax error: invalid character: '#' +./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.6: syntax error: invalid character: '#' +./calc.at:1390: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -85493,52 +85895,132 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) - -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS input: +503. calc.at:1391: testing Calculator %glr-parser %locations api.location.type={Span} ... +./calc.at:1391: mv calc.y.tmp calc.y + + | 1//2 +./calc.at:1375: $PREPARSER ./calc input ./calc.at:1369: cat stderr +./calc.at:1391: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +stderr: ./calc.at:1371: cat stderr - | - | +1 -./calc.at:1370: $PREPARSER ./calc input +504. calc.at:1392: testing Calculator %glr-parser %name-prefix "calc" ... +./calc.at:1392: mv calc.y.tmp calc.y + +stderr: +./calc.at:1392: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +./calc.at:1374: cat stderr +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.6: syntax error: invalid character: '#' +input: +stderr: + | (1 + 1) / (1 - 1) +./calc.at:1369: $PREPARSER ./calc input input: +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' + | (# + 1) = 1111 +./calc.at:1371: $PREPARSER ./calc input +stderr: +input: +./calc.at:1370: cat stderr | | +1 -./calc.at:1371: $PREPARSER ./calc input +./calc.at:1374: $PREPARSER ./calc input +1.11-17: error: null divisor stderr: -2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +1.2: syntax error: invalid character: '#' +input: +./calc.at:1375: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +syntax error +./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1391: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +stderr: | (# + 1) = 1111 +./calc.at:1370: $PREPARSER ./calc input stderr: -./calc.at:1368: $PREPARSER ./calc input -2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1374: cat stderr +1.11-17: error: null divisor stderr: -2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: +./calc.at:1375: cat stderr +1.2: syntax error: invalid character: '#' +./calc.at:1392: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +1.2: syntax error: invalid character: '#' +syntax error +stderr: +./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: +./calc.at:1369: cat stderr +./types.at:139: ./check +input: +stderr: +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./calc.at:1371: cat stderr + | error +./calc.at:1375: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' -./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1375: $EGREP '(malloc|free) *\(' calc.[ch] | $EGREP -v 'INFRINGES ON USER NAME SPACE' +495. calc.at:1369: ok +stderr: +./calc.at:1374: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +1.1: syntax error, unexpected invalid token +./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1370: cat stderr input: + | (1 + # + 1) = 1111 +./calc.at:1371: $PREPARSER ./calc input +stderr: +stderr: +1.1: syntax error, unexpected invalid token +1.6: syntax error: invalid character: '#' input: -./calc.at:1371: $PREPARSER ./calc /dev/null - | (# + 1) = 1111 + +./calc.at:1374: cat stderr + | (1 + # + 1) = 1111 +./calc.at:1370: $PREPARSER ./calc input +./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: +./calc.at:1374: $PREPARSER ./calc /dev/null +./calc.at:1375: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -./calc.at:1369: $PREPARSER ./calc input -1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) -1.2: syntax error: invalid character: '#' - | error -./calc.at:1374: $PREPARSER ./calc input stderr: -./calc.at:1375: "$PERL" -ne ' +1.6: syntax error: invalid character: '#' +stdout: +1.6: syntax error: invalid character: '#' +stderr: +./calc.at:1375: cat stderr +./calc.at:1387: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. @@ -85549,38 +86031,10 @@ || /\t/ )' calc.c -stderr: -2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) -stderr: +./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error -./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./types.at:139: ./check -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y -1.2: syntax error: invalid character: '#' -503. calc.at:1391: testing Calculator %glr-parser %locations api.location.type={Span} ... -./calc.at:1391: mv calc.y.tmp calc.y - -stderr: -syntax error -stderr: input: -./calc.at:1368: cat stderr -./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1391: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1374: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -85594,47 +86048,60 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -./calc.at:1375: $PREPARSER ./calc input +./calc.at:1387: $PREPARSER ./calc input +stderr: +stderr: stderr: ./calc.at:1371: cat stderr +1.6: syntax error: invalid character: '#' +syntax error +input: +./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +505. calc.at:1393: testing Calculator %glr-parser api.prefix={calc} ... +./calc.at:1393: mv calc.y.tmp calc.y + + | 1 = 2 = 3 +./calc.at:1393: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +./calc.at:1375: $PREPARSER ./calc input +stderr: ./calc.at:1370: cat stderr -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: -./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.2: syntax error: invalid character: '#' input: -./calc.at:1374: cat stderr -./calc.at:1370: $PREPARSER ./calc /dev/null - | (1 + # + 1) = 1111 -./calc.at:1368: $PREPARSER ./calc input input: - | 1 = 2 = 3 -./calc.at:1374: $PREPARSER ./calc input +1.7: syntax error, unexpected '=' + | (1 + 1) / (1 - 1) +./calc.at:1371: $PREPARSER ./calc input +./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 2 +./calc.at:1387: $PREPARSER ./calc input stderr: stderr: -syntax error -./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: +./calc.at:1374: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: syntax error -./calc.at:1375: $EGREP -c -v 'Return for a new token:|LAC:' stderr -stderr: +./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.7: syntax error, unexpected '=' +1.11-17: error: null divisor + | (1 + 1) / (1 - 1) +./calc.at:1370: $PREPARSER ./calc input stderr: -./calc.at:1371: $PREPARSER ./calc input -./calc.at:1391: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS -1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) -1.6: syntax error: invalid character: '#' stderr: -./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1369: cat stderr +1.11-17: error: null divisor +./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error ./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.1-46: error: 4444 != 1 -./calc.at:1374: "$PERL" -pi -e 'use strict; +./calc.at:1374: cat stderr +./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -85644,51 +86111,70 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1393: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +1.11-17: error: null divisor stderr: -1.6: syntax error: invalid character: '#' +input: +./calc.at:1375: cat stderr +1.11-17: error: null divisor + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1374: $PREPARSER ./calc input stderr: +./calc.at:1371: cat stderr +./calc.at:1387: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 +./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.1-46: error: 4444 != 1 - | 1 2 -./calc.at:1375: $PREPARSER ./calc input ./calc.at:1370: cat stderr -./calc.at:1368: cat stderr -input: + | + | +1 +497. calc.at:1371: ok +./calc.at:1375: $PREPARSER ./calc input stderr: -1.3: syntax error, unexpected number -./calc.at:1374: cat stderr - | (1 + # + 1) = 1111 -./calc.at:1369: $PREPARSER ./calc input -./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +496. calc.at:1370: ok +./calc.at:1387: cat stderr stderr: -./calc.at:1371: cat stderr -input: -1.6: syntax error: invalid character: '#' +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 +2.1: syntax error, unexpected '+' +./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 - | (1 + 1) / (1 - 1) -./calc.at:1370: $PREPARSER ./calc input -./calc.at:1368: $PREPARSER ./calc input - | - | +1 -./calc.at:1374: $PREPARSER ./calc input -./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.3: syntax error, unexpected number + | 1//2 + +./calc.at:1387: $PREPARSER ./calc input +2.1: syntax error, unexpected '+' + stderr: -1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.1-46: error: 4444 != 1 +./calc.at:1374: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +syntax error +./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -85700,43 +86186,77 @@ }eg ' expout || exit 77 stderr: -stderr: -1.11-17: error: null divisor +syntax error ./calc.at:1375: cat stderr -./calc.at:1368: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +506. calc.at:1394: testing Calculator %glr-parser %verbose ... +./calc.at:1394: mv calc.y.tmp calc.y + +./calc.at:1374: cat stderr +./calc.at:1394: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +507. calc.at:1395: testing Calculator %glr-parser parse.error=verbose ... +./calc.at:1395: mv calc.y.tmp calc.y + +./calc.at:1375: $PREPARSER ./calc /dev/null +stderr: +1.1: syntax error, unexpected end of file +./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: +stderr: +1.1: syntax error, unexpected end of file +./calc.at:1395: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y + | (!!) + (1 2) = 1 +./calc.at:1374: $PREPARSER ./calc input +./calc.at:1387: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: syntax error +error: 2222 != 1 ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1375: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1375: cat stderr +./calc.at:1387: cat stderr +./calc.at:1395: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS stderr: +syntax error +error: 2222 != 1 +./calc.at:1394: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +input: + | error +./calc.at:1387: $PREPARSER ./calc input input: - | (!!) + (1 2) = 1 - | 1//2 -1.6: syntax error: invalid character: '#' stderr: -./calc.at:1375: $PREPARSER ./calc input -./calc.at:1371: $PREPARSER ./calc input stderr: syntax error + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +stdout: +./types.at:139: $PREPARSER ./test +./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./calc.at:1375: $PREPARSER ./calc input stderr: -stderr: -1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-16: error: 2222 != 1 -1.11-17: error: null divisor -1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 -./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1369: cat stderr -./calc.at:1368: cat stderr -1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-16: error: 2222 != 1 ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -85747,22 +86267,21 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | (1 + 1) / (1 - 1) -./calc.at:1369: $PREPARSER ./calc input +======== Testing with C++ standard flags: '' +./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: +syntax error stderr: -1.11-17: error: null divisor -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1370: cat stderr -./calc.at:1369: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.1-46: error: 4444 != 1 stderr: -494. calc.at:1368: ok -./calc.at:1374: cat stderr stdout: -./calc.at:1374: $PREPARSER ./calc /dev/null -stderr: -./calc.at:1387: "$PERL" -ne ' +./calc.at:1374: cat stderr +./calc.at:1390: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. @@ -85773,7 +86292,6 @@ || /\t/ )' calc.c -./calc.at:1371: cat stderr ./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -85784,14 +86302,18 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: +./calc.at:1387: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 input: - | (!!) + (1 2) = 1 -1.11-17: error: null divisor input: -./calc.at:1370: $PREPARSER ./calc input -syntax error -./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -85805,81 +86327,52 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -./calc.at:1387: $PREPARSER ./calc input -stderr: -./calc.at:1369: cat stderr +./calc.at:1390: $PREPARSER ./calc input stderr: -input: -./calc.at:1375: cat stderr -1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-16: error: 2222 != 1 | (- *) + (1 2) = 1 -./calc.at:1371: $PREPARSER ./calc input -stderr: -./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1374: $PREPARSER ./calc input +./calc.at:1375: cat stderr +./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - +./calc.at:1387: cat stderr syntax error -495. calc.at:1369: ok -./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-17: error: 2222 != 1 +syntax error +error: 2222 != 1 +./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: + | (!!) + (1 2) = 1 stderr: - | error ./calc.at:1375: $PREPARSER ./calc input stderr: -1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-16: error: 2222 != 1 -1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-17: error: 2222 != 1 +stderr: stderr: input: -./calc.at:1370: cat stderr -input: - | (- *) + (1 2) = 1 -./calc.at:1370: $PREPARSER ./calc input -1.1: syntax error, unexpected invalid token +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 +syntax error +syntax error +error: 2222 != 1 ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 -./calc.at:1374: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +input: +./calc.at:1390: $PREPARSER ./calc input +stdout: +./types.at:139: ./check +stderr: + | 1 = 2 = 3 +./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y ./calc.at:1387: $PREPARSER ./calc input stderr: -1.1: syntax error, unexpected invalid token +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 stderr: stderr: - -1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-17: error: 2222 != 1 -./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -504. calc.at:1392: testing Calculator %glr-parser %name-prefix "calc" ... -./calc.at:1392: mv calc.y.tmp calc.y - -./calc.at:1392: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +1.3: syntax error syntax error -stderr: -1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-17: error: 2222 != 1 ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1371: cat stderr -syntax error -./calc.at:1375: "$PERL" -pi -e 'use strict; +./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -85889,7 +86382,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1387: "$PERL" -pi -e 'use strict; +./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -85899,33 +86392,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -./calc.at:1374: cat stderr -./calc.at:1375: cat stderr - | (* *) + (*) + (*) -./calc.at:1371: $PREPARSER ./calc input -./calc.at:1370: cat stderr -stderr: -input: -input: -1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -stderr: -505. calc.at:1393: testing Calculator %glr-parser api.prefix={calc} ... -./calc.at:1393: mv calc.y.tmp calc.y - - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1374: $PREPARSER ./calc input -stderr: -1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) - | 1 = 2 = 3 -stdout: -./calc.at:1375: $PREPARSER ./calc input -./calc.at:1387: cat stderr ./calc.at:1389: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" @@ -85937,31 +86403,12 @@ || /\t/ )' calc.c calc.h -./calc.at:1393: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -./calc.at:1371: cat stderr -input: -./calc.at:1392: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS -input: stderr: - | 1//2 -./calc.at:1387: $PREPARSER ./calc input -input: stderr: - | 1 + 2 * 3 + !+ ++ -./calc.at:1371: $PREPARSER ./calc input -syntax error -syntax error syntax error -syntax error -error: 4444 != 1 -./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +./calc.at:1375: cat stderr +1.3: syntax error input: -stderr: -stderr: -syntax error -./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.7: syntax error, unexpected '=' | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -85975,51 +86422,11 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: $PREPARSER ./calc input -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 -stderr: - | (* *) + (*) + (*) -./calc.at:1370: $PREPARSER ./calc input -./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -syntax error -stderr: -1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -stderr: -1.7: syntax error, unexpected '=' -stderr: -./calc.at:1371: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1393: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS -./calc.at:1374: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -stderr: -1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) - | 1 2 input: -./calc.at:1389: $PREPARSER ./calc input - | 1 + 2 * 3 + !- ++ -./calc.at:1375: "$PERL" -pi -e 'use strict; +./calc.at:1374: cat stderr + | (- *) + (1 2) = 1 +./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86029,10 +86436,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1371: $PREPARSER ./calc input stderr: -stderr: -syntax error +./calc.at:1375: $PREPARSER ./calc input +./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -86043,13 +86449,44 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +stderr: +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.12: syntax error, unexpected number +1.1-17: error: 2222 != 1 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1374: cat stderr +./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | (* *) + (*) + (*) +./calc.at:1374: $PREPARSER ./calc input +stderr: +stderr: +stderr: +stderr: +./calc.at:1387: cat stderr +./calc.at:1390: cat stderr +syntax error +syntax error +syntax error +./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1375: cat stderr -./calc.at:1370: cat stderr stdout: -./calc.at:1390: "$PERL" -ne ' +input: +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.12: syntax error, unexpected number +1.1-17: error: 2222 != 1 +stdout: +./calc.at:1391: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c + +./calc.at:1392: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. @@ -86060,14 +86497,27 @@ || /\t/ )' calc.c -./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: + | 1 2 +./calc.at:1389: $PREPARSER ./calc input input: input: - | 1 + 2 * 3 + !+ ++ -./calc.at:1370: $PREPARSER ./calc input -syntax error + | 1//2 +./calc.at:1375: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 input: +./calc.at:1390: $PREPARSER ./calc input +syntax error +syntax error +syntax error stderr: input: | 1 + 2 * 3 = 7 @@ -86083,36 +86533,43 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -./calc.at:1390: $PREPARSER ./calc input stderr: - | (!!) + (1 2) = 1 +./calc.at:1392: $PREPARSER ./calc input + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1391: $PREPARSER ./calc input | | +1 -./calc.at:1375: $PREPARSER ./calc input -./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1387: cat stderr -stderr: +./calc.at:1387: $PREPARSER ./calc input +syntax error +1.3: syntax error +./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1374: $PREPARSER ./calc input stderr: -stderr: -2.1: syntax error, unexpected '+' -input: -./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 2 -./calc.at:1390: $PREPARSER ./calc input +./calc.at:1375: cat stderr stderr: stderr: -1.3: syntax error -./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error -error: 2222 != 1 -./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: +syntax error 1.3: syntax error -./calc.at:1370: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1389: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86123,32 +86580,11 @@ }eg ' expout || exit 77 stderr: -2.1: syntax error, unexpected '+' stderr: syntax error -error: 2222 != 1 -./calc.at:1371: cat stderr input: - | error -./calc.at:1387: $PREPARSER ./calc input input: - | 1 + 2 * 3 + !* ++ -./calc.at:1371: $PREPARSER ./calc input -stderr: -./calc.at:1375: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.14: memory exhausted -stderr: -syntax error -./calc.at:1389: cat stderr +input: ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -86159,7 +86595,17 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1374: "$PERL" -pi -e 'use strict; + | (* *) + (*) + (*) + | 1 2 +./calc.at:1375: $PREPARSER ./calc input +./calc.at:1374: cat stderr + | 1 2 +./calc.at:1391: $PREPARSER ./calc input +./calc.at:1392: $PREPARSER ./calc input +stderr: +stderr: +stderr: +./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86169,46 +86615,19 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | 1 + 2 * 3 + !- ++ -./calc.at:1370: $PREPARSER ./calc input -./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -./calc.at:1375: cat stderr -stderr: -1.14: memory exhausted -input: -syntax error -./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1390: cat stderr -stderr: -input: -./calc.at:1371: cat stderr - | 1//2 -./calc.at:1390: $PREPARSER ./calc input -./calc.at:1374: cat stderr -./calc.at:1375: $PREPARSER ./calc /dev/null - | 1//2 -stderr: -./calc.at:1389: $PREPARSER ./calc input -stderr: -input: 1.3: syntax error - | (#) + (#) = 2222 -./calc.at:1371: $PREPARSER ./calc input -./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.1: syntax error, unexpected end of file -stderr: +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -stderr: -./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error +./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: +stderr: + | 1 + 2 * 3 + !+ ++ +./calc.at:1390: cat stderr +stderr: ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -86219,18 +86638,34 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.1: syntax error, unexpected end of file -stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1370: cat stderr - | (- *) + (1 2) = 1 ./calc.at:1374: $PREPARSER ./calc input stderr: +syntax error +stderr: 1.3: syntax error +./calc.at:1389: cat stderr stderr: -./calc.at:1375: "$PERL" -pi -e 'use strict; +./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1393: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c + +input: + | error +./calc.at:1390: $PREPARSER ./calc input +input: +./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86241,9 +86676,12 @@ }eg ' expout || exit 77 stderr: + | 1//2 +stderr: ./calc.at:1387: cat stderr -syntax error -./calc.at:1390: "$PERL" -pi -e 'use strict; +./calc.at:1374: $EGREP -c -v 'Return for a new token:|LAC:' stderr +input: +./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86253,56 +86691,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1375: cat stderr -./calc.at:1371: cat stderr -syntax error -syntax error -error: 2222 != 1 -./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: -input: -stdout: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -stderr: -input: -./calc.at:1375: $PREPARSER ./calc input - | 1 = 2 = 3 -./calc.at:1391: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c - -./calc.at:1387: $PREPARSER ./calc input -syntax error -syntax error -error: 2222 != 1 - | 1 + 2 * 3 + !* ++ -./calc.at:1370: $PREPARSER ./calc input -stderr: -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.1-46: error: 4444 != 1 -./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +./calc.at:1389: $PREPARSER ./calc input +1.1: syntax error stderr: -input: -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.1-46: error: 4444 != 1 -input: +./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error -./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -86316,15 +86709,11 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 +./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1393: $PREPARSER ./calc input stderr: -./calc.at:1391: $PREPARSER ./calc input -stderr: -syntax error -stderr: - | (1 + #) = 1111 -1.14: memory exhausted -./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1375: "$PERL" -pi -e 'use strict; +./calc.at:1387: $PREPARSER ./calc /dev/null +./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86334,18 +86723,31 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1371: $PREPARSER ./calc input stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1390: cat stderr +./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1375: cat stderr stderr: -1.14: memory exhausted +syntax error +./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +1.1: syntax error +./calc.at:1391: cat stderr +input: stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1389: "$PERL" -pi -e 'use strict; +stderr: + | 1 + 2 * 3 + !- ++ +./calc.at:1374: $PREPARSER ./calc input +./calc.at:1392: cat stderr +syntax error +stderr: +input: +input: +input: + | 1//2 +./calc.at:1391: $PREPARSER ./calc input +./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86355,23 +86757,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1371: cat stderr -./calc.at:1375: cat stderr -input: -input: -input: -./calc.at:1389: cat stderr - | (# + 1) = 1111 -./calc.at:1371: $PREPARSER ./calc input | 1 2 -./calc.at:1391: $PREPARSER ./calc input -stderr: -./calc.at:1370: cat stderr -1.3: syntax error - | error -./calc.at:1390: $PREPARSER ./calc input -./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1374: "$PERL" -pi -e 'use strict; +./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86382,6 +86769,20 @@ }eg ' expout || exit 77 stderr: +./calc.at:1393: $PREPARSER ./calc input + | 1 + 2 * 3 + !+ ++ +./calc.at:1375: $PREPARSER ./calc input +1.3: syntax error +stderr: +./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +input: +syntax error + | 1//2 +./calc.at:1392: $PREPARSER ./calc input +./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -86393,38 +86794,21 @@ }eg ' expout || exit 77 stderr: -1.2: syntax error: invalid character: '#' -stderr: -input: - | (!!) + (1 2) = 1 -./calc.at:1387: cat stderr -./calc.at:1375: $PREPARSER ./calc input -1.3: syntax error -1.1: syntax error -input: -input: -input: -./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | - | +1 -./calc.at:1387: $PREPARSER ./calc input -./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | error -./calc.at:1374: cat stderr stderr: - | (#) + (#) = 2222 stderr: +./calc.at:1389: cat stderr syntax error -./calc.at:1370: $PREPARSER ./calc input -./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1389: $PREPARSER ./calc input -stderr: +./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +./calc.at:1390: cat stderr +1.3: syntax error stderr: -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 -./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1375: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: +input: syntax error +./calc.at:1387: cat stderr +input: ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -86435,28 +86819,74 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + | error + | 1 = 2 = 3 +./calc.at:1390: $PREPARSER ./calc input +./calc.at:1389: $PREPARSER ./calc input stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' stderr: -1.1: syntax error +./calc.at:1374: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +1.7: syntax error +./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: syntax error -1.2: syntax error: invalid character: '#' +./calc.at:1393: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: + | 1 + 2 * 3 + !- ++ +./calc.at:1375: $PREPARSER ./calc input stderr: - | (* *) + (*) + (*) -./calc.at:1374: $PREPARSER ./calc input +./calc.at:1391: cat stderr + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1387: $PREPARSER ./calc input +stderr: +./calc.at:1392: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error stderr: -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 +./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 +./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.7: syntax error +./calc.at:1393: cat stderr stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1375: "$PERL" -pi -e 'use strict; +input: +stderr: +./calc.at:1374: cat stderr + | error +./calc.at:1391: $PREPARSER ./calc input +./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86466,12 +86896,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1391: cat stderr -./calc.at:1375: cat stderr +./calc.at:1392: cat stderr syntax error syntax error syntax error -./calc.at:1390: "$PERL" -pi -e 'use strict; +syntax error +error: 4444 != 1 +input: +./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86481,16 +86913,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1371: cat stderr -input: - | 1//2 -./calc.at:1391: $PREPARSER ./calc input stderr: -1.3: syntax error +input: +1.1: syntax error ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1387: "$PERL" -pi -e 'use strict; +./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86500,21 +86927,23 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + | 1//2 + | 1 + 2 * 3 + !* ++ +./calc.at:1393: $PREPARSER ./calc input +./calc.at:1374: $PREPARSER ./calc input +stderr: input: -input: - | (1 + # + 1) = 1111 -./calc.at:1371: $PREPARSER ./calc input +./calc.at:1390: cat stderr stderr: - | (- *) + (1 2) = 1 -./calc.at:1375: $PREPARSER ./calc input -./calc.at:1370: cat stderr stderr: +./calc.at:1375: cat stderr +memory exhausted +./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.1: syntax error +./calc.at:1389: cat stderr syntax error -syntax error -syntax error -1.6: syntax error: invalid character: '#' -./calc.at:1390: cat stderr -./calc.at:1389: "$PERL" -pi -e 'use strict; + | error +./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86524,29 +86953,19 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.3: syntax error +./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1392: $PREPARSER ./calc input +input: stderr: -./calc.at:1389: cat stderr -./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1387: cat stderr -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.12: syntax error, unexpected number -1.1-17: error: 2222 != 1 -./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: - | 1 = 2 = 3 + | + | +1 ./calc.at:1390: $PREPARSER ./calc input +syntax error +./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.7: syntax error -./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1387: $PREPARSER ./calc /dev/null stderr: stderr: -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.12: syntax error, unexpected number -1.1-17: error: 2222 != 1 ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -86557,13 +86976,30 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +memory exhausted + | 1 + 2 * 3 + !* ++ +2.1: syntax error +./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1375: $PREPARSER ./calc input input: -./calc.at:1371: cat stderr syntax error -input: +stderr: | 1 = 2 = 3 +stderr: ./calc.at:1389: $PREPARSER ./calc input -./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +1.14: memory exhausted +./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1387: cat stderr +stderr: +syntax error +stderr: +./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +2.1: syntax error +./calc.at:1391: cat stderr +stderr: +stderr: +input: ./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -86574,17 +87010,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (1 + #) = 1111 -stderr: -stderr: -1.7: syntax error -./calc.at:1391: cat stderr -./calc.at:1370: $PREPARSER ./calc input -stderr: -1.6: syntax error: invalid character: '#' syntax error -./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1375: "$PERL" -pi -e 'use strict; +1.14: memory exhausted + | (!!) + (1 2) = 1 +./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86594,19 +87023,26 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1387: $PREPARSER ./calc input input: - | error -stderr: -./calc.at:1391: $PREPARSER ./calc input +./calc.at:1392: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error +error: 2222 != 1 +./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 = 2 = 3 +./calc.at:1391: $PREPARSER ./calc input stderr: -1.1: syntax error -syntax error -./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1390: "$PERL" -pi -e 'use strict; +./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86616,23 +87052,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1374: cat stderr -./calc.at:1375: cat stderr - | (1 + 1) / (1 - 1) -stderr: -./calc.at:1371: $PREPARSER ./calc input -./calc.at:1390: cat stderr stderr: -stderr: -1.6: syntax error: invalid character: '#' -input: - | - | +1 -input: -./calc.at:1390: $PREPARSER ./calc input -input: -1.1: syntax error -./calc.at:1389: "$PERL" -pi -e 'use strict; +./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86642,14 +87063,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -2.1: syntax error -./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (* *) + (*) + (*) -1.11-17: error: null divisor - | 1 + 2 * 3 + !+ ++ -./calc.at:1374: $PREPARSER ./calc input -./calc.at:1387: "$PERL" -pi -e 'use strict; +./calc.at:1374: cat stderr +1.7: syntax error +./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1390: cat stderr +./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86659,14 +87077,26 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1375: $PREPARSER ./calc input +syntax error +error: 2222 != 1 +./calc.at:1375: cat stderr +input: +./calc.at:1392: cat stderr stderr: +./calc.at:1390: $PREPARSER ./calc /dev/null +1.7: syntax error + | (#) + (#) = 2222 stderr: -2.1: syntax error -./calc.at:1389: cat stderr -./calc.at:1371: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1393: cat stderr +./calc.at:1374: $PREPARSER ./calc input +input: stderr: -./calc.at:1390: "$PERL" -pi -e 'use strict; +input: + | (#) + (#) = 2222 +1.1: syntax error +./calc.at:1375: $PREPARSER ./calc input +./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86676,13 +87106,13 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + | 1 = 2 = 3 +syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1389: cat stderr ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1392: $PREPARSER ./calc input stderr: -./calc.at:1370: cat stderr -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -./calc.at:1374: $EGREP -c -v 'Return for a new token:|LAC:' stderr ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -86693,58 +87123,33 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -1.11-17: error: null divisor -./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1390: cat stderr input: -input: -./calc.at:1387: cat stderr - | - | +1 -stderr: -./calc.at:1389: $PREPARSER ./calc input - | 1 + 2 * 3 + !- ++ -./calc.at:1374: $PREPARSER ./calc input -input: -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -./calc.at:1371: cat stderr stderr: - | (# + 1) = 1111 -input: -./calc.at:1370: $PREPARSER ./calc input +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' + | error +./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1393: $PREPARSER ./calc input stderr: -./calc.at:1391: cat stderr - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1387: $PREPARSER ./calc input syntax error +./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: stderr: -./calc.at:1390: $PREPARSER ./calc /dev/null -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 -./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error: invalid character: '#' +syntax error: invalid character: '#' +1.1: syntax error stderr: -./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error +input: +./calc.at:1387: cat stderr +./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: + | + | +1 +stdout: +./calc.at:1389: $PREPARSER ./calc input stderr: -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 -1.1: syntax error -1.2: syntax error: invalid character: '#' -./calc.at:1392: "$PERL" -ne ' +./calc.at:1394: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. @@ -86755,10 +87160,12 @@ || /\t/ )' calc.c -./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +syntax error stderr: -497. calc.at:1371: ok -./calc.at:1375: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86768,11 +87175,13 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1391: cat stderr +syntax error +./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error input: -stderr: -./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -./calc.at:1387: "$PERL" -pi -e 'use strict; +./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86782,10 +87191,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.1: syntax error - | 1 = 2 = 3 -./calc.at:1391: $PREPARSER ./calc input -stderr: +input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -86799,14 +87205,11 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -./calc.at:1392: $PREPARSER ./calc input + | (- *) + (1 2) = 1 stderr: -./calc.at:1375: cat stderr -1.7: syntax error -1.2: syntax error: invalid character: '#' - -./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1389: "$PERL" -pi -e 'use strict; +./calc.at:1387: $PREPARSER ./calc input +./calc.at:1394: $PREPARSER ./calc input +./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86816,8 +87219,21 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +syntax error stderr: -./calc.at:1390: "$PERL" -pi -e 'use strict; + | + | +1 +./calc.at:1391: $PREPARSER ./calc input +./calc.at:1390: cat stderr +stderr: +./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1375: cat stderr +syntax error +syntax error +error: 2222 != 1 +./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86827,24 +87243,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -stderr: -1.7: syntax error -./calc.at:1387: cat stderr -stderr: -input: - | 1 2 -./calc.at:1392: $PREPARSER ./calc input - | 1 + 2 * 3 + !+ ++ -stderr: -./calc.at:1370: cat stderr -./calc.at:1390: cat stderr -./calc.at:1375: $PREPARSER ./calc input -506. calc.at:1394: testing Calculator %glr-parser %verbose ... -./calc.at:1394: mv calc.y.tmp calc.y - -./calc.at:1374: "$PERL" -pi -e 'use strict; +./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86854,54 +87253,31 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +2.1: syntax error input: -syntax error -./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1374: cat stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1390: $PREPARSER ./calc input stderr: -./calc.at:1389: cat stderr stderr: -input: -./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1394: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -./calc.at:1391: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +stderr: stderr: syntax error +syntax error +error: 2222 != 1 +stdout: input: - | (1 + # + 1) = 1111 -./calc.at:1374: cat stderr - | (!!) + (1 2) = 1 -./calc.at:1370: $PREPARSER ./calc input -./calc.at:1389: $PREPARSER ./calc /dev/null -./calc.at:1387: $PREPARSER ./calc input -stderr: +input: +2.1: syntax error 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error -error: 2222 != 1 -stderr: -./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.6: syntax error: invalid character: '#' -stderr: -./calc.at:1391: cat stderr -syntax error -./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1392: "$PERL" -pi -e 'use strict; +./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -86911,32 +87287,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: - | - | +1 -./calc.at:1391: $PREPARSER ./calc input -input: -./calc.at:1375: $EGREP -c -v 'Return for a new token:|LAC:' stderr -stderr: -2.1: syntax error -./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 + 2 * 3 + !* ++ -./calc.at:1374: $PREPARSER ./calc input -syntax error -error: 2222 != 1 -./calc.at:1392: cat stderr -stderr: -stderr: -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 -stderr: -stdout: -./calc.at:1393: "$PERL" -ne ' + | (1 + #) = 1111 +./calc.at:1395: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. @@ -86947,18 +87299,45 @@ || /\t/ )' calc.c +./calc.at:1375: $PREPARSER ./calc input + | 1 2 +./calc.at:1393: cat stderr input: +./calc.at:1394: $PREPARSER ./calc input +./calc.at:1392: cat stderr stderr: - | 1//2 -./calc.at:1392: $PREPARSER ./calc input -memory exhausted -./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1394: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS -2.1: syntax error + | (1 + #) = 1111 +./calc.at:1374: $PREPARSER ./calc input +1.6: syntax error: invalid character: '#' stderr: +stderr: +./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error input: -1.6: syntax error: invalid character: '#' +./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 input: +./calc.at:1391: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | 1 = 2 = 3 +syntax error: invalid character: '#' +./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1389: cat stderr +./calc.at:1393: $PREPARSER ./calc input +stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -86972,7 +87351,24 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 +input: +./calc.at:1395: $PREPARSER ./calc input +./calc.at:1387: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | + | +1 +./calc.at:1392: $PREPARSER ./calc input stderr: +syntax error +./calc.at:1389: $PREPARSER ./calc /dev/null ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -86983,26 +87379,29 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1393: $PREPARSER ./calc input stderr: -syntax error stderr: -memory exhausted - | 1 + 2 * 3 + !- ++ -./calc.at:1375: $PREPARSER ./calc input -./calc.at:1370: cat stderr +./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: syntax error +1.6: syntax error: invalid character: '#' ./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +syntax error: invalid character: '#' stderr: stderr: -input: - | (1 + 1) / (1 - 1) stderr: -./calc.at:1370: $PREPARSER ./calc input -./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error +syntax error +./calc.at:1391: cat stderr stderr: -./calc.at:1387: "$PERL" -pi -e 'use strict; +./calc.at:1390: cat stderr +./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87012,10 +87411,21 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.11-17: error: null divisor -./calc.at:1370: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1390: cat stderr -./calc.at:1391: "$PERL" -pi -e 'use strict; +./calc.at:1387: cat stderr +./calc.at:1391: $PREPARSER ./calc /dev/null +input: +syntax error + | 1 2 +stderr: +./calc.at:1375: cat stderr +./calc.at:1395: $PREPARSER ./calc input +1.1: syntax error +./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +input: +syntax error, unexpected number +./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87025,7 +87435,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1374: "$PERL" -pi -e 'use strict; +./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87035,14 +87445,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -stderr: -1.11-17: error: null divisor -./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1387: cat stderr -./calc.at:1374: cat stderr -stderr: -./calc.at:1389: "$PERL" -pi -e 'use strict; +input: + | (!!) + (1 2) = 1 +./calc.at:1390: $PREPARSER ./calc input +./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87052,17 +87458,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | (!!) + (1 2) = 1 -./calc.at:1390: $PREPARSER ./calc input -input: - | 1 2 -input: -./calc.at:1393: $PREPARSER ./calc input -stderr: - | (#) + (#) = 2222 stderr: -./calc.at:1375: "$PERL" -pi -e 'use strict; +input: +./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87072,16 +87470,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +stderr: +stderr: +1.1: syntax error + | (* *) + (*) + (*) + | (# + 1) = 1111 1.11: syntax error 1.1-16: error: 2222 != 1 +./calc.at:1375: $PREPARSER ./calc input ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1374: $PREPARSER ./calc input -syntax error -./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1389: cat stderr -./calc.at:1375: cat stderr -input: ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -87092,46 +87489,21 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -./calc.at:1370: cat stderr -input: - | (- *) + (1 2) = 1 ./calc.at:1387: $PREPARSER ./calc input +syntax error, unexpected number stderr: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1389: $PREPARSER ./calc input -syntax error -syntax error -error: 2222 != 1 -./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1391: cat stderr stderr: -syntax error: invalid character: '#' -syntax error: invalid character: '#' -syntax error -syntax error -syntax error syntax error syntax error -error: 4444 != 1 -./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error syntax error -error: 2222 != 1 -stderr: -./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1392: cat stderr stderr: +./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error: invalid character: '#' 1.11: syntax error 1.1-16: error: 2222 != 1 - | 1 + 2 * 3 + !* ++ -./calc.at:1375: $PREPARSER ./calc input -./calc.at:1391: $PREPARSER ./calc /dev/null -stderr: -stderr: -./calc.at:1390: "$PERL" -pi -e 'use strict; +./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1394: cat stderr +./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87141,15 +87513,16 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1393: cat stderr +./calc.at:1389: cat stderr +stderr: +./calc.at:1392: cat stderr +stderr: +./calc.at:1374: cat stderr syntax error syntax error syntax error -syntax error -error: 4444 != 1 -stderr: -syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1393: "$PERL" -pi -e 'use strict; +./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87159,12 +87532,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.14: memory exhausted -./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -496. calc.at:1370: ok -1.1: syntax error -./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1387: "$PERL" -pi -e 'use strict; +1.2: syntax error: invalid character: '#' +input: +./calc.at:1392: $PREPARSER ./calc /dev/null + | 1//2 +./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87174,34 +87546,24 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1394: $PREPARSER ./calc input input: stderr: -1.1: syntax error - +./calc.at:1395: cat stderr +input: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +syntax error +./calc.at:1389: $PREPARSER ./calc input +./calc.at:1391: cat stderr +./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - | error -./calc.at:1392: $PREPARSER ./calc input -./calc.at:1374: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1389: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1391: "$PERL" -pi -e 'use strict; +input: +syntax error +./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | + | +1 +./calc.at:1393: $PREPARSER ./calc input +./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87211,25 +87573,21 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1387: cat stderr stderr: -syntax error -./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1390: cat stderr -input: - | (* *) + (*) + (*) -./calc.at:1387: $PREPARSER ./calc input -1.14: memory exhausted + | (# + 1) = 1111 +./calc.at:1374: $PREPARSER ./calc input stderr: +syntax error stderr: -./calc.at:1391: cat stderr syntax error syntax error syntax error -./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1393: cat stderr syntax error -./calc.at:1375: "$PERL" -pi -e 'use strict; +error: 4444 != 1 +input: +stderr: +./calc.at:1375: cat stderr +./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87240,48 +87598,41 @@ }eg ' expout || exit 77 stderr: -./calc.at:1374: cat stderr -syntax error syntax error +./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1//2 +./calc.at:1395: $PREPARSER ./calc input syntax error -507. calc.at:1395: testing Calculator %glr-parser parse.error=verbose ... +./calc.at:1390: cat stderr +syntax error: invalid character: '#' input: +./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +stderr: ./calc.at:1391: $PREPARSER ./calc input -input: - | (1 + #) = 1111 -./calc.at:1374: $PREPARSER ./calc input -./calc.at:1389: cat stderr stderr: +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 +syntax error, unexpected '/', expecting number or '-' or '(' or '!' input: -syntax error: invalid character: '#' -./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: stderr: +syntax error +syntax error: invalid character: '#' + | (1 + # + 1) = 1111 +./calc.at:1375: $PREPARSER ./calc input 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 -./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1395: mv calc.y.tmp calc.y - -syntax error: invalid character: '#' -./calc.at:1375: cat stderr - | (- *) + (1 2) = 1 -./calc.at:1390: $PREPARSER ./calc input -input: -./calc.at:1395: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y input: - | (#) + (#) = 2222 -./calc.at:1375: $PREPARSER ./calc input -stderr: - | 1//2 -./calc.at:1393: $PREPARSER ./calc input -stderr: -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 ./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -87292,19 +87643,38 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1387: cat stderr + | (- *) + (1 2) = 1 +stderr: +stderr: +./calc.at:1390: $PREPARSER ./calc input stderr: +stderr: +syntax error, unexpected '/', expecting number or '-' or '(' or '!' 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' +1.6: syntax error: invalid character: '#' +./calc.at:1394: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 input: -stderr: -./calc.at:1374: "$PERL" -pi -e 'use strict; +./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87314,11 +87684,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -syntax error -stderr: -./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1387: "$PERL" -pi -e 'use strict; +./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87328,8 +87694,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (!!) + (1 2) = 1 -./calc.at:1391: "$PERL" -pi -e 'use strict; +./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87339,19 +87704,17 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1389: $PREPARSER ./calc input -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' +stderr: + | 1 + 2 * 3 + !+ ++ +./calc.at:1392: cat stderr +./calc.at:1387: $PREPARSER ./calc input +1.6: syntax error: invalid character: '#' +stderr: 1.4: syntax error 1.12: syntax error 1.1-17: error: 2222 != 1 -./calc.at:1387: cat stderr -./calc.at:1392: cat stderr stderr: -stderr: -syntax error -./calc.at:1374: cat stderr -./calc.at:1375: "$PERL" -pi -e 'use strict; +./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87361,13 +87724,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -syntax error -error: 2222 != 1 -./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: -./calc.at:1391: cat stderr -./calc.at:1390: "$PERL" -pi -e 'use strict; +./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87377,17 +87735,26 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stdout: -./types.at:139: $PREPARSER ./test -./calc.at:1375: cat stderr -stderr: - | 1 + 2 * 3 + !+ ++ -./calc.at:1387: $PREPARSER ./calc input -input: +./calc.at:1394: cat stderr input: +./calc.at:1374: cat stderr +./calc.at:1375: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -input: -./calc.at:1393: "$PERL" -pi -e 'use strict; +./calc.at:1393: cat stderr + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1392: $PREPARSER ./calc input +./calc.at:1389: cat stderr +./calc.at:1395: cat stderr +./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87397,52 +87764,87 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 = 2 = 3 +stderr: +./calc.at:1375: cat stderr +./calc.at:1391: cat stderr +input: +input: +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 +./calc.at:1393: $PREPARSER ./calc /dev/null +./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 + !- ++ +input: +stderr: +./calc.at:1387: $PREPARSER ./calc input +input: +input: + | error +./calc.at:1394: $PREPARSER ./calc input + | error +syntax error +./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 -./calc.at:1391: $PREPARSER ./calc input - | (# + 1) = 1111 -./calc.at:1392: $PREPARSER ./calc input -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: +./calc.at:1389: $PREPARSER ./calc input +./calc.at:1395: $PREPARSER ./calc input +stderr: + | (1 + # + 1) = 1111 ./calc.at:1374: $PREPARSER ./calc input -./calc.at:1393: cat stderr -input: - | (1 + #) = 1111 -./calc.at:1375: $PREPARSER ./calc input -======== Testing with C++ standard flags: '' ./calc.at:1390: cat stderr +input: +syntax error +./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | (!!) + (1 2) = 1 +./calc.at:1391: $PREPARSER ./calc input + | (1 + 1) / (1 - 1) stderr: stderr: -1.6: syntax error: invalid character: '#' +./calc.at:1375: $PREPARSER ./calc input syntax error -./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +syntax error +syntax error +error: 4444 != 1 stderr: -./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.11: syntax error -1.1-16: error: 2222 != 1 -./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +syntax error, unexpected invalid token syntax error error: 2222 != 1 -./calc.at:1395: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -stderr: +./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' -input: +./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +stderr: stderr: ./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.6: syntax error: invalid character: '#' - | 1 + 2 * 3 + !- ++ -./calc.at:1387: $PREPARSER ./calc input stderr: -input: -./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +syntax error +1.11-17: error: null divisor +./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.11: syntax error +1.1-16: error: 2222 != 1 +./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: +stderr: +stderr: syntax error -./calc.at:1375: "$PERL" -pi -e 'use strict; +error: 2222 != 1 +stderr: + | (* *) + (*) + (*) +syntax error: invalid character: '#' +syntax error, unexpected invalid token +./calc.at:1390: $PREPARSER ./calc input +1.11-17: error: null divisor +./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87452,26 +87854,22 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | error -./calc.at:1393: $PREPARSER ./calc input -1.11: syntax error -1.1-16: error: 2222 != 1 - | (* *) + (*) + (*) -./calc.at:1390: $PREPARSER ./calc input -stderr: -stderr: -syntax error: invalid character: '#' -stderr: -syntax error -./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: -syntax error -./calc.at:1375: cat stderr +./calc.at:1393: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 1.2: syntax error 1.10: syntax error 1.16: syntax error -./calc.at:1391: "$PERL" -pi -e 'use strict; +./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87482,7 +87880,9 @@ }eg ' expout || exit 77 ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1393: "$PERL" -pi -e 'use strict; +1.11: syntax error +1.1-16: error: 2222 != 1 +./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87492,7 +87892,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1389: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87502,8 +87903,22 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -./calc.at:1392: "$PERL" -pi -e 'use strict; +1.2: syntax error +1.10: syntax error +1.16: syntax error +./calc.at:1393: cat stderr +./calc.at:1392: cat stderr +./calc.at:1395: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87523,10 +87938,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (# + 1) = 1111 -./calc.at:1375: $PREPARSER ./calc input -stderr: -./calc.at:1387: "$PERL" -pi -e 'use strict; +./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87536,39 +87948,122 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -1.2: syntax error -1.10: syntax error -1.16: syntax error -./calc.at:1393: cat stderr -stdout: -./types.at:139: ./check -stderr: +./calc.at:1387: cat stderr +./calc.at:1375: cat stderr +./calc.at:1394: cat stderr +./calc.at:1395: cat stderr +input: +./calc.at:1390: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1393: $PREPARSER ./calc input + | (!!) + (1 2) = 1 +input: input: -1.2: syntax error: invalid character: '#' -./calc.at:1389: cat stderr ./calc.at:1374: cat stderr +./calc.at:1392: $PREPARSER ./calc input +input: + | 123 +./calc.at:1391: cat stderr +./calc.at:1389: cat stderr +stderr: +./calc.at:1375: $PREPARSER ./calc --num input +stderr: | 1 = 2 = 3 -./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1393: $PREPARSER ./calc input +syntax error +error: 2222 != 1 + | 1 + 2 * 3 + !* ++ +./calc.at:1387: $PREPARSER ./calc input +./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1394: $PREPARSER ./calc input stderr: syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 ./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./types.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o test.cc test.y + | 1 = 2 = 3 stderr: input: -./calc.at:1391: cat stderr -./calc.at:1392: cat stderr - | (1 + # + 1) = 1111 -1.2: syntax error: invalid character: '#' +stderr: +./calc.at:1395: $PREPARSER ./calc input +./calc.at:1390: cat stderr +syntax error +input: +./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +memory exhausted + | (1 + 1) / (1 - 1) +./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1374: $PREPARSER ./calc input stderr: + | (- *) + (1 2) = 1 +stderr: +input: +./calc.at:1389: $PREPARSER ./calc input +./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +syntax error +error: 2222 != 1 +stderr: +syntax error, unexpected '=' +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 +stderr: +error: null divisor +./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +syntax error +syntax error +error: 2222 != 1 + | (- *) + (1 2) = 1 +./calc.at:1391: $PREPARSER ./calc input +./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +memory exhausted stderr: syntax error +stderr: +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 +./calc.at:1375: $EGREP -c -v 'Return for a new token:|LAC:' stderr +stderr: +./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: +stderr: +error: null divisor +syntax error +syntax error +error: 2222 != 1 + | 1 + 2 * 3 + !+ ++ +stderr: +./calc.at:1390: $PREPARSER ./calc input +syntax error, unexpected '=' +stderr: +stderr: input: -syntax error: invalid character: '#' -./calc.at:1390: "$PERL" -pi -e 'use strict; +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 + | 1 + 2 * 3 +./calc.at:1375: $PREPARSER ./calc --num input +./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87578,10 +88073,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (- *) + (1 2) = 1 -./calc.at:1391: $PREPARSER ./calc input -./calc.at:1375: "$PERL" -pi -e 'use strict; +./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87592,22 +88084,18 @@ }eg ' expout || exit 77 stderr: - | (- *) + (1 2) = 1 -./calc.at:1389: $PREPARSER ./calc input -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 -./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1387: cat stderr -./calc.at:1375: cat stderr -stderr: -syntax error: invalid character: '#' -syntax error -syntax error -error: 2222 != 1 -./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1393: "$PERL" -pi -e 'use strict; +./calc.at:1374: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +1.3: syntax error, unexpected '+', expecting end of file +./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87617,19 +88105,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 -stderr: -syntax error -syntax error -error: 2222 != 1 -input: - | - | +1 -input: -./calc.at:1392: $PREPARSER ./calc input ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -87640,10 +88115,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1 + 2 * 3 + !* ++ -./calc.at:1387: $PREPARSER ./calc input -./calc.at:1390: cat stderr -./calc.at:1374: "$PERL" -pi -e 'use strict; +./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87653,19 +88125,59 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1389: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -stderr: -input: +./calc.at:1395: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1393: cat stderr -syntax error -memory exhausted -./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1392: cat stderr +./calc.at:1395: cat stderr +stderr: +./calc.at:1374: cat stderr + | 1 + 2 * 3 + !- ++ +./calc.at:1390: $PREPARSER ./calc input ./calc.at:1391: cat stderr - | (1 + # + 1) = 1111 +./calc.at:1394: cat stderr +1.3: syntax error, unexpected '+', expecting end of file +stderr: +./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -./calc.at:1375: $PREPARSER ./calc input -./calc.at:1389: "$PERL" -pi -e 'use strict; +./calc.at:1389: cat stderr +input: + | (!!) + (1 2) = 1 +./calc.at:1387: cat stderr +input: +./calc.at:1393: $PREPARSER ./calc input +input: + | (- *) + (1 2) = 1 + | 123 +./calc.at:1374: $PREPARSER ./calc --num input +./calc.at:1392: $PREPARSER ./calc input + | + | +1 +stderr: +input: +./calc.at:1395: $PREPARSER ./calc input +./calc.at:1375: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87675,51 +88187,92 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: input: -memory exhausted stderr: -input: - | 1 + 2 * 3 + !+ ++ +stderr: | | +1 +stderr: +stderr: syntax error -./calc.at:1393: $PREPARSER ./calc input -./calc.at:1390: $PREPARSER ./calc input +error: 2222 != 1 +input: +./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1394: $PREPARSER ./calc input | (* *) + (*) + (*) +syntax error, unexpected '+' ./calc.at:1391: $PREPARSER ./calc input -./calc.at:1374: cat stderr -stderr: +input: stderr: +./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +syntax error +error: 2222 != 1 stderr: + | (#) + (#) = 2222 +./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (* *) + (*) + (*) +./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1389: $PREPARSER ./calc input +./calc.at:1387: $PREPARSER ./calc input syntax error -./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1375: cat stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error -./types.at:139: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.6: syntax error: invalid character: '#' stderr: -./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +syntax error +syntax error stderr: -./calc.at:1389: cat stderr -./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error +error: 2222 != 1 +./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1390: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +stderr: +./calc.at:1374: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: +syntax error, unexpected '+' +syntax error +input: +syntax error +syntax error +error: 2222 != 1 1.2: syntax error 1.10: syntax error 1.16: syntax error -input: -input: - | (1 + 1) / (1 - 1) -./calc.at:1374: $PREPARSER ./calc input - | (* *) + (*) + (*) -./calc.at:1389: $PREPARSER ./calc input + | 1 + 2 * 3 stderr: +./calc.at:1375: $PREPARSER ./calc --exp input +syntax error: invalid character: '#' +syntax error: invalid character: '#' +input: stderr: stderr: +./calc.at:1390: cat stderr + | 1 + 2 * 3 +./calc.at:1374: $PREPARSER ./calc --num input +syntax error +syntax error +syntax error ./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -87740,12 +88293,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -syntax error -syntax error -syntax error -./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1387: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87755,12 +88305,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -error: null divisor -1.6: syntax error: invalid character: '#' -./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 + 2 * 3 + !- ++ -./calc.at:1390: $PREPARSER ./calc input -./calc.at:1392: "$PERL" -pi -e 'use strict; +syntax error +./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87770,15 +88316,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -./calc.at:1393: cat stderr -./calc.at:1391: cat stderr -syntax error -syntax error -syntax error -stderr: -./calc.at:1387: cat stderr -./calc.at:1375: "$PERL" -pi -e 'use strict; +./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87788,25 +88326,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -error: null divisor input: - | (#) + (#) = 2222 -./calc.at:1387: $PREPARSER ./calc input -stderr: -./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1393: $PREPARSER ./calc /dev/null -./calc.at:1375: cat stderr -stderr: -syntax error: invalid character: '#' -syntax error: invalid character: '#' stderr: -syntax error -./calc.at:1392: cat stderr -./calc.at:1389: "$PERL" -pi -e 'use strict; +./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 + !* ++ +./calc.at:1375: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87816,19 +88341,13 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -input: -stderr: -./calc.at:1392: $PREPARSER ./calc /dev/null - | 1 + 2 * 3 + !+ ++ - | (1 + 1) / (1 - 1) -./calc.at:1375: $PREPARSER ./calc input -./calc.at:1391: $PREPARSER ./calc input +./calc.at:1390: $PREPARSER ./calc input +./calc.at:1391: cat stderr stderr: +./calc.at:1393: cat stderr +./calc.at:1395: cat stderr stderr: -./calc.at:1389: cat stderr -./calc.at:1374: "$PERL" -pi -e 'use strict; +./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87838,8 +88357,39 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +1.14: memory exhausted +syntax error +./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +499. calc.at:1375: ok +./calc.at:1392: cat stderr +./calc.at:1395: $PREPARSER ./calc /dev/null +./calc.at:1394: cat stderr +input: +stderr: +input: +syntax error, unexpected end of input +./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (- *) + (1 2) = 1 +./calc.at:1393: $PREPARSER ./calc input +./calc.at:1394: $PREPARSER ./calc /dev/null +stderr: + | 1 + 2 * 3 + !+ ++ +stderr: +./calc.at:1391: $PREPARSER ./calc input +./calc.at:1389: cat stderr +./calc.at:1387: cat stderr +syntax error +syntax error +error: 2222 != 1 +1.14: memory exhausted +input: +./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +stderr: ./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1387: "$PERL" -pi -e 'use strict; +syntax error, unexpected end of input +./calc.at:1374: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87849,8 +88399,18 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + | (* *) + (*) + (*) +./calc.at:1392: $PREPARSER ./calc input +syntax error +stderr: +./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + stderr: +stderr: +input: syntax error +syntax error +error: 2222 != 1 ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -87861,30 +88421,33 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: -stderr: input: stderr: | 1 + 2 * 3 + !+ ++ -1.11-17: error: null divisor - | 1 + 2 * 3 + !- ++ -./calc.at:1389: $PREPARSER ./calc input -./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error -./calc.at:1391: $PREPARSER ./calc input syntax error -stderr: +syntax error +syntax error +./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1389: $PREPARSER ./calc input ./calc.at:1374: cat stderr -./calc.at:1387: cat stderr + | (1 + #) = 1111 +stderr: +./calc.at:1387: $PREPARSER ./calc input +input: stderr: -./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1390: cat stderr + | 1 + 2 * 3 + !- ++ stderr: +./calc.at:1391: $PREPARSER ./calc input +syntax error: invalid character: '#' +./calc.at:1390: cat stderr +./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1392: "$PERL" -pi -e 'use strict; +syntax error +syntax error +syntax error +./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87894,13 +88457,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.11-17: error: null divisor -stderr: -input: - | 123 -input: input: -./calc.at:1375: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87910,7 +88470,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1393: "$PERL" -pi -e 'use strict; + | 1 + 2 * 3 +./calc.at:1374: $PREPARSER ./calc --exp input +508. calc.at:1397: testing Calculator %glr-parser api.pure %locations ... +stderr: +stderr: +./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87920,8 +88485,20 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1374: $PREPARSER ./calc --num input -./calc.at:1391: "$PERL" -pi -e 'use strict; +input: +./calc.at:1395: cat stderr +./calc.at:1397: mv calc.y.tmp calc.y + +stderr: + | (#) + (#) = 2222 +./calc.at:1390: $PREPARSER ./calc input +./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1397: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +syntax error: invalid character: '#' +stderr: +input: +input: +./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87931,60 +88508,60 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1 + 2 * 3 + !* ++ - | (1 + #) = 1111 -./calc.at:1387: $PREPARSER ./calc input -./calc.at:1392: cat stderr -./calc.at:1390: $PREPARSER ./calc input -input: -input: -./calc.at:1375: cat stderr - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1392: $PREPARSER ./calc input +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !- ++ -stderr: -stderr: ./calc.at:1389: $PREPARSER ./calc input + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1395: $PREPARSER ./calc input stderr: -./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.14: memory exhausted -stderr: -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 -./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1391: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: stderr: ./calc.at:1374: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1394: cat stderr ./calc.at:1393: cat stderr -syntax error: invalid character: '#' -./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: stderr: -syntax error -syntax error -syntax error -syntax error +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' error: 4444 != 1 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error: invalid character: '#' -input: -stderr: -stderr: - | 123 -./calc.at:1391: cat stderr -./calc.at:1375: $PREPARSER ./calc --num input +./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' stderr: +./calc.at:1392: cat stderr input: -1.14: memory exhausted - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1393: $PREPARSER ./calc input +498. calc.at:1374: ok input: -./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1390: "$PERL" -pi -e 'use strict; +stderr: +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +error: 4444 != 1 + | (* *) + (*) + (*) +./calc.at:1393: $PREPARSER ./calc input + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +stderr: +./calc.at:1394: $PREPARSER ./calc input +./calc.at:1397: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +syntax error +syntax error +syntax error +./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -87994,11 +88571,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | 1 + 2 * 3 -./calc.at:1374: $PREPARSER ./calc --num input +./calc.at:1391: cat stderr stderr: -./calc.at:1392: "$PERL" -pi -e 'use strict; +./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88013,13 +88589,17 @@ syntax error syntax error error: 4444 != 1 +input: +./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -stderr: -./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 + 2 * 3 + !* ++ + | 1 + 2 * 3 + !+ ++ +./calc.at:1392: $PREPARSER ./calc input +syntax error +syntax error syntax error -./calc.at:1391: $PREPARSER ./calc input stderr: +stderr: + ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -88030,7 +88610,17 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1387: "$PERL" -pi -e 'use strict; +./calc.at:1390: cat stderr +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 +input: +./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1387: cat stderr + | 1 + 2 * 3 + !* ++ +./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88040,67 +88630,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1391: $PREPARSER ./calc input stderr: -./calc.at:1390: cat stderr -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 -stderr: -stdout: -./calc.at:1392: cat stderr -./calc.at:1394: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c - -1.14: memory exhausted -./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1375: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: +./calc.at:1395: cat stderr input: - | (!!) + (1 2) = 1 1.14: memory exhausted -./calc.at:1392: $PREPARSER ./calc input - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1394: $PREPARSER ./calc input -input: -stderr: -./calc.at:1387: cat stderr -stderr: -stderr: -syntax error -input: -./calc.at:1389: cat stderr -./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 + 2 * 3 -syntax error -error: 2222 != 1 -./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (#) + (#) = 2222 -./calc.at:1390: $PREPARSER ./calc input -./calc.at:1375: $PREPARSER ./calc --num input +./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -88111,11 +88648,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -syntax error -error: 2222 != 1 -stderr: -./calc.at:1391: "$PERL" -pi -e 'use strict; + | (# + 1) = 1111 + | (1 + #) = 1111 +./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88125,42 +88660,48 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -stderr: +./calc.at:1387: $PREPARSER ./calc input +./calc.at:1390: $PREPARSER ./calc input input: +stderr: +stderr: +stderr: +./calc.at:1389: cat stderr +syntax error: invalid character: '#' +1.6: syntax error: invalid character: '#' +./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 + !- ++ ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1392: $PREPARSER ./calc input +509. calc.at:1398: testing Calculator %glr-parser parse.error=verbose %locations ... +./calc.at:1398: mv calc.y.tmp calc.y + +input: +1.14: memory exhausted +./calc.at:1398: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y + | (!!) + (1 2) = 1 +./calc.at:1395: $PREPARSER ./calc input stderr: - | 1 + 2 * 3 + !* ++ -1.3: syntax error, unexpected '+', expecting end of file +./calc.at:1393: cat stderr input: +stderr: + | 1 + 2 * 3 + !* ++ ./calc.at:1389: $PREPARSER ./calc input stderr: +1.6: syntax error: invalid character: '#' +stderr: +./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error, unexpected number +error: 2222 != 1 stderr: +./calc.at:1394: cat stderr +./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error: invalid character: '#' +input: memory exhausted -./calc.at:1392: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (# + 1) = 1111 ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1387: $PREPARSER ./calc input -./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -input: -./calc.at:1391: cat stderr -./calc.at:1393: cat stderr - | 1 2 -./calc.at:1394: $PREPARSER ./calc input stderr: -./calc.at:1374: "$PERL" -pi -e 'use strict; +./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88170,19 +88711,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + | 1 + 2 * 3 + !+ ++ +./calc.at:1393: $PREPARSER ./calc input stderr: -syntax error: invalid character: '#' -stderr: -./calc.at:1392: cat stderr -./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error -./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -memory exhausted stderr: -input: stderr: -syntax error: invalid character: '#' -1.3: syntax error, unexpected '+', expecting end of file +./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -88193,27 +88727,19 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: +syntax error, unexpected number +error: 2222 != 1 input: -syntax error - | (#) + (#) = 2222 - | (- *) + (1 2) = 1 -./calc.at:1391: $PREPARSER ./calc input -./calc.at:1392: $PREPARSER ./calc input -stderr: +memory exhausted + | (!!) + (1 2) = 1 +./calc.at:1394: $PREPARSER ./calc input stderr: -syntax error -syntax error -error: 2222 != 1 -./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -input: -syntax error syntax error error: 2222 != 1 +./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1391: cat stderr +./calc.at:1390: cat stderr ./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -88224,10 +88750,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (!!) + (1 2) = 1 -./calc.at:1374: cat stderr -./calc.at:1393: $PREPARSER ./calc input -./calc.at:1375: "$PERL" -pi -e 'use strict; +./calc.at:1398: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88237,9 +88761,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1390: cat stderr stderr: -./calc.at:1394: "$PERL" -pi -e 'use strict; +input: +./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88251,6 +88775,9 @@ ' expout || exit 77 syntax error error: 2222 != 1 + | 1 + 2 * 3 + !- ++ +./calc.at:1393: $PREPARSER ./calc input +input: input: ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} @@ -88262,45 +88789,28 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1375: cat stderr -./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1387: cat stderr - | 1 + 2 * 3 -./calc.at:1374: $PREPARSER ./calc --exp input + | (#) + (#) = 2222 +./calc.at:1391: $PREPARSER ./calc input stderr: +./calc.at:1387: cat stderr +./calc.at:1395: cat stderr stderr: -input: + | (# + 1) = 1111 +./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1390: $PREPARSER ./calc input stderr: - | (1 + #) = 1111 -syntax error -error: 2222 != 1 -./calc.at:1392: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' -./calc.at:1389: cat stderr -./calc.at:1390: $PREPARSER ./calc input -input: -./calc.at:1394: cat stderr -stderr: -1.6: syntax error: invalid character: '#' +./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error: invalid character: '#' ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1392: cat stderr +input: input: -./calc.at:1374: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 + 2 * 3 -./calc.at:1375: $PREPARSER ./calc --exp input - | (1 + # + 1) = 1111 -./calc.at:1387: $PREPARSER ./calc input stderr: -./calc.at:1391: "$PERL" -pi -e 'use strict; +stderr: + | (1 + # + 1) = 1111 +./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88310,44 +88820,30 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1389: cat stderr +stderr: +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1387: $PREPARSER ./calc input + | (- *) + (1 2) = 1 +./calc.at:1395: $PREPARSER ./calc input stderr: stderr: +1.2: syntax error: invalid character: '#' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected number +error: 2222 != 1 +./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: syntax error: invalid character: '#' ./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -./calc.at:1374: $EGREP -c -v 'Return for a new token:|LAC:' stderr -stderr: | (#) + (#) = 2222 -syntax error: invalid character: '#' + | 1 + 2 * 3 + !* ++ ./calc.at:1389: $PREPARSER ./calc input -./calc.at:1392: cat stderr -stderr: -./calc.at:1391: cat stderr -syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1375: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: -input: - | (* *) + (*) + (*) ./calc.at:1392: $PREPARSER ./calc input - | 1//2 -./calc.at:1394: $PREPARSER ./calc input stderr: -syntax error -syntax error -syntax error -stderr: -./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error -./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error -syntax error -syntax error -./calc.at:1387: "$PERL" -pi -e 'use strict; +./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88357,9 +88853,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -1.6: syntax error: invalid character: '#' -./calc.at:1393: "$PERL" -pi -e 'use strict; +./calc.at:1394: cat stderr +./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88370,10 +88865,17 @@ }eg ' expout || exit 77 stderr: -498. calc.at:1374: ok -./calc.at:1375: $EGREP -c -v 'Return for a new token:|LAC:' stderr -syntax error -./calc.at:1392: "$PERL" -pi -e 'use strict; +stderr: +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected number +error: 2222 != 1 +syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +memory exhausted +./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88383,19 +88885,24 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (1 + #) = 1111 -./calc.at:1391: $PREPARSER ./calc input +syntax error: invalid character: '#' +input: +stderr: stderr: syntax error: invalid character: '#' syntax error: invalid character: '#' -./calc.at:1387: cat stderr + | (- *) + (1 2) = 1 +./calc.at:1394: $PREPARSER ./calc input +./calc.at:1391: cat stderr +memory exhausted stderr: -./calc.at:1392: cat stderr -499. calc.at:1375: ok -./calc.at:1393: cat stderr -1.6: syntax error: invalid character: '#' -./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1390: "$PERL" -pi -e 'use strict; +syntax error +syntax error +error: 2222 != 1 +./calc.at:1390: cat stderr +./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88405,8 +88912,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -./calc.at:1394: "$PERL" -pi -e 'use strict; +./calc.at:1393: cat stderr + | (1 + #) = 1111 +./calc.at:1391: $PREPARSER ./calc input +./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88417,16 +88926,13 @@ }eg ' expout || exit 77 stderr: - | (1 + 1) / (1 - 1) -./calc.at:1387: $PREPARSER ./calc input stderr: -1.6: syntax error: invalid character: '#' - input: -error: null divisor -./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (- *) + (1 2) = 1 -./calc.at:1393: $PREPARSER ./calc input +./calc.at:1395: cat stderr +1.6: syntax error: invalid character: '#' +syntax error +syntax error +error: 2222 != 1 ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -88437,18 +88943,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + # + 1) = 1111 input: +./calc.at:1390: $PREPARSER ./calc input + | 1 + 2 * 3 + !* ++ +./calc.at:1393: $PREPARSER ./calc input stderr: -stderr: -error: null divisor - | 1 + 2 * 3 + !+ ++ -./calc.at:1392: $PREPARSER ./calc input -./calc.at:1394: cat stderr -syntax error -syntax error -error: 2222 != 1 -./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1391: "$PERL" -pi -e 'use strict; +./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88459,28 +88961,28 @@ }eg ' expout || exit 77 stderr: -./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1389: cat stderr -stderr: input: -./calc.at:1390: cat stderr - | (1 + #) = 1111 -./calc.at:1389: $PREPARSER ./calc input +./calc.at:1387: cat stderr +1.6: syntax error: invalid character: '#' +1.6: syntax error: invalid character: '#' +./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -syntax error: invalid character: '#' -./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - + | (* *) + (*) + (*) +./calc.at:1395: $PREPARSER ./calc input +memory exhausted +./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: -syntax error: invalid character: '#' -syntax error -syntax error -error: 2222 != 1 -input: +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: - | 1 + 2 * 3 + !- ++ -./calc.at:1392: $PREPARSER ./calc input -./calc.at:1387: "$PERL" -pi -e 'use strict; +./calc.at:1389: cat stderr +./calc.at:1392: cat stderr +1.6: syntax error: invalid character: '#' +stderr: +./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88490,25 +88992,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | error -./calc.at:1394: $PREPARSER ./calc input -stderr: -input: -./calc.at:1391: cat stderr -stderr: -508. calc.at:1397: testing Calculator %glr-parser api.pure %locations ... -./calc.at:1397: mv calc.y.tmp calc.y - -./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (# + 1) = 1111 -./calc.at:1390: $PREPARSER ./calc input -stderr: -stderr: -./calc.at:1397: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -syntax error -./calc.at:1387: cat stderr -./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1389: "$PERL" -pi -e 'use strict; +memory exhausted + | (1 + 1) / (1 - 1) +./calc.at:1387: $PREPARSER ./calc input +./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88518,19 +89005,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | (# + 1) = 1111 -./calc.at:1391: $PREPARSER ./calc input stderr: -syntax error -500. calc.at:1387: ok -1.2: syntax error: invalid character: '#' -./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1389: cat stderr -stderr: -1.2: syntax error: invalid character: '#' -./calc.at:1393: "$PERL" -pi -e 'use strict; +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +input: +error: null divisor +input: +./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88540,12 +89023,30 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.2: syntax error: invalid character: '#' -./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | (# + 1) = 1111 +./calc.at:1387: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + #) = 1111 +./calc.at:1391: cat stderr ./calc.at:1389: $PREPARSER ./calc input -./calc.at:1394: "$PERL" -pi -e 'use strict; + | (#) + (#) = 2222 +./calc.at:1392: $PREPARSER ./calc input +./calc.at:1394: cat stderr +stderr: +stderr: +error: null divisor +stderr: +input: +syntax error: invalid character: '#' +./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1390: cat stderr +input: + | (* *) + (*) + (*) +./calc.at:1394: $PREPARSER ./calc input +syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88555,7 +89056,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1392: "$PERL" -pi -e 'use strict; + | (# + 1) = 1111 +./calc.at:1391: $PREPARSER ./calc input +./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88565,46 +89068,17 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: syntax error: invalid character: '#' -./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -509. calc.at:1398: testing Calculator %glr-parser parse.error=verbose %locations ... -./calc.at:1398: mv calc.y.tmp calc.y - -./calc.at:1398: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -./calc.at:1393: cat stderr -input: -stderr: -./calc.at:1390: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 stderr: 1.2: syntax error: invalid character: '#' -./calc.at:1390: cat stderr - | (* *) + (*) + (*) -./calc.at:1393: $PREPARSER ./calc input - -./calc.at:1392: cat stderr -stderr: syntax error syntax error syntax error -./calc.at:1398: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS -./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error: invalid character: '#' -./calc.at:1394: cat stderr +./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -syntax error -syntax error -syntax error -./calc.at:1391: "$PERL" -pi -e 'use strict; +input: +./calc.at:1387: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88614,33 +89088,24 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -input: - | 1 = 2 = 3 -./calc.at:1394: $PREPARSER ./calc input - | 1 + 2 * 3 + !* ++ -./calc.at:1392: $PREPARSER ./calc input +syntax error: invalid character: '#' +syntax error: invalid character: '#' + | (1 + 1) / (1 - 1) stderr: +./calc.at:1390: $PREPARSER ./calc input stderr: +1.2: syntax error: invalid character: '#' +./calc.at:1395: cat stderr +syntax error syntax error -./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -memory exhausted -./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: syntax error -input: - | (1 + # + 1) = 1111 -./calc.at:1390: $PREPARSER ./calc input -stderr: -memory exhausted stderr: -./calc.at:1397: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS -1.6: syntax error: invalid character: '#' +./calc.at:1393: cat stderr +1.11-17: error: null divisor ./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1391: cat stderr -./calc.at:1392: "$PERL" -pi -e 'use strict; +1.11-17: error: null divisor +./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88650,11 +89115,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -510. calc.at:1400: testing Calculator %glr-parser parse.error=custom %locations %header %name-prefix "calc" %verbose ... -./calc.at:1400: mv calc.y.tmp calc.y - -./calc.at:1390: "$PERL" -pi -e 'use strict; +./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88664,7 +89125,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1389: "$PERL" -pi -e 'use strict; +./calc.at:1387: cat stderr +./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88674,7 +89136,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1393: "$PERL" -pi -e 'use strict; +input: +input: + | (#) + (#) = 2222 +stderr: +./calc.at:1393: $PREPARSER ./calc input + | 1 + 2 * 3 + !+ ++ +./calc.at:1395: $PREPARSER ./calc input +./calc.at:1391: cat stderr +./calc.at:1390: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88684,21 +89154,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stdout: input: | (1 + # + 1) = 1111 +stdout: ./calc.at:1391: $PREPARSER ./calc input -./calc.at:1395: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c - ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -88710,52 +89169,33 @@ }eg ' expout || exit 77 stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1390: cat stderr stderr: -./calc.at:1392: cat stderr -1.6: syntax error: invalid character: '#' ./calc.at:1389: cat stderr -./calc.at:1393: cat stderr -input: - | (1 + 1) / (1 - 1) -./calc.at:1390: $PREPARSER ./calc input -input: -stderr: -input: -./calc.at:1400: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y - | (#) + (#) = 2222 -./calc.at:1392: $PREPARSER ./calc input -1.11-17: error: null divisor - | 1 + 2 * 3 + !+ ++ -./calc.at:1393: $PREPARSER ./calc input -./calc.at:1390: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1397: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c + +./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +500. calc.at:1387: ok +./calc.at:1392: cat stderr stderr: -./calc.at:1394: cat stderr -input: -./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' syntax error: invalid character: '#' +./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.6: syntax error: invalid character: '#' +./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +input: stderr: -./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.11-17: error: null divisor -./calc.at:1391: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 input: - | - | +1 -./calc.at:1394: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -88769,21 +89209,30 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -stderr: +./calc.at:1397: $PREPARSER ./calc input input: -stderr: | 1 + 2 * 3 + !- ++ -./calc.at:1393: $PREPARSER ./calc input -input: +./calc.at:1390: cat stderr +stderr: ./calc.at:1395: $PREPARSER ./calc input +./calc.at:1394: cat stderr +stderr: + | (# + 1) = 1111 +1.6: syntax error: invalid character: '#' syntax error: invalid character: '#' syntax error: invalid character: '#' -stderr: - | (1 + # + 1) = 1111 + | (1 + #) = 1111 ./calc.at:1389: $PREPARSER ./calc input stderr: +./calc.at:1392: $PREPARSER ./calc input ./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1390: "$PERL" -pi -e 'use strict; +./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +502. calc.at:1390: stderr: + ok +stderr: + +input: +./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88794,13 +89243,17 @@ }eg ' expout || exit 77 stderr: -syntax error syntax error: invalid character: '#' -./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1390: cat stderr -./calc.at:1392: "$PERL" -pi -e 'use strict; +syntax error: invalid character: '#' +./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 + !+ ++ +./calc.at:1394: $PREPARSER ./calc input +stderr: +stderr: +stderr: +./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88810,21 +89263,44 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +syntax error: invalid character: '#' +input: +stderr: + | 1 2 stderr: +./calc.at:1397: $PREPARSER ./calc input stderr: syntax error: invalid character: '#' -./calc.at:1400: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS ./calc.at:1391: cat stderr -502. calc.at:1390: ok +1.3: syntax error +input: +./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +510. calc.at:1400: testing Calculator %glr-parser parse.error=custom %locations %header %name-prefix "calc" %verbose ... +./calc.at:1400: mv calc.y.tmp calc.y + +./calc.at:1395: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + + | 1 + 2 * 3 + !- ++ stderr: +./calc.at:1394: $PREPARSER ./calc input +./calc.at:1393: cat stderr +./calc.at:1395: cat stderr stderr: -syntax error -input: +1.3: syntax error input: - | 1 2 -./calc.at:1395: $PREPARSER ./calc input -./calc.at:1392: cat stderr +./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1400: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y | (1 + 1) / (1 - 1) +./calc.at:1391: $PREPARSER ./calc input ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -88835,10 +89311,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - -./calc.at:1391: $PREPARSER ./calc input -stderr: -./calc.at:1394: "$PERL" -pi -e 'use strict; +./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88849,16 +89322,9 @@ }eg ' expout || exit 77 stderr: -1.11-17: error: null divisor -./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -syntax error, unexpected number - | (1 + #) = 1111 -./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1392: $PREPARSER ./calc input -stderr: -syntax error, unexpected number -./calc.at:1393: "$PERL" -pi -e 'use strict; +1.11-17: error: null divisor +./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88868,19 +89334,34 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + | (1 + #) = 1111 +./calc.at:1391: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1393: $PREPARSER ./calc input +input: stderr: + | 1 + 2 * 3 + !* ++ +./calc.at:1395: $PREPARSER ./calc input syntax error: invalid character: '#' -./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1392: cat stderr stderr: stderr: -syntax error: invalid character: '#' -1.11-17: error: null divisor -511. calc.at:1401: testing Calculator %glr-parser parse.error=custom %locations %header %name-prefix "calc" %verbose api.pure ... ./calc.at:1389: cat stderr +511. calc.at:1401: testing Calculator %glr-parser parse.error=custom %locations %header %name-prefix "calc" %verbose api.pure ... ./calc.at:1401: mv calc.y.tmp calc.y -./calc.at:1394: cat stderr -./calc.at:1392: "$PERL" -pi -e 'use strict; +1.11-17: error: null divisor +memory exhausted +./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +syntax error: invalid character: '#' +memory exhausted +input: +./calc.at:1397: cat stderr +./calc.at:1401: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +./calc.at:1391: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88890,8 +89371,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1394: $PREPARSER ./calc /dev/null -./calc.at:1391: "$PERL" -pi -e 'use strict; +input: + | (# + 1) = 1111 +./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88901,7 +89383,19 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1395: "$PERL" -pi -e 'use strict; +./calc.at:1392: $PREPARSER ./calc input + | (1 + # + 1) = 1111 +./calc.at:1389: $PREPARSER ./calc input +./calc.at:1400: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS +stderr: +syntax error: invalid character: '#' +./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +syntax error: invalid character: '#' +input: +./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1391: cat stderr +./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88911,46 +89405,41 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1401: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -./calc.at:1395: cat stderr -./calc.at:1393: cat stderr -input: stderr: - | (1 + 1) / (1 - 1) -syntax error -./calc.at:1389: $PREPARSER ./calc input -./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1392: cat stderr -input: stderr: +./calc.at:1395: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1394: cat stderr | 1//2 -./calc.at:1395: $PREPARSER ./calc input -error: null divisor -input: -./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1397: $PREPARSER ./calc input +syntax error: invalid character: '#' stderr: -./calc.at:1391: cat stderr +503. calc.at:1391: ok +syntax error: invalid character: '#' +1.3: syntax error +./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1395: cat stderr +input: +./calc.at:1393: cat stderr | 1 + 2 * 3 + !* ++ +./calc.at:1394: $PREPARSER ./calc input stderr: -./calc.at:1393: $PREPARSER ./calc input -error: null divisor -stderr: +./calc.at:1401: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS input: -memory exhausted -./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (# + 1) = 1111 -stderr: stderr: -./calc.at:1392: $PREPARSER ./calc input +1.3: syntax error + | (#) + (#) = 2222 +./calc.at:1395: $PREPARSER ./calc input +input: memory exhausted -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -syntax error -503. calc.at:1391: ok -./calc.at:1401: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS -stderr: ./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -88961,9 +89450,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -syntax error: invalid character: '#' -./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1395: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88973,7 +89461,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1393: "$PERL" -pi -e 'use strict; +./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (# + 1) = 1111 +./calc.at:1393: $PREPARSER ./calc input +syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + +./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -88983,6 +89478,23 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +stderr: +stderr: +syntax error: invalid character: '#' +./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +memory exhausted +stderr: +syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1392: cat stderr +stderr: +./calc.at:1397: cat stderr +./calc.at:1389: cat stderr +syntax error: invalid character: '#' +512. calc.at:1402: testing Calculator %glr-parser parse.error=detailed %locations %header %name-prefix "calc" %verbose ... +input: +./calc.at:1402: mv calc.y.tmp calc.y + ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -88993,24 +89505,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1395: cat stderr -./calc.at:1389: cat stderr -./calc.at:1393: cat stderr -stderr: -501. calc.at:1389: ok -syntax error: invalid character: '#' -input: - | error -./calc.at:1395: $PREPARSER ./calc input input: -stderr: - - | (#) + (#) = 2222 -./calc.at:1393: $PREPARSER ./calc input -syntax error, unexpected invalid token -./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1392: "$PERL" -pi -e 'use strict; +./calc.at:1397: $PREPARSER ./calc input +input: +./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -89020,33 +89519,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -512. calc.at:1402: testing Calculator %glr-parser parse.error=detailed %locations %header %name-prefix "calc" %verbose ... -./calc.at:1392: cat stderr -./calc.at:1394: cat stderr -stderr: -./calc.at:1402: mv calc.y.tmp calc.y - -stderr: -input: -syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1394: $PREPARSER ./calc input -./calc.at:1402: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: -syntax error, unexpected invalid token -input: + | (1 + 1) / (1 - 1) | (1 + # + 1) = 1111 +1.1: syntax error +./calc.at:1389: $PREPARSER ./calc input +./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: $PREPARSER ./calc input -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 -./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1395: "$PERL" -pi -e 'use strict; +./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -89056,31 +89536,26 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -syntax error: invalid character: '#' stderr: -./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error: invalid character: '#' +./calc.at:1402: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +stderr: +./calc.at:1395: cat stderr syntax error: invalid character: '#' +./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 +error: null divisor +./calc.at:1389: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1394: cat stderr +1.1: syntax error stderr: syntax error: invalid character: '#' -./calc.at:1395: cat stderr input: - | 1 = 2 = 3 -513. calc.at:1403: testing Calculator %glr-parser parse.error=verbose %locations %header %name-prefix "calc" %verbose ... -./calc.at:1403: mv calc.y.tmp calc.y - -./calc.at:1395: $PREPARSER ./calc input stderr: -syntax error, unexpected '=' -./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1402: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS -./calc.at:1392: "$PERL" -pi -e 'use strict; +./calc.at:1393: cat stderr + | (#) + (#) = 2222 +./calc.at:1394: $PREPARSER ./calc input +error: null divisor +./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -89090,8 +89565,19 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +input: stderr: -./calc.at:1393: "$PERL" -pi -e 'use strict; + | (1 + #) = 1111 +./calc.at:1395: $PREPARSER ./calc input +syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +syntax error: invalid character: '#' +input: +./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1392: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -89101,8 +89587,16 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1403: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -./calc.at:1394: "$PERL" -pi -e 'use strict; + | (1 + # + 1) = 1111 +./calc.at:1393: $PREPARSER ./calc input +stderr: +./calc.at:1397: cat stderr +./calc.at:1402: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS +syntax error: invalid character: '#' +syntax error: invalid character: '#' +syntax error: invalid character: '#' +stderr: +./calc.at:1389: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -89112,12 +89606,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -syntax error, unexpected '=' -./calc.at:1394: cat stderr +syntax error: invalid character: '#' +./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1392: cat stderr -./calc.at:1393: cat stderr -./calc.at:1403: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS input: +stderr: +syntax error: invalid character: '#' + | 1 = 2 = 3 +./calc.at:1397: $PREPARSER ./calc input ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -89128,39 +89624,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (!!) + (1 2) = 1 -input: -./calc.at:1394: $PREPARSER ./calc input -input: -stderr: -./calc.at:1395: cat stderr - | (1 + #) = 1111 -./calc.at:1393: $PREPARSER ./calc input -syntax error -error: 2222 != 1 - | (1 + 1) / (1 - 1) -stderr: -./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1392: $PREPARSER ./calc input -syntax error: invalid character: '#' -stderr: -./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error -error: 2222 != 1 -error: null divisor -./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | - | +1 -stderr: -stderr: -./calc.at:1395: $PREPARSER ./calc input -syntax error: invalid character: '#' -stderr: -error: null divisor -syntax error, unexpected '+' -./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -89172,8 +89635,21 @@ }eg ' expout || exit 77 stderr: -syntax error, unexpected '+' -./calc.at:1392: "$PERL" -pi -e 'use strict; +input: +./calc.at:1389: cat stderr +1.7: syntax error + | (1 + 1) / (1 - 1) +./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1392: $PREPARSER ./calc input +./calc.at:1395: cat stderr +stderr: +501. calc.at:1389: ok +stderr: +error: null divisor +./calc.at:1394: cat stderr +./calc.at:1392: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.7: syntax error +./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -89183,7 +89659,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1393: "$PERL" -pi -e 'use strict; +input: + | (# + 1) = 1111 +input: +./calc.at:1395: $PREPARSER ./calc input +stderr: +./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -89193,35 +89674,22 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1394: cat stderr -./calc.at:1392: cat stderr -./calc.at:1395: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1393: cat stderr -504. calc.at:1392: ok -./calc.at:1395: cat stderr -input: -input: - | (# + 1) = 1111 - | (- *) + (1 2) = 1 -./calc.at:1393: $PREPARSER ./calc input -./calc.at:1395: $PREPARSER ./calc /dev/null + | (1 + #) = 1111 +stderr: +error: null divisor ./calc.at:1394: $PREPARSER ./calc input +syntax error: invalid character: '#' +./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -stdout: + +./calc.at:1393: cat stderr stderr: +syntax error: invalid character: '#' +./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -syntax error -syntax error -error: 2222 != 1 +stdout: +./calc.at:1397: cat stderr +syntax error: invalid character: '#' ./calc.at:1398: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" @@ -89233,10 +89701,22 @@ || /\t/ )' calc.c -./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error: invalid character: '#' -./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1392: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: + | (1 + 1) / (1 - 1) +./calc.at:1393: $PREPARSER ./calc input +syntax error: invalid character: '#' +input: input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 @@ -89251,26 +89731,17 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -./calc.at:1398: $PREPARSER ./calc input - -syntax error, unexpected end of input -stderr: -./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error -syntax error -error: 2222 != 1 stderr: + | + | +1 +./calc.at:1398: $PREPARSER ./calc input +./calc.at:1397: $PREPARSER ./calc input +error: null divisor stderr: -syntax error, unexpected end of input -syntax error: invalid character: '#' +./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -514. calc.at:1405: testing Calculator %glr-parser parse.error=custom %locations %header %name-prefix "calc" %verbose ... -input: - | 1 2 -./calc.at:1398: $PREPARSER ./calc input -./calc.at:1394: "$PERL" -pi -e 'use strict; +513. calc.at:1403: testing Calculator %glr-parser parse.error=verbose %locations %header %name-prefix "calc" %verbose ... +./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -89280,11 +89751,18 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1405: mv calc.y.tmp calc.y +./calc.at:1392: cat stderr +2.1: syntax error +./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1403: mv calc.y.tmp calc.y +./calc.at:1395: cat stderr +error: null divisor +504. calc.at:1392: ok stderr: -1.3: syntax error, unexpected number -./calc.at:1393: "$PERL" -pi -e 'use strict; +./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -89294,8 +89772,18 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1395: "$PERL" -pi -e 'use strict; +2.1: syntax error +stderr: +input: +input: + | 1 2 +./calc.at:1398: $PREPARSER ./calc input +./calc.at:1403: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y + | (1 + # + 1) = 1111 +./calc.at:1394: cat stderr +./calc.at:1395: $PREPARSER ./calc input +stderr: +./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -89305,30 +89793,13 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1405: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -./calc.at:1395: cat stderr -./calc.at:1394: cat stderr stderr: 1.3: syntax error, unexpected number -input: -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1395: $PREPARSER ./calc input - | (* *) + (*) + (*) -./calc.at:1394: $PREPARSER ./calc input -stderr: -syntax error -syntax error -syntax error -./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1393: cat stderr -stderr: -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -error: 4444 != 1 -./calc.at:1398: "$PERL" -pi -e 'use strict; + +./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error: invalid character: '#' +./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1393: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -89338,32 +89809,20 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1398: cat stderr -stderr: -stderr: -syntax error -syntax error -syntax error -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -error: 4444 != 1 -input: -./calc.at:1405: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS - | 1//2 -./calc.at:1398: $PREPARSER ./calc input input: + | (# + 1) = 1111 stderr: - | (1 + # + 1) = 1111 -./calc.at:1393: $PREPARSER ./calc input +./calc.at:1394: $PREPARSER ./calc input +stderr: +./calc.at:1397: cat stderr +1.3: syntax error, unexpected number +syntax error: invalid character: '#' stderr: +./calc.at:1393: cat stderr syntax error: invalid character: '#' -./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1394: "$PERL" -pi -e 'use strict; +./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1397: $PREPARSER ./calc /dev/null +./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -89373,11 +89832,17 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1403: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: stderr: -./calc.at:1394: cat stderr -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +1.1: syntax error +./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1398: cat stderr +514. calc.at:1405: testing Calculator %glr-parser parse.error=custom %locations %header %name-prefix "calc" %verbose ... +./calc.at:1405: mv calc.y.tmp calc.y + syntax error: invalid character: '#' +505. calc.at:1393: ok ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -89388,7 +89853,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1398: "$PERL" -pi -e 'use strict; +stderr: +1.1: syntax error +./calc.at:1395: cat stderr +./calc.at:1405: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +input: + | 1//2 +./calc.at:1398: $PREPARSER ./calc input +./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -89398,8 +89870,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1395: cat stderr -./calc.at:1393: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -89409,115 +89881,23 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1398: cat stderr -input: -stderr: -input: - | 1 + 2 * 3 + !+ ++ -./calc.at:1394: $PREPARSER ./calc input - | error -./calc.at:1398: $PREPARSER ./calc input -stderr: -stdout: -stderr: input: -./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1393: cat stderr -./calc.at:1397: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c - - | (!!) + (1 2) = 1 +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' + | (1 + 1) / (1 - 1) ./calc.at:1395: $PREPARSER ./calc input -stderr: -1.1: syntax error, unexpected invalid token ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -syntax error, unexpected number -error: 2222 != 1 -input: -./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -stderr: -stderr: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 - | 1 + 2 * 3 + !- ++ -./calc.at:1397: $PREPARSER ./calc input -syntax error, unexpected number -error: 2222 != 1 -./calc.at:1394: $PREPARSER ./calc input -stderr: -stdout: -input: -stderr: -./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1400: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c calc.h +error: null divisor +./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: - | (1 + 1) / (1 - 1) -./calc.at:1393: $PREPARSER ./calc input stderr: +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' error: null divisor -1.1: syntax error, unexpected invalid token -./calc.at:1393: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: -./calc.at:1394: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1400: $PREPARSER ./calc input +./calc.at:1397: cat stderr +./calc.at:1394: cat stderr +./calc.at:1405: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS input: -stderr: ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -89528,13 +89908,25 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 2 +515. calc.at:1407: testing Calculator %glr-parser %debug ... + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1397: $PREPARSER ./calc input -stderr: -stderr: input: +./calc.at:1407: mv calc.y.tmp calc.y + +./calc.at:1398: cat stderr + | (1 + # + 1) = 1111 +./calc.at:1394: $PREPARSER ./calc input +stderr: +./calc.at:1407: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 +./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error: invalid character: '#' ./calc.at:1395: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -89545,48 +89937,21 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1 2 -./calc.at:1400: $PREPARSER ./calc input -error: null divisor -stderr: -1.3: syntax error -./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) -./calc.at:1394: cat stderr -./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) +./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1398: cat stderr -stdout: +./calc.at:1395: cat stderr stderr: input: -1.3: syntax error - | 1 + 2 * 3 + !* ++ -./calc.at:1393: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1394: $PREPARSER ./calc input -./calc.at:1400: cat stderr -./calc.at:1401: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c calc.h - -./calc.at:1395: cat stderr +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 + | error +./calc.at:1398: $PREPARSER ./calc input +syntax error: invalid character: '#' +stderr: +1.1: syntax error, unexpected invalid token ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -89597,32 +89962,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -memory exhausted -input: -./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 = 2 = 3 -./calc.at:1398: $PREPARSER ./calc input -input: -stderr: -stderr: - | (- *) + (1 2) = 1 -1.7: syntax error, unexpected '=' -./calc.at:1395: $PREPARSER ./calc input -./calc.at:1393: cat stderr ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -memory exhausted -stderr: -1.7: syntax error, unexpected '=' -input: +507. calc.at:1395: ok stderr: -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected number -error: 2222 != 1 - | 1//2 -./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1400: $PREPARSER ./calc input -./calc.at:1398: "$PERL" -pi -e 'use strict; +./calc.at:1407: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS +1.1: syntax error, unexpected invalid token +./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -89632,43 +89977,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -stderr: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1401: $PREPARSER ./calc input -./calc.at:1398: cat stderr -1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) -./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -input: -505. calc.at:1393: ok -1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) -./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected number -error: 2222 != 1 -stderr: - | - | +1 -./calc.at:1398: $PREPARSER ./calc input -stderr: -2.1: syntax error, unexpected '+' -./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1394: "$PERL" -pi -e 'use strict; +./calc.at:1397: cat stderr + +./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -89678,51 +89989,35 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1400: cat stderr -./calc.at:1397: cat stderr input: + | (!!) + (1 2) = 1 +./calc.at:1398: cat stderr +./calc.at:1397: $PREPARSER ./calc input +stderr: ./calc.at:1394: cat stderr - | 1 2 -./calc.at:1401: $PREPARSER ./calc input +1.11: syntax error +1.1-16: error: 2222 != 1 +./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: + | 1 = 2 = 3 +./calc.at:1398: $PREPARSER ./calc input stderr: +1.11: syntax error +1.1-16: error: 2222 != 1 stderr: -1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) +1.7: syntax error, unexpected '=' +./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: - | (#) + (#) = 2222 +516. calc.at:1408: testing Calculator %glr-parser parse.error=verbose %debug %locations %header %name-prefix "calc" %verbose ... +./calc.at:1408: mv calc.y.tmp calc.y + + | (1 + 1) / (1 - 1) ./calc.at:1394: $PREPARSER ./calc input -./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -2.1: syntax error, unexpected '+' -input: stderr: - | 1//2 -syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1397: $PREPARSER ./calc input +error: null divisor ./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.3: syntax error -./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: - | error - -./calc.at:1400: $PREPARSER ./calc input -stderr: -./calc.at:1398: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.3: syntax error -syntax error: invalid character: '#' -syntax error: invalid character: '#' -stderr: -./calc.at:1395: "$PERL" -pi -e 'use strict; +./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -89732,8 +90027,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +1.7: syntax error, unexpected '=' +./calc.at:1408: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: -./calc.at:1397: "$PERL" -pi -e 'use strict; +error: null divisor +./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -89744,12 +90042,8 @@ }eg ' expout || exit 77 ./calc.at:1398: cat stderr -1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) -./calc.at:1398: $PREPARSER ./calc /dev/null -./calc.at:1395: cat stderr -stderr: +./calc.at:1397: cat stderr +input: ./calc.at:1394: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -89760,12 +90054,26 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.1: syntax error, unexpected end of input -./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | + | +1 +./calc.at:1398: $PREPARSER ./calc input stderr: -1.1: syntax error, unexpected end of input -./calc.at:1401: cat stderr input: +./calc.at:1408: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS +2.1: syntax error, unexpected '+' + | (- *) + (1 2) = 1 +./calc.at:1397: $PREPARSER ./calc input +./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 +./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1394: cat stderr +2.1: syntax error, unexpected '+' +stderr: +506. calc.at:1394: ok ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -89776,71 +90084,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (* *) + (*) + (*) -stderr: -./calc.at:1395: $PREPARSER ./calc input -1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1398: cat stderr -./calc.at:1400: cat stderr -./calc.at:1394: cat stderr -./calc.at:1397: cat stderr -input: -515. calc.at:1407: testing Calculator %glr-parser %debug ... -./calc.at:1407: mv calc.y.tmp calc.y - -./calc.at:1407: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y - | 1//2 -input: -./calc.at:1401: $PREPARSER ./calc input -stderr: -input: -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -input: - | (1 + #) = 1111 - | error -./calc.at:1397: $PREPARSER ./calc input -./calc.at:1394: $PREPARSER ./calc input -stderr: - | 1 = 2 = 3 -1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) -./calc.at:1400: $PREPARSER ./calc input -input: -stderr: -./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error: invalid character: '#' -./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -stderr: -./calc.at:1398: $PREPARSER ./calc input -1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) -stderr: -./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.1-46: error: 4444 != 1 -./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.1: syntax error -./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) -stderr: -1.1: syntax error -stderr: -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.1-46: error: 4444 != 1 +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -89851,14 +90097,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) -stderr: +./calc.at:1398: cat stderr stderr: stdout: -./calc.at:1400: cat stderr -syntax error: invalid character: '#' -./calc.at:1402: "$PERL" -ne ' +./calc.at:1400: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. @@ -89869,24 +90111,11 @@ || /\t/ )' calc.c calc.h -./calc.at:1401: cat stderr +./calc.at:1398: $PREPARSER ./calc /dev/null input: +stderr: + ./calc.at:1397: cat stderr -./calc.at:1407: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c $LIBS - | - | +1 -input: -./calc.at:1400: $PREPARSER ./calc input -./calc.at:1395: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -89900,71 +90129,25 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -./calc.at:1402: $PREPARSER ./calc input -./calc.at:1398: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: +./calc.at:1400: $PREPARSER ./calc input stderr: -input: -./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1395: cat stderr -input: - | 1 = 2 = 3 - | error -./calc.at:1397: $PREPARSER ./calc input -./calc.at:1401: $PREPARSER ./calc input -2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) +1.1: syntax error, unexpected end of input +./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -./calc.at:1398: cat stderr -stderr: -2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) -1.7: syntax error -stderr: -./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) -input: -./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1394: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 input: stderr: -1.7: syntax error - | (!!) + (1 2) = 1 -./calc.at:1398: $PREPARSER ./calc input - | 1 2 + | (* *) + (*) + (*) stderr: -./calc.at:1400: cat stderr +./calc.at:1397: $PREPARSER ./calc input stderr: -./calc.at:1402: $PREPARSER ./calc input +1.1: syntax error, unexpected end of input stderr: -input: -1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) stdout: -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 -stderr: - | 1 + 2 * 3 + !+ ++ -./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1395: $PREPARSER ./calc input -./calc.at:1403: "$PERL" -ne ' +input: +1.2: syntax error +1.10: syntax error +1.16: syntax error +./calc.at:1401: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. @@ -89975,18 +90158,31 @@ || /\t/ )' calc.c calc.h -1.3: syntax error, unexpected number -./calc.at:1400: $PREPARSER ./calc /dev/null -./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1401: cat stderr +./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +517. calc.at:1409: testing Calculator %glr-parser parse.error=verbose %debug %locations %header api.prefix={calc} api.token.prefix={TOK_} %verbose ... +./calc.at:1409: mv calc.y.tmp calc.y + + | 1 2 +./calc.at:1400: $PREPARSER ./calc input +./calc.at:1398: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: stderr: stderr: -./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: +./calc.at:1398: cat stderr +1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) +./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error +1.10: syntax error +1.16: syntax error | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -90000,51 +90196,14 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -./calc.at:1397: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1403: $PREPARSER ./calc input -1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) -stderr: -./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.3: syntax error, unexpected number -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 -input: -./calc.at:1400: cat stderr - | 1 = 2 = 3 ./calc.at:1401: $PREPARSER ./calc input -./calc.at:1394: cat stderr -./calc.at:1397: cat stderr stderr: -input: -./calc.at:1402: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) -./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1400: $PREPARSER ./calc input stderr: +./calc.at:1409: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: -stderr: -stderr: -./calc.at:1398: "$PERL" -pi -e 'use strict; +./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -90054,139 +90213,54 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) - | (# + 1) = 1111 -./calc.at:1394: $PREPARSER ./calc input -stderr: -input: -syntax error: invalid character: '#' -input: -./calc.at:1402: cat stderr -input: -./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 2 -./calc.at:1403: $PREPARSER ./calc input -./calc.at:1398: cat stderr -stderr: -stderr: - | - | +1 -1.3: syntax error, unexpected number -./calc.at:1397: $PREPARSER ./calc input -input: -./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error: invalid character: '#' -1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.1-46: error: 4444 != 1 - | 1 + 2 * 3 + !- ++ -./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (- *) + (1 2) = 1 + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1398: $PREPARSER ./calc input -./calc.at:1401: cat stderr -./calc.at:1395: $PREPARSER ./calc input -stderr: -input: -stderr: stderr: -1.3: syntax error, unexpected number stderr: -1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' 1.1-46: error: 4444 != 1 -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.12: syntax error, unexpected number -1.1-17: error: 2222 != 1 ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1//2 -stderr: -./calc.at:1402: $PREPARSER ./calc input -2.1: syntax error -./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1400: cat stderr input: -./calc.at:1394: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: - | - | +1 +./calc.at:1397: cat stderr + | 1 2 ./calc.at:1401: $PREPARSER ./calc input stderr: -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -stderr: -2.1: syntax error -./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1400: cat stderr -stderr: -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.12: syntax error, unexpected number -1.1-17: error: 2222 != 1 -stderr: -./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1403: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.1-46: error: 4444 != 1 stderr: input: -./calc.at:1403: cat stderr -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +./calc.at:1409: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: - | (!!) + (1 2) = 1 + | 1//2 ./calc.at:1400: $PREPARSER ./calc input input: - | 1//2 -./calc.at:1403: $PREPARSER ./calc input -stderr: +stdout: +1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) +./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1402: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1395: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1402: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c calc.h + + | 1 + 2 * 3 + !+ ++ +./calc.at:1397: $PREPARSER ./calc input +1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) +./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1401: cat stderr -./calc.at:1394: cat stderr -./calc.at:1395: cat stderr ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -90197,138 +90271,72 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1397: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-16: error: 2222 != 1 -./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1401: $PREPARSER ./calc /dev/null -./calc.at:1403: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: - | 1 + 2 * 3 + !* ++ -./calc.at:1395: $PREPARSER ./calc input -input: -./calc.at:1398: cat stderr -./calc.at:1402: cat stderr stderr: +input: +./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1402: $PREPARSER ./calc input stderr: -1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1403: cat stderr -./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-16: error: 2222 != 1 - | (1 + # + 1) = 1111 -stderr: -./calc.at:1394: $PREPARSER ./calc input stderr: stderr: -memory exhausted -1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: stderr: +./calc.at:1398: cat stderr +1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) stdout: -stderr: +./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -syntax error: invalid character: '#' -./calc.at:1401: cat stderr - | error -./calc.at:1402: $PREPARSER ./calc input - | error -./calc.at:1403: $PREPARSER ./calc input ./types.at:139: $PREPARSER ./test + | 1 + 2 * 3 + !- ++ +./calc.at:1397: $PREPARSER ./calc input input: -./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -memory exhausted -stderr: +./calc.at:1401: cat stderr stderr: - | (* *) + (*) + (*) +./calc.at:1400: cat stderr + | (!!) + (1 2) = 1 ./calc.at:1398: $PREPARSER ./calc input -./calc.at:1397: cat stderr -input: stderr: -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -1.1: syntax error, unexpected invalid token stderr: stderr: -./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1401: $PREPARSER ./calc input -./calc.at:1400: cat stderr -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error: invalid character: '#' +./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1397: $PREPARSER ./calc /dev/null +input: +input: +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1//2 stderr: -1.1: syntax error, unexpected invalid token -1.1: syntax error, unexpected invalid token -./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 2 +./calc.at:1401: $PREPARSER ./calc input +input: +./calc.at:1402: $PREPARSER ./calc input stderr: stderr: -input: -1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.1-46: error: 4444 != 1 - | (- *) + (1 2) = 1 +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 +stderr: +1.3: syntax error, unexpected number +452. types.at:139: ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + ok + | error +1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1400: $PREPARSER ./calc input ./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1395: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.1-46: error: 4444 != 1 -stderr: -./calc.at:1403: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.1: syntax error -1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-17: error: 2222 != 1 -./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1395: cat stderr -./calc.at:1394: "$PERL" -pi -e 'use strict; +./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -90338,26 +90346,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -./calc.at:1403: cat stderr -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -451. types.at:139: ok -stderr: -stderr: -1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-17: error: 2222 != 1 -1.1: syntax error -1.1: syntax error, unexpected invalid token -input: - | 1 = 2 = 3 -./calc.at:1403: $PREPARSER ./calc input -input: -./calc.at:1394: cat stderr -./calc.at:1400: cat stderr -stderr: ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -90368,170 +90356,21 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1402: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.7: syntax error, unexpected '=' -./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: - | (#) + (#) = 2222 -./calc.at:1395: $PREPARSER ./calc input -./calc.at:1401: cat stderr -input: -stderr: -./calc.at:1398: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (* *) + (*) + (*) -./calc.at:1400: $PREPARSER ./calc input -1.7: syntax error, unexpected '=' -./calc.at:1402: cat stderr -input: -stderr: -1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - -input: - | (!!) + (1 2) = 1 -stderr: -./calc.at:1401: $PREPARSER ./calc input stderr: -1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -syntax error: invalid character: '#' -syntax error: invalid character: '#' stderr: -./calc.at:1397: cat stderr -1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-16: error: 2222 != 1 +1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) ./calc.at:1398: cat stderr -./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (1 + 1) / (1 - 1) -./calc.at:1403: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1400: cat stderr -./calc.at:1394: $PREPARSER ./calc input -./calc.at:1397: $PREPARSER ./calc input -stderr: -1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-16: error: 2222 != 1 -stderr: -./calc.at:1403: cat stderr -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 -./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -stderr: -input: - | 1 = 2 = 3 +1.3: syntax error, unexpected number stderr: - | 1 + 2 * 3 + !+ ++ -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 -./calc.at:1398: $PREPARSER ./calc input -error: null divisor +1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1397: cat stderr input: ./calc.at:1401: cat stderr -./calc.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1402: $PREPARSER ./calc input - | - | +1 -stderr: -./calc.at:1403: $PREPARSER ./calc input -./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -1.7: syntax error, unexpected '=' -error: null divisor -./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | 1 + 2 * 3 + !+ ++ -./calc.at:1397: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1400: $PREPARSER ./calc input -stderr: -stderr: -2.1: syntax error, unexpected '+' -stderr: -stderr: -./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.7: syntax error, unexpected '=' -./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -516. calc.at:1408: testing Calculator %glr-parser parse.error=verbose %debug %locations %header %name-prefix "calc" %verbose ... -./calc.at:1408: mv calc.y.tmp calc.y + | (- *) + (1 2) = 1 -stderr: -input: -2.1: syntax error, unexpected '+' -./calc.at:1395: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1394: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | 1 + 2 * 3 + !- ++ -./calc.at:1397: cat stderr ./calc.at:1398: $PREPARSER ./calc input -input: ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -90544,187 +90383,48 @@ ' expout || exit 77 stderr: input: - | 1 + 2 * 3 + !- ++ -./calc.at:1400: $PREPARSER ./calc input - | (- *) + (1 2) = 1 -./calc.at:1395: cat stderr -./calc.at:1402: cat stderr -./calc.at:1401: $PREPARSER ./calc input -./calc.at:1394: cat stderr -./calc.at:1403: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -stderr: - | (!!) + (1 2) = 1 -input: -./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1397: $PREPARSER ./calc input - | - | +1 -./calc.at:1402: $PREPARSER ./calc input -./calc.at:1403: cat stderr -input: -./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -506. calc.at:1394: ok -1.11: syntax error -1.1-16: error: 2222 != 1 -2.1: syntax error, unexpected '+' -./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -./calc.at:1408: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -stderr: -stderr: -stderr: - | (1 + #) = 1111 -./calc.at:1395: $PREPARSER ./calc input -2.1: syntax error, unexpected '+' -./calc.at:1403: $PREPARSER ./calc /dev/null -stderr: -syntax error: invalid character: '#' -1.11: syntax error -1.1-16: error: 2222 != 1 -./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.1: syntax error, unexpected end of input -1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-17: error: 2222 != 1 -./calc.at:1398: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1397: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 ./calc.at:1400: cat stderr -./calc.at:1398: cat stderr -stderr: -1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.12: syntax error, unexpected number 1.1-17: error: 2222 != 1 -stderr: -./calc.at:1402: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error: invalid character: '#' - -./calc.at:1397: cat stderr -input: -stderr: -1.1: syntax error, unexpected end of input | 1 + 2 * 3 + !* ++ -./calc.at:1398: $PREPARSER ./calc input -./calc.at:1401: cat stderr -stderr: +./calc.at:1397: $PREPARSER ./calc input input: -1.14: memory exhausted ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (- *) + (1 2) = 1 -./calc.at:1397: $PREPARSER ./calc input ./calc.at:1402: cat stderr stderr: -input: -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 -./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (* *) + (*) + (*) + | error ./calc.at:1401: $PREPARSER ./calc input -stderr: -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 -stderr: +1.14: memory exhausted input: -1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) - | 1 + 2 * 3 + !* ++ +./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 = 2 = 3 ./calc.at:1400: $PREPARSER ./calc input -./calc.at:1402: $PREPARSER ./calc /dev/null -517. calc.at:1409: testing Calculator %glr-parser parse.error=verbose %debug %locations %header api.prefix={calc} api.token.prefix={TOK_} %verbose ... +1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1395: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1409: mv calc.y.tmp calc.y - -./calc.at:1403: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.14: memory exhausted +input: +stderr: +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.12: syntax error, unexpected number +1.1-17: error: 2222 != 1 +1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1401: cat stderr -./calc.at:1403: cat stderr stderr: -./calc.at:1395: cat stderr -1.14: memory exhausted + | 1//2 +./calc.at:1402: $PREPARSER ./calc input 1.14: memory exhausted -./calc.at:1409: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -./calc.at:1408: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS stderr: -input: -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1403: $PREPARSER ./calc input -1.1: syntax error, unexpected end of file -./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: -./calc.at:1397: "$PERL" -pi -e 'use strict; +518. calc.at:1411: testing Calculator %glr-parser api.pure parse.error=verbose %debug %locations %header %name-prefix "calc" %verbose ... +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1411: mv calc.y.tmp calc.y + +./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -90734,26 +90434,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.1-46: error: 4444 != 1 -./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -stderr: - | 1 + 2 * 3 + !+ ++ -1.1: syntax error, unexpected end of file -./calc.at:1401: $PREPARSER ./calc input -stderr: -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.1-46: error: 4444 != 1 -stderr: - | (# + 1) = 1111 -./calc.at:1398: "$PERL" -pi -e 'use strict; +1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) +./calc.at:1398: cat stderr +./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -90763,27 +90446,16 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1395: $PREPARSER ./calc input stderr: +./calc.at:1401: cat stderr +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1400: cat stderr -stderr: -syntax error: invalid character: '#' -./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1411: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +input: + | (* *) + (*) + (*) +./calc.at:1398: $PREPARSER ./calc input ./calc.at:1397: cat stderr -./calc.at:1398: cat stderr -stderr: -syntax error: invalid character: '#' -./calc.at:1403: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -90794,124 +90466,38 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1403: cat stderr -input: -./calc.at:1395: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1402: cat stderr -input: - | 1 + 2 * 3 + !- ++ - | (#) + (#) = 2222 -./calc.at:1395: cat stderr -input: + | 1 = 2 = 3 ./calc.at:1401: $PREPARSER ./calc input -./calc.at:1400: $PREPARSER ./calc input -input: -stderr: -stderr: - | (!!) + (1 2) = 1 -./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1403: $PREPARSER ./calc input -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -input: + | + | +1 stderr: - | (#) + (#) = 2222 -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 +./calc.at:1400: $PREPARSER ./calc input +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1402: cat stderr +1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) input: -./calc.at:1398: $PREPARSER ./calc input - | (1 + # + 1) = 1111 -./calc.at:1395: $PREPARSER ./calc input - | (* *) + (*) + (*) -stderr: -./calc.at:1402: $PREPARSER ./calc input +./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.1-46: error: 4444 != 1 -./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (#) + (#) = 2222 +2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1397: $PREPARSER ./calc input -syntax error: invalid character: '#' -./calc.at:1409: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -syntax error: invalid character: '#' -stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' stderr: -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 -1.2: syntax error -1.10: syntax error -1.16: syntax error -stderr: -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.1-46: error: 4444 != 1 stderr: -./calc.at:1403: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1401: cat stderr -./calc.at:1402: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1395: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 stderr: -./calc.at:1395: cat stderr stdout: -./calc.at:1403: cat stderr -./calc.at:1405: "$PERL" -ne ' +1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) +input: +./calc.at:1403: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. @@ -90922,6 +90508,10 @@ || /\t/ )' calc.c calc.h +stderr: +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -90932,100 +90522,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -./calc.at:1402: cat stderr - | (- *) + (1 2) = 1 -stderr: -input: -./calc.at:1403: $PREPARSER ./calc input -1.2: syntax error -1.10: syntax error -1.16: syntax error -input: - | (1 + 1) / (1 - 1) - | 1 + 2 * 3 + !* ++ -./calc.at:1395: $PREPARSER ./calc input -stderr: -./calc.at:1401: $PREPARSER ./calc input -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.12: syntax error, unexpected number -1.1-17: error: 2222 != 1 -./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -error: null divisor -./calc.at:1400: cat stderr -stderr: -./calc.at:1395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.12: syntax error, unexpected number -1.1-17: error: 2222 != 1 -input: - | (!!) + (1 2) = 1 +./calc.at:1411: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS + | error +2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1402: $PREPARSER ./calc input -stderr: -./calc.at:1398: cat stderr -stderr: -./calc.at:1397: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 -./calc.at:1403: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.14: memory exhausted -error: null divisor -./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -input: -./calc.at:1403: cat stderr input: - | (1 + #) = 1111 stderr: -./calc.at:1395: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 -./calc.at:1400: $PREPARSER ./calc input - | (* *) + (*) + (*) -./calc.at:1403: $PREPARSER ./calc input stderr: -./calc.at:1402: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -1.14: memory exhausted +./calc.at:1401: cat stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -91039,87 +90543,18 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -./calc.at:1405: $PREPARSER ./calc input -./calc.at:1395: cat stderr -stderr: -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1402: cat stderr -stderr: -./calc.at:1401: cat stderr -1.6: syntax error: invalid character: '#' -stderr: - | (1 + #) = 1111 -507. calc.at:1395: ok -./calc.at:1398: $PREPARSER ./calc input -./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1397: cat stderr -./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: -1.6: syntax error: invalid character: '#' -stderr: -./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: - | (#) + (#) = 2222 -./calc.at:1401: $PREPARSER ./calc input -1.6: syntax error: invalid character: '#' -stderr: -input: -stderr: - | 1 2 +./calc.at:1403: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' -./calc.at:1405: $PREPARSER ./calc input -./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) -./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -input: -stderr: - -1.6: syntax error: invalid character: '#' -input: - | 1 + 2 * 3 + !+ ++ -./calc.at:1400: cat stderr -./calc.at:1397: $PREPARSER ./calc input - | (- *) + (1 2) = 1 -./calc.at:1402: $PREPARSER ./calc input stderr: -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.12: syntax error, unexpected number -1.1-17: error: 2222 != 1 +./calc.at:1398: cat stderr +1.1: syntax error, unexpected invalid token ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) -stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -stderr: -./calc.at:1403: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1400: cat stderr +./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1403: cat stderr -./calc.at:1405: cat stderr - | (# + 1) = 1111 -./calc.at:1400: $PREPARSER ./calc input stderr: -./calc.at:1398: "$PERL" -pi -e 'use strict; +./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -91130,85 +90565,28 @@ }eg ' expout || exit 77 stderr: -1.2: syntax error: invalid character: '#' -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.12: syntax error, unexpected number -1.1-17: error: 2222 != 1 -./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -518. calc.at:1411: testing Calculator %glr-parser api.pure parse.error=verbose %debug %locations %header %name-prefix "calc" %verbose ... -input: -./calc.at:1411: mv calc.y.tmp calc.y - - | 1//2 -./calc.at:1405: $PREPARSER ./calc input -./calc.at:1401: cat stderr -stderr: -./calc.at:1411: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -input: + | + | +1 +./calc.at:1401: $PREPARSER ./calc input +1.1: syntax error, unexpected invalid token input: -1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) -./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1400: $PREPARSER ./calc /dev/null | 1 + 2 * 3 + !+ ++ -input: -stderr: -./calc.at:1403: $PREPARSER ./calc input -./calc.at:1398: cat stderr - | (1 + #) = 1111 -1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) -./calc.at:1401: $PREPARSER ./calc input -stderr: -stderr: -./calc.at:1402: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.2: syntax error: invalid character: '#' - | 1 + 2 * 3 + !- ++ -stderr: -./calc.at:1397: $PREPARSER ./calc input -./calc.at:1405: cat stderr -./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1400: cat stderr -1.6: syntax error: invalid character: '#' -./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -input: -input: - | (# + 1) = 1111 - | error -input: - | (1 + # + 1) = 1111 -./calc.at:1405: $PREPARSER ./calc input -./calc.at:1400: $PREPARSER ./calc input -./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1398: $PREPARSER ./calc input +input: stderr: stderr: -stderr: -stderr: -1.6: syntax error: invalid character: '#' -1.2: syntax error: invalid character: '#' ./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.6: syntax error: invalid character: '#' -./calc.at:1402: cat stderr -input: - | 1 + 2 * 3 + !- ++ + | 1 2 ./calc.at:1403: $PREPARSER ./calc input stderr: -./calc.at:1401: cat stderr -stderr: -./calc.at:1411: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS -./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1397: "$PERL" -pi -e 'use strict; +./calc.at:1397: cat stderr +./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -91218,139 +90596,52 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (# + 1) = 1111 stderr: -1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1401: $PREPARSER ./calc input -stderr: -1.6: syntax error: invalid character: '#' stderr: -./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: -1.2: syntax error: invalid character: '#' +1.3: syntax error, unexpected number +./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1402: cat stderr +2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: -1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) input: - | (* *) + (*) + (*) -./calc.at:1402: $PREPARSER ./calc input -./calc.at:1397: cat stderr -stderr: -1.2: syntax error: invalid character: '#' -./calc.at:1398: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1403: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1398: cat stderr -./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' input: - | (1 + # + 1) = 1111 + | 1 + 2 * 3 + !- ++ + | (1 + #) = 1111 ./calc.at:1398: $PREPARSER ./calc input -stderr: -1.2: syntax error: invalid character: '#' -input: -./calc.at:1405: cat stderr - | 1 + 2 * 3 + !* ++ -./calc.at:1403: cat stderr ./calc.at:1397: $PREPARSER ./calc input -./calc.at:1400: cat stderr +stdout: stderr: -1.14: memory exhausted -./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.6: syntax error: invalid character: '#' -input: +./calc.at:1405: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c calc.h + +1.3: syntax error, unexpected number stderr: -./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.14: memory exhausted input: +./calc.at:1400: cat stderr stderr: - | 1 = 2 = 3 -./calc.at:1405: $PREPARSER ./calc input 1.6: syntax error: invalid character: '#' - | 1 + 2 * 3 + !* ++ -./calc.at:1403: $PREPARSER ./calc input -input: -stderr: -stderr: -1.14: memory exhausted -./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1398: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1402: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1401: cat stderr -stderr: - | (1 + 1) / (1 - 1) -./calc.at:1397: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1400: $PREPARSER ./calc input -1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) -./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.14: memory exhausted + | 1 = 2 = 3 +./calc.at:1402: $PREPARSER ./calc input stderr: stderr: -./calc.at:1398: cat stderr -1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) -1.11-17: error: null divisor -./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1401: $PREPARSER ./calc /dev/null input: +1.7: syntax error, unexpected '=' +./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - | (1 + # + 1) = 1111 -./calc.at:1402: cat stderr -./calc.at:1401: $PREPARSER ./calc input -1.11-17: error: null divisor -stderr: -./calc.at:1405: cat stderr -./calc.at:1397: cat stderr -input: ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -91361,42 +90652,34 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.6: syntax error: invalid character: '#' - | 1 + 2 * 3 + !+ ++ input: -./calc.at:1402: $PREPARSER ./calc input - | (#) + (#) = 2222 -./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1397: $PREPARSER ./calc input -stderr: -input: - | (1 + 1) / (1 - 1) -./calc.at:1398: $PREPARSER ./calc input -./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.11-17: error: null divisor -input: -./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 | - | +1 + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +1.6: syntax error: invalid character: '#' +1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1405: $PREPARSER ./calc input -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: +./calc.at:1403: cat stderr +./calc.at:1400: $PREPARSER ./calc input stderr: ./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.11-17: error: null divisor -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' stderr: -stderr: -2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) -1.6: syntax error: invalid character: '#' -./calc.at:1397: "$PERL" -pi -e 'use strict; +1.7: syntax error, unexpected '=' +./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -91406,18 +90689,19 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1400: cat stderr -./calc.at:1403: cat stderr -stderr: -./calc.at:1405: cat stderr -./calc.at:1405: $PREPARSER ./calc /dev/null stderr: 1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.1-46: error: 4444 != 1 +./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -./calc.at:1401: cat stderr -510. calc.at:1400: ok -./calc.at:1398: "$PERL" -pi -e 'use strict; + | 1//2 +./calc.at:1403: $PREPARSER ./calc input +stderr: +./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -91427,42 +90711,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -./calc.at:1397: cat stderr -stderr: - | 1 + 2 * 3 + !- ++ -./calc.at:1402: $PREPARSER ./calc input - | (#) + (#) = 2222 -./calc.at:1403: $PREPARSER ./calc input -1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: -stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: ./calc.at:1398: cat stderr - | (1 + 1) / (1 - 1) -./calc.at:1401: $PREPARSER ./calc input -./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | (1 + #) = 1111 -./calc.at:1397: $PREPARSER ./calc input -stderr: -stderr: -509. calc.at:1398: ok - -stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1405: cat stderr -stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -1.11-17: error: null divisor -./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.11-17: error: null divisor +1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.1-46: error: 4444 != 1 +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -91473,10 +90730,27 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1401: cat stderr + | 1 2 +./calc.at:1405: $PREPARSER ./calc input +stderr: +./calc.at:1400: cat stderr +stderr: +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1402: cat stderr +1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) +input: +./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1397: cat stderr + | 1 + 2 * 3 + !* ++ stderr: -1.6: syntax error: invalid character: '#' +./calc.at:1398: $PREPARSER ./calc input +1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) input: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1403: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -91487,70 +90761,61 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1401: cat stderr -./calc.at:1405: $PREPARSER ./calc input -519. calc.at:1413: testing Calculator %glr-parser api.pure parse.error=verbose %debug %locations %header %name-prefix "calc" %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... -./calc.at:1413: mv calc.y.tmp calc.y - -./calc.at:1403: cat stderr +stderr: +./calc.at:1401: $PREPARSER ./calc input + | + | +1 +./calc.at:1402: $PREPARSER ./calc input stderr: input: -./calc.at:1397: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1413: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y - | 1 + 2 * 3 + !* ++ +1.14: memory exhausted 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 -./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1402: $PREPARSER ./calc input -511. calc.at:1401: - ok -./calc.at:1397: cat stderr -input: +./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1403: cat stderr stderr: -1.14: memory exhausted +input: + | (!!) + (1 2) = 1 +./calc.at:1400: $PREPARSER ./calc input +2.1: syntax error, unexpected '+' + | (# + 1) = 1111 ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (1 + #) = 1111 -./calc.at:1403: $PREPARSER ./calc input +./calc.at:1397: $PREPARSER ./calc input stderr: +./calc.at:1405: cat stderr stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-16: error: 2222 != 1 +stderr: +stderr: +./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.2: syntax error: invalid character: '#' +./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +1.14: memory exhausted 1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) 1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.1-46: error: 4444 != 1 -input: - | (# + 1) = 1111 - -./calc.at:1397: $PREPARSER ./calc input -stderr: -520. calc.at:1414: testing Calculator %glr-parser api.pure parse.error=verbose %debug %locations %header api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... stderr: +2.1: syntax error, unexpected '+' stderr: -1.14: memory exhausted + | error stderr: +./calc.at:1403: $PREPARSER ./calc input stdout: +1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-16: error: 2222 != 1 +input: 1.2: syntax error: invalid character: '#' -1.6: syntax error: invalid character: '#' -./calc.at:1405: cat stderr -./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1414: mv calc.y.tmp calc.y - -./calc.at:1402: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -91560,6 +90825,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +1.1: syntax error, unexpected invalid token +./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" @@ -91571,10 +90838,26 @@ || /\t/ )' calc.c + | 1//2 +./calc.at:1405: $PREPARSER ./calc input +./calc.at:1401: cat stderr stderr: -1.2: syntax error: invalid character: '#' -./calc.at:1402: cat stderr +./calc.at:1398: cat stderr input: +./calc.at:1402: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) +./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1400: cat stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -91588,6 +90871,9 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 +1.1: syntax error, unexpected invalid token +./calc.at:1402: cat stderr +./calc.at:1407: $PREPARSER ./calc input ./calc.at:1397: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -91598,27 +90884,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1407: $PREPARSER ./calc input -input: +stderr: input: -./calc.at:1403: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -521. calc.at:1416: testing Calculator %glr-parser %no-lines api.pure parse.error=verbose %debug %locations %header api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... -./calc.at:1416: mv calc.y.tmp calc.y - - | (!!) + (1 2) = 1 stderr: -./calc.at:1405: $PREPARSER ./calc input - | (#) + (#) = 2222 -./calc.at:1402: $PREPARSER ./calc input +input: Starting parse Entering state 0 Reading a token @@ -92456,23 +91725,40 @@ Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1397: cat stderr +./calc.at:1402: $PREPARSER ./calc /dev/null +1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) + | (!!) + (1 2) = 1 +./calc.at:1401: $PREPARSER ./calc input stderr: -./calc.at:1403: cat stderr + | (#) + (#) = 2222 +./calc.at:1398: $PREPARSER ./calc input +./calc.at:1403: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: 1.2: syntax error: invalid character: '#' 1.8: syntax error: invalid character: '#' -stderr: +1.1: syntax error, unexpected end of file +./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: ./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1414: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y -./calc.at:1413: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS -./calc.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +stderr: +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' + | (- *) + (1 2) = 1 +stderr: +./calc.at:1400: $PREPARSER ./calc input 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 -./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | (1 + # + 1) = 1111 -./calc.at:1397: $PREPARSER ./calc input +./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1403: cat stderr stderr: Starting parse Entering state 0 @@ -93310,22 +92596,39 @@ Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) +./calc.at:1405: cat stderr +./calc.at:1397: cat stderr +stderr: stderr: +stderr: +1.1: syntax error, unexpected end of file +input: 1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-16: error: 2222 != 1 -stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' +1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-17: error: 2222 != 1 +./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -1.6: syntax error: invalid character: '#' -./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -input: -1.6: syntax error: invalid character: '#' - | (# + 1) = 1111 + | 1 = 2 = 3 ./calc.at:1403: $PREPARSER ./calc input | 1 2 +stderr: ./calc.at:1407: $PREPARSER ./calc input +input: +stdout: +./calc.at:1408: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c calc.h + stderr: Starting parse Entering state 0 @@ -93343,22 +92646,9 @@ Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.1: 2) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1405: cat stderr -./calc.at:1402: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1416: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS -stderr: -1.2: syntax error: invalid character: '#' -./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1397: "$PERL" -pi -e 'use strict; +./calc.at:1401: cat stderr + | error +./calc.at:1398: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -93368,84 +92658,38 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token "number" (1.1: 2) -syntax error -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token "number" (1.1: 2) -./calc.at:1402: cat stderr -stderr: -1.2: syntax error: invalid character: '#' -./calc.at:1397: cat stderr -./calc.at:1414: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS -input: - | (- *) + (1 2) = 1 -./calc.at:1405: $PREPARSER ./calc input -input: -stderr: - | (1 + #) = 1111 -./calc.at:1402: $PREPARSER ./calc input 1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) 1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) 1.1-17: error: 2222 != 1 -./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -stderr: -./calc.at:1407: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (1 + 1) / (1 - 1) -./calc.at:1397: $PREPARSER ./calc input -1.6: syntax error: invalid character: '#' -./calc.at:1403: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./calc.at:1405: $PREPARSER ./calc input stderr: -1.11-17: error: null divisor -./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-17: error: 2222 != 1 -1.6: syntax error: invalid character: '#' -./calc.at:1403: cat stderr -./calc.at:1407: cat stderr +1.7: syntax error, unexpected '=' +./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1398: cat stderr stderr: -1.11-17: error: null divisor input: | (1 + # + 1) = 1111 -./calc.at:1403: $PREPARSER ./calc input -./calc.at:1405: cat stderr -input: +1.7: syntax error, unexpected '=' +./calc.at:1397: $PREPARSER ./calc input stderr: -1.6: syntax error: invalid character: '#' + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1408: $PREPARSER ./calc input +1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -93456,43 +92700,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1//2 -./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1407: $PREPARSER ./calc input stderr: -./calc.at:1397: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '/' (1.1: ) -Shifting token '/' (1.1: ) -Entering state 23 -Reading a token -Next token is token '/' (1.1: ) -syntax error -Error: popping token '/' (1.1: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.1: ) -./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1402: cat stderr Starting parse Entering state 0 Reading a token @@ -93504,209 +92713,10 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '/' (1.1: ) -Shifting token '/' (1.1: ) -Entering state 23 -Reading a token -Next token is token '/' (1.1: ) +Next token is token "number" (1.1: 2) syntax error -Error: popping token '/' (1.1: ) Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.1: ) -input: - | (# + 1) = 1111 -input: -./calc.at:1402: $PREPARSER ./calc input - | (* *) + (*) + (*) -./calc.at:1405: $PREPARSER ./calc input -stderr: -1.2: syntax error: invalid character: '#' -stderr: -stderr: -./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.6: syntax error: invalid character: '#' -stderr: -stderr: -1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -./calc.at:1397: cat stderr -./calc.at:1403: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.2: syntax error: invalid character: '#' -./calc.at:1403: cat stderr -./calc.at:1407: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1405: cat stderr -./calc.at:1407: cat stderr -./calc.at:1402: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -508. calc.at:1397: ok -input: - | (1 + 1) / (1 - 1) -./calc.at:1403: $PREPARSER ./calc input -stderr: -input: -./calc.at:1402: cat stderr -1.11-17: error: null divisor -./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | 1 + 2 * 3 + !+ ++ - | error -input: -./calc.at:1407: $PREPARSER ./calc input -./calc.at:1405: $PREPARSER ./calc input - | (1 + # + 1) = 1111 -./calc.at:1402: $PREPARSER ./calc input - -stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -1.6: syntax error: invalid character: '#' -stderr: -./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1402: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -1.11-17: error: null divisor -Starting parse -Entering state 0 -Reading a token -Next token is token "invalid token" (1.1: ) -syntax error -Cleanup: discarding lookahead token "invalid token" (1.1: ) -./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1402: cat stderr -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "invalid token" (1.1: ) -syntax error -Cleanup: discarding lookahead token "invalid token" (1.1: ) -input: -./calc.at:1403: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1403: cat stderr - | 1 + 2 * 3 + !- ++ -input: - | (1 + 1) / (1 - 1) -./calc.at:1402: $PREPARSER ./calc input -./calc.at:1405: $PREPARSER ./calc input -stderr: -513. calc.at:1403: ok -./calc.at:1407: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.11-17: error: null divisor -./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.11-17: error: null divisor -stderr: -stdout: -522. calc.at:1426: testing Calculator lalr1.cc %header ... -./calc.at:1426: mv calc.y.tmp calc.y - -./calc.at:1408: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c calc.h - -stderr: - -./calc.at:1426: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -./calc.at:1402: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1407: cat stderr -./calc.at:1402: cat stderr -input: -512. calc.at:1402: ok - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1408: $PREPARSER ./calc input -./calc.at:1405: cat stderr -stderr: +Cleanup: discarding lookahead token "number" (1.1: 2) input: Starting parse Entering state 0 @@ -94544,47 +93554,34 @@ Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) - | 1 = 2 = 3 -./calc.at:1407: $PREPARSER ./calc input ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1426: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 -Reading a token -Next token is token "number" (1.1: 2) -Shifting token "number" (1.1: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 2) --> $$ = nterm exp (1.1: 2) -Entering state 28 -Reading a token -Next token is token '=' (1.1: ) -syntax error -Error: popping nterm exp (1.1: 2) -Error: popping token '=' (1.1: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '=' (1.1: ) -./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -523. calc.at:1431: testing Calculator C++ ... +1.6: syntax error: invalid character: '#' + | (- *) + (1 2) = 1 +./calc.at:1401: $PREPARSER ./calc input +./calc.at:1402: cat stderr +./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: +./calc.at:1400: cat stderr stderr: -./calc.at:1431: mv calc.y.tmp calc.y - stderr: +stderr: +stderr: +1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) + | (1 + #) = 1111 +./calc.at:1398: $PREPARSER ./calc input +1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-17: error: 2222 != 1 +./calc.at:1403: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -95421,48 +94418,327 @@ Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) - - | 1 + 2 * 3 + !* ++ +./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +input: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1402: $PREPARSER ./calc input +stderr: +1.6: syntax error: invalid character: '#' +input: +stderr: +stderr: + | 1 2 +./calc.at:1408: $PREPARSER ./calc input +stderr: +1.6: syntax error: invalid character: '#' +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.1-46: error: 4444 != 1 +./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token "number" (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token "number" (1.3: 2) +./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-17: error: 2222 != 1 +./calc.at:1403: cat stderr + | (* *) + (*) + (*) +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token "number" (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token "number" (1.3: 2) +./calc.at:1405: cat stderr +./calc.at:1400: $PREPARSER ./calc input +stderr: +stderr: +1.6: syntax error: invalid character: '#' +./calc.at:1407: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1408: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stdout: +1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1408: cat stderr +./calc.at:1397: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./types.at:139: $PREPARSER ./test +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.1-46: error: 4444 != 1 +stderr: +input: +./calc.at:1401: cat stderr +./calc.at:1398: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: + | 1//2 +./calc.at:1408: $PREPARSER ./calc input +./calc.at:1407: cat stderr +input: +input: +1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1397: cat stderr +stderr: + | 1 = 2 = 3 +./calc.at:1398: cat stderr ./calc.at:1405: $PREPARSER ./calc input + | + | +1 Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 -Reducing stack 0 by rule 5 (line 81): +Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 Reading a token -Next token is token "number" (1.1: 2) -Shifting token "number" (1.1: 2) +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '/' (1.3: ) +./calc.at:1403: $PREPARSER ./calc input +./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +./calc.at:1402: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) +2.1: syntax error, unexpected '+' +./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +451. types.at:139: ok +stderr: +./calc.at:1400: cat stderr + | (* *) + (*) + (*) +./calc.at:1401: $PREPARSER ./calc input +./calc.at:1402: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '/' (1.3: ) + | 1//2 +./calc.at:1407: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 2) --> $$ = nterm exp (1.1: 2) -Entering state 28 + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 Reading a token -Next token is token '=' (1.1: ) +Next token is token '/' (1.1: ) +Shifting token '/' (1.1: ) +Entering state 23 +Reading a token +Next token is token '/' (1.1: ) syntax error -Error: popping nterm exp (1.1: 2) -Error: popping token '=' (1.1: ) +Error: popping token '/' (1.1: ) Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '=' (1.1: ) -./calc.at:1431: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +Cleanup: discarding lookahead token '/' (1.1: ) +./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: + | (1 + 1) / (1 - 1) +./calc.at:1397: $PREPARSER ./calc input +stderr: +2.1: syntax error, unexpected '+' +stderr: input: +1.11-17: error: null divisor stderr: - | 1 2 +./calc.at:1397: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) +./calc.at:1405: cat stderr +./calc.at:1408: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -1.14: memory exhausted -./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: stderr: -./calc.at:1408: $PREPARSER ./calc input + | (# + 1) = 1111 +1.11-17: error: null divisor +input: +./calc.at:1398: $PREPARSER ./calc input +./calc.at:1403: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '/' (1.1: ) +Shifting token '/' (1.1: ) +Entering state 23 +Reading a token +Next token is token '/' (1.1: ) +syntax error +Error: popping token '/' (1.1: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '/' (1.1: ) + | (!!) + (1 2) = 1 +./calc.at:1403: cat stderr +1.2: syntax error: invalid character: '#' + | 1 + 2 * 3 + !+ ++ +./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1402: $PREPARSER ./calc input +./calc.at:1403: $PREPARSER ./calc /dev/null +./calc.at:1400: $PREPARSER ./calc input +stderr: +stderr: +./calc.at:1408: cat stderr +1.1: syntax error, unexpected end of input +./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +./calc.at:1397: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +input: +stdout: +./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1409: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" @@ -95474,25 +94750,51 @@ || /\t/ )' calc.c calc.h -1.14: memory exhausted +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 +./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) + stderr: +1.1: syntax error, unexpected end of input + | + | +1 input: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token "number" (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token "number" (1.3: 2) -./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.2: syntax error: invalid character: '#' +./calc.at:1405: $PREPARSER ./calc input +stderr: +stderr: +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 + | error +stderr: +./calc.at:1408: $PREPARSER ./calc input +./calc.at:1398: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +input: +./calc.at:1403: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1397: cat stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -95503,10 +94805,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -524. calc.at:1432: testing Calculator C++ %locations ... -./calc.at:1432: mv calc.y.tmp calc.y - -./calc.at:1432: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +input: +2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 + !- ++ +./calc.at:1401: cat stderr +./calc.at:1400: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -95521,24 +94825,32 @@ | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1409: $PREPARSER ./calc input -./calc.at:1405: cat stderr -stderr: Starting parse Entering state 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token "number" (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token "number" (1.3: 2) +Next token is token "invalid token" (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" (1.1: ) +./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1402: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1398: cat stderr +./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +519. calc.at:1413: testing Calculator %glr-parser api.pure parse.error=verbose %debug %locations %header %name-prefix "calc" %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... +./calc.at:1413: mv calc.y.tmp calc.y + +./calc.at:1403: cat stderr Starting parse Entering state 0 Reading a token @@ -95838,7 +95150,7 @@ Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 125): - $1 = token '(' (5.1: ) + $1 = token '508. calc.at:1397: (' (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) @@ -96375,13 +95687,21 @@ Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) + ok +./calc.at:1407: cat stderr +2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./calc.at:1402: cat stderr +stderr: input: -./calc.at:1431: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -./calc.at:1407: cat stderr - | (#) + (#) = 2222 -./calc.at:1405: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token "invalid token" (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" (1.1: ) +stderr: Starting parse Entering state 0 Reading a token @@ -97218,37 +96538,17 @@ Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) + | 1 + 2 * 3 + !+ ++ input: +./calc.at:1401: $PREPARSER ./calc input input: + | (1 + # + 1) = 1111 +./calc.at:1398: $PREPARSER ./calc input | 1 2 - | - | +1 -./calc.at:1407: $PREPARSER ./calc input -./calc.at:1409: $PREPARSER ./calc input stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 76): - $1 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Reading a token -Next token is token '+' (1.1: ) -syntax error -Error: popping nterm input (1.1: ) -Cleanup: discarding lookahead token '+' (1.1: ) -./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1409: $PREPARSER ./calc input +./calc.at:1413: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -97259,10 +96559,13 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: +./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +input: +input: +1.6: syntax error: invalid character: '#' +./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1405: cat stderr Starting parse Entering state 0 Reading a token @@ -97278,47 +96581,97 @@ 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) -stdout: +input: ./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (- *) + (1 2) = 1 +./calc.at:1402: $PREPARSER ./calc input ./calc.at:1408: cat stderr stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1411: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c calc.h + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 + | error +./calc.at:1407: $PREPARSER ./calc input +./calc.at:1403: $PREPARSER ./calc input +stderr: +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.12: syntax error, unexpected number +1.1-17: error: 2222 != 1 +stderr: +stderr: +./calc.at:1400: cat stderr +./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.1-46: error: 4444 != 1 +Starting parse +Entering state 0 +Reading a token +Next token is token "invalid token" (1.1: ) +syntax error +Cleanup: discarding lookahead token "invalid token" (1.1: ) +./calc.at:1405: $PREPARSER ./calc /dev/null +./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.6: syntax error: invalid character: '#' +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token "number" (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token "number" (1.3: 2) input: - | 1//2 +stderr: +stderr: +input: +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.12: syntax error, unexpected number +1.1-17: error: 2222 != 1 + | 1 = 2 = 3 +stderr: +stderr: +1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) + | 1 + 2 * 3 + !- ++ +./calc.at:1401: $PREPARSER ./calc input ./calc.at:1408: $PREPARSER ./calc input +./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.1-46: error: 4444 != 1 +stderr: Starting parse Entering state 0 Reading a token -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 76): - $1 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Reading a token -Next token is token '+' (1.1: ) +Next token is token "invalid token" (1.1: ) syntax error -Error: popping nterm input (1.1: ) -Cleanup: discarding lookahead token '+' (1.1: ) -stderr: +Cleanup: discarding lookahead token "invalid token" (1.1: ) +input: stderr: +./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1398: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -97330,17 +96683,73 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 19 Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 28 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.3: ) +Cleanup: discarding lookahead token '=' (1.7: ) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1405: cat stderr + | 1 + 2 * 3 + !* ++ +./calc.at:1413: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS +./calc.at:1400: $PREPARSER ./calc input +./calc.at:1409: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1403: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1402: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1398: cat stderr +stderr: +stderr: +./calc.at:1407: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: Starting parse Entering state 0 Reading a token @@ -97352,28 +96761,42 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token "number" (1.3: 2) -1.3: syntax error, unexpected number +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 19 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 28 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token "number" (1.3: 2) -./calc.at:1432: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +Cleanup: discarding lookahead token '=' (1.7: ) +1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1403: cat stderr +1.14: memory exhausted +520. calc.at:1414: testing Calculator %glr-parser api.pure parse.error=verbose %debug %locations %header api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... +./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1402: cat stderr +./calc.at:1409: cat stderr input: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1411: $PREPARSER ./calc input +./calc.at:1414: mv calc.y.tmp calc.y + +./calc.at:1401: cat stderr + | (1 + 1) / (1 - 1) +./calc.at:1398: $PREPARSER ./calc input stderr: -./calc.at:1409: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1405: cat stderr +input: +./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -97383,7 +96806,36 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +1.14: memory exhausted +./calc.at:1407: cat stderr +1.11-17: error: null divisor +input: +input: +./calc.at:1398: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (!!) + (1 2) = 1 +./calc.at:1403: $PREPARSER ./calc input + | (* *) + (*) + (*) + | 1//2 +./calc.at:1402: $PREPARSER ./calc input +./calc.at:1414: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +input: +./calc.at:1409: $PREPARSER ./calc input +stderr: stderr: +stderr: + | 1 + 2 * 3 + !* ++ +./calc.at:1401: $PREPARSER ./calc input +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1408: cat stderr +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 +1.11-17: error: null divisor +stderr: +./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1400: cat stderr input: Starting parse Entering state 0 @@ -97405,7 +96857,20 @@ Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) - | (1 + #) = 1111 +stderr: +./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +stderr: +1.14: memory exhausted +./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +stderr: +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 +stderr: +./calc.at:1405: $PREPARSER ./calc input + | 1 = 2 = 3 +input: Starting parse Entering state 0 Reading a token @@ -97417,69 +96882,86 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '/' (1.3: ) +./calc.at:1407: $PREPARSER ./calc input +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1398: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: + | + | +1 +./calc.at:1408: $PREPARSER ./calc input +input: +stderr: +1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.1-46: error: 4444 != 1 +stderr: +./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (#) + (#) = 2222 +stderr: +./calc.at:1400: $PREPARSER ./calc input +1.14: memory exhausted +Starting parse +Entering state 0 Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) +Reading a token +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) Entering state 19 Reading a token -Next token is token "number" (1.13: 7) -Shifting token "number" (1.13: 7) +Next token is token "number" (1.1: 2) +Shifting token "number" (1.1: 2) Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.13: 7) --> $$ = nterm exp (1.13: 7) +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 2) +-> $$ = nterm exp (1.1: 2) Entering state 28 Reading a token -Next token is token '\n' (1.14-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-9: 7) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13: 7) --> $$ = nterm exp (1.1-13: 7) -Entering state 8 -Next token is token '\n' (1.14-2.0: ) -Shifting token '\n' (1.14-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-13: 7) - $2 = token '\n' (1.14-2.0: ) +Next token is token '=' (1.1: ) +syntax error +Error: popping nterm exp (1.1: 2) +Error: popping token '=' (1.1: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '=' (1.1: ) +./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1398: cat stderr +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 83): + $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): @@ -97487,195 +96969,1488 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token -Next token is token "number" (2.1: 1) -Shifting token "number" (2.1: 1) +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Cleanup: discarding lookahead token '+' (2.1: ) +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1409: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1402: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1403: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +509. calc.at:1398: ok +stderr: +./calc.at:1401: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (2.1: 1) --> $$ = nterm exp (2.1: 1) +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '+' (2.3: ) -Shifting token '+' (2.3: ) -Entering state 21 +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) +Entering state 19 Reading a token -Next token is token "number" (2.5: 2) -Shifting token "number" (2.5: 2) +Next token is token "number" (1.1: 2) +Shifting token "number" (1.1: 2) Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (2.5: 2) --> $$ = nterm exp (2.5: 2) -Entering state 30 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 2) +-> $$ = nterm exp (1.1: 2) +Entering state 28 Reading a token -Next token is token '*' (2.7: ) -Shifting token '*' (2.7: ) -Entering state 22 +Next token is token '=' (1.1: ) +syntax error +Error: popping nterm exp (1.1: 2) +Error: popping token '=' (1.1: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '=' (1.1: ) +stderr: +./calc.at:1414: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS +1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.1-46: error: 4444 != 1 +Starting parse +Entering state 0 Reading a token -Next token is token '-' (2.9: ) -Shifting token '-' (2.9: ) -Entering state 2 +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 83): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 Reading a token -Next token is token "number" (2.10: 3) -Shifting token "number" (2.10: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (2.10: 3) --> $$ = nterm exp (2.10: 3) -Entering state 10 +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Cleanup: discarding lookahead token '+' (2.1: ) +stderr: +./calc.at:1402: cat stderr +./calc.at:1403: cat stderr +./calc.at:1409: cat stderr +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +input: +./calc.at:1408: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1405: cat stderr + | (#) + (#) = 2222 +input: +./calc.at:1401: $PREPARSER ./calc input +input: +input: + + | 1 + 2 * 3 + !+ ++ + | (- *) + (1 2) = 1 + | error +./calc.at:1409: $PREPARSER ./calc input +./calc.at:1402: $PREPARSER ./calc input +./calc.at:1403: $PREPARSER ./calc input +stderr: +./calc.at:1407: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1408: cat stderr +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1400: cat stderr +stderr: +stderr: +stderr: +input: +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.12: syntax error, unexpected number +1.1-17: error: 2222 != 1 +Starting parse +Entering state 0 Reading a token -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (2.9: ) - $2 = nterm exp (2.10: 3) --> $$ = nterm exp (2.9-10: -3) -Entering state 31 -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 9 (line 101): - $1 = nterm exp (2.5: 2) - $2 = token '*' (2.7: ) - $3 = nterm exp (2.9-10: -3) --> $$ = nterm exp (2.5-10: -6) -Entering state 30 -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (2.1: 1) - $2 = token '+' (2.3: ) - $3 = nterm exp (2.5-10: -6) --> $$ = nterm exp (2.1-10: -5) -Entering state 8 -Next token is token '=' (2.12: ) -Shifting token '=' (2.12: ) -Entering state 19 +Next token is token "invalid token" (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" (1.1: ) + | (!!) + (1 2) = 1 +./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1405: $PREPARSER ./calc input +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1408: $PREPARSER ./calc /dev/null +stderr: +./calc.at:1407: cat stderr +1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-16: error: 2222 != 1 +input: +stderr: +./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +Starting parse +Entering state 0 Reading a token -Next token is token '-' (2.14: ) -Shifting token '-' (2.14: ) -Entering state 2 +Next token is token "invalid token" (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" (1.1: ) +stderr: +Starting parse +Entering state 0 Reading a token -Next token is token "number" (2.15: 5) -Shifting token "number" (2.15: 5) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (2.15: 5) --> $$ = nterm exp (2.15: 5) -Entering state 10 +Now at end of input. +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token "end of input" (1.1: ) +./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + #) = 1111 +./calc.at:1400: $PREPARSER ./calc input +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.12: syntax error, unexpected number +1.1-17: error: 2222 != 1 +stderr: +stderr: +input: +./calc.at:1401: cat stderr +1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-16: error: 2222 != 1 +input: +521. calc.at:1416: testing Calculator %glr-parser %no-lines api.pure parse.error=verbose %debug %locations %header api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... +./calc.at:1416: mv calc.y.tmp calc.y + +stderr: +1.6: syntax error: invalid character: '#' +./calc.at:1409: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | + | +1 +./calc.at:1407: $PREPARSER ./calc input + | 1 + 2 * 3 + !- ++ +./calc.at:1402: $PREPARSER ./calc input +./calc.at:1416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.c calc.y +input: +Starting parse +Entering state 0 Reading a token -Next token is token '\n' (2.16-3.0: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (2.14: ) - $2 = nterm exp (2.15: 5) --> $$ = nterm exp (2.14-15: -5) -Entering state 28 -Next token is token '\n' (2.16-3.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (2.1-10: -5) - $2 = token '=' (2.12: ) - $3 = nterm exp (2.14-15: -5) --> $$ = nterm exp (2.1-15: -5) -Entering state 8 -Next token is token '\n' (2.16-3.0: ) -Shifting token '\n' (2.16-3.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (2.1-15: -5) - $2 = token '\n' (2.16-3.0: ) --> $$ = nterm line (2.1-3.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-2.0: ) - $2 = nterm line (2.1-3.0: ) --> $$ = nterm input (1.1-3.0: ) -Entering state 6 +Now at end of input. +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token "end of input" (1.1: ) +stderr: + | (1 + #) = 1111 +./calc.at:1401: $PREPARSER ./calc input +./calc.at:1405: cat stderr +./calc.at:1409: cat stderr +stderr: +stderr: +./calc.at:1403: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +Starting parse +Entering state 0 Reading a token -Next token is token '\n' (3.1-4.0: ) -Shifting token '\n' (3.1-4.0: ) +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) Entering state 3 -Reducing stack 0 by rule 3 (line 83): - $1 = token '\n' (3.1-4.0: ) --> $$ = nterm line (3.1-4.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-3.0: ) - $2 = nterm line (3.1-4.0: ) --> $$ = nterm input (1.1-4.0: ) +Reducing stack 0 by rule 3 (line 76): + $1 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) Entering state 6 Reading a token -Next token is token '-' (4.1: ) -Shifting token '-' (4.1: ) -Entering state 2 +Next token is token '+' (1.1: ) +syntax error +Error: popping nterm input (1.1: ) +Cleanup: discarding lookahead token '+' (1.1: ) +1.6: syntax error: invalid character: '#' +./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.6: syntax error: invalid character: '#' +input: +./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1408: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1403: cat stderr + | 1 = 2 = 3 +./calc.at:1409: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 Reading a token -Next token is token "number" (4.2: 1) -Shifting token "number" (4.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (4.2: 1) --> $$ = nterm exp (4.2: 1) -Entering state 10 +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 76): + $1 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) +Entering state 6 Reading a token -Next token is token '^' (4.3: ) -Shifting token '^' (4.3: ) -Entering state 24 +Next token is token '+' (1.1: ) +syntax error +Error: popping nterm input (1.1: ) +Cleanup: discarding lookahead token '+' (1.1: ) +./calc.at:1408: cat stderr +input: +stderr: +stderr: + | (- *) + (1 2) = 1 +./calc.at:1405: $PREPARSER ./calc input +./calc.at:1400: cat stderr +Starting parse +Entering state 0 Reading a token -Next token is token "number" (4.4: 2) -Shifting token "number" (4.4: 2) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (4.4: 2) --> $$ = nterm exp (4.4: 2) -Entering state 33 -Reading a token -Next token is token '=' (4.6: ) -Reducing stack 0 by rule 12 (line 112): - $1 = nterm exp (4.2: 1) - $2 = token '^' (4.3: ) - $3 = nterm exp (4.4: 2) --> $$ = nterm exp (4.2-4: 1) -Entering state 10 -Next token is token '=' (4.6: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (4.1: ) - $2 = nterm exp (4.2-4: 1) --> $$ = nterm exp (4.1-4: -1) + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 -Next token is token '=' (4.6: ) -Shifting token '=' (4.6: ) -Entering state 19 Reading a token -Next token is token '-' (4.8: ) -Shifting token '-' (4.8: ) -Entering state 2 +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 19 Reading a token -Next token is token "number" (4.9: 1) -Shifting token "number" (4.9: 1) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (4.9: 1) --> $$ = nterm exp (4.9: 1) -Entering state 10 -Reading a token -Next token is token '\n' (4.10-5.0: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (4.8: ) - $2 = nterm exp (4.9: 1) --> $$ = nterm exp (4.8-9: -1) + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 28 -Next token is token '\n' (4.10-5.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (4.1-4: -1) - $2 = token '=' (4.6: ) - $3 = nterm exp (4.8-9: -1) --> $$ = nterm exp (4.1-9: -1) -Entering state 8 -Next token is token '\n' (4.10-5.0: ) -Shifting token '\n' (4.10-5.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (4.1-9: -1) - $2 = token '\n' (4.10-5.0: ) --> $$ = nterm line (4.1-5.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-4.0: ) - $2 = nterm line (4.1-5.0: ) +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Error: popping token '=' (1.3: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '=' (1.7: ) +./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.6: syntax error: invalid character: '#' +1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-17: error: 2222 != 1 +input: +./calc.at:1402: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +stderr: +./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 19 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 28 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Error: popping token '=' (1.3: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '=' (1.7: ) + | (* *) + (*) + (*) + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +input: +./calc.at:1403: $PREPARSER ./calc input +./calc.at:1408: $PREPARSER ./calc input +stderr: +./calc.at:1402: cat stderr +stderr: + | (# + 1) = 1111 +./calc.at:1416: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o calc calc.c calc-lex.c calc-main.c $LIBS +./calc.at:1407: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1400: $PREPARSER ./calc input +stderr: +1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-17: error: 2222 != 1 +./calc.at:1401: cat stderr +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Reading a token +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Reading a token +Next token is token "number" (1.7: 1) +Shifting token "number" (1.7: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.7: 1) +-> $$ = nterm exp (1.7: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 21 +Reading a token +Next token is token "number" (1.11: 1) +Shifting token "number" (1.11: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 30 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Reading a token +Next token is token "number" (1.15: 1) +Shifting token "number" (1.15: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 30 +Reading a token +Next token is token '+' (1.17: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 21 +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Error: popping nterm exp (1.7-15: 3) +Shifting token error (1.7-18: ) +Entering state 11 +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 30 +Reading a token +Next token is token '+' (1.20: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) +Entering state 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 21 +Reading a token +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 +Reading a token +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) +Entering state 11 +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) +Reading a token +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Reading a token +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Reading a token +Next token is token ')' (1.28: ) +Entering state 11 +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 30 +Reading a token +Next token is token '+' (1.30: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) +Entering state 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +Entering state 21 +Reading a token +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) +Entering state 4 +Reading a token +Next token is token "number" (1.33: 1) +Shifting token "number" (1.33: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 +Reading a token +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 22 +Reading a token +Next token is token "number" (1.37: 2) +Shifting token "number" (1.37: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 31 +Reading a token +Next token is token '*' (1.39: ) +Reducing stack 0 by rule 9 (line 107): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 22 +Reading a token +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Error: popping nterm exp (1.33-37: 2) +Shifting token error (1.33-41: ) +Entering state 11 +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) +Reading a token +Next token is token ')' (1.42: ) +Entering state 11 +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) +Entering state 30 +Reading a token +Next token is token '=' (1.44: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) +Entering state 8 +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) +Entering state 19 +Reading a token +Next token is token "number" (1.46: 1) +Shifting token "number" (1.46: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.46: 1) +-> $$ = nterm exp (1.46: 1) +Entering state 28 +Reading a token +Next token is token '\n' (1.47-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) +Entering state 8 +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: +./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1409: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error: invalid character: '#' +./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1405: cat stderr +input: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Reading a token +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Reading a token +Next token is token "number" (1.7: 1) +Shifting token "number" (1.7: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.7: 1) +-> $$ = nterm exp (1.7: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 21 +Reading a token +Next token is token "number" (1.11: 1) +Shifting token "number" (1.11: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 30 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Reading a token +Next token is token "number" (1.15: 1) +Shifting token "number" (1.15: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 30 +Reading a token +Next token is token '+' (1.17: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 21 +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Error: popping nterm exp (1.7-15: 3) +Shifting token error (1.7-18: ) +Entering state 11 +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 30 +Reading a token +Next token is token '+' (1.20: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) +Entering state 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 21 +Reading a token +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 +Reading a token +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) +Entering state 11 +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) +Reading a token +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Reading a token +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Reading a token +Next token is token ')' (1.28: ) +Entering state 11 +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 30 +Reading a token +Next token is token '+' (1.30: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) +Entering state 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +Entering state 21 +Reading a token +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) +Entering state 4 +Reading a token +Next token is token "number" (1.33: 1) +Shifting token "number" (1.33: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 +Reading a token +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 22 +Reading a token +Next token is token "number" (1.37: 2) +Shifting token "number" (1.37: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 31 +Reading a token +Next token is token '*' (1.39: ) +Reducing stack 0 by rule 9 (line 107): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 22 +Reading a token +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Error: popping nterm exp (1.33-37: 2) +Shifting token error (1.33-41: ) +Entering state 11 +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) +Reading a token +Next token is token ')' (1.42: ) +Entering state 11 +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) +Entering state 30 +Reading a token +Next token is token '=' (1.44: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) +Entering state 8 +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) +Entering state 19 +Reading a token +Next token is token "number" (1.46: 1) +Shifting token "number" (1.46: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.46: 1) +-> $$ = nterm exp (1.46: 1) +Entering state 28 +Reading a token +Next token is token '\n' (1.47-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) +Entering state 8 +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1409: cat stderr +./calc.at:1407: cat stderr +input: +stderr: +stderr: +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' + | 1 + 2 * 3 + !* ++ + | (# + 1) = 1111 +./calc.at:1401: $PREPARSER ./calc input +./calc.at:1402: $PREPARSER ./calc input +./calc.at:1408: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +1.2: syntax error: invalid character: '#' +stderr: +stderr: +1.2: syntax error: invalid character: '#' +input: +input: +./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1407: $PREPARSER ./calc /dev/null +1.14: memory exhausted +./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | + | +1 +./calc.at:1409: $PREPARSER ./calc input +./calc.at:1403: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: + | (* *) + (*) + (*) +./calc.at:1408: cat stderr +./calc.at:1405: $PREPARSER ./calc input +stderr: +stdout: +stderr: +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 83): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Cleanup: discarding lookahead token '+' (2.1: ) +./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1400: cat stderr +1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +Starting parse +Entering state 0 +Reading a token +Now at end of input. +syntax error +Cleanup: discarding lookahead token "end of input" (1.1: ) +./calc.at:1411: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c calc.h + +1.2: syntax error: invalid character: '#' +./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1403: cat stderr +stderr: +1.14: memory exhausted +stderr: +input: +stderr: +input: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 83): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Cleanup: discarding lookahead token '+' (2.1: ) + | (!!) + (1 2) = 1 +1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +Starting parse +Entering state 0 +Reading a token +Now at end of input. +syntax error +Cleanup: discarding lookahead token "end of input" (1.1: ) + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +input: +./calc.at:1408: $PREPARSER ./calc input +./calc.at:1401: cat stderr +./calc.at:1411: $PREPARSER ./calc input +input: +stderr: + | (1 + # + 1) = 1111 +stderr: +./calc.at:1400: $PREPARSER ./calc input + | 1 + 2 * 3 + !+ ++ +./calc.at:1402: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1403: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Reading a token +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 16 +Reducing stack 0 by rule 16 (line 128): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Shifting token error (1.2-3: ) +Entering state 11 +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) +Entering state 21 +Reading a token +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) +Entering state 4 +Reading a token +Next token is token "number" (1.9: 1) +Shifting token "number" (1.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.9: 1) +-> $$ = nterm exp (1.9: 1) +Entering state 12 +Reading a token +Next token is token "number" (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Shifting token error (1.9-11: ) +Entering state 11 +Next token is token "number" (1.11: 2) +Error: discarding token "number" (1.11: 2) +Reading a token +Next token is token ')' (1.12: ) +Entering state 11 +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) +Entering state 30 +Reading a token +Next token is token '=' (1.14: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) +Entering state 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) +Entering state 19 +Reading a token +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 +Reading a token +Next token is token '\n' (1.17-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Reading a token +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 9 (line 101): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 19 +Reading a token +Next token is token "number" (1.13: 7) +Shifting token "number" (1.13: 7) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.13: 7) +-> $$ = nterm exp (1.13: 7) +Entering state 28 +Reading a token +Next token is token '\n' (1.14-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-9: 7) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13: 7) +-> $$ = nterm exp (1.1-13: 7) +Entering state 8 +Next token is token '\n' (1.14-2.0: ) +Shifting token '\n' (1.14-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-13: 7) + $2 = token '\n' (1.14-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Next token is token "number" (2.1: 1) +Shifting token "number" (2.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (2.1: 1) +-> $$ = nterm exp (2.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (2.3: ) +Shifting token '+' (2.3: ) +Entering state 21 +Reading a token +Next token is token "number" (2.5: 2) +Shifting token "number" (2.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (2.5: 2) +-> $$ = nterm exp (2.5: 2) +Entering state 30 +Reading a token +Next token is token '*' (2.7: ) +Shifting token '*' (2.7: ) +Entering state 22 +Reading a token +Next token is token '-' (2.9: ) +Shifting token '-' (2.9: ) +Entering state 2 +Reading a token +Next token is token "number" (2.10: 3) +Shifting token "number" (2.10: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (2.10: 3) +-> $$ = nterm exp (2.10: 3) +Entering state 10 +Reading a token +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (2.9: ) + $2 = nterm exp (2.10: 3) +-> $$ = nterm exp (2.9-10: -3) +Entering state 31 +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 9 (line 101): + $1 = nterm exp (2.5: 2) + $2 = token '*' (2.7: ) + $3 = nterm exp (2.9-10: -3) +-> $$ = nterm exp (2.5-10: -6) +Entering state 30 +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (2.1: 1) + $2 = token '+' (2.3: ) + $3 = nterm exp (2.5-10: -6) +-> $$ = nterm exp (2.1-10: -5) +Entering state 8 +Next token is token '=' (2.12: ) +Shifting token '=' (2.12: ) +Entering state 19 +Reading a token +Next token is token '-' (2.14: ) +Shifting token '-' (2.14: ) +Entering state 2 +Reading a token +Next token is token "number" (2.15: 5) +Shifting token "number" (2.15: 5) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (2.15: 5) +-> $$ = nterm exp (2.15: 5) +Entering state 10 +Reading a token +Next token is token '\n' (2.16-3.0: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (2.14: ) + $2 = nterm exp (2.15: 5) +-> $$ = nterm exp (2.14-15: -5) +Entering state 28 +Next token is token '\n' (2.16-3.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (2.1-10: -5) + $2 = token '=' (2.12: ) + $3 = nterm exp (2.14-15: -5) +-> $$ = nterm exp (2.1-15: -5) +Entering state 8 +Next token is token '\n' (2.16-3.0: ) +Shifting token '\n' (2.16-3.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (2.1-15: -5) + $2 = token '\n' (2.16-3.0: ) +-> $$ = nterm line (2.1-3.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-2.0: ) + $2 = nterm line (2.1-3.0: ) +-> $$ = nterm input (1.1-3.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (3.1-4.0: ) +Shifting token '\n' (3.1-4.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 83): + $1 = token '\n' (3.1-4.0: ) +-> $$ = nterm line (3.1-4.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-3.0: ) + $2 = nterm line (3.1-4.0: ) +-> $$ = nterm input (1.1-4.0: ) +Entering state 6 +Reading a token +Next token is token '-' (4.1: ) +Shifting token '-' (4.1: ) +Entering state 2 +Reading a token +Next token is token "number" (4.2: 1) +Shifting token "number" (4.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (4.2: 1) +-> $$ = nterm exp (4.2: 1) +Entering state 10 +Reading a token +Next token is token '^' (4.3: ) +Shifting token '^' (4.3: ) +Entering state 24 +Reading a token +Next token is token "number" (4.4: 2) +Shifting token "number" (4.4: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (4.4: 2) +-> $$ = nterm exp (4.4: 2) +Entering state 33 +Reading a token +Next token is token '=' (4.6: ) +Reducing stack 0 by rule 12 (line 112): + $1 = nterm exp (4.2: 1) + $2 = token '^' (4.3: ) + $3 = nterm exp (4.4: 2) +-> $$ = nterm exp (4.2-4: 1) +Entering state 10 +Next token is token '=' (4.6: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (4.1: ) + $2 = nterm exp (4.2-4: 1) +-> $$ = nterm exp (4.1-4: -1) +Entering state 8 +Next token is token '=' (4.6: ) +Shifting token '=' (4.6: ) +Entering state 19 +Reading a token +Next token is token '-' (4.8: ) +Shifting token '-' (4.8: ) +Entering state 2 +Reading a token +Next token is token "number" (4.9: 1) +Shifting token "number" (4.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (4.9: 1) +-> $$ = nterm exp (4.9: 1) +Entering state 10 +Reading a token +Next token is token '\n' (4.10-5.0: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (4.8: ) + $2 = nterm exp (4.9: 1) +-> $$ = nterm exp (4.8-9: -1) +Entering state 28 +Next token is token '\n' (4.10-5.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (4.1-4: -1) + $2 = token '=' (4.6: ) + $3 = nterm exp (4.8-9: -1) +-> $$ = nterm exp (4.1-9: -1) +Entering state 8 +Next token is token '\n' (4.10-5.0: ) +Shifting token '\n' (4.10-5.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (4.1-9: -1) + $2 = token '\n' (4.10-5.0: ) +-> $$ = nterm line (4.1-5.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-4.0: ) + $2 = nterm line (4.1-5.0: ) -> $$ = nterm input (1.1-5.0: ) Entering state 6 Reading a token @@ -98243,10 +99018,154 @@ Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1405: $PREPARSER ./calc input +stderr: +./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1409: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1405: cat stderr +./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.6: syntax error: invalid character: '#' +input: +./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1402: cat stderr + | (1 + # + 1) = 1111 +./calc.at:1401: $PREPARSER ./calc input +stderr: ./calc.at:1409: cat stderr stderr: stderr: +./calc.at:1407: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Reading a token +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 16 +Reducing stack 0 by rule 16 (line 128): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Shifting token error (1.2-3: ) +Entering state 11 +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) +Entering state 21 +Reading a token +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) +Entering state 4 +Reading a token +Next token is token "number" (1.9: 1) +Shifting token "number" (1.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.9: 1) +-> $$ = nterm exp (1.9: 1) +Entering state 12 +Reading a token +Next token is token "number" (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Shifting token error (1.9-11: ) +Entering state 11 +Next token is token "number" (1.11: 2) +Error: discarding token "number" (1.11: 2) +Reading a token +Next token is token ')' (1.12: ) +Entering state 11 +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) +Entering state 30 +Reading a token +Next token is token '=' (1.14: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) +Entering state 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) +Entering state 19 +Reading a token +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 +Reading a token +Next token is token '\n' (1.17-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: Starting parse Entering state 0 Reading a token @@ -99083,20 +100002,32 @@ Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1407: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +1.6: syntax error: invalid character: '#' input: - | 1 2 +input: +./calc.at:1409: $PREPARSER ./calc /dev/null +input: +./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.6: syntax error: invalid character: '#' +input: +stderr: + | 1 2 + | 1 + 2 * 3 + !+ ++ + | (#) + (#) = 2222 +stderr: +./calc.at:1405: $PREPARSER ./calc input +./calc.at:1402: $PREPARSER ./calc input ./calc.at:1411: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Now at end of input. +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token "end of input" (1.1: ) +./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 + !- ++ +stderr: +stderr: ./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -99107,14 +100038,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1408: cat stderr stderr: 1.6: syntax error: invalid character: '#' -stderr: -input: - | 1//2 -./calc.at:1407: cat stderr +./calc.at:1403: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -99130,198 +100056,34 @@ 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) -./calc.at:1409: $PREPARSER ./calc input -input: +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.3: ) -./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | error -./calc.at:1408: $PREPARSER ./calc input -./calc.at:1407: $PREPARSER ./calc /dev/null -./calc.at:1405: cat stderr -stderr: -Starting parse -Entering state 0 -Reading a token -Now at end of input. -syntax error -Cleanup: discarding lookahead token "end of input" (1.1: ) -./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1400: cat stderr +./calc.at:1407: cat stderr +./calc.at:1408: cat stderr stderr: +./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.3: ) +./calc.at:1401: cat stderr stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token "number" (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token "number" (1.3: 2) -Starting parse -Entering state 0 -Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" (1.1: ) -./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -input: Starting parse Entering state 0 Reading a token Now at end of input. -syntax error +1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) - | (# + 1) = 1111 -./calc.at:1405: $PREPARSER ./calc input -./calc.at:1411: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" (1.1: ) -./calc.at:1409: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1411: cat stderr -1.2: syntax error: invalid character: '#' -./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: 1.2: syntax error: invalid character: '#' -./calc.at:1409: cat stderr -./calc.at:1407: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1408: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1405: cat stderr +1.8: syntax error: invalid character: '#' input: - | 1//2 -./calc.at:1411: $PREPARSER ./calc input -stderr: input: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.3: ) -./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | error -./calc.at:1409: $PREPARSER ./calc input -./calc.at:1407: cat stderr -./calc.at:1408: cat stderr -stderr: -stderr: -stderr: input: - | (1 + # + 1) = 1111 + | 1 + 2 * 3 + !- ++ ./calc.at:1405: $PREPARSER ./calc input -stdout: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" (1.1: ) -./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -99333,25 +100095,21 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) +Next token is token "number" (1.3: 2) +1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.3: ) -./types.at:139: $PREPARSER ./test -1.6: syntax error: invalid character: '#' -./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Cleanup: discarding lookahead token "number" (1.3: 2) stderr: -1.6: syntax error: invalid character: '#' + | (1 + 1) / (1 - 1) + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +input: stderr: +./calc.at:1407: $PREPARSER ./calc input +./calc.at:1400: $PREPARSER ./calc input + | (- *) + (1 2) = 1 +./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -input: -input: -./calc.at:1411: "$PERL" -pi -e 'use strict; +./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -99361,53 +100119,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1 = 2 = 3 -./types.at:139: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1408: $PREPARSER ./calc input -Starting parse -Entering state 0 -Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" (1.1: ) -./calc.at:1411: cat stderr - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1407: $PREPARSER ./calc input -stderr: -./calc.at:1405: cat stderr -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 19 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 28 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Error: popping token '=' (1.3: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '=' (1.7: ) -./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -input: -input: +./calc.at:1408: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -99656,6 +100369,10 @@ Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +stderr: +1.11-17: error: null divisor +./calc.at:1400: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -99666,11 +100383,156 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1411: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: | (1 + 1) / (1 - 1) -./calc.at:1405: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Reading a token +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Reducing stack 0 by rule 15 (line 127): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Shifting token error (1.2-4: ) +Entering state 11 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Reading a token +Next token is token ')' (1.5: ) +Entering state 11 +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 21 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Reading a token +Next token is token "number" (1.10: 1) +Shifting token "number" (1.10: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Reading a token +Next token is token "number" (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Shifting token error (1.10-12: ) +Entering state 11 +Next token is token "number" (1.12: 2) +Error: discarding token "number" (1.12: 2) +Reading a token +Next token is token ')' (1.13: ) +Entering state 11 +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 30 +Reading a token +Next token is token '=' (1.15: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) +Entering state 8 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) +Entering state 19 +Reading a token +Next token is token "number" (1.17: 1) +Shifting token "number" (1.17: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.17: 1) +-> $$ = nterm exp (1.17: 1) +Entering state 28 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) +Entering state 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1401: $PREPARSER ./calc input +./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1402: cat stderr +./calc.at:1403: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1411: cat stderr +./calc.at:1409: cat stderr +stderr: stderr: 1.11-17: error: null divisor -./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1401: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1403: cat stderr +1.11-17: error: null divisor stderr: Starting parse Entering state 0 @@ -99919,12 +100781,149 @@ Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) -452. types.at:139: ok - | error +input: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Reading a token +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Reducing stack 0 by rule 15 (line 127): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Shifting token error (1.2-4: ) +Entering state 11 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Reading a token +Next token is token ')' (1.5: ) +Entering state 11 +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 21 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Reading a token +Next token is token "number" (1.10: 1) +Shifting token "number" (1.10: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Reading a token +Next token is token "number" (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Shifting token error (1.10-12: ) +Entering state 11 +Next token is token "number" (1.12: 2) +Error: discarding token "number" (1.12: 2) +Reading a token +Next token is token ')' (1.13: ) +Entering state 11 +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 30 +Reading a token +Next token is token '=' (1.15: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) +Entering state 8 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) +Entering state 19 +Reading a token +Next token is token "number" (1.17: 1) +Shifting token "number" (1.17: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.17: 1) +-> $$ = nterm exp (1.17: 1) +Entering state 28 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) +Entering state 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1405: cat stderr +input: stderr: -./calc.at:1411: $PREPARSER ./calc input + | (1 + #) = 1111 +input: +./calc.at:1402: $PREPARSER ./calc input 1.11-17: error: null divisor -./calc.at:1409: cat stderr +stderr: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1400: cat stderr +./calc.at:1409: $PREPARSER ./calc input + | 1//2 +1.6: syntax error: invalid character: '#' +./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1411: $PREPARSER ./calc input +./calc.at:1408: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: stderr: stderr: Starting parse @@ -99938,33 +100937,562 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '/' (1.3: ) +./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Reading a token +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Reading a token +Next token is token "number" (1.7: 1) +Shifting token "number" (1.7: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.7: 1) +-> $$ = nterm exp (1.7: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 21 +Reading a token +Next token is token "number" (1.11: 1) +Shifting token "number" (1.11: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 30 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Reading a token +Next token is token "number" (1.15: 1) +Shifting token "number" (1.15: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 30 +Reading a token +Next token is token '+' (1.17: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 21 +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Error: popping nterm exp (1.7-15: 3) +Shifting token error (1.7-18: ) +Entering state 11 +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 30 +Reading a token +Next token is token '+' (1.20: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) +Entering state 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 21 +Reading a token +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 +Reading a token +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) +Entering state 11 +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) +Reading a token +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Reading a token +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Reading a token +Next token is token ')' (1.28: ) +Entering state 11 +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 30 +Reading a token +Next token is token '+' (1.30: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) +Entering state 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +Entering state 21 +Reading a token +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) +Entering state 4 +Reading a token +Next token is token "number" (1.33: 1) +Shifting token "number" (1.33: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 +Reading a token +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 22 +Reading a token +Next token is token "number" (1.37: 2) +Shifting token "number" (1.37: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 31 +Reading a token +Next token is token '*' (1.39: ) +Reducing stack 0 by rule 9 (line 107): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 22 +Reading a token +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Error: popping nterm exp (1.33-37: 2) +Shifting token error (1.33-41: ) +Entering state 11 +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) +Reading a token +Next token is token ')' (1.42: ) +Entering state 11 +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) +Entering state 30 +Reading a token +Next token is token '=' (1.44: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) +Entering state 8 +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) Entering state 19 Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) +Next token is token "number" (1.46: 1) +Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) + $1 = token "number" (1.46: 1) +-> $$ = nterm exp (1.46: 1) Entering state 28 Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Error: popping token '=' (1.3: ) +Next token is token '\n' (1.47-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) +Entering state 8 +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: +./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +510. calc.at:1400: | 1 + 2 * 3 + !* ++ +input: +./calc.at:1403: $PREPARSER ./calc input + ok +./calc.at:1407: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +1.6: syntax error: invalid character: '#' +./calc.at:1408: cat stderr +stderr: + | 1 + 2 * 3 + !* ++ +./calc.at:1401: cat stderr +./calc.at:1405: $PREPARSER ./calc input +stderr: +1.14: memory exhausted +stderr: +stderr: +1.14: memory exhausted +./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '=' (1.7: ) -./calc.at:1405: cat stderr +Cleanup: discarding lookahead token '/' (1.3: ) +input: Starting parse Entering state 0 Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" (1.1: ) -./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1407: "$PERL" -pi -e 'use strict; +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Reading a token +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Reading a token +Next token is token "number" (1.7: 1) +Shifting token "number" (1.7: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.7: 1) +-> $$ = nterm exp (1.7: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 21 +Reading a token +Next token is token "number" (1.11: 1) +Shifting token "number" (1.11: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 30 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Reading a token +Next token is token "number" (1.15: 1) +Shifting token "number" (1.15: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 30 +Reading a token +Next token is token '+' (1.17: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 21 +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Error: popping nterm exp (1.7-15: 3) +Shifting token error (1.7-18: ) +Entering state 11 +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 30 +Reading a token +Next token is token '+' (1.20: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) +Entering state 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 21 +Reading a token +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 +Reading a token +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) +Entering state 11 +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) +Reading a token +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Reading a token +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Reading a token +Next token is token ')' (1.28: ) +Entering state 11 +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 30 +Reading a token +Next token is token '+' (1.30: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) +Entering state 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +Entering state 21 +Reading a token +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) +Entering state 4 +Reading a token +Next token is token "number" (1.33: 1) +Shifting token "number" (1.33: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 +Reading a token +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 22 +Reading a token +Next token is token "number" (1.37: 2) +Shifting token "number" (1.37: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 31 +Reading a token +Next token is token '*' (1.39: ) +Reducing stack 0 by rule 9 (line 107): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 22 +Reading a token +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Error: popping nterm exp (1.33-37: 2) +Shifting token error (1.33-41: ) +Entering state 11 +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) +Reading a token +Next token is token ')' (1.42: ) +Entering state 11 +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) +Entering state 30 +Reading a token +Next token is token '=' (1.44: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) +Entering state 8 +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) +Entering state 19 +Reading a token +Next token is token "number" (1.46: 1) +Shifting token "number" (1.46: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.46: 1) +-> $$ = nterm exp (1.46: 1) +Entering state 28 +Reading a token +Next token is token '\n' (1.47-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) +Entering state 8 +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +511. calc.at:1401: ok +./calc.at:1402: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -99974,10 +101502,143 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - -514. calc.at:1405: ok ./calc.at:1407: cat stderr -./calc.at:1408: "$PERL" -pi -e 'use strict; + | (* *) + (*) + (*) +./calc.at:1408: $PREPARSER ./calc input +stderr: +stderr: +stderr: +1.14: memory exhausted +./calc.at:1402: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) +Reading a token +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Reading a token +Next token is token ')' (1.5: ) +Entering state 11 +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 21 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Reading a token +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) +Entering state 11 +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) +Reading a token +Next token is token ')' (1.11: ) +Entering state 11 +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) +Entering state 30 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) +Entering state 8 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Reading a token +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 +Reading a token +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) +Reading a token +Next token is token ')' (1.17: ) +Entering state 11 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 30 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) +Entering state 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +1.14: memory exhausted +./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1409: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + +./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -99988,20 +101649,146 @@ }eg ' expout || exit 77 input: +./calc.at:1405: cat stderr +stderr: input: | (!!) + (1 2) = 1 +./calc.at:1409: cat stderr ./calc.at:1407: $PREPARSER ./calc input - | 1 = 2 = 3 -./calc.at:1409: $PREPARSER ./calc input -stderr: -./calc.at:1408: cat stderr +./calc.at:1411: cat stderr Starting parse Entering state 0 Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" (1.1: ) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) +Reading a token +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Reading a token +Next token is token ')' (1.5: ) +Entering state 11 +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 21 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Reading a token +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) +Entering state 11 +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) +Reading a token +Next token is token ')' (1.11: ) +Entering state 11 +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) +Entering state 30 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) +Entering state 8 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Reading a token +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 +Reading a token +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) +Reading a token +Next token is token ')' (1.17: ) +Entering state 11 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 30 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) +Entering state 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) + | (# + 1) = 1111 +./calc.at:1403: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1402: $PREPARSER ./calc input +stderr: + stderr: +input: +./calc.at:1403: cat stderr +1.2: syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token @@ -100113,7 +101900,161 @@ Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) +./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (!!) + (1 2) = 1 + | (#) + (#) = 2222 +./calc.at:1405: $PREPARSER ./calc input +./calc.at:1408: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1409: $PREPARSER ./calc input +input: +stderr: +stderr: +input: +1.2: syntax error: invalid character: '#' + | error +./calc.at:1411: $PREPARSER ./calc input +./calc.at:1408: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Reading a token +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 16 +Reducing stack 0 by rule 16 (line 128): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Shifting token error (1.2-3: ) +Entering state 11 +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) +Entering state 21 +Reading a token +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) +Entering state 4 +Reading a token +Next token is token "number" (1.9: 1) +Shifting token "number" (1.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.9: 1) +-> $$ = nterm exp (1.9: 1) +Entering state 12 +Reading a token +Next token is token "number" (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Shifting token error (1.9-11: ) +Entering state 11 +Next token is token "number" (1.11: 2) +Error: discarding token "number" (1.11: 2) +Reading a token +Next token is token ')' (1.12: ) +Entering state 11 +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) +Entering state 30 +Reading a token +Next token is token '=' (1.14: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) +Entering state 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) +Entering state 19 +Reading a token +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 +Reading a token +Next token is token '\n' (1.17-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: +./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +522. calc.at:1426: testing Calculator lalr1.cc %header ... +./calc.at:1426: mv calc.y.tmp calc.y + +stderr: +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +stderr: +./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (#) + (#) = 2222 +./calc.at:1403: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token "invalid token" (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" (1.1: ) +./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse @@ -100227,7 +102168,163 @@ Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Reading a token +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 16 +Reducing stack 0 by rule 16 (line 128): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Shifting token error (1.2-3: ) +Entering state 11 +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) +Entering state 21 +Reading a token +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) +Entering state 4 +Reading a token +Next token is token "number" (1.9: 1) +Shifting token "number" (1.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.9: 1) +-> $$ = nterm exp (1.9: 1) +Entering state 12 +Reading a token +Next token is token "number" (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Shifting token error (1.9-11: ) +Entering state 11 +Next token is token "number" (1.11: 2) +Error: discarding token "number" (1.11: 2) +Reading a token +Next token is token ')' (1.12: ) +Entering state 11 +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) +Entering state 30 +Reading a token +Next token is token '=' (1.14: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) +Entering state 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) +Entering state 19 +Reading a token +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 +Reading a token +Next token is token '\n' (1.17-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1426: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1402: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +523. calc.at:1431: testing Calculator C++ ... +./calc.at:1431: mv calc.y.tmp calc.y +input: +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +Starting parse +Entering state 0 +Reading a token +Next token is token "invalid token" (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" (1.1: ) + | 1 + 2 * 3 + !+ ++ +./calc.at:1408: $PREPARSER ./calc input +stderr: +./calc.at:1431: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1409: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1402: cat stderr Starting parse Entering state 0 Reading a token @@ -100239,9 +102336,9 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 19 +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) @@ -100249,16 +102346,50 @@ Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) -Entering state 28 +Entering state 30 Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Error: popping token '=' (1.3: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '=' (1.7: ) -./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Reading a token +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 107): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Reducing stack 0 by rule 17 (line 129): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -100269,11 +102400,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | - | +1 -./calc.at:1408: $PREPARSER ./calc input -stderr: -./calc.at:1411: cat stderr +./calc.at:1405: cat stderr +./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1409: cat stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -100284,11 +102413,229 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -525. calc.at:1433: testing Calculator C++ %locations $NO_EXCEPTIONS_CXXFLAGS ... -./calc.at:1433: mv calc.y.tmp calc.y - -./calc.at:1433: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +./calc.at:1411: cat stderr +./calc.at:1403: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +input: + | (1 + # + 1) = 1111 +./calc.at:1402: $PREPARSER ./calc input +./calc.at:1403: cat stderr +stderr: + | (1 + #) = 1111 +stderr: +./calc.at:1405: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Reading a token +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 107): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Reducing stack 0 by rule 17 (line 129): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +input: +./calc.at:1426: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS +input: +1.6: syntax error: invalid character: '#' + | (- *) + (1 2) = 1 +./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1409: $PREPARSER ./calc input +stderr: +input: +1.6: syntax error: invalid character: '#' + | 1 + 2 * 3 + !- ++ + | 1 = 2 = 3 +./calc.at:1411: $PREPARSER ./calc input +./calc.at:1408: $PREPARSER ./calc input +stderr: +./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Reading a token +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Reducing stack 0 by rule 15 (line 127): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Shifting token error (1.2-4: ) +Entering state 11 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Reading a token +Next token is token ')' (1.5: ) +Entering state 11 +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 21 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Reading a token +Next token is token "number" (1.10: 1) +Shifting token "number" (1.10: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Reading a token +Next token is token "number" (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Shifting token error (1.10-12: ) +Entering state 11 +Next token is token "number" (1.12: 2) +Error: discarding token "number" (1.12: 2) +Reading a token +Next token is token ')' (1.13: ) +Entering state 11 +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 30 +Reading a token +Next token is token '=' (1.15: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) +Entering state 8 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) +Entering state 19 +Reading a token +Next token is token "number" (1.17: 1) +Shifting token "number" (1.17: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.17: 1) +-> $$ = nterm exp (1.17: 1) +Entering state 28 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) +Entering state 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) stderr: +./calc.at:1431: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +./calc.at:1407: cat stderr +./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -100318,37 +102665,257 @@ Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) + | (1 + #) = 1111 +./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1403: $PREPARSER ./calc input +stderr: Starting parse Entering state 0 Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 83): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Cleanup: discarding lookahead token '+' (2.1: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Reading a token +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 107): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Reducing stack 0 by rule 18 (line 130): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) ./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1407: cat stderr +1.6: syntax error: invalid character: '#' +stderr: +stderr: +1.6: syntax error: invalid character: '#' +stderr: +1.6: syntax error: invalid character: '#' +./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input: +stderr: Starting parse Entering state 0 Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 83): - $1 = token '\n' (1.1-2.0: ) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Reading a token +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 107): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Reducing stack 0 by rule 18 (line 130): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) + | (- *) + (1 2) = 1 +./calc.at:1407: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Reading a token +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Reducing stack 0 by rule 15 (line 127): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Shifting token error (1.2-4: ) +Entering state 11 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Reading a token +Next token is token ')' (1.5: ) +Entering state 11 +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 21 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Reading a token +Next token is token "number" (1.10: 1) +Shifting token "number" (1.10: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Reading a token +Next token is token "number" (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Shifting token error (1.10-12: ) +Entering state 11 +Next token is token "number" (1.12: 2) +Error: discarding token "number" (1.12: 2) +Reading a token +Next token is token ')' (1.13: ) +Entering state 11 +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 30 +Reading a token +Next token is token '=' (1.15: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) +Entering state 8 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) +Entering state 19 +Reading a token +Next token is token "number" (1.17: 1) +Shifting token "number" (1.17: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.17: 1) +-> $$ = nterm exp (1.17: 1) +Entering state 28 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) +Entering state 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): @@ -100356,53 +102923,11 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Cleanup: discarding lookahead token '+' (2.1: ) -./calc.at:1409: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -526. calc.at:1434: testing Calculator C++ %locations api.location.type={Span} ... -./calc.at:1434: mv calc.y.tmp calc.y - -./calc.at:1434: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y - | 1 = 2 = 3 -./calc.at:1411: $PREPARSER ./calc input -input: -./calc.at:1408: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -stderr: -stdout: -./calc.at:1413: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c calc.h - -./calc.at:1408: cat stderr - | (- *) + (1 2) = 1 +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token @@ -100432,12 +102957,16 @@ Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) -./calc.at:1407: $PREPARSER ./calc input -./calc.at:1409: cat stderr -stderr: -./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1433: $CXX $CPPFLAGS $CXXFLAGS $NO_EXCEPTIONS_CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -./calc.at:1408: $PREPARSER ./calc /dev/null +./calc.at:1402: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: stderr: Starting parse @@ -100556,44 +103085,178 @@ Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) -Starting parse -Entering state 0 -Reading a token -Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1402: cat stderr +1.6: syntax error: invalid character: '#' +./calc.at:1409: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1408: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1411: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1405: cat stderr Starting parse Entering state 0 Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '-' (1.1: ) +Shifting token '-' (1.1: ) +Entering state 2 +Reading a token +Next token is token '*' (1.1: ) +syntax error +Shifting token error (1.1: ) +Entering state 9 +Reducing stack 0 by rule 15 (line 120): + $1 = token '-' (1.1: ) + $2 = token error (1.1: ) +Shifting token error (1.1: ) +Entering state 11 +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) +Reading a token +Next token is token ')' (1.1: ) +Entering state 11 +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 -Reducing stack 0 by rule 5 (line 88): +Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) -Entering state 8 +Entering state 12 Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) +Next token is token "number" (1.1: 2) +syntax error +Error: popping nterm exp (1.1: 1) +Shifting token error (1.1: ) +Entering state 11 +Next token is token "number" (1.1: 2) +Error: discarding token "number" (1.1: 2) +Reading a token +Next token is token ')' (1.1: ) +Entering state 11 +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 30 +Reading a token +Next token is token '=' (1.1: ) +Reducing stack 0 by rule 7 (line 98): + $1 = nterm exp (1.1: 1111) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 2222) +Entering state 8 +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) Entering state 19 Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 28 Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Error: popping token '=' (1.3: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '=' (1.7: ) -./calc.at:1411: "$PERL" -pi -e 'use strict; +Next token is token '\n' (1.1: ) +Reducing stack 0 by rule 6 (line 82): + $1 = nterm exp (1.1: 2222) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 1) +error: 2222 != 1 +-> $$ = nterm exp (1.1: 2222) +Entering state 8 +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 77): + $1 = nterm exp (1.1: 2222) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (1.1: ) +Entering state 17 +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) +input: +./calc.at:1409: cat stderr +./calc.at:1408: cat stderr +input: + | (1 + 1) / (1 - 1) +./calc.at:1403: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1402: $PREPARSER ./calc input +./calc.at:1411: cat stderr +stderr: + | (# + 1) = 1111 +./calc.at:1405: $PREPARSER ./calc input +./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -100604,27 +103267,143 @@ }eg ' expout || exit 77 input: +./calc.at:1403: cat stderr +1.11-17: error: null divisor + | (* *) + (*) + (*) +./calc.at:1402: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1409: $PREPARSER ./calc input input: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1411: cat stderr -./calc.at:1413: $PREPARSER ./calc input +stderr: +input: +stderr: + | 1 + 2 * 3 + !* ++ +./calc.at:1408: $PREPARSER ./calc input +1.2: syntax error: invalid character: '#' | | +1 +./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1411: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) +Reading a token +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Reading a token +Next token is token ')' (1.5: ) +Entering state 11 +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 21 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Reading a token +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) +Entering state 11 +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) +Reading a token +Next token is token ')' (1.11: ) +Entering state 11 +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) +Entering state 30 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) +Entering state 8 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 +Reading a token +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 +Reading a token +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) +Reading a token +Next token is token ')' (1.17: ) +Entering state 11 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 30 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) +Entering state 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) stderr: -./calc.at:1409: $PREPARSER ./calc input -input: +stderr: +./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1407: cat stderr +1.11-17: error: null divisor Starting parse Entering state 0 Reading a token @@ -100660,45 +103439,45 @@ -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 9 (line 101): +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 99): +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 19 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 Reading a token -Next token is token "number" (1.13: 7) -Shifting token "number" (1.13: 7) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.13: 7) --> $$ = nterm exp (1.13: 7) -Entering state 28 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 Reading a token -Next token is token '\n' (1.14-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-9: 7) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13: 7) --> $$ = nterm exp (1.1-13: 7) -Entering state 8 -Next token is token '\n' (1.14-2.0: ) -Shifting token '\n' (1.14-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-13: 7) - $2 = token '\n' (1.14-2.0: ) +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Reducing stack 0 by rule 19 (line 131): + $1 = token '!' (1.13: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 83): + $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): @@ -100706,829 +103485,414 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token -Next token is token "number" (2.1: 1) -Shifting token "number" (2.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (2.1: 1) --> $$ = nterm exp (2.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (2.3: ) -Shifting token '+' (2.3: ) -Entering state 21 +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Cleanup: discarding lookahead token '+' (2.1: ) +./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: + | (# + 1) = 1111 +./calc.at:1403: $PREPARSER ./calc input +stderr: +stderr: +1.2: syntax error: invalid character: '#' +stderr: +input: +Starting parse +Entering state 0 Reading a token -Next token is token "number" (2.5: 2) -Shifting token "number" (2.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (2.5: 2) --> $$ = nterm exp (2.5: 2) -Entering state 30 +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 83): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 Reading a token -Next token is token '*' (2.7: ) -Shifting token '*' (2.7: ) -Entering state 22 -Reading a token -Next token is token '-' (2.9: ) -Shifting token '-' (2.9: ) -Entering state 2 -Reading a token -Next token is token "number" (2.10: 3) -Shifting token "number" (2.10: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (2.10: 3) --> $$ = nterm exp (2.10: 3) -Entering state 10 -Reading a token -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (2.9: ) - $2 = nterm exp (2.10: 3) --> $$ = nterm exp (2.9-10: -3) -Entering state 31 -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 9 (line 101): - $1 = nterm exp (2.5: 2) - $2 = token '*' (2.7: ) - $3 = nterm exp (2.9-10: -3) --> $$ = nterm exp (2.5-10: -6) -Entering state 30 -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (2.1: 1) - $2 = token '+' (2.3: ) - $3 = nterm exp (2.5-10: -6) --> $$ = nterm exp (2.1-10: -5) -Entering state 8 -Next token is token '=' (2.12: ) -Shifting token '=' (2.12: ) -Entering state 19 -Reading a token -Next token is token '-' (2.14: ) -Shifting token '-' (2.14: ) -Entering state 2 -Reading a token -Next token is token "number" (2.15: 5) -Shifting token "number" (2.15: 5) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (2.15: 5) --> $$ = nterm exp (2.15: 5) -Entering state 10 -Reading a token -Next token is token '\n' (2.16-3.0: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (2.14: ) - $2 = nterm exp (2.15: 5) --> $$ = nterm exp (2.14-15: -5) -Entering state 28 -Next token is token '\n' (2.16-3.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (2.1-10: -5) - $2 = token '=' (2.12: ) - $3 = nterm exp (2.14-15: -5) --> $$ = nterm exp (2.1-15: -5) -Entering state 8 -Next token is token '\n' (2.16-3.0: ) -Shifting token '\n' (2.16-3.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (2.1-15: -5) - $2 = token '\n' (2.16-3.0: ) --> $$ = nterm line (2.1-3.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-2.0: ) - $2 = nterm line (2.1-3.0: ) --> $$ = nterm input (1.1-3.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (3.1-4.0: ) -Shifting token '\n' (3.1-4.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 83): - $1 = token '\n' (3.1-4.0: ) --> $$ = nterm line (3.1-4.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-3.0: ) - $2 = nterm line (3.1-4.0: ) --> $$ = nterm input (1.1-4.0: ) -Entering state 6 -Reading a token -Next token is token '-' (4.1: ) -Shifting token '-' (4.1: ) -Entering state 2 -Reading a token -Next token is token "number" (4.2: 1) -Shifting token "number" (4.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (4.2: 1) --> $$ = nterm exp (4.2: 1) -Entering state 10 -Reading a token -Next token is token '^' (4.3: ) -Shifting token '^' (4.3: ) -Entering state 24 -Reading a token -Next token is token "number" (4.4: 2) -Shifting token "number" (4.4: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (4.4: 2) --> $$ = nterm exp (4.4: 2) -Entering state 33 -Reading a token -Next token is token '=' (4.6: ) -Reducing stack 0 by rule 12 (line 112): - $1 = nterm exp (4.2: 1) - $2 = token '^' (4.3: ) - $3 = nterm exp (4.4: 2) --> $$ = nterm exp (4.2-4: 1) -Entering state 10 -Next token is token '=' (4.6: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (4.1: ) - $2 = nterm exp (4.2-4: 1) --> $$ = nterm exp (4.1-4: -1) -Entering state 8 -Next token is token '=' (4.6: ) -Shifting token '=' (4.6: ) -Entering state 19 -Reading a token -Next token is token '-' (4.8: ) -Shifting token '-' (4.8: ) -Entering state 2 -Reading a token -Next token is token "number" (4.9: 1) -Shifting token "number" (4.9: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (4.9: 1) --> $$ = nterm exp (4.9: 1) -Entering state 10 -Reading a token -Next token is token '\n' (4.10-5.0: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (4.8: ) - $2 = nterm exp (4.9: 1) --> $$ = nterm exp (4.8-9: -1) -Entering state 28 -Next token is token '\n' (4.10-5.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (4.1-4: -1) - $2 = token '=' (4.6: ) - $3 = nterm exp (4.8-9: -1) --> $$ = nterm exp (4.1-9: -1) -Entering state 8 -Next token is token '\n' (4.10-5.0: ) -Shifting token '\n' (4.10-5.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (4.1-9: -1) - $2 = token '\n' (4.10-5.0: ) --> $$ = nterm line (4.1-5.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-4.0: ) - $2 = nterm line (4.1-5.0: ) --> $$ = nterm input (1.1-5.0: ) -Entering state 6 +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Cleanup: discarding lookahead token '+' (2.1: ) +1.2: syntax error: invalid character: '#' +./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 Reading a token -Next token is token '(' (5.1: ) -Shifting token '(' (5.1: ) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '-' (5.2: ) -Shifting token '-' (5.2: ) -Entering state 2 +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) Reading a token -Next token is token "number" (5.3: 1) -Shifting token "number" (5.3: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (5.3: 1) --> $$ = nterm exp (5.3: 1) -Entering state 10 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) Reading a token -Next token is token ')' (5.4: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (5.2: ) - $2 = nterm exp (5.3: 1) --> $$ = nterm exp (5.2-3: -1) -Entering state 12 -Next token is token ')' (5.4: ) -Shifting token ')' (5.4: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 113): - $1 = token '(' (5.1: ) - $2 = nterm exp (5.2-3: -1) - $3 = token ')' (5.4: ) --> $$ = nterm exp (5.1-4: -1) +Next token is token ')' (1.5: ) +Entering state 11 +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token -Next token is token '^' (5.5: ) -Shifting token '^' (5.5: ) -Entering state 24 +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 21 Reading a token -Next token is token "number" (5.6: 2) -Shifting token "number" (5.6: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (5.6: 2) --> $$ = nterm exp (5.6: 2) -Entering state 33 +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 Reading a token -Next token is token '=' (5.8: ) -Reducing stack 0 by rule 12 (line 112): - $1 = nterm exp (5.1-4: -1) - $2 = token '^' (5.5: ) - $3 = nterm exp (5.6: 2) --> $$ = nterm exp (5.1-6: 1) -Entering state 8 -Next token is token '=' (5.8: ) -Shifting token '=' (5.8: ) -Entering state 19 +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) +Entering state 11 +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) Reading a token -Next token is token "number" (5.10: 1) -Shifting token "number" (5.10: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (5.10: 1) --> $$ = nterm exp (5.10: 1) -Entering state 28 +Next token is token ')' (1.11: ) +Entering state 11 +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) +Entering state 30 Reading a token -Next token is token '\n' (5.11-6.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (5.1-6: 1) - $2 = token '=' (5.8: ) - $3 = nterm exp (5.10: 1) --> $$ = nterm exp (5.1-10: 1) +Next token is token '+' (1.13: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) Entering state 8 -Next token is token '\n' (5.11-6.0: ) -Shifting token '\n' (5.11-6.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (5.1-10: 1) - $2 = token '\n' (5.11-6.0: ) --> $$ = nterm line (5.1-6.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-5.0: ) - $2 = nterm line (5.1-6.0: ) --> $$ = nterm input (1.1-6.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (6.1-7.0: ) -Shifting token '\n' (6.1-7.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 83): - $1 = token '\n' (6.1-7.0: ) --> $$ = nterm line (6.1-7.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-6.0: ) - $2 = nterm line (6.1-7.0: ) --> $$ = nterm input (1.1-7.0: ) -Entering state 6 -Reading a token -Next token is token '-' (7.1: ) -Shifting token '-' (7.1: ) -Entering state 2 -Reading a token -Next token is token '-' (7.2: ) -Shifting token '-' (7.2: ) -Entering state 2 -Reading a token -Next token is token '-' (7.3: ) -Shifting token '-' (7.3: ) -Entering state 2 -Reading a token -Next token is token "number" (7.4: 1) -Shifting token "number" (7.4: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (7.4: 1) --> $$ = nterm exp (7.4: 1) -Entering state 10 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 Reading a token -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (7.3: ) - $2 = nterm exp (7.4: 1) --> $$ = nterm exp (7.3-4: -1) -Entering state 10 -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (7.2: ) - $2 = nterm exp (7.3-4: -1) --> $$ = nterm exp (7.2-4: 1) -Entering state 10 -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (7.1: ) - $2 = nterm exp (7.2-4: 1) --> $$ = nterm exp (7.1-4: -1) -Entering state 8 -Next token is token '=' (7.6: ) -Shifting token '=' (7.6: ) -Entering state 19 +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 Reading a token -Next token is token '-' (7.8: ) -Shifting token '-' (7.8: ) -Entering state 2 +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) Reading a token -Next token is token "number" (7.9: 1) -Shifting token "number" (7.9: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (7.9: 1) --> $$ = nterm exp (7.9: 1) -Entering state 10 +Next token is token ')' (1.17: ) +Entering state 11 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 30 Reading a token -Next token is token '\n' (7.10-8.0: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (7.8: ) - $2 = nterm exp (7.9: 1) --> $$ = nterm exp (7.8-9: -1) -Entering state 28 -Next token is token '\n' (7.10-8.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (7.1-4: -1) - $2 = token '=' (7.6: ) - $3 = nterm exp (7.8-9: -1) --> $$ = nterm exp (7.1-9: -1) +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) Entering state 8 -Next token is token '\n' (7.10-8.0: ) -Shifting token '\n' (7.10-8.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (7.1-9: -1) - $2 = token '\n' (7.10-8.0: ) --> $$ = nterm line (7.1-8.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-7.0: ) - $2 = nterm line (7.1-8.0: ) --> $$ = nterm input (1.1-8.0: ) + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token -Next token is token '\n' (8.1-9.0: ) -Shifting token '\n' (8.1-9.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 83): - $1 = token '\n' (8.1-9.0: ) --> $$ = nterm line (8.1-9.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-8.0: ) - $2 = nterm line (8.1-9.0: ) --> $$ = nterm input (1.1-9.0: ) -Entering state 6 +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: +./calc.at:1402: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (* *) + (*) + (*) +./calc.at:1407: $PREPARSER ./calc input +./calc.at:1411: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1405: cat stderr +Starting parse +Entering state 0 Reading a token -Next token is token "number" (9.1: 1) -Shifting token "number" (9.1: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (9.1: 1) --> $$ = nterm exp (9.1: 1) + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '-' (9.3: ) -Shifting token '-' (9.3: ) -Entering state 20 -Reading a token -Next token is token "number" (9.5: 2) -Shifting token "number" (9.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (9.5: 2) --> $$ = nterm exp (9.5: 2) -Entering state 29 -Reading a token -Next token is token '-' (9.7: ) -Reducing stack 0 by rule 8 (line 100): - $1 = nterm exp (9.1: 1) - $2 = token '-' (9.3: ) - $3 = nterm exp (9.5: 2) --> $$ = nterm exp (9.1-5: -1) -Entering state 8 -Next token is token '-' (9.7: ) -Shifting token '-' (9.7: ) -Entering state 20 +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 Reading a token -Next token is token "number" (9.9: 3) -Shifting token "number" (9.9: 3) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (9.9: 3) --> $$ = nterm exp (9.9: 3) -Entering state 29 -Reading a token -Next token is token '=' (9.11: ) -Reducing stack 0 by rule 8 (line 100): - $1 = nterm exp (9.1-5: -1) - $2 = token '-' (9.7: ) - $3 = nterm exp (9.9: 3) --> $$ = nterm exp (9.1-9: -4) -Entering state 8 -Next token is token '=' (9.11: ) -Shifting token '=' (9.11: ) -Entering state 19 + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 Reading a token -Next token is token '-' (9.13: ) -Shifting token '-' (9.13: ) -Entering state 2 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 Reading a token -Next token is token "number" (9.14: 4) -Shifting token "number" (9.14: 4) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (9.14: 4) --> $$ = nterm exp (9.14: 4) -Entering state 10 + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 Reading a token -Next token is token '\n' (9.15-10.0: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (9.13: ) - $2 = nterm exp (9.14: 4) --> $$ = nterm exp (9.13-14: -4) -Entering state 28 -Next token is token '\n' (9.15-10.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (9.1-9: -4) - $2 = token '=' (9.11: ) - $3 = nterm exp (9.13-14: -4) --> $$ = nterm exp (9.1-14: -4) +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 107): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '\n' (9.15-10.0: ) -Shifting token '\n' (9.15-10.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (9.1-14: -4) - $2 = token '\n' (9.15-10.0: ) --> $$ = nterm line (9.1-10.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-9.0: ) - $2 = nterm line (9.1-10.0: ) --> $$ = nterm input (1.1-10.0: ) -Entering state 6 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 Reading a token -Next token is token "number" (10.1: 1) -Shifting token "number" (10.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (10.1: 1) --> $$ = nterm exp (10.1: 1) -Entering state 8 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 Reading a token -Next token is token '-' (10.3: ) -Shifting token '-' (10.3: ) -Entering state 20 +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Reducing stack 0 by rule 19 (line 131): + $1 = token '!' (1.13: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +stderr: +stderr: +./calc.at:1411: cat stderr +./calc.at:1402: cat stderr +Starting parse +Entering state 0 Reading a token -Next token is token '(' (10.5: ) -Shifting token '(' (10.5: ) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (10.6: 2) -Shifting token "number" (10.6: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (10.6: 2) --> $$ = nterm exp (10.6: 2) -Entering state 12 -Reading a token -Next token is token '-' (10.8: ) -Shifting token '-' (10.8: ) -Entering state 20 -Reading a token -Next token is token "number" (10.10: 3) -Shifting token "number" (10.10: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (10.10: 3) --> $$ = nterm exp (10.10: 3) -Entering state 29 -Reading a token -Next token is token ')' (10.11: ) -Reducing stack 0 by rule 8 (line 100): - $1 = nterm exp (10.6: 2) - $2 = token '-' (10.8: ) - $3 = nterm exp (10.10: 3) --> $$ = nterm exp (10.6-10: -1) -Entering state 12 -Next token is token ')' (10.11: ) -Shifting token ')' (10.11: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 113): - $1 = token '(' (10.5: ) - $2 = nterm exp (10.6-10: -1) - $3 = token ')' (10.11: ) --> $$ = nterm exp (10.5-11: -1) -Entering state 29 -Reading a token -Next token is token '=' (10.13: ) -Reducing stack 0 by rule 8 (line 100): - $1 = nterm exp (10.1: 1) - $2 = token '-' (10.3: ) - $3 = nterm exp (10.5-11: -1) --> $$ = nterm exp (10.1-11: 2) -Entering state 8 -Next token is token '=' (10.13: ) -Shifting token '=' (10.13: ) -Entering state 19 -Reading a token -Next token is token "number" (10.15: 2) -Shifting token "number" (10.15: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (10.15: 2) --> $$ = nterm exp (10.15: 2) -Entering state 28 -Reading a token -Next token is token '\n' (10.16-11.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (10.1-11: 2) - $2 = token '=' (10.13: ) - $3 = nterm exp (10.15: 2) --> $$ = nterm exp (10.1-15: 2) -Entering state 8 -Next token is token '\n' (10.16-11.0: ) -Shifting token '\n' (10.16-11.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (10.1-15: 2) - $2 = token '\n' (10.16-11.0: ) --> $$ = nterm line (10.1-11.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-10.0: ) - $2 = nterm line (10.1-11.0: ) --> $$ = nterm input (1.1-11.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (11.1-12.0: ) -Shifting token '\n' (11.1-12.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 83): - $1 = token '\n' (11.1-12.0: ) --> $$ = nterm line (11.1-12.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-11.0: ) - $2 = nterm line (11.1-12.0: ) --> $$ = nterm input (1.1-12.0: ) -Entering state 6 -Reading a token -Next token is token "number" (12.1: 2) -Shifting token "number" (12.1: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (12.1: 2) --> $$ = nterm exp (12.1: 2) -Entering state 8 -Reading a token -Next token is token '^' (12.2: ) -Shifting token '^' (12.2: ) -Entering state 24 -Reading a token -Next token is token "number" (12.3: 2) -Shifting token "number" (12.3: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (12.3: 2) --> $$ = nterm exp (12.3: 2) -Entering state 33 -Reading a token -Next token is token '^' (12.4: ) -Shifting token '^' (12.4: ) -Entering state 24 +Next token is token '*' (1.1: ) +syntax error +Shifting token error (1.1: ) +Entering state 11 +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) Reading a token -Next token is token "number" (12.5: 3) -Shifting token "number" (12.5: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (12.5: 3) --> $$ = nterm exp (12.5: 3) -Entering state 33 +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) Reading a token -Next token is token '=' (12.7: ) -Reducing stack 0 by rule 12 (line 112): - $1 = nterm exp (12.3: 2) - $2 = token '^' (12.4: ) - $3 = nterm exp (12.5: 3) --> $$ = nterm exp (12.3-5: 8) -Entering state 33 -Next token is token '=' (12.7: ) -Reducing stack 0 by rule 12 (line 112): - $1 = nterm exp (12.1: 2) - $2 = token '^' (12.2: ) - $3 = nterm exp (12.3-5: 8) --> $$ = nterm exp (12.1-5: 256) +Next token is token ')' (1.1: ) +Entering state 11 +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) Entering state 8 -Next token is token '=' (12.7: ) -Shifting token '=' (12.7: ) -Entering state 19 -Reading a token -Next token is token "number" (12.9-11: 256) -Shifting token "number" (12.9-11: 256) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (12.9-11: 256) --> $$ = nterm exp (12.9-11: 256) -Entering state 28 Reading a token -Next token is token '\n' (12.12-13.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (12.1-5: 256) - $2 = token '=' (12.7: ) - $3 = nterm exp (12.9-11: 256) --> $$ = nterm exp (12.1-11: 256) -Entering state 8 -Next token is token '\n' (12.12-13.0: ) -Shifting token '\n' (12.12-13.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (12.1-11: 256) - $2 = token '\n' (12.12-13.0: ) --> $$ = nterm line (12.1-13.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-12.0: ) - $2 = nterm line (12.1-13.0: ) --> $$ = nterm input (1.1-13.0: ) -Entering state 6 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 Reading a token -Next token is token '(' (13.1: ) -Shifting token '(' (13.1: ) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (13.2: 2) -Shifting token "number" (13.2: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (13.2: 2) --> $$ = nterm exp (13.2: 2) -Entering state 12 -Reading a token -Next token is token '^' (13.3: ) -Shifting token '^' (13.3: ) -Entering state 24 +Next token is token '*' (1.1: ) +syntax error +Shifting token error (1.1: ) +Entering state 11 +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) Reading a token -Next token is token "number" (13.4: 2) -Shifting token "number" (13.4: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (13.4: 2) --> $$ = nterm exp (13.4: 2) -Entering state 33 +Next token is token ')' (1.1: ) +Entering state 11 +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 30 Reading a token -Next token is token ')' (13.5: ) -Reducing stack 0 by rule 12 (line 112): - $1 = nterm exp (13.2: 2) - $2 = token '^' (13.3: ) - $3 = nterm exp (13.4: 2) --> $$ = nterm exp (13.2-4: 4) -Entering state 12 -Next token is token ')' (13.5: ) -Shifting token ')' (13.5: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 113): - $1 = token '(' (13.1: ) - $2 = nterm exp (13.2-4: 4) - $3 = token ')' (13.5: ) --> $$ = nterm exp (13.1-5: 4) +Next token is token '+' (1.1: ) +Reducing stack 0 by rule 7 (line 98): + $1 = nterm exp (1.1: 1111) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 2222) Entering state 8 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 Reading a token -Next token is token '^' (13.6: ) -Shifting token '^' (13.6: ) -Entering state 24 -Reading a token -Next token is token "number" (13.7: 3) -Shifting token "number" (13.7: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (13.7: 3) --> $$ = nterm exp (13.7: 3) -Entering state 33 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 Reading a token -Next token is token '=' (13.9: ) -Reducing stack 0 by rule 12 (line 112): - $1 = nterm exp (13.1-5: 4) - $2 = token '^' (13.6: ) - $3 = nterm exp (13.7: 3) --> $$ = nterm exp (13.1-7: 64) -Entering state 8 -Next token is token '=' (13.9: ) -Shifting token '=' (13.9: ) -Entering state 19 +Next token is token '*' (1.1: ) +syntax error +Shifting token error (1.1: ) +Entering state 11 +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) Reading a token -Next token is token "number" (13.11-12: 64) -Shifting token "number" (13.11-12: 64) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (13.11-12: 64) --> $$ = nterm exp (13.11-12: 64) -Entering state 28 +Next token is token ')' (1.1: ) +Entering state 11 +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 30 Reading a token -Next token is token '\n' (13.13-14.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (13.1-7: 64) - $2 = token '=' (13.9: ) - $3 = nterm exp (13.11-12: 64) --> $$ = nterm exp (13.1-12: 64) +Next token is token '\n' (1.1: ) +Reducing stack 0 by rule 7 (line 98): + $1 = nterm exp (1.1: 2222) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 3333) Entering state 8 -Next token is token '\n' (13.13-14.0: ) -Shifting token '\n' (13.13-14.0: ) +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (13.1-12: 64) - $2 = token '\n' (13.13-14.0: ) --> $$ = nterm line (13.1-14.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-13.0: ) - $2 = nterm line (13.1-14.0: ) --> $$ = nterm input (1.1-14.0: ) +Reducing stack 0 by rule 4 (line 77): + $1 = nterm exp (1.1: 3333) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" (14.1: ) +Shifting token "end of input" (1.1: ) Entering state 17 -Cleanup: popping token "end of input" (14.1: ) -Cleanup: popping nterm input (1.1-14.0: ) -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 83): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Cleanup: discarding lookahead token '+' (2.1: ) - | - | +1 -./calc.at:1411: $PREPARSER ./calc input -./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) +1.2: syntax error: invalid character: '#' +./calc.at:1409: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1411: $PREPARSER ./calc /dev/null +input: stderr: +512. calc.at:1402: ok +./calc.at:1409: cat stderr +./calc.at:1408: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 83): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Cleanup: discarding lookahead token '+' (2.1: ) +Now at end of input. +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token "end of input" (1.1: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + # + 1) = 1111 +stderr: +./calc.at:1405: $PREPARSER ./calc input +./calc.at:1403: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 83): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Cleanup: discarding lookahead token '+' (2.1: ) Starting parse Entering state 0 Reading a token @@ -101536,22 +103900,16 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '-' (1.1: ) -Shifting token '-' (1.1: ) -Entering state 2 -Reading a token Next token is token '*' (1.1: ) syntax error Shifting token error (1.1: ) -Entering state 9 -Reducing stack 0 by rule 15 (line 120): - $1 = token '-' (1.1: ) - $2 = token error (1.1: ) -Shifting token error (1.1: ) Entering state 11 Next token is token '*' (1.1: ) Error: discarding token '*' (1.1: ) Reading a token +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) +Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) @@ -101572,21 +103930,12 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Reading a token -Next token is token "number" (1.1: 2) +Next token is token '*' (1.1: ) syntax error -Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 -Next token is token "number" (1.1: 2) -Error: discarding token "number" (1.1: 2) +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) Reading a token Next token is token ')' (1.1: ) Entering state 11 @@ -101600,38 +103949,52 @@ -> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token -Next token is token '=' (1.1: ) +Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 1111) $2 = token '+' (1.1: ) $3 = nterm exp (1.1: 1111) -> $$ = nterm exp (1.1: 2222) Entering state 8 -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 28 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '*' (1.1: ) +syntax error +Shifting token error (1.1: ) +Entering state 11 +Next token is token '*' (1.1: ) +Error: discarding token '*' (1.1: ) +Reading a token +Next token is token ')' (1.1: ) +Entering state 11 +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) +Entering state 30 Reading a token Next token is token '\n' (1.1: ) -Reducing stack 0 by rule 6 (line 82): +Reducing stack 0 by rule 7 (line 98): $1 = nterm exp (1.1: 2222) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1) -error: 2222 != 1 --> $$ = nterm exp (1.1: 2222) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 3333) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): - $1 = nterm exp (1.1: 2222) + $1 = nterm exp (1.1: 3333) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 @@ -101645,33 +104008,23 @@ Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) +./calc.at:1408: cat stderr +1.6: syntax error: invalid character: '#' +./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +input: +./calc.at:1403: cat stderr Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) + | 1 + 2 * 3 + !+ ++ +./calc.at:1409: $PREPARSER ./calc input stderr: stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 83): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Cleanup: discarding lookahead token '+' (2.1: ) +1.6: syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token @@ -101707,862 +104060,415 @@ -> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 9 (line 101): +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 107): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 99): +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 105): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 19 -Reading a token -Next token is token "number" (1.13: 7) -Shifting token "number" (1.13: 7) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.13: 7) --> $$ = nterm exp (1.13: 7) -Entering state 28 -Reading a token -Next token is token '\n' (1.14-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-9: 7) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13: 7) --> $$ = nterm exp (1.1-13: 7) -Entering state 8 -Next token is token '\n' (1.14-2.0: ) -Shifting token '\n' (1.14-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-13: 7) - $2 = token '\n' (1.14-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Next token is token "number" (2.1: 1) -Shifting token "number" (2.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (2.1: 1) --> $$ = nterm exp (2.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (2.3: ) -Shifting token '+' (2.3: ) +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) Entering state 21 Reading a token -Next token is token "number" (2.5: 2) -Shifting token "number" (2.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (2.5: 2) --> $$ = nterm exp (2.5: 2) -Entering state 30 -Reading a token -Next token is token '*' (2.7: ) -Shifting token '*' (2.7: ) -Entering state 22 -Reading a token -Next token is token '-' (2.9: ) -Shifting token '-' (2.9: ) -Entering state 2 -Reading a token -Next token is token "number" (2.10: 3) -Shifting token "number" (2.10: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (2.10: 3) --> $$ = nterm exp (2.10: 3) -Entering state 10 -Reading a token -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (2.9: ) - $2 = nterm exp (2.10: 3) --> $$ = nterm exp (2.9-10: -3) -Entering state 31 -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 9 (line 101): - $1 = nterm exp (2.5: 2) - $2 = token '*' (2.7: ) - $3 = nterm exp (2.9-10: -3) --> $$ = nterm exp (2.5-10: -6) -Entering state 30 -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (2.1: 1) - $2 = token '+' (2.3: ) - $3 = nterm exp (2.5-10: -6) --> $$ = nterm exp (2.1-10: -5) -Entering state 8 -Next token is token '=' (2.12: ) -Shifting token '=' (2.12: ) -Entering state 19 -Reading a token -Next token is token '-' (2.14: ) -Shifting token '-' (2.14: ) -Entering state 2 -Reading a token -Next token is token "number" (2.15: 5) -Shifting token "number" (2.15: 5) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (2.15: 5) --> $$ = nterm exp (2.15: 5) -Entering state 10 -Reading a token -Next token is token '\n' (2.16-3.0: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (2.14: ) - $2 = nterm exp (2.15: 5) --> $$ = nterm exp (2.14-15: -5) -Entering state 28 -Next token is token '\n' (2.16-3.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (2.1-10: -5) - $2 = token '=' (2.12: ) - $3 = nterm exp (2.14-15: -5) --> $$ = nterm exp (2.1-15: -5) -Entering state 8 -Next token is token '\n' (2.16-3.0: ) -Shifting token '\n' (2.16-3.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (2.1-15: -5) - $2 = token '\n' (2.16-3.0: ) --> $$ = nterm line (2.1-3.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-2.0: ) - $2 = nterm line (2.1-3.0: ) --> $$ = nterm input (1.1-3.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (3.1-4.0: ) -Shifting token '\n' (3.1-4.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 83): - $1 = token '\n' (3.1-4.0: ) --> $$ = nterm line (3.1-4.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-3.0: ) - $2 = nterm line (3.1-4.0: ) --> $$ = nterm input (1.1-4.0: ) -Entering state 6 -Reading a token -Next token is token '-' (4.1: ) -Shifting token '-' (4.1: ) -Entering state 2 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 Reading a token -Next token is token "number" (4.2: 1) -Shifting token "number" (4.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (4.2: 1) --> $$ = nterm exp (4.2: 1) -Entering state 10 +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Reducing stack 0 by rule 17 (line 129): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +input: +./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (#) + (#) = 2222 +./calc.at:1408: $PREPARSER ./calc input + +./calc.at:1411: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +stderr: +./calc.at:1407: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 Reading a token -Next token is token '^' (4.3: ) -Shifting token '^' (4.3: ) -Entering state 24 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 Reading a token -Next token is token "number" (4.4: 2) -Shifting token "number" (4.4: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (4.4: 2) --> $$ = nterm exp (4.4: 2) -Entering state 33 +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) Reading a token -Next token is token '=' (4.6: ) -Reducing stack 0 by rule 12 (line 112): - $1 = nterm exp (4.2: 1) - $2 = token '^' (4.3: ) - $3 = nterm exp (4.4: 2) --> $$ = nterm exp (4.2-4: 1) -Entering state 10 -Next token is token '=' (4.6: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (4.1: ) - $2 = nterm exp (4.2-4: 1) --> $$ = nterm exp (4.1-4: -1) +Next token is token ')' (1.3: ) +Entering state 11 +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) Entering state 8 -Next token is token '=' (4.6: ) -Shifting token '=' (4.6: ) -Entering state 19 -Reading a token -Next token is token '-' (4.8: ) -Shifting token '-' (4.8: ) -Entering state 2 -Reading a token -Next token is token "number" (4.9: 1) -Shifting token "number" (4.9: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (4.9: 1) --> $$ = nterm exp (4.9: 1) -Entering state 10 Reading a token -Next token is token '\n' (4.10-5.0: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (4.8: ) - $2 = nterm exp (4.9: 1) --> $$ = nterm exp (4.8-9: -1) -Entering state 28 -Next token is token '\n' (4.10-5.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (4.1-4: -1) - $2 = token '=' (4.6: ) - $3 = nterm exp (4.8-9: -1) --> $$ = nterm exp (4.1-9: -1) -Entering state 8 -Next token is token '\n' (4.10-5.0: ) -Shifting token '\n' (4.10-5.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (4.1-9: -1) - $2 = token '\n' (4.10-5.0: ) --> $$ = nterm line (4.1-5.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-4.0: ) - $2 = nterm line (4.1-5.0: ) --> $$ = nterm input (1.1-5.0: ) -Entering state 6 +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) +Entering state 21 Reading a token -Next token is token '(' (5.1: ) -Shifting token '(' (5.1: ) +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) Entering state 4 Reading a token -Next token is token '-' (5.2: ) -Shifting token '-' (5.2: ) -Entering state 2 -Reading a token -Next token is token "number" (5.3: 1) -Shifting token "number" (5.3: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (5.3: 1) --> $$ = nterm exp (5.3: 1) -Entering state 10 -Reading a token -Next token is token ')' (5.4: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (5.2: ) - $2 = nterm exp (5.3: 1) --> $$ = nterm exp (5.2-3: -1) -Entering state 12 -Next token is token ')' (5.4: ) -Shifting token ')' (5.4: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 113): - $1 = token '(' (5.1: ) - $2 = nterm exp (5.2-3: -1) - $3 = token ')' (5.4: ) --> $$ = nterm exp (5.1-4: -1) -Entering state 8 -Reading a token -Next token is token '^' (5.5: ) -Shifting token '^' (5.5: ) -Entering state 24 +1.8: syntax error: invalid character: '#' +Next token is token error (1.8: ) +Shifting token error (1.8: ) +Entering state 11 +Next token is token error (1.8: ) +Error: discarding token error (1.8: ) Reading a token -Next token is token "number" (5.6: 2) -Shifting token "number" (5.6: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (5.6: 2) --> $$ = nterm exp (5.6: 2) -Entering state 33 +Next token is token ')' (1.9: ) +Entering state 11 +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 30 Reading a token -Next token is token '=' (5.8: ) -Reducing stack 0 by rule 12 (line 112): - $1 = nterm exp (5.1-4: -1) - $2 = token '^' (5.5: ) - $3 = nterm exp (5.6: 2) --> $$ = nterm exp (5.1-6: 1) +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) Entering state 8 -Next token is token '=' (5.8: ) -Shifting token '=' (5.8: ) +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) Entering state 19 Reading a token -Next token is token "number" (5.10: 1) -Shifting token "number" (5.10: 1) +Next token is token "number" (1.13-16: 2222) +Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (5.10: 1) --> $$ = nterm exp (5.10: 1) + $1 = token "number" (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token -Next token is token '\n' (5.11-6.0: ) +Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (5.1-6: 1) - $2 = token '=' (5.8: ) - $3 = nterm exp (5.10: 1) --> $$ = nterm exp (5.1-10: 1) + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 -Next token is token '\n' (5.11-6.0: ) -Shifting token '\n' (5.11-6.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (5.1-10: 1) - $2 = token '\n' (5.11-6.0: ) --> $$ = nterm line (5.1-6.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-5.0: ) - $2 = nterm line (5.1-6.0: ) --> $$ = nterm input (1.1-6.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (6.1-7.0: ) -Shifting token '\n' (6.1-7.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 83): - $1 = token '\n' (6.1-7.0: ) --> $$ = nterm line (6.1-7.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-6.0: ) - $2 = nterm line (6.1-7.0: ) --> $$ = nterm input (1.1-7.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token -Next token is token '-' (7.1: ) -Shifting token '-' (7.1: ) -Entering state 2 -Reading a token -Next token is token '-' (7.2: ) -Shifting token '-' (7.2: ) -Entering state 2 -Reading a token -Next token is token '-' (7.3: ) -Shifting token '-' (7.3: ) -Entering state 2 -Reading a token -Next token is token "number" (7.4: 1) -Shifting token "number" (7.4: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (7.4: 1) --> $$ = nterm exp (7.4: 1) -Entering state 10 -Reading a token -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (7.3: ) - $2 = nterm exp (7.4: 1) --> $$ = nterm exp (7.3-4: -1) -Entering state 10 -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (7.2: ) - $2 = nterm exp (7.3-4: -1) --> $$ = nterm exp (7.2-4: 1) -Entering state 10 -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (7.1: ) - $2 = nterm exp (7.2-4: 1) --> $$ = nterm exp (7.1-4: -1) -Entering state 8 -Next token is token '=' (7.6: ) -Shifting token '=' (7.6: ) -Entering state 19 -Reading a token -Next token is token '-' (7.8: ) -Shifting token '-' (7.8: ) -Entering state 2 +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) + | (1 + # + 1) = 1111 +./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1405: cat stderr +./calc.at:1403: $PREPARSER ./calc input +./calc.at:1411: cat stderr +stderr: +stderr: +stderr: +Starting parse +Entering state 0 Reading a token -Next token is token "number" (7.9: 1) -Shifting token "number" (7.9: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (7.9: 1) --> $$ = nterm exp (7.9: 1) -Entering state 10 -Reading a token -Next token is token '\n' (7.10-8.0: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (7.8: ) - $2 = nterm exp (7.9: 1) --> $$ = nterm exp (7.8-9: -1) -Entering state 28 -Next token is token '\n' (7.10-8.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (7.1-4: -1) - $2 = token '=' (7.6: ) - $3 = nterm exp (7.8-9: -1) --> $$ = nterm exp (7.1-9: -1) + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 -Next token is token '\n' (7.10-8.0: ) -Shifting token '\n' (7.10-8.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (7.1-9: -1) - $2 = token '\n' (7.10-8.0: ) --> $$ = nterm line (7.1-8.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-7.0: ) - $2 = nterm line (7.1-8.0: ) --> $$ = nterm input (1.1-8.0: ) -Entering state 6 Reading a token -Next token is token '\n' (8.1-9.0: ) -Shifting token '\n' (8.1-9.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 83): - $1 = token '\n' (8.1-9.0: ) --> $$ = nterm line (8.1-9.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-8.0: ) - $2 = nterm line (8.1-9.0: ) --> $$ = nterm input (1.1-9.0: ) -Entering state 6 +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 Reading a token -Next token is token "number" (9.1: 1) -Shifting token "number" (9.1: 1) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (9.1: 1) --> $$ = nterm exp (9.1: 1) -Entering state 8 + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 Reading a token -Next token is token '-' (9.3: ) -Shifting token '-' (9.3: ) -Entering state 20 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 Reading a token -Next token is token "number" (9.5: 2) -Shifting token "number" (9.5: 2) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (9.5: 2) --> $$ = nterm exp (9.5: 2) -Entering state 29 + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 Reading a token -Next token is token '-' (9.7: ) -Reducing stack 0 by rule 8 (line 100): - $1 = nterm exp (9.1: 1) - $2 = token '-' (9.3: ) - $3 = nterm exp (9.5: 2) --> $$ = nterm exp (9.1-5: -1) +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 107): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '-' (9.7: ) -Shifting token '-' (9.7: ) -Entering state 20 -Reading a token -Next token is token "number" (9.9: 3) -Shifting token "number" (9.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (9.9: 3) --> $$ = nterm exp (9.9: 3) -Entering state 29 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 Reading a token -Next token is token '=' (9.11: ) -Reducing stack 0 by rule 8 (line 100): - $1 = nterm exp (9.1-5: -1) - $2 = token '-' (9.7: ) - $3 = nterm exp (9.9: 3) --> $$ = nterm exp (9.1-9: -4) -Entering state 8 -Next token is token '=' (9.11: ) -Shifting token '=' (9.11: ) -Entering state 19 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 Reading a token -Next token is token '-' (9.13: ) -Shifting token '-' (9.13: ) -Entering state 2 +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Reducing stack 0 by rule 17 (line 129): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +Starting parse +Entering state 0 Reading a token -Next token is token "number" (9.14: 4) -Shifting token "number" (9.14: 4) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (9.14: 4) --> $$ = nterm exp (9.14: 4) -Entering state 10 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 Reading a token -Next token is token '\n' (9.15-10.0: ) -Reducing stack 0 by rule 11 (line 111): - $1 = token '-' (9.13: ) - $2 = nterm exp (9.14: 4) --> $$ = nterm exp (9.13-14: -4) -Entering state 28 -Next token is token '\n' (9.15-10.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (9.1-9: -4) - $2 = token '=' (9.11: ) - $3 = nterm exp (9.13-14: -4) --> $$ = nterm exp (9.1-14: -4) -Entering state 8 -Next token is token '\n' (9.15-10.0: ) -Shifting token '\n' (9.15-10.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (9.1-14: -4) - $2 = token '\n' (9.15-10.0: ) --> $$ = nterm line (9.1-10.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-9.0: ) - $2 = nterm line (9.1-10.0: ) --> $$ = nterm input (1.1-10.0: ) -Entering state 6 +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) Reading a token -Next token is token "number" (10.1: 1) -Shifting token "number" (10.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (10.1: 1) --> $$ = nterm exp (10.1: 1) +Next token is token ')' (1.3: ) +Entering state 11 +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token -Next token is token '-' (10.3: ) -Shifting token '-' (10.3: ) -Entering state 20 +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) +Entering state 21 Reading a token -Next token is token '(' (10.5: ) -Shifting token '(' (10.5: ) +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) Entering state 4 Reading a token -Next token is token "number" (10.6: 2) -Shifting token "number" (10.6: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (10.6: 2) --> $$ = nterm exp (10.6: 2) -Entering state 12 -Reading a token -Next token is token '-' (10.8: ) -Shifting token '-' (10.8: ) -Entering state 20 -Reading a token -Next token is token "number" (10.10: 3) -Shifting token "number" (10.10: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (10.10: 3) --> $$ = nterm exp (10.10: 3) -Entering state 29 +1.8: syntax error: invalid character: '#' +Next token is token error (1.8: ) +Shifting token error (1.8: ) +Entering state 11 +Next token is token error (1.8: ) +Error: discarding token error (1.8: ) Reading a token -Next token is token ')' (10.11: ) -Reducing stack 0 by rule 8 (line 100): - $1 = nterm exp (10.6: 2) - $2 = token '-' (10.8: ) - $3 = nterm exp (10.10: 3) --> $$ = nterm exp (10.6-10: -1) -Entering state 12 -Next token is token ')' (10.11: ) -Shifting token ')' (10.11: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 113): - $1 = token '(' (10.5: ) - $2 = nterm exp (10.6-10: -1) - $3 = token ')' (10.11: ) --> $$ = nterm exp (10.5-11: -1) -Entering state 29 +Next token is token ')' (1.9: ) +Entering state 11 +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 30 Reading a token -Next token is token '=' (10.13: ) -Reducing stack 0 by rule 8 (line 100): - $1 = nterm exp (10.1: 1) - $2 = token '-' (10.3: ) - $3 = nterm exp (10.5-11: -1) --> $$ = nterm exp (10.1-11: 2) +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) Entering state 8 -Next token is token '=' (10.13: ) -Shifting token '=' (10.13: ) +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) Entering state 19 Reading a token -Next token is token "number" (10.15: 2) -Shifting token "number" (10.15: 2) +Next token is token "number" (1.13-16: 2222) +Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (10.15: 2) --> $$ = nterm exp (10.15: 2) + $1 = token "number" (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token -Next token is token '\n' (10.16-11.0: ) +Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (10.1-11: 2) - $2 = token '=' (10.13: ) - $3 = nterm exp (10.15: 2) --> $$ = nterm exp (10.1-15: 2) + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 -Next token is token '\n' (10.16-11.0: ) -Shifting token '\n' (10.16-11.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (10.1-15: 2) - $2 = token '\n' (10.16-11.0: ) --> $$ = nterm line (10.1-11.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-10.0: ) - $2 = nterm line (10.1-11.0: ) --> $$ = nterm input (1.1-11.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (11.1-12.0: ) -Shifting token '\n' (11.1-12.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 83): - $1 = token '\n' (11.1-12.0: ) --> $$ = nterm line (11.1-12.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-11.0: ) - $2 = nterm line (11.1-12.0: ) --> $$ = nterm input (1.1-12.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token -Next token is token "number" (12.1: 2) -Shifting token "number" (12.1: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (12.1: 2) --> $$ = nterm exp (12.1: 2) -Entering state 8 -Reading a token -Next token is token '^' (12.2: ) -Shifting token '^' (12.2: ) -Entering state 24 -Reading a token -Next token is token "number" (12.3: 2) -Shifting token "number" (12.3: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (12.3: 2) --> $$ = nterm exp (12.3: 2) -Entering state 33 -Reading a token -Next token is token '^' (12.4: ) -Shifting token '^' (12.4: ) -Entering state 24 -Reading a token -Next token is token "number" (12.5: 3) -Shifting token "number" (12.5: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (12.5: 3) --> $$ = nterm exp (12.5: 3) -Entering state 33 -Reading a token -Next token is token '=' (12.7: ) -Reducing stack 0 by rule 12 (line 112): - $1 = nterm exp (12.3: 2) - $2 = token '^' (12.4: ) - $3 = nterm exp (12.5: 3) --> $$ = nterm exp (12.3-5: 8) -Entering state 33 -Next token is token '=' (12.7: ) -Reducing stack 0 by rule 12 (line 112): - $1 = nterm exp (12.1: 2) - $2 = token '^' (12.2: ) - $3 = nterm exp (12.3-5: 8) --> $$ = nterm exp (12.1-5: 256) -Entering state 8 -Next token is token '=' (12.7: ) -Shifting token '=' (12.7: ) -Entering state 19 +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +1.6: syntax error: invalid character: '#' +./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | 1 + 2 * 3 + !- ++ +./calc.at:1409: $PREPARSER ./calc input +stderr: +input: +Starting parse +Entering state 0 Reading a token -Next token is token "number" (12.9-11: 256) -Shifting token "number" (12.9-11: 256) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (12.9-11: 256) --> $$ = nterm exp (12.9-11: 256) -Entering state 28 -Reading a token -Next token is token '\n' (12.12-13.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (12.1-5: 256) - $2 = token '=' (12.7: ) - $3 = nterm exp (12.9-11: 256) --> $$ = nterm exp (12.1-11: 256) + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 -Next token is token '\n' (12.12-13.0: ) -Shifting token '\n' (12.12-13.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (12.1-11: 256) - $2 = token '\n' (12.12-13.0: ) --> $$ = nterm line (12.1-13.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-12.0: ) - $2 = nterm line (12.1-13.0: ) --> $$ = nterm input (1.1-13.0: ) -Entering state 6 -Reading a token -Next token is token '(' (13.1: ) -Shifting token '(' (13.1: ) -Entering state 4 -Reading a token -Next token is token "number" (13.2: 2) -Shifting token "number" (13.2: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (13.2: 2) --> $$ = nterm exp (13.2: 2) -Entering state 12 Reading a token -Next token is token '^' (13.3: ) -Shifting token '^' (13.3: ) -Entering state 24 +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 Reading a token -Next token is token "number" (13.4: 2) -Shifting token "number" (13.4: 2) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (13.4: 2) --> $$ = nterm exp (13.4: 2) -Entering state 33 -Reading a token -Next token is token ')' (13.5: ) -Reducing stack 0 by rule 12 (line 112): - $1 = nterm exp (13.2: 2) - $2 = token '^' (13.3: ) - $3 = nterm exp (13.4: 2) --> $$ = nterm exp (13.2-4: 4) -Entering state 12 -Next token is token ')' (13.5: ) -Shifting token ')' (13.5: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 113): - $1 = token '(' (13.1: ) - $2 = nterm exp (13.2-4: 4) - $3 = token ')' (13.5: ) --> $$ = nterm exp (13.1-5: 4) -Entering state 8 + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 Reading a token -Next token is token '^' (13.6: ) -Shifting token '^' (13.6: ) -Entering state 24 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 Reading a token -Next token is token "number" (13.7: 3) -Shifting token "number" (13.7: 3) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (13.7: 3) --> $$ = nterm exp (13.7: 3) -Entering state 33 + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 Reading a token -Next token is token '=' (13.9: ) -Reducing stack 0 by rule 12 (line 112): - $1 = nterm exp (13.1-5: 4) - $2 = token '^' (13.6: ) - $3 = nterm exp (13.7: 3) --> $$ = nterm exp (13.1-7: 64) +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 107): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '=' (13.9: ) -Shifting token '=' (13.9: ) -Entering state 19 -Reading a token -Next token is token "number" (13.11-12: 64) -Shifting token "number" (13.11-12: 64) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (13.11-12: 64) --> $$ = nterm exp (13.11-12: 64) -Entering state 28 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 Reading a token -Next token is token '\n' (13.13-14.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (13.1-7: 64) - $2 = token '=' (13.9: ) - $3 = nterm exp (13.11-12: 64) --> $$ = nterm exp (13.1-12: 64) -Entering state 8 -Next token is token '\n' (13.13-14.0: ) -Shifting token '\n' (13.13-14.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (13.1-12: 64) - $2 = token '\n' (13.13-14.0: ) --> $$ = nterm line (13.1-14.0: ) -Entering state 18 -Reducing stack 0 by rule 2 (line 79): - $1 = nterm input (1.1-13.0: ) - $2 = nterm line (13.1-14.0: ) --> $$ = nterm input (1.1-14.0: ) -Entering state 6 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 Reading a token -Now at end of input. -Shifting token "end of input" (14.1: ) -Entering state 17 -Cleanup: popping token "end of input" (14.1: ) -Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1434: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Reducing stack 0 by rule 18 (line 130): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: - | 1 2 -./calc.at:1413: $PREPARSER ./calc input + | (1 + 1) / (1 - 1) +./calc.at:1405: $PREPARSER ./calc input +524. calc.at:1432: testing Calculator C++ %locations ... +./calc.at:1432: mv calc.y.tmp calc.y + +./calc.at:1407: cat stderr + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1411: $PREPARSER ./calc input stderr: -./calc.at:1409: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1411: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1409: cat stderr -./calc.at:1408: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token "number" (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token "number" (1.3: 2) -./calc.at:1408: cat stderr stderr: -./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1407: "$PERL" -pi -e 'use strict; +./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -102572,57 +104478,13 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token "number" (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token "number" (1.3: 2) -./calc.at:1411: cat stderr -./calc.at:1409: $PREPARSER ./calc /dev/null +./calc.at:1432: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +1.11-17: error: null divisor stdout: stderr: -Starting parse -Entering state 0 -Reading a token -Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" (1.1: ) -./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1416: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c calc.h - -./calc.at:1408: $PREPARSER ./calc input -./calc.at:1411: $PREPARSER ./calc /dev/null -stderr: -Starting parse -Entering state 0 -Reading a token -Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" (1.1: ) +./calc.at:1405: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1407: cat stderr Starting parse Entering state 0 Reading a token @@ -102637,7 +104499,7 @@ Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) @@ -102673,7 +104535,7 @@ Entering state 30 Reading a token Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) @@ -102692,7 +104554,7 @@ Entering state 30 Reading a token Next token is token '+' (1.17: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) @@ -102711,7 +104573,7 @@ Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) @@ -102719,7 +104581,7 @@ Entering state 30 Reading a token Next token is token '+' (1.20: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) @@ -102751,7 +104613,7 @@ Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) @@ -102759,7 +104621,7 @@ Entering state 30 Reading a token Next token is token '+' (1.30: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) @@ -102794,7 +104656,7 @@ Entering state 31 Reading a token Next token is token '*' (1.39: ) -Reducing stack 0 by rule 9 (line 107): +Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) @@ -102818,7 +104680,7 @@ Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) @@ -102826,7 +104688,7 @@ Entering state 30 Reading a token Next token is token '=' (1.44: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) @@ -102870,36 +104732,92 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1416: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c calc.h + +1.6: syntax error: invalid character: '#' +./calc.at:1408: cat stderr Starting parse Entering state 0 Reading a token -Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" (1.1: ) -./calc.at:1413: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Reading a token +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 107): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Reducing stack 0 by rule 18 (line 130): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) stderr: -./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1409: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +input: +1.11-17: error: null divisor +input: +stderr: + | 1 + 2 * 3 + !+ ++ +./calc.at:1407: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -102914,7 +104832,7 @@ Next token is token ')' (1.2: ) Shifting token ')' (1.2: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.2: ) @@ -102950,7 +104868,7 @@ Entering state 30 Reading a token Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7: 1) $2 = token '+' (1.9: ) $3 = nterm exp (1.11: 1) @@ -102969,7 +104887,7 @@ Entering state 30 Reading a token Next token is token '+' (1.17: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.7-11: 2) $2 = token '+' (1.13: ) $3 = nterm exp (1.15: 1) @@ -102988,7 +104906,7 @@ Next token is token ')' (1.18: ) Shifting token ')' (1.18: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.6: ) $2 = token error (1.7-18: ) $3 = token ')' (1.18: ) @@ -102996,7 +104914,7 @@ Entering state 30 Reading a token Next token is token '+' (1.20: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-2: 1111) $2 = token '+' (1.4: ) $3 = nterm exp (1.6-18: 1111) @@ -103028,7 +104946,7 @@ Next token is token ')' (1.28: ) Shifting token ')' (1.28: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.22: ) $2 = token error (1.23-27: ) $3 = token ')' (1.28: ) @@ -103036,7 +104954,7 @@ Entering state 30 Reading a token Next token is token '+' (1.30: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-18: 2222) $2 = token '+' (1.20: ) $3 = nterm exp (1.22-28: 1111) @@ -103071,7 +104989,7 @@ Entering state 31 Reading a token Next token is token '*' (1.39: ) -Reducing stack 0 by rule 9 (line 107): +Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.33: 1) $2 = token '*' (1.35: ) $3 = nterm exp (1.37: 2) @@ -103095,7 +105013,7 @@ Next token is token ')' (1.42: ) Shifting token ')' (1.42: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.32: ) $2 = token error (1.33-41: ) $3 = token ')' (1.42: ) @@ -103103,7 +105021,7 @@ Entering state 30 Reading a token Next token is token '=' (1.44: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-28: 3333) $2 = token '+' (1.30: ) $3 = nterm exp (1.32-42: 1111) @@ -103147,19 +105065,6 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: -./calc.at:1413: cat stderr -input: -./calc.at:1408: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -103173,17 +105078,32 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -./calc.at:1416: $PREPARSER ./calc input -Starting parse -Entering state 0 -Reading a token -Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" (1.1: ) -./calc.at:1409: cat stderr input: -./calc.at:1408: cat stderr +./calc.at:1416: $PREPARSER ./calc input stderr: + | (1 + #) = 1111 +./calc.at:1408: $PREPARSER ./calc input +./calc.at:1409: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1403: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -104021,11 +105941,73 @@ Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) stderr: -input: -stdout: - | 1//2 -./calc.at:1413: $PREPARSER ./calc input -./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Reading a token +Next token is token "number" (1.1: 2) +Shifting token "number" (1.1: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 2) +-> $$ = nterm exp (1.1: 2) +Entering state 30 +Reading a token +Next token is token '*' (1.1: ) +Shifting token '*' (1.1: ) +Entering state 22 +Reading a token +Next token is token "number" (1.1: 3) +Shifting token "number" (1.1: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 3) +-> $$ = nterm exp (1.1: 3) +Entering state 31 +Reading a token +Next token is token '+' (1.1: ) +Reducing stack 0 by rule 9 (line 100): + $1 = nterm exp (1.1: 2) + $2 = token '*' (1.1: ) + $3 = nterm exp (1.1: 3) +-> $$ = nterm exp (1.1: 6) +Entering state 30 +Next token is token '+' (1.1: ) +Reducing stack 0 by rule 7 (line 98): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 6) +-> $$ = nterm exp (1.1: 7) +Entering state 8 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Reading a token +Next token is token '!' (1.1: ) +Shifting token '!' (1.1: ) +Entering state 5 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 14 +Reducing stack 0 by rule 17 (line 122): + $1 = token '!' (1.1: ) + $2 = token '+' (1.1: ) +Cleanup: popping token '+' (1.1: ) +Cleanup: popping nterm exp (1.1: 7) +./calc.at:1405: cat stderr +./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -104036,37 +106018,238 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1432: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +./calc.at:1409: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) +Reading a token +Next token is token ')' (1.7: ) +Entering state 11 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Reading a token +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +514. calc.at:1405: ok +stderr: +./calc.at:1403: cat stderr stderr: +./calc.at:1411: cat stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 -Reducing stack 0 by rule 5 (line 88): +Reducing stack 0 by rule 5 (line 81): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.3: ) +Next token is token "number" (1.1: 2) +Shifting token "number" (1.1: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 2) +-> $$ = nterm exp (1.1: 2) +Entering state 30 +Reading a token +Next token is token '*' (1.1: ) +Shifting token '*' (1.1: ) +Entering state 22 +Reading a token +Next token is token "number" (1.1: 3) +Shifting token "number" (1.1: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 3) +-> $$ = nterm exp (1.1: 3) +Entering state 31 +Reading a token +Next token is token '+' (1.1: ) +Reducing stack 0 by rule 9 (line 100): + $1 = nterm exp (1.1: 2) + $2 = token '*' (1.1: ) + $3 = nterm exp (1.1: 3) +-> $$ = nterm exp (1.1: 6) +Entering state 30 +Next token is token '+' (1.1: ) +Reducing stack 0 by rule 7 (line 98): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 6) +-> $$ = nterm exp (1.1: 7) +Entering state 8 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Reading a token +Next token is token '!' (1.1: ) +Shifting token '!' (1.1: ) +Entering state 5 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 14 +Reducing stack 0 by rule 17 (line 122): + $1 = token '!' (1.1: ) + $2 = token '+' (1.1: ) +Cleanup: popping token '+' (1.1: ) +Cleanup: popping nterm exp (1.1: 7) +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) +Reading a token +Next token is token ')' (1.7: ) +Entering state 11 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Reading a token +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) input: - | (* *) + (*) + (*) -./calc.at:1407: $PREPARSER ./calc input -./calc.at:1411: cat stderr -stderr: - | (!!) + (1 2) = 1 -./calc.at:1408: $PREPARSER ./calc input -stderr: -./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: +stderr: + | 1 + 2 * 3 + !- ++ Starting parse Entering state 0 Reading a token @@ -104903,138 +107086,169 @@ Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1414: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.c calc.h - - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -stderr: + | 1 + 2 * 3 + !* ++ +input: +./calc.at:1407: $PREPARSER ./calc input ./calc.at:1409: $PREPARSER ./calc input input: + | (1 + 1) / (1 - 1) +stderr: +./calc.at:1403: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '*' (1.1: ) -syntax error -Shifting token error (1.1: ) -Entering state 11 -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Reading a token -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Reading a token -Next token is token ')' (1.1: ) -Entering state 11 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 +Next token is token "number" (1.1: 2) +Shifting token "number" (1.1: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 2) +-> $$ = nterm exp (1.1: 2) +Entering state 30 Reading a token Next token is token '*' (1.1: ) -syntax error -Shifting token error (1.1: ) -Entering state 11 -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) +Shifting token '*' (1.1: ) +Entering state 22 Reading a token -Next token is token ')' (1.1: ) -Entering state 11 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 30 +Next token is token "number" (1.1: 3) +Shifting token "number" (1.1: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 3) +-> $$ = nterm exp (1.1: 3) +Entering state 31 Reading a token Next token is token '+' (1.1: ) +Reducing stack 0 by rule 9 (line 100): + $1 = nterm exp (1.1: 2) + $2 = token '*' (1.1: ) + $3 = nterm exp (1.1: 3) +-> $$ = nterm exp (1.1: 6) +Entering state 30 +Next token is token '+' (1.1: ) Reducing stack 0 by rule 7 (line 98): - $1 = nterm exp (1.1: 1111) + $1 = nterm exp (1.1: 1) $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 2222) + $3 = nterm exp (1.1: 6) +-> $$ = nterm exp (1.1: 7) Entering state 8 Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 +Next token is token '!' (1.1: ) +Shifting token '!' (1.1: ) +Entering state 5 Reading a token -Next token is token '*' (1.1: ) -syntax error -Shifting token error (1.1: ) -Entering state 11 -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) +Next token is token '-' (1.1: ) +Shifting token '-' (1.1: ) +Entering state 13 +Reducing stack 0 by rule 18 (line 123): + $1 = token '!' (1.1: ) + $2 = token '-' (1.1: ) +Cleanup: popping token '+' (1.1: ) +Cleanup: popping nterm exp (1.1: 7) +./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | (!!) + (1 2) = 1 +./calc.at:1408: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | 1 2 +stderr: +./calc.at:1411: $PREPARSER ./calc input +stderr: +./calc.at:1416: $PREPARSER ./calc input +1.11-17: error: null divisor +Starting parse +Entering state 0 Reading a token -Next token is token ')' (1.1: ) -Entering state 11 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token -Next token is token '\n' (1.1: ) -Reducing stack 0 by rule 7 (line 98): - $1 = nterm exp (1.1: 2222) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 3333) +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Reading a token +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 107): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 77): - $1 = nterm exp (1.1: 3333) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) - | 1 2 -./calc.at:1416: $PREPARSER ./calc input +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Reducing stack 0 by rule 19 (line 131): + $1 = token '!' (1.13: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1403: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + +stderr: +./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: Starting parse Entering state 0 Reading a token @@ -105049,7 +107263,7 @@ Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 -Reducing stack 0 by rule 16 (line 128): +Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) @@ -105058,7 +107272,7 @@ Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) @@ -105094,7 +107308,7 @@ Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) @@ -105102,7 +107316,7 @@ Entering state 30 Reading a token Next token is token '=' (1.14: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) @@ -105146,259 +107360,177 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 +Next token is token "number" (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token "number" (1.3: 2) +./calc.at:1408: cat stderr +stdout: +stderr: +./calc.at:1414: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c calc.h + +Starting parse +Entering state 0 Reading a token -Next token is token "number" (1.7: 1) -Shifting token "number" (1.7: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) Entering state 21 Reading a token -Next token is token "number" (1.11: 1) -Shifting token "number" (1.11: 1) +Next token is token "number" (1.1: 2) +Shifting token "number" (1.1: 2) Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.11: 1) --> $$ = nterm exp (1.11: 1) +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 2) +-> $$ = nterm exp (1.1: 2) Entering state 30 Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 +Next token is token '*' (1.1: ) +Shifting token '*' (1.1: ) +Entering state 22 Reading a token -Next token is token "number" (1.15: 1) -Shifting token "number" (1.15: 1) +Next token is token "number" (1.1: 3) +Shifting token "number" (1.1: 3) Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 30 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 21 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 3) +-> $$ = nterm exp (1.1: 3) +Entering state 31 Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Error: popping nterm exp (1.7-15: 3) -Shifting token error (1.7-18: ) -Entering state 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) +Next token is token '+' (1.1: ) +Reducing stack 0 by rule 9 (line 100): + $1 = nterm exp (1.1: 2) + $2 = token '*' (1.1: ) + $3 = nterm exp (1.1: 3) +-> $$ = nterm exp (1.1: 6) Entering state 30 -Reading a token -Next token is token '+' (1.20: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) +Next token is token '+' (1.1: ) +Reducing stack 0 by rule 7 (line 98): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 6) +-> $$ = nterm exp (1.1: 7) Entering state 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) Entering state 21 Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) +Next token is token '!' (1.1: ) +Shifting token '!' (1.1: ) +Entering state 5 Reading a token -Next token is token ')' (1.28: ) -Entering state 11 -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 30 +Next token is token '-' (1.1: ) +Shifting token '-' (1.1: ) +Entering state 13 +Reducing stack 0 by rule 18 (line 123): + $1 = token '!' (1.1: ) + $2 = token '-' (1.1: ) +Cleanup: popping token '+' (1.1: ) +Cleanup: popping nterm exp (1.1: 7) +1.11-17: error: null divisor +./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +stderr: +stderr: +input: +Starting parse +Entering state 0 Reading a token -Next token is token '+' (1.30: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) -Entering state 21 Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) -Entering state 4 +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 Reading a token -Next token is token "number" (1.33: 1) -Shifting token "number" (1.33: 1) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) Entering state 22 Reading a token -Next token is token "number" (1.37: 2) -Shifting token "number" (1.37: 2) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.37: 2) --> $$ = nterm exp (1.37: 2) + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token -Next token is token '*' (1.39: ) +Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 107): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) -Entering state 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 22 -Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Error: popping nterm exp (1.33-37: 2) -Shifting token error (1.33-41: ) -Entering state 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Reading a token -Next token is token ')' (1.42: ) -Entering state 11 -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) Entering state 30 -Reading a token -Next token is token '=' (1.44: ) +Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) -Entering state 19 -Reading a token -Next token is token "number" (1.46: 1) -Shifting token "number" (1.46: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.46: 1) --> $$ = nterm exp (1.46: 1) -Entering state 28 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 Reading a token -Next token is token '\n' (1.47-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) -Entering state 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Reducing stack 0 by rule 19 (line 131): + $1 = token '!' (1.13: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) + | (# + 1) = 1111 +./calc.at:1408: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -105413,7 +107545,7 @@ Next token is token '!' (1.3: ) Shifting token '!' (1.3: ) Entering state 16 -Reducing stack 0 by rule 16 (line 128): +Reducing stack 0 by rule 16 (line 116): $1 = token '!' (1.2: ) $2 = token '!' (1.3: ) Shifting token error (1.2-3: ) @@ -105422,7 +107554,7 @@ Next token is token ')' (1.4: ) Shifting token ')' (1.4: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-3: ) $3 = token ')' (1.4: ) @@ -105458,7 +107590,7 @@ Next token is token ')' (1.12: ) Shifting token ')' (1.12: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.8: ) $2 = token error (1.9-11: ) $3 = token ')' (1.12: ) @@ -105466,7 +107598,7 @@ Entering state 30 Reading a token Next token is token '=' (1.14: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-4: 1111) $2 = token '+' (1.6: ) $3 = nterm exp (1.8-12: 1111) @@ -105510,27 +107642,6 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.3: ) -input: stderr: stderr: | 1 + 2 * 3 = 7 @@ -105546,7 +107657,6 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -./calc.at:1414: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -105554,234 +107664,56 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) -Entering state 8 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Reading a token -Next token is token "number" (1.7: 1) -Shifting token "number" (1.7: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 21 -Reading a token -Next token is token "number" (1.11: 1) -Shifting token "number" (1.11: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.11: 1) --> $$ = nterm exp (1.11: 1) -Entering state 30 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Reading a token -Next token is token "number" (1.15: 1) -Shifting token "number" (1.15: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 30 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 21 -Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Error: popping nterm exp (1.7-15: 3) -Shifting token error (1.7-18: ) -Entering state 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) -Entering state 30 -Reading a token -Next token is token '+' (1.20: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) -Entering state 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) -Entering state 21 -Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) +Error: discarding token '+' (1.4: ) Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) +Next token is token "number" (1.6: 1) +Error: discarding token "number" (1.6: 1) Reading a token -Next token is token ')' (1.28: ) +Next token is token ')' (1.7: ) Entering state 11 -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 30 -Reading a token -Next token is token '+' (1.30: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) -Entering state 21 -Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) -Entering state 4 -Reading a token -Next token is token "number" (1.33: 1) -Shifting token "number" (1.33: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 22 -Reading a token -Next token is token "number" (1.37: 2) -Shifting token "number" (1.37: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 31 -Reading a token -Next token is token '*' (1.39: ) -Reducing stack 0 by rule 9 (line 107): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) -Entering state 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 22 -Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Error: popping nterm exp (1.33-37: 2) -Shifting token error (1.33-41: ) -Entering state 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Reading a token -Next token is token ')' (1.42: ) -Entering state 11 -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) -Entering state 30 Reading a token -Next token is token '=' (1.44: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) -Entering state 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 19 Reading a token -Next token is token "number" (1.46: 1) -Shifting token "number" (1.46: 1) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.46: 1) --> $$ = nterm exp (1.46: 1) + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token -Next token is token '\n' (1.47-2.0: ) +Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): @@ -105794,126 +107726,44 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1414: $PREPARSER ./calc input +./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '*' (1.1: ) -syntax error -Shifting token error (1.1: ) -Entering state 11 -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Reading a token -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Reading a token -Next token is token ')' (1.1: ) -Entering state 11 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '*' (1.1: ) -syntax error -Shifting token error (1.1: ) -Entering state 11 -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Reading a token -Next token is token ')' (1.1: ) -Entering state 11 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 30 -Reading a token -Next token is token '+' (1.1: ) -Reducing stack 0 by rule 7 (line 98): - $1 = nterm exp (1.1: 1111) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 2222) -Entering state 8 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '*' (1.1: ) -syntax error -Shifting token error (1.1: ) -Entering state 11 -Next token is token '*' (1.1: ) -Error: discarding token '*' (1.1: ) -Reading a token -Next token is token ')' (1.1: ) -Entering state 11 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 30 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack 0 by rule 7 (line 98): - $1 = nterm exp (1.1: 2222) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 3333) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 77): - $1 = nterm exp (1.1: 3333) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) -./calc.at:1411: $PREPARSER ./calc input +Next token is token "number" (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token "number" (1.3: 2) +./calc.at:1403: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: +./calc.at:1409: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -106750,7 +108600,11 @@ Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) +525. calc.at:1433: testing Calculator C++ %locations $NO_EXCEPTIONS_CXXFLAGS ... +./calc.at:1403: cat stderr stderr: +./calc.at:1433: mv calc.y.tmp calc.y + Starting parse Entering state 0 Reading a token @@ -106758,234 +108612,56 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) -Entering state 8 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Reading a token -Next token is token "number" (1.7: 1) -Shifting token "number" (1.7: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 21 -Reading a token -Next token is token "number" (1.11: 1) -Shifting token "number" (1.11: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.11: 1) --> $$ = nterm exp (1.11: 1) -Entering state 30 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Reading a token -Next token is token "number" (1.15: 1) -Shifting token "number" (1.15: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 30 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 21 -Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Error: popping nterm exp (1.7-15: 3) -Shifting token error (1.7-18: ) -Entering state 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) -Entering state 30 -Reading a token -Next token is token '+' (1.20: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) -Entering state 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) -Entering state 21 -Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) +Error: discarding token '+' (1.4: ) Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) +Next token is token "number" (1.6: 1) +Error: discarding token "number" (1.6: 1) Reading a token -Next token is token ')' (1.28: ) +Next token is token ')' (1.7: ) Entering state 11 -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 30 -Reading a token -Next token is token '+' (1.30: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) -Entering state 21 -Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) -Entering state 4 -Reading a token -Next token is token "number" (1.33: 1) -Shifting token "number" (1.33: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 22 -Reading a token -Next token is token "number" (1.37: 2) -Shifting token "number" (1.37: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 31 -Reading a token -Next token is token '*' (1.39: ) -Reducing stack 0 by rule 9 (line 101): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) -Entering state 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 22 -Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Error: popping nterm exp (1.33-37: 2) -Shifting token error (1.33-41: ) -Entering state 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Reading a token -Next token is token ')' (1.42: ) -Entering state 11 -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) -Entering state 30 Reading a token -Next token is token '=' (1.44: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) -Entering state 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 19 Reading a token -Next token is token "number" (1.46: 1) -Shifting token "number" (1.46: 1) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.46: 1) --> $$ = nterm exp (1.46: 1) + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token -Next token is token '\n' (1.47-2.0: ) +Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): @@ -106998,7 +108674,8 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1413: "$PERL" -pi -e 'use strict; +./calc.at:1409: cat stderr +./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -107008,8 +108685,17 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1409: "$PERL" -pi -e 'use strict; +./calc.at:1416: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -107019,8 +108705,22 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1433: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +stderr: +stdout: +input: +./calc.at:1408: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -107032,287 +108732,21 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token "number" (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token "number" (1.3: 2) -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 21 Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Reading a token -Next token is token "number" (1.7: 1) -Shifting token "number" (1.7: 1) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 21 -Reading a token -Next token is token "number" (1.11: 1) -Shifting token "number" (1.11: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.11: 1) --> $$ = nterm exp (1.11: 1) -Entering state 30 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Reading a token -Next token is token "number" (1.15: 1) -Shifting token "number" (1.15: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 30 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 21 -Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Error: popping nterm exp (1.7-15: 3) -Shifting token error (1.7-18: ) -Entering state 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) -Entering state 30 -Reading a token -Next token is token '+' (1.20: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) -Entering state 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) -Entering state 21 -Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) -Reading a token -Next token is token ')' (1.28: ) -Entering state 11 -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 30 -Reading a token -Next token is token '+' (1.30: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) -Entering state 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) -Entering state 21 -Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) -Entering state 4 -Reading a token -Next token is token "number" (1.33: 1) -Shifting token "number" (1.33: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 22 -Reading a token -Next token is token "number" (1.37: 2) -Shifting token "number" (1.37: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 31 -Reading a token -Next token is token '*' (1.39: ) -Reducing stack 0 by rule 9 (line 101): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) -Entering state 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 22 -Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Error: popping nterm exp (1.33-37: 2) -Shifting token error (1.33-41: ) -Entering state 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Reading a token -Next token is token ')' (1.42: ) -Entering state 11 -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) -Entering state 30 -Reading a token -Next token is token '=' (1.44: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) -Entering state 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) -Entering state 19 -Reading a token -Next token is token "number" (1.46: 1) -Shifting token "number" (1.46: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.46: 1) --> $$ = nterm exp (1.46: 1) -Entering state 28 -Reading a token -Next token is token '\n' (1.47-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) -Entering state 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1413: cat stderr -./calc.at:1409: cat stderr -stderr: -input: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) @@ -107586,7 +109020,8 @@ Shifting token ')' (5.4: ) Entering state 27 Reducing stack 0 by rule 13 (line 113): - $1 = token '(' (5.1: ) + $1 = token '('513. calc.at:1403: ok + (5.1: ) $2 = nterm exp (5.2-3: -1) $3 = token ')' (5.4: ) -> $$ = nterm exp (5.1-4: -1) @@ -108123,212 +109558,26 @@ Entering state 17 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) - | error -./calc.at:1413: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" (1.1: ) -./calc.at:1408: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | 1 2 -./calc.at:1414: $PREPARSER ./calc input -stderr: -./calc.at:1407: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1411: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token "number" (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token "number" (1.3: 2) -input: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token "number" (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token "number" (1.3: 2) - | (!!) + (1 2) = 1 +./calc.at:1411: cat stderr +./calc.at:1413: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.c calc.h + + | (#) + (#) = 2222 +./calc.at:1416: cat stderr ./calc.at:1409: $PREPARSER ./calc input -./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1407: cat stderr +input: stderr: -./calc.at:1416: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1411: cat stderr -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 16 -Reducing stack 0 by rule 16 (line 128): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Shifting token error (1.2-3: ) -Entering state 11 -Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) -Entering state 21 -Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) -Entering state 4 -Reading a token -Next token is token "number" (1.9: 1) -Shifting token "number" (1.9: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 1) --> $$ = nterm exp (1.9: 1) -Entering state 12 -Reading a token -Next token is token "number" (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Shifting token error (1.9-11: ) -Entering state 11 -Next token is token "number" (1.11: 2) -Error: discarding token "number" (1.11: 2) -Reading a token -Next token is token ')' (1.12: ) -Entering state 11 -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) -Entering state 30 -Reading a token -Next token is token '=' (1.14: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) -Entering state 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) -Entering state 19 -Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 28 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1408: cat stderr -./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: + | 1 2 Starting parse Entering state 0 Reading a token @@ -108336,90 +109585,76 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 16 -Reducing stack 0 by rule 16 (line 128): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Shifting token error (1.2-3: ) +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) +Next token is token ')' (1.3: ) +Entering state 11 +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) Entering state 21 Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) Entering state 4 Reading a token -Next token is token "number" (1.9: 1) -Shifting token "number" (1.9: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 1) --> $$ = nterm exp (1.9: 1) -Entering state 12 -Reading a token -Next token is token "number" (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Shifting token error (1.9-11: ) +1.8: syntax error: invalid character: '#' +Next token is token error (1.8: ) +Shifting token error (1.8: ) Entering state 11 -Next token is token "number" (1.11: 2) -Error: discarding token "number" (1.11: 2) +Next token is token error (1.8: ) +Error: discarding token error (1.8: ) Reading a token -Next token is token ')' (1.12: ) +Next token is token ')' (1.9: ) Entering state 11 -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) Entering state 30 Reading a token -Next token is token '=' (1.14: ) +Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) Entering state 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) Entering state 19 Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) +Next token is token "number" (1.13-16: 2222) +Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) + $1 = token "number" (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) -> $$ = nterm exp (1.1-16: 2222) Entering state 8 Next token is token '\n' (1.17-2.0: ) @@ -108441,8 +109676,30 @@ Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: +./calc.at:1414: $PREPARSER ./calc input +./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +input: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 | (- *) + (1 2) = 1 stderr: +./calc.at:1411: $PREPARSER ./calc input + | 1//2 +./calc.at:1413: $PREPARSER ./calc input +./calc.at:1416: $PREPARSER ./calc input +input: Starting parse Entering state 0 Reading a token @@ -108458,21 +109715,10 @@ 1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token "number" (1.3: 2) -./calc.at:1416: cat stderr -./calc.at:1408: $PREPARSER ./calc input stderr: stderr: -./calc.at:1409: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1407: cat stderr +stderr: +input: Starting parse Entering state 0 Reading a token @@ -108488,7 +109734,7 @@ 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 -Reducing stack 0 by rule 15 (line 127): +Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) @@ -108501,7 +109747,7 @@ Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) @@ -108537,7 +109783,7 @@ Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) @@ -108545,7 +109791,7 @@ Entering state 30 Reading a token Next token is token '=' (1.15: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) @@ -108589,117 +109835,971 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" (1.1: ) -input: - | (!!) + (1 2) = 1 -./calc.at:1411: $PREPARSER ./calc input -input: -./calc.at:1409: cat stderr -stderr: -input: - | 1//2 -./calc.at:1414: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1416: $PREPARSER ./calc input - | 1 + 2 * 3 + !+ ++ -./calc.at:1407: $PREPARSER ./calc input -./calc.at:1413: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 stderr: -input: +./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 -Reducing stack 0 by rule 5 (line 81): +Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 21 Reading a token -Next token is token "number" (1.1: 2) -Shifting token "number" (1.1: 2) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 2) --> $$ = nterm exp (1.1: 2) +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token -Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) Entering state 22 Reading a token -Next token is token "number" (1.1: 3) -Shifting token "number" (1.1: 3) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 3) --> $$ = nterm exp (1.1: 3) +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) Entering state 31 Reading a token -Next token is token '+' (1.1: ) -Reducing stack 0 by rule 9 (line 100): - $1 = nterm exp (1.1: 2) - $2 = token '*' (1.1: ) - $3 = nterm exp (1.1: 3) --> $$ = nterm exp (1.1: 6) +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 9 (line 101): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) Entering state 30 -Next token is token '+' (1.1: ) -Reducing stack 0 by rule 7 (line 98): +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 6) --> $$ = nterm exp (1.1: 7) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 19 +Reading a token +Next token is token "number" (1.13: 7) +Shifting token "number" (1.13: 7) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.13: 7) +-> $$ = nterm exp (1.13: 7) +Entering state 28 +Reading a token +Next token is token '\n' (1.14-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-9: 7) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13: 7) +-> $$ = nterm exp (1.1-13: 7) +Entering state 8 +Next token is token '\n' (1.14-2.0: ) +Shifting token '\n' (1.14-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-13: 7) + $2 = token '\n' (1.14-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Next token is token "number" (2.1: 1) +Shifting token "number" (2.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (2.1: 1) +-> $$ = nterm exp (2.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (2.3: ) +Shifting token '+' (2.3: ) Entering state 21 Reading a token -Next token is token '!' (1.1: ) -Shifting token '!' (1.1: ) -Entering state 5 +Next token is token "number" (2.5: 2) +Shifting token "number" (2.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (2.5: 2) +-> $$ = nterm exp (2.5: 2) +Entering state 30 Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 14 -Reducing stack 0 by rule 17 (line 122): - $1 = token '!' (1.1: ) - $2 = token '+' (1.1: ) -Cleanup: popping token '+' (1.1: ) -Cleanup: popping nterm exp (1.1: 7) -./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (- *) + (1 2) = 1 -./calc.at:1409: $PREPARSER ./calc input -stderr: -stderr: +Next token is token '*' (2.7: ) +Shifting token '*' (2.7: ) +Entering state 22 +Reading a token +Next token is token '-' (2.9: ) +Shifting token '-' (2.9: ) +Entering state 2 +Reading a token +Next token is token "number" (2.10: 3) +Shifting token "number" (2.10: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (2.10: 3) +-> $$ = nterm exp (2.10: 3) +Entering state 10 +Reading a token +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (2.9: ) + $2 = nterm exp (2.10: 3) +-> $$ = nterm exp (2.9-10: -3) +Entering state 31 +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 9 (line 101): + $1 = nterm exp (2.5: 2) + $2 = token '*' (2.7: ) + $3 = nterm exp (2.9-10: -3) +-> $$ = nterm exp (2.5-10: -6) +Entering state 30 +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (2.1: 1) + $2 = token '+' (2.3: ) + $3 = nterm exp (2.5-10: -6) +-> $$ = nterm exp (2.1-10: -5) +Entering state 8 +Next token is token '=' (2.12: ) +Shifting token '=' (2.12: ) +Entering state 19 +Reading a token +Next token is token '-' (2.14: ) +Shifting token '-' (2.14: ) +Entering state 2 +Reading a token +Next token is token "number" (2.15: 5) +Shifting token "number" (2.15: 5) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (2.15: 5) +-> $$ = nterm exp (2.15: 5) +Entering state 10 +Reading a token +Next token is token '\n' (2.16-3.0: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (2.14: ) + $2 = nterm exp (2.15: 5) +-> $$ = nterm exp (2.14-15: -5) +Entering state 28 +Next token is token '\n' (2.16-3.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (2.1-10: -5) + $2 = token '=' (2.12: ) + $3 = nterm exp (2.14-15: -5) +-> $$ = nterm exp (2.1-15: -5) +Entering state 8 +Next token is token '\n' (2.16-3.0: ) +Shifting token '\n' (2.16-3.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (2.1-15: -5) + $2 = token '\n' (2.16-3.0: ) +-> $$ = nterm line (2.1-3.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-2.0: ) + $2 = nterm line (2.1-3.0: ) +-> $$ = nterm input (1.1-3.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (3.1-4.0: ) +Shifting token '\n' (3.1-4.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 83): + $1 = token '\n' (3.1-4.0: ) +-> $$ = nterm line (3.1-4.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-3.0: ) + $2 = nterm line (3.1-4.0: ) +-> $$ = nterm input (1.1-4.0: ) +Entering state 6 +Reading a token +Next token is token '-' (4.1: ) +Shifting token '-' (4.1: ) +Entering state 2 +Reading a token +Next token is token "number" (4.2: 1) +Shifting token "number" (4.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (4.2: 1) +-> $$ = nterm exp (4.2: 1) +Entering state 10 +Reading a token +Next token is token '^' (4.3: ) +Shifting token '^' (4.3: ) +Entering state 24 +Reading a token +Next token is token "number" (4.4: 2) +Shifting token "number" (4.4: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (4.4: 2) +-> $$ = nterm exp (4.4: 2) +Entering state 33 +Reading a token +Next token is token '=' (4.6: ) +Reducing stack 0 by rule 12 (line 112): + $1 = nterm exp (4.2: 1) + $2 = token '^' (4.3: ) + $3 = nterm exp (4.4: 2) +-> $$ = nterm exp (4.2-4: 1) +Entering state 10 +Next token is token '=' (4.6: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (4.1: ) + $2 = nterm exp (4.2-4: 1) +-> $$ = nterm exp (4.1-4: -1) +Entering state 8 +Next token is token '=' (4.6: ) +Shifting token '=' (4.6: ) +Entering state 19 +Reading a token +Next token is token '-' (4.8: ) +Shifting token '-' (4.8: ) +Entering state 2 +Reading a token +Next token is token "number" (4.9: 1) +Shifting token "number" (4.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (4.9: 1) +-> $$ = nterm exp (4.9: 1) +Entering state 10 +Reading a token +Next token is token '\n' (4.10-5.0: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (4.8: ) + $2 = nterm exp (4.9: 1) +-> $$ = nterm exp (4.8-9: -1) +Entering state 28 +Next token is token '\n' (4.10-5.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (4.1-4: -1) + $2 = token '=' (4.6: ) + $3 = nterm exp (4.8-9: -1) +-> $$ = nterm exp (4.1-9: -1) +Entering state 8 +Next token is token '\n' (4.10-5.0: ) +Shifting token '\n' (4.10-5.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (4.1-9: -1) + $2 = token '\n' (4.10-5.0: ) +-> $$ = nterm line (4.1-5.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-4.0: ) + $2 = nterm line (4.1-5.0: ) +-> $$ = nterm input (1.1-5.0: ) +Entering state 6 +Reading a token +Next token is token '(' (5.1: ) +Shifting token '(' (5.1: ) +Entering state 4 +Reading a token +Next token is token '-' (5.2: ) +Shifting token '-' (5.2: ) +Entering state 2 +Reading a token +Next token is token "number" (5.3: 1) +Shifting token "number" (5.3: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (5.3: 1) +-> $$ = nterm exp (5.3: 1) +Entering state 10 +Reading a token +Next token is token ')' (5.4: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (5.2: ) + $2 = nterm exp (5.3: 1) +-> $$ = nterm exp (5.2-3: -1) +Entering state 12 +Next token is token ')' (5.4: ) +Shifting token ')' (5.4: ) +Entering state 27 +Reducing stack 0 by rule 13 (line 113): + $1 = token '(' (5.1: ) + $2 = nterm exp (5.2-3: -1) + $3 = token ')' (5.4: ) +-> $$ = nterm exp (5.1-4: -1) +Entering state 8 +Reading a token +Next token is token '^' (5.5: ) +Shifting token '^' (5.5: ) +Entering state 24 +Reading a token +Next token is token "number" (5.6: 2) +Shifting token "number" (5.6: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (5.6: 2) +-> $$ = nterm exp (5.6: 2) +Entering state 33 +Reading a token +Next token is token '=' (5.8: ) +Reducing stack 0 by rule 12 (line 112): + $1 = nterm exp (5.1-4: -1) + $2 = token '^' (5.5: ) + $3 = nterm exp (5.6: 2) +-> $$ = nterm exp (5.1-6: 1) +Entering state 8 +Next token is token '=' (5.8: ) +Shifting token '=' (5.8: ) +Entering state 19 +Reading a token +Next token is token "number" (5.10: 1) +Shifting token "number" (5.10: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (5.10: 1) +-> $$ = nterm exp (5.10: 1) +Entering state 28 +Reading a token +Next token is token '\n' (5.11-6.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (5.1-6: 1) + $2 = token '=' (5.8: ) + $3 = nterm exp (5.10: 1) +-> $$ = nterm exp (5.1-10: 1) +Entering state 8 +Next token is token '\n' (5.11-6.0: ) +Shifting token '\n' (5.11-6.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (5.1-10: 1) + $2 = token '\n' (5.11-6.0: ) +-> $$ = nterm line (5.1-6.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-5.0: ) + $2 = nterm line (5.1-6.0: ) +-> $$ = nterm input (1.1-6.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (6.1-7.0: ) +Shifting token '\n' (6.1-7.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 83): + $1 = token '\n' (6.1-7.0: ) +-> $$ = nterm line (6.1-7.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-6.0: ) + $2 = nterm line (6.1-7.0: ) +-> $$ = nterm input (1.1-7.0: ) +Entering state 6 +Reading a token +Next token is token '-' (7.1: ) +Shifting token '-' (7.1: ) +Entering state 2 +Reading a token +Next token is token '-' (7.2: ) +Shifting token '-' (7.2: ) +Entering state 2 +Reading a token +Next token is token '-' (7.3: ) +Shifting token '-' (7.3: ) +Entering state 2 +Reading a token +Next token is token "number" (7.4: 1) +Shifting token "number" (7.4: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (7.4: 1) +-> $$ = nterm exp (7.4: 1) +Entering state 10 +Reading a token +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (7.3: ) + $2 = nterm exp (7.4: 1) +-> $$ = nterm exp (7.3-4: -1) +Entering state 10 +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (7.2: ) + $2 = nterm exp (7.3-4: -1) +-> $$ = nterm exp (7.2-4: 1) +Entering state 10 +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (7.1: ) + $2 = nterm exp (7.2-4: 1) +-> $$ = nterm exp (7.1-4: -1) +Entering state 8 +Next token is token '=' (7.6: ) +Shifting token '=' (7.6: ) +Entering state 19 +Reading a token +Next token is token '-' (7.8: ) +Shifting token '-' (7.8: ) +Entering state 2 +Reading a token +Next token is token "number" (7.9: 1) +Shifting token "number" (7.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (7.9: 1) +-> $$ = nterm exp (7.9: 1) +Entering state 10 +Reading a token +Next token is token '\n' (7.10-8.0: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (7.8: ) + $2 = nterm exp (7.9: 1) +-> $$ = nterm exp (7.8-9: -1) +Entering state 28 +Next token is token '\n' (7.10-8.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (7.1-4: -1) + $2 = token '=' (7.6: ) + $3 = nterm exp (7.8-9: -1) +-> $$ = nterm exp (7.1-9: -1) +Entering state 8 +Next token is token '\n' (7.10-8.0: ) +Shifting token '\n' (7.10-8.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (7.1-9: -1) + $2 = token '\n' (7.10-8.0: ) +-> $$ = nterm line (7.1-8.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-7.0: ) + $2 = nterm line (7.1-8.0: ) +-> $$ = nterm input (1.1-8.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (8.1-9.0: ) +Shifting token '\n' (8.1-9.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 83): + $1 = token '\n' (8.1-9.0: ) +-> $$ = nterm line (8.1-9.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-8.0: ) + $2 = nterm line (8.1-9.0: ) +-> $$ = nterm input (1.1-9.0: ) +Entering state 6 +Reading a token +Next token is token "number" (9.1: 1) +Shifting token "number" (9.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (9.1: 1) +-> $$ = nterm exp (9.1: 1) +Entering state 8 +Reading a token +Next token is token '-' (9.3: ) +Shifting token '-' (9.3: ) +Entering state 20 +Reading a token +Next token is token "number" (9.5: 2) +Shifting token "number" (9.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (9.5: 2) +-> $$ = nterm exp (9.5: 2) +Entering state 29 +Reading a token +Next token is token '-' (9.7: ) +Reducing stack 0 by rule 8 (line 100): + $1 = nterm exp (9.1: 1) + $2 = token '-' (9.3: ) + $3 = nterm exp (9.5: 2) +-> $$ = nterm exp (9.1-5: -1) +Entering state 8 +Next token is token '-' (9.7: ) +Shifting token '-' (9.7: ) +Entering state 20 +Reading a token +Next token is token "number" (9.9: 3) +Shifting token "number" (9.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (9.9: 3) +-> $$ = nterm exp (9.9: 3) +Entering state 29 +Reading a token +Next token is token '=' (9.11: ) +Reducing stack 0 by rule 8 (line 100): + $1 = nterm exp (9.1-5: -1) + $2 = token '-' (9.7: ) + $3 = nterm exp (9.9: 3) +-> $$ = nterm exp (9.1-9: -4) +Entering state 8 +Next token is token '=' (9.11: ) +Shifting token '=' (9.11: ) +Entering state 19 +Reading a token +Next token is token '-' (9.13: ) +Shifting token '-' (9.13: ) +Entering state 2 +Reading a token +Next token is token "number" (9.14: 4) +Shifting token "number" (9.14: 4) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (9.14: 4) +-> $$ = nterm exp (9.14: 4) +Entering state 10 +Reading a token +Next token is token '\n' (9.15-10.0: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (9.13: ) + $2 = nterm exp (9.14: 4) +-> $$ = nterm exp (9.13-14: -4) +Entering state 28 +Next token is token '\n' (9.15-10.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (9.1-9: -4) + $2 = token '=' (9.11: ) + $3 = nterm exp (9.13-14: -4) +-> $$ = nterm exp (9.1-14: -4) +Entering state 8 +Next token is token '\n' (9.15-10.0: ) +Shifting token '\n' (9.15-10.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (9.1-14: -4) + $2 = token '\n' (9.15-10.0: ) +-> $$ = nterm line (9.1-10.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-9.0: ) + $2 = nterm line (9.1-10.0: ) +-> $$ = nterm input (1.1-10.0: ) +Entering state 6 +Reading a token +Next token is token "number" (10.1: 1) +Shifting token "number" (10.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (10.1: 1) +-> $$ = nterm exp (10.1: 1) +Entering state 8 +Reading a token +Next token is token '-' (10.3: ) +Shifting token '-' (10.3: ) +Entering state 20 +Reading a token +Next token is token '(' (10.5: ) +Shifting token '(' (10.5: ) +Entering state 4 +Reading a token +Next token is token "number" (10.6: 2) +Shifting token "number" (10.6: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (10.6: 2) +-> $$ = nterm exp (10.6: 2) +Entering state 12 +Reading a token +Next token is token '-' (10.8: ) +Shifting token '-' (10.8: ) +Entering state 20 +Reading a token +Next token is token "number" (10.10: 3) +Shifting token "number" (10.10: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (10.10: 3) +-> $$ = nterm exp (10.10: 3) +Entering state 29 +Reading a token +Next token is token ')' (10.11: ) +Reducing stack 0 by rule 8 (line 100): + $1 = nterm exp (10.6: 2) + $2 = token '-' (10.8: ) + $3 = nterm exp (10.10: 3) +-> $$ = nterm exp (10.6-10: -1) +Entering state 12 +Next token is token ')' (10.11: ) +Shifting token ')' (10.11: ) +Entering state 27 +Reducing stack 0 by rule 13 (line 113): + $1 = token '(' (10.5: ) + $2 = nterm exp (10.6-10: -1) + $3 = token ')' (10.11: ) +-> $$ = nterm exp (10.5-11: -1) +Entering state 29 +Reading a token +Next token is token '=' (10.13: ) +Reducing stack 0 by rule 8 (line 100): + $1 = nterm exp (10.1: 1) + $2 = token '-' (10.3: ) + $3 = nterm exp (10.5-11: -1) +-> $$ = nterm exp (10.1-11: 2) +Entering state 8 +Next token is token '=' (10.13: ) +Shifting token '=' (10.13: ) +Entering state 19 +Reading a token +Next token is token "number" (10.15: 2) +Shifting token "number" (10.15: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (10.15: 2) +-> $$ = nterm exp (10.15: 2) +Entering state 28 +Reading a token +Next token is token '\n' (10.16-11.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (10.1-11: 2) + $2 = token '=' (10.13: ) + $3 = nterm exp (10.15: 2) +-> $$ = nterm exp (10.1-15: 2) +Entering state 8 +Next token is token '\n' (10.16-11.0: ) +Shifting token '\n' (10.16-11.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (10.1-15: 2) + $2 = token '\n' (10.16-11.0: ) +-> $$ = nterm line (10.1-11.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-10.0: ) + $2 = nterm line (10.1-11.0: ) +-> $$ = nterm input (1.1-11.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (11.1-12.0: ) +Shifting token '\n' (11.1-12.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 83): + $1 = token '\n' (11.1-12.0: ) +-> $$ = nterm line (11.1-12.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-11.0: ) + $2 = nterm line (11.1-12.0: ) +-> $$ = nterm input (1.1-12.0: ) +Entering state 6 +Reading a token +Next token is token "number" (12.1: 2) +Shifting token "number" (12.1: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (12.1: 2) +-> $$ = nterm exp (12.1: 2) +Entering state 8 +Reading a token +Next token is token '^' (12.2: ) +Shifting token '^' (12.2: ) +Entering state 24 +Reading a token +Next token is token "number" (12.3: 2) +Shifting token "number" (12.3: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (12.3: 2) +-> $$ = nterm exp (12.3: 2) +Entering state 33 +Reading a token +Next token is token '^' (12.4: ) +Shifting token '^' (12.4: ) +Entering state 24 +Reading a token +Next token is token "number" (12.5: 3) +Shifting token "number" (12.5: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (12.5: 3) +-> $$ = nterm exp (12.5: 3) +Entering state 33 +Reading a token +Next token is token '=' (12.7: ) +Reducing stack 0 by rule 12 (line 112): + $1 = nterm exp (12.3: 2) + $2 = token '^' (12.4: ) + $3 = nterm exp (12.5: 3) +-> $$ = nterm exp (12.3-5: 8) +Entering state 33 +Next token is token '=' (12.7: ) +Reducing stack 0 by rule 12 (line 112): + $1 = nterm exp (12.1: 2) + $2 = token '^' (12.2: ) + $3 = nterm exp (12.3-5: 8) +-> $$ = nterm exp (12.1-5: 256) +Entering state 8 +Next token is token '=' (12.7: ) +Shifting token '=' (12.7: ) +Entering state 19 +Reading a token +Next token is token "number" (12.9-11: 256) +Shifting token "number" (12.9-11: 256) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (12.9-11: 256) +-> $$ = nterm exp (12.9-11: 256) +Entering state 28 +Reading a token +Next token is token '\n' (12.12-13.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (12.1-5: 256) + $2 = token '=' (12.7: ) + $3 = nterm exp (12.9-11: 256) +-> $$ = nterm exp (12.1-11: 256) +Entering state 8 +Next token is token '\n' (12.12-13.0: ) +Shifting token '\n' (12.12-13.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (12.1-11: 256) + $2 = token '\n' (12.12-13.0: ) +-> $$ = nterm line (12.1-13.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-12.0: ) + $2 = nterm line (12.1-13.0: ) +-> $$ = nterm input (1.1-13.0: ) +Entering state 6 +Reading a token +Next token is token '(' (13.1: ) +Shifting token '(' (13.1: ) +Entering state 4 +Reading a token +Next token is token "number" (13.2: 2) +Shifting token "number" (13.2: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (13.2: 2) +-> $$ = nterm exp (13.2: 2) +Entering state 12 +Reading a token +Next token is token '^' (13.3: ) +Shifting token '^' (13.3: ) +Entering state 24 +Reading a token +Next token is token "number" (13.4: 2) +Shifting token "number" (13.4: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (13.4: 2) +-> $$ = nterm exp (13.4: 2) +Entering state 33 +Reading a token +Next token is token ')' (13.5: ) +Reducing stack 0 by rule 12 (line 112): + $1 = nterm exp (13.2: 2) + $2 = token '^' (13.3: ) + $3 = nterm exp (13.4: 2) +-> $$ = nterm exp (13.2-4: 4) +Entering state 12 +Next token is token ')' (13.5: ) +Shifting token ')' (13.5: ) +Entering state 27 +Reducing stack 0 by rule 13 (line 113): + $1 = token '(' (13.1: ) + $2 = nterm exp (13.2-4: 4) + $3 = token ')' (13.5: ) +-> $$ = nterm exp (13.1-5: 4) +Entering state 8 +Reading a token +Next token is token '^' (13.6: ) +Shifting token '^' (13.6: ) +Entering state 24 +Reading a token +Next token is token "number" (13.7: 3) +Shifting token "number" (13.7: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (13.7: 3) +-> $$ = nterm exp (13.7: 3) +Entering state 33 +Reading a token +Next token is token '=' (13.9: ) +Reducing stack 0 by rule 12 (line 112): + $1 = nterm exp (13.1-5: 4) + $2 = token '^' (13.6: ) + $3 = nterm exp (13.7: 3) +-> $$ = nterm exp (13.1-7: 64) +Entering state 8 +Next token is token '=' (13.9: ) +Shifting token '=' (13.9: ) +Entering state 19 +Reading a token +Next token is token "number" (13.11-12: 64) +Shifting token "number" (13.11-12: 64) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (13.11-12: 64) +-> $$ = nterm exp (13.11-12: 64) +Entering state 28 +Reading a token +Next token is token '\n' (13.13-14.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (13.1-7: 64) + $2 = token '=' (13.9: ) + $3 = nterm exp (13.11-12: 64) +-> $$ = nterm exp (13.1-12: 64) +Entering state 8 +Next token is token '\n' (13.13-14.0: ) +Shifting token '\n' (13.13-14.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (13.1-12: 64) + $2 = token '\n' (13.13-14.0: ) +-> $$ = nterm line (13.1-14.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-13.0: ) + $2 = nterm line (13.1-14.0: ) +-> $$ = nterm input (1.1-14.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (14.1: ) +Entering state 17 +Cleanup: popping token "end of input" (14.1: ) +Cleanup: popping nterm input (1.1-14.0: ) +./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) +Reading a token +Next token is token ')' (1.3: ) +Entering state 11 +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) +Entering state 21 +Reading a token +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Reading a token +1.8: syntax error: invalid character: '#' +Next token is token error (1.8: ) +Shifting token error (1.8: ) +Entering state 11 +Next token is token error (1.8: ) +Error: discarding token error (1.8: ) +Reading a token +Next token is token ')' (1.9: ) +Entering state 11 +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 30 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) +Entering state 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 19 +Reading a token +Next token is token "number" (1.13-16: 2222) +Shifting token "number" (1.13-16: 2222) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) +Entering state 28 +Reading a token +Next token is token '\n' (1.17-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '/' (1.3: ) + | 1 + 2 * 3 + !* ++ +./calc.at:1407: $PREPARSER ./calc input +./calc.at:1433: $CXX $CPPFLAGS $CXXFLAGS $NO_EXCEPTIONS_CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS + | (1 + # + 1) = 1111 stderr: + +./calc.at:1408: $PREPARSER ./calc input +./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -108757,15 +110857,19 @@ Shifting token '!' (1.1: ) Entering state 5 Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 14 -Reducing stack 0 by rule 17 (line 122): +Next token is token '*' (1.1: ) +Shifting token '*' (1.1: ) +Entering state 15 +Reducing stack 0 by rule 19 (line 124): $1 = token '!' (1.1: ) - $2 = token '+' (1.1: ) + $2 = token '*' (1.1: ) +memory exhausted Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) -./calc.at:1414: cat stderr +./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +stderr: Starting parse Entering state 0 Reading a token @@ -108773,98 +110877,70 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 16 -Reducing stack 0 by rule 16 (line 116): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Shifting token error (1.2-3: ) -Entering state 11 -Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) -Entering state 21 -Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) -Entering state 4 -Reading a token -Next token is token "number" (1.9: 1) -Shifting token "number" (1.9: 1) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 1) --> $$ = nterm exp (1.9: 1) + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token -Next token is token "number" (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Shifting token error (1.9-11: ) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) Entering state 11 -Next token is token "number" (1.11: 2) -Error: discarding token "number" (1.11: 2) +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) Reading a token -Next token is token ')' (1.12: ) +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Reading a token +Next token is token "number" (1.10: 1) +Error: discarding token "number" (1.10: 1) +Reading a token +Next token is token ')' (1.11: ) Entering state 11 -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) -Entering state 30 -Reading a token -Next token is token '=' (1.14: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) Entering state 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) +Reading a token +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) Entering state 19 Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) +Next token is token "number" (1.15-18: 1111) +Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) + $1 = token "number" (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token -Next token is token '\n' (1.17-2.0: ) +Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): @@ -108878,7 +110954,8 @@ Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: -input: +./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: Starting parse Entering state 0 Reading a token @@ -108894,7 +110971,7 @@ 1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error (1.4: ) Entering state 9 -Reducing stack 0 by rule 15 (line 127): +Reducing stack 0 by rule 15 (line 115): $1 = token '-' (1.2: ) $2 = token error (1.4: ) Shifting token error (1.2-4: ) @@ -108907,7 +110984,7 @@ Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) @@ -108943,7 +111020,7 @@ Next token is token ')' (1.13: ) Shifting token ')' (1.13: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10-12: ) $3 = token ')' (1.13: ) @@ -108951,7 +111028,7 @@ Entering state 30 Reading a token Next token is token '=' (1.15: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-13: 1111) @@ -108998,107 +111075,112 @@ Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Reducing stack 0 by rule 15 (line 127): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Shifting token error (1.2-4: ) -Entering state 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) +Next token is token "number" (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token "number" (1.3: 2) +Starting parse +Entering state 0 Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 21 +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '/' (1.3: ) +Starting parse +Entering state 0 Reading a token -Next token is token "number" (1.10: 1) -Shifting token "number" (1.10: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 Reading a token -Next token is token "number" (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Shifting token error (1.10-12: ) -Entering state 11 -Next token is token "number" (1.12: 2) -Error: discarding token "number" (1.12: 2) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 Reading a token -Next token is token ')' (1.13: ) -Entering state 11 -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token -Next token is token '=' (1.15: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Reading a token +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 9 (line 101): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) Entering state 19 Reading a token -Next token is token "number" (1.17: 1) -Shifting token "number" (1.17: 1) +Next token is token "number" (1.13: 7) +Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.17: 1) --> $$ = nterm exp (1.17: 1) + $1 = token "number" (1.13: 7) +-> $$ = nterm exp (1.13: 7) Entering state 28 Reading a token -Next token is token '\n' (1.18-2.0: ) +Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) + $1 = nterm exp (1.1-9: 7) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13: 7) +-> $$ = nterm exp (1.1-13: 7) Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.14-2.0: ) +Shifting token '\n' (1.14-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-13: 7) + $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): @@ -109106,221 +111188,764 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 +Next token is token "number" (2.1: 1) +Shifting token "number" (2.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (2.1: 1) +-> $$ = nterm exp (2.1: 1) +Entering state 8 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token '+' (2.3: ) +Shifting token '+' (2.3: ) +Entering state 21 +Reading a token +Next token is token "number" (2.5: 2) +Shifting token "number" (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) + $1 = token "number" (2.5: 2) +-> $$ = nterm exp (2.5: 2) +Entering state 30 +Reading a token +Next token is token '*' (2.7: ) +Shifting token '*' (2.7: ) +Entering state 22 +Reading a token +Next token is token '-' (2.9: ) +Shifting token '-' (2.9: ) +Entering state 2 +Reading a token +Next token is token "number" (2.10: 3) +Shifting token "number" (2.10: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (2.10: 3) +-> $$ = nterm exp (2.10: 3) +Entering state 10 +Reading a token +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (2.9: ) + $2 = nterm exp (2.10: 3) +-> $$ = nterm exp (2.9-10: -3) +Entering state 31 +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 9 (line 101): + $1 = nterm exp (2.5: 2) + $2 = token '*' (2.7: ) + $3 = nterm exp (2.9-10: -3) +-> $$ = nterm exp (2.5-10: -6) +Entering state 30 +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (2.1: 1) + $2 = token '+' (2.3: ) + $3 = nterm exp (2.5-10: -6) +-> $$ = nterm exp (2.1-10: -5) Entering state 8 +Next token is token '=' (2.12: ) +Shifting token '=' (2.12: ) +Entering state 19 Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 +Next token is token '-' (2.14: ) +Shifting token '-' (2.14: ) +Entering state 2 Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.3: ) - | 1 + 2 * 3 + !- ++ -./calc.at:1407: $PREPARSER ./calc input -stderr: -stderr: -Starting parse -Entering state 0 +Next token is token "number" (2.15: 5) +Shifting token "number" (2.15: 5) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (2.15: 5) +-> $$ = nterm exp (2.15: 5) +Entering state 10 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) +Next token is token '\n' (2.16-3.0: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (2.14: ) + $2 = nterm exp (2.15: 5) +-> $$ = nterm exp (2.14-15: -5) +Entering state 28 +Next token is token '\n' (2.16-3.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (2.1-10: -5) + $2 = token '=' (2.12: ) + $3 = nterm exp (2.14-15: -5) +-> $$ = nterm exp (2.1-15: -5) +Entering state 8 +Next token is token '\n' (2.16-3.0: ) +Shifting token '\n' (2.16-3.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (2.1-15: -5) + $2 = token '\n' (2.16-3.0: ) +-> $$ = nterm line (2.1-3.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-2.0: ) + $2 = nterm line (2.1-3.0: ) +-> $$ = nterm input (1.1-3.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (3.1-4.0: ) +Shifting token '\n' (3.1-4.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 83): + $1 = token '\n' (3.1-4.0: ) +-> $$ = nterm line (3.1-4.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-3.0: ) + $2 = nterm line (3.1-4.0: ) +-> $$ = nterm input (1.1-4.0: ) +Entering state 6 +Reading a token +Next token is token '-' (4.1: ) +Shifting token '-' (4.1: ) +Entering state 2 +Reading a token +Next token is token "number" (4.2: 1) +Shifting token "number" (4.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (4.2: 1) +-> $$ = nterm exp (4.2: 1) +Entering state 10 +Reading a token +Next token is token '^' (4.3: ) +Shifting token '^' (4.3: ) +Entering state 24 +Reading a token +Next token is token "number" (4.4: 2) +Shifting token "number" (4.4: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (4.4: 2) +-> $$ = nterm exp (4.4: 2) +Entering state 33 +Reading a token +Next token is token '=' (4.6: ) +Reducing stack 0 by rule 12 (line 112): + $1 = nterm exp (4.2: 1) + $2 = token '^' (4.3: ) + $3 = nterm exp (4.4: 2) +-> $$ = nterm exp (4.2-4: 1) +Entering state 10 +Next token is token '=' (4.6: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (4.1: ) + $2 = nterm exp (4.2-4: 1) +-> $$ = nterm exp (4.1-4: -1) +Entering state 8 +Next token is token '=' (4.6: ) +Shifting token '=' (4.6: ) +Entering state 19 +Reading a token +Next token is token '-' (4.8: ) +Shifting token '-' (4.8: ) +Entering state 2 +Reading a token +Next token is token "number" (4.9: 1) +Shifting token "number" (4.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (4.9: 1) +-> $$ = nterm exp (4.9: 1) +Entering state 10 +Reading a token +Next token is token '\n' (4.10-5.0: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (4.8: ) + $2 = nterm exp (4.9: 1) +-> $$ = nterm exp (4.8-9: -1) +Entering state 28 +Next token is token '\n' (4.10-5.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (4.1-4: -1) + $2 = token '=' (4.6: ) + $3 = nterm exp (4.8-9: -1) +-> $$ = nterm exp (4.1-9: -1) +Entering state 8 +Next token is token '\n' (4.10-5.0: ) +Shifting token '\n' (4.10-5.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (4.1-9: -1) + $2 = token '\n' (4.10-5.0: ) +-> $$ = nterm line (4.1-5.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-4.0: ) + $2 = nterm line (4.1-5.0: ) +-> $$ = nterm input (1.1-5.0: ) +Entering state 6 +Reading a token +Next token is token '(' (5.1: ) +Shifting token '(' (5.1: ) Entering state 4 Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) +Next token is token '-' (5.2: ) +Shifting token '-' (5.2: ) Entering state 2 Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Reducing stack 0 by rule 15 (line 127): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Shifting token error (1.2-4: ) -Entering state 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) +Next token is token "number" (5.3: 1) +Shifting token "number" (5.3: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (5.3: 1) +-> $$ = nterm exp (5.3: 1) +Entering state 10 Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) +Next token is token ')' (5.4: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (5.2: ) + $2 = nterm exp (5.3: 1) +-> $$ = nterm exp (5.2-3: -1) +Entering state 12 +Next token is token ')' (5.4: ) +Shifting token ')' (5.4: ) +Entering state 27 +Reducing stack 0 by rule 13 (line 113): + $1 = token '(' (5.1: ) + $2 = nterm exp (5.2-3: -1) + $3 = token ')' (5.4: ) +-> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 21 +Next token is token '^' (5.5: ) +Shifting token '^' (5.5: ) +Entering state 24 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) +Next token is token "number" (5.6: 2) +Shifting token "number" (5.6: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (5.6: 2) +-> $$ = nterm exp (5.6: 2) +Entering state 33 +Reading a token +Next token is token '=' (5.8: ) +Reducing stack 0 by rule 12 (line 112): + $1 = nterm exp (5.1-4: -1) + $2 = token '^' (5.5: ) + $3 = nterm exp (5.6: 2) +-> $$ = nterm exp (5.1-6: 1) +Entering state 8 +Next token is token '=' (5.8: ) +Shifting token '=' (5.8: ) +Entering state 19 +Reading a token +Next token is token "number" (5.10: 1) +Shifting token "number" (5.10: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (5.10: 1) +-> $$ = nterm exp (5.10: 1) +Entering state 28 +Reading a token +Next token is token '\n' (5.11-6.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (5.1-6: 1) + $2 = token '=' (5.8: ) + $3 = nterm exp (5.10: 1) +-> $$ = nterm exp (5.1-10: 1) +Entering state 8 +Next token is token '\n' (5.11-6.0: ) +Shifting token '\n' (5.11-6.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (5.1-10: 1) + $2 = token '\n' (5.11-6.0: ) +-> $$ = nterm line (5.1-6.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-5.0: ) + $2 = nterm line (5.1-6.0: ) +-> $$ = nterm input (1.1-6.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (6.1-7.0: ) +Shifting token '\n' (6.1-7.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 83): + $1 = token '\n' (6.1-7.0: ) +-> $$ = nterm line (6.1-7.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-6.0: ) + $2 = nterm line (6.1-7.0: ) +-> $$ = nterm input (1.1-7.0: ) +Entering state 6 +Reading a token +Next token is token '-' (7.1: ) +Shifting token '-' (7.1: ) +Entering state 2 +Reading a token +Next token is token '-' (7.2: ) +Shifting token '-' (7.2: ) +Entering state 2 +Reading a token +Next token is token '-' (7.3: ) +Shifting token '-' (7.3: ) +Entering state 2 +Reading a token +Next token is token "number" (7.4: 1) +Shifting token "number" (7.4: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (7.4: 1) +-> $$ = nterm exp (7.4: 1) +Entering state 10 +Reading a token +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (7.3: ) + $2 = nterm exp (7.4: 1) +-> $$ = nterm exp (7.3-4: -1) +Entering state 10 +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (7.2: ) + $2 = nterm exp (7.3-4: -1) +-> $$ = nterm exp (7.2-4: 1) +Entering state 10 +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (7.1: ) + $2 = nterm exp (7.2-4: 1) +-> $$ = nterm exp (7.1-4: -1) +Entering state 8 +Next token is token '=' (7.6: ) +Shifting token '=' (7.6: ) +Entering state 19 +Reading a token +Next token is token '-' (7.8: ) +Shifting token '-' (7.8: ) +Entering state 2 +Reading a token +Next token is token "number" (7.9: 1) +Shifting token "number" (7.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (7.9: 1) +-> $$ = nterm exp (7.9: 1) +Entering state 10 +Reading a token +Next token is token '\n' (7.10-8.0: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (7.8: ) + $2 = nterm exp (7.9: 1) +-> $$ = nterm exp (7.8-9: -1) +Entering state 28 +Next token is token '\n' (7.10-8.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (7.1-4: -1) + $2 = token '=' (7.6: ) + $3 = nterm exp (7.8-9: -1) +-> $$ = nterm exp (7.1-9: -1) +Entering state 8 +Next token is token '\n' (7.10-8.0: ) +Shifting token '\n' (7.10-8.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (7.1-9: -1) + $2 = token '\n' (7.10-8.0: ) +-> $$ = nterm line (7.1-8.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-7.0: ) + $2 = nterm line (7.1-8.0: ) +-> $$ = nterm input (1.1-8.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (8.1-9.0: ) +Shifting token '\n' (8.1-9.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 83): + $1 = token '\n' (8.1-9.0: ) +-> $$ = nterm line (8.1-9.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-8.0: ) + $2 = nterm line (8.1-9.0: ) +-> $$ = nterm input (1.1-9.0: ) +Entering state 6 +Reading a token +Next token is token "number" (9.1: 1) +Shifting token "number" (9.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (9.1: 1) +-> $$ = nterm exp (9.1: 1) +Entering state 8 +Reading a token +Next token is token '-' (9.3: ) +Shifting token '-' (9.3: ) +Entering state 20 +Reading a token +Next token is token "number" (9.5: 2) +Shifting token "number" (9.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (9.5: 2) +-> $$ = nterm exp (9.5: 2) +Entering state 29 +Reading a token +Next token is token '-' (9.7: ) +Reducing stack 0 by rule 8 (line 100): + $1 = nterm exp (9.1: 1) + $2 = token '-' (9.3: ) + $3 = nterm exp (9.5: 2) +-> $$ = nterm exp (9.1-5: -1) +Entering state 8 +Next token is token '-' (9.7: ) +Shifting token '-' (9.7: ) +Entering state 20 +Reading a token +Next token is token "number" (9.9: 3) +Shifting token "number" (9.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (9.9: 3) +-> $$ = nterm exp (9.9: 3) +Entering state 29 +Reading a token +Next token is token '=' (9.11: ) +Reducing stack 0 by rule 8 (line 100): + $1 = nterm exp (9.1-5: -1) + $2 = token '-' (9.7: ) + $3 = nterm exp (9.9: 3) +-> $$ = nterm exp (9.1-9: -4) +Entering state 8 +Next token is token '=' (9.11: ) +Shifting token '=' (9.11: ) +Entering state 19 +Reading a token +Next token is token '-' (9.13: ) +Shifting token '-' (9.13: ) +Entering state 2 +Reading a token +Next token is token "number" (9.14: 4) +Shifting token "number" (9.14: 4) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (9.14: 4) +-> $$ = nterm exp (9.14: 4) +Entering state 10 +Reading a token +Next token is token '\n' (9.15-10.0: ) +Reducing stack 0 by rule 11 (line 111): + $1 = token '-' (9.13: ) + $2 = nterm exp (9.14: 4) +-> $$ = nterm exp (9.13-14: -4) +Entering state 28 +Next token is token '\n' (9.15-10.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (9.1-9: -4) + $2 = token '=' (9.11: ) + $3 = nterm exp (9.13-14: -4) +-> $$ = nterm exp (9.1-14: -4) +Entering state 8 +Next token is token '\n' (9.15-10.0: ) +Shifting token '\n' (9.15-10.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (9.1-14: -4) + $2 = token '\n' (9.15-10.0: ) +-> $$ = nterm line (9.1-10.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-9.0: ) + $2 = nterm line (9.1-10.0: ) +-> $$ = nterm input (1.1-10.0: ) +Entering state 6 +Reading a token +Next token is token "number" (10.1: 1) +Shifting token "number" (10.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (10.1: 1) +-> $$ = nterm exp (10.1: 1) +Entering state 8 +Reading a token +Next token is token '-' (10.3: ) +Shifting token '-' (10.3: ) +Entering state 20 +Reading a token +Next token is token '(' (10.5: ) +Shifting token '(' (10.5: ) Entering state 4 Reading a token -Next token is token "number" (1.10: 1) -Shifting token "number" (1.10: 1) +Next token is token "number" (10.6: 2) +Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.10: 1) --> $$ = nterm exp (1.10: 1) + $1 = token "number" (10.6: 2) +-> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token -Next token is token "number" (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Shifting token error (1.10-12: ) -Entering state 11 -Next token is token "number" (1.12: 2) -Error: discarding token "number" (1.12: 2) +Next token is token '-' (10.8: ) +Shifting token '-' (10.8: ) +Entering state 20 Reading a token -Next token is token ')' (1.13: ) -Entering state 11 -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) -Entering state 30 +Next token is token "number" (10.10: 3) +Shifting token "number" (10.10: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (10.10: 3) +-> $$ = nterm exp (10.10: 3) +Entering state 29 Reading a token -Next token is token '=' (1.15: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) +Next token is token ')' (10.11: ) +Reducing stack 0 by rule 8 (line 100): + $1 = nterm exp (10.6: 2) + $2 = token '-' (10.8: ) + $3 = nterm exp (10.10: 3) +-> $$ = nterm exp (10.6-10: -1) +Entering state 12 +Next token is token ')' (10.11: ) +Shifting token ')' (10.11: ) +Entering state 27 +Reducing stack 0 by rule 13 (line 113): + $1 = token '(' (10.5: ) + $2 = nterm exp (10.6-10: -1) + $3 = token ')' (10.11: ) +-> $$ = nterm exp (10.5-11: -1) +Entering state 29 +Reading a token +Next token is token '=' (10.13: ) +Reducing stack 0 by rule 8 (line 100): + $1 = nterm exp (10.1: 1) + $2 = token '-' (10.3: ) + $3 = nterm exp (10.5-11: -1) +-> $$ = nterm exp (10.1-11: 2) Entering state 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) +Next token is token '=' (10.13: ) +Shifting token '=' (10.13: ) Entering state 19 Reading a token -Next token is token "number" (1.17: 1) -Shifting token "number" (1.17: 1) +Next token is token "number" (10.15: 2) +Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.17: 1) --> $$ = nterm exp (1.17: 1) + $1 = token "number" (10.15: 2) +-> $$ = nterm exp (10.15: 2) Entering state 28 Reading a token -Next token is token '\n' (1.18-2.0: ) +Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) + $1 = nterm exp (10.1-11: 2) + $2 = token '=' (10.13: ) + $3 = nterm exp (10.15: 2) +-> $$ = nterm exp (10.1-15: 2) Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (10.16-11.0: ) +Shifting token '\n' (10.16-11.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) + $1 = nterm exp (10.1-15: 2) + $2 = token '\n' (10.16-11.0: ) +-> $$ = nterm line (10.1-11.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-10.0: ) + $2 = nterm line (10.1-11.0: ) +-> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1413: cat stderr -Starting parse -Entering state 0 +Next token is token '\n' (11.1-12.0: ) +Shifting token '\n' (11.1-12.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 83): + $1 = token '\n' (11.1-12.0: ) +-> $$ = nterm line (11.1-12.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-11.0: ) + $2 = nterm line (11.1-12.0: ) +-> $$ = nterm input (1.1-12.0: ) +Entering state 6 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token "number" (12.1: 2) +Shifting token "number" (12.1: 2) Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (12.1: 2) +-> $$ = nterm exp (12.1: 2) Entering state 8 Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 +Next token is token '^' (12.2: ) +Shifting token '^' (12.2: ) +Entering state 24 Reading a token -Next token is token "number" (1.1: 2) -Shifting token "number" (1.1: 2) +Next token is token "number" (12.3: 2) +Shifting token "number" (12.3: 2) Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 2) --> $$ = nterm exp (1.1: 2) -Entering state 30 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (12.3: 2) +-> $$ = nterm exp (12.3: 2) +Entering state 33 Reading a token -Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) -Entering state 22 +Next token is token '^' (12.4: ) +Shifting token '^' (12.4: ) +Entering state 24 Reading a token -Next token is token "number" (1.1: 3) -Shifting token "number" (1.1: 3) +Next token is token "number" (12.5: 3) +Shifting token "number" (12.5: 3) Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 3) --> $$ = nterm exp (1.1: 3) -Entering state 31 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (12.5: 3) +-> $$ = nterm exp (12.5: 3) +Entering state 33 Reading a token -Next token is token '+' (1.1: ) -Reducing stack 0 by rule 9 (line 100): - $1 = nterm exp (1.1: 2) - $2 = token '*' (1.1: ) - $3 = nterm exp (1.1: 3) --> $$ = nterm exp (1.1: 6) -Entering state 30 -Next token is token '+' (1.1: ) -Reducing stack 0 by rule 7 (line 98): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 6) --> $$ = nterm exp (1.1: 7) +Next token is token '=' (12.7: ) +Reducing stack 0 by rule 12 (line 112): + $1 = nterm exp (12.3: 2) + $2 = token '^' (12.4: ) + $3 = nterm exp (12.5: 3) +-> $$ = nterm exp (12.3-5: 8) +Entering state 33 +Next token is token '=' (12.7: ) +Reducing stack 0 by rule 12 (line 112): + $1 = nterm exp (12.1: 2) + $2 = token '^' (12.2: ) + $3 = nterm exp (12.3-5: 8) +-> $$ = nterm exp (12.1-5: 256) Entering state 8 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 +Next token is token '=' (12.7: ) +Shifting token '=' (12.7: ) +Entering state 19 Reading a token -Next token is token '!' (1.1: ) -Shifting token '!' (1.1: ) -Entering state 5 +Next token is token "number" (12.9-11: 256) +Shifting token "number" (12.9-11: 256) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (12.9-11: 256) +-> $$ = nterm exp (12.9-11: 256) +Entering state 28 Reading a token -Next token is token '-' (1.1: ) -Shifting token '-' (1.1: ) -Entering state 13 -Reducing stack 0 by rule 18 (line 123): - $1 = token '!' (1.1: ) - $2 = token '-' (1.1: ) -Cleanup: popping token '+' (1.1: ) -Cleanup: popping nterm exp (1.1: 7) -./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1408: "$PERL" -pi -e 'use strict; +Next token is token '\n' (12.12-13.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (12.1-5: 256) + $2 = token '=' (12.7: ) + $3 = nterm exp (12.9-11: 256) +-> $$ = nterm exp (12.1-11: 256) +Entering state 8 +Next token is token '\n' (12.12-13.0: ) +Shifting token '\n' (12.12-13.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (12.1-11: 256) + $2 = token '\n' (12.12-13.0: ) +-> $$ = nterm line (12.1-13.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-12.0: ) + $2 = nterm line (12.1-13.0: ) +-> $$ = nterm input (1.1-13.0: ) +Entering state 6 +Reading a token +Next token is token '(' (13.1: ) +Shifting token '(' (13.1: ) +Entering state 4 +Reading a token +Next token is token "number" (13.2: 2) +Shifting token "number" (13.2: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (13.2: 2) +-> $$ = nterm exp (13.2: 2) +Entering state 12 +Reading a token +Next token is token '^' (13.3: ) +Shifting token '^' (13.3: ) +Entering state 24 +Reading a token +Next token is token "number" (13.4: 2) +Shifting token "number" (13.4: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (13.4: 2) +-> $$ = nterm exp (13.4: 2) +Entering state 33 +Reading a token +Next token is token ')' (13.5: ) +Reducing stack 0 by rule 12 (line 112): + $1 = nterm exp (13.2: 2) + $2 = token '^' (13.3: ) + $3 = nterm exp (13.4: 2) +-> $$ = nterm exp (13.2-4: 4) +Entering state 12 +Next token is token ')' (13.5: ) +Shifting token ')' (13.5: ) +Entering state 27 +Reducing stack 0 by rule 13 (line 113): + $1 = token '(' (13.1: ) + $2 = nterm exp (13.2-4: 4) + $3 = token ')' (13.5: ) +-> $$ = nterm exp (13.1-5: 4) +Entering state 8 +Reading a token +Next token is token '^' (13.6: ) +Shifting token '^' (13.6: ) +Entering state 24 +Reading a token +Next token is token "number" (13.7: 3) +Shifting token "number" (13.7: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (13.7: 3) +-> $$ = nterm exp (13.7: 3) +Entering state 33 +Reading a token +Next token is token '=' (13.9: ) +Reducing stack 0 by rule 12 (line 112): + $1 = nterm exp (13.1-5: 4) + $2 = token '^' (13.6: ) + $3 = nterm exp (13.7: 3) +-> $$ = nterm exp (13.1-7: 64) +Entering state 8 +Next token is token '=' (13.9: ) +Shifting token '=' (13.9: ) +Entering state 19 +Reading a token +Next token is token "number" (13.11-12: 64) +Shifting token "number" (13.11-12: 64) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (13.11-12: 64) +-> $$ = nterm exp (13.11-12: 64) +Entering state 28 +Reading a token +Next token is token '\n' (13.13-14.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (13.1-7: 64) + $2 = token '=' (13.9: ) + $3 = nterm exp (13.11-12: 64) +-> $$ = nterm exp (13.1-12: 64) +Entering state 8 +Next token is token '\n' (13.13-14.0: ) +Shifting token '\n' (13.13-14.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (13.1-12: 64) + $2 = token '\n' (13.13-14.0: ) +-> $$ = nterm line (13.1-14.0: ) +Entering state 18 +Reducing stack 0 by rule 2 (line 79): + $1 = nterm input (1.1-13.0: ) + $2 = nterm line (13.1-14.0: ) +-> $$ = nterm input (1.1-14.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (14.1: ) +Entering state 17 +Cleanup: popping token "end of input" (14.1: ) +Cleanup: popping nterm input (1.1-14.0: ) +stderr: +stderr: +./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -109330,15 +111955,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -input: - | 1 = 2 = 3 -./calc.at:1408: cat stderr -./calc.at:1413: $PREPARSER ./calc input -stderr: -stderr: Starting parse Entering state 0 Reading a token @@ -109396,47 +112012,124 @@ Shifting token '!' (1.1: ) Entering state 5 Reading a token -Next token is token '-' (1.1: ) -Shifting token '-' (1.1: ) -Entering state 13 -Reducing stack 0 by rule 18 (line 123): +Next token is token '*' (1.1: ) +Shifting token '*' (1.1: ) +Entering state 15 +Reducing stack 0 by rule 19 (line 124): $1 = token '!' (1.1: ) - $2 = token '-' (1.1: ) + $2 = token '*' (1.1: ) +memory exhausted Cleanup: popping token '+' (1.1: ) Cleanup: popping nterm exp (1.1: 7) -stderr: - | 1//2 Starting parse Entering state 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) +Reading a token +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Reading a token +Next token is token "number" (1.10: 1) +Error: discarding token "number" (1.10: 1) +Reading a token +Next token is token ')' (1.11: ) +Entering state 11 +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) Entering state 19 Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) +Next token is token "number" (1.15-18: 1111) +Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) + $1 = token "number" (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Error: popping token '=' (1.3: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '=' (1.7: ) -./calc.at:1414: $PREPARSER ./calc input -./calc.at:1409: "$PERL" -pi -e 'use strict; +Next token is token '\n' (1.19-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) +Entering state 8 +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +input: + | 1 2 +./calc.at:1414: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1413: $PREPARSER ./calc input +stderr: +./calc.at:1416: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1409: cat stderr +./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -109457,16 +112150,45 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) +Next token is token "number" (1.3: 2) +1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.3: ) +Cleanup: discarding lookahead token "number" (1.3: 2) +./calc.at:1408: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +526. calc.at:1434: testing Calculator C++ %locations api.location.type={Span} ... +./calc.at:1434: mv calc.y.tmp calc.y + +./calc.at:1416: cat stderr +./calc.at:1414: cat stderr +./calc.at:1411: cat stderr +./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1434: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +./calc.at:1407: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1408: cat stderr +input: + | (1 + #) = 1111 +./calc.at:1409: $PREPARSER ./calc input stderr: +input: +input: Starting parse Entering state 0 Reading a token @@ -109478,18 +112200,18 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 23 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) +Next token is token "number" (1.3: 2) +1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.3: ) -./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Cleanup: discarding lookahead token "number" (1.3: 2) input: + | error + | 1//2 +./calc.at:1414: $PREPARSER ./calc input +stderr: | (* *) + (*) + (*) +./calc.at:1411: $PREPARSER ./calc input +./calc.at:1416: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -109497,98 +112219,64 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 16 -Reducing stack 0 by rule 16 (line 116): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Shifting token error (1.2-3: ) -Entering state 11 -Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) -Entering state 21 -Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) -Entering state 4 -Reading a token -Next token is token "number" (1.9: 1) -Shifting token "number" (1.9: 1) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 1) --> $$ = nterm exp (1.9: 1) + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token -Next token is token "number" (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Shifting token error (1.9-11: ) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) Entering state 11 -Next token is token "number" (1.11: 2) -Error: discarding token "number" (1.11: 2) +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) Reading a token -Next token is token ')' (1.12: ) +Next token is token ')' (1.7: ) Entering state 11 -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) -Entering state 30 -Reading a token -Next token is token '=' (1.14: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 19 Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token -Next token is token '\n' (1.17-2.0: ) +Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): @@ -109601,19 +112289,31 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1408: $PREPARSER ./calc input -./calc.at:1416: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: stderr: -./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '/' (1.3: ) Starting parse Entering state 0 Reading a token @@ -109636,7 +112336,7 @@ Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) @@ -109663,7 +112363,7 @@ Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) @@ -109671,7 +112371,7 @@ Entering state 30 Reading a token Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) @@ -109697,7 +112397,7 @@ Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) @@ -109705,7 +112405,7 @@ Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) @@ -109729,21 +112429,19 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1411: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1409: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token "invalid token" (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" (1.1: ) + | (1 + 1) / (1 - 1) +./calc.at:1408: $PREPARSER ./calc input +./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1407: cat stderr +./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1411: cat stderr -./calc.at:1407: "$PERL" -pi -e 'use strict; +./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -109753,41 +112451,125 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: +./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Reading a token +Next token is token "number" (1.6: 1) +Shifting token "number" (1.6: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 30 +Reading a token +Next token is token ')' (1.7: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 27 +Reducing stack 0 by rule 13 (line 125): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 19 +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 23 Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Reading a token +Next token is token "number" (1.12: 1) +Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 28 + $1 = token "number" (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Error: popping token '=' (1.3: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '=' (1.7: ) +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 20 +Reading a token +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 29 +Reading a token +Next token is token ')' (1.17: ) +Reducing stack 0 by rule 8 (line 106): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 27 +Reducing stack 0 by rule 13 (line 125): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 32 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 10 (line 108): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) +Entering state 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) stderr: -./calc.at:1416: cat stderr - | (* *) + (*) + (*) -./calc.at:1409: $PREPARSER ./calc input stderr: +./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -109795,101 +112577,180 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 Reading a token -Next token is token ')' (1.5: ) +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) +Reading a token +Next token is token ')' (1.7: ) +Entering state 11 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 126): $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 21 +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) -Entering state 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 Reading a token -Next token is token ')' (1.11: ) -Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Reading a token +Next token is token "number" (1.6: 1) +Shifting token "number" (1.6: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.6: 1) +-> $$ = nterm exp (1.6: 1) Entering state 30 Reading a token -Next token is token '+' (1.13: ) +Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 27 +Reducing stack 0 by rule 13 (line 125): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) Entering state 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 23 +Reading a token +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) Entering state 4 Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) +Next token is token "number" (1.12: 1) +Shifting token "number" (1.12: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 20 +Reading a token +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 29 Reading a token Next token is token ')' (1.17: ) -Entering state 11 +Reducing stack 0 by rule 8 (line 106): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) +Entering state 27 +Reducing stack 0 by rule 13 (line 125): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 30 +-> $$ = nterm exp (1.11-17: 0) +Entering state 32 Reading a token Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) +Reducing stack 0 by rule 10 (line 108): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-17: 3333) + $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 @@ -109903,7 +112764,6 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: Starting parse Entering state 0 Reading a token @@ -109926,7 +112786,7 @@ Next token is token ')' (1.5: ) Shifting token ')' (1.5: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-4: ) $3 = token ')' (1.5: ) @@ -109953,7 +112813,7 @@ Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.9: ) $2 = token error (1.10: ) $3 = token ')' (1.11: ) @@ -109961,7 +112821,7 @@ Entering state 30 Reading a token Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) $3 = nterm exp (1.9-11: 1111) @@ -109987,7 +112847,7 @@ Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.15: ) $2 = token error (1.16: ) $3 = token ')' (1.17: ) @@ -109995,7 +112855,7 @@ Entering state 30 Reading a token Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-11: 2222) $2 = token '+' (1.13: ) $3 = nterm exp (1.15-17: 1111) @@ -110019,7 +112879,8 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1413: cat stderr Starting parse Entering state 0 Reading a token @@ -110040,79 +112901,21 @@ Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) -./calc.at:1407: cat stderr -input: - | 1 + 2 * 3 + !* ++ + | (#) + (#) = 2222 ./calc.at:1407: $PREPARSER ./calc input +./calc.at:1409: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Reading a token -Next token is token "number" (1.1: 2) -Shifting token "number" (1.1: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 2) --> $$ = nterm exp (1.1: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) -Entering state 22 -Reading a token -Next token is token "number" (1.1: 3) -Shifting token "number" (1.1: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 3) --> $$ = nterm exp (1.1: 3) -Entering state 31 -Reading a token -Next token is token '+' (1.1: ) -Reducing stack 0 by rule 9 (line 100): - $1 = nterm exp (1.1: 2) - $2 = token '*' (1.1: ) - $3 = nterm exp (1.1: 3) --> $$ = nterm exp (1.1: 6) -Entering state 30 -Next token is token '+' (1.1: ) -Reducing stack 0 by rule 7 (line 98): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 6) --> $$ = nterm exp (1.1: 7) -Entering state 8 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Reading a token -Next token is token '!' (1.1: ) -Shifting token '!' (1.1: ) -Entering state 5 -Reading a token -Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) -Entering state 15 -Reducing stack 0 by rule 19 (line 124): - $1 = token '!' (1.1: ) - $2 = token '*' (1.1: ) -memory exhausted -Cleanup: popping token '+' (1.1: ) -Cleanup: popping nterm exp (1.1: 7) -./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1408: "$PERL" -pi -e 'use strict; +./calc.at:1434: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -110122,10 +112925,16 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +Starting parse +Entering state 0 +Reading a token +Next token is token "invalid token" (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" (1.1: ) input: stderr: -input: -./calc.at:1413: "$PERL" -pi -e 'use strict; +./calc.at:1409: cat stderr +./calc.at:1408: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -110135,10 +112944,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | error -./calc.at:1416: $PREPARSER ./calc input -./calc.at:1408: cat stderr -./calc.at:1413: cat stderr Starting parse Entering state 0 Reading a token @@ -110146,115 +112951,112 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) +syntax error: invalid character: '#' +Next token is token error (1.1: ) +Shifting token error (1.1: ) Entering state 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) -Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) +Next token is token error (1.1: ) +Error: discarding token error (1.1: ) Reading a token -Next token is token ')' (1.5: ) +Next token is token ')' (1.1: ) Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) Entering state 21 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) +syntax error: invalid character: '#' +Next token is token error (1.1: ) +Shifting token error (1.1: ) Entering state 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) +Next token is token error (1.1: ) +Error: discarding token error (1.1: ) Reading a token -Next token is token ')' (1.11: ) +Next token is token ')' (1.1: ) Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) +Reducing stack 0 by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) +Next token is token '=' (1.1: ) +Reducing stack 0 by rule 7 (line 98): + $1 = nterm exp (1.1: 1111) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 2222) Entering state 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 -Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) +Entering state 19 Reading a token -Next token is token ')' (1.17: ) -Entering state 11 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 30 +Next token is token "number" (1.1: 2222) +Shifting token "number" (1.1: 2222) +Entering state 1 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 2222) +-> $$ = nterm exp (1.1: 2222) +Entering state 28 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) +Next token is token '\n' (1.1: ) +Reducing stack 0 by rule 6 (line 82): + $1 = nterm exp (1.1: 2222) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 2222) +-> $$ = nterm exp (1.1: 2222) Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) +Reducing stack 0 by rule 4 (line 77): + $1 = nterm exp (1.1: 2222) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) +Reducing stack 0 by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) +Shifting token "end of input" (1.1: ) Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - | (- *) + (1 2) = 1 +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) +./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1411: cat stderr +./calc.at:1414: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | 1//2 +./calc.at:1413: $PREPARSER ./calc input +./calc.at:1408: cat stderr +stderr: stderr: Starting parse Entering state 0 @@ -110262,68 +113064,21 @@ Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 -Reducing stack 0 by rule 5 (line 81): +Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Reading a token -Next token is token "number" (1.1: 2) -Shifting token "number" (1.1: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 2) --> $$ = nterm exp (1.1: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) -Entering state 22 -Reading a token -Next token is token "number" (1.1: 3) -Shifting token "number" (1.1: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 3) --> $$ = nterm exp (1.1: 3) -Entering state 31 -Reading a token -Next token is token '+' (1.1: ) -Reducing stack 0 by rule 9 (line 100): - $1 = nterm exp (1.1: 2) - $2 = token '*' (1.1: ) - $3 = nterm exp (1.1: 3) --> $$ = nterm exp (1.1: 6) -Entering state 30 -Next token is token '+' (1.1: ) -Reducing stack 0 by rule 7 (line 98): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 6) --> $$ = nterm exp (1.1: 7) -Entering state 8 -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Reading a token -Next token is token '!' (1.1: ) -Shifting token '!' (1.1: ) -Entering state 5 +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 Reading a token -Next token is token '*' (1.1: ) -Shifting token '*' (1.1: ) -Entering state 15 -Reducing stack 0 by rule 19 (line 124): - $1 = token '!' (1.1: ) - $2 = token '*' (1.1: ) -memory exhausted -Cleanup: popping token '+' (1.1: ) -Cleanup: popping nterm exp (1.1: 7) -./calc.at:1411: $PREPARSER ./calc input -./calc.at:1414: "$PERL" -pi -e 'use strict; +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '/' (1.3: ) +./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -110333,16 +113088,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" (1.1: ) -stderr: -input: -./calc.at:1414: cat stderr Starting parse Entering state 0 Reading a token @@ -110350,298 +113095,134 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Reducing stack 0 by rule 15 (line 115): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Shifting token error (1.2-4: ) +syntax error: invalid character: '#' +Next token is token error (1.1: ) +Shifting token error (1.1: ) Entering state 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) +Next token is token error (1.1: ) +Error: discarding token error (1.1: ) Reading a token -Next token is token ')' (1.5: ) +Next token is token ')' (1.1: ) Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) Entering state 26 -Reducing stack 0 by rule 14 (line 114): +Reducing stack 0 by rule 14 (line 119): $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) Entering state 8 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) Entering state 21 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (1.10: 1) -Shifting token "number" (1.10: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Reading a token -Next token is token "number" (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Shifting token error (1.10-12: ) +syntax error: invalid character: '#' +Next token is token error (1.1: ) +Shifting token error (1.1: ) Entering state 11 -Next token is token "number" (1.12: 2) -Error: discarding token "number" (1.12: 2) +Next token is token error (1.1: ) +Error: discarding token error (1.1: ) Reading a token -Next token is token ')' (1.13: ) +Next token is token ')' (1.1: ) Entering state 11 -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) +Reducing stack 0 by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) Entering state 30 Reading a token -Next token is token '=' (1.15: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) +Next token is token '=' (1.1: ) +Reducing stack 0 by rule 7 (line 98): + $1 = nterm exp (1.1: 1111) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 2222) Entering state 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) Entering state 19 Reading a token -Next token is token "number" (1.17: 1) -Shifting token "number" (1.17: 1) +Next token is token "number" (1.1: 2222) +Shifting token "number" (1.1: 2222) Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.17: 1) --> $$ = nterm exp (1.17: 1) +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 2222) +-> $$ = nterm exp (1.1: 2222) Entering state 28 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) +Next token is token '\n' (1.1: ) +Reducing stack 0 by rule 6 (line 82): + $1 = nterm exp (1.1: 2222) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 2222) +-> $$ = nterm exp (1.1: 2222) Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) +Reducing stack 0 by rule 4 (line 77): + $1 = nterm exp (1.1: 2222) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) +Reducing stack 0 by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) +Shifting token "end of input" (1.1: ) Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) +./calc.at:1414: cat stderr input: -./calc.at:1409: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: +input: +./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +516. calc.at:1408: ok | 1 + 2 * 3 + !+ ++ +./calc.at:1411: $PREPARSER ./calc input +stderr: + | (# + 1) = 1111 +./calc.at:1409: $PREPARSER ./calc input +stderr: +./calc.at:1416: cat stderr Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Reducing stack 0 by rule 15 (line 115): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Shifting token error (1.2-4: ) -Entering state 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 21 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Reading a token -Next token is token "number" (1.10: 1) -Shifting token "number" (1.10: 1) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 Reading a token -Next token is token "number" (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Shifting token error (1.10-12: ) -Entering state 11 -Next token is token "number" (1.12: 2) -Error: discarding token "number" (1.12: 2) -Reading a token -Next token is token ')' (1.13: ) -Entering state 11 -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) -Entering state 30 -Reading a token -Next token is token '=' (1.15: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) -Entering state 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) -Entering state 19 -Reading a token -Next token is token "number" (1.17: 1) -Shifting token "number" (1.17: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.17: 1) --> $$ = nterm exp (1.17: 1) -Entering state 28 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) -Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - | - | +1 -./calc.at:1408: $PREPARSER ./calc input -./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1413: $PREPARSER ./calc input -./calc.at:1411: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1407: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 Reading a token Next token is token "number" (1.9: 3) Shifting token "number" (1.9: 3) @@ -110652,14 +113233,14 @@ Entering state 31 Reading a token Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 107): +Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) @@ -110676,46 +113257,34 @@ Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 -Reducing stack 0 by rule 17 (line 129): +Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 83): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Cleanup: discarding lookahead token '+' (2.1: ) +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 23 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '/' (1.3: ) stderr: -./calc.at:1411: cat stderr -./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1409: cat stderr input: - | (* *) + (*) + (*) -./calc.at:1411: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" (1.1: ) Starting parse Entering state 0 Reading a token @@ -110723,102 +113292,56 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) -Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 21 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) -Entering state 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) +Next token is token "number" (1.6: 1) +Error: discarding token "number" (1.6: 1) Reading a token -Next token is token ')' (1.11: ) +Next token is token ')' (1.7: ) Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) -Entering state 30 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 Reading a token -Next token is token ')' (1.17: ) -Entering state 11 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 30 +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) +Next token is token '\n' (1.15-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): @@ -110831,136 +113354,12 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1414: $PREPARSER ./calc input stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) -Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 21 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) -Entering state 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) -Reading a token -Next token is token ')' (1.11: ) -Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) -Entering state 30 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) -Entering state 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 -Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) -Reading a token -Next token is token ')' (1.17: ) -Entering state 11 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 30 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) -Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1411: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 stderr: +input: Starting parse Entering state 0 Reading a token @@ -110997,14 +113396,14 @@ Entering state 31 Reading a token Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 107): +Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) @@ -111021,21 +113420,12 @@ Next token is token '+' (1.14: ) Shifting token '+' (1.14: ) Entering state 14 -Reducing stack 0 by rule 17 (line 129): +Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -stderr: -input: -./calc.at:1411: cat stderr -Starting parse -Entering state 0 -Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" (1.1: ) -./calc.at:1416: "$PERL" -pi -e 'use strict; +./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -111045,310 +113435,101 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | 1 + 2 * 3 + !+ ++ -./calc.at:1409: $PREPARSER ./calc input -input: - | 1 + 2 * 3 + !+ ++ -./calc.at:1411: $PREPARSER ./calc input -stderr: -stderr: -./calc.at:1407: cat stderr - | 1 + 2 * 3 + !- ++ -stderr: -./calc.at:1408: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 83): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Cleanup: discarding lookahead token '+' (2.1: ) -./calc.at:1416: cat stderr +Next token is token "invalid token" (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" (1.1: ) stderr: + | 1 = 2 = 3 Starting parse Entering state 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 107): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Reducing stack 0 by rule 17 (line 129): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Reducing stack 0 by rule 17 (line 117): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -stderr: -./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 +Next token is token "number" (1.6: 1) +Error: discarding token "number" (1.6: 1) Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) +Next token is token ')' (1.7: ) +Entering state 11 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 107): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) +Next token is token '\n' (1.15-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Reducing stack 0 by rule 18 (line 130): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -input: - | 1 = 2 = 3 +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) input: -./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1416: $PREPARSER ./calc input -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 107): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Reducing stack 0 by rule 17 (line 129): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) - | (#) + (#) = 2222 + +./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1413: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: + | 1 + 2 * 3 + !- ++ +./calc.at:1413: cat stderr +./calc.at:1411: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -111378,89 +113559,25 @@ Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) -input: stderr: stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Reducing stack 0 by rule 17 (line 117): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) - | 1 + 2 * 3 + !- ++ -./calc.at:1409: $PREPARSER ./calc input -input: +./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token Next token is token "invalid token" (1.1: ) 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token "invalid token" (1.1: ) -stderr: -./calc.at:1407: $PREPARSER ./calc input - | 1 + 2 * 3 + !- ++ -stderr: -./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1411: $PREPARSER ./calc input +./calc.at:1409: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -111497,14 +113614,14 @@ Entering state 31 Reading a token Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 107): +Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) @@ -111521,13 +113638,13 @@ Next token is token '-' (1.14: ) Shifting token '-' (1.14: ) Entering state 13 -Reducing stack 0 by rule 18 (line 130): +Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1407: cat stderr stderr: Starting parse Entering state 0 @@ -111540,9 +113657,9 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) @@ -111550,50 +113667,17 @@ Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 107): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 +Entering state 28 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Reducing stack 0 by rule 18 (line 130): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Error: popping token '=' (1.3: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '=' (1.7: ) +input: +stderr: +./calc.at:1409: cat stderr Starting parse Entering state 0 Reading a token @@ -111659,6 +113743,18 @@ $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) + | error +./calc.at:1416: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1413: $PREPARSER ./calc input ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -111669,76 +113765,21 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1416: cat stderr +input: stderr: ./calc.at:1414: cat stderr -stderr: + | (1 + #) = 1111 +./calc.at:1407: $PREPARSER ./calc input +input: Starting parse Entering state 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 107): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Reducing stack 0 by rule 18 (line 130): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1413: "$PERL" -pi -e 'use strict; +Next token is token "invalid token" (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" (1.1: ) +input: +./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -111748,6 +113789,17 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +527. calc.at:1435: testing Calculator C++ %header %locations parse.error=verbose %name-prefix "calc" %verbose ... +./calc.at:1435: mv calc.y.tmp calc.y + + | (1 + # + 1) = 1111 +./calc.at:1409: $PREPARSER ./calc input +stderr: +./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | + | +1 +./calc.at:1416: $PREPARSER ./calc input +stderr: Starting parse Entering state 0 Reading a token @@ -111755,35 +113807,22 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -syntax error: invalid character: '#' -Next token is token error (1.1: ) -Shifting token error (1.1: ) -Entering state 11 -Next token is token error (1.1: ) -Error: discarding token error (1.1: ) -Reading a token -Next token is token ')' (1.1: ) -Entering state 11 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) +Error: popping token '+' (1.1: ) +Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) @@ -111799,39 +113838,32 @@ $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) -Entering state 30 -Reading a token -Next token is token '=' (1.1: ) -Reducing stack 0 by rule 7 (line 98): - $1 = nterm exp (1.1: 1111) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 2222) Entering state 8 +Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token -Next token is token "number" (1.1: 2222) -Shifting token "number" (1.1: 2222) +Next token is token "number" (1.1: 1111) +Shifting token "number" (1.1: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 2222) --> $$ = nterm exp (1.1: 2222) + $1 = token "number" (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): - $1 = nterm exp (1.1: 2222) + $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 2222) --> $$ = nterm exp (1.1: 2222) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): - $1 = nterm exp (1.1: 2222) + $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 @@ -111845,129 +113877,124 @@ Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) -stderr: ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1411: cat stderr +stderr: +stderr: +input: Starting parse Entering state 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 19 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 28 +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 83): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Error: popping token '=' (1.3: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '=' (1.7: ) +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Cleanup: discarding lookahead token '+' (2.1: ) Starting parse Entering state 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) Entering state 21 Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) +Next token is token "number" (1.10: 1) +Error: discarding token "number" (1.10: 1) +Reading a token +Next token is token ')' (1.11: ) +Entering state 11 +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) +Entering state 8 +Reading a token +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) +Entering state 19 +Reading a token +Next token is token "number" (1.15-18: 1111) +Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 + $1 = token "number" (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) +Entering state 28 Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) +Next token is token '\n' (1.19-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1435: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +Starting parse +Entering state 0 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Reducing stack 0 by rule 18 (line 118): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1413: cat stderr -input: -./calc.at:1408: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1413: $PREPARSER ./calc /dev/null +Next token is token "invalid token" (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" (1.1: ) | 1 = 2 = 3 -stderr: ./calc.at:1414: $PREPARSER ./calc input -stderr: -./calc.at:1409: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -111975,35 +114002,22 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -syntax error: invalid character: '#' -Next token is token error (1.1: ) -Shifting token error (1.1: ) -Entering state 11 -Next token is token error (1.1: ) -Error: discarding token error (1.1: ) -Reading a token -Next token is token ')' (1.1: ) -Entering state 11 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 Reading a token Next token is token '+' (1.1: ) Shifting token '+' (1.1: ) Entering state 21 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) +Error: popping token '+' (1.1: ) +Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) @@ -112019,39 +114033,32 @@ $2 = token error (1.1: ) $3 = token ')' (1.1: ) -> $$ = nterm exp (1.1: 1111) -Entering state 30 -Reading a token -Next token is token '=' (1.1: ) -Reducing stack 0 by rule 7 (line 98): - $1 = nterm exp (1.1: 1111) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 2222) Entering state 8 +Reading a token Next token is token '=' (1.1: ) Shifting token '=' (1.1: ) Entering state 19 Reading a token -Next token is token "number" (1.1: 2222) -Shifting token "number" (1.1: 2222) +Next token is token "number" (1.1: 1111) +Shifting token "number" (1.1: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 2222) --> $$ = nterm exp (1.1: 2222) + $1 = token "number" (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) Entering state 28 Reading a token Next token is token '\n' (1.1: ) Reducing stack 0 by rule 6 (line 82): - $1 = nterm exp (1.1: 2222) + $1 = nterm exp (1.1: 1111) $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 2222) --> $$ = nterm exp (1.1: 2222) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): - $1 = nterm exp (1.1: 2222) + $1 = nterm exp (1.1: 1111) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 @@ -112065,14 +114072,96 @@ Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) +./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +input: stderr: Starting parse Entering state 0 Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) +Reading a token +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Reading a token +Next token is token "number" (1.10: 1) +Error: discarding token "number" (1.10: 1) +Reading a token +Next token is token ')' (1.11: ) +Entering state 11 +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 126): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) +Entering state 8 +Reading a token +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) +Entering state 19 +Reading a token +Next token is token "number" (1.15-18: 1111) +Shifting token "number" (1.15-18: 1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) +Entering state 28 +Reading a token +Next token is token '\n' (1.19-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) +Entering state 8 +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" (1.1: ) -./calc.at:1408: cat stderr +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) + | 1 + 2 * 3 + !* ++ +./calc.at:1411: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -112102,21 +114191,25 @@ Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) -./calc.at:1416: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1409: cat stderr -input: - | 1 + 2 * 3 + !* ++ -./calc.at:1408: $PREPARSER ./calc input -./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 83): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Cleanup: discarding lookahead token '+' (2.1: ) stderr: Starting parse Entering state 0 @@ -112154,14 +114247,14 @@ Entering state 31 Reading a token Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 107): +Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) @@ -112178,25 +114271,27 @@ Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 -Reducing stack 0 by rule 19 (line 131): +Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -input: -./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1413: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: Starting parse Entering state 0 Reading a token -Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" (1.1: ) -Starting parse -Entering state 0 -Reading a token Next token is token "number" (1.1: 1) Shifting token "number" (1.1: 1) Entering state 1 @@ -112230,14 +114325,14 @@ Entering state 31 Reading a token Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 107): +Reducing stack 0 by rule 9 (line 101): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 30 Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) @@ -112254,7 +114349,7 @@ Next token is token '*' (1.14: ) Shifting token '*' (1.14: ) Entering state 15 -Reducing stack 0 by rule 19 (line 131): +Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) $2 = token '*' (1.14: ) 1.14: memory exhausted @@ -112271,7 +114366,8 @@ }eg ' expout || exit 77 ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1408: "$PERL" -pi -e 'use strict; +./calc.at:1411: cat stderr +./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -112281,77 +114377,19 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1416: cat stderr - | 1 + 2 * 3 + !* ++ -./calc.at:1409: $PREPARSER ./calc input stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 107): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Reducing stack 0 by rule 19 (line 131): - $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1407: "$PERL" -pi -e 'use strict; +./calc.at:1413: cat stderr +./calc.at:1416: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1409: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -112361,9 +114399,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1407: cat stderr Starting parse Entering state 0 Reading a token @@ -112393,123 +114428,16 @@ Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) -./calc.at:1413: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1411: cat stderr -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 107): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Reducing stack 0 by rule 19 (line 131): - $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -input: -./calc.at:1408: cat stderr - | - | +1 -./calc.at:1416: $PREPARSER ./calc input +./calc.at:1416: cat stderr +./calc.at:1435: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS input: - | (1 + #) = 1111 -./calc.at:1407: $PREPARSER ./calc input -stderr: + | (#) + (#) = 2222 +./calc.at:1411: $PREPARSER ./calc input +./calc.at:1409: cat stderr +./calc.at:1407: cat stderr stderr: -./calc.at:1409: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 83): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Cleanup: discarding lookahead token '+' (2.1: ) +./calc.at:1416: $PREPARSER ./calc /dev/null +input: Starting parse Entering state 0 Reading a token @@ -112517,78 +114445,107 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) +Next token is token ')' (1.3: ) +Entering state 11 +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 114): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) Entering state 21 Reading a token -syntax error: invalid character: '#' -Next token is token error (1.1: ) -Error: popping token '+' (1.1: ) -Error: popping nterm exp (1.1: 1) -Shifting token error (1.1: ) +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Reading a token +1.8: syntax error: invalid character: '#' +Next token is token error (1.8: ) +Shifting token error (1.8: ) Entering state 11 -Next token is token error (1.1: ) -Error: discarding token error (1.1: ) +Next token is token error (1.8: ) +Error: discarding token error (1.8: ) Reading a token -Next token is token ')' (1.1: ) +Next token is token ')' (1.9: ) Entering state 11 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) Entering state 26 -Reducing stack 0 by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 +Reducing stack 0 by rule 14 (line 114): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 30 Reading a token -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) +Entering state 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) Entering state 19 Reading a token -Next token is token "number" (1.1: 1111) -Shifting token "number" (1.1: 1111) +Next token is token "number" (1.13-16: 2222) +Shifting token "number" (1.13-16: 2222) Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 1111) --> $$ = nterm exp (1.1: 1111) +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token -Next token is token '\n' (1.1: ) -Reducing stack 0 by rule 6 (line 82): - $1 = nterm exp (1.1: 1111) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 1111) +Next token is token '\n' (1.17-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 25 -Reducing stack 0 by rule 4 (line 77): - $1 = nterm exp (1.1: 1111) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) Entering state 7 -Reducing stack 0 by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" (1.1: ) +Shifting token "end of input" (2.1: ) Entering state 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) -./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1413: cat stderr +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: + | 1 = 2 = 3 +./calc.at:1413: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Now at end of input. +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token "end of input" (1.1: ) +stderr: input: ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} @@ -112600,17 +114557,23 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -./calc.at:1409: cat stderr - | (#) + (#) = 2222 -./calc.at:1408: $PREPARSER ./calc input - | 1 + 2 * 3 + !* ++ stderr: -./calc.at:1414: cat stderr -./calc.at:1411: $PREPARSER ./calc input +./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: stderr: +./calc.at:1431: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + stderr: -./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: Starting parse Entering state 0 Reading a token @@ -112630,7 +114593,7 @@ Next token is token ')' (1.3: ) Shifting token ')' (1.3: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2: ) $3 = token ')' (1.3: ) @@ -112657,7 +114620,7 @@ Next token is token ')' (1.9: ) Shifting token ')' (1.9: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.7: ) $2 = token error (1.8: ) $3 = token ')' (1.9: ) @@ -112665,7 +114628,7 @@ Entering state 30 Reading a token Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 105): +Reducing stack 0 by rule 7 (line 99): $1 = nterm exp (1.1-3: 1111) $2 = token '+' (1.5: ) $3 = nterm exp (1.7-9: 1111) @@ -112708,7 +114671,14 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + 1) / (1 - 1) +./calc.at:1409: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Now at end of input. +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token "end of input" (1.1: ) Starting parse Entering state 0 Reading a token @@ -112720,9 +114690,9 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 19 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) @@ -112730,51 +114700,164 @@ Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) -Entering state 30 +Entering state 28 Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Error: popping token '=' (1.3: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '=' (1.7: ) +stderr: +Starting parse +Entering state 0 Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Reading a token +Next token is token "number" (1.6: 1) +Shifting token "number" (1.6: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.6: 1) +-> $$ = nterm exp (1.6: 1) Entering state 30 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) +Reading a token +Next token is token ')' (1.7: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 27 +Reducing stack 0 by rule 13 (line 125): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 23 Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Reducing stack 0 by rule 19 (line 119): - $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Reading a token +Next token is token "number" (1.12: 1) +Shifting token "number" (1.12: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 20 +Reading a token +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 29 +Reading a token +Next token is token ')' (1.17: ) +Reducing stack 0 by rule 8 (line 106): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 27 +Reducing stack 0 by rule 13 (line 125): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 32 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 10 (line 108): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) +Entering state 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +input: + | (# + 1) = 1111 +./calc.at:1407: $PREPARSER ./calc input +./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1414: cat stderr + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1431: $PREPARSER ./calc input +stderr: +./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1416: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: Starting parse Entering state 0 Reading a token @@ -112782,27 +114865,134 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) Entering state 21 Reading a token +Next token is token "number" (1.6: 1) +Shifting token "number" (1.6: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 30 +Reading a token +Next token is token ')' (1.7: ) +Reducing stack 0 by rule 7 (line 105): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 27 +Reducing stack 0 by rule 13 (line 125): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) +Entering state 8 +Reading a token +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 23 +Reading a token +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Reading a token +Next token is token "number" (1.12: 1) +Shifting token "number" (1.12: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 20 +Reading a token +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 29 +Reading a token +Next token is token ')' (1.17: ) +Reducing stack 0 by rule 8 (line 106): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 27 +Reducing stack 0 by rule 13 (line 125): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 32 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 10 (line 108): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) +Entering state 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) -Error: popping token '+' (1.1: ) -Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) Error: discarding token error (1.1: ) Reading a token +Next token is token '+' (1.1: ) +Error: discarding token '+' (1.1: ) +Reading a token +Next token is token "number" (1.1: 1) +Error: discarding token "number" (1.1: 1) +Reading a token Next token is token ')' (1.1: ) Entering state 11 Next token is token ')' (1.1: ) @@ -112852,181 +115042,180 @@ Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) -./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1411: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 19 Reading a token -Next token is token ')' (1.3: ) -Entering state 11 -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 28 Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 21 +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Error: popping token '=' (1.3: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '=' (1.7: ) +./calc.at:1431: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1416: cat stderr +input: +stderr: +./calc.at:1409: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | + | +1 +./calc.at:1414: $PREPARSER ./calc input +Starting parse +Entering state 0 Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Reading a token -1.8: syntax error: invalid character: '#' -Next token is token error (1.8: ) -Shifting token error (1.8: ) +syntax error: invalid character: '#' +Next token is token error (1.1: ) +Shifting token error (1.1: ) Entering state 11 -Next token is token error (1.8: ) -Error: discarding token error (1.8: ) +Next token is token error (1.1: ) +Error: discarding token error (1.1: ) Reading a token -Next token is token ')' (1.9: ) +Next token is token '+' (1.1: ) +Error: discarding token '+' (1.1: ) +Reading a token +Next token is token "number" (1.1: 1) +Error: discarding token "number" (1.1: 1) +Reading a token +Next token is token ')' (1.1: ) Entering state 11 -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 30 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) +Reducing stack 0 by rule 14 (line 119): + $1 = token '(' (1.1: ) + $2 = token error (1.1: ) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 1111) Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) +Reading a token +Next token is token '=' (1.1: ) +Shifting token '=' (1.1: ) Entering state 19 Reading a token -Next token is token "number" (1.13-16: 2222) -Shifting token "number" (1.13-16: 2222) +Next token is token "number" (1.1: 1111) +Shifting token "number" (1.1: 1111) Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) Entering state 28 Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) +Next token is token '\n' (1.1: ) +Reducing stack 0 by rule 6 (line 82): + $1 = nterm exp (1.1: 1111) + $2 = token '=' (1.1: ) + $3 = nterm exp (1.1: 1111) +-> $$ = nterm exp (1.1: 1111) Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) +Reducing stack 0 by rule 4 (line 77): + $1 = nterm exp (1.1: 1111) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) +Reducing stack 0 by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) +Shifting token "end of input" (1.1: ) Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -input: +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) stderr: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1413: $PREPARSER ./calc input +./calc.at:1411: cat stderr +./calc.at:1413: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1409: cat stderr input: -stderr: Starting parse Entering state 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 83): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Reducing stack 0 by rule 19 (line 119): - $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) - | - | +1 -./calc.at:1414: $PREPARSER ./calc input +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Cleanup: discarding lookahead token '+' (2.1: ) + | 1 2 +input: +./calc.at:1431: $PREPARSER ./calc input + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1416: $PREPARSER ./calc input +./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +517. calc.at:1409: ok +./calc.at:1413: cat stderr +stderr: +input: + | (1 + #) = 1111 stderr: +./calc.at:1411: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -113274,7 +115463,9 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +syntax error +./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -113285,7 +115476,87 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) +Reading a token +Next token is token ')' (1.7: ) +Entering state 11 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 114): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Reading a token +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: Starting parse Entering state 0 Reading a token @@ -113305,18 +115576,91 @@ 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) +syntax error stderr: +input: stderr: -./calc.at:1408: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 + | + | +1 +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) +Reading a token +Next token is token ')' (1.7: ) +Entering state 11 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 114): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Reading a token +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) + +./calc.at:1407: cat stderr Starting parse Entering state 0 Reading a token @@ -113564,8 +115908,8 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | (#) + (#) = 2222 -./calc.at:1409: $PREPARSER ./calc input +./calc.at:1413: $PREPARSER ./calc input +stderr: Starting parse Entering state 0 Reading a token @@ -113585,6 +115929,17 @@ 2.1: syntax error, unexpected '+' Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) +./calc.at:1416: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -113595,113 +115950,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1411: cat stderr -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token ')' (1.3: ) -Entering state 11 -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 21 -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Reading a token -1.8: syntax error: invalid character: '#' -Next token is token error (1.8: ) -Shifting token error (1.8: ) -Entering state 11 -Next token is token error (1.8: ) -Error: discarding token error (1.8: ) -Reading a token -Next token is token ')' (1.9: ) -Entering state 11 -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 30 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 19 -Reading a token -Next token is token "number" (1.13-16: 2222) -Shifting token "number" (1.13-16: 2222) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 28 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1407: cat stderr -./calc.at:1408: cat stderr -input: - | (#) + (#) = 2222 -./calc.at:1411: $PREPARSER ./calc input -./calc.at:1416: "$PERL" -pi -e 'use strict; +./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -113711,108 +115960,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token ')' (1.3: ) -Entering state 11 -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 21 -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Reading a token -1.8: syntax error: invalid character: '#' -Next token is token error (1.8: ) -Shifting token error (1.8: ) -Entering state 11 -Next token is token error (1.8: ) -Error: discarding token error (1.8: ) -Reading a token -Next token is token ')' (1.9: ) -Entering state 11 -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 30 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 19 -Reading a token -Next token is token "number" (1.13-16: 2222) -Shifting token "number" (1.13-16: 2222) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 28 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1416: cat stderr -./calc.at:1413: "$PERL" -pi -e 'use strict; +input: +./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -113822,6 +115971,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1416: cat stderr +./calc.at:1411: cat stderr + | (1 + # + 1) = 1111 +./calc.at:1407: $PREPARSER ./calc input +stderr: +./calc.at:1414: cat stderr Starting parse Entering state 0 Reading a token @@ -113842,7 +115997,6 @@ Error: popping nterm input (1.1-2.0: ) Cleanup: discarding lookahead token '+' (2.1: ) stderr: -./calc.at:1413: cat stderr Starting parse Entering state 0 Reading a token @@ -113850,232 +116004,22 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token ')' (1.3: ) -Entering state 11 -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 21 -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Reading a token -1.8: syntax error: invalid character: '#' -Next token is token error (1.8: ) -Shifting token error (1.8: ) -Entering state 11 -Next token is token error (1.8: ) -Error: discarding token error (1.8: ) -Reading a token -Next token is token ')' (1.9: ) -Entering state 11 -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 30 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 19 -Reading a token -Next token is token "number" (1.13-16: 2222) -Shifting token "number" (1.13-16: 2222) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 28 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token ')' (1.3: ) -Entering state 11 -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) Entering state 21 Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Reading a token -1.8: syntax error: invalid character: '#' -Next token is token error (1.8: ) -Shifting token error (1.8: ) -Entering state 11 -Next token is token error (1.8: ) -Error: discarding token error (1.8: ) -Reading a token -Next token is token ')' (1.9: ) -Entering state 11 -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 30 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 19 -Reading a token -Next token is token "number" (1.13-16: 2222) -Shifting token "number" (1.13-16: 2222) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 28 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -input: -input: - | (1 + #) = 1111 -./calc.at:1408: $PREPARSER ./calc input - | (# + 1) = 1111 -./calc.at:1416: $PREPARSER ./calc /dev/null -./calc.at:1407: $PREPARSER ./calc input -./calc.at:1411: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -stderr: -./calc.at:1414: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) +Error: popping token '+' (1.1: ) +Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) @@ -114136,7 +116080,16 @@ Entering state 17 Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) -./calc.at:1409: "$PERL" -pi -e 'use strict; +./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1414: $PREPARSER ./calc /dev/null +./calc.at:1431: cat stderr +input: +stderr: +528. calc.at:1437: testing Calculator C++ %locations parse.error=verbose api.prefix={calc} %verbose ... +./calc.at:1437: mv calc.y.tmp calc.y + +./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -114146,89 +116099,19 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + | (!!) + (1 2) = 1 stderr: -./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1416: $PREPARSER ./calc input + | (# + 1) = 1111 Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) -Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) -Reading a token -Next token is token ')' (1.7: ) -Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token "end of input" (1.1: ) +./calc.at:1411: $PREPARSER ./calc input stderr: - | (!!) + (1 2) = 1 +./calc.at:1437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y Starting parse Entering state 0 Reading a token @@ -114236,100 +116119,22 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) Entering state 21 Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) -Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) -Reading a token -Next token is token ')' (1.7: ) -Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1413: $PREPARSER ./calc input -./calc.at:1411: cat stderr -Starting parse -Entering state 0 -Reading a token -Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" (1.1: ) -./calc.at:1414: cat stderr -stderr: -./calc.at:1409: cat stderr -stderr: -input: - | (1 + #) = 1111 -./calc.at:1411: $PREPARSER ./calc input -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token syntax error: invalid character: '#' Next token is token error (1.1: ) +Error: popping token '+' (1.1: ) +Error: popping nterm exp (1.1: 1) Shifting token error (1.1: ) Entering state 11 Next token is token error (1.1: ) @@ -114502,6 +116307,7 @@ Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: +./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -114509,115 +116315,18 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) -Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) -Reading a token -Next token is token ')' (1.7: ) +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1408: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 +Error: discarding token '+' (1.4: ) Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) -Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) +Next token is token "number" (1.6: 1) +Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 @@ -114668,21 +116377,11 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1408: cat stderr -./calc.at:1414: $PREPARSER ./calc /dev/null -./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1413: cat stderr +./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: - | (1 + #) = 1111 -stderr: +./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -Starting parse -Entering state 0 -Reading a token -Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" (1.1: ) -./calc.at:1409: $PREPARSER ./calc input stderr: Starting parse Entering state 0 @@ -114690,6 +116389,8 @@ Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) + | 1//2 +./calc.at:1413: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Reading a token @@ -114697,33 +116398,25 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 +Error: discarding token '+' (1.4: ) Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) -Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) +Next token is token "number" (1.6: 1) +Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) @@ -114767,108 +116460,16 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1411: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1431: $PREPARSER ./calc input +stderr: +stderr: stderr: Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) -Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) -Reading a token -Next token is token ')' (1.7: ) -Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1407: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -input: -./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token "end of input" (1.1: ) Starting parse Entering state 0 Reading a token @@ -114980,8 +116581,41 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | (# + 1) = 1111 -./calc.at:1408: $PREPARSER ./calc input +./calc.at:1407: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +syntax error +./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1411: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1437: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +./calc.at:1414: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1411: cat stderr stderr: ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} @@ -114993,103 +116627,25 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Reading a token -Next token is token "number" (1.6: 1) -Error: discarding token "number" (1.6: 1) -Reading a token -Next token is token ')' (1.7: ) -Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: -./calc.at:1432: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - -./calc.at:1411: cat stderr -./calc.at:1416: cat stderr -./calc.at:1407: cat stderr stderr: +./calc.at:1414: cat stderr +syntax error Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token "end of input" (1.1: ) +./calc.at:1407: cat stderr +./calc.at:1416: cat stderr input: - | (# + 1) = 1111 input: -./calc.at:1409: "$PERL" -pi -e 'use strict; + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1414: $PREPARSER ./calc input +input: + | (1 + 1) / (1 - 1) +./calc.at:1407: $PREPARSER ./calc input +./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -115099,11 +116655,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1411: $PREPARSER ./calc input -stderr: stderr: | (1 + # + 1) = 1111 -./calc.at:1407: $PREPARSER ./calc input +./calc.at:1411: $PREPARSER ./calc input +stderr: Starting parse Entering state 0 Reading a token @@ -115111,72 +116666,46 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Reading a token -Next token is token "number" (1.6: 1) -Error: discarding token "number" (1.6: 1) -Reading a token -Next token is token ')' (1.7: ) -Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 30 Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) +Next token is token ')' (1.1: ) +Reducing stack 0 by rule 7 (line 98): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1) +-> $$ = nterm exp (1.1: 2) +Entering state 12 +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 27 +Reducing stack 0 by rule 13 (line 118): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.1: 2) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 2) Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 +Next token is token '/' (1.1: ) +Shifting token '/' (1.1: ) +Entering state 23 Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) @@ -115190,61 +116719,48 @@ -> $$ = nterm exp (1.1: 1) Entering state 12 Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Reading a token -syntax error: invalid character: '#' -Next token is token error (1.1: ) -Error: popping token '+' (1.1: ) -Error: popping nterm exp (1.1: 1) -Shifting token error (1.1: ) -Entering state 11 -Next token is token error (1.1: ) -Error: discarding token error (1.1: ) -Reading a token -Next token is token '+' (1.1: ) -Error: discarding token '+' (1.1: ) +Next token is token '-' (1.1: ) +Shifting token '-' (1.1: ) +Entering state 20 Reading a token Next token is token "number" (1.1: 1) -Error: discarding token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 29 Reading a token Next token is token ')' (1.1: ) -Entering state 11 +Reducing stack 0 by rule 8 (line 99): + $1 = nterm exp (1.1: 1) + $2 = token '-' (1.1: ) + $3 = nterm exp (1.1: 1) +-> $$ = nterm exp (1.1: 0) +Entering state 12 Next token is token ')' (1.1: ) Shifting token ')' (1.1: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 119): +Entering state 27 +Reducing stack 0 by rule 13 (line 118): $1 = token '(' (1.1: ) - $2 = token error (1.1: ) + $2 = nterm exp (1.1: 0) $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 -Reading a token -Next token is token "number" (1.1: 1111) -Shifting token "number" (1.1: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 1111) --> $$ = nterm exp (1.1: 1111) -Entering state 28 +-> $$ = nterm exp (1.1: 0) +Entering state 32 Reading a token Next token is token '\n' (1.1: ) -Reducing stack 0 by rule 6 (line 82): - $1 = nterm exp (1.1: 1111) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 1111) +Reducing stack 0 by rule 10 (line 101): + $1 = nterm exp (1.1: 2) + $2 = token '/' (1.1: ) + $3 = nterm exp (1.1: 0) +error: null divisor +-> $$ = nterm exp (1.1: 2) Entering state 8 Next token is token '\n' (1.1: ) Shifting token '\n' (1.1: ) Entering state 25 Reducing stack 0 by rule 4 (line 77): - $1 = nterm exp (1.1: 1111) + $1 = nterm exp (1.1: 2) $2 = token '\n' (1.1: ) -> $$ = nterm line (1.1: ) Entering state 7 @@ -115259,9 +116775,17 @@ Cleanup: popping token "end of input" (1.1: ) Cleanup: popping nterm input (1.1: ) ./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1409: cat stderr input: -stderr: +./calc.at:1431: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -115269,445 +116793,156 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 114): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 Reading a token Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 Reading a token -Next token is token "number" (1.6: 1) -Error: discarding token "number" (1.6: 1) +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 Reading a token -Next token is token ')' (1.7: ) -Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 +Next token is token "number" (1.7: 1) +Shifting token "number" (1.7: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.7: 1) +-> $$ = nterm exp (1.7: 1) +Entering state 12 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 21 Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) +Next token is token "number" (1.11: 1) +Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 + $1 = token "number" (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 30 Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 +Next token is token '+' (1.13: ) +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 21 Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -Starting parse -Entering state 0 +Next token is token "number" (1.15: 1) +Shifting token "number" (1.15: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 30 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) +Next token is token '+' (1.17: ) +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 21 +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Error: popping nterm exp (1.7-15: 3) +Shifting token error (1.7-18: ) +Entering state 11 +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 114): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 30 +Reading a token +Next token is token '+' (1.20: ) +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) +Entering state 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 21 +Reading a token +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) Entering state 4 Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) Reading a token -Next token is token "number" (1.6: 1) -Error: discarding token "number" (1.6: 1) +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) Reading a token -Next token is token ')' (1.7: ) +Next token is token ')' (1.28: ) Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 30 +Reading a token +Next token is token '+' (1.30: ) +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) Entering state 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +Entering state 21 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) +Entering state 4 Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) +Next token is token "number" (1.33: 1) +Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1413: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1432: $PREPARSER ./calc input -input: -input: -./calc.at:1413: cat stderr -stderr: -./calc.at:1411: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1408: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1416: $PREPARSER ./calc input -./calc.at:1411: cat stderr -stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Reading a token -syntax error: invalid character: '#' -Next token is token error (1.1: ) -Error: popping token '+' (1.1: ) -Error: popping nterm exp (1.1: 1) -Shifting token error (1.1: ) -Entering state 11 -Next token is token error (1.1: ) -Error: discarding token error (1.1: ) -Reading a token -Next token is token '+' (1.1: ) -Error: discarding token '+' (1.1: ) -Reading a token -Next token is token "number" (1.1: 1) -Error: discarding token "number" (1.1: 1) -Reading a token -Next token is token ')' (1.1: ) -Entering state 11 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 119): - $1 = token '(' (1.1: ) - $2 = token error (1.1: ) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.1: ) -Shifting token '=' (1.1: ) -Entering state 19 -Reading a token -Next token is token "number" (1.1: 1111) -Shifting token "number" (1.1: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 1111) --> $$ = nterm exp (1.1: 1111) -Entering state 28 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack 0 by rule 6 (line 82): - $1 = nterm exp (1.1: 1111) - $2 = token '=' (1.1: ) - $3 = nterm exp (1.1: 1111) --> $$ = nterm exp (1.1: 1111) -Entering state 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 77): - $1 = nterm exp (1.1: 1111) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) -./calc.at:1414: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1432: $EGREP -c -v 'Return for a new token:|LAC:' stderr - | (# + 1) = 1111 -./calc.at:1409: $PREPARSER ./calc input -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Reading a token -Next token is token "number" (1.7: 1) -Shifting token "number" (1.7: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 21 -Reading a token -Next token is token "number" (1.11: 1) -Shifting token "number" (1.11: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.11: 1) --> $$ = nterm exp (1.11: 1) -Entering state 30 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 21 -Reading a token -Next token is token "number" (1.15: 1) -Shifting token "number" (1.15: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 30 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 21 -Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Error: popping nterm exp (1.7-15: 3) -Shifting token error (1.7-18: ) -Entering state 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) -Entering state 30 -Reading a token -Next token is token '+' (1.20: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) -Entering state 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) -Entering state 21 -Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) -Reading a token -Next token is token ')' (1.28: ) -Entering state 11 -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 30 -Reading a token -Next token is token '+' (1.30: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) -Entering state 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) -Entering state 21 -Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) -Entering state 4 -Reading a token -Next token is token "number" (1.33: 1) -Shifting token "number" (1.33: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 + $1 = token "number" (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 Reading a token Next token is token '*' (1.35: ) Shifting token '*' (1.35: ) @@ -115798,91 +117033,11 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: -./calc.at:1408: cat stderr -input: -input: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Reading a token -Next token is token "number" (1.6: 1) -Error: discarding token "number" (1.6: 1) -Reading a token -Next token is token ')' (1.7: ) -Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) | (- *) + (1 2) = 1 -./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1414: cat stderr -./calc.at:1413: $PREPARSER ./calc input -input: - | (1 + # + 1) = 1111 -./calc.at:1411: $PREPARSER ./calc input - | 1 2 -./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1432: $PREPARSER ./calc input +./calc.at:1416: $PREPARSER ./calc input stderr: stderr: +./calc.at:1413: cat stderr stderr: Starting parse Entering state 0 @@ -115967,18 +117122,123 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.1: ) +Shifting token '+' (1.1: ) +Entering state 21 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 30 +Reading a token +Next token is token ')' (1.1: ) +Reducing stack 0 by rule 7 (line 98): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.1: ) + $3 = nterm exp (1.1: 1) +-> $$ = nterm exp (1.1: 2) +Entering state 12 +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 27 +Reducing stack 0 by rule 13 (line 118): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.1: 2) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 2) +Entering state 8 +Reading a token +Next token is token '/' (1.1: ) +Shifting token '/' (1.1: ) +Entering state 23 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 12 +Reading a token +Next token is token '-' (1.1: ) +Shifting token '-' (1.1: ) +Entering state 20 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 81): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 29 +Reading a token +Next token is token ')' (1.1: ) +Reducing stack 0 by rule 8 (line 99): + $1 = nterm exp (1.1: 1) + $2 = token '-' (1.1: ) + $3 = nterm exp (1.1: 1) +-> $$ = nterm exp (1.1: 0) +Entering state 12 +Next token is token ')' (1.1: ) +Shifting token ')' (1.1: ) +Entering state 27 +Reducing stack 0 by rule 13 (line 118): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.1: 0) + $3 = token ')' (1.1: ) +-> $$ = nterm exp (1.1: 0) +Entering state 32 +Reading a token +Next token is token '\n' (1.1: ) +Reducing stack 0 by rule 10 (line 101): + $1 = nterm exp (1.1: 2) + $2 = token '/' (1.1: ) + $3 = nterm exp (1.1: 0) +error: null divisor +-> $$ = nterm exp (1.1: 2) +Entering state 8 +Next token is token '\n' (1.1: ) +Shifting token '\n' (1.1: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 77): + $1 = nterm exp (1.1: 2) + $2 = token '\n' (1.1: ) +-> $$ = nterm line (1.1: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 71): + $1 = nterm line (1.1: ) +-> $$ = nterm input (1.1: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (1.1: ) +Entering state 17 +Cleanup: popping token "end of input" (1.1: ) +Cleanup: popping nterm input (1.1: ) +./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1407: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -116095,164 +117355,11 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Reading a token -Next token is token "number" (1.6: 1) -Error: discarding token "number" (1.6: 1) -Reading a token -Next token is token ')' (1.7: ) -Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 -Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -1.3: syntax error -stderr: -./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1431: cat stderr stderr: +./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) -Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) -Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Reading a token -Next token is token "number" (1.10: 1) -Error: discarding token "number" (1.10: 1) -Reading a token -Next token is token ')' (1.11: ) -Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) -Entering state 19 -Reading a token -Next token is token "number" (1.15-18: 1111) -Shifting token "number" (1.15-18: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) -Entering state 28 -Reading a token -Next token is token '\n' (1.19-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) -Entering state 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - | (1 + # + 1) = 1111 +stderr: Starting parse Entering state 0 Reading a token @@ -116500,144 +117607,6 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1408: $PREPARSER ./calc input -./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1407: cat stderr -./calc.at:1409: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1409: cat stderr -stderr: -input: -stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Reducing stack 0 by rule 15 (line 115): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Shifting token error (1.2-4: ) -Entering state 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 21 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Reading a token -Next token is token "number" (1.10: 1) -Shifting token "number" (1.10: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Reading a token -Next token is token "number" (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Shifting token error (1.10-12: ) -Entering state 11 -Next token is token "number" (1.12: 2) -Error: discarding token "number" (1.12: 2) -Reading a token -Next token is token ')' (1.13: ) -Entering state 11 -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) -Entering state 30 -Reading a token -Next token is token '=' (1.15: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) -Entering state 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) -Entering state 19 -Reading a token -Next token is token "number" (1.17: 1) -Shifting token "number" (1.17: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.17: 1) --> $$ = nterm exp (1.17: 1) -Entering state 28 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) -Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -1.3: syntax error -input: -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 Starting parse Entering state 0 Reading a token @@ -116677,7 +117646,7 @@ Next token is token ')' (1.11: ) Shifting token ')' (1.11: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) @@ -116721,24 +117690,12 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1414: $PREPARSER ./calc input -./calc.at:1411: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (1 + 1) / (1 - 1) -./calc.at:1407: $PREPARSER ./calc input - | (1 + # + 1) = 1111 -./calc.at:1409: $PREPARSER ./calc input -stderr: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +input: +./calc.at:1413: $PREPARSER ./calc input + | error stderr: +./calc.at:1431: $PREPARSER ./calc input stderr: Starting parse Entering state 0 @@ -116747,70 +117704,103 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Reducing stack 0 by rule 15 (line 115): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Shifting token error (1.2-4: ) +Entering state 11 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) +Next token is token ')' (1.5: ) Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 114): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 21 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 Reading a token Next token is token "number" (1.10: 1) -Error: discarding token "number" (1.10: 1) +Shifting token "number" (1.10: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 Reading a token -Next token is token ')' (1.11: ) +Next token is token "number" (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Shifting token error (1.10-12: ) Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token "number" (1.12: 2) +Error: discarding token "number" (1.12: 2) +Reading a token +Next token is token ')' (1.13: ) +Entering state 11 +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) -Entering state 8 +Reducing stack 0 by rule 14 (line 114): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 30 Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) +Next token is token '=' (1.15: ) +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) +Entering state 8 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) Entering state 19 Reading a token -Next token is token "number" (1.15-18: 1111) -Shifting token "number" (1.15-18: 1111) +Next token is token "number" (1.17: 1) +Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) + $1 = token "number" (1.17: 1) +-> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token -Next token is token '\n' (1.19-2.0: ) +Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) Entering state 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): @@ -116830,121 +117820,6 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 30 -Reading a token -Next token is token ')' (1.1: ) -Reducing stack 0 by rule 7 (line 98): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1) --> $$ = nterm exp (1.1: 2) -Entering state 12 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 118): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.1: 2) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 2) -Entering state 8 -Reading a token -Next token is token '/' (1.1: ) -Shifting token '/' (1.1: ) -Entering state 23 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Reading a token -Next token is token '-' (1.1: ) -Shifting token '-' (1.1: ) -Entering state 20 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 29 -Reading a token -Next token is token ')' (1.1: ) -Reducing stack 0 by rule 8 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '-' (1.1: ) - $3 = nterm exp (1.1: 1) --> $$ = nterm exp (1.1: 0) -Entering state 12 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 118): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.1: 0) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 0) -Entering state 32 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack 0 by rule 10 (line 101): - $1 = nterm exp (1.1: 2) - $2 = token '/' (1.1: ) - $3 = nterm exp (1.1: 0) -error: null divisor --> $$ = nterm exp (1.1: 2) -Entering state 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 77): - $1 = nterm exp (1.1: 2) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token Next token is token ')' (1.2: ) 1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) @@ -117185,94 +118060,7 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: -./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1407: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1411: cat stderr -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) -Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) -Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Reading a token -Next token is token "number" (1.10: 1) -Error: discarding token "number" (1.10: 1) -Reading a token -Next token is token ')' (1.11: ) -Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) -Entering state 19 -Reading a token -Next token is token "number" (1.15-18: 1111) -Shifting token "number" (1.15-18: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) -Entering state 28 -Reading a token -Next token is token '\n' (1.19-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) -Entering state 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1416: "$PERL" -pi -e 'use strict; +./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -117283,7 +118071,7 @@ }eg ' expout || exit 77 stderr: -./calc.at:1432: "$PERL" -pi -e 'use strict; +./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -117293,91 +118081,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) -Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) -Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Reading a token -Next token is token "number" (1.10: 1) -Error: discarding token "number" (1.10: 1) -Reading a token -Next token is token ')' (1.11: ) -Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 126): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) -Entering state 19 -Reading a token -Next token is token "number" (1.15-18: 1111) -Shifting token "number" (1.15-18: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) -Entering state 28 -Reading a token -Next token is token '\n' (1.19-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) -Entering state 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1413: "$PERL" -pi -e 'use strict; +./calc.at:1407: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -117387,139 +118091,13 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1411: cat stderr +./calc.at:1414: cat stderr +syntax error +./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.1: ) -Shifting token '+' (1.1: ) -Entering state 21 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 30 -Reading a token -Next token is token ')' (1.1: ) -Reducing stack 0 by rule 7 (line 98): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.1: ) - $3 = nterm exp (1.1: 1) --> $$ = nterm exp (1.1: 2) -Entering state 12 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 118): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.1: 2) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 2) -Entering state 8 -Reading a token -Next token is token '/' (1.1: ) -Shifting token '/' (1.1: ) -Entering state 23 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 12 -Reading a token -Next token is token '-' (1.1: ) -Shifting token '-' (1.1: ) -Entering state 20 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 81): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 29 -Reading a token -Next token is token ')' (1.1: ) -Reducing stack 0 by rule 8 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '-' (1.1: ) - $3 = nterm exp (1.1: 1) --> $$ = nterm exp (1.1: 0) -Entering state 12 -Next token is token ')' (1.1: ) -Shifting token ')' (1.1: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 118): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.1: 0) - $3 = token ')' (1.1: ) --> $$ = nterm exp (1.1: 0) -Entering state 32 -Reading a token -Next token is token '\n' (1.1: ) -Reducing stack 0 by rule 10 (line 101): - $1 = nterm exp (1.1: 2) - $2 = token '/' (1.1: ) - $3 = nterm exp (1.1: 0) -error: null divisor --> $$ = nterm exp (1.1: 2) -Entering state 8 -Next token is token '\n' (1.1: ) -Shifting token '\n' (1.1: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 77): - $1 = nterm exp (1.1: 2) - $2 = token '\n' (1.1: ) --> $$ = nterm line (1.1: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 71): - $1 = nterm line (1.1: ) --> $$ = nterm input (1.1: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (1.1: ) -Entering state 17 -Cleanup: popping token "end of input" (1.1: ) -Cleanup: popping nterm input (1.1: ) -input: -./calc.at:1432: cat stderr - | (1 + 1) / (1 - 1) -./calc.at:1411: $PREPARSER ./calc input -stderr: -./calc.at:1413: cat stderr -./calc.at:1408: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1409: "$PERL" -pi -e 'use strict; +./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -117530,6 +118108,14 @@ }eg ' expout || exit 77 stderr: +syntax error +input: +input: +./calc.at:1416: cat stderr + | (1 + 1) / (1 - 1) +./calc.at:1411: $PREPARSER ./calc input + | (!!) + (1 2) = 1 +./calc.at:1414: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -117777,8 +118363,121 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -input: -input: +./calc.at:1407: cat stderr +stderr: +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Reading a token +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 16 +Reducing stack 0 by rule 16 (line 116): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Shifting token error (1.2-3: ) +Entering state 11 +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 114): + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) +Entering state 21 +Reading a token +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) +Entering state 4 +Reading a token +Next token is token "number" (1.9: 1) +Shifting token "number" (1.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.9: 1) +-> $$ = nterm exp (1.9: 1) +Entering state 12 +Reading a token +Next token is token "number" (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Shifting token error (1.9-11: ) +Entering state 11 +Next token is token "number" (1.11: 2) +Error: discarding token "number" (1.11: 2) +Reading a token +Next token is token ')' (1.12: ) +Entering state 11 +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 114): + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) +Entering state 30 +Reading a token +Next token is token '=' (1.14: ) +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) +Entering state 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) +Entering state 19 +Reading a token +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 +Reading a token +Next token is token '\n' (1.17-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token @@ -117895,8 +118594,10 @@ Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1411: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1416: cat stderr -./calc.at:1407: "$PERL" -pi -e 'use strict; +stdout: +515. calc.at:1407: ok +./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -117906,7 +118607,18 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1414: "$PERL" -pi -e 'use strict; +./calc.at:1432: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -117916,18 +118628,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1//2 -./calc.at:1432: $PREPARSER ./calc input -./calc.at:1409: cat stderr -./calc.at:1414: cat stderr -./calc.at:1408: cat stderr +input: | (* *) + (*) + (*) -./calc.at:1407: cat stderr -stderr: -./calc.at:1413: $PREPARSER ./calc input +./calc.at:1416: $PREPARSER ./calc input stderr: +./calc.at:1413: cat stderr stderr: -input: Starting parse Entering state 0 Reading a token @@ -118043,6 +118749,7 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +stderr: Starting parse Entering state 0 Reading a token @@ -118158,17 +118865,6 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.3: syntax error -./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (1 + 1) / (1 - 1) -./calc.at:1409: $PREPARSER ./calc input -input: -stderr: -stderr: -515. calc.at:1407: ok -1.3: syntax error - | (!!) + (1 2) = 1 input: Starting parse Entering state 0 @@ -118177,62 +118873,75 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 Reading a token -Next token is token "number" (1.6: 1) -Shifting token "number" (1.6: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 30 +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 16 +Reducing stack 0 by rule 16 (line 116): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Shifting token error (1.2-3: ) +Entering state 11 Reading a token -Next token is token ')' (1.7: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 125): +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 23 +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) +Entering state 21 Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) Entering state 4 Reading a token -Next token is token "number" (1.12: 1) -Shifting token "number" (1.12: 1) +Next token is token "number" (1.9: 1) +Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.12: 1) --> $$ = nterm exp (1.12: 1) + $1 = token "number" (1.9: 1) +-> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 20 +Next token is token "number" (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Shifting token error (1.9-11: ) +Entering state 11 +Next token is token "number" (1.11: 2) +Error: discarding token "number" (1.11: 2) +Reading a token +Next token is token ')' (1.12: ) +Entering state 11 +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 114): + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) +Entering state 30 +Reading a token +Next token is token '=' (1.14: ) +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) +Entering state 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) +Entering state 19 Reading a token Next token is token "number" (1.16: 1) Shifting token "number" (1.16: 1) @@ -118240,39 +118949,22 @@ Reducing stack 0 by rule 5 (line 88): $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) -Entering state 29 +Entering state 28 Reading a token -Next token is token ')' (1.17: ) -Reducing stack 0 by rule 8 (line 106): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) +Next token is token '\n' (1.17-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 125): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 32 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 10 (line 108): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): @@ -118285,13 +118977,23 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1416: $PREPARSER ./calc input -./calc.at:1409: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (1 + 1) / (1 - 1) -./calc.at:1408: $PREPARSER ./calc input -stderr: -input: -./calc.at:1432: "$PERL" -pi -e 'use strict; +./calc.at:1431: cat stderr +./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1432: $PREPARSER ./calc input +./calc.at:1411: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -118301,7 +119003,16 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +input: +stderr: + + | (!!) + (1 2) = 1 +./calc.at:1413: $PREPARSER ./calc input +./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +stderr: stderr: +./calc.at:1411: cat stderr Starting parse Entering state 0 Reading a token @@ -118413,123 +119124,16 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Reading a token -Next token is token "number" (1.6: 1) -Shifting token "number" (1.6: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 30 -Reading a token -Next token is token ')' (1.7: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 125): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) -Entering state 8 -Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 23 -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Reading a token -Next token is token "number" (1.12: 1) -Shifting token "number" (1.12: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 20 -Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 29 -Reading a token -Next token is token ')' (1.17: ) -Reducing stack 0 by rule 8 (line 106): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 125): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 32 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 10 (line 108): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) -Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1414: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -118645,136 +119249,18 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | (!!) + (1 2) = 1 -./calc.at:1414: $PREPARSER ./calc input -./calc.at:1408: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 = 2 = 3 +./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1431: $PREPARSER ./calc input stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Reading a token -Next token is token "number" (1.6: 1) -Shifting token "number" (1.6: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 30 -Reading a token -Next token is token ')' (1.7: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 125): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) -Entering state 8 -Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 23 -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Reading a token -Next token is token "number" (1.12: 1) -Shifting token "number" (1.12: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 20 -Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 29 -Reading a token -Next token is token ')' (1.17: ) -Reducing stack 0 by rule 8 (line 106): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 125): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 32 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 10 (line 108): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) -Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1413: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1411: "$PERL" -pi -e 'use strict; +./calc.at:1432: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1414: cat stderr +stderr: +518. calc.at:1411: ok +stderr: +syntax error +./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -118791,123 +119277,6 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Reading a token -Next token is token "number" (1.6: 1) -Shifting token "number" (1.6: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 30 -Reading a token -Next token is token ')' (1.7: ) -Reducing stack 0 by rule 7 (line 105): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 125): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) -Entering state 8 -Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 23 -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Reading a token -Next token is token "number" (1.12: 1) -Shifting token "number" (1.12: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 20 -Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 29 -Reading a token -Next token is token ')' (1.17: ) -Reducing stack 0 by rule 8 (line 106): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 125): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 32 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 10 (line 108): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) -Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -stderr: -./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token Next token is token '!' (1.2: ) Shifting token '!' (1.2: ) Entering state 5 @@ -119012,472 +119381,124 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - -./calc.at:1432: cat stderr -./calc.at:1413: cat stderr -./calc.at:1411: cat stderr -./calc.at:1408: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +stderr: input: - | 1 + 2 * 3 + !+ ++ -./calc.at:1413: $PREPARSER ./calc input input: -stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 16 -Reducing stack 0 by rule 16 (line 116): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Shifting token error (1.2-3: ) -Entering state 11 -Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) -Entering state 21 -Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) -Entering state 4 -Reading a token -Next token is token "number" (1.9: 1) -Shifting token "number" (1.9: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 1) --> $$ = nterm exp (1.9: 1) -Entering state 12 -Reading a token -Next token is token "number" (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Shifting token error (1.9-11: ) -Entering state 11 -Next token is token "number" (1.11: 2) -Error: discarding token "number" (1.11: 2) -Reading a token -Next token is token ')' (1.12: ) -Entering state 11 -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) -Entering state 30 -Reading a token -Next token is token '=' (1.14: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) -Entering state 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) -Entering state 19 -Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 28 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -518. calc.at:1411: ok - | error +syntax error + | (- *) + (1 2) = 1 +./calc.at:1416: cat stderr +529. calc.at:1438: testing Calculator C++ %locations parse.error=verbose %debug %name-prefix "calc" %verbose ... + | 1 2 +./calc.at:1414: $PREPARSER ./calc input ./calc.at:1432: $PREPARSER ./calc input -./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Reducing stack 0 by rule 17 (line 117): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1408: cat stderr -stderr: -./calc.at:1409: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1409: cat stderr -./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -516. calc.at:1408: ok -1.1: syntax error -./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Reducing stack 0 by rule 17 (line 117): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1438: mv calc.y.tmp calc.y -input: -./calc.at:1416: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: - | 1 + 2 * 3 + !- ++ -./calc.at:1413: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Reducing stack 0 by rule 18 (line 118): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -517. calc.at:1409: 1.1: syntax error - ok -Starting parse -Entering state 0 -Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 16 -Reducing stack 0 by rule 16 (line 116): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Shifting token error (1.2-3: ) +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Reducing stack 0 by rule 15 (line 115): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Shifting token error (1.2-4: ) Entering state 11 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) +Next token is token ')' (1.5: ) +Entering state 11 +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) Entering state 21 Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) Entering state 4 Reading a token -Next token is token "number" (1.9: 1) -Shifting token "number" (1.9: 1) +Next token is token "number" (1.10: 1) +Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 1) --> $$ = nterm exp (1.9: 1) + $1 = token "number" (1.10: 1) +-> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token -Next token is token "number" (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Shifting token error (1.9-11: ) +Next token is token "number" (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Shifting token error (1.10-12: ) Entering state 11 -Next token is token "number" (1.11: 2) -Error: discarding token "number" (1.11: 2) +Next token is token "number" (1.12: 2) +Error: discarding token "number" (1.12: 2) Reading a token -Next token is token ')' (1.12: ) +Next token is token ')' (1.13: ) Entering state 11 -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) Entering state 30 Reading a token -Next token is token '=' (1.14: ) +Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) Entering state 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) Entering state 19 Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) +Next token is token "number" (1.17: 1) +Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) + $1 = token "number" (1.17: 1) +-> $$ = nterm exp (1.17: 1) Entering state 28 Reading a token -Next token is token '\n' (1.17-2.0: ) +Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): @@ -119490,82 +119511,6 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -527. calc.at:1435: testing Calculator C++ %header %locations parse.error=verbose %name-prefix "calc" %verbose ... -./calc.at:1435: mv calc.y.tmp calc.y - -./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1416: cat stderr -stderr: - -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Reducing stack 0 by rule 18 (line 118): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1435: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -528. calc.at:1437: testing Calculator C++ %locations parse.error=verbose api.prefix={calc} %verbose ... -./calc.at:1437: mv calc.y.tmp calc.y - ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -119576,66 +119521,16 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -./calc.at:1414: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.3: syntax error input: -./calc.at:1432: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1413: cat stderr stderr: -stdout: -./calc.at:1433: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - -./calc.at:1414: cat stderr - | (- *) + (1 2) = 1 -input: + | 1 + 2 * 3 + !+ ++ ./calc.at:1416: $PREPARSER ./calc input -input: - | 1 + 2 * 3 + !* ++ -./calc.at:1432: cat stderr -stderr: -./calc.at:1413: $PREPARSER ./calc input - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1433: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -119753,10 +119648,19 @@ Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: -./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1433: $EGREP -c -v 'Return for a new token:|LAC:' stderr +1.3: syntax error +./calc.at:1431: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: +input: Starting parse Entering state 0 Reading a token @@ -119814,30 +119718,41 @@ Shifting token '!' (1.13: ) Entering state 5 Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Reducing stack 0 by rule 19 (line 119): +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted + $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -input: - | 1 2 -./calc.at:1433: $PREPARSER ./calc input -./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (- *) + (1 2) = 1 +./calc.at:1413: $PREPARSER ./calc input +./calc.at:1414: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: +530. calc.at:1440: testing Calculator C++ %locations parse.error=verbose %debug api.prefix={calc} %verbose ... ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1435: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS - | 1 = 2 = 3 -./calc.at:1432: $PREPARSER ./calc input -1.3: syntax error -./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -stderr: +./calc.at:1432: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1440: mv calc.y.tmp calc.y + Starting parse Entering state 0 Reading a token @@ -119954,11 +119869,12 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -1.3: syntax error -1.7: syntax error -input: -./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +./calc.at:1431: cat stderr +./calc.at:1414: cat stderr +./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./calc.at:1438: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS Starting parse Entering state 0 Reading a token @@ -120016,33 +119932,24 @@ Shifting token '!' (1.13: ) Entering state 5 Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Reducing stack 0 by rule 19 (line 119): +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted + $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) - | (- *) + (1 2) = 1 +input: +input: + | 1 + 2 * 3 + !- ++ stderr: -./calc.at:1414: $PREPARSER ./calc input -529. calc.at:1438: testing Calculator C++ %locations parse.error=verbose %debug %name-prefix "calc" %verbose ... -1.7: syntax error +./calc.at:1416: $PREPARSER ./calc input + | + | +1 +input: +./calc.at:1431: $PREPARSER ./calc input stderr: -./calc.at:1433: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1438: mv calc.y.tmp calc.y - Starting parse Entering state 0 Reading a token @@ -120159,182 +120066,80 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -./calc.at:1437: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -530. calc.at:1440: testing Calculator C++ %locations parse.error=verbose %debug api.prefix={calc} %verbose ... -./calc.at:1440: mv calc.y.tmp calc.y - -./calc.at:1416: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1440: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -./calc.at:1413: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1432: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1413: cat stderr +./calc.at:1432: cat stderr Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Reducing stack 0 by rule 15 (line 115): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Shifting token error (1.2-4: ) -Entering state 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 21 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Reading a token -Next token is token "number" (1.10: 1) -Shifting token "number" (1.10: 1) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Reading a token -Next token is token "number" (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Shifting token error (1.10-12: ) -Entering state 11 -Next token is token "number" (1.12: 2) -Error: discarding token "number" (1.12: 2) -Reading a token -Next token is token ')' (1.13: ) -Entering state 11 -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 30 Reading a token -Next token is token '=' (1.15: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) -Entering state 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) -Entering state 19 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 Reading a token -Next token is token "number" (1.17: 1) -Shifting token "number" (1.17: 1) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.17: 1) --> $$ = nterm exp (1.17: 1) -Entering state 28 + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 101): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1414: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1432: cat stderr -./calc.at:1416: cat stderr -./calc.at:1433: cat stderr -./calc.at:1414: cat stderr -input: - | (#) + (#) = 2222 -./calc.at:1413: $PREPARSER ./calc input -input: +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Reducing stack 0 by rule 18 (line 118): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) | (* *) + (*) + (*) +stderr: ./calc.at:1414: $PREPARSER ./calc input +syntax error +./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: Starting parse Entering state 0 Reading a token @@ -120450,15 +120255,93 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -input: - | (* *) + (*) + (*) -./calc.at:1416: $PREPARSER ./calc input -input: -input: +./calc.at:1413: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | 1//2 +./calc.at:1432: $PREPARSER ./calc input +stderr: ./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - | 1//2 +./calc.at:1413: cat stderr +stderr: +syntax error +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Reading a token +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 101): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Reducing stack 0 by rule 18 (line 118): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1440: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +1.3: syntax error stderr: +./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -120574,115 +120457,22 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1433: $PREPARSER ./calc input -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token ')' (1.3: ) -Entering state 11 -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 21 -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Reading a token -1.8: syntax error: invalid character: '#' -Next token is token error (1.8: ) -Shifting token error (1.8: ) -Entering state 11 -Next token is token error (1.8: ) -Error: discarding token error (1.8: ) -Reading a token -Next token is token ')' (1.9: ) -Entering state 11 -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 30 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 19 -Reading a token -Next token is token "number" (1.13-16: 2222) -Shifting token "number" (1.13-16: 2222) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 28 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - | - | +1 -./calc.at:1432: $PREPARSER ./calc input -stderr: +input: stderr: +./calc.at:1416: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (* *) + (*) + (*) +./calc.at:1413: $PREPARSER ./calc input 1.3: syntax error -./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1440: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -120798,11 +120588,111 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -2.1: syntax error -./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1416: cat stderr +./calc.at:1414: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1431: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1432: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: + | 1 + 2 * 3 + !* ++ +./calc.at:1416: $PREPARSER ./calc input +./calc.at:1414: cat stderr stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Reading a token +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 101): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Reducing stack 0 by rule 19 (line 119): + $1 = token '!' (1.13: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) stderr: -1.3: syntax error +./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -120918,162 +120808,13 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: -./calc.at:1438: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -2.1: syntax error -./calc.at:1433: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token ')' (1.3: ) -Entering state 11 -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 21 -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Reading a token -1.8: syntax error: invalid character: '#' -Next token is token error (1.8: ) -Shifting token error (1.8: ) -Entering state 11 -Next token is token error (1.8: ) -Error: discarding token error (1.8: ) -Reading a token -Next token is token ')' (1.9: ) -Entering state 11 -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 30 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 19 -Reading a token -Next token is token "number" (1.13-16: 2222) -Shifting token "number" (1.13-16: 2222) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 28 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -stderr: -./calc.at:1414: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1432: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stdout: -./calc.at:1416: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1431: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - -./calc.at:1414: cat stderr +./calc.at:1431: cat stderr input: + | 1 + 2 * 3 + !+ ++ +./calc.at:1431: $PREPARSER ./calc /dev/null +./calc.at:1414: $PREPARSER ./calc input +./calc.at:1432: cat stderr +stderr: ./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -121084,9 +120825,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1 + 2 * 3 + !+ ++ -./calc.at:1414: $PREPARSER ./calc input -input: stderr: Starting parse Entering state 0 @@ -121153,121 +120891,84 @@ $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1413: cat stderr - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1431: $PREPARSER ./calc input -./calc.at:1433: cat stderr -./calc.at:1416: cat stderr -./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -input: -./calc.at:1432: cat stderr - | error -./calc.at:1433: $PREPARSER ./calc input +syntax error +./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1432: $PREPARSER ./calc /dev/null -stderr: -1.1: syntax error -./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -stderr: - | (1 + #) = 1111 -./calc.at:1413: $PREPARSER ./calc input -stderr: Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 21 Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) -Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) -Reading a token -Next token is token ')' (1.7: ) -Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 101): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Reducing stack 0 by rule 19 (line 119): + $1 = token '!' (1.13: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1413: cat stderr + | error +./calc.at:1432: $PREPARSER ./calc input stderr: -input: - | 1 + 2 * 3 + !+ ++ -./calc.at:1416: $PREPARSER ./calc input stderr: +stderr: +syntax error Starting parse Entering state 0 Reading a token @@ -121333,9 +121034,38 @@ $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -stderr: +1.1: syntax error +./calc.at:1416: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: input: + | 1 + 2 * 3 + !- ++ +stderr: +./calc.at:1414: $PREPARSER ./calc input +./calc.at:1416: cat stderr + | 1 + 2 * 3 + !+ ++ stderr: +./calc.at:1413: $PREPARSER ./calc input +1.1: syntax error +./calc.at:1431: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -121393,25 +121123,30 @@ Shifting token '!' (1.13: ) Entering state 5 Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Reducing stack 0 by rule 17 (line 117): +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) + $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) - | 1 + 2 * 3 + !- ++ -./calc.at:1414: $PREPARSER ./calc input -./calc.at:1431: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.1: syntax error -./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.1: syntax error -stderr: -./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +input: + | (#) + (#) = 2222 +./calc.at:1416: $PREPARSER ./calc input +./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./calc.at:1432: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -121469,12 +121204,12 @@ Shifting token '!' (1.13: ) Entering state 5 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Reducing stack 0 by rule 18 (line 118): +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) + $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) Starting parse @@ -121484,64 +121219,84 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token ')' (1.3: ) +Entering state 11 +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 114): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) Entering state 21 Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Reading a token +1.8: syntax error: invalid character: '#' +Next token is token error (1.8: ) +Shifting token error (1.8: ) Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) +Next token is token error (1.8: ) +Error: discarding token error (1.8: ) Reading a token -Next token is token ')' (1.7: ) +Next token is token ')' (1.9: ) Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 30 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) +Entering state 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) Entering state 19 Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) +Next token is token "number" (1.13-16: 2222) +Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) + $1 = token "number" (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) Entering state 28 Reading a token -Next token is token '\n' (1.15-2.0: ) +Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): @@ -121554,6 +121309,7 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +stderr: Starting parse Entering state 0 Reading a token @@ -121611,19 +121367,18 @@ Shifting token '!' (1.13: ) Entering state 5 Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Reducing stack 0 by rule 17 (line 117): +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Reducing stack 0 by rule 18 (line 118): $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) + $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -input: - | 1 + 2 * 3 + !- ++ -./calc.at:1416: $PREPARSER ./calc input -stderr: -./calc.at:1432: "$PERL" -pi -e 'use strict; +./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1431: cat stderr +./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -121633,7 +121388,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: Starting parse Entering state 0 Reading a token @@ -121691,28 +121447,126 @@ Shifting token '!' (1.13: ) Entering state 5 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Reducing stack 0 by rule 18 (line 118): +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Reducing stack 0 by rule 17 (line 117): $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) + $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +input: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) +Reading a token +Next token is token ')' (1.3: ) +Entering state 11 +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 114): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) +Entering state 21 +Reading a token +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Reading a token +1.8: syntax error: invalid character: '#' +Next token is token error (1.8: ) +Shifting token error (1.8: ) +Entering state 11 +Next token is token error (1.8: ) +Error: discarding token error (1.8: ) +Reading a token +Next token is token ')' (1.9: ) +Entering state 11 +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 114): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 30 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) +Entering state 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 19 +Reading a token +Next token is token "number" (1.13-16: 2222) +Shifting token "number" (1.13-16: 2222) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) +Entering state 28 +Reading a token +Next token is token '\n' (1.17-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1432: cat stderr +./calc.at:1414: cat stderr +input: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1431: $PREPARSER ./calc input + | 1 + 2 * 3 + !- ++ +./calc.at:1413: $PREPARSER ./calc input stderr: -./calc.at:1413: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 stderr: +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 Starting parse Entering state 0 Reading a token @@ -121778,22 +121632,11 @@ $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1432: cat stderr -stdout: -./calc.at:1434: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - input: -stderr: -./calc.at:1413: cat stderr +./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | 1 + 2 * 3 + !* ++ +./calc.at:1414: $PREPARSER ./calc input ./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -121804,14 +121647,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 + | 1 = 2 = 3 ./calc.at:1432: $PREPARSER ./calc input - | 1 2 -./calc.at:1431: $PREPARSER ./calc input -1.1: syntax error stderr: -input: +./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: Starting parse Entering state 0 Reading a token @@ -121869,75 +121709,24 @@ Shifting token '!' (1.13: ) Entering state 5 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Reducing stack 0 by rule 18 (line 118): +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Reducing stack 0 by rule 19 (line 119): $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1434: $PREPARSER ./calc input -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 -./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.7: syntax error ./calc.at:1416: cat stderr +./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: stderr: -./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 -input: -stderr: -./calc.at:1433: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error -input: - | 1 + 2 * 3 + !* ++ -./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1432: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1416: $PREPARSER ./calc input -./calc.at:1434: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: - | (# + 1) = 1111 -./calc.at:1413: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -122004,9 +121793,117 @@ 1.14: memory exhausted Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -stderr: syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 +stderr: +./calc.at:1434: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +input: +1.7: syntax error +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Reading a token +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 101): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Reducing stack 0 by rule 18 (line 118): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) + | (1 + #) = 1111 +./calc.at:1416: $PREPARSER ./calc input +./calc.at:1414: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: stderr: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 Starting parse Entering state 0 Reading a token @@ -122014,18 +121911,26 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 Reading a token Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 Reading a token -Next token is token "number" (1.6: 1) -Error: discarding token "number" (1.6: 1) +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 @@ -122076,7 +121981,8 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1414: "$PERL" -pi -e 'use strict; +./calc.at:1434: $PREPARSER ./calc input +./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -122086,15 +121992,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1432: cat stderr -input: -./calc.at:1414: cat stderr -./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 2 -./calc.at:1434: $PREPARSER ./calc input -stderr: -./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1431: "$PERL" -pi -e 'use strict; +./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -122104,78 +122002,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Reducing stack 0 by rule 19 (line 119): - $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1433: cat stderr -input: - | 1 + 2 * 3 + !* ++ -./calc.at:1416: "$PERL" -pi -e 'use strict; +./calc.at:1414: cat stderr +./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -122185,8 +122016,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1414: $PREPARSER ./calc input -./calc.at:1416: cat stderr +./calc.at:1413: cat stderr stderr: Starting parse Entering state 0 @@ -122195,18 +122025,26 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 Reading a token Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 Reading a token -Next token is token "number" (1.6: 1) -Error: discarding token "number" (1.6: 1) +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) Entering state 11 @@ -122257,85 +122095,15 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -1.3: syntax error - | (!!) + (1 2) = 1 -input: -./calc.at:1432: $PREPARSER ./calc input stderr: -./calc.at:1431: cat stderr +input: +./calc.at:1434: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1432: cat stderr | (#) + (#) = 2222 -./calc.at:1416: $PREPARSER ./calc input -./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 21 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 22 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 31 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 101): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 30 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 21 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Reading a token -Next token is token '*' (1.14: ) -Shifting token '*' (1.14: ) -Entering state 15 -Reducing stack 0 by rule 19 (line 119): - $1 = token '!' (1.13: ) - $2 = token '*' (1.14: ) -1.14: memory exhausted -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1414: $PREPARSER ./calc input +./calc.at:1431: cat stderr input: stderr: -./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: Starting parse Entering state 0 Reading a token @@ -122433,14 +122201,26 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | 1 = 2 = 3 -./calc.at:1433: $PREPARSER ./calc input -1.11: syntax error -1.1-16: error: 2222 != 1 -stderr: -1.3: syntax error -./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 + !* ++ +./calc.at:1416: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +./calc.at:1413: $PREPARSER ./calc input stderr: + | + | +1 +./calc.at:1432: $PREPARSER ./calc input +input: +./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: Starting parse Entering state 0 Reading a token @@ -122508,34 +122288,22 @@ Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) stderr: -./calc.at:1413: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: - | 1//2 -./calc.at:1434: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1413: cat stderr -./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 2 +./calc.at:1434: $PREPARSER ./calc input + | (!!) + (1 2) = 1 +./calc.at:1416: cat stderr ./calc.at:1431: $PREPARSER ./calc input -1.7: syntax error -./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +stderr: +2.1: syntax error +./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +error: 2222 != 1 +./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.3: syntax error +./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -122633,24 +122401,84 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1414: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 stderr: -syntax error -./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 21 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 30 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 22 +Reading a token +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 31 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 101): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 30 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 21 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '*' (1.14: ) +Shifting token '*' (1.14: ) +Entering state 15 +Reducing stack 0 by rule 19 (line 119): + $1 = token '!' (1.13: ) + $2 = token '*' (1.14: ) +1.14: memory exhausted +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) input: -./calc.at:1414: cat stderr -./calc.at:1416: "$PERL" -pi -e 'use strict; +2.1: syntax error +syntax error +error: 2222 != 1 + | (# + 1) = 1111 +1.3: syntax error +./calc.at:1416: $PREPARSER ./calc input +./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -122660,13 +122488,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.11: syntax error -1.1-16: error: 2222 != 1 -stderr: -1.7: syntax error - | (1 + # + 1) = 1111 -syntax error -./calc.at:1413: $PREPARSER ./calc input stderr: Starting parse Entering state 0 @@ -122675,70 +122496,56 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) Reading a token -Next token is token "number" (1.10: 1) -Error: discarding token "number" (1.10: 1) +Next token is token "number" (1.6: 1) +Error: discarding token "number" (1.6: 1) Reading a token -Next token is token ')' (1.11: ) +Next token is token ')' (1.7: ) Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 19 Reading a token -Next token is token "number" (1.15-18: 1111) -Shifting token "number" (1.15-18: 1111) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token -Next token is token '\n' (1.19-2.0: ) +Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): @@ -122751,7 +122558,8 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1433: "$PERL" -pi -e 'use strict; +./calc.at:1414: cat stderr +./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -122761,9 +122569,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1434: cat stderr -./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -122774,14 +122579,29 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: +./calc.at:1434: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: - | (#) + (#) = 2222 -./calc.at:1414: $PREPARSER ./calc input - | 1//2 -./calc.at:1434: $PREPARSER ./calc input -stdout: +./calc.at:1431: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -122789,70 +122609,56 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) Reading a token -Next token is token "number" (1.10: 1) -Error: discarding token "number" (1.10: 1) +Next token is token "number" (1.6: 1) +Error: discarding token "number" (1.6: 1) Reading a token -Next token is token ')' (1.11: ) +Next token is token ')' (1.7: ) Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 19 Reading a token -Next token is token "number" (1.15-18: 1111) -Shifting token "number" (1.15-18: 1111) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token -Next token is token '\n' (1.19-2.0: ) +Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): @@ -122865,44 +122671,13 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1416: cat stderr -./calc.at:1426: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc calc.hh - -./calc.at:1433: cat stderr -./calc.at:1431: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -./calc.at:1413: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1413: cat stderr | (1 + #) = 1111 +./calc.at:1414: $PREPARSER ./calc input stderr: -./calc.at:1416: $PREPARSER ./calc input +./calc.at:1434: cat stderr stderr: +stdout: Starting parse Entering state 0 Reading a token @@ -122980,15 +122755,35 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1413: cat stderr +./calc.at:1433: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +./calc.at:1432: cat stderr +./calc.at:1416: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -1.3: syntax error - | - | +1 +./calc.at:1432: $PREPARSER ./calc /dev/null input: -./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1433: $PREPARSER ./calc input -./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1431: cat stderr + | (#) + (#) = 2222 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -123002,11 +122797,18 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -./calc.at:1426: $PREPARSER ./calc input + | 1//2 +stderr: +./calc.at:1413: $PREPARSER ./calc input +./calc.at:1433: $PREPARSER ./calc input +./calc.at:1434: $PREPARSER ./calc input +./calc.at:1416: cat stderr +stderr: stderr: +1.1: syntax error stderr: stderr: -input: +./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -123104,16 +122906,7 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: -./calc.at:1431: cat stderr - | (1 + 1) / (1 - 1) -./calc.at:1432: cat stderr -./calc.at:1413: $PREPARSER ./calc input -1.3: syntax error -./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -123191,127 +122984,21 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Reading a token -Next token is token "number" (1.6: 1) -Shifting token "number" (1.6: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 30 -Reading a token -Next token is token ')' (1.7: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 113): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) -Entering state 8 -Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 23 -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Reading a token -Next token is token "number" (1.12: 1) -Shifting token "number" (1.12: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 20 -Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 29 -Reading a token -Next token is token ')' (1.17: ) -Reducing stack 0 by rule 8 (line 100): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 113): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 32 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 10 (line 102): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) -Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +1.3: syntax error +./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1426: $EGREP -c -v 'Return for a new token:|LAC:' stderr -2.1: syntax error -./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1434: "$PERL" -pi -e 'use strict; +stderr: +input: +input: +1.1: syntax error + | (1 + # + 1) = 1111 +./calc.at:1416: $PREPARSER ./calc input + | (- *) + (1 2) = 1 +./calc.at:1431: $PREPARSER ./calc input +./calc.at:1433: $EGREP -c -v 'Return for a new token:|LAC:' stderr +stderr: +./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -123322,6 +123009,7 @@ }eg ' expout || exit 77 stderr: +1.3: syntax error stderr: Starting parse Entering state 0 @@ -123330,121 +123018,6 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 -Reading a token -Next token is token "number" (1.6: 1) -Shifting token "number" (1.6: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 30 -Reading a token -Next token is token ')' (1.7: ) -Reducing stack 0 by rule 7 (line 99): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 113): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) -Entering state 8 -Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 23 -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Reading a token -Next token is token "number" (1.12: 1) -Shifting token "number" (1.12: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 20 -Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 29 -Reading a token -Next token is token ')' (1.17: ) -Reducing stack 0 by rule 8 (line 100): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 27 -Reducing stack 0 by rule 13 (line 113): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 32 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 10 (line 102): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) -Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 25 -Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 78): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 17 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token 1.2: syntax error: invalid character: '#' Next token is token error (1.2: ) Shifting token error (1.2: ) @@ -123536,10 +123109,94 @@ Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: -input: - | (- *) + (1 2) = 1 -2.1: syntax error -./calc.at:1416: "$PERL" -pi -e 'use strict; +./calc.at:1414: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) +Reading a token +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Reading a token +Next token is token "number" (1.10: 1) +Error: discarding token "number" (1.10: 1) +Reading a token +Next token is token ')' (1.11: ) +Entering state 11 +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 114): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) +Entering state 8 +Reading a token +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) +Entering state 19 +Reading a token +Next token is token "number" (1.15-18: 1111) +Shifting token "number" (1.15-18: 1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) +Entering state 28 +Reading a token +Next token is token '\n' (1.19-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) +Entering state 8 +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +syntax error +syntax error +error: 2222 != 1 +./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -123549,25 +123206,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1432: $PREPARSER ./calc input -./calc.at:1434: cat stderr -input: +./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -./calc.at:1414: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | error +./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 -./calc.at:1426: $PREPARSER ./calc input -./calc.at:1431: $PREPARSER ./calc input -./calc.at:1413: "$PERL" -pi -e 'use strict; +./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -123577,29 +123220,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1416: cat stderr -stderr: -stderr: -stderr: -./calc.at:1413: cat stderr -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 +./calc.at:1433: $PREPARSER ./calc input input: -syntax error -./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | error -./calc.at:1414: cat stderr -./calc.at:1434: $PREPARSER ./calc input -./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 -519. calc.at:1413: ok -syntax error -./calc.at:1433: "$PERL" -pi -e 'use strict; +./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -123609,22 +123232,19 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error stderr: -1.1: syntax error +stderr: | (# + 1) = 1111 -./calc.at:1416: $PREPARSER ./calc input -./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1414: $PREPARSER ./calc input +1.3: syntax error stderr: +./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error -input: +syntax error +error: 2222 != 1 stderr: - - | (1 + #) = 1111 -./calc.at:1433: cat stderr -./calc.at:1414: $PREPARSER ./calc input +./calc.at:1413: cat stderr +./calc.at:1432: cat stderr Starting parse Entering state 0 Reading a token @@ -123632,56 +123252,70 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 Reading a token Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 Reading a token -Next token is token "number" (1.6: 1) -Error: discarding token "number" (1.6: 1) +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) Reading a token -Next token is token ')' (1.7: ) +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Reading a token +Next token is token "number" (1.10: 1) +Error: discarding token "number" (1.10: 1) +Reading a token +Next token is token ')' (1.11: ) Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) Entering state 19 Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) +Next token is token "number" (1.15-18: 1111) +Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) + $1 = token "number" (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) Entering state 28 Reading a token -Next token is token '\n' (1.15-2.0: ) +Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): @@ -123694,9 +123328,6 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1433: $PREPARSER ./calc /dev/null -stderr: Starting parse Entering state 0 Reading a token @@ -123766,7 +123397,11 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1432: "$PERL" -pi -e 'use strict; +./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1434: cat stderr +stderr: +1.3: syntax error +./calc.at:1416: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -123776,8 +123411,13 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +input: +input: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: -stderr: +./calc.at:1432: $PREPARSER ./calc input + | (1 + #) = 1111 +./calc.at:1413: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -123785,26 +123425,18 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 +Error: discarding token '+' (1.4: ) Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) -Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) +Next token is token "number" (1.6: 1) +Error: discarding token "number" (1.6: 1) Reading a token Next token is token ')' (1.7: ) Entering state 11 @@ -123855,18 +123487,7 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1426: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1416: "$PERL" -pi -e 'use strict; +./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -123876,16 +123497,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.1: syntax error -./calc.at:1416: cat stderr -1.1: syntax error -./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (1 + # + 1) = 1111 -./calc.at:1416: $PREPARSER ./calc input stderr: stderr: +./calc.at:1416: cat stderr Starting parse Entering state 0 Reading a token @@ -123963,9 +123578,7 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -1.1: syntax error -./calc.at:1432: cat stderr -./calc.at:1431: "$PERL" -pi -e 'use strict; +./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -123975,6 +123588,17 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 + | error +./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1434: $PREPARSER ./calc input +stderr: +./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: ./calc.at:1414: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -123985,24 +123609,20 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1426: cat stderr stderr: -./calc.at:1434: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1431: cat stderr +1.1: syntax error +./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 + | (1 + 1) / (1 - 1) +./calc.at:1416: $PREPARSER ./calc input +stderr: ./calc.at:1414: cat stderr -531. calc.at:1441: testing Calculator C++ %locations parse.error=verbose %debug api.prefix={calc} api.token.prefix={TOK_} %verbose ... -./calc.at:1441: mv calc.y.tmp calc.y - -./calc.at:1441: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -input: +./calc.at:1433: cat stderr Starting parse Entering state 0 Reading a token @@ -124031,49 +123651,43 @@ Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Reading a token -Next token is token "number" (1.10: 1) -Error: discarding token "number" (1.10: 1) -Reading a token -Next token is token ')' (1.11: ) +Next token is token ')' (1.7: ) Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 19 Reading a token -Next token is token "number" (1.15-18: 1111) -Shifting token "number" (1.15-18: 1111) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token -Next token is token '\n' (1.19-2.0: ) +Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): @@ -124086,19 +123700,8 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | (# + 1) = 1111 -./calc.at:1414: $PREPARSER ./calc input stderr: -./calc.at:1433: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +stderr: Starting parse Entering state 0 Reading a token @@ -124106,56 +123709,102 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 Reading a token Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 Reading a token Next token is token "number" (1.6: 1) -Error: discarding token "number" (1.6: 1) +Shifting token "number" (1.6: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 30 Reading a token Next token is token ')' (1.7: ) -Entering state 11 +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): +Entering state 27 +Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) + $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) +-> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 23 Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Reading a token +Next token is token "number" (1.12: 1) +Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 + $1 = token "number" (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 20 +Reading a token +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 29 +Reading a token +Next token is token ')' (1.17: ) +Reducing stack 0 by rule 8 (line 100): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 27 +Reducing stack 0 by rule 13 (line 113): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 32 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 10 (line 102): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): @@ -124168,18 +123817,54 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +1.1: syntax error +./calc.at:1432: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 input: -./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1//2 -./calc.at:1426: $PREPARSER ./calc input -stderr: input: -./calc.at:1433: cat stderr - | (* *) + (*) + (*) -syntax error ./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (* *) + (*) + (*) +input: +./calc.at:1431: $PREPARSER ./calc input + | 1//2 +./calc.at:1433: $PREPARSER ./calc input +./calc.at:1413: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (1 + # + 1) = 1111 +./calc.at:1434: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1414: $PREPARSER ./calc input +stderr: +stderr: +stderr: +syntax error +syntax error +syntax error Starting parse Entering state 0 Reading a token @@ -124187,56 +123872,102 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 Reading a token Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 Reading a token Next token is token "number" (1.6: 1) -Error: discarding token "number" (1.6: 1) +Shifting token "number" (1.6: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 30 Reading a token Next token is token ')' (1.7: ) -Entering state 11 +Reducing stack 0 by rule 7 (line 99): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) -Entering state 26 -Reducing stack 0 by rule 14 (line 114): +Entering state 27 +Reducing stack 0 by rule 13 (line 113): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) + $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) +-> $$ = nterm exp (1.1-7: 2) Entering state 8 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 19 +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 23 Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Reading a token +Next token is token "number" (1.12: 1) +Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 28 + $1 = token "number" (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 20 +Reading a token +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 29 +Reading a token +Next token is token ')' (1.17: ) +Reducing stack 0 by rule 8 (line 100): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 27 +Reducing stack 0 by rule 13 (line 113): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 32 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 10 (line 102): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): @@ -124249,25 +123980,6 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1432: $PREPARSER ./calc input -stderr: -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1414: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1433: $PREPARSER ./calc input -1.2: syntax error -1.10: syntax error -1.16: syntax error Starting parse Entering state 0 Reading a token @@ -124351,77 +124063,16 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1431: cat stderr -stderr: -./calc.at:1434: cat stderr -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 +./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.3: syntax error +./calc.at:1413: cat stderr ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1432: cat stderr +./calc.at:1434: cat stderr stderr: stderr: -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 -stderr: -1.2: syntax error -1.10: syntax error -1.16: syntax error -syntax error -./calc.at:1414: cat stderr -./calc.at:1441: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -./calc.at:1432: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1416: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -input: -./calc.at:1426: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (1 + # + 1) = 1111 -./calc.at:1414: $PREPARSER ./calc input stderr: -./calc.at:1433: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1432: cat stderr - | 1 = 2 = 3 input: Starting parse Entering state 0 @@ -124506,12 +124157,24 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1434: $PREPARSER ./calc input - | 1 = 2 = 3 -./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1431: $PREPARSER ./calc input -stderr: + | (# + 1) = 1111 +./calc.at:1413: $PREPARSER ./calc input +syntax error +syntax error +syntax error +./calc.at:1416: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +1.3: syntax error stderr: +input: Starting parse Entering state 0 Reading a token @@ -124519,70 +124182,162 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) +Reading a token +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Reading a token +Next token is token "number" (1.6: 1) +Error: discarding token "number" (1.6: 1) +Reading a token +Next token is token ')' (1.7: ) +Entering state 11 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 114): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 19 +Reading a token +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 28 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 21 +Next token is token '\n' (1.15-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +input: +./calc.at:1414: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1416: cat stderr + | (!!) + (1 2) = 1 +./calc.at:1432: $PREPARSER ./calc input +./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 = 2 = 3 +./calc.at:1434: $PREPARSER ./calc input +stderr: +./calc.at:1433: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1414: cat stderr +stderr: +1.11: syntax error +1.1-16: error: 2222 != 1 +./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.7: syntax error +./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +521. calc.at:1416: ok +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) Reading a token -Next token is token "number" (1.10: 1) -Error: discarding token "number" (1.10: 1) +Next token is token "number" (1.6: 1) +Error: discarding token "number" (1.6: 1) Reading a token -Next token is token ')' (1.11: ) +Next token is token ')' (1.7: ) Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 26 Reducing stack 0 by rule 14 (line 114): $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 19 Reading a token -Next token is token "number" (1.15-18: 1111) -Shifting token "number" (1.15-18: 1111) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 88): - $1 = token "number" (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 28 Reading a token -Next token is token '\n' (1.19-2.0: ) +Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 89): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 25 Reducing stack 0 by rule 4 (line 84): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 78): @@ -124595,16 +124350,28 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1431: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: stderr: -./calc.at:1416: cat stderr -1.7: syntax error -./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1426: cat stderr stderr: -syntax error 1.7: syntax error -./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1414: "$PERL" -pi -e 'use strict; +1.11: syntax error +1.1-16: error: 2222 != 1 +./calc.at:1433: cat stderr +input: + | (1 + 1) / (1 - 1) +./calc.at:1414: $PREPARSER ./calc input +stdout: +./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -124614,12 +124381,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -input: - | (1 + 1) / (1 - 1) -./calc.at:1416: $PREPARSER ./calc input -./calc.at:1433: cat stderr stderr: +./calc.at:1431: cat stderr ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -124745,26 +124508,58 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: +./calc.at:1413: cat stderr +./calc.at:1426: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc calc.hh + +./calc.at:1432: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + input: - | 1 + 2 * 3 + !+ ++ -./calc.at:1432: $PREPARSER ./calc input -syntax error | error -./calc.at:1414: cat stderr +./calc.at:1433: $PREPARSER ./calc input +./calc.at:1434: cat stderr input: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 ./calc.at:1426: $PREPARSER ./calc input stderr: -./calc.at:1434: cat stderr - | (!!) + (1 2) = 1 -./calc.at:1433: $PREPARSER ./calc input +./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +input: +1.1: syntax error stderr: -./calc.at:1416: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error +./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + # + 1) = 1111 ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: +./calc.at:1413: $PREPARSER ./calc input stderr: Starting parse Entering state 0 @@ -124881,20 +124676,138 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: -./calc.at:1432: $EGREP -c -v 'Return for a new token:|LAC:' stderr + | 1 + 2 * 3 + !+ ++ +./calc.at:1431: $PREPARSER ./calc input input: -1.11: syntax error -1.1-16: error: 2222 != 1 +stderr: +stderr: +stderr: +./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +1.1: syntax error +stderr: | | +1 -./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) +Reading a token +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Reading a token +Next token is token "number" (1.10: 1) +Error: discarding token "number" (1.10: 1) +Reading a token +Next token is token ')' (1.11: ) +Entering state 11 +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 114): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) +Entering state 8 +Reading a token +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) +Entering state 19 +Reading a token +Next token is token "number" (1.15-18: 1111) +Shifting token "number" (1.15-18: 1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) +Entering state 28 +Reading a token +Next token is token '\n' (1.19-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) +Entering state 8 +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stdout: +./calc.at:1432: cat stderr ./calc.at:1434: $PREPARSER ./calc input - | (1 + 1) / (1 - 1) -./calc.at:1414: $PREPARSER ./calc input +./calc.at:1431: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1435: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc calc.hh + +./calc.at:1426: $EGREP -c -v 'Return for a new token:|LAC:' stderr +531. calc.at:1441: testing Calculator C++ %locations parse.error=verbose %debug api.prefix={calc} api.token.prefix={TOK_} %verbose ... stderr: -syntax error -./calc.at:1431: "$PERL" -pi -e 'use strict; +./calc.at:1414: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1441: mv calc.y.tmp calc.y + +2.1: syntax error +./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1441: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +./calc.at:1414: cat stderr +./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -124904,10 +124817,211 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +input: +input: +input: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 stderr: +./calc.at:1435: $PREPARSER ./calc input + | 1 2 +./calc.at:1426: $PREPARSER ./calc input +input: + | (- *) + (1 2) = 1 2.1: syntax error +./calc.at:1432: $PREPARSER ./calc input stderr: -./calc.at:1416: "$PERL" -pi -e 'use strict; +stderr: + | 1 + 2 * 3 + !- ++ +./calc.at:1431: $PREPARSER ./calc input +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 21 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) +Reading a token +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Reading a token +Next token is token "number" (1.10: 1) +Error: discarding token "number" (1.10: 1) +Reading a token +Next token is token ')' (1.11: ) +Entering state 11 +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 26 +Reducing stack 0 by rule 14 (line 114): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) +Entering state 8 +Reading a token +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) +Entering state 19 +Reading a token +Next token is token "number" (1.15-18: 1111) +Shifting token "number" (1.15-18: 1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 88): + $1 = token "number" (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) +Entering state 28 +Reading a token +Next token is token '\n' (1.19-2.0: ) +Reducing stack 0 by rule 6 (line 89): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) +Entering state 8 +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) +Entering state 25 +Reducing stack 0 by rule 4 (line 84): + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 78): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 17 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 +520. calc.at:1414: ok +./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1434: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1433: cat stderr +stderr: +stderr: +stderr: +./calc.at:1413: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +syntax error +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 +./calc.at:1435: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1441: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +./calc.at:1434: cat stderr +./calc.at:1413: cat stderr +input: +./calc.at:1432: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: + +./calc.at:1434: $PREPARSER ./calc /dev/null +./calc.at:1426: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | 1 = 2 = 3 +./calc.at:1433: $PREPARSER ./calc input +stdout: +stderr: +stderr: +input: +1.7: syntax error +./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1437: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +1.1: syntax error + | 1 2 +./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1435: $PREPARSER ./calc input +./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -124917,6 +125031,29 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +input: + | (1 + 1) / (1 - 1) +1.7: syntax error +./calc.at:1413: $PREPARSER ./calc input +input: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1437: $PREPARSER ./calc input +stderr: +stderr: +stderr: +1.3: syntax error, unexpected number Starting parse Entering state 0 Reading a token @@ -125032,26 +125169,25 @@ Entering state 17 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.11: syntax error -1.1-16: error: 2222 != 1 -./calc.at:1426: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1414: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1426: cat stderr +./calc.at:1431: cat stderr +input: +./calc.at:1413: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.1: syntax error +./calc.at:1432: cat stderr + | 1//2 +./calc.at:1426: $PREPARSER ./calc input stderr: -./calc.at:1416: cat stderr +1.3: syntax error, unexpected number input: - | 1 + 2 * 3 + !- ++ -./calc.at:1432: $PREPARSER ./calc input +stderr: +stderr: +syntax error +./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -125062,14 +125198,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -2.1: syntax error -521. calc.at:1416: ok -./calc.at:1431: cat stderr -./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1426: cat stderr -./calc.at:1433: cat stderr -stderr: + | (#) + (#) = 2222 +./calc.at:1431: $PREPARSER ./calc input +./calc.at:1437: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Reading a token @@ -125186,52 +125317,13 @@ Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: -input: -input: - | - | +1 - | (- *) + (1 2) = 1 -./calc.at:1433: $PREPARSER ./calc input -input: -./calc.at:1431: $PREPARSER ./calc input - | 1 = 2 = 3 +532. calc.at:1443: testing Calculator C++ %header %locations parse.error=verbose %debug %name-prefix "calc" %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... stderr: -./calc.at:1426: $PREPARSER ./calc input -./calc.at:1414: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1434: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 +input: +./calc.at:1443: mv calc.y.tmp calc.y -./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -stderr: -./calc.at:1414: cat stderr -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 syntax error -./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1432: "$PERL" -pi -e 'use strict; +./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125241,11 +125333,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -syntax error -syntax error -./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1433: "$PERL" -pi -e 'use strict; +./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125255,13 +125343,17 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -520. calc.at:1414: ok +syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (* *) + (*) + (*) +./calc.at:1432: $PREPARSER ./calc input +./calc.at:1435: cat stderr stderr: -./calc.at:1434: cat stderr -./calc.at:1433: cat stderr -syntax error -./calc.at:1432: cat stderr -./calc.at:1431: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1443: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +input: +./calc.at:1413: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125271,26 +125363,18 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1434: $PREPARSER ./calc /dev/null -input: - | (* *) + (*) + (*) -./calc.at:1433: $PREPARSER ./calc input -input: -532. calc.at:1443: testing Calculator C++ %header %locations parse.error=verbose %debug %name-prefix "calc" %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... -./calc.at:1443: mv calc.y.tmp calc.y - -./calc.at:1443: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y - | (#) + (#) = 2222 -stderr: -stderr: -./calc.at:1432: $PREPARSER ./calc input -1.1: syntax error 1.2: syntax error 1.10: syntax error 1.16: syntax error -./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - -./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1433: cat stderr +syntax error: invalid character: '#' +syntax error: invalid character: '#' + | 1 2 +./calc.at:1434: cat stderr +./calc.at:1437: $PREPARSER ./calc input +input: +./calc.at:1413: cat stderr ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -125302,46 +125386,29 @@ }eg ' expout || exit 77 stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: + | 1//2 +./calc.at:1435: $PREPARSER ./calc input +1.3: syntax error, unexpected number +./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.1: syntax error -./calc.at:1431: cat stderr 1.2: syntax error 1.10: syntax error 1.16: syntax error -./calc.at:1434: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1426: cat stderr -stderr: -./calc.at:1443: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -533. calc.at:1445: testing Calculator C++ parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... -./calc.at:1445: mv calc.y.tmp calc.y - -./calc.at:1445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -./calc.at:1431: $PREPARSER ./calc /dev/null -stderr: -./calc.at:1434: cat stderr -syntax error +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' input: -./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: +519. calc.at:1413: ok + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 | | +1 +./calc.at:1434: $PREPARSER ./calc input stderr: -./calc.at:1433: "$PERL" -pi -e 'use strict; +./calc.at:1433: $PREPARSER ./calc input +./calc.at:1426: cat stderr +stderr: +./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125351,7 +125418,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1432: "$PERL" -pi -e 'use strict; +./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125361,29 +125428,42 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1434: $PREPARSER ./calc input -syntax error -./calc.at:1426: $PREPARSER ./calc input stderr: +1.3: syntax error, unexpected number +stderr: +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 +2.1: syntax error ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1443: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS +input: stderr: -syntax error -./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error + | error +./calc.at:1437: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: 1.2: syntax error 1.18: syntax error 1.23: syntax error 1.41: syntax error 1.1-46: error: 4444 != 1 -./calc.at:1426: "$PERL" -pi -e 'use strict; +./calc.at:1426: $PREPARSER ./calc input +2.1: syntax error +./calc.at:1432: cat stderr +./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125393,9 +125473,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1433: cat stderr -./calc.at:1432: cat stderr -./calc.at:1431: "$PERL" -pi -e 'use strict; +./calc.at:1431: cat stderr + +stderr: +./calc.at:1437: cat stderr +syntax error +./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1435: cat stderr +./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125405,6 +125490,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +input: + | 1 + 2 * 3 + !+ ++ ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -125415,48 +125502,42 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1432: $PREPARSER ./calc input input: - | 1 + 2 * 3 + !+ ++ -./calc.at:1433: $PREPARSER ./calc input -./calc.at:1445: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -input: -./calc.at:1426: cat stderr stderr: | (1 + #) = 1111 -./calc.at:1432: $PREPARSER ./calc input -./calc.at:1431: cat stderr -./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1431: $PREPARSER ./calc input +input: +input: +syntax error stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1434: cat stderr -./calc.at:1426: $PREPARSER ./calc /dev/null stderr: -./calc.at:1433: $EGREP -c -v 'Return for a new token:|LAC:' stderr + | 1//2 +./calc.at:1437: $PREPARSER ./calc input + | error +./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error: invalid character: '#' +./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -input: +./calc.at:1435: $PREPARSER ./calc input +./calc.at:1433: cat stderr +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +533. calc.at:1445: testing Calculator C++ parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... +./calc.at:1445: mv calc.y.tmp calc.y + +./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.6: syntax error: invalid character: '#' - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1431: $PREPARSER ./calc input -syntax error -./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | (!!) + (1 2) = 1 stderr: -./calc.at:1434: $PREPARSER ./calc input -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 +./calc.at:1434: cat stderr +1.1: syntax error, unexpected invalid token +./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error -input: +./calc.at:1445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +./calc.at:1432: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: - | 1 + 2 * 3 + !- ++ -./calc.at:1432: "$PERL" -pi -e 'use strict; +syntax error: invalid character: '#' +./calc.at:1433: $PREPARSER ./calc /dev/null +./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125466,17 +125547,26 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1433: $PREPARSER ./calc input -1.11: syntax error -1.1-16: error: 2222 != 1 stderr: -./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' stderr: +1.1: syntax error ./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.1: syntax error, unexpected invalid token +input: + | (!!) + (1 2) = 1 +./calc.at:1434: $PREPARSER ./calc input +stderr: + | 1 + 2 * 3 + !- ++ +stderr: +./calc.at:1432: $PREPARSER ./calc input +1.1: syntax error +./calc.at:1426: cat stderr +stderr: 1.11: syntax error 1.1-16: error: 2222 != 1 -stderr: -./calc.at:1426: "$PERL" -pi -e 'use strict; +./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125486,14 +125576,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 -stderr: -./calc.at:1432: cat stderr -./calc.at:1433: "$PERL" -pi -e 'use strict; +./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125503,7 +125586,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1434: "$PERL" -pi -e 'use strict; +./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125513,8 +125596,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1426: cat stderr -./calc.at:1431: "$PERL" -pi -e 'use strict; +./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1435: cat stderr +./calc.at:1437: cat stderr +stderr: +stderr: +input: +./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125524,53 +125613,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | (# + 1) = 1111 -./calc.at:1432: $PREPARSER ./calc input -stderr: -./calc.at:1434: cat stderr -1.2: syntax error: invalid character: '#' -./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1433: cat stderr -./calc.at:1431: cat stderr -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +1.11: syntax error +1.1-16: error: 2222 != 1 + | 1 = 2 = 3 +./calc.at:1445: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1426: $PREPARSER ./calc input -input: - | (- *) + (1 2) = 1 -./calc.at:1434: $PREPARSER ./calc input -stderr: -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 -./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 -./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./calc.at:1431: cat stderr input: - | (#) + (#) = 2222 -input: -./calc.at:1433: $PREPARSER ./calc input -stderr: -1.2: syntax error: invalid character: '#' -stderr: - | (!!) + (1 2) = 1 -./calc.at:1431: $PREPARSER ./calc input -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 -stderr: -stderr: -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 ./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -125581,12 +125631,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 = 2 = 3 syntax error -error: 2222 != 1 -./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -125597,14 +125643,40 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1435: $PREPARSER ./calc input +input: +stderr: +input: +./calc.at:1433: cat stderr +1.7: syntax error, unexpected '=' + | (# + 1) = 1111 +./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | error stderr: +./calc.at:1431: $PREPARSER ./calc input +./calc.at:1437: $PREPARSER ./calc input syntax error -error: 2222 != 1 ./calc.at:1432: cat stderr stderr: +stderr: +stderr: +syntax error: invalid character: '#' +1.7: syntax error, unexpected '=' +input: ./calc.at:1434: cat stderr -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' +./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.1: syntax error, unexpected invalid token +./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +stderr: +input: +./calc.at:1433: $PREPARSER ./calc input +syntax error: invalid character: '#' +input: + | (#) + (#) = 2222 +stderr: +./calc.at:1432: $PREPARSER ./calc input ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -125615,18 +125687,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1431: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -./calc.at:1433: "$PERL" -pi -e 'use strict; + | (- *) + (1 2) = 1 +./calc.at:1434: $PREPARSER ./calc input +stderr: +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 +./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125636,50 +125705,26 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (1 + # + 1) = 1111 -./calc.at:1432: $PREPARSER ./calc input -input: - | (* *) + (*) + (*) -stderr: -./calc.at:1434: $PREPARSER ./calc input -1.6: syntax error: invalid character: '#' -./calc.at:1431: cat stderr -./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1426: cat stderr -./calc.at:1433: cat stderr -input: +1.1: syntax error, unexpected invalid token stderr: -1.6: syntax error: invalid character: '#' -1.2: syntax error -1.10: syntax error -1.16: syntax error +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 ./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (!!) + (1 2) = 1 -./calc.at:1426: $PREPARSER ./calc input -input: - | (- *) + (1 2) = 1 -./calc.at:1431: $PREPARSER ./calc input -stderr: -stderr: -syntax error -syntax error -error: 2222 != 1 stderr: +./calc.at:1435: cat stderr 1.2: syntax error -1.10: syntax error -1.16: syntax error -syntax error -error: 2222 != 1 -./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 stderr: -syntax error -error: 2222 != 1 -input: - | (1 + #) = 1111 -./calc.at:1433: $PREPARSER ./calc input -./calc.at:1432: "$PERL" -pi -e 'use strict; +./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125690,7 +125735,9 @@ }eg ' expout || exit 77 stderr: -./calc.at:1434: "$PERL" -pi -e 'use strict; +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125700,17 +125747,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.6: syntax error: invalid character: '#' -./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error -syntax error -error: 2222 != 1 -./calc.at:1434: cat stderr -stderr: -1.6: syntax error: invalid character: '#' +./calc.at:1426: cat stderr +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 input: -./calc.at:1431: "$PERL" -pi -e 'use strict; +./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125720,8 +125762,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1 + 2 * 3 + !+ ++ -./calc.at:1434: $PREPARSER ./calc input ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -125732,7 +125772,13 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1426: "$PERL" -pi -e 'use strict; + | + | +1 +./calc.at:1435: $PREPARSER ./calc input +./calc.at:1437: cat stderr +stderr: +./calc.at:1431: cat stderr +./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125742,59 +125788,34 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1432: cat stderr -stderr: -./calc.at:1434: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1433: cat stderr -input: - | (1 + 1) / (1 - 1) -./calc.at:1432: $PREPARSER ./calc input -./calc.at:1431: cat stderr -./calc.at:1426: cat stderr -input: - | 1 + 2 * 3 + !- ++ -./calc.at:1434: $PREPARSER ./calc input -input: -input: +2.1: syntax error, unexpected '+' input: - | (* *) + (*) + (*) - | (- *) + (1 2) = 1 -stderr: -./calc.at:1431: $PREPARSER ./calc input -stderr: - | (# + 1) = 1111 +./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | + | +1 ./calc.at:1426: $PREPARSER ./calc input -./calc.at:1433: $PREPARSER ./calc input +./calc.at:1432: cat stderr stderr: +input: stderr: -./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error +./calc.at:1433: cat stderr + | 1 = 2 = 3 +2.1: syntax error, unexpected '+' +./calc.at:1437: $PREPARSER ./calc input syntax error -error: 2222 != 1 ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error -syntax error -syntax error -./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.11-17: error: null divisor -stderr: -stderr: -./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error -syntax error -syntax error -1.2: syntax error: invalid character: '#' -./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1434: cat stderr + | (1 + # + 1) = 1111 +input: +./calc.at:1431: $PREPARSER ./calc input stderr: -syntax error -syntax error -error: 2222 != 1 -1.11-17: error: null divisor + | (1 + #) = 1111 +./calc.at:1432: $PREPARSER ./calc input stderr: -./calc.at:1431: "$PERL" -pi -e 'use strict; +1.7: syntax error, unexpected '=' +input: +./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125804,7 +125825,40 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1432: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error + | (!!) + (1 2) = 1 +stderr: +./calc.at:1433: $PREPARSER ./calc input +1.6: syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +input: +1.11: syntax error +1.1-16: error: 2222 != 1 +./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1435: cat stderr + | (* *) + (*) + (*) +./calc.at:1434: $PREPARSER ./calc input +stderr: +stderr: +1.7: syntax error, unexpected '=' +syntax error: invalid character: '#' +stderr: +stderr: +1.2: syntax error +1.10: syntax error +1.16: syntax error +1.6: syntax error: invalid character: '#' +./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.11: syntax error +1.1-16: error: 2222 != 1 +./calc.at:1435: $PREPARSER ./calc /dev/null +./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125815,9 +125869,8 @@ }eg ' expout || exit 77 stderr: -1.2: syntax error: invalid character: '#' -./calc.at:1431: cat stderr -./calc.at:1434: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125827,7 +125880,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1426: "$PERL" -pi -e 'use strict; +./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125837,8 +125890,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1432: cat stderr -./calc.at:1426: cat stderr ./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -125849,38 +125900,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -input: - | 1 + 2 * 3 + !+ ++ -./calc.at:1434: cat stderr -./calc.at:1431: $PREPARSER ./calc input - | (* *) + (*) + (*) -./calc.at:1426: $PREPARSER ./calc input -stderr: -stderr: -syntax error -syntax error -syntax error -524. calc.at:1432: ok -./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1433: cat stderr -stderr: -syntax error -syntax error -syntax error -stderr: -./calc.at:1431: $EGREP -c -v 'Return for a new token:|LAC:' stderr -input: -input: - | (#) + (#) = 2222 -./calc.at:1434: $PREPARSER ./calc input - | 1 + 2 * 3 + !- ++ -./calc.at:1431: $PREPARSER ./calc input -stderr: -stderr: -./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1426: "$PERL" -pi -e 'use strict; +1.1: syntax error, unexpected end of input +1.2: syntax error +1.10: syntax error +1.16: syntax error +./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125890,18 +125915,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1426: cat stderr +./calc.at:1437: cat stderr stderr: +./calc.at:1426: cat stderr +1.1: syntax error, unexpected end of input +./calc.at:1426: $PREPARSER ./calc /dev/null +./calc.at:1433: cat stderr +./calc.at:1432: cat stderr input: -input: - | (1 + # + 1) = 1111 -./calc.at:1433: $PREPARSER ./calc input - | 1 + 2 * 3 + !+ ++ -./calc.at:1426: $PREPARSER ./calc input -./calc.at:1431: "$PERL" -pi -e 'use strict; +./calc.at:1434: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125912,18 +125934,14 @@ }eg ' expout || exit 77 stderr: + | + | +1 +./calc.at:1431: cat stderr +./calc.at:1437: $PREPARSER ./calc input +syntax error stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: - -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' ./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1431: cat stderr -1.6: syntax error: invalid character: '#' -./calc.at:1434: "$PERL" -pi -e 'use strict; +./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -125933,143 +125951,46 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -./calc.at:1426: $EGREP -c -v 'Return for a new token:|LAC:' stderr -534. calc.at:1446: testing Calculator C++ %header %locations parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... -./calc.at:1446: mv calc.y.tmp calc.y - +2.1: syntax error, unexpected '+' +./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: - | (#) + (#) = 2222 -./calc.at:1433: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1431: $PREPARSER ./calc input -stderr: -syntax error: invalid character: '#' -syntax error: invalid character: '#' input: -./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 + 2 * 3 + !- ++ -stderr: -syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1426: $PREPARSER ./calc input -./calc.at:1434: cat stderr -stderr: -./calc.at:1446: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1433: cat stderr input: + | (- *) + (1 2) = 1 stderr: - | (1 + 1) / (1 - 1) ./calc.at:1433: $PREPARSER ./calc input + | (# + 1) = 1111 +./calc.at:1432: $PREPARSER ./calc input +./calc.at:1435: cat stderr +syntax error stderr: -stdout: -./calc.at:1437: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - -stderr: -input: -1.11-17: error: null divisor -./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1431: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1437: $PREPARSER ./calc input - | (1 + #) = 1111 -./calc.at:1434: $PREPARSER ./calc input -stderr: -./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + 1) / (1 - 1) stderr: stderr: +./calc.at:1431: $PREPARSER ./calc input +2.1: syntax error, unexpected '+' +./calc.at:1434: cat stderr +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 +./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error: invalid character: '#' stderr: -./calc.at:1437: $EGREP -c -v 'Return for a new token:|LAC:' stderr -1.11-17: error: null divisor -./calc.at:1446: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS +./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -1.6: syntax error: invalid character: '#' -./calc.at:1431: cat stderr - | 1 2 -./calc.at:1437: $PREPARSER ./calc input -./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +error: null divisor +./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1435: $PREPARSER ./calc input stderr: -./calc.at:1426: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1433: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +input: +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 + | 1 + 2 * 3 + !+ ++ stderr: -1.6: syntax error: invalid character: '#' -1.3: syntax error, unexpected number -./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.3: syntax error, unexpected number -./calc.at:1426: cat stderr -./calc.at:1434: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -input: - | (1 + #) = 1111 -./calc.at:1431: $PREPARSER ./calc input +./calc.at:1434: $PREPARSER ./calc input ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -126081,31 +126002,14 @@ }eg ' expout || exit 77 stderr: - | (#) + (#) = 2222 -syntax error: invalid character: '#' -./calc.at:1426: $PREPARSER ./calc input -stderr: -./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1434: cat stderr -./calc.at:1433: cat stderr -./calc.at:1437: cat stderr -stderr: -stderr: -syntax error: invalid character: '#' -syntax error: invalid character: '#' -syntax error: invalid character: '#' -input: - | (# + 1) = 1111 -./calc.at:1434: $PREPARSER ./calc input -525. calc.at:1433: ok +error: null divisor +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.1-46: error: 4444 != 1 stderr: -input: -1.2: syntax error: invalid character: '#' -./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1//2 +./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -126116,12 +126020,16 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1437: $PREPARSER ./calc input -stderr: 1.2: syntax error: invalid character: '#' +./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - -./calc.at:1431: "$PERL" -pi -e 'use strict; +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.1-46: error: 4444 != 1 +stderr: +./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -126131,9 +126039,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1434: "$PERL" -pi -e 'use strict; +./calc.at:1437: cat stderr +./calc.at:1434: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1437: $PREPARSER ./calc /dev/null +./calc.at:1426: cat stderr +stderr: +./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -126143,10 +126054,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -./calc.at:1426: cat stderr -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1437: "$PERL" -pi -e 'use strict; +input: +./calc.at:1431: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -126156,23 +126065,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1437: cat stderr -535. calc.at:1448: testing Calculator C++ %header %locations api.location.file=none ... -./calc.at:1448: mv calc.y.tmp calc.y - -input: -./calc.at:1431: cat stderr - | (1 + #) = 1111 -./calc.at:1426: $PREPARSER ./calc input -stderr: -syntax error: invalid character: '#' -./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1448: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -stderr: -./calc.at:1434: cat stderr -input: -syntax error: invalid character: '#' -./calc.at:1426: "$PERL" -pi -e 'use strict; +1.1: syntax error, unexpected end of input +./calc.at:1433: cat stderr +./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -126182,26 +126077,13 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | error -input: - | (# + 1) = 1111 -input: -./calc.at:1426: cat stderr - | (1 + # + 1) = 1111 -./calc.at:1434: $PREPARSER ./calc input -./calc.at:1437: $PREPARSER ./calc input -./calc.at:1431: $PREPARSER ./calc input -stderr: -1.6: syntax error: invalid character: '#' stderr: -./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.1: syntax error, unexpected invalid token ./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: stdout: -./calc.at:1440: "$PERL" -ne ' + | 1 + 2 * 3 + !- ++ +./calc.at:1434: $PREPARSER ./calc input +input: +./calc.at:1438: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. @@ -126212,19 +126094,37 @@ || /\t/ )' calc.cc -syntax error: invalid character: '#' -./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1435: cat stderr stderr: -syntax error: invalid character: '#' + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: - | (# + 1) = 1111 -./calc.at:1426: $PREPARSER ./calc input -1.6: syntax error: invalid character: '#' stderr: -./calc.at:1448: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS -1.1: syntax error, unexpected invalid token +./calc.at:1426: $PREPARSER ./calc input +./calc.at:1432: cat stderr input: +stdout: +./calc.at:1431: cat stderr +./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +1.1: syntax error, unexpected end of input +input: +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 +./calc.at:1440: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -126238,21 +126138,21 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -./calc.at:1440: $PREPARSER ./calc input -syntax error: invalid character: '#' -./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1438: $PREPARSER ./calc input + | (* *) + (*) + (*) +input: +./calc.at:1433: $PREPARSER ./calc input stderr: -syntax error: invalid character: '#' -./calc.at:1434: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +stderr: + | (!!) + (1 2) = 1 +./calc.at:1435: $PREPARSER ./calc input +input: +1.2: syntax error +1.10: syntax error +1.16: syntax error +523. calc.at:1431: ok +stderr: +./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -126263,17 +126163,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +input: + | (1 + # + 1) = 1111 +stderr: stderr: -./calc.at:1431: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 Starting parse Entering state 0 Stack now 0 @@ -127291,9 +127184,50 @@ Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1432: $PREPARSER ./calc input + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 ./calc.at:1437: cat stderr +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 +stderr: +./calc.at:1440: $PREPARSER ./calc input +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 +./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.6: syntax error: invalid character: '#' +./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1434: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: +stderr: +1.2: syntax error +1.10: syntax error +1.16: syntax error Starting parse Entering state 0 Stack now 0 @@ -128311,322 +128245,7 @@ Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1440: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1434: cat stderr -input: - | 1 = 2 = 3 -./calc.at:1437: $PREPARSER ./calc input -input: - | 1 2 -./calc.at:1440: $PREPARSER ./calc input -stderr: -./calc.at:1426: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token number (1.3: 2) -Stack now 0 -./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1431: cat stderr -stderr: -input: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token number (1.3: 2) -Stack now 0 -./calc.at:1426: cat stderr - | (1 + # + 1) = 1111 -./calc.at:1431: $PREPARSER ./calc input -stderr: -stderr: -1.7: syntax error, unexpected '=' -input: -./calc.at:1440: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1440: cat stderr -syntax error: invalid character: '#' -./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: - | (1 + # + 1) = 1111 -./calc.at:1426: $PREPARSER ./calc input - | (1 + 1) / (1 - 1) -1.7: syntax error, unexpected '=' -./calc.at:1434: $PREPARSER ./calc input -stderr: -syntax error: invalid character: '#' -stderr: -./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -1.11-17: error: null divisor -./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error: invalid character: '#' - | 1//2 -stderr: -./calc.at:1440: $PREPARSER ./calc input -syntax error: invalid character: '#' -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 22 -Stack now 0 8 22 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) -Stack now 0 -./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 22 -Stack now 0 8 22 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) -Stack now 0 -./calc.at:1431: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1437: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1431: cat stderr -stderr: -./calc.at:1440: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.11-17: error: null divisor -input: -./calc.at:1440: cat stderr - | (1 + 1) / (1 - 1) -./calc.at:1431: $PREPARSER ./calc input -stderr: -error: null divisor -./calc.at:1437: cat stderr -./calc.at:1431: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1434: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -error: null divisor -./calc.at:1426: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: - | error -./calc.at:1426: cat stderr -./calc.at:1440: $PREPARSER ./calc input -./calc.at:1431: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -input: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -Stack now 0 ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1431: cat stderr - | - | +1 -stderr: -./calc.at:1437: $PREPARSER ./calc input -stderr: -./calc.at:1434: cat stderr -stdout: -./calc.at:1438: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - -523. calc.at:1431: ok -input: -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -Stack now 0 - | (1 + 1) / (1 - 1) -./calc.at:1426: $PREPARSER ./calc input -input: -2.1: syntax error, unexpected '+' -./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -526. calc.at:1434: ok -error: null divisor -./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -error: null divisor - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1438: $PREPARSER ./calc input -./calc.at:1440: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -stderr: Starting parse Entering state 0 Stack now 0 @@ -128947,6 +128566,7 @@ Entering state 24 Stack now 0 6 8 24 Reducing stack by rule 4 (line 75): +input: $1 = nterm exp (4.1-9: -1) $2 = token '\n' (4.10-5.0: ) -> $$ = nterm line (4.1-5.0: ) @@ -129644,9 +129264,36 @@ Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1438: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: -2.1: syntax error, unexpected '+' +stderr: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +stderr: +./calc.at:1437: $PREPARSER ./calc input +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 +1.6: syntax error: invalid character: '#' + +./calc.at:1433: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1426: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Stack now 0 @@ -130664,9 +130311,17 @@ Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1438: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1440: cat stderr -./calc.at:1426: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1440: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1434: cat stderr +input: +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.1-46: error: 4444 != 1 +./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1432: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -130676,9 +130331,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - -./calc.at:1426: cat stderr -./calc.at:1437: "$PERL" -pi -e 'use strict; + | 1 2 +./calc.at:1438: $PREPARSER ./calc input +input: +input: +./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -130689,23 +130346,11 @@ }eg ' expout || exit 77 stderr: -stdout: -input: -./calc.at:1437: cat stderr - | 1 = 2 = 3 -./calc.at:1441: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - + | (#) + (#) = 2222 +./calc.at:1434: $PREPARSER ./calc input +./calc.at:1433: cat stderr + | 1 2 ./calc.at:1440: $PREPARSER ./calc input -input: stderr: Starting parse Entering state 0 @@ -130721,53 +130366,53 @@ Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 18 -Stack now 0 8 18 +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token number (1.3: 2) +Stack now 0 +./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1435: cat stderr +./calc.at:1426: cat stderr +stderr: +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.1-46: error: 4444 != 1 +stderr: +stderr: +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 8 18 1 +Stack now 0 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 18 -Error: popping token '=' (1.3: ) + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 Stack now 0 8 +Reading a token +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) +Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 - | 1 2 ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1432: cat stderr +534. calc.at:1446: testing Calculator C++ %header %locations parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... input: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1441: $PREPARSER ./calc input -stderr: -522. calc.at:1426: ok +./calc.at:1446: mv calc.y.tmp calc.y -./calc.at:1438: $PREPARSER ./calc input -stderr: +input: Starting parse Entering state 0 Stack now 0 @@ -130788,13 +130433,24 @@ Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 -./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | 1 + 2 * 3 + !+ ++ +./calc.at:1433: $PREPARSER ./calc input + | (- *) + (1 2) = 1 +./calc.at:1437: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1435: $PREPARSER ./calc input stderr: -./calc.at:1437: $PREPARSER ./calc /dev/null -536. calc.at:1449: testing Calculator C++ %header %locations api.location.file="my-location.hh" ... stderr: -1.1: syntax error, unexpected end of input -./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (!!) + (1 2) = 1 Starting parse Entering state 0 Stack now 0 @@ -130809,103 +130465,864 @@ Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 20 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 -Stack now 0 8 20 29 21 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 20 29 21 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 -Stack now 0 8 20 29 21 30 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Stack now 0 8 20 29 -Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.13: 7) -Shifting token number (1.13: 7) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.13: 7) --> $$ = nterm exp (1.13: 7) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.14-2.0: ) -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-9: 7) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13: 7) --> $$ = nterm exp (1.1-13: 7) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.14-2.0: ) -Shifting token '\n' (1.14-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-13: 7) - $2 = token '\n' (1.14-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token number (2.1: 1) -Shifting token number (2.1: 1) -Entering state 1 -Stack now 0 6 1 -Reducing stack by rule 5 (line 79): - $1 = token number (2.1: 1) --> $$ = nterm exp (2.1: 1) -Entering state 8 -Stack now 0 6 8 -Reading a token -Next token is token '+' (2.3: ) -Shifting token '+' (2.3: ) +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token number (1.3: 2) +Stack now 0 +./calc.at:1426: $PREPARSER ./calc input +stderr: +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +stderr: +stderr: +input: +./calc.at:1437: cat stderr +./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.12: syntax error, unexpected number +1.1-17: error: 2222 != 1 +syntax error +error: 2222 != 1 +./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1438: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (1 + 1) / (1 - 1) +./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1446: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +./calc.at:1432: $PREPARSER ./calc input +stderr: +./calc.at:1440: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +1.11-17: error: null divisor +./calc.at:1432: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1434: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1433: $EGREP -c -v 'Return for a new token:|LAC:' stderr +stderr: +input: +syntax error +error: 2222 != 1 +./calc.at:1438: cat stderr +stderr: + | (!!) + (1 2) = 1 +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.12: syntax error, unexpected number +1.1-17: error: 2222 != 1 +./calc.at:1437: $PREPARSER ./calc input +./calc.at:1440: cat stderr +stderr: +input: +stderr: +1.11-17: error: null divisor + | 1 + 2 * 3 + !- ++ +./calc.at:1433: $PREPARSER ./calc input +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 +input: +input: +./calc.at:1434: cat stderr +./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: + | 1//2 + | 1//2 +./calc.at:1438: $PREPARSER ./calc input +./calc.at:1440: $PREPARSER ./calc input +./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1435: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1426: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +stderr: +./calc.at:1432: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 22 +Stack now 0 8 22 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '/' (1.3: ) +Stack now 0 +./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 +stderr: +./calc.at:1446: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS + | (1 + #) = 1111 +./calc.at:1434: $PREPARSER ./calc input +./calc.at:1435: cat stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 22 +Stack now 0 8 22 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '/' (1.3: ) +Stack now 0 +./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 22 +Stack now 0 8 22 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '/' (1.3: ) +Stack now 0 +./calc.at:1437: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +1.6: syntax error: invalid character: '#' +./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1426: cat stderr +stderr: +input: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 22 +Stack now 0 8 22 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '/' (1.3: ) +Stack now 0 +./calc.at:1432: cat stderr +./calc.at:1437: cat stderr + | (* *) + (*) + (*) +./calc.at:1435: $PREPARSER ./calc input +stderr: +input: +./calc.at:1433: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +1.6: syntax error: invalid character: '#' +./calc.at:1440: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1438: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (- *) + (1 2) = 1 +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1426: $PREPARSER ./calc input +524. calc.at:1432: ok +input: +stderr: +./calc.at:1440: cat stderr +syntax error +syntax error +error: 2222 != 1 +./calc.at:1438: cat stderr +./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (- *) + (1 2) = 1 +./calc.at:1437: $PREPARSER ./calc input +./calc.at:1434: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +stderr: +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.12: syntax error, unexpected number +1.1-17: error: 2222 != 1 +./calc.at:1433: cat stderr +input: +stderr: +input: +./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | error + | error +syntax error +syntax error +error: 2222 != 1 +./calc.at:1438: $PREPARSER ./calc input +./calc.at:1440: $PREPARSER ./calc input +stderr: +./calc.at:1434: cat stderr +stderr: + +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) +Stack now 0 +./calc.at:1435: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) +Stack now 0 +./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (#) + (#) = 2222 +./calc.at:1433: $PREPARSER ./calc input +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.12: syntax error, unexpected number +1.1-17: error: 2222 != 1 +./calc.at:1435: cat stderr +stderr: +input: +stderr: +stderr: +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) +Stack now 0 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) +Stack now 0 +./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1426: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (# + 1) = 1111 +./calc.at:1434: $PREPARSER ./calc input +./calc.at:1437: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +stderr: +stderr: + | 1 + 2 * 3 + !+ ++ +./calc.at:1440: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1435: $PREPARSER ./calc input +./calc.at:1437: cat stderr +1.2: syntax error: invalid character: '#' +./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +535. calc.at:1448: testing Calculator C++ %header %locations api.location.file=none ... +./calc.at:1438: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1448: mv calc.y.tmp calc.y + +stderr: +./calc.at:1426: cat stderr +./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1438: cat stderr +./calc.at:1440: cat stderr +input: +1.2: syntax error: invalid character: '#' +stderr: +./calc.at:1448: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +input: + | (* *) + (*) + (*) +./calc.at:1437: $PREPARSER ./calc input +./calc.at:1433: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1435: $EGREP -c -v 'Return for a new token:|LAC:' stderr +input: + | (* *) + (*) + (*) +./calc.at:1426: $PREPARSER ./calc input + | 1 = 2 = 3 +stderr: +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +stderr: +./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1438: $PREPARSER ./calc input +stderr: +./calc.at:1434: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | 1 = 2 = 3 +stdout: +./calc.at:1440: $PREPARSER ./calc input +stderr: +syntax error +syntax error +syntax error +./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1441: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +stderr: +input: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 18 +Error: popping token '=' (1.3: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 +./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1433: cat stderr +stderr: +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' + | 1 + 2 * 3 + !- ++ +./calc.at:1435: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 18 +Error: popping token '=' (1.3: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 +stderr: +./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +syntax error +syntax error +syntax error +./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +stderr: +input: +./calc.at:1434: cat stderr +stderr: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1441: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 18 +Error: popping token '=' (1.3: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 18 +Error: popping token '=' (1.3: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 + | (1 + #) = 1111 +./calc.at:1433: $PREPARSER ./calc input +./calc.at:1437: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +stderr: +1.6: syntax error: invalid character: '#' +./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +input: +./calc.at:1438: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Stack now 0 8 20 29 21 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 20 29 21 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Stack now 0 8 20 29 21 30 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack by rule 9 (line 92): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Stack now 0 8 20 29 +Next token is token '=' (1.11: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.13: 7) +Shifting token number (1.13: 7) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.13: 7) +-> $$ = nterm exp (1.13: 7) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' (1.14-2.0: ) +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1.1-9: 7) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13: 7) +-> $$ = nterm exp (1.1-13: 7) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.14-2.0: ) +Shifting token '\n' (1.14-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-13: 7) + $2 = token '\n' (1.14-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token number (2.1: 1) +Shifting token number (2.1: 1) +Entering state 1 +Stack now 0 6 1 +Reducing stack by rule 5 (line 79): + $1 = token number (2.1: 1) +-> $$ = nterm exp (2.1: 1) +Entering state 8 +Stack now 0 6 8 +Reading a token +Next token is token '+' (2.3: ) +Shifting token '+' (2.3: ) Entering state 20 Stack now 0 6 8 20 Reading a token @@ -131812,72 +132229,10 @@ Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 18 -Error: popping token '=' (1.3: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) -Stack now 0 -stderr: +./calc.at:1437: cat stderr ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - -1.1: syntax error, unexpected end of input -./calc.at:1449: mv calc.y.tmp calc.y - -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token number (1.3: 2) -Stack now 0 + | (1 + # + 1) = 1111 +./calc.at:1434: $PREPARSER ./calc input stderr: ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} @@ -131889,7 +132244,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1437: "$PERL" -pi -e 'use strict; +./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -131899,7 +132254,26 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1449: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +stderr: +./calc.at:1448: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS +1.6: syntax error: invalid character: '#' +./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1438: cat stderr +1.6: syntax error: invalid character: '#' +./calc.at:1435: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1440: cat stderr +stderr: +input: Starting parse Entering state 0 Stack now 0 @@ -132918,10 +133292,14 @@ Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1441: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1437: cat stderr -537. calc.at:1451: testing Calculator C++ %no-lines %header %locations api.location.file="my-location.hh" ... -./calc.at:1440: cat stderr -./calc.at:1438: "$PERL" -pi -e 'use strict; +1.6: syntax error: invalid character: '#' + | 1 + 2 * 3 + !+ ++ +./calc.at:1437: $PREPARSER ./calc input +./calc.at:1435: cat stderr +input: +./calc.at:1426: cat stderr +stderr: +./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -132932,56 +133310,95 @@ }eg ' expout || exit 77 input: -./calc.at:1451: mv calc.y.tmp calc.y - + | + | +1 +./calc.at:1438: $PREPARSER ./calc input +./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1434: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | + | +1 +stderr: +input: +./calc.at:1440: $PREPARSER ./calc input +input: + | (#) + (#) = 2222 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 74): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Stack now 0 +Cleanup: discarding lookahead token '+' (2.1: ) +Stack now 0 +./calc.at:1435: $PREPARSER ./calc input +./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: | 1 2 ./calc.at:1441: $PREPARSER ./calc input input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -538. calc.at:1453: testing Calculator C++ %locations parse.lac=full parse.error=verbose ... -./calc.at:1453: mv calc.y.tmp calc.y - -./calc.at:1437: $PREPARSER ./calc input stderr: + | 1 + 2 * 3 + !+ ++ +./calc.at:1437: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1426: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 74): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) Stack now 0 -Cleanup: discarding lookahead token number (1.3: 2) +Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 -input: -./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1438: cat stderr - | - | +1 -./calc.at:1440: $PREPARSER ./calc input -./calc.at:1453: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.1-46: error: 4444 != 1 -./calc.at:1451: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +./calc.at:1433: cat stderr stderr: -./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | 1//2 +stderr: +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 @@ -133002,6 +133419,9 @@ Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 +./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -133027,39 +133447,13 @@ Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 -./calc.at:1438: $PREPARSER ./calc input -./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1434: cat stderr +input: stderr: + | 1 + 2 * 3 + !- ++ stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 22 -Stack now 0 8 22 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) -Stack now 0 -./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1449: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS +input: +./calc.at:1437: $PREPARSER ./calc input stderr: Starting parse Entering state 0 @@ -133075,36 +133469,13 @@ Entering state 8 Stack now 0 8 Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 22 -Stack now 0 8 22 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Stack now 0 8 +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number Error: popping nterm exp (1.1: 1) Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) +Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.1-46: error: 4444 != 1 -stderr: -./calc.at:1441: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: + | (# + 1) = 1111 Starting parse Entering state 0 Stack now 0 @@ -133130,8 +133501,10 @@ Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 -stdout: -./calc.at:1438: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1433: $PREPARSER ./calc input +stderr: +./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -133141,18 +133514,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1435: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc calc.hh - -./calc.at:1437: "$PERL" -pi -e 'use strict; +./calc.at:1426: $EGREP -c -v 'Return for a new token:|LAC:' stderr +input: +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -133162,10 +133528,20 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1437: cat stderr ./calc.at:1441: cat stderr + | (1 + 1) / (1 - 1) input: -./calc.at:1438: cat stderr +./calc.at:1434: $PREPARSER ./calc input + | 1//2 +./calc.at:1441: $PREPARSER ./calc input +stderr: +./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error: invalid character: '#' +./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +stderr: +1.11-17: error: null divisor ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -133176,27 +133552,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1435: $PREPARSER ./calc input -input: - | 1//2 -./calc.at:1441: $PREPARSER ./calc input -stderr: -input: -./calc.at:1451: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS -./calc.at:1453: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +./calc.at:1434: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 @@ -133225,12 +133582,17 @@ Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1440: cat stderr - | (!!) + (1 2) = 1 -./calc.at:1437: $PREPARSER ./calc input -input: - | error +./calc.at:1435: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1438: cat stderr stderr: Starting parse Entering state 0 @@ -133259,20 +133621,38 @@ Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 -./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1438: $PREPARSER ./calc input +./calc.at:1435: cat stderr +input: +stderr: +./calc.at:1440: cat stderr +./calc.at:1438: $PREPARSER ./calc /dev/null +./calc.at:1433: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: stderr: + | 1 + 2 * 3 + !- ++ +./calc.at:1426: $PREPARSER ./calc input +1.11-17: error: null divisor +input: ./calc.at:1440: $PREPARSER ./calc /dev/null -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -Stack now 0 -./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1437: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -133284,9 +133664,26 @@ }eg ' expout || exit 77 stderr: -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 -./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1434: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token end of input (1.1: ) +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token end of input (1.1: ) +Stack now 0 +./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + #) = 1111 Starting parse Entering state 0 Stack now 0 @@ -133295,24 +133692,27 @@ 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 -stderr: ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1441: cat stderr +./calc.at:1433: cat stderr +./calc.at:1435: $PREPARSER ./calc input stderr: -./calc.at:1435: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) +Next token is token end of input (1.1: ) +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 stderr: -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 +./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -input: +stderr: +1.6: syntax error: invalid character: '#' +./calc.at:1441: cat stderr +stderr: +./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1437: cat stderr Starting parse Entering state 0 Stack now 0 @@ -133321,9 +133721,30 @@ 1.1: syntax error, unexpected end of input Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 +input: + | (1 + # + 1) = 1111 +./calc.at:1433: $PREPARSER ./calc input +./calc.at:1440: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +stderr: +1.6: syntax error: invalid character: '#' +input: +1.6: syntax error: invalid character: '#' +./calc.at:1434: cat stderr +input: | error ./calc.at:1441: $PREPARSER ./calc input -input: +./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1440: cat stderr stderr: ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} @@ -133335,9 +133756,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1 2 -./calc.at:1435: $PREPARSER ./calc input -./calc.at:1437: "$PERL" -pi -e 'use strict; + | (#) + (#) = 2222 +./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -133347,6 +133767,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1437: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -133356,11 +133777,8 @@ Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1438: cat stderr stderr: -1.3: syntax error, unexpected number -./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1440: "$PERL" -pi -e 'use strict; +./calc.at:1435: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -133370,8 +133788,19 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +1.6: syntax error: invalid character: '#' +526. calc.at:1434: ok stderr: -./calc.at:1437: cat stderr +./calc.at:1438: cat stderr +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +input: +./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1435: cat stderr + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +stderr: +./calc.at:1440: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -133380,15 +133809,10 @@ 1.1: syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 -input: -stderr: -./calc.at:1440: cat stderr - | 1 = 2 = 3 -./calc.at:1438: $PREPARSER ./calc input -1.3: syntax error, unexpected number +./calc.at:1426: cat stderr +stdout: stderr: -input: -./calc.at:1441: "$PERL" -pi -e 'use strict; +./calc.at:1433: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -133398,109 +133822,347 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1441: cat stderr +./calc.at:1445: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token number (1.7: 1) +Shifting token number (1.7: 1) Entering state 1 -Stack now 0 1 +Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) + $1 = token number (1.7: 1) +-> $$ = nterm exp (1.7: 1) +Entering state 12 +Stack now 0 8 20 4 12 +Reading a token +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 20 +Stack now 0 8 20 4 12 20 +Reading a token +Next token is token number (1.11: 1) +Shifting token number (1.11: 1) +Entering state 1 +Stack now 0 8 20 4 12 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 29 +Stack now 0 8 20 4 12 20 29 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Stack now 0 8 20 4 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 20 +Stack now 0 8 20 4 12 20 +Reading a token +Next token is token number (1.15: 1) +Shifting token number (1.15: 1) +Entering state 1 +Stack now 0 8 20 4 12 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 29 +Stack now 0 8 20 4 12 20 29 +Reading a token +Next token is token '+' (1.17: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Stack now 0 8 20 4 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 20 +Stack now 0 8 20 4 12 20 +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Stack now 0 8 20 4 12 +Error: popping nterm exp (1.7-15: 3) +Stack now 0 8 20 4 +Shifting token error (1.7-18: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '+' (1.20: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 20 +Stack now 0 8 20 Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 18 -Stack now 0 8 18 +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 +Stack now 0 8 20 4 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) +Error: popping token error (1.23: ) +Stack now 0 8 20 4 +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Error: popping token error (1.23: ) +Stack now 0 8 20 4 +Shifting token error (1.23-25: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Error: popping token error (1.23-25: ) +Stack now 0 8 20 4 +Shifting token error (1.23-27: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '+' (1.30: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token number (1.33: 1) +Shifting token number (1.33: 1) Entering state 1 -Stack now 0 8 18 1 +Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 27 -Stack now 0 8 18 27 + $1 = token number (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 +Stack now 0 8 20 4 12 Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 18 -Error: popping token '=' (1.3: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) -Stack now 0 -./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (- *) + (1 2) = 1 -./calc.at:1437: $PREPARSER ./calc input -stderr: -input: -Starting parse -Entering state 0 -Stack now 0 +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 21 +Stack now 0 8 20 4 12 21 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token number (1.37: 2) +Shifting token number (1.37: 2) Entering state 1 -Stack now 0 1 +Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) + $1 = token number (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 30 +Stack now 0 8 20 4 12 21 30 +Reading a token +Next token is token '*' (1.39: ) +Reducing stack by rule 9 (line 92): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Stack now 0 8 20 4 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 21 +Stack now 0 8 20 4 12 21 +Reading a token +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Stack now 0 8 20 4 12 +Error: popping nterm exp (1.33-37: 2) +Stack now 0 8 20 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) +Error: popping token error (1.33-41: ) +Stack now 0 8 20 4 +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '=' (1.44: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token number (1.46: 1) +Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) + $1 = token number (1.46: 1) +-> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 18 -Error: popping token '=' (1.3: ) +Next token is token '\n' (1.47-2.0: ) +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) +Entering state 8 Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) -Stack now 0 -stderr: -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.12: syntax error, unexpected number -1.1-17: error: 2222 != 1 -./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1440: $PREPARSER ./calc input +./calc.at:1438: $PREPARSER ./calc input input: -./calc.at:1435: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1438: "$PERL" -pi -e 'use strict; +stderr: +input: +input: + +./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -133510,12 +134172,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1 = 2 = 3 -./calc.at:1441: $PREPARSER ./calc input -stderr: stderr: -stderr: -./calc.at:1435: cat stderr Starting parse Entering state 0 Stack now 0 @@ -133826,100 +134483,32 @@ Entering state 6 Stack now 0 6 Reading a token -Next token is token end of inpStarting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 18 -Error: popping token '=' (1.3: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) -Stack now 0 -ut (2.1: ) +Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1438: cat stderr -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.12: syntax error, unexpected number -1.1-17: error: 2222 != 1 -stderr: -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 18 -Error: popping token '=' (1.3: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) -Stack now 0 -input: + | (# + 1) = 1111 +./calc.at:1433: cat stderr +./calc.at:1435: $PREPARSER ./calc input + | (#) + (#) = 2222 +./calc.at:1426: $PREPARSER ./calc input + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1445: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -134237,6 +134826,7 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1437: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -134247,114 +134837,18 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | - | +1 -input: -./calc.at:1438: $PREPARSER ./calc input - | 1//2 -./calc.at:1435: $PREPARSER ./calc input stderr: -./calc.at:1441: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1441: cat stderr -./calc.at:1437: cat stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 74): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) -Stack now 0 -./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1440: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1441: cat stderr stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 74): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) -Stack now 0 -./calc.at:1440: cat stderr -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +1.2: syntax error: invalid character: '#' ./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: - | (* *) + (*) + (*) -./calc.at:1437: $PREPARSER ./calc input -stderr: -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1438: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 stderr: -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -./calc.at:1437: "$PERL" -pi -e 'use strict; +./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -134364,52 +134858,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -input: ./calc.at:1437: cat stderr -input: - | - | +1 -./calc.at:1441: $PREPARSER ./calc input - | 1 + 2 * 3 + !+ ++ -./calc.at:1437: $PREPARSER ./calc input -stderr: -stderr: -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 74): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) -Stack now 0 -./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (!!) + (1 2) = 1 -./calc.at:1440: $PREPARSER ./calc input -./calc.at:1438: cat stderr -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -stderr: -./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: + | (1 + 1) / (1 - 1) Starting parse Entering state 0 Stack now 0 @@ -134419,278 +134869,298 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Stack now 0 4 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 15 -Stack now 0 4 5 15 -Reducing stack by rule 16 (line 107): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Stack now 0 4 -Shifting token error (1.2-3: ) +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 -Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) Entering state 20 Stack now 0 8 20 Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) Entering state 4 Stack now 0 8 20 4 Reading a token -Next token is token number (1.9: 1) -Shifting token number (1.9: 1) +Next token is token number (1.7: 1) +Shifting token number (1.7: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.9: 1) --> $$ = nterm exp (1.9: 1) + $1 = token number (1.7: 1) +-> $$ = nterm exp (1.7: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token -Next token is token number (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Stack now 0 8 20 4 -Shifting token error (1.9-11: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token number (1.11: 2) -Error: discarding token number (1.11: 2) -Error: popping token error (1.9-11: ) +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 20 +Stack now 0 8 20 4 12 20 +Reading a token +Next token is token number (1.11: 1) +Shifting token number (1.11: 1) +Entering state 1 +Stack now 0 8 20 4 12 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 29 +Stack now 0 8 20 4 12 20 29 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Stack now 0 8 20 4 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 20 +Stack now 0 8 20 4 12 20 +Reading a token +Next token is token number (1.15: 1) +Shifting token number (1.15: 1) +Entering state 1 +Stack now 0 8 20 4 12 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 29 +Stack now 0 8 20 4 12 20 29 +Reading a token +Next token is token '+' (1.17: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Stack now 0 8 20 4 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 20 +Stack now 0 8 20 4 12 20 +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Stack now 0 8 20 4 12 +Error: popping nterm exp (1.7-15: 3) Stack now 0 8 20 4 -Shifting token error (1.9-11: ) +Shifting token error (1.7-18: ) Entering state 11 Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token -Next token is token '=' (1.14: ) +Next token is token '+' (1.20: ) Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1437: $EGREP -c -v 'Return for a new token:|LAC:' stderr -stderr: -./calc.at:1438: $PREPARSER ./calc /dev/null -./calc.at:1445: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - -stderr: -Starting parse -Entering state 0 -Stack now 0 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 20 +Stack now 0 8 20 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) Entering state 4 -Stack now 0 4 +Stack now 0 8 20 4 Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Stack now 0 4 5 +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) +Error: popping token error (1.23: ) +Stack now 0 8 20 4 +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 20 4 11 Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 15 -Stack now 0 4 5 15 -Reducing stack by rule 16 (line 107): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Stack now 0 4 -Shifting token error (1.2-3: ) +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Error: popping token error (1.23: ) +Stack now 0 8 20 4 +Shifting token error (1.23-25: ) Entering state 11 -Stack now 0 4 11 +Stack now 0 8 20 4 11 Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Error: popping token error (1.23-25: ) +Stack now 0 8 20 4 +Shifting token error (1.23-27: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) Entering state 25 -Stack now 0 4 11 25 +Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '+' (1.30: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) Entering state 8 Stack now 0 8 -Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) Entering state 20 Stack now 0 8 20 Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) Entering state 4 Stack now 0 8 20 4 Reading a token -Next token is token number (1.9: 1) -Shifting token number (1.9: 1) +Next token is token number (1.33: 1) +Shifting token number (1.33: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.9: 1) --> $$ = nterm exp (1.9: 1) + $1 = token number (1.33: 1) +-> $$ = nterm exp (1.33: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token -Next token is token number (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 21 +Stack now 0 8 20 4 12 21 +Reading a token +Next token is token number (1.37: 2) +Shifting token number (1.37: 2) +Entering state 1 +Stack now 0 8 20 4 12 21 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 30 +Stack now 0 8 20 4 12 21 30 +Reading a token +Next token is token '*' (1.39: ) +Reducing stack by rule 9 (line 92): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Stack now 0 8 20 4 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 21 +Stack now 0 8 20 4 12 21 +Reading a token +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Stack now 0 8 20 4 12 +Error: popping nterm exp (1.33-37: 2) Stack now 0 8 20 4 -Shifting token error (1.9-11: ) +Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 -Next token is token number (1.11: 2) -Error: discarding token number (1.11: 2) -Error: popping token error (1.9-11: ) +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) +Error: popping token error (1.33-41: ) Stack now 0 8 20 4 -Shifting token error (1.9-11: ) +Shifting token error (1.33-41: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token -Next token is token '=' (1.14: ) +Next token is token '=' (1.44: ) Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) Entering state 8 Stack now 0 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) Entering state 18 Stack now 0 8 18 Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) +Next token is token number (1.46: 1) +Shifting token number (1.46: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) + $1 = token number (1.46: 1) +-> $$ = nterm exp (1.46: 1) Entering state 27 Stack now 0 8 18 27 Reading a token -Next token is token '\n' (1.17-2.0: ) +Next token is token '\n' (1.47-2.0: ) Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -134707,102 +135177,7 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 74): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) -Stack now 0 -input: - | 1 + 2 * 3 + !- ++ -./calc.at:1437: $PREPARSER ./calc input -stderr: -./calc.at:1441: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token end of input (1.1: ) -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token end of input (1.1: ) -Stack now 0 -./calc.at:1440: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1435: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1435: cat stderr -input: - | error -./calc.at:1435: $PREPARSER ./calc input - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1440: cat stderr -./calc.at:1445: $PREPARSER ./calc input -./calc.at:1441: cat stderr -stderr: -1.1: syntax error, unexpected invalid token -stderr: -stderr: +./calc.at:1433: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -135820,363 +136195,18 @@ Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token end of input (1.1: ) -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token end of input (1.1: ) -Stack now 0 -./calc.at:1441: $PREPARSER ./calc /dev/null -./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token end of input (1.1: ) -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token end of input (1.1: ) -Stack now 0 -input: stderr: -./calc.at:1437: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (- *) + (1 2) = 1 -./calc.at:1440: $PREPARSER ./calc input -1.1: syntax error, unexpected invalid token +input: +./calc.at:1440: cat stderr ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error: invalid character: '#' +syntax error: invalid character: '#' +1.2: syntax error: invalid character: '#' +input: stderr: -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Stack now 0 4 2 -Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 106): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2-4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token number (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Stack now 0 8 20 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token number (1.12: 2) -Error: discarding token number (1.12: 2) -Error: popping token error (1.10-12: ) -Stack now 0 8 20 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '=' (1.15: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.17: 1) --> $$ = nterm exp (1.17: 1) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token end of input (1.1: ) -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token end of input (1.1: ) -Stack now 0 -./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Stack now 0 4 2 -Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 106): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2-4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token number (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Stack now 0 8 20 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token number (1.12: 2) -Error: discarding token number (1.12: 2) -Error: popping token error (1.10-12: ) -Stack now 0 8 20 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '=' (1.15: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.17: 1) --> $$ = nterm exp (1.17: 1) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1437: cat stderr -./calc.at:1435: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1435: cat stderr +1.11-17: error: null divisor + | 1 = 2 = 3 ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -136187,9 +136217,16 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1433: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1441: $PREPARSER ./calc input +stderr: + | (1 + #) = 1111 +./calc.at:1437: $PREPARSER ./calc input input: - | 1 = 2 = 3 -./calc.at:1435: $PREPARSER ./calc input +536. calc.at:1449: testing Calculator C++ %header %locations api.location.file="my-location.hh" ... +./calc.at:1449: mv calc.y.tmp calc.y + +stderr: Starting parse Entering state 0 Stack now 0 @@ -137207,101 +137244,56 @@ Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () -stderr: -1.7: syntax error, unexpected '=' -./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1441: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 ./calc.at:1445: $EGREP -c -v 'Return for a new token:|LAC:' stderr -input: -stderr: - | (#) + (#) = 2222 -./calc.at:1437: $PREPARSER ./calc input stderr: -1.7: syntax error, unexpected '=' -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (!!) + (1 2) = 1 stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1440: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1441: cat stderr -./calc.at:1437: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 ./calc.at:1438: cat stderr -input: -./calc.at:1440: cat stderr -./calc.at:1435: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -./calc.at:1437: cat stderr - | 1 2 -./calc.at:1445: $PREPARSER ./calc input -./calc.at:1435: cat stderr - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -stderr: -./calc.at:1438: $PREPARSER ./calc input +1.11-17: error: null divisor +./calc.at:1440: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 Stack now 0 1 Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token -Next token is token number (2) -syntax error, unexpected number -Error: popping nterm exp (1) +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 18 +Error: popping token '=' (1.3: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) Stack now 0 -Cleanup: discarding lookahead token number (2) +Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 -./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -input: -stderr: +./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - | - | +1 +1.6: syntax error: invalid character: '#' +./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -137311,298 +137303,344 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Stack now 0 4 5 +Reading a token +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 15 +Stack now 0 4 5 15 +Reducing stack by rule 16 (line 107): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Stack now 0 4 +Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token -Next token is token number (1.7: 1) -Shifting token number (1.7: 1) +Next token is token number (1.9: 1) +Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 20 -Stack now 0 8 20 4 12 20 -Reading a token -Next token is token number (1.11: 1) -Shifting token number (1.11: 1) -Entering state 1 -Stack now 0 8 20 4 12 20 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.11: 1) --> $$ = nterm exp (1.11: 1) -Entering state 29 -Stack now 0 8 20 4 12 20 29 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Stack now 0 8 20 4 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 20 -Stack now 0 8 20 4 12 20 -Reading a token -Next token is token number (1.15: 1) -Shifting token number (1.15: 1) -Entering state 1 -Stack now 0 8 20 4 12 20 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 29 -Stack now 0 8 20 4 12 20 29 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) + $1 = token number (1.9: 1) +-> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 20 -Stack now 0 8 20 4 12 20 Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Stack now 0 8 20 4 12 -Error: popping nterm exp (1.7-15: 3) +Next token is token number (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 -Shifting token error (1.7-18: ) +Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) +Next token is token number (1.11: 2) +Error: discarding token number (1.11: 2) +Error: popping token error (1.9-11: ) +Stack now 0 8 20 4 +Shifting token error (1.9-11: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token -Next token is token '+' (1.20: ) +Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) -Entering state 20 -Stack now 0 8 20 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) +Entering state 18 +Stack now 0 8 18 Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Stack now 0 8 20 4 +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 27 +Stack now 0 8 18 27 Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Error: popping token error (1.23: ) -Stack now 0 8 20 4 -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 20 4 11 +Next token is token '\n' (1.17-2.0: ) +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Error: popping token error (1.23: ) -Stack now 0 8 20 4 -Shifting token error (1.23-25: ) -Entering state 11 -Stack now 0 8 20 4 11 +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1435: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1426: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +stderr: +stderr: + | 1 2 +1.6: syntax error: invalid character: '#' +stderr: +./calc.at:1435: cat stderr +./calc.at:1445: $PREPARSER ./calc input +./calc.at:1449: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +./calc.at:1433: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) -Error: popping token error (1.23-25: ) -Stack now 0 8 20 4 -Shifting token error (1.23-27: ) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 18 +Error: popping token '=' (1.3: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 + | (!!) + (1 2) = 1 +./calc.at:1438: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Stack now 0 4 5 +Reading a token +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 15 +Stack now 0 4 5 15 +Reducing stack by rule 16 (line 107): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Stack now 0 4 +Shifting token error (1.2-3: ) Entering state 11 -Stack now 0 8 20 4 11 +Stack now 0 4 11 Reading a token -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) Entering state 25 -Stack now 0 8 20 4 11 25 +Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '+' (1.30: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) +Reading a token +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token -Next token is token number (1.33: 1) -Shifting token number (1.33: 1) +Next token is token number (1.9: 1) +Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 21 -Stack now 0 8 20 4 12 21 -Reading a token -Next token is token number (1.37: 2) -Shifting token number (1.37: 2) -Entering state 1 -Stack now 0 8 20 4 12 21 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 30 -Stack now 0 8 20 4 12 21 30 -Reading a token -Next token is token '*' (1.39: ) -Reducing stack by rule 9 (line 92): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) + $1 = token number (1.9: 1) +-> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 21 -Stack now 0 8 20 4 12 21 Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Stack now 0 8 20 4 12 -Error: popping nterm exp (1.33-37: 2) +Next token is token number (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 -Shifting token error (1.33-41: ) +Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Error: popping token error (1.33-41: ) +Next token is token number (1.11: 2) +Error: discarding token number (1.11: 2) +Error: popping token error (1.9-11: ) Stack now 0 8 20 4 -Shifting token error (1.33-41: ) +Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token -Next token is token '=' (1.44: ) +Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token -Next token is token number (1.46: 1) -Shifting token number (1.46: 1) +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.46: 1) --> $$ = nterm exp (1.46: 1) + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token -Next token is token '\n' (1.47-2.0: ) +Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -137619,7 +137657,7 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1435: $PREPARSER ./calc input +stderr: Starting parse Entering state 0 Stack now 0 @@ -137640,15 +137678,6 @@ Stack now 0 Cleanup: discarding lookahead token number (2) Stack now 0 -./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: - | (* *) + (*) + (*) -2.1: syntax error, unexpected '+' -./calc.at:1440: $PREPARSER ./calc input -input: -./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: Starting parse Entering state 0 Stack now 0 @@ -137658,132 +137687,121 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Stack now 0 4 5 Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2: ) +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 15 +Stack now 0 4 5 15 +Reducing stack by rule 16 (line 107): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) Stack now 0 4 -Shifting token error (1.2-4: ) +Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) +Next token is token number (1.9: 1) +Shifting token number (1.9: 1) +Entering state 1 +Stack now 0 8 20 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.9: 1) +-> $$ = nterm exp (1.9: 1) +Entering state 12 +Stack now 0 8 20 4 12 +Reading a token +Next token is token number (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Stack now 0 8 20 4 +Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) -Error: popping token error (1.10: ) +Next token is token number (1.11: 2) +Error: discarding token number (1.11: 2) +Error: popping token error (1.9-11: ) Stack now 0 8 20 4 -Shifting token error (1.10: ) +Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token -Next token is token '+' (1.13: ) +Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) -Error: popping token error (1.16: ) -Stack now 0 8 20 4 -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 20 4 11 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) +Entering state 18 +Stack now 0 8 18 Reading a token -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 29 -Stack now 0 8 20 29 +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 27 +Stack now 0 8 18 27 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) +Next token is token '\n' (1.17-2.0: ) +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -137800,15 +137818,47 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1441: $PREPARSER ./calc input - | (1 + #) = 1111 -./calc.at:1437: $PREPARSER ./calc input +./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1426: cat stderr +./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1437: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: + | (1 + # + 1) = 1111 +./calc.at:1435: $PREPARSER ./calc input +./calc.at:1433: cat stderr +./calc.at:1441: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: +input: stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1440: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Stack now 0 @@ -137818,298 +137868,121 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Stack now 0 4 5 +Reading a token +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 15 +Stack now 0 4 5 15 +Reducing stack by rule 16 (line 107): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Stack now 0 4 +Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token number (1.7: 1) -Shifting token number (1.7: 1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 20 -Stack now 0 8 20 4 12 20 -Reading a token -Next token is token number (1.11: 1) -Shifting token number (1.11: 1) -Entering state 1 -Stack now 0 8 20 4 12 20 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.11: 1) --> $$ = nterm exp (1.11: 1) -Entering state 29 -Stack now 0 8 20 4 12 20 29 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Stack now 0 8 20 4 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 20 -Stack now 0 8 20 4 12 20 -Reading a token -Next token is token number (1.15: 1) -Shifting token number (1.15: 1) -Entering state 1 -Stack now 0 8 20 4 12 20 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 29 -Stack now 0 8 20 4 12 20 29 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Stack now 0 8 20 4 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 20 -Stack now 0 8 20 4 12 20 -Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Stack now 0 8 20 4 12 -Error: popping nterm exp (1.7-15: 3) -Stack now 0 8 20 4 -Shifting token error (1.7-18: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '+' (1.20: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Error: popping token error (1.23: ) -Stack now 0 8 20 4 -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Error: popping token error (1.23: ) -Stack now 0 8 20 4 -Shifting token error (1.23-25: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) -Error: popping token error (1.23-25: ) -Stack now 0 8 20 4 -Shifting token error (1.23-27: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 29 -Stack now 0 8 20 29 Reading a token -Next token is token '+' (1.30: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token -Next token is token number (1.33: 1) -Shifting token number (1.33: 1) +Next token is token number (1.9: 1) +Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 21 -Stack now 0 8 20 4 12 21 -Reading a token -Next token is token number (1.37: 2) -Shifting token number (1.37: 2) -Entering state 1 -Stack now 0 8 20 4 12 21 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 30 -Stack now 0 8 20 4 12 21 30 -Reading a token -Next token is token '*' (1.39: ) -Reducing stack by rule 9 (line 92): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) + $1 = token number (1.9: 1) +-> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 21 -Stack now 0 8 20 4 12 21 Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Stack now 0 8 20 4 12 -Error: popping nterm exp (1.33-37: 2) +Next token is token number (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 -Shifting token error (1.33-41: ) +Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Error: popping token error (1.33-41: ) +Next token is token number (1.11: 2) +Error: discarding token number (1.11: 2) +Error: popping token error (1.9-11: ) Stack now 0 8 20 4 -Shifting token error (1.33-41: ) +Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token -Next token is token '=' (1.44: ) +Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token -Next token is token number (1.46: 1) -Shifting token number (1.46: 1) +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.46: 1) --> $$ = nterm exp (1.46: 1) + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token -Next token is token '\n' (1.47-2.0: ) +Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -138126,9 +137999,114 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) + | (1 + #) = 1111 +./calc.at:1426: $PREPARSER ./calc input +1.6: syntax error: invalid character: '#' +./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1437: cat stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token number (2) +syntax error, unexpected number +Error: popping nterm exp (1) +Stack now 0 +Cleanup: discarding lookahead token number (2) +Stack now 0 +stderr: +./calc.at:1441: cat stderr +525. calc.at:1433: syntax error: invalid character: '#' + ok +./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1440: cat stderr +stderr: +stderr: +./calc.at:1449: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS +syntax error: invalid character: '#' +1.6: syntax error: invalid character: '#' +input: +./calc.at:1438: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: + | + | +1 +input: +./calc.at:1441: $PREPARSER ./calc input + | (# + 1) = 1111 +./calc.at:1445: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (- *) + (1 2) = 1 +./calc.at:1440: $PREPARSER ./calc input +./calc.at:1437: $PREPARSER ./calc input stderr: +./calc.at:1435: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: stderr: +./calc.at:1438: cat stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 74): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Stack now 0 +Cleanup: discarding lookahead token '+' (2.1: ) +Stack now 0 +1.2: syntax error: invalid character: '#' +./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -138138,22 +138116,26 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) -Error: popping token error (1.2: ) +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Stack now 0 4 2 +Reading a token +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 106): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) Stack now 0 4 -Shifting token error (1.2: ) +Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 -Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) -Error: popping token error (1.2: ) +Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 @@ -138181,9 +138163,802 @@ Entering state 4 Stack now 0 8 20 4 Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) +Entering state 1 +Stack now 0 8 20 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Stack now 0 8 20 4 12 +Reading a token +Next token is token number (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Stack now 0 8 20 4 +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token number (1.12: 2) +Error: discarding token number (1.12: 2) +Error: popping token error (1.10-12: ) +Stack now 0 8 20 4 +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '=' (1.15: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.17: 1) +-> $$ = nterm exp (1.17: 1) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1445: cat stderr + +./calc.at:1435: cat stderr +./calc.at:1426: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +stderr: +input: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Stack now 0 4 2 +Reading a token +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 106): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2-4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) +Entering state 1 +Stack now 0 8 20 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Stack now 0 8 20 4 12 +Reading a token +Next token is token number (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Stack now 0 8 20 4 +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token number (1.12: 2) +Error: discarding token number (1.12: 2) +Error: popping token error (1.10-12: ) +Stack now 0 8 20 4 +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '=' (1.15: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.17: 1) +-> $$ = nterm exp (1.17: 1) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: + | (- *) + (1 2) = 1 +./calc.at:1438: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 74): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Stack now 0 +Cleanup: discarding lookahead token '+' (2.1: ) +Stack now 0 +input: +input: +1.2: syntax error: invalid character: '#' +./calc.at:1426: cat stderr +stderr: + | (1 + 1) / (1 - 1) +./calc.at:1435: $PREPARSER ./calc input + | 1//2 +./calc.at:1445: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Stack now 0 4 2 +Reading a token +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 106): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2-4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) +Entering state 1 +Stack now 0 8 20 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Stack now 0 8 20 4 12 +Reading a token +Next token is token number (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Stack now 0 8 20 4 +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token number (1.12: 2) +Error: discarding token number (1.12: 2) +Error: popping token error (1.10-12: ) +Stack now 0 8 20 4 +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '=' (1.15: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.17: 1) +-> $$ = nterm exp (1.17: 1) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.11-17: error: null divisor +./calc.at:1441: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1437: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '/' () +Shifting token '/' () +Entering state 22 +Stack now 0 8 22 +Reading a token +Next token is token '/' () +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' () +Stack now 0 8 +Error: popping nterm exp (1) +Stack now 0 +Cleanup: discarding lookahead token '/' () +Stack now 0 +input: +./calc.at:1440: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1441: cat stderr + | (# + 1) = 1111 +stderr: +./calc.at:1426: $PREPARSER ./calc input +./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1437: cat stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Stack now 0 4 2 +Reading a token +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 106): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2-4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) +Entering state 1 +Stack now 0 8 20 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Stack now 0 8 20 4 12 +Reading a token +Next token is token number (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Stack now 0 8 20 4 +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token number (1.12: 2) +Error: discarding token number (1.12: 2) +Error: popping token error (1.10-12: ) +Stack now 0 8 20 4 +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '=' (1.15: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.17: 1) +-> $$ = nterm exp (1.17: 1) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: +stderr: +stderr: +syntax error: invalid character: '#' +./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.11-17: error: null divisor +./calc.at:1440: cat stderr +./calc.at:1441: $PREPARSER ./calc /dev/null +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '/' () +Shifting token '/' () +Entering state 22 +Stack now 0 8 22 +Reading a token +Next token is token '/' () +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' () +Stack now 0 8 +Error: popping nterm exp (1) +Stack now 0 +Cleanup: discarding lookahead token '/' () +Stack now 0 +537. calc.at:1451: testing Calculator C++ %no-lines %header %locations api.location.file="my-location.hh" ... +./calc.at:1451: mv calc.y.tmp calc.y + +stderr: +stderr: +./calc.at:1438: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token end of input (1.1: ) +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token end of input (1.1: ) +Stack now 0 +./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | (1 + # + 1) = 1111 +./calc.at:1451: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +./calc.at:1435: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1437: $PREPARSER ./calc input +syntax error: invalid character: '#' + | (* *) + (*) + (*) +./calc.at:1440: $PREPARSER ./calc input +./calc.at:1438: cat stderr +stderr: +stderr: +./calc.at:1435: cat stderr +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Next token is token '*' (1.10: ) @@ -138280,7 +139055,561 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -2.1: syntax error, unexpected '+' +./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.6: syntax error: invalid character: '#' +./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token end of input (1.1: ) +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token end of input (1.1: ) +Stack now 0 +stderr: +./calc.at:1445: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) +Error: popping token error (1.10: ) +Stack now 0 8 20 4 +Shifting token error (1.10: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) +Error: popping token error (1.16: ) +Stack now 0 8 20 4 +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +527. calc.at:1435: ok +stderr: +./calc.at:1426: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +1.6: syntax error: invalid character: '#' +input: +./calc.at:1441: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1445: cat stderr + | (* *) + (*) + (*) +./calc.at:1438: $PREPARSER ./calc input +./calc.at:1440: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1441: cat stderr +stderr: +./calc.at:1426: cat stderr +./calc.at:1437: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) +Error: popping token error (1.10: ) +Stack now 0 8 20 4 +Shifting token error (1.10: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) +Error: popping token error (1.16: ) +Stack now 0 8 20 4 +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +input: +./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1440: cat stderr +./calc.at:1451: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS + | error +./calc.at:1445: $PREPARSER ./calc input + +input: +stderr: +stderr: +./calc.at:1437: cat stderr + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1441: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) +Error: popping token error (1.10: ) +Stack now 0 8 20 4 +Shifting token error (1.10: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) +Error: popping token error (1.16: ) +Stack now 0 8 20 4 +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token invalid token () +syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token () +Stack now 0 +input: + | (1 + # + 1) = 1111 +./calc.at:1426: $PREPARSER ./calc input +./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +input: + | 1 + 2 * 3 + !+ ++ +stderr: +./calc.at:1440: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -138599,8 +139928,116 @@ Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error: invalid character: '#' +stderr: +input: +./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1438: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Stack now 0 8 20 29 21 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 20 29 21 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Stack now 0 8 20 29 21 30 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 92): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Stack now 0 8 20 29 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 20 5 +Reading a token +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Stack now 0 8 20 5 14 +Reducing stack by rule 17 (line 108): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Stack now 0 8 20 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) + | (1 + 1) / (1 - 1) +./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1437: $PREPARSER ./calc input stderr: stderr: +stderr: +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token invalid token () +syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token () +Stack now 0 +syntax error: invalid character: '#' Starting parse Entering state 0 Stack now 0 @@ -138911,14 +140348,105 @@ Entering state 6 Stack now 0 6 Reading a token -Next token is token end of input (2.1: ) +Next token is token end of inp1.11-17: error: null divisor +ut (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1440: "$PERL" -pi -e 'use strict; +./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +538. calc.at:1453: testing Calculator C++ %locations parse.lac=full parse.error=verbose ... +stderr: +./calc.at:1438: cat stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Stack now 0 8 20 29 21 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 20 29 21 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Stack now 0 8 20 29 21 30 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 92): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Stack now 0 8 20 29 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 20 5 +Reading a token +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Stack now 0 8 20 5 14 +Reducing stack by rule 17 (line 108): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Stack now 0 8 20 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1440: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1453: mv calc.y.tmp calc.y + +stderr: +./calc.at:1453: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +input: +./calc.at:1426: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -138928,7 +140456,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.6: syntax error: invalid character: '#' + | 1 + 2 * 3 + !- ++ +./calc.at:1440: $PREPARSER ./calc input +1.11-17: error: null divisor +input: ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -138939,20 +140470,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1438: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1440: cat stderr -input: +stderr: | 1 + 2 * 3 + !+ ++ -./calc.at:1440: $PREPARSER ./calc input ./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -138963,18 +140482,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1445: cat stderr -./calc.at:1435: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: +./calc.at:1438: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -139045,81 +140553,31 @@ Entering state 5 Stack now 0 8 20 5 Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Stack now 0 8 20 5 14 -Reducing stack by rule 17 (line 108): +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Stack now 0 8 20 5 13 +Reducing stack by rule 18 (line 109): $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) + $2 = token '-' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1441: cat stderr -input: +./calc.at:1426: cat stderr ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1438: cat stderr - | 1//2 -./calc.at:1445: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Stack now 0 8 22 -Reading a token -Next token is token '/' () -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' () -Stack now 0 8 -Error: popping nterm exp (1) -Stack now 0 -Cleanup: discarding lookahead token '/' () -Stack now 0 -./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1435: cat stderr -stderr: +./calc.at:1445: cat stderr stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Stack now 0 8 22 -Reading a token -Next token is token '/' () -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' () -Stack now 0 8 -Error: popping nterm exp (1) -Stack now 0 -Cleanup: discarding lookahead token '/' () -Stack now 0 +./calc.at:1453: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +./calc.at:1437: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Stack now 0 @@ -139200,40 +140658,9 @@ Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1440: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1435: $PREPARSER ./calc /dev/null -./calc.at:1437: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1437: cat stderr -stderr: -1.1: syntax error, unexpected end of input -./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | 1 + 2 * 3 + !- ++ -./calc.at:1440: $PREPARSER ./calc input -input: -stderr: +./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.1: syntax error, unexpected end of input -./calc.at:1445: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: +./calc.at:1441: cat stderr Starting parse Entering state 0 Stack now 0 @@ -139314,12 +140741,15 @@ Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) - | (!!) + (1 2) = 1 -./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1438: $PREPARSER ./calc input - | (!!) + (1 2) = 1 +input: +input: +./calc.at:1437: cat stderr stderr: -./calc.at:1445: cat stderr + | 1 = 2 = 3 + | (1 + 1) / (1 - 1) +./calc.at:1445: $PREPARSER ./calc input +./calc.at:1426: $PREPARSER ./calc input +input: Starting parse Entering state 0 Stack now 0 @@ -139390,17 +140820,20 @@ Entering state 5 Stack now 0 8 20 5 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Stack now 0 8 20 5 13 -Reducing stack by rule 18 (line 109): +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Stack now 0 8 20 5 14 +Reducing stack by rule 17 (line 108): $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) + $2 = token '+' (1.14: ) Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1441: $PREPARSER ./calc input +./calc.at:1438: $EGREP -c -v 'Return for a new token:|LAC:' stderr +stderr: +528. calc.at:1437: ok + | (!!) + (1 2) = 1 ./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -139411,9 +140844,50 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1441: $PREPARSER ./calc input stderr: -./calc.at:1440: cat stderr -input: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '=' () +syntax error, unexpected '=' +Error: popping nterm exp (2) +Stack now 0 8 18 +Error: popping token '=' () +Stack now 0 8 +Error: popping nterm exp (1) +Stack now 0 +Cleanup: discarding lookahead token '=' () +Stack now 0 +error: null divisor +stderr: +./calc.at:1426: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -139554,20 +141028,15 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1435: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (# + 1) = 1111 -stderr: ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1435: cat stderr +./calc.at:1440: cat stderr +./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +stderr: +stderr: +stderr: + | 1 + 2 * 3 + !- ++ +./calc.at:1438: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -139708,15 +141177,143 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '=' () +syntax error, unexpected '=' +Error: popping nterm exp (2) +Stack now 0 8 18 +Error: popping token '=' () +Stack now 0 8 +Error: popping nterm exp (1) +Stack now 0 +Cleanup: discarding lookahead token '=' () +Stack now 0 +error: null divisor +stderr: input: -./calc.at:1437: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Stack now 0 8 20 29 21 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 20 29 21 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Stack now 0 8 20 29 21 30 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 92): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Stack now 0 8 20 29 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 20 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Stack now 0 8 20 5 13 +Reducing stack by rule 18 (line 109): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Stack now 0 8 20 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (#) + (#) = 2222 + ./calc.at:1440: $PREPARSER ./calc input -input: - | error +./calc.at:1441: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -./calc.at:1445: $PREPARSER ./calc input -./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -139840,17 +141437,112 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -input: +./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1441: cat stderr +./calc.at:1445: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token invalid token () -syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token () -Stack now 0 +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Stack now 0 8 20 29 21 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 20 29 21 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Stack now 0 8 20 29 21 30 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack by rule 9 (line 92): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Stack now 0 8 20 29 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 20 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Stack now 0 8 20 5 13 +Reducing stack by rule 18 (line 109): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Stack now 0 8 20 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1426: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1445: cat stderr +input: + | (- *) + (1 2) = 1 stderr: Starting parse Entering state 0 @@ -139975,337 +141667,6 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1435: $PREPARSER ./calc input -stderr: -stderr: -stderr: -./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Stack now 0 4 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 15 -Stack now 0 4 5 15 -Reducing stack by rule 16 (line 107): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Stack now 0 4 -Shifting token error (1.2-3: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token number (1.9: 1) -Shifting token number (1.9: 1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.9: 1) --> $$ = nterm exp (1.9: 1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token number (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Stack now 0 8 20 4 -Shifting token error (1.9-11: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token number (1.11: 2) -Error: discarding token number (1.11: 2) -Error: popping token error (1.9-11: ) -Stack now 0 8 20 4 -Shifting token error (1.9-11: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '=' (1.14: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -stderr: -1.2: syntax error: invalid character: '#' -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token invalid token () -syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token () -Stack now 0 -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.1-46: error: 4444 != 1 -./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Stack now 0 4 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 15 -Stack now 0 4 5 15 -Reducing stack by rule 16 (line 107): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Stack now 0 4 -Shifting token error (1.2-3: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token number (1.9: 1) -Shifting token number (1.9: 1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.9: 1) --> $$ = nterm exp (1.9: 1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token number (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Stack now 0 8 20 4 -Shifting token error (1.9-11: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token number (1.11: 2) -Error: discarding token number (1.11: 2) -Error: popping token error (1.9-11: ) -Stack now 0 8 20 4 -Shifting token error (1.9-11: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '=' (1.14: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1441: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1441: cat stderr -./calc.at:1440: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.1-46: error: 4444 != 1 ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -140316,52 +141677,13 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -./calc.at:1435: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.2: syntax error: invalid character: '#' -./calc.at:1435: cat stderr -./calc.at:1438: cat stderr -./calc.at:1440: cat stderr -./calc.at:1445: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -input: - | (- *) + (1 2) = 1 ./calc.at:1441: $PREPARSER ./calc input - | (!!) + (1 2) = 1 -./calc.at:1435: $PREPARSER ./calc input -stderr: -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 -./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +539. calc.at:1454: testing Calculator C++ %locations parse.lac=full parse.error=detailed ... stderr: +./calc.at:1438: cat stderr +./calc.at:1454: mv calc.y.tmp calc.y + input: - | (- *) + (1 2) = 1 -./calc.at:1438: $PREPARSER ./calc input -input: -./calc.at:1445: cat stderr - | (1 + #) = 1111 -stderr: -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 -./calc.at:1440: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -140511,7 +141833,12 @@ Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1437: "$PERL" -pi -e 'use strict; + | + | +1 +./calc.at:1445: $PREPARSER ./calc input +stderr: +./calc.at:1454: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +./calc.at:1440: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -140521,210 +141848,33 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: +./calc.at:1426: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Stack now 0 4 12 20 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 74): + $1 = token '\n' () +-> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) + $1 = nterm line () +-> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -./calc.at:1437: cat stderr -stderr: -Starting parse -Entering state 0 +Next token is token '+' () +syntax error, unexpected '+' +Error: popping nterm input () Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Stack now 0 4 12 20 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +Cleanup: discarding lookahead token '+' () +Stack now 0 +stderr: Starting parse Entering state 0 Stack now 0 @@ -140873,7 +142023,49 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: + | (#) + (#) = 2222 +./calc.at:1438: $PREPARSER ./calc input +./calc.at:1440: cat stderr +522. calc.at:1426: stderr: + ok +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 74): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '+' () +syntax error, unexpected '+' +Error: popping nterm input () +Stack now 0 +Cleanup: discarding lookahead token '+' () +Stack now 0 +./calc.at:1441: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Stack now 0 @@ -140883,129 +142075,104 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Stack now 0 4 2 -Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 106): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2-4: ) +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.1-2: ) Stack now 0 4 -Shifting token error (1.2-4: ) +Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) + $2 = token error (1.1-2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token number (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Stack now 0 8 20 4 -Shifting token error (1.10-12: ) +1.8: syntax error: invalid character: '#' +Next token is token error (1.8: ) +Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 -Next token is token number (1.12: 2) -Error: discarding token number (1.12: 2) -Error: popping token error (1.10-12: ) +Next token is token invalid token (1.8: ) +Error: discarding token invalid token (1.8: ) +Error: popping token error (1.1-8: ) Stack now 0 8 20 4 -Shifting token error (1.10-12: ) +Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) + $1 = token '(' (1.7: ) + $2 = token error (1.1-8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token -Next token is token '=' (1.15: ) +Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) +Next token is token number (1.13-16: 2222) +Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.17: 1) --> $$ = nterm exp (1.17: 1) + $1 = token number (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token -Next token is token '\n' (1.18-2.0: ) +Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -141023,18 +142190,11 @@ Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1435: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | 1 = 2 = 3 -./calc.at:1445: $PREPARSER ./calc input +input: + | (1 + #) = 1111 +./calc.at:1440: $PREPARSER ./calc input +./calc.at:1441: cat stderr +stderr: stderr: Starting parse Entering state 0 @@ -141045,129 +142205,104 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Stack now 0 4 2 -Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 106): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2-4: ) +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.1-2: ) Stack now 0 4 -Shifting token error (1.2-4: ) +Shifting token error (1.1-2: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) + $2 = token error (1.1-2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) Entering state 20 Stack now 0 8 20 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) Entering state 4 Stack now 0 8 20 4 Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token number (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Stack now 0 8 20 4 -Shifting token error (1.10-12: ) +1.8: syntax error: invalid character: '#' +Next token is token error (1.8: ) +Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 -Next token is token number (1.12: 2) -Error: discarding token number (1.12: 2) -Error: popping token error (1.10-12: ) +Next token is token invalid token (1.8: ) +Error: discarding token invalid token (1.8: ) +Error: popping token error (1.1-8: ) Stack now 0 8 20 4 -Shifting token error (1.10-12: ) +Shifting token error (1.1-8: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) + $1 = token '(' (1.7: ) + $2 = token error (1.1-8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token -Next token is token '=' (1.15: ) +Next token is token '=' (1.11: ) Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) Entering state 8 Stack now 0 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) Entering state 18 Stack now 0 8 18 Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) +Next token is token number (1.13-16: 2222) +Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.17: 1) --> $$ = nterm exp (1.17: 1) + $1 = token number (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token -Next token is token '\n' (1.18-2.0: ) +Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -141184,60 +142319,108 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1441: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1441: cat stderr -input: -./calc.at:1435: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 -Stack now 0 1 +Stack now 0 4 1 Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Stack now 0 4 12 20 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' () -Shifting token '=' () +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 18 Stack now 0 8 18 Reading a token -Next token is token number (2) -Shifting token number (2) +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): - $1 = token number (2) --> $$ = nterm exp (2) + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 27 Stack now 0 8 18 27 Reading a token -Next token is token '=' () -syntax error, unexpected '=' -Error: popping nterm exp (2) -Stack now 0 8 18 -Error: popping token '=' () +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 Stack now 0 8 -Error: popping nterm exp (1) -Stack now 0 -Cleanup: discarding lookahead token '=' () -Stack now 0 -./calc.at:1438: "$PERL" -pi -e 'use strict; +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) + +./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -141247,8 +142430,13 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1438: cat stderr -./calc.at:1440: "$PERL" -pi -e 'use strict; +input: +./calc.at:1454: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS + | (* *) + (*) + (*) +./calc.at:1441: $PREPARSER ./calc input +stderr: +./calc.at:1445: cat stderr +./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -141258,22 +142446,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (1 + # + 1) = 1111 -./calc.at:1437: $PREPARSER ./calc input -./calc.at:1440: cat stderr -stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -input: - | (* *) + (*) + (*) - | (* *) + (*) + (*) -./calc.at:1441: $PREPARSER ./calc input -./calc.at:1438: $PREPARSER ./calc input stderr: - | (- *) + (1 2) = 1 Starting parse Entering state 0 Stack now 0 @@ -141283,132 +142456,80 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) -Error: popping token error (1.2: ) +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Stack now 0 4 12 20 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) Stack now 0 4 -Shifting token error (1.2: ) +Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 -Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2: ) +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) Stack now 0 4 -Shifting token error (1.2-4: ) +Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) -Error: popping token error (1.10: ) -Stack now 0 8 20 4 -Shifting token error (1.10: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 -Stack now 0 8 20 4 Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) -Error: popping token error (1.16: ) -Stack now 0 8 20 4 -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 20 4 11 +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 18 +Stack now 0 8 18 Reading a token -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 29 -Stack now 0 8 20 29 +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 27 +Stack now 0 8 18 27 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -141425,10 +142546,6 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: -./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1435: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -141581,6 +142698,8 @@ Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1438: cat stderr +./calc.at:1445: $PREPARSER ./calc /dev/null stderr: Starting parse Entering state 0 @@ -141733,11 +142852,47 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1440: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token end of input () +syntax error, unexpected end of input +Cleanup: discarding lookahead token end of input () +Stack now 0 +input: +./calc.at:1440: cat stderr +540. calc.at:1455: testing Calculator C++ %locations parse.lac=full parse.error=detailed parse.trace ... +./calc.at:1455: mv calc.y.tmp calc.y + + | (1 + #) = 1111 +./calc.at:1438: $PREPARSER ./calc input +./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1441: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1455: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +input: stderr: - | (# + 1) = 1111 stderr: -./calc.at:1440: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -141747,132 +142902,80 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) -Error: popping token error (1.2: ) +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Stack now 0 4 12 20 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) Stack now 0 4 -Shifting token error (1.2: ) +Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 -Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2: ) +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) Stack now 0 4 -Shifting token error (1.2-4: ) +Shifting token error (1.2-6: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) -Error: popping token error (1.10: ) -Stack now 0 8 20 4 -Shifting token error (1.10: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Stack now 0 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 -Stack now 0 8 20 4 Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) -Error: popping token error (1.16: ) -Stack now 0 8 20 4 -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 20 4 11 +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 18 +Stack now 0 8 18 Reading a token -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 29 -Stack now 0 8 20 29 +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 27 +Stack now 0 8 18 27 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -141889,61 +142992,19 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -1.6: syntax error: invalid character: '#' -stderr: + | (# + 1) = 1111 +./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1440: $PREPARSER ./calc input +./calc.at:1441: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '=' () -syntax error, unexpected '=' -Error: popping nterm exp (2) -Stack now 0 8 18 -Error: popping token '=' () -Stack now 0 8 -Error: popping nterm exp (1) -Stack now 0 -Cleanup: discarding lookahead token '=' () +Next token is token end of input () +syntax error, unexpected end of input +Cleanup: discarding lookahead token end of input () Stack now 0 stderr: -./calc.at:1438: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.12: syntax error, unexpected number -1.1-17: error: 2222 != 1 Starting parse Entering state 0 Stack now 0 @@ -142040,80 +143101,109 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1445: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1441: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1438: cat stderr -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.12: syntax error, unexpected number -1.1-17: error: 2222 != 1 -./calc.at:1445: cat stderr -./calc.at:1437: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1437: cat stderr -input: - | - | +1 -./calc.at:1445: $PREPARSER ./calc input -input: -./calc.at:1441: cat stderr stderr: - | 1 + 2 * 3 + !+ ++ Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 74): - $1 = token '\n' () --> $$ = nterm line () +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Stack now 0 4 12 20 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token '+' () -syntax error, unexpected '+' -Error: popping nterm input () -Stack now 0 -Cleanup: discarding lookahead token '+' () -Stack now 0 -./calc.at:1438: $PREPARSER ./calc input +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +input: +stderr: Starting parse Entering state 0 Stack now 0 @@ -142210,6 +143300,18 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) + | 1 + 2 * 3 + !+ ++ +./calc.at:1441: $PREPARSER ./calc input +./calc.at:1445: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: Starting parse Entering state 0 @@ -142291,9 +143393,18 @@ Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -input: -./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1435: "$PERL" -pi -e 'use strict; +./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1440: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -142303,9 +143414,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1445: cat stderr +./calc.at:1455: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: -./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (1 + 1) / (1 - 1) Starting parse Entering state 0 Stack now 0 @@ -142386,324 +143497,440 @@ Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1437: $PREPARSER ./calc input +./calc.at:1441: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1438: cat stderr +./calc.at:1440: cat stderr +input: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1445: $PREPARSER ./calc input +input: input: -./calc.at:1438: $EGREP -c -v 'Return for a new token:|LAC:' stderr - | 1 + 2 * 3 + !+ ++ -stderr: -./calc.at:1441: $PREPARSER ./calc input -1.11-17: error: null divisor -./calc.at:1437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1435: cat stderr -stderr: -1.11-17: error: null divisor stderr: + | (# + 1) = 1111 +./calc.at:1438: $PREPARSER ./calc input input: stderr: - | 1 + 2 * 3 + !- ++ Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token ')' () +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Stack now 0 4 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) +Next token is token '+' () +Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token number (1) +Shifting token number (1) Entering state 1 -Stack now 0 8 20 1 +Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Stack now 0 8 20 4 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Stack now 0 8 20 4 12 20 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 8 20 4 12 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 29 -Stack now 0 8 20 29 +Stack now 0 8 20 4 12 20 29 Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 -Stack now 0 8 20 29 21 +Next token is token '+' () +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 +Stack now 0 8 20 4 12 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Stack now 0 8 20 4 12 20 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token number (1) +Shifting token number (1) Entering state 1 -Stack now 0 8 20 29 21 1 +Stack now 0 8 20 4 12 20 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 -Stack now 0 8 20 29 21 30 + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 +Stack now 0 8 20 4 12 20 29 Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) +Next token is token '+' () +Reducing stack by rule 7 (line 90): + $1 = nterm exp (2) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (3) +Entering state 12 +Stack now 0 8 20 4 12 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Stack now 0 8 20 4 12 20 +Reading a token +Next token is token ')' () +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' () +Stack now 0 8 20 4 12 +Error: popping nterm exp (3) +Stack now 0 8 20 4 +Shifting token error () +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 -Next token is token '+' (1.11: ) +Reading a token +Next token is token '+' () Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) +Next token is token '+' () +Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 20 5 +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Stack now 0 8 20 4 Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Stack now 0 8 20 5 14 -Reducing stack by rule 17 (line 108): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Stack now 0 8 20 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1438: $PREPARSER ./calc input -./calc.at:1440: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -Starting parse -Entering state 0 -Stack now 0 +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' () +Error: discarding token '*' () +Error: popping token error () +Stack now 0 8 20 4 +Shifting token error () +Entering state 11 +Stack now 0 8 20 4 11 Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 74): - $1 = token '\n' () --> $$ = nterm line () -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Stack now 0 6 +Next token is token '*' () +Error: discarding token '*' () +Error: popping token error () +Stack now 0 8 20 4 +Shifting token error () +Entering state 11 +Stack now 0 8 20 4 11 Reading a token -Next token is token '+' () -syntax error, unexpected '+' -Error: popping nterm input () -Stack now 0 -Cleanup: discarding lookahead token '+' () -Stack now 0 -stderr: -stderr: - | (* *) + (*) + (*) -./calc.at:1435: $PREPARSER ./calc input -stderr: -./calc.at:1437: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Stack now 0 +Next token is token '*' () +Error: discarding token '*' () +Error: popping token error () +Stack now 0 8 20 4 +Shifting token error () +Entering state 11 +Stack now 0 8 20 4 11 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '+' () +Reducing stack by rule 7 (line 90): + $1 = nterm exp (2222) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (3333) Entering state 8 Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) +Next token is token '+' () +Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token number (1) +Shifting token number (1) Entering state 1 -Stack now 0 8 20 1 +Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 -Stack now 0 8 20 29 + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Stack now 0 8 20 4 12 Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) +Next token is token '*' () +Shifting token '*' () Entering state 21 -Stack now 0 8 20 29 21 +Stack now 0 8 20 4 12 21 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token number (2) +Shifting token number (2) Entering state 1 -Stack now 0 8 20 29 21 1 +Stack now 0 8 20 4 12 21 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) + $1 = token number (2) +-> $$ = nterm exp (2) Entering state 30 -Stack now 0 8 20 29 21 30 +Stack now 0 8 20 4 12 21 30 Reading a token -Next token is token '+' (1.11: ) +Next token is token '*' () Reducing stack by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) + $1 = nterm exp (1) + $2 = token '*' () + $3 = nterm exp (2) +-> $$ = nterm exp (2) +Entering state 12 +Stack now 0 8 20 4 12 +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Stack now 0 8 20 4 12 21 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' () +Stack now 0 8 20 4 12 +Error: popping nterm exp (2) +Stack now 0 8 20 4 +Shifting token error () +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' () +Error: discarding token '*' () +Error: popping token error () +Stack now 0 8 20 4 +Shifting token error () +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 -Next token is token '+' (1.11: ) +Reading a token +Next token is token '=' () Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) + $1 = nterm exp (3333) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (4444) Entering state 8 Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 20 -Stack now 0 8 20 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Stack now 0 8 18 Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 20 5 +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 27 +Stack now 0 8 18 27 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Stack now 0 8 20 5 13 -Reducing stack by rule 18 (line 109): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Stack now 0 8 20 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Next token is token '\n' () +Reducing stack by rule 6 (line 80): + $1 = nterm exp (4444) + $2 = token '=' () + $3 = nterm exp (1) +error: 4444 != 1 +-> $$ = nterm exp (4444) +Entering state 8 +Stack now 0 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (4444) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input () +Shifting token end of input () +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input () +Cleanup: popping nterm input () + | (1 + # + 1) = 1111 +./calc.at:1440: $PREPARSER ./calc input + | 1 + 2 * 3 + !- ++ +./calc.at:1441: $PREPARSER ./calc input +stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 20 -Stack now 0 8 20 +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.1-2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.1-2: ) +Stack now 0 4 +Shifting token error (1.1-2: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 20 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 -Stack now 0 8 20 29 +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Error: popping token error (1.1-2: ) +Stack now 0 4 +Shifting token error (1.1-4: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 -Stack now 0 8 20 29 21 +Next token is token number (1.6: 1) +Error: discarding token number (1.6: 1) +Error: popping token error (1.1-4: ) +Stack now 0 4 +Shifting token error (1.1-6: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.1-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 -Stack now 0 8 20 29 21 1 +Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 -Stack now 0 8 20 29 21 30 + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 27 +Stack now 0 8 18 27 Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Stack now 0 8 20 29 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 20 5 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Stack now 0 8 20 5 14 -Reducing stack by rule 17 (line 108): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Stack now 0 8 20 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1441: $EGREP -c -v 'Return for a new token:|LAC:' stderr -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1440: cat stderr -./calc.at:1437: cat stderr -stderr: +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -142784,51 +144011,7 @@ Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1445: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -./calc.at:1445: cat stderr -input: - | (1 + # + 1) = 1111 -./calc.at:1440: $PREPARSER ./calc input -./calc.at:1435: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -./calc.at:1438: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -528. calc.at:1437: ok -./calc.at:1438: cat stderr -./calc.at:1435: cat stderr - | 1 + 2 * 3 + !- ++ -./calc.at:1441: $PREPARSER ./calc input -./calc.at:1445: $PREPARSER ./calc /dev/null +./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -142946,17 +144129,422 @@ Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +stderr: +stderr: +stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token end of input () -syntax error, unexpected end of input -Cleanup: discarding lookahead token end of input () +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.1-2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.1-2: ) +Stack now 0 4 +Shifting token error (1.1-2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Error: popping token error (1.1-2: ) +Stack now 0 4 +Shifting token error (1.1-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token number (1.6: 1) +Error: discarding token number (1.6: 1) +Error: popping token error (1.1-4: ) +Stack now 0 4 +Shifting token error (1.1-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.1-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +Starting parse +Entering state 0 Stack now 0 -stderr: -input: -stderr: +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token ')' () +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Stack now 0 4 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 8 20 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Stack now 0 8 20 4 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Stack now 0 8 20 4 12 20 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 8 20 4 12 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 +Stack now 0 8 20 4 12 20 29 +Reading a token +Next token is token '+' () +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 +Stack now 0 8 20 4 12 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Stack now 0 8 20 4 12 20 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 8 20 4 12 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 +Stack now 0 8 20 4 12 20 29 +Reading a token +Next token is token '+' () +Reducing stack by rule 7 (line 90): + $1 = nterm exp (2) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (3) +Entering state 12 +Stack now 0 8 20 4 12 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Stack now 0 8 20 4 12 20 +Reading a token +Next token is token ')' () +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' () +Stack now 0 8 20 4 12 +Error: popping nterm exp (3) +Stack now 0 8 20 4 +Shifting token error () +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '+' () +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Stack now 0 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' () +Error: discarding token '*' () +Error: popping token error () +Stack now 0 8 20 4 +Shifting token error () +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token '*' () +Error: discarding token '*' () +Error: popping token error () +Stack now 0 8 20 4 +Shifting token error () +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token '*' () +Error: discarding token '*' () +Error: popping token error () +Stack now 0 8 20 4 +Shifting token error () +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '+' () +Reducing stack by rule 7 (line 90): + $1 = nterm exp (2222) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (3333) +Entering state 8 +Stack now 0 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 8 20 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Stack now 0 8 20 4 12 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Stack now 0 8 20 4 12 21 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Stack now 0 8 20 4 12 21 1 +Reducing stack by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 30 +Stack now 0 8 20 4 12 21 30 +Reading a token +Next token is token '*' () +Reducing stack by rule 9 (line 92): + $1 = nterm exp (1) + $2 = token '*' () + $3 = nterm exp (2) +-> $$ = nterm exp (2) +Entering state 12 +Stack now 0 8 20 4 12 +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Stack now 0 8 20 4 12 21 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' () +Stack now 0 8 20 4 12 +Error: popping nterm exp (2) +Stack now 0 8 20 4 +Shifting token error () +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' () +Error: discarding token '*' () +Error: popping token error () +Stack now 0 8 20 4 +Shifting token error () +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '=' () +Reducing stack by rule 7 (line 90): + $1 = nterm exp (3333) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (4444) +Entering state 8 +Stack now 0 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' () +Reducing stack by rule 6 (line 80): + $1 = nterm exp (4444) + $2 = token '=' () + $3 = nterm exp (1) +error: 4444 != 1 +-> $$ = nterm exp (4444) +Entering state 8 +Stack now 0 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (4444) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input () +Shifting token end of input () +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input () +Cleanup: popping nterm input () Starting parse Entering state 0 Stack now 0 @@ -143037,8 +144625,6 @@ Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) - | 1 + 2 * 3 + !+ ++ -./calc.at:1435: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -143154,16 +144740,51 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -stderr: -./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (#) + (#) = 2222 -./calc.at:1438: $PREPARSER ./calc input -stderr: -stderr: +./calc.at:1441: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1438: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1440: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1441: cat stderr stderr: +./calc.at:1445: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1438: cat stderr stdout: +./calc.at:1440: cat stderr ./calc.at:1443: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" @@ -143175,7 +144796,148 @@ || /\t/ )' calc.cc calc.hh -./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1445: cat stderr +input: +input: + | (#) + (#) = 2222 + | (1 + # + 1) = 1111 +./calc.at:1438: $PREPARSER ./calc input +./calc.at:1441: $PREPARSER ./calc input +input: +input: +stderr: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1443: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Stack now 0 4 12 20 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-8: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token number (1.10: 1) +Error: discarding token number (1.10: 1) +Error: popping token error (1.2-8: ) +Stack now 0 4 +Shifting token error (1.2-10: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.15-18: 1111) +Shifting token number (1.15-18: 1111) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' (1.19-2.0: ) +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: +./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: Starting parse Entering state 0 Stack now 0 @@ -143299,116 +145061,12 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -input: -./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1443: $PREPARSER ./calc input -./calc.at:1440: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1435: $EGREP -c -v 'Return for a new token:|LAC:' stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 20 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 -Stack now 0 8 20 29 21 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 20 29 21 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 -Stack now 0 8 20 29 21 30 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Stack now 0 8 20 29 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 20 5 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Stack now 0 8 20 5 13 -Reducing stack by rule 18 (line 109): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Stack now 0 8 20 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) + | (1 + 1) / (1 - 1) +./calc.at:1440: $PREPARSER ./calc input +./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: + | (!!) + (1 2) = 1 +./calc.at:1445: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -144426,18 +146084,407 @@ Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) +stderr: +stderr: +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Stack now 0 4 12 20 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +Shifting token error (1.2-8: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token number (1.10: 1) +Error: discarding token number (1.10: 1) +Error: popping token error (1.2-8: ) +Stack now 0 4 +Shifting token error (1.2-10: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.15-18: 1111) +Shifting token number (1.15-18: 1111) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' (1.19-2.0: ) +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Stack now 0 4 5 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 15 +Stack now 0 4 5 15 +Reducing stack by rule 16 (line 107): + $1 = token '!' () + $2 = token '!' () +Stack now 0 4 +Shifting token error () +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 8 20 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Stack now 0 8 20 4 12 +Reading a token +Next token is token number (2) +syntax error, unexpected number +Error: popping nterm exp (1) +Stack now 0 8 20 4 +Shifting token error () +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token number (2) +Error: discarding token number (2) +Error: popping token error () +Stack now 0 8 20 4 +Shifting token error () +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '=' () +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' () +Reducing stack by rule 6 (line 80): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (1) +error: 2222 != 1 +-> $$ = nterm exp (2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input () +Shifting token end of input () +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input () +Cleanup: popping nterm input () +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Stack now 0 4 12 20 +Reading a token +Next token is token number (1.6: 1) +Shifting token number (1.6: 1) +Entering state 1 +Stack now 0 4 12 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 29 +Stack now 0 4 12 20 29 +Reading a token +Next token is token ')' (1.7: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Stack now 0 4 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Stack now 0 4 12 26 +Reducing stack by rule 13 (line 104): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 22 +Stack now 0 8 22 +Reading a token +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Stack now 0 8 22 4 +Reading a token +Next token is token number (1.12: 1) +Shifting token number (1.12: 1) +Entering state 1 +Stack now 0 8 22 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Stack now 0 8 22 4 12 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 19 +Stack now 0 8 22 4 12 19 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Stack now 0 8 22 4 12 19 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 +Stack now 0 8 22 4 12 19 28 +Reading a token +Next token is token ')' (1.17: ) +Reducing stack by rule 8 (line 91): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Stack now 0 8 22 4 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Stack now 0 8 22 4 12 26 +Reducing stack by rule 13 (line 104): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 31 +Stack now 0 8 22 31 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 10 (line 93): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1441: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - +./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 @@ -144562,18 +146609,160 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1438: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token end of input () -syntax error, unexpected end of input -Cleanup: discarding lookahead token end of input () -Stack now 0 -./calc.at:1440: cat stderr -stderr: -./calc.at:1441: cat stderr -input: +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Stack now 0 4 12 20 +Reading a token +Next token is token number (1.6: 1) +Shifting token number (1.6: 1) +Entering state 1 +Stack now 0 4 12 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 29 +Stack now 0 4 12 20 29 +Reading a token +Next token is token ')' (1.7: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Stack now 0 4 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Stack now 0 4 12 26 +Reducing stack by rule 13 (line 104): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 22 +Stack now 0 8 22 +Reading a token +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Stack now 0 8 22 4 +Reading a token +Next token is token number (1.12: 1) +Shifting token number (1.12: 1) +Entering state 1 +Stack now 0 8 22 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Stack now 0 8 22 4 12 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 19 +Stack now 0 8 22 4 12 19 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Stack now 0 8 22 4 12 19 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 +Stack now 0 8 22 4 12 19 28 +Reading a token +Next token is token ')' (1.17: ) +Reducing stack by rule 8 (line 91): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Stack now 0 8 22 4 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Stack now 0 8 22 4 12 26 +Reducing stack by rule 13 (line 104): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 31 +Stack now 0 8 22 31 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 10 (line 93): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 @@ -145592,328 +147781,184 @@ Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1443: $EGREP -c -v 'Return for a new token:|LAC:' stderr - | 1 + 2 * 3 + !- ++ -./calc.at:1435: $PREPARSER ./calc input -./calc.at:1438: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -539. calc.at:1454: testing Calculator C++ %locations parse.lac=full parse.error=detailed ... -./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1438: cat stderr - | (1 + 1) / (1 - 1) -stderr: -./calc.at:1440: $PREPARSER ./calc input -input: -input: -input: - | (#) + (#) = 2222 -./calc.at:1441: $PREPARSER ./calc input - | 1 2 -./calc.at:1443: $PREPARSER ./calc input stderr: -./calc.at:1445: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (1 + #) = 1111 -./calc.at:1454: mv calc.y.tmp calc.y - -./calc.at:1435: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1438: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) +Next token is token '(' () +Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Stack now 0 4 12 20 -Reading a token -Next token is token number (1.6: 1) -Shifting token number (1.6: 1) -Entering state 1 -Stack now 0 4 12 20 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 29 -Stack now 0 4 12 20 29 -Reading a token -Next token is token ')' (1.7: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Stack now 0 4 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Stack now 0 4 12 26 -Reducing stack by rule 13 (line 104): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 22 -Stack now 0 8 22 -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Stack now 0 8 22 4 -Reading a token -Next token is token number (1.12: 1) -Shifting token number (1.12: 1) -Entering state 1 -Stack now 0 8 22 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Stack now 0 8 22 4 12 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 19 -Stack now 0 8 22 4 12 19 -Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) -Entering state 1 -Stack now 0 8 22 4 12 19 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 28 -Stack now 0 8 22 4 12 19 28 -Reading a token -Next token is token ')' (1.17: ) -Reducing stack by rule 8 (line 91): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Stack now 0 8 22 4 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Stack now 0 8 22 4 12 26 -Reducing stack by rule 13 (line 104): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 31 -Stack now 0 8 22 31 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 10 (line 93): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1440: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Stack now 0 4 5 Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.1-2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.1-2: ) +Next token is token '!' () +Shifting token '!' () +Entering state 15 +Stack now 0 4 5 15 +Reducing stack by rule 16 (line 107): + $1 = token '!' () + $2 = token '!' () Stack now 0 4 -Shifting token error (1.1-2: ) +Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) +Next token is token ')' () +Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.1-2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) +Next token is token '+' () +Shifting token '+' () Entering state 20 Stack now 0 8 20 Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) +Next token is token '(' () +Shifting token '(' () Entering state 4 Stack now 0 8 20 4 Reading a token -1.8: syntax error: invalid character: '#' -Next token is token error (1.8: ) -Shifting token error (1.1-8: ) +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 8 20 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Stack now 0 8 20 4 12 +Reading a token +Next token is token number (2) +syntax error, unexpected number +Error: popping nterm exp (1) +Stack now 0 8 20 4 +Shifting token error () Entering state 11 Stack now 0 8 20 4 11 -Next token is token invalid token (1.8: ) -Error: discarding token invalid token (1.8: ) -Error: popping token error (1.1-8: ) +Next token is token number (2) +Error: discarding token number (2) +Error: popping token error () Stack now 0 8 20 4 -Shifting token error (1.1-8: ) +Shifting token error () Entering state 11 Stack now 0 8 20 4 11 Reading a token -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) +Next token is token ')' () +Shifting token ')' () Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): - $1 = token '(' (1.7: ) - $2 = token error (1.1-8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 29 Stack now 0 8 20 29 Reading a token -Next token is token '=' (1.11: ) +Next token is token '=' () Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) +Next token is token '=' () +Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token -Next token is token number (1.13-16: 2222) -Shifting token number (1.13-16: 2222) +Next token is token number (1) +Shifting token number (1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 27 Stack now 0 8 18 27 Reading a token -Next token is token '\n' (1.17-2.0: ) +Next token is token '\n' () Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (1) +error: 2222 != 1 +-> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' () +Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) + $1 = nterm line () +-> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) +Next token is token end of input () +Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1454: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +Cleanup: popping token end of input () +Cleanup: popping nterm input () +./calc.at:1441: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1438: cat stderr +input: +./calc.at:1441: cat stderr + | 1 2 +./calc.at:1443: $PREPARSER ./calc input +./calc.at:1440: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: +./calc.at:1445: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: Starting parse Entering state 0 Stack now 0 @@ -145934,6 +147979,15 @@ Stack now 0 Cleanup: discarding lookahead token number (1.3: 2) Stack now 0 +./calc.at:1440: cat stderr +input: + | (1 + #) = 1111 + | (1 + 1) / (1 - 1) +./calc.at:1441: $PREPARSER ./calc input +./calc.at:1438: $PREPARSER ./calc input +stderr: +./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: Starting parse Entering state 0 Stack now 0 @@ -146033,12 +148087,10 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1435: cat stderr -stderr: -stderr: +./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1445: cat stderr +530. calc.at:1440: ok +stderr: Starting parse Entering state 0 Stack now 0 @@ -146180,130 +148232,27 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: +./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.1-2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.1-2: ) -Stack now 0 4 -Shifting token error (1.1-2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.1-2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -1.8: syntax error: invalid character: '#' -Next token is token error (1.8: ) -Shifting token error (1.1-8: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token invalid token (1.8: ) -Error: discarding token invalid token (1.8: ) -Error: popping token error (1.1-8: ) -Stack now 0 8 20 4 -Shifting token error (1.1-8: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.7: ) - $2 = token error (1.1-8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.13-16: 2222) -Shifting token number (1.13-16: 2222) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 8 18 1 +Stack now 0 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token number (1.3: 2) +Stack now 0 stderr: Starting parse Entering state 0 @@ -146404,39 +148353,150 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +stderr: +input: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 -Stack now 0 1 +Stack now 0 4 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Stack now 0 4 12 20 +Reading a token +Next token is token number (1.6: 1) +Shifting token number (1.6: 1) +Entering state 1 +Stack now 0 4 12 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 29 +Stack now 0 4 12 20 29 +Reading a token +Next token is token ')' (1.7: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Stack now 0 4 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Stack now 0 4 12 26 +Reducing stack by rule 13 (line 104): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) Entering state 8 Stack now 0 8 Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token number (1.3: 2) -Stack now 0 -input: -./calc.at:1440: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1441: "$PERL" -pi -e 'use strict; +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 22 +Stack now 0 8 22 +Reading a token +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Stack now 0 8 22 4 +Reading a token +Next token is token number (1.12: 1) +Shifting token number (1.12: 1) +Entering state 1 +Stack now 0 8 22 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Stack now 0 8 22 4 12 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 19 +Stack now 0 8 22 4 12 19 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Stack now 0 8 22 4 12 19 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 +Stack now 0 8 22 4 12 19 28 +Reading a token +Next token is token ')' (1.17: ) +Reducing stack by rule 8 (line 91): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Stack now 0 8 22 4 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Stack now 0 8 22 4 12 26 +Reducing stack by rule 13 (line 104): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 31 +Stack now 0 8 22 31 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 10 (line 93): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -146446,8 +148506,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + | (- *) + (1 2) = 1 +./calc.at:1443: cat stderr ./calc.at:1445: $PREPARSER ./calc input -./calc.at:1443: "$PERL" -pi -e 'use strict; +./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -146457,10 +148519,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1454: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS + stderr: -./calc.at:1440: cat stderr -./calc.at:1441: cat stderr Starting parse Entering state 0 Stack now 0 @@ -146470,182 +148530,43 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token ')' () -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 8 20 4 12 20 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 8 20 4 12 20 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 -Stack now 0 8 20 4 12 20 29 -Reading a token -Next token is token '+' () -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 -Stack now 0 8 20 4 12 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 8 20 4 12 20 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 8 20 4 12 20 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 -Stack now 0 8 20 4 12 20 29 -Reading a token -Next token is token '+' () -Reducing stack by rule 7 (line 90): - $1 = nterm exp (2) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (3) -Entering state 12 -Stack now 0 8 20 4 12 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 8 20 4 12 20 -Reading a token -Next token is token ')' () -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' () -Stack now 0 8 20 4 12 -Error: popping nterm exp (3) -Stack now 0 8 20 4 -Shifting token error () -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '+' () -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Stack now 0 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Stack now 0 8 20 4 +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Stack now 0 4 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token '*' () -Error: discarding token '*' () -Error: popping token error () -Stack now 0 8 20 4 -Shifting token error () -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token '*' () -Error: discarding token '*' () -Error: popping token error () -Stack now 0 8 20 4 +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 106): + $1 = token '-' () + $2 = token error () +Stack now 0 4 Shifting token error () Entering state 11 -Stack now 0 8 20 4 11 -Reading a token +Stack now 0 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () -Stack now 0 8 20 4 +Stack now 0 4 Shifting token error () Entering state 11 -Stack now 0 8 20 4 11 +Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 -Stack now 0 8 20 4 11 25 +Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '+' () -Reducing stack by rule 7 (line 90): - $1 = nterm exp (2222) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (3333) Entering state 8 Stack now 0 8 +Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 @@ -146666,45 +148587,15 @@ Entering state 12 Stack now 0 8 20 4 12 Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Stack now 0 8 20 4 12 21 -Reading a token Next token is token number (2) -Shifting token number (2) -Entering state 1 -Stack now 0 8 20 4 12 21 1 -Reducing stack by rule 5 (line 79): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 30 -Stack now 0 8 20 4 12 21 30 -Reading a token -Next token is token '*' () -Reducing stack by rule 9 (line 92): - $1 = nterm exp (1) - $2 = token '*' () - $3 = nterm exp (2) --> $$ = nterm exp (2) -Entering state 12 -Stack now 0 8 20 4 12 -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Stack now 0 8 20 4 12 21 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' () -Stack now 0 8 20 4 12 -Error: popping nterm exp (2) +syntax error, unexpected number +Error: popping nterm exp (1) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token number (2) +Error: discarding token number (2) Error: popping token error () Stack now 0 8 20 4 Shifting token error () @@ -146725,10 +148616,10 @@ Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): - $1 = nterm exp (3333) + $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) --> $$ = nterm exp (4444) +-> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '=' () @@ -146748,11 +148639,11 @@ Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): - $1 = nterm exp (4444) + $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) -error: 4444 != 1 --> $$ = nterm exp (4444) +error: 2222 != 1 +-> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '\n' () @@ -146760,7 +148651,7 @@ Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (4444) + $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -146778,7 +148669,6 @@ Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () -input: ./calc.at:1438: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -146789,127 +148679,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (#) + (#) = 2222 -./calc.at:1435: $PREPARSER ./calc input -./calc.at:1443: cat stderr -stderr: -./calc.at:1438: cat stderr -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' input: -./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1441: cat stderr ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -530. calc.at:1440: ok - | (1 + #) = 1111 -./calc.at:1441: $PREPARSER ./calc input -stderr: -stderr: | 1//2 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Stack now 0 4 12 20 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1443: $PREPARSER ./calc input -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -input: +./calc.at:1438: cat stderr stderr: stderr: Starting parse @@ -146939,7 +148714,7 @@ Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 - | (# + 1) = 1111 +input: Starting parse Entering state 0 Stack now 0 @@ -146949,182 +148724,43 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token ')' () -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 8 20 4 12 20 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 8 20 4 12 20 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 -Stack now 0 8 20 4 12 20 29 -Reading a token -Next token is token '+' () -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 -Stack now 0 8 20 4 12 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 8 20 4 12 20 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 8 20 4 12 20 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 -Stack now 0 8 20 4 12 20 29 -Reading a token -Next token is token '+' () -Reducing stack by rule 7 (line 90): - $1 = nterm exp (2) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (3) -Entering state 12 -Stack now 0 8 20 4 12 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 8 20 4 12 20 -Reading a token -Next token is token ')' () -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' () -Stack now 0 8 20 4 12 -Error: popping nterm exp (3) -Stack now 0 8 20 4 -Shifting token error () -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '+' () -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Stack now 0 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Stack now 0 8 20 4 +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Stack now 0 4 2 Reading a token Next token is token '*' () syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token '*' () -Error: discarding token '*' () -Error: popping token error () -Stack now 0 8 20 4 -Shifting token error () -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token '*' () -Error: discarding token '*' () -Error: popping token error () -Stack now 0 8 20 4 +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 106): + $1 = token '-' () + $2 = token error () +Stack now 0 4 Shifting token error () Entering state 11 -Stack now 0 8 20 4 11 -Reading a token +Stack now 0 4 11 Next token is token '*' () Error: discarding token '*' () Error: popping token error () -Stack now 0 8 20 4 +Stack now 0 4 Shifting token error () Entering state 11 -Stack now 0 8 20 4 11 +Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 -Stack now 0 8 20 4 11 25 +Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '+' () -Reducing stack by rule 7 (line 90): - $1 = nterm exp (2222) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (3333) Entering state 8 Stack now 0 8 +Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 @@ -147145,45 +148781,15 @@ Entering state 12 Stack now 0 8 20 4 12 Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Stack now 0 8 20 4 12 21 -Reading a token Next token is token number (2) -Shifting token number (2) -Entering state 1 -Stack now 0 8 20 4 12 21 1 -Reducing stack by rule 5 (line 79): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 30 -Stack now 0 8 20 4 12 21 30 -Reading a token -Next token is token '*' () -Reducing stack by rule 9 (line 92): - $1 = nterm exp (1) - $2 = token '*' () - $3 = nterm exp (2) --> $$ = nterm exp (2) -Entering state 12 -Stack now 0 8 20 4 12 -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Stack now 0 8 20 4 12 21 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' () -Stack now 0 8 20 4 12 -Error: popping nterm exp (2) +syntax error, unexpected number +Error: popping nterm exp (1) Stack now 0 8 20 4 Shifting token error () Entering state 11 Stack now 0 8 20 4 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token number (2) +Error: discarding token number (2) Error: popping token error () Stack now 0 8 20 4 Shifting token error () @@ -147204,10 +148810,10 @@ Reading a token Next token is token '=' () Reducing stack by rule 7 (line 90): - $1 = nterm exp (3333) + $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) --> $$ = nterm exp (4444) +-> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '=' () @@ -147227,11 +148833,11 @@ Reading a token Next token is token '\n' () Reducing stack by rule 6 (line 80): - $1 = nterm exp (4444) + $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) -error: 4444 != 1 --> $$ = nterm exp (4444) +error: 2222 != 1 +-> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '\n' () @@ -147239,7 +148845,7 @@ Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (4444) + $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -147257,7 +148863,15 @@ Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () -./calc.at:1438: $PREPARSER ./calc input +529. calc.at:1438: ok +541. calc.at:1457: testing Calculator C++ parse.error=custom ... + | (# + 1) = 1111 +./calc.at:1441: $PREPARSER ./calc input +./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1457: mv calc.y.tmp calc.y + +./calc.at:1457: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +stderr: stderr: Starting parse Entering state 0 @@ -147268,35 +148882,32 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.1-2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.1-2: ) +Stack now 0 4 +Shifting token error (1.1-2: ) +Entering state 11 +Stack now 0 4 11 Reading a token Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Stack now 0 4 12 20 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) +Error: discarding token '+' (1.4: ) +Error: popping token error (1.1-2: ) Stack now 0 4 -Shifting token error (1.2-6: ) +Shifting token error (1.1-4: ) Entering state 11 Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) +Reading a token +Next token is token number (1.6: 1) +Error: discarding token number (1.6: 1) +Error: popping token error (1.1-4: ) Stack now 0 4 -Shifting token error (1.2-6: ) +Shifting token error (1.1-6: ) Entering state 11 Stack now 0 4 11 Reading a token @@ -147306,7 +148917,7 @@ Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) + $2 = token error (1.1-6: ) $3 = token ')' (1.7: ) -> $$ = nterm exp (1.1-7: 1111) Entering state 8 @@ -147358,9 +148969,7 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: +./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -147388,18 +148997,7 @@ Stack now 0 Cleanup: discarding lookahead token '/' (1.3: ) Stack now 0 - -./calc.at:1435: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1441: "$PERL" -pi -e 'use strict; +./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -147409,6 +149007,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + +stderr: Starting parse Entering state 0 Stack now 0 @@ -147505,20 +149105,7 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1445: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1435: cat stderr -stderr: -./calc.at:1441: cat stderr +./calc.at:1445: cat stderr ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -147529,122 +149116,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.1-2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.1-2: ) -Stack now 0 4 -Shifting token error (1.1-2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Error: popping token error (1.1-2: ) -Stack now 0 4 -Shifting token error (1.1-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1.6: 1) -Error: discarding token number (1.6: 1) -Error: popping token error (1.1-4: ) -Stack now 0 4 -Shifting token error (1.1-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.1-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1443: cat stderr -./calc.at:1445: cat stderr -input: - | error -./calc.at:1443: $PREPARSER ./calc input -540. calc.at:1455: testing Calculator C++ %locations parse.lac=full parse.error=detailed parse.trace ... -./calc.at:1455: mv calc.y.tmp calc.y - -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -Stack now 0 -./calc.at:1455: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -input: -./calc.at:1438: "$PERL" -pi -e 'use strict; +./calc.at:1457: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -147654,167 +149127,99 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (1 + #) = 1111 -./calc.at:1435: $PREPARSER ./calc input -stderr: -input: -1.6: syntax error: invalid character: '#' -./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -./calc.at:1438: cat stderr - | (# + 1) = 1111 -./calc.at:1441: $PREPARSER ./calc input - | (!!) + (1 2) = 1 -stderr: + | (* *) + (*) + (*) ./calc.at:1445: $PREPARSER ./calc input stderr: +./calc.at:1441: cat stderr +542. calc.at:1458: testing Calculator C++ parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} ... +./calc.at:1458: mv calc.y.tmp calc.y + Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -Stack now 0 -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) +Next token is token '(' () +Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.1-2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.1-2: ) -Stack now 0 4 -Shifting token error (1.1-2: ) +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () Entering state 11 Stack now 0 4 11 -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Error: popping token error (1.1-2: ) +Next token is token '*' () +Error: discarding token '*' () +Error: popping token error () Stack now 0 4 -Shifting token error (1.1-4: ) +Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token -Next token is token number (1.6: 1) -Error: discarding token number (1.6: 1) -Error: popping token error (1.1-4: ) +Next token is token '*' () +Error: discarding token '*' () +Error: popping token error () Stack now 0 4 -Shifting token error (1.1-6: ) +Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' () +Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.1-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.6: syntax error: invalid character: '#' -stderr: -Starting parse -Entering state 0 -Stack now 0 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Stack now 0 4 5 +Stack now 0 8 20 4 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 15 -Stack now 0 4 5 15 -Reducing stack by rule 16 (line 107): - $1 = token '!' () - $2 = token '!' () -Stack now 0 4 +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 -Stack now 0 4 11 +Stack now 0 8 20 4 11 +Next token is token '*' () +Error: discarding token '*' () +Error: popping token error () +Stack now 0 8 20 4 +Shifting token error () +Entering state 11 +Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 -Stack now 0 4 11 25 +Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '+' () +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 -Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 @@ -147825,25 +149230,13 @@ Entering state 4 Stack now 0 8 20 4 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token number (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Stack now 0 8 20 4 +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 8 20 4 11 -Next token is token number (2) -Error: discarding token number (2) +Next token is token '*' () +Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () @@ -147862,36 +149255,12 @@ Entering state 29 Stack now 0 8 20 29 Reading a token -Next token is token '=' () +Next token is token '\n' () Reducing stack by rule 7 (line 90): - $1 = nterm exp (1111) + $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' () -Reducing stack by rule 6 (line 80): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) +-> $$ = nterm exp (3333) Entering state 8 Stack now 0 8 Next token is token '\n' () @@ -147899,7 +149268,7 @@ Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (2222) + $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -147917,155 +149286,101 @@ Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () -./calc.at:1435: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1443: cat stderr +./calc.at:1458: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +input: + | error +./calc.at:1443: $PREPARSER ./calc input stderr: +stderr: + | (1 + # + 1) = 1111 Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) +Next token is token '(' () +Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.1-2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.1-2: ) -Stack now 0 4 -Shifting token error (1.1-2: ) +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () Entering state 11 Stack now 0 4 11 -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Error: popping token error (1.1-2: ) +Next token is token '*' () +Error: discarding token '*' () +Error: popping token error () Stack now 0 4 -Shifting token error (1.1-4: ) +Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token -Next token is token number (1.6: 1) -Error: discarding token number (1.6: 1) -Error: popping token error (1.1-4: ) +Next token is token '*' () +Error: discarding token '*' () +Error: popping token error () Stack now 0 4 -Shifting token error (1.1-6: ) +Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' () +Shifting token ')' () Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.1-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1435: cat stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Stack now 0 8 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Stack now 0 4 5 +Stack now 0 8 20 4 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 15 -Stack now 0 4 5 15 -Reducing stack by rule 16 (line 107): - $1 = token '!' () - $2 = token '!' () -Stack now 0 4 +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 -Stack now 0 4 11 +Stack now 0 8 20 4 11 +Next token is token '*' () +Error: discarding token '*' () +Error: popping token error () +Stack now 0 8 20 4 +Shifting token error () +Entering state 11 +Stack now 0 8 20 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 -Stack now 0 4 11 25 +Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '+' () +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 -Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 @@ -148076,25 +149391,13 @@ Entering state 4 Stack now 0 8 20 4 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token number (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Stack now 0 8 20 4 +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Stack now 0 8 20 4 11 -Next token is token number (2) -Error: discarding token number (2) +Next token is token '*' () +Error: discarding token '*' () Error: popping token error () Stack now 0 8 20 4 Shifting token error () @@ -148113,36 +149416,12 @@ Entering state 29 Stack now 0 8 20 29 Reading a token -Next token is token '=' () +Next token is token '\n' () Reducing stack by rule 7 (line 90): - $1 = nterm exp (1111) + $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' () -Reducing stack by rule 6 (line 80): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) +-> $$ = nterm exp (3333) Entering state 8 Stack now 0 8 Next token is token '\n' () @@ -148150,7 +149429,7 @@ Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (2222) + $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -148168,20 +149447,16 @@ Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () - | (1 + # + 1) = 1111 -./calc.at:1455: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -./calc.at:1438: $PREPARSER ./calc input +./calc.at:1441: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) +Stack now 0 stderr: -./calc.at:1441: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 Starting parse Entering state 0 Stack now 0 @@ -148297,21 +149572,9 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1441: cat stderr -input: -./calc.at:1443: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - | (# + 1) = 1111 ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -148322,7 +149585,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1435: $PREPARSER ./calc input +stderr: +./calc.at:1458: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS Starting parse Entering state 0 Stack now 0 @@ -148438,12 +149702,26 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: -./calc.at:1443: cat stderr -input: - | (1 + # + 1) = 1111 -./calc.at:1441: $PREPARSER ./calc input -./calc.at:1438: "$PERL" -pi -e 'use strict; +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) +Stack now 0 +./calc.at:1445: cat stderr +./calc.at:1443: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -148453,249 +149731,181 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1443: cat stderr +input: + | 1 + 2 * 3 + !+ ++ +./calc.at:1441: cat stderr +./calc.at:1445: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) +Next token is token number (1) +Shifting token number (1) Entering state 1 -Stack now 0 4 1 +Stack now 0 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Stack now 0 8 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' () +Shifting token '+' () Entering state 20 -Stack now 0 4 12 20 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-8: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1.10: 1) -Error: discarding token number (1.10: 1) -Error: popping token error (1.2-8: ) -Stack now 0 4 -Shifting token error (1.2-10: ) -Entering state 11 -Stack now 0 4 11 +Stack now 0 8 20 Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) -Entering state 8 -Stack now 0 8 +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Stack now 0 8 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 +Stack now 0 8 20 29 Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) -Entering state 18 -Stack now 0 8 18 +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Stack now 0 8 20 29 21 Reading a token -Next token is token number (1.15-18: 1111) -Shifting token number (1.15-18: 1111) +Next token is token number (3) +Shifting token number (3) Entering state 1 -Stack now 0 8 18 1 +Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) -Entering state 27 -Stack now 0 8 18 27 + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 30 +Stack now 0 8 20 29 21 30 Reading a token -Next token is token '\n' (1.19-2.0: ) -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) +Next token is token '+' () +Reducing stack by rule 9 (line 92): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Stack now 0 8 20 29 +Next token is token '+' () +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Stack now 0 8 20 Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1445: cat stderr -./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.2: syntax error: invalid character: '#' -./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1438: cat stderr +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Stack now 0 8 20 5 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 14 +Stack now 0 8 20 5 14 +Reducing stack by rule 17 (line 108): + $1 = token '!' () + $2 = token '+' () +Stack now 0 8 20 +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) +input: +./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 = 2 = 3 +./calc.at:1443: $PREPARSER ./calc input +input: + | (1 + 1) / (1 - 1) +stderr: stderr: +./calc.at:1441: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) +Next token is token number (1) +Shifting token number (1) Entering state 1 -Stack now 0 4 1 +Stack now 0 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Stack now 0 8 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' () +Shifting token '+' () Entering state 20 -Stack now 0 4 12 20 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -Shifting token error (1.2-8: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1.10: 1) -Error: discarding token number (1.10: 1) -Error: popping token error (1.2-8: ) -Stack now 0 4 -Shifting token error (1.2-10: ) -Entering state 11 -Stack now 0 4 11 +Stack now 0 8 20 Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) -Entering state 8 -Stack now 0 8 +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Stack now 0 8 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 +Stack now 0 8 20 29 Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) -Entering state 18 -Stack now 0 8 18 +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Stack now 0 8 20 29 21 Reading a token -Next token is token number (1.15-18: 1111) -Shifting token number (1.15-18: 1111) +Next token is token number (3) +Shifting token number (3) Entering state 1 -Stack now 0 8 18 1 +Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) -Entering state 27 -Stack now 0 8 18 27 + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 30 +Stack now 0 8 20 29 21 30 Reading a token -Next token is token '\n' (1.19-2.0: ) -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) +Next token is token '+' () +Reducing stack by rule 9 (line 92): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Stack now 0 8 20 29 +Next token is token '+' () +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Stack now 0 8 20 Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -input: - | 1 = 2 = 3 -./calc.at:1443: $PREPARSER ./calc input -input: - | (1 + 1) / (1 - 1) -stderr: +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Stack now 0 8 20 5 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 14 +Stack now 0 8 20 5 14 +Reducing stack by rule 17 (line 108): + $1 = token '!' () + $2 = token '+' () +Stack now 0 8 20 +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) Starting parse Entering state 0 Stack now 0 @@ -148735,10 +149945,8 @@ Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 -./calc.at:1438: $PREPARSER ./calc input -stderr: -1.2: syntax error: invalid character: '#' stderr: +./calc.at:1445: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 @@ -148880,8 +150088,12 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: stderr: + | 1 + 2 * 3 + !- ++ +./calc.at:1445: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -149023,77 +150235,19 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1438: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1441: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (- *) + (1 2) = 1 -./calc.at:1438: cat stderr -./calc.at:1445: $PREPARSER ./calc input stderr: -./calc.at:1441: cat stderr -529. calc.at:1438: ok +stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Stack now 0 4 2 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 106): - $1 = token '-' () - $2 = token error () -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Next token is token '*' () -Error: discarding token '*' () -Error: popping token error () -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 8 Stack now 0 8 Reading a token @@ -149102,104 +150256,67 @@ Entering state 20 Stack now 0 8 20 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token number (2) +Shifting token number (2) Entering state 1 -Stack now 0 8 20 4 1 +Stack now 0 8 20 1 Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token number (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Stack now 0 8 20 4 -Shifting token error () -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token number (2) -Error: discarding token number (2) -Error: popping token error () -Stack now 0 8 20 4 -Shifting token error () -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) + $1 = token number (2) +-> $$ = nterm exp (2) Entering state 29 Stack now 0 8 20 29 Reading a token -Next token is token '=' () -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Stack now 0 8 18 +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Stack now 0 8 20 29 21 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token number (3) +Shifting token number (3) Entering state 1 -Stack now 0 8 18 1 +Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 27 -Stack now 0 8 18 27 + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 30 +Stack now 0 8 20 29 21 30 Reading a token -Next token is token '\n' () -Reducing stack by rule 6 (line 80): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) +Next token is token '+' () +Reducing stack by rule 9 (line 92): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Stack now 0 8 20 29 +Next token is token '+' () +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) Entering state 8 Stack now 0 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (2222) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Stack now 0 6 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Stack now 0 8 20 Reading a token -Next token is token end of input () -Shifting token end of input () -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -stderr: +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Stack now 0 8 20 5 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 13 +Stack now 0 8 20 5 13 +Reducing stack by rule 18 (line 109): + $1 = token '!' () + $2 = token '-' () +Stack now 0 8 20 +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) Starting parse Entering state 0 Stack now 0 @@ -149239,7 +150356,8 @@ Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 -./calc.at:1435: "$PERL" -pi -e 'use strict; +./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1441: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -149249,8 +150367,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -149261,487 +150377,94 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1435: cat stderr stderr: - | (1 + 1) / (1 - 1) +./calc.at:1441: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Stack now 0 4 +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Stack now 0 8 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Stack now 0 4 2 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Stack now 0 8 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 +Stack now 0 8 20 29 Reading a token Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 106): - $1 = token '-' () - $2 = token error () -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Next token is token '*' () -Error: discarding token '*' () -Error: popping token error () -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Stack now 0 8 20 4 +Shifting token '*' () +Entering state 21 +Stack now 0 8 20 29 21 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token number (3) +Shifting token number (3) Entering state 1 -Stack now 0 8 20 4 1 +Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token number (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Stack now 0 8 20 4 -Shifting token error () -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token number (2) -Error: discarding token number (2) -Error: popping token error () -Stack now 0 8 20 4 -Shifting token error () -Entering state 11 -Stack now 0 8 20 4 11 + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 30 +Stack now 0 8 20 29 21 30 Reading a token -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) +Next token is token '+' () +Reducing stack by rule 9 (line 92): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) Entering state 29 Stack now 0 8 20 29 -Reading a token -Next token is token '=' () +Next token is token '+' () Reducing stack by rule 7 (line 90): - $1 = nterm exp (1111) + $1 = nterm exp (1) $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' () -Reducing stack by rule 6 (line 80): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (2222) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of input () -Shifting token end of input () -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -./calc.at:1441: $PREPARSER ./calc input -stderr: -stderr: -./calc.at:1443: cat stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Stack now 0 4 12 20 -Reading a token -Next token is token number (1.6: 1) -Shifting token number (1.6: 1) -Entering state 1 -Stack now 0 4 12 20 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 29 -Stack now 0 4 12 20 29 -Reading a token -Next token is token ')' (1.7: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Stack now 0 4 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Stack now 0 4 12 26 -Reducing stack by rule 13 (line 104): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 22 -Stack now 0 8 22 -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Stack now 0 8 22 4 -Reading a token -Next token is token number (1.12: 1) -Shifting token number (1.12: 1) -Entering state 1 -Stack now 0 8 22 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Stack now 0 8 22 4 12 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 19 -Stack now 0 8 22 4 12 19 -Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) -Entering state 1 -Stack now 0 8 22 4 12 19 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 28 -Stack now 0 8 22 4 12 19 28 -Reading a token -Next token is token ')' (1.17: ) -Reducing stack by rule 8 (line 91): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Stack now 0 8 22 4 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Stack now 0 8 22 4 12 26 -Reducing stack by rule 13 (line 104): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 31 -Stack now 0 8 22 31 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 10 (line 93): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) + $3 = nterm exp (6) +-> $$ = nterm exp (7) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -input: - | (1 + # + 1) = 1111 -./calc.at:1435: $PREPARSER ./calc input -stdout: -./calc.at:1441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1453: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - - -1.6: syntax error: invalid character: '#' -./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: -1.6: syntax error: invalid character: '#' - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1453: $PREPARSER ./calc input -stderr: -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' () +Shifting token '+' () Entering state 20 -Stack now 0 4 12 20 -Reading a token -Next token is token number (1.6: 1) -Shifting token number (1.6: 1) -Entering state 1 -Stack now 0 4 12 20 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 29 -Stack now 0 4 12 20 29 -Reading a token -Next token is token ')' (1.7: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Stack now 0 4 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Stack now 0 4 12 26 -Reducing stack by rule 13 (line 104): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 22 -Stack now 0 8 22 -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Stack now 0 8 22 4 -Reading a token -Next token is token number (1.12: 1) -Shifting token number (1.12: 1) -Entering state 1 -Stack now 0 8 22 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Stack now 0 8 22 4 12 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 19 -Stack now 0 8 22 4 12 19 -Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) -Entering state 1 -Stack now 0 8 22 4 12 19 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 28 -Stack now 0 8 22 4 12 19 28 -Reading a token -Next token is token ')' (1.17: ) -Reducing stack by rule 8 (line 91): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Stack now 0 8 22 4 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Stack now 0 8 22 4 12 26 -Reducing stack by rule 13 (line 104): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 31 -Stack now 0 8 22 31 +Stack now 0 8 20 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 10 (line 93): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Stack now 0 8 20 5 Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +Next token is token '-' () +Shifting token '-' () +Entering state 13 +Stack now 0 8 20 5 13 +Reducing stack by rule 18 (line 109): + $1 = token '!' () + $2 = token '-' () +Stack now 0 8 20 +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) +./calc.at:1443: cat stderr +531. calc.at:1441: ok input: | | +1 ./calc.at:1443: $PREPARSER ./calc input -./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -149753,16 +150476,6 @@ }eg ' expout || exit 77 stderr: -./calc.at:1435: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 Starting parse Entering state 0 Stack now 0 @@ -149788,24 +150501,13 @@ Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 -stderr: -./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1445: cat stderr -./calc.at:1435: cat stderr + +./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1453: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1441: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 input: - | (1 + 1) / (1 - 1) + | (#) + (#) = 2222 +./calc.at:1445: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -149831,37 +150533,7 @@ Stack now 0 Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 -./calc.at:1435: $PREPARSER ./calc input -541. calc.at:1457: testing Calculator C++ parse.error=custom ... -./calc.at:1457: mv calc.y.tmp calc.y - -./calc.at:1457: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -./calc.at:1441: cat stderr -stderr: -input: -531. calc.at:1441: ok -1.11-17: error: null divisor -./calc.at:1435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (* *) + (*) + (*) -./calc.at:1445: $PREPARSER ./calc input -input: -./calc.at:1457: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS - | 1 2 -./calc.at:1443: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 stderr: -1.11-17: error: null divisor -./calc.at:1453: $PREPARSER ./calc input -stderr: -./calc.at:1443: cat stderr Starting parse Entering state 0 Stack now 0 @@ -149871,21 +150543,13 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Next token is token '*' () -Error: discarding token '*' () -Error: popping token error () -Stack now 0 4 +syntax error: invalid character: '#' +Next token is token error () Shifting token error () Entering state 11 Stack now 0 4 11 -Reading a token -Next token is token '*' () -Error: discarding token '*' () +Next token is token invalid token () +Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () @@ -149914,13 +150578,13 @@ Entering state 4 Stack now 0 8 20 4 Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error: invalid character: '#' +Next token is token error () Shifting token error () Entering state 11 Stack now 0 8 20 4 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token invalid token () +Error: discarding token invalid token () Error: popping token error () Stack now 0 8 20 4 Shifting token error () @@ -149939,7 +150603,7 @@ Entering state 29 Stack now 0 8 20 29 Reading a token -Next token is token '+' () +Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () @@ -149947,47 +150611,27 @@ -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token '*' () -Error: discarding token '*' () -Error: popping token error () -Stack now 0 8 20 4 -Shifting token error () -Entering state 11 -Stack now 0 8 20 4 11 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Stack now 0 8 18 Reading a token -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Stack now 0 8 20 29 +Next token is token number (2222) +Shifting token number (2222) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (2222) +-> $$ = nterm exp (2222) +Entering state 27 +Stack now 0 8 18 27 Reading a token Next token is token '\n' () -Reducing stack by rule 7 (line 90): +Reducing stack by rule 6 (line 80): $1 = nterm exp (2222) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (3333) + $2 = token '=' () + $3 = nterm exp (2222) +-> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 Next token is token '\n' () @@ -149995,7 +150639,7 @@ Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (3333) + $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -150013,31 +150657,8 @@ Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () -./calc.at:1443: $PREPARSER ./calc /dev/null -stderr: -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token end of input (1.1: ) -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token end of input (1.1: ) -Stack now 0 ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token end of input (1.1: ) -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token end of input (1.1: ) -Stack now 0 -1.3: syntax error, unexpected number -./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1435: "$PERL" -pi -e 'use strict; +./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -150047,22 +150668,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +543. calc.at:1459: testing Calculator C++ parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} parse.lac=full ... +./calc.at:1459: mv calc.y.tmp calc.y +./calc.at:1459: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: -./calc.at:1435: cat stderr -stderr: -./calc.at:1443: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 ./calc.at:1443: cat stderr -1.3: syntax error, unexpected number Starting parse Entering state 0 Stack now 0 @@ -150072,21 +150683,13 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Next token is token '*' () -Error: discarding token '*' () -Error: popping token error () -Stack now 0 4 +syntax error: invalid character: '#' +Next token is token error () Shifting token error () Entering state 11 Stack now 0 4 11 -Reading a token -Next token is token '*' () -Error: discarding token '*' () +Next token is token invalid token () +Error: discarding token invalid token () Error: popping token error () Stack now 0 4 Shifting token error () @@ -150115,13 +150718,13 @@ Entering state 4 Stack now 0 8 20 4 Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error: invalid character: '#' +Next token is token error () Shifting token error () Entering state 11 Stack now 0 8 20 4 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token invalid token () +Error: discarding token invalid token () Error: popping token error () Stack now 0 8 20 4 Shifting token error () @@ -150140,7 +150743,7 @@ Entering state 29 Stack now 0 8 20 29 Reading a token -Next token is token '+' () +Next token is token '=' () Reducing stack by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () @@ -150148,47 +150751,173 @@ -> $$ = nterm exp (2222) Entering state 8 Stack now 0 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 8 20 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (2222) +Shifting token number (2222) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (2222) +-> $$ = nterm exp (2222) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' () +Reducing stack by rule 6 (line 80): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (2222) +-> $$ = nterm exp (2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input () +Shifting token end of input () +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input () +Cleanup: popping nterm input () +./calc.at:1443: $PREPARSER ./calc /dev/null +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token end of input (1.1: ) +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token end of input (1.1: ) +Stack now 0 +./calc.at:1445: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1459: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +./calc.at:1445: cat stderr +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token end of input (1.1: ) +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token end of input (1.1: ) +Stack now 0 +./calc.at:1443: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: + | (1 + #) = 1111 +./calc.at:1445: $PREPARSER ./calc input +./calc.at:1443: cat stderr +stderr: +Starting parse +Entering state 0 +Stack now 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 -Stack now 0 8 20 4 +Stack now 0 4 Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Stack now 0 4 12 20 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Stack now 0 4 12 +Error: popping nterm exp (1) +Stack now 0 4 Shifting token error () Entering state 11 -Stack now 0 8 20 4 11 -Next token is token '*' () -Error: discarding token '*' () +Stack now 0 4 11 +Next token is token invalid token () +Error: discarding token invalid token () Error: popping token error () -Stack now 0 8 20 4 +Stack now 0 4 Shifting token error () Entering state 11 -Stack now 0 8 20 4 11 +Stack now 0 4 11 Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 -Stack now 0 8 20 4 11 25 +Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 29 -Stack now 0 8 20 29 +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1111) +Shifting token number (1111) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Stack now 0 8 18 27 Reading a token Next token is token '\n' () -Reducing stack by rule 7 (line 90): - $1 = nterm exp (2222) - $2 = token '+' () +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () $3 = nterm exp (1111) --> $$ = nterm exp (3333) +-> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 Next token is token '\n' () @@ -150196,7 +150925,7 @@ Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (3333) + $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -150215,10 +150944,12 @@ Cleanup: popping token end of input () Cleanup: popping nterm input () input: +./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1443: $PREPARSER ./calc input stderr: -527. calc.at:1435: Starting parse +stderr: +Starting parse Entering state 0 Stack now 0 Reading a token @@ -150535,18 +151266,106 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - ok +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Stack now 0 4 12 20 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Stack now 0 4 12 +Error: popping nterm exp (1) +Stack now 0 4 +Shifting token error () +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token () +Error: discarding token invalid token () +Error: popping token error () +Stack now 0 4 +Shifting token error () +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1111) +Shifting token number (1111) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' () +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input () +Shifting token end of input () +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input () +Cleanup: popping nterm input () ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1453: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 stderr: Starting parse Entering state 0 @@ -150865,11 +151684,6 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1453: cat stderr -542. calc.at:1458: testing Calculator C++ parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} ... -./calc.at:1458: mv calc.y.tmp calc.y - -./calc.at:1458: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -150880,6 +151694,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1445: cat stderr ./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -150890,22 +151705,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1443: cat stderr -input: - | 1//2 -./calc.at:1453: $PREPARSER ./calc input -./calc.at:1445: cat stderr -stderr: - -input: - | (!!) + (1 2) = 1 -./calc.at:1443: $PREPARSER ./calc input stderr: stdout: -stderr: -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1448: "$PERL" -ne ' +input: +./calc.at:1443: cat stderr + | (# + 1) = 1111 +./calc.at:1446: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. @@ -150916,233 +151721,107 @@ || /\t/ )' calc.cc calc.hh +./calc.at:1445: $PREPARSER ./calc input stderr: input: -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' - | 1 + 2 * 3 + !+ ++ -./calc.at:1445: $PREPARSER ./calc input +input: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) +Next token is token '(' () +Shifting token '(' () Entering state 4 Stack now 0 4 Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Stack now 0 4 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 15 -Stack now 0 4 5 15 -Reducing stack by rule 16 (line 107): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token () +Error: discarding token invalid token () +Error: popping token error () Stack now 0 4 -Shifting token error (1.2-3: ) +Shifting token error () Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token number (1.9: 1) -Shifting token number (1.9: 1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.9: 1) --> $$ = nterm exp (1.9: 1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token number (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Stack now 0 8 20 4 -Shifting token error (1.9-11: ) +Next token is token '+' () +Error: discarding token '+' () +Error: popping token error () +Stack now 0 4 +Shifting token error () Entering state 11 -Stack now 0 8 20 4 11 -Next token is token number (1.11: 2) -Error: discarding token number (1.11: 2) -Error: popping token error (1.9-11: ) -Stack now 0 8 20 4 -Shifting token error (1.9-11: ) +Stack now 0 4 11 +Reading a token +Next token is token number (1) +Error: discarding token number (1) +Error: popping token error () +Stack now 0 4 +Shifting token error () Entering state 11 -Stack now 0 8 20 4 11 +Stack now 0 4 11 Reading a token -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) +Next token is token ')' () +Shifting token ')' () Entering state 25 -Stack now 0 8 20 4 11 25 +Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '=' (1.14: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) +Reading a token +Next token is token '=' () +Shifting token '=' () Entering state 18 Stack now 0 8 18 Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) +Next token is token number (1111) +Shifting token number (1111) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) + $1 = token number (1111) +-> $$ = nterm exp (1111) Entering state 27 Stack now 0 8 18 27 Reading a token -Next token is token '\n' (1.17-2.0: ) +Next token is token '\n' () Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' () +Shifting token '\n' () Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) + $1 = nterm line () +-> $$ = nterm input () Entering state 6 Stack now 0 6 Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) +Next token is token end of input () +Shifting token end of input () Entering state 16 Stack now 0 6 16 Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -input: -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Stack now 0 8 20 1 -Reducing stack by rule 5 (line 79): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Stack now 0 8 20 29 21 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Stack now 0 8 20 29 21 1 -Reducing stack by rule 5 (line 79): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 30 -Stack now 0 8 20 29 21 30 -Reading a token -Next token is token '+' () -Reducing stack by rule 9 (line 92): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Stack now 0 8 20 29 -Next token is token '+' () -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) -Entering state 8 -Stack now 0 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Stack now 0 8 20 5 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 14 -Stack now 0 8 20 5 14 -Reducing stack by rule 17 (line 108): - $1 = token '!' () - $2 = token '+' () -Stack now 0 8 20 -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) +Cleanup: popping token end of input () +Cleanup: popping nterm input () + | (!!) + (1 2) = 1 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -151156,8 +151835,8 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -./calc.at:1448: $PREPARSER ./calc input -./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1446: $PREPARSER ./calc input +./calc.at:1443: $PREPARSER ./calc input stderr: stderr: Starting parse @@ -151300,169 +151979,7 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stdout: -./calc.at:1458: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -stderr: -543. calc.at:1459: testing Calculator C++ parse.error=custom %locations api.prefix={calc} %parse-param {semantic_value *result}{int *count}{int *nerrs} parse.lac=full ... -./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1446: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc calc.hh - ./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1459: mv calc.y.tmp calc.y - -stderr: -./calc.at:1448: $EGREP -c -v 'Return for a new token:|LAC:' stderr -stderr: -./calc.at:1453: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1459: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Stack now 0 8 20 1 -Reducing stack by rule 5 (line 79): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Stack now 0 8 20 29 21 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Stack now 0 8 20 29 21 1 -Reducing stack by rule 5 (line 79): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 30 -Stack now 0 8 20 29 21 30 -Reading a token -Next token is token '+' () -Reducing stack by rule 9 (line 92): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Stack now 0 8 20 29 -Next token is token '+' () -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) -Entering state 8 -Stack now 0 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Stack now 0 8 20 5 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 14 -Stack now 0 8 20 5 14 -Reducing stack by rule 17 (line 108): - $1 = token '!' () - $2 = token '+' () -Stack now 0 8 20 -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) -./calc.at:1445: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1453: cat stderr -./calc.at:1443: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -input: - | 1 2 -./calc.at:1448: $PREPARSER ./calc input -input: -./calc.at:1443: cat stderr - | error -./calc.at:1453: $PREPARSER ./calc input - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1446: $PREPARSER ./calc input -stderr: -stderr: -1.1: syntax error, unexpected invalid token -1.3: syntax error -./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | (- *) + (1 2) = 1 -./calc.at:1443: $PREPARSER ./calc input - | 1 + 2 * 3 + !- ++ -./calc.at:1445: $PREPARSER ./calc input -stderr: -stderr: -1.3: syntax error -stderr: Starting parse Entering state 0 Stack now 0 @@ -152480,230 +152997,134 @@ Stack now 0 6 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) +./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Stack now 0 8 20 1 -Reducing stack by rule 5 (line 79): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Stack now 0 8 20 29 21 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Stack now 0 8 20 29 21 1 -Reducing stack by rule 5 (line 79): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 30 -Stack now 0 8 20 29 21 30 -Reading a token -Next token is token '+' () -Reducing stack by rule 9 (line 92): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Stack now 0 8 20 29 -Next token is token '+' () -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) -Entering state 8 -Stack now 0 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Stack now 0 8 20 5 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 13 -Stack now 0 8 20 5 13 -Reducing stack by rule 18 (line 109): - $1 = token '!' () - $2 = token '-' () -Stack now 0 8 20 -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) -./calc.at:1448: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Stack now 0 -Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Stack now 0 4 2 +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Stack now 0 4 5 Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 106): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2-4: ) +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 15 +Stack now 0 4 5 15 +Reducing stack by rule 16 (line 107): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) Stack now 0 4 -Shifting token error (1.2-4: ) +Shifting token error (1.2-3: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) Entering state 20 Stack now 0 8 20 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) Entering state 4 Stack now 0 8 20 4 Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) +Next token is token number (1.9: 1) +Shifting token number (1.9: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.10: 1) --> $$ = nterm exp (1.10: 1) + $1 = token number (1.9: 1) +-> $$ = nterm exp (1.9: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token -Next token is token number (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) +Next token is token number (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) Stack now 0 8 20 4 -Shifting token error (1.10-12: ) +Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 -Next token is token number (1.12: 2) -Error: discarding token number (1.12: 2) -Error: popping token error (1.10-12: ) +Next token is token number (1.11: 2) +Error: discarding token number (1.11: 2) +Error: popping token error (1.9-11: ) Stack now 0 8 20 4 -Shifting token error (1.10-12: ) +Shifting token error (1.9-11: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token -Next token is token '=' (1.15: ) +Next token is token '=' (1.14: ) Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) Entering state 8 Stack now 0 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) Entering state 18 Stack now 0 8 18 Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.17: 1) --> $$ = nterm exp (1.17: 1) + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) Entering state 27 Stack now 0 8 18 27 Reading a token -Next token is token '\n' (1.18-2.0: ) +Next token is token '\n' (1.17-2.0: ) Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -152720,11 +153141,102 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1459: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -1.1: syntax error, unexpected invalid token -./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Stack now 0 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token () +Error: discarding token invalid token () +Error: popping token error () +Stack now 0 4 +Shifting token error () +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Error: popping token error () +Stack now 0 4 +Shifting token error () +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token number (1) +Error: discarding token number (1) +Error: popping token error () +Stack now 0 4 +Shifting token error () +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1111) +Shifting token number (1111) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' () +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input () +Shifting token end of input () +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input () +Cleanup: popping nterm input () stderr: Starting parse Entering state 0 @@ -153744,8 +154256,223 @@ Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1446: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1443: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +./calc.at:1445: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1443: cat stderr + | 1 2 +./calc.at:1446: $PREPARSER ./calc input stderr: -./calc.at:1448: cat stderr +./calc.at:1445: cat stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token number (1.3: 2) +Stack now 0 +stderr: +stderr: +input: +input: +stdout: +./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (- *) + (1 2) = 1 +./calc.at:1443: $PREPARSER ./calc input + | (1 + # + 1) = 1111 +./calc.at:1445: $PREPARSER ./calc input +stdout: +./calc.at:1448: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc calc.hh + +stderr: +stderr: +./calc.at:1453: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token number (1.3: 2) +Stack now 0 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Stack now 0 4 12 20 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Stack now 0 4 12 +Error: popping nterm exp (1) +Stack now 0 4 +Shifting token error () +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token () +Error: discarding token invalid token () +Error: popping token error () +Stack now 0 4 +Shifting token error () +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Error: popping token error () +Stack now 0 4 +Shifting token error () +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token number (1) +Error: discarding token number (1) +Error: popping token error () +Stack now 0 4 +Shifting token error () +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1111) +Shifting token number (1111) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' () +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input () +Shifting token end of input () +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input () +Cleanup: popping nterm input () Starting parse Entering state 0 Stack now 0 @@ -153894,7 +154621,26 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1453: "$PERL" -pi -e 'use strict; +input: +./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1448: $PREPARSER ./calc input +input: +stderr: +./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -153905,134 +154651,136 @@ }eg ' expout || exit 77 stderr: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1453: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Stack now 0 4 +Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 -Stack now 0 1 +Stack now 0 4 1 Reducing stack by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) -Entering state 8 -Stack now 0 8 +Entering state 12 +Stack now 0 4 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 -Stack now 0 8 20 +Stack now 0 4 12 20 Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Stack now 0 8 20 1 -Reducing stack by rule 5 (line 79): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 -Stack now 0 8 20 29 +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Stack now 0 4 12 +Error: popping nterm exp (1) +Stack now 0 4 +Shifting token error () +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token () +Error: discarding token invalid token () +Error: popping token error () +Stack now 0 4 +Shifting token error () +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Stack now 0 8 20 29 21 +Next token is token '+' () +Error: discarding token '+' () +Error: popping token error () +Stack now 0 4 +Shifting token error () +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Stack now 0 8 20 29 21 1 -Reducing stack by rule 5 (line 79): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 30 -Stack now 0 8 20 29 21 30 +Next token is token number (1) +Error: discarding token number (1) +Error: popping token error () +Stack now 0 4 +Shifting token error () +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token '+' () -Reducing stack by rule 9 (line 92): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Stack now 0 8 20 29 -Next token is token '+' () -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Stack now 0 8 20 5 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 13 -Stack now 0 8 20 5 13 -Reducing stack by rule 18 (line 109): - $1 = token '!' () - $2 = token '-' () -Stack now 0 8 20 -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) -./calc.at:1443: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -./calc.at:1453: cat stderr -./calc.at:1443: cat stderr -input: - | 1 2 -./calc.at:1446: $PREPARSER ./calc input -stderr: - | 1//2 -./calc.at:1448: $PREPARSER ./calc input -Starting parse -Entering state 0 -Stack now 0 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Stack now 0 8 18 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token number (1111) +Shifting token number (1111) Entering state 1 -Stack now 0 1 +Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) + $1 = token number (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' () +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) Entering state 8 Stack now 0 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Stack now 0 6 Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token number (1.3: 2) -Stack now 0 -input: -input: - | (* *) + (*) + (*) - | 1 = 2 = 3 -./calc.at:1443: $PREPARSER ./calc input -./calc.at:1453: $PREPARSER ./calc input -stderr: -./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +Next token is token end of input () +Shifting token end of input () +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input () +Cleanup: popping nterm input () +./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 @@ -154043,22 +154791,26 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) -Error: popping token error (1.2: ) +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Stack now 0 4 2 +Reading a token +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 106): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) Stack now 0 4 -Shifting token error (1.2: ) +Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 -Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) -Error: popping token error (1.2: ) +Error: popping token error (1.2-4: ) Stack now 0 4 Shifting token error (1.2-4: ) Entering state 11 @@ -154086,80 +154838,73 @@ Entering state 4 Stack now 0 8 20 4 Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) +Entering state 1 +Stack now 0 8 20 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Stack now 0 8 20 4 12 +Reading a token +Next token is token number (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Stack now 0 8 20 4 +Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) -Error: popping token error (1.10: ) +Next token is token number (1.12: 2) +Error: discarding token number (1.12: 2) +Error: popping token error (1.10-12: ) Stack now 0 8 20 4 -Shifting token error (1.10: ) +Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token -Next token is token '+' (1.13: ) +Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) -Error: popping token error (1.16: ) -Stack now 0 8 20 4 -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 20 4 11 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) +Entering state 18 +Stack now 0 8 18 Reading a token -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 29 -Stack now 0 8 20 29 +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.17: 1) +-> $$ = nterm exp (1.17: 1) +Entering state 27 +Stack now 0 8 18 27 Reading a token Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 Next token is token '\n' (1.18-2.0: ) @@ -154167,7 +154912,7 @@ Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-17: 3333) + $1 = nterm exp (1.1-17: 2222) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 @@ -154185,14 +154930,29 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -1.7: syntax error, unexpected '=' +stderr: +./calc.at:1446: cat stderr +stderr: ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.3: syntax error -./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1448: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: +input: + | 1//2 +./calc.at:1443: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1446: $PREPARSER ./calc input +./calc.at:1453: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: -1.7: syntax error, unexpected '=' +input: +stdout: stderr: ./calc.at:1445: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} @@ -154204,8 +154964,113 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1454: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + + | 1 2 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 22 +Stack now 0 8 22 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '/' (1.3: ) +Stack now 0 +./calc.at:1448: $PREPARSER ./calc input +./calc.at:1443: cat stderr +input: +stderr: +./calc.at:1445: cat stderr +1.3: syntax error + | 1 2 +input: +./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1453: $PREPARSER ./calc input +./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.3: syntax error, unexpected number + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1454: $PREPARSER ./calc input +input: +input: 1.3: syntax error + | (* *) + (*) + (*) + | (1 + 1) / (1 - 1) +./calc.at:1445: $PREPARSER ./calc input +./calc.at:1443: $PREPARSER ./calc input +stderr: stderr: +stderr: +stderr: +./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 22 +Stack now 0 8 22 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '/' (1.3: ) +Stack now 0 Starting parse Entering state 0 Stack now 0 @@ -154357,37 +155222,150 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1453: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1) +Shifting token number (1) Entering state 1 -Stack now 0 1 +Stack now 0 4 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Stack now 0 4 12 20 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 4 12 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 +Stack now 0 4 12 20 29 +Reading a token +Next token is token ')' () +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 +Stack now 0 4 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Stack now 0 4 12 26 +Reducing stack by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (2) + $3 = token ')' () +-> $$ = nterm exp (2) Entering state 8 Stack now 0 8 Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token number (1.3: 2) -Stack now 0 -./calc.at:1445: cat stderr +Next token is token '/' () +Shifting token '/' () +Entering state 22 +Stack now 0 8 22 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Stack now 0 8 22 4 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 8 22 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Stack now 0 8 22 4 12 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Stack now 0 8 22 4 12 19 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 8 22 4 12 19 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 28 +Stack now 0 8 22 4 12 19 28 +Reading a token +Next token is token ')' () +Reducing stack by rule 8 (line 91): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (1) +-> $$ = nterm exp (0) +Entering state 12 +Stack now 0 8 22 4 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Stack now 0 8 22 4 12 26 +Reducing stack by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (0) + $3 = token ')' () +-> $$ = nterm exp (0) +Entering state 31 +Stack now 0 8 22 31 +Reading a token +Next token is token '\n' () +Reducing stack by rule 10 (line 93): + $1 = nterm exp (2) + $2 = token '/' () + $3 = nterm exp (0) +error: null divisor +-> $$ = nterm exp (2) +Entering state 8 +Stack now 0 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (2) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input () +Shifting token end of input () +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input () +Cleanup: popping nterm input () +stderr: +./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -154398,51 +155376,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1443: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -./calc.at:1453: cat stderr - | (#) + (#) = 2222 -./calc.at:1445: $PREPARSER ./calc input -./calc.at:1448: cat stderr -./calc.at:1446: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.3: syntax error, unexpected number +./calc.at:1454: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: -./calc.at:1443: cat stderr -input: -stdout: -./calc.at:1449: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc calc.hh - -./calc.at:1446: cat stderr -input: stderr: -input: - | error Starting parse Entering state 0 Stack now 0 @@ -154452,95 +155390,113 @@ Entering state 4 Stack now 0 4 Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token () -Error: discarding token invalid token () -Error: popping token error () -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Stack now 0 4 12 20 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 4 12 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 +Stack now 0 4 12 20 29 Reading a token Next token is token ')' () +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 +Stack now 0 4 12 +Next token is token ')' () Shifting token ')' () -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): +Entering state 26 +Stack now 0 4 12 26 +Reducing stack by rule 13 (line 104): $1 = token '(' () - $2 = token error () + $2 = nterm exp (2) $3 = token ')' () --> $$ = nterm exp (1111) +-> $$ = nterm exp (2) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 8 20 +Next token is token '/' () +Shifting token '/' () +Entering state 22 +Stack now 0 8 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 -Stack now 0 8 20 4 +Stack now 0 8 22 4 Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token invalid token () -Error: discarding token invalid token () -Error: popping token error () -Stack now 0 8 20 4 -Shifting token error () -Entering state 11 -Stack now 0 8 20 4 11 +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 8 22 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Stack now 0 8 22 4 12 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Stack now 0 8 22 4 12 19 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Stack now 0 8 22 4 12 19 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 28 +Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' () +Reducing stack by rule 8 (line 91): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (1) +-> $$ = nterm exp (0) +Entering state 12 +Stack now 0 8 22 4 12 +Next token is token ')' () Shifting token ')' () -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 105): +Entering state 26 +Stack now 0 8 22 4 12 26 +Reducing stack by rule 13 (line 104): $1 = token '(' () - $2 = token error () + $2 = nterm exp (0) $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '=' () -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (2222) -Shifting token number (2222) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (2222) --> $$ = nterm exp (2222) -Entering state 27 -Stack now 0 8 18 27 +-> $$ = nterm exp (0) +Entering state 31 +Stack now 0 8 22 31 Reading a token Next token is token '\n' () -Reducing stack by rule 6 (line 80): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (2222) --> $$ = nterm exp (2222) +Reducing stack by rule 10 (line 93): + $1 = nterm exp (2) + $2 = token '/' () + $3 = nterm exp (0) +error: null divisor +-> $$ = nterm exp (2) Entering state 8 Stack now 0 8 Next token is token '\n' () @@ -154548,7 +155504,7 @@ Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (2222) + $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -154566,198 +155522,250 @@ Stack now 0 6 16 Cleanup: popping token end of input () Cleanup: popping nterm input () -./calc.at:1448: $PREPARSER ./calc input - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1449: $PREPARSER ./calc input -input: - | 1//2 -./calc.at:1446: $PREPARSER ./calc input -./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -stderr: - | - | +1 +./calc.at:1446: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1453: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 -Next token is token invalid token () -Error: discarding token invalid token () -Error: popping token error () +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) +Error: popping token error (1.2: ) Stack now 0 4 -Shifting token error () +Shifting token error (1.2: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' () -Shifting token ')' () +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' () -Shifting token '+' () +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 -Next token is token invalid token () -Error: discarding token invalid token () -Error: popping token error () +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) +Error: popping token error (1.10: ) Stack now 0 8 20 4 -Shifting token error () +Shifting token error (1.10: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token -Next token is token ')' () -Shifting token ')' () +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token -Next token is token '=' () +Next token is token '+' (1.13: ) Reducing stack by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Stack now 0 8 18 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 20 +Stack now 0 8 20 Reading a token -Next token is token number (2222) -Shifting token number (2222) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (2222) --> $$ = nterm exp (2222) -Entering state 27 -Stack now 0 8 18 27 +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 +Stack now 0 8 20 4 Reading a token -Next token is token '\n' () -Reducing stack by rule 6 (line 80): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (2222) --> $$ = nterm exp (2222) +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) +Error: popping token error (1.16: ) +Stack now 0 8 20 4 +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 -Next token is token '\n' () -Shifting token '\n' () +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (2222) - $2 = token '\n' () --> $$ = nterm line () + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token end of input () -Shifting token end of input () +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.1: syntax error +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1448: cat stderr +./calc.at:1446: cat stderr +input: +./calc.at:1453: cat stderr +input: + | 1 2 +./calc.at:1454: $PREPARSER ./calc input +./calc.at:1443: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1445: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -./calc.at:1453: $PREPARSER ./calc input + | 1//2 +./calc.at:1448: $PREPARSER ./calc input +stderr: +1.3: syntax error, unexpected number +./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1443: cat stderr +stderr: +1.3: syntax error + | error +./calc.at:1446: $PREPARSER ./calc input +./calc.at:1445: cat stderr ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +1.3: syntax error, unexpected number + | 1//2 +./calc.at:1453: $PREPARSER ./calc input +stderr: +input: stderr: -./calc.at:1449: $EGREP -c -v 'Return for a new token:|LAC:' stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 22 -Stack now 0 8 22 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) Stack now 0 -stderr: -input: +533. calc.at:1445: ok | 1 + 2 * 3 + !+ ++ ./calc.at:1443: $PREPARSER ./calc input stderr: -1.1: syntax error -2.1: syntax error, unexpected '+' +./calc.at:1454: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +1.3: syntax error +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -2.1: syntax error, unexpected '+' stderr: ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} @@ -154769,34 +155777,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 22 -Stack now 0 8 22 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) -Stack now 0 +./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -154877,23 +155858,25 @@ Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1454: cat stderr stderr: -input: - | 1 2 -./calc.at:1449: $PREPARSER ./calc input +stderr: +./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' + ./calc.at:1448: cat stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) +Stack now 0 +input: stderr: -./calc.at:1446: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 + | 1//2 +./calc.at:1454: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -154974,17 +155957,24 @@ Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -1.3: syntax error -./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | 1 = 2 = 3 -./calc.at:1448: $PREPARSER ./calc input +./calc.at:1453: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1443: $EGREP -c -v 'Return for a new token:|LAC:' stderr +input: stderr: -stderr: -1.3: syntax error -1.7: syntax error -./calc.at:1445: "$PERL" -pi -e 'use strict; +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | error +./calc.at:1448: $PREPARSER ./calc input +./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -154994,10 +155984,26 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1453: cat stderr +stderr: +stderr: +1.1: syntax error ./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1446: cat stderr +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +input: stderr: -1.7: syntax error -./calc.at:1453: "$PERL" -pi -e 'use strict; +1.1: syntax error +input: +544. calc.at:1468: testing Calculator glr.cc ... +./calc.at:1468: mv calc.y.tmp calc.y + +./calc.at:1468: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y + | error +./calc.at:1453: $PREPARSER ./calc input + | 1 + 2 * 3 + !- ++ +./calc.at:1443: $PREPARSER ./calc input +./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -155007,11 +156013,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1445: cat stderr +stderr: input: -./calc.at:1446: cat stderr -./calc.at:1453: cat stderr -./calc.at:1449: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -155021,25 +156026,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | 1 + 2 * 3 + !- ++ -./calc.at:1443: $PREPARSER ./calc input - | error -./calc.at:1446: $PREPARSER ./calc input -./calc.at:1453: $PREPARSER ./calc /dev/null -stderr: -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token invalid token (1.1: ) 1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -Stack now 0 -./calc.at:1449: cat stderr -input: -stderr: +./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -155120,142 +156108,54 @@ Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) - | (1 + #) = 1111 -./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.1: syntax error, unexpected end of input -./calc.at:1445: $PREPARSER ./calc input + | 1 = 2 = 3 +./calc.at:1446: $PREPARSER ./calc input +./calc.at:1454: cat stderr ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | 1//2 -./calc.at:1449: $PREPARSER ./calc input -stderr: -stderr: -./calc.at:1448: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -stderr: -1.1: syntax error, unexpected end of input -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -Stack now 0 -1.3: syntax error -./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: stderr: -1.3: syntax error Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 4 1 +Stack now 0 1 Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 4 12 20 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Stack now 0 4 12 -Error: popping nterm exp (1) -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token () -Error: discarding token invalid token () -Error: popping token error () -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token -Next token is token '=' () -Shifting token '=' () +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) Entering state 18 Stack now 0 8 18 Reading a token -Next token is token number (1111) -Shifting token number (1111) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): - $1 = token number (1111) --> $$ = nterm exp (1111) + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 27 Stack now 0 8 18 27 Reading a token -Next token is token '\n' () -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 18 +Error: popping token '=' (1.3: ) Stack now 0 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of input () -Shifting token end of input () -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 +stderr: +input: +stderr: +stderr: Starting parse Entering state 0 Stack now 0 @@ -155336,156 +156236,42 @@ Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1446: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1443: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 + | error +./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.1: syntax error, unexpected invalid token ./calc.at:1448: cat stderr -./calc.at:1446: cat stderr -./calc.at:1453: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1443: cat stderr +./calc.at:1454: $PREPARSER ./calc input +stdout: +stderr: +stderr: +1.1: syntax error, unexpected invalid token +./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +./calc.at:1449: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc calc.hh + +./calc.at:1457: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 4 12 20 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Stack now 0 4 12 -Error: popping nterm exp (1) -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token () -Error: discarding token invalid token () -Error: popping token error () -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1111) -Shifting token number (1111) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' () -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of input () -Shifting token end of input () -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -input: -input: -./calc.at:1453: cat stderr -./calc.at:1449: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | 1 = 2 = 3 -./calc.at:1446: $PREPARSER ./calc input stderr: +1.1: syntax error, unexpected invalid token Starting parse Entering state 0 Stack now 0 @@ -155525,18 +156311,73 @@ Stack now 0 Cleanup: discarding lookahead token '=' (1.7: ) Stack now 0 +./calc.at:1453: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +./calc.at:1443: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +input: +./calc.at:1446: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 | - | +1 + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1457: $PREPARSER ./calc input + | 1 = 2 = 3 + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 ./calc.at:1448: $PREPARSER ./calc input -input: -./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1449: $PREPARSER ./calc input stderr: -2.1: syntax error -./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (#) + (#) = 2222 -./calc.at:1443: $PREPARSER ./calc input +./calc.at:1453: cat stderr stderr: -./calc.at:1445: "$PERL" -pi -e 'use strict; +./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -155546,6 +156387,35 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +stderr: +./calc.at:1468: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1443: cat stderr +stderr: +./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1457: $EGREP -c -v 'Return for a new token:|LAC:' stderr +1.7: syntax error +./calc.at:1446: cat stderr +./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1454: cat stderr +stderr: +input: +./calc.at:1449: $EGREP -c -v 'Return for a new token:|LAC:' stderr +input: +stderr: + | 1 = 2 = 3 + | (#) + (#) = 2222 +./calc.at:1443: $PREPARSER ./calc input +./calc.at:1453: $PREPARSER ./calc input +input: +1.7: syntax error + | 1 2 +input: +./calc.at:1457: $PREPARSER ./calc input +stderr: +stderr: +input: + | 1 = 2 = 3 Starting parse Entering state 0 Stack now 0 @@ -155669,53 +156539,55 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +1.7: syntax error, unexpected '=' +./calc.at:1454: $PREPARSER ./calc input stderr: -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | + | +1 +syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) stderr: -./calc.at:1453: $PREPARSER ./calc input -2.1: syntax error +./calc.at:1446: $PREPARSER ./calc input ./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | 1 2 +./calc.at:1449: $PREPARSER ./calc input +stderr: +1.7: syntax error, unexpected '=' +./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 27 -Stack now 0 8 18 27 +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 74): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 18 -Error: popping token '=' (1.3: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) +Cleanup: discarding lookahead token '+' (2.1: ) Stack now 0 -./calc.at:1445: cat stderr +stderr: +1.3: syntax error +./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.7: syntax error, unexpected '=' +stderr: +1.3: syntax error ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -155726,7 +156598,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1449: cat stderr +stderr: +./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) +stderr: +1.7: syntax error, unexpected '=' stderr: stderr: Starting parse @@ -155852,121 +156728,54 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.1-46: error: 4444 != 1 -./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | (# + 1) = 1111 -./calc.at:1445: $PREPARSER ./calc input -stderr: -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.1-46: error: 4444 != 1 -stderr: +./calc.at:1453: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Stack now 0 4 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token () -Error: discarding token invalid token () -Error: popping token error () -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Error: popping token error () -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1) -Error: discarding token number (1) -Error: popping token error () -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1111) -Shifting token number (1111) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' () -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 74): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token end of input () -Shifting token end of input () -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -stderr: +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Stack now 0 +Cleanup: discarding lookahead token '+' (2.1: ) +Stack now 0 +./calc.at:1457: cat stderr +./calc.at:1449: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1448: cat stderr -./calc.at:1446: "$PERL" -pi -e 'use strict; +./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -155976,14 +156785,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: +./calc.at:1453: cat stderr input: -./calc.at:1448: $PREPARSER ./calc /dev/null -./calc.at:1446: cat stderr - | error -stderr: -./calc.at:1453: "$PERL" -pi -e 'use strict; +./calc.at:1454: cat stderr +./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -155993,7 +156798,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1443: "$PERL" -pi -e 'use strict; + | 1//2 +./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -156003,13 +156809,31 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.1: syntax error -./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1449: $PREPARSER ./calc input +input: +./calc.at:1457: $PREPARSER ./calc input +input: + | + | +1 +stderr: +./calc.at:1448: $PREPARSER ./calc input + | + | +1 +stderr: +./calc.at:1449: cat stderr ./calc.at:1443: cat stderr +./calc.at:1453: $PREPARSER ./calc input +syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) input: +stdout: | | +1 +./calc.at:1454: $PREPARSER ./calc input +./calc.at:1446: cat stderr +./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +stderr: +stderr: ./calc.at:1451: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" @@ -156021,137 +156845,28 @@ || /\t/ )' calc.cc calc.hh -./calc.at:1446: $PREPARSER ./calc input +syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) +2.1: syntax error +./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1446: $PREPARSER ./calc /dev/null +2.1: syntax error, unexpected '+' stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 74): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '+' (2.1: ) +./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) -Stack now 0 +./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: -./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (1 + #) = 1111 +2.1: syntax error +input: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Stack now 0 4 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token () -Error: discarding token invalid token () -Error: popping token error () -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Error: popping token error () -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1) -Error: discarding token number (1) -Error: popping token error () -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1111) -Shifting token number (1111) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' () -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of input () -Shifting token end of input () -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -./calc.at:1443: $PREPARSER ./calc input -stderr: -input: -1.1: syntax error +Next token is token end of input (1.1: ) +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token end of input (1.1: ) +Stack now 0 + | (1 + #) = 1111 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -156165,11 +156880,29 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 +./calc.at:1443: $PREPARSER ./calc input ./calc.at:1451: $PREPARSER ./calc input stderr: -./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1453: cat stderr stderr: +input: +2.1: syntax error, unexpected '+' +stderr: +2.1: syntax error, unexpected '+' + | 1//2 +stderr: +./calc.at:1449: $PREPARSER ./calc input +./calc.at:1448: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 @@ -156270,38 +157003,49 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1457: cat stderr +1.3: syntax error +./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1454: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1451: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1453: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1454: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 74): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) +Next token is token end of input (1.1: ) +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token end of input (1.1: ) Stack now 0 -1.1: syntax error -./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1448: cat stderr stderr: +input: +1.3: syntax error stderr: -./calc.at:1451: $EGREP -c -v 'Return for a new token:|LAC:' stderr + | error +./calc.at:1457: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -156401,38 +157145,12 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1448: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1446: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1445: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1454: $PREPARSER ./calc /dev/null +./calc.at:1448: $PREPARSER ./calc /dev/null +./calc.at:1453: cat stderr stderr: -./calc.at:1443: "$PERL" -pi -e 'use strict; +input: +./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -156442,177 +157160,17 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.1: syntax error -./calc.at:1446: cat stderr -input: - | (!!) + (1 2) = 1 -./calc.at:1445: cat stderr -input: -./calc.at:1453: $PREPARSER ./calc input -./calc.at:1448: cat stderr -./calc.at:1446: $PREPARSER ./calc /dev/null -./calc.at:1443: cat stderr | 1 2 -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token end of input (1.1: ) -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token end of input (1.1: ) -Stack now 0 -stderr: ./calc.at:1451: $PREPARSER ./calc input -input: -./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -input: -stderr: -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 - | (1 + # + 1) = 1111 - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1448: $PREPARSER ./calc input -./calc.at:1445: $PREPARSER ./calc input - | (# + 1) = 1111 -stderr: -./calc.at:1443: $PREPARSER ./calc input -1.3: syntax error -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token end of input (1.1: ) -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token end of input (1.1: ) -Stack now 0 -./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 -./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 4 12 20 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Stack now 0 4 12 -Error: popping nterm exp (1) -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token () -Error: discarding token invalid token () -Error: popping token error () -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Error: popping token error () -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1) -Error: discarding token number (1) -Error: popping token error () -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1111) -Shifting token number (1111) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' () -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of input () -Shifting token end of input () -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () +1.1: syntax error, unexpected end of file +./calc.at:1453: $PREPARSER ./calc /dev/null +./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1446: cat stderr +1.1: syntax error ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -156623,110 +157181,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.1-2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.1-2: ) -Stack now 0 4 -Shifting token error (1.1-2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Error: popping token error (1.1-2: ) -Stack now 0 4 -Shifting token error (1.1-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1.6: 1) -Error: discarding token number (1.6: 1) -Error: popping token error (1.1-4: ) -Stack now 0 4 -Shifting token error (1.1-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.1-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) stderr: -./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1446: "$PERL" -pi -e 'use strict; +./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -156736,278 +157194,39 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +1.3: syntax error stderr: -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 +./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.1: syntax error, unexpected end of input +syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.1-2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.1-2: ) -Stack now 0 4 -Shifting token error (1.1-2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Error: popping token error (1.1-2: ) -Stack now 0 4 -Shifting token error (1.1-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1.6: 1) -Error: discarding token number (1.6: 1) -Error: popping token error (1.1-4: ) -Stack now 0 4 -Shifting token error (1.1-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.1-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -1.3: syntax error -./calc.at:1446: cat stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 4 12 20 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Stack now 0 4 12 -Error: popping nterm exp (1) -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token () -Error: discarding token invalid token () -Error: popping token error () -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Error: popping token error () -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1) -Error: discarding token number (1) -Error: popping token error () -Stack now 0 4 -Shifting token error () -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1111) -Shifting token number (1111) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' () -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of input () -Shifting token end of input () -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -./calc.at:1449: cat stderr -./calc.at:1453: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1448: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1443: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: +stderr: +./calc.at:1443: cat stderr +stderr: +1.1: syntax error input: - | 1 = 2 = 3 -./calc.at:1449: $PREPARSER ./calc input +stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1448: cat stderr +1.3: syntax error ./calc.at:1446: $PREPARSER ./calc input +stdout: +1.1: syntax error, unexpected end of file stderr: -1.7: syntax error -./calc.at:1451: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1449: cat stderr +./calc.at:1455: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + stderr: +1.1: syntax error, unexpected end of input Starting parse Entering state 0 Stack now 0 @@ -157318,18 +157537,41 @@ Entering state 6 Stack now 0 6 Reading a token -Next token is token end of inpstderr: -ut (2.1: ) +Next token is token end of input (2.1: ) Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1451: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 input: -./calc.at:1453: cat stderr -./calc.at:1445: "$PERL" -pi -e 'use strict; + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1455: $PREPARSER ./calc input +input: +input: +./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -157339,8 +157581,1220 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1443: cat stderr +./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1453: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (# + 1) = 1111 +./calc.at:1443: $PREPARSER ./calc input +./calc.at:1454: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | error +./calc.at:1449: $PREPARSER ./calc input +./calc.at:1457: cat stderr +stderr: +stderr: +./calc.at:1454: cat stderr +./calc.at:1451: cat stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 20 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Stack now 0 8 20 29 21 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 20 29 21 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Stack now 0 8 20 29 21 30 +Reading a token +Next token is token '=' (1.11: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R9 G29 R7 G8 S18 +Reducing stack by rule 9 (line 105): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Stack now 0 8 20 29 +Next token is token '=' (1.11: ) +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.13: 7) +Shifting token number (1.13: 7) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.13: 7) +-> $$ = nterm exp (1.13: 7) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' (1.14-2.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R6 G8 S24 +Reducing stack by rule 6 (line 93): + $1 = nterm exp (1.1-9: 7) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13: 7) +-> $$ = nterm exp (1.1-13: 7) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.14-2.0: ) +Shifting token '\n' (1.14-2.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (1.1-13: 7) + $2 = token '\n' (1.14-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 82): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token number (2.1: 1) +Shifting token number (2.1: 1) +Entering state 1 +Stack now 0 6 1 +Reducing stack by rule 5 (line 92): + $1 = token number (2.1: 1) +-> $$ = nterm exp (2.1: 1) +Entering state 8 +Stack now 0 6 8 +Reading a token +Next token is token '+' (2.3: ) +Shifting token '+' (2.3: ) +Entering state 20 +Stack now 0 6 8 20 +Reading a token +Next token is token number (2.5: 2) +Shifting token number (2.5: 2) +Entering state 1 +Stack now 0 6 8 20 1 +Reducing stack by rule 5 (line 92): + $1 = token number (2.5: 2) +-> $$ = nterm exp (2.5: 2) +Entering state 29 +Stack now 0 6 8 20 29 +Reading a token +Next token is token '*' (2.7: ) +Shifting token '*' (2.7: ) +Entering state 21 +Stack now 0 6 8 20 29 21 +Reading a token +Next token is token '-' (2.9: ) +Shifting token '-' (2.9: ) +Entering state 2 +Stack now 0 6 8 20 29 21 2 +Reading a token +Next token is token number (2.10: 3) +Shifting token number (2.10: 3) +Entering state 1 +Stack now 0 6 8 20 29 21 2 1 +Reducing stack by rule 5 (line 92): + $1 = token number (2.10: 3) +-> $$ = nterm exp (2.10: 3) +Entering state 10 +Stack now 0 6 8 20 29 21 2 10 +Reading a token +Next token is token '=' (2.12: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R11 G30 R9 G29 R7 G8 S18 +Reducing stack by rule 11 (line 115): + $1 = token '-' (2.9: ) + $2 = nterm exp (2.10: 3) +-> $$ = nterm exp (2.9-10: -3) +Entering state 30 +Stack now 0 6 8 20 29 21 30 +Next token is token '=' (2.12: ) +Reducing stack by rule 9 (line 105): + $1 = nterm exp (2.5: 2) + $2 = token '*' (2.7: ) + $3 = nterm exp (2.9-10: -3) +-> $$ = nterm exp (2.5-10: -6) +Entering state 29 +Stack now 0 6 8 20 29 +Next token is token '=' (2.12: ) +Reducing stack by rule 7 (line 103): + $1 = nterm exp (2.1: 1) + $2 = token '+' (2.3: ) + $3 = nterm exp (2.5-10: -6) +-> $$ = nterm exp (2.1-10: -5) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (2.12: ) +Shifting token '=' (2.12: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 6 8 18 +Reading a token +Next token is token '-' (2.14: ) +Shifting token '-' (2.14: ) +Entering state 2 +Stack now 0 6 8 18 2 +Reading a token +Next token is token number (2.15: 5) +Shifting token number (2.15: 5) +Entering state 1 +Stack now 0 6 8 18 2 1 +Reducing stack by rule 5 (line 92): + $1 = token number (2.15: 5) +-> $$ = nterm exp (2.15: 5) +Entering state 10 +Stack now 0 6 8 18 2 10 +Reading a token +Next token is token '\n' (2.16-3.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R11 G27 R6 G8 S24 +Reducing stack by rule 11 (line 115): + $1 = token '-' (2.14: ) + $2 = nterm exp (2.15: 5) +-> $$ = nterm exp (2.14-15: -5) +Entering state 27 +Stack now 0 6 8 18 27 +Next token is token '\n' (2.16-3.0: ) +Reducing stack by rule 6 (line 93): + $1 = nterm exp (2.1-10: -5) + $2 = token '=' (2.12: ) + $3 = nterm exp (2.14-15: -5) +-> $$ = nterm exp (2.1-15: -5) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (2.16-3.0: ) +Shifting token '\n' (2.16-3.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 6 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (2.1-15: -5) + $2 = token '\n' (2.16-3.0: ) +-> $$ = nterm line (2.1-3.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-2.0: ) + $2 = nterm line (2.1-3.0: ) +-> $$ = nterm input (1.1-3.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '\n' (3.1-4.0: ) +Shifting token '\n' (3.1-4.0: ) +Entering state 3 +Stack now 0 6 3 +Reducing stack by rule 3 (line 87): + $1 = token '\n' (3.1-4.0: ) +-> $$ = nterm line (3.1-4.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-3.0: ) + $2 = nterm line (3.1-4.0: ) +-> $$ = nterm input (1.1-4.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '-' (4.1: ) +Shifting token '-' (4.1: ) +Entering state 2 +Stack now 0 6 2 +Reading a token +Next token is token number (4.2: 1) +Shifting token number (4.2: 1) +Entering state 1 +Stack now 0 6 2 1 +Reducing stack by rule 5 (line 92): + $1 = token number (4.2: 1) +-> $$ = nterm exp (4.2: 1) +Entering state 10 +Stack now 0 6 2 10 +Reading a token +Next token is token '^' (4.3: ) +Shifting token '^' (4.3: ) +Entering state 23 +Stack now 0 6 2 10 23 +Reading a token +Next token is token number (4.4: 2) +Shifting token number (4.4: 2) +Entering state 1 +Stack now 0 6 2 10 23 1 +Reducing stack by rule 5 (line 92): + $1 = token number (4.4: 2) +-> $$ = nterm exp (4.4: 2) +Entering state 32 +Stack now 0 6 2 10 23 32 +Reading a token +Next token is token '=' (4.6: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R12 G10 R11 G8 S18 +Reducing stack by rule 12 (line 116): + $1 = nterm exp (4.2: 1) + $2 = token '^' (4.3: ) + $3 = nterm exp (4.4: 2) +-> $$ = nterm exp (4.2-4: 1) +Entering state 10 +Stack now 0 6 2 10 +Next token is token '=' (4.6: ) +Reducing stack by rule 11 (line 115): + $1 = token '-' (4.1: ) + $2 = nterm exp (4.2-4: 1) +-> $$ = nterm exp (4.1-4: -1) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (4.6: ) +Shifting token '=' (4.6: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 6 8 18 +Reading a token +Next token is token '-' (4.8: ) +Shifting token '-' (4.8: ) +Entering state 2 +Stack now 0 6 8 18 2 +Reading a token +Next token is token number (4.9: 1) +Shifting token number (4.9: 1) +Entering state 1 +Stack now 0 6 8 18 2 1 +Reducing stack by rule 5 (line 92): + $1 = token number (4.9: 1) +-> $$ = nterm exp (4.9: 1) +Entering state 10 +Stack now 0 6 8 18 2 10 +Reading a token +Next token is token '\n' (4.10-5.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R11 G27 R6 G8 S24 +Reducing stack by rule 11 (line 115): + $1 = token '-' (4.8: ) + $2 = nterm exp (4.9: 1) +-> $$ = nterm exp (4.8-9: -1) +Entering state 27 +Stack now 0 6 8 18 27 +Next token is token '\n' (4.10-5.0: ) +Reducing stack by rule 6 (line 93): + $1 = nterm exp (4.1-4: -1) + $2 = token '=' (4.6: ) + $3 = nterm exp (4.8-9: -1) +-> $$ = nterm exp (4.1-9: -1) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (4.10-5.0: ) +Shifting token '\n' (4.10-5.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 6 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (4.1-9: -1) + $2 = token '\n' (4.10-5.0: ) +-> $$ = nterm line (4.1-5.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-4.0: ) + $2 = nterm line (4.1-5.0: ) +-> $$ = nterm input (1.1-5.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '(' (5.1: ) +Shifting token '(' (5.1: ) +Entering state 4 +Stack now 0 6 4 +Reading a token +Next token is token '-' (5.2: ) +Shifting token '-' (5.2: ) +Entering state 2 +Stack now 0 6 4 2 +Reading a token +Next token is token number (5.3: 1) +Shifting token number (5.3: 1) +Entering state 1 +Stack now 0 6 4 2 1 +Reducing stack by rule 5 (line 92): + $1 = token number (5.3: 1) +-> $$ = nterm exp (5.3: 1) +Entering state 10 +Stack now 0 6 4 2 10 +Reading a token +Next token is token ')' (5.4: ) +LAC: initial context established for ')' +LAC: checking lookahead ')': R11 G12 S26 +Reducing stack by rule 11 (line 115): + $1 = token '-' (5.2: ) + $2 = nterm exp (5.3: 1) +-> $$ = nterm exp (5.2-3: -1) +Entering state 12 +Stack now 0 6 4 12 +Next token is token ')' (5.4: ) +Shifting token ')' (5.4: ) +LAC: initial context discarded due to shift +Entering state 26 +Stack now 0 6 4 12 26 +Reducing stack by rule 13 (line 117): + $1 = token '(' (5.1: ) + $2 = nterm exp (5.2-3: -1) + $3 = token ')' (5.4: ) +-> $$ = nterm exp (5.1-4: -1) +Entering state 8 +Stack now 0 6 8 +Reading a token +Next token is token '^' (5.5: ) +Shifting token '^' (5.5: ) +Entering state 23 +Stack now 0 6 8 23 +Reading a token +Next token is token number (5.6: 2) +Shifting token number (5.6: 2) +Entering state 1 +Stack now 0 6 8 23 1 +Reducing stack by rule 5 (line 92): + $1 = token number (5.6: 2) +-> $$ = nterm exp (5.6: 2) +Entering state 32 +Stack now 0 6 8 23 32 +Reading a token +Next token is token '=' (5.8: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R12 G8 S18 +Reducing stack by rule 12 (line 116): + $1 = nterm exp (5.1-4: -1) + $2 = token '^' (5.5: ) + $3 = nterm exp (5.6: 2) +-> $$ = nterm exp (5.1-6: 1) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (5.8: ) +Shifting token '=' (5.8: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 6 8 18 +Reading a token +Next token is token number (5.10: 1) +Shifting token number (5.10: 1) +Entering state 1 +Stack now 0 6 8 18 1 +Reducing stack by rule 5 (line 92): + $1 = token number (5.10: 1) +-> $$ = nterm exp (5.10: 1) +Entering state 27 +Stack now 0 6 8 18 27 +Reading a token +Next token is token '\n' (5.11-6.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R6 G8 S24 +Reducing stack by rule 6 (line 93): + $1 = nterm exp (5.1-6: 1) + $2 = token '=' (5.8: ) + $3 = nterm exp (5.10: 1) +-> $$ = nterm exp (5.1-10: 1) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (5.11-6.0: ) +Shifting token '\n' (5.11-6.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 6 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (5.1-10: 1) + $2 = token '\n' (5.11-6.0: ) +-> $$ = nterm line (5.1-6.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-5.0: ) + $2 = nterm line (5.1-6.0: ) +-> $$ = nterm input (1.1-6.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '\n' (6.1-7.0: ) +Shifting token '\n' (6.1-7.0: ) +Entering state 3 +Stack now 0 6 3 +Reducing stack by rule 3 (line 87): + $1 = token '\n' (6.1-7.0: ) +-> $$ = nterm line (6.1-7.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-6.0: ) + $2 = nterm line (6.1-7.0: ) +-> $$ = nterm input (1.1-7.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '-' (7.1: ) +Shifting token '-' (7.1: ) +Entering state 2 +Stack now 0 6 2 +Reading a token +Next token is token '-' (7.2: ) +Shifting token '-' (7.2: ) +Entering state 2 +Stack now 0 6 2 2 +Reading a token +Next token is token '-' (7.3: ) +Shifting token '-' (7.3: ) +Entering state 2 +Stack now 0 6 2 2 2 +Reading a token +Next token is token number (7.4: 1) +Shifting token number (7.4: 1) +Entering state 1 +Stack now 0 6 2 2 2 1 +Reducing stack by rule 5 (line 92): + $1 = token number (7.4: 1) +-> $$ = nterm exp (7.4: 1) +Entering state 10 +Stack now 0 6 2 2 2 10 +Reading a token +Next token is token '=' (7.6: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R11 G10 R11 G10 R11 G8 S18 +Reducing stack by rule 11 (line 115): + $1 = token '-' (7.3: ) + $2 = nterm exp (7.4: 1) +-> $$ = nterm exp (7.3-4: -1) +Entering state 10 +Stack now 0 6 2 2 10 +Next token is token '=' (7.6: ) +Reducing stack by rule 11 (line 115): + $1 = token '-' (7.2: ) + $2 = nterm exp (7.3-4: -1) +-> $$ = nterm exp (7.2-4: 1) +Entering state 10 +Stack now 0 6 2 10 +Next token is token '=' (7.6: ) +Reducing stack by rule 11 (line 115): + $1 = token '-' (7.1: ) + $2 = nterm exp (7.2-4: 1) +-> $$ = nterm exp (7.1-4: -1) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (7.6: ) +Shifting token '=' (7.6: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 6 8 18 +Reading a token +Next token is token '-' (7.8: ) +Shifting token '-' (7.8: ) +Entering state 2 +Stack now 0 6 8 18 2 +Reading a token +Next token is token number (7.9: 1) +Shifting token number (7.9: 1) +Entering state 1 +Stack now 0 6 8 18 2 1 +Reducing stack by rule 5 (line 92): + $1 = token number (7.9: 1) +-> $$ = nterm exp (7.9: 1) +Entering state 10 +Stack now 0 6 8 18 2 10 +Reading a token +Next token is token '\n' (7.10-8.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R11 G27 R6 G8 S24 +Reducing stack by rule 11 (line 115): + $1 = token '-' (7.8: ) + $2 = nterm exp (7.9: 1) +-> $$ = nterm exp (7.8-9: -1) +Entering state 27 +Stack now 0 6 8 18 27 +Next token is token '\n' (7.10-8.0: ) +Reducing stack by rule 6 (line 93): + $1 = nterm exp (7.1-4: -1) + $2 = token '=' (7.6: ) + $3 = nterm exp (7.8-9: -1) +-> $$ = nterm exp (7.1-9: -1) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (7.10-8.0: ) +Shifting token '\n' (7.10-8.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 6 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (7.1-9: -1) + $2 = token '\n' (7.10-8.0: ) +-> $$ = nterm line (7.1-8.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-7.0: ) + $2 = nterm line (7.1-8.0: ) +-> $$ = nterm input (1.1-8.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '\n' (8.1-9.0: ) +Shifting token '\n' (8.1-9.0: ) +Entering state 3 +Stack now 0 6 3 +Reducing stack by rule 3 (line 87): + $1 = token '\n' (8.1-9.0: ) +-> $$ = nterm line (8.1-9.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-8.0: ) + $2 = nterm line (8.1-9.0: ) +-> $$ = nterm input (1.1-9.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token number (9.1: 1) +Shifting token number (9.1: 1) +Entering state 1 +Stack now 0 6 1 +Reducing stack by rule 5 (line 92): + $1 = token number (9.1: 1) +-> $$ = nterm exp (9.1: 1) +Entering state 8 +Stack now 0 6 8 +Reading a token +Next token is token '-' (9.3: ) +Shifting token '-' (9.3: ) +Entering state 19 +Stack now 0 6 8 19 +Reading a token +Next token is token number (9.5: 2) +Shifting token number (9.5: 2) +Entering state 1 +Stack now 0 6 8 19 1 +Reducing stack by rule 5 (line 92): + $1 = token number (9.5: 2) +-> $$ = nterm exp (9.5: 2) +Entering state 28 +Stack now 0 6 8 19 28 +Reading a token +Next token is token '-' (9.7: ) +LAC: initial context established for '-' +LAC: checking lookahead '-': R8 G8 S19 +Reducing stack by rule 8 (line 104): + $1 = nterm exp (9.1: 1) + $2 = token '-' (9.3: ) + $3 = nterm exp (9.5: 2) +-> $$ = nterm exp (9.1-5: -1) +Entering state 8 +Stack now 0 6 8 +Next token is token '-' (9.7: ) +Shifting token '-' (9.7: ) +LAC: initial context discarded due to shift +Entering state 19 +Stack now 0 6 8 19 +Reading a token +Next token is token number (9.9: 3) +Shifting token number (9.9: 3) +Entering state 1 +Stack now 0 6 8 19 1 +Reducing stack by rule 5 (line 92): + $1 = token number (9.9: 3) +-> $$ = nterm exp (9.9: 3) +Entering state 28 +Stack now 0 6 8 19 28 +Reading a token +Next token is token '=' (9.11: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R8 G8 S18 +Reducing stack by rule 8 (line 104): + $1 = nterm exp (9.1-5: -1) + $2 = token '-' (9.7: ) + $3 = nterm exp (9.9: 3) +-> $$ = nterm exp (9.1-9: -4) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (9.11: ) +Shifting token '=' (9.11: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 6 8 18 +Reading a token +Next token is token '-' (9.13: ) +Shifting token '-' (9.13: ) +Entering state 2 +Stack now 0 6 8 18 2 +Reading a token +Next token is token number (9.14: 4) +Shifting token number (9.14: 4) +Entering state 1 +Stack now 0 6 8 18 2 1 +Reducing stack by rule 5 (line 92): + $1 = token number (9.14: 4) +-> $$ = nterm exp (9.14: 4) +Entering state 10 +Stack now 0 6 8 18 2 10 +Reading a token +Next token is token '\n' (9.15-10.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R11 G27 R6 G8 S24 +Reducing stack by rule 11 (line 115): + $1 = token '-' (9.13: ) + $2 = nterm exp (9.14: 4) +-> $$ = nterm exp (9.13-14: -4) +Entering state 27 +Stack now 0 6 8 18 27 +Next token is token '\n' (9.15-10.0: ) +Reducing stack by rule 6 (line 93): + $1 = nterm exp (9.1-9: -4) + $2 = token '=' (9.11: ) + $3 = nterm exp (9.13-14: -4) +-> $$ = nterm exp (9.1-14: -4) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (9.15-10.0: ) +Shifting token '\n' (9.15-10.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 6 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (9.1-14: -4) + $2 = token '\n' (9.15-10.0: ) +-> $$ = nterm line (9.1-10.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-9.0: ) + $2 = nterm line (9.1-10.0: ) +-> $$ = nterm input (1.1-10.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token number (10.1: 1) +Shifting token number (10.1: 1) +Entering state 1 +Stack now 0 6 1 +Reducing stack by rule 5 (line 92): + $1 = token number (10.1: 1) +-> $$ = nterm exp (10.1: 1) +Entering state 8 +Stack now 0 6 8 +Reading a token +Next token is token '-' (10.3: ) +Shifting token '-' (10.3: ) +Entering state 19 +Stack now 0 6 8 19 +Reading a token +Next token is token '(' (10.5: ) +Shifting token '(' (10.5: ) +Entering state 4 +Stack now 0 6 8 19 4 +Reading a token +Next token is token number (10.6: 2) +Shifting token number (10.6: 2) +Entering state 1 +Stack now 0 6 8 19 4 1 +Reducing stack by rule 5 (line 92): + $1 = token number (10.6: 2) +-> $$ = nterm exp (10.6: 2) +Entering state 12 +Stack now 0 6 8 19 4 12 +Reading a token +Next token is token '-' (10.8: ) +Shifting token '-' (10.8: ) +Entering state 19 +Stack now 0 6 8 19 4 12 19 +Reading a token +Next token is token number (10.10: 3) +Shifting token number (10.10: 3) +Entering state 1 +Stack now 0 6 8 19 4 12 19 1 +Reducing stack by rule 5 (line 92): + $1 = token number (10.10: 3) +-> $$ = nterm exp (10.10: 3) +Entering state 28 +Stack now 0 6 8 19 4 12 19 28 +Reading a token +Next token is token ')' (10.11: ) +LAC: initial context established for ')' +LAC: checking lookahead ')': R8 G12 S26 +Reducing stack by rule 8 (line 104): + $1 = nterm exp (10.6: 2) + $2 = token '-' (10.8: ) + $3 = nterm exp (10.10: 3) +-> $$ = nterm exp (10.6-10: -1) +Entering state 12 +Stack now 0 6 8 19 4 12 +Next token is token ')' (10.11: ) +Shifting token ')' (10.11: ) +LAC: initial context discarded due to shift +Entering state 26 +Stack now 0 6 8 19 4 12 26 +Reducing stack by rule 13 (line 117): + $1 = token '(' (10.5: ) + $2 = nterm exp (10.6-10: -1) + $3 = token ')' (10.11: ) +-> $$ = nterm exp (10.5-11: -1) +Entering state 28 +Stack now 0 6 8 19 28 +Reading a token +Next token is token '=' (10.13: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R8 G8 S18 +Reducing stack by rule 8 (line 104): + $1 = nterm exp (10.1: 1) + $2 = token '-' (10.3: ) + $3 = nterm exp (10.5-11: -1) +-> $$ = nterm exp (10.1-11: 2) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (10.13: ) +Shifting token '=' (10.13: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 6 8 18 +Reading a token +Next token is token number (10.15: 2) +Shifting token number (10.15: 2) +Entering state 1 +Stack now 0 6 8 18 1 +Reducing stack by rule 5 (line 92): + $1 = token number (10.15: 2) +-> $$ = nterm exp (10.15: 2) +Entering state 27 +Stack now 0 6 8 18 27 +Reading a token +Next token is token '\n' (10.16-11.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R6 G8 S24 +Reducing stack by rule 6 (line 93): + $1 = nterm exp (10.1-11: 2) + $2 = token '=' (10.13: ) + $3 = nterm exp (10.15: 2) +-> $$ = nterm exp (10.1-15: 2) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (10.16-11.0: ) +Shifting token '\n' (10.16-11.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 6 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (10.1-15: 2) + $2 = token '\n' (10.16-11.0: ) +-> $$ = nterm line (10.1-11.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-10.0: ) + $2 = nterm line (10.1-11.0: ) +-> $$ = nterm input (1.1-11.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '\n' (11.1-12.0: ) +Shifting token '\n' (11.1-12.0: ) +Entering state 3 +Stack now 0 6 3 +Reducing stack by rule 3 (line 87): + $1 = token '\n' (11.1-12.0: ) +-> $$ = nterm line (11.1-12.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-11.0: ) + $2 = nterm line (11.1-12.0: ) +-> $$ = nterm input (1.1-12.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token number (12.1: 2) +Shifting token number (12.1: 2) +Entering state 1 +Stack now 0 6 1 +Reducing stack by rule 5 (line 92): + $1 = token number (12.1: 2) +-> $$ = nterm exp (12.1: 2) +Entering state 8 +Stack now 0 6 8 +Reading a token +Next token is token '^' (12.2: ) +Shifting token '^' (12.2: ) +Entering state 23 +Stack now 0 6 8 23 +Reading a token +Next token is token number (12.3: 2) +Shifting token number (12.3: 2) +Entering state 1 +Stack now 0 6 8 23 1 +Reducing stack by rule 5 (line 92): + $1 = token number (12.3: 2) +-> $$ = nterm exp (12.3: 2) +Entering state 32 +Stack now 0 6 8 23 32 +Reading a token +Next token is token '^' (12.4: ) +Shifting token '^' (12.4: ) +Entering state 23 +Stack now 0 6 8 23 32 23 +Reading a token +Next token is token number (12.5: 3) +Shifting token number (12.5: 3) +Entering state 1 +Stack now 0 6 8 23 32 23 1 +Reducing stack by rule 5 (line 92): + $1 = token number (12.5: 3) +-> $$ = nterm exp (12.5: 3) +Entering state 32 +Stack now 0 6 8 23 32 23 32 +Reading a token +Next token is token '=' (12.7: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R12 G32 R12 G8 S18 +Reducing stack by rule 12 (line 116): + $1 = nterm exp (12.3: 2) + $2 = token '^' (12.4: ) + $3 = nterm exp (12.5: 3) +-> $$ = nterm exp (12.3-5: 8) +Entering state 32 +Stack now 0 6 8 23 32 +Next token is token '=' (12.7: ) +Reducing stack by rule 12 (line 116): + $1 = nterm exp (12.1: 2) + $2 = token '^' (12.2: ) + $3 = nterm exp (12.3-5: 8) +-> $$ = nterm exp (12.1-5: 256) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (12.7: ) +Shifting token '=' (12.7: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 6 8 18 +Reading a token +Next token is token number (12.9-11: 256) +Shifting token number (12.9-11: 256) +Entering state 1 +Stack now 0 6 8 18 1 +Reducing stack by rule 5 (line 92): + $1 = token number (12.9-11: 256) +-> $$ = nterm exp (12.9-11: 256) +Entering state 27 +Stack now 0 6 8 18 27 +Reading a token +Next token is token '\n' (12.12-13.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R6 G8 S24 +Reducing stack by rule 6 (line 93): + $1 = nterm exp (12.1-5: 256) + $2 = token '=' (12.7: ) + $3 = nterm exp (12.9-11: 256) +-> $$ = nterm exp (12.1-11: 256) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (12.12-13.0: ) +Shifting token '\n' (12.12-13.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 6 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (12.1-11: 256) + $2 = token '\n' (12.12-13.0: ) +-> $$ = nterm line (12.1-13.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-12.0: ) + $2 = nterm line (12.1-13.0: ) +-> $$ = nterm input (1.1-13.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '(' (13.1: ) +Shifting token '(' (13.1: ) +Entering state 4 +Stack now 0 6 4 +Reading a token +Next token is token number (13.2: 2) +Shifting token number (13.2: 2) +Entering state 1 +Stack now 0 6 4 1 +Reducing stack by rule 5 (line 92): + $1 = token number (13.2: 2) +-> $$ = nterm exp (13.2: 2) +Entering state 12 +Stack now 0 6 4 12 +Reading a token +Next token is token '^' (13.3: ) +Shifting token '^' (13.3: ) +Entering state 23 +Stack now 0 6 4 12 23 +Reading a token +Next token is token number (13.4: 2) +Shifting token number (13.4: 2) +Entering state 1 +Stack now 0 6 4 12 23 1 +Reducing stack by rule 5 (line 92): + $1 = token number (13.4: 2) +-> $$ = nterm exp (13.4: 2) +Entering state 32 +Stack now 0 6 4 12 23 32 +Reading a token +Next token is token ')' (13.5: ) +LAC: initial context established for ')' +LAC: checking lookahead ')': R12 G12 S26 +Reducing stack by rule 12 (line 116): + $1 = nterm exp (13.2: 2) + $2 = token '^' (13.3: ) + $3 = nterm exp (13.4: 2) +-> $$ = nterm exp (13.2-4: 4) +Entering state 12 +Stack now 0 6 4 12 +Next token is token ')' (13.5: ) +Shifting token ')' (13.5: ) +LAC: initial context discarded due to shift +Entering state 26 +Stack now 0 6 4 12 26 +Reducing stack by rule 13 (line 117): + $1 = token '(' (13.1: ) + $2 = nterm exp (13.2-4: 4) + $3 = token ')' (13.5: ) +-> $$ = nterm exp (13.1-5: 4) +Entering state 8 +Stack now 0 6 8 +Reading a token +Next token is token '^' (13.6: ) +Shifting token '^' (13.6: ) +Entering state 23 +Stack now 0 6 8 23 +Reading a token +Next token is token number (13.7: 3) +Shifting token number (13.7: 3) +Entering state 1 +Stack now 0 6 8 23 1 +Reducing stack by rule 5 (line 92): + $1 = token number (13.7: 3) +-> $$ = nterm exp (13.7: 3) +Entering state 32 +Stack now 0 6 8 23 32 +Reading a token +Next token is token '=' (13.9: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R12 G8 S18 +Reducing stack by rule 12 (line 116): + $1 = nterm exp (13.1-5: 4) + $2 = token '^' (13.6: ) + $3 = nterm exp (13.7: 3) +-> $$ = nterm exp (13.1-7: 64) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (13.9: ) +Shifting token '=' (13.9: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 6 8 18 +Reading a token +Next token is token number (13.11-12: 64) +Shifting token number (13.11-12: 64) +Entering state 1 +Stack now 0 6 8 18 1 +Reducing stack by rule 5 (line 92): + $1 = token number (13.11-12: 64) +-> $$ = nterm exp (13.11-12: 64) +Entering state 27 +Stack now 0 6 8 18 27 +Reading a token +Next token is token '\n' (13.13-14.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R6 G8 S24 +Reducing stack by rule 6 (line 93): + $1 = nterm exp (13.1-7: 64) + $2 = token '=' (13.9: ) + $3 = nterm exp (13.11-12: 64) +-> $$ = nterm exp (13.1-12: 64) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (13.13-14.0: ) +Shifting token '\n' (13.13-14.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 6 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (13.1-12: 64) + $2 = token '\n' (13.13-14.0: ) +-> $$ = nterm line (13.1-14.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-13.0: ) + $2 = nterm line (13.1-14.0: ) +-> $$ = nterm input (1.1-14.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of file (14.1: ) +Shifting token end of file (14.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of file (14.1: ) +Cleanup: popping nterm input (1.1-14.0: ) +./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: stderr: +1.1: syntax error +./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.1-2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.1-2: ) +Stack now 0 4 +Shifting token error (1.1-2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Error: popping token error (1.1-2: ) +Stack now 0 4 +Shifting token error (1.1-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token number (1.6: 1) +Error: discarding token number (1.6: 1) +Error: popping token error (1.1-4: ) +Stack now 0 4 +Shifting token error (1.1-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.1-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Stack now 0 @@ -157658,9 +159112,1104 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | (!!) + (1 2) = 1 -./calc.at:1445: cat stderr -./calc.at:1448: $PREPARSER ./calc input +stderr: +stderr: +./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 20 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Stack now 0 8 20 29 21 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Stack now 0 8 20 29 21 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Stack now 0 8 20 29 21 30 +Reading a token +Next token is token '=' (1.11: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R9 G29 R7 G8 S18 +Reducing stack by rule 9 (line 105): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Stack now 0 8 20 29 +Next token is token '=' (1.11: ) +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.13: 7) +Shifting token number (1.13: 7) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.13: 7) +-> $$ = nterm exp (1.13: 7) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' (1.14-2.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R6 G8 S24 +Reducing stack by rule 6 (line 93): + $1 = nterm exp (1.1-9: 7) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13: 7) +-> $$ = nterm exp (1.1-13: 7) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.14-2.0: ) +Shifting token '\n' (1.14-2.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (1.1-13: 7) + $2 = token '\n' (1.14-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 82): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token number (2.1: 1) +Shifting token number (2.1: 1) +Entering state 1 +Stack now 0 6 1 +Reducing stack by rule 5 (line 92): + $1 = token number (2.1: 1) +-> $$ = nterm exp (2.1: 1) +Entering state 8 +Stack now 0 6 8 +Reading a token +Next token is token '+' (2.3: ) +Shifting token '+' (2.3: ) +Entering state 20 +Stack now 0 6 8 20 +Reading a token +Next token is token number (2.5: 2) +Shifting token number (2.5: 2) +Entering state 1 +Stack now 0 6 8 20 1 +Reducing stack by rule 5 (line 92): + $1 = token number (2.5: 2) +-> $$ = nterm exp (2.5: 2) +Entering state 29 +Stack now 0 6 8 20 29 +Reading a token +Next token is token '*' (2.7: ) +Shifting token '*' (2.7: ) +Entering state 21 +Stack now 0 6 8 20 29 21 +Reading a token +Next token is token '-' (2.9: ) +Shifting token '-' (2.9: ) +Entering state 2 +Stack now 0 6 8 20 29 21 2 +Reading a token +Next token is token number (2.10: 3) +Shifting token number (2.10: 3) +Entering state 1 +Stack now 0 6 8 20 29 21 2 1 +Reducing stack by rule 5 (line 92): + $1 = token number (2.10: 3) +-> $$ = nterm exp (2.10: 3) +Entering state 10 +Stack now 0 6 8 20 29 21 2 10 +Reading a token +Next token is token '=' (2.12: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R11 G30 R9 G29 R7 G8 S18 +Reducing stack by rule 11 (line 115): + $1 = token '-' (2.9: ) + $2 = nterm exp (2.10: 3) +-> $$ = nterm exp (2.9-10: -3) +Entering state 30 +Stack now 0 6 8 20 29 21 30 +Next token is token '=' (2.12: ) +Reducing stack by rule 9 (line 105): + $1 = nterm exp (2.5: 2) + $2 = token '*' (2.7: ) + $3 = nterm exp (2.9-10: -3) +-> $$ = nterm exp (2.5-10: -6) +Entering state 29 +Stack now 0 6 8 20 29 +Next token is token '=' (2.12: ) +Reducing stack by rule 7 (line 103): + $1 = nterm exp (2.1: 1) + $2 = token '+' (2.3: ) + $3 = nterm exp (2.5-10: -6) +-> $$ = nterm exp (2.1-10: -5) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (2.12: ) +Shifting token '=' (2.12: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 6 8 18 +Reading a token +Next token is token '-' (2.14: ) +Shifting token '-' (2.14: ) +Entering state 2 +Stack now 0 6 8 18 2 +Reading a token +Next token is token number (2.15: 5) +Shifting token number (2.15: 5) +Entering state 1 +Stack now 0 6 8 18 2 1 +Reducing stack by rule 5 (line 92): + $1 = token number (2.15: 5) +-> $$ = nterm exp (2.15: 5) +Entering state 10 +Stack now 0 6 8 18 2 10 +Reading a token +Next token is token '\n' (2.16-3.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R11 G27 R6 G8 S24 +Reducing stack by rule 11 (line 115): + $1 = token '-' (2.14: ) + $2 = nterm exp (2.15: 5) +-> $$ = nterm exp (2.14-15: -5) +Entering state 27 +Stack now 0 6 8 18 27 +Next token is token '\n' (2.16-3.0: ) +Reducing stack by rule 6 (line 93): + $1 = nterm exp (2.1-10: -5) + $2 = token '=' (2.12: ) + $3 = nterm exp (2.14-15: -5) +-> $$ = nterm exp (2.1-15: -5) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (2.16-3.0: ) +Shifting token '\n' (2.16-3.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 6 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (2.1-15: -5) + $2 = token '\n' (2.16-3.0: ) +-> $$ = nterm line (2.1-3.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-2.0: ) + $2 = nterm line (2.1-3.0: ) +-> $$ = nterm input (1.1-3.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '\n' (3.1-4.0: ) +Shifting token '\n' (3.1-4.0: ) +Entering state 3 +Stack now 0 6 3 +Reducing stack by rule 3 (line 87): + $1 = token '\n' (3.1-4.0: ) +-> $$ = nterm line (3.1-4.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-3.0: ) + $2 = nterm line (3.1-4.0: ) +-> $$ = nterm input (1.1-4.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '-' (4.1: ) +Shifting token '-' (4.1: ) +Entering state 2 +Stack now 0 6 2 +Reading a token +Next token is token number (4.2: 1) +Shifting token number (4.2: 1) +Entering state 1 +Stack now 0 6 2 1 +Reducing stack by rule 5 (line 92): + $1 = token number (4.2: 1) +-> $$ = nterm exp (4.2: 1) +Entering state 10 +Stack now 0 6 2 10 +Reading a token +Next token is token '^' (4.3: ) +Shifting token '^' (4.3: ) +Entering state 23 +Stack now 0 6 2 10 23 +Reading a token +Next token is token number (4.4: 2) +Shifting token number (4.4: 2) +Entering state 1 +Stack now 0 6 2 10 23 1 +Reducing stack by rule 5 (line 92): + $1 = token number (4.4: 2) +-> $$ = nterm exp (4.4: 2) +Entering state 32 +Stack now 0 6 2 10 23 32 +Reading a token +Next token is token '=' (4.6: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R12 G10 R11 G8 S18 +Reducing stack by rule 12 (line 116): + $1 = nterm exp (4.2: 1) + $2 = token '^' (4.3: ) + $3 = nterm exp (4.4: 2) +-> $$ = nterm exp (4.2-4: 1) +Entering state 10 +Stack now 0 6 2 10 +Next token is token '=' (4.6: ) +Reducing stack by rule 11 (line 115): + $1 = token '-' (4.1: ) + $2 = nterm exp (4.2-4: 1) +-> $$ = nterm exp (4.1-4: -1) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (4.6: ) +Shifting token '=' (4.6: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 6 8 18 +Reading a token +Next token is token '-' (4.8: ) +Shifting token '-' (4.8: ) +Entering state 2 +Stack now 0 6 8 18 2 +Reading a token +Next token is token number (4.9: 1) +Shifting token number (4.9: 1) +Entering state 1 +Stack now 0 6 8 18 2 1 +Reducing stack by rule 5 (line 92): + $1 = token number (4.9: 1) +-> $$ = nterm exp (4.9: 1) +Entering state 10 +Stack now 0 6 8 18 2 10 +Reading a token +Next token is token '\n' (4.10-5.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R11 G27 R6 G8 S24 +Reducing stack by rule 11 (line 115): + $1 = token '-' (4.8: ) + $2 = nterm exp (4.9: 1) +-> $$ = nterm exp (4.8-9: -1) +Entering state 27 +Stack now 0 6 8 18 27 +Next token is token '\n' (4.10-5.0: ) +Reducing stack by rule 6 (line 93): + $1 = nterm exp (4.1-4: -1) + $2 = token '=' (4.6: ) + $3 = nterm exp (4.8-9: -1) +-> $$ = nterm exp (4.1-9: -1) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (4.10-5.0: ) +Shifting token '\n' (4.10-5.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 6 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (4.1-9: -1) + $2 = token '\n' (4.10-5.0: ) +-> $$ = nterm line (4.1-5.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-4.0: ) + $2 = nterm line (4.1-5.0: ) +-> $$ = nterm input (1.1-5.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '(' (5.1: ) +Shifting token '(' (5.1: ) +Entering state 4 +Stack now 0 6 4 +Reading a token +Next token is token '-' (5.2: ) +Shifting token '-' (5.2: ) +Entering state 2 +Stack now 0 6 4 2 +Reading a token +Next token is token number (5.3: 1) +Shifting token number (5.3: 1) +Entering state 1 +Stack now 0 6 4 2 1 +Reducing stack by rule 5 (line 92): + $1 = token number (5.3: 1) +-> $$ = nterm exp (5.3: 1) +Entering state 10 +Stack now 0 6 4 2 10 +Reading a token +Next token is token ')' (5.4: ) +LAC: initial context established for ')' +LAC: checking lookahead ')': R11 G12 S26 +Reducing stack by rule 11 (line 115): + $1 = token '-' (5.2: ) + $2 = nterm exp (5.3: 1) +-> $$ = nterm exp (5.2-3: -1) +Entering state 12 +Stack now 0 6 4 12 +Next token is token ')' (5.4: ) +Shifting token ')' (5.4: ) +LAC: initial context discarded due to shift +Entering state 26 +Stack now 0 6 4 12 26 +Reducing stack by rule 13 (line 117): + $1 = token '(' (5.1: ) + $2 = nterm exp (5.2-3: -1) + $3 = token ')' (5.4: ) +-> $$ = nterm exp (5.1-4: -1) +Entering state 8 +Stack now 0 6 8 +Reading a token +Next token is token '^' (5.5: ) +Shifting token '^' (5.5: ) +Entering state 23 +Stack now 0 6 8 23 +Reading a token +Next token is token number (5.6: 2) +Shifting token number (5.6: 2) +Entering state 1 +Stack now 0 6 8 23 1 +Reducing stack by rule 5 (line 92): + $1 = token number (5.6: 2) +-> $$ = nterm exp (5.6: 2) +Entering state 32 +Stack now 0 6 8 23 32 +Reading a token +Next token is token '=' (5.8: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R12 G8 S18 +Reducing stack by rule 12 (line 116): + $1 = nterm exp (5.1-4: -1) + $2 = token '^' (5.5: ) + $3 = nterm exp (5.6: 2) +-> $$ = nterm exp (5.1-6: 1) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (5.8: ) +Shifting token '=' (5.8: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 6 8 18 +Reading a token +Next token is token number (5.10: 1) +Shifting token number (5.10: 1) +Entering state 1 +Stack now 0 6 8 18 1 +Reducing stack by rule 5 (line 92): + $1 = token number (5.10: 1) +-> $$ = nterm exp (5.10: 1) +Entering state 27 +Stack now 0 6 8 18 27 +Reading a token +Next token is token '\n' (5.11-6.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R6 G8 S24 +Reducing stack by rule 6 (line 93): + $1 = nterm exp (5.1-6: 1) + $2 = token '=' (5.8: ) + $3 = nterm exp (5.10: 1) +-> $$ = nterm exp (5.1-10: 1) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (5.11-6.0: ) +Shifting token '\n' (5.11-6.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 6 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (5.1-10: 1) + $2 = token '\n' (5.11-6.0: ) +-> $$ = nterm line (5.1-6.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-5.0: ) + $2 = nterm line (5.1-6.0: ) +-> $$ = nterm input (1.1-6.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '\n' (6.1-7.0: ) +Shifting token '\n' (6.1-7.0: ) +Entering state 3 +Stack now 0 6 3 +Reducing stack by rule 3 (line 87): + $1 = token '\n' (6.1-7.0: ) +-> $$ = nterm line (6.1-7.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-6.0: ) + $2 = nterm line (6.1-7.0: ) +-> $$ = nterm input (1.1-7.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '-' (7.1: ) +Shifting token '-' (7.1: ) +Entering state 2 +Stack now 0 6 2 +Reading a token +Next token is token '-' (7.2: ) +Shifting token '-' (7.2: ) +Entering state 2 +Stack now 0 6 2 2 +Reading a token +Next token is token '-' (7.3: ) +Shifting token '-' (7.3: ) +Entering state 2 +Stack now 0 6 2 2 2 +Reading a token +Next token is token number (7.4: 1) +Shifting token number (7.4: 1) +Entering state 1 +Stack now 0 6 2 2 2 1 +Reducing stack by rule 5 (line 92): + $1 = token number (7.4: 1) +-> $$ = nterm exp (7.4: 1) +Entering state 10 +Stack now 0 6 2 2 2 10 +Reading a token +Next token is token '=' (7.6: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R11 G10 R11 G10 R11 G8 S18 +Reducing stack by rule 11 (line 115): + $1 = token '-' (7.3: ) + $2 = nterm exp (7.4: 1) +-> $$ = nterm exp (7.3-4: -1) +Entering state 10 +Stack now 0 6 2 2 10 +Next token is token '=' (7.6: ) +Reducing stack by rule 11 (line 115): + $1 = token '-' (7.2: ) + $2 = nterm exp (7.3-4: -1) +-> $$ = nterm exp (7.2-4: 1) +Entering state 10 +Stack now 0 6 2 10 +Next token is token '=' (7.6: ) +Reducing stack by rule 11 (line 115): + $1 = token '-' (7.1: ) + $2 = nterm exp (7.2-4: 1) +-> $$ = nterm exp (7.1-4: -1) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (7.6: ) +Shifting token '=' (7.6: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 6 8 18 +Reading a token +Next token is token '-' (7.8: ) +Shifting token '-' (7.8: ) +Entering state 2 +Stack now 0 6 8 18 2 +Reading a token +Next token is token number (7.9: 1) +Shifting token number (7.9: 1) +Entering state 1 +Stack now 0 6 8 18 2 1 +Reducing stack by rule 5 (line 92): + $1 = token number (7.9: 1) +-> $$ = nterm exp (7.9: 1) +Entering state 10 +Stack now 0 6 8 18 2 10 +Reading a token +Next token is token '\n' (7.10-8.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R11 G27 R6 G8 S24 +Reducing stack by rule 11 (line 115): + $1 = token '-' (7.8: ) + $2 = nterm exp (7.9: 1) +-> $$ = nterm exp (7.8-9: -1) +Entering state 27 +Stack now 0 6 8 18 27 +Next token is token '\n' (7.10-8.0: ) +Reducing stack by rule 6 (line 93): + $1 = nterm exp (7.1-4: -1) + $2 = token '=' (7.6: ) + $3 = nterm exp (7.8-9: -1) +-> $$ = nterm exp (7.1-9: -1) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (7.10-8.0: ) +Shifting token '\n' (7.10-8.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 6 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (7.1-9: -1) + $2 = token '\n' (7.10-8.0: ) +-> $$ = nterm line (7.1-8.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-7.0: ) + $2 = nterm line (7.1-8.0: ) +-> $$ = nterm input (1.1-8.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '\n' (8.1-9.0: ) +Shifting token '\n' (8.1-9.0: ) +Entering state 3 +Stack now 0 6 3 +Reducing stack by rule 3 (line 87): + $1 = token '\n' (8.1-9.0: ) +-> $$ = nterm line (8.1-9.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-8.0: ) + $2 = nterm line (8.1-9.0: ) +-> $$ = nterm input (1.1-9.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token number (9.1: 1) +Shifting token number (9.1: 1) +Entering state 1 +Stack now 0 6 1 +Reducing stack by rule 5 (line 92): + $1 = token number (9.1: 1) +-> $$ = nterm exp (9.1: 1) +Entering state 8 +Stack now 0 6 8 +Reading a token +Next token is token '-' (9.3: ) +Shifting token '-' (9.3: ) +Entering state 19 +Stack now 0 6 8 19 +Reading a token +Next token is token number (9.5: 2) +Shifting token number (9.5: 2) +Entering state 1 +Stack now 0 6 8 19 1 +Reducing stack by rule 5 (line 92): + $1 = token number (9.5: 2) +-> $$ = nterm exp (9.5: 2) +Entering state 28 +Stack now 0 6 8 19 28 +Reading a token +Next token is token '-' (9.7: ) +LAC: initial context established for '-' +LAC: checking lookahead '-': R8 G8 S19 +Reducing stack by rule 8 (line 104): + $1 = nterm exp (9.1: 1) + $2 = token '-' (9.3: ) + $3 = nterm exp (9.5: 2) +-> $$ = nterm exp (9.1-5: -1) +Entering state 8 +Stack now 0 6 8 +Next token is token '-' (9.7: ) +Shifting token '-' (9.7: ) +LAC: initial context discarded due to shift +Entering state 19 +Stack now 0 6 8 19 +Reading a token +Next token is token number (9.9: 3) +Shifting token number (9.9: 3) +Entering state 1 +Stack now 0 6 8 19 1 +Reducing stack by rule 5 (line 92): + $1 = token number (9.9: 3) +-> $$ = nterm exp (9.9: 3) +Entering state 28 +Stack now 0 6 8 19 28 +Reading a token +Next token is token '=' (9.11: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R8 G8 S18 +Reducing stack by rule 8 (line 104): + $1 = nterm exp (9.1-5: -1) + $2 = token '-' (9.7: ) + $3 = nterm exp (9.9: 3) +-> $$ = nterm exp (9.1-9: -4) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (9.11: ) +Shifting token '=' (9.11: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 6 8 18 +Reading a token +Next token is token '-' (9.13: ) +Shifting token '-' (9.13: ) +Entering state 2 +Stack now 0 6 8 18 2 +Reading a token +Next token is token number (9.14: 4) +Shifting token number (9.14: 4) +Entering state 1 +Stack now 0 6 8 18 2 1 +Reducing stack by rule 5 (line 92): + $1 = token number (9.14: 4) +-> $$ = nterm exp (9.14: 4) +Entering state 10 +Stack now 0 6 8 18 2 10 +Reading a token +Next token is token '\n' (9.15-10.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R11 G27 R6 G8 S24 +Reducing stack by rule 11 (line 115): + $1 = token '-' (9.13: ) + $2 = nterm exp (9.14: 4) +-> $$ = nterm exp (9.13-14: -4) +Entering state 27 +Stack now 0 6 8 18 27 +Next token is token '\n' (9.15-10.0: ) +Reducing stack by rule 6 (line 93): + $1 = nterm exp (9.1-9: -4) + $2 = token '=' (9.11: ) + $3 = nterm exp (9.13-14: -4) +-> $$ = nterm exp (9.1-14: -4) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (9.15-10.0: ) +Shifting token '\n' (9.15-10.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 6 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (9.1-14: -4) + $2 = token '\n' (9.15-10.0: ) +-> $$ = nterm line (9.1-10.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-9.0: ) + $2 = nterm line (9.1-10.0: ) +-> $$ = nterm input (1.1-10.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token number (10.1: 1) +Shifting token number (10.1: 1) +Entering state 1 +Stack now 0 6 1 +Reducing stack by rule 5 (line 92): + $1 = token number (10.1: 1) +-> $$ = nterm exp (10.1: 1) +Entering state 8 +Stack now 0 6 8 +Reading a token +Next token is token '-' (10.3: ) +Shifting token '-' (10.3: ) +Entering state 19 +Stack now 0 6 8 19 +Reading a token +Next token is token '(' (10.5: ) +Shifting token '(' (10.5: ) +Entering state 4 +Stack now 0 6 8 19 4 +Reading a token +Next token is token number (10.6: 2) +Shifting token number (10.6: 2) +Entering state 1 +Stack now 0 6 8 19 4 1 +Reducing stack by rule 5 (line 92): + $1 = token number (10.6: 2) +-> $$ = nterm exp (10.6: 2) +Entering state 12 +Stack now 0 6 8 19 4 12 +Reading a token +Next token is token '-' (10.8: ) +Shifting token '-' (10.8: ) +Entering state 19 +Stack now 0 6 8 19 4 12 19 +Reading a token +Next token is token number (10.10: 3) +Shifting token number (10.10: 3) +Entering state 1 +Stack now 0 6 8 19 4 12 19 1 +Reducing stack by rule 5 (line 92): + $1 = token number (10.10: 3) +-> $$ = nterm exp (10.10: 3) +Entering state 28 +Stack now 0 6 8 19 4 12 19 28 +Reading a token +Next token is token ')' (10.11: ) +LAC: initial context established for ')' +LAC: checking lookahead ')': R8 G12 S26 +Reducing stack by rule 8 (line 104): + $1 = nterm exp (10.6: 2) + $2 = token '-' (10.8: ) + $3 = nterm exp (10.10: 3) +-> $$ = nterm exp (10.6-10: -1) +Entering state 12 +Stack now 0 6 8 19 4 12 +Next token is token ')' (10.11: ) +Shifting token ')' (10.11: ) +LAC: initial context discarded due to shift +Entering state 26 +Stack now 0 6 8 19 4 12 26 +Reducing stack by rule 13 (line 117): + $1 = token '(' (10.5: ) + $2 = nterm exp (10.6-10: -1) + $3 = token ')' (10.11: ) +-> $$ = nterm exp (10.5-11: -1) +Entering state 28 +Stack now 0 6 8 19 28 +Reading a token +Next token is token '=' (10.13: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R8 G8 S18 +Reducing stack by rule 8 (line 104): + $1 = nterm exp (10.1: 1) + $2 = token '-' (10.3: ) + $3 = nterm exp (10.5-11: -1) +-> $$ = nterm exp (10.1-11: 2) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (10.13: ) +Shifting token '=' (10.13: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 6 8 18 +Reading a token +Next token is token number (10.15: 2) +Shifting token number (10.15: 2) +Entering state 1 +Stack now 0 6 8 18 1 +Reducing stack by rule 5 (line 92): + $1 = token number (10.15: 2) +-> $$ = nterm exp (10.15: 2) +Entering state 27 +Stack now 0 6 8 18 27 +Reading a token +Next token is token '\n' (10.16-11.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R6 G8 S24 +Reducing stack by rule 6 (line 93): + $1 = nterm exp (10.1-11: 2) + $2 = token '=' (10.13: ) + $3 = nterm exp (10.15: 2) +-> $$ = nterm exp (10.1-15: 2) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (10.16-11.0: ) +Shifting token '\n' (10.16-11.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 6 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (10.1-15: 2) + $2 = token '\n' (10.16-11.0: ) +-> $$ = nterm line (10.1-11.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-10.0: ) + $2 = nterm line (10.1-11.0: ) +-> $$ = nterm input (1.1-11.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '\n' (11.1-12.0: ) +Shifting token '\n' (11.1-12.0: ) +Entering state 3 +Stack now 0 6 3 +Reducing stack by rule 3 (line 87): + $1 = token '\n' (11.1-12.0: ) +-> $$ = nterm line (11.1-12.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-11.0: ) + $2 = nterm line (11.1-12.0: ) +-> $$ = nterm input (1.1-12.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token number (12.1: 2) +Shifting token number (12.1: 2) +Entering state 1 +Stack now 0 6 1 +Reducing stack by rule 5 (line 92): + $1 = token number (12.1: 2) +-> $$ = nterm exp (12.1: 2) +Entering state 8 +Stack now 0 6 8 +Reading a token +Next token is token '^' (12.2: ) +Shifting token '^' (12.2: ) +Entering state 23 +Stack now 0 6 8 23 +Reading a token +Next token is token number (12.3: 2) +Shifting token number (12.3: 2) +Entering state 1 +Stack now 0 6 8 23 1 +Reducing stack by rule 5 (line 92): + $1 = token number (12.3: 2) +-> $$ = nterm exp (12.3: 2) +Entering state 32 +Stack now 0 6 8 23 32 +Reading a token +Next token is token '^' (12.4: ) +Shifting token '^' (12.4: ) +Entering state 23 +Stack now 0 6 8 23 32 23 +Reading a token +Next token is token number (12.5: 3) +Shifting token number (12.5: 3) +Entering state 1 +Stack now 0 6 8 23 32 23 1 +Reducing stack by rule 5 (line 92): + $1 = token number (12.5: 3) +-> $$ = nterm exp (12.5: 3) +Entering state 32 +Stack now 0 6 8 23 32 23 32 +Reading a token +Next token is token '=' (12.7: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R12 G32 R12 G8 S18 +Reducing stack by rule 12 (line 116): + $1 = nterm exp (12.3: 2) + $2 = token '^' (12.4: ) + $3 = nterm exp (12.5: 3) +-> $$ = nterm exp (12.3-5: 8) +Entering state 32 +Stack now 0 6 8 23 32 +Next token is token '=' (12.7: ) +Reducing stack by rule 12 (line 116): + $1 = nterm exp (12.1: 2) + $2 = token '^' (12.2: ) + $3 = nterm exp (12.3-5: 8) +-> $$ = nterm exp (12.1-5: 256) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (12.7: ) +Shifting token '=' (12.7: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 6 8 18 +Reading a token +Next token is token number (12.9-11: 256) +Shifting token number (12.9-11: 256) +Entering state 1 +Stack now 0 6 8 18 1 +Reducing stack by rule 5 (line 92): + $1 = token number (12.9-11: 256) +-> $$ = nterm exp (12.9-11: 256) +Entering state 27 +Stack now 0 6 8 18 27 +Reading a token +Next token is token '\n' (12.12-13.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R6 G8 S24 +Reducing stack by rule 6 (line 93): + $1 = nterm exp (12.1-5: 256) + $2 = token '=' (12.7: ) + $3 = nterm exp (12.9-11: 256) +-> $$ = nterm exp (12.1-11: 256) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (12.12-13.0: ) +Shifting token '\n' (12.12-13.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 6 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (12.1-11: 256) + $2 = token '\n' (12.12-13.0: ) +-> $$ = nterm line (12.1-13.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-12.0: ) + $2 = nterm line (12.1-13.0: ) +-> $$ = nterm input (1.1-13.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '(' (13.1: ) +Shifting token '(' (13.1: ) +Entering state 4 +Stack now 0 6 4 +Reading a token +Next token is token number (13.2: 2) +Shifting token number (13.2: 2) +Entering state 1 +Stack now 0 6 4 1 +Reducing stack by rule 5 (line 92): + $1 = token number (13.2: 2) +-> $$ = nterm exp (13.2: 2) +Entering state 12 +Stack now 0 6 4 12 +Reading a token +Next token is token '^' (13.3: ) +Shifting token '^' (13.3: ) +Entering state 23 +Stack now 0 6 4 12 23 +Reading a token +Next token is token number (13.4: 2) +Shifting token number (13.4: 2) +Entering state 1 +Stack now 0 6 4 12 23 1 +Reducing stack by rule 5 (line 92): + $1 = token number (13.4: 2) +-> $$ = nterm exp (13.4: 2) +Entering state 32 +Stack now 0 6 4 12 23 32 +Reading a token +Next token is token ')' (13.5: ) +LAC: initial context established for ')' +LAC: checking lookahead ')': R12 G12 S26 +Reducing stack by rule 12 (line 116): + $1 = nterm exp (13.2: 2) + $2 = token '^' (13.3: ) + $3 = nterm exp (13.4: 2) +-> $$ = nterm exp (13.2-4: 4) +Entering state 12 +Stack now 0 6 4 12 +Next token is token ')' (13.5: ) +Shifting token ')' (13.5: ) +LAC: initial context discarded due to shift +Entering state 26 +Stack now 0 6 4 12 26 +Reducing stack by rule 13 (line 117): + $1 = token '(' (13.1: ) + $2 = nterm exp (13.2-4: 4) + $3 = token ')' (13.5: ) +-> $$ = nterm exp (13.1-5: 4) +Entering state 8 +Stack now 0 6 8 +Reading a token +Next token is token '^' (13.6: ) +Shifting token '^' (13.6: ) +Entering state 23 +Stack now 0 6 8 23 +Reading a token +Next token is token number (13.7: 3) +Shifting token number (13.7: 3) +Entering state 1 +Stack now 0 6 8 23 1 +Reducing stack by rule 5 (line 92): + $1 = token number (13.7: 3) +-> $$ = nterm exp (13.7: 3) +Entering state 32 +Stack now 0 6 8 23 32 +Reading a token +Next token is token '=' (13.9: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R12 G8 S18 +Reducing stack by rule 12 (line 116): + $1 = nterm exp (13.1-5: 4) + $2 = token '^' (13.6: ) + $3 = nterm exp (13.7: 3) +-> $$ = nterm exp (13.1-7: 64) +Entering state 8 +Stack now 0 6 8 +Next token is token '=' (13.9: ) +Shifting token '=' (13.9: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 6 8 18 +Reading a token +Next token is token number (13.11-12: 64) +Shifting token number (13.11-12: 64) +Entering state 1 +Stack now 0 6 8 18 1 +Reducing stack by rule 5 (line 92): + $1 = token number (13.11-12: 64) +-> $$ = nterm exp (13.11-12: 64) +Entering state 27 +Stack now 0 6 8 18 27 +Reading a token +Next token is token '\n' (13.13-14.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R6 G8 S24 +Reducing stack by rule 6 (line 93): + $1 = nterm exp (13.1-7: 64) + $2 = token '=' (13.9: ) + $3 = nterm exp (13.11-12: 64) +-> $$ = nterm exp (13.1-12: 64) +Entering state 8 +Stack now 0 6 8 +Next token is token '\n' (13.13-14.0: ) +Shifting token '\n' (13.13-14.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 6 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (13.1-12: 64) + $2 = token '\n' (13.13-14.0: ) +-> $$ = nterm line (13.1-14.0: ) +Entering state 17 +Stack now 0 6 17 +Reducing stack by rule 2 (line 83): + $1 = nterm input (1.1-13.0: ) + $2 = nterm line (13.1-14.0: ) +-> $$ = nterm input (1.1-14.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of file (14.1: ) +Shifting token end of file (14.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of file (14.1: ) +Cleanup: popping nterm input (1.1-14.0: ) +./calc.at:1453: cat stderr +input: +1.1: syntax error +./calc.at:1455: $EGREP -c -v 'Return for a new token:|LAC:' stderr +input: + | 1//2 +./calc.at:1451: $PREPARSER ./calc input +input: +./calc.at:1448: cat stderr + | 1 = 2 = 3 +./calc.at:1457: $PREPARSER ./calc input +stderr: ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -157671,13 +160220,108 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.7: syntax error stderr: +stderr: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1454: $PREPARSER ./calc input input: -1.11: syntax error -1.1-16: error: 2222 != 1 -./calc.at:1446: cat stderr -./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.3: syntax error +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.1-2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.1-2: ) +Stack now 0 4 +Shifting token error (1.1-2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Error: popping token error (1.1-2: ) +Stack now 0 4 +Shifting token error (1.1-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token number (1.6: 1) +Error: discarding token number (1.6: 1) +Error: popping token error (1.1-4: ) +Stack now 0 4 +Shifting token error (1.1-6: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.1-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} @@ -157689,21 +160333,74 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (1 + 1) / (1 - 1) -stderr: -input: -./calc.at:1445: $PREPARSER ./calc input -1.11: syntax error -1.1-16: error: 2222 != 1 - | (1 + # + 1) = 1111 -input: -./calc.at:1443: $PREPARSER ./calc input - | (- *) + (1 2) = 1 - | (!!) + (1 2) = 1 -./calc.at:1446: $PREPARSER ./calc input +syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: $PREPARSER ./calc input -./calc.at:1451: cat stderr -./calc.at:1448: "$PERL" -pi -e 'use strict; +input: +stderr: +./calc.at:1446: cat stderr + | 1 2 +./calc.at:1455: $PREPARSER ./calc input +stderr: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1448: $PREPARSER ./calc input +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.1-46: error: 4444 != 1 +./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.1-46: error: 4444 != 1 +./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +stderr: +stderr: +1.3: syntax error +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 +./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token number (1.3: 2) +LAC: initial context established for number +LAC: checking lookahead number: Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: Err +LAC: checking lookahead '=': S18 +LAC: checking lookahead '-': S19 +LAC: checking lookahead '+': S20 +LAC: checking lookahead '*': S21 +LAC: checking lookahead '/': S22 +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token number (1.3: 2) +Stack now 0 +syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) +./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -157716,10 +160413,77 @@ stderr: stderr: ./calc.at:1449: cat stderr -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.12: syntax error, unexpected number -1.1-17: error: 2222 != 1 -./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.1-46: error: 4444 != 1 +input: +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.1-46: error: 4444 != 1 +stderr: +stderr: +./calc.at:1443: cat stderr +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 + | (!!) + (1 2) = 1 +./calc.at:1446: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token number (1.3: 2) +LAC: initial context established for number +LAC: checking lookahead number: Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: Err +LAC: checking lookahead '=': S18 +LAC: checking lookahead '-': S19 +LAC: checking lookahead '+': S20 +LAC: checking lookahead '*': S21 +LAC: checking lookahead '/': S22 +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token number (1.3: 2) +Stack now 0 +stderr: +./calc.at:1451: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1453: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Stack now 0 @@ -157860,151 +160624,197 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +input: +input: +./calc.at:1454: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1457: cat stderr +./calc.at:1453: cat stderr +./calc.at:1448: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 = 2 = 3 +./calc.at:1449: $PREPARSER ./calc input +./calc.at:1455: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (1 + # + 1) = 1111 +./calc.at:1443: $PREPARSER ./calc input +stderr: stderr: +./calc.at:1454: cat stderr +input: +./calc.at:1451: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Stack now 0 4 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 4 12 20 +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Stack now 0 4 5 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 4 12 20 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 -Stack now 0 4 12 20 29 +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 15 +Stack now 0 4 5 15 +Reducing stack by rule 16 (line 107): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Stack now 0 4 +Shifting token error (1.2-3: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token ')' () -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 -Stack now 0 4 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Stack now 0 4 12 26 -Reducing stack by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (2) - $3 = token ')' () --> $$ = nterm exp (2) +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Stack now 0 8 22 +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) +Entering state 20 +Stack now 0 8 20 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) Entering state 4 -Stack now 0 8 22 4 +Stack now 0 8 20 4 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token number (1.9: 1) +Shifting token number (1.9: 1) Entering state 1 -Stack now 0 8 22 4 1 +Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) + $1 = token number (1.9: 1) +-> $$ = nterm exp (1.9: 1) Entering state 12 -Stack now 0 8 22 4 12 +Stack now 0 8 20 4 12 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Stack now 0 8 22 4 12 19 +Next token is token number (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Stack now 0 8 20 4 +Shifting token error (1.9-11: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token number (1.11: 2) +Error: discarding token number (1.11: 2) +Error: popping token error (1.9-11: ) +Stack now 0 8 20 4 +Shifting token error (1.9-11: ) +Entering state 11 +Stack now 0 8 20 4 11 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '=' (1.14: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) Entering state 1 -Stack now 0 8 22 4 12 19 1 +Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 28 -Stack now 0 8 22 4 12 19 28 -Reading a token -Next token is token ')' () -Reducing stack by rule 8 (line 91): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (1) --> $$ = nterm exp (0) -Entering state 12 -Stack now 0 8 22 4 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Stack now 0 8 22 4 12 26 -Reducing stack by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (0) - $3 = token ')' () --> $$ = nterm exp (0) -Entering state 31 -Stack now 0 8 22 31 + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 27 +Stack now 0 8 18 27 Reading a token -Next token is token '\n' () -Reducing stack by rule 10 (line 93): - $1 = nterm exp (2) - $2 = token '/' () - $3 = nterm exp (0) -error: null divisor --> $$ = nterm exp (2) +Next token is token '\n' (1.17-2.0: ) +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' () -Shifting token '\n' () +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (2) - $2 = token '\n' () --> $$ = nterm line () + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 Reducing stack by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token end of input () -Shifting token end of input () +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +1.7: syntax error input: stderr: +./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | + | +1 + | (!!) + (1 2) = 1 Starting parse Entering state 0 Stack now 0 @@ -158120,20 +160930,60 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1457: $PREPARSER ./calc input +./calc.at:1448: cat stderr +./calc.at:1453: $PREPARSER ./calc input stderr: -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.12: syntax error, unexpected number -1.1-17: error: 2222 != 1 +stderr: +./calc.at:1455: cat stderr input: -./calc.at:1448: cat stderr -./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | - | +1 -./calc.at:1449: $PREPARSER ./calc input stderr: -./calc.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1//2 +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 +1.7: syntax error +./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (!!) + (1 2) = 1 +input: +./calc.at:1454: $PREPARSER ./calc input +syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | error ./calc.at:1451: $PREPARSER ./calc input +input: +stderr: +./calc.at:1446: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (!!) + (1 2) = 1 +./calc.at:1448: $PREPARSER ./calc input +stderr: +stderr: +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 +stderr: +1.1: syntax error +./calc.at:1449: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1446: cat stderr Starting parse Entering state 0 Stack now 0 @@ -158249,153 +161099,76 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 +stderr: +stderr: + | 1//2 +./calc.at:1455: $PREPARSER ./calc input +1.11: syntax error +1.1-16: error: 2222 != 1 +./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: stderr: -2.1: syntax error +1.1: syntax error +./calc.at:1443: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Stack now 0 4 12 20 -Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 4 12 20 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 -Stack now 0 4 12 20 29 -Reading a token -Next token is token ')' () -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 -Stack now 0 4 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Stack now 0 4 12 26 -Reducing stack by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (2) - $3 = token ')' () --> $$ = nterm exp (2) +Stack now 0 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Stack now 0 8 Reading a token -Next token is token '/' () -Shifting token '/' () +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) Entering state 22 Stack now 0 8 22 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Stack now 0 8 22 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 8 22 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Stack now 0 8 22 4 12 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Stack now 0 8 22 4 12 19 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Stack now 0 8 22 4 12 19 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 28 -Stack now 0 8 22 4 12 19 28 -Reading a token -Next token is token ')' () -Reducing stack by rule 8 (line 91): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (1) --> $$ = nterm exp (0) -Entering state 12 -Stack now 0 8 22 4 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Stack now 0 8 22 4 12 26 -Reducing stack by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (0) - $3 = token ')' () --> $$ = nterm exp (0) -Entering state 31 -Stack now 0 8 22 31 -Reading a token -Next token is token '\n' () -Reducing stack by rule 10 (line 93): - $1 = nterm exp (2) - $2 = token '/' () - $3 = nterm exp (0) -error: null divisor --> $$ = nterm exp (2) -Entering state 8 +Next token is token '/' (1.3: ) +LAC: initial context established for '/' +LAC: checking lookahead '/': Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': Err +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) Stack now 0 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (2) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of input () -Shifting token end of input () -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '/' (1.3: ) +Stack now 0 +1.11: syntax error, unexpected number +1.1-16: error: 2222 != 1 stderr: -./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -158406,9 +161179,47 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.3: syntax error -./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.11: syntax error +1.1-16: error: 2222 != 1 +./calc.at:1449: cat stderr +input: ./calc.at:1453: cat stderr + | (- *) + (1 2) = 1 +./calc.at:1446: $PREPARSER ./calc input +./calc.at:1443: cat stderr +stderr: +./calc.at:1451: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1454: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +./calc.at:1448: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Stack now 0 @@ -158418,121 +161229,129 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Stack now 0 4 5 +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Stack now 0 4 2 Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 15 -Stack now 0 4 5 15 -Reducing stack by rule 16 (line 107): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 106): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) Stack now 0 4 -Shifting token error (1.2-3: ) +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2-4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) Entering state 11 Stack now 0 4 11 Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) Entering state 25 Stack now 0 4 11 25 Reducing stack by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) Entering state 4 Stack now 0 8 20 4 Reading a token -Next token is token number (1.9: 1) -Shifting token number (1.9: 1) +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) Entering state 1 Stack now 0 8 20 4 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.9: 1) --> $$ = nterm exp (1.9: 1) + $1 = token number (1.10: 1) +-> $$ = nterm exp (1.10: 1) Entering state 12 Stack now 0 8 20 4 12 Reading a token -Next token is token number (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) +Next token is token number (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) Stack now 0 8 20 4 -Shifting token error (1.9-11: ) +Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 -Next token is token number (1.11: 2) -Error: discarding token number (1.11: 2) -Error: popping token error (1.9-11: ) +Next token is token number (1.12: 2) +Error: discarding token number (1.12: 2) +Error: popping token error (1.10-12: ) Stack now 0 8 20 4 -Shifting token error (1.9-11: ) +Shifting token error (1.10-12: ) Entering state 11 Stack now 0 8 20 4 11 Reading a token -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) Entering state 25 Stack now 0 8 20 4 11 25 Reducing stack by rule 14 (line 105): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) Entering state 29 Stack now 0 8 20 29 Reading a token -Next token is token '=' (1.14: ) +Next token is token '=' (1.15: ) Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) Entering state 8 Stack now 0 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) Entering state 18 Stack now 0 8 18 Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 79): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) + $1 = token number (1.17: 1) +-> $$ = nterm exp (1.17: 1) Entering state 27 Stack now 0 8 18 27 Reading a token -Next token is token '\n' (1.17-2.0: ) +Next token is token '\n' (1.18-2.0: ) Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -158549,55 +161368,69 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 22 +Stack now 0 8 22 +Reading a token +Next token is token '/' (1.3: ) +LAC: initial context established for '/' +LAC: checking lookahead '/': Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': Err +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '/' (1.3: ) +Stack now 0 input: + | + | +1 +./calc.at:1449: $PREPARSER ./calc input | (- *) + (1 2) = 1 -./calc.at:1448: $PREPARSER ./calc input -stderr: -2.1: syntax error -stderr: -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 -./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1457: cat stderr +./calc.at:1453: $PREPARSER ./calc input +./calc.at:1454: cat stderr +./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1446: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 stderr: -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 -./calc.at:1443: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.3: syntax error -./calc.at:1443: cat stderr input: -./calc.at:1448: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1445: "$PERL" -pi -e 'use strict; +./calc.at:1448: cat stderr +./calc.at:1451: cat stderr +./calc.at:1457: $PREPARSER ./calc /dev/null +2.1: syntax error +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.12: syntax error, unexpected number +1.1-17: error: 2222 != 1 +./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -158607,39 +161440,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (* *) + (*) + (*) -./calc.at:1453: $PREPARSER ./calc input -stderr: -./calc.at:1446: cat stderr -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1449: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1445: cat stderr -input: -./calc.at:1451: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +stderr: | (1 + 1) / (1 - 1) ./calc.at:1443: $PREPARSER ./calc input stderr: +stderr: +syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -158649,23 +161457,171 @@ Entering state 4 Stack now 0 4 Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Stack now 0 4 2 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 106): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2-4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) Entering state 20 -Stack now 0 4 12 20 +Stack now 0 8 20 Reading a token -Next token is token number (1.6: 1) -Shifting token number (1.6: 1) +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) +Entering state 1 +Stack now 0 8 20 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Stack now 0 8 20 4 12 +Reading a token +Next token is token number (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Stack now 0 8 20 4 +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token number (1.12: 2) +Error: discarding token number (1.12: 2) +Error: popping token error (1.10-12: ) +Stack now 0 8 20 4 +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 105): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '=' (1.15: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.17: 1) +-> $$ = nterm exp (1.17: 1) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 6 (line 80): + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Stack now 0 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Stack now 0 4 12 20 +Reading a token +Next token is token number (1.6: 1) +Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 Reducing stack by rule 5 (line 79): @@ -158781,20 +161737,63 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +input: stderr: -533. calc.at:1445: ok -./calc.at:1449: cat stderr -./calc.at:1448: cat stderr -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1455: cat stderr input: -./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +2.1: syntax error | (- *) + (1 2) = 1 +./calc.at:1454: $PREPARSER ./calc input +stderr: + | 1 = 2 = 3 +./calc.at:1451: $PREPARSER ./calc input +input: +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.12: syntax error, unexpected number +1.1-17: error: 2222 != 1 +stderr: + | (- *) + (1 2) = 1 +stderr: +stderr: +./calc.at:1443: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1448: $PREPARSER ./calc input +syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.12: syntax error, unexpected number +1.1-17: error: 2222 != 1 +./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +input: +1.7: syntax error +./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 +./calc.at:1449: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | error +./calc.at:1446: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1455: $PREPARSER ./calc input +stderr: stderr: -./calc.at:1446: $PREPARSER ./calc input -./calc.at:1451: cat stderr -./calc.at:1449: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Stack now 0 @@ -158936,178 +161935,32 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -input: stderr: -1.1: syntax error -stderr: - | (* *) + (*) + (*) -./calc.at:1453: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1448: $PREPARSER ./calc input - -./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Stack now 0 4 2 -Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 106): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2-4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token number (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Stack now 0 8 20 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token number (1.12: 2) -Error: discarding token number (1.12: 2) -Error: popping token error (1.10-12: ) -Stack now 0 8 20 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '=' (1.15: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.17: 1) --> $$ = nterm exp (1.17: 1) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -input: -1.2: syntax error -1.10: syntax error -1.16: syntax error -./calc.at:1443: "$PERL" -pi -e 'use strict; +Next token is token invalid token (1.1: ) +LAC: initial context established for invalid token +LAC: checking lookahead invalid token: Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': S3 +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) +Stack now 0 +./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -159117,23 +161970,22 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1453: cat stderr -stderr: - | error -stderr: -./calc.at:1451: $PREPARSER ./calc input -1.2: syntax error -1.10: syntax error -1.16: syntax error -./calc.at:1443: cat stderr -1.1: syntax error +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.12: syntax error, unexpected number +1.1-17: error: 2222 != 1 +./calc.at:1446: cat stderr +./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.7: syntax error stderr: -1.1: syntax error -./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 +./calc.at:1453: cat stderr +./calc.at:1457: cat stderr stderr: -./calc.at:1449: "$PERL" -pi -e 'use strict; +./calc.at:1449: cat stderr +input: +./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -159143,157 +161995,29 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -1.1: syntax error Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Stack now 0 4 2 -Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 106): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2-4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token number (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Stack now 0 8 20 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token number (1.12: 2) -Error: discarding token number (1.12: 2) -Error: popping token error (1.10-12: ) -Stack now 0 8 20 4 -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '=' (1.15: ) -Reducing stack by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 79): - $1 = token number (1.17: 1) --> $$ = nterm exp (1.17: 1) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 6 (line 80): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -532. calc.at:1443: input: +Next token is token invalid token (1.1: ) +LAC: initial context established for invalid token +LAC: checking lookahead invalid token: Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': S3 +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) +Stack now 0 ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -159304,17 +162028,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - ok - | 1 + 2 * 3 + !+ ++ -./calc.at:1453: $PREPARSER ./calc input -stderr: -./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -544. calc.at:1468: testing Calculator glr.cc ... -./calc.at:1449: cat stderr -./calc.at:1468: mv calc.y.tmp calc.y - -./calc.at:1468: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -./calc.at:1446: "$PERL" -pi -e 'use strict; +./calc.at:1443: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -159324,9 +162038,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -./calc.at:1453: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1451: "$PERL" -pi -e 'use strict; + | (* *) + (*) + (*) +input: +./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -159336,51 +162050,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1448: cat stderr -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1449: $PREPARSER ./calc input -./calc.at:1446: cat stderr -input: - | 1 + 2 * 3 + !- ++ -input: -./calc.at:1453: $PREPARSER ./calc input -./calc.at:1451: cat stderr -stderr: - | 1 + 2 * 3 + !+ ++ -stderr: -./calc.at:1448: $PREPARSER ./calc input -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 -./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | 1 = 2 = 3 -./calc.at:1451: $PREPARSER ./calc input -stderr: +./calc.at:1446: $PREPARSER ./calc input input: stderr: -stderr: -stderr: -1.7: syntax error +./calc.at:1443: cat stderr | (* *) + (*) + (*) -./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 -./calc.at:1446: $PREPARSER ./calc input -stderr: -1.7: syntax error -stderr: -./calc.at:1448: $EGREP -c -v 'Return for a new token:|LAC:' stderr - +./calc.at:1453: $PREPARSER ./calc input + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1449: $PREPARSER ./calc /dev/null +./calc.at:1457: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -159532,7 +162210,18 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1451: "$PERL" -pi -e 'use strict; +./calc.at:1454: cat stderr +stderr: +stderr: +stderr: +./calc.at:1451: cat stderr +syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +error: 4444 != 1 +1.1: syntax error +./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -159542,8 +162231,20 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1451: cat stderr +532. calc.at:1443: ./calc.at:1448: cat stderr + ok +stderr: +stderr: +stderr: +./calc.at:1455: cat stderr +input: stderr: Starting parse Entering state 0 @@ -159696,7 +162397,31 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1453: "$PERL" -pi -e 'use strict; +1.1: syntax error +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +error: 4444 != 1 +input: + | (* *) + (*) + (*) + | + | +1 +./calc.at:1454: $PREPARSER ./calc input +./calc.at:1451: $PREPARSER ./calc input +input: +stderr: +stderr: +input: +2.1: syntax error +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' + | (* *) + (*) + (*) +./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -159706,7 +162431,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1449: "$PERL" -pi -e 'use strict; +./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -159716,18 +162441,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -./calc.at:1468: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS - | 1 + 2 * 3 + !- ++ +./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1448: $PREPARSER ./calc input -input: -./calc.at:1453: cat stderr -stderr: - | - | +1 -./calc.at:1451: $PREPARSER ./calc input -./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1446: "$PERL" -pi -e 'use strict; + | 1 = 2 = 3 +./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1455: $PREPARSER ./calc input +./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -159739,33 +162458,139 @@ ' expout || exit 77 stderr: stderr: -input: -./calc.at:1449: cat stderr - | (#) + (#) = 2222 -2.1: syntax error -./calc.at:1453: $PREPARSER ./calc input -./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: + +1.2: syntax error +1.10: syntax error +1.16: syntax error stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: +./calc.at:1457: cat stderr ./calc.at:1446: cat stderr -./calc.at:1454: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '=' (1.7: ) +LAC: checking lookahead '=': Err +LAC: checking lookahead end of file: R6 G8 Err +LAC: checking lookahead number: R6 G8 Err +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S19 +LAC: checking lookahead '+': S20 +LAC: checking lookahead '*': S21 +LAC: checking lookahead '/': S22 +LAC: checking lookahead NEG: R6 G8 Err +LAC: checking lookahead '^': S23 +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 18 +Error: popping token '=' (1.3: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +2.1: syntax error +./calc.at:1453: cat stderr +stderr: input: stderr: -./calc.at:1448: "$PERL" -pi -e 'use strict; +1.2: syntax error +1.10: syntax error +1.16: syntax error +input: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '=' (1.7: ) +LAC: checking lookahead '=': Err +LAC: checking lookahead end of file: R6 G8 Err +LAC: checking lookahead number: R6 G8 Err +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S19 +LAC: checking lookahead '+': S20 +LAC: checking lookahead '*': S21 +LAC: checking lookahead '/': S22 +LAC: checking lookahead NEG: R6 G8 Err +LAC: checking lookahead '^': S23 +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Stack now 0 8 18 +Error: popping token '=' (1.3: ) +Stack now 0 8 +Error: popping nterm exp (1.1: 1) +Stack now 0 +Cleanup: discarding lookahead token '=' (1.7: ) +Stack now 0 + | (!!) + (1 2) = 1 +./calc.at:1457: $PREPARSER ./calc input +./calc.at:1454: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -159775,43 +162600,17 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (!!) + (1 2) = 1 -./calc.at:1449: $PREPARSER ./calc input -2.1: syntax error -stderr: -input: -stderr: -1.11: syntax error -1.1-16: error: 2222 != 1 - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1454: $PREPARSER ./calc input -stderr: -./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./calc.at:1449: cat stderr input: -545. calc.at:1469: testing Calculator glr2.cc ... -./calc.at:1469: mv calc.y.tmp calc.y - -./calc.at:1469: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' | 1 + 2 * 3 + !+ ++ ./calc.at:1446: $PREPARSER ./calc input -./calc.at:1454: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1451: "$PERL" -pi -e 'use strict; +syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +error: 2222 != 1 +./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 + !+ ++ +./calc.at:1453: $PREPARSER ./calc input +./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -159821,12 +162620,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1448: cat stderr stderr: stderr: -1.11: syntax error -1.1-16: error: 2222 != 1 -./calc.at:1453: "$PERL" -pi -e 'use strict; +./calc.at:1454: cat stderr +./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -159916,13 +162713,26 @@ Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) +stderr: +545. calc.at:1469: testing Calculator glr2.cc ... +input: +./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1469: mv calc.y.tmp calc.y + +syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +error: 2222 != 1 ./calc.at:1451: cat stderr + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1449: $PREPARSER ./calc input +./calc.at:1469: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | 1 2 +./calc.at:1455: cat stderr stderr: -./calc.at:1454: $PREPARSER ./calc input +stderr: +./calc.at:1453: $EGREP -c -v 'Return for a new token:|LAC:' stderr input: +./calc.at:1448: cat stderr +stderr: Starting parse Entering state 0 Stack now 0 @@ -160003,41 +162813,103 @@ Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1453: cat stderr ./calc.at:1446: $EGREP -c -v 'Return for a new token:|LAC:' stderr - | (#) + (#) = 2222 -./calc.at:1449: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1448: $PREPARSER ./calc input + | 1 + 2 * 3 + !+ ++ +./calc.at:1451: $PREPARSER ./calc /dev/null +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 +input: +./calc.at:1454: $PREPARSER ./calc input +./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: + | + | +1 +./calc.at:1455: $PREPARSER ./calc input stderr: -./calc.at:1451: $PREPARSER ./calc /dev/null -./calc.at:1469: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +1.1: syntax error +./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' stderr: -./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1457: cat stderr +input: +input: +stderr: +stderr: | 1 + 2 * 3 + !- ++ -1.3: syntax error, unexpected number + | 1 + 2 * 3 + !+ ++ +./calc.at:1453: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 87): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 82): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '+' (2.1: ) +LAC: initial context established for '+' +LAC: checking lookahead '+': Err +LAC: checking lookahead end of file: S16 +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': S3 +LAC: checking lookahead '(': S4 +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Stack now 0 +Cleanup: discarding lookahead token '+' (2.1: ) +Stack now 0 +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 +./calc.at:1448: $PREPARSER ./calc input +./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 1.1: syntax error + | 1 + 2 * 3 + !- ++ ./calc.at:1446: $PREPARSER ./calc input -input: -./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1449: cat stderr - | (1 + #) = 1111 -./calc.at:1453: $PREPARSER ./calc input stderr: -./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1454: $EGREP -c -v 'Return for a new token:|LAC:' stderr + | (- *) + (1 2) = 1 +./calc.at:1451: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Stack now 0 @@ -160118,17 +162990,80 @@ Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1449: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1457: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Stack now 0 3 +Reducing stack by rule 3 (line 87): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 82): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token '+' (2.1: ) +LAC: initial context established for '+' +LAC: checking lookahead '+': Err +LAC: checking lookahead end of file: S16 +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': S3 +LAC: checking lookahead '(': S4 +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Stack now 0 +Cleanup: discarding lookahead token '+' (2.1: ) +Stack now 0 stderr: -1.6: syntax error: invalid character: '#' -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1469: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +stderr: input: -1.3: syntax error, unexpected number +./calc.at:1448: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +error: 2222 != 1 +./calc.at:1455: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stdout: +./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: + | 1 + 2 * 3 + !- ++ Starting parse Entering state 0 Stack now 0 @@ -160209,9 +163144,20 @@ Stack now 0 8 20 Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) - | (- *) + (1 2) = 1 -./calc.at:1449: $PREPARSER ./calc input -./calc.at:1446: "$PERL" -pi -e 'use strict; +./calc.at:1454: $PREPARSER ./calc input +./calc.at:1458: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +./calc.at:1449: cat stderr +./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -160221,7 +163167,18 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1448: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1451: cat stderr +stderr: +./calc.at:1455: cat stderr +input: +./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +error: 2222 != 1 +input: +./calc.at:1453: cat stderr +./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -160231,44 +163188,111 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.1: syntax error +./calc.at:1455: $PREPARSER ./calc /dev/null + | 1 + 2 * 3 + !- ++ + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +input: +./calc.at:1458: $PREPARSER ./calc input +./calc.at:1448: $PREPARSER ./calc input +input: +stderr: stderr: +stderr: + | (!!) + (1 2) = 1 +./calc.at:1449: $PREPARSER ./calc input ./calc.at:1446: cat stderr -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token end of file (1.1: ) +LAC: initial context established for end of file +LAC: checking lookahead end of file: Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': S3 +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.1: syntax error, unexpected end of file +Cleanup: discarding lookahead token end of file (1.1: ) +Stack now 0 + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1451: $PREPARSER ./calc input +stderr: +./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.11: syntax error +1.1-16: error: 2222 != 1 +input: +stderr: +stderr: ./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1454: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 stderr: -./calc.at:1451: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: +stdout: +stderr: + | (#) + (#) = 2222 +./calc.at:1457: cat stderr +./calc.at:1453: $PREPARSER ./calc input +stdout: | (#) + (#) = 2222 ./calc.at:1446: $PREPARSER ./calc input -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 stderr: -./calc.at:1453: "$PERL" -pi -e 'use strict; +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 +stderr: +./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token end of file (1.1: ) +LAC: initial context established for end of file +LAC: checking lookahead end of file: Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': S3 +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.1: syntax error, unexpected end of file +Cleanup: discarding lookahead token end of file (1.1: ) +Stack now 0 +stderr: +./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -160278,8 +163302,33 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1448: cat stderr -./calc.at:1454: cat stderr +./calc.at:1468: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +./calc.at:1459: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +1.11: syntax error +1.1-16: error: 2222 != 1 +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 @@ -160403,9 +163452,48 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +stderr: +stderr: +./calc.at:1458: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1455: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1451: cat stderr +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +input: +input: +./calc.at:1453: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: +./calc.at:1454: cat stderr +./calc.at:1455: cat stderr +input: +./calc.at:1448: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -160416,6 +163504,58 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + | (* *) + (*) + (*) + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 +./calc.at:1459: $PREPARSER ./calc input +stderr: +input: +stderr: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1457: $PREPARSER ./calc input + | 1 2 +./calc.at:1468: $PREPARSER ./calc input +./calc.at:1458: $PREPARSER ./calc input +stderr: +./calc.at:1453: cat stderr +./calc.at:1451: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Stack now 0 @@ -160539,15 +163679,17 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +stderr: +./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: - | (1 + #) = 1111 -input: -./calc.at:1448: $PREPARSER ./calc input -./calc.at:1453: cat stderr - | 1//2 +1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) +./calc.at:1451: cat stderr input: -./calc.at:1454: $PREPARSER ./calc input -stderr: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} @@ -160559,71 +163701,893 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1451: $PREPARSER ./calc input +./calc.at:1455: $PREPARSER ./calc input +./calc.at:1448: cat stderr +./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1449: cat stderr -1.6: syntax error: invalid character: '#' -./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | (# + 1) = 1111 + | (#) + (#) = 2222 stderr: +input: +./calc.at:1454: $PREPARSER ./calc input + | (1 + #) = 1111 ./calc.at:1453: $PREPARSER ./calc input -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token ')' (1.2: ) +LAC: initial context established for ')' +LAC: checking lookahead ')': Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': Err +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +LAC: initial context discarded due to error recovery +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token number (1.7: 1) +Shifting token number (1.7: 1) +Entering state 1 +Stack now 0 8 20 4 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.7: 1) +-> $$ = nterm exp (1.7: 1) +Entering state 12 +Stack now 0 8 20 4 12 +Reading a token +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 20 +Stack now 0 8 20 4 12 20 +Reading a token +Next token is token number (1.11: 1) +Shifting token number (1.11: 1) +Entering state 1 +Stack now 0 8 20 4 12 20 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 29 +Stack now 0 8 20 4 12 20 29 +Reading a token +Next token is token '+' (1.13: ) +LAC: initial context established for '+' +LAC: checking lookahead '+': R7 G12 S20 +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Stack now 0 8 20 4 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +LAC: initial context discarded due to shift +Entering state 20 +Stack now 0 8 20 4 12 20 +Reading a token +Next token is token number (1.15: 1) +Shifting token number (1.15: 1) +Entering state 1 +Stack now 0 8 20 4 12 20 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 29 +Stack now 0 8 20 4 12 20 29 +Reading a token +Next token is token '+' (1.17: ) +LAC: initial context established for '+' +LAC: checking lookahead '+': R7 G12 S20 +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Stack now 0 8 20 4 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +LAC: initial context discarded due to shift +Entering state 20 +Stack now 0 8 20 4 12 20 +Reading a token +Next token is token ')' (1.18: ) +LAC: initial context established for ')' +LAC: checking lookahead ')': Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': Err +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Stack now 0 8 20 4 12 +Error: popping nterm exp (1.7-15: 3) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.7-18: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '+' (1.20: ) +LAC: initial context established for '+' +LAC: checking lookahead '+': R7 G8 S20 +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +LAC: initial context discarded due to shift +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token '*' (1.23: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': Err +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +LAC: initial context discarded due to error recovery +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' (1.23: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +Error: discarding token '*' (1.23: ) +Error: popping token error (1.23: ) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token '*' (1.25: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +Error: discarding token '*' (1.25: ) +Error: popping token error (1.23: ) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.23-25: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token '*' (1.27: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +Error: discarding token '*' (1.27: ) +Error: popping token error (1.23-25: ) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.23-27: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '+' (1.30: ) +LAC: initial context established for '+' +LAC: checking lookahead '+': R7 G8 S20 +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +LAC: initial context discarded due to shift +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token number (1.33: 1) +Shifting token number (1.33: 1) +Entering state 1 +Stack now 0 8 20 4 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 +Stack now 0 8 20 4 12 +Reading a token +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 21 +Stack now 0 8 20 4 12 21 +Reading a token +Next token is token number (1.37: 2) +Shifting token number (1.37: 2) +Entering state 1 +Stack now 0 8 20 4 12 21 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 30 +Stack now 0 8 20 4 12 21 30 +Reading a token +Next token is token '*' (1.39: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': R9 G12 S21 +Reducing stack by rule 9 (line 105): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Stack now 0 8 20 4 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +LAC: initial context discarded due to shift +Entering state 21 +Stack now 0 8 20 4 12 21 +Reading a token +Next token is token '*' (1.41: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': Err +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Stack now 0 8 20 4 12 +Error: popping nterm exp (1.33-37: 2) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' (1.41: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +Error: discarding token '*' (1.41: ) +Error: popping token error (1.33-41: ) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '=' (1.44: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R7 G8 S18 +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.46: 1) +Shifting token number (1.46: 1) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.46: 1) +-> $$ = nterm exp (1.46: 1) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' (1.47-2.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R6 G8 S24 +Reducing stack by rule 6 (line 93): + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 82): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of file (2.1: ) +Shifting token end of file (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1459: $EGREP -c -v 'Return for a new token:|LAC:' stderr +input: +./calc.at:1446: cat stderr + | (!!) + (1 2) = 1 stderr: -1.2: syntax error: invalid character: '#' +./calc.at:1451: $PREPARSER ./calc input +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +stderr: +1.6: syntax error: invalid character: '#' +1.11: syntax error +1.1-16: error: 2222 != 1 ./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1446: cat stderr input: +./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - | (* *) + (*) + (*) -./calc.at:1449: $PREPARSER ./calc input -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1454: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.2: syntax error -1.10: syntax error -1.16: syntax error -1.6: syntax error: invalid character: '#' -./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) 1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +input: +input: + | (#) + (#) = 2222 +./calc.at:1448: $PREPARSER ./calc input stderr: -./calc.at:1454: cat stderr -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error +input: +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token ')' (1.2: ) +LAC: initial context established for ')' +LAC: checking lookahead ')': Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': Err +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +LAC: initial context discarded due to error recovery +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token number (1.7: 1) +Shifting token number (1.7: 1) +Entering state 1 +Stack now 0 8 20 4 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.7: 1) +-> $$ = nterm exp (1.7: 1) +Entering state 12 +Stack now 0 8 20 4 12 +Reading a token +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 20 +Stack now 0 8 20 4 12 20 +Reading a token +Next token is token number (1.11: 1) +Shifting token number (1.11: 1) +Entering state 1 +Stack now 0 8 20 4 12 20 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 29 +Stack now 0 8 20 4 12 20 29 +Reading a token +Next token is token '+' (1.13: ) +LAC: initial context established for '+' +LAC: checking lookahead '+': R7 G12 S20 +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Stack now 0 8 20 4 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +LAC: initial context discarded due to shift +Entering state 20 +Stack now 0 8 20 4 12 20 +Reading a token +Next token is token number (1.15: 1) +Shifting token number (1.15: 1) +Entering state 1 +Stack now 0 8 20 4 12 20 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 29 +Stack now 0 8 20 4 12 20 29 +Reading a token +Next token is token '+' (1.17: ) +LAC: initial context established for '+' +LAC: checking lookahead '+': R7 G12 S20 +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Stack now 0 8 20 4 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +LAC: initial context discarded due to shift +Entering state 20 +Stack now 0 8 20 4 12 20 +Reading a token +Next token is token ')' (1.18: ) +LAC: initial context established for ')' +LAC: checking lookahead ')': Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': Err +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Stack now 0 8 20 4 12 +Error: popping nterm exp (1.7-15: 3) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.7-18: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '+' (1.20: ) +LAC: initial context established for '+' +LAC: checking lookahead '+': R7 G8 S20 +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +LAC: initial context discarded due to shift +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token '*' (1.23: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': Err +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +LAC: initial context discarded due to error recovery +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' (1.23: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +Error: discarding token '*' (1.23: ) +Error: popping token error (1.23: ) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.23: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token '*' (1.25: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +Error: discarding token '*' (1.25: ) +Error: popping token error (1.23: ) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.23-25: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token '*' (1.27: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +Error: discarding token '*' (1.27: ) +Error: popping token error (1.23-25: ) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.23-27: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '+' (1.30: ) +LAC: initial context established for '+' +LAC: checking lookahead '+': R7 G8 S20 +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +LAC: initial context discarded due to shift +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token number (1.33: 1) +Shifting token number (1.33: 1) +Entering state 1 +Stack now 0 8 20 4 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 +Stack now 0 8 20 4 12 +Reading a token +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 21 +Stack now 0 8 20 4 12 21 +Reading a token +Next token is token number (1.37: 2) +Shifting token number (1.37: 2) +Entering state 1 +Stack now 0 8 20 4 12 21 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 30 +Stack now 0 8 20 4 12 21 30 +Reading a token +Next token is token '*' (1.39: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': R9 G12 S21 +Reducing stack by rule 9 (line 105): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Stack now 0 8 20 4 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +LAC: initial context discarded due to shift +Entering state 21 +Stack now 0 8 20 4 12 21 +Reading a token +Next token is token '*' (1.41: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': Err +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Stack now 0 8 20 4 12 +Error: popping nterm exp (1.33-37: 2) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' (1.41: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +Error: discarding token '*' (1.41: ) +Error: popping token error (1.33-41: ) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.33-41: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '=' (1.44: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R7 G8 S18 +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.46: 1) +Shifting token number (1.46: 1) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.46: 1) +-> $$ = nterm exp (1.46: 1) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' (1.47-2.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R6 G8 S24 +Reducing stack by rule 6 (line 93): + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) 1.1-46: error: 4444 != 1 -./calc.at:1453: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +-> $$ = nterm exp (1.1-46: 4444) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 82): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of file (2.1: ) +Shifting token end of file (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: + | (1 + #) = 1111 stderr: +./calc.at:1446: $PREPARSER ./calc input + | (- *) + (1 2) = 1 +./calc.at:1449: $PREPARSER ./calc input + | 1 2 input: -./calc.at:1448: "$PERL" -pi -e 'use strict; +1.11: syntax error +1.1-16: error: 2222 != 1 +./calc.at:1459: $PREPARSER ./calc input +./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -160633,21 +164597,24 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.2: syntax error -1.10: syntax error -1.16: syntax error -./calc.at:1453: cat stderr -input: - | error - | (1 + #) = 1111 -./calc.at:1454: $PREPARSER ./calc input stderr: -1.1: syntax error, unexpected invalid token -./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1446: $PREPARSER ./calc input stderr: +1.6: syntax error: invalid character: '#' +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1458: cat stderr +stderr: + | 1 2 +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 +./calc.at:1468: $PREPARSER ./calc input +./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1454: cat stderr +./calc.at:1457: cat stderr +1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) stderr: -input: Starting parse Entering state 0 Stack now 0 @@ -160747,6 +164714,8 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +stderr: +syntax error ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -160757,17 +164726,50 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (1 + # + 1) = 1111 -./calc.at:1453: $PREPARSER ./calc input +./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1453: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.1: syntax error, unexpected invalid token +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1455: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +input: +input: +input: stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1448: cat stderr stderr: +./calc.at:1453: cat stderr + | (1 + #) = 1111 + | 1 + 2 * 3 + !+ ++ +./calc.at:1454: $PREPARSER ./calc input +stderr: + | 1//2 +1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) +./calc.at:1457: $PREPARSER ./calc input +./calc.at:1458: $PREPARSER ./calc input +./calc.at:1455: cat stderr Starting parse Entering state 0 Stack now 0 @@ -160867,6 +164869,10 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +syntax error +stderr: +stderr: +stderr: ./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -160877,8 +164883,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +1.6: syntax error: invalid character: '#' ./calc.at:1451: cat stderr -./calc.at:1454: "$PERL" -pi -e 'use strict; +./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) +./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -160889,21 +164899,12 @@ }eg ' expout || exit 77 input: - | (# + 1) = 1111 -./calc.at:1448: $PREPARSER ./calc input -./calc.at:1454: cat stderr -stderr: -1.2: syntax error: invalid character: '#' -./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1449: cat stderr -input: stderr: +./calc.at:1459: cat stderr input: -1.2: syntax error: invalid character: '#' +./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 -./calc.at:1451: $PREPARSER ./calc input - | 1 = 2 = 3 -./calc.at:1453: "$PERL" -pi -e 'use strict; +./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -160913,17 +164914,199 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1454: $PREPARSER ./calc input + | (# + 1) = 1111 +1.6: syntax error: invalid character: '#' +./calc.at:1455: $PREPARSER ./calc input +./calc.at:1453: $PREPARSER ./calc input +input: stderr: stderr: -1.11: syntax error -1.1-16: error: 2222 != 1 -./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1453: cat stderr -1.11: syntax error +./calc.at:1449: cat stderr +stderr: +./calc.at:1457: $EGREP -c -v 'Return for a new token:|LAC:' stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Stack now 0 4 5 +Reading a token +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 15 +Stack now 0 4 5 15 +Reducing stack by rule 16 (line 120): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Stack now 0 4 +Shifting token error (1.2-3: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token number (1.9: 1) +Shifting token number (1.9: 1) +Entering state 1 +Stack now 0 8 20 4 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.9: 1) +-> $$ = nterm exp (1.9: 1) +Entering state 12 +Stack now 0 8 20 4 12 +Reading a token +Next token is token number (1.11: 2) +LAC: initial context established for number +LAC: checking lookahead number: Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: Err +LAC: checking lookahead '=': S18 +LAC: checking lookahead '-': S19 +LAC: checking lookahead '+': S20 +LAC: checking lookahead '*': S21 +LAC: checking lookahead '/': S22 +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.9-11: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token number (1.11: 2) +LAC: initial context established for number +LAC: checking lookahead number: Err +Error: discarding token number (1.11: 2) +Error: popping token error (1.9-11: ) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.9-11: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '=' (1.14: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R7 G8 S18 +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' (1.17-2.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R6 G8 S24 +Reducing stack by rule 6 (line 93): + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) 1.1-16: error: 2222 != 1 -./calc.at:1448: "$PERL" -pi -e 'use strict; +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 82): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of file (2.1: ) +Shifting token end of file (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +input: +1.2: syntax error: invalid character: '#' +./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1468: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) +./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1//2 +./calc.at:1446: cat stderr + | (- *) + (1 2) = 1 +./calc.at:1459: $PREPARSER ./calc input +./calc.at:1448: cat stderr +./calc.at:1451: $PREPARSER ./calc input +stderr: +./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -160934,26 +165117,198 @@ }eg ' expout || exit 77 stderr: -1.7: syntax error, unexpected '=' +stderr: +stderr: input: -./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: +1.2: syntax error: invalid character: '#' +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 +./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Stack now 0 4 5 +Reading a token +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 15 +Stack now 0 4 5 15 +Reducing stack by rule 16 (line 120): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Stack now 0 4 +Shifting token error (1.2-3: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token number (1.9: 1) +Shifting token number (1.9: 1) +Entering state 1 +Stack now 0 8 20 4 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.9: 1) +-> $$ = nterm exp (1.9: 1) +Entering state 12 +Stack now 0 8 20 4 12 +Reading a token +Next token is token number (1.11: 2) +LAC: initial context established for number +LAC: checking lookahead number: Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: Err +LAC: checking lookahead '=': S18 +LAC: checking lookahead '-': S19 +LAC: checking lookahead '+': S20 +LAC: checking lookahead '*': S21 +LAC: checking lookahead '/': S22 +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.9-11: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token number (1.11: 2) +LAC: initial context established for number +LAC: checking lookahead number: Err +Error: discarding token number (1.11: 2) +Error: popping token error (1.9-11: ) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.9-11: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '=' (1.14: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R7 G8 S18 +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' (1.17-2.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R6 G8 S24 +Reducing stack by rule 6 (line 93): + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 82): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of file (2.1: ) +Shifting token end of file (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) + | (* *) + (*) + (*) input: -./calc.at:1457: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - - | 1 + 2 * 3 + !+ ++ +./calc.at:1454: cat stderr ./calc.at:1449: $PREPARSER ./calc input +input: +./calc.at:1468: cat stderr +./calc.at:1458: cat stderr +input: +./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + #) = 1111 +./calc.at:1448: $PREPARSER ./calc input stderr: -./calc.at:1446: "$PERL" -pi -e 'use strict; + | 1 + 2 * 3 + !- ++ + | (# + 1) = 1111 +stderr: +stderr: +1.2: syntax error +1.10: syntax error +1.16: syntax error +./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1446: $PREPARSER ./calc input +./calc.at:1457: $PREPARSER ./calc input +stderr: +./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -160963,26 +165318,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 +1.6: syntax error: invalid character: '#' +./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1457: $PREPARSER ./calc input -./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - | (1 + 1) / (1 - 1) -./calc.at:1453: $PREPARSER ./calc input -./calc.at:1451: "$PERL" -pi -e 'use strict; +1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) +./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -160992,26 +165336,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1446: cat stderr -stderr: -stderr: -1.7: syntax error, unexpected '=' -./calc.at:1449: $EGREP -c -v 'Return for a new token:|LAC:' stderr -input: -./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.11-17: error: null divisor -./calc.at:1451: cat stderr | (# + 1) = 1111 -./calc.at:1446: $PREPARSER ./calc input -./calc.at:1448: cat stderr -stderr: -./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -./calc.at:1457: $EGREP -c -v 'Return for a new token:|LAC:' stderr stderr: -1.11-17: error: null divisor stderr: +./calc.at:1454: $PREPARSER ./calc input +input: + | error +./calc.at:1458: $PREPARSER ./calc input Starting parse Entering state 0 Stack now 0 @@ -161108,13 +165440,37 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1453: cat stderr +stderr: +1.2: syntax error +1.10: syntax error +1.16: syntax error +./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: + | 1//2 +1.2: syntax error: invalid character: '#' +./calc.at:1468: $PREPARSER ./calc input +./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1455: cat stderr +stderr: +1.6: syntax error: invalid character: '#' +./calc.at:1451: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (1 + # + 1) = 1111 -./calc.at:1448: $PREPARSER ./calc input -input: +./calc.at:1459: cat stderr +1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) stderr: - | 1 + 2 * 3 + !- ++ -./calc.at:1454: "$PERL" -pi -e 'use strict; +stderr: +input: +./calc.at:1449: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -161124,6 +165480,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +stderr: + | (1 + # + 1) = 1111 +stderr: +./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1453: $PREPARSER ./calc input +input: Starting parse Entering state 0 Stack now 0 @@ -161220,22 +165584,7 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1449: $PREPARSER ./calc input -input: - | 1 2 -input: -stderr: -./calc.at:1457: $PREPARSER ./calc input -stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (- *) + (1 2) = 1 -./calc.at:1451: $PREPARSER ./calc input -stderr: -./calc.at:1454: cat stderr -1.6: syntax error: invalid character: '#' -./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1446: "$PERL" -pi -e 'use strict; +./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -161245,8 +165594,210 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +1.2: syntax error: invalid character: '#' stderr: -./calc.at:1453: "$PERL" -pi -e 'use strict; +stderr: + | (- *) + (1 2) = 1 +stderr: +./calc.at:1455: $PREPARSER ./calc input +1.6: syntax error: invalid character: '#' +./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) +syntax error +input: +stderr: +./calc.at:1451: cat stderr + | error +./calc.at:1459: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Stack now 0 4 2 +Reading a token +Next token is token '*' (1.4: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': Err +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +LAC: initial context discarded due to error recovery +Shifting token error (1.4: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 119): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.4: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2-4: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) +Entering state 1 +Stack now 0 8 20 4 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Stack now 0 8 20 4 12 +Reading a token +Next token is token number (1.12: 2) +LAC: initial context established for number +LAC: checking lookahead number: Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: Err +LAC: checking lookahead '=': S18 +LAC: checking lookahead '-': S19 +LAC: checking lookahead '+': S20 +LAC: checking lookahead '*': S21 +LAC: checking lookahead '/': S22 +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token number (1.12: 2) +LAC: initial context established for number +LAC: checking lookahead number: Err +Error: discarding token number (1.12: 2) +Error: popping token error (1.10-12: ) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '=' (1.15: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R7 G8 S18 +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.17: 1) +-> $$ = nterm exp (1.17: 1) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' (1.18-2.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R6 G8 S24 +Reducing stack by rule 6 (line 93): + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 82): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of file (2.1: ) +Shifting token end of file (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1449: cat stderr +./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -161256,12 +165807,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 -input: -./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1448: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -161271,35 +165818,205 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | - | +1 -./calc.at:1454: $PREPARSER ./calc input -stderr: +./calc.at:1448: cat stderr stderr: -syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) +1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) +1.6: syntax error: invalid character: '#' +./calc.at:1457: cat stderr +./calc.at:1458: cat stderr stderr: -./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1446: cat stderr -./calc.at:1453: cat stderr -1.4: syntax error -1.12: syntax error +./calc.at:1454: cat stderr +input: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Stack now 0 4 2 +Reading a token +Next token is token '*' (1.4: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': Err +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +LAC: initial context discarded due to error recovery +Shifting token error (1.4: ) +Entering state 9 +Stack now 0 4 2 9 +Reducing stack by rule 15 (line 119): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Stack now 0 4 +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.4: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2-4: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) +Entering state 1 +Stack now 0 8 20 4 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Stack now 0 8 20 4 12 +Reading a token +Next token is token number (1.12: 2) +LAC: initial context established for number +LAC: checking lookahead number: Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: Err +LAC: checking lookahead '=': S18 +LAC: checking lookahead '-': S19 +LAC: checking lookahead '+': S20 +LAC: checking lookahead '*': S21 +LAC: checking lookahead '/': S22 +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token number (1.12: 2) +LAC: initial context established for number +LAC: checking lookahead number: Err +Error: discarding token number (1.12: 2) +Error: popping token error (1.10-12: ) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.10-12: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '=' (1.15: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R7 G8 S18 +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) +LAC: initial context discarded due to shift +Entering state 18 +Stack now 0 8 18 +Reading a token +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) +Entering state 1 +Stack now 0 8 18 1 +Reducing stack by rule 5 (line 92): + $1 = token number (1.17: 1) +-> $$ = nterm exp (1.17: 1) +Entering state 27 +Stack now 0 8 18 27 +Reading a token +Next token is token '\n' (1.18-2.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R6 G8 S24 +Reducing stack by rule 6 (line 93): + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) 1.1-17: error: 2222 != 1 -./calc.at:1448: cat stderr -2.1: syntax error, unexpected '+' -stderr: -./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +-> $$ = nterm exp (1.1-17: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 82): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of file (2.1: ) +Shifting token end of file (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: - | (1 + 1) / (1 - 1) -./calc.at:1448: $PREPARSER ./calc input -stderr: -2.1: syntax error, unexpected '+' -stderr: -538. calc.at:1453: ok -stderr: -syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) -1.11-17: error: null divisor -./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1454: "$PERL" -pi -e 'use strict; +./calc.at:1446: cat stderr +./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -161309,8 +166026,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + | 1 + 2 * 3 + !+ ++ +./calc.at:1449: $PREPARSER ./calc input + | (* *) + (*) + (*) +./calc.at:1451: $PREPARSER ./calc input input: -./calc.at:1451: "$PERL" -pi -e 'use strict; +./calc.at:1453: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -161320,26 +166041,24 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - - | (1 + # + 1) = 1111 stderr: -./calc.at:1446: $PREPARSER ./calc input -stdout: +input: +input: stderr: -./calc.at:1457: cat stderr + | 1 = 2 = 3 + | (#) + (#) = 2222 +./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1458: $PREPARSER ./calc input stderr: -./calc.at:1458: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - -./calc.at:1449: "$PERL" -pi -e 'use strict; + | (# + 1) = 1111 +input: +./calc.at:1448: $PREPARSER ./calc input +stderr: +./calc.at:1457: $PREPARSER ./calc input + | (1 + # + 1) = 1111 +./calc.at:1446: $PREPARSER ./calc input +./calc.at:1455: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -161349,8 +166068,22 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.11-17: error: null divisor -./calc.at:1454: cat stderr +stderr: +1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1453: cat stderr +1.2: syntax error: invalid character: '#' + | (1 + # + 1) = 1111 +./calc.at:1454: $PREPARSER ./calc input +./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) +stderr: +1.2: syntax error +1.10: syntax error +1.16: syntax error +stderr: +./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1468: cat stderr +stderr: Starting parse Entering state 0 Stack now 0 @@ -161466,18 +166199,35 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1451: cat stderr -input: - | 1//2 -./calc.at:1457: $PREPARSER ./calc input +stderr: +./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1449: $EGREP -c -v 'Return for a new token:|LAC:' stderr +1.6: syntax error: invalid character: '#' +syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1455: cat stderr +stderr: ./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1454: $PREPARSER ./calc /dev/null stderr: +input: +stderr: +./calc.at:1459: cat stderr +1.2: syntax error +1.10: syntax error +1.16: syntax error +1.2: syntax error: invalid character: '#' +input: +stderr: +1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) stderr: stderr: -syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) -./calc.at:1449: cat stderr +1.6: syntax error: invalid character: '#' + | (1 + 1) / (1 - 1) input: +./calc.at:1453: $PREPARSER ./calc input + | error Starting parse Entering state 0 Stack now 0 @@ -161593,7 +166343,20 @@ Stack now 0 6 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1468: $PREPARSER ./calc input +syntax error: invalid character: '#' +syntax error: invalid character: '#' +input: + | 1 + 2 * 3 + !- ++ +stderr: +stderr: +./calc.at:1449: $PREPARSER ./calc input +syntax error + | (* *) + (*) + (*) +./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: +./calc.at:1455: $PREPARSER ./calc input +1.11-17: error: null divisor ./calc.at:1448: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -161604,41 +166367,229 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.1: syntax error, unexpected end of file -./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (* *) + (*) + (*) - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1458: $PREPARSER ./calc input -546. calc.at:1476: testing Calculator C++ %glr-parser ... -./calc.at:1451: $PREPARSER ./calc input -./calc.at:1476: mv calc.y.tmp calc.y - -stderr: -./calc.at:1476: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -stderr: -stderr: -1.1: syntax error, unexpected end of file +./calc.at:1458: cat stderr stderr: +./calc.at:1453: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) -input: -1.2: syntax error -1.10: syntax error -1.16: syntax error -./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 = 2 = 3 +./calc.at:1459: $PREPARSER ./calc input +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '*' (1.2: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': Err +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +LAC: initial context discarded due to error recovery +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.2: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +Error: discarding token '*' (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '*' (1.4: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token '*' (1.10: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': Err +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +LAC: initial context discarded due to error recovery +Shifting token error (1.10: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' (1.10: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +Error: discarding token '*' (1.10: ) +Error: popping token error (1.10: ) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.10: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '+' (1.13: ) +LAC: initial context established for '+' +LAC: checking lookahead '+': R7 G8 S20 +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) +Entering state 8 +Stack now 0 8 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +LAC: initial context discarded due to shift +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +Next token is token '*' (1.16: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': Err +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +LAC: initial context discarded due to error recovery +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' (1.16: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +Error: discarding token '*' (1.16: ) +Error: popping token error (1.16: ) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '\n' (1.18-2.0: ) +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R7 G8 S24 +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) +Entering state 8 +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +LAC: initial context discarded due to shift +Entering state 24 +Stack now 0 8 24 +Reducing stack by rule 4 (line 88): + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 82): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Stack now 0 6 +Reading a token +Next token is token end of file (2.1: ) +Shifting token end of file (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1446: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -161649,13 +166600,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stdout: -./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1448: cat stderr -1.2: syntax error -1.10: syntax error -1.16: syntax error ./calc.at:1454: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -161666,22 +166614,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (#) + (#) = 2222 -stderr: -./calc.at:1446: cat stderr -./calc.at:1449: $PREPARSER ./calc input -./calc.at:1455: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - -535. calc.at:1448: ok ./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -161692,127 +166624,223 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -input: -./calc.at:1458: $EGREP -c -v 'Return for a new token:|LAC:' stderr - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1455: $PREPARSER ./calc input -stderr: +syntax error +1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) stderr: - | (1 + 1) / (1 - 1) +input: ./calc.at:1454: cat stderr +./calc.at:1446: cat stderr +1.11-17: error: null divisor +stderr: ./calc.at:1457: cat stderr -./calc.at:1446: $PREPARSER ./calc input -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' +./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1448: cat stderr +stderr: + | + | +1 +./calc.at:1458: $PREPARSER ./calc input +./calc.at:1451: cat stderr Starting parse Entering state 0 Stack now 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token '*' (1.2: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': Err +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +LAC: initial context discarded due to error recovery +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token '*' (1.2: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +Error: discarding token '*' (1.2: ) +Error: popping token error (1.2: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token '*' (1.4: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +Error: discarding token '*' (1.4: ) +Error: popping token error (1.2: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.2-4: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Stack now 0 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) Entering state 20 Stack now 0 8 20 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 20 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 -Stack now 0 8 20 29 21 +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Stack now 0 8 20 4 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 20 29 21 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 -Stack now 0 8 20 29 21 30 +Next token is token '*' (1.10: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': Err +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +LAC: initial context discarded due to error recovery +Shifting token error (1.10: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' (1.10: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +Error: discarding token '*' (1.10: ) +Error: popping token error (1.10: ) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.10: ) +Entering state 11 +Stack now 0 8 20 4 11 Reading a token -Next token is token '=' (1.11: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R9 G29 R7 G8 S18 -Reducing stack by rule 9 (line 105): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) Entering state 29 Stack now 0 8 20 29 -Next token is token '=' (1.11: ) +Reading a token +Next token is token '+' (1.13: ) +LAC: initial context established for '+' +LAC: checking lookahead '+': R7 G8 S20 Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) Entering state 8 Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) LAC: initial context discarded due to shift -Entering state 18 -Stack now 0 8 18 +Entering state 20 +Stack now 0 8 20 Reading a token -Next token is token number (1.13: 7) -Shifting token number (1.13: 7) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.13: 7) --> $$ = nterm exp (1.13: 7) -Entering state 27 -Stack now 0 8 18 27 +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 +Stack now 0 8 20 4 Reading a token -Next token is token '\n' (1.14-2.0: ) +Next token is token '*' (1.16: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +LAC: checking lookahead end of file: Err +LAC: checking lookahead number: S1 +LAC: checking lookahead '=': Err +LAC: checking lookahead '-': S2 +LAC: checking lookahead '+': Err +LAC: checking lookahead '*': Err +LAC: checking lookahead '/': Err +LAC: checking lookahead NEG: Err +LAC: checking lookahead '^': Err +LAC: checking lookahead '\n': Err +LAC: checking lookahead '(': S4 +LAC: checking lookahead ')': Err +LAC: checking lookahead '!': S5 +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +LAC: initial context discarded due to error recovery +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token '*' (1.16: ) +LAC: initial context established for '*' +LAC: checking lookahead '*': Err +Error: discarding token '*' (1.16: ) +Error: popping token error (1.16: ) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.16: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '\n' (1.18-2.0: ) LAC: initial context established for '\n' -LAC: checking lookahead '\n': R6 G8 S24 -Reducing stack by rule 6 (line 93): - $1 = nterm exp (1.1-9: 7) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13: 7) --> $$ = nterm exp (1.1-13: 7) +LAC: checking lookahead '\n': R7 G8 S24 +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.14-2.0: ) -Shifting token '\n' (1.14-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): - $1 = nterm exp (1.1-13: 7) - $2 = token '\n' (1.14-2.0: ) + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -161822,995 +166850,785 @@ Entering state 6 Stack now 0 6 Reading a token -Next token is token number (2.1: 1) -Shifting token number (2.1: 1) -Entering state 1 -Stack now 0 6 1 -Reducing stack by rule 5 (line 92): - $1 = token number (2.1: 1) --> $$ = nterm exp (2.1: 1) -Entering state 8 -Stack now 0 6 8 -Reading a token -Next token is token '+' (2.3: ) -Shifting token '+' (2.3: ) -Entering state 20 -Stack now 0 6 8 20 +Next token is token end of file (2.1: ) +Shifting token end of file (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: +stderr: +2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) +1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) +input: + | (1 + 1) / (1 - 1) +input: +./calc.at:1468: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1454: $PREPARSER ./calc input +input: +input: +./calc.at:1453: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (1 + 1) / (1 - 1) +./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: + | (1 + # + 1) = 1111 + | (1 + #) = 1111 +./calc.at:1449: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1446: $PREPARSER ./calc input +./calc.at:1448: $PREPARSER ./calc input +./calc.at:1457: $PREPARSER ./calc input +1.11-17: error: null divisor +input: +./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: + | 1 + 2 * 3 + !+ ++ +./calc.at:1459: cat stderr +./calc.at:1455: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1451: $PREPARSER ./calc input +stderr: +stderr: +stderr: +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token number (2.5: 2) -Shifting token number (2.5: 2) -Entering state 1 -Stack now 0 6 8 20 1 -Reducing stack by rule 5 (line 92): - $1 = token number (2.5: 2) --> $$ = nterm exp (2.5: 2) -Entering state 29 -Stack now 0 6 8 20 29 -Reading a token -Next token is token '*' (2.7: ) -Shifting token '*' (2.7: ) -Entering state 21 -Stack now 0 6 8 20 29 21 -Reading a token -Next token is token '-' (2.9: ) -Shifting token '-' (2.9: ) -Entering state 2 -Stack now 0 6 8 20 29 21 2 -Reading a token -Next token is token number (2.10: 3) -Shifting token number (2.10: 3) -Entering state 1 -Stack now 0 6 8 20 29 21 2 1 -Reducing stack by rule 5 (line 92): - $1 = token number (2.10: 3) --> $$ = nterm exp (2.10: 3) -Entering state 10 -Stack now 0 6 8 20 29 21 2 10 -Reading a token -Next token is token '=' (2.12: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R11 G30 R9 G29 R7 G8 S18 -Reducing stack by rule 11 (line 115): - $1 = token '-' (2.9: ) - $2 = nterm exp (2.10: 3) --> $$ = nterm exp (2.9-10: -3) -Entering state 30 -Stack now 0 6 8 20 29 21 30 -Next token is token '=' (2.12: ) -Reducing stack by rule 9 (line 105): - $1 = nterm exp (2.5: 2) - $2 = token '*' (2.7: ) - $3 = nterm exp (2.9-10: -3) --> $$ = nterm exp (2.5-10: -6) -Entering state 29 -Stack now 0 6 8 20 29 -Next token is token '=' (2.12: ) -Reducing stack by rule 7 (line 103): - $1 = nterm exp (2.1: 1) - $2 = token '+' (2.3: ) - $3 = nterm exp (2.5-10: -6) --> $$ = nterm exp (2.1-10: -5) -Entering state 8 -Stack now 0 6 8 -Next token is token '=' (2.12: ) -Shifting token '=' (2.12: ) -LAC: initial context discarded due to shift -Entering state 18 -Stack now 0 6 8 18 -Reading a token -Next token is token '-' (2.14: ) -Shifting token '-' (2.14: ) -Entering state 2 -Stack now 0 6 8 18 2 -Reading a token -Next token is token number (2.15: 5) -Shifting token number (2.15: 5) -Entering state 1 -Stack now 0 6 8 18 2 1 -Reducing stack by rule 5 (line 92): - $1 = token number (2.15: 5) --> $$ = nterm exp (2.15: 5) -Entering state 10 -Stack now 0 6 8 18 2 10 -Reading a token -Next token is token '\n' (2.16-3.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R11 G27 R6 G8 S24 -Reducing stack by rule 11 (line 115): - $1 = token '-' (2.14: ) - $2 = nterm exp (2.15: 5) --> $$ = nterm exp (2.14-15: -5) -Entering state 27 -Stack now 0 6 8 18 27 -Next token is token '\n' (2.16-3.0: ) -Reducing stack by rule 6 (line 93): - $1 = nterm exp (2.1-10: -5) - $2 = token '=' (2.12: ) - $3 = nterm exp (2.14-15: -5) --> $$ = nterm exp (2.1-15: -5) -Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (2.16-3.0: ) -Shifting token '\n' (2.16-3.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 6 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (2.1-15: -5) - $2 = token '\n' (2.16-3.0: ) --> $$ = nterm line (2.1-3.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-2.0: ) - $2 = nterm line (2.1-3.0: ) --> $$ = nterm input (1.1-3.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '\n' (3.1-4.0: ) -Shifting token '\n' (3.1-4.0: ) -Entering state 3 -Stack now 0 6 3 -Reducing stack by rule 3 (line 87): - $1 = token '\n' (3.1-4.0: ) --> $$ = nterm line (3.1-4.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-3.0: ) - $2 = nterm line (3.1-4.0: ) --> $$ = nterm input (1.1-4.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '-' (4.1: ) -Shifting token '-' (4.1: ) -Entering state 2 -Stack now 0 6 2 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 Reading a token -Next token is token number (4.2: 1) -Shifting token number (4.2: 1) +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 -Stack now 0 6 2 1 -Reducing stack by rule 5 (line 92): - $1 = token number (4.2: 1) --> $$ = nterm exp (4.2: 1) -Entering state 10 -Stack now 0 6 2 10 +Stack now 0 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 Reading a token -Next token is token '^' (4.3: ) -Shifting token '^' (4.3: ) -Entering state 23 -Stack now 0 6 2 10 23 +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Stack now 0 4 12 20 Reading a token -Next token is token number (4.4: 2) -Shifting token number (4.4: 2) +Next token is token number (1.6: 1) +Shifting token number (1.6: 1) Entering state 1 -Stack now 0 6 2 10 23 1 -Reducing stack by rule 5 (line 92): - $1 = token number (4.4: 2) --> $$ = nterm exp (4.4: 2) -Entering state 32 -Stack now 0 6 2 10 23 32 +Stack now 0 4 12 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 29 +Stack now 0 4 12 20 29 Reading a token -Next token is token '=' (4.6: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R12 G10 R11 G8 S18 -Reducing stack by rule 12 (line 116): - $1 = nterm exp (4.2: 1) - $2 = token '^' (4.3: ) - $3 = nterm exp (4.4: 2) --> $$ = nterm exp (4.2-4: 1) -Entering state 10 -Stack now 0 6 2 10 -Next token is token '=' (4.6: ) -Reducing stack by rule 11 (line 115): - $1 = token '-' (4.1: ) - $2 = nterm exp (4.2-4: 1) --> $$ = nterm exp (4.1-4: -1) +Next token is token ')' (1.7: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Stack now 0 4 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Stack now 0 4 12 26 +Reducing stack by rule 13 (line 104): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (4.6: ) -Shifting token '=' (4.6: ) -LAC: initial context discarded due to shift -Entering state 18 -Stack now 0 6 8 18 -Reading a token -Next token is token '-' (4.8: ) -Shifting token '-' (4.8: ) -Entering state 2 -Stack now 0 6 8 18 2 -Reading a token -Next token is token number (4.9: 1) -Shifting token number (4.9: 1) -Entering state 1 -Stack now 0 6 8 18 2 1 -Reducing stack by rule 5 (line 92): - $1 = token number (4.9: 1) --> $$ = nterm exp (4.9: 1) -Entering state 10 -Stack now 0 6 8 18 2 10 +Stack now 0 8 Reading a token -Next token is token '\n' (4.10-5.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R11 G27 R6 G8 S24 -Reducing stack by rule 11 (line 115): - $1 = token '-' (4.8: ) - $2 = nterm exp (4.9: 1) --> $$ = nterm exp (4.8-9: -1) -Entering state 27 -Stack now 0 6 8 18 27 -Next token is token '\n' (4.10-5.0: ) -Reducing stack by rule 6 (line 93): - $1 = nterm exp (4.1-4: -1) - $2 = token '=' (4.6: ) - $3 = nterm exp (4.8-9: -1) --> $$ = nterm exp (4.1-9: -1) -Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (4.10-5.0: ) -Shifting token '\n' (4.10-5.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 6 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (4.1-9: -1) - $2 = token '\n' (4.10-5.0: ) --> $$ = nterm line (4.1-5.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-4.0: ) - $2 = nterm line (4.1-5.0: ) --> $$ = nterm input (1.1-5.0: ) -Entering state 6 -Stack now 0 6 +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 22 +Stack now 0 8 22 Reading a token -Next token is token '(' (5.1: ) -Shifting token '(' (5.1: ) +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) Entering state 4 -Stack now 0 6 4 -Reading a token -Next token is token '-' (5.2: ) -Shifting token '-' (5.2: ) -Entering state 2 -Stack now 0 6 4 2 +Stack now 0 8 22 4 Reading a token -Next token is token number (5.3: 1) -Shifting token number (5.3: 1) +Next token is token number (1.12: 1) +Shifting token number (1.12: 1) Entering state 1 -Stack now 0 6 4 2 1 -Reducing stack by rule 5 (line 92): - $1 = token number (5.3: 1) --> $$ = nterm exp (5.3: 1) -Entering state 10 -Stack now 0 6 4 2 10 -Reading a token -Next token is token ')' (5.4: ) -LAC: initial context established for ')' -LAC: checking lookahead ')': R11 G12 S26 -Reducing stack by rule 11 (line 115): - $1 = token '-' (5.2: ) - $2 = nterm exp (5.3: 1) --> $$ = nterm exp (5.2-3: -1) +Stack now 0 8 22 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.12: 1) +-> $$ = nterm exp (1.12: 1) Entering state 12 -Stack now 0 6 4 12 -Next token is token ')' (5.4: ) -Shifting token ')' (5.4: ) -LAC: initial context discarded due to shift -Entering state 26 -Stack now 0 6 4 12 26 -Reducing stack by rule 13 (line 117): - $1 = token '(' (5.1: ) - $2 = nterm exp (5.2-3: -1) - $3 = token ')' (5.4: ) --> $$ = nterm exp (5.1-4: -1) -Entering state 8 -Stack now 0 6 8 +Stack now 0 8 22 4 12 Reading a token -Next token is token '^' (5.5: ) -Shifting token '^' (5.5: ) -Entering state 23 -Stack now 0 6 8 23 +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 19 +Stack now 0 8 22 4 12 19 Reading a token -Next token is token number (5.6: 2) -Shifting token number (5.6: 2) +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) Entering state 1 -Stack now 0 6 8 23 1 -Reducing stack by rule 5 (line 92): - $1 = token number (5.6: 2) --> $$ = nterm exp (5.6: 2) -Entering state 32 -Stack now 0 6 8 23 32 -Reading a token -Next token is token '=' (5.8: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R12 G8 S18 -Reducing stack by rule 12 (line 116): - $1 = nterm exp (5.1-4: -1) - $2 = token '^' (5.5: ) - $3 = nterm exp (5.6: 2) --> $$ = nterm exp (5.1-6: 1) -Entering state 8 -Stack now 0 6 8 -Next token is token '=' (5.8: ) -Shifting token '=' (5.8: ) -LAC: initial context discarded due to shift -Entering state 18 -Stack now 0 6 8 18 +Stack now 0 8 22 4 12 19 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 +Stack now 0 8 22 4 12 19 28 Reading a token -Next token is token number (5.10: 1) -Shifting token number (5.10: 1) -Entering state 1 -Stack now 0 6 8 18 1 -Reducing stack by rule 5 (line 92): - $1 = token number (5.10: 1) --> $$ = nterm exp (5.10: 1) -Entering state 27 -Stack now 0 6 8 18 27 +Next token is token ')' (1.17: ) +Reducing stack by rule 8 (line 91): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Stack now 0 8 22 4 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Stack now 0 8 22 4 12 26 +Reducing stack by rule 13 (line 104): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 31 +Stack now 0 8 22 31 Reading a token -Next token is token '\n' (5.11-6.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R6 G8 S24 -Reducing stack by rule 6 (line 93): - $1 = nterm exp (5.1-6: 1) - $2 = token '=' (5.8: ) - $3 = nterm exp (5.10: 1) --> $$ = nterm exp (5.1-10: 1) +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 10 (line 93): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (5.11-6.0: ) -Shifting token '\n' (5.11-6.0: ) -LAC: initial context discarded due to shift +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 24 -Stack now 0 6 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (5.1-10: 1) - $2 = token '\n' (5.11-6.0: ) --> $$ = nterm line (5.1-6.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-5.0: ) - $2 = nterm line (5.1-6.0: ) --> $$ = nterm input (1.1-6.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '\n' (6.1-7.0: ) -Shifting token '\n' (6.1-7.0: ) -Entering state 3 -Stack now 0 6 3 -Reducing stack by rule 3 (line 87): - $1 = token '\n' (6.1-7.0: ) --> $$ = nterm line (6.1-7.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-6.0: ) - $2 = nterm line (6.1-7.0: ) --> $$ = nterm input (1.1-7.0: ) +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token '-' (7.1: ) -Shifting token '-' (7.1: ) -Entering state 2 -Stack now 0 6 2 -Reading a token -Next token is token '-' (7.2: ) -Shifting token '-' (7.2: ) -Entering state 2 -Stack now 0 6 2 2 +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +1.6: syntax error: invalid character: '#' +stderr: +./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error: invalid character: '#' +./calc.at:1453: cat stderr +./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1455: cat stderr +1.11-17: error: null divisor +./calc.at:1468: cat stderr +input: +./calc.at:1449: cat stderr +stderr: +stderr: +538. calc.at:1453: | + | +1 + ok +./calc.at:1459: $PREPARSER ./calc input +syntax error: invalid character: '#' +stderr: +1.6: syntax error: invalid character: '#' +stderr: +stderr: +./calc.at:1451: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1458: cat stderr +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token '-' (7.3: ) -Shifting token '-' (7.3: ) -Entering state 2 -Stack now 0 6 2 2 2 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 Reading a token -Next token is token number (7.4: 1) -Shifting token number (7.4: 1) +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 -Stack now 0 6 2 2 2 1 -Reducing stack by rule 5 (line 92): - $1 = token number (7.4: 1) --> $$ = nterm exp (7.4: 1) -Entering state 10 -Stack now 0 6 2 2 2 10 -Reading a token -Next token is token '=' (7.6: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R11 G10 R11 G10 R11 G8 S18 -Reducing stack by rule 11 (line 115): - $1 = token '-' (7.3: ) - $2 = nterm exp (7.4: 1) --> $$ = nterm exp (7.3-4: -1) -Entering state 10 -Stack now 0 6 2 2 10 -Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 115): - $1 = token '-' (7.2: ) - $2 = nterm exp (7.3-4: -1) --> $$ = nterm exp (7.2-4: 1) -Entering state 10 -Stack now 0 6 2 10 -Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 115): - $1 = token '-' (7.1: ) - $2 = nterm exp (7.2-4: 1) --> $$ = nterm exp (7.1-4: -1) -Entering state 8 -Stack now 0 6 8 -Next token is token '=' (7.6: ) -Shifting token '=' (7.6: ) -LAC: initial context discarded due to shift -Entering state 18 -Stack now 0 6 8 18 +Stack now 0 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 Reading a token -Next token is token '-' (7.8: ) -Shifting token '-' (7.8: ) -Entering state 2 -Stack now 0 6 8 18 2 +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Stack now 0 4 12 20 Reading a token -Next token is token number (7.9: 1) -Shifting token number (7.9: 1) +Next token is token number (1.6: 1) +Shifting token number (1.6: 1) Entering state 1 -Stack now 0 6 8 18 2 1 -Reducing stack by rule 5 (line 92): - $1 = token number (7.9: 1) --> $$ = nterm exp (7.9: 1) -Entering state 10 -Stack now 0 6 8 18 2 10 +Stack now 0 4 12 20 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 29 +Stack now 0 4 12 20 29 Reading a token -Next token is token '\n' (7.10-8.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R11 G27 R6 G8 S24 -Reducing stack by rule 11 (line 115): - $1 = token '-' (7.8: ) - $2 = nterm exp (7.9: 1) --> $$ = nterm exp (7.8-9: -1) -Entering state 27 -Stack now 0 6 8 18 27 -Next token is token '\n' (7.10-8.0: ) -Reducing stack by rule 6 (line 93): - $1 = nterm exp (7.1-4: -1) - $2 = token '=' (7.6: ) - $3 = nterm exp (7.8-9: -1) --> $$ = nterm exp (7.1-9: -1) +Next token is token ')' (1.7: ) +Reducing stack by rule 7 (line 90): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Stack now 0 4 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Stack now 0 4 12 26 +Reducing stack by rule 13 (line 104): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (7.10-8.0: ) -Shifting token '\n' (7.10-8.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 6 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (7.1-9: -1) - $2 = token '\n' (7.10-8.0: ) --> $$ = nterm line (7.1-8.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-7.0: ) - $2 = nterm line (7.1-8.0: ) --> $$ = nterm input (1.1-8.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '\n' (8.1-9.0: ) -Shifting token '\n' (8.1-9.0: ) -Entering state 3 -Stack now 0 6 3 -Reducing stack by rule 3 (line 87): - $1 = token '\n' (8.1-9.0: ) --> $$ = nterm line (8.1-9.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-8.0: ) - $2 = nterm line (8.1-9.0: ) --> $$ = nterm input (1.1-9.0: ) -Entering state 6 -Stack now 0 6 +Stack now 0 8 Reading a token -Next token is token number (9.1: 1) -Shifting token number (9.1: 1) -Entering state 1 -Stack now 0 6 1 -Reducing stack by rule 5 (line 92): - $1 = token number (9.1: 1) --> $$ = nterm exp (9.1: 1) -Entering state 8 -Stack now 0 6 8 +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 22 +Stack now 0 8 22 Reading a token -Next token is token '-' (9.3: ) -Shifting token '-' (9.3: ) -Entering state 19 -Stack now 0 6 8 19 +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Stack now 0 8 22 4 Reading a token -Next token is token number (9.5: 2) -Shifting token number (9.5: 2) +Next token is token number (1.12: 1) +Shifting token number (1.12: 1) Entering state 1 -Stack now 0 6 8 19 1 -Reducing stack by rule 5 (line 92): - $1 = token number (9.5: 2) --> $$ = nterm exp (9.5: 2) -Entering state 28 -Stack now 0 6 8 19 28 +Stack now 0 8 22 4 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Stack now 0 8 22 4 12 Reading a token -Next token is token '-' (9.7: ) -LAC: initial context established for '-' -LAC: checking lookahead '-': R8 G8 S19 -Reducing stack by rule 8 (line 104): - $1 = nterm exp (9.1: 1) - $2 = token '-' (9.3: ) - $3 = nterm exp (9.5: 2) --> $$ = nterm exp (9.1-5: -1) -Entering state 8 -Stack now 0 6 8 -Next token is token '-' (9.7: ) -Shifting token '-' (9.7: ) -LAC: initial context discarded due to shift +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) Entering state 19 -Stack now 0 6 8 19 +Stack now 0 8 22 4 12 19 Reading a token -Next token is token number (9.9: 3) -Shifting token number (9.9: 3) +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) Entering state 1 -Stack now 0 6 8 19 1 -Reducing stack by rule 5 (line 92): - $1 = token number (9.9: 3) --> $$ = nterm exp (9.9: 3) +Stack now 0 8 22 4 12 19 1 +Reducing stack by rule 5 (line 79): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) Entering state 28 -Stack now 0 6 8 19 28 -Reading a token -Next token is token '=' (9.11: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R8 G8 S18 -Reducing stack by rule 8 (line 104): - $1 = nterm exp (9.1-5: -1) - $2 = token '-' (9.7: ) - $3 = nterm exp (9.9: 3) --> $$ = nterm exp (9.1-9: -4) -Entering state 8 -Stack now 0 6 8 -Next token is token '=' (9.11: ) -Shifting token '=' (9.11: ) -LAC: initial context discarded due to shift -Entering state 18 -Stack now 0 6 8 18 -Reading a token -Next token is token '-' (9.13: ) -Shifting token '-' (9.13: ) -Entering state 2 -Stack now 0 6 8 18 2 +Stack now 0 8 22 4 12 19 28 Reading a token -Next token is token number (9.14: 4) -Shifting token number (9.14: 4) -Entering state 1 -Stack now 0 6 8 18 2 1 -Reducing stack by rule 5 (line 92): - $1 = token number (9.14: 4) --> $$ = nterm exp (9.14: 4) -Entering state 10 -Stack now 0 6 8 18 2 10 +Next token is token ')' (1.17: ) +Reducing stack by rule 8 (line 91): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Stack now 0 8 22 4 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Stack now 0 8 22 4 12 26 +Reducing stack by rule 13 (line 104): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 31 +Stack now 0 8 22 31 Reading a token -Next token is token '\n' (9.15-10.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R11 G27 R6 G8 S24 -Reducing stack by rule 11 (line 115): - $1 = token '-' (9.13: ) - $2 = nterm exp (9.14: 4) --> $$ = nterm exp (9.13-14: -4) -Entering state 27 -Stack now 0 6 8 18 27 -Next token is token '\n' (9.15-10.0: ) -Reducing stack by rule 6 (line 93): - $1 = nterm exp (9.1-9: -4) - $2 = token '=' (9.11: ) - $3 = nterm exp (9.13-14: -4) --> $$ = nterm exp (9.1-14: -4) +Next token is token '\n' (1.18-2.0: ) +Reducing stack by rule 10 (line 93): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (9.15-10.0: ) -Shifting token '\n' (9.15-10.0: ) -LAC: initial context discarded due to shift +Stack now 0 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 24 -Stack now 0 6 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (9.1-14: -4) - $2 = token '\n' (9.15-10.0: ) --> $$ = nterm line (9.1-10.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-9.0: ) - $2 = nterm line (9.1-10.0: ) --> $$ = nterm input (1.1-10.0: ) +Stack now 0 8 24 +Reducing stack by rule 4 (line 75): + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token number (10.1: 1) -Shifting token number (10.1: 1) +Next token is token end of input (2.1: ) +Shifting token end of input (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +input: +./calc.at:1454: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) +input: +input: + | (#) + (#) = 2222 +./calc.at:1449: $PREPARSER ./calc input + | 1 + 2 * 3 + !+ ++ + | 1 = 2 = 3 +./calc.at:1455: $PREPARSER ./calc input +./calc.at:1454: cat stderr +./calc.at:1458: $PREPARSER ./calc /dev/null +./calc.at:1468: $PREPARSER ./calc input +stderr: +./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1448: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +input: +stderr: +stderr: +./calc.at:1457: cat stderr +./calc.at:1446: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 6 1 +Stack now 0 1 Reducing stack by rule 5 (line 92): - $1 = token number (10.1: 1) --> $$ = nterm exp (10.1: 1) + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 -Stack now 0 6 8 -Reading a token -Next token is token '-' (10.3: ) -Shifting token '-' (10.3: ) -Entering state 19 -Stack now 0 6 8 19 +Stack now 0 8 Reading a token -Next token is token '(' (10.5: ) -Shifting token '(' (10.5: ) -Entering state 4 -Stack now 0 6 8 19 4 +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Stack now 0 8 20 Reading a token -Next token is token number (10.6: 2) -Shifting token number (10.6: 2) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 -Stack now 0 6 8 19 4 1 +Stack now 0 8 20 1 Reducing stack by rule 5 (line 92): - $1 = token number (10.6: 2) --> $$ = nterm exp (10.6: 2) -Entering state 12 -Stack now 0 6 8 19 4 12 + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 +Stack now 0 8 20 29 Reading a token -Next token is token '-' (10.8: ) -Shifting token '-' (10.8: ) -Entering state 19 -Stack now 0 6 8 19 4 12 19 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Stack now 0 8 20 29 21 Reading a token -Next token is token number (10.10: 3) -Shifting token number (10.10: 3) +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) Entering state 1 -Stack now 0 6 8 19 4 12 19 1 +Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 92): - $1 = token number (10.10: 3) --> $$ = nterm exp (10.10: 3) -Entering state 28 -Stack now 0 6 8 19 4 12 19 28 -Reading a token -Next token is token ')' (10.11: ) -LAC: initial context established for ')' -LAC: checking lookahead ')': R8 G12 S26 -Reducing stack by rule 8 (line 104): - $1 = nterm exp (10.6: 2) - $2 = token '-' (10.8: ) - $3 = nterm exp (10.10: 3) --> $$ = nterm exp (10.6-10: -1) -Entering state 12 -Stack now 0 6 8 19 4 12 -Next token is token ')' (10.11: ) -Shifting token ')' (10.11: ) -LAC: initial context discarded due to shift -Entering state 26 -Stack now 0 6 8 19 4 12 26 -Reducing stack by rule 13 (line 117): - $1 = token '(' (10.5: ) - $2 = nterm exp (10.6-10: -1) - $3 = token ')' (10.11: ) --> $$ = nterm exp (10.5-11: -1) -Entering state 28 -Stack now 0 6 8 19 28 + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Stack now 0 8 20 29 21 30 Reading a token -Next token is token '=' (10.13: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R8 G8 S18 -Reducing stack by rule 8 (line 104): - $1 = nterm exp (10.1: 1) - $2 = token '-' (10.3: ) - $3 = nterm exp (10.5-11: -1) --> $$ = nterm exp (10.1-11: 2) +Next token is token '+' (1.11: ) +LAC: initial context established for '+' +LAC: checking lookahead '+': R9 G29 R7 G8 S20 +Reducing stack by rule 9 (line 105): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Stack now 0 8 20 29 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (10.13: ) -Shifting token '=' (10.13: ) +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) LAC: initial context discarded due to shift -Entering state 18 -Stack now 0 6 8 18 -Reading a token -Next token is token number (10.15: 2) -Shifting token number (10.15: 2) -Entering state 1 -Stack now 0 6 8 18 1 -Reducing stack by rule 5 (line 92): - $1 = token number (10.15: 2) --> $$ = nterm exp (10.15: 2) -Entering state 27 -Stack now 0 6 8 18 27 +Entering state 20 +Stack now 0 8 20 Reading a token -Next token is token '\n' (10.16-11.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R6 G8 S24 -Reducing stack by rule 6 (line 93): - $1 = nterm exp (10.1-11: 2) - $2 = token '=' (10.13: ) - $3 = nterm exp (10.15: 2) --> $$ = nterm exp (10.1-15: 2) -Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (10.16-11.0: ) -Shifting token '\n' (10.16-11.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 6 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (10.1-15: 2) - $2 = token '\n' (10.16-11.0: ) --> $$ = nterm line (10.1-11.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-10.0: ) - $2 = nterm line (10.1-11.0: ) --> $$ = nterm input (1.1-11.0: ) -Entering state 6 -Stack now 0 6 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 20 5 Reading a token -Next token is token '\n' (11.1-12.0: ) -Shifting token '\n' (11.1-12.0: ) -Entering state 3 -Stack now 0 6 3 -Reducing stack by rule 3 (line 87): - $1 = token '\n' (11.1-12.0: ) --> $$ = nterm line (11.1-12.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-11.0: ) - $2 = nterm line (11.1-12.0: ) --> $$ = nterm input (1.1-12.0: ) -Entering state 6 -Stack now 0 6 +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Stack now 0 8 20 5 14 +Reducing stack by rule 17 (line 121): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Stack now 0 8 20 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 + !- ++ +./calc.at:1451: $PREPARSER ./calc input +539. calc.at:1454: ok +stderr: +syntax error +1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) +./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + +2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) +stderr: +input: +stderr: +./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1446: cat stderr +./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: + | (# + 1) = 1111 +./calc.at:1448: cat stderr +./calc.at:1457: $PREPARSER ./calc input +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +syntax error +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token number (12.1: 2) -Shifting token number (12.1: 2) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 6 1 +Stack now 0 1 Reducing stack by rule 5 (line 92): - $1 = token number (12.1: 2) --> $$ = nterm exp (12.1: 2) + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 -Stack now 0 6 8 -Reading a token -Next token is token '^' (12.2: ) -Shifting token '^' (12.2: ) -Entering state 23 -Stack now 0 6 8 23 -Reading a token -Next token is token number (12.3: 2) -Shifting token number (12.3: 2) -Entering state 1 -Stack now 0 6 8 23 1 -Reducing stack by rule 5 (line 92): - $1 = token number (12.3: 2) --> $$ = nterm exp (12.3: 2) -Entering state 32 -Stack now 0 6 8 23 32 +Stack now 0 8 Reading a token -Next token is token '^' (12.4: ) -Shifting token '^' (12.4: ) -Entering state 23 -Stack now 0 6 8 23 32 23 +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Stack now 0 8 20 Reading a token -Next token is token number (12.5: 3) -Shifting token number (12.5: 3) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 -Stack now 0 6 8 23 32 23 1 +Stack now 0 8 20 1 Reducing stack by rule 5 (line 92): - $1 = token number (12.5: 3) --> $$ = nterm exp (12.5: 3) -Entering state 32 -Stack now 0 6 8 23 32 23 32 + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 +Stack now 0 8 20 29 Reading a token -Next token is token '=' (12.7: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R12 G32 R12 G8 S18 -Reducing stack by rule 12 (line 116): - $1 = nterm exp (12.3: 2) - $2 = token '^' (12.4: ) - $3 = nterm exp (12.5: 3) --> $$ = nterm exp (12.3-5: 8) -Entering state 32 -Stack now 0 6 8 23 32 -Next token is token '=' (12.7: ) -Reducing stack by rule 12 (line 116): - $1 = nterm exp (12.1: 2) - $2 = token '^' (12.2: ) - $3 = nterm exp (12.3-5: 8) --> $$ = nterm exp (12.1-5: 256) -Entering state 8 -Stack now 0 6 8 -Next token is token '=' (12.7: ) -Shifting token '=' (12.7: ) -LAC: initial context discarded due to shift -Entering state 18 -Stack now 0 6 8 18 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Stack now 0 8 20 29 21 Reading a token -Next token is token number (12.9-11: 256) -Shifting token number (12.9-11: 256) +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) Entering state 1 -Stack now 0 6 8 18 1 +Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 92): - $1 = token number (12.9-11: 256) --> $$ = nterm exp (12.9-11: 256) -Entering state 27 -Stack now 0 6 8 18 27 + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Stack now 0 8 20 29 21 30 Reading a token -Next token is token '\n' (12.12-13.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R6 G8 S24 -Reducing stack by rule 6 (line 93): - $1 = nterm exp (12.1-5: 256) - $2 = token '=' (12.7: ) - $3 = nterm exp (12.9-11: 256) --> $$ = nterm exp (12.1-11: 256) +Next token is token '+' (1.11: ) +LAC: initial context established for '+' +LAC: checking lookahead '+': R9 G29 R7 G8 S20 +Reducing stack by rule 9 (line 105): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Stack now 0 8 20 29 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (12.12-13.0: ) -Shifting token '\n' (12.12-13.0: ) +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 6 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (12.1-11: 256) - $2 = token '\n' (12.12-13.0: ) --> $$ = nterm line (12.1-13.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-12.0: ) - $2 = nterm line (12.1-13.0: ) --> $$ = nterm input (1.1-13.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '(' (13.1: ) -Shifting token '(' (13.1: ) -Entering state 4 -Stack now 0 6 4 +Entering state 20 +Stack now 0 8 20 Reading a token -Next token is token number (13.2: 2) -Shifting token number (13.2: 2) -Entering state 1 -Stack now 0 6 4 1 -Reducing stack by rule 5 (line 92): - $1 = token number (13.2: 2) --> $$ = nterm exp (13.2: 2) -Entering state 12 -Stack now 0 6 4 12 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 20 5 Reading a token -Next token is token '^' (13.3: ) -Shifting token '^' (13.3: ) -Entering state 23 -Stack now 0 6 4 12 23 +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Stack now 0 8 20 5 14 +Reducing stack by rule 17 (line 121): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Stack now 0 8 20 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1455: $EGREP -c -v 'Return for a new token:|LAC:' stderr +stderr: +stderr: +stderr: +534. calc.at:1446: ok +./calc.at:1459: cat stderr +syntax error: invalid character: '#' +./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) +input: +stderr: +input: + + | 1 + 2 * 3 + !- ++ +./calc.at:1455: $PREPARSER ./calc input +syntax error: invalid character: '#' + | (1 + 1) / (1 - 1) +./calc.at:1449: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1459: $PREPARSER ./calc /dev/null +stderr: +./calc.at:1448: $PREPARSER ./calc input +546. calc.at:1476: testing Calculator C++ %glr-parser ... +./calc.at:1476: mv calc.y.tmp calc.y + +./calc.at:1468: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token number (13.4: 2) -Shifting token number (13.4: 2) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 -Stack now 0 6 4 12 23 1 +Stack now 0 1 Reducing stack by rule 5 (line 92): - $1 = token number (13.4: 2) --> $$ = nterm exp (13.4: 2) -Entering state 32 -Stack now 0 6 4 12 23 32 -Reading a token -Next token is token ')' (13.5: ) -LAC: initial context established for ')' -LAC: checking lookahead ')': R12 G12 S26 -Reducing stack by rule 12 (line 116): - $1 = nterm exp (13.2: 2) - $2 = token '^' (13.3: ) - $3 = nterm exp (13.4: 2) --> $$ = nterm exp (13.2-4: 4) -Entering state 12 -Stack now 0 6 4 12 -Next token is token ')' (13.5: ) -Shifting token ')' (13.5: ) -LAC: initial context discarded due to shift -Entering state 26 -Stack now 0 6 4 12 26 -Reducing stack by rule 13 (line 117): - $1 = token '(' (13.1: ) - $2 = nterm exp (13.2-4: 4) - $3 = token ')' (13.5: ) --> $$ = nterm exp (13.1-5: 4) + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 -Stack now 0 6 8 +Stack now 0 8 Reading a token -Next token is token '^' (13.6: ) -Shifting token '^' (13.6: ) -Entering state 23 -Stack now 0 6 8 23 +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Stack now 0 8 20 Reading a token -Next token is token number (13.7: 3) -Shifting token number (13.7: 3) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 -Stack now 0 6 8 23 1 +Stack now 0 8 20 1 Reducing stack by rule 5 (line 92): - $1 = token number (13.7: 3) --> $$ = nterm exp (13.7: 3) -Entering state 32 -Stack now 0 6 8 23 32 + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 +Stack now 0 8 20 29 Reading a token -Next token is token '=' (13.9: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R12 G8 S18 -Reducing stack by rule 12 (line 116): - $1 = nterm exp (13.1-5: 4) - $2 = token '^' (13.6: ) - $3 = nterm exp (13.7: 3) --> $$ = nterm exp (13.1-7: 64) -Entering state 8 -Stack now 0 6 8 -Next token is token '=' (13.9: ) -Shifting token '=' (13.9: ) -LAC: initial context discarded due to shift -Entering state 18 -Stack now 0 6 8 18 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Stack now 0 8 20 29 21 Reading a token -Next token is token number (13.11-12: 64) -Shifting token number (13.11-12: 64) +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) Entering state 1 -Stack now 0 6 8 18 1 +Stack now 0 8 20 29 21 1 Reducing stack by rule 5 (line 92): - $1 = token number (13.11-12: 64) --> $$ = nterm exp (13.11-12: 64) -Entering state 27 -Stack now 0 6 8 18 27 + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Stack now 0 8 20 29 21 30 Reading a token -Next token is token '\n' (13.13-14.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R6 G8 S24 -Reducing stack by rule 6 (line 93): - $1 = nterm exp (13.1-7: 64) - $2 = token '=' (13.9: ) - $3 = nterm exp (13.11-12: 64) --> $$ = nterm exp (13.1-12: 64) +Next token is token '+' (1.11: ) +LAC: initial context established for '+' +LAC: checking lookahead '+': R9 G29 R7 G8 S20 +Reducing stack by rule 9 (line 105): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Stack now 0 8 20 29 +Next token is token '+' (1.11: ) +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (13.13-14.0: ) -Shifting token '\n' (13.13-14.0: ) +Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 6 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (13.1-12: 64) - $2 = token '\n' (13.13-14.0: ) --> $$ = nterm line (13.1-14.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-13.0: ) - $2 = nterm line (13.1-14.0: ) --> $$ = nterm input (1.1-14.0: ) -Entering state 6 -Stack now 0 6 +Entering state 20 +Stack now 0 8 20 Reading a token -Next token is token end of file (14.1: ) -Shifting token end of file (14.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of file (14.1: ) -Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 20 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Stack now 0 8 20 5 13 +Reducing stack by rule 18 (line 122): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Stack now 0 8 20 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1458: cat stderr ./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - | 1 2 -./calc.at:1458: $PREPARSER ./calc input -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1451: cat stderr stderr: +./calc.at:1451: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) +1.11-17: error: null divisor +./calc.at:1448: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1476: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + stderr: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1449: cat stderr +./calc.at:1458: $PREPARSER ./calc input +./calc.at:1468: cat stderr Starting parse Entering state 0 Stack now 0 @@ -162855,9 +167673,9 @@ Entering state 30 Stack now 0 8 20 29 21 30 Reading a token -Next token is token '=' (1.11: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R9 G29 R7 G8 S18 +Next token is token '+' (1.11: ) +LAC: initial context established for '+' +LAC: checking lookahead '+': R9 G29 R7 G8 S20 Reducing stack by rule 9 (line 105): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) @@ -162865,7 +167683,7 @@ -> $$ = nterm exp (1.5-9: 6) Entering state 29 Stack now 0 8 20 29 -Next token is token '=' (1.11: ) +Next token is token '+' (1.11: ) Reducing stack by rule 7 (line 103): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) @@ -162873,40 +167691,230 @@ -> $$ = nterm exp (1.1-9: 7) Entering state 8 Stack now 0 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +LAC: initial context discarded due to shift +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Stack now 0 8 20 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Stack now 0 8 20 5 13 +Reducing stack by rule 18 (line 122): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Stack now 0 8 20 +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +stderr: +stderr: +./calc.at:1457: cat stderr +./calc.at:1451: cat stderr +stderr: +1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.1-46: error: 4444 != 1 +1.11-17: error: null divisor +1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) +547. calc.at:1476: testing Calculator glr2.cc ... +./calc.at:1476: mv calc.y.tmp calc.y + +input: +./calc.at:1455: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | + | +1 +./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1468: $PREPARSER ./calc input +./calc.at:1476: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +input: +input: +stderr: + | (1 + #) = 1111 + | (1 + # + 1) = 1111 +./calc.at:1449: $PREPARSER ./calc input +./calc.at:1457: $PREPARSER ./calc input +./calc.at:1448: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1459: cat stderr +./calc.at:1455: cat stderr + | (#) + (#) = 2222 +stderr: +./calc.at:1451: $PREPARSER ./calc input +syntax error +stderr: +./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.1-46: error: 4444 != 1 +stderr: +1.6: syntax error: invalid character: '#' +./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error: invalid character: '#' +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +548. calc.at:1477: testing Calculator C++ %glr-parser %locations ... +./calc.at:1477: mv calc.y.tmp calc.y + +input: +./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (#) + (#) = 2222 +./calc.at:1455: $PREPARSER ./calc input +./calc.at:1477: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +input: +./calc.at:1448: cat stderr +stderr: +stderr: +./calc.at:1458: cat stderr +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.1-2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +LAC: initial context established for invalid token +LAC: checking lookahead invalid token: Err +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.1-2: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.1-2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.1: ) + $2 = token error (1.1-2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) +Entering state 8 +Stack now 0 8 +Reading a token +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) +Entering state 20 +Stack now 0 8 20 +Reading a token +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Stack now 0 8 20 4 +Reading a token +1.8: syntax error: invalid character: '#' +Next token is token error (1.8: ) +Shifting token error (1.1-8: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token invalid token (1.8: ) +LAC: initial context established for invalid token +LAC: checking lookahead invalid token: Err +Error: discarding token invalid token (1.8: ) +Error: popping token error (1.1-8: ) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.1-8: ) +Entering state 11 +Stack now 0 8 20 4 11 +Reading a token +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.7: ) + $2 = token error (1.1-8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 29 +Stack now 0 8 20 29 +Reading a token +Next token is token '=' (1.11: ) +LAC: initial context established for '=' +LAC: checking lookahead '=': R7 G8 S18 +Reducing stack by rule 7 (line 103): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) +Entering state 8 +Stack now 0 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) LAC: initial context discarded due to shift Entering state 18 Stack now 0 8 18 Reading a token -Next token is token number (1.13: 7) -Shifting token number (1.13: 7) +Next token is token number (1.13-16: 2222) +Shifting token number (1.13-16: 2222) Entering state 1 Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): - $1 = token number (1.13: 7) --> $$ = nterm exp (1.13: 7) + $1 = token number (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) Entering state 27 Stack now 0 8 18 27 Reading a token -Next token is token '\n' (1.14-2.0: ) +Next token is token '\n' (1.17-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): - $1 = nterm exp (1.1-9: 7) + $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) - $3 = nterm exp (1.13: 7) --> $$ = nterm exp (1.1-13: 7) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 Stack now 0 8 -Next token is token '\n' (1.14-2.0: ) -Shifting token '\n' (1.14-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 Reducing stack by rule 4 (line 88): - $1 = nterm exp (1.1-13: 7) - $2 = token '\n' (1.14-2.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 @@ -162916,985 +167924,1226 @@ Entering state 6 Stack now 0 6 Reading a token -Next token is token number (2.1: 1) -Shifting token number (2.1: 1) -Entering state 1 -Stack now 0 6 1 -Reducing stack by rule 5 (line 92): - $1 = token number (2.1: 1) --> $$ = nterm exp (2.1: 1) +Next token is token end of file (2.1: ) +Shifting token end of file (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1459: $PREPARSER ./calc input +syntax error +1.6: syntax error: invalid character: '#' +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +stderr: +535. calc.at:1448: ok +stderr: +./calc.at:1476: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +syntax error: invalid character: '#' +1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.1-46: error: 4444 != 1 +input: +stderr: + | (!!) + (1 2) = 1 +./calc.at:1458: $PREPARSER ./calc input +./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1451: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1449: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.1-2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +LAC: initial context established for invalid token +LAC: checking lookahead invalid token: Err +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.1-2: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.1-2: ) +Entering state 11 +Stack now 0 4 11 +Reading a token +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.1: ) + $2 = token error (1.1-2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) Entering state 8 -Stack now 0 6 8 +Stack now 0 8 Reading a token -Next token is token '+' (2.3: ) -Shifting token '+' (2.3: ) +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) Entering state 20 -Stack now 0 6 8 20 -Reading a token -Next token is token number (2.5: 2) -Shifting token number (2.5: 2) -Entering state 1 -Stack now 0 6 8 20 1 -Reducing stack by rule 5 (line 92): - $1 = token number (2.5: 2) --> $$ = nterm exp (2.5: 2) -Entering state 29 -Stack now 0 6 8 20 29 +Stack now 0 8 20 Reading a token -Next token is token '*' (2.7: ) -Shifting token '*' (2.7: ) -Entering state 21 -Stack now 0 6 8 20 29 21 +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Stack now 0 8 20 4 Reading a token -Next token is token '-' (2.9: ) -Shifting token '-' (2.9: ) -Entering state 2 -Stack now 0 6 8 20 29 21 2 +1.8: syntax error: invalid character: '#' +Next token is token error (1.8: ) +Shifting token error (1.1-8: ) +Entering state 11 +Stack now 0 8 20 4 11 +Next token is token invalid token (1.8: ) +LAC: initial context established for invalid token +LAC: checking lookahead invalid token: Err +Error: discarding token invalid token (1.8: ) +Error: popping token error (1.1-8: ) +Stack now 0 8 20 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.1-8: ) +Entering state 11 +Stack now 0 8 20 4 11 Reading a token -Next token is token number (2.10: 3) -Shifting token number (2.10: 3) -Entering state 1 -Stack now 0 6 8 20 29 21 2 1 -Reducing stack by rule 5 (line 92): - $1 = token number (2.10: 3) --> $$ = nterm exp (2.10: 3) -Entering state 10 -Stack now 0 6 8 20 29 21 2 10 +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 25 +Stack now 0 8 20 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.7: ) + $2 = token error (1.1-8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 29 +Stack now 0 8 20 29 Reading a token -Next token is token '=' (2.12: ) +Next token is token '=' (1.11: ) LAC: initial context established for '=' -LAC: checking lookahead '=': R11 G30 R9 G29 R7 G8 S18 -Reducing stack by rule 11 (line 115): - $1 = token '-' (2.9: ) - $2 = nterm exp (2.10: 3) --> $$ = nterm exp (2.9-10: -3) -Entering state 30 -Stack now 0 6 8 20 29 21 30 -Next token is token '=' (2.12: ) -Reducing stack by rule 9 (line 105): - $1 = nterm exp (2.5: 2) - $2 = token '*' (2.7: ) - $3 = nterm exp (2.9-10: -3) --> $$ = nterm exp (2.5-10: -6) -Entering state 29 -Stack now 0 6 8 20 29 -Next token is token '=' (2.12: ) +LAC: checking lookahead '=': R7 G8 S18 Reducing stack by rule 7 (line 103): - $1 = nterm exp (2.1: 1) - $2 = token '+' (2.3: ) - $3 = nterm exp (2.5-10: -6) --> $$ = nterm exp (2.1-10: -5) + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (2.12: ) -Shifting token '=' (2.12: ) +Stack now 0 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) LAC: initial context discarded due to shift Entering state 18 -Stack now 0 6 8 18 -Reading a token -Next token is token '-' (2.14: ) -Shifting token '-' (2.14: ) -Entering state 2 -Stack now 0 6 8 18 2 +Stack now 0 8 18 Reading a token -Next token is token number (2.15: 5) -Shifting token number (2.15: 5) +Next token is token number (1.13-16: 2222) +Shifting token number (1.13-16: 2222) Entering state 1 -Stack now 0 6 8 18 2 1 +Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): - $1 = token number (2.15: 5) --> $$ = nterm exp (2.15: 5) -Entering state 10 -Stack now 0 6 8 18 2 10 + $1 = token number (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) +Entering state 27 +Stack now 0 8 18 27 Reading a token -Next token is token '\n' (2.16-3.0: ) +Next token is token '\n' (1.17-2.0: ) LAC: initial context established for '\n' -LAC: checking lookahead '\n': R11 G27 R6 G8 S24 -Reducing stack by rule 11 (line 115): - $1 = token '-' (2.14: ) - $2 = nterm exp (2.15: 5) --> $$ = nterm exp (2.14-15: -5) -Entering state 27 -Stack now 0 6 8 18 27 -Next token is token '\n' (2.16-3.0: ) +LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): - $1 = nterm exp (2.1-10: -5) - $2 = token '=' (2.12: ) - $3 = nterm exp (2.14-15: -5) --> $$ = nterm exp (2.1-15: -5) + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (2.16-3.0: ) -Shifting token '\n' (2.16-3.0: ) +Stack now 0 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) LAC: initial context discarded due to shift Entering state 24 -Stack now 0 6 8 24 +Stack now 0 8 24 Reducing stack by rule 4 (line 88): - $1 = nterm exp (2.1-15: -5) - $2 = token '\n' (2.16-3.0: ) --> $$ = nterm line (2.1-3.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-2.0: ) - $2 = nterm line (2.1-3.0: ) --> $$ = nterm input (1.1-3.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 82): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token '\n' (3.1-4.0: ) -Shifting token '\n' (3.1-4.0: ) -Entering state 3 -Stack now 0 6 3 -Reducing stack by rule 3 (line 87): - $1 = token '\n' (3.1-4.0: ) --> $$ = nterm line (3.1-4.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-3.0: ) - $2 = nterm line (3.1-4.0: ) --> $$ = nterm input (1.1-4.0: ) -Entering state 6 -Stack now 0 6 +Next token is token end of file (2.1: ) +Shifting token end of file (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1476: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +stderr: +1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-16: error: 2222 != 1 +stderr: +./calc.at:1468: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.1-46: error: 4444 != 1 +./calc.at:1455: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + +./calc.at:1457: cat stderr +./calc.at:1449: cat stderr +stderr: +./calc.at:1455: cat stderr +1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-16: error: 2222 != 1 +./calc.at:1451: cat stderr +./calc.at:1459: cat stderr +input: +input: +./calc.at:1477: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +./calc.at:1468: cat stderr +input: +./calc.at:1458: cat stderr + | (# + 1) = 1111 + | (1 + #) = 1111 + | (1 + 1) / (1 - 1) +./calc.at:1449: $PREPARSER ./calc input +./calc.at:1457: $PREPARSER ./calc input +./calc.at:1455: $PREPARSER ./calc input +input: +input: +stderr: +./calc.at:1468: $PREPARSER ./calc /dev/null +stderr: +stderr: + | (1 + #) = 1111 + | (!!) + (1 2) = 1 +stderr: +./calc.at:1459: $PREPARSER ./calc input +./calc.at:1451: $PREPARSER ./calc input +error: null divisor +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token '-' (4.1: ) -Shifting token '-' (4.1: ) -Entering state 2 -Stack now 0 6 2 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 Reading a token -Next token is token number (4.2: 1) -Shifting token number (4.2: 1) +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 -Stack now 0 6 2 1 +Stack now 0 4 1 Reducing stack by rule 5 (line 92): - $1 = token number (4.2: 1) --> $$ = nterm exp (4.2: 1) -Entering state 10 -Stack now 0 6 2 10 + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 Reading a token -Next token is token '^' (4.3: ) -Shifting token '^' (4.3: ) -Entering state 23 -Stack now 0 6 2 10 23 +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Stack now 0 4 12 20 Reading a token -Next token is token number (4.4: 2) -Shifting token number (4.4: 2) -Entering state 1 -Stack now 0 6 2 10 23 1 -Reducing stack by rule 5 (line 92): - $1 = token number (4.4: 2) --> $$ = nterm exp (4.4: 2) -Entering state 32 -Stack now 0 6 2 10 23 32 +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +LAC: initial context established for invalid token +LAC: checking lookahead invalid token: Err +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token '=' (4.6: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R12 G10 R11 G8 S18 -Reducing stack by rule 12 (line 116): - $1 = nterm exp (4.2: 1) - $2 = token '^' (4.3: ) - $3 = nterm exp (4.4: 2) --> $$ = nterm exp (4.2-4: 1) -Entering state 10 -Stack now 0 6 2 10 -Next token is token '=' (4.6: ) -Reducing stack by rule 11 (line 115): - $1 = token '-' (4.1: ) - $2 = nterm exp (4.2-4: 1) --> $$ = nterm exp (4.1-4: -1) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (4.6: ) -Shifting token '=' (4.6: ) -LAC: initial context discarded due to shift -Entering state 18 -Stack now 0 6 8 18 +Stack now 0 8 Reading a token -Next token is token '-' (4.8: ) -Shifting token '-' (4.8: ) -Entering state 2 -Stack now 0 6 8 18 2 +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 18 +Stack now 0 8 18 Reading a token -Next token is token number (4.9: 1) -Shifting token number (4.9: 1) +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 -Stack now 0 6 8 18 2 1 +Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): - $1 = token number (4.9: 1) --> $$ = nterm exp (4.9: 1) -Entering state 10 -Stack now 0 6 8 18 2 10 + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 27 +Stack now 0 8 18 27 Reading a token -Next token is token '\n' (4.10-5.0: ) +Next token is token '\n' (1.15-2.0: ) LAC: initial context established for '\n' -LAC: checking lookahead '\n': R11 G27 R6 G8 S24 -Reducing stack by rule 11 (line 115): - $1 = token '-' (4.8: ) - $2 = nterm exp (4.9: 1) --> $$ = nterm exp (4.8-9: -1) -Entering state 27 -Stack now 0 6 8 18 27 -Next token is token '\n' (4.10-5.0: ) +LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): - $1 = nterm exp (4.1-4: -1) - $2 = token '=' (4.6: ) - $3 = nterm exp (4.8-9: -1) --> $$ = nterm exp (4.1-9: -1) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (4.10-5.0: ) -Shifting token '\n' (4.10-5.0: ) +Stack now 0 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) LAC: initial context discarded due to shift Entering state 24 -Stack now 0 6 8 24 +Stack now 0 8 24 Reducing stack by rule 4 (line 88): - $1 = nterm exp (4.1-9: -1) - $2 = token '\n' (4.10-5.0: ) --> $$ = nterm line (4.1-5.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-4.0: ) - $2 = nterm line (4.1-5.0: ) --> $$ = nterm input (1.1-5.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 82): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token '(' (5.1: ) -Shifting token '(' (5.1: ) -Entering state 4 -Stack now 0 6 4 +Next token is token end of file (2.1: ) +Shifting token end of file (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +1.2: syntax error: invalid character: '#' +./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +stderr: +./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error + | (- *) + (1 2) = 1 +./calc.at:1458: $PREPARSER ./calc input +./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-16: error: 2222 != 1 +549. calc.at:1477: testing Calculator glr2.cc %locations ... +./calc.at:1477: mv calc.y.tmp calc.y + +1.6: syntax error: invalid character: '#' +stderr: +stderr: +./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token '-' (5.2: ) -Shifting token '-' (5.2: ) -Entering state 2 -Stack now 0 6 4 2 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 Reading a token -Next token is token number (5.3: 1) -Shifting token number (5.3: 1) +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 -Stack now 0 6 4 2 1 +Stack now 0 4 1 Reducing stack by rule 5 (line 92): - $1 = token number (5.3: 1) --> $$ = nterm exp (5.3: 1) -Entering state 10 -Stack now 0 6 4 2 10 -Reading a token -Next token is token ')' (5.4: ) -LAC: initial context established for ')' -LAC: checking lookahead ')': R11 G12 S26 -Reducing stack by rule 11 (line 115): - $1 = token '-' (5.2: ) - $2 = nterm exp (5.3: 1) --> $$ = nterm exp (5.2-3: -1) + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) Entering state 12 -Stack now 0 6 4 12 -Next token is token ')' (5.4: ) -Shifting token ')' (5.4: ) -LAC: initial context discarded due to shift -Entering state 26 -Stack now 0 6 4 12 26 -Reducing stack by rule 13 (line 117): - $1 = token '(' (5.1: ) - $2 = nterm exp (5.2-3: -1) - $3 = token ')' (5.4: ) --> $$ = nterm exp (5.1-4: -1) -Entering state 8 -Stack now 0 6 8 +Stack now 0 4 12 Reading a token -Next token is token '^' (5.5: ) -Shifting token '^' (5.5: ) -Entering state 23 -Stack now 0 6 8 23 +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Stack now 0 4 12 20 Reading a token -Next token is token number (5.6: 2) -Shifting token number (5.6: 2) -Entering state 1 -Stack now 0 6 8 23 1 -Reducing stack by rule 5 (line 92): - $1 = token number (5.6: 2) --> $$ = nterm exp (5.6: 2) -Entering state 32 -Stack now 0 6 8 23 32 +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +LAC: initial context established for invalid token +LAC: checking lookahead invalid token: Err +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token '=' (5.8: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R12 G8 S18 -Reducing stack by rule 12 (line 116): - $1 = nterm exp (5.1-4: -1) - $2 = token '^' (5.5: ) - $3 = nterm exp (5.6: 2) --> $$ = nterm exp (5.1-6: 1) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (5.8: ) -Shifting token '=' (5.8: ) -LAC: initial context discarded due to shift +Stack now 0 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 18 -Stack now 0 6 8 18 +Stack now 0 8 18 Reading a token -Next token is token number (5.10: 1) -Shifting token number (5.10: 1) +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 -Stack now 0 6 8 18 1 +Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): - $1 = token number (5.10: 1) --> $$ = nterm exp (5.10: 1) + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 27 -Stack now 0 6 8 18 27 +Stack now 0 8 18 27 Reading a token -Next token is token '\n' (5.11-6.0: ) +Next token is token '\n' (1.15-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): - $1 = nterm exp (5.1-6: 1) - $2 = token '=' (5.8: ) - $3 = nterm exp (5.10: 1) --> $$ = nterm exp (5.1-10: 1) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (5.11-6.0: ) -Shifting token '\n' (5.11-6.0: ) +Stack now 0 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) LAC: initial context discarded due to shift Entering state 24 -Stack now 0 6 8 24 +Stack now 0 8 24 Reducing stack by rule 4 (line 88): - $1 = nterm exp (5.1-10: 1) - $2 = token '\n' (5.11-6.0: ) --> $$ = nterm line (5.1-6.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-5.0: ) - $2 = nterm line (5.1-6.0: ) --> $$ = nterm input (1.1-6.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '\n' (6.1-7.0: ) -Shifting token '\n' (6.1-7.0: ) -Entering state 3 -Stack now 0 6 3 -Reducing stack by rule 3 (line 87): - $1 = token '\n' (6.1-7.0: ) --> $$ = nterm line (6.1-7.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-6.0: ) - $2 = nterm line (6.1-7.0: ) --> $$ = nterm input (1.1-7.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 82): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token '-' (7.1: ) -Shifting token '-' (7.1: ) -Entering state 2 -Stack now 0 6 2 -Reading a token -Next token is token '-' (7.2: ) -Shifting token '-' (7.2: ) -Entering state 2 -Stack now 0 6 2 2 -Reading a token -Next token is token '-' (7.3: ) -Shifting token '-' (7.3: ) -Entering state 2 -Stack now 0 6 2 2 2 -Reading a token -Next token is token number (7.4: 1) -Shifting token number (7.4: 1) -Entering state 1 -Stack now 0 6 2 2 2 1 -Reducing stack by rule 5 (line 92): - $1 = token number (7.4: 1) --> $$ = nterm exp (7.4: 1) -Entering state 10 -Stack now 0 6 2 2 2 10 -Reading a token -Next token is token '=' (7.6: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R11 G10 R11 G10 R11 G8 S18 -Reducing stack by rule 11 (line 115): - $1 = token '-' (7.3: ) - $2 = nterm exp (7.4: 1) --> $$ = nterm exp (7.3-4: -1) -Entering state 10 -Stack now 0 6 2 2 10 -Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 115): - $1 = token '-' (7.2: ) - $2 = nterm exp (7.3-4: -1) --> $$ = nterm exp (7.2-4: 1) -Entering state 10 -Stack now 0 6 2 10 -Next token is token '=' (7.6: ) -Reducing stack by rule 11 (line 115): - $1 = token '-' (7.1: ) - $2 = nterm exp (7.2-4: 1) --> $$ = nterm exp (7.1-4: -1) -Entering state 8 -Stack now 0 6 8 -Next token is token '=' (7.6: ) -Shifting token '=' (7.6: ) -LAC: initial context discarded due to shift -Entering state 18 -Stack now 0 6 8 18 -Reading a token -Next token is token '-' (7.8: ) -Shifting token '-' (7.8: ) -Entering state 2 -Stack now 0 6 8 18 2 -Reading a token -Next token is token number (7.9: 1) -Shifting token number (7.9: 1) -Entering state 1 -Stack now 0 6 8 18 2 1 -Reducing stack by rule 5 (line 92): - $1 = token number (7.9: 1) --> $$ = nterm exp (7.9: 1) -Entering state 10 -Stack now 0 6 8 18 2 10 -Reading a token -Next token is token '\n' (7.10-8.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R11 G27 R6 G8 S24 -Reducing stack by rule 11 (line 115): - $1 = token '-' (7.8: ) - $2 = nterm exp (7.9: 1) --> $$ = nterm exp (7.8-9: -1) -Entering state 27 -Stack now 0 6 8 18 27 -Next token is token '\n' (7.10-8.0: ) -Reducing stack by rule 6 (line 93): - $1 = nterm exp (7.1-4: -1) - $2 = token '=' (7.6: ) - $3 = nterm exp (7.8-9: -1) --> $$ = nterm exp (7.1-9: -1) -Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (7.10-8.0: ) -Shifting token '\n' (7.10-8.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 6 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (7.1-9: -1) - $2 = token '\n' (7.10-8.0: ) --> $$ = nterm line (7.1-8.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-7.0: ) - $2 = nterm line (7.1-8.0: ) --> $$ = nterm input (1.1-8.0: ) -Entering state 6 -Stack now 0 6 +Next token is token end of file (2.1: ) +Shifting token end of file (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-17: error: 2222 != 1 +./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error: invalid character: '#' +stderr: +error: null divisor +syntax error +./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1477: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +stderr: +stderr: +1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-16: error: 2222 != 1 +stderr: +1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-17: error: 2222 != 1 +./calc.at:1455: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1449: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +1.6: syntax error: invalid character: '#' +./calc.at:1459: cat stderr +./calc.at:1468: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1457: cat stderr +./calc.at:1455: cat stderr +./calc.at:1458: cat stderr +input: +./calc.at:1451: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1449: cat stderr +541. calc.at:1457: ok +./calc.at:1468: cat stderr + | (- *) + (1 2) = 1 +input: +./calc.at:1459: $PREPARSER ./calc input + | (* *) + (*) + (*) +./calc.at:1458: $PREPARSER ./calc input +stderr: +input: +input: +stderr: +./calc.at:1451: cat stderr +1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-17: error: 2222 != 1 +1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +input: +./calc.at:1477: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS + | (# + 1) = 1111 + | (1 + # + 1) = 1111 +./calc.at:1449: $PREPARSER ./calc input +./calc.at:1455: $PREPARSER ./calc input +./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1468: $PREPARSER ./calc input +stderr: +input: +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token '\n' (8.1-9.0: ) -Shifting token '\n' (8.1-9.0: ) -Entering state 3 -Stack now 0 6 3 -Reducing stack by rule 3 (line 87): - $1 = token '\n' (8.1-9.0: ) --> $$ = nterm line (8.1-9.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-8.0: ) - $2 = nterm line (8.1-9.0: ) --> $$ = nterm input (1.1-9.0: ) -Entering state 6 -Stack now 0 6 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 Reading a token -Next token is token number (9.1: 1) -Shifting token number (9.1: 1) -Entering state 1 -Stack now 0 6 1 -Reducing stack by rule 5 (line 92): - $1 = token number (9.1: 1) --> $$ = nterm exp (9.1: 1) -Entering state 8 -Stack now 0 6 8 +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.1-2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +LAC: initial context established for invalid token +LAC: checking lookahead invalid token: Err +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.1-2: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.1-2: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token '-' (9.3: ) -Shifting token '-' (9.3: ) -Entering state 19 -Stack now 0 6 8 19 +Next token is token '+' (1.4: ) +LAC: initial context established for '+' +LAC: checking lookahead '+': Err +Error: discarding token '+' (1.4: ) +Error: popping token error (1.1-2: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.1-4: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token number (9.5: 2) -Shifting token number (9.5: 2) -Entering state 1 -Stack now 0 6 8 19 1 -Reducing stack by rule 5 (line 92): - $1 = token number (9.5: 2) --> $$ = nterm exp (9.5: 2) -Entering state 28 -Stack now 0 6 8 19 28 +Next token is token number (1.6: 1) +LAC: initial context established for number +LAC: checking lookahead number: Err +Error: discarding token number (1.6: 1) +Error: popping token error (1.1-4: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.1-6: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token '-' (9.7: ) -LAC: initial context established for '-' -LAC: checking lookahead '-': R8 G8 S19 -Reducing stack by rule 8 (line 104): - $1 = nterm exp (9.1: 1) - $2 = token '-' (9.3: ) - $3 = nterm exp (9.5: 2) --> $$ = nterm exp (9.1-5: -1) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.1: ) + $2 = token error (1.1-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 -Stack now 0 6 8 -Next token is token '-' (9.7: ) -Shifting token '-' (9.7: ) -LAC: initial context discarded due to shift -Entering state 19 -Stack now 0 6 8 19 -Reading a token -Next token is token number (9.9: 3) -Shifting token number (9.9: 3) -Entering state 1 -Stack now 0 6 8 19 1 -Reducing stack by rule 5 (line 92): - $1 = token number (9.9: 3) --> $$ = nterm exp (9.9: 3) -Entering state 28 -Stack now 0 6 8 19 28 +Stack now 0 8 Reading a token -Next token is token '=' (9.11: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R8 G8 S18 -Reducing stack by rule 8 (line 104): - $1 = nterm exp (9.1-5: -1) - $2 = token '-' (9.7: ) - $3 = nterm exp (9.9: 3) --> $$ = nterm exp (9.1-9: -4) -Entering state 8 -Stack now 0 6 8 -Next token is token '=' (9.11: ) -Shifting token '=' (9.11: ) -LAC: initial context discarded due to shift +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 18 -Stack now 0 6 8 18 -Reading a token -Next token is token '-' (9.13: ) -Shifting token '-' (9.13: ) -Entering state 2 -Stack now 0 6 8 18 2 +Stack now 0 8 18 Reading a token -Next token is token number (9.14: 4) -Shifting token number (9.14: 4) +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 -Stack now 0 6 8 18 2 1 +Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): - $1 = token number (9.14: 4) --> $$ = nterm exp (9.14: 4) -Entering state 10 -Stack now 0 6 8 18 2 10 + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 27 +Stack now 0 8 18 27 Reading a token -Next token is token '\n' (9.15-10.0: ) +Next token is token '\n' (1.15-2.0: ) LAC: initial context established for '\n' -LAC: checking lookahead '\n': R11 G27 R6 G8 S24 -Reducing stack by rule 11 (line 115): - $1 = token '-' (9.13: ) - $2 = nterm exp (9.14: 4) --> $$ = nterm exp (9.13-14: -4) -Entering state 27 -Stack now 0 6 8 18 27 -Next token is token '\n' (9.15-10.0: ) +LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): - $1 = nterm exp (9.1-9: -4) - $2 = token '=' (9.11: ) - $3 = nterm exp (9.13-14: -4) --> $$ = nterm exp (9.1-14: -4) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (9.15-10.0: ) -Shifting token '\n' (9.15-10.0: ) +Stack now 0 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) LAC: initial context discarded due to shift Entering state 24 -Stack now 0 6 8 24 +Stack now 0 8 24 Reducing stack by rule 4 (line 88): - $1 = nterm exp (9.1-14: -4) - $2 = token '\n' (9.15-10.0: ) --> $$ = nterm line (9.1-10.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-9.0: ) - $2 = nterm line (9.1-10.0: ) --> $$ = nterm input (1.1-10.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 82): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token number (10.1: 1) -Shifting token number (10.1: 1) -Entering state 1 -Stack now 0 6 1 -Reducing stack by rule 5 (line 92): - $1 = token number (10.1: 1) --> $$ = nterm exp (10.1: 1) -Entering state 8 -Stack now 0 6 8 -Reading a token -Next token is token '-' (10.3: ) -Shifting token '-' (10.3: ) -Entering state 19 -Stack now 0 6 8 19 +Next token is token end of file (2.1: ) +Shifting token end of file (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +1.6: syntax error: invalid character: '#' +./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + +stderr: +./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: + | (# + 1) = 1111 +stderr: +1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +1.1-17: error: 2222 != 1 +./calc.at:1451: $PREPARSER ./calc input +stderr: +stderr: +1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 +./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error: invalid character: '#' +./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.6: syntax error: invalid character: '#' +stderr: +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token '(' (10.5: ) -Shifting token '(' (10.5: ) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 -Stack now 0 6 8 19 4 -Reading a token -Next token is token number (10.6: 2) -Shifting token number (10.6: 2) -Entering state 1 -Stack now 0 6 8 19 4 1 -Reducing stack by rule 5 (line 92): - $1 = token number (10.6: 2) --> $$ = nterm exp (10.6: 2) -Entering state 12 -Stack now 0 6 8 19 4 12 +Stack now 0 4 Reading a token -Next token is token '-' (10.8: ) -Shifting token '-' (10.8: ) -Entering state 19 -Stack now 0 6 8 19 4 12 19 +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.1-2: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.2: ) +LAC: initial context established for invalid token +LAC: checking lookahead invalid token: Err +Error: discarding token invalid token (1.2: ) +Error: popping token error (1.1-2: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.1-2: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token number (10.10: 3) -Shifting token number (10.10: 3) -Entering state 1 -Stack now 0 6 8 19 4 12 19 1 -Reducing stack by rule 5 (line 92): - $1 = token number (10.10: 3) --> $$ = nterm exp (10.10: 3) -Entering state 28 -Stack now 0 6 8 19 4 12 19 28 +Next token is token '+' (1.4: ) +LAC: initial context established for '+' +LAC: checking lookahead '+': Err +Error: discarding token '+' (1.4: ) +Error: popping token error (1.1-2: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.1-4: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token ')' (10.11: ) -LAC: initial context established for ')' -LAC: checking lookahead ')': R8 G12 S26 -Reducing stack by rule 8 (line 104): - $1 = nterm exp (10.6: 2) - $2 = token '-' (10.8: ) - $3 = nterm exp (10.10: 3) --> $$ = nterm exp (10.6-10: -1) -Entering state 12 -Stack now 0 6 8 19 4 12 -Next token is token ')' (10.11: ) -Shifting token ')' (10.11: ) -LAC: initial context discarded due to shift -Entering state 26 -Stack now 0 6 8 19 4 12 26 -Reducing stack by rule 13 (line 117): - $1 = token '(' (10.5: ) - $2 = nterm exp (10.6-10: -1) - $3 = token ')' (10.11: ) --> $$ = nterm exp (10.5-11: -1) -Entering state 28 -Stack now 0 6 8 19 28 +Next token is token number (1.6: 1) +LAC: initial context established for number +LAC: checking lookahead number: Err +Error: discarding token number (1.6: 1) +Error: popping token error (1.1-4: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.1-6: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token '=' (10.13: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R8 G8 S18 -Reducing stack by rule 8 (line 104): - $1 = nterm exp (10.1: 1) - $2 = token '-' (10.3: ) - $3 = nterm exp (10.5-11: -1) --> $$ = nterm exp (10.1-11: 2) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.1: ) + $2 = token error (1.1-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (10.13: ) -Shifting token '=' (10.13: ) -LAC: initial context discarded due to shift +Stack now 0 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 18 -Stack now 0 6 8 18 +Stack now 0 8 18 Reading a token -Next token is token number (10.15: 2) -Shifting token number (10.15: 2) +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 -Stack now 0 6 8 18 1 +Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): - $1 = token number (10.15: 2) --> $$ = nterm exp (10.15: 2) + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 27 -Stack now 0 6 8 18 27 +Stack now 0 8 18 27 Reading a token -Next token is token '\n' (10.16-11.0: ) +Next token is token '\n' (1.15-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): - $1 = nterm exp (10.1-11: 2) - $2 = token '=' (10.13: ) - $3 = nterm exp (10.15: 2) --> $$ = nterm exp (10.1-15: 2) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (10.16-11.0: ) -Shifting token '\n' (10.16-11.0: ) +Stack now 0 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) LAC: initial context discarded due to shift Entering state 24 -Stack now 0 6 8 24 +Stack now 0 8 24 Reducing stack by rule 4 (line 88): - $1 = nterm exp (10.1-15: 2) - $2 = token '\n' (10.16-11.0: ) --> $$ = nterm line (10.1-11.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-10.0: ) - $2 = nterm line (10.1-11.0: ) --> $$ = nterm input (1.1-11.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 82): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token '\n' (11.1-12.0: ) -Shifting token '\n' (11.1-12.0: ) -Entering state 3 -Stack now 0 6 3 -Reducing stack by rule 3 (line 87): - $1 = token '\n' (11.1-12.0: ) --> $$ = nterm line (11.1-12.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-11.0: ) - $2 = nterm line (11.1-12.0: ) --> $$ = nterm input (1.1-12.0: ) -Entering state 6 -Stack now 0 6 +Next token is token end of file (2.1: ) +Shifting token end of file (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 +./calc.at:1459: cat stderr +./calc.at:1458: cat stderr +1.2: syntax error: invalid character: '#' +./calc.at:1449: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +550. calc.at:1478: testing Calculator C++ %glr-parser %locations api.location.type={Span} ... +./calc.at:1478: mv calc.y.tmp calc.y + +input: +./calc.at:1455: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y + | 1 + 2 * 3 + !+ ++ +./calc.at:1458: $PREPARSER ./calc input +input: +./calc.at:1451: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1468: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1455: cat stderr +./calc.at:1449: cat stderr + | (* *) + (*) + (*) +./calc.at:1459: $PREPARSER ./calc input +stderr: +./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +input: +stderr: +input: +./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + 1) / (1 - 1) +./calc.at:1458: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1451: cat stderr +./calc.at:1449: $PREPARSER ./calc input + | (1 + # + 1) = 1111 +./calc.at:1455: $PREPARSER ./calc input +./calc.at:1468: cat stderr +stderr: +stderr: +stderr: +1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +1.11-17: error: null divisor +./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 Reading a token -Next token is token number (12.1: 2) -Shifting token number (12.1: 2) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Stack now 0 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 -Stack now 0 6 1 +Stack now 0 4 1 Reducing stack by rule 5 (line 92): - $1 = token number (12.1: 2) --> $$ = nterm exp (12.1: 2) -Entering state 8 -Stack now 0 6 8 + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Stack now 0 4 12 Reading a token -Next token is token '^' (12.2: ) -Shifting token '^' (12.2: ) -Entering state 23 -Stack now 0 6 8 23 +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Stack now 0 4 12 20 Reading a token -Next token is token number (12.3: 2) -Shifting token number (12.3: 2) -Entering state 1 -Stack now 0 6 8 23 1 -Reducing stack by rule 5 (line 92): - $1 = token number (12.3: 2) --> $$ = nterm exp (12.3: 2) -Entering state 32 -Stack now 0 6 8 23 32 +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +LAC: initial context established for invalid token +LAC: checking lookahead invalid token: Err +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token '^' (12.4: ) -Shifting token '^' (12.4: ) -Entering state 23 -Stack now 0 6 8 23 32 23 +Next token is token '+' (1.8: ) +LAC: initial context established for '+' +LAC: checking lookahead '+': Err +Error: discarding token '+' (1.8: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.2-8: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token number (12.5: 3) -Shifting token number (12.5: 3) -Entering state 1 -Stack now 0 6 8 23 32 23 1 -Reducing stack by rule 5 (line 92): - $1 = token number (12.5: 3) --> $$ = nterm exp (12.5: 3) -Entering state 32 -Stack now 0 6 8 23 32 23 32 +Next token is token number (1.10: 1) +LAC: initial context established for number +LAC: checking lookahead number: Err +Error: discarding token number (1.10: 1) +Error: popping token error (1.2-8: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.2-10: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token '=' (12.7: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R12 G32 R12 G8 S18 -Reducing stack by rule 12 (line 116): - $1 = nterm exp (12.3: 2) - $2 = token '^' (12.4: ) - $3 = nterm exp (12.5: 3) --> $$ = nterm exp (12.3-5: 8) -Entering state 32 -Stack now 0 6 8 23 32 -Next token is token '=' (12.7: ) -Reducing stack by rule 12 (line 116): - $1 = nterm exp (12.1: 2) - $2 = token '^' (12.2: ) - $3 = nterm exp (12.3-5: 8) --> $$ = nterm exp (12.1-5: 256) +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (12.7: ) -Shifting token '=' (12.7: ) -LAC: initial context discarded due to shift +Stack now 0 8 +Reading a token +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) Entering state 18 -Stack now 0 6 8 18 +Stack now 0 8 18 Reading a token -Next token is token number (12.9-11: 256) -Shifting token number (12.9-11: 256) +Next token is token number (1.15-18: 1111) +Shifting token number (1.15-18: 1111) Entering state 1 -Stack now 0 6 8 18 1 +Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): - $1 = token number (12.9-11: 256) --> $$ = nterm exp (12.9-11: 256) + $1 = token number (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) Entering state 27 -Stack now 0 6 8 18 27 +Stack now 0 8 18 27 Reading a token -Next token is token '\n' (12.12-13.0: ) +Next token is token '\n' (1.19-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): - $1 = nterm exp (12.1-5: 256) - $2 = token '=' (12.7: ) - $3 = nterm exp (12.9-11: 256) --> $$ = nterm exp (12.1-11: 256) + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (12.12-13.0: ) -Shifting token '\n' (12.12-13.0: ) +Stack now 0 8 +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) LAC: initial context discarded due to shift Entering state 24 -Stack now 0 6 8 24 +Stack now 0 8 24 Reducing stack by rule 4 (line 88): - $1 = nterm exp (12.1-11: 256) - $2 = token '\n' (12.12-13.0: ) --> $$ = nterm line (12.1-13.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-12.0: ) - $2 = nterm line (12.1-13.0: ) --> $$ = nterm input (1.1-13.0: ) + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 82): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token '(' (13.1: ) -Shifting token '(' (13.1: ) +Next token is token end of file (2.1: ) +Shifting token end of file (2.1: ) +Entering state 16 +Stack now 0 6 16 +Stack now 0 6 16 +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +input: +input: + | (!!) + (1 2) = 1 +./calc.at:1459: cat stderr +./calc.at:1468: $PREPARSER ./calc input + | (1 + # + 1) = 1111 +./calc.at:1451: $PREPARSER ./calc input +stderr: + | 1 + 2 * 3 + !- ++ +./calc.at:1458: $PREPARSER ./calc input +stderr: +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 -Stack now 0 6 4 +Stack now 0 4 Reading a token -Next token is token number (13.2: 2) -Shifting token number (13.2: 2) +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 -Stack now 0 6 4 1 +Stack now 0 4 1 Reducing stack by rule 5 (line 92): - $1 = token number (13.2: 2) --> $$ = nterm exp (13.2: 2) + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) Entering state 12 -Stack now 0 6 4 12 -Reading a token -Next token is token '^' (13.3: ) -Shifting token '^' (13.3: ) -Entering state 23 -Stack now 0 6 4 12 23 +Stack now 0 4 12 Reading a token -Next token is token number (13.4: 2) -Shifting token number (13.4: 2) -Entering state 1 -Stack now 0 6 4 12 23 1 -Reducing stack by rule 5 (line 92): - $1 = token number (13.4: 2) --> $$ = nterm exp (13.4: 2) -Entering state 32 -Stack now 0 6 4 12 23 32 +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Stack now 0 4 12 20 Reading a token -Next token is token ')' (13.5: ) -LAC: initial context established for ')' -LAC: checking lookahead ')': R12 G12 S26 -Reducing stack by rule 12 (line 116): - $1 = nterm exp (13.2: 2) - $2 = token '^' (13.3: ) - $3 = nterm exp (13.4: 2) --> $$ = nterm exp (13.2-4: 4) -Entering state 12 -Stack now 0 6 4 12 -Next token is token ')' (13.5: ) -Shifting token ')' (13.5: ) -LAC: initial context discarded due to shift -Entering state 26 -Stack now 0 6 4 12 26 -Reducing stack by rule 13 (line 117): - $1 = token '(' (13.1: ) - $2 = nterm exp (13.2-4: 4) - $3 = token ')' (13.5: ) --> $$ = nterm exp (13.1-5: 4) -Entering state 8 -Stack now 0 6 8 +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Stack now 0 4 12 +Error: popping nterm exp (1.2: 1) +Stack now 0 4 +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 +Next token is token invalid token (1.6: ) +LAC: initial context established for invalid token +LAC: checking lookahead invalid token: Err +Error: discarding token invalid token (1.6: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.2-6: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token '^' (13.6: ) -Shifting token '^' (13.6: ) -Entering state 23 -Stack now 0 6 8 23 +Next token is token '+' (1.8: ) +LAC: initial context established for '+' +LAC: checking lookahead '+': Err +Error: discarding token '+' (1.8: ) +Error: popping token error (1.2-6: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.2-8: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token number (13.7: 3) -Shifting token number (13.7: 3) -Entering state 1 -Stack now 0 6 8 23 1 -Reducing stack by rule 5 (line 92): - $1 = token number (13.7: 3) --> $$ = nterm exp (13.7: 3) -Entering state 32 -Stack now 0 6 8 23 32 +Next token is token number (1.10: 1) +LAC: initial context established for number +LAC: checking lookahead number: Err +Error: discarding token number (1.10: 1) +Error: popping token error (1.2-8: ) +Stack now 0 4 +LAC: initial context discarded due to error recovery +Shifting token error (1.2-10: ) +Entering state 11 +Stack now 0 4 11 Reading a token -Next token is token '=' (13.9: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R12 G8 S18 -Reducing stack by rule 12 (line 116): - $1 = nterm exp (13.1-5: 4) - $2 = token '^' (13.6: ) - $3 = nterm exp (13.7: 3) --> $$ = nterm exp (13.1-7: 64) +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 25 +Stack now 0 4 11 25 +Reducing stack by rule 14 (line 118): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) Entering state 8 -Stack now 0 6 8 -Next token is token '=' (13.9: ) -Shifting token '=' (13.9: ) -LAC: initial context discarded due to shift +Stack now 0 8 +Reading a token +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) Entering state 18 -Stack now 0 6 8 18 +Stack now 0 8 18 Reading a token -Next token is token number (13.11-12: 64) -Shifting token number (13.11-12: 64) +Next token is token number (1.15-18: 1111) +Shifting token number (1.15-18: 1111) Entering state 1 -Stack now 0 6 8 18 1 +Stack now 0 8 18 1 Reducing stack by rule 5 (line 92): - $1 = token number (13.11-12: 64) --> $$ = nterm exp (13.11-12: 64) + $1 = token number (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) Entering state 27 -Stack now 0 6 8 18 27 +Stack now 0 8 18 27 Reading a token -Next token is token '\n' (13.13-14.0: ) +Next token is token '\n' (1.19-2.0: ) LAC: initial context established for '\n' LAC: checking lookahead '\n': R6 G8 S24 Reducing stack by rule 6 (line 93): - $1 = nterm exp (13.1-7: 64) - $2 = token '=' (13.9: ) - $3 = nterm exp (13.11-12: 64) --> $$ = nterm exp (13.1-12: 64) + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) Entering state 8 -Stack now 0 6 8 -Next token is token '\n' (13.13-14.0: ) -Shifting token '\n' (13.13-14.0: ) +Stack now 0 8 +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) LAC: initial context discarded due to shift Entering state 24 -Stack now 0 6 8 24 +Stack now 0 8 24 Reducing stack by rule 4 (line 88): - $1 = nterm exp (13.1-12: 64) - $2 = token '\n' (13.13-14.0: ) --> $$ = nterm line (13.1-14.0: ) -Entering state 17 -Stack now 0 6 17 -Reducing stack by rule 2 (line 83): - $1 = nterm input (1.1-13.0: ) - $2 = nterm line (13.1-14.0: ) --> $$ = nterm input (1.1-14.0: ) + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Stack now 0 7 +Reducing stack by rule 1 (line 82): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token end of file (14.1: ) -Shifting token end of file (14.1: ) +Next token is token end of file (2.1: ) +Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 -Cleanup: popping token end of file (14.1: ) -Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1455: $EGREP -c -v 'Return for a new token:|LAC:' stderr +Cleanup: popping token end of file (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1478: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +1.11-17: error: null divisor +stderr: +syntax error +error: 2222 != 1 +./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.6: syntax error: invalid character: '#' +stderr: +./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +stderr: + | 1 + 2 * 3 + !+ ++ +./calc.at:1459: $PREPARSER ./calc input +syntax error +error: 2222 != 1 +./calc.at:1455: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1449: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.6: syntax error: invalid character: '#' +./calc.at:1455: cat stderr +./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +stderr: + | (1 + 1) / (1 - 1) +./calc.at:1455: $PREPARSER ./calc input stderr: Starting parse Entering state 0 @@ -163909,7 +169158,7 @@ Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 -Reducing stack by rule 5 (line 79): +Reducing stack by rule 5 (line 92): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 @@ -163924,14 +169173,16 @@ Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 -Reducing stack by rule 5 (line 79): +Reducing stack by rule 5 (line 92): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) -Reducing stack by rule 7 (line 90): +LAC: initial context established for ')' +LAC: checking lookahead ')': R7 G12 S26 +Reducing stack by rule 7 (line 103): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) @@ -163940,9 +169191,10 @@ Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) +LAC: initial context discarded due to shift Entering state 26 Stack now 0 4 12 26 -Reducing stack by rule 13 (line 104): +Reducing stack by rule 13 (line 117): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) @@ -163964,7 +169216,7 @@ Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 -Reducing stack by rule 5 (line 79): +Reducing stack by rule 5 (line 92): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 @@ -163979,14 +169231,16 @@ Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 -Reducing stack by rule 5 (line 79): +Reducing stack by rule 5 (line 92): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) -Reducing stack by rule 8 (line 91): +LAC: initial context established for ')' +LAC: checking lookahead ')': R8 G12 S26 +Reducing stack by rule 8 (line 104): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) @@ -163995,9 +169249,10 @@ Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) +LAC: initial context discarded due to shift Entering state 26 Stack now 0 8 22 4 12 26 -Reducing stack by rule 13 (line 104): +Reducing stack by rule 13 (line 117): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) @@ -164006,7 +169261,9 @@ Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 10 (line 93): +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R10 G8 S24 +Reducing stack by rule 10 (line 106): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) @@ -164016,32 +169273,31 @@ Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) +LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 -Reducing stack by rule 4 (line 75): +Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 69): +Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) +Next token is token end of file (2.1: ) +Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) +Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - -1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) -input: -input: -./calc.at:1449: "$PERL" -pi -e 'use strict; +./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -164051,20 +169307,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | error -./calc.at:1457: $PREPARSER ./calc input -stderr: -./calc.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1476: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -input: -stderr: -./calc.at:1454: $PREPARSER ./calc input - | 1 + 2 * 3 + !+ ++ -./calc.at:1451: $PREPARSER ./calc input -./calc.at:1449: cat stderr Starting parse Entering state 0 Stack now 0 @@ -164078,7 +169320,7 @@ Shifting token number (1.2: 1) Entering state 1 Stack now 0 4 1 -Reducing stack by rule 5 (line 79): +Reducing stack by rule 5 (line 92): $1 = token number (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 @@ -164093,14 +169335,16 @@ Shifting token number (1.6: 1) Entering state 1 Stack now 0 4 12 20 1 -Reducing stack by rule 5 (line 79): +Reducing stack by rule 5 (line 92): $1 = token number (1.6: 1) -> $$ = nterm exp (1.6: 1) Entering state 29 Stack now 0 4 12 20 29 Reading a token Next token is token ')' (1.7: ) -Reducing stack by rule 7 (line 90): +LAC: initial context established for ')' +LAC: checking lookahead ')': R7 G12 S26 +Reducing stack by rule 7 (line 103): $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) $3 = nterm exp (1.6: 1) @@ -164109,9 +169353,10 @@ Stack now 0 4 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) +LAC: initial context discarded due to shift Entering state 26 Stack now 0 4 12 26 -Reducing stack by rule 13 (line 104): +Reducing stack by rule 13 (line 117): $1 = token '(' (1.1: ) $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) @@ -164133,7 +169378,7 @@ Shifting token number (1.12: 1) Entering state 1 Stack now 0 8 22 4 1 -Reducing stack by rule 5 (line 79): +Reducing stack by rule 5 (line 92): $1 = token number (1.12: 1) -> $$ = nterm exp (1.12: 1) Entering state 12 @@ -164148,14 +169393,16 @@ Shifting token number (1.16: 1) Entering state 1 Stack now 0 8 22 4 12 19 1 -Reducing stack by rule 5 (line 79): +Reducing stack by rule 5 (line 92): $1 = token number (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 28 Stack now 0 8 22 4 12 19 28 Reading a token Next token is token ')' (1.17: ) -Reducing stack by rule 8 (line 91): +LAC: initial context established for ')' +LAC: checking lookahead ')': R8 G12 S26 +Reducing stack by rule 8 (line 104): $1 = nterm exp (1.12: 1) $2 = token '-' (1.14: ) $3 = nterm exp (1.16: 1) @@ -164164,9 +169411,10 @@ Stack now 0 8 22 4 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) +LAC: initial context discarded due to shift Entering state 26 Stack now 0 8 22 4 12 26 -Reducing stack by rule 13 (line 104): +Reducing stack by rule 13 (line 117): $1 = token '(' (1.11: ) $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) @@ -164175,7 +169423,9 @@ Stack now 0 8 22 31 Reading a token Next token is token '\n' (1.18-2.0: ) -Reducing stack by rule 10 (line 93): +LAC: initial context established for '\n' +LAC: checking lookahead '\n': R10 G8 S24 +Reducing stack by rule 10 (line 106): $1 = nterm exp (1.1-7: 2) $2 = token '/' (1.9: ) $3 = nterm exp (1.11-17: 0) @@ -164185,45 +169435,30 @@ Stack now 0 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) +LAC: initial context discarded due to shift Entering state 24 Stack now 0 8 24 -Reducing stack by rule 4 (line 75): +Reducing stack by rule 4 (line 88): $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Stack now 0 7 -Reducing stack by rule 1 (line 69): +Reducing stack by rule 1 (line 82): $1 = nterm line (1.1-2.0: ) -> $$ = nterm input (1.1-2.0: ) Entering state 6 Stack now 0 6 Reading a token -Next token is token end of input (2.1: ) -Shifting token end of input (2.1: ) +Next token is token end of file (2.1: ) +Shifting token end of file (2.1: ) Entering state 16 Stack now 0 6 16 Stack now 0 6 16 -Cleanup: popping token end of input (2.1: ) +Cleanup: popping token end of file (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -input: -stderr: -stderr: - | 1 2 -./calc.at:1455: $PREPARSER ./calc input -syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) -stderr: -stderr: -./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1458: cat stderr -./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.1-46: error: 4444 != 1 -./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1446: "$PERL" -pi -e 'use strict; +./calc.at:1449: cat stderr +./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -164233,87 +169468,64 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token number (1.3: 2) -LAC: initial context established for number -LAC: checking lookahead number: Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: Err -LAC: checking lookahead '=': S18 -LAC: checking lookahead '-': S19 -LAC: checking lookahead '+': S20 -LAC: checking lookahead '*': S21 -LAC: checking lookahead '/': S22 -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token number (1.3: 2) -Stack now 0 -./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./calc.at:1459: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1455: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1458: cat stderr +536. calc.at:1449: ok +./calc.at:1451: cat stderr +./calc.at:1468: cat stderr +./calc.at:1455: cat stderr +input: +input: + | 1 + 2 * 3 + !- ++ +./calc.at:1459: $PREPARSER ./calc input +input: stderr: + | (#) + (#) = 2222 +./calc.at:1458: $PREPARSER ./calc input + | (- *) + (1 2) = 1 +./calc.at:1468: $PREPARSER ./calc input input: -./calc.at:1446: cat stderr - | (1 + #) = 1111 -./calc.at:1449: $PREPARSER ./calc input -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token number (1.3: 2) -LAC: initial context established for number -LAC: checking lookahead number: Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: Err -LAC: checking lookahead '=': S18 -LAC: checking lookahead '-': S19 -LAC: checking lookahead '+': S20 -LAC: checking lookahead '*': S21 -LAC: checking lookahead '/': S22 -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token number (1.3: 2) -Stack now 0 +540. calc.at:1455: ok + | (1 + 1) / (1 - 1) +./calc.at:1451: $PREPARSER ./calc input stderr: -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.1-46: error: 4444 != 1 stderr: -syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) -547. calc.at:1476: testing Calculator glr2.cc ... -input: stderr: - | 1//2 -1.6: syntax error: invalid character: '#' -./calc.at:1451: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1455: "$PERL" -pi -e 'use strict; +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +syntax error +error: 2222 != 1 +./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + +1.11-17: error: null divisor +./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +syntax error +syntax error +error: 2222 != 1 +stderr: +stderr: +1.11-17: error: null divisor +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' + +./calc.at:1459: cat stderr +./calc.at:1451: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -164323,8 +169535,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1458: $PREPARSER ./calc input -./calc.at:1454: "$PERL" -pi -e 'use strict; +./calc.at:1458: cat stderr +./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -164334,122 +169546,126 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1476: mv calc.y.tmp calc.y +551. calc.at:1478: testing Calculator glr2.cc %locations api.location.type={Span} ... +./calc.at:1478: mv calc.y.tmp calc.y +input: +./calc.at:1478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y + | (#) + (#) = 2222 +./calc.at:1459: $PREPARSER ./calc input stderr: -534. calc.at:1446: ok -./calc.at:1455: cat stderr -./calc.at:1454: cat stderr +./calc.at:1451: cat stderr +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' input: +./calc.at:1468: cat stderr +552. calc.at:1479: testing Calculator C++ %glr-parser %header parse.error=verbose %name-prefix "calc" %verbose ... +./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +537. calc.at:1451: ok + | (1 + #) = 1111 +./calc.at:1479: mv calc.y.tmp calc.y + +./calc.at:1458: $PREPARSER ./calc input +stderr: +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +stderr: 1.6: syntax error: invalid character: '#' - | 1//2 -./calc.at:1455: $PREPARSER ./calc input +./calc.at:1479: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +input: + | (* *) + (*) + (*) +./calc.at:1459: cat stderr +./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1468: $PREPARSER ./calc input + stderr: -1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) +./calc.at:1478: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: -./calc.at:1476: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 22 -Stack now 0 8 22 -Reading a token -Next token is token '/' (1.3: ) -LAC: initial context established for '/' -LAC: checking lookahead '/': Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': Err -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) -Stack now 0 -./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +syntax error +syntax error +./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +1.6: syntax error: invalid character: '#' + | (1 + #) = 1111 +./calc.at:1459: $PREPARSER ./calc input stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 22 -Stack now 0 8 22 -Reading a token -Next token is token '/' (1.3: ) -LAC: initial context established for '/' -LAC: checking lookahead '/': Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': Err -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '/' (1.3: ) -Stack now 0 +stderr: +syntax error +syntax error +syntax error +./calc.at:1458: cat stderr +1.6: syntax error: invalid character: '#' +553. calc.at:1479: testing Calculator glr2.cc %header parse.error=verbose %name-prefix "calc" %verbose ... +./calc.at:1479: mv calc.y.tmp calc.y + +./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1479: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS +input: +./calc.at:1468: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (# + 1) = 1111 +./calc.at:1458: $PREPARSER ./calc input +./calc.at:1479: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +stderr: +stderr: +1.6: syntax error: invalid character: '#' +1.2: syntax error: invalid character: '#' ./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1468: cat stderr +./calc.at:1459: cat stderr +stderr: +1.2: syntax error: invalid character: '#' input: - | 1 + 2 * 3 + !- ++ -./calc.at:1451: $PREPARSER ./calc input +input: + | 1 + 2 * 3 + !+ ++ +./calc.at:1468: $PREPARSER ./calc input + | (# + 1) = 1111 +./calc.at:1459: $PREPARSER ./calc input +./calc.at:1458: cat stderr stderr: -./calc.at:1457: cat stderr -./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) +./calc.at:1479: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS +1.2: syntax error: invalid character: '#' +./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: + | (1 + # + 1) = 1111 +./calc.at:1458: $PREPARSER ./calc input stderr: stderr: +1.2: syntax error: invalid character: '#' input: - | (!!) + (1 2) = 1 -./calc.at:1454: $PREPARSER ./calc input + | 1 + 2 * 3 + !- ++ +./calc.at:1468: $PREPARSER ./calc input +1.6: syntax error: invalid character: '#' +stderr: +./calc.at:1459: cat stderr +./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.6: syntax error: invalid character: '#' +stderr: input: -./calc.at:1449: "$PERL" -pi -e 'use strict; + | (1 + # + 1) = 1111 +./calc.at:1459: $PREPARSER ./calc input +./calc.at:1458: cat stderr +stderr: +1.6: syntax error: invalid character: '#' +input: +./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + 1) / (1 - 1) +./calc.at:1458: $PREPARSER ./calc input +./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -164459,9 +169675,36 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - -stdout: -./calc.at:1455: "$PERL" -pi -e 'use strict; +stderr: +stderr: +1.6: syntax error: invalid character: '#' +1.11-17: error: null divisor +./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1468: cat stderr +./calc.at:1459: cat stderr +input: +stderr: + | (#) + (#) = 2222 +./calc.at:1468: $PREPARSER ./calc input +1.11-17: error: null divisor +stderr: +input: +syntax error: invalid character: '#' +syntax error: invalid character: '#' + | (1 + 1) / (1 - 1) +./calc.at:1459: $PREPARSER ./calc input +./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.11-17: error: null divisor +stderr: +./calc.at:1458: cat stderr +syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +542. calc.at:1458: ok +1.11-17: error: null divisor +./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -164471,8 +169714,28 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1459: cat stderr +543. calc.at:1459: ok + +./calc.at:1468: cat stderr +input: + + | (1 + #) = 1111 +./calc.at:1468: $PREPARSER ./calc input stderr: -./calc.at:1451: "$PERL" -pi -e 'use strict; +syntax error: invalid character: '#' +./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +554. calc.at:1480: testing Calculator C++ %glr-parser parse.error=verbose api.prefix={calc} %verbose ... +./calc.at:1480: mv calc.y.tmp calc.y + +stderr: +./calc.at:1480: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +syntax error: invalid character: '#' +555. calc.at:1480: testing Calculator glr2.cc parse.error=verbose api.prefix={calc} %verbose ... +./calc.at:1480: mv calc.y.tmp calc.y + +./calc.at:1480: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -164482,7 +169745,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1459: "$PERL" -ne ' +./calc.at:1468: cat stderr +stderr: +stdout: +input: +./calc.at:1477: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. @@ -164493,22 +169760,13 @@ || /\t/ )' calc.cc - | 1 = 2 = 3 -./calc.at:1457: $PREPARSER ./calc input -./calc.at:1455: cat stderr -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 -./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -stderr: + | (# + 1) = 1111 +./calc.at:1468: $PREPARSER ./calc input stderr: -./calc.at:1451: cat stderr -1.11: syntax error, unexpected number -1.1-16: error: 2222 != 1 -./calc.at:1458: cat stderr -./calc.at:1449: cat stderr -syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) input: +./calc.at:1480: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +syntax error: invalid character: '#' +./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -164522,73 +169780,17 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 - | error -./calc.at:1459: $PREPARSER ./calc input -./calc.at:1455: $PREPARSER ./calc input -./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1477: $PREPARSER ./calc input +./calc.at:1480: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token invalid token (1.1: ) -LAC: initial context established for invalid token -LAC: checking lookahead invalid token: Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': S3 -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -Stack now 0 -./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error: invalid character: '#' stderr: -548. calc.at:1477: testing Calculator C++ %glr-parser %locations ... -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token invalid token (1.1: ) -LAC: initial context established for invalid token -LAC: checking lookahead invalid token: Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': S3 -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -Stack now 0 -input: -input: -stderr: -syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) -./calc.at:1476: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS input: -./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | error -./calc.at:1458: $PREPARSER ./calc input - | (#) + (#) = 2222 -./calc.at:1451: $PREPARSER ./calc input -./calc.at:1455: "$PERL" -pi -e 'use strict; + | 1 2 +./calc.at:1477: $PREPARSER ./calc input +./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -164598,14 +169800,13 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1477: mv calc.y.tmp calc.y - -stderr: -./calc.at:1455: cat stderr stderr: +1.3: syntax error +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - | (# + 1) = 1111 -./calc.at:1454: "$PERL" -pi -e 'use strict; +1.3: syntax error +./calc.at:1468: cat stderr +./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -164615,81 +169816,53 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1477: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: - | 1 = 2 = 3 -./calc.at:1455: $PREPARSER ./calc input -./calc.at:1449: $PREPARSER ./calc input + | (1 + # + 1) = 1111 +./calc.at:1468: $PREPARSER ./calc input stderr: -1.2: syntax error: invalid character: '#' -./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1454: cat stderr -./calc.at:1459: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1477: cat stderr +syntax error: invalid character: '#' +./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +stdout: +./calc.at:1476: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + stderr: -1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '=' (1.7: ) -LAC: checking lookahead '=': Err -LAC: checking lookahead end of file: R6 G8 Err -LAC: checking lookahead number: R6 G8 Err -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S19 -LAC: checking lookahead '+': S20 -LAC: checking lookahead '*': S21 -LAC: checking lookahead '/': S22 -LAC: checking lookahead NEG: R6 G8 Err -LAC: checking lookahead '^': S23 -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 18 -Error: popping token '=' (1.3: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) -Stack now 0 -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +input: +syntax error: invalid character: '#' + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1476: $PREPARSER ./calc input + | 1//2 +./calc.at:1477: $PREPARSER ./calc input stderr: +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +1.3: syntax error +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.2: syntax error: invalid character: '#' -1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1451: "$PERL" -pi -e 'use strict; +./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -164700,60 +169873,13 @@ }eg ' expout || exit 77 input: -./calc.at:1457: cat stderr - | (- *) + (1 2) = 1 -./calc.at:1454: $PREPARSER ./calc input -input: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '=' (1.7: ) -LAC: checking lookahead '=': Err -LAC: checking lookahead end of file: R6 G8 Err -LAC: checking lookahead number: R6 G8 Err -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S19 -LAC: checking lookahead '+': S20 -LAC: checking lookahead '*': S21 -LAC: checking lookahead '/': S22 -LAC: checking lookahead NEG: R6 G8 Err -LAC: checking lookahead '^': S23 -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Stack now 0 8 18 -Error: popping token '=' (1.3: ) -Stack now 0 8 -Error: popping nterm exp (1.1: 1) -Stack now 0 -Cleanup: discarding lookahead token '=' (1.7: ) -Stack now 0 -./calc.at:1449: "$PERL" -pi -e 'use strict; +stderr: + | 1 2 +1.3: syntax error +./calc.at:1476: $PREPARSER ./calc input +stderr: +syntax error +./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -164763,31 +169889,21 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1458: cat stderr -stderr: - | 1 2 -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.12: syntax error, unexpected number -1.1-17: error: 2222 != 1 -./calc.at:1459: $PREPARSER ./calc input -./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1451: cat stderr +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1468: cat stderr stderr: -1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) +syntax error input: - | (1 + #) = 1111 -./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1449: cat stderr -./calc.at:1451: $PREPARSER ./calc input -stderr: +./calc.at:1477: cat stderr + | (1 + 1) / (1 - 1) +./calc.at:1468: $PREPARSER ./calc input stderr: input: -1.6: syntax error: invalid character: '#' -input: -./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | - | +1 -./calc.at:1455: "$PERL" -pi -e 'use strict; +error: null divisor + | error +./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1477: $PREPARSER ./calc input +./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -164797,29 +169913,16 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1457: $PREPARSER ./calc input -input: - | (1 + # + 1) = 1111 -./calc.at:1449: $PREPARSER ./calc input -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.12: syntax error, unexpected number -1.1-17: error: 2222 != 1 -stderr: -stderr: -syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) stderr: -./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.6: syntax error: invalid character: '#' +1.1: syntax error +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) - | 1 = 2 = 3 -1.3: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) -./calc.at:1458: $PREPARSER ./calc input +error: null divisor stderr: -./calc.at:1454: "$PERL" -pi -e 'use strict; +./calc.at:1476: cat stderr +1.1: syntax error +input: +./calc.at:1468: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -164829,10 +169932,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -1.6: syntax error: invalid character: '#' -stderr: -./calc.at:1455: cat stderr -./calc.at:1451: "$PERL" -pi -e 'use strict; +./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -164842,9 +169942,25 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1459: cat stderr + | 1//2 +./calc.at:1476: $PREPARSER ./calc input +stderr: +syntax error +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1468: cat stderr +./calc.at:1477: cat stderr +stderr: +syntax error +544. calc.at:1468: ok input: -./calc.at:1449: "$PERL" -pi -e 'use strict; + | 1 = 2 = 3 +./calc.at:1477: $PREPARSER ./calc input +stderr: +1.7: syntax error +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + +stderr: +./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -164854,121 +169970,42 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | - | +1 -./calc.at:1455: $PREPARSER ./calc input -1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) -./calc.at:1477: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -input: -./calc.at:1454: cat stderr - | 1//2 -./calc.at:1459: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 87): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 82): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '+' (2.1: ) -LAC: initial context established for '+' -LAC: checking lookahead '+': Err -LAC: checking lookahead end of file: S16 -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': S3 -LAC: checking lookahead '(': S4 -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) -Stack now 0 -./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1449: cat stderr -./calc.at:1457: cat stderr -./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1451: cat stderr -stderr: -1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) -stderr: -./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1457: $PREPARSER ./calc /dev/null -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Stack now 0 3 -Reducing stack by rule 3 (line 87): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 82): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token '+' (2.1: ) -LAC: initial context established for '+' -LAC: checking lookahead '+': Err -LAC: checking lookahead end of file: S16 -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': S3 -LAC: checking lookahead '(': S4 -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Stack now 0 -Cleanup: discarding lookahead token '+' (2.1: ) -Stack now 0 +1.7: syntax error +./calc.at:1477: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1476: cat stderr +556. calc.at:1482: testing Calculator C++ %glr-parser %debug ... +./calc.at:1482: mv calc.y.tmp calc.y + +./calc.at:1477: cat stderr +./calc.at:1482: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y input: -stderr: - | (* *) + (*) + (*) -syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1454: $PREPARSER ./calc input + | error +./calc.at:1476: $PREPARSER ./calc input input: -1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) + | + | +1 +./calc.at:1477: $PREPARSER ./calc input stderr: stderr: -input: -syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) +syntax error +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +2.1: syntax error +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - | (# + 1) = 1111 -./calc.at:1451: $PREPARSER ./calc input -1.3: syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) stderr: -./calc.at:1455: "$PERL" -pi -e 'use strict; +syntax error +2.1: syntax error +./calc.at:1482: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -164978,35 +170015,62 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (1 + 1) / (1 - 1) -./calc.at:1449: $PREPARSER ./calc input stderr: -1.11-17: error: null divisor -./calc.at:1449: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.2: syntax error: invalid character: '#' -./calc.at:1457: cat stderr -./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1476: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stdout: +./calc.at:1477: cat stderr +./calc.at:1478: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +./calc.at:1477: $PREPARSER ./calc /dev/null +./calc.at:1476: cat stderr stderr: -./calc.at:1458: cat stderr +input: +1.1: syntax error +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1478: $PREPARSER ./calc input stderr: -1.2: syntax error: invalid character: '#' -1.11-17: error: null divisor -./calc.at:1455: cat stderr stderr: -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -./calc.at:1459: cat stderr - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1455: $PREPARSER ./calc /dev/null +1.1: syntax error + | 1 = 2 = 3 +./calc.at:1476: $PREPARSER ./calc input stderr: -./calc.at:1457: $PREPARSER ./calc input -./calc.at:1449: "$PERL" -pi -e 'use strict; +syntax error +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -165016,34 +170080,19 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +stderr: input: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token end of file (1.1: ) -LAC: initial context established for end of file -LAC: checking lookahead end of file: Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': S3 -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.1: syntax error, unexpected end of file -Cleanup: discarding lookahead token end of file (1.1: ) -Stack now 0 -./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | error -./calc.at:1459: $PREPARSER ./calc input -./calc.at:1451: "$PERL" -pi -e 'use strict; + | 1 2 +syntax error +./calc.at:1478: $PREPARSER ./calc input +./calc.at:1477: cat stderr +stderr: +1.3: syntax error +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +input: +1.3: syntax error +./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -165053,7 +170102,16 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1454: "$PERL" -pi -e 'use strict; + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1477: $PREPARSER ./calc input +stderr: +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -165063,55 +170121,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -stderr: -stderr: -syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -error: 4444 != 1 -./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token end of file (1.1: ) -LAC: initial context established for end of file -LAC: checking lookahead end of file: Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': S3 -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.1: syntax error, unexpected end of file -Cleanup: discarding lookahead token end of file (1.1: ) -Stack now 0 -./calc.at:1454: cat stderr -1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) - | - | +1 -stderr: -./calc.at:1458: $PREPARSER ./calc input stderr: -./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) -syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -error: 4444 != 1 -./calc.at:1449: cat stderr -./calc.at:1455: "$PERL" -pi -e 'use strict; +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 +./calc.at:1476: cat stderr +./calc.at:1478: cat stderr +./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -165121,886 +170139,32 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1451: cat stderr -./calc.at:1455: cat stderr -stderr: -2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) -input: -stderr: - | 1 + 2 * 3 + !+ ++ -1.1: syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1454: $PREPARSER ./calc input -536. calc.at:1449: ok input: -./calc.at:1458: cat stderr -stderr: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1455: $PREPARSER ./calc input + | + | +1 +./calc.at:1476: $PREPARSER ./calc input input: -./calc.at:1457: cat stderr -./calc.at:1458: $PREPARSER ./calc /dev/null -./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1459: cat stderr -stderr: -1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) - | (1 + # + 1) = 1111 -./calc.at:1451: $PREPARSER ./calc input - -./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1477: cat stderr stderr: -input: + | 1//2 +./calc.at:1478: $PREPARSER ./calc input stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token ')' (1.2: ) -LAC: initial context established for ')' -LAC: checking lookahead ')': Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': Err -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -LAC: initial context discarded due to error recovery -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token number (1.7: 1) -Shifting token number (1.7: 1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 20 -Stack now 0 8 20 4 12 20 -Reading a token -Next token is token number (1.11: 1) -Shifting token number (1.11: 1) -Entering state 1 -Stack now 0 8 20 4 12 20 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.11: 1) --> $$ = nterm exp (1.11: 1) -Entering state 29 -Stack now 0 8 20 4 12 20 29 -Reading a token -Next token is token '+' (1.13: ) -LAC: initial context established for '+' -LAC: checking lookahead '+': R7 G12 S20 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Stack now 0 8 20 4 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -LAC: initial context discarded due to shift -Entering state 20 -Stack now 0 8 20 4 12 20 -Reading a token -Next token is token number (1.15: 1) -Shifting token number (1.15: 1) -Entering state 1 -Stack now 0 8 20 4 12 20 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 29 -Stack now 0 8 20 4 12 20 29 -Reading a token -Next token is token '+' (1.17: ) -LAC: initial context established for '+' -LAC: checking lookahead '+': R7 G12 S20 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Stack now 0 8 20 4 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -LAC: initial context discarded due to shift -Entering state 20 -Stack now 0 8 20 4 12 20 -Reading a token -Next token is token ')' (1.18: ) -LAC: initial context established for ')' -LAC: checking lookahead ')': Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': Err -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Stack now 0 8 20 4 12 -Error: popping nterm exp (1.7-15: 3) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.7-18: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '+' (1.20: ) -LAC: initial context established for '+' -LAC: checking lookahead '+': R7 G8 S20 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) -LAC: initial context discarded due to shift -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token '*' (1.23: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': Err -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -LAC: initial context discarded due to error recovery -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token '*' (1.23: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -Error: discarding token '*' (1.23: ) -Error: popping token error (1.23: ) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token '*' (1.25: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -Error: discarding token '*' (1.25: ) -Error: popping token error (1.23: ) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.23-25: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token '*' (1.27: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -Error: discarding token '*' (1.27: ) -Error: popping token error (1.23-25: ) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.23-27: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '+' (1.30: ) -LAC: initial context established for '+' -LAC: checking lookahead '+': R7 G8 S20 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) -LAC: initial context discarded due to shift -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token number (1.33: 1) -Shifting token number (1.33: 1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 21 -Stack now 0 8 20 4 12 21 -Reading a token -Next token is token number (1.37: 2) -Shifting token number (1.37: 2) -Entering state 1 -Stack now 0 8 20 4 12 21 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 30 -Stack now 0 8 20 4 12 21 30 -Reading a token -Next token is token '*' (1.39: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': R9 G12 S21 -Reducing stack by rule 9 (line 105): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) -Entering state 12 -Stack now 0 8 20 4 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -LAC: initial context discarded due to shift -Entering state 21 -Stack now 0 8 20 4 12 21 -Reading a token -Next token is token '*' (1.41: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': Err -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Stack now 0 8 20 4 12 -Error: popping nterm exp (1.33-37: 2) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.33-41: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token '*' (1.41: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -Error: discarding token '*' (1.41: ) -Error: popping token error (1.33-41: ) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.33-41: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '=' (1.44: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R7 G8 S18 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) -LAC: initial context discarded due to shift -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.46: 1) -Shifting token number (1.46: 1) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.46: 1) --> $$ = nterm exp (1.46: 1) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.47-2.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R6 G8 S24 -Reducing stack by rule 6 (line 93): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 82): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of file (2.1: ) -Shifting token end of file (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1454: $EGREP -c -v 'Return for a new token:|LAC:' stderr +syntax error +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.3: syntax error +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: - | 1 = 2 = 3 -./calc.at:1459: $PREPARSER ./calc input -stderr: -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token ')' (1.2: ) -LAC: initial context established for ')' -LAC: checking lookahead ')': Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': Err -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -LAC: initial context discarded due to error recovery -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token number (1.7: 1) -Shifting token number (1.7: 1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 20 -Stack now 0 8 20 4 12 20 -Reading a token -Next token is token number (1.11: 1) -Shifting token number (1.11: 1) -Entering state 1 -Stack now 0 8 20 4 12 20 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.11: 1) --> $$ = nterm exp (1.11: 1) -Entering state 29 -Stack now 0 8 20 4 12 20 29 -Reading a token -Next token is token '+' (1.13: ) -LAC: initial context established for '+' -LAC: checking lookahead '+': R7 G12 S20 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Stack now 0 8 20 4 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -LAC: initial context discarded due to shift -Entering state 20 -Stack now 0 8 20 4 12 20 -Reading a token -Next token is token number (1.15: 1) -Shifting token number (1.15: 1) -Entering state 1 -Stack now 0 8 20 4 12 20 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 29 -Stack now 0 8 20 4 12 20 29 -Reading a token -Next token is token '+' (1.17: ) -LAC: initial context established for '+' -LAC: checking lookahead '+': R7 G12 S20 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Stack now 0 8 20 4 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -LAC: initial context discarded due to shift -Entering state 20 -Stack now 0 8 20 4 12 20 -Reading a token -Next token is token ')' (1.18: ) -LAC: initial context established for ')' -LAC: checking lookahead ')': Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': Err -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Stack now 0 8 20 4 12 -Error: popping nterm exp (1.7-15: 3) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.7-18: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '+' (1.20: ) -LAC: initial context established for '+' -LAC: checking lookahead '+': R7 G8 S20 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) -LAC: initial context discarded due to shift -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token '*' (1.23: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': Err -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -LAC: initial context discarded due to error recovery -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token '*' (1.23: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -Error: discarding token '*' (1.23: ) -Error: popping token error (1.23: ) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.23: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token '*' (1.25: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -Error: discarding token '*' (1.25: ) -Error: popping token error (1.23: ) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.23-25: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token '*' (1.27: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -Error: discarding token '*' (1.27: ) -Error: popping token error (1.23-25: ) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.23-27: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '+' (1.30: ) -LAC: initial context established for '+' -LAC: checking lookahead '+': R7 G8 S20 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) -LAC: initial context discarded due to shift -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token number (1.33: 1) -Shifting token number (1.33: 1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 21 -Stack now 0 8 20 4 12 21 -Reading a token -Next token is token number (1.37: 2) -Shifting token number (1.37: 2) -Entering state 1 -Stack now 0 8 20 4 12 21 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 30 -Stack now 0 8 20 4 12 21 30 -Reading a token -Next token is token '*' (1.39: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': R9 G12 S21 -Reducing stack by rule 9 (line 105): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) -Entering state 12 -Stack now 0 8 20 4 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -LAC: initial context discarded due to shift -Entering state 21 -Stack now 0 8 20 4 12 21 -Reading a token -Next token is token '*' (1.41: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': Err -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Stack now 0 8 20 4 12 -Error: popping nterm exp (1.33-37: 2) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.33-41: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token '*' (1.41: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -Error: discarding token '*' (1.41: ) -Error: popping token error (1.33-41: ) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.33-41: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '=' (1.44: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R7 G8 S18 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) -LAC: initial context discarded due to shift -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.46: 1) -Shifting token number (1.46: 1) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.46: 1) --> $$ = nterm exp (1.46: 1) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.47-2.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R6 G8 S24 -Reducing stack by rule 6 (line 93): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 82): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of file (2.1: ) -Shifting token end of file (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +syntax error | (!!) + (1 2) = 1 -./calc.at:1457: $PREPARSER ./calc input -1.6: syntax error: invalid character: '#' -./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) -stderr: -1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) -549. calc.at:1477: testing Calculator glr2.cc %locations ... stderr: +./calc.at:1477: $PREPARSER ./calc input +1.3: syntax error stderr: -./calc.at:1477: mv calc.y.tmp calc.y - -./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1455: "$PERL" -pi -e 'use strict; +1.11: syntax error +1.1-16: error: 2222 != 1 +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -166010,27 +170174,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -error: 2222 != 1 -1.6: syntax error: invalid character: '#' -./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 + 2 * 3 + !- ++ -./calc.at:1454: $PREPARSER ./calc input -./calc.at:1477: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: -syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -error: 2222 != 1 -stderr: -./calc.at:1458: cat stderr -./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1455: cat stderr -stderr: -1.7: syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) -input: - | (!!) + (1 2) = 1 -./calc.at:1451: "$PERL" -pi -e 'use strict; +./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -166040,11 +170185,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1455: $PREPARSER ./calc input -input: -./calc.at:1457: cat stderr -./calc.at:1459: cat stderr -./calc.at:1454: "$PERL" -pi -e 'use strict; +1.11: syntax error +1.1-16: error: 2222 != 1 +./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -166054,387 +170197,36 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1478: cat stderr +./calc.at:1476: cat stderr input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 - | - | +1 -./calc.at:1459: $PREPARSER ./calc input -stderr: -stderr: -2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) -./calc.at:1458: $PREPARSER ./calc input -stderr: -./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Stack now 0 4 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 15 -Stack now 0 4 5 15 -Reducing stack by rule 16 (line 120): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Stack now 0 4 -Shifting token error (1.2-3: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token number (1.9: 1) -Shifting token number (1.9: 1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.9: 1) --> $$ = nterm exp (1.9: 1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token number (1.11: 2) -LAC: initial context established for number -LAC: checking lookahead number: Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: Err -LAC: checking lookahead '=': S18 -LAC: checking lookahead '-': S19 -LAC: checking lookahead '+': S20 -LAC: checking lookahead '*': S21 -LAC: checking lookahead '/': S22 -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.9-11: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token number (1.11: 2) -LAC: initial context established for number -LAC: checking lookahead number: Err -Error: discarding token number (1.11: 2) -Error: popping token error (1.9-11: ) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.9-11: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '=' (1.14: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R7 G8 S18 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) -LAC: initial context discarded due to shift -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.17-2.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R6 G8 S24 -Reducing stack by rule 6 (line 93): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 82): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of file (2.1: ) -Shifting token end of file (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1476: $PREPARSER ./calc /dev/null + | error +./calc.at:1478: $PREPARSER ./calc input +./calc.at:1477: cat stderr stderr: -2.1: syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) -1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.1-46: error: 4444 != 1 -./calc.at:1454: cat stderr -./calc.at:1459: cat stderr -./calc.at:1459: $PREPARSER ./calc /dev/null stderr: -1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) +1.1: syntax error +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -./calc.at:1451: cat stderr -./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: | (- *) + (1 2) = 1 -./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1457: $PREPARSER ./calc input -./calc.at:1477: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -stderr: -stderr: -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -error: 2222 != 1 -input: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Stack now 0 4 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 15 -Stack now 0 4 5 15 -Reducing stack by rule 16 (line 120): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Stack now 0 4 -Shifting token error (1.2-3: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token number (1.9: 1) -Shifting token number (1.9: 1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.9: 1) --> $$ = nterm exp (1.9: 1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token number (1.11: 2) -LAC: initial context established for number -LAC: checking lookahead number: Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: Err -LAC: checking lookahead '=': S18 -LAC: checking lookahead '-': S19 -LAC: checking lookahead '+': S20 -LAC: checking lookahead '*': S21 -LAC: checking lookahead '/': S22 -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.9-11: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token number (1.11: 2) -LAC: initial context established for number -LAC: checking lookahead number: Err -Error: discarding token number (1.11: 2) -Error: popping token error (1.9-11: ) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.9-11: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '=' (1.14: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R7 G8 S18 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) -LAC: initial context discarded due to shift -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.17-2.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R6 G8 S24 -Reducing stack by rule 6 (line 93): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 82): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of file (2.1: ) -Shifting token end of file (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.1: syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) -stderr: -1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.1-46: error: 4444 != 1 -input: stderr: - | (#) + (#) = 2222 - | (1 + 1) / (1 - 1) -./calc.at:1451: $PREPARSER ./calc input -./calc.at:1454: $PREPARSER ./calc input +./calc.at:1477: $PREPARSER ./calc input +syntax error +1.1: syntax error stderr: -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -error: 2222 != 1 +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1459: cat stderr -1.11-17: error: null divisor -./calc.at:1455: "$PERL" -pi -e 'use strict; +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 +./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -166444,24 +170236,17 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1451: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1458: cat stderr -stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1455: cat stderr -stderr: -./calc.at:1457: cat stderr -input: - | (- *) + (1 2) = 1 -./calc.at:1455: $PREPARSER ./calc input -1.11-17: error: null divisor -input: -input: -stderr: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1459: $PREPARSER ./calc input -./calc.at:1454: "$PERL" -pi -e 'use strict; +./calc.at:1476: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -166471,210 +170256,40 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1478: cat stderr +./calc.at:1477: cat stderr input: - | (!!) + (1 2) = 1 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Stack now 0 4 2 -Reading a token -Next token is token '*' (1.4: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': Err -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -LAC: initial context discarded due to error recovery -Shifting token error (1.4: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 119): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.4: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2-4: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token number (1.12: 2) -LAC: initial context established for number -LAC: checking lookahead number: Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: Err -LAC: checking lookahead '=': S18 -LAC: checking lookahead '-': S19 -LAC: checking lookahead '+': S20 -LAC: checking lookahead '*': S21 -LAC: checking lookahead '/': S22 -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token number (1.12: 2) -LAC: initial context established for number -LAC: checking lookahead number: Err -Error: discarding token number (1.12: 2) -Error: popping token error (1.10-12: ) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '=' (1.15: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R7 G8 S18 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) -LAC: initial context discarded due to shift -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.17: 1) --> $$ = nterm exp (1.17: 1) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.18-2.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R6 G8 S24 -Reducing stack by rule 6 (line 93): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 82): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of file (2.1: ) -Shifting token end of file (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -stderr: -./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1458: $PREPARSER ./calc input -./calc.at:1454: cat stderr + | 1 = 2 = 3 +./calc.at:1478: $PREPARSER ./calc input +./calc.at:1476: cat stderr stderr: +1.7: syntax error +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: | (* *) + (*) + (*) -1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.1-46: error: 4444 != 1 -./calc.at:1457: $PREPARSER ./calc input -1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-16: error: 2222 != 1 +input: +./calc.at:1477: $PREPARSER ./calc input + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: -./calc.at:1451: "$PERL" -pi -e 'use strict; +./calc.at:1476: $PREPARSER ./calc input +1.2: syntax error +1.10: syntax error +1.16: syntax error +stderr: +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.7: syntax error +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.2: syntax error +1.10: syntax error +1.16: syntax error +./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -166684,204 +170299,27 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Stack now 0 4 2 -Reading a token -Next token is token '*' (1.4: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': Err -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -LAC: initial context discarded due to error recovery -Shifting token error (1.4: ) -Entering state 9 -Stack now 0 4 2 9 -Reducing stack by rule 15 (line 119): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Stack now 0 4 -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.4: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2-4: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) -Entering state 1 -Stack now 0 8 20 4 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Stack now 0 8 20 4 12 -Reading a token -Next token is token number (1.12: 2) -LAC: initial context established for number -LAC: checking lookahead number: Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: Err -LAC: checking lookahead '=': S18 -LAC: checking lookahead '-': S19 -LAC: checking lookahead '+': S20 -LAC: checking lookahead '*': S21 -LAC: checking lookahead '/': S22 -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token number (1.12: 2) -LAC: initial context established for number -LAC: checking lookahead number: Err -Error: discarding token number (1.12: 2) -Error: popping token error (1.10-12: ) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.10-12: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '=' (1.15: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R7 G8 S18 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) -LAC: initial context discarded due to shift -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.17: 1) --> $$ = nterm exp (1.17: 1) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.18-2.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R6 G8 S24 -Reducing stack by rule 6 (line 93): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 82): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of file (2.1: ) -Shifting token end of file (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -input: +./calc.at:1477: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 +./calc.at:1478: cat stderr stderr: +./calc.at:1477: cat stderr stdout: -./calc.at:1468: "$PERL" -ne ' +./calc.at:1476: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. @@ -166892,15 +170330,7 @@ || /\t/ )' calc.cc -./calc.at:1451: cat stderr -stderr: -1.2: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.18: syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -1.23: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.41: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.1-46: error: 4444 != 1 - | (1 + #) = 1111 -./calc.at:1455: "$PERL" -pi -e 'use strict; +./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -166910,12 +170340,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1454: $PREPARSER ./calc input -537. calc.at:1451: ok -stderr: -1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-16: error: 2222 != 1 input: +input: +input: + | + | +1 +./calc.at:1478: $PREPARSER ./calc input + | 1 + 2 * 3 + !+ ++ +./calc.at:1477: $PREPARSER ./calc input | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -166929,472 +170361,92 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -./calc.at:1468: $PREPARSER ./calc input -./calc.at:1455: cat stderr +./calc.at:1476: $PREPARSER ./calc input stderr: stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1459: cat stderr -./calc.at:1457: cat stderr +2.1: syntax error +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1476: cat stderr +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1458: cat stderr +stderr: +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +2.1: syntax error stderr: input: -1.6: syntax error: invalid character: '#' -input: - +stderr: | (!!) + (1 2) = 1 -./calc.at:1459: $PREPARSER ./calc input - | (* *) + (*) + (*) +input: +./calc.at:1476: $PREPARSER ./calc input + | 1 2 +./calc.at:1476: $PREPARSER ./calc input stderr: -./calc.at:1455: $PREPARSER ./calc input +./calc.at:1478: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '*' (1.2: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': Err -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -LAC: initial context discarded due to error recovery -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.2: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -Error: discarding token '*' (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '*' (1.4: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token '*' (1.10: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': Err -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -LAC: initial context discarded due to error recovery -Shifting token error (1.10: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token '*' (1.10: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -Error: discarding token '*' (1.10: ) -Error: popping token error (1.10: ) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.10: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '+' (1.13: ) -LAC: initial context established for '+' -LAC: checking lookahead '+': R7 G8 S20 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -LAC: initial context discarded due to shift -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token '*' (1.16: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': Err -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -LAC: initial context discarded due to error recovery -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token '*' (1.16: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -Error: discarding token '*' (1.16: ) -Error: popping token error (1.16: ) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '\n' (1.18-2.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R7 G8 S24 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 82): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of file (2.1: ) -Shifting token end of file (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +error: 2222 != 1 +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: + | 1 + 2 * 3 + !- ++ +syntax error +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1477: $PREPARSER ./calc input stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token '*' (1.2: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': Err -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -LAC: initial context discarded due to error recovery -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token '*' (1.2: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -Error: discarding token '*' (1.2: ) -Error: popping token error (1.2: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '*' (1.4: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -Error: discarding token '*' (1.4: ) -Error: popping token error (1.2: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.2-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token '*' (1.10: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': Err -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -LAC: initial context discarded due to error recovery -Shifting token error (1.10: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token '*' (1.10: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -Error: discarding token '*' (1.10: ) -Error: popping token error (1.10: ) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.10: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '+' (1.13: ) -LAC: initial context established for '+' -LAC: checking lookahead '+': R7 G8 S20 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -LAC: initial context discarded due to shift -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -Next token is token '*' (1.16: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -LAC: checking lookahead end of file: Err -LAC: checking lookahead number: S1 -LAC: checking lookahead '=': Err -LAC: checking lookahead '-': S2 -LAC: checking lookahead '+': Err -LAC: checking lookahead '*': Err -LAC: checking lookahead '/': Err -LAC: checking lookahead NEG: Err -LAC: checking lookahead '^': Err -LAC: checking lookahead '\n': Err -LAC: checking lookahead '(': S4 -LAC: checking lookahead ')': Err -LAC: checking lookahead '!': S5 -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -LAC: initial context discarded due to error recovery -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token '*' (1.16: ) -LAC: initial context established for '*' -LAC: checking lookahead '*': Err -Error: discarding token '*' (1.16: ) -Error: popping token error (1.16: ) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.16: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '\n' (1.18-2.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R7 G8 S24 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 82): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of file (2.1: ) -Shifting token end of file (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-16: error: 2222 != 1 -input: -./calc.at:1455: "$PERL" -pi -e 'use strict; +stderr: +syntax error +error: 2222 != 1 +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +syntax error +./calc.at:1478: cat stderr +stderr: +./calc.at:1478: $PREPARSER ./calc /dev/null +stderr: +stderr: +stdout: +./calc.at:1480: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +./calc.at:1476: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +1.1: syntax error +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1477: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -167404,16 +170456,32 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1 2 input: -./calc.at:1468: $PREPARSER ./calc input -./calc.at:1455: cat stderr stderr: -./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error - | 1 + 2 * 3 + !+ ++ -./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1454: "$PERL" -pi -e 'use strict; + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1480: $PREPARSER ./calc input +1.1: syntax error +./calc.at:1476: cat stderr +stderr: +./calc.at:1476: cat stderr +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1477: cat stderr +stderr: +input: + | 1 2 +./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -167423,35 +170491,80 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1457: $PREPARSER ./calc input +./calc.at:1480: $PREPARSER ./calc input +input: +stderr: | (- *) + (1 2) = 1 +./calc.at:1476: $PREPARSER ./calc input +input: + | 1//2 +./calc.at:1476: $PREPARSER ./calc input +syntax error, unexpected number +input: +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1458: $PREPARSER ./calc input -./calc.at:1454: cat stderr stderr: +./calc.at:1478: cat stderr stderr: -1.11: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-16: error: 2222 != 1 syntax error -1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-17: error: 2222 != 1 +syntax error +error: 2222 != 1 + | (#) + (#) = 2222 +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1477: $PREPARSER ./calc input +syntax error +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -input: - | 1 + 2 * 3 + !+ ++ -./calc.at:1455: $PREPARSER ./calc input -./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1459: cat stderr stderr: -./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: stderr: -550. calc.at:1478: testing Calculator C++ %glr-parser %locations api.location.type={Span} ... -./calc.at:1478: mv calc.y.tmp calc.y +syntax error, unexpected number +./calc.at:1469: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc -./calc.at:1478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +syntax error +syntax error +error: 2222 != 1 +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +stderr: +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error input: -./calc.at:1457: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1468: "$PERL" -pi -e 'use strict; +input: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1478: $PREPARSER ./calc input +stderr: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +stderr: +./calc.at:1469: $PREPARSER ./calc input +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -167461,202 +170574,39 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (# + 1) = 1111 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 20 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 -Stack now 0 8 20 29 21 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 20 29 21 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 -Stack now 0 8 20 29 21 30 -Reading a token -Next token is token '+' (1.11: ) -LAC: initial context established for '+' -LAC: checking lookahead '+': R9 G29 R7 G8 S20 -Reducing stack by rule 9 (line 105): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Stack now 0 8 20 29 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -LAC: initial context discarded due to shift -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 20 5 -Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Stack now 0 8 20 5 14 -Reducing stack by rule 17 (line 121): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Stack now 0 8 20 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -stderr: -1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-17: error: 2222 != 1 -./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1454: $PREPARSER ./calc input -stderr: - | (- *) + (1 2) = 1 -./calc.at:1459: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' -./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +1.8: syntax error: invalid character: '#' stderr: -1.2: syntax error: invalid character: '#' -input: +./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1476: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-17: error: 2222 != 1 - | 1 + 2 * 3 + !- ++ -./calc.at:1468: cat stderr -./calc.at:1457: $PREPARSER ./calc input -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 20 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 -Stack now 0 8 20 29 21 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 20 29 21 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 -Stack now 0 8 20 29 21 30 -Reading a token -Next token is token '+' (1.11: ) -LAC: initial context established for '+' -LAC: checking lookahead '+': R9 G29 R7 G8 S20 -Reducing stack by rule 9 (line 105): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Stack now 0 8 20 29 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -LAC: initial context discarded due to shift -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 20 5 -Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Stack now 0 8 20 5 14 -Reducing stack by rule 17 (line 121): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Stack now 0 8 20 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1458: cat stderr -./calc.at:1455: $EGREP -c -v 'Return for a new token:|LAC:' stderr +./calc.at:1476: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1454: "$PERL" -pi -e 'use strict; +./calc.at:1480: cat stderr +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 +./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -167666,215 +170616,94 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1476: cat stderr input: + | 1 2 +./calc.at:1469: $PREPARSER ./calc input +./calc.at:1476: cat stderr input: - | 1 + 2 * 3 + !- ++ -./calc.at:1455: $PREPARSER ./calc input -./calc.at:1454: cat stderr - | (* *) + (*) + (*) -./calc.at:1458: $PREPARSER ./calc input +./calc.at:1478: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 20 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 -Stack now 0 8 20 29 21 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 20 29 21 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 -Stack now 0 8 20 29 21 30 -Reading a token -Next token is token '+' (1.11: ) -LAC: initial context established for '+' -LAC: checking lookahead '+': R9 G29 R7 G8 S20 -Reducing stack by rule 9 (line 105): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Stack now 0 8 20 29 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -LAC: initial context discarded due to shift -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 20 5 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Stack now 0 8 20 5 13 -Reducing stack by rule 18 (line 122): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Stack now 0 8 20 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -input: -./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1//2 -./calc.at:1468: $PREPARSER ./calc input +input: +./calc.at:1480: $PREPARSER ./calc input +syntax error +./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: + | (* *) + (*) + (*) stderr: +./calc.at:1476: $PREPARSER ./calc input +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +input: +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1477: cat stderr +syntax error stderr: -1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) + | error +./calc.at:1476: $PREPARSER ./calc input +./calc.at:1478: cat stderr +syntax error +syntax error +syntax error stderr: -./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error -./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.4: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.12: syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -1.1-17: error: 2222 != 1 +stderr: input: +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | (1 + #) = 1111 +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +./calc.at:1477: $PREPARSER ./calc input stderr: + | (!!) + (1 2) = 1 +./calc.at:1478: $PREPARSER ./calc input +syntax error +syntax error syntax error stderr: - | (1 + # + 1) = 1111 -./calc.at:1454: $PREPARSER ./calc input stderr: +./calc.at:1469: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -./calc.at:1457: cat stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Stack now 0 8 20 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 -Stack now 0 8 20 29 21 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Stack now 0 8 20 29 21 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 -Stack now 0 8 20 29 21 30 -Reading a token -Next token is token '+' (1.11: ) -LAC: initial context established for '+' -LAC: checking lookahead '+': R9 G29 R7 G8 S20 -Reducing stack by rule 9 (line 105): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Stack now 0 8 20 29 -Next token is token '+' (1.11: ) -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Stack now 0 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -LAC: initial context discarded due to shift -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Stack now 0 8 20 5 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Stack now 0 8 20 5 13 -Reducing stack by rule 18 (line 122): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Stack now 0 8 20 -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error 1.6: syntax error: invalid character: '#' -./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.11: syntax error +1.1-16: error: 2222 != 1 +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1469: cat stderr +stderr: +./calc.at:1480: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -./calc.at:1459: cat stderr 1.6: syntax error: invalid character: '#' -./calc.at:1468: "$PERL" -pi -e 'use strict; +./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -167884,15 +170713,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1478: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -./calc.at:1458: cat stderr -input: -input: - | (#) + (#) = 2222 -./calc.at:1457: $PREPARSER ./calc input +1.11: syntax error +1.1-16: error: 2222 != 1 +./calc.at:1480: cat stderr input: -./calc.at:1468: cat stderr -./calc.at:1455: "$PERL" -pi -e 'use strict; +./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -167902,8 +170727,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (* *) + (*) + (*) -./calc.at:1454: "$PERL" -pi -e 'use strict; +./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -167913,194 +170737,62 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1459: $PREPARSER ./calc input -stderr: - | 1 + 2 * 3 + !+ ++ -./calc.at:1458: $PREPARSER ./calc input -stderr: -./calc.at:1454: cat stderr + | 1//2 +./calc.at:1469: $PREPARSER ./calc input input: -syntax error: invalid character: '#' -syntax error: invalid character: '#' -1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1455: cat stderr +./calc.at:1478: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 | error -./calc.at:1468: $PREPARSER ./calc input stderr: -./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1480: $PREPARSER ./calc input +syntax error +./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error: invalid character: '#' -syntax error: invalid character: '#' +syntax error, unexpected invalid token +./calc.at:1476: cat stderr +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1476: cat stderr +./calc.at:1477: cat stderr +./calc.at:1478: cat stderr +stderr: +input: syntax error -./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: - | (1 + 1) / (1 - 1) -./calc.at:1454: $PREPARSER ./calc input stderr: + | 1 + 2 * 3 + !+ ++ +syntax error, unexpected invalid token +./calc.at:1476: $PREPARSER ./calc input input: + | (# + 1) = 1111 stderr: -./calc.at:1458: $EGREP -c -v 'Return for a new token:|LAC:' stderr - | (#) + (#) = 2222 -./calc.at:1455: $PREPARSER ./calc input -stderr: +./calc.at:1477: $PREPARSER ./calc input + | 1 = 2 = 3 +input: +./calc.at:1476: $PREPARSER ./calc input stderr: -1.2: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.10: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.16: syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -1.11-17: error: null divisor +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (- *) + (1 2) = 1 stderr: -./calc.at:1454: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token +./calc.at:1478: $PREPARSER ./calc input 1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.1-2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -LAC: initial context established for invalid token -LAC: checking lookahead invalid token: Err -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.1-2: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.1-2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.1: ) - $2 = token error (1.1-2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -1.8: syntax error: invalid character: '#' -Next token is token error (1.8: ) -Shifting token error (1.1-8: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token invalid token (1.8: ) -LAC: initial context established for invalid token -LAC: checking lookahead invalid token: Err -Error: discarding token invalid token (1.8: ) -Error: popping token error (1.1-8: ) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.1-8: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.7: ) - $2 = token error (1.1-8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '=' (1.11: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R7 G8 S18 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -LAC: initial context discarded due to shift -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.13-16: 2222) -Shifting token number (1.13-16: 2222) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.17-2.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R6 G8 S24 -Reducing stack by rule 6 (line 93): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 82): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of file (2.1: ) -Shifting token end of file (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) syntax error -./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1457: cat stderr -./calc.at:1459: cat stderr -stderr: -input: +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - | 1 + 2 * 3 + !- ++ -./calc.at:1458: $PREPARSER ./calc input +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 stderr: -./calc.at:1468: "$PERL" -pi -e 'use strict; +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -168110,160 +170802,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.1-2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -LAC: initial context established for invalid token -LAC: checking lookahead invalid token: Err -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.1-2: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.1-2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.1: ) - $2 = token error (1.1-2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 20 -Stack now 0 8 20 -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Stack now 0 8 20 4 -Reading a token -1.8: syntax error: invalid character: '#' -Next token is token error (1.8: ) -Shifting token error (1.1-8: ) -Entering state 11 -Stack now 0 8 20 4 11 -Next token is token invalid token (1.8: ) -LAC: initial context established for invalid token -LAC: checking lookahead invalid token: Err -Error: discarding token invalid token (1.8: ) -Error: popping token error (1.1-8: ) -Stack now 0 8 20 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.1-8: ) -Entering state 11 -Stack now 0 8 20 4 11 -Reading a token -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 25 -Stack now 0 8 20 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.7: ) - $2 = token error (1.1-8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 29 -Stack now 0 8 20 29 -Reading a token -Next token is token '=' (1.11: ) -LAC: initial context established for '=' -LAC: checking lookahead '=': R7 G8 S18 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -LAC: initial context discarded due to shift -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.13-16: 2222) -Shifting token number (1.13-16: 2222) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.17-2.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R6 G8 S24 -Reducing stack by rule 6 (line 93): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 82): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of file (2.1: ) -Shifting token end of file (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1468: cat stderr -1.11-17: error: null divisor -input: - | (1 + #) = 1111 -./calc.at:1457: $PREPARSER ./calc input stderr: -syntax error: invalid character: '#' -./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error: invalid character: '#' stderr: - | 1 + 2 * 3 + !+ ++ -input: -./calc.at:1459: $PREPARSER ./calc input - | 1 = 2 = 3 -./calc.at:1468: $PREPARSER ./calc input -./calc.at:1454: "$PERL" -pi -e 'use strict; +./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -168273,12 +170815,29 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +1.2: syntax error: invalid character: '#' stderr: -stderr: +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 syntax error -./calc.at:1454: cat stderr -./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1455: "$PERL" -pi -e 'use strict; + | 1 + 2 * 3 + !- ++ +./calc.at:1476: $PREPARSER ./calc input +stderr: +./calc.at:1469: cat stderr +./calc.at:1480: cat stderr +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1477: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -168288,26 +170847,36 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1458: cat stderr stderr: -./calc.at:1455: cat stderr -syntax error -539. calc.at:1454: ok -./calc.at:1457: cat stderr -./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: - | (#) + (#) = 2222 -./calc.at:1458: $PREPARSER ./calc input +./calc.at:1476: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 input: + | error +./calc.at:1469: $PREPARSER ./calc input + | 1 = 2 = 3 +./calc.at:1480: $PREPARSER ./calc input +./calc.at:1478: cat stderr +./calc.at:1477: cat stderr stderr: stderr: - | (# + 1) = 1111 -./calc.at:1459: $EGREP -c -v 'Return for a new token:|LAC:' stderr -./calc.at:1457: $PREPARSER ./calc input +syntax error, unexpected '=' +./calc.at:1476: cat stderr +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1468: "$PERL" -pi -e 'use strict; +input: + | (* *) + (*) + (*) +./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -168317,2307 +170886,37 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (1 + #) = 1111 -./calc.at:1455: $PREPARSER ./calc input +./calc.at:1478: $PREPARSER ./calc input + | (1 + # + 1) = 1111 +stderr: +./calc.at:1477: $PREPARSER ./calc input +stderr: input: - | 1 + 2 * 3 + !- ++ stderr: -./calc.at:1459: $PREPARSER ./calc input stderr: +1.2: syntax error +1.10: syntax error +1.16: syntax error +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +syntax error, unexpected '=' + | + | +1 +./calc.at:1476: $PREPARSER ./calc input stderr: -syntax error: invalid character: '#' -./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Stack now 0 4 12 20 -Reading a token 1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -LAC: initial context established for invalid token -LAC: checking lookahead invalid token: Err -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R6 G8 S24 -Reducing stack by rule 6 (line 93): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 82): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of file (2.1: ) -Shifting token end of file (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - -stderr: -syntax error: invalid character: '#' -./calc.at:1468: cat stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Stack now 0 4 12 20 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -LAC: initial context established for invalid token -LAC: checking lookahead invalid token: Err -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R6 G8 S24 -Reducing stack by rule 6 (line 93): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 82): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of file (2.1: ) -Shifting token end of file (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -stderr: -stderr: -stdout: -./calc.at:1476: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -stderr: -input: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1476: $PREPARSER ./calc input -./calc.at:1455: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -551. calc.at:1478: testing Calculator glr2.cc %locations api.location.type={Span} ... -./calc.at:1455: cat stderr -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1478: mv calc.y.tmp calc.y - -./calc.at:1478: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -input: - | - | +1 -stderr: -./calc.at:1468: $PREPARSER ./calc input -input: -./calc.at:1458: cat stderr - | (# + 1) = 1111 -./calc.at:1455: $PREPARSER ./calc input -stderr: -./calc.at:1459: cat stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.1-2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -LAC: initial context established for invalid token -LAC: checking lookahead invalid token: Err -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.1-2: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.1-2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.4: ) -LAC: initial context established for '+' -LAC: checking lookahead '+': Err -Error: discarding token '+' (1.4: ) -Error: popping token error (1.1-2: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.1-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1.6: 1) -LAC: initial context established for number -LAC: checking lookahead number: Err -Error: discarding token number (1.6: 1) -Error: popping token error (1.1-4: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.1-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.1: ) - $2 = token error (1.1-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R6 G8 S24 -Reducing stack by rule 6 (line 93): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 82): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of file (2.1: ) -Shifting token end of file (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: -syntax error -input: - | 1 2 -./calc.at:1476: $PREPARSER ./calc input -./calc.at:1457: cat stderr -stderr: -./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (1 + #) = 1111 -./calc.at:1458: $PREPARSER ./calc input -input: -stderr: -stderr: -syntax error -1.6: syntax error: invalid character: '#' -stderr: - | (#) + (#) = 2222 -./calc.at:1459: $PREPARSER ./calc input -./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.1-2: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.2: ) -LAC: initial context established for invalid token -LAC: checking lookahead invalid token: Err -Error: discarding token invalid token (1.2: ) -Error: popping token error (1.1-2: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.1-2: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.4: ) -LAC: initial context established for '+' -LAC: checking lookahead '+': Err -Error: discarding token '+' (1.4: ) -Error: popping token error (1.1-2: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.1-4: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1.6: 1) -LAC: initial context established for number -LAC: checking lookahead number: Err -Error: discarding token number (1.6: 1) -Error: popping token error (1.1-4: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.1-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.1: ) - $2 = token error (1.1-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R6 G8 S24 -Reducing stack by rule 6 (line 93): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 82): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of file (2.1: ) -Shifting token end of file (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -input: -syntax error - | (1 + # + 1) = 1111 -./calc.at:1457: $PREPARSER ./calc input -./calc.at:1455: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1478: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -stderr: -./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.6: syntax error: invalid character: '#' -./calc.at:1468: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -stderr: -syntax error: invalid character: '#' -./calc.at:1455: cat stderr -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1458: cat stderr -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1459: cat stderr -input: -./calc.at:1468: cat stderr - | (# + 1) = 1111 -./calc.at:1458: $PREPARSER ./calc input -stderr: -1.2: syntax error: invalid character: '#' -input: -./calc.at:1468: $PREPARSER ./calc /dev/null - | (1 + # + 1) = 1111 -./calc.at:1455: $PREPARSER ./calc input -./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error -./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1457: cat stderr -stderr: -input: - | (1 + 1) / (1 - 1) -./calc.at:1457: $PREPARSER ./calc input - | (1 + #) = 1111 -./calc.at:1476: cat stderr -./calc.at:1459: $PREPARSER ./calc input -stderr: -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Stack now 0 4 12 20 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -LAC: initial context established for invalid token -LAC: checking lookahead invalid token: Err -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.8: ) -LAC: initial context established for '+' -LAC: checking lookahead '+': Err -Error: discarding token '+' (1.8: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.2-8: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1.10: 1) -LAC: initial context established for number -LAC: checking lookahead number: Err -Error: discarding token number (1.10: 1) -Error: popping token error (1.2-8: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.2-10: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.15-18: 1111) -Shifting token number (1.15-18: 1111) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.19-2.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R6 G8 S24 -Reducing stack by rule 6 (line 93): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 82): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of file (2.1: ) -Shifting token end of file (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -stderr: -error: null divisor -./calc.at:1457: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -error: null divisor -1.6: syntax error: invalid character: '#' -1.2: syntax error: invalid character: '#' -syntax error -input: -stderr: -./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Stack now 0 4 12 20 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Stack now 0 4 12 -Error: popping nterm exp (1.2: 1) -Stack now 0 4 -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Next token is token invalid token (1.6: ) -LAC: initial context established for invalid token -LAC: checking lookahead invalid token: Err -Error: discarding token invalid token (1.6: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.2-6: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token '+' (1.8: ) -LAC: initial context established for '+' -LAC: checking lookahead '+': Err -Error: discarding token '+' (1.8: ) -Error: popping token error (1.2-6: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.2-8: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token number (1.10: 1) -LAC: initial context established for number -LAC: checking lookahead number: Err -Error: discarding token number (1.10: 1) -Error: popping token error (1.2-8: ) -Stack now 0 4 -LAC: initial context discarded due to error recovery -Shifting token error (1.2-10: ) -Entering state 11 -Stack now 0 4 11 -Reading a token -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 25 -Stack now 0 4 11 25 -Reducing stack by rule 14 (line 118): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) -Entering state 18 -Stack now 0 8 18 -Reading a token -Next token is token number (1.15-18: 1111) -Shifting token number (1.15-18: 1111) -Entering state 1 -Stack now 0 8 18 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) -Entering state 27 -Stack now 0 8 18 27 -Reading a token -Next token is token '\n' (1.19-2.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R6 G8 S24 -Reducing stack by rule 6 (line 93): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 82): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of file (2.1: ) -Shifting token end of file (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - | 1//2 -./calc.at:1476: $PREPARSER ./calc input -stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1455: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -syntax error -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1458: cat stderr -./calc.at:1455: cat stderr -./calc.at:1468: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1457: cat stderr -input: -./calc.at:1459: cat stderr -input: - | (1 + # + 1) = 1111 -stderr: -./calc.at:1468: cat stderr -syntax error -./calc.at:1458: $PREPARSER ./calc input - | (1 + 1) / (1 - 1) -541. calc.at:1457: ok -./calc.at:1455: $PREPARSER ./calc input -stderr: -1.6: syntax error: invalid character: '#' -stderr: -input: - | (# + 1) = 1111 -stderr: -input: -./calc.at:1459: $PREPARSER ./calc input -stderr: -stdout: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Stack now 0 4 12 20 -Reading a token -Next token is token number (1.6: 1) -Shifting token number (1.6: 1) -Entering state 1 -Stack now 0 4 12 20 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 29 -Stack now 0 4 12 20 29 -Reading a token -Next token is token ')' (1.7: ) -LAC: initial context established for ')' -LAC: checking lookahead ')': R7 G12 S26 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Stack now 0 4 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -LAC: initial context discarded due to shift -Entering state 26 -Stack now 0 4 12 26 -Reducing stack by rule 13 (line 117): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 22 -Stack now 0 8 22 -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Stack now 0 8 22 4 -Reading a token -Next token is token number (1.12: 1) -Shifting token number (1.12: 1) -Entering state 1 -Stack now 0 8 22 4 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Stack now 0 8 22 4 12 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 19 -Stack now 0 8 22 4 12 19 -Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) -Entering state 1 -Stack now 0 8 22 4 12 19 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 28 -Stack now 0 8 22 4 12 19 28 -Reading a token -Next token is token ')' (1.17: ) -LAC: initial context established for ')' -LAC: checking lookahead ')': R8 G12 S26 -Reducing stack by rule 8 (line 104): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Stack now 0 8 22 4 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -LAC: initial context discarded due to shift -Entering state 26 -Stack now 0 8 22 4 12 26 -Reducing stack by rule 13 (line 117): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 31 -Stack now 0 8 22 31 -Reading a token -Next token is token '\n' (1.18-2.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R10 G8 S24 -Reducing stack by rule 10 (line 106): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 82): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of file (2.1: ) -Shifting token end of file (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -1.2: syntax error: invalid character: '#' -./calc.at:1468: $PREPARSER ./calc input -./calc.at:1455: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1477: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - -stderr: -./calc.at:1458: cat stderr -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | (1 + 1) / (1 - 1) -./calc.at:1458: $PREPARSER ./calc input -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 -./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.11-17: error: null divisor -input: -stderr: -1.2: syntax error: invalid character: '#' -stderr: -stderr: -./calc.at:1458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1477: $PREPARSER ./calc input -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Stack now 0 4 -Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Stack now 0 4 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Stack now 0 4 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Stack now 0 4 12 20 -Reading a token -Next token is token number (1.6: 1) -Shifting token number (1.6: 1) -Entering state 1 -Stack now 0 4 12 20 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 29 -Stack now 0 4 12 20 29 -Reading a token -Next token is token ')' (1.7: ) -LAC: initial context established for ')' -LAC: checking lookahead ')': R7 G12 S26 -Reducing stack by rule 7 (line 103): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Stack now 0 4 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -LAC: initial context discarded due to shift -Entering state 26 -Stack now 0 4 12 26 -Reducing stack by rule 13 (line 117): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) -Entering state 8 -Stack now 0 8 -Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 22 -Stack now 0 8 22 -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Stack now 0 8 22 4 -Reading a token -Next token is token number (1.12: 1) -Shifting token number (1.12: 1) -Entering state 1 -Stack now 0 8 22 4 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Stack now 0 8 22 4 12 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 19 -Stack now 0 8 22 4 12 19 -Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) -Entering state 1 -Stack now 0 8 22 4 12 19 1 -Reducing stack by rule 5 (line 92): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 28 -Stack now 0 8 22 4 12 19 28 -Reading a token -Next token is token ')' (1.17: ) -LAC: initial context established for ')' -LAC: checking lookahead ')': R8 G12 S26 -Reducing stack by rule 8 (line 104): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Stack now 0 8 22 4 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -LAC: initial context discarded due to shift -Entering state 26 -Stack now 0 8 22 4 12 26 -Reducing stack by rule 13 (line 117): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 31 -Stack now 0 8 22 31 -Reading a token -Next token is token '\n' (1.18-2.0: ) -LAC: initial context established for '\n' -LAC: checking lookahead '\n': R10 G8 S24 -Reducing stack by rule 10 (line 106): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) -Entering state 8 -Stack now 0 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -LAC: initial context discarded due to shift -Entering state 24 -Stack now 0 8 24 -Reducing stack by rule 4 (line 88): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Stack now 0 7 -Reducing stack by rule 1 (line 82): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Stack now 0 6 -Reading a token -Next token is token end of file (2.1: ) -Shifting token end of file (2.1: ) -Entering state 16 -Stack now 0 6 16 -Stack now 0 6 16 -Cleanup: popping token end of file (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1476: cat stderr - -stderr: -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1459: cat stderr -stderr: -stderr: - | error -input: - | 1 2 -./calc.at:1476: $PREPARSER ./calc input -stderr: -./calc.at:1477: $PREPARSER ./calc input -1.11-17: error: null divisor -stderr: -syntax error -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.3: syntax error -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: -./calc.at:1455: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1468: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error -./calc.at:1458: cat stderr - | (1 + # + 1) = 1111 -./calc.at:1459: $PREPARSER ./calc input -stderr: -1.3: syntax error -./calc.at:1455: cat stderr -stderr: -1.6: syntax error: invalid character: '#' -552. calc.at:1479: testing Calculator C++ %glr-parser %header parse.error=verbose %name-prefix "calc" %verbose ... -./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -542. calc.at:1458: ok -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1479: mv calc.y.tmp calc.y - -stderr: -./calc.at:1468: cat stderr -1.6: syntax error: invalid character: '#' -540. calc.at:1455: ok -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1476: cat stderr -./calc.at:1479: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -input: -input: -./calc.at:1459: cat stderr - | 1 = 2 = 3 -./calc.at:1476: $PREPARSER ./calc input - | (!!) + (1 2) = 1 -./calc.at:1468: $PREPARSER ./calc input -stderr: -syntax error -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1477: cat stderr -stderr: -syntax error - -syntax error -error: 2222 != 1 -./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | (1 + 1) / (1 - 1) -stderr: -./calc.at:1459: $PREPARSER ./calc input - -stderr: -syntax error -error: 2222 != 1 -input: -1.11-17: error: null divisor - | 1//2 -./calc.at:1477: $PREPARSER ./calc input -./calc.at:1459: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -553. calc.at:1479: testing Calculator glr2.cc %header parse.error=verbose %name-prefix "calc" %verbose ... -./calc.at:1479: mv calc.y.tmp calc.y - -1.3: syntax error -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.3: syntax error -./calc.at:1479: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS -stderr: -1.11-17: error: null divisor -./calc.at:1468: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1479: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -./calc.at:1476: cat stderr -./calc.at:1459: cat stderr -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1468: cat stderr -input: - | - | +1 -./calc.at:1476: $PREPARSER ./calc input -543. calc.at:1459: ok -stderr: -554. calc.at:1480: testing Calculator C++ %glr-parser parse.error=verbose api.prefix={calc} %verbose ... -input: -./calc.at:1480: mv calc.y.tmp calc.y - -syntax error -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1480: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y - | (- *) + (1 2) = 1 -./calc.at:1468: $PREPARSER ./calc input -./calc.at:1477: cat stderr -./calc.at:1479: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS -stderr: -stderr: -syntax error -syntax error -error: 2222 != 1 -./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error - -input: -./calc.at:1480: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -stderr: - | error -syntax error -syntax error -error: 2222 != 1 -./calc.at:1477: $PREPARSER ./calc input -stderr: -1.1: syntax error -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.1: syntax error -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1468: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -555. calc.at:1480: testing Calculator glr2.cc parse.error=verbose api.prefix={calc} %verbose ... -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1480: mv calc.y.tmp calc.y - -./calc.at:1476: cat stderr -./calc.at:1480: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -./calc.at:1476: $PREPARSER ./calc /dev/null -./calc.at:1477: cat stderr -./calc.at:1468: cat stderr -stderr: -syntax error -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error -input: -input: - | 1 = 2 = 3 - | (* *) + (*) + (*) -./calc.at:1477: $PREPARSER ./calc input -./calc.at:1468: $PREPARSER ./calc input -stderr: -1.7: syntax error -stderr: -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error -syntax error -syntax error -./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1476: cat stderr -stderr: -syntax error -syntax error -syntax error -1.7: syntax error -input: -./calc.at:1480: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1476: $PREPARSER ./calc input -./calc.at:1468: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1477: cat stderr -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 -./calc.at:1468: cat stderr -stderr: -input: - | 1 + 2 * 3 + !+ ++ -stdout: -./calc.at:1468: $PREPARSER ./calc input -input: -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1469: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - - | - | +1 -./calc.at:1477: $PREPARSER ./calc input -./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: -stderr: -2.1: syntax error -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1469: $PREPARSER ./calc input -stderr: -input: -./calc.at:1476: cat stderr - | 1 + 2 * 3 + !- ++ -stderr: -./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1468: $PREPARSER ./calc input -2.1: syntax error -stderr: -./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: -stderr: -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (!!) + (1 2) = 1 -input: -./calc.at:1476: $PREPARSER ./calc input - | 1 2 -./calc.at:1469: $PREPARSER ./calc input -stderr: -stderr: -syntax error -error: 2222 != 1 -syntax error -./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1477: cat stderr -stderr: -stderr: -stderr: -./calc.at:1468: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error -error: 2222 != 1 -./calc.at:1477: $PREPARSER ./calc /dev/null -stdout: -syntax error -./calc.at:1478: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - -stderr: -1.1: syntax error -input: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1478: $PREPARSER ./calc input -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1468: cat stderr -stderr: -input: - | 1 2 -./calc.at:1478: $PREPARSER ./calc input -./calc.at:1469: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.1: syntax error -stderr: -input: -./calc.at:1476: cat stderr -1.3: syntax error -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (#) + (#) = 2222 -./calc.at:1468: $PREPARSER ./calc input -./calc.at:1469: cat stderr -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -stderr: -./calc.at:1477: cat stderr -syntax error: invalid character: '#' -syntax error: invalid character: '#' -1.3: syntax error -input: -./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1477: $PREPARSER ./calc input - | 1//2 -./calc.at:1469: $PREPARSER ./calc input -stderr: - | (- *) + (1 2) = 1 -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1476: $PREPARSER ./calc input -stderr: -./calc.at:1478: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error -stderr: -./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error -syntax error -error: 2222 != 1 -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 -syntax error: invalid character: '#' -syntax error: invalid character: '#' -stderr: -syntax error -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -syntax error -syntax error -error: 2222 != 1 -./calc.at:1478: cat stderr -input: -./calc.at:1468: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | 1//2 -./calc.at:1478: $PREPARSER ./calc input -./calc.at:1468: cat stderr -./calc.at:1469: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -1.3: syntax error -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1476: cat stderr -stderr: -./calc.at:1477: cat stderr -1.3: syntax error -input: -input: - | (1 + #) = 1111 - | (* *) + (*) + (*) -./calc.at:1476: $PREPARSER ./calc input -./calc.at:1468: $PREPARSER ./calc input -input: -./calc.at:1469: cat stderr -stderr: -syntax error: invalid character: '#' - | (!!) + (1 2) = 1 -./calc.at:1477: $PREPARSER ./calc input -./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1478: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -syntax error -syntax error -syntax error -1.11: syntax error -1.1-16: error: 2222 != 1 -stderr: -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | error -./calc.at:1478: cat stderr -./calc.at:1469: $PREPARSER ./calc input -stderr: -input: - | error -./calc.at:1478: $PREPARSER ./calc input -stderr: -1.11: syntax error -1.1-16: error: 2222 != 1 -syntax error: invalid character: '#' -stderr: -stdout: -stderr: -1.1: syntax error -./calc.at:1476: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error -./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error -syntax error -syntax error -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -input: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1476: $PREPARSER ./calc input -1.1: syntax error -./calc.at:1468: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -stderr: -syntax error -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1477: cat stderr -stderr: -./calc.at:1478: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1468: cat stderr -input: -./calc.at:1478: cat stderr - | 1 2 -./calc.at:1476: $PREPARSER ./calc input -input: - | (- *) + (1 2) = 1 -./calc.at:1477: $PREPARSER ./calc input -stderr: -syntax error -input: -./calc.at:1469: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: - | (# + 1) = 1111 -./calc.at:1468: $PREPARSER ./calc input -input: -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -syntax error - | 1 = 2 = 3 -./calc.at:1478: $PREPARSER ./calc input -syntax error: invalid character: '#' -./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.7: syntax error -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.7: syntax error -stderr: -./calc.at:1469: cat stderr -./calc.at:1476: cat stderr -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 -stderr: -syntax error: invalid character: '#' -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: - | 1 = 2 = 3 -./calc.at:1469: $PREPARSER ./calc input -stderr: -syntax error -input: -./calc.at:1478: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | 1 + 2 * 3 + !+ ++ -./calc.at:1476: cat stderr -./calc.at:1476: $PREPARSER ./calc input -./calc.at:1468: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -stderr: - | 1//2 -./calc.at:1476: $PREPARSER ./calc input -stderr: syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error -stderr: -./calc.at:1478: cat stderr -./calc.at:1468: cat stderr -./calc.at:1477: cat stderr -syntax error -input: -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | - | +1 -input: -./calc.at:1478: $PREPARSER ./calc input -input: ./calc.at:1476: cat stderr - | (* *) + (*) + (*) -./calc.at:1477: $PREPARSER ./calc input -stderr: -input: -1.2: syntax error -1.10: syntax error -1.16: syntax error -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: - | (1 + # + 1) = 1111 -./calc.at:1468: $PREPARSER ./calc input - | error -./calc.at:1476: $PREPARSER ./calc input - | 1 + 2 * 3 + !- ++ -./calc.at:1476: $PREPARSER ./calc input -2.1: syntax error -./calc.at:1469: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -syntax error -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: stderr: 1.2: syntax error 1.10: syntax error 1.16: syntax error stderr: stderr: -2.1: syntax error -syntax error: invalid character: '#' -./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error -./calc.at:1469: cat stderr -stderr: -./calc.at:1477: cat stderr -input: - | 1 + 2 * 3 + !+ ++ -./calc.at:1477: $PREPARSER ./calc input -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -syntax error: invalid character: '#' -./calc.at:1478: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -input: - | - | +1 -input: -./calc.at:1469: $PREPARSER ./calc input -./calc.at:1476: cat stderr - | 1 + 2 * 3 + !- ++ -./calc.at:1477: $PREPARSER ./calc input -stderr: -stderr: -syntax error -./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 = 2 = 3 -stderr: -./calc.at:1476: $PREPARSER ./calc input -syntax error -stderr: -./calc.at:1468: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1478: cat stderr -./calc.at:1478: $PREPARSER ./calc /dev/null -stderr: -stderr: -./calc.at:1468: cat stderr -./calc.at:1476: cat stderr -1.1: syntax error -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: syntax error -1.1: syntax error -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -input: - | (1 + 1) / (1 - 1) -./calc.at:1468: $PREPARSER ./calc input ./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -170628,10 +170927,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (#) + (#) = 2222 -./calc.at:1476: $PREPARSER ./calc input -stderr: -stderr: +1.6: syntax error: invalid character: '#' ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -170642,65 +170938,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1477: cat stderr -error: null divisor -./calc.at:1468: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -syntax error -stderr: | (#) + (#) = 2222 -stderr: -./calc.at:1477: $PREPARSER ./calc input -./calc.at:1469: cat stderr -error: null divisor -stderr: -syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1469: $PREPARSER ./calc /dev/null -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1478: cat stderr -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -stderr: -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1468: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error -./calc.at:1477: "$PERL" -pi -e 'use strict; +./calc.at:1476: $PREPARSER ./calc input +./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -170710,70 +170950,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1476: cat stderr -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1478: $PREPARSER ./calc input -syntax error -input: -stderr: - | (1 + #) = 1111 -./calc.at:1476: $PREPARSER ./calc input -./calc.at:1476: cat stderr stderr: -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1477: cat stderr syntax error: invalid character: '#' -./calc.at:1468: cat stderr -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: syntax error: invalid character: '#' - | - | +1 -./calc.at:1476: $PREPARSER ./calc input -stderr: -stderr: -544. calc.at:1468: ok -syntax error ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 -./calc.at:1469: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1476: cat stderr -input: -stderr: -syntax error -./calc.at:1478: "$PERL" -pi -e 'use strict; +./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -170784,8 +170965,8 @@ }eg ' expout || exit 77 ./calc.at:1469: cat stderr - | (1 + #) = 1111 -./calc.at:1477: $PREPARSER ./calc input +./calc.at:1480: cat stderr +./calc.at:1478: cat stderr stderr: ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} @@ -170797,293 +170978,26 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - - | (# + 1) = 1111 -1.6: syntax error: invalid character: '#' -./calc.at:1476: $PREPARSER ./calc input -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: syntax error: invalid character: '#' -./calc.at:1478: cat stderr -1.6: syntax error: invalid character: '#' -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1469: $PREPARSER ./calc input -stderr: -stderr: -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1476: cat stderr -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 -./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr syntax error: invalid character: '#' -./calc.at:1476: $PREPARSER ./calc /dev/null -input: -stderr: - | (!!) + (1 2) = 1 -syntax error -./calc.at:1478: $PREPARSER ./calc input -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -1.11: syntax error -1.1-16: error: 2222 != 1 -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1477: cat stderr -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 -556. calc.at:1482: testing Calculator C++ %glr-parser %debug ... -./calc.at:1482: mv calc.y.tmp calc.y - -syntax error -./calc.at:1482: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -stderr: -1.11: syntax error -1.1-16: error: 2222 != 1 -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: - | (# + 1) = 1111 -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1477: $PREPARSER ./calc input -./calc.at:1469: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1478: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.2: syntax error: invalid character: '#' -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1476: cat stderr -./calc.at:1482: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -./calc.at:1469: cat stderr -./calc.at:1476: cat stderr -stderr: input: -./calc.at:1478: cat stderr input: -stderr: -stdout: - | (!!) + (1 2) = 1 + | 1 = 2 = 3 ./calc.at:1469: $PREPARSER ./calc input - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1476: $PREPARSER ./calc input -1.2: syntax error: invalid character: '#' -./calc.at:1480: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - -stderr: -syntax error -error: 2222 != 1 -stderr: -./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | (1 + # + 1) = 1111 -./calc.at:1476: $PREPARSER ./calc input -stderr: -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error -error: 2222 != 1 -input: -input: -stderr: -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1480: $PREPARSER ./calc input - | (- *) + (1 2) = 1 -./calc.at:1478: $PREPARSER ./calc input -syntax error: invalid character: '#' -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error -syntax error -syntax error -syntax error -error: 4444 != 1 -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: + | +1 stderr: -syntax error: invalid character: '#' -./calc.at:1469: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 ./calc.at:1477: cat stderr -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1476: cat stderr -./calc.at:1469: cat stderr -stderr: -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 -input: - | (!!) + (1 2) = 1 -./calc.at:1476: $PREPARSER ./calc input -stderr: -syntax error -error: 2222 != 1 -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | (- *) + (1 2) = 1 -./calc.at:1469: $PREPARSER ./calc input -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -stderr: -syntax error -syntax error -error: 2222 != 1 -./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 2 ./calc.at:1480: $PREPARSER ./calc input input: +stdout: stderr: -syntax error -syntax error -error: 2222 != 1 -./calc.at:1478: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (1 + # + 1) = 1111 -./calc.at:1477: $PREPARSER ./calc input + | 1 + 2 * 3 + !+ ++ ./calc.at:1476: cat stderr -stderr: -stderr: +./calc.at:1478: $PREPARSER ./calc input syntax error -error: 2222 != 1 -input: - | (1 + 1) / (1 - 1) -./calc.at:1476: $PREPARSER ./calc input -stderr: -syntax error, unexpected number -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.6: syntax error: invalid character: '#' -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -stdout: -stderr: -./calc.at:1477: "$PERL" -ne ' +./calc.at:1482: "$PERL" -ne ' chomp; print "$ARGV:$.: {$_}\n" if (# No starting/ending empty lines. @@ -171094,268 +171008,20 @@ || /\t/ )' calc.cc -syntax error, unexpected number -./calc.at:1469: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1478: cat stderr -input: -error: null divisor -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1477: $PREPARSER ./calc input -stderr: -stderr: -stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | (* *) + (*) + (*) -./calc.at:1478: $PREPARSER ./calc input -stderr: -error: null divisor -stderr: -1.2: syntax error -1.10: syntax error -1.16: syntax error -./calc.at:1480: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | 1 2 -./calc.at:1480: cat stderr -./calc.at:1477: $PREPARSER ./calc input -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1469: cat stderr -1.2: syntax error -1.10: syntax error -1.16: syntax error -input: - | 1//2 -./calc.at:1480: $PREPARSER ./calc input -stderr: -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.3: syntax error -stderr: -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1478: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | (* *) + (*) + (*) -./calc.at:1469: $PREPARSER ./calc input -stderr: -stderr: -1.3: syntax error -./calc.at:1477: cat stderr -syntax error -syntax error -syntax error ./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1478: cat stderr stderr: -stderr: -input: -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -syntax error -syntax error -syntax error +syntax error, unexpected '+' +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: - | 1 + 2 * 3 + !+ ++ - | (1 + 1) / (1 - 1) -./calc.at:1478: $PREPARSER ./calc input -./calc.at:1477: $PREPARSER ./calc input stderr: -stderr: -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.11-17: error: null divisor ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1476: cat stderr -stderr: -stderr: -./calc.at:1477: cat stderr -input: -1.11-17: error: null divisor -./calc.at:1476: cat stderr -./calc.at:1480: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | 1 + 2 * 3 + !- ++ -./calc.at:1478: $PREPARSER ./calc input +./calc.at:1476: $PREPARSER ./calc /dev/null + | (1 + 1) / (1 - 1) stderr: -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -input: -./calc.at:1480: cat stderr - | 1//2 ./calc.at:1477: $PREPARSER ./calc input - | (- *) + (1 2) = 1 -./calc.at:1469: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1476: $PREPARSER ./calc input -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -546. calc.at:1476: ok -stderr: -input: -stderr: -1.3: syntax error - | error -./calc.at:1480: $PREPARSER ./calc input -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1469: cat stderr -syntax error -syntax error -error: 2222 != 1 -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1477: cat stderr -stderr: -stderr: -syntax error, unexpected invalid token -syntax error syntax error -error: 2222 != 1 -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1478: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -548. calc.at:1477: ok -stderr: input: - -1.3: syntax error - | 1 + 2 * 3 + !+ ++ -./calc.at:1469: $PREPARSER ./calc input -stderr: -./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -stderr: -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error, unexpected invalid token -input: -557. calc.at:1482: testing Calculator glr2.cc %debug ... - | 1 + 2 * 3 + !- ++ -./calc.at:1469: $PREPARSER ./calc input -./calc.at:1482: mv calc.y.tmp calc.y - -./calc.at:1482: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -./calc.at:1478: cat stderr ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -171367,255 +171033,7 @@ }eg ' expout || exit 77 stderr: -./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1477: cat stderr -stderr: -input: - -input: - | (#) + (#) = 2222 -./calc.at:1476: cat stderr -./calc.at:1478: $PREPARSER ./calc input - | error -./calc.at:1477: $PREPARSER ./calc input -stderr: -1.1: syntax error -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1480: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (* *) + (*) + (*) -./calc.at:1476: $PREPARSER ./calc input -stderr: -./calc.at:1482: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -stderr: -stderr: -./calc.at:1480: cat stderr -syntax error -syntax error -syntax error -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.1: syntax error -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1469: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1478: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -558. calc.at:1485: testing Calculator C++ %glr-parser parse.error=detailed %debug %name-prefix "calc" %verbose ... -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1469: cat stderr -input: -input: -syntax error -syntax error syntax error - | 1 = 2 = 3 -./calc.at:1480: $PREPARSER ./calc input -./calc.at:1485: mv calc.y.tmp calc.y - - | (#) + (#) = 2222 -./calc.at:1469: $PREPARSER ./calc input -stderr: -./calc.at:1478: cat stderr -stderr: -./calc.at:1485: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -syntax error, unexpected '=' -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1477: cat stderr -./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | (1 + #) = 1111 -stderr: -./calc.at:1478: $PREPARSER ./calc input -stderr: -syntax error, unexpected '=' -stderr: -input: -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error: invalid character: '#' -syntax error: invalid character: '#' - | 1 = 2 = 3 -./calc.at:1477: $PREPARSER ./calc input -stderr: -1.7: syntax error -1.6: syntax error: invalid character: '#' -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.7: syntax error -stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1485: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -./calc.at:1476: cat stderr -./calc.at:1480: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1480: cat stderr -./calc.at:1469: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1478: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | 1 + 2 * 3 + !+ ++ -./calc.at:1476: $PREPARSER ./calc input -input: - | - | +1 -./calc.at:1480: $PREPARSER ./calc input -stderr: -stderr: -syntax error, unexpected '+' -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1477: cat stderr -./calc.at:1469: cat stderr -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error, unexpected '+' -./calc.at:1478: cat stderr -input: -stderr: - | (1 + #) = 1111 -./calc.at:1469: $PREPARSER ./calc input -input: -stderr: -syntax error: invalid character: '#' -./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | - | +1 -./calc.at:1477: $PREPARSER ./calc input - | 1 + 2 * 3 + !- ++ -./calc.at:1476: $PREPARSER ./calc input -input: -./calc.at:1480: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -stderr: - | (# + 1) = 1111 -./calc.at:1478: $PREPARSER ./calc input -syntax error: invalid character: '#' -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1480: cat stderr -stderr: -2.1: syntax error -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.2: syntax error: invalid character: '#' -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: -./calc.at:1480: $PREPARSER ./calc /dev/null -./calc.at:1479: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc calc.hh - -stderr: -stderr: -stderr: -syntax error, unexpected end of input -1.2: syntax error: invalid character: '#' -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -2.1: syntax error -input: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -171629,799 +171047,18 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 -./calc.at:1479: $PREPARSER ./calc input -stderr: -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1469: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1478: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error, unexpected end of input -stderr: -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1478: cat stderr -./calc.at:1469: cat stderr -./calc.at:1480: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -stdout: - | 1 2 -./calc.at:1479: $PREPARSER ./calc input -./calc.at:1477: cat stderr -./calc.at:1478: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - -./calc.at:1480: cat stderr -input: - | (# + 1) = 1111 -./calc.at:1469: $PREPARSER ./calc input -stderr: -./calc.at:1476: cat stderr -stderr: -syntax error, unexpected number -input: -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1477: $PREPARSER ./calc /dev/null - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1480: $PREPARSER ./calc input -syntax error: invalid character: '#' -input: -./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: - | (1 + # + 1) = 1111 -1.1: syntax error -./calc.at:1478: $PREPARSER ./calc input -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -error: 4444 != 1 -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: -stderr: -1.6: syntax error: invalid character: '#' - | (#) + (#) = 2222 -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1476: $PREPARSER ./calc input -input: -stderr: -syntax error: invalid character: '#' -stderr: -stderr: -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -error: 4444 != 1 -syntax error: invalid character: '#' -syntax error: invalid character: '#' ./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error, unexpected '+' stderr: -1.6: syntax error: invalid character: '#' -syntax error, unexpected number - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1478: $PREPARSER ./calc input -stderr: -stderr: -syntax error: invalid character: '#' -syntax error: invalid character: '#' -1.1: syntax error -stderr: -./calc.at:1469: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1478: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1479: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1480: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1479: cat stderr -./calc.at:1469: cat stderr -./calc.at:1480: cat stderr -input: -stderr: - | 1//2 -./calc.at:1479: $PREPARSER ./calc input -./calc.at:1478: cat stderr -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -input: -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | (1 + # + 1) = 1111 -./calc.at:1469: $PREPARSER ./calc input -input: - | 1 2 - | (!!) + (1 2) = 1 -./calc.at:1478: $PREPARSER ./calc input -./calc.at:1480: $PREPARSER ./calc input -stderr: -./calc.at:1477: cat stderr -stderr: -stderr: -stderr: -syntax error: invalid character: '#' -input: -./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -1.3: syntax error -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1476: cat stderr -stderr: -stderr: -1.3: syntax error -syntax error, unexpected number -error: 2222 != 1 -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error, unexpected number -error: 2222 != 1 - | (1 + 1) / (1 - 1) -syntax error: invalid character: '#' -./calc.at:1478: $PREPARSER ./calc input -./calc.at:1478: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -stderr: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 1.11-17: error: null divisor -./calc.at:1477: $PREPARSER ./calc input -./calc.at:1480: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1478: cat stderr -./calc.at:1479: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 ./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1480: cat stderr +./calc.at:1482: $PREPARSER ./calc input stderr: -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 -./calc.at:1469: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: - | 1//2 - | (1 + #) = 1111 -./calc.at:1478: $PREPARSER ./calc input -./calc.at:1479: cat stderr -./calc.at:1476: $PREPARSER ./calc input stderr: stderr: input: -stderr: -1.3: syntax error -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error 1.11-17: error: null divisor -syntax error: invalid character: '#' -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -1.3: syntax error -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (- *) + (1 2) = 1 -./calc.at:1480: $PREPARSER ./calc input -stderr: -input: - | error -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected number -error: 2222 != 1 -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1477: cat stderr -./calc.at:1478: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1479: $PREPARSER ./calc input -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected number -error: 2222 != 1 -stderr: -./calc.at:1469: cat stderr -./calc.at:1478: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error: invalid character: '#' -stderr: -./calc.at:1480: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error, unexpected invalid token -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1478: cat stderr - | (1 + 1) / (1 - 1) -./calc.at:1469: $PREPARSER ./calc input -stderr: -error: null divisor -./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (!!) + (1 2) = 1 -./calc.at:1477: $PREPARSER ./calc input -./calc.at:1480: cat stderr -stderr: -stderr: -stderr: -syntax error, unexpected invalid token -error: null divisor -1.11: syntax error -1.1-16: error: 2222 != 1 -input: -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | error -./calc.at:1478: $PREPARSER ./calc input -input: -./calc.at:1478: cat stderr -stderr: - | (* *) + (*) + (*) -1.1: syntax error -./calc.at:1480: $PREPARSER ./calc input -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1476: cat stderr -stderr: -stderr: -stderr: -1.1: syntax error -550. calc.at:1478: ok -./calc.at:1479: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1479: cat stderr -1.11: syntax error -1.1-16: error: 2222 != 1 -./calc.at:1469: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -input: -./calc.at:1478: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' - | (# + 1) = 1111 -./calc.at:1476: $PREPARSER ./calc input - -stderr: -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: - | 1 = 2 = 3 -./calc.at:1479: $PREPARSER ./calc input -syntax error: invalid character: '#' -./calc.at:1469: cat stderr -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1478: cat stderr -stderr: -syntax error, unexpected '=' -./calc.at:1480: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -545. calc.at:1469: stderr: - ok -./calc.at:1480: cat stderr -syntax error: invalid character: '#' -input: -./calc.at:1477: cat stderr - | 1 + 2 * 3 + !+ ++ -./calc.at:1480: $PREPARSER ./calc input -stderr: -syntax error, unexpected '=' -559. calc.at:1485: testing Calculator glr2.cc parse.error=detailed %debug %name-prefix "calc" %verbose ... -./calc.at:1485: mv calc.y.tmp calc.y - -input: - | 1 = 2 = 3 -./calc.at:1478: $PREPARSER ./calc input -stderr: -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1485: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y - -input: -stderr: - | 1 + 2 * 3 + !- ++ -./calc.at:1480: $PREPARSER ./calc input -1.7: syntax error -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -./calc.at:1479: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: - | (- *) + (1 2) = 1 -1.7: syntax error -./calc.at:1477: $PREPARSER ./calc input -stderr: -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1479: cat stderr -./calc.at:1476: cat stderr -./calc.at:1480: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1485: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -stderr: -560. calc.at:1486: testing Calculator C++ %glr-parser parse.error=verbose %debug %name-prefix "calc" %verbose ... -./calc.at:1486: mv calc.y.tmp calc.y - -input: -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 - | (1 + # + 1) = 1111 -./calc.at:1476: $PREPARSER ./calc input -./calc.at:1478: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -input: -./calc.at:1486: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -syntax error: invalid character: '#' - | - | +1 -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1480: cat stderr -./calc.at:1479: $PREPARSER ./calc input -stderr: -syntax error: invalid character: '#' -./calc.at:1478: cat stderr -input: -./calc.at:1477: cat stderr -stderr: - | (#) + (#) = 2222 -./calc.at:1480: $PREPARSER ./calc input -syntax error, unexpected '+' -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -stderr: - | (* *) + (*) + (*) -./calc.at:1477: $PREPARSER ./calc input -syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -syntax error: invalid character: '#' -syntax error: invalid character: '#' -syntax error, unexpected '+' -input: -stderr: - | - | +1 -./calc.at:1478: $PREPARSER ./calc input -1.2: syntax error -1.10: syntax error -1.16: syntax error -stderr: -./calc.at:1480: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -2.1: syntax error -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1480: cat stderr -./calc.at:1486: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -input: -./calc.at:1476: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (1 + #) = 1111 -./calc.at:1480: $PREPARSER ./calc input -stderr: -syntax error: invalid character: '#' -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -syntax error: invalid character: '#' -./calc.at:1479: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -1.2: syntax error -1.10: syntax error -1.16: syntax error -stderr: -./calc.at:1476: cat stderr -./calc.at:1479: cat stderr -2.1: syntax error -./calc.at:1477: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1479: $PREPARSER ./calc /dev/null -stderr: -syntax error, unexpected end of input -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1480: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: - | (1 + 1) / (1 - 1) -./calc.at:1476: $PREPARSER ./calc input -stderr: -./calc.at:1480: cat stderr -stderr: -syntax error, unexpected end of input -./calc.at:1478: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1477: cat stderr -error: null divisor -input: - | (# + 1) = 1111 -./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1480: $PREPARSER ./calc input -stderr: -stdout: -stderr: -./calc.at:1482: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - -syntax error: invalid character: '#' -stderr: -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -error: null divisor -input: -./calc.at:1478: cat stderr - | 1 + 2 * 3 + !+ ++ -input: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1482: $PREPARSER ./calc input -./calc.at:1477: $PREPARSER ./calc input -stderr: -stdout: -stderr: Starting parse Entering state 0 Reading a token @@ -173259,18 +171896,22 @@ Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1480: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - -./calc.at:1479: "$PERL" -pi -e 'use strict; + | 1 + 2 * 3 + !- ++ +./calc.at:1478: $PREPARSER ./calc input +./calc.at:1476: cat stderr +stderr: +stderr: +./calc.at:1477: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -173280,11 +171921,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -./calc.at:1478: $PREPARSER ./calc /dev/null -stderr: -stderr: -input: Starting parse Entering state 0 Reading a token @@ -174121,27 +172757,39 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1479: cat stderr stderr: -./calc.at:1480: $PREPARSER ./calc input -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1480: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 input: -1.1: syntax error -stderr: +stdout: | 1 2 +./calc.at:1477: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +./calc.at:1482: $PREPARSER ./calc input +./calc.at:1480: cat stderr +stderr: +input: +stderr: + | (1 + #) = 1111 +./calc.at:1476: $PREPARSER ./calc input ./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -174152,11 +172800,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1482: $PREPARSER ./calc input -syntax error: invalid character: '#' -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +input: Starting parse Entering state 0 Reading a token @@ -174172,15 +172816,46 @@ syntax error Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) +./calc.at:1469: cat stderr ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1477: cat stderr stderr: -input: +./calc.at:1478: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1480: $PREPARSER ./calc /dev/null + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1477: $PREPARSER ./calc input +stderr: +syntax error: invalid character: '#' stderr: +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +548. calc.at:1477: ok +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: - | 1 + 2 * 3 + !- ++ -./calc.at:1477: $PREPARSER ./calc input - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +syntax error, unexpected end of input +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1476: cat stderr Starting parse Entering state 0 Reading a token @@ -174196,33 +172871,33 @@ syntax error Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) -input: -./calc.at:1479: $PREPARSER ./calc input + | + | +1 +./calc.at:1469: $PREPARSER ./calc input stderr: stderr: stderr: -1.1: syntax error -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -error: 4444 != 1 - | 1 2 -./calc.at:1480: $PREPARSER ./calc input -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1476: cat stderr -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1478: cat stderr +syntax error: invalid character: '#' stderr: -syntax error, unexpected number +syntax error +./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +input: + | 1 2 +syntax error, unexpected end of input +./calc.at:1477: $PREPARSER ./calc input +input: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1476: $PREPARSER ./calc input stderr: -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -error: 4444 != 1 stderr: -./calc.at:1478: "$PERL" -pi -e 'use strict; +syntax error +1.3: syntax error + +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (#) + (#) = 2222 +./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174232,8 +172907,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -547. calc.at:1476: ok -./calc.at:1482: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1478: $PREPARSER ./calc input +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 +./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174243,8 +172924,33 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -syntax error, unexpected number +stderr: +stderr: +1.3: syntax error +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +stderr: +./calc.at:1482: cat stderr +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 +./calc.at:1478: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -174255,8 +172961,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1480: cat stderr -./calc.at:1479: "$PERL" -pi -e 'use strict; +./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174266,8 +172971,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1478: cat stderr - +stderr: +./calc.at:1476: cat stderr ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -174278,10 +172983,31 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1480: cat stderr input: input: -./calc.at:1482: cat stderr -./calc.at:1480: "$PERL" -pi -e 'use strict; +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' + | 1//2 + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +557. calc.at:1482: testing Calculator glr2.cc %debug ... +./calc.at:1478: $PREPARSER ./calc input +./calc.at:1482: $PREPARSER ./calc input +./calc.at:1482: mv calc.y.tmp calc.y + +./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174291,59 +173017,22 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1478: $PREPARSER ./calc input -./calc.at:1479: cat stderr - | (1 + # + 1) = 1111 -stderr: ./calc.at:1480: $PREPARSER ./calc input -./calc.at:1480: cat stderr -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -syntax error: invalid character: '#' +./calc.at:1482: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +error: 4444 != 1 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1477: cat stderr -stderr: -1.2: syntax error -1.18: syntax error -1.23: syntax error -1.41: syntax error -1.1-46: error: 4444 != 1 -stderr: -input: -input: -561. calc.at:1486: testing Calculator glr2.cc parse.error=verbose %debug %name-prefix "calc" %verbose ... -syntax error: invalid character: '#' - | (#) + (#) = 2222 -./calc.at:1486: mv calc.y.tmp calc.y - -./calc.at:1477: $PREPARSER ./calc input - | 1//2 -input: input: -./calc.at:1480: $PREPARSER ./calc input - | 1//2 -./calc.at:1482: $PREPARSER ./calc input -stderr: -stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1486: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: - | (!!) + (1 2) = 1 +./calc.at:1477: cat stderr +./calc.at:1469: cat stderr stderr: -./calc.at:1479: $PREPARSER ./calc input -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1478: "$PERL" -pi -e 'use strict; +./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174353,7 +173042,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1478: cat stderr +stderr: +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: + | (# + 1) = 1111 +./calc.at:1476: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -174375,21 +173069,29 @@ Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1480: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1469: $PREPARSER ./calc /dev/null +input: stderr: -syntax error, unexpected number -error: 2222 != 1 +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +error: 4444 != 1 stderr: -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +syntax error: invalid character: '#' + | 1//2 +./calc.at:1477: $PREPARSER ./calc input +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +syntax error +./calc.at:1476: cat stderr +./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: + | (1 + #) = 1111 +./calc.at:1478: $PREPARSER ./calc input +input: Starting parse Entering state 0 Reading a token @@ -174410,9 +173112,18 @@ Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () +1.3: syntax error +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1477: "$PERL" -pi -e 'use strict; + | 1 2 +./calc.at:1478: $PREPARSER ./calc input +stderr: +stderr: +1.6: syntax error: invalid character: '#' +input: +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error: invalid character: '#' +./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174422,11 +173133,21 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -syntax error, unexpected number -error: 2222 != 1 -./calc.at:1478: cat stderr -./calc.at:1477: cat stderr + | (!!) + (1 2) = 1 +./calc.at:1476: $PREPARSER ./calc input +./calc.at:1482: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +syntax error +stderr: +stderr: +stderr: +1.3: syntax error +1.6: syntax error: invalid character: '#' +stderr: +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.3: syntax error ./calc.at:1480: cat stderr +syntax error +error: 2222 != 1 ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -174437,11 +173158,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1486: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -input: - | (1 + #) = 1111 -./calc.at:1477: $PREPARSER ./calc input -./calc.at:1480: "$PERL" -pi -e 'use strict; +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.3: syntax error +stderr: +./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174451,15 +173172,42 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1469: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1478: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1477: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +syntax error +error: 2222 != 1 input: - | (!!) + (1 2) = 1 -./calc.at:1478: $PREPARSER ./calc input ./calc.at:1482: cat stderr -input: -./calc.at:1479: "$PERL" -pi -e 'use strict; + | (!!) + (1 2) = 1 +./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174469,30 +173217,22 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1480: cat stderr -stderr: -stderr: -./calc.at:1479: cat stderr -input: - | (1 + 1) / (1 - 1) -./calc.at:1480: $PREPARSER ./calc input - | error -1.6: syntax error: invalid character: '#' -1.11: syntax error -1.1-16: error: 2222 != 1 -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: $PREPARSER ./calc input stderr: -stderr: -stderr: -syntax error, unexpected invalid token +./calc.at:1476: cat stderr input: +syntax error, unexpected number +error: 2222 != 1 ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1469: cat stderr +./calc.at:1478: cat stderr | error -error: null divisor +./calc.at:1477: cat stderr ./calc.at:1482: $PREPARSER ./calc input stderr: -./calc.at:1477: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1478: cat stderr +./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174502,34 +173242,59 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error, unexpected number +error: 2222 != 1 +Starting parse +Entering state 0 +Reading a token +Next token is token "invalid token" () +syntax error +Cleanup: discarding lookahead token "invalid token" () +input: +input: +input: +./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | (1 + # + 1) = 1111 +./calc.at:1476: $PREPARSER ./calc input + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 stderr: -1.11: syntax error -1.1-16: error: 2222 != 1 +./calc.at:1469: $PREPARSER ./calc input + | error +./calc.at:1477: $PREPARSER ./calc input + | (# + 1) = 1111 +./calc.at:1478: $PREPARSER ./calc input input: +stderr: Starting parse Entering state 0 Reading a token Next token is token "invalid token" () syntax error Cleanup: discarding lookahead token "invalid token" () -./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (- *) + (1 2) = 1 -./calc.at:1479: $PREPARSER ./calc input -syntax error, unexpected invalid token +./calc.at:1476: cat stderr stderr: + | 1//2 stderr: -error: null divisor -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected number -error: 2222 != 1 -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1477: cat stderr stderr: -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected number -error: 2222 != 1 -./calc.at:1478: "$PERL" -pi -e 'use strict; +syntax error: invalid character: '#' +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1478: $PREPARSER ./calc input +1.1: syntax error +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 +1.2: syntax error: invalid character: '#' +stderr: +./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +stderr: +./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174539,14 +173304,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +1.3: syntax error +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +syntax error: invalid character: '#' stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "invalid token" () -syntax error -Cleanup: discarding lookahead token "invalid token" () -./calc.at:1479: "$PERL" -pi -e 'use strict; +1.1: syntax error + | (- *) + (1 2) = 1 +1.2: syntax error: invalid character: '#' +./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174556,20 +173322,16 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | (# + 1) = 1111 -./calc.at:1477: $PREPARSER ./calc input -./calc.at:1479: cat stderr -stderr: -1.2: syntax error: invalid character: '#' -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: stderr: - | (* *) + (*) + (*) -./calc.at:1479: $PREPARSER ./calc input -1.2: syntax error: invalid character: '#' +syntax error +syntax error +syntax error +syntax error +error: 4444 != 1 +./calc.at:1476: $PREPARSER ./calc input +./calc.at:1480: cat stderr stderr: -./calc.at:1482: "$PERL" -pi -e 'use strict; +./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174579,11 +173341,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1480: "$PERL" -pi -e 'use strict; +stderr: +stdout: +input: +./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174593,11 +173354,19 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + | (- *) + (1 2) = 1 +./calc.at:1480: $PREPARSER ./calc input +1.3: syntax error stderr: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -./calc.at:1477: "$PERL" -pi -e 'use strict; +syntax error, unexpected number +error: 2222 != 1 +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +syntax error +error: 2222 != 1 +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174607,7 +173376,18 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1480: "$PERL" -pi -e 'use strict; +./calc.at:1479: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc calc.hh + +./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174617,33 +173397,62 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1480: cat stderr ./calc.at:1482: cat stderr -./calc.at:1480: cat stderr -554. calc.at:1480: ok -./calc.at:1478: cat stderr ./calc.at:1477: cat stderr +stderr: +stderr: +syntax error +syntax error +error: 2222 != 1 input: -input: - | (- *) + (1 2) = 1 -./calc.at:1478: $PREPARSER ./calc input - | 1 = 2 = 3 -./calc.at:1480: $PREPARSER ./calc input +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected number +error: 2222 != 1 +./calc.at:1478: cat stderr +./calc.at:1469: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1479: $PREPARSER ./calc input +./calc.at:1476: cat stderr stderr: - input: input: +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 = 2 = 3 | 1 = 2 = 3 -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 - | (1 + # + 1) = 1111 -stderr: ./calc.at:1482: $PREPARSER ./calc input -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1478: cat stderr ./calc.at:1477: $PREPARSER ./calc input -syntax error, unexpected '=' -./calc.at:1479: "$PERL" -pi -e 'use strict; +input: + | (1 + # + 1) = 1111 +./calc.at:1478: $PREPARSER ./calc input + | (1 + 1) / (1 - 1) +stderr: +stderr: +stderr: +./calc.at:1476: $PREPARSER ./calc input +./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174653,9 +173462,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -stderr: -1.6: syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token @@ -174685,19 +173491,8 @@ Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -1.4: syntax error -1.12: syntax error -1.1-17: error: 2222 != 1 -./calc.at:1479: cat stderr -stderr: -1.6: syntax error: invalid character: '#' -syntax error, unexpected '=' -./calc.at:1478: "$PERL" -pi -e 'use strict; +1.7: syntax error +./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174707,6 +173502,23 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1469: cat stderr +input: +stderr: +error: null divisor +input: +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.6: syntax error: invalid character: '#' + | 1 2 +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1479: $PREPARSER ./calc input + | error +./calc.at:1480: cat stderr +stderr: +./calc.at:1478: $PREPARSER ./calc input stderr: Starting parse Entering state 0 @@ -174737,6 +173549,25 @@ Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () +input: +stderr: +stderr: +stderr: +1.7: syntax error + | (!!) + (1 2) = 1 +stderr: +./calc.at:1476: cat stderr +error: null divisor +syntax error, unexpected number +1.1: syntax error +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1469: $PREPARSER ./calc input +1.6: syntax error: invalid character: '#' +stderr: +stderr: +input: +syntax error, unexpected number ./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -174748,18 +173579,14 @@ }eg ' expout || exit 77 input: -562. calc.at:1487: testing Calculator glr2.cc parse.error=custom %debug %name-prefix "calc" %verbose ... - | 1 + 2 * 3 + !+ ++ -./calc.at:1479: $PREPARSER ./calc input -stderr: -./calc.at:1487: mv calc.y.tmp calc.y - -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1478: cat stderr -./calc.at:1477: cat stderr -./calc.at:1487: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: -./calc.at:1482: "$PERL" -pi -e 'use strict; +syntax error +error: 2222 != 1 + | (* *) + (*) + (*) +1.1: syntax error +./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1480: $PREPARSER ./calc input +./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174769,7 +173596,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1480: "$PERL" -pi -e 'use strict; + | (* *) + (*) + (*) +./calc.at:1476: $PREPARSER ./calc input +./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174779,36 +173608,40 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | (1 + 1) / (1 - 1) -./calc.at:1477: $PREPARSER ./calc input -./calc.at:1480: cat stderr -input: -input: - | (* *) + (*) + (*) -./calc.at:1478: $PREPARSER ./calc input -stderr: - | 1 + 2 * 3 + !- ++ -./calc.at:1479: $PREPARSER ./calc input -1.11-17: error: null divisor -stderr: -./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.2: syntax error -1.10: syntax error -1.16: syntax error -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1482: cat stderr -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1482: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: - | - | +1 -./calc.at:1480: $PREPARSER ./calc input stderr: -1.2: syntax error -1.10: syntax error -1.16: syntax error +syntax error +syntax error +syntax error +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +error: 2222 != 1 +./calc.at:1478: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1477: cat stderr stderr: stderr: ./calc.at:1479: "$PERL" -pi -e 'use strict; @@ -174821,12 +173654,18 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -syntax error, unexpected '+' -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -1.11-17: error: null divisor +syntax error +syntax error +syntax error +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1478: cat stderr +./calc.at:1476: cat stderr ./calc.at:1479: cat stderr -./calc.at:1478: "$PERL" -pi -e 'use strict; +./calc.at:1482: cat stderr +./calc.at:1478: cat stderr +./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174836,15 +173675,34 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +input: +546. calc.at:1476: ok | | +1 -./calc.at:1482: $PREPARSER ./calc input +./calc.at:1477: $PREPARSER ./calc input +./calc.at:1476: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: input: - | (#) + (#) = 2222 -./calc.at:1479: $PREPARSER ./calc input -./calc.at:1487: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS stderr: -./calc.at:1477: "$PERL" -pi -e 'use strict; +input: + | + | +1 +input: + | 1//2 +./calc.at:1482: $PREPARSER ./calc input +2.1: syntax error +./calc.at:1479: $PREPARSER ./calc input +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174854,11 +173712,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + | (1 + 1) / (1 - 1) + | 1 = 2 = 3 +./calc.at:1478: $PREPARSER ./calc input +stderr: +./calc.at:1478: $PREPARSER ./calc input +./calc.at:1469: cat stderr +stderr: stderr: stderr: -syntax error, unexpected '+' -syntax error: invalid character: '#' -syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token @@ -174879,12 +173741,23 @@ Error: popping nterm input () Cleanup: discarding lookahead token '+' () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +stderr: +./calc.at:1480: cat stderr +2.1: syntax error ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1478: cat stderr -./calc.at:1477: cat stderr +1.11-17: error: null divisor +./calc.at:1476: cat stderr +1.7: syntax error +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + +input: +stderr: + | (- *) + (1 2) = 1 +./calc.at:1469: $PREPARSER ./calc input +stderr: stderr: -syntax error: invalid character: '#' -syntax error: invalid character: '#' stderr: Starting parse Entering state 0 @@ -174906,10 +173779,9 @@ Error: popping nterm input () Cleanup: discarding lookahead token '+' () input: -549. calc.at:1477: ok - | 1 + 2 * 3 + !+ ++ -./calc.at:1478: $PREPARSER ./calc input -./calc.at:1482: "$PERL" -pi -e 'use strict; +stderr: +input: +./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174919,10 +173791,23 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +1.11-17: error: null divisor +syntax error, unexpected '/', expecting number or '-' or '(' or '!' + | 1 + 2 * 3 + !+ ++ +./calc.at:1476: $PREPARSER ./calc input +1.7: syntax error + | 1 + 2 * 3 + !+ ++ +syntax error +syntax error +error: 2222 != 1 +./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1480: $PREPARSER ./calc input stderr: -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1480: "$PERL" -pi -e 'use strict; +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -174932,13 +173817,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | 1 + 2 * 3 + !- ++ -./calc.at:1478: $PREPARSER ./calc input -stderr: -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1480: cat stderr ./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -174949,6 +173827,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1477: cat stderr +syntax error +syntax error +error: 2222 != 1 +stderr: +stderr: +558. calc.at:1485: testing Calculator C++ %glr-parser parse.error=detailed %debug %name-prefix "calc" %verbose ... +./calc.at:1485: mv calc.y.tmp calc.y + ./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -174959,51 +173846,110 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1482: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1479: cat stderr +./calc.at:1477: $PREPARSER ./calc /dev/null +./calc.at:1485: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +input: +stderr: ./calc.at:1478: cat stderr -./calc.at:1480: $PREPARSER ./calc /dev/null -./calc.at:1482: cat stderr - + | 1 + 2 * 3 + !- ++ +input: +./calc.at:1480: $PREPARSER ./calc input +1.1: syntax error +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -syntax error, unexpected end of input +./calc.at:1478: cat stderr + | 1 + 2 * 3 + !- ++ +./calc.at:1476: $PREPARSER ./calc input +./calc.at:1469: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1482: cat stderr +1.1: syntax error input: +550. calc.at:1478: ok +stderr: input: -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (1 + #) = 1111 -./calc.at:1479: $PREPARSER ./calc input stderr: - | (#) + (#) = 2222 -syntax error: invalid character: '#' + | + | +1 +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1478: $PREPARSER ./calc input -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | error ./calc.at:1482: $PREPARSER ./calc /dev/null +./calc.at:1479: $PREPARSER ./calc input stderr: stderr: stderr: -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -syntax error, unexpected end of input +2.1: syntax error ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error: invalid character: '#' Starting parse Entering state 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" () +stderr: +./calc.at:1477: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1469: cat stderr ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error, unexpected invalid token +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: +2.1: syntax error +stderr: +./calc.at:1480: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + Starting parse Entering state 0 Reading a token Now at end of input. syntax error Cleanup: discarding lookahead token "end of input" () -1.2: syntax error: invalid character: '#' -1.8: syntax error: invalid character: '#' -./calc.at:1479: "$PERL" -pi -e 'use strict; +./calc.at:1477: cat stderr +input: +./calc.at:1485: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +syntax error, unexpected invalid token + | (* *) + (*) + (*) +./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -175013,11 +173959,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -563. calc.at:1489: testing Calculator C++ %glr-parser parse.error=verbose %debug %name-prefix "calc" api.token.prefix={TOK_} %verbose ... -./calc.at:1489: mv calc.y.tmp calc.y - -./calc.at:1489: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -./calc.at:1480: "$PERL" -pi -e 'use strict; +./calc.at:1469: $PREPARSER ./calc input +stderr: +./calc.at:1480: cat stderr +input: +syntax error +syntax error +syntax error +./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -175027,8 +173977,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1479: cat stderr -./calc.at:1478: "$PERL" -pi -e 'use strict; + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +stderr: +./calc.at:1477: $PREPARSER ./calc input +syntax error +syntax error +syntax error +stderr: +./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -175038,9 +173994,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1480: cat stderr -stderr: -./calc.at:1482: "$PERL" -pi -e 'use strict; +./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -175051,65 +174005,82 @@ }eg ' expout || exit 77 input: -input: -stdout: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 - | (# + 1) = 1111 +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1476: cat stderr + | (#) + (#) = 2222 ./calc.at:1480: $PREPARSER ./calc input +./calc.at:1479: cat stderr +stderr: ./calc.at:1478: cat stderr -./calc.at:1479: $PREPARSER ./calc input -./calc.at:1485: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc +559. calc.at:1485: testing Calculator glr2.cc parse.error=detailed %debug %name-prefix "calc" %verbose ... +./calc.at:1485: mv calc.y.tmp calc.y -stderr: syntax error: invalid character: '#' -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error: invalid character: '#' +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1485: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +input: +./calc.at:1478: $PREPARSER ./calc /dev/null +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 ./calc.at:1482: cat stderr +./calc.at:1469: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (#) + (#) = 2222 +input: +./calc.at:1476: $PREPARSER ./calc input +stderr: + | 1 = 2 = 3 stderr: stderr: +./calc.at:1479: $PREPARSER ./calc input syntax error: invalid character: '#' -input: -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -error: 4444 != 1 -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error: invalid character: '#' +1.1: syntax error +syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -error: 4444 != 1 -input: input: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1485: $PREPARSER ./calc input +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1477: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +syntax error, unexpected '=' | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1482: $PREPARSER ./calc input - | (1 + #) = 1111 stderr: -./calc.at:1478: $PREPARSER ./calc input +./calc.at:1469: cat stderr +syntax error: invalid character: '#' +syntax error: invalid character: '#' +stderr: +stderr: +stderr: Starting parse Entering state 0 Reading a token @@ -175358,7 +174329,23 @@ Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.1: syntax error +syntax error, unexpected '=' +input: stderr: +./calc.at:1477: cat stderr + | 1 + 2 * 3 + !+ ++ +./calc.at:1469: $PREPARSER ./calc input +./calc.at:1480: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -175606,859 +174593,7 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -stderr: -1.6: syntax error: invalid character: '#' -stderr: -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 30 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (7) -Shifting token number (7) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (7) --> $$ = nterm exp (7) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (7) - $2 = token '=' () - $3 = nterm exp (7) --> $$ = nterm exp (7) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (7) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 10 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (3) --> $$ = nterm exp (-3) -Entering state 30 -Next token is token '=' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (-3) --> $$ = nterm exp (-6) -Entering state 29 -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (-6) --> $$ = nterm exp (-5) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (5) -Shifting token number (5) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (5) --> $$ = nterm exp (5) -Entering state 10 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (5) --> $$ = nterm exp (-5) -Entering state 27 -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (-5) - $2 = token '=' () - $3 = nterm exp (-5) --> $$ = nterm exp (-5) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (-5) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 10 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 32 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (1) - $2 = token '^' () - $3 = nterm exp (2) --> $$ = nterm exp (1) -Entering state 10 -Next token is token '=' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 10 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 27 -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (-1) - $2 = token '=' () - $3 = nterm exp (-1) --> $$ = nterm exp (-1) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (-1) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 10 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): - $1 = token '(' () - $2 = nterm exp (-1) - $3 = token ')' () --> $$ = nterm exp (-1) -Entering state 8 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 32 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (-1) - $2 = token '^' () - $3 = nterm exp (2) --> $$ = nterm exp (1) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (1) - $2 = token '=' () - $3 = nterm exp (1) --> $$ = nterm exp (1) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (1) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 10 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 10 -Next token is token '=' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (-1) --> $$ = nterm exp (1) -Entering state 10 -Next token is token '=' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 10 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 27 -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (-1) - $2 = token '=' () - $3 = nterm exp (-1) --> $$ = nterm exp (-1) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (-1) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 28 -Reading a token -Next token is token '-' () -Reducing stack 0 by rule 8 (line 104): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (2) --> $$ = nterm exp (-1) -Entering state 8 -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 28 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 8 (line 104): - $1 = nterm exp (-1) - $2 = token '-' () - $3 = nterm exp (3) --> $$ = nterm exp (-4) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (4) -Shifting token number (4) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (4) --> $$ = nterm exp (4) -Entering state 10 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (4) --> $$ = nterm exp (-4) -Entering state 27 -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (-4) - $2 = token '=' () - $3 = nterm exp (-4) --> $$ = nterm exp (-4) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (-4) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 12 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 28 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 8 (line 104): - $1 = nterm exp (2) - $2 = token '-' () - $3 = nterm exp (3) --> $$ = nterm exp (-1) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): - $1 = token '(' () - $2 = nterm exp (-1) - $3 = token ')' () --> $$ = nterm exp (-1) -Entering state 28 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 8 (line 104): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (-1) --> $$ = nterm exp (2) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (2) - $2 = token '=' () - $3 = nterm exp (2) --> $$ = nterm exp (2) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 8 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 32 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 32 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (2) - $2 = token '^' () - $3 = nterm exp (3) --> $$ = nterm exp (8) -Entering state 32 -Next token is token '=' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (2) - $2 = token '^' () - $3 = nterm exp (8) --> $$ = nterm exp (256) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (256) -Shifting token number (256) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (256) --> $$ = nterm exp (256) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (256) - $2 = token '=' () - $3 = nterm exp (256) --> $$ = nterm exp (256) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (256) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 12 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 32 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (2) - $2 = token '^' () - $3 = nterm exp (2) --> $$ = nterm exp (4) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): - $1 = token '(' () - $2 = nterm exp (4) - $3 = token ')' () --> $$ = nterm exp (4) -Entering state 8 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 32 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (4) - $2 = token '^' () - $3 = nterm exp (3) --> $$ = nterm exp (64) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (64) -Shifting token number (64) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (64) --> $$ = nterm exp (64) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (64) - $2 = token '=' () - $3 = nterm exp (64) --> $$ = nterm exp (64) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (64) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1480: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1489: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -./calc.at:1479: "$PERL" -pi -e 'use strict; +./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -176468,850 +174603,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1480: cat stderr stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 30 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (7) -Shifting token number (7) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (7) --> $$ = nterm exp (7) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (7) - $2 = token '=' () - $3 = nterm exp (7) --> $$ = nterm exp (7) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (7) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 10 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (3) --> $$ = nterm exp (-3) -Entering state 30 -Next token is token '=' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (-3) --> $$ = nterm exp (-6) -Entering state 29 -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (-6) --> $$ = nterm exp (-5) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (5) -Shifting token number (5) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (5) --> $$ = nterm exp (5) -Entering state 10 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (5) --> $$ = nterm exp (-5) -Entering state 27 -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (-5) - $2 = token '=' () - $3 = nterm exp (-5) --> $$ = nterm exp (-5) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (-5) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 10 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 32 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (1) - $2 = token '^' () - $3 = nterm exp (2) --> $$ = nterm exp (1) -Entering state 10 -Next token is token '=' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 10 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 27 -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (-1) - $2 = token '=' () - $3 = nterm exp (-1) --> $$ = nterm exp (-1) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (-1) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 10 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): - $1 = token '(' () - $2 = nterm exp (-1) - $3 = token ')' () --> $$ = nterm exp (-1) -Entering state 8 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 32 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (-1) - $2 = token '^' () - $3 = nterm exp (2) --> $$ = nterm exp (1) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (1) - $2 = token '=' () - $3 = nterm exp (1) --> $$ = nterm exp (1) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (1) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 10 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 10 -Next token is token '=' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (-1) --> $$ = nterm exp (1) -Entering state 10 -Next token is token '=' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 10 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 27 -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (-1) - $2 = token '=' () - $3 = nterm exp (-1) --> $$ = nterm exp (-1) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (-1) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 28 -Reading a token -Next token is token '-' () -Reducing stack 0 by rule 8 (line 104): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (2) --> $$ = nterm exp (-1) -Entering state 8 -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 28 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 8 (line 104): - $1 = nterm exp (-1) - $2 = token '-' () - $3 = nterm exp (3) --> $$ = nterm exp (-4) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (4) -Shifting token number (4) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (4) --> $$ = nterm exp (4) -Entering state 10 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (4) --> $$ = nterm exp (-4) -Entering state 27 -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (-4) - $2 = token '=' () - $3 = nterm exp (-4) --> $$ = nterm exp (-4) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (-4) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 12 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 28 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 8 (line 104): - $1 = nterm exp (2) - $2 = token '-' () - $3 = nterm exp (3) --> $$ = nterm exp (-1) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): - $1 = token '(' () - $2 = nterm exp (-1) - $3 = token ')' () --> $$ = nterm exp (-1) -Entering state 28 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 8 (line 104): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (-1) --> $$ = nterm exp (2) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (2) - $2 = token '=' () - $3 = nterm exp (2) --> $$ = nterm exp (2) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 8 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 32 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 32 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (2) - $2 = token '^' () - $3 = nterm exp (3) --> $$ = nterm exp (8) -Entering state 32 -Next token is token '=' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (2) - $2 = token '^' () - $3 = nterm exp (8) --> $$ = nterm exp (256) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (256) -Shifting token number (256) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (256) --> $$ = nterm exp (256) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (256) - $2 = token '=' () - $3 = nterm exp (256) --> $$ = nterm exp (256) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (256) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 12 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 32 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (2) - $2 = token '^' () - $3 = nterm exp (2) --> $$ = nterm exp (4) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): - $1 = token '(' () - $2 = nterm exp (4) - $3 = token ')' () --> $$ = nterm exp (4) -Entering state 8 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 32 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (4) - $2 = token '^' () - $3 = nterm exp (3) --> $$ = nterm exp (64) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (64) -Shifting token number (64) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (64) --> $$ = nterm exp (64) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (64) - $2 = token '=' () - $3 = nterm exp (64) --> $$ = nterm exp (64) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (64) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -input: +./calc.at:1485: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +./calc.at:1480: cat stderr +./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -stderr: | (!!) + (1 2) = 1 - | 1 2 -./calc.at:1482: "$PERL" -pi -e 'use strict; +./calc.at:1477: $PREPARSER ./calc input +./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -177321,31 +174620,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1480: $PREPARSER ./calc input -./calc.at:1485: $PREPARSER ./calc input -1.6: syntax error: invalid character: '#' stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token number (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Cleanup: discarding lookahead token number (2) -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1479: cat stderr -syntax error, unexpected number -error: 2222 != 1 -./calc.at:1478: "$PERL" -pi -e 'use strict; +1.11: syntax error +1.1-16: error: 2222 != 1 +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -177356,46 +174635,21 @@ }eg ' expout || exit 77 stderr: -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token number (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Cleanup: discarding lookahead token number (2) -input: - | (1 + # + 1) = 1111 -./calc.at:1479: $PREPARSER ./calc input -stderr: -stderr: -syntax error: invalid character: '#' -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error, unexpected number -error: 2222 != 1 stderr: +input: ./calc.at:1478: cat stderr +input: +./calc.at:1479: cat stderr + | (1 + #) = 1111 +./calc.at:1480: $PREPARSER ./calc input +stderr: +1.11: syntax error +1.1-16: error: 2222 != 1 + | 1 + 2 * 3 + !- ++ syntax error: invalid character: '#' -./calc.at:1480: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1482: cat stderr -./calc.at:1485: "$PERL" -pi -e 'use strict; +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1469: $PREPARSER ./calc input +./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -177405,9 +174659,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1480: cat stderr -./calc.at:1485: cat stderr -./calc.at:1479: "$PERL" -pi -e 'use strict; +stderr: +stderr: +./calc.at:1476: cat stderr +./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error: invalid character: '#' +./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -177419,50 +174676,37 @@ ' expout || exit 77 input: input: - | (- *) + (1 2) = 1 -./calc.at:1480: $PREPARSER ./calc input -input: +./calc.at:1482: cat stderr + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1478: $PREPARSER ./calc input + | + | +1 +./calc.at:1479: $PREPARSER ./calc input stderr: input: -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected number -error: 2222 != 1 - | (!!) + (1 2) = 1 -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1482: $PREPARSER ./calc input - | 1//2 - | (# + 1) = 1111 -./calc.at:1485: $PREPARSER ./calc input stderr: -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected number -error: 2222 != 1 -./calc.at:1479: cat stderr -./calc.at:1478: $PREPARSER ./calc input stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '/' () -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '/' () -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + #) = 1111 +syntax error, unexpected '+' +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1476: $PREPARSER ./calc input stderr: stderr: +./calc.at:1477: cat stderr +input: +1.2: syntax error +1.18: syntax error +1.23: syntax error +1.41: syntax error +1.1-46: error: 4444 != 1 +syntax error: invalid character: '#' +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -177473,6 +174717,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + | (!!) + (1 2) = 1 +./calc.at:1482: $PREPARSER ./calc input +stderr: +stderr: +syntax error, unexpected '+' Starting parse Entering state 0 Reading a token @@ -177584,22 +174833,36 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: ./calc.at:1480: cat stderr +./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1469: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 input: -1.2: syntax error: invalid character: '#' -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -stderr: - | (* *) + (*) + (*) -./calc.at:1480: $PREPARSER ./calc input -1.2: syntax error: invalid character: '#' - | (1 + 1) / (1 - 1) -./calc.at:1479: $PREPARSER ./calc input -stderr: +syntax error: invalid character: '#' +./calc.at:1478: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (- *) + (1 2) = 1 +./calc.at:1477: $PREPARSER ./calc input stderr: +input: stderr: -error: null divisor Starting parse Entering state 0 Reading a token @@ -177711,38 +174974,18 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '/' () -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '/' () +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 + | (# + 1) = 1111 +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1480: $PREPARSER ./calc input +./calc.at:1469: cat stderr stderr: -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' stderr: -./calc.at:1480: "$PERL" -pi -e 'use strict; +./calc.at:1478: cat stderr +./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -177752,8 +174995,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -error: null divisor -./calc.at:1478: "$PERL" -pi -e 'use strict; +./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -177763,7 +175005,42 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1480: cat stderr +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 +stdout: +syntax error: invalid character: '#' +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | (#) + (#) = 2222 +./calc.at:1480: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +./calc.at:1469: $PREPARSER ./calc input +stderr: +input: +./calc.at:1479: cat stderr +stderr: +syntax error: invalid character: '#' +./calc.at:1477: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (!!) + (1 2) = 1 ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -177774,9 +175051,46 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1482: cat stderr +syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1478: $PREPARSER ./calc input +./calc.at:1476: cat stderr +stderr: input: -./calc.at:1485: "$PERL" -pi -e 'use strict; +./calc.at:1479: $PREPARSER ./calc /dev/null +1.11: syntax error +1.1-16: error: 2222 != 1 +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +stderr: +./calc.at:1480: $PREPARSER ./calc input +stderr: +syntax error, unexpected end of input +stderr: +syntax error: invalid character: '#' +syntax error: invalid character: '#' +input: +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: + | (# + 1) = 1111 +./calc.at:1482: cat stderr +./calc.at:1476: $PREPARSER ./calc input +./calc.at:1477: cat stderr +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -177786,10 +175100,60 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +1.11: syntax error +1.1-16: error: 2222 != 1 +stderr: +stderr: +syntax error: invalid character: '#' +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +syntax error, unexpected end of input +input: +stderr: +stdout: +input: | (- *) + (1 2) = 1 ./calc.at:1482: $PREPARSER ./calc input stderr: +syntax error: invalid character: '#' input: +./calc.at:1480: cat stderr +./calc.at:1479: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc calc.hh + + | (* *) + (*) + (*) +stderr: +./calc.at:1478: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | 1 2 +./calc.at:1477: $PREPARSER ./calc input +./calc.at:1469: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1480: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -177908,6 +175272,10 @@ Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +stderr: +syntax error, unexpected number +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: Starting parse Entering state 0 Reading a token @@ -178024,14 +175392,46 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () +1.2: syntax error +1.10: syntax error +1.16: syntax error +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +input: +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +stderr: +./calc.at:1479: $PREPARSER ./calc input +1.2: syntax error +1.10: syntax error +1.16: syntax error +./calc.at:1469: cat stderr + | (1 + # + 1) = 1111 ./calc.at:1478: cat stderr - | 1 + 2 * 3 + !+ ++ ./calc.at:1480: $PREPARSER ./calc input stderr: -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1485: cat stderr -stderr: -./calc.at:1479: "$PERL" -pi -e 'use strict; +./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -178041,8 +175441,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -./calc.at:1482: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1479: cat stderr +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -178052,21 +175455,25 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +syntax error, unexpected number +syntax error: invalid character: '#' input: - | 1 + 2 * 3 + !- ++ -./calc.at:1480: $PREPARSER ./calc input -./calc.at:1479: cat stderr -stderr: ./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1476: cat stderr +input: stderr: - | (1 + # + 1) = 1111 + | (- *) + (1 2) = 1 ./calc.at:1478: $PREPARSER ./calc input -552. calc.at:1479: ok -./calc.at:1482: cat stderr + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 input: stderr: -1.6: syntax error: invalid character: '#' -./calc.at:1480: "$PERL" -pi -e 'use strict; +./calc.at:1479: $PREPARSER ./calc input + | (1 + #) = 1111 +stderr: +./calc.at:1469: $PREPARSER ./calc input +stderr: +./calc.at:1477: cat stderr +./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -178076,34 +175483,96 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +syntax error: invalid character: '#' +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 +input: +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +error: 4444 != 1 ./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | error -./calc.at:1485: $PREPARSER ./calc input -./calc.at:1480: cat stderr +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -1.6: syntax error: invalid character: '#' input: - | (#) + (#) = 2222 -./calc.at:1480: $PREPARSER ./calc input + | 1 2 +./calc.at:1479: $PREPARSER ./calc input +syntax error: invalid character: '#' + | (1 + # + 1) = 1111 +./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1476: $PREPARSER ./calc input +stderr: +stderr: +./calc.at:1480: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +syntax error, unexpected number +1.4: syntax error +1.12: syntax error +1.1-17: error: 2222 != 1 +stderr: +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +error: 4444 != 1 syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 + !+ ++ +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1477: $PREPARSER ./calc input +./calc.at:1480: cat stderr +./calc.at:1482: cat stderr +stderr: stderr: stderr: syntax error: invalid character: '#' +./calc.at:1478: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1480: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +syntax error, unexpected number +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +input: +./calc.at:1480: cat stderr syntax error: invalid character: '#' +stderr: + | 1//2 +./calc.at:1480: $PREPARSER ./calc input +input: +./calc.at:1478: cat stderr | (* *) + (*) + (*) -./calc.at:1482: $PREPARSER ./calc input -Starting parse -Entering state 0 -Reading a token -Next token is token invalid token () -syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token () stderr: -./calc.at:1478: "$PERL" -pi -e 'use strict; +./calc.at:1482: $PREPARSER ./calc input +./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -178113,8 +175582,17 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - +input: +input: +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + 1) / (1 - 1) +./calc.at:1480: $PREPARSER ./calc input +stderr: + | 1 + 2 * 3 + !- ++ +./calc.at:1477: $PREPARSER ./calc input +./calc.at:1479: cat stderr +input: Starting parse Entering state 0 Reading a token @@ -178230,16 +175708,39 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () +stderr: +stderr: +./calc.at:1469: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +error: null divisor + | (* *) + (*) + (*) +./calc.at:1478: $PREPARSER ./calc input +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token invalid token () -syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token () -./calc.at:1478: cat stderr -./calc.at:1480: "$PERL" -pi -e 'use strict; +stderr: +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +./calc.at:1479: cat stderr +./calc.at:1476: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -178250,39 +175751,12 @@ }eg ' expout || exit 77 stderr: -stdout: -input: -./calc.at:1480: cat stderr -./calc.at:1479: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc calc.hh - input: +1.2: syntax error +1.10: syntax error +1.16: syntax error +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1479: $PREPARSER ./calc input -stderr: - | (1 + 1) / (1 - 1) -./calc.at:1478: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -178398,20 +175872,21 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: + | (!!) + (1 2) = 1 stderr: -1.11-17: error: null divisor -./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (1 + #) = 1111 -./calc.at:1480: $PREPARSER ./calc input +./calc.at:1479: $PREPARSER ./calc input +error: null divisor +./calc.at:1469: cat stderr stderr: -564. calc.at:1489: testing Calculator glr2.cc parse.error=verbose %debug %name-prefix "calc" api.token.prefix={TOK_} %verbose ... stderr: -./calc.at:1489: mv calc.y.tmp calc.y - input: -./calc.at:1482: "$PERL" -pi -e 'use strict; +syntax error, unexpected number +error: 2222 != 1 +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error +1.10: syntax error +1.16: syntax error +./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -178421,15 +175896,24 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | 1 2 + | 1//2 ./calc.at:1479: $PREPARSER ./calc input -./calc.at:1489: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: -1.11-17: error: null divisor +./calc.at:1476: cat stderr +input: +./calc.at:1480: cat stderr +./calc.at:1477: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -./calc.at:1482: cat stderr -syntax error: invalid character: '#' -./calc.at:1485: "$PERL" -pi -e 'use strict; +./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -178439,14 +175923,101 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (# + 1) = 1111 syntax error, unexpected number +error: 2222 != 1 +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +./calc.at:1469: $PREPARSER ./calc input ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1482: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1480: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +input: +./calc.at:1480: cat stderr +stderr: +syntax error: invalid character: '#' +./calc.at:1477: cat stderr + | error +./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +input: +./calc.at:1480: $PREPARSER ./calc input + | (1 + 1) / (1 - 1) +./calc.at:1476: $PREPARSER ./calc input +stderr: +stderr: +syntax error, unexpected invalid token +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1478: cat stderr +554. calc.at:1480: ok +./calc.at:1482: cat stderr +stderr: +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +error: null divisor +./calc.at:1476: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error, unexpected invalid token +stderr: +input: +stderr: +syntax error: invalid character: '#' + | (#) + (#) = 2222 +error: null divisor +./calc.at:1477: $PREPARSER ./calc input +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +stderr: + | 1 + 2 * 3 + !+ ++ +./calc.at:1478: $PREPARSER ./calc input +./calc.at:1479: cat stderr +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: input: stderr: +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1479: cat stderr +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 + 2 * 3 + !+ ++ ./calc.at:1482: $PREPARSER ./calc input -./calc.at:1478: "$PERL" -pi -e 'use strict; +./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -178456,7 +176027,29 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + +input: stderr: +./calc.at:1480: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1476: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -178522,12 +176115,42 @@ $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) + | error +./calc.at:1479: $PREPARSER ./calc input ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error: invalid character: '#' -./calc.at:1485: cat stderr +input: +./calc.at:1477: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: stderr: +syntax error, unexpected invalid token +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (- *) + (1 2) = 1 +./calc.at:1479: $PREPARSER ./calc input +./calc.at:1480: cat stderr +./calc.at:1469: cat stderr +./calc.at:1476: cat stderr +stderr: +stderr: +syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected number +error: 2222 != 1 +input: +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 + !- ++ +./calc.at:1478: $PREPARSER ./calc input +stderr: +syntax error, unexpected invalid token +input: +stderr: Starting parse Entering state 0 Reading a token @@ -178593,56 +176216,32 @@ $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) -./calc.at:1478: cat stderr +547. calc.at:1476: ok + | (1 + # + 1) = 1111 input: input: +stderr: +./calc.at:1469: $PREPARSER ./calc input +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected number +error: 2222 != 1 | 1 = 2 = 3 -./calc.at:1485: $PREPARSER ./calc input -551. calc.at:1478: | 1 + 2 * 3 + !- ++ - ok +./calc.at:1480: $PREPARSER ./calc input +./calc.at:1477: cat stderr +stderr: + | 1 + 2 * 3 + !- ++ ./calc.at:1482: $PREPARSER ./calc input +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error: invalid character: '#' +./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 27 -Reading a token -Next token is token '=' () syntax error, unexpected '=' -Error: popping nterm exp (2) -Error: popping token '=' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '=' () -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1479: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +stderr: +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | (1 + #) = 1111 +stderr: Starting parse Entering state 0 Reading a token @@ -178708,8 +176307,10 @@ $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) +stderr: +./calc.at:1477: $PREPARSER ./calc input ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1480: "$PERL" -pi -e 'use strict; +./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -178719,40 +176320,27 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1479: cat stderr -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 27 -Reading a token -Next token is token '=' () +syntax error: invalid character: '#' syntax error, unexpected '=' -Error: popping nterm exp (2) -Error: popping token '=' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '=' () -./calc.at:1489: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS -./calc.at:1480: cat stderr +560. calc.at:1486: testing Calculator C++ %glr-parser parse.error=verbose %debug %name-prefix "calc" %verbose ... +./calc.at:1486: mv calc.y.tmp calc.y + stderr: +./calc.at:1486: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +1.6: syntax error: invalid character: '#' +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + +stderr: +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -178818,22 +176406,33 @@ $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) -input: - | 1//2 -./calc.at:1479: $PREPARSER ./calc input - +./calc.at:1478: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1479: cat stderr +./calc.at:1469: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: +1.6: syntax error: invalid character: '#' +./calc.at:1479: cat stderr +./calc.at:1469: cat stderr input: -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (# + 1) = 1111 -./calc.at:1480: $PREPARSER ./calc input -stderr: -syntax error: invalid character: '#' -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -./calc.at:1485: "$PERL" -pi -e 'use strict; +./calc.at:1477: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -178843,12 +176442,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -565. calc.at:1491: testing Calculator C++ %glr-parser %locations %header parse.error=verbose %debug %name-prefix "calc" %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... -./calc.at:1485: cat stderr -./calc.at:1491: mv calc.y.tmp calc.y - -stderr: -syntax error: invalid character: '#' ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -178859,7 +176452,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1479: "$PERL" -pi -e 'use strict; +./calc.at:1478: cat stderr + | 1 = 2 = 3 +./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -178869,56 +176464,69 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1479: $PREPARSER ./calc input +input: +./calc.at:1477: cat stderr + | (* *) + (*) + (*) +./calc.at:1479: $PREPARSER ./calc input +561. calc.at:1486: testing Calculator glr2.cc parse.error=verbose %debug %name-prefix "calc" %verbose ... +./calc.at:1486: mv calc.y.tmp calc.y + +stderr: +./calc.at:1480: cat stderr +./calc.at:1486: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +input: +stderr: +./calc.at:1486: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +syntax error, unexpected '=' + | (1 + 1) / (1 - 1) +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1469: $PREPARSER ./calc input +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: ./calc.at:1482: cat stderr +stderr: +input: +stderr: input: -./calc.at:1479: cat stderr | | +1 -./calc.at:1485: $PREPARSER ./calc input +./calc.at:1480: $PREPARSER ./calc input +syntax error, unexpected '=' + | (#) + (#) = 2222 stderr: -./calc.at:1491: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '+' () -syntax error, unexpected '+' -Error: popping nterm input () -Cleanup: discarding lookahead token '+' () -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1478: $PREPARSER ./calc input +error: null divisor + | (# + 1) = 1111 +./calc.at:1469: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '+' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' syntax error, unexpected '+' -Error: popping nterm input () -Cleanup: discarding lookahead token '+' () +./calc.at:1477: $PREPARSER ./calc input +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +1.2: syntax error: invalid character: '#' +stderr: +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' input: -./calc.at:1480: "$PERL" -pi -e 'use strict; +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: + | (#) + (#) = 2222 +syntax error, unexpected '+' +./calc.at:1482: $PREPARSER ./calc input +error: null divisor +stderr: +1.2: syntax error: invalid character: '#' +stderr: +./calc.at:1479: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -178928,9 +176536,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (#) + (#) = 2222 -./calc.at:1482: $PREPARSER ./calc input -stderr: Starting parse Entering state 0 Reading a token @@ -179029,11 +176634,32 @@ Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | error -./calc.at:1480: cat stderr -./calc.at:1479: $PREPARSER ./calc input stderr: +1.2: syntax error: invalid character: '#' +1.8: syntax error: invalid character: '#' +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1477: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1479: cat stderr +./calc.at:1479: cat stderr Starting parse Entering state 0 Reading a token @@ -179131,17 +176757,8 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -input: -stderr: - | (1 + # + 1) = 1111 -./calc.at:1480: $PREPARSER ./calc input -stderr: -syntax error: invalid character: '#' -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error, unexpected invalid token -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1485: "$PERL" -pi -e 'use strict; +./calc.at:1486: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -179151,11 +176768,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -syntax error, unexpected invalid token -stderr: -syntax error: invalid character: '#' -./calc.at:1485: cat stderr -./calc.at:1482: "$PERL" -pi -e 'use strict; +./calc.at:1478: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -179165,8 +176778,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1491: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS -./calc.at:1480: "$PERL" -pi -e 'use strict; +./calc.at:1469: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -179176,9 +176788,25 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +input: + | 1 + 2 * 3 + !+ ++ +input: +./calc.at:1479: $PREPARSER ./calc input ./calc.at:1480: cat stderr -./calc.at:1485: $PREPARSER ./calc /dev/null -./calc.at:1479: "$PERL" -pi -e 'use strict; + | + | +1 +./calc.at:1479: $PREPARSER ./calc input +stderr: +./calc.at:1478: cat stderr +./calc.at:1469: cat stderr +./calc.at:1477: cat stderr +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +syntax error, unexpected '+' +./calc.at:1480: $PREPARSER ./calc /dev/null +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -179188,48 +176816,68 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1482: cat stderr stderr: -Starting parse -Entering state 0 -Reading a token -Now at end of input. -syntax error, unexpected end of file -Cleanup: discarding lookahead token end of file () -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +545. calc.at:1469: ok +stderr: +syntax error, unexpected end of input +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: - | (1 + 1) / (1 - 1) -./calc.at:1480: $PREPARSER ./calc input -./calc.at:1479: cat stderr +input: +input: + | (1 + # + 1) = 1111 +./calc.at:1477: $PREPARSER ./calc input +syntax error, unexpected '+' + | 1 + 2 * 3 + !- ++ +./calc.at:1479: $PREPARSER ./calc input + | (1 + #) = 1111 +./calc.at:1478: $PREPARSER ./calc input stderr: stderr: -error: null divisor stderr: -./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Now at end of input. -syntax error, unexpected end of file -Cleanup: discarding lookahead token end of file () -input: -stdout: stderr: - | (1 + #) = 1111 -./calc.at:1482: $PREPARSER ./calc input -error: null divisor -./calc.at:1486: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc +1.6: syntax error: invalid character: '#' +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.6: syntax error: invalid character: '#' +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error, unexpected end of input +stderr: +stderr: +./calc.at:1482: cat stderr stderr: +1.6: syntax error: invalid character: '#' +1.6: syntax error: invalid character: '#' +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1478: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1477: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1480: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -179240,6 +176888,24 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +input: +./calc.at:1479: cat stderr + | (1 + #) = 1111 +./calc.at:1482: $PREPARSER ./calc input +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1480: cat stderr +stderr: +./calc.at:1479: $PREPARSER ./calc /dev/null +./calc.at:1478: cat stderr Starting parse Entering state 0 Reading a token @@ -179318,112 +176984,80 @@ Cleanup: popping token "end of input" () Cleanup: popping nterm input () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1480: cat stderr -input: -input: - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 - | 1 = 2 = 3 -./calc.at:1486: $PREPARSER ./calc input -./calc.at:1479: $PREPARSER ./calc input -stderr: stderr: -syntax error, unexpected '=' +./calc.at:1479: cat stderr +syntax error, unexpected end of input ./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1485: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1477: cat stderr +562. calc.at:1487: testing Calculator glr2.cc parse.error=custom %debug %name-prefix "calc" %verbose ... +stderr: +input: +./calc.at:1487: mv calc.y.tmp calc.y + Starting parse Entering state 0 Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) -Entering state 8 +Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token -Next token is token "number" (2) -Shifting token "number" (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token "number" (3) -Shifting token "number" (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (3) --> $$ = nterm exp (3) -Entering state 30 +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () Reading a token -Next token is token '=' () -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 8 +Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (7) -Shifting token "number" (7) +Next token is token "number" (1111) +Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (7) --> $$ = nterm exp (7) + $1 = token "number" (1111) +-> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (7) + $1 = nterm exp (1111) $2 = token '=' () - $3 = nterm exp (7) --> $$ = nterm exp (7) + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (7) + $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -179432,90 +177066,3317 @@ -> $$ = nterm input () Entering state 6 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token "number" (2) -Shifting token "number" (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token "number" (3) -Shifting token "number" (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (3) --> $$ = nterm exp (3) -Entering state 10 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' () - $2 = nterm exp (3) --> $$ = nterm exp (-3) -Entering state 30 -Next token is token '=' () -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (-3) --> $$ = nterm exp (-6) -Entering state 29 -Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (-6) --> $$ = nterm exp (-5) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token "number" (5) -Shifting token "number" (5) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (5) --> $$ = nterm exp (5) -Entering state 10 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' () - $2 = nterm exp (5) --> $$ = nterm exp (-5) -Entering state 27 -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (-5) - $2 = token '=' () - $3 = nterm exp (-5) --> $$ = nterm exp (-5) +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +input: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1480: $PREPARSER ./calc input +stderr: +input: + | (# + 1) = 1111 +input: +stderr: +./calc.at:1478: $PREPARSER ./calc input +syntax error, unexpected end of input +./calc.at:1487: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y + | (1 + 1) / (1 - 1) +./calc.at:1477: $PREPARSER ./calc input + | (#) + (#) = 2222 +./calc.at:1479: $PREPARSER ./calc input +stderr: +stderr: +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +error: 4444 != 1 +1.2: syntax error: invalid character: '#' +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +1.11-17: error: null divisor +./calc.at:1477: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +error: 4444 != 1 +stderr: +stderr: +1.11-17: error: null divisor +./calc.at:1482: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1479: cat stderr +syntax error: invalid character: '#' +syntax error: invalid character: '#' +1.2: syntax error: invalid character: '#' +./calc.at:1477: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +./calc.at:1480: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1482: cat stderr + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1478: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1479: $PREPARSER ./calc input +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1480: cat stderr +stderr: +./calc.at:1487: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +error: 4444 != 1 +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1479: cat stderr + | (# + 1) = 1111 +./calc.at:1482: $PREPARSER ./calc input +./calc.at:1477: cat stderr +./calc.at:1478: cat stderr +stderr: +input: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token "number" (1) +Error: discarding token "number" (1) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1111) +Shifting token "number" (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (!!) + (1 2) = 1 +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +error: 4444 != 1 +./calc.at:1480: $PREPARSER ./calc input +input: + | (1 + #) = 1111 +./calc.at:1479: $PREPARSER ./calc input +stderr: +549. calc.at:1477: input: + ok +syntax error, unexpected number +error: 2222 != 1 +stderr: +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + # + 1) = 1111 +./calc.at:1478: $PREPARSER ./calc input +stderr: +syntax error: invalid character: '#' +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token "number" (1) +Error: discarding token "number" (1) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1111) +Shifting token "number" (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +stderr: +1.6: syntax error: invalid character: '#' +stderr: +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +syntax error, unexpected number +error: 2222 != 1 +syntax error: invalid character: '#' +stderr: +./calc.at:1479: cat stderr + +1.6: syntax error: invalid character: '#' +./calc.at:1482: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1478: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (!!) + (1 2) = 1 +./calc.at:1479: $PREPARSER ./calc input +stderr: +./calc.at:1479: cat stderr +./calc.at:1482: cat stderr +syntax error, unexpected number +error: 2222 != 1 +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1480: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +563. calc.at:1489: testing Calculator C++ %glr-parser parse.error=verbose %debug %name-prefix "calc" api.token.prefix={TOK_} %verbose ... +./calc.at:1489: mv calc.y.tmp calc.y + +./calc.at:1489: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +input: +stderr: +./calc.at:1480: cat stderr +input: +syntax error, unexpected number +error: 2222 != 1 +./calc.at:1478: cat stderr + | (1 + # + 1) = 1111 +./calc.at:1482: $PREPARSER ./calc input + | (# + 1) = 1111 +./calc.at:1479: $PREPARSER ./calc input +stderr: +stderr: +input: +syntax error: invalid character: '#' +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (- *) + (1 2) = 1 +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token "number" (1) +Error: discarding token "number" (1) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1111) +Shifting token "number" (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1480: $PREPARSER ./calc input +input: +./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: + | (1 + 1) / (1 - 1) +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +syntax error: invalid character: '#' +./calc.at:1478: $PREPARSER ./calc input +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected number +error: 2222 != 1 +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token "number" (1) +Error: discarding token "number" (1) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1111) +Shifting token "number" (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1479: cat stderr +1.11-17: error: null divisor +./calc.at:1478: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1489: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected number +error: 2222 != 1 +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +1.11-17: error: null divisor +input: + | (- *) + (1 2) = 1 +./calc.at:1479: $PREPARSER ./calc input +./calc.at:1479: cat stderr +./calc.at:1482: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected number +error: 2222 != 1 +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1478: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1480: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected number +error: 2222 != 1 +input: +./calc.at:1482: cat stderr +./calc.at:1480: cat stderr + | (1 + # + 1) = 1111 +./calc.at:1479: $PREPARSER ./calc input +stderr: +input: +syntax error: invalid character: '#' +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1478: cat stderr + | (* *) + (*) + (*) +./calc.at:1480: $PREPARSER ./calc input + | (1 + 1) / (1 - 1) +./calc.at:1482: $PREPARSER ./calc input +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +stderr: +stderr: +551. calc.at:1478: ok +syntax error: invalid character: '#' +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 29 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (2) + $3 = token ')' () +-> $$ = nterm exp (2) +Entering state 8 +Reading a token +Next token is token '/' () +Shifting token '/' () +Entering state 22 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 28 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (1) +-> $$ = nterm exp (0) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (0) + $3 = token ')' () +-> $$ = nterm exp (0) +Entering state 31 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 10 (line 93): + $1 = nterm exp (2) + $2 = token '/' () + $3 = nterm exp (0) +error: null divisor +-> $$ = nterm exp (2) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1479: cat stderr +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +input: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 29 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (2) + $3 = token ')' () +-> $$ = nterm exp (2) +Entering state 8 +Reading a token +Next token is token '/' () +Shifting token '/' () +Entering state 22 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 28 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (1) +-> $$ = nterm exp (0) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (0) + $3 = token ')' () +-> $$ = nterm exp (0) +Entering state 31 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 10 (line 93): + $1 = nterm exp (2) + $2 = token '/' () + $3 = nterm exp (0) +error: null divisor +-> $$ = nterm exp (2) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () + | (* *) + (*) + (*) +./calc.at:1479: $PREPARSER ./calc input +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +stderr: +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + +./calc.at:1479: cat stderr +stderr: +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +./calc.at:1480: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1482: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: + | (1 + 1) / (1 - 1) +./calc.at:1479: $PREPARSER ./calc input +./calc.at:1480: cat stderr +stderr: +564. calc.at:1489: testing Calculator glr2.cc parse.error=verbose %debug %name-prefix "calc" api.token.prefix={TOK_} %verbose ... +error: null divisor +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1482: cat stderr +./calc.at:1489: mv calc.y.tmp calc.y + + | 1 + 2 * 3 + !+ ++ +./calc.at:1480: $PREPARSER ./calc input +./calc.at:1479: cat stderr +stderr: +./calc.at:1489: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +stderr: +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +error: null divisor +556. calc.at:1482: ok +stderr: +input: + + | 1 + 2 * 3 + !+ ++ +./calc.at:1479: $PREPARSER ./calc input +input: +stderr: + | 1 + 2 * 3 + !- ++ +./calc.at:1480: $PREPARSER ./calc input +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1489: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc $LIBS +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1479: cat stderr +565. calc.at:1491: testing Calculator C++ %glr-parser %locations %header parse.error=verbose %debug %name-prefix "calc" %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... +./calc.at:1491: mv calc.y.tmp calc.y + +stderr: +input: +./calc.at:1491: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y + | 1 + 2 * 3 + !- ++ +./calc.at:1479: $PREPARSER ./calc input +552. calc.at:1479: ok +stderr: +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1480: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1480: cat stderr + +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: + | (#) + (#) = 2222 +./calc.at:1480: $PREPARSER ./calc input +./calc.at:1479: cat stderr +stderr: +syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1491: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +566. calc.at:1491: testing Calculator glr2.cc %locations %header parse.error=verbose %debug %name-prefix "calc" %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... +./calc.at:1491: mv calc.y.tmp calc.y + +stderr: +input: +syntax error: invalid character: '#' +syntax error: invalid character: '#' + | (#) + (#) = 2222 +./calc.at:1479: $PREPARSER ./calc input +stderr: +./calc.at:1491: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +stderr: +syntax error: invalid character: '#' +syntax error: invalid character: '#' +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +./calc.at:1485: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +stderr: +./calc.at:1480: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +syntax error: invalid character: '#' +syntax error: invalid character: '#' +input: +./calc.at:1480: cat stderr + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1485: $PREPARSER ./calc input +input: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 30 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 9 (line 105): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '=' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (7) +Shifting token number (7) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (7) +-> $$ = nterm exp (7) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (7) + $2 = token '=' () + $3 = nterm exp (7) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (7) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 10 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 11 (line 115): + $1 = token '-' () + $2 = nterm exp (3) +-> $$ = nterm exp (-3) +Entering state 30 +Next token is token '=' () +Reducing stack 0 by rule 9 (line 105): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (-3) +-> $$ = nterm exp (-6) +Entering state 29 +Next token is token '=' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (-6) +-> $$ = nterm exp (-5) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (5) +Shifting token number (5) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (5) +-> $$ = nterm exp (5) +Entering state 10 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 11 (line 115): + $1 = token '-' () + $2 = nterm exp (5) +-> $$ = nterm exp (-5) +Entering state 27 +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (-5) + $2 = token '=' () + $3 = nterm exp (-5) +-> $$ = nterm exp (-5) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (-5) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 87): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 10 +Reading a token +Next token is token '^' () +Shifting token '^' () +Entering state 23 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 32 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 12 (line 116): + $1 = nterm exp (1) + $2 = token '^' () + $3 = nterm exp (2) +-> $$ = nterm exp (1) +Entering state 10 +Next token is token '=' () +Reducing stack 0 by rule 11 (line 115): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 10 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 11 (line 115): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 27 +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (-1) + $2 = token '=' () + $3 = nterm exp (-1) +-> $$ = nterm exp (-1) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (-1) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 10 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 11 (line 115): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 117): + $1 = token '(' () + $2 = nterm exp (-1) + $3 = token ')' () +-> $$ = nterm exp (-1) +Entering state 8 +Reading a token +Next token is token '^' () +Shifting token '^' () +Entering state 23 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 32 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 12 (line 116): + $1 = nterm exp (-1) + $2 = token '^' () + $3 = nterm exp (2) +-> $$ = nterm exp (1) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (1) + $2 = token '=' () + $3 = nterm exp (1) +-> $$ = nterm exp (1) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (1) + $2 = token '\n'./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 87): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 10 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 11 (line 115): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 10 +Next token is token '=' () +Reducing stack 0 by rule 11 (line 115): + $1 = token '-' () + $2 = nterm exp (-1) +-> $$ = nterm exp (1) +Entering state 10 +Next token is token '=' () +Reducing stack 0 by rule 11 (line 115): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 10 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 11 (line 115): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 27 +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (-1) + $2 = token '=' () + $3 = nterm exp (-1) +-> $$ = nterm exp (-1) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (-1) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 87): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 28 +Reading a token +Next token is token '-' () +Reducing stack 0 by rule 8 (line 104): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (2) +-> $$ = nterm exp (-1) +Entering state 8 +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 28 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 8 (line 104): + $1 = nterm exp (-1) + $2 = token '-' () + $3 = nterm exp (3) +-> $$ = nterm exp (-4) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (4) +Shifting token number (4) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (4) +-> $$ = nterm exp (4) +Entering state 10 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 11 (line 115): + $1 = token '-' () + $2 = nterm exp (4) +-> $$ = nterm exp (-4) +Entering state 27 +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (-4) + $2 = token '=' () + $3 = nterm exp (-4) +-> $$ = nterm exp (-4) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (-4) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 12 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 28 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 8 (line 104): + $1 = nterm exp (2) + $2 = token '-' () + $3 = nterm exp (3) +-> $$ = nterm exp (-1) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 117): + $1 = token '(' () + $2 = nterm exp (-1) + $3 = token ')' () +-> $$ = nterm exp (-1) +Entering state 28 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 8 (line 104): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (-1) +-> $$ = nterm exp (2) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (2) + $2 = token '=' () + $3 = nterm exp (2) +-> $$ = nterm exp (2) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (2) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 87): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 8 +Reading a token +Next token is token '^' () +Shifting token '^' () +Entering state 23 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 32 +Reading a token +Next token is token '^' () +Shifting token '^' () +Entering state 23 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 32 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 12 (line 116): + $1 = nterm exp (2) + $2 = token '^' () + $3 = nterm exp (3) +-> $$ = nterm exp (8) +Entering state 32 +Next token is token '=' () +Reducing stack 0 by rule 12 (line 116): + $1 = nterm exp (2) + $2 = token '^' () + $3 = nterm exp (8) +-> $$ = nterm exp (256) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (256) +Shifting token number (256) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (256) +-> $$ = nterm exp (256) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (256) + $2 = token '=' () + $3 = nterm exp (256) +-> $$ = nterm exp (256) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (256) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 12 +Reading a token +Next token is token '^' () +Shifting token '^' () +Entering state 23 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 32 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 12 (line 116): + $1 = nterm exp (2) + $2 = token '^' () + $3 = nterm exp (2) +-> $$ = nterm exp (4) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 117): + $1 = token '(' () + $2 = nterm exp (4) + $3 = token ')' () +-> $$ = nterm exp (4) +Entering state 8 +Reading a token +Next token is token '^' () +Shifting token '^' () +Entering state 23 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 32 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 12 (line 116): + $1 = nterm exp (4) + $2 = token '^' () + $3 = nterm exp (3) +-> $$ = nterm exp (64) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (64) +Shifting token number (64) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (64) +-> $$ = nterm exp (64) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (64) + $2 = token '=' () + $3 = nterm exp (64) +-> $$ = nterm exp (64) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (64) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + #) = 1111 +./calc.at:1479: cat stderr +./calc.at:1480: $PREPARSER ./calc input +stderr: +./calc.at:1491: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 30 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 9 (line 105): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '=' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (7) +Shifting token number (7) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (7) +-> $$ = nterm exp (7) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (7) + $2 = token '=' () + $3 = nterm exp (7) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (7) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 10 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 11 (line 115): + $1 = token '-' () + $2 = nterm exp (3) +-> $$ = nterm exp (-3) +Entering state 30 +Next token is token '=' () +Reducing stack 0 by rule 9 (line 105): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (-3) +-> $$ = nterm exp (-6) +Entering state 29 +Next token is token '=' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (-6) +-> $$ = nterm exp (-5) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (5) +Shifting token number (5) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (5) +-> $$ = nterm exp (5) +Entering state 10 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 11 (line 115): + $1 = token '-' () + $2 = nterm exp (5) +-> $$ = nterm exp (-5) +Entering state 27 +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (-5) + $2 = token '=' () + $3 = nterm exp (-5) +-> $$ = nterm exp (-5) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (-5) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 87): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 10 +Reading a token +Next token is token '^' () +Shifting token '^' () +Entering state 23 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 32 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 12 (line 116): + $1 = nterm exp (1) + $2 = token '^' () + $3 = nterm exp (2) +-> $$ = nterm exp (1) +Entering state 10 +Next token is token '=' () +Reducing stack 0 by rule 11 (line 115): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 10 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 11 (line 115): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 27 +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (-1) + $2 = token '=' () + $3 = nterm exp (-1) +-> $$ = nterm exp (-1) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (-1) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 10 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 11 (line 115): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 117): + $1 = token '(' () + $2 = nterm exp (-1) + $3 = token ')' () +-> $$ = nterm exp (-1) +Entering state 8 +Reading a token +Next token is token '^' () +Shifting token '^' () +Entering state 23 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 32 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 12 (line 116): + $1 = nterm exp (-1) + $2 = token '^' () + $3 = nterm exp (2) +-> $$ = nterm exp (1) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (1) + $2 = token '=' () + $3 = nterm exp (1) +-> $$ = nterm exp (1) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (1) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 87): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 10 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 11 (line 115): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 10 +Next token is token '=' () +Reducing stack 0 by rule 11 (line 115): + $1 = token '-' () + $2 = nterm exp (-1) +-> $$ = nterm exp (1) +Entering state 10 +Next token is token '=' () +Reducing stack 0 by rule 11 (line 115): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 10 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 11 (line 115): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 27 +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (-1) + $2 = token '=' () + $3 = nterm exp (-1) +-> $$ = nterm exp (-1) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (-1) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 87): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 28 +Reading a token +Next token is token '-' () +Reducing stack 0 by rule 8 (line 104): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (2) +-> $$ = nterm exp (-1) +Entering state 8 +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 28 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 8 (line 104): + $1 = nterm exp (-1) + $2 = token '-' () + $3 = nterm exp (3) +-> $$ = nterm exp (-4) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (4) +Shifting token number (4) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (4) +-> $$ = nterm exp (4) +Entering state 10 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 11 (line 115): + $1 = token '-' () + $2 = nterm exp (4) +-> $$ = nterm exp (-4) +Entering state 27 +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (-4) + $2 = token '=' () + $3 = nterm exp (-4) +-> $$ = nterm exp (-4) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (-4) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 12 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 28 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 8 (line 104): + $1 = nterm exp (2) + $2 = token '-' () + $3 = nterm exp (3) +-> $$ = nterm exp (-1) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 117): + $1 = token '(' () + $2 = nterm exp (-1) + $3 = token ')' () +-> $$ = nterm exp (-1) +Entering state 28 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 8 (line 104): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (-1) +-> $$ = nterm exp (2) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (2) + $2 = token '=' () + $3 = nterm exp (2) +-> $$ = nterm exp (2) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (2) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 87): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 8 +Reading a token +Next token is token '^' () +Shifting token '^' () +Entering state 23 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 32 +Reading a token +Next token is token '^' () +Shifting token '^' () +Entering state 23 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 32 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 12 (line 116): + $1 = nterm exp (2) + $2 = token '^' () + $3 = nterm exp (3) +-> $$ = nterm exp (8) +Entering state 32 +Next token is token '=' () +Reducing stack 0 by rule 12 (line 116): + $1 = nterm exp (2) + $2 = token '^' () + $3 = nterm exp (8) +-> $$ = nterm exp (256) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (256) +Shifting token number (256) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (256) +-> $$ = nterm exp (256) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (256) + $2 = token '=' () + $3 = nterm exp (256) +-> $$ = nterm exp (256) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (256) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 12 +Reading a token +Next token is token '^' () +Shifting token '^' () +Entering state 23 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 32 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 12 (line 116): + $1 = nterm exp (2) + $2 = token '^' () + $3 = nterm exp (2) +-> $$ = nterm exp (4) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 117): + $1 = token '(' () + $2 = nterm exp (4) + $3 = token ')' () +-> $$ = nterm exp (4) +Entering state 8 +Reading a token +Next token is token '^' () +Shifting token '^' () +Entering state 23 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 32 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 12 (line 116): + $1 = nterm exp (4) + $2 = token '^' () + $3 = nterm exp (3) +-> $$ = nterm exp (64) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (64) +Shifting token number (64) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (64) +-> $$ = nterm exp (64) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (64) + $2 = token '=' () + $3 = nterm exp (64) +-> $$ = nterm exp (64) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (64) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 83): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +syntax error: invalid character: '#' +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | 1 2 +input: +./calc.at:1485: $PREPARSER ./calc input +stderr: + | (1 + #) = 1111 +./calc.at:1479: $PREPARSER ./calc input +stderr: +syntax error: invalid character: '#' +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token number (2) +syntax error, unexpected number +Error: popping nterm exp (1) +Cleanup: discarding lookahead token number (2) +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +syntax error: invalid character: '#' +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token number (2) +syntax error, unexpected number +Error: popping nterm exp (1) +Cleanup: discarding lookahead token number (2) +stderr: +syntax error: invalid character: '#' +./calc.at:1480: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1485: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1480: cat stderr +./calc.at:1485: cat stderr +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +./calc.at:1479: cat stderr + | (# + 1) = 1111 +./calc.at:1480: $PREPARSER ./calc input +input: +stderr: + | 1//2 +./calc.at:1485: $PREPARSER ./calc input +syntax error: invalid character: '#' +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | (# + 1) = 1111 +./calc.at:1479: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '/' () +Shifting token '/' () +Entering state 22 +Reading a token +Next token is token '/' () +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '/' () +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +stderr: +syntax error: invalid character: '#' +syntax error: invalid character: '#' +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '/' () +Shifting token '/' () +Entering state 22 +Reading a token +Next token is token '/' () +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '/' () +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +syntax error: invalid character: '#' +./calc.at:1480: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1485: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1480: cat stderr +./calc.at:1485: cat stderr +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: + | (1 + # + 1) = 1111 +input: +./calc.at:1480: $PREPARSER ./calc input +./calc.at:1479: cat stderr + | error +stderr: +./calc.at:1485: $PREPARSER ./calc input +syntax error: invalid character: '#' +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +stderr: + | (1 + # + 1) = 1111 +./calc.at:1479: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token invalid token () +syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token () +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +syntax error: invalid character: '#' +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error: invalid character: '#' +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token invalid token () +syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token () +syntax error: invalid character: '#' +./calc.at:1480: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1485: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1485: cat stderr +stderr: +./calc.at:1480: cat stderr +./calc.at:1479: cat stderr +stdout: +./calc.at:1482: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +input: + | 1 = 2 = 3 +input: +./calc.at:1485: $PREPARSER ./calc input + | (1 + 1) / (1 - 1) +./calc.at:1479: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 27 +Reading a token +Next token is token '=' () +syntax error, unexpected '=' +Error: popping nterm exp (2) +Error: popping token '=' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '=' () +stderr: +error: null divisor +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +input: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1482: $PREPARSER ./calc input + | (1 + 1) / (1 - 1) +stderr: +./calc.at:1480: $PREPARSER ./calc input +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 27 +Reading a token +Next token is token '=' () +syntax error, unexpected '=' +Error: popping nterm exp (2) +Error: popping token '=' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '=' () +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token "number" (2) +Shifting token "number" (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token "number" (3) +Shifting token "number" (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (3) +-> $$ = nterm exp (3) +Entering state 30 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (7) +Shifting token "number" (7) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (7) +-> $$ = nterm exp (7) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (7) + $2 = token '=' () + $3 = nterm exp (7) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (7) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token "number" (2) +Shifting token "number" (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token "number" (3) +Shifting token "number" (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (3) +-> $$ = nterm exp (3) +Entering state 10 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (3) +-> $$ = nterm exp (-3) +Entering state 30 +Next token is token '=' () +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (-3) +-> $$ = nterm exp (-6) +Entering state 29 +Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (-6) +-> $$ = nterm exp (-5) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token "number" (5) +Shifting token "number" (5) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (5) +-> $$ = nterm exp (5) +Entering state 10 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (5) +-> $$ = nterm exp (-5) +Entering state 27 +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (-5) + $2 = token '=' () + $3 = nterm exp (-5) +-> $$ = nterm exp (-5) Entering state 8 Next token is token '\n' () Shifting token '\n' () @@ -180187,100 +181048,11 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error, unexpected '=' -stderr: -555. calc.at:1480: ok +./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +error: null divisor +./calc.at:1480: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +error: null divisor stderr: -./calc.at:1479: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1485: cat stderr -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token "number" (1111) -Shifting token "number" (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1111) --> $$ = nterm exp (1111) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token @@ -181117,260 +181889,90 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () +stderr: input: -./calc.at:1479: cat stderr +error: null divisor +./calc.at:1485: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 | 1 2 -input: -./calc.at:1486: $PREPARSER ./calc input - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1485: $PREPARSER ./calc input -input: - | - | +1 -./calc.at:1479: $PREPARSER ./calc input -stderr: -syntax error, unexpected '+' -stderr: -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - -stderr: +./calc.at:1482: $PREPARSER ./calc input +./calc.at:1479: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -syntax error, unexpected '+' +./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token ')' () -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1) +Shifting token "number" (1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) -> $$ = nterm exp (1) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (2) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (3) -Entering state 12 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token ')' () -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' () -Error: popping nterm exp (3) -Shifting token error () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (2222) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (3333) Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 +Next token is token "number" (2) +syntax error +Error: popping nterm exp (1) +Cleanup: discarding lookahead token "number" (2) +./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1479: cat stderr +stderr: +input: +Starting parse +Entering state 0 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1) +Shifting token "number" (1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) -> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 30 -Reading a token -Next token is token '*' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (1) - $2 = token '*' () - $3 = nterm exp (2) --> $$ = nterm exp (2) -Entering state 12 -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' () -Error: popping nterm exp (2) -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (3333) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (4444) Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 27 +Next token is token "number" (2) +syntax error +Error: popping nterm exp (1) +Cleanup: discarding lookahead token "number" (2) +553. calc.at:1479: ok +./calc.at:1480: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | + | +1 +./calc.at:1485: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (4444) - $2 = token '=' () - $3 = nterm exp (1) -error: 4444 != 1 --> $$ = nterm exp (4444) -Entering state 8 -Next token is token '\n' () Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (4444) - $2 = token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 87): + $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 82): @@ -181378,29 +181980,34 @@ -> $$ = nterm input () Entering state 6 Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () +Next token is token '+' () +syntax error, unexpected '+' +Error: popping nterm input () +Cleanup: discarding lookahead token '+' () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1480: cat stderr +stderr: Starting parse Entering state 0 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 87): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 Reading a token -Next token is token "number" (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Cleanup: discarding lookahead token "number" (2) -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1479: "$PERL" -pi -e 'use strict; +Next token is token '+' () +syntax error, unexpected '+' +Error: popping nterm input () +Cleanup: discarding lookahead token '+' () +555. calc.at:1480: ok +./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -181410,7 +182017,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1482: "$PERL" -pi -e 'use strict; + +./calc.at:1482: cat stderr +./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -181420,7 +182029,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1479: cat stderr + +./calc.at:1485: cat stderr +input: +567. calc.at:1492: testing Calculator C++ %glr-parser %locations %header parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... +./calc.at:1492: mv calc.y.tmp calc.y + + | 1//2 +./calc.at:1482: $PREPARSER ./calc input +./calc.at:1485: $PREPARSER ./calc /dev/null stderr: stderr: Starting parse @@ -181434,10 +182051,114 @@ -> $$ = nterm exp (1) Entering state 8 Reading a token -Next token is token "number" (2) -syntax error, unexpected number +Next token is token '/' () +Shifting token '/' () +Entering state 22 +Reading a token +Next token is token '/' () +syntax error +Error: popping token '/' () Error: popping nterm exp (1) -Cleanup: discarding lookahead token "number" (2) +Cleanup: discarding lookahead token '/' () +Starting parse +Entering state 0 +Reading a token +Now at end of input. +syntax error, unexpected end of file +Cleanup: discarding lookahead token end of file () +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1492: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +stderr: +568. calc.at:1492: testing Calculator glr2.cc %locations %header parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... +stderr: +Starting parse +Entering state 0 +Reading a token +Now at end of input. +syntax error, unexpected end of file +Cleanup: discarding lookahead token end of file () +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '/' () +Shifting token '/' () +Entering state 22 +Reading a token +Next token is token '/' () +syntax error +Error: popping token '/' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '/' () +./calc.at:1492: mv calc.y.tmp calc.y + +./calc.at:1492: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +./calc.at:1485: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1482: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1485: cat stderr +stdout: +./calc.at:1486: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +./calc.at:1492: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS +./calc.at:1482: cat stderr +input: +input: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1486: $PREPARSER ./calc input + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1485: $PREPARSER ./calc input +input: +stderr: +stderr: +./calc.at:1492: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS Starting parse Entering state 0 Reading a token @@ -181685,100 +182406,81 @@ Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () -./calc.at:1479: $PREPARSER ./calc /dev/null -stderr: -syntax error, unexpected end of input -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -566. calc.at:1491: testing Calculator glr2.cc %locations %header parse.error=verbose %debug %name-prefix "calc" %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... -./calc.at:1491: mv calc.y.tmp calc.y - -./calc.at:1491: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -./calc.at:1482: cat stderr -stderr: -syntax error, unexpected end of input -./calc.at:1485: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -./calc.at:1485: cat stderr -./calc.at:1486: cat stderr -./calc.at:1491: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS - | (# + 1) = 1111 -./calc.at:1482: $PREPARSER ./calc input -stderr: +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | error Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 8 Reading a token Next token is token '+' () -Error: discarding token '+' () +Shifting token '+' () +Entering state 20 Reading a token -Next token is token "number" (1) -Error: discarding token "number" (1) +Next token is token "number" (2) +Shifting token "number" (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2) +-> $$ = nterm exp (2) +Entering state 29 Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token "number" (3) +Shifting token "number" (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (3) +-> $$ = nterm exp (3) +Entering state 30 Reading a token Next token is token '=' () +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (1111) -Shifting token "number" (1111) +Next token is token "number" (7) +Shifting token "number" (7) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1111) --> $$ = nterm exp (1111) + $1 = token "number" (7) +-> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) + $1 = nterm exp (7) $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) + $3 = nterm exp (7) +-> $$ = nterm exp (7) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) + $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -181787,2148 +182489,72 @@ -> $$ = nterm input () Entering state 6 Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () -input: -./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1479: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (!!) + (1 2) = 1 -./calc.at:1485: $PREPARSER ./calc input -./calc.at:1479: cat stderr -stderr: -Starting parse -Entering state 0 +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 8 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token "number" (2) +Shifting token "number" (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2) +-> $$ = nterm exp (2) +Entering state 29 Reading a token -Next token is token '+' () -Error: discarding token '+' () +Next token is token '*' () +Shifting token '*' () +Entering state 21 Reading a token -Next token is token "number" (1) -Error: discarding token "number" (1) +Next token is token '-' () +Shifting token '-' () +Entering state 2 Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 +Next token is token "number" (3) +Shifting token "number" (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (3) +-> $$ = nterm exp (3) +Entering state 10 Reading a token Next token is token '=' () +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (3) +-> $$ = nterm exp (-3) +Entering state 30 +Next token is token '=' () +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (-3) +-> $$ = nterm exp (-6) +Entering state 29 +Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (-6) +-> $$ = nterm exp (-5) +Entering state 8 +Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (1111) -Shifting token "number" (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1111) --> $$ = nterm exp (1111) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () -stderr: -input: -input: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 15 -Reducing stack 0 by rule 16 (line 120): - $1 = token '!' () - $2 = token '!' () -Shifting token error () -Entering state 11 -Reading a token -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token number (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token number (2) -Error: discarding token number (2) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2222) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1479: $PREPARSER ./calc input -stderr: -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -error: 4444 != 1 -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1//2 -./calc.at:1486: $PREPARSER ./calc input -stderr: -stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 15 -Reducing stack 0 by rule 16 (line 120): - $1 = token '!' () - $2 = token '!' () -Shifting token error () -Entering state 11 -Reading a token -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token number (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token number (2) -Error: discarding token number (2) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2222) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1482: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '/' () -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '/' () -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -error: 4444 != 1 -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1485: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1482: cat stderr -./calc.at:1485: cat stderr -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '/' () -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '/' () -input: - | (- *) + (1 2) = 1 -./calc.at:1485: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 9 -Reducing stack 0 by rule 15 (line 119): - $1 = token '-' () - $2 = token error () -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token number (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token number (2) -Error: discarding token number (2) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2222) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1479: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 9 -Reducing stack 0 by rule 15 (line 119): - $1 = token '-' () - $2 = token error () -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token number (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token number (2) -Error: discarding token number (2) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2222) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1479: cat stderr -./calc.at:1485: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (1 + # + 1) = 1111 -./calc.at:1482: $PREPARSER ./calc input -./calc.at:1485: cat stderr -stderr: -input: -input: - | (* *) + (*) + (*) -./calc.at:1485: $PREPARSER ./calc input -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token "number" (1) -Error: discarding token "number" (1) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token "number" (1111) -Shifting token "number" (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1111) --> $$ = nterm exp (1111) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () -./calc.at:1486: cat stderr -./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (2222) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (3333) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (3333) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () - | (!!) + (1 2) = 1 -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1479: $PREPARSER ./calc input -input: -stderr: - | error -./calc.at:1486: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token "number" (1) -Error: discarding token "number" (1) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token "number" (1111) -Shifting token "number" (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1111) --> $$ = nterm exp (1111) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (2222) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (3333) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (3333) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -stderr: -stderr: -syntax error, unexpected number -error: 2222 != 1 -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Next token is token "invalid token" () -syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" () -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error, unexpected number -error: 2222 != 1 -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "invalid token" () -syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" () -./calc.at:1485: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1482: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1485: cat stderr -input: - | 1 + 2 * 3 + !+ ++ -./calc.at:1485: $PREPARSER ./calc input -./calc.at:1479: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1482: cat stderr -stderr: -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 30 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) -Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 14 -Reducing stack 0 by rule 17 (line 121): - $1 = token '!' () - $2 = token '+' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1486: cat stderr -input: -./calc.at:1479: cat stderr - | (1 + 1) / (1 - 1) -./calc.at:1482: $PREPARSER ./calc input -input: -stderr: - | 1 = 2 = 3 -./calc.at:1486: $PREPARSER ./calc input -stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token "number" (2) -Shifting token "number" (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2) --> $$ = nterm exp (2) -Entering state 27 -Reading a token -Next token is token '=' () -syntax error, unexpected '=' -Error: popping nterm exp (2) -Error: popping token '=' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '=' () -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 29 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (2) - $3 = token ')' () --> $$ = nterm exp (2) -Entering state 8 -Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 28 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (1) --> $$ = nterm exp (0) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (0) - $3 = token ')' () --> $$ = nterm exp (0) -Entering state 31 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (2) - $2 = token '/' () - $3 = nterm exp (0) -error: null divisor --> $$ = nterm exp (2) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 30 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) -Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 14 -Reducing stack 0 by rule 17 (line 121): - $1 = token '!' () - $2 = token '+' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token "number" (2) -Shifting token "number" (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2) --> $$ = nterm exp (2) -Entering state 27 -Reading a token -Next token is token '=' () -syntax error, unexpected '=' -Error: popping nterm exp (2) -Error: popping token '=' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '=' () -input: - | 1 + 2 * 3 + !- ++ -stderr: -./calc.at:1485: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 29 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (2) - $3 = token ')' () --> $$ = nterm exp (2) -Entering state 8 -Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 28 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (1) --> $$ = nterm exp (0) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (0) - $3 = token ')' () --> $$ = nterm exp (0) -Entering state 31 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (2) - $2 = token '/' () - $3 = nterm exp (0) -error: null divisor --> $$ = nterm exp (2) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 30 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) -Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 13 -Reducing stack 0 by rule 18 (line 122): - $1 = token '!' () - $2 = token '-' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 30 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) -Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 13 -Reducing stack 0 by rule 18 (line 122): - $1 = token '!' () - $2 = token '-' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) -input: - | (- *) + (1 2) = 1 -./calc.at:1479: $PREPARSER ./calc input -stdout: -stderr: -./calc.at:1485: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected number -error: 2222 != 1 -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1485: cat stderr -stderr: -./calc.at:1482: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: - | (#) + (#) = 2222 -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected number -error: 2222 != 1 -./calc.at:1485: $PREPARSER ./calc input -stderr: -input: -./calc.at:1482: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1486: cat stderr - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (2222) -Shifting token number (2222) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2222) --> $$ = nterm exp (2222) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (2222) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2222) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1482: $PREPARSER ./calc input -stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (2222) -Shifting token number (2222) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2222) --> $$ = nterm exp (2222) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (2222) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2222) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token "number" (2) -Shifting token "number" (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token "number" (3) -Shifting token "number" (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (3) --> $$ = nterm exp (3) -Entering state 30 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token "number" (7) -Shifting token "number" (7) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (7) --> $$ = nterm exp (7) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (7) - $2 = token '=' () - $3 = nterm exp (7) --> $$ = nterm exp (7) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (7) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token "number" (2) -Shifting token "number" (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token "number" (3) -Shifting token "number" (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (3) --> $$ = nterm exp (3) -Entering state 10 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' () - $2 = nterm exp (3) --> $$ = nterm exp (-3) -Entering state 30 -Next token is token '=' () -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (-3) --> $$ = nterm exp (-6) -Entering state 29 -Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (-6) --> $$ = nterm exp (-5) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token "number" (5) -Shifting token "number" (5) +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token "number" (5) +Shifting token "number" (5) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (5) @@ -184618,64 +183244,17 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | - | +1 -./calc.at:1479: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1486: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '+' () -syntax error, unexpected '+' -Error: popping nterm input () -Cleanup: discarding lookahead token '+' () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1482: $PREPARSER ./calc input +stderr: +stderr: stderr: Starting parse Entering state 0 Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '+' () -syntax error, unexpected '+' -Error: popping nterm input () -Cleanup: discarding lookahead token '+' () -./calc.at:1482: cat stderr -stderr: +Next token is token "invalid token" () +syntax error +Cleanup: discarding lookahead token "invalid token" () Starting parse Entering state 0 Reading a token @@ -185512,78 +184091,7 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -./calc.at:1479: cat stderr -input: - | 1 2 -./calc.at:1482: $PREPARSER ./calc input -./calc.at:1485: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -556. calc.at:1482: ok -./calc.at:1485: cat stderr -input: -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token "number" (2) -syntax error -Error: popping nterm exp (1) -Cleanup: discarding lookahead token "number" (2) ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (* *) + (*) + (*) -./calc.at:1479: $PREPARSER ./calc input -./calc.at:1486: cat stderr -stderr: -stderr: -input: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token "number" (2) -syntax error -Error: popping nterm exp (1) -Cleanup: discarding lookahead token "number" (2) - | (1 + #) = 1111 -./calc.at:1485: $PREPARSER ./calc input -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: Starting parse Entering state 0 Reading a token @@ -185591,28 +184099,9 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token Next token is token ')' () +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () @@ -185624,50 +184113,9 @@ -> $$ = nterm exp (1111) Entering state 8 Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1111) -Shifting token number (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1486: $PREPARSER ./calc /dev/null -stderr: -stderr: - -Starting parse -Entering state 0 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () @@ -185685,159 +184133,16 @@ Shifting token '+' () Entering state 20 Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1111) -Shifting token number (1111) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -stderr: -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Starting parse -Entering state 0 -Reading a token -Now at end of input. -syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" () -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Reading a token -Now at end of input. -syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" () -./calc.at:1482: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1486: cat stderr -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1486: $PREPARSER ./calc input -stderr: -./calc.at:1482: cat stderr -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token ')' () -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) + $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): +Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (1) @@ -185847,16 +184152,16 @@ Shifting token '+' () Entering state 20 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (1) +Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) -> $$ = nterm exp (1) Entering state 29 Reading a token Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): +Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2) $2 = token '+' () $3 = nterm exp (1) @@ -185875,7 +184180,7 @@ Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () @@ -185883,7 +184188,7 @@ Entering state 29 Reading a token Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): +Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) @@ -185915,7 +184220,7 @@ Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () @@ -185923,7 +184228,7 @@ Entering state 29 Reading a token Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): +Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) @@ -185937,11 +184242,11 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (1) +Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token @@ -185949,16 +184254,16 @@ Shifting token '*' () Entering state 21 Reading a token -Next token is token "number" (2) -Shifting token "number" (2) +Next token is token number (2) +Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) -> $$ = nterm exp (2) Entering state 30 Reading a token Next token is token '*' () -Reducing stack 0 by rule 9 (line 92): +Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (1) $2 = token '*' () $3 = nterm exp (2) @@ -185982,7 +184287,7 @@ Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () @@ -185990,7 +184295,7 @@ Entering state 29 Reading a token Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): +Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) @@ -186000,16 +184305,16 @@ Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (1) +Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) @@ -186019,24 +184324,76 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 69): +Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" () +Shifting token end of file () Entering state 16 -Cleanup: popping token "end of input" () +Cleanup: popping token end of file () Cleanup: popping nterm input () +input: + | 1 2 +./calc.at:1486: $PREPARSER ./calc input +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token "invalid token" () +syntax error +Cleanup: discarding lookahead token "invalid token" () +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token "number" (2) +syntax error, unexpected number +Error: popping nterm exp (1) +Cleanup: discarding lookahead token "number" (2) ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -567. calc.at:1492: testing Calculator C++ %glr-parser %locations %header parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... -./calc.at:1479: "$PERL" -pi -e 'use strict; +./calc.at:1485: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token "number" (2) +syntax error, unexpected number +Error: popping nterm exp (1) +Cleanup: discarding lookahead token "number" (2) +./calc.at:1485: cat stderr +./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -186046,6 +184403,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +input: + | (!!) + (1 2) = 1 +./calc.at:1485: $PREPARSER ./calc input stderr: Starting parse Entering state 0 @@ -186054,14 +184414,23 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token ')' () -syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 15 +Reducing stack 0 by rule 16 (line 120): + $1 = token '!' () + $2 = token '!' () Shifting token error () Entering state 11 +Reading a token Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () @@ -186076,119 +184445,123 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (1) +Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) -> $$ = nterm exp (1) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) Entering state 12 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 29 Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (2) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (3) -Entering state 12 -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Next token is token number (2) +syntax error, unexpected number +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token number (2) +Error: discarding token number (2) Reading a token Next token is token ')' () -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' () -Error: popping nterm exp (3) -Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): +Next token is token '=' () +Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (1) +error: 2222 != 1 +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1482: cat stderr +./calc.at:1486: cat stderr +Starting parse +Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 15 +Reducing stack 0 by rule 16 (line 120): + $1 = token '!' () + $2 = token '!' () Shifting token error () Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token '*' () -Error: discarding token '*' () Reading a token Next token is token ')' () -Entering state 11 -Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (2222) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (3333) Entering state 8 +Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 @@ -186197,52 +184570,28 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (1) +Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token "number" (2) -Shifting token "number" (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2) --> $$ = nterm exp (2) -Entering state 30 -Reading a token -Next token is token '*' () -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1) - $2 = token '*' () - $3 = nterm exp (2) --> $$ = nterm exp (2) -Entering state 12 -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' () -Error: popping nterm exp (2) +Next token is token number (2) +syntax error, unexpected number +Error: popping nterm exp (1) Shifting token error () Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token number (2) +Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () @@ -186250,67 +184599,57 @@ Entering state 29 Reading a token Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (3333) +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) --> $$ = nterm exp (4444) +-> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (1) +Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (4444) +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) -error: 4444 != 1 --> $$ = nterm exp (4444) +error: 2222 != 1 +-> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (4444) +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 69): +Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" () +Shifting token end of file () Entering state 16 -Cleanup: popping token "end of input" () +Cleanup: popping token end of file () Cleanup: popping nterm input () input: -./calc.at:1492: mv calc.y.tmp calc.y - - | 1//2 + | 1 = 2 = 3 +input: ./calc.at:1482: $PREPARSER ./calc input -./calc.at:1485: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1479: cat stderr -./calc.at:1485: cat stderr + | 1//2 +./calc.at:1486: $PREPARSER ./calc input +stderr: stderr: Starting parse Entering state 0 @@ -186328,13 +184667,42 @@ Entering state 22 Reading a token Next token is token '/' () -syntax error +syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (2) +Shifting token "number" (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2) +-> $$ = nterm exp (2) +Entering state 27 +Reading a token +Next token is token '=' () +syntax error +Error: popping nterm exp (2) +Error: popping token '=' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '=' () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1486: "$PERL" -pi -e 'use strict; +./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -186344,10 +184712,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (# + 1) = 1111 -./calc.at:1485: $PREPARSER ./calc input stderr: -input: Starting parse Entering state 0 Reading a token @@ -186364,89 +184729,42 @@ Entering state 22 Reading a token Next token is token '/' () -syntax error +syntax error, unexpected '/', expecting number or '-' or '(' or '!' Error: popping token '/' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '/' () -./calc.at:1492: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y stderr: -./calc.at:1486: cat stderr - | 1 + 2 * 3 + !+ ++ -./calc.at:1479: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token number (1) -Error: discarding token number (1) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token number (1111) -Shifting token number (1111) +Next token is token "number" (2) +Shifting token "number" (2) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1111) --> $$ = nterm exp (1111) +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2) +-> $$ = nterm exp (2) Entering state 27 Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1482: "$PERL" -pi -e 'use strict; +Next token is token '=' () +syntax error +Error: popping nterm exp (2) +Error: popping token '=' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '=' () +./calc.at:1485: cat stderr +./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -186457,8 +184775,20 @@ }eg ' expout || exit 77 input: - | (!!) + (1 2) = 1 -./calc.at:1486: $PREPARSER ./calc input + | (- *) + (1 2) = 1 +./calc.at:1485: $PREPARSER ./calc input +./calc.at:1482: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1486: cat stderr +stderr: Starting parse Entering state 0 Reading a token @@ -186466,18 +184796,57 @@ Shifting token '(' () Entering state 4 Reading a token -syntax error: invalid character: '#' -Next token is token error () +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 9 +Reducing stack 0 by rule 15 (line 119): + $1 = token '-' () + $2 = token error () Shifting token error () Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 Reading a token Next token is token '+' () -Error: discarding token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 Reading a token Next token is token number (1) -Error: discarding token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token number (2) +syntax error, unexpected number +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token number (2) +Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 @@ -186489,32 +184858,40 @@ $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 8 +Entering state 29 Reading a token Next token is token '=' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token number (1111) -Shifting token number (1111) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): - $1 = token number (1111) --> $$ = nterm exp (1111) + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (1111) + $1 = nterm exp (2222) $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) + $3 = nterm exp (1) +error: 2222 != 1 +-> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (1111) + $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -186528,8 +184905,12 @@ Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | error +./calc.at:1486: $PREPARSER ./calc input +stderr: stderr: -./calc.at:1482: cat stderr Starting parse Entering state 0 Reading a token @@ -186537,23 +184918,28 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 +Next token is token '-' () +Shifting token '-' () +Entering state 2 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 15 -Reducing stack 0 by rule 16 (line 107): - $1 = token '!' () - $2 = token '!' () +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 9 +Reducing stack 0 by rule 15 (line 119): + $1 = token '-' () + $2 = token error () Shifting token error () Entering state 11 +Next token is token '*' () +Error: discarding token '*' () Reading a token Next token is token ')' () +Entering state 11 +Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () @@ -186568,28 +184954,28 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (1) +Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token -Next token is token "number" (2) +Next token is token number (2) syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 -Next token is token "number" (2) -Error: discarding token "number" (2) +Next token is token number (2) +Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () @@ -186597,7 +184983,7 @@ Entering state 29 Reading a token Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): +Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) @@ -186607,16 +184993,16 @@ Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (1) +Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) @@ -186626,36 +185012,121 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 69): +Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" () +Shifting token end of file () Entering state 16 -Cleanup: popping token "end of input" () +Cleanup: popping token end of file () Cleanup: popping nterm input () +./calc.at:1482: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token "invalid token" () +syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token "invalid token" () +syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" () input: -stderr: - | error +./calc.at:1485: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | + | +1 ./calc.at:1482: $PREPARSER ./calc input -input: stderr: +./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token -Next token is token "invalid token" () +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '+' () syntax error -Cleanup: discarding lookahead token "invalid token" () +Error: popping nterm input () +Cleanup: discarding lookahead token '+' () ./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +stdout: +stderr: +input: +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '+' () +syntax error +Error: popping nterm input () +Cleanup: discarding lookahead token '+' () +./calc.at:1489: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +./calc.at:1486: cat stderr + | (* *) + (*) + (*) +./calc.at:1485: $PREPARSER ./calc input +input: +stderr: Starting parse Entering state 0 Reading a token @@ -186663,23 +185134,22 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 15 -Reducing stack 0 by rule 16 (line 107): - $1 = token '!' () - $2 = token '!' () +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 +Next token is token '*' () +Error: discarding token '*' () Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () @@ -186694,116 +185164,84 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token "number" (2) -syntax error, unexpected number -Error: popping nterm exp (1) +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 -Next token is token "number" (2) -Error: discarding token "number" (2) +Next token is token '*' () +Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 27 +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2222) +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 69): +Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" () +Shifting token end of file () Entering state 16 -Cleanup: popping token "end of input" () +Cleanup: popping token end of file () Cleanup: popping nterm input () -stderr: - | 1 + 2 * 3 + !- ++ -Starting parse -Entering state 0 -Reading a token -Next token is token "invalid token" () -syntax error -Cleanup: discarding lookahead token "invalid token" () -./calc.at:1479: $PREPARSER ./calc input -stderr: -./calc.at:1485: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -stdout: -./calc.at:1489: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1492: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS -input: -stderr: | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -186817,8 +185255,9 @@ | | 2^2^3 = 256 | (2^2)^3 = 64 +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: $PREPARSER ./calc input -./calc.at:1485: cat stderr +input: ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -186829,10 +185268,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + | 1 = 2 = 3 +stderr: +./calc.at:1486: $PREPARSER ./calc input +stderr: stderr: -input: - | (1 + # + 1) = 1111 -./calc.at:1485: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -187669,18 +186109,6 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: Starting parse Entering state 0 Reading a token @@ -187688,32 +186116,15 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token '+' () -Error: discarding token '+' () +Next token is token '*' () +Error: discarding token '*' () Reading a token -Next token is token number (1) -Error: discarding token number (1) +Next token is token '*' () +Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 @@ -187727,79 +186138,54 @@ -> $$ = nterm exp (1111) Entering state 8 Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token -Next token is token number (1111) -Shifting token number (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1111) +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 27 +Entering state 29 Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) - $2 = token '=' () + $2 = token '+' () $3 = nterm exp (1111) --> $$ = nterm exp (1111) +-> $$ = nterm exp (2222) Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1486: cat stderr -stderr: -Starting parse -Entering state 0 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token number (1) -Error: discarding token number (1) +Next token is token '*' () +Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 @@ -187811,32 +186197,20 @@ $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1111) -Shifting token number (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 +Entering state 29 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (1111) - $2 = token '=' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (2222) + $2 = token '+' () $3 = nterm exp (1111) --> $$ = nterm exp (1111) +-> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (1111) + $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -187850,7 +186224,39 @@ Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (2) +Shifting token "number" (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2) +-> $$ = nterm exp (2) +Entering state 27 +Reading a token +Next token is token '=' () +syntax error, unexpected '=' +Error: popping nterm exp (2) +Error: popping token '=' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '=' () +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./calc.at:1482: cat stderr Starting parse Entering state 0 Reading a token @@ -188687,8 +187093,38 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () +stderr: input: -./calc.at:1479: "$PERL" -pi -e 'use strict; +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (2) +Shifting token "number" (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2) +-> $$ = nterm exp (2) +Entering state 27 +Reading a token +Next token is token '=' () +syntax error, unexpected '=' +Error: popping nterm exp (2) +Error: popping token '=' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '=' () +./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -188698,13 +187134,37 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1482: cat stderr | 1 2 ./calc.at:1489: $PREPARSER ./calc input -input: +./calc.at:1482: $PREPARSER ./calc /dev/null stderr: - | (- *) + (1 2) = 1 -./calc.at:1485: "$PERL" -pi -e 'use strict; +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token "number" (2) +syntax error, unexpected number +Error: popping nterm exp (1) +Cleanup: discarding lookahead token "number" (2) +stderr: +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1485: cat stderr +Starting parse +Entering state 0 +Reading a token +Now at end of input. +syntax error +Cleanup: discarding lookahead token "end of input" () +./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -188714,6 +187174,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +input: Starting parse Entering state 0 Reading a token @@ -188729,115 +187190,117 @@ syntax error, unexpected number Error: popping nterm exp (1) Cleanup: discarding lookahead token "number" (2) -./calc.at:1486: $PREPARSER ./calc input -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 + !+ ++ +./calc.at:1485: $PREPARSER ./calc input stderr: -./calc.at:1479: cat stderr -./calc.at:1485: cat stderr +./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 9 -Reducing stack 0 by rule 15 (line 106): - $1 = token '-' () - $2 = token error () -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Now at end of input. +syntax error +Cleanup: discarding lookahead token "end of input" () +stderr: +Starting parse +Entering state 0 Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (2) +Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 Reading a token -Next token is token "number" (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token "number" (2) -Error: discarding token "number" (2) +Next token is token '*' () +Shifting token '*' () +Entering state 21 Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 30 Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) +Next token is token '+' () +Reducing stack 0 by rule 9 (line 105): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) + $3 = nterm exp (6) +-> $$ = nterm exp (7) Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 27 +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 14 +Reducing stack 0 by rule 17 (line 121): + $1 = token '!' () + $2 = token '+' () +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) +input: +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | + | +1 +./calc.at:1486: $PREPARSER ./calc input +./calc.at:1489: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1482: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +Starting parse +Entering state 0 Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) -Entering state 8 Next token is token '\n' () Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2222) - $2 = token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -188845,136 +187308,86 @@ -> $$ = nterm input () Entering state 6 Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () +Next token is token '+' () +syntax error, unexpected '+' +Error: popping nterm input () +Cleanup: discarding lookahead token '+' () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -stderr: - | 1 = 2 = 3 -stderr: -./calc.at:1482: $PREPARSER ./calc input +./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (1) +Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token -Next token is token "number" (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Cleanup: discarding lookahead token "number" (2) -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 9 -Reducing stack 0 by rule 15 (line 106): - $1 = token '-' () - $2 = token error () -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (2) +Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 Reading a token -Next token is token "number" (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token "number" (2) -Error: discarding token "number" (2) +Next token is token '*' () +Shifting token '*' () +Entering state 21 Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 30 Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) +Next token is token '+' () +Reducing stack 0 by rule 9 (line 105): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) + $3 = nterm exp (6) +-> $$ = nterm exp (7) Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 27 +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 14 +Reducing stack 0 by rule 17 (line 121): + $1 = token '!' () + $2 = token '+' () +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) +stderr: +Starting parse +Entering state 0 Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) -Entering state 8 Next token is token '\n' () Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2222) - $2 = token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -188982,19 +187395,87 @@ -> $$ = nterm input () Entering state 6 Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () +Next token is token '+' () +syntax error, unexpected '+' +Error: popping nterm input () +Cleanup: discarding lookahead token '+' () input: - | (1 + 1) / (1 - 1) -./calc.at:1485: $PREPARSER ./calc input +./calc.at:1482: cat stderr input: + | 1 + 2 * 3 + !- ++ +./calc.at:1485: $PREPARSER ./calc input +stderr: + | 1//2 +./calc.at:1489: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 30 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 9 (line 105): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 13 +Reducing stack 0 by rule 18 (line 122): + $1 = token '!' () + $2 = token '-' () +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) +Starting parse +Entering state 0 +Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 @@ -189003,163 +187484,99 @@ -> $$ = nterm exp (1) Entering state 8 Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token "number" (2) -Shifting token "number" (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2) --> $$ = nterm exp (2) -Entering state 27 +Next token is token '/' () +Shifting token '/' () +Entering state 22 Reading a token -Next token is token '=' () -syntax error -Error: popping nterm exp (2) -Error: popping token '=' () +Next token is token '/' () +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' () Error: popping nterm exp (1) -Cleanup: discarding lookahead token '=' () - | (#) + (#) = 2222 -./calc.at:1479: $PREPARSER ./calc input -./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Cleanup: discarding lookahead token '/' () +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1482: $PREPARSER ./calc input stderr: -syntax error: invalid character: '#' -syntax error: invalid character: '#' -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) -Entering state 12 +Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token number (2) +Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) + $1 = token number (2) +-> $$ = nterm exp (2) Entering state 29 Reading a token -Next token is token ')' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): - $1 = token '(' () - $2 = nterm exp (2) - $3 = token ')' () --> $$ = nterm exp (2) -Entering state 8 -Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 +Next token is token '*' () +Shifting token '*' () +Entering state 21 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token number (3) +Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 28 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 8 (line 104): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (1) --> $$ = nterm exp (0) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): - $1 = token '(' () - $2 = nterm exp (0) - $3 = token ')' () --> $$ = nterm exp (0) -Entering state 31 + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 30 Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 10 (line 106): +Next token is token '+' () +Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) - $2 = token '/' () - $3 = nterm exp (0) -error: null divisor --> $$ = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -syntax error: invalid character: '#' -syntax error: invalid character: '#' -stderr: -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 13 +Reducing stack 0 by rule 18 (line 122): + $1 = token '!' () + $2 = token '-' () +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) stderr: +./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token @@ -189171,24 +187588,15 @@ -> $$ = nterm exp (1) Entering state 8 Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token "number" (2) -Shifting token "number" (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2) --> $$ = nterm exp (2) -Entering state 27 +Next token is token '/' () +Shifting token '/' () +Entering state 22 Reading a token -Next token is token '=' () -syntax error -Error: popping nterm exp (2) -Error: popping token '=' () +Next token is token '/' () +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' () Error: popping nterm exp (1) -Cleanup: discarding lookahead token '=' () +Cleanup: discarding lookahead token '/' () Starting parse Entering state 0 Reading a token @@ -189196,173 +187604,58 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 -Reading a token Next token is token ')' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 +syntax error +Shifting token error () +Entering state 11 Next token is token ')' () Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): +Entering state 25 +Reducing stack 0 by rule 14 (line 105): $1 = token '(' () - $2 = nterm exp (2) + $2 = token error () $3 = token ')' () --> $$ = nterm exp (2) +-> $$ = nterm exp (1111) Entering state 8 Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1) +Shifting token "number" (1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 12 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1) +Shifting token "number" (1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) -> $$ = nterm exp (1) -Entering state 28 +Entering state 29 Reading a token -Next token is token ')' () -Reducing stack 0 by rule 8 (line 104): +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) - $2 = token '-' () + $2 = token '+' () $3 = nterm exp (1) --> $$ = nterm exp (0) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): - $1 = token '(' () - $2 = nterm exp (0) - $3 = token ')' () --> $$ = nterm exp (0) -Entering state 31 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 10 (line 106): - $1 = nterm exp (2) - $2 = token '/' () - $3 = nterm exp (0) -error: null divisor -> $$ = nterm exp (2) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1479: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1479: cat stderr -./calc.at:1489: cat stderr -./calc.at:1486: cat stderr -./calc.at:1482: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1485: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -input: - | (1 + #) = 1111 -input: -./calc.at:1479: $PREPARSER ./calc input -./calc.at:1485: cat stderr - | 1//2 -./calc.at:1489: $PREPARSER ./calc input - | (* *) + (*) + (*) -./calc.at:1486: $PREPARSER ./calc input -stderr: -stderr: -stderr: -syntax error: invalid character: '#' -Starting parse -Entering state 0 +Entering state 12 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token Next token is token "number" (1) Shifting token "number" (1) @@ -189370,37 +187663,24 @@ Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '/' () -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '/' () -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Entering state 29 Reading a token -Next token is token '*' () -Error: discarding token '*' () +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (2) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (3) +Entering state 12 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token Next token is token ')' () +syntax error +Error: popping token '+' () +Error: popping nterm exp (3) +Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () @@ -189410,9 +187690,16 @@ $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 8 +Entering state 29 Reading a token Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token @@ -189421,12 +187708,18 @@ Entering state 4 Reading a token Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () @@ -189441,10 +187734,10 @@ Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) + $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) --> $$ = nterm exp (2222) +-> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () @@ -189454,8 +187747,41 @@ Shifting token '(' () Entering state 4 Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token "number" (2) +Shifting token "number" (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2) +-> $$ = nterm exp (2) +Entering state 30 +Reading a token +Next token is token '*' () +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1) + $2 = token '*' () + $3 = nterm exp (2) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token '*' () +syntax error +Error: popping token '*' () +Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () @@ -189473,18 +187799,38 @@ -> $$ = nterm exp (1111) Entering state 29 Reading a token -Next token is token '\n' () +Next token is token '=' () Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (2222) + $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) --> $$ = nterm exp (3333) +-> $$ = nterm exp (4444) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (4444) + $2 = token '=' () + $3 = nterm exp (1) +error: 4444 != 1 +-> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (3333) + $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -189498,51 +187844,93 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -./calc.at:1482: cat stderr -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -558. calc.at:1485: ok -stderr: -stderr: +./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -syntax error: invalid character: '#' +./calc.at:1486: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token ')' () +syntax error +Shifting token error () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) -Entering state 8 +Entering state 12 Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token -Next token is token '/' () -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '/' () -Starting parse -Entering state 0 +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 29 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 29 Reading a token -Next token is token '*' () -Error: discarding token '*' () +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (2) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (3) +Entering state 12 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token Next token is token ')' () +syntax error +Error: popping token '+' () +Error: popping nterm exp (3) +Shifting token error () Entering state 11 Next token is token ')' () Shifting token ')' () @@ -189552,9 +187940,16 @@ $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 8 +Entering state 29 Reading a token Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token @@ -189563,12 +187958,18 @@ Entering state 4 Reading a token Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () @@ -189583,10 +187984,10 @@ Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) + $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) --> $$ = nterm exp (2222) +-> $$ = nterm exp (3333) Entering state 8 Next token is token '+' () Shifting token '+' () @@ -189596,8 +187997,41 @@ Shifting token '(' () Entering state 4 Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token "number" (2) +Shifting token "number" (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2) +-> $$ = nterm exp (2) +Entering state 30 +Reading a token +Next token is token '*' () +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1) + $2 = token '*' () + $3 = nterm exp (2) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token '*' () +syntax error +Error: popping token '*' () +Error: popping nterm exp (2) Shifting token error () Entering state 11 Next token is token '*' () @@ -189615,18 +188049,38 @@ -> $$ = nterm exp (1111) Entering state 29 Reading a token -Next token is token '\n' () +Next token is token '=' () Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (2222) + $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) --> $$ = nterm exp (3333) +-> $$ = nterm exp (4444) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (4444) + $2 = token '=' () + $3 = nterm exp (1) +error: 4444 != 1 +-> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (3333) + $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -189640,32 +188094,7 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -input: - - | - | +1 -./calc.at:1482: $PREPARSER ./calc input stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '+' () -syntax error -Error: popping nterm input () -Cleanup: discarding lookahead token '+' () -./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -189676,18 +188105,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1479: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1479: cat stderr -./calc.at:1486: "$PERL" -pi -e 'use strict; +./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -189697,36 +188115,16 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: Starting parse Entering state 0 Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '+' () -syntax error -Error: popping nterm input () -Cleanup: discarding lookahead token '+' () -568. calc.at:1492: testing Calculator glr2.cc %locations %header parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... -./calc.at:1492: mv calc.y.tmp calc.y - +Now at end of input. +syntax error, unexpected end of input +Cleanup: discarding lookahead token "end of input" () +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: cat stderr -input: -./calc.at:1492: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y - | (# + 1) = 1111 -./calc.at:1479: $PREPARSER ./calc input -./calc.at:1486: cat stderr stderr: +./calc.at:1485: cat stderr ./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -189737,85 +188135,20 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +Starting parse +Entering state 0 +Reading a token +Now at end of input. +syntax error, unexpected end of input +Cleanup: discarding lookahead token "end of input" () input: -syntax error: invalid character: '#' -input: -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | error ./calc.at:1489: $PREPARSER ./calc input - | 1 + 2 * 3 + !+ ++ -./calc.at:1486: $PREPARSER ./calc input -stderr: -stderr: +input: stderr: -syntax error: invalid character: '#' -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token "number" (2) -Shifting token "number" (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token "number" (3) -Shifting token "number" (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (3) --> $$ = nterm exp (3) -Entering state 30 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) -Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 14 -Reducing stack 0 by rule 17 (line 108): - $1 = token '!' () - $2 = token '+' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (#) + (#) = 2222 ./calc.at:1482: cat stderr +./calc.at:1485: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -189824,13 +188157,7 @@ Cleanup: discarding lookahead token "invalid token" () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "invalid token" () -syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" () -./calc.at:1479: "$PERL" -pi -e 'use strict; +./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -189840,292 +188167,251 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1482: $PREPARSER ./calc /dev/null -stderr: -stderr: Starting parse Entering state 0 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token -Next token is token "number" (2) -Shifting token "number" (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 +Next token is token '(' () +Shifting token '(' () +Entering state 4 Reading a token -Next token is token "number" (3) -Shifting token "number" (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (3) --> $$ = nterm exp (3) -Entering state 30 +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () Reading a token -Next token is token '+' () -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 29 -Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1111) $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Next token is token '=' () +Shifting token '=' () +Entering state 18 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 +Next token is token number (2222) +Shifting token number (2222) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2222) +-> $$ = nterm exp (2222) +Entering state 27 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 14 -Reducing stack 0 by rule 17 (line 108): - $1 = token '!' () - $2 = token '+' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) -./calc.at:1492: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS -./calc.at:1479: cat stderr -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (2222) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: Starting parse Entering state 0 Reading a token -Now at end of input. -syntax error -Cleanup: discarding lookahead token "end of input" () +Next token is token "invalid token" () +syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" () input: -./calc.at:1489: cat stderr -./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 + 2 * 3 + !- ++ -./calc.at:1486: $PREPARSER ./calc input +./calc.at:1486: cat stderr stderr: + | (!!) + (1 2) = 1 +./calc.at:1482: $PREPARSER ./calc input stderr: -input: - | 1 = 2 = 3 -input: Starting parse Entering state 0 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token "number" (2) -Shifting token "number" (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 +Next token is token '(' () +Shifting token '(' () +Entering state 4 Reading a token -Next token is token "number" (3) -Shifting token "number" (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (3) --> $$ = nterm exp (3) -Entering state 30 +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () Reading a token -Next token is token '+' () -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 8 +Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 +Next token is token '(' () +Shifting token '(' () +Entering state 4 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 13 -Reducing stack 0 by rule 18 (line 109): - $1 = token '!' () - $2 = token '-' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1489: $PREPARSER ./calc input -Starting parse -Entering state 0 +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () Reading a token -Now at end of input. -syntax error -Cleanup: discarding lookahead token "end of input" () -stderr: - | (1 + # + 1) = 1111 -Starting parse -Entering state 0 +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) +Next token is token '=' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) Entering state 8 -Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (2) -Shifting token "number" (2) +Next token is token number (2222) +Shifting token number (2222) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2) --> $$ = nterm exp (2) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2222) +-> $$ = nterm exp (2222) Entering state 27 Reading a token -Next token is token '=' () -syntax error, unexpected '=' -Error: popping nterm exp (2) -Error: popping token '=' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '=' () -./calc.at:1479: $PREPARSER ./calc input -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -syntax error: invalid character: '#' -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (2222) +-> $$ = nterm exp (2222) Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +Starting parse +Entering state 0 Reading a token -Next token is token "number" (2) -Shifting token "number" (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2) --> $$ = nterm exp (2) -Entering state 29 +Next token is token '(' () +Shifting token '(' () +Entering state 4 Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 +Next token is token '!' () +Shifting token '!' () +Entering state 5 Reading a token -Next token is token "number" (3) -Shifting token "number" (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (3) --> $$ = nterm exp (3) -Entering state 30 +Next token is token '!' () +Shifting token '!' () +Entering state 15 +Reducing stack 0 by rule 16 (line 107): + $1 = token '!' () + $2 = token '!' () +Shifting token error () +Entering state 11 Reading a token -Next token is token '+' () -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 8 +Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 13 -Reducing stack 0 by rule 18 (line 109): - $1 = token '!' () - $2 = token '-' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) -stderr: -stderr: -syntax error: invalid character: '#' -./calc.at:1482: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 +Next token is token '(' () +Shifting token '(' () +Entering state 4 Reading a token Next token is token "number" (1) Shifting token "number" (1) @@ -190133,37 +188419,78 @@ Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) -Entering state 8 +Entering state 12 +Reading a token +Next token is token "number" (2) +syntax error +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token "number" (2) +Error: discarding token "number" (2) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 Reading a token Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (2) -Shifting token "number" (2) +Next token is token "number" (1) +Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2) --> $$ = nterm exp (2) + $1 = token "number" (1) +-> $$ = nterm exp (1) Entering state 27 Reading a token -Next token is token '=' () -syntax error, unexpected '=' -Error: popping nterm exp (2) -Error: popping token '=' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '=' () -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1486: cat stderr +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (1) +error: 2222 != 1 +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1486: $PREPARSER ./calc input +stderr: ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -190174,30 +188501,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1482: cat stderr -./calc.at:1489: cat stderr -./calc.at:1479: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1482: $PREPARSER ./calc input - | (#) + (#) = 2222 -./calc.at:1479: cat stderr -./calc.at:1486: $PREPARSER ./calc input -input: -stderr: - | - | +1 -./calc.at:1489: $PREPARSER ./calc input stderr: Starting parse Entering state 0 @@ -190207,7 +188510,7 @@ Entering state 4 Reading a token Next token is token ')' () -syntax error +syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () @@ -190279,7 +188582,7 @@ Entering state 20 Reading a token Next token is token ')' () -syntax error +syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () @@ -190310,7 +188613,7 @@ Entering state 4 Reading a token Next token is token '*' () -syntax error +syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () @@ -190381,7 +188684,7 @@ Entering state 21 Reading a token Next token is token '*' () -syntax error +syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () @@ -190446,8 +188749,6 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: Starting parse Entering state 0 Reading a token @@ -190455,16 +188756,20 @@ Shifting token '(' () Entering state 4 Reading a token -syntax error: invalid character: '#' -Next token is token error () +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 15 +Reducing stack 0 by rule 16 (line 107): + $1 = token '!' () + $2 = token '!' () Shifting token error () Entering state 11 -Next token is token error () -Error: discarding token error () Reading a token Next token is token ')' () -Entering state 11 -Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): @@ -190482,12 +188787,21 @@ Shifting token '(' () Entering state 4 Reading a token -syntax error: invalid character: '#' -Next token is token error () +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token "number" (2) +syntax error +Error: popping nterm exp (1) Shifting token error () Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token "number" (2) +Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 @@ -190512,19 +188826,20 @@ Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (2222) -Shifting token "number" (2222) +Next token is token "number" (1) +Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2222) --> $$ = nterm exp (2222) + $1 = token "number" (1) +-> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () - $3 = nterm exp (2222) + $3 = nterm exp (1) +error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () @@ -190545,32 +188860,21 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '+' () -syntax error, unexpected '+' -Error: popping nterm input () -Cleanup: discarding lookahead token '+' () -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | (1 + 1) / (1 - 1) -stderr: -./calc.at:1479: $PREPARSER ./calc input +./calc.at:1485: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1489: cat stderr stderr: +./calc.at:1485: cat stderr +input: Starting parse Entering state 0 Reading a token @@ -190579,7 +188883,7 @@ Entering state 4 Reading a token Next token is token ')' () -syntax error +syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token ')' () @@ -190651,7 +188955,7 @@ Entering state 20 Reading a token Next token is token ')' () -syntax error +syntax error, unexpected ')', expecting number or '-' or '(' or '!' Error: popping token '+' () Error: popping nterm exp (3) Shifting token error () @@ -190682,7 +188986,7 @@ Entering state 4 Reading a token Next token is token '*' () -syntax error +syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () @@ -190753,7 +189057,7 @@ Entering state 21 Reading a token Next token is token '*' () -syntax error +syntax error, unexpected '*', expecting number or '-' or '(' or '!' Error: popping token '*' () Error: popping nterm exp (2) Shifting token error () @@ -190818,42 +189122,174 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -stdout: + | 1 = 2 = 3 +./calc.at:1489: $PREPARSER ./calc input +./calc.at:1482: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: stderr: -./calc.at:1485: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - + | (1 + #) = 1111 +./calc.at:1485: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (2) +Shifting token "number" (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2) +-> $$ = nterm exp (2) +Entering state 27 +Reading a token +Next token is token '=' () +syntax error, unexpected '=' +Error: popping nterm exp (2) +Error: popping token '=' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '=' () +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (1111) +Shifting token number (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 Next token is token '\n' () Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (1111) + $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 69): +Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token -Next token is token '+' () -syntax error, unexpected '+' -Error: popping nterm input () -Cleanup: discarding lookahead token '+' () +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (2) +Shifting token "number" (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2) +-> $$ = nterm exp (2) +Entering state 27 +Reading a token +Next token is token '=' () +syntax error, unexpected '=' +Error: popping nterm exp (2) +Error: popping token '=' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '=' () +./calc.at:1486: cat stderr +./calc.at:1482: cat stderr stderr: -error: null divisor -./calc.at:1479: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -190861,8 +189297,22 @@ Shifting token '(' () Entering state 4 Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token syntax error: invalid character: '#' Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () @@ -190873,6 +189323,90 @@ Next token is token ')' () Shifting token ')' () Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (1111) +Shifting token number (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +input: + | (!!) + (1 2) = 1 +./calc.at:1486: $PREPARSER ./calc input +input: +stderr: +./calc.at:1489: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (- *) + (1 2) = 1 +./calc.at:1482: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 15 +Reducing stack 0 by rule 16 (line 107): + $1 = token '!' () + $2 = token '!' () +Shifting token error () +Entering state 11 +Reading a token +Next token is token ')' () +Shifting token ')' () +Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () @@ -190888,12 +189422,21 @@ Shifting token '(' () Entering state 4 Reading a token -syntax error: invalid character: '#' -Next token is token error () +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token "number" (2) +syntax error, unexpected number +Error: popping nterm exp (1) Shifting token error () Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token "number" (2) +Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 @@ -190918,19 +189461,386 @@ Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (2222) -Shifting token "number" (2222) +Next token is token "number" (1) +Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2222) + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (1) +error: 2222 != 1 +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1489: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token '*' () +syntax error +Shifting token error () +Entering state 9 +Reducing stack 0 by rule 15 (line 106): + $1 = token '-' () + $2 = token error () +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token "number" (2) +syntax error +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token "number" (2) +Error: discarding token "number" (2) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) -> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () - $3 = nterm exp (2222) + $3 = nterm exp (1) +error: 2222 != 1 +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1485: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 15 +Reducing stack 0 by rule 16 (line 107): + $1 = token '!' () + $2 = token '!' () +Shifting token error () +Entering state 11 +Reading a token +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token "number" (2) +syntax error, unexpected number +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token "number" (2) +Error: discarding token "number" (2) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (1) +error: 2222 != 1 +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1485: cat stderr +input: +stderr: + | + | +1 +stderr: +./calc.at:1489: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token '*' () +syntax error +Shifting token error () +Entering state 9 +Reducing stack 0 by rule 15 (line 106): + $1 = token '-' () + $2 = token error () +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token "number" (2) +syntax error +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token "number" (2) +Error: discarding token "number" (2) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (1) +error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () @@ -190951,7 +189861,144 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () +stdout: +input: +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '+' () +syntax error, unexpected '+' +Error: popping nterm input () +Cleanup: discarding lookahead token '+' () +./calc.at:1485: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (# + 1) = 1111 +./calc.at:1485: $PREPARSER ./calc input +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '+' () +syntax error, unexpected '+' +Error: popping nterm input () +Cleanup: discarding lookahead token '+' () input: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token number (1) +Error: discarding token number (1) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (1111) +Shifting token number (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1486: cat stderr | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -190966,7 +190013,7 @@ | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1485: $PREPARSER ./calc input -./calc.at:1489: "$PERL" -pi -e 'use strict; +./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -190977,12 +190024,80 @@ }eg ' expout || exit 77 stderr: -./calc.at:1489: cat stderr -./calc.at:1489: $PREPARSER ./calc /dev/null stderr: Starting parse Entering state 0 Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token number (1) +Error: discarding token number (1) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (1111) +Shifting token number (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +input: +Starting parse +Entering state 0 +Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 @@ -191817,7 +190932,8 @@ Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1482: "$PERL" -pi -e 'use strict; + | (- *) + (1 2) = 1 +./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -191827,15 +190943,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1482: cat stderr +./calc.at:1486: $PREPARSER ./calc input stderr: -Starting parse -Entering state 0 -Reading a token -Now at end of input. -syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" () -error: null divisor -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 @@ -192673,73 +191783,133 @@ Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () -input: - | 1 2 -./calc.at:1485: $PREPARSER ./calc input -stderr: +./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 9 +Reducing stack 0 by rule 15 (line 106): + $1 = token '-' () + $2 = token error () +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) -> $$ = nterm exp (1) -Entering state 8 +Entering state 12 Reading a token -Next token is token number (2) +Next token is token "number" (2) syntax error, unexpected number Error: popping nterm exp (1) -Cleanup: discarding lookahead token number (2) -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -stderr: -Starting parse -Entering state 0 +Shifting token error () +Entering state 11 +Next token is token "number" (2) +Error: discarding token "number" (2) Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) -> $$ = nterm exp (1) -Entering state 8 +Entering state 27 Reading a token -Next token is token number (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Cleanup: discarding lookahead token number (2) -Starting parse -Entering state 0 +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (1) +error: 2222 != 1 +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 Reading a token Now at end of input. -syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" () -./calc.at:1482: cat stderr -./calc.at:1486: cat stderr -./calc.at:1485: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -./calc.at:1479: "$PERL" -pi -e 'use strict; + | 1 2 +./calc.at:1485: $PREPARSER ./calc input +./calc.at:1489: $PREPARSER ./calc /dev/null +input: + | (* *) + (*) + (*) +stderr: +./calc.at:1482: $PREPARSER ./calc input +./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -192749,14 +191919,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: - | (1 + #) = 1111 -./calc.at:1485: cat stderr - | (!!) + (1 2) = 1 -./calc.at:1486: $PREPARSER ./calc input -./calc.at:1482: $PREPARSER ./calc input -stderr: -./calc.at:1479: cat stderr stderr: Starting parse Entering state 0 @@ -192765,20 +191927,25 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 +Next token is token '-' () +Shifting token '-' () +Entering state 2 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 15 -Reducing stack 0 by rule 16 (line 107): - $1 = token '!' () - $2 = token '!' () +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 9 +Reducing stack 0 by rule 15 (line 106): + $1 = token '-' () + $2 = token error () Shifting token error () Entering state 11 +Next token is token '*' () +Error: discarding token '*' () Reading a token Next token is token ')' () +Entering state 11 +Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): @@ -192805,7 +191972,7 @@ Entering state 12 Reading a token Next token is token "number" (2) -syntax error +syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 @@ -192869,7 +192036,32 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +Starting parse +Entering state 0 +Reading a token +Now at end of input. +syntax error, unexpected end of input +Cleanup: discarding lookahead token "end of input" () +stderr: +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token number (2) +syntax error, unexpected number +Error: popping nterm exp (1) +Cleanup: discarding lookahead token number (2) +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token @@ -192877,26 +192069,42 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 +Next token is token '*' () +syntax error +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error Shifting token error () Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token '*' () +Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 @@ -192908,32 +192116,54 @@ $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 +Next token is token '(' () +Shifting token '(' () +Entering state 4 Reading a token -Next token is token "number" (1111) -Shifting token "number" (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1111) +Next token is token '*' () +syntax error +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 27 +Entering state 29 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (2222) + $2 = token '+' () $3 = nterm exp (1111) --> $$ = nterm exp (1111) +-> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) + $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -192947,23 +192177,15 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: +./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -553. calc.at:1479: | 1//2 - ok -./calc.at:1485: $PREPARSER ./calc input stderr: +Starting parse +Entering state 0 +Reading a token +Now at end of input. +syntax error, unexpected end of input +Cleanup: discarding lookahead token "end of input" () stderr: Starting parse Entering state 0 @@ -192976,16 +192198,11 @@ -> $$ = nterm exp (1) Entering state 8 Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '/' () -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' () +Next token is token number (2) +syntax error, unexpected number Error: popping nterm exp (1) -Cleanup: discarding lookahead token '/' () -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Cleanup: discarding lookahead token number (2) +input: Starting parse Entering state 0 Reading a token @@ -192993,20 +192210,19 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 15 -Reducing stack 0 by rule 16 (line 107): - $1 = token '!' () - $2 = token '!' () +Next token is token '*' () +syntax error Shifting token error () Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token '*' () +Error: discarding token '*' () Reading a token Next token is token ')' () +Entering state 11 +Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): @@ -193024,21 +192240,12 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token "number" (2) +Next token is token '*' () syntax error -Error: popping nterm exp (1) Shifting token error () Entering state 11 -Next token is token "number" (2) -Error: discarding token "number" (2) +Next token is token '*' () +Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 @@ -193052,38 +192259,52 @@ -> $$ = nterm exp (1111) Entering state 29 Reading a token -Next token is token '=' () +Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 27 +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2222) + $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -193097,6 +192318,19 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () + | (1 + # + 1) = 1111 +./calc.at:1485: $PREPARSER ./calc input +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: Starting parse Entering state 0 Reading a token @@ -193104,11 +192338,11 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (1) +Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token @@ -193125,12 +192359,18 @@ Next token is token error () Error: discarding token error () Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token number (1) +Error: discarding token number (1) +Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () @@ -193141,16 +192381,16 @@ Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (1111) -Shifting token "number" (1111) +Next token is token number (1111) +Shifting token number (1111) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1111) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) @@ -193159,44 +192399,129 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 69): +Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" () +Shifting token end of file () Entering state 16 -Cleanup: popping token "end of input" () +Cleanup: popping token end of file () Cleanup: popping nterm input () -./calc.at:1489: cat stderr +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1486: cat stderr +./calc.at:1485: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: +./calc.at:1489: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: Starting parse Entering state 0 Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) -Entering state 8 +Entering state 12 Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token -Next token is token '/' () -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' () +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () Error: popping nterm exp (1) -Cleanup: discarding lookahead token '/' () -./calc.at:1485: "$PERL" -pi -e 'use strict; +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token number (1) +Error: discarding token number (1) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (1111) +Shifting token number (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -193206,23 +192531,42 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 + | (* *) + (*) + (*) +./calc.at:1486: $PREPARSER ./calc input ./calc.at:1485: cat stderr +./calc.at:1489: cat stderr input: -./calc.at:1482: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 + | 1//2 +./calc.at:1485: $PREPARSER ./calc input +./calc.at:1482: cat stderr +stderr: +input: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '/' () +Shifting token '/' () +Entering state 22 +Reading a token +Next token is token '/' () +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '/' () | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: $PREPARSER ./calc input -input: - -./calc.at:1486: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -193232,11 +192576,121 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: - | error -./calc.at:1486: cat stderr -./calc.at:1485: $PREPARSER ./calc input -./calc.at:1482: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (2222) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (3333) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (3333) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token @@ -193484,18 +192938,31 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -stderr: +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: - | (- *) + (1 2) = 1 -./calc.at:1482: $PREPARSER ./calc input +stderr: stderr: Starting parse Entering state 0 Reading a token -Next token is token invalid token () -syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token () +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '/' () +Shifting token '/' () +Entering state 22 +Reading a token +Next token is token '/' () +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '/' () Starting parse Entering state 0 Reading a token @@ -193503,22 +192970,16 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token Next token is token '*' () -syntax error -Shifting token error () -Entering state 9 -Reducing stack 0 by rule 15 (line 106): - $1 = token '-' () - $2 = token error () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () @@ -193539,21 +193000,12 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token "number" (2) -syntax error -Error: popping nterm exp (1) +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 -Next token is token "number" (2) -Error: discarding token "number" (2) +Next token is token '*' () +Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 @@ -193567,38 +193019,52 @@ -> $$ = nterm exp (1111) Entering state 29 Reading a token -Next token is token '=' () +Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 27 +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2222) + $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -193612,11 +193078,20 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -stderr: +./calc.at:1485: cat stderr + | 1 + 2 * 3 + !+ ++ stderr: +./calc.at:1482: $PREPARSER ./calc input +./calc.at:1485: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -193864,132 +193339,296 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () - | (# + 1) = 1111 -./calc.at:1486: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token "number" (2) +Shifting token "number" (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token "number" (3) +Shifting token "number" (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (3) +-> $$ = nterm exp (3) +Entering state 30 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 14 +Reducing stack 0 by rule 17 (line 108): + $1 = token '!' () + $2 = token '+' () +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) +./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | (1 + 1) / (1 - 1) +./calc.at:1485: $PREPARSER ./calc input +stderr: +./calc.at:1485: cat stderr +input: + | error +stderr: +./calc.at:1485: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 Reading a token -Next token is token '*' () -syntax error -Shifting token error () -Entering state 9 -Reducing stack 0 by rule 15 (line 106): - $1 = token '-' () - $2 = token error () -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 Reading a token Next token is token ')' () -Entering state 11 +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 Next token is token ')' () Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Entering state 26 +Reducing stack 0 by rule 13 (line 117): $1 = token '(' () - $2 = token error () + $2 = nterm exp (2) $3 = token ')' () --> $$ = nterm exp (1111) +-> $$ = nterm exp (2) Entering state 8 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Next token is token '/' () +Shifting token '/' () +Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (1) +Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token -Next token is token "number" (2) -syntax error -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token "number" (2) -Error: discarding token "number" (2) +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 28 Reading a token Next token is token ')' () -Entering state 11 +Reducing stack 0 by rule 8 (line 104): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (1) +-> $$ = nterm exp (0) +Entering state 12 Next token is token ')' () Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Entering state 26 +Reducing stack 0 by rule 13 (line 117): $1 = token '(' () - $2 = token error () + $2 = nterm exp (0) $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 27 +-> $$ = nterm exp (0) +Entering state 31 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) +Reducing stack 0 by rule 10 (line 106): + $1 = nterm exp (2) + $2 = token '/' () + $3 = nterm exp (0) +error: null divisor +-> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2222) +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 69): +Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" () +Shifting token end of file () Entering state 16 -Cleanup: popping token "end of input" () +Cleanup: popping token end of file () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token "number" (2) +Shifting token "number" (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token "number" (3) +Shifting token "number" (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (3) +-> $$ = nterm exp (3) +Entering state 30 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 14 +Reducing stack 0 by rule 17 (line 108): + $1 = token '!' () + $2 = token '+' () +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +input: +./calc.at:1489: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Reading a token Next token is token invalid token () syntax error, unexpected invalid token Cleanup: discarding lookahead token invalid token () + | 1 + 2 * 3 + !- ++ +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1482: $PREPARSER ./calc input stderr: +./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token @@ -193997,70 +193636,272 @@ Shifting token '(' () Entering state 4 Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 Reading a token Next token is token '+' () -Error: discarding token '+' () +Shifting token '+' () +Entering state 20 Reading a token -Next token is token "number" (1) -Error: discarding token "number" (1) +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 Reading a token Next token is token ')' () -Entering state 11 +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 Next token is token ')' () Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Entering state 26 +Reducing stack 0 by rule 13 (line 117): $1 = token '(' () - $2 = token error () + $2 = nterm exp (2) $3 = token ')' () --> $$ = nterm exp (1111) +-> $$ = nterm exp (2) Entering state 8 Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 +Next token is token '/' () +Shifting token '/' () +Entering state 22 Reading a token -Next token is token "number" (1111) -Shifting token "number" (1111) +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (1) +Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1111) --> $$ = nterm exp (1111) -Entering state 27 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 28 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 8 (line 104): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (1) +-> $$ = nterm exp (0) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 117): + $1 = token '(' () + $2 = nterm exp (0) + $3 = token ')' () +-> $$ = nterm exp (0) +Entering state 31 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) +Reducing stack 0 by rule 10 (line 106): + $1 = nterm exp (2) + $2 = token '/' () + $3 = nterm exp (0) +error: null divisor +-> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 69): +Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" () +Shifting token end of file () Entering state 16 -Cleanup: popping token "end of input" () +Cleanup: popping token end of file () Cleanup: popping nterm input () -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./calc.at:1486: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token "number" (2) +Shifting token "number" (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token "number" (3) +Shifting token "number" (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (3) +-> $$ = nterm exp (3) +Entering state 30 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 13 +Reducing stack 0 by rule 18 (line 109): + $1 = token '!' () + $2 = token '-' () +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) +./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token invalid token () +syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token () +input: +stderr: + | (!!) + (1 2) = 1 +input: +./calc.at:1489: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token "number" (2) +Shifting token "number" (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token "number" (3) +Shifting token "number" (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (3) +-> $$ = nterm exp (3) +Entering state 30 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 13 +Reducing stack 0 by rule 18 (line 109): + $1 = token '!' () + $2 = token '-' () +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) + | 1 + 2 * 3 + !+ ++ +./calc.at:1486: $PREPARSER ./calc input +./calc.at:1485: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -194068,18 +193909,52 @@ Shifting token '(' () Entering state 4 Reading a token -syntax error: invalid character: '#' -Next token is token error () +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 15 +Reducing stack 0 by rule 16 (line 107): + $1 = token '!' () + $2 = token '!' () Shifting token error () Entering state 11 -Next token is token error () -Error: discarding token error () +Reading a token +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 Reading a token Next token is token '+' () -Error: discarding token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 Reading a token Next token is token "number" (1) -Error: discarding token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token "number" (2) +syntax error, unexpected number +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token "number" (2) +Error: discarding token "number" (2) Reading a token Next token is token ')' () Entering state 11 @@ -194091,32 +193966,40 @@ $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 8 +Entering state 29 Reading a token Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (1111) -Shifting token "number" (1111) +Next token is token "number" (1) +Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1111) --> $$ = nterm exp (1111) + $1 = token "number" (1) +-> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) + $1 = nterm exp (2222) $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) + $3 = nterm exp (1) +error: 2222 != 1 +-> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) + $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -194130,101 +194013,16 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -569. calc.at:1494: testing Calculator C++ %glr-parser %no-lines %locations %header parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... -./calc.at:1494: mv calc.y.tmp calc.y - -./calc.at:1482: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1485: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1494: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y -stdout: -./calc.at:1485: cat stderr -./calc.at:1486: cat stderr -./calc.at:1489: cat stderr -./calc.at:1486: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - -input: -input: -input: -input: -./calc.at:1482: cat stderr - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1486: $PREPARSER ./calc input - | (1 + # + 1) = 1111 - | 1 = 2 = 3 -./calc.at:1485: $PREPARSER ./calc input -./calc.at:1486: $PREPARSER ./calc input - | (!!) + (1 2) = 1 -./calc.at:1489: $PREPARSER ./calc input -stderr: +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1) +Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) + $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token @@ -194232,11 +194030,11 @@ Shifting token '+' () Entering state 20 Reading a token -Next token is token number (2) -Shifting token number (2) +Next token is token "number" (2) +Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (2) + $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token @@ -194244,52 +194042,155 @@ Shifting token '*' () Entering state 21 Reading a token -Next token is token number (3) -Shifting token number (3) +Next token is token "number" (3) +Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (3) + $1 = token "number" (3) -> $$ = nterm exp (3) Entering state 30 Reading a token -Next token is token '=' () +Next token is token '+' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 -Next token is token '=' () +Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 14 +Reducing stack 0 by rule 17 (line 108): + $1 = token '!' () + $2 = token '+' () +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) +./calc.at:1485: cat stderr +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1485: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 15 +Reducing stack 0 by rule 16 (line 107): + $1 = token '!' () + $2 = token '!' () +Shifting token error () +Entering state 11 +Reading a token +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token "number" (2) +syntax error, unexpected number +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token "number" (2) +Error: discarding token "number" (2) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token number (7) -Shifting token number (7) +Next token is token "number" (1) +Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (7) --> $$ = nterm exp (7) + $1 = token "number" (1) +-> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (7) + $1 = nterm exp (2222) $2 = token '=' () - $3 = nterm exp (7) --> $$ = nterm exp (7) + $3 = nterm exp (1) +error: 2222 != 1 +-> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (7) + $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -194298,11 +194199,32 @@ -> $$ = nterm input () Entering state 6 Reading a token -Next token is token number (1) -Shifting token number (1) +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +558. calc.at:1485: ok +stderr: +./calc.at:1482: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1485: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) + $1 = token "number" (1) -> $$ = nterm exp (1) Entering state 8 Reading a token @@ -194310,11 +194232,11 @@ Shifting token '+' () Entering state 20 Reading a token -Next token is token number (2) -Shifting token number (2) +Next token is token "number" (2) +Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (2) + $1 = token "number" (2) -> $$ = nterm exp (2) Entering state 29 Reading a token @@ -194322,33 +194244,1274 @@ Shifting token '*' () Entering state 21 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (3) -Shifting token number (3) +Next token is token "number" (3) +Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (3) + $1 = token "number" (3) -> $$ = nterm exp (3) -Entering state 10 +Entering state 30 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 14 +Reducing stack 0 by rule 17 (line 108): + $1 = token '!' () + $2 = token '+' () +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) +input: + | 1 + 2 * 3 + !- ++ +./calc.at:1486: $PREPARSER ./calc input +./calc.at:1482: cat stderr +input: + +stderr: +./calc.at:1489: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | 1 = 2 = 3 +./calc.at:1485: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token "number" (2) +Shifting token "number" (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token "number" (3) +Shifting token "number" (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (3) +-> $$ = nterm exp (3) +Entering state 30 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 13 +Reducing stack 0 by rule 18 (line 109): + $1 = token '!' () + $2 = token '-' () +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +input: +./calc.at:1489: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 Reading a token Next token is token '=' () -Reducing stack 0 by rule 11 (line 102): +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 27 +Reading a token +Next token is token '=' () +syntax error, unexpected '=' +Error: popping nterm exp (2) +Error: popping token '=' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '=' () +stderr: +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token "number" (2) +Shifting token "number" (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token "number" (3) +Shifting token "number" (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (3) +-> $$ = nterm exp (3) +Entering state 30 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 13 +Reducing stack 0 by rule 18 (line 109): + $1 = token '!' () + $2 = token '-' () +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) + | (#) + (#) = 2222 +./calc.at:1482: $PREPARSER ./calc input +input: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 27 +Reading a token +Next token is token '=' () +syntax error, unexpected '=' +Error: popping nterm exp (2) +Error: popping token '=' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '=' () +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (2222) +Shifting token "number" (2222) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2222) +-> $$ = nterm exp (2222) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (2222) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () + | (- *) + (1 2) = 1 +./calc.at:1489: $PREPARSER ./calc input +./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +569. calc.at:1494: testing Calculator C++ %glr-parser %no-lines %locations %header parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 9 +Reducing stack 0 by rule 15 (line 106): + $1 = token '-' () + $2 = token error () +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token "number" (2) +syntax error, unexpected number +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token "number" (2) +Error: discarding token "number" (2) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (1) +error: 2222 != 1 +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1494: mv calc.y.tmp calc.y + +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (2222) +Shifting token "number" (2222) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2222) +-> $$ = nterm exp (2222) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (2222) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1486: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 9 +Reducing stack 0 by rule 15 (line 106): + $1 = token '-' () + $2 = token error () +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token "number" (2) +syntax error, unexpected number +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token "number" (2) +Error: discarding token "number" (2) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (1) +error: 2222 != 1 +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1494: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y +./calc.at:1485: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +./calc.at:1485: cat stderr + | (#) + (#) = 2222 +./calc.at:1486: $PREPARSER ./calc input +./calc.at:1489: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1482: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (2222) +Shifting token "number" (2222) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2222) +-> $$ = nterm exp (2222) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (2222) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1489: cat stderr +stderr: + | + | +1 +./calc.at:1485: $PREPARSER ./calc input +stdout: +stderr: +input: +stderr: +./calc.at:1487: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + + | (* *) + (*) + (*) +./calc.at:1489: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (2222) +Shifting token "number" (2222) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2222) +-> $$ = nterm exp (2222) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (2222) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1482: cat stderr +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 87): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '+' () +syntax error, unexpected '+' +Error: popping nterm input () +Cleanup: discarding lookahead token '+' () +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (2222) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (3333) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (3333) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1494: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS +stderr: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1487: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 87): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '+' () +syntax error, unexpected '+' +Error: popping nterm input () +Cleanup: discarding lookahead token '+' () +input: +stderr: + | (1 + #) = 1111 +./calc.at:1482: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 30 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 9 (line 105): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '=' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (7) +Shifting token number (7) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (7) +-> $$ = nterm exp (7) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (7) + $2 = token '=' () + $3 = nterm exp (7) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (7) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 10 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () -Reducing stack 0 by rule 9 (line 92): +Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): +Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) @@ -194365,19 +195528,19 @@ Next token is token number (5) Shifting token number (5) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 11 (line 102): +Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) @@ -194386,12 +195549,12 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -194400,11 +195563,11 @@ Next token is token '\n' () Shifting token '\n' () Entering state 3 -Reducing stack 0 by rule 3 (line 74): +Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -194417,7 +195580,7 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 @@ -194429,20 +195592,20 @@ Next token is token number (2) Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () -Reducing stack 0 by rule 12 (line 103): +Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () -Reducing stack 0 by rule 11 (line 102): +Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) @@ -194458,19 +195621,19 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 11 (line 102): +Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) @@ -194479,12 +195642,12 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -194501,13 +195664,13 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () -Reducing stack 0 by rule 11 (line 102): +Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) @@ -194515,7 +195678,7 @@ Next token is token ')' () Shifting token ')' () Entering state 26 -Reducing stack 0 by rule 13 (line 104): +Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () @@ -194529,13 +195692,13 @@ Next token is token number (2) Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () -Reducing stack 0 by rule 12 (line 103): +Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) @@ -194548,13 +195711,13 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) @@ -194563,12 +195726,12 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -194577,11 +195740,11 @@ Next token is token '\n' () Shifting token '\n' () Entering state 3 -Reducing stack 0 by rule 3 (line 74): +Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -194602,25 +195765,25 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () -Reducing stack 0 by rule 11 (line 102): +Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () -Reducing stack 0 by rule 11 (line 102): +Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () -Reducing stack 0 by rule 11 (line 102): +Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) @@ -194636,19 +195799,19 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 11 (line 102): +Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) @@ -194657,12 +195820,12 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -194671,11 +195834,11 @@ Next token is token '\n' () Shifting token '\n' () Entering state 3 -Reducing stack 0 by rule 3 (line 74): +Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -194684,7 +195847,7 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 @@ -194696,13 +195859,13 @@ Next token is token number (2) Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () -Reducing stack 0 by rule 8 (line 91): +Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) @@ -194715,13 +195878,13 @@ Next token is token number (3) Shifting token number (3) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () -Reducing stack 0 by rule 8 (line 91): +Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) @@ -194738,19 +195901,19 @@ Next token is token number (4) Shifting token number (4) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 11 (line 102): +Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) @@ -194759,12 +195922,12 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -194773,7 +195936,7 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 @@ -194789,7 +195952,7 @@ Next token is token number (2) Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 @@ -194801,13 +195964,13 @@ Next token is token number (3) Shifting token number (3) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () -Reducing stack 0 by rule 8 (line 91): +Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) @@ -194816,7 +195979,7 @@ Next token is token ')' () Shifting token ')' () Entering state 26 -Reducing stack 0 by rule 13 (line 104): +Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () @@ -194824,7 +195987,7 @@ Entering state 28 Reading a token Next token is token '=' () -Reducing stack 0 by rule 8 (line 91): +Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) @@ -194837,13 +196000,13 @@ Next token is token number (2) Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) @@ -194852,12 +196015,12 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -194866,11 +196029,11 @@ Next token is token '\n' () Shifting token '\n' () Entering state 3 -Reducing stack 0 by rule 3 (line 74): +Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -194879,7 +196042,7 @@ Next token is token number (2) Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 @@ -194891,7 +196054,7 @@ Next token is token number (2) Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 @@ -194903,20 +196066,20 @@ Next token is token number (3) Shifting token number (3) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () -Reducing stack 0 by rule 12 (line 103): +Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () -Reducing stack 0 by rule 12 (line 103): +Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) @@ -194929,13 +196092,13 @@ Next token is token number (256) Shifting token number (256) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) @@ -194944,12 +196107,12 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -194962,7 +196125,7 @@ Next token is token number (2) Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 @@ -194974,13 +196137,13 @@ Next token is token number (2) Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () -Reducing stack 0 by rule 12 (line 103): +Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) @@ -194989,7 +196152,7 @@ Next token is token ')' () Shifting token ')' () Entering state 26 -Reducing stack 0 by rule 13 (line 104): +Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () @@ -195003,13 +196166,13 @@ Next token is token number (3) Shifting token number (3) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () -Reducing stack 0 by rule 12 (line 103): +Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) @@ -195022,13 +196185,13 @@ Next token is token number (64) Shifting token number (64) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) @@ -195037,55 +196200,23 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token end of input () +Shifting token end of file () Entering state 16 -Cleanup: popping token end of input () +Cleanup: popping token end of file () Cleanup: popping nterm input () -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 27 -Reading a token -Next token is token '=' () -syntax error, unexpected '=' -Error: popping nterm exp (2) -Error: popping token '=' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '=' () -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 @@ -195094,20 +196225,19 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 15 -Reducing stack 0 by rule 16 (line 107): - $1 = token '!' () - $2 = token '!' () +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token '*' () +Error: discarding token '*' () Reading a token Next token is token ')' () +Entering state 11 +Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): @@ -195125,21 +196255,12 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token "number" (2) -syntax error, unexpected number -Error: popping nterm exp (1) +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 -Next token is token "number" (2) -Error: discarding token "number" (2) +Next token is token '*' () +Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 @@ -195153,38 +196274,52 @@ -> $$ = nterm exp (1111) Entering state 29 Reading a token -Next token is token '=' () +Next token is token '+' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 27 +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2222) + $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -195226,12 +196361,6 @@ Next token is token error () Error: discarding token error () Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token "number" (1) -Error: discarding token "number" (1) -Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () @@ -195281,16 +196410,25 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -input: -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 @@ -195302,7 +196440,7 @@ Next token is token number (2) Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 @@ -195314,20 +196452,20 @@ Next token is token number (3) Shifting token number (3) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token Next token is token '=' () -Reducing stack 0 by rule 9 (line 92): +Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): +Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) @@ -195340,13 +196478,13 @@ Next token is token number (7) Shifting token number (7) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (7) -> $$ = nterm exp (7) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (7) $2 = token '=' () $3 = nterm exp (7) @@ -195355,12 +196493,12 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (7) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 69): +Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 @@ -195368,7 +196506,7 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 @@ -195380,7 +196518,7 @@ Next token is token number (2) Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 @@ -195396,26 +196534,26 @@ Next token is token number (3) Shifting token number (3) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 10 Reading a token Next token is token '=' () -Reducing stack 0 by rule 11 (line 102): +Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (3) -> $$ = nterm exp (-3) Entering state 30 Next token is token '=' () -Reducing stack 0 by rule 9 (line 92): +Reducing stack 0 by rule 9 (line 105): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (-3) -> $$ = nterm exp (-6) Entering state 29 Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): +Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (-6) @@ -195432,19 +196570,19 @@ Next token is token number (5) Shifting token number (5) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (5) -> $$ = nterm exp (5) Entering state 10 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 11 (line 102): +Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (5) -> $$ = nterm exp (-5) Entering state 27 Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-5) $2 = token '=' () $3 = nterm exp (-5) @@ -195453,12 +196591,12 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-5) $2 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -195467,11 +196605,11 @@ Next token is token '\n' () Shifting token '\n' () Entering state 3 -Reducing stack 0 by rule 3 (line 74): +Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -195484,7 +196622,7 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 @@ -195496,20 +196634,20 @@ Next token is token number (2) Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () -Reducing stack 0 by rule 12 (line 103): +Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (1) $2 = token '^' () $3 = nterm exp (2) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () -Reducing stack 0 by rule 11 (line 102): +Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) @@ -195525,19 +196663,19 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 11 (line 102): +Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) @@ -195546,12 +196684,12 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -195568,13 +196706,13 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token ')' () -Reducing stack 0 by rule 11 (line 102): +Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) @@ -195582,7 +196720,7 @@ Next token is token ')' () Shifting token ')' () Entering state 26 -Reducing stack 0 by rule 13 (line 104): +Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () @@ -195596,13 +196734,13 @@ Next token is token number (2) Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token '=' () -Reducing stack 0 by rule 12 (line 103): +Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (-1) $2 = token '^' () $3 = nterm exp (2) @@ -195615,13 +196753,13 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1) $2 = token '=' () $3 = nterm exp (1) @@ -195630,12 +196768,12 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -195644,11 +196782,11 @@ Next token is token '\n' () Shifting token '\n' () Entering state 3 -Reducing stack 0 by rule 3 (line 74): +Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -195669,25 +196807,25 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '=' () -Reducing stack 0 by rule 11 (line 102): +Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 10 Next token is token '=' () -Reducing stack 0 by rule 11 (line 102): +Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (-1) -> $$ = nterm exp (1) Entering state 10 Next token is token '=' () -Reducing stack 0 by rule 11 (line 102): +Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) @@ -195703,19 +196841,19 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 10 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 11 (line 102): +Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (1) -> $$ = nterm exp (-1) Entering state 27 Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-1) $2 = token '=' () $3 = nterm exp (-1) @@ -195724,12 +196862,12 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -195738,11 +196876,11 @@ Next token is token '\n' () Shifting token '\n' () Entering state 3 -Reducing stack 0 by rule 3 (line 74): +Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -195751,7 +196889,7 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 @@ -195763,13 +196901,13 @@ Next token is token number (2) Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 28 Reading a token Next token is token '-' () -Reducing stack 0 by rule 8 (line 91): +Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (2) @@ -195782,13 +196920,13 @@ Next token is token number (3) Shifting token number (3) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token '=' () -Reducing stack 0 by rule 8 (line 91): +Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (-1) $2 = token '-' () $3 = nterm exp (3) @@ -195805,19 +196943,19 @@ Next token is token number (4) Shifting token number (4) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (4) -> $$ = nterm exp (4) Entering state 10 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 11 (line 102): +Reducing stack 0 by rule 11 (line 115): $1 = token '-' () $2 = nterm exp (4) -> $$ = nterm exp (-4) Entering state 27 Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (-4) $2 = token '=' () $3 = nterm exp (-4) @@ -195826,12 +196964,12 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (-4) $2 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -195840,7 +196978,7 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 @@ -195856,7 +196994,7 @@ Next token is token number (2) Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 @@ -195868,13 +197006,13 @@ Next token is token number (3) Shifting token number (3) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 28 Reading a token Next token is token ')' () -Reducing stack 0 by rule 8 (line 91): +Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (2) $2 = token '-' () $3 = nterm exp (3) @@ -195883,7 +197021,7 @@ Next token is token ')' () Shifting token ')' () Entering state 26 -Reducing stack 0 by rule 13 (line 104): +Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (-1) $3 = token ')' () @@ -195891,7 +197029,7 @@ Entering state 28 Reading a token Next token is token '=' () -Reducing stack 0 by rule 8 (line 91): +Reducing stack 0 by rule 8 (line 104): $1 = nterm exp (1) $2 = token '-' () $3 = nterm exp (-1) @@ -195904,13 +197042,13 @@ Next token is token number (2) Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2) $2 = token '=' () $3 = nterm exp (2) @@ -195919,12 +197057,12 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -195933,11 +197071,11 @@ Next token is token '\n' () Shifting token '\n' () Entering state 3 -Reducing stack 0 by rule 3 (line 74): +Reducing stack 0 by rule 3 (line 87): $1 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -195946,7 +197084,7 @@ Next token is token number (2) Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 8 @@ -195958,7 +197096,7 @@ Next token is token number (2) Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 @@ -195970,20 +197108,20 @@ Next token is token number (3) Shifting token number (3) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () -Reducing stack 0 by rule 12 (line 103): +Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (3) -> $$ = nterm exp (8) Entering state 32 Next token is token '=' () -Reducing stack 0 by rule 12 (line 103): +Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (8) @@ -195996,13 +197134,13 @@ Next token is token number (256) Shifting token number (256) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (256) -> $$ = nterm exp (256) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (256) $2 = token '=' () $3 = nterm exp (256) @@ -196011,12 +197149,12 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (256) $2 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () @@ -196029,7 +197167,7 @@ Next token is token number (2) Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 @@ -196041,13 +197179,13 @@ Next token is token number (2) Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) Entering state 32 Reading a token Next token is token ')' () -Reducing stack 0 by rule 12 (line 103): +Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (2) $2 = token '^' () $3 = nterm exp (2) @@ -196056,7 +197194,7 @@ Next token is token ')' () Shifting token ')' () Entering state 26 -Reducing stack 0 by rule 13 (line 104): +Reducing stack 0 by rule 13 (line 117): $1 = token '(' () $2 = nterm exp (4) $3 = token ')' () @@ -196070,13 +197208,13 @@ Next token is token number (3) Shifting token number (3) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (3) -> $$ = nterm exp (3) Entering state 32 Reading a token Next token is token '=' () -Reducing stack 0 by rule 12 (line 103): +Reducing stack 0 by rule 12 (line 116): $1 = nterm exp (4) $2 = token '^' () $3 = nterm exp (3) @@ -196089,13 +197227,13 @@ Next token is token number (64) Shifting token number (64) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (64) -> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (64) $2 = token '=' () $3 = nterm exp (64) @@ -196104,141 +197242,25 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () Entering state 17 -Reducing stack 0 by rule 2 (line 70): +Reducing stack 0 by rule 2 (line 83): $1 = nterm input () $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token end of input () +Shifting token end of file () Entering state 16 -Cleanup: popping token end of input () +Cleanup: popping token end of file () Cleanup: popping nterm input () - | (* *) + (*) + (*) -./calc.at:1494: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS -./calc.at:1482: $PREPARSER ./calc input -stderr: +./calc.at:1486: cat stderr input: stderr: -stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 15 -Reducing stack 0 by rule 16 (line 107): - $1 = token '!' () - $2 = token '!' () -Shifting token error () -Entering state 11 -Reading a token -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token "number" (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token "number" (2) -Error: discarding token "number" (2) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2222) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token @@ -196267,12 +197289,6 @@ Next token is token error () Error: discarding token error () Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token "number" (1) -Error: discarding token "number" (1) -Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () @@ -196322,123 +197338,29 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '*' () -syntax error -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '*' () -syntax error -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '*' () -syntax error -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (2222) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (3333) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (3333) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () -./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | 1 2 +./calc.at:1487: $PREPARSER ./calc input +./calc.at:1489: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1485: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -196450,27 +197372,19 @@ -> $$ = nterm exp (1) Entering state 8 Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 27 -Reading a token -Next token is token '=' () -syntax error, unexpected '=' -Error: popping nterm exp (2) -Error: popping token '=' () +syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) Error: popping nterm exp (1) -Cleanup: discarding lookahead token '=' () +Cleanup: discarding lookahead token number (2) +./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1489: cat stderr + | (1 + #) = 1111 ./calc.at:1486: $PREPARSER ./calc input +./calc.at:1485: cat stderr stderr: stderr: +./calc.at:1485: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Reading a token @@ -196478,42 +197392,26 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token '*' () -syntax error -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '*' () -syntax error +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) Shifting token error () Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token error () +Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 @@ -196525,54 +197423,32 @@ $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 Reading a token -Next token is token '*' () -syntax error -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token '=' () +Shifting token '=' () +Entering state 18 Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () +Next token is token "number" (1111) +Shifting token "number" (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1111) -> $$ = nterm exp (1111) -Entering state 29 +Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (2222) - $2 = token '+' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () $3 = nterm exp (1111) --> $$ = nterm exp (3333) +-> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (3333) + $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -196586,43 +197462,24 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token number (2) -syntax error, unexpected number +syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) Error: popping nterm exp (1) Cleanup: discarding lookahead token number (2) -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1485: "$PERL" -pi -e 'use strict; +./calc.at:1482: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -196632,316 +197489,85 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1486: cat stderr stderr: -./calc.at:1489: cat stderr + | 1 + 2 * 3 + !+ ++ +./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token number (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Cleanup: discarding lookahead token number (2) -./calc.at:1482: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1485: cat stderr -input: -input: - | (1 + 1) / (1 - 1) -input: -./calc.at:1486: $PREPARSER ./calc input - | (- *) + (1 2) = 1 -./calc.at:1489: $PREPARSER ./calc input - | - | +1 +Now at end of input. +syntax error, unexpected end of file +Cleanup: discarding lookahead token end of file () +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1485: $PREPARSER ./calc input stderr: Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1) -> $$ = nterm exp (1) -Entering state 12 +Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token "number" (2) +Shifting token "number" (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 29 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (2) - $3 = token ')' () + $1 = token "number" (2) -> $$ = nterm exp (2) -Entering state 8 -Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 +Entering state 29 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 +Next token is token '*' () +Shifting token '*' () +Entering state 21 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token "number" (3) +Shifting token "number" (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 28 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (1) --> $$ = nterm exp (0) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (0) - $3 = token ')' () --> $$ = nterm exp (0) -Entering state 31 + $1 = token "number" (3) +-> $$ = nterm exp (3) +Entering state 30 Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (2) - $2 = token '/' () - $3 = nterm exp (0) -error: null divisor --> $$ = nterm exp (2) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Next token is token '+' () +Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () -./calc.at:1482: cat stderr -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 9 -Reducing stack 0 by rule 15 (line 106): - $1 = token '-' () - $2 = token error () -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) Entering state 8 -Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token "number" (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token "number" (2) -Error: discarding token "number" (2) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 +Next token is token '!' () +Shifting token '!' () +Entering state 5 Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) +Next token is token '+' () +Shifting token '+' () +Entering state 14 +Reducing stack 0 by rule 17 (line 108): + $1 = token '!' () $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2222) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '+' () -syntax error, unexpected '+' -Error: popping nterm input () -Cleanup: discarding lookahead token '+' () -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: stderr: -./calc.at:1486: cat stderr -input: Starting parse Entering state 0 Reading a token @@ -196949,42 +197575,6 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 9 -Reducing stack 0 by rule 15 (line 106): - $1 = token '-' () - $2 = token error () -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token Next token is token "number" (1) Shifting token "number" (1) Entering state 1 @@ -196993,13 +197583,18 @@ -> $$ = nterm exp (1) Entering state 12 Reading a token -Next token is token "number" (2) -syntax error, unexpected number +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 -Next token is token "number" (2) -Error: discarding token "number" (2) +Next token is token error () +Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 @@ -197011,40 +197606,32 @@ $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) Entering state 8 +Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token "number" (1111) +Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) + $1 = token "number" (1111) +-> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (2222) + $1 = nterm exp (1111) $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2222) + $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -197058,144 +197645,15 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () +stderr: Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 29 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (2) - $3 = token ')' () --> $$ = nterm exp (2) -Entering state 8 -Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 28 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (1) --> $$ = nterm exp (0) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (0) - $3 = token ')' () --> $$ = nterm exp (0) -Entering state 31 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (2) - $2 = token '/' () - $3 = nterm exp (0) -error: null divisor --> $$ = nterm exp (2) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () -stderr: - | 1 + 2 * 3 + !+ ++ -./calc.at:1482: $PREPARSER ./calc input +syntax error, unexpected end of file +Cleanup: discarding lookahead token end of file () stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '+' () -syntax error, unexpected '+' -Error: popping nterm input () -Cleanup: discarding lookahead token '+' () +stdout: Starting parse Entering state 0 Reading a token @@ -197261,13 +197719,25 @@ $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) +./calc.at:1486: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +./calc.at:1482: cat stderr input: -./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1//2 -./calc.at:1486: $PREPARSER ./calc input -stderr: + | 1 + 2 * 3 + !- ++ +./calc.at:1487: cat stderr +input: +./calc.at:1489: $PREPARSER ./calc input stderr: -./calc.at:1489: "$PERL" -pi -e 'use strict; +./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -197334,46 +197804,32 @@ Shifting token '!' () Entering state 5 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 14 -Reducing stack 0 by rule 17 (line 108): +Next token is token '-' () +Shifting token '-' () +Entering state 13 +Reducing stack 0 by rule 18 (line 109): $1 = token '!' () - $2 = token '+' () + $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '/' () -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '/' () -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1489: cat stderr +input: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1486: $PREPARSER ./calc input + | (# + 1) = 1111 +./calc.at:1482: $PREPARSER ./calc input ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -197384,7 +197840,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +stderr: input: +./calc.at:1486: cat stderr +stderr: stderr: Starting parse Entering state 0 @@ -197397,41 +197856,15 @@ -> $$ = nterm exp (1) Entering state 8 Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '/' () -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '/' () -./calc.at:1485: cat stderr - | 1 + 2 * 3 + !- ++ -./calc.at:1482: $PREPARSER ./calc input -./calc.at:1486: cat stderr -stderr: -input: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token -Next token is token "number" (2) -Shifting token "number" (2) +Next token is token number (2) +Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2) + $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token @@ -197439,58 +197872,65 @@ Shifting token '*' () Entering state 21 Reading a token -Next token is token "number" (3) -Shifting token "number" (3) +Next token is token number (3) +Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (3) + $1 = token number (3) -> $$ = nterm exp (3) Entering state 30 Reading a token -Next token is token '+' () +Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () $3 = nterm exp (3) -> $$ = nterm exp (6) Entering state 29 -Next token is token '+' () +Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () $3 = nterm exp (6) -> $$ = nterm exp (7) Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Next token is token '=' () +Shifting token '=' () +Entering state 18 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 +Next token is token number (7) +Shifting token number (7) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (7) +-> $$ = nterm exp (7) +Entering state 27 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 13 -Reducing stack 0 by rule 18 (line 109): - $1 = token '!' () - $2 = token '-' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) -./calc.at:1485: $PREPARSER ./calc /dev/null - | (* *) + (*) + (*) -./calc.at:1489: $PREPARSER ./calc input -./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -Starting parse -Entering state 0 +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (7) + $2 = token '=' () + $3 = nterm exp (7) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (7) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) + $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token @@ -197498,11 +197938,11 @@ Shifting token '+' () Entering state 20 Reading a token -Next token is token "number" (2) -Shifting token "number" (2) +Next token is token number (2) +Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2) + $1 = token number (2) -> $$ = nterm exp (2) Entering state 29 Reading a token @@ -197510,728 +197950,740 @@ Shifting token '*' () Entering state 21 Reading a token -Next token is token "number" (3) -Shifting token "number" (3) +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (3) +Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (3) + $1 = token number (3) -> $$ = nterm exp (3) -Entering state 30 +Entering state 10 Reading a token -Next token is token '+' () +Next token is token '=' () +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (3) +-> $$ = nterm exp (-3) +Entering state 30 +Next token is token '=' () Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (2) $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) + $3 = nterm exp (-3) +-> $$ = nterm exp (-6) Entering state 29 -Next token is token '+' () +Next token is token '=' () Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1) $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) + $3 = nterm exp (-6) +-> $$ = nterm exp (-5) Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 +Next token is token '=' () +Shifting token '=' () +Entering state 18 Reading a token Next token is token '-' () Shifting token '-' () -Entering state 13 -Reducing stack 0 by rule 18 (line 109): - $1 = token '!' () - $2 = token '-' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) -Starting parse -Entering state 0 -Reading a token -Now at end of input. -syntax error, unexpected end of file -Cleanup: discarding lookahead token end of file () -stderr: -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -560. calc.at:1486: ok -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Entering state 2 Reading a token -Next token is token '*' () -Error: discarding token '*' () +Next token is token number (5) +Shifting token number (5) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (5) +-> $$ = nterm exp (5) +Entering state 10 Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) +Next token is token '\n' () +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (5) +-> $$ = nterm exp (-5) +Entering state 27 +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (-5) + $2 = token '=' () + $3 = nterm exp (-5) +-> $$ = nterm exp (-5) Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (-5) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 +Next token is token '-' () +Shifting token '-' () +Entering state 2 Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 10 Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 +Next token is token '^' () +Shifting token '^' () +Entering state 23 Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 32 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 +Next token is token '=' () +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (1) + $2 = token '^' () + $3 = nterm exp (2) +-> $$ = nterm exp (1) +Entering state 10 +Next token is token '=' () +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token '-' () +Shifting token '-' () +Entering state 2 Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 10 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (2222) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (3333) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 27 +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (-1) + $2 = token '=' () + $3 = nterm exp (-1) +-> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (3333) + $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Now at end of input. -syntax error, unexpected end of file -Cleanup: discarding lookahead token end of file () -./calc.at:1486: cat stderr -stderr: -Starting parse -Entering state 0 -Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token '-' () +Shifting token '-' () +Entering state 2 Reading a token -Next token is token '*' () -Error: discarding token '*' () +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 10 Reading a token Next token is token ')' () -Entering state 11 +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 12 Next token is token ')' () Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Entering state 26 +Reducing stack 0 by rule 13 (line 104): $1 = token '(' () - $2 = token error () + $2 = nterm exp (-1) $3 = token ')' () --> $$ = nterm exp (1111) +-> $$ = nterm exp (-1) Entering state 8 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token '^' () +Shifting token '^' () +Entering state 23 Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 32 Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) +Next token is token '=' () +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (-1) + $2 = token '^' () + $3 = nterm exp (2) +-> $$ = nterm exp (1) Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token '=' () +Shifting token '=' () +Entering state 18 Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (2222) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (3333) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1) + $2 = token '=' () + $3 = nterm exp (1) +-> $$ = nterm exp (1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (3333) + $1 = nterm exp (1) $2 = token '\n' () -> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () -./calc.at:1482: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: - | error -./calc.at:1486: $PREPARSER ./calc input -./calc.at:1485: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: - -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Reading a token -Next token is token invalid token () -syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token () -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1482: cat stderr -./calc.at:1485: cat stderr -./calc.at:1489: cat stderr -stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token invalid token () -syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token () -input: -input: -stdout: - | (#) + (#) = 2222 - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1485: $PREPARSER ./calc input -./calc.at:1482: $PREPARSER ./calc input -./calc.at:1491: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc calc.hh - -input: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Next token is token '-' () +Shifting token '-' () +Entering state 2 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 +Next token is token '-' () +Shifting token '-' () +Entering state 2 Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token '-' () +Shifting token '-' () +Entering state 2 Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 10 Reading a token Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 10 +Next token is token '=' () +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (-1) +-> $$ = nterm exp (1) +Entering state 10 +Next token is token '=' () +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (2222) -Shifting token "number" (2222) +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2222) --> $$ = nterm exp (2222) -Entering state 27 + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 10 Reading a token Next token is token '\n' () +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 27 +Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (2222) + $1 = nterm exp (-1) $2 = token '=' () - $3 = nterm exp (2222) --> $$ = nterm exp (2222) + $3 = nterm exp (-1) +-> $$ = nterm exp (-1) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2222) + $1 = nterm exp (-1) $2 = token '\n' () -> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () -./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: - | 1 + 2 * 3 + !+ ++ -./calc.at:1489: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 Reading a token -Next token is token ')' () -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 28 +Reading a token +Next token is token '-' () +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (2) +-> $$ = nterm exp (-1) Entering state 8 +Next token is token '-' () +Shifting token '-' () +Entering state 19 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 28 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 +Next token is token '=' () +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (-1) + $2 = token '-' () + $3 = nterm exp (3) +-> $$ = nterm exp (-4) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (4) +Shifting token number (4) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (4) +-> $$ = nterm exp (4) +Entering state 10 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Next token is token '\n' () +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (4) +-> $$ = nterm exp (-4) +Entering state 27 +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (-4) + $2 = token '=' () + $3 = nterm exp (-4) +-> $$ = nterm exp (-4) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (-4) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): +Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) -Entering state 29 +Entering state 8 Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) -> $$ = nterm exp (2) Entering state 12 -Next token is token '+' () -Shifting token '+' () -Entering state 20 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 +Next token is token '-' () +Shifting token '-' () +Entering state 19 Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (2) - $2 = token '+' () - $3 = nterm exp (1) +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (3) -> $$ = nterm exp (3) -Entering state 12 -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Entering state 28 Reading a token Next token is token ')' () -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' () -Error: popping nterm exp (3) -Shifting token error () -Entering state 11 +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (2) + $2 = token '-' () + $3 = nterm exp (3) +-> $$ = nterm exp (-1) +Entering state 12 Next token is token ')' () Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): +Entering state 26 +Reducing stack 0 by rule 13 (line 104): $1 = token '(' () - $2 = token error () + $2 = nterm exp (-1) $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 +-> $$ = nterm exp (-1) +Entering state 28 Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) +Next token is token '=' () +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (-1) +-> $$ = nterm exp (2) Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Next token is token '=' () +Shifting token '=' () +Entering state 18 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 27 Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2) + $2 = token '=' () + $3 = nterm exp (2) +-> $$ = nterm exp (2) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 Reading a token -Next token is token '*' () -Error: discarding token '*' () +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 Reading a token -Next token is token '*' () -Error: discarding token '*' () +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 8 Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 +Next token is token '^' () +Shifting token '^' () +Entering state 23 Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (2222) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (3333) +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 32 +Reading a token +Next token is token '^' () +Shifting token '^' () +Entering state 23 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 32 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (2) + $2 = token '^' () + $3 = nterm exp (3) +-> $$ = nterm exp (8) +Entering state 32 +Next token is token '=' () +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (2) + $2 = token '^' () + $3 = nterm exp (8) +-> $$ = nterm exp (256) Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (256) +Shifting token number (256) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (256) +-> $$ = nterm exp (256) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (256) + $2 = token '=' () + $3 = nterm exp (256) +-> $$ = nterm exp (256) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (256) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token number (2) +Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) Entering state 12 Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 +Next token is token '^' () +Shifting token '^' () +Entering state 23 Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 92): +Reducing stack 0 by rule 5 (line 79): $1 = token number (2) -> $$ = nterm exp (2) -Entering state 30 +Entering state 32 Reading a token -Next token is token '*' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (1) - $2 = token '*' () +Next token is token ')' () +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (2) + $2 = token '^' () $3 = nterm exp (2) --> $$ = nterm exp (2) +-> $$ = nterm exp (4) Entering state 12 -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' () -Error: popping nterm exp (2) -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 Next token is token ')' () Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): +Entering state 26 +Reducing stack 0 by rule 13 (line 104): $1 = token '(' () - $2 = token error () + $2 = nterm exp (4) $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 +-> $$ = nterm exp (4) +Entering state 8 +Reading a token +Next token is token '^' () +Shifting token '^' () +Entering state 23 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 32 Reading a token Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (3333) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (4444) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (4) + $2 = token '^' () + $3 = nterm exp (3) +-> $$ = nterm exp (64) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token number (64) +Shifting token number (64) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) +Reducing stack 0 by rule 5 (line 79): + $1 = token number (64) +-> $$ = nterm exp (64) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (4444) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (64) $2 = token '=' () - $3 = nterm exp (1) -error: 4444 != 1 --> $$ = nterm exp (4444) + $3 = nterm exp (64) +-> $$ = nterm exp (64) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (4444) +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (64) $2 = token '\n' () -> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token end of file () +Shifting token end of input () Entering state 16 -Cleanup: popping token end of file () +Cleanup: popping token end of input () Cleanup: popping nterm input () -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: + | 1//2 +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1487: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -198246,32 +198698,11 @@ Next token is token error () Error: discarding token error () Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 +Error: discarding token '+' () Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token "number" (1) +Error: discarding token "number" (1) Reading a token Next token is token ')' () Entering state 11 @@ -198283,39 +198714,32 @@ $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) Entering state 8 +Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (2222) -Shifting token "number" (2222) +Next token is token "number" (1111) +Shifting token "number" (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2222) --> $$ = nterm exp (2222) + $1 = token "number" (1111) +-> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (2222) + $1 = nterm exp (1111) $2 = token '=' () - $3 = nterm exp (2222) --> $$ = nterm exp (2222) + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2222) + $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -198329,8 +198753,7 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -stdout: -570. calc.at:1494: testing Calculator glr2.cc %no-lines %locations %header parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... +./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -198388,67 +198811,1139 @@ Shifting token '!' () Entering state 5 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 14 -Reducing stack 0 by rule 17 (line 108): +Next token is token '-' () +Shifting token '-' () +Entering state 13 +Reducing stack 0 by rule 18 (line 109): $1 = token '!' () - $2 = token '+' () + $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) -input: -./calc.at:1494: mv calc.y.tmp calc.y - -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1487: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1491: $PREPARSER ./calc input stderr: +./calc.at:1485: cat stderr +input: Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 Reading a token -Next token is token ')' () -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token ')' () -Shifting token ')' () +Next token is token '/' () +Shifting token '/' () +Entering state 22 +Reading a token +Next token is token '/' () +syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) +Error: popping token '/' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '/' () +./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: + | (# + 1) = 1111 +./calc.at:1486: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 30 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (7) +Shifting token number (7) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (7) +-> $$ = nterm exp (7) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (7) + $2 = token '=' () + $3 = nterm exp (7) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (7) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 10 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (3) +-> $$ = nterm exp (-3) +Entering state 30 +Next token is token '=' () +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (-3) +-> $$ = nterm exp (-6) +Entering state 29 +Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (-6) +-> $$ = nterm exp (-5) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (5) +Shifting token number (5) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (5) +-> $$ = nterm exp (5) +Entering state 10 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (5) +-> $$ = nterm exp (-5) +Entering state 27 +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (-5) + $2 = token '=' () + $3 = nterm exp (-5) +-> $$ = nterm exp (-5) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (-5) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 10 +Reading a token +Next token is token '^' () +Shifting token '^' () +Entering state 23 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 32 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (1) + $2 = token '^' () + $3 = nterm exp (2) +-> $$ = nterm exp (1) +Entering state 10 +Next token is token '=' () +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 10 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 27 +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (-1) + $2 = token '=' () + $3 = nterm exp (-1) +-> $$ = nterm exp (-1) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (-1) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 10 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (-1) + $3 = token ')' () +-> $$ = nterm exp (-1) +Entering state 8 +Reading a token +Next token is token '^' () +Shifting token '^' () +Entering state 23 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 32 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (-1) + $2 = token '^' () + $3 = nterm exp (2) +-> $$ = nterm exp (1) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1) + $2 = token '=' () + $3 = nterm exp (1) +-> $$ = nterm exp (1) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 10 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 10 +Next token is token '=' () +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (-1) +-> $$ = nterm exp (1) +Entering state 10 +Next token is token '=' () +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 10 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (1) +-> $$ = nterm exp (-1) +Entering state 27 +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (-1) + $2 = token '=' () + $3 = nterm exp (-1) +-> $$ = nterm exp (-1) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (-1) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 28 +Reading a token +Next token is token '-' () +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (2) +-> $$ = nterm exp (-1) +Entering state 8 +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 28 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (-1) + $2 = token '-' () + $3 = nterm exp (3) +-> $$ = nterm exp (-4) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token number (4) +Shifting token number (4) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (4) +-> $$ = nterm exp (4) +Entering state 10 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' () + $2 = nterm exp (4) +-> $$ = nterm exp (-4) +Entering state 27 +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (-4) + $2 = token '=' () + $3 = nterm exp (-4) +-> $$ = nterm exp (-4) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (-4) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 12 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 28 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (2) + $2 = token '-' () + $3 = nterm exp (3) +-> $$ = nterm exp (-1) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (-1) + $3 = token ')' () +-> $$ = nterm exp (-1) +Entering state 28 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (-1) +-> $$ = nterm exp (2) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2) + $2 = token '=' () + $3 = nterm exp (2) +-> $$ = nterm exp (2) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 8 +Reading a token +Next token is token '^' () +Shifting token '^' () +Entering state 23 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 32 +Reading a token +Next token is token '^' () +Shifting token '^' () +Entering state 23 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 32 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (2) + $2 = token '^' () + $3 = nterm exp (3) +-> $$ = nterm exp (8) +Entering state 32 +Next token is token '=' () +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (2) + $2 = token '^' () + $3 = nterm exp (8) +-> $$ = nterm exp (256) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (256) +Shifting token number (256) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (256) +-> $$ = nterm exp (256) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (256) + $2 = token '=' () + $3 = nterm exp (256) +-> $$ = nterm exp (256) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (256) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 12 +Reading a token +Next token is token '^' () +Shifting token '^' () +Entering state 23 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 32 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (2) + $2 = token '^' () + $3 = nterm exp (2) +-> $$ = nterm exp (4) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (4) + $3 = token ')' () +-> $$ = nterm exp (4) +Entering state 8 +Reading a token +Next token is token '^' () +Shifting token '^' () +Entering state 23 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 32 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (4) + $2 = token '^' () + $3 = nterm exp (3) +-> $$ = nterm exp (64) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (64) +Shifting token number (64) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (64) +-> $$ = nterm exp (64) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (64) + $2 = token '=' () + $3 = nterm exp (64) +-> $$ = nterm exp (64) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (64) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input () + $2 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input () +Entering state 16 +Cleanup: popping token end of input () +Cleanup: popping nterm input () +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token "number" (1) +Error: discarding token "number" (1) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1111) +Shifting token "number" (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '/' () +Shifting token '/' () +Entering state 22 +Reading a token +Next token is token '/' () +syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) +Error: popping token '/' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '/' () +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token "number" (1) +Error: discarding token "number" (1) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1111) +Shifting token "number" (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +input: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +stderr: + | 1 2 +./calc.at:1485: $PREPARSER ./calc input +./calc.at:1489: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1486: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token "number" (1) +Error: discarding token "number" (1) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1111) +Shifting token "number" (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token ')' () +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token ')' () +Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): $1 = token '(' () @@ -198684,73 +200179,857 @@ Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token number (2) +syntax error, unexpected number +Error: popping nterm exp (1) +Cleanup: discarding lookahead token number (2) +./calc.at:1489: cat stderr +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1487: cat stderr +stderr: stderr: input: +./calc.at:1482: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) + $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token +Next token is token number (2) +syntax error, unexpected number +Error: popping nterm exp (1) +Cleanup: discarding lookahead token number (2) + | (#) + (#) = 2222 +./calc.at:1489: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token ')' () +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token -Next token is token "number" (2) -Shifting token "number" (2) +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (1) +Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) -> $$ = nterm exp (2) +Entering state 12 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (2) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (3) +Entering state 12 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token ')' () +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' () +Error: popping nterm exp (3) +Shifting token error () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 29 Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (2222) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (3333) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token Next token is token '*' () Shifting token '*' () Entering state 21 Reading a token -Next token is token "number" (3) -Shifting token "number" (3) +Next token is token number (2) +Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (3) --> $$ = nterm exp (3) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) Entering state 30 Reading a token -Next token is token '+' () -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (2) +Next token is token '*' () +Reducing stack 0 by rule 9 (line 105): + $1 = nterm exp (1) $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) + $3 = nterm exp (2) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' () +Error: popping nterm exp (2) +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 29 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (3333) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (4444) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (4444) + $2 = token '=' () + $3 = nterm exp (1) +error: 4444 != 1 +-> $$ = nterm exp (4444) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (4444) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +input: +stderr: + | error +./calc.at:1487: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '=' () Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) + $1 = nterm exp (1111) $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (2222) +Shifting token "number" (2222) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2222) +-> $$ = nterm exp (2222) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (2222) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1486: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token invalid token () +syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) +Cleanup: discarding lookahead token invalid token () +./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1482: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 8 +Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (2222) +Shifting token "number" (2222) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2222) +-> $$ = nterm exp (2222) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (2222) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token invalid token () +syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) +Cleanup: discarding lookahead token invalid token () +input: +stderr: +./calc.at:1485: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (1 + # + 1) = 1111 +./calc.at:1486: $PREPARSER ./calc input +stdout: +input: +./calc.at:1486: cat stderr +./calc.at:1491: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc calc.hh + + | (1 + # + 1) = 1111 +stderr: +./calc.at:1482: $PREPARSER ./calc input +./calc.at:1485: cat stderr +stderr: +./calc.at:1489: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () -Entering state 14 -Reducing stack 0 by rule 17 (line 108): - $1 = token '!' () - $2 = token '+' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) +Entering state 20 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token "number" (1) +Error: discarding token "number" (1) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1111) +Shifting token "number" (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +input: +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token "number" (1) +Error: discarding token "number" (1) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1111) +Shifting token "number" (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1487: cat stderr +./calc.at:1491: $PREPARSER ./calc input +input: +input: +stderr: + | 1//2 +./calc.at:1486: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token "number" (1) +Error: discarding token "number" (1) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1111) +Shifting token "number" (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +stderr: +stderr: +./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token @@ -199587,867 +201866,225 @@ Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1486: cat stderr -./calc.at:1494: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -input: -./calc.at:1487: $PREPARSER ./calc input -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 + 2 * 3 + !- ++ -./calc.at:1482: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1489: $PREPARSER ./calc input -stderr: -input: stderr: + | (!!) + (1 2) = 1 Starting parse Entering state 0 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 30 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (7) -Shifting token number (7) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (7) --> $$ = nterm exp (7) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (7) - $2 = token '=' () - $3 = nterm exp (7) --> $$ = nterm exp (7) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (7) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 +Next token is token '(' () +Shifting token '(' () +Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1) +Shifting token "number" (1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) -> $$ = nterm exp (1) -Entering state 8 +Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 10 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (3) --> $$ = nterm exp (-3) -Entering state 30 -Next token is token '=' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (-3) --> $$ = nterm exp (-6) -Entering state 29 -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (-6) --> $$ = nterm exp (-5) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (5) -Shifting token number (5) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (5) --> $$ = nterm exp (5) -Entering state 10 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (5) --> $$ = nterm exp (-5) -Entering state 27 -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (-5) - $2 = token '=' () - $3 = nterm exp (-5) --> $$ = nterm exp (-5) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (-5) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 10 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 32 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (1) - $2 = token '^' () - $3 = nterm exp (2) --> $$ = nterm exp (1) -Entering state 10 -Next token is token '=' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 10 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 27 -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (-1) - $2 = token '=' () - $3 = nterm exp (-1) --> $$ = nterm exp (-1) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (-1) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 +Next token is token '+' () +Error: discarding token '+' () Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 10 +Next token is token "number" (1) +Error: discarding token "number" (1) Reading a token Next token is token ')' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 12 +Entering state 11 Next token is token ')' () Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): +Entering state 25 +Reducing stack 0 by rule 14 (line 105): $1 = token '(' () - $2 = nterm exp (-1) + $2 = token error () $3 = token ')' () --> $$ = nterm exp (-1) +-> $$ = nterm exp (1111) Entering state 8 Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 32 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (-1) - $2 = token '^' () - $3 = nterm exp (2) --> $$ = nterm exp (1) -Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1111) +Shifting token "number" (1111) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1111) +-> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (1) - $2 = token '=' () - $3 = nterm exp (1) --> $$ = nterm exp (1) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (1) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 10 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 10 -Next token is token '=' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (-1) --> $$ = nterm exp (1) -Entering state 10 -Next token is token '=' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 10 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 27 -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (-1) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1111) $2 = token '=' () - $3 = nterm exp (-1) --> $$ = nterm exp (-1) + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (-1) +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1485: $PREPARSER ./calc input +input: +Starting parse +Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): +Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 28 -Reading a token -Next token is token '-' () -Reducing stack 0 by rule 8 (line 104): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (2) --> $$ = nterm exp (-1) -Entering state 8 -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 28 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 8 (line 104): - $1 = nterm exp (-1) - $2 = token '-' () - $3 = nterm exp (3) --> $$ = nterm exp (-4) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (4) -Shifting token number (4) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (4) --> $$ = nterm exp (4) -Entering state 10 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (4) --> $$ = nterm exp (-4) -Entering state 27 -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (-4) - $2 = token '=' () - $3 = nterm exp (-4) --> $$ = nterm exp (-4) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (-4) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 +Next token is token '/' () +Shifting token '/' () +Entering state 22 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 +Next token is token '/' () +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '/' () +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: + | 1 = 2 = 3 +./calc.at:1487: $PREPARSER ./calc input +input: +stderr: +stderr: +stderr: +Starting parse +Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 12 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 +Next token is token '!' () +Shifting token '!' () +Entering state 5 Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 28 +Next token is token '!' () +Shifting token '!' () +Entering state 15 +Reducing stack 0 by rule 16 (line 120): + $1 = token '!' () + $2 = token '!' () +Shifting token error () +Entering state 11 Reading a token Next token is token ')' () -Reducing stack 0 by rule 8 (line 104): - $1 = nterm exp (2) - $2 = token '-' () - $3 = nterm exp (3) --> $$ = nterm exp (-1) -Entering state 12 -Next token is token ')' () Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): +Entering state 25 +Reducing stack 0 by rule 14 (line 118): $1 = token '(' () - $2 = nterm exp (-1) + $2 = token error () $3 = token ')' () --> $$ = nterm exp (-1) -Entering state 28 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 8 (line 104): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (-1) --> $$ = nterm exp (2) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (2) - $2 = token '=' () - $3 = nterm exp (2) --> $$ = nterm exp (2) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 8 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 32 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 32 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (2) - $2 = token '^' () - $3 = nterm exp (3) --> $$ = nterm exp (8) -Entering state 32 -Next token is token '=' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (2) - $2 = token '^' () - $3 = nterm exp (8) --> $$ = nterm exp (256) +-> $$ = nterm exp (1111) Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (256) -Shifting token number (256) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (256) --> $$ = nterm exp (256) -Entering state 27 Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (256) - $2 = token '=' () - $3 = nterm exp (256) --> $$ = nterm exp (256) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (256) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token -Next token is token number (2) -Shifting token number (2) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 12 Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 32 +syntax error, unexpected number +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token number (2) +Error: discarding token number (2) Reading a token Next token is token ')' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (2) - $2 = token '^' () - $3 = nterm exp (2) --> $$ = nterm exp (4) -Entering state 12 +Entering state 11 Next token is token ')' () Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): +Entering state 25 +Reducing stack 0 by rule 14 (line 118): $1 = token '(' () - $2 = nterm exp (4) + $2 = token error () $3 = token ')' () --> $$ = nterm exp (4) -Entering state 8 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 32 +-> $$ = nterm exp (1111) +Entering state 29 Reading a token Next token is token '=' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (4) - $2 = token '^' () - $3 = nterm exp (3) --> $$ = nterm exp (64) +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token number (64) -Shifting token number (64) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): - $1 = token number (64) --> $$ = nterm exp (64) + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (64) + $1 = nterm exp (2222) $2 = token '=' () - $3 = nterm exp (64) --> $$ = nterm exp (64) + $3 = nterm exp (1) +error: 2222 != 1 +-> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (64) + $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token @@ -200456,85 +202093,28 @@ Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () -stderr: -./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 = 2 = 3 -./calc.at:1485: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1486: $PREPARSER ./calc input + | (1 + #) = 1111 +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) + $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token "number" (2) -Shifting token "number" (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token "number" (3) -Shifting token "number" (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (3) --> $$ = nterm exp (3) -Entering state 30 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) -Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 +Next token is token '/' () +Shifting token '/' () +Entering state 22 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 13 -Reducing stack 0 by rule 18 (line 109): - $1 = token '!' () - $2 = token '-' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) +Next token is token '/' () +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '/' () Starting parse Entering state 0 Reading a token @@ -201371,41 +202951,7 @@ Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 27 -Reading a token -Next token is token '=' () -syntax error, unexpected '=' -Error: popping nterm exp (2) -Error: popping token '=' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '=' () -./calc.at:1482: cat stderr -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -201417,976 +202963,28 @@ -> $$ = nterm exp (1) Entering state 8 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 30 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (7) -Shifting token number (7) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (7) --> $$ = nterm exp (7) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (7) - $2 = token '=' () - $3 = nterm exp (7) --> $$ = nterm exp (7) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (7) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 10 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (3) --> $$ = nterm exp (-3) -Entering state 30 -Next token is token '=' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (-3) --> $$ = nterm exp (-6) -Entering state 29 -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (-6) --> $$ = nterm exp (-5) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (5) -Shifting token number (5) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (5) --> $$ = nterm exp (5) -Entering state 10 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (5) --> $$ = nterm exp (-5) -Entering state 27 -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (-5) - $2 = token '=' () - $3 = nterm exp (-5) --> $$ = nterm exp (-5) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (-5) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 10 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 32 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (1) - $2 = token '^' () - $3 = nterm exp (2) --> $$ = nterm exp (1) -Entering state 10 -Next token is token '=' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 10 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 27 -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (-1) - $2 = token '=' () - $3 = nterm exp (-1) --> $$ = nterm exp (-1) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (-1) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 10 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): - $1 = token '(' () - $2 = nterm exp (-1) - $3 = token ')' () --> $$ = nterm exp (-1) -Entering state 8 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 32 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (-1) - $2 = token '^' () - $3 = nterm exp (2) --> $$ = nterm exp (1) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (1) - $2 = token '=' () - $3 = nterm exp (1) --> $$ = nterm exp (1) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (1) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 10 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 10 -Next token is token '=' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (-1) --> $$ = nterm exp (1) -Entering state 10 -Next token is token '=' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 10 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (1) --> $$ = nterm exp (-1) -Entering state 27 -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (-1) - $2 = token '=' () - $3 = nterm exp (-1) --> $$ = nterm exp (-1) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (-1) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 28 -Reading a token -Next token is token '-' () -Reducing stack 0 by rule 8 (line 104): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (2) --> $$ = nterm exp (-1) -Entering state 8 -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 28 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 8 (line 104): - $1 = nterm exp (-1) - $2 = token '-' () - $3 = nterm exp (3) --> $$ = nterm exp (-4) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token number (4) -Shifting token number (4) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (4) --> $$ = nterm exp (4) -Entering state 10 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 11 (line 115): - $1 = token '-' () - $2 = nterm exp (4) --> $$ = nterm exp (-4) -Entering state 27 -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (-4) - $2 = token '=' () - $3 = nterm exp (-4) --> $$ = nterm exp (-4) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (-4) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 12 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 28 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 8 (line 104): - $1 = nterm exp (2) - $2 = token '-' () - $3 = nterm exp (3) --> $$ = nterm exp (-1) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): - $1 = token '(' () - $2 = nterm exp (-1) - $3 = token ')' () --> $$ = nterm exp (-1) -Entering state 28 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 8 (line 104): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (-1) --> $$ = nterm exp (2) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (2) - $2 = token '=' () - $3 = nterm exp (2) --> $$ = nterm exp (2) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 8 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 32 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 32 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (2) - $2 = token '^' () - $3 = nterm exp (3) --> $$ = nterm exp (8) -Entering state 32 -Next token is token '=' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (2) - $2 = token '^' () - $3 = nterm exp (8) --> $$ = nterm exp (256) -Entering state 8 Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token number (256) -Shifting token number (256) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (256) --> $$ = nterm exp (256) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (256) - $2 = token '=' () - $3 = nterm exp (256) --> $$ = nterm exp (256) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (256) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 12 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token Next token is token number (2) Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 92): $1 = token number (2) -> $$ = nterm exp (2) -Entering state 32 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (2) - $2 = token '^' () - $3 = nterm exp (2) --> $$ = nterm exp (4) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): - $1 = token '(' () - $2 = nterm exp (4) - $3 = token ')' () --> $$ = nterm exp (4) -Entering state 8 -Reading a token -Next token is token '^' () -Shifting token '^' () -Entering state 23 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 32 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 12 (line 116): - $1 = nterm exp (4) - $2 = token '^' () - $3 = nterm exp (3) --> $$ = nterm exp (64) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (64) -Shifting token number (64) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (64) --> $$ = nterm exp (64) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (64) - $2 = token '=' () - $3 = nterm exp (64) --> $$ = nterm exp (64) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (64) - $2 = token '\n' () --> $$ = nterm line () -Entering state 17 -Reducing stack 0 by rule 2 (line 83): - $1 = nterm input () - $2 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () - | 1 2 -./calc.at:1485: cat stderr -./calc.at:1491: $PREPARSER ./calc input -stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token "number" (2) -Shifting token "number" (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token "number" (3) -Shifting token "number" (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (3) --> $$ = nterm exp (3) -Entering state 30 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) -Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 13 -Reducing stack 0 by rule 18 (line 109): - $1 = token '!' () - $2 = token '-' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) -stderr: -input: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token "number" (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token "number" (1.3: 2) - | 1 2 -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2) --> $$ = nterm exp (2) Entering state 27 Reading a token Next token is token '=' () -syntax error, unexpected '=' +syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) Error: popping nterm exp (2) Error: popping token '=' () Error: popping nterm exp (1) Cleanup: discarding lookahead token '=' () -input: -./calc.at:1487: $PREPARSER ./calc input - | (1 + #) = 1111 -./calc.at:1482: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token number (2) -syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) -Error: popping nterm exp (1) -Cleanup: discarding lookahead token number (2) ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: stderr: -./calc.at:1494: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS stderr: - | (!!) + (1 2) = 1 -./calc.at:1485: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -202464,59 +203062,7 @@ Entering state 16 Cleanup: popping token "end of input" () Cleanup: popping nterm input () -stderr: -./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token number (2) -syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] ['\n']) -Error: popping nterm exp (1) -Cleanup: discarding lookahead token number (2) -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token "number" (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token "number" (1.3: 2) -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -202628,10 +203174,59 @@ Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: + | 1 2 +./calc.at:1491: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 27 +Reading a token +Next token is token '=' () +syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) +Error: popping nterm exp (2) +Error: popping token '=' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '=' () +./calc.at:1482: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -./calc.at:1489: cat stderr -./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token @@ -202710,7 +203305,70 @@ Cleanup: popping token "end of input" () Cleanup: popping nterm input () stderr: -./calc.at:1491: "$PERL" -pi -e 'use strict; +./calc.at:1486: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token "number" (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token "number" (1.3: 2) +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1482: cat stderr +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1485: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +input: +./calc.at:1487: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token "number" (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token "number" (1.3: 2) +input: +./calc.at:1485: cat stderr + | (1 + 1) / (1 - 1) +./calc.at:1486: $PREPARSER ./calc input +./calc.at:1486: cat stderr + | (1 + 1) / (1 - 1) +./calc.at:1482: $PREPARSER ./calc input +./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -202720,6 +203378,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +stderr: +stderr: +input: Starting parse Entering state 0 Reading a token @@ -202727,20 +203388,662 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 15 -Reducing stack 0 by rule 16 (line 120): - $1 = token '!' () - $2 = token '!' () +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 29 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (2) + $3 = token ')' () +-> $$ = nterm exp (2) +Entering state 8 +Reading a token +Next token is token '/' () +Shifting token '/' () +Entering state 22 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 28 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (1) +-> $$ = nterm exp (0) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (0) + $3 = token ')' () +-> $$ = nterm exp (0) +Entering state 31 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 10 (line 93): + $1 = nterm exp (2) + $2 = token '/' () + $3 = nterm exp (0) +error: null divisor +-> $$ = nterm exp (2) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | + | +1 +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 29 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (2) + $3 = token ')' () +-> $$ = nterm exp (2) +Entering state 8 +Reading a token +Next token is token '/' () +Shifting token '/' () +Entering state 22 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 28 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (1) +-> $$ = nterm exp (0) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (0) + $3 = token ')' () +-> $$ = nterm exp (0) +Entering state 31 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 10 (line 93): + $1 = nterm exp (2) + $2 = token '/' () + $3 = nterm exp (0) +error: null divisor +-> $$ = nterm exp (2) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1489: cat stderr +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1487: $PREPARSER ./calc input +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (- *) + (1 2) = 1 +./calc.at:1485: $PREPARSER ./calc input +input: +stderr: +stderr: +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 87): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '+' () +syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) +Error: popping nterm input () +Cleanup: discarding lookahead token '+' () +./calc.at:1491: cat stderr + | error +./calc.at:1486: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 29 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (2) + $3 = token ')' () +-> $$ = nterm exp (2) +Entering state 8 +Reading a token +Next token is token '/' () +Shifting token '/' () +Entering state 22 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 28 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (1) +-> $$ = nterm exp (0) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (0) + $3 = token ')' () +-> $$ = nterm exp (0) +Entering state 31 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 10 (line 93): + $1 = nterm exp (2) + $2 = token '/' () + $3 = nterm exp (0) +error: null divisor +-> $$ = nterm exp (2) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 9 +Reducing stack 0 by rule 15 (line 119): + $1 = token '-' () + $2 = token error () +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token number (2) +syntax error, unexpected number +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token number (2) +Error: discarding token number (2) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (1) +error: 2222 != 1 +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +input: +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 29 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (2) + $3 = token ')' () +-> $$ = nterm exp (2) +Entering state 8 +Reading a token +Next token is token '/' () +Shifting token '/' () +Entering state 22 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 28 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (1) +-> $$ = nterm exp (0) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (0) + $3 = token ')' () +-> $$ = nterm exp (0) +Entering state 31 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 10 (line 93): + $1 = nterm exp (2) + $2 = token '/' () + $3 = nterm exp (0) +error: null divisor +-> $$ = nterm exp (2) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +stderr: + | (# + 1) = 1111 +./calc.at:1489: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token invalid token () +syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token () +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 9 +Reducing stack 0 by rule 15 (line 119): + $1 = token '-' () + $2 = token error () Shifting token error () Entering state 11 +Next token is token '*' () +Error: discarding token '*' () Reading a token Next token is token ')' () +Entering state 11 +Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 118): @@ -202831,16 +204134,902 @@ Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 87): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '+' () +syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) +Error: popping nterm input () +Cleanup: discarding lookahead token '+' () +input: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token "number" (1) +Error: discarding token "number" (1) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1111) +Shifting token "number" (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () + | 1//2 +./calc.at:1491: $PREPARSER ./calc input +stderr: +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token invalid token () +syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token () +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 22 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '/' (1.3: ) +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token "number" (1) +Error: discarding token "number" (1) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1111) +Shifting token "number" (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1482: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1487: cat stderr +./calc.at:1485: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1487: $PREPARSER ./calc /dev/null +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +Starting parse +Entering state 0 +Reading a token +Now at end of input. +syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) +Cleanup: discarding lookahead token end of file () +./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 22 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '/' (1.3: ) +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1485: cat stderr +./calc.at:1482: cat stderr +./calc.at:1486: cat stderr +557. calc.at:1482: ok +./calc.at:1486: cat stderr +stderr: +./calc.at:1489: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Reading a token +Now at end of input. +syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) +Cleanup: discarding lookahead token end of file () input: +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1491: cat stderr - | (#) + (#) = 2222 + | (* *) + (*) + (*) +input: +./calc.at:1485: $PREPARSER ./calc input + | 1 = 2 = 3 +./calc.at:1486: $PREPARSER ./calc input +560. calc.at:1486: ok +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 27 +Reading a token +Next token is token '=' () +syntax error, unexpected '=' +Error: popping nterm exp (2) +Error: popping token '=' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '=' () +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1489: cat stderr +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (2222) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (3333) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (3333) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 27 +Reading a token +Next token is token '=' () +syntax error, unexpected '=' +Error: popping nterm exp (2) +Error: popping token '=' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '=' () +input: + | error +./calc.at:1487: cat stderr +./calc.at:1491: $PREPARSER ./calc input input: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token "invalid token" (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" (1.1: ) +stderr: + +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (2222) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (3333) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (3333) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () + | (1 + # + 1) = 1111 ./calc.at:1489: $PREPARSER ./calc input - | - | +1 +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1487: $PREPARSER ./calc input +./calc.at:1485: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + stderr: -./calc.at:1486: $PREPARSER ./calc input +./calc.at:1485: cat stderr +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token ')' () +syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +Shifting token error () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (2) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (3) +Entering state 12 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token ')' () +syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +Error: popping token '+' () +Error: popping nterm exp (3) +Shifting token error () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (2222) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (3333) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 30 +Reading a token +Next token is token '*' () +Reducing stack 0 by rule 9 (line 105): + $1 = nterm exp (1) + $2 = token '*' () + $3 = nterm exp (2) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token '*' () +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +Error: popping token '*' () +Error: popping nterm exp (2) +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (3333) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (4444) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (4444) + $2 = token '=' () + $3 = nterm exp (1) +error: 4444 != 1 +-> $$ = nterm exp (4444) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (4444) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Reading a token +Next token is token "invalid token" (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" (1.1: ) Starting parse Entering state 0 Reading a token @@ -202848,13 +205037,33 @@ Shifting token '(' () Entering state 4 Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token syntax error: invalid character: '#' Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token "number" (1) +Error: discarding token "number" (1) +Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () @@ -202867,6 +205076,197 @@ -> $$ = nterm exp (1111) Entering state 8 Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1111) +Shifting token "number" (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token ')' () +syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +Shifting token error () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (2) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (3) +Entering state 12 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token ')' () +syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) +Error: popping token '+' () +Error: popping nterm exp (3) +Shifting token error () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (2222) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (3333) +Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 @@ -202875,13 +205275,145 @@ Shifting token '(' () Entering state 4 Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 30 +Reading a token +Next token is token '*' () +Reducing stack 0 by rule 9 (line 105): + $1 = nterm exp (1) + $2 = token '*' () + $3 = nterm exp (2) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token '*' () +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +Error: popping token '*' () +Error: popping nterm exp (2) +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (3333) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (4444) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (4444) + $2 = token '=' () + $3 = nterm exp (1) +error: 4444 != 1 +-> $$ = nterm exp (4444) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (4444) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +./calc.at:1491: cat stderr +input: + | 1 = 2 = 3 +stderr: +./calc.at:1486: cat stderr +input: +./calc.at:1491: $PREPARSER ./calc input +./calc.at:1487: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token syntax error: invalid character: '#' Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token "number" (1) +Error: discarding token "number" (1) +Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () @@ -202892,10 +205424,246 @@ $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token "number" (1111) +Shifting token "number" (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +stderr: + | 1 + 2 * 3 + !+ ++ +./calc.at:1485: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 18 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 27 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Error: popping token '=' (1.3: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '=' (1.7: ) +input: + | + | +1 +stderr: +./calc.at:1486: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 30 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 9 (line 105): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 14 +Reducing stack 0 by rule 17 (line 121): + $1 = token '!' () + $2 = token '+' () +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) +570. calc.at:1494: testing Calculator glr2.cc %no-lines %locations %header parse.error=verbose %debug api.prefix={calc} %verbose %parse-param {semantic_value *result}{int *count}{int *nerrs} ... +./calc.at:1494: mv calc.y.tmp calc.y + +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | (!!) + (1 2) = 1 +./calc.at:1487: $PREPARSER ./calc input +stderr: +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '+' () +syntax error, unexpected '+' +Error: popping nterm input () +Cleanup: discarding lookahead token '+' () +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 15 +Reducing stack 0 by rule 16 (line 120): + $1 = token '!' () + $2 = token '!' () +Shifting token error () +Entering state 11 +Reading a token +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token number (2) +syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token number (2) +Error: discarding token number (2) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 29 Reading a token Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): +Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) @@ -202905,44 +205673,211 @@ Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (2222) -Shifting token "number" (2222) +Next token is token number (1) +Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2222) --> $$ = nterm exp (2222) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () - $3 = nterm exp (2222) + $3 = nterm exp (1) +error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 69): +Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" () +Shifting token end of file () Entering state 16 -Cleanup: popping token "end of input" () +Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 18 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 27 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Error: popping token '=' (1.3: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '=' (1.7: ) +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 30 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 9 (line 105): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 14 +Reducing stack 0 by rule 17 (line 121): + $1 = token '!' () + $2 = token '+' () +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) +./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +571. calc.at:1504: testing Calculator lalr1.d ... +./calc.at:1504: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y input: -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1//2 -./calc.at:1485: "$PERL" -pi -e 'use strict; +./calc.at:1494: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.cc calc.y + | 1 + 2 * 3 + !- ++ +./calc.at:1485: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 30 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 9 (line 105): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 13 +Reducing stack 0 by rule 18 (line 122): + $1 = token '!' () + $2 = token '-' () +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -202952,10 +205887,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stdout: -./calc.at:1487: $PREPARSER ./calc input stderr: -input: +stderr: Starting parse Entering state 0 Reading a token @@ -202975,18 +205908,7 @@ syntax error, unexpected '+' Error: popping nterm input () Cleanup: discarding lookahead token '+' () -./calc.at:1489: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc - -./calc.at:1482: "$PERL" -pi -e 'use strict; +./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -202996,9 +205918,118 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1485: cat stderr +./calc.at:1491: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 15 +Reducing stack 0 by rule 16 (line 120): + $1 = token '!' () + $2 = token '!' () +Shifting token error () +Entering state 11 +Reading a token +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token number (2) +syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token number (2) +Error: discarding token number (2) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (1) +error: 2222 != 1 +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token @@ -203010,23 +206041,629 @@ -> $$ = nterm exp (1) Entering state 8 Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 30 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 9 (line 105): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 13 +Reducing stack 0 by rule 18 (line 122): + $1 = token '!' () + $2 = token '-' () +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) +input: +./calc.at:1489: cat stderr +571. calc.at:1504: | + | +1 +./calc.at:1491: $PREPARSER ./calc input +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + skipped (calc.at:1504) +./calc.at:1487: cat stderr +stderr: +./calc.at:1486: cat stderr +input: + | (1 + 1) / (1 - 1) +./calc.at:1489: $PREPARSER ./calc input +./calc.at:1486: $PREPARSER ./calc /dev/null +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Cleanup: discarding lookahead token '+' (2.1: ) +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Now at end of input. +syntax error, unexpected end of input +Cleanup: discarding lookahead token end of input () +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 29 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (2) + $3 = token ')' () +-> $$ = nterm exp (2) +Entering state 8 +Reading a token Next token is token '/' () Shifting token '/' () Entering state 22 Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 28 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (1) +-> $$ = nterm exp (0) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (0) + $3 = token ')' () +-> $$ = nterm exp (0) +Entering state 31 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 10 (line 93): + $1 = nterm exp (2) + $2 = token '/' () + $3 = nterm exp (0) +error: null divisor +-> $$ = nterm exp (2) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1485: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 29 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (2) + $3 = token ')' () +-> $$ = nterm exp (2) +Entering state 8 +Reading a token Next token is token '/' () -syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) -Error: popping token '/' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '/' () +Shifting token '/' () +Entering state 22 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token "number" (1) +Shifting token "number" (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1) +-> $$ = nterm exp (1) +Entering state 28 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (1) +-> $$ = nterm exp (0) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (0) + $3 = token ')' () +-> $$ = nterm exp (0) +Entering state 31 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 10 (line 93): + $1 = nterm exp (2) + $2 = token '/' () + $3 = nterm exp (0) +error: null divisor +-> $$ = nterm exp (2) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" () +Entering state 16 +Cleanup: popping token "end of input" () +Cleanup: popping nterm input () +./calc.at:1494: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o calc calc.cc calc-lex.cc calc-main.cc $LIBS +./calc.at:1485: cat stderr stderr: -./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1//2 -./calc.at:1491: $PREPARSER ./calc input +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + +input: input: Starting parse Entering state 0 Reading a token +Now at end of input. +syntax error, unexpected end of input +Cleanup: discarding lookahead token end of input () + | (- *) + (1 2) = 1 + | (#) + (#) = 2222 +./calc.at:1487: $PREPARSER ./calc input +./calc.at:1485: $PREPARSER ./calc input +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token '*' () +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +Shifting token error () +Entering state 9 +Reducing stack 0 by rule 15 (line 119): + $1 = token '-' () + $2 = token error () +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token number (2) +syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token number (2) +Error: discarding token number (2) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (1) +error: 2222 != 1 +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 2 +Reading a token +Next token is token '*' () +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +Shifting token error () +Entering state 9 +Reducing stack 0 by rule 15 (line 119): + $1 = token '-' () + $2 = token error () +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token number (2) +syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token number (2) +Error: discarding token number (2) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (1) +error: 2222 != 1 +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Cleanup: discarding lookahead token '+' (2.1: ) +Starting parse +Entering state 0 +Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 @@ -203043,7 +206680,7 @@ Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () @@ -203070,7 +206707,7 @@ Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () @@ -203078,7 +206715,7 @@ Entering state 29 Reading a token Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): +Reducing stack 0 by rule 7 (line 103): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) @@ -203088,16 +206725,16 @@ Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (2222) -Shifting token "number" (2222) +Next token is token number (2222) +Shifting token number (2222) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2222) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2222) -> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (2222) @@ -203106,21 +206743,306 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 69): +Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" () +Shifting token end of file () Entering state 16 -Cleanup: popping token "end of input" () +Cleanup: popping token end of file () +Cleanup: popping nterm input () +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1489: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1487: cat stderr +572. calc.at:1509: testing Calculator D ... +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1489: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (2222) +Shifting token number (2222) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2222) +-> $$ = nterm exp (2222) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (2222) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (2222) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +./calc.at:1509: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y +stderr: +563. calc.at:1489: ok +stdout: +./calc.at:1489: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc + +input: + | (* *) + (*) + (*) +./calc.at:1487: $PREPARSER ./calc input +./calc.at:1486: cat stderr +./calc.at:1491: cat stderr +input: +input: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1486: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (2222) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (3333) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (3333) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () Cleanup: popping nterm input () +./calc.at:1491: $PREPARSER ./calc /dev/null +./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1485: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -203138,35 +207060,241 @@ stderr: stderr: stderr: -input: Starting parse Entering state 0 Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token ')' () +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (2) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (3) +Entering state 12 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token ')' () +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' () +Error: popping nterm exp (3) +Shifting token error () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 +Next token is token '(' () +Shifting token '(' () +Entering state 4 Reading a token -Next token is token '/' () -syntax error on token ['/'] (expected: [number] ['-'] ['('] ['!']) -Error: popping token '/' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '/' () -Starting parse -Entering state 0 +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (2222) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (3333) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 30 +Reading a token +Next token is token '*' () +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1) + $2 = token '*' () + $3 = nterm exp (2) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' () +Error: popping nterm exp (2) +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (3333) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (4444) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 27 Reading a token Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (4444) + $2 = token '=' () + $3 = nterm exp (1) +error: 4444 != 1 +-> $$ = nterm exp (4444) +Entering state 8 +Next token is token '\n' () Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (4444) + $2 = token '\n' () -> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -203174,34 +207302,12 @@ -> $$ = nterm input () Entering state 6 Reading a token -Next token is token '+' () -syntax error, unexpected '+' -Error: popping nterm input () -Cleanup: discarding lookahead token '+' () -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 22 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.3: ) -stderr: -./calc.at:1482: cat stderr - | (- *) + (1 2) = 1 -./calc.at:1485: $PREPARSER ./calc input +Now at end of input. +Shifting token end of input () +Entering state 16 +Cleanup: popping token end of input () +Cleanup: popping nterm input () +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -204039,11 +208145,12 @@ Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: - | (# + 1) = 1111 -./calc.at:1482: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Now at end of input. +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token "end of input" (1.1: ) Starting parse Entering state 0 Reading a token @@ -204051,17 +208158,72 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 +Next token is token '*' () +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () Reading a token Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () -Entering state 9 -Reducing stack 0 by rule 15 (line 119): - $1 = token '-' () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) Shifting token error () Entering state 11 Next token is token '*' () @@ -204077,6 +208239,60 @@ $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (2222) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (3333) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (3333) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +./calc.at:1485: cat stderr +input: + | (1 + #) = 1111 +./calc.at:1485: $PREPARSER ./calc input +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: + +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token ')' () +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '+' () @@ -204090,25 +208306,170 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): +Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token -Next token is token number (2) -syntax error, unexpected number -Error: popping nterm exp (1) +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (2) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (3) +Entering state 12 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token ')' () +syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' () +Error: popping nterm exp (3) +Shifting token error () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 29 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (2222) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (3333) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token Next token is token number (2) -Error: discarding token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 30 +Reading a token +Next token is token '*' () +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1) + $2 = token '*' () + $3 = nterm exp (2) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' () +Error: popping nterm exp (2) +Shifting token error () +Entering state 11 +Next token is token '*' () +Error: discarding token '*' () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 118): +Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () @@ -204116,11 +208477,11 @@ Entering state 29 Reading a token Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (3333) $2 = token '+' () $3 = nterm exp (1111) --> $$ = nterm exp (2222) +-> $$ = nterm exp (4444) Entering state 8 Next token is token '=' () Shifting token '=' () @@ -204129,51 +208490,38 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): +Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (2222) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (4444) $2 = token '=' () $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) +error: 4444 != 1 +-> $$ = nterm exp (4444) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2222) +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (4444) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 82): +Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token end of file () +Shifting token end of input () Entering state 16 -Cleanup: popping token end of file () +Cleanup: popping token end of input () Cleanup: popping nterm input () stderr: -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -204181,25 +208529,33 @@ Shifting token '(' () Entering state 4 Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token syntax error: invalid character: '#' Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token "number" (1) -Error: discarding token "number" (1) -Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () @@ -204210,16 +208566,16 @@ Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (1111) -Shifting token "number" (1111) +Next token is token number (1111) +Shifting token number (1111) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1111) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) @@ -204228,42 +208584,29 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 69): +Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" () +Shifting token end of file () Entering state 16 -Cleanup: popping token "end of input" () +Cleanup: popping token end of file () Cleanup: popping nterm input () -Starting parse +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +572. calc.at:1509: Starting parse Entering state 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 22 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.3: ) -./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Now at end of input. +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token "end of input" (1.1: ) Starting parse Entering state 0 Reading a token @@ -205100,8 +209443,12 @@ Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () +./calc.at:1487: cat stderr stderr: + skipped (calc.at:1509) input: +input: + | 1 2 ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -205112,6 +209459,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1489: $PREPARSER ./calc input + | 1 + 2 * 3 + !+ ++ +./calc.at:1487: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -205119,42 +209469,6 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 9 -Reducing stack 0 by rule 15 (line 119): - $1 = token '-' () - $2 = token error () -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 @@ -205163,13 +209477,18 @@ -> $$ = nterm exp (1) Entering state 12 Reading a token -Next token is token number (2) -syntax error, unexpected number +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 -Next token is token number (2) -Error: discarding token number (2) +Next token is token error () +Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 @@ -205181,104 +209500,22 @@ $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2222) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1487: cat stderr -./calc.at:1489: cat stderr - | 1 2 -stderr: -./calc.at:1489: $PREPARSER ./calc input -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token "number" (1) -Error: discarding token "number" (1) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (1111) -Shifting token "number" (1111) +Next token is token number (1111) +Shifting token number (1111) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1111) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) @@ -205287,84 +209524,89 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 69): +Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" () +Shifting token end of file () Entering state 16 -Cleanup: popping token "end of input" () +Cleanup: popping token end of file () Cleanup: popping nterm input () stderr: -./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token Next token is token number (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Cleanup: discarding lookahead token number (2) -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -input: -./calc.at:1491: cat stderr -./calc.at:1486: $PREPARSER ./calc /dev/null -stderr: - | error -stderr: - | (1 + #) = 1111 -./calc.at:1487: $PREPARSER ./calc input -./calc.at:1489: $PREPARSER ./calc input -Starting parse -Entering state 0 +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token number (3) +Shifting token number (3) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 30 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 9 (line 105): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '+' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token -Next token is token number (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Cleanup: discarding lookahead token number (2) -Starting parse -Entering state 0 +Next token is token '!' () +Shifting token '!' () +Entering state 5 Reading a token -Now at end of input. -syntax error, unexpected end of input -Cleanup: discarding lookahead token end of input () -stderr: -stderr: -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1485: "$PERL" -pi -e 'use strict; +Next token is token '+' () +Shifting token '+' () +Entering state 14 +Reducing stack 0 by rule 17 (line 121): + $1 = token '!' () + $2 = token '+' () +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) +./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -205374,14 +209616,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -Starting parse -Entering state 0 -Reading a token -Next token is token invalid token () -syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) -Cleanup: discarding lookahead token invalid token () -./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1482: "$PERL" -pi -e 'use strict; +./calc.at:1486: cat stderr +stderr: +./calc.at:1491: cat stderr +./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -205391,368 +209629,95 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) + $1 = token number (1) -> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token "number" (1111) -Shifting token "number" (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1111) --> $$ = nterm exp (1111) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () -input: +Next token is token number (2) +syntax error, unexpected number +Error: popping nterm exp (1) +Cleanup: discarding lookahead token number (2) ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | error -./calc.at:1491: $PREPARSER ./calc input -stderr: -./calc.at:1485: cat stderr -Starting parse -Entering state 0 -Reading a token -Now at end of input. -syntax error, unexpected end of input -Cleanup: discarding lookahead token end of input () stderr: +input: + + | (!!) + (1 2) = 1 +./calc.at:1486: $PREPARSER ./calc input stderr: stderr: Starting parse Entering state 0 Reading a token -Next token is token invalid token () -syntax error on token [invalid token] (expected: [number] ['-'] ['\n'] ['('] ['!']) -Cleanup: discarding lookahead token invalid token () -Starting parse -Entering state 0 -Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" (1.1: ) -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (1) +Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) -> $$ = nterm exp (1) -Entering state 12 +Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token "number" (1111) -Shifting token "number" (1111) +Next token is token number (2) +Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1111) --> $$ = nterm exp (1111) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1482: cat stderr - | (* *) + (*) + (*) -./calc.at:1485: $PREPARSER ./calc input -./calc.at:1489: cat stderr -stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" (1.1: ) -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Reducing stack 0 by rule 5 (line 92): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 Reading a token Next token is token '*' () -Error: discarding token '*' () +Shifting token '*' () +Entering state 21 Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 30 Reading a token Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) +Reducing stack 0 by rule 9 (line 105): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) Entering state 29 -Reading a token Next token is token '+' () Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) + $1 = nterm exp (1) $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) + $3 = nterm exp (6) +-> $$ = nterm exp (7) Entering state 8 Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 +Next token is token '!' () +Shifting token '!' () +Entering state 5 Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (2222) +Next token is token '+' () +Shifting token '+' () +Entering state 14 +Reducing stack 0 by rule 17 (line 121): + $1 = token '!' () $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (3333) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (3333) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1487: cat stderr - | (1 + # + 1) = 1111 -./calc.at:1482: $PREPARSER ./calc input -input: -stderr: -./calc.at:1486: cat stderr -./calc.at:1489: cat stderr -stderr: - | 1//2 -./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1489: $PREPARSER ./calc input +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) Starting parse Entering state 0 Reading a token @@ -205760,62 +209725,29 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 +Next token is token '!' () +Shifting token '!' () +Entering state 5 Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Next token is token '!' () +Shifting token '!' () +Entering state 15 +Reducing stack 0 by rule 16 (line 107): + $1 = token '!' () + $2 = token '!' () Shifting token error () Entering state 11 -Next token is token '*' () -Error: discarding token '*' () Reading a token Next token is token ')' () -Entering state 11 -Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 118): +Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) Entering state 8 +Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 @@ -205824,197 +209756,21 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (2222) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (3333) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (3333) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token "number" (1) -Error: discarding token "number" (1) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token "number" (1111) -Shifting token "number" (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1111) --> $$ = nterm exp (1111) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () -./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: -./calc.at:1491: cat stderr -Starting parse -Entering state 0 -Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '/' () -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '/' () -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 = 2 = 3 -input: -stderr: -./calc.at:1487: $PREPARSER ./calc input -input: - | (# + 1) = 1111 -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) Entering state 12 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () +Next token is token number (2) +syntax error, unexpected number Error: popping nterm exp (1) Shifting token error () Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token "number" (1) -Error: discarding token "number" (1) +Next token is token number (2) +Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 @@ -206026,138 +209782,40 @@ $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 8 +Entering state 29 Reading a token Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token "number" (1111) -Shifting token "number" (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1111) --> $$ = nterm exp (1111) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) - $2 = token '=' () + $2 = token '+' () $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () -./calc.at:1489: $PREPARSER ./calc input -stderr: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -stderr: -./calc.at:1486: $PREPARSER ./calc input -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 27 -Reading a token -Next token is token '=' () -syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) -Error: popping nterm exp (2) -Error: popping token '=' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '=' () -./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token "number" (1) -Error: discarding token "number" (1) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) +-> $$ = nterm exp (2222) Entering state 8 -Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (1111) -Shifting token "number" (1111) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1111) --> $$ = nterm exp (1111) + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) + $1 = nterm exp (2222) $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) + $3 = nterm exp (1) +error: 2222 != 1 +-> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) + $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -206167,12 +209825,11 @@ Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" () +Shifting token end of input () Entering state 16 -Cleanup: popping token "end of input" () +Cleanup: popping token end of input () Cleanup: popping nterm input () -input: -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -206184,15 +209841,14 @@ -> $$ = nterm exp (1) Entering state 8 Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '/' () -syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' () +Next token is token number (2) +syntax error, unexpected number Error: popping nterm exp (1) -Cleanup: discarding lookahead token '/' () +Cleanup: discarding lookahead token number (2) +input: +stderr: +input: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 Starting parse Entering state 0 Reading a token @@ -206200,125 +209856,20 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token ')' () -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (2) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (3) -Entering state 12 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token ')' () -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' () -Error: popping nterm exp (3) -Shifting token error () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 +Next token is token '!' () +Shifting token '!' () +Entering state 5 Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Next token is token '!' () +Shifting token '!' () +Entering state 15 +Reducing stack 0 by rule 16 (line 107): + $1 = token '!' () + $2 = token '!' () Shifting token error () Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token '*' () -Error: discarding token '*' () Reading a token Next token is token ')' () -Entering state 11 -Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): @@ -206326,15 +209877,8 @@ $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (2222) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (3333) Entering state 8 +Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 @@ -206351,37 +209895,13 @@ -> $$ = nterm exp (1) Entering state 12 Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 30 -Reading a token -Next token is token '*' () -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1) - $2 = token '*' () - $3 = nterm exp (2) --> $$ = nterm exp (2) -Entering state 12 -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' () -Error: popping nterm exp (2) +syntax error, unexpected number +Error: popping nterm exp (1) Shifting token error () Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token number (2) +Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 @@ -206397,10 +209917,10 @@ Reading a token Next token is token '=' () Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (3333) + $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) --> $$ = nterm exp (4444) +-> $$ = nterm exp (2222) Entering state 8 Next token is token '=' () Shifting token '=' () @@ -206416,17 +209936,17 @@ Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (4444) + $1 = nterm exp (2222) $2 = token '=' () $3 = nterm exp (1) -error: 4444 != 1 --> $$ = nterm exp (4444) +error: 2222 != 1 +-> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (4444) + $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -206440,557 +209960,261 @@ Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () - | 1 = 2 = 3 -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: $PREPARSER ./calc input -./calc.at:1485: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -stderr: +573. calc.at:1510: testing Calculator D %locations ... + | 1 + 2 * 3 + !- ++ stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 27 -Reading a token -Next token is token '=' () -syntax error on token ['='] (expected: ['-'] ['+'] ['*'] ['/'] ['^']) -Error: popping nterm exp (2) -Error: popping token '=' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '=' () -./calc.at:1485: cat stderr -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 18 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 27 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Error: popping token '=' (1.3: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '=' (1.7: ) -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token "number" (1) -Error: discarding token "number" (1) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token "number" (1111) -Shifting token "number" (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1111) --> $$ = nterm exp (1111) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () +./calc.at:1510: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y +input: +./calc.at:1487: $PREPARSER ./calc input stderr: -./calc.at:1482: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token ')' () -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error () +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) Entering state 11 -Next token is token ')' () -Shifting token ')' () +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token -Next token is token '+' () -Shifting token '+' () +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) Entering state 20 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1.7: 1) +Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) + $1 = token "number" (1.7: 1) +-> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token -Next token is token '+' () -Shifting token '+' () +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) Entering state 20 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1.11: 1) +Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) + $1 = token "number" (1.11: 1) +-> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token -Next token is token '+' () +Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) Entering state 12 -Next token is token '+' () -Shifting token '+' () +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) Entering state 20 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1.15: 1) +Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) + $1 = token "number" (1.15: 1) +-> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token -Next token is token '+' () +Next token is token '+' (1.17: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (2) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (3) + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) Entering state 12 -Next token is token '+' () -Shifting token '+' () +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) Entering state 20 Reading a token -Next token is token ')' () -syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' () -Error: popping nterm exp (3) -Shifting token error () +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Error: popping nterm exp (1.7-15: 3) +Shifting token error (1.7-18: ) Entering state 11 -Next token is token ')' () -Shifting token ')' () +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token -Next token is token '+' () +Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) Entering state 8 -Next token is token '+' () -Shifting token '+' () +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) Entering state 20 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) Entering state 4 Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) Reading a token -Next token is token '*' () -Error: discarding token '*' () +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) Reading a token -Next token is token '*' () -Error: discarding token '*' () +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) Reading a token -Next token is token ')' () +Next token is token ')' (1.28: ) Entering state 11 -Next token is token ')' () -Shifting token ')' () +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token -Next token is token '+' () +Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (2222) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (3333) + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) Entering state 8 -Next token is token '+' () -Shifting token '+' () +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) Entering state 20 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1.33: 1) +Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) + $1 = token "number" (1.33: 1) +-> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token -Next token is token '*' () -Shifting token '*' () +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) Entering state 21 Reading a token -Next token is token number (2) -Shifting token number (2) +Next token is token "number" (1.37: 2) +Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (2) --> $$ = nterm exp (2) + $1 = token "number" (1.37: 2) +-> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token -Next token is token '*' () +Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1) - $2 = token '*' () - $3 = nterm exp (2) --> $$ = nterm exp (2) + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) Entering state 12 -Next token is token '*' () -Shifting token '*' () +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) Entering state 21 Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' () -Error: popping nterm exp (2) -Shifting token error () +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Error: popping nterm exp (1.33-37: 2) +Shifting token error (1.33-41: ) Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) Reading a token -Next token is token ')' () +Next token is token ')' (1.42: ) Entering state 11 -Next token is token ')' () -Shifting token ')' () +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token -Next token is token '=' () +Next token is token '=' (1.44: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (3333) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (4444) + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) Entering state 8 -Next token is token '=' () -Shifting token '=' () +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) Entering state 18 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1.46: 1) +Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) + $1 = token "number" (1.46: 1) +-> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token -Next token is token '\n' () +Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (4444) - $2 = token '=' () - $3 = nterm exp (1) -error: 4444 != 1 --> $$ = nterm exp (4444) + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) Entering state 8 -Next token is token '\n' () -Shifting token '\n' () +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (4444) - $2 = token '\n' () --> $$ = nterm line () + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) +-> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. -Shifting token end of input () +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: - | 1 + 2 * 3 + !+ ++ -stderr: -./calc.at:1485: $PREPARSER ./calc input -./calc.at:1489: cat stderr -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 18 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 27 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Error: popping token '=' (1.3: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '=' (1.7: ) -stderr: -./calc.at:1487: cat stderr -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1482: cat stderr -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 30 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) -Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 14 -Reducing stack 0 by rule 17 (line 121): - $1 = token '!' () - $2 = token '+' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1489: cat stderr -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -input: -input: -stderr: -./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token @@ -207048,39 +210272,19 @@ Shifting token '!' () Entering state 5 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 14 -Reducing stack 0 by rule 17 (line 121): +Next token is token '-' () +Shifting token '-' () +Entering state 13 +Reducing stack 0 by rule 18 (line 122): $1 = token '!' () - $2 = token '+' () + $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) - | (1 + 1) / (1 - 1) - | error -./calc.at:1489: $PREPARSER ./calc input - | - | +1 -./calc.at:1482: $PREPARSER ./calc input -./calc.at:1487: $PREPARSER ./calc input -./calc.at:1486: cat stderr -stderr: -input: -input: - | (1 + # + 1) = 1111 -stderr: - | 1 + 2 * 3 + !- ++ -./calc.at:1489: $PREPARSER ./calc input -stderr: +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (# + 1) = 1111 ./calc.at:1485: $PREPARSER ./calc input -./calc.at:1491: cat stderr -Starting parse -Entering state 0 -Reading a token -Next token is token invalid token () -syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token () -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: Starting parse Entering state 0 Reading a token @@ -207088,137 +210292,90 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () Reading a token Next token is token '+' () -Shifting token '+' () -Entering state 20 +Error: discarding token '+' () Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 29 +Next token is token number (1) +Error: discarding token number (1) Reading a token Next token is token ')' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 +Entering state 11 Next token is token ')' () Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): +Entering state 25 +Reducing stack 0 by rule 14 (line 118): $1 = token '(' () - $2 = nterm exp (2) + $2 = token error () $3 = token ')' () --> $$ = nterm exp (2) +-> $$ = nterm exp (1111) Entering state 8 Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 +Next token is token '=' () +Shifting token '=' () +Entering state 18 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (1111) +Shifting token number (1111) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 28 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (1) --> $$ = nterm exp (0) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (0) - $3 = token ')' () --> $$ = nterm exp (0) -Entering state 31 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1111) +-> $$ = nterm exp (1111) +Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (2) - $2 = token '/' () - $3 = nterm exp (0) -error: null divisor --> $$ = nterm exp (2) +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2) +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 69): +Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" () +Shifting token end of file () Entering state 16 -Cleanup: popping token "end of input" () +Cleanup: popping token end of file () Cleanup: popping nterm input () +./calc.at:1489: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -./calc.at:1482: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '+' () -syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) -Error: popping nterm input () -Cleanup: discarding lookahead token '+' () -./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 @@ -207288,119 +210445,257 @@ Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Reading a token +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Reading a token +Next token is token "number" (1.7: 1) +Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) + $1 = token "number" (1.7: 1) +-> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token -Next token is token '+' () -Shifting token '+' () +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) Entering state 20 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token "number" (1.11: 1) +Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) + $1 = token "number" (1.11: 1) +-> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token -Next token is token ')' () +Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (2) - $3 = token ')' () --> $$ = nterm exp (2) +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 20 +Reading a token +Next token is token "number" (1.15: 1) +Shifting token "number" (1.15: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 29 +Reading a token +Next token is token '+' (1.17: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 20 +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Error: popping nterm exp (1.7-15: 3) +Shifting token error (1.7-18: ) +Entering state 11 +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 29 +Reading a token +Next token is token '+' (1.20: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) Entering state 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 20 Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) +Entering state 11 +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) +Reading a token +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Reading a token +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Reading a token +Next token is token ')' (1.28: ) +Entering state 11 +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 29 +Reading a token +Next token is token '+' (1.30: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) +Entering state 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +Entering state 20 +Reading a token +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) Entering state 4 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token "number" (1.33: 1) +Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) + $1 = token "number" (1.33: 1) +-> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 21 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token "number" (1.37: 2) +Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 28 + $1 = token "number" (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 30 Reading a token -Next token is token ')' () -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (1) --> $$ = nterm exp (0) +Next token is token '*' (1.39: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (0) - $3 = token ')' () --> $$ = nterm exp (0) -Entering state 31 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 21 Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (2) - $2 = token '/' () - $3 = nterm exp (0) -error: null divisor --> $$ = nterm exp (2) +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Error: popping nterm exp (1.33-37: 2) +Shifting token error (1.33-41: ) +Entering state 11 +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) +Reading a token +Next token is token ')' (1.42: ) +Entering state 11 +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) +Entering state 29 +Reading a token +Next token is token '=' (1.44: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) Entering state 8 -Next token is token '\n' () -Shifting token '\n' () +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) +Entering state 18 +Reading a token +Next token is token "number" (1.46: 1) +Shifting token "number" (1.46: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.46: 1) +-> $$ = nterm exp (1.46: 1) +Entering state 27 +Reading a token +Next token is token '\n' (1.47-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) +Entering state 8 +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2) - $2 = token '\n' () --> $$ = nterm line () + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) +-> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" () +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1489: cat stderr +./calc.at:1486: cat stderr +input: +stderr: + | 1//2 +input: +./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -207408,22 +210703,8 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token syntax error: invalid character: '#' Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () @@ -207432,15 +210713,15 @@ Next token is token '+' () Error: discarding token '+' () Reading a token -Next token is token "number" (1) -Error: discarding token "number" (1) +Next token is token number (1) +Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () @@ -207451,16 +210732,16 @@ Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (1111) -Shifting token "number" (1111) +Next token is token number (1111) +Shifting token number (1111) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1111) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): +Reducing stack 0 by rule 6 (line 93): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) @@ -207469,119 +210750,59 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): +Reducing stack 0 by rule 4 (line 88): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 69): +Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" () +Shifting token end of file () Entering state 16 -Cleanup: popping token "end of input" () +Cleanup: popping token end of file () Cleanup: popping nterm input () -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -stderr: -stderr: - | (!!) + (1 2) = 1 -Starting parse -Entering state 0 -Reading a token -Next token is token invalid token () -syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token () -./calc.at:1486: $PREPARSER ./calc input -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 87): - $1 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '+' () -syntax error on token ['+'] (expected: [end of file] [number] ['-'] ['\n'] ['('] ['!']) -Error: popping nterm input () -Cleanup: discarding lookahead token '+' () stderr: -input: Starting parse Entering state 0 Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): +Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 8 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 30 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) -Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 +Next token is token '/' () +Shifting token '/' () +Entering state 22 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 13 -Reducing stack 0 by rule 18 (line 122): - $1 = token '!' () - $2 = token '-' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) +Next token is token '/' () +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '/' () +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +574. calc.at:1512: testing Calculator D parse.error=detailed api.prefix={calc} %verbose ... +./calc.at:1512: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y +./calc.at:1487: cat stderr + | (- *) + (1 2) = 1 +./calc.at:1491: cat stderr +./calc.at:1486: $PREPARSER ./calc input stderr: stderr: Starting parse @@ -207591,20 +210812,25 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 +Next token is token '-' () +Shifting token '-' () +Entering state 2 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 15 -Reducing stack 0 by rule 16 (line 107): - $1 = token '!' () - $2 = token '!' () +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 9 +Reducing stack 0 by rule 15 (line 106): + $1 = token '-' () + $2 = token error () Shifting token error () Entering state 11 +Next token is token '*' () +Error: discarding token '*' () Reading a token Next token is token ')' () +Entering state 11 +Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): @@ -207695,114 +210921,35 @@ Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () - | - | +1 Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) + $1 = token number (1) -> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token "number" (1) -Error: discarding token "number" (1) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) Entering state 8 Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token "number" (1111) -Shifting token "number" (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1111) --> $$ = nterm exp (1111) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 +Next token is token '/' () +Shifting token '/' () +Entering state 22 Reading a token -Now at end of input. -Shifting token "end of input" () -Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () +Next token is token '/' () +syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '/' () ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1491: $PREPARSER ./calc input +573. calc.at:1510: input: + skipped (calc.at:1510) +input: + | (#) + (#) = 2222 stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Cleanup: discarding lookahead token '+' (2.1: ) -./calc.at:1482: "$PERL" -pi -e 'use strict; + | (!!) + (1 2) = 1 +./calc.at:1487: $PREPARSER ./calc input +./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -207812,6 +210959,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1491: $PREPARSER ./calc input stderr: Starting parse Entering state 0 @@ -207820,20 +210968,25 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 +Next token is token '-' () +Shifting token '-' () +Entering state 2 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 15 -Reducing stack 0 by rule 16 (line 107): - $1 = token '!' () - $2 = token '!' () +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error () +Entering state 9 +Reducing stack 0 by rule 15 (line 106): + $1 = token '-' () + $2 = token error () Shifting token error () Entering state 11 +Next token is token '*' () +Error: discarding token '*' () Reading a token Next token is token ')' () +Entering state 11 +Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): @@ -207924,113 +211077,7 @@ Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1487: cat stderr -./calc.at:1485: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1482: cat stderr -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1487: $PREPARSER ./calc /dev/null -./calc.at:1489: cat stderr -./calc.at:1485: cat stderr -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Cleanup: discarding lookahead token '+' (2.1: ) -Starting parse -Entering state 0 -Reading a token -Now at end of input. -syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) -Cleanup: discarding lookahead token end of file () -./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1489: cat stderr -557. calc.at:1482: ok -stderr: -input: -input: -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Reading a token -Now at end of input. -syntax error on token [end of file] (expected: [number] ['-'] ['\n'] ['('] ['!']) -Cleanup: discarding lookahead token end of file () - | 1 = 2 = 3 - | (#) + (#) = 2222 -./calc.at:1485: $PREPARSER ./calc input -./calc.at:1489: $PREPARSER ./calc input -stderr: -./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -stderr: -stdout: - | (1 + 1) / (1 - 1) stderr: -./calc.at:1486: cat stderr -./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -208128,190 +211175,135 @@ Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () -./calc.at:1492: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc calc.hh - -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +./calc.at:1485: cat stderr Starting parse Entering state 0 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 27 +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 15 +Reducing stack 0 by rule 16 (line 107): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Shifting token error (1.2-3: ) +Entering state 11 Reading a token -Next token is token '=' () -syntax error, unexpected '=' -Error: popping nterm exp (2) -Error: popping token '=' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '=' () -./calc.at:1491: cat stderr -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) +Entering state 8 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) +Entering state 20 +Reading a token +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) Entering state 4 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token "number" (1.9: 1) +Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) + $1 = token "number" (1.9: 1) +-> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Next token is token "number" (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Shifting token error (1.9-11: ) +Entering state 11 +Next token is token "number" (1.11: 2) +Error: discarding token "number" (1.11: 2) Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) +Next token is token ')' (1.12: ) +Entering state 11 +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token -Next token is token ')' () +Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (2) - $3 = token ')' () --> $$ = nterm exp (2) + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) Entering state 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) +Entering state 18 Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 28 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (1) --> $$ = nterm exp (0) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (0) - $3 = token ')' () --> $$ = nterm exp (0) -Entering state 31 + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 27 Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (2) - $2 = token '/' () - $3 = nterm exp (0) -error: null divisor --> $$ = nterm exp (2) +Next token is token '\n' (1.17-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 -Next token is token '\n' () -Shifting token '\n' () +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2) - $2 = token '\n' () --> $$ = nterm line () + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" () +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token "end of input" () -Cleanup: popping nterm input () -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -input: - | (- *) + (1 2) = 1 -./calc.at:1486: $PREPARSER ./calc input -./calc.at:1487: cat stderr -./calc.at:1491: $PREPARSER ./calc /dev/null - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 +574. calc.at:1512: ./calc.at:1489: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1492: $PREPARSER ./calc input + skipped (calc.at:1512) stderr: +./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token @@ -208409,125 +211401,156 @@ Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () -stderr: -stderr: +input: Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 9 -Reducing stack 0 by rule 15 (line 106): - $1 = token '-' () - $2 = token error () -Shifting token error () +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 15 +Reducing stack 0 by rule 16 (line 107): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Shifting token error (1.2-3: ) Entering state 11 -Next token is token '*' () -Error: discarding token '*' () Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token -Next token is token '+' () -Shifting token '+' () +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) Entering state 20 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1.9: 1) +Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) + $1 = token "number" (1.9: 1) +-> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token -Next token is token number (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Shifting token error () +Next token is token "number" (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Shifting token error (1.9-11: ) Entering state 11 -Next token is token number (2) -Error: discarding token number (2) +Next token is token "number" (1.11: 2) +Error: discarding token "number" (1.11: 2) Reading a token -Next token is token ')' () +Next token is token ')' (1.12: ) Entering state 11 -Next token is token ')' () -Shifting token ')' () +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token -Next token is token '=' () +Next token is token '=' (1.14: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) Entering state 8 -Next token is token '=' () -Shifting token '=' () +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) Entering state 18 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token -Next token is token '\n' () +Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 -Next token is token '\n' () -Shifting token '\n' () +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2222) - $2 = token '\n' () --> $$ = nterm line () + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. -Shifting token end of input () +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: + | (1 + # + 1) = 1111 +./calc.at:1485: $PREPARSER ./calc input +stdout: + +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1492: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc calc.hh + +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token @@ -208535,11 +211558,11 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (1) +Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 Reading a token @@ -208547,138 +211570,179 @@ Shifting token '+' () Entering state 20 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 29 +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token number (1) +Error: discarding token number (1) Reading a token Next token is token ')' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 +Entering state 11 Next token is token ')' () Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): +Entering state 25 +Reducing stack 0 by rule 14 (line 118): $1 = token '(' () - $2 = nterm exp (2) + $2 = token error () $3 = token ')' () --> $$ = nterm exp (2) +-> $$ = nterm exp (1111) Entering state 8 Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token "number" (1) -Shifting token "number" (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 +Next token is token '=' () +Shifting token '=' () +Entering state 18 Reading a token -Next token is token "number" (1) -Shifting token "number" (1) +Next token is token number (1111) +Shifting token number (1111) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1) --> $$ = nterm exp (1) -Entering state 28 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (1) --> $$ = nterm exp (0) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (0) - $3 = token ')' () --> $$ = nterm exp (0) -Entering state 31 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1111) +-> $$ = nterm exp (1111) +Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (2) - $2 = token '/' () - $3 = nterm exp (0) -error: null divisor --> $$ = nterm exp (2) +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2) +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 69): +Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" () +Shifting token end of file () Entering state 16 -Cleanup: popping token "end of input" () +Cleanup: popping token end of file () Cleanup: popping nterm input () +./calc.at:1486: cat stderr +./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: Starting parse Entering state 0 Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token number (1) +Error: discarding token number (1) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token number (2) -Shifting token number (2) +Next token is token number (1111) +Shifting token number (1111) Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2) --> $$ = nterm exp (2) +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1111) +-> $$ = nterm exp (1111) Entering state 27 Reading a token -Next token is token '=' () -syntax error, unexpected '=' -Error: popping nterm exp (2) -Error: popping token '=' () -Error: popping nterm exp (1) -Cleanup: discarding lookahead token '=' () -stderr: -Starting parse -Entering state 0 +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 Reading a token Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" (1.1: ) +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +input: +input: +input: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1487: cat stderr +./calc.at:1492: $PREPARSER ./calc input +stderr: + | error +./calc.at:1489: $PREPARSER ./calc input + | (- *) + (1 2) = 1 +./calc.at:1491: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -209515,128 +212579,8 @@ Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -stderr: input: -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 9 -Reducing stack 0 by rule 15 (line 106): - $1 = token '-' () - $2 = token error () -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token number (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token number (2) -Error: discarding token number (2) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2222) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input () -Entering state 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1487: $PREPARSER ./calc input +stderr: ./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -209647,264 +212591,18 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -571. calc.at:1504: testing Calculator lalr1.d ... -stderr: -stderr: +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1485: cat stderr stderr: -./calc.at:1504: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token ')' () -syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -Shifting token error () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (2) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (3) -Entering state 12 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token ')' () -syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -Error: popping token '+' () -Error: popping nterm exp (3) -Shifting token error () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '*' () -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (2222) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (3333) -Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 30 -Reading a token -Next token is token '*' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (1) - $2 = token '*' () - $3 = nterm exp (2) --> $$ = nterm exp (2) -Entering state 12 -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token '*' () -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -Error: popping token '*' () -Error: popping nterm exp (2) -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (3333) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (4444) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (4444) - $2 = token '=' () - $3 = nterm exp (1) -error: 4444 != 1 --> $$ = nterm exp (4444) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (4444) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token -Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" (1.1: ) +Next token is token invalid token () +syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token () +stderr: +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -210741,134 +213439,207 @@ Entering state 16 Cleanup: popping token "end of input" (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1485: cat stderr input: -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +input: | 1 2 ./calc.at:1492: $PREPARSER ./calc input + | (* *) + (*) + (*) +./calc.at:1486: $PREPARSER ./calc input + | (1 + #) = 1111 +./calc.at:1487: $PREPARSER ./calc input +stderr: +stderr: Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token "number" (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token "number" (1.3: 2) +575. calc.at:1514: testing Calculator D %debug ... +./calc.at:1514: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token ')' () -syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -Shifting token error () +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Reading a token +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Reducing stack 0 by rule 15 (line 106): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Shifting token error (1.2-4: ) Entering state 11 -Next token is token ')' () -Shifting token ')' () +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Reading a token +Next token is token ')' (1.5: ) +Entering state 11 +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token -Next token is token '+' () -Shifting token '+' () +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) Entering state 20 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1.10: 1) +Shifting token "number" (1.10: 1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.10: 1) +-> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Next token is token "number" (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Shifting token error (1.10-12: ) +Entering state 11 +Next token is token "number" (1.12: 2) +Error: discarding token "number" (1.12: 2) Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) +Next token is token ')' (1.13: ) +Entering state 11 +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Next token is token '=' (1.15: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) +Entering state 8 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) +Entering state 18 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1.17: 1) +Shifting token "number" (1.17: 1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.17: 1) +-> $$ = nterm exp (1.17: 1) +Entering state 27 Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (2) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (3) -Entering state 12 -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) +Entering state 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 Reading a token -Next token is token ')' () -syntax error on token [')'] (expected: [number] ['-'] ['('] ['!']) -Error: popping token '+' () -Error: popping nterm exp (3) +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 16 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token invalid token () +syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token () + | (1 + 1) / (1 - 1) +./calc.at:1485: $PREPARSER ./calc input +stderr: +stderr: +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token "number" (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token "number" (1.3: 2) +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token '*' () +syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token '*' () +Error: discarding token '*' () +Reading a token +Next token is token ')' () +Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 118): +Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) Entering state 8 +Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 @@ -210878,24 +213649,18 @@ Entering state 4 Reading a token Next token is token '*' () -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () Error: discarding token '*' () Reading a token -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token '*' () -Error: discarding token '*' () -Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 118): +Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () @@ -210903,11 +213668,11 @@ Entering state 29 Reading a token Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (2222) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) --> $$ = nterm exp (3333) +-> $$ = nterm exp (2222) Entering state 8 Next token is token '+' () Shifting token '+' () @@ -210917,41 +213682,8 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 30 -Reading a token -Next token is token '*' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (1) - $2 = token '*' () - $3 = nterm exp (2) --> $$ = nterm exp (2) -Entering state 12 -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token Next token is token '*' () -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -Error: popping token '*' () -Error: popping nterm exp (2) +syntax error, unexpected '*', expecting number or '-' or '(' or '!' Shifting token error () Entering state 11 Next token is token '*' () @@ -210962,103 +213694,41 @@ Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 118): +Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (3333) +Next token is token '\n' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (2222) $2 = token '+' () $3 = nterm exp (1111) --> $$ = nterm exp (4444) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (4444) - $2 = token '=' () - $3 = nterm exp (1) -error: 4444 != 1 --> $$ = nterm exp (4444) +-> $$ = nterm exp (3333) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (4444) +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (3333) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 82): +Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token end of file () +Shifting token end of input () Entering state 16 -Cleanup: popping token end of file () +Cleanup: popping token end of input () Cleanup: popping nterm input () -stderr: -./calc.at:1489: cat stderr -./calc.at:1489: cat stderr -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token "number" (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token "number" (1.3: 2) -./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (1 + #) = 1111 -./calc.at:1485: $PREPARSER ./calc input -571. calc.at:1504: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: - skipped (calc.at:1504) +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +576. calc.at:1516: testing Calculator D parse.error=custom ... +./calc.at:1516: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y Starting parse Entering state 0 Reading a token @@ -211078,51 +213748,89 @@ Shifting token '+' () Entering state 20 Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 Reading a token Next token is token ')' () -Entering state 11 +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 Next token is token ')' () Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): +Entering state 26 +Reducing stack 0 by rule 13 (line 117): $1 = token '(' () - $2 = token error () + $2 = nterm exp (2) $3 = token ')' () --> $$ = nterm exp (1111) +-> $$ = nterm exp (2) Entering state 8 Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 +Next token is token '/' () +Shifting token '/' () +Entering state 22 Reading a token -Next token is token number (1111) -Shifting token number (1111) +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 28 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 8 (line 104): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (1) +-> $$ = nterm exp (0) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 117): + $1 = token '(' () + $2 = nterm exp (0) + $3 = token ')' () +-> $$ = nterm exp (0) +Entering state 31 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) +Reducing stack 0 by rule 10 (line 106): + $1 = nterm exp (2) + $2 = token '/' () + $3 = nterm exp (0) +error: null divisor +-> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (1111) + $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -211136,93 +213844,7 @@ Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () -563. calc.at:1489: ok ./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1486: cat stderr - | - | +1 -./calc.at:1489: $PREPARSER ./calc input -./calc.at:1491: cat stderr -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token "number" (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token "number" (1.3: 2) -./calc.at:1487: cat stderr -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '+' () -syntax error, unexpected '+' -Error: popping nterm input () -Cleanup: discarding lookahead token '+' () -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -input: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -input: -stderr: -./calc.at:1491: $PREPARSER ./calc input -stderr: -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | (* *) + (*) + (*) -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' () -Shifting token '\n' () -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Next token is token '+' () -syntax error, unexpected '+' -Error: popping nterm input () -Cleanup: discarding lookahead token '+' () - | (!!) + (1 2) = 1 -./calc.at:1487: $PREPARSER ./calc input -stderr: - -./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -211300,254 +213922,7 @@ Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Reading a token -Next token is token "number" (1.7: 1) -Shifting token "number" (1.7: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 20 -Reading a token -Next token is token "number" (1.11: 1) -Shifting token "number" (1.11: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.11: 1) --> $$ = nterm exp (1.11: 1) -Entering state 29 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 20 -Reading a token -Next token is token "number" (1.15: 1) -Shifting token "number" (1.15: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 29 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 20 -Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Error: popping nterm exp (1.7-15: 3) -Shifting token error (1.7-18: ) -Entering state 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) -Entering state 29 -Reading a token -Next token is token '+' (1.20: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) -Entering state 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) -Entering state 20 -Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) -Reading a token -Next token is token ')' (1.28: ) -Entering state 11 -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 29 -Reading a token -Next token is token '+' (1.30: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) -Entering state 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) -Entering state 20 -Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) -Entering state 4 -Reading a token -Next token is token "number" (1.33: 1) -Shifting token "number" (1.33: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 21 -Reading a token -Next token is token "number" (1.37: 2) -Shifting token "number" (1.37: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.39: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) -Entering state 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 21 -Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Error: popping nterm exp (1.33-37: 2) -Shifting token error (1.33-41: ) -Entering state 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Reading a token -Next token is token ')' (1.42: ) -Entering state 11 -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.44: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) -Entering state 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) -Entering state 18 -Reading a token -Next token is token "number" (1.46: 1) -Shifting token "number" (1.46: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.46: 1) --> $$ = nterm exp (1.46: 1) -Entering state 27 -Reading a token -Next token is token '\n' (1.47-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) -Entering state 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -stderr: +./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 @@ -211664,121 +214039,135 @@ Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () +stderr: +stderr: +stderr: +./calc.at:1492: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 15 -Reducing stack 0 by rule 16 (line 120): - $1 = token '!' () - $2 = token '!' () -Shifting token error () +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Reducing stack 0 by rule 15 (line 106): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Shifting token error (1.2-4: ) Entering state 11 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) Reading a token -Next token is token ')' () -Shifting token ')' () +Next token is token ')' (1.5: ) +Entering state 11 +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token -Next token is token '+' () -Shifting token '+' () +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) Entering state 20 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1.10: 1) +Shifting token "number" (1.10: 1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.10: 1) +-> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token -Next token is token number (2) -syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -Error: popping nterm exp (1) -Shifting token error () +Next token is token "number" (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Shifting token error (1.10-12: ) Entering state 11 -Next token is token number (2) -Error: discarding token number (2) +Next token is token "number" (1.12: 2) +Error: discarding token "number" (1.12: 2) Reading a token -Next token is token ')' () +Next token is token ')' (1.13: ) Entering state 11 -Next token is token ')' () -Shifting token ')' () +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) +Next token is token '=' (1.15: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) Entering state 8 -Next token is token '=' () -Shifting token '=' () +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) Entering state 18 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1.17: 1) +Shifting token "number" (1.17: 1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.17: 1) +-> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) Entering state 8 -Next token is token '\n' () -Shifting token '\n' () +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2222) - $2 = token '\n' () --> $$ = nterm line () +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. -Shifting token end of file () +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token @@ -211786,32 +214175,46 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 15 -Reducing stack 0 by rule 16 (line 120): - $1 = token '!' () - $2 = token '!' () -Shifting token error () -Entering state 11 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 Reading a token Next token is token ')' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token ')' () Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): +Entering state 26 +Reducing stack 0 by rule 13 (line 117): $1 = token '(' () - $2 = token error () + $2 = nterm exp (2) $3 = token ')' () --> $$ = nterm exp (1111) +-> $$ = nterm exp (2) Entering state 8 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Next token is token '/' () +Shifting token '/' () +Entering state 22 Reading a token Next token is token '(' () Shifting token '(' () @@ -211825,36 +214228,9 @@ -> $$ = nterm exp (1) Entering state 12 Reading a token -Next token is token number (2) -syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token number (2) -Error: discarding token number (2) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 +Next token is token '-' () +Shifting token '-' () +Entering state 19 Reading a token Next token is token number (1) Shifting token number (1) @@ -211862,21 +214238,38 @@ Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) -Entering state 27 +Entering state 28 Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (2222) - $2 = token '=' () +Next token is token ')' () +Reducing stack 0 by rule 8 (line 104): + $1 = nterm exp (1) + $2 = token '-' () $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) +-> $$ = nterm exp (0) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 117): + $1 = token '(' () + $2 = nterm exp (0) + $3 = token ')' () +-> $$ = nterm exp (0) +Entering state 31 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 10 (line 106): + $1 = nterm exp (2) + $2 = token '/' () + $3 = nterm exp (0) +error: null divisor +-> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2222) + $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -211890,373 +214283,84 @@ Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () -./calc.at:1492: cat stderr -stderr: -Starting parse +575. calc.at:1514: Starting parse Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) Shifting token error () Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token error () +Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Reducing stack 0 by rule 14 (line 118): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 Reading a token -Next token is token '*' () -syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token '=' () +Shifting token '=' () +Entering state 18 Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () +Next token is token number (1111) +Shifting token number (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1111) -> $$ = nterm exp (1111) -Entering state 29 +Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (2222) - $2 = token '+' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (1111) + $2 = token '=' () $3 = nterm exp (1111) --> $$ = nterm exp (3333) +-> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (3333) +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 69): +Reducing stack 0 by rule 1 (line 82): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token end of input () +Shifting token end of file () Entering state 16 -Cleanup: popping token end of input () +Cleanup: popping token end of file () Cleanup: popping nterm input () - -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Reading a token -Next token is token "number" (1.7: 1) -Shifting token "number" (1.7: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 20 -Reading a token -Next token is token "number" (1.11: 1) -Shifting token "number" (1.11: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.11: 1) --> $$ = nterm exp (1.11: 1) -Entering state 29 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 20 -Reading a token -Next token is token "number" (1.15: 1) -Shifting token "number" (1.15: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 29 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 20 -Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Error: popping nterm exp (1.7-15: 3) -Shifting token error (1.7-18: ) -Entering state 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) -Entering state 29 -Reading a token -Next token is token '+' (1.20: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) -Entering state 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) -Entering state 20 -Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) -Reading a token -Next token is token ')' (1.28: ) -Entering state 11 -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 29 -Reading a token -Next token is token '+' (1.30: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) -Entering state 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) -Entering state 20 -Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) -Entering state 4 -Reading a token -Next token is token "number" (1.33: 1) -Shifting token "number" (1.33: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 21 -Reading a token -Next token is token "number" (1.37: 2) -Shifting token "number" (1.37: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.39: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) -Entering state 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 21 -Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Error: popping nterm exp (1.33-37: 2) -Shifting token error (1.33-41: ) -Entering state 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Reading a token -Next token is token ')' (1.42: ) -Entering state 11 -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.44: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) -Entering state 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) -Entering state 18 -Reading a token -Next token is token "number" (1.46: 1) -Shifting token "number" (1.46: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.46: 1) --> $$ = nterm exp (1.46: 1) -Entering state 27 -Reading a token -Next token is token '\n' (1.47-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) -Entering state 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1485: "$PERL" -pi -e 'use strict; +./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -212266,7 +214370,20 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1489: "$PERL" -pi -e 'use strict; +./calc.at:1492: cat stderr +./calc.at:1489: cat stderr + skipped (calc.at:1514) +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1485: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -212277,10 +214394,9 @@ }eg ' expout || exit 77 input: -572. calc.at:1509: testing Calculator D ... -./calc.at:1509: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y | 1//2 -./calc.at:1491: "$PERL" -pi -e 'use strict; +./calc.at:1492: $PREPARSER ./calc input +./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -212290,13 +214406,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1492: $PREPARSER ./calc input -./calc.at:1485: cat stderr ./calc.at:1491: cat stderr +./calc.at:1485: cat stderr + +input: stderr: -./calc.at:1487: cat stderr -./calc.at:1489: cat stderr -Starting parse + | 1 = 2 = 3 +./calc.at:1489: $PREPARSER ./calc input +./calc.at:1486: cat stderr +576. calc.at:1516: Starting parse Entering state 0 Reading a token Next token is token "number" (1.1: 1) @@ -212316,36 +214434,50 @@ Error: popping token '/' (1.2: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '/' (1.3: ) -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -573. calc.at:1510: testing Calculator D %locations ... -./calc.at:1510: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y -./calc.at:1489: $PREPARSER ./calc /dev/null - | (!!) + (1 2) = 1 -./calc.at:1491: $PREPARSER ./calc input -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -stderr: + skipped (calc.at:1516) +559. calc.at:1485: ok stderr: - | (# + 1) = 1111 -./calc.at:1486: cat stderr -./calc.at:1485: $PREPARSER ./calc input +./calc.at:1487: cat stderr Starting parse Entering state 0 Reading a token -Now at end of input. -syntax error, unexpected end of input -Cleanup: discarding lookahead token end of input () +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 27 +Reading a token +Next token is token '=' () +syntax error, unexpected '=' +Error: popping nterm exp (2) +Error: popping token '=' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '=' () +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | (* *) + (*) + (*) +./calc.at:1491: $PREPARSER ./calc input +stderr: + +input: + | 1 + 2 * 3 + !+ ++ +./calc.at:1486: $PREPARSER ./calc input +stderr: Starting parse Entering state 0 Reading a token @@ -212353,98 +214485,102 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 15 -Reducing stack 0 by rule 16 (line 107): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Shifting token error (1.2-3: ) +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) Entering state 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Reading a token +Next token is token ')' (1.5: ) +Entering state 11 +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) Entering state 20 Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) Entering state 4 Reading a token -Next token is token "number" (1.9: 1) -Shifting token "number" (1.9: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.9: 1) --> $$ = nterm exp (1.9: 1) -Entering state 12 -Reading a token -Next token is token "number" (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Shifting token error (1.9-11: ) +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) Entering state 11 -Next token is token "number" (1.11: 2) -Error: discarding token "number" (1.11: 2) +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) Reading a token -Next token is token ')' (1.12: ) +Next token is token ')' (1.11: ) Entering state 11 -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token -Next token is token '=' (1.14: ) +Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) Entering state 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) -Entering state 18 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 20 Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 27 +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) +Reading a token +Next token is token ')' (1.17: ) +Entering state 11 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 29 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -212457,11 +214593,75 @@ Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -input: stderr: stderr: - | (- *) + (1 2) = 1 -./calc.at:1487: $PREPARSER ./calc input +input: +Starting parse +Entering state 0 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 +Reading a token +Next token is token '*' () +Shifting token '*' () +Entering state 21 +Reading a token +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 30 +Reading a token +Next token is token '+' () +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 14 +Reducing stack 0 by rule 17 (line 108): + $1 = token '!' () + $2 = token '+' () +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -212485,133 +214685,122 @@ Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token Next token is token number (1) -Error: discarding token number (1) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 8 Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token number (1111) -Shifting token number (1111) +Next token is token number (2) +Shifting token number (2) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1111) --> $$ = nterm exp (1111) +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) Entering state 27 Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Next token is token '=' () +syntax error, unexpected '=' +Error: popping nterm exp (2) +Error: popping token '=' () +Error: popping nterm exp (1) +Cleanup: discarding lookahead token '=' () +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (# + 1) = 1111 +./calc.at:1487: $PREPARSER ./calc input stderr: -572. calc.at:1509: Starting parse +stderr: +stderr: +Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +Next token is token number (2) +Shifting token number (2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2) +-> $$ = nterm exp (2) +Entering state 29 Reading a token Next token is token '*' () -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -Shifting token error () -Entering state 9 -Reducing stack 0 by rule 15 (line 119): - $1 = token '-' () - $2 = token error () -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Shifting token '*' () +Entering state 21 Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 +Next token is token number (3) +Shifting token number (3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 30 Reading a token Next token is token '+' () +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) +Entering state 29 +Next token is token '+' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) +Entering state 8 +Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 14 +Reducing stack 0 by rule 17 (line 108): + $1 = token '!' () + $2 = token '+' () +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) +Starting parse +Entering state 0 +Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token number (2) -syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -Error: popping nterm exp (1) +syntax error: invalid character: '#' +Next token is token error () Shifting token error () Entering state 11 -Next token is token number (2) -Error: discarding token number (2) +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token number (1) +Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 @@ -212623,40 +214812,32 @@ $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) Entering state 8 +Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token number (1111) +Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) + $1 = token number (1111) +-> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (2222) + $1 = nterm exp (1111) $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2222) + $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -212671,8 +214852,10 @@ Cleanup: popping token end of file () Cleanup: popping nterm input () ./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: +577. calc.at:1517: testing Calculator D %locations parse.error=custom ... +input: +./calc.at:1517: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y + Starting parse Entering state 0 Reading a token @@ -212680,230 +214863,114 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 15 -Reducing stack 0 by rule 16 (line 107): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Shifting token error (1.2-3: ) +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) Entering state 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Reading a token +Next token is token ')' (1.5: ) +Entering state 11 +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) Entering state 20 Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) Entering state 4 Reading a token -Next token is token "number" (1.9: 1) -Shifting token "number" (1.9: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.9: 1) --> $$ = nterm exp (1.9: 1) -Entering state 12 -Reading a token -Next token is token "number" (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Shifting token error (1.9-11: ) +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) Entering state 11 -Next token is token "number" (1.11: 2) -Error: discarding token "number" (1.11: 2) +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) Reading a token -Next token is token ')' (1.12: ) +Next token is token ')' (1.11: ) Entering state 11 -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token -Next token is token '=' (1.14: ) +Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) -Entering state 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) -Entering state 18 -Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 27 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - skipped (calc.at:1509) -stderr: -stderr: -input: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 2 -Reading a token -Next token is token '*' () -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -Shifting token error () -Entering state 9 -Reducing stack 0 by rule 15 (line 119): - $1 = token '-' () - $2 = token error () -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) Entering state 20 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token number (2) -syntax error on token [number] (expected: ['='] ['-'] ['+'] ['*'] ['/'] ['^'] [')']) -Error: popping nterm exp (1) -Shifting token error () +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) Entering state 11 -Next token is token number (2) -Error: discarding token number (2) +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) Reading a token -Next token is token ')' () +Next token is token ')' (1.17: ) Entering state 11 -Next token is token ')' () -Shifting token ')' () +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) Entering state 29 Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) Entering state 8 -Next token is token '\n' () -Shifting token '\n' () +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2222) - $2 = token '\n' () --> $$ = nterm line () +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. -Shifting token end of file () +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -212914,7 +214981,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -573. calc.at:1510: Starting parse + | 1 + 2 * 3 + !- ++ +./calc.at:1486: $PREPARSER ./calc input +stderr: +./calc.at:1492: cat stderr +stderr: +Starting parse Entering state 0 Reading a token Next token is token '(' () @@ -212983,16 +215055,17 @@ Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () -Starting parse -Entering state 0 -Reading a token -Now at end of input. -syntax error, unexpected end of input -Cleanup: discarding lookahead token end of input () - | 1 + 2 * 3 + !+ ++ -./calc.at:1486: $PREPARSER ./calc input - skipped (calc.at:1510) -stderr: +./calc.at:1489: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +578. calc.at:1518: testing Calculator D %locations parse.error=detailed ... Starting parse Entering state 0 Reading a token @@ -213050,12 +215123,12 @@ Shifting token '!' () Entering state 5 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 14 -Reducing stack 0 by rule 17 (line 108): +Next token is token '-' () +Shifting token '-' () +Entering state 13 +Reducing stack 0 by rule 18 (line 109): $1 = token '!' () - $2 = token '+' () + $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) ./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr @@ -213069,10 +215142,13 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1487: cat stderr -./calc.at:1492: cat stderr +./calc.at:1518: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y +./calc.at:1489: cat stderr stderr: input: + | error +./calc.at:1491: cat stderr +./calc.at:1492: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -213130,32 +215206,127 @@ Shifting token '!' () Entering state 5 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 14 -Reducing stack 0 by rule 17 (line 108): +Next token is token '-' () +Shifting token '-' () +Entering state 13 +Reducing stack 0 by rule 18 (line 109): $1 = token '!' () - $2 = token '+' () + $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) - - -./calc.at:1491: cat stderr +stderr: +577. calc.at:1517: input: + skipped (calc.at:1517) input: -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | 1 + 2 * 3 + !- ++ - | (* *) + (*) + (*) +./calc.at:1487: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token "invalid token" (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" (1.1: ) + | + | +1 + | 1 + 2 * 3 + !+ ++ +./calc.at:1491: $PREPARSER ./calc input +./calc.at:1489: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Reading a token +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 20 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Reducing stack 0 by rule 17 (line 108): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +stderr: +579. calc.at:1519: testing Calculator D %locations parse.error=simple ... +./calc.at:1519: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '+' () +syntax error, unexpected '+' +Error: popping nterm input () +Cleanup: discarding lookahead token '+' () +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +578. calc.at:1518: | (1 + # + 1) = 1111 ./calc.at:1487: $PREPARSER ./calc input -./calc.at:1485: "$PERL" -pi -e 'use strict; +stderr: + +./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -213165,77 +215336,188 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1486: $PREPARSER ./calc input stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token "invalid token" (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" (1.1: ) stderr: + skipped (calc.at:1518) Starting parse Entering state 0 Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 79): +Reducing stack 0 by rule 5 (line 92): $1 = token number (1) -> $$ = nterm exp (1) -Entering state 8 +Entering state 12 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token -Next token is token number (2) -Shifting token number (2) +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token number (1) +Error: discarding token number (1) +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 118): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 +Reading a token +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (1111) +Shifting token number (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' () +Shifting token '\n' () +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Next token is token '+' () +syntax error, unexpected '+' +Error: popping nterm input () +Cleanup: discarding lookahead token '+' () +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (2) --> $$ = nterm exp (2) + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token -Next token is token '*' () -Shifting token '*' () +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) Entering state 21 Reading a token -Next token is token number (3) -Shifting token number (3) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (3) --> $$ = nterm exp (3) + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token -Next token is token '+' () +Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) Entering state 29 -Next token is token '+' () +Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '+' () -Shifting token '+' () +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) Entering state 20 Reading a token -Next token is token '!' () -Shifting token '!' () +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) Entering state 5 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 13 -Reducing stack 0 by rule 18 (line 109): - $1 = token '!' () - $2 = token '-' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Reducing stack 0 by rule 17 (line 108): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1486: cat stderr input: -./calc.at:1485: cat stderr -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: + | 1 + 2 * 3 + !- ++ Starting parse Entering state 0 Reading a token @@ -213243,15 +215525,32 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token '*' () -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) Shifting token error () Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token error () +Error: discarding token error () Reading a token -Next token is token '*' () -Error: discarding token '*' () +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token number (1) +Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 @@ -213265,40 +215564,90 @@ -> $$ = nterm exp (1111) Entering state 8 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (1111) +Shifting token number (1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1111) +-> $$ = nterm exp (1111) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 93): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +./calc.at:1491: $PREPARSER ./calc input +./calc.at:1492: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1492: cat stderr +579. calc.at:1519: stderr: + skipped (calc.at:1519) +input: + + | (#) + (#) = 2222 +./calc.at:1486: $PREPARSER ./calc input +580. calc.at:1520: testing Calculator D parse.error=detailed %debug %verbose ... +stderr: +./calc.at:1520: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y +Starting parse +Entering state 0 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token -Next token is token '*' () -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error: invalid character: '#' +Next token is token error () Shifting token error () Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token error () +Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 118): +Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) Entering state 8 +Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 @@ -213307,53 +215656,148 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token '*' () -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error: invalid character: '#' +Next token is token error () Shifting token error () Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token error () +Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 118): +Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (2222) +Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) --> $$ = nterm exp (3333) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (2222) +Shifting token number (2222) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2222) +-> $$ = nterm exp (2222) +Entering state 27 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (2222) +-> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (3333) +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 82): +Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token end of file () +Shifting token end of input () Entering state 16 -Cleanup: popping token end of file () +Cleanup: popping token end of input () Cleanup: popping nterm input () -./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1489: cat stderr +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Reading a token +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 20 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Reducing stack 0 by rule 18 (line 109): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) stderr: +./calc.at:1489: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -213361,22 +215805,19 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token '*' () -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error: invalid character: '#' +Next token is token error () Shifting token error () Entering state 11 -Next token is token '*' () -Error: discarding token '*' () -Reading a token -Next token is token '*' () -Error: discarding token '*' () +Next token is token error () +Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 118): +Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () @@ -213391,171 +215832,211 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token '*' () -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) +syntax error: invalid character: '#' +Next token is token error () Shifting token error () Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token error () +Error: discarding token error () Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 118): +Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) Entering state 29 Reading a token -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): +Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1111) $2 = token '+' () $3 = nterm exp (1111) -> $$ = nterm exp (2222) Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '*' () -syntax error on token ['*'] (expected: [number] ['-'] ['('] ['!']) -Shifting token error () -Entering state 11 -Next token is token '*' () -Error: discarding token '*' () +Next token is token '=' () +Shifting token '=' () +Entering state 18 Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 +Next token is token number (2222) +Shifting token number (2222) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2222) +-> $$ = nterm exp (2222) +Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 7 (line 103): +Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (3333) + $2 = token '=' () + $3 = nterm exp (2222) +-> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (3333) +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 82): +Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token end of file () +Shifting token end of input () Entering state 16 -Cleanup: popping token end of file () +Cleanup: popping token end of input () Cleanup: popping nterm input () - | error -stderr: + | 1 = 2 = 3 +./calc.at:1487: cat stderr + ./calc.at:1492: $PREPARSER ./calc input +stderr: Starting parse Entering state 0 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '+' () -Shifting token '+' () +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 18 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 27 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Error: popping token '=' (1.3: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '=' (1.7: ) +stderr: +./calc.at:1489: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 20 Reading a token -Next token is token number (2) -Shifting token number (2) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (2) --> $$ = nterm exp (2) + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token -Next token is token '*' () -Shifting token '*' () +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) Entering state 21 Reading a token -Next token is token number (3) -Shifting token number (3) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (3) --> $$ = nterm exp (3) + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token -Next token is token '+' () +Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) Entering state 29 -Next token is token '+' () +Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '+' () -Shifting token '+' () +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) Entering state 20 Reading a token -Next token is token '!' () -Shifting token '!' () +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) Entering state 5 Reading a token -Next token is token '-' () -Shifting token '-' () +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) Entering state 13 Reducing stack 0 by rule 18 (line 109): - $1 = token '!' () - $2 = token '-' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +input: +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (1 + 1) / (1 - 1) +./calc.at:1489: $PREPARSER ./calc /dev/null +./calc.at:1487: $PREPARSER ./calc input +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +582. calc.at:1523: testing Calculator D %locations parse.lac=full parse.error=detailed ... +./calc.at:1486: cat stderr +stderr: stderr: +581. calc.at:1521: testing Calculator D parse.error=detailed %debug api.symbol.prefix={SYMB_} api.token.prefix={TOK_} %verbose ... +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" (1.1: ) -input: -input: - | (- *) + (1 2) = 1 -input: -./calc.at:1491: $PREPARSER ./calc input - | (1 + # + 1) = 1111 -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1485: $PREPARSER ./calc input - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1487: cat stderr +Now at end of input. +syntax error, unexpected end of input +Cleanup: discarding lookahead token end of input () stderr: -./calc.at:1489: $PREPARSER ./calc input +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1523: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y +stderr: +./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token @@ -213575,57 +216056,89 @@ Shifting token '+' () Entering state 20 Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token Next token is token number (1) -Error: discarding token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 Reading a token Next token is token ')' () -Entering state 11 +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 Next token is token ')' () Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): +Entering state 26 +Reducing stack 0 by rule 13 (line 117): $1 = token '(' () - $2 = token error () + $2 = nterm exp (2) $3 = token ')' () --> $$ = nterm exp (1111) +-> $$ = nterm exp (2) Entering state 8 Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 +Next token is token '/' () +Shifting token '/' () +Entering state 22 Reading a token -Next token is token number (1111) -Shifting token number (1111) +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 92): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 28 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 8 (line 104): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (1) +-> $$ = nterm exp (0) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 117): + $1 = token '(' () + $2 = nterm exp (0) + $3 = token ')' () +-> $$ = nterm exp (0) +Entering state 31 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) +Reducing stack 0 by rule 10 (line 106): + $1 = nterm exp (2) + $2 = token '/' () + $3 = nterm exp (0) +error: null divisor +-> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (1111) + $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -213639,128 +216152,269 @@ Entering state 16 Cleanup: popping token end of file () Cleanup: popping nterm input () +./calc.at:1521: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 18 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 27 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Error: popping token '=' (1.3: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '=' (1.7: ) +./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Now at end of input. +syntax error, unexpected end of input +Cleanup: discarding lookahead token end of input () +input: +580. calc.at:1520: stderr: + | (1 + #) = 1111 +./calc.at:1486: $PREPARSER ./calc input + skipped (calc.at:1520) stderr: -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) +Next token is token '(' () +Shifting token '(' () Entering state 4 Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Reducing stack 0 by rule 15 (line 106): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Shifting token error (1.2-4: ) -Entering state 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 7 (line 103): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 117): + $1 = token '(' () + $2 = nterm exp (2) + $3 = token ')' () +-> $$ = nterm exp (2) Entering state 8 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 +Next token is token '/' () +Shifting token '/' () +Entering state 22 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) +Next token is token '(' () +Shifting token '(' () Entering state 4 Reading a token -Next token is token "number" (1.10: 1) -Shifting token "number" (1.10: 1) +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 92): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 28 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 8 (line 104): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (1) +-> $$ = nterm exp (0) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 117): + $1 = token '(' () + $2 = nterm exp (0) + $3 = token ')' () +-> $$ = nterm exp (0) +Entering state 31 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 10 (line 106): + $1 = nterm exp (2) + $2 = token '/' () + $3 = nterm exp (0) +error: null divisor +-> $$ = nterm exp (2) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 88): + $1 = nterm exp (2) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 82): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of file () +Entering state 16 +Cleanup: popping token end of file () +Cleanup: popping nterm input () +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.10: 1) --> $$ = nterm exp (1.10: 1) + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 12 Reading a token -Next token is token "number" (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Shifting token error (1.10-12: ) +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) +Shifting token error () Entering state 11 -Next token is token "number" (1.12: 2) -Error: discarding token "number" (1.12: 2) +Next token is token error () +Error: discarding token error () Reading a token -Next token is token ')' (1.13: ) +Next token is token ')' () Entering state 11 -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) +Next token is token ')' () +Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.15: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) +Reading a token +Next token is token '=' () +Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (1.17: 1) -Shifting token "number" (1.17: 1) +Next token is token number (1111) +Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.17: 1) --> $$ = nterm exp (1.17: 1) + $1 = token number (1111) +-> $$ = nterm exp (1111) Entering state 27 Reading a token -Next token is token '\n' (1.18-2.0: ) +Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' () +Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) + $1 = nterm line () +-> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) +Shifting token end of input () Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -stderr: +Cleanup: popping token end of input () +Cleanup: popping nterm input () +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1492: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: + | (#) + (#) = 2222 +./calc.at:1492: cat stderr +./calc.at:1491: $PREPARSER ./calc input + stderr: stderr: -575. calc.at:1514: testing Calculator D %debug ... +./calc.at:1489: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -213771,7 +216425,7 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): +Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 @@ -213789,18 +216443,12 @@ Next token is token error () Error: discarding token error () Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token number (1) -Error: discarding token number (1) -Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 118): +Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () @@ -213814,13 +216462,13 @@ Next token is token number (1111) Shifting token number (1111) Entering state 1 -Reducing stack 0 by rule 5 (line 92): +Reducing stack 0 by rule 5 (line 79): $1 = token number (1111) -> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): +Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (1111) $2 = token '=' () $3 = nterm exp (1111) @@ -213829,28 +216477,246 @@ Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 88): +Reducing stack 0 by rule 4 (line 75): $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 82): +Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token end of file () +Shifting token end of input () Entering state 16 -Cleanup: popping token end of file () +Cleanup: popping token end of input () Cleanup: popping nterm input () Starting parse Entering state 0 Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" (1.1: ) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) +Reading a token +Next token is token ')' (1.3: ) +Entering state 11 +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) +Entering state 20 +Reading a token +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Reading a token +1.8: syntax error: invalid character: '#' +Next token is token error (1.8: ) +Shifting token error (1.8: ) +Entering state 11 +Next token is token error (1.8: ) +Error: discarding token error (1.8: ) +Reading a token +Next token is token ')' (1.9: ) +Entering state 11 +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 29 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) +Entering state 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 18 +Reading a token +Next token is token "number" (1.13-16: 2222) +Shifting token "number" (1.13-16: 2222) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) +Entering state 27 +Reading a token +Next token is token '\n' (1.17-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 16 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +582. calc.at:1523: input: + skipped (calc.at:1523) ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1489: cat stderr + | + | +1 +./calc.at:1492: $PREPARSER ./calc input +./calc.at:1487: cat stderr +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Cleanup: discarding lookahead token '+' (2.1: ) +581. calc.at:1521: Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) +Reading a token +Next token is token ')' (1.3: ) +Entering state 11 +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) +Entering state 20 +Reading a token +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Reading a token +1.8: syntax error: invalid character: '#' +Next token is token error (1.8: ) +Shifting token error (1.8: ) +Entering state 11 +Next token is token error (1.8: ) +Error: discarding token error (1.8: ) +Reading a token +Next token is token ')' (1.9: ) +Entering state 11 +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 29 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) +Entering state 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 18 +Reading a token +Next token is token "number" (1.13-16: 2222) +Shifting token "number" (1.13-16: 2222) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) +Entering state 27 +Reading a token +Next token is token '\n' (1.17-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 16 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) + skipped (calc.at:1521) +input: ./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -213861,8 +216727,27 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -input: -574. calc.at:1512: testing Calculator D parse.error=detailed api.prefix={calc} %verbose ... +562. calc.at:1487: ok +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1489: $PREPARSER ./calc input +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + +./calc.at:1486: cat stderr +stderr: +stderr: +583. calc.at:1524: testing Calculator D %locations parse.lac=full parse.error=custom ... +./calc.at:1524: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y +./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token @@ -214111,117 +216996,14 @@ Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1512: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y - | 1 + 2 * 3 + !+ ++ -./calc.at:1487: $PREPARSER ./calc input -./calc.at:1514: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y -stderr: -stderr: -./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Reducing stack 0 by rule 15 (line 106): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Shifting token error (1.2-4: ) -Entering state 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Reading a token -Next token is token "number" (1.10: 1) -Shifting token "number" (1.10: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Reading a token -Next token is token "number" (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Shifting token error (1.10-12: ) -Entering state 11 -Next token is token "number" (1.12: 2) -Error: discarding token "number" (1.12: 2) -Reading a token -Next token is token ')' (1.13: ) -Entering state 11 -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.15: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) -Entering state 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) -Entering state 18 -Reading a token -Next token is token "number" (1.17: 1) -Shifting token "number" (1.17: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.17: 1) --> $$ = nterm exp (1.17: 1) -Entering state 27 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) -Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -214229,77 +217011,23 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Cleanup: discarding lookahead token '+' (2.1: ) + stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 30 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) -Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 14 -Reducing stack 0 by rule 17 (line 121): - $1 = token '!' () - $2 = token '+' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) +./calc.at:1492: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: Starting parse Entering state 0 Reading a token @@ -214547,249 +217275,382 @@ Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () -./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1485: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1485: cat stderr input: + | (# + 1) = 1111 +./calc.at:1486: $PREPARSER ./calc input + + | (1 + #) = 1111 +stderr: +./calc.at:1491: $PREPARSER ./calc input ./calc.at:1492: cat stderr Starting parse Entering state 0 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () Reading a token Next token is token '+' () -Shifting token '+' () -Entering state 20 +Error: discarding token '+' () Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 +Next token is token number (1) +Error: discarding token number (1) Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 Reading a token -Next token is token number (3) -Shifting token number (3) +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (1111) +Shifting token number (1111) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 30 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1111) +-> $$ = nterm exp (1111) +Entering state 27 Reading a token -Next token is token '+' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 14 -Reducing stack 0 by rule 17 (line 121): - $1 = token '!' () - $2 = token '+' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) -./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -574. calc.at:1512: | 1 = 2 = 3 -./calc.at:1492: $PREPARSER ./calc input -input: - | (#) + (#) = 2222 - | 1 + 2 * 3 + !- ++ +Now at end of input. +Shifting token end of input () +Entering state 16 +Cleanup: popping token end of input () +Cleanup: popping nterm input () +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - skipped (calc.at:1512) -./calc.at:1486: $PREPARSER ./calc input -575. calc.at:1514: ./calc.at:1487: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) +Reading a token +Next token is token ')' (1.7: ) +Entering state 11 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 18 Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Error: popping token '=' (1.3: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '=' (1.7: ) -./calc.at:1491: cat stderr -input: -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - skipped (calc.at:1514) +Next token is token '\n' (1.15-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 16 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1492: $PREPARSER ./calc /dev/null +583. calc.at:1524: ./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +stderr: + skipped (calc.at:1524) Starting parse Entering state 0 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 +Now at end of input. +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token "end of input" (1.1: ) +Starting parse +Entering state 0 +Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () Reading a token Next token is token '+' () -Shifting token '+' () -Entering state 20 +Error: discarding token '+' () Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 +Next token is token number (1) +Error: discarding token number (1) Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 Reading a token -Next token is token number (3) -Shifting token number (3) +Next token is token '=' () +Shifting token '=' () +Entering state 18 +Reading a token +Next token is token number (1111) +Shifting token number (1111) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 30 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1111) +-> $$ = nterm exp (1111) +Entering state 27 Reading a token -Next token is token '+' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) +Next token is token '\n' () +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 13 -Reducing stack 0 by rule 18 (line 122): - $1 = token '!' () - $2 = token '-' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) +Now at end of input. +Shifting token end of input () +Entering state 16 +Cleanup: popping token end of input () +Cleanup: popping nterm input () +./calc.at:1489: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +584. calc.at:1525: testing Calculator D %locations parse.lac=full parse.error=detailed parse.trace ... +./calc.at:1525: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1489: cat stderr +585. calc.at:1530: testing Calculator D api.token.constructor %locations parse.error=custom api.value.type=union ... +./calc.at:1530: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y stderr: Starting parse Entering state 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) +Reading a token +Next token is token ')' (1.7: ) +Entering state 11 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 18 Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Error: popping token '=' (1.3: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '=' (1.7: ) -./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +Next token is token '\n' (1.15-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 16 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) + +Starting parse +Entering state 0 +Reading a token +Now at end of input. +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token "end of input" (1.1: ) +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 input: - | (1 + 1) / (1 - 1) +586. calc.at:1531: testing Calculator D api.token.constructor %locations parse.error=detailed ... +./calc.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (!!) + (1 2) = 1 +./calc.at:1489: $PREPARSER ./calc input +./calc.at:1492: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1486: cat stderr +stderr: +./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token @@ -214797,16 +217658,20 @@ Shifting token '(' () Entering state 4 Reading a token -syntax error: invalid character: '#' -Next token is token error () +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 15 +Reducing stack 0 by rule 16 (line 107): + $1 = token '!' () + $2 = token '!' () Shifting token error () Entering state 11 -Next token is token error () -Error: discarding token error () Reading a token Next token is token ')' () -Entering state 11 -Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): @@ -214824,12 +217689,21 @@ Shifting token '(' () Entering state 4 Reading a token -syntax error: invalid character: '#' -Next token is token error () +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token number (2) +syntax error, unexpected number +Error: popping nterm exp (1) Shifting token error () Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token number (2) +Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 @@ -214854,19 +217728,20 @@ Shifting token '=' () Entering state 18 Reading a token -Next token is token number (2222) -Shifting token number (2222) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (2222) --> $$ = nterm exp (2222) + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () - $3 = nterm exp (2222) + $3 = nterm exp (1) +error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () @@ -214887,219 +217762,12 @@ Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () -./calc.at:1485: $PREPARSER ./calc input -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: - | (* *) + (*) + (*) -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 -Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 30 -Reading a token -Next token is token '+' () -Reducing stack 0 by rule 9 (line 105): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) -Entering state 29 -Next token is token '+' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) -Entering state 8 -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 13 -Reducing stack 0 by rule 18 (line 122): - $1 = token '!' () - $2 = token '-' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) -./calc.at:1491: $PREPARSER ./calc input -stderr: - -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): - $1 = token '(' () - $2 = nterm exp (2) - $3 = token ')' () --> $$ = nterm exp (2) -Entering state 8 -Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 28 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 8 (line 104): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (1) --> $$ = nterm exp (0) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): - $1 = token '(' () - $2 = nterm exp (0) - $3 = token ')' () --> $$ = nterm exp (0) -Entering state 31 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 10 (line 106): - $1 = nterm exp (2) - $2 = token '/' () - $3 = nterm exp (0) -error: null divisor --> $$ = nterm exp (2) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1485: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: cat stderr - -./calc.at:1489: cat stderr -stderr: +584. calc.at:1525: stderr: +585. calc.at:1530: input: +input: + skipped (calc.at:1530) Starting parse Entering state 0 Reading a token @@ -215107,16 +217775,20 @@ Shifting token '(' () Entering state 4 Reading a token -syntax error: invalid character: '#' -Next token is token error () +Next token is token '!' () +Shifting token '!' () +Entering state 5 +Reading a token +Next token is token '!' () +Shifting token '!' () +Entering state 15 +Reducing stack 0 by rule 16 (line 107): + $1 = token '!' () + $2 = token '!' () Shifting token error () Entering state 11 -Next token is token error () -Error: discarding token error () Reading a token Next token is token ')' () -Entering state 11 -Next token is token ')' () Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): @@ -215134,12 +217806,21 @@ Shifting token '(' () Entering state 4 Reading a token -syntax error: invalid character: '#' -Next token is token error () +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token number (2) +syntax error, unexpected number +Error: popping nterm exp (1) Shifting token error () Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token number (2) +Error: discarding token number (2) Reading a token Next token is token ')' () Entering state 11 @@ -215164,19 +217845,20 @@ Shifting token '=' () Entering state 18 Reading a token -Next token is token number (2222) -Shifting token number (2222) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (2222) --> $$ = nterm exp (2222) + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): $1 = nterm exp (2222) $2 = token '=' () - $3 = nterm exp (2222) + $3 = nterm exp (1) +error: 2222 != 1 -> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () @@ -215197,127 +217879,19 @@ Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) -Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) -Entering state 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) -Reading a token -Next token is token ')' (1.11: ) -Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) -Entering state 29 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) -Entering state 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 20 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 -Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) -Reading a token -Next token is token ')' (1.17: ) -Entering state 11 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 29 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) -Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) + skipped (calc.at:1525) +586. calc.at:1531: | (# + 1) = 1111 +./calc.at:1491: $PREPARSER ./calc input + | (1 + # + 1) = 1111 +./calc.at:1486: $PREPARSER ./calc input input: - | - | +1 -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1492: $PREPARSER ./calc input stderr: + skipped (calc.at:1531) +stderr: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +./calc.at:1492: $PREPARSER ./calc input +587. calc.at:1532: testing Calculator D api.push-pull=both ... +./calc.at:1532: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y Starting parse Entering state 0 Reading a token @@ -215325,102 +217899,56 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) Shifting token error (1.2: ) Entering state 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) -Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) -Entering state 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) +Next token is token "number" (1.6: 1) +Error: discarding token "number" (1.6: 1) Reading a token -Next token is token ')' (1.11: ) +Next token is token ')' (1.7: ) Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) -Entering state 29 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 20 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 18 Reading a token -Next token is token ')' (1.17: ) -Entering state 11 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 29 +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 27 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) +Next token is token '\n' (1.15-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -215433,31 +217961,6 @@ Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -input: -stderr: - | (!!) + (1 2) = 1 -./calc.at:1489: $PREPARSER ./calc input -stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Cleanup: discarding lookahead token '+' (2.1: ) Starting parse Entering state 0 Reading a token @@ -215465,37 +217968,6 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 15 -Reducing stack 0 by rule 16 (line 107): - $1 = token '!' () - $2 = token '!' () -Shifting token error () -Entering state 11 -Reading a token -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token Next token is token number (1) Shifting token number (1) Entering state 1 @@ -215504,13 +217976,24 @@ -> $$ = nterm exp (1) Entering state 12 Reading a token -Next token is token number (2) -syntax error, unexpected number +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () Error: popping nterm exp (1) Shifting token error () Entering state 11 -Next token is token number (2) -Error: discarding token number (2) +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token number (1) +Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 @@ -215522,40 +218005,32 @@ $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) Entering state 8 +Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token number (1111) +Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) + $1 = token number (1111) +-> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (2222) + $1 = nterm exp (1111) $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2222) + $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -215569,475 +218044,257 @@ Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () +stderr: +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): - $1 = token '(' () - $2 = nterm exp (2) - $3 = token ')' () --> $$ = nterm exp (2) +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1.7: 1) +Shifting token "number" (1.7: 1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.7: 1) +-> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 20 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1.11: 1) +Shifting token "number" (1.11: 1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 28 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 29 Reading a token -Next token is token ')' () -Reducing stack 0 by rule 8 (line 104): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (1) --> $$ = nterm exp (0) +Next token is token '+' (1.13: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): - $1 = token '(' () - $2 = nterm exp (0) - $3 = token ')' () --> $$ = nterm exp (0) -Entering state 31 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 10 (line 106): - $1 = nterm exp (2) - $2 = token '/' () - $3 = nterm exp (0) -error: null divisor --> $$ = nterm exp (2) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1487: cat stderr -./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -577. calc.at:1517: testing Calculator D %locations parse.error=custom ... -./calc.at:1491: cat stderr -./calc.at:1486: cat stderr -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 -Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 15 -Reducing stack 0 by rule 16 (line 107): - $1 = token '!' () - $2 = token '!' () -Shifting token error () -Entering state 11 -Reading a token -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) Entering state 20 Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1.15: 1) +Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 + $1 = token "number" (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 29 Reading a token -Next token is token number (2) -syntax error, unexpected number -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token number (2) -Error: discarding token number (2) +Next token is token '+' (1.17: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 20 Reading a token -Next token is token ')' () +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Error: popping nterm exp (1.7-15: 3) +Shifting token error (1.7-18: ) Entering state 11 -Next token is token ')' () -Shifting token ')' () +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) Entering state 29 Reading a token -Next token is token '=' () +Next token is token '+' (1.20: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 20 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 27 +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (1) -error: 2222 != 1 --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2222) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) +Entering state 11 +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) Reading a token -Now at end of input. -Shifting token end of input () -Entering state 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -stderr: -./calc.at:1517: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y -576. calc.at:1516: testing Calculator D parse.error=custom ... -./calc.at:1516: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y -Starting parse -Entering state 0 +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Cleanup: discarding lookahead token '+' (2.1: ) -input: -input: - | (#) + (#) = 2222 -./calc.at:1485: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | 1 + 2 * 3 + !+ ++ -./calc.at:1491: $PREPARSER ./calc input -./calc.at:1487: $PREPARSER ./calc input -stderr: -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -stderr: -Starting parse -Entering state 0 +Next token is token ')' (1.28: ) +Entering state 11 +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 29 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) +Next token is token '+' (1.30: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) Entering state 20 Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) +Entering state 4 +Reading a token +Next token is token "number" (1.33: 1) +Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 + $1 = token "number" (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) Entering state 21 Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) +Next token is token "number" (1.37: 2) +Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) + $1 = token "number" (1.37: 2) +-> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token -Next token is token '+' (1.11: ) +Next token is token '*' (1.39: ) Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 20 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Reducing stack 0 by rule 17 (line 108): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1485: cat stderr -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 21 Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Error: popping nterm exp (1.33-37: 2) +Shifting token error (1.33-41: ) Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) Reading a token -Next token is token ')' () +Next token is token ')' (1.42: ) Entering state 11 -Next token is token ')' () -Shifting token ')' () +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) +Next token is token '=' (1.44: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) Entering state 8 -Next token is token '=' () -Shifting token '=' () +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) Entering state 18 Reading a token -Next token is token number (2222) -Shifting token number (2222) +Next token is token "number" (1.46: 1) +Shifting token "number" (1.46: 1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2222) --> $$ = nterm exp (2222) +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.46: 1) +-> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (2222) --> $$ = nterm exp (2222) +Next token is token '\n' (1.47-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) Entering state 8 -Next token is token '\n' () -Shifting token '\n' () +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2222) - $2 = token '\n' () --> $$ = nterm line () +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) +-> $$ = nterm line (1.1-2.0: ) Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. -Shifting token end of file () +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -216048,11 +218305,11 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (1 + #) = 1111 -./calc.at:1486: $PREPARSER ./calc input -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + + stderr: stderr: +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -216081,6 +218338,12 @@ Next token is token error () Error: discarding token error () Reading a token +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token number (1) +Error: discarding token number (1) +Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () @@ -216130,199 +218393,354 @@ Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () -./calc.at:1489: cat stderr -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1492: cat stderr -stderr: Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token "number" (1.6: 1) +Error: discarding token "number" (1.6: 1) Reading a token -Next token is token ')' () +Next token is token ')' (1.7: ) Entering state 11 -Next token is token ')' () -Shifting token ')' () +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token -Next token is token '=' () -Shifting token '=' () +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 18 Reading a token -Next token is token number (1111) -Shifting token number (1111) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1111) --> $$ = nterm exp (1111) + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token -Next token is token '\n' () +Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Next token is token '\n' () -Shifting token '\n' () +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. -Shifting token end of input () +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -./calc.at:1492: $PREPARSER ./calc /dev/null -576. calc.at:1516: stderr: +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: +./calc.at:1489: cat stderr Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 Reading a token -Next token is token ')' () +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Reading a token +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Reading a token +Next token is token "number" (1.7: 1) +Shifting token "number" (1.7: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.7: 1) +-> $$ = nterm exp (1.7: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 20 +Reading a token +Next token is token "number" (1.11: 1) +Shifting token "number" (1.11: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 29 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 20 +Reading a token +Next token is token "number" (1.15: 1) +Shifting token "number" (1.15: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 29 +Reading a token +Next token is token '+' (1.17: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 20 +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Error: popping nterm exp (1.7-15: 3) +Shifting token error (1.7-18: ) Entering state 11 -Next token is token ')' () -Shifting token ')' () +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 29 +Reading a token +Next token is token '+' (1.20: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) Entering state 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 20 Reading a token -Next token is token '+' () -Shifting token '+' () +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 +Reading a token +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) +Entering state 11 +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) +Reading a token +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Reading a token +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Reading a token +Next token is token ')' (1.28: ) +Entering state 11 +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 29 +Reading a token +Next token is token '+' (1.30: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) +Entering state 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) Entering state 20 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) Entering state 4 Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () +Next token is token "number" (1.33: 1) +Shifting token "number" (1.33: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 +Reading a token +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 21 +Reading a token +Next token is token "number" (1.37: 2) +Shifting token "number" (1.37: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 30 +Reading a token +Next token is token '*' (1.39: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 21 +Reading a token +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Error: popping nterm exp (1.33-37: 2) +Shifting token error (1.33-41: ) Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) Reading a token -Next token is token ')' () +Next token is token ')' (1.42: ) Entering state 11 -Next token is token ')' () -Shifting token ')' () +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) Entering state 29 Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) +Next token is token '=' (1.44: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) Entering state 8 -Next token is token '=' () -Shifting token '=' () +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) Entering state 18 Reading a token -Next token is token number (2222) -Shifting token number (2222) +Next token is token "number" (1.46: 1) +Shifting token "number" (1.46: 1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (2222) --> $$ = nterm exp (2222) +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.46: 1) +-> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (2222) --> $$ = nterm exp (2222) +Next token is token '\n' (1.47-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) Entering state 8 -Next token is token '\n' () -Shifting token '\n' () +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2222) - $2 = token '\n' () --> $$ = nterm line () +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) +-> $$ = nterm line (1.1-2.0: ) Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. -Shifting token end of file () +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -stderr: -Starting parse -Entering state 0 -Reading a token -Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" (1.1: ) +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +587. calc.at:1532: ./calc.at:1491: cat stderr +./calc.at:1486: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + skipped (calc.at:1532) input: +588. calc.at:1533: testing Calculator D parse.trace parse.error=custom %locations api.push-pull=both parse.lac=full ... +./calc.at:1533: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y | (- *) + (1 2) = 1 -577. calc.at:1517: ./calc.at:1489: $PREPARSER ./calc input -559. calc.at:1485: ok +./calc.at:1489: $PREPARSER ./calc input +589. calc.at:1544: testing Calculator Java ... stderr: - skipped (calc.at:1517) +./calc.at:1486: cat stderr Starting parse Entering state 0 Reading a token @@ -216439,74 +218857,9 @@ Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () - skipped (calc.at:1516) +input: ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 20 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 20 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Reducing stack 0 by rule 17 (line 108): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1486: "$PERL" -pi -e 'use strict; +./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -216516,8 +218869,12 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +590. calc.at:1545: testing Calculator Java parse.error=custom ... +./calc.at:1545: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y +./calc.at:1544: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y + | (1 + # + 1) = 1111 stderr: +./calc.at:1491: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -216634,176 +218991,96 @@ Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () -./calc.at:1486: cat stderr - -input: - | 1 + 2 * 3 + !- ++ -./calc.at:1491: $PREPARSER ./calc input -stderr: -./calc.at:1487: cat stderr - stderr: -input: -Starting parse -Entering state 0 -Reading a token -Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" (1.1: ) - | (# + 1) = 1111 -./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 20 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) Entering state 20 Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Reducing stack 0 by rule 18 (line 109): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1489: cat stderr -stderr: - -input: - | (1 + #) = 1111 -./calc.at:1487: $PREPARSER ./calc input -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) Reading a token -Next token is token '+' () -Error: discarding token '+' () +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) Reading a token -Next token is token number (1) -Error: discarding token number (1) +Next token is token "number" (1.10: 1) +Error: discarding token "number" (1.10: 1) Reading a token -Next token is token ')' () +Next token is token ')' (1.11: ) Entering state 11 -Next token is token ')' () -Shifting token ')' () +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token -Next token is token '=' () -Shifting token '=' () +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) Entering state 18 Reading a token -Next token is token number (1111) -Shifting token number (1111) +Next token is token "number" (1.15-18: 1111) +Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1111) --> $$ = nterm exp (1111) + $1 = token "number" (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token -Next token is token '\n' () +Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) Entering state 8 -Next token is token '\n' () -Shifting token '\n' () +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) +-> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. -Shifting token end of input () +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) + +input: + | (1 + 1) / (1 - 1) +./calc.at:1492: cat stderr +./calc.at:1486: $PREPARSER ./calc input +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 @@ -216815,7 +219092,7 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): +Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 @@ -216824,146 +219101,209 @@ Shifting token '+' () Entering state 20 Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 Reading a token Next token is token ')' () -Entering state 11 +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 Next token is token ')' () Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): +Entering state 26 +Reducing stack 0 by rule 13 (line 104): $1 = token '(' () - $2 = token error () + $2 = nterm exp (2) $3 = token ')' () --> $$ = nterm exp (1111) +-> $$ = nterm exp (2) Entering state 8 Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 +Next token is token '/' () +Shifting token '/' () +Entering state 22 Reading a token -Next token is token number (1111) -Shifting token number (1111) +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (1) +Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 28 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (1) +-> $$ = nterm exp (0) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (0) + $3 = token ')' () +-> $$ = nterm exp (0) +Entering state 31 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) +Reducing stack 0 by rule 10 (line 93): + $1 = nterm exp (2) + $2 = token '/' () + $3 = nterm exp (0) +error: null divisor +-> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (1111) +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 82): +Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token end of file () +Shifting token end of input () Entering state 16 -Cleanup: popping token end of file () +Cleanup: popping token end of input () Cleanup: popping nterm input () -./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1489: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (!!) + (1 2) = 1 +588. calc.at:1533: ./calc.at:1492: $PREPARSER ./calc input + skipped (calc.at:1533) +stderr: +stderr: +590. calc.at:1545: stderr: +./calc.at:1489: cat stderr + skipped (calc.at:1545) Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) Reading a token -Next token is token '+' () -Error: discarding token '+' () +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) Reading a token -Next token is token number (1) -Error: discarding token number (1) +Next token is token "number" (1.10: 1) +Error: discarding token "number" (1.10: 1) Reading a token -Next token is token ')' () +Next token is token ')' (1.11: ) Entering state 11 -Next token is token ')' () -Shifting token ')' () +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token -Next token is token '=' () -Shifting token '=' () +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) Entering state 18 Reading a token -Next token is token number (1111) -Shifting token number (1111) +Next token is token "number" (1.15-18: 1111) +Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1111) --> $$ = nterm exp (1111) + $1 = token "number" (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token -Next token is token '\n' () +Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) Entering state 8 -Next token is token '\n' () -Shifting token '\n' () +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) +-> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. -Shifting token end of input () +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +589. calc.at:1544: 591. calc.at:1546: testing Calculator Java parse.error=detailed ... +./calc.at:1546: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y + skipped (calc.at:1544) +input: Starting parse Entering state 0 Reading a token @@ -216974,7 +219314,7 @@ Next token is token number (1) Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): +Reducing stack 0 by rule 5 (line 79): $1 = token number (1) -> $$ = nterm exp (1) Entering state 12 @@ -216983,133 +219323,219 @@ Shifting token '+' () Entering state 20 Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 Reading a token Next token is token ')' () -Entering state 11 +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 Next token is token ')' () Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): +Entering state 26 +Reducing stack 0 by rule 13 (line 104): $1 = token '(' () - $2 = token error () + $2 = nterm exp (2) $3 = token ')' () --> $$ = nterm exp (1111) +-> $$ = nterm exp (2) Entering state 8 Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 +Next token is token '/' () +Shifting token '/' () +Entering state 22 Reading a token -Next token is token number (1111) -Shifting token number (1111) +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token +Next token is token number (1) +Shifting token number (1) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 +Reading a token +Next token is token '-' () +Shifting token '-' () +Entering state 19 +Reading a token +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 28 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (1) +-> $$ = nterm exp (0) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (0) + $3 = token ')' () +-> $$ = nterm exp (0) +Entering state 31 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) +Reducing stack 0 by rule 10 (line 93): + $1 = nterm exp (2) + $2 = token '/' () + $3 = nterm exp (0) +error: null divisor +-> $$ = nterm exp (2) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (1111) +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 82): +Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token end of file () +Shifting token end of input () Entering state 16 -Cleanup: popping token end of file () +Cleanup: popping token end of input () Cleanup: popping nterm input () -578. calc.at:1518: testing Calculator D %locations parse.error=detailed ... -./calc.at:1518: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y -stderr: + | (* *) + (*) + (*) + +./calc.at:1489: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Reading a token +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 15 +Reducing stack 0 by rule 16 (line 107): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Shifting token error (1.2-3: ) +Entering state 11 +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) Entering state 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) Entering state 20 Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) +Entering state 4 +Reading a token +Next token is token "number" (1.9: 1) +Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) + $1 = token "number" (1.9: 1) +-> $$ = nterm exp (1.9: 1) +Entering state 12 +Reading a token +Next token is token "number" (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Shifting token error (1.9-11: ) +Entering state 11 +Next token is token "number" (1.11: 2) +Error: discarding token "number" (1.11: 2) +Reading a token +Next token is token ')' (1.12: ) +Entering state 11 +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) Entering state 29 Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 +Next token is token '=' (1.14: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) +Entering state 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) +Entering state 18 Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 27 Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) +Next token is token '\n' (1.17-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 20 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Reducing stack 0 by rule 18 (line 109): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -input: +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 16 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: + +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -217120,10 +219546,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 - | (* *) + (*) + (*) -./calc.at:1492: cat stderr -./calc.at:1489: $PREPARSER ./calc input -stderr: Starting parse Entering state 0 Reading a token @@ -217240,7 +219662,9 @@ Cleanup: popping token end of input () Cleanup: popping nterm input () ./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -578. calc.at:1518: ./calc.at:1486: "$PERL" -pi -e 'use strict; +stderr: + +./calc.at:1486: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -217251,8 +219675,117 @@ }eg ' expout || exit 77 ./calc.at:1491: cat stderr - skipped (calc.at:1518) -./calc.at:1486: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Reading a token +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 15 +Reducing stack 0 by rule 16 (line 107): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Shifting token error (1.2-3: ) +Entering state 11 +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) +Entering state 20 +Reading a token +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) +Entering state 4 +Reading a token +Next token is token "number" (1.9: 1) +Shifting token "number" (1.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.9: 1) +-> $$ = nterm exp (1.9: 1) +Entering state 12 +Reading a token +Next token is token "number" (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Shifting token error (1.9-11: ) +Entering state 11 +Next token is token "number" (1.11: 2) +Error: discarding token "number" (1.11: 2) +Reading a token +Next token is token ')' (1.12: ) +Entering state 11 +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) +Entering state 29 +Reading a token +Next token is token '=' (1.14: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) +Entering state 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) +Entering state 18 +Reading a token +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 27 +Reading a token +Next token is token '\n' (1.17-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 16 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 @@ -217369,101 +219902,141 @@ Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () -./calc.at:1487: cat stderr -579. calc.at:1519: testing Calculator D %locations parse.error=simple ... -input: -./calc.at:1519: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y - | (1 + # + 1) = 1111 -./calc.at:1486: $PREPARSER ./calc input - +./calc.at:1486: cat stderr +./calc.at:1492: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 input: +591. calc.at:1546: | (1 + 1) / (1 - 1) +./calc.at:1491: $PREPARSER ./calc input + skipped (calc.at:1546) +561. calc.at:1486: ok +592. calc.at:1547: testing Calculator Java parse.error=verbose ... stderr: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1492: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token -Next token is token '+' () -Shifting token '+' () +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) Entering state 20 Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token "number" (1.6: 1) +Shifting token "number" (1.6: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 29 Reading a token -Next token is token '+' () -Error: discarding token '+' () +Next token is token ')' (1.7: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) +Entering state 8 Reading a token -Next token is token number (1) -Error: discarding token number (1) +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 22 Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 +Next token is token "number" (1.12: 1) +Shifting token "number" (1.12: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 Reading a token -Next token is token number (1111) -Shifting token number (1111) +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 19 +Reading a token +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) +Next token is token ')' (1.17: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 31 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 10 (line 93): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) Entering state 8 -Next token is token '\n' () -Shifting token '\n' () +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. -Shifting token end of input () +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1547: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y +./calc.at:1492: cat stderr ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -217474,91 +220047,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +593. calc.at:1548: testing Calculator Java %locations parse.error=custom ... +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1489: cat stderr +./calc.at:1548: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y +594. calc.at:1549: testing Calculator Java %locations parse.error=detailed ... +./calc.at:1549: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y + stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token number (1) -Error: discarding token number (1) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1111) -Shifting token number (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input () -Entering state 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () input: Starting parse Entering state 0 @@ -217567,234 +220063,102 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Reading a token -Next token is token "number" (1.7: 1) -Shifting token "number" (1.7: 1) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.7: 1) --> $$ = nterm exp (1.7: 1) + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 20 -Reading a token -Next token is token "number" (1.11: 1) -Shifting token "number" (1.11: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.11: 1) --> $$ = nterm exp (1.11: 1) -Entering state 29 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) Entering state 20 Reading a token -Next token is token "number" (1.15: 1) -Shifting token "number" (1.15: 1) +Next token is token "number" (1.6: 1) +Shifting token "number" (1.6: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 29 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 20 -Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Error: popping nterm exp (1.7-15: 3) -Shifting token error (1.7-18: ) -Entering state 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) + $1 = token "number" (1.6: 1) +-> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token -Next token is token '+' (1.20: ) +Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-2: 1111) + $1 = nterm exp (1.2: 1) $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) Entering state 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) -Entering state 20 -Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) Reading a token -Next token is token ')' (1.28: ) -Entering state 11 -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 29 -Reading a token -Next token is token '+' (1.30: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) -Entering state 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) -Entering state 20 +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 22 Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) Entering state 4 Reading a token -Next token is token "number" (1.33: 1) -Shifting token "number" (1.33: 1) +Next token is token "number" (1.12: 1) +Shifting token "number" (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.33: 1) --> $$ = nterm exp (1.33: 1) + $1 = token "number" (1.12: 1) +-> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 21 +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 19 Reading a token -Next token is token "number" (1.37: 2) -Shifting token "number" (1.37: 2) +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 30 + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 Reading a token -Next token is token '*' (1.39: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) +Next token is token ')' (1.17: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) Entering state 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 21 -Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Error: popping nterm exp (1.33-37: 2) -Shifting token error (1.33-41: ) -Entering state 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Reading a token -Next token is token ')' (1.42: ) -Entering state 11 -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.44: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) -Entering state 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) -Entering state 18 -Reading a token -Next token is token "number" (1.46: 1) -Shifting token "number" (1.46: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.46: 1) --> $$ = nterm exp (1.46: 1) -Entering state 27 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 31 Reading a token -Next token is token '\n' (1.47-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 10 (line 93): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) Entering state 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -217807,87 +220171,12 @@ Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) + + | (- *) + (1 2) = 1 input: - | (#) + (#) = 2222 -./calc.at:1491: $PREPARSER ./calc input - | (# + 1) = 1111 -stderr: -580. calc.at:1520: testing Calculator D parse.error=detailed %debug %verbose ... -./calc.at:1520: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1489: cat stderr -./calc.at:1487: $PREPARSER ./calc input +./calc.at:1492: $PREPARSER ./calc input stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token number (1) -Error: discarding token number (1) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1111) -Shifting token number (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () + | 1 + 2 * 3 + !+ ++ Starting parse Entering state 0 Reading a token @@ -217895,84 +220184,103 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Reading a token +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Reducing stack 0 by rule 15 (line 106): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Shifting token error (1.2-4: ) Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) Reading a token -Next token is token ')' (1.3: ) +Next token is token ')' (1.5: ) Entering state 11 -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) Entering state 20 Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) Entering state 4 Reading a token -1.8: syntax error: invalid character: '#' -Next token is token error (1.8: ) -Shifting token error (1.8: ) +Next token is token "number" (1.10: 1) +Shifting token "number" (1.10: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Reading a token +Next token is token "number" (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Shifting token error (1.10-12: ) Entering state 11 -Next token is token error (1.8: ) -Error: discarding token error (1.8: ) +Next token is token "number" (1.12: 2) +Error: discarding token "number" (1.12: 2) Reading a token -Next token is token ')' (1.9: ) +Next token is token ')' (1.13: ) Entering state 11 -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token -Next token is token '=' (1.11: ) +Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) Entering state 18 Reading a token -Next token is token "number" (1.13-16: 2222) -Shifting token "number" (1.13-16: 2222) +Next token is token "number" (1.17: 1) +Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) + $1 = token "number" (1.17: 1) +-> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token -Next token is token '\n' (1.17-2.0: ) +Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -217985,245 +220293,194 @@ Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -input: -./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 + 2 * 3 + !+ ++ ./calc.at:1489: $PREPARSER ./calc input +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +592. calc.at:1547: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Reading a token -Next token is token "number" (1.7: 1) -Shifting token "number" (1.7: 1) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 8 Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) +Next token is token '+' () +Shifting token '+' () Entering state 20 Reading a token -Next token is token "number" (1.11: 1) -Shifting token "number" (1.11: 1) +Next token is token number (2) +Shifting token number (2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.11: 1) --> $$ = nterm exp (1.11: 1) + $1 = token number (2) +-> $$ = nterm exp (2) Entering state 29 Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 20 +Next token is token '*' () +Shifting token '*' () +Entering state 21 Reading a token -Next token is token "number" (1.15: 1) -Shifting token "number" (1.15: 1) +Next token is token number (3) +Shifting token number (3) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 29 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 20 + $1 = token number (3) +-> $$ = nterm exp (3) +Entering state 30 Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Error: popping nterm exp (1.7-15: 3) -Shifting token error (1.7-18: ) -Entering state 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) +Next token is token '+' () +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (2) + $2 = token '*' () + $3 = nterm exp (3) +-> $$ = nterm exp (6) Entering state 29 -Reading a token -Next token is token '+' (1.20: ) +Next token is token '+' () Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (6) +-> $$ = nterm exp (7) Entering state 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) +Next token is token '+' () +Shifting token '+' () Entering state 20 Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 +Next token is token '!' () +Shifting token '!' () +Entering state 5 Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) +Next token is token '+' () +Shifting token '+' () +Entering state 14 +Reducing stack 0 by rule 17 (line 108): + $1 = token '!' () + $2 = token '+' () +Cleanup: popping token '+' () +Cleanup: popping nterm exp (7) +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +593. calc.at:1548: skipped (calc.at:1547) +stderr: + skipped (calc.at:1548) +stderr: +./calc.at:1491: cat stderr +Starting parse +Entering state 0 Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 Reading a token -Next token is token ')' (1.28: ) +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Reducing stack 0 by rule 15 (line 106): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Shifting token error (1.2-4: ) Entering state 11 -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Reading a token +Next token is token ')' (1.5: ) +Entering state 11 +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 29 -Reading a token -Next token is token '+' (1.30: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) Entering state 20 Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) Entering state 4 Reading a token -Next token is token "number" (1.33: 1) -Shifting token "number" (1.33: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 21 -Reading a token -Next token is token "number" (1.37: 2) -Shifting token "number" (1.37: 2) +Next token is token "number" (1.10: 1) +Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.39: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) + $1 = token "number" (1.10: 1) +-> $$ = nterm exp (1.10: 1) Entering state 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 21 Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Error: popping nterm exp (1.33-37: 2) -Shifting token error (1.33-41: ) +Next token is token "number" (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Shifting token error (1.10-12: ) Entering state 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) +Next token is token "number" (1.12: 2) +Error: discarding token "number" (1.12: 2) Reading a token -Next token is token ')' (1.42: ) +Next token is token ')' (1.13: ) Entering state 11 -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) Entering state 29 Reading a token -Next token is token '=' (1.44: ) +Next token is token '=' (1.15: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) Entering state 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) Entering state 18 Reading a token -Next token is token "number" (1.46: 1) -Shifting token "number" (1.46: 1) +Next token is token "number" (1.17: 1) +Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.46: 1) --> $$ = nterm exp (1.46: 1) + $1 = token "number" (1.17: 1) +-> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token -Next token is token '\n' (1.47-2.0: ) +Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) Entering state 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -218236,7 +220493,6 @@ Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: Starting parse Entering state 0 Reading a token @@ -218302,8 +220558,18 @@ $2 = token '+' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1486: "$PERL" -pi -e 'use strict; +595. calc.at:1550: testing Calculator Java %locations parse.error=verbose ... +594. calc.at:1549: ./calc.at:1550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y + skipped (calc.at:1549) +input: +565. calc.at:1491: ok + + | 1 + 2 * 3 + !- ++ +./calc.at:1489: $PREPARSER ./calc input + +596. calc.at:1551: testing Calculator Java parse.trace parse.error=verbose ... +./calc.at:1551: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y +./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -218314,7 +220580,6 @@ }eg ' expout || exit 77 stderr: -581. calc.at:1521: testing Calculator D parse.error=detailed %debug api.symbol.prefix={SYMB_} api.token.prefix={TOK_} %verbose ... Starting parse Entering state 0 Reading a token @@ -218372,190 +220637,18 @@ Shifting token '!' () Entering state 5 Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 14 -Reducing stack 0 by rule 17 (line 108): +Next token is token '-' () +Shifting token '-' () +Entering state 13 +Reducing stack 0 by rule 18 (line 109): $1 = token '!' () - $2 = token '+' () + $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) -input: - | 1 + 2 * 3 + !- ++ -./calc.at:1489: $PREPARSER ./calc input -./calc.at:1521: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1492: cat stderr stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token number (1) -Error: discarding token number (1) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1111) -Shifting token number (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1486: cat stderr -579. calc.at:1519: skipped (calc.at:1519) -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token ')' (1.3: ) -Entering state 11 -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 20 -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Reading a token -1.8: syntax error: invalid character: '#' -Next token is token error (1.8: ) -Shifting token error (1.8: ) -Entering state 11 -Next token is token error (1.8: ) -Error: discarding token error (1.8: ) -Reading a token -Next token is token ')' (1.9: ) -Entering state 11 -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 18 -Reading a token -Next token is token "number" (1.13-16: 2222) -Shifting token "number" (1.13-16: 2222) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 27 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) + Starting parse Entering state 0 Reading a token @@ -218621,178 +220714,265 @@ $2 = token '-' () Cleanup: popping token '+' () Cleanup: popping nterm exp (7) -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +596. calc.at:1551: 595. calc.at:1550: input: -./calc.at:1487: cat stderr -input: -./calc.at:1492: cat stderr -input: - | (1 + # + 1) = 1111 -./calc.at:1487: $PREPARSER ./calc input -stderr: - | (1 + 1) / (1 - 1) + | (* *) + (*) + (*) +./calc.at:1492: $PREPARSER ./calc input +598. calc.at:1554: testing Calculator Java api.push-pull=both ... +./calc.at:1554: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y + skipped (calc.at:1551) + skipped (calc.at:1550) stderr: -./calc.at:1486: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token -Next token is token '(' () -Shifting token '(' () +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) -Shifting token error () +Next token is token ')' (1.5: ) Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 Reading a token -Next token is token '+' () -Error: discarding token '+' () +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 20 Reading a token -Next token is token number (1) -Error: discarding token number (1) +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 Reading a token -Next token is token ')' () +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) Entering state 11 -Next token is token ')' () -Shifting token ')' () +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) +Reading a token +Next token is token ')' (1.11: ) +Entering state 11 +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) Entering state 25 -Reducing stack 0 by rule 14 (line 118): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) +Entering state 29 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) Entering state 8 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 20 Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 Reading a token -Next token is token number (1111) -Shifting token number (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) +Next token is token ')' (1.17: ) +Entering state 11 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 29 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) Entering state 8 -Next token is token '\n' () -Shifting token '\n' () +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. -Shifting token end of file () +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1489: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +599. calc.at:1555: testing Calculator Java api.push-pull=both parse.error=detailed %locations ... +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y + +./calc.at:1489: cat stderr +stderr: + Starting parse Entering state 0 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) +Reading a token +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Reading a token +Next token is token ')' (1.5: ) +Entering state 11 +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token -Next token is token '+' () -Shifting token '+' () +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) Entering state 20 Reading a token -Next token is token number (2) -Shifting token number (2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2) --> $$ = nterm exp (2) -Entering state 29 -Reading a token -Next token is token '*' () -Shifting token '*' () -Entering state 21 +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 Reading a token -Next token is token number (3) -Shifting token number (3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (3) --> $$ = nterm exp (3) -Entering state 30 +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) +Entering state 11 +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) Reading a token -Next token is token '+' () -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (2) - $2 = token '*' () - $3 = nterm exp (3) --> $$ = nterm exp (6) +Next token is token ')' (1.11: ) +Entering state 11 +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) Entering state 29 -Next token is token '+' () +Reading a token +Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (6) --> $$ = nterm exp (7) + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) Entering state 8 -Next token is token '+' () -Shifting token '+' () +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) Entering state 20 Reading a token -Next token is token '!' () -Shifting token '!' () -Entering state 5 +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 13 -Reducing stack 0 by rule 18 (line 109): - $1 = token '!' () - $2 = token '-' () -Cleanup: popping token '+' () -Cleanup: popping nterm exp (7) -581. calc.at:1521: 580. calc.at:1520: ./calc.at:1491: "$PERL" -pi -e 'use strict; +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) +Reading a token +Next token is token ')' (1.17: ) +Entering state 11 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 29 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) +Entering state 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 16 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +597. calc.at:1552: testing Calculator Java parse.trace parse.error=verbose %locations %lex-param {InputStream is} ... +./calc.at:1552: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y +./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -218802,11 +220982,13 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +input: +600. calc.at:1556: testing Calculator Java parse.trace parse.error=custom %locations %lex-param {InputStream is} api.push-pull=both ... + | (#) + (#) = 2222 +./calc.at:1489: $PREPARSER ./calc input +./calc.at:1556: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y +./calc.at:1492: cat stderr stderr: -./calc.at:1491: cat stderr -stderr: - skipped (calc.at:1521) - skipped (calc.at:1520) Starting parse Entering state 0 Reading a token @@ -218814,83 +220996,98 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () +Reading a token +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) +Entering state 8 Reading a token Next token is token '+' () Shifting token '+' () Entering state 20 Reading a token +Next token is token '(' () +Shifting token '(' () +Entering state 4 +Reading a token syntax error: invalid character: '#' Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) Shifting token error () Entering state 11 Next token is token error () Error: discarding token error () Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token number (1) -Error: discarding token number (1) -Reading a token Next token is token ')' () Entering state 11 Next token is token ')' () Shifting token ')' () Entering state 25 -Reducing stack 0 by rule 14 (line 118): +Reducing stack 0 by rule 14 (line 105): $1 = token '(' () $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 8 +Entering state 29 Reading a token Next token is token '=' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) +Entering state 8 +Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token number (1111) -Shifting token number (1111) +Next token is token number (2222) +Shifting token number (2222) Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1111) --> $$ = nterm exp (1111) +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2222) +-> $$ = nterm exp (2222) Entering state 27 Reading a token Next token is token '\n' () -Reducing stack 0 by rule 6 (line 93): - $1 = nterm exp (1111) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2222) $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) + $3 = nterm exp (2222) +-> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (1111) +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 -Reducing stack 0 by rule 1 (line 82): +Reducing stack 0 by rule 1 (line 69): $1 = nterm line () -> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token end of file () +Shifting token end of input () Entering state 16 -Cleanup: popping token end of file () +Cleanup: popping token end of input () Cleanup: popping nterm input () -input: +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: Starting parse Entering state 0 Reading a token @@ -218898,338 +221095,83 @@ Shifting token '(' () Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () Reading a token Next token is token ')' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 +Entering state 11 Next token is token ')' () Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): +Entering state 25 +Reducing stack 0 by rule 14 (line 105): $1 = token '(' () - $2 = nterm exp (2) + $2 = token error () $3 = token ')' () --> $$ = nterm exp (2) +-> $$ = nterm exp (1111) Entering state 8 Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token Next token is token '(' () Shifting token '(' () Entering state 4 Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 28 +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () Reading a token Next token is token ')' () -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (1) --> $$ = nterm exp (0) -Entering state 12 +Entering state 11 Next token is token ')' () Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (0) - $3 = token ')' () --> $$ = nterm exp (0) -Entering state 31 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (2) - $2 = token '/' () - $3 = nterm exp (0) -error: null divisor --> $$ = nterm exp (2) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input () -Entering state 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -./calc.at:1486: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (!!) + (1 2) = 1 -./calc.at:1492: $PREPARSER ./calc input -stderr: -input: - - | (1 + #) = 1111 -./calc.at:1491: $PREPARSER ./calc input -stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 15 -Reducing stack 0 by rule 16 (line 107): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Shifting token error (1.2-3: ) -Entering state 11 -Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) -Entering state 20 -Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) -Entering state 4 -Reading a token -Next token is token "number" (1.9: 1) -Shifting token "number" (1.9: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.9: 1) --> $$ = nterm exp (1.9: 1) -Entering state 12 -Reading a token -Next token is token "number" (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Shifting token error (1.9-11: ) -Entering state 11 -Next token is token "number" (1.11: 2) -Error: discarding token "number" (1.11: 2) -Reading a token -Next token is token ')' (1.12: ) -Entering state 11 -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 29 Reading a token -Next token is token '=' (1.14: ) +Next token is token '=' () Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) + $1 = nterm exp (1111) + $2 = token '+' () + $3 = nterm exp (1111) +-> $$ = nterm exp (2222) Entering state 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) +Next token is token '=' () +Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) +Next token is token number (2222) +Shifting token number (2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) + $1 = token number (2222) +-> $$ = nterm exp (2222) Entering state 27 Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (2) - $3 = token ')' () --> $$ = nterm exp (2) -Entering state 8 -Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 28 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (1) --> $$ = nterm exp (0) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (0) - $3 = token ')' () --> $$ = nterm exp (0) -Entering state 31 -Reading a token Next token is token '\n' () -Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (2) - $2 = token '/' () - $3 = nterm exp (0) -error: null divisor --> $$ = nterm exp (2) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2222) + $2 = token '=' () + $3 = nterm exp (2222) +-> $$ = nterm exp (2222) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2) + $1 = nterm exp (2222) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -219243,86 +221185,84 @@ Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () -582. calc.at:1523: testing Calculator D %locations parse.lac=full parse.error=detailed ... -./calc.at:1523: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y +598. calc.at:1554: 601. calc.at:1557: testing Calculator Java parse.trace parse.error=verbose %locations %lex-param {InputStream is} api.push-pull=both ... + skipped (calc.at:1554) +602. calc.at:1560: testing Calculator Java parse.trace parse.error=custom %locations parse.lac=full ... +597. calc.at:1552: ./calc.at:1560: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y +./calc.at:1557: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y -Starting parse +input: + skipped (calc.at:1552) +599. calc.at:1555: | 1 + 2 * 3 + !+ ++ +./calc.at:1492: $PREPARSER ./calc input + skipped (calc.at:1555) +stderr: +602. calc.at:1560: Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 20 Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) -Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) -Reading a token -Next token is token ')' (1.7: ) -Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 20 Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Reducing stack 0 by rule 17 (line 108): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) + skipped (calc.at:1560) ./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -219333,291 +221273,179 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -stderr: -./calc.at:1494: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc calc.hh +./calc.at:1489: cat stderr +600. calc.at:1556: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + skipped (calc.at:1556) + + -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./calc.at:1487: cat stderr +input: Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 15 -Reducing stack 0 by rule 16 (line 107): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Shifting token error (1.2-3: ) -Entering state 11 -Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 20 Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) -Entering state 4 -Reading a token -Next token is token "number" (1.9: 1) -Shifting token "number" (1.9: 1) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.9: 1) --> $$ = nterm exp (1.9: 1) -Entering state 12 -Reading a token -Next token is token "number" (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Shifting token error (1.9-11: ) -Entering state 11 -Next token is token "number" (1.11: 2) -Error: discarding token "number" (1.11: 2) -Reading a token -Next token is token ')' (1.12: ) -Entering state 11 -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token -Next token is token '=' (1.14: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) -Entering state 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) -Entering state 18 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 27 + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 20 Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -stdout: -./calc.at:1491: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc calc.hh - -./calc.at:1489: cat stderr -582. calc.at:1523: stderr: -input: - skipped (calc.at:1523) -./calc.at:1486: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Reducing stack 0 by rule 17 (line 108): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) + | (1 + #) = 1111 +./calc.at:1489: $PREPARSER ./calc input input: -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1491: $PREPARSER ./calc input +stderr: +601. calc.at:1557: | 1 + 2 * 3 + !- ++ + skipped (calc.at:1557) +./calc.at:1492: $PREPARSER ./calc input + Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) +Next token is token '(' () +Shifting token '(' () Entering state 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 12 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' () +Shifting token '+' () Entering state 20 Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) +Shifting token error () Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) +Next token is token error () +Error: discarding token error () Reading a token -Next token is token ')' (1.7: ) +Next token is token ')' () Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' () +Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 8 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) +Next token is token '=' () +Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) +Next token is token number (1111) +Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) + $1 = token number (1111) +-> $$ = nterm exp (1111) Entering state 27 Reading a token -Next token is token '\n' (1.15-2.0: ) +Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' () +Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) + $1 = nterm line () +-> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) +Shifting token end of input () Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -583. calc.at:1524: testing Calculator D %locations parse.lac=full parse.error=custom ... - | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 -./calc.at:1486: cat stderr -./calc.at:1492: cat stderr -./calc.at:1524: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y -./calc.at:1494: $PREPARSER ./calc input - -input: +Cleanup: popping token end of input () +Cleanup: popping nterm input () +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +603. calc.at:1561: testing Calculator Java parse.trace parse.error=custom %locations api.push-pull=both parse.lac=full ... +./calc.at:1561: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y stderr: +605. torture.at:216: testing Big horizontal ... +./torture.at:230: "$PERL" -w ./gengram.pl 1000 || exit 77 +stdout: Starting parse Entering state 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.1: 1) + $1 = token "number" (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token @@ -219625,11 +221453,11 @@ Shifting token '+' (1.3: ) Entering state 20 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.5: 2) + $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token @@ -219637,819 +221465,1265 @@ Shifting token '*' (1.7: ) Entering state 21 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.9: 3) + $1 = token "number" (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token -Next token is token '=' (1.11: ) +Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 -Next token is token '=' (1.11: ) +Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 18 -Reading a token -Next token is token number (1.13: 7) -Shifting token number (1.13: 7) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.13: 7) --> $$ = nterm exp (1.13: 7) -Entering state 27 -Reading a token -Next token is token '\n' (1.14-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-9: 7) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13: 7) --> $$ = nterm exp (1.1-13: 7) -Entering state 8 -Next token is token '\n' (1.14-2.0: ) -Shifting token '\n' (1.14-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-13: 7) - $2 = token '\n' (1.14-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Next token is token number (2.1: 1) -Shifting token number (2.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2.1: 1) --> $$ = nterm exp (2.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (2.3: ) -Shifting token '+' (2.3: ) +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) Entering state 20 Reading a token -Next token is token number (2.5: 2) -Shifting token number (2.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2.5: 2) --> $$ = nterm exp (2.5: 2) -Entering state 29 -Reading a token -Next token is token '*' (2.7: ) -Shifting token '*' (2.7: ) -Entering state 21 -Reading a token -Next token is token '-' (2.9: ) -Shifting token '-' (2.9: ) -Entering state 2 -Reading a token -Next token is token number (2.10: 3) -Shifting token number (2.10: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2.10: 3) --> $$ = nterm exp (2.10: 3) -Entering state 10 -Reading a token -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (2.9: ) - $2 = nterm exp (2.10: 3) --> $$ = nterm exp (2.9-10: -3) -Entering state 30 -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (2.5: 2) - $2 = token '*' (2.7: ) - $3 = nterm exp (2.9-10: -3) --> $$ = nterm exp (2.5-10: -6) -Entering state 29 -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (2.1: 1) - $2 = token '+' (2.3: ) - $3 = nterm exp (2.5-10: -6) --> $$ = nterm exp (2.1-10: -5) -Entering state 8 -Next token is token '=' (2.12: ) -Shifting token '=' (2.12: ) -Entering state 18 -Reading a token -Next token is token '-' (2.14: ) -Shifting token '-' (2.14: ) -Entering state 2 -Reading a token -Next token is token number (2.15: 5) -Shifting token number (2.15: 5) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2.15: 5) --> $$ = nterm exp (2.15: 5) -Entering state 10 -Reading a token -Next token is token '\n' (2.16-3.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (2.14: ) - $2 = nterm exp (2.15: 5) --> $$ = nterm exp (2.14-15: -5) -Entering state 27 -Next token is token '\n' (2.16-3.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (2.1-10: -5) - $2 = token '=' (2.12: ) - $3 = nterm exp (2.14-15: -5) --> $$ = nterm exp (2.1-15: -5) -Entering state 8 -Next token is token '\n' (2.16-3.0: ) -Shifting token '\n' (2.16-3.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2.1-15: -5) - $2 = token '\n' (2.16-3.0: ) --> $$ = nterm line (2.1-3.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-2.0: ) - $2 = nterm line (2.1-3.0: ) --> $$ = nterm input (1.1-3.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (3.1-4.0: ) -Shifting token '\n' (3.1-4.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (3.1-4.0: ) --> $$ = nterm line (3.1-4.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-3.0: ) - $2 = nterm line (3.1-4.0: ) --> $$ = nterm input (1.1-4.0: ) -Entering state 6 -Reading a token -Next token is token '-' (4.1: ) -Shifting token '-' (4.1: ) -Entering state 2 -Reading a token -Next token is token number (4.2: 1) -Shifting token number (4.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (4.2: 1) --> $$ = nterm exp (4.2: 1) -Entering state 10 -Reading a token -Next token is token '^' (4.3: ) -Shifting token '^' (4.3: ) -Entering state 23 -Reading a token -Next token is token number (4.4: 2) -Shifting token number (4.4: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (4.4: 2) --> $$ = nterm exp (4.4: 2) -Entering state 32 -Reading a token -Next token is token '=' (4.6: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (4.2: 1) - $2 = token '^' (4.3: ) - $3 = nterm exp (4.4: 2) --> $$ = nterm exp (4.2-4: 1) -Entering state 10 -Next token is token '=' (4.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (4.1: ) - $2 = nterm exp (4.2-4: 1) --> $$ = nterm exp (4.1-4: -1) -Entering state 8 -Next token is token '=' (4.6: ) -Shifting token '=' (4.6: ) -Entering state 18 -Reading a token -Next token is token '-' (4.8: ) -Shifting token '-' (4.8: ) -Entering state 2 -Reading a token -Next token is token number (4.9: 1) -Shifting token number (4.9: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (4.9: 1) --> $$ = nterm exp (4.9: 1) -Entering state 10 -Reading a token -Next token is token '\n' (4.10-5.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (4.8: ) - $2 = nterm exp (4.9: 1) --> $$ = nterm exp (4.8-9: -1) -Entering state 27 -Next token is token '\n' (4.10-5.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (4.1-4: -1) - $2 = token '=' (4.6: ) - $3 = nterm exp (4.8-9: -1) --> $$ = nterm exp (4.1-9: -1) -Entering state 8 -Next token is token '\n' (4.10-5.0: ) -Shifting token '\n' (4.10-5.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (4.1-9: -1) - $2 = token '\n' (4.10-5.0: ) --> $$ = nterm line (4.1-5.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-4.0: ) - $2 = nterm line (4.1-5.0: ) --> $$ = nterm input (1.1-5.0: ) -Entering state 6 -Reading a token -Next token is token '(' (5.1: ) -Shifting token '(' (5.1: ) -Entering state 4 -Reading a token -Next token is token '-' (5.2: ) -Shifting token '-' (5.2: ) -Entering state 2 -Reading a token -Next token is token number (5.3: 1) -Shifting token number (5.3: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (5.3: 1) --> $$ = nterm exp (5.3: 1) -Entering state 10 -Reading a token -Next token is token ')' (5.4: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (5.2: ) - $2 = nterm exp (5.3: 1) --> $$ = nterm exp (5.2-3: -1) -Entering state 12 -Next token is token ')' (5.4: ) -Shifting token ')' (5.4: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (5.1: ) - $2 = nterm exp (5.2-3: -1) - $3 = token ')' (5.4: ) --> $$ = nterm exp (5.1-4: -1) -Entering state 8 -Reading a token -Next token is token '^' (5.5: ) -Shifting token '^' (5.5: ) -Entering state 23 -Reading a token -Next token is token number (5.6: 2) -Shifting token number (5.6: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (5.6: 2) --> $$ = nterm exp (5.6: 2) -Entering state 32 -Reading a token -Next token is token '=' (5.8: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (5.1-4: -1) - $2 = token '^' (5.5: ) - $3 = nterm exp (5.6: 2) --> $$ = nterm exp (5.1-6: 1) -Entering state 8 -Next token is token '=' (5.8: ) -Shifting token '=' (5.8: ) -Entering state 18 -Reading a token -Next token is token number (5.10: 1) -Shifting token number (5.10: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (5.10: 1) --> $$ = nterm exp (5.10: 1) -Entering state 27 -Reading a token -Next token is token '\n' (5.11-6.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (5.1-6: 1) - $2 = token '=' (5.8: ) - $3 = nterm exp (5.10: 1) --> $$ = nterm exp (5.1-10: 1) -Entering state 8 -Next token is token '\n' (5.11-6.0: ) -Shifting token '\n' (5.11-6.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (5.1-10: 1) - $2 = token '\n' (5.11-6.0: ) --> $$ = nterm line (5.1-6.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-5.0: ) - $2 = nterm line (5.1-6.0: ) --> $$ = nterm input (1.1-6.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (6.1-7.0: ) -Shifting token '\n' (6.1-7.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (6.1-7.0: ) --> $$ = nterm line (6.1-7.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-6.0: ) - $2 = nterm line (6.1-7.0: ) --> $$ = nterm input (1.1-7.0: ) -Entering state 6 -Reading a token -Next token is token '-' (7.1: ) -Shifting token '-' (7.1: ) -Entering state 2 -Reading a token -Next token is token '-' (7.2: ) -Shifting token '-' (7.2: ) -Entering state 2 -Reading a token -Next token is token '-' (7.3: ) -Shifting token '-' (7.3: ) -Entering state 2 -Reading a token -Next token is token number (7.4: 1) -Shifting token number (7.4: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (7.4: 1) --> $$ = nterm exp (7.4: 1) -Entering state 10 -Reading a token -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.3: ) - $2 = nterm exp (7.4: 1) --> $$ = nterm exp (7.3-4: -1) -Entering state 10 -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.2: ) - $2 = nterm exp (7.3-4: -1) --> $$ = nterm exp (7.2-4: 1) -Entering state 10 -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.1: ) - $2 = nterm exp (7.2-4: 1) --> $$ = nterm exp (7.1-4: -1) -Entering state 8 -Next token is token '=' (7.6: ) -Shifting token '=' (7.6: ) -Entering state 18 -Reading a token -Next token is token '-' (7.8: ) -Shifting token '-' (7.8: ) -Entering state 2 -Reading a token -Next token is token number (7.9: 1) -Shifting token number (7.9: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (7.9: 1) --> $$ = nterm exp (7.9: 1) -Entering state 10 -Reading a token -Next token is token '\n' (7.10-8.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.8: ) - $2 = nterm exp (7.9: 1) --> $$ = nterm exp (7.8-9: -1) -Entering state 27 -Next token is token '\n' (7.10-8.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (7.1-4: -1) - $2 = token '=' (7.6: ) - $3 = nterm exp (7.8-9: -1) --> $$ = nterm exp (7.1-9: -1) -Entering state 8 -Next token is token '\n' (7.10-8.0: ) -Shifting token '\n' (7.10-8.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (7.1-9: -1) - $2 = token '\n' (7.10-8.0: ) --> $$ = nterm line (7.1-8.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-7.0: ) - $2 = nterm line (7.1-8.0: ) --> $$ = nterm input (1.1-8.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (8.1-9.0: ) -Shifting token '\n' (8.1-9.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (8.1-9.0: ) --> $$ = nterm line (8.1-9.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-8.0: ) - $2 = nterm line (8.1-9.0: ) --> $$ = nterm input (1.1-9.0: ) -Entering state 6 -Reading a token -Next token is token number (9.1: 1) -Shifting token number (9.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (9.1: 1) --> $$ = nterm exp (9.1: 1) -Entering state 8 -Reading a token -Next token is token '-' (9.3: ) -Shifting token '-' (9.3: ) -Entering state 19 -Reading a token -Next token is token number (9.5: 2) -Shifting token number (9.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (9.5: 2) --> $$ = nterm exp (9.5: 2) -Entering state 28 -Reading a token -Next token is token '-' (9.7: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (9.1: 1) - $2 = token '-' (9.3: ) - $3 = nterm exp (9.5: 2) --> $$ = nterm exp (9.1-5: -1) -Entering state 8 -Next token is token '-' (9.7: ) -Shifting token '-' (9.7: ) -Entering state 19 -Reading a token -Next token is token number (9.9: 3) -Shifting token number (9.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (9.9: 3) --> $$ = nterm exp (9.9: 3) -Entering state 28 -Reading a token -Next token is token '=' (9.11: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (9.1-5: -1) - $2 = token '-' (9.7: ) - $3 = nterm exp (9.9: 3) --> $$ = nterm exp (9.1-9: -4) -Entering state 8 -Next token is token '=' (9.11: ) -Shifting token '=' (9.11: ) -Entering state 18 -Reading a token -Next token is token '-' (9.13: ) -Shifting token '-' (9.13: ) -Entering state 2 -Reading a token -Next token is token number (9.14: 4) -Shifting token number (9.14: 4) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (9.14: 4) --> $$ = nterm exp (9.14: 4) -Entering state 10 -Reading a token -Next token is token '\n' (9.15-10.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (9.13: ) - $2 = nterm exp (9.14: 4) --> $$ = nterm exp (9.13-14: -4) -Entering state 27 -Next token is token '\n' (9.15-10.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (9.1-9: -4) - $2 = token '=' (9.11: ) - $3 = nterm exp (9.13-14: -4) --> $$ = nterm exp (9.1-14: -4) -Entering state 8 -Next token is token '\n' (9.15-10.0: ) -Shifting token '\n' (9.15-10.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (9.1-14: -4) - $2 = token '\n' (9.15-10.0: ) --> $$ = nterm line (9.1-10.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-9.0: ) - $2 = nterm line (9.1-10.0: ) --> $$ = nterm input (1.1-10.0: ) -Entering state 6 -Reading a token -Next token is token number (10.1: 1) -Shifting token number (10.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (10.1: 1) --> $$ = nterm exp (10.1: 1) -Entering state 8 -Reading a token -Next token is token '-' (10.3: ) -Shifting token '-' (10.3: ) -Entering state 19 -Reading a token -Next token is token '(' (10.5: ) -Shifting token '(' (10.5: ) -Entering state 4 -Reading a token -Next token is token number (10.6: 2) -Shifting token number (10.6: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (10.6: 2) --> $$ = nterm exp (10.6: 2) -Entering state 12 -Reading a token -Next token is token '-' (10.8: ) -Shifting token '-' (10.8: ) -Entering state 19 -Reading a token -Next token is token number (10.10: 3) -Shifting token number (10.10: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (10.10: 3) --> $$ = nterm exp (10.10: 3) -Entering state 28 -Reading a token -Next token is token ')' (10.11: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (10.6: 2) - $2 = token '-' (10.8: ) - $3 = nterm exp (10.10: 3) --> $$ = nterm exp (10.6-10: -1) -Entering state 12 -Next token is token ')' (10.11: ) -Shifting token ')' (10.11: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (10.5: ) - $2 = nterm exp (10.6-10: -1) - $3 = token ')' (10.11: ) --> $$ = nterm exp (10.5-11: -1) -Entering state 28 -Reading a token -Next token is token '=' (10.13: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (10.1: 1) - $2 = token '-' (10.3: ) - $3 = nterm exp (10.5-11: -1) --> $$ = nterm exp (10.1-11: 2) -Entering state 8 -Next token is token '=' (10.13: ) -Shifting token '=' (10.13: ) -Entering state 18 -Reading a token -Next token is token number (10.15: 2) -Shifting token number (10.15: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (10.15: 2) --> $$ = nterm exp (10.15: 2) -Entering state 27 -Reading a token -Next token is token '\n' (10.16-11.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (10.1-11: 2) - $2 = token '=' (10.13: ) - $3 = nterm exp (10.15: 2) --> $$ = nterm exp (10.1-15: 2) -Entering state 8 -Next token is token '\n' (10.16-11.0: ) -Shifting token '\n' (10.16-11.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (10.1-15: 2) - $2 = token '\n' (10.16-11.0: ) --> $$ = nterm line (10.1-11.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-10.0: ) - $2 = nterm line (10.1-11.0: ) --> $$ = nterm input (1.1-11.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (11.1-12.0: ) -Shifting token '\n' (11.1-12.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (11.1-12.0: ) --> $$ = nterm line (11.1-12.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-11.0: ) - $2 = nterm line (11.1-12.0: ) --> $$ = nterm input (1.1-12.0: ) -Entering state 6 -Reading a token -Next token is token number (12.1: 2) -Shifting token number (12.1: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (12.1: 2) --> $$ = nterm exp (12.1: 2) -Entering state 8 -Reading a token -Next token is token '^' (12.2: ) -Shifting token '^' (12.2: ) -Entering state 23 -Reading a token -Next token is token number (12.3: 2) -Shifting token number (12.3: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (12.3: 2) --> $$ = nterm exp (12.3: 2) -Entering state 32 -Reading a token -Next token is token '^' (12.4: ) -Shifting token '^' (12.4: ) -Entering state 23 -Reading a token -Next token is token number (12.5: 3) -Shifting token number (12.5: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (12.5: 3) --> $$ = nterm exp (12.5: 3) -Entering state 32 -Reading a token -Next token is token '=' (12.7: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (12.3: 2) - $2 = token '^' (12.4: ) - $3 = nterm exp (12.5: 3) --> $$ = nterm exp (12.3-5: 8) -Entering state 32 -Next token is token '=' (12.7: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (12.1: 2) - $2 = token '^' (12.2: ) - $3 = nterm exp (12.3-5: 8) --> $$ = nterm exp (12.1-5: 256) -Entering state 8 -Next token is token '=' (12.7: ) -Shifting token '=' (12.7: ) -Entering state 18 -Reading a token -Next token is token number (12.9-11: 256) -Shifting token number (12.9-11: 256) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (12.9-11: 256) --> $$ = nterm exp (12.9-11: 256) -Entering state 27 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 Reading a token -Next token is token '\n' (12.12-13.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (12.1-5: 256) - $2 = token '=' (12.7: ) - $3 = nterm exp (12.9-11: 256) --> $$ = nterm exp (12.1-11: 256) -Entering state 8 -Next token is token '\n' (12.12-13.0: ) -Shifting token '\n' (12.12-13.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (12.1-11: 256) - $2 = token '\n' (12.12-13.0: ) --> $$ = nterm line (12.1-13.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-12.0: ) - $2 = nterm line (12.1-13.0: ) --> $$ = nterm input (1.1-13.0: ) -Entering state 6 +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Reducing stack 0 by rule 18 (line 109): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +604. torture.at:132: testing Big triangle ... +./torture.at:138: "$PERL" -w ./gengram.pl 200 || exit 77 +stderr: +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 Reading a token -Next token is token '(' (13.1: ) -Shifting token '(' (13.1: ) +Next token is token '(' () +Shifting token '(' () Entering state 4 Reading a token -Next token is token number (13.2: 2) -Shifting token number (13.2: 2) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (13.2: 2) --> $$ = nterm exp (13.2: 2) + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 12 Reading a token -Next token is token '^' (13.3: ) -Shifting token '^' (13.3: ) -Entering state 23 +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token -Next token is token number (13.4: 2) -Shifting token number (13.4: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (13.4: 2) --> $$ = nterm exp (13.4: 2) -Entering state 32 +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () Reading a token -Next token is token ')' (13.5: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (13.2: 2) - $2 = token '^' (13.3: ) - $3 = nterm exp (13.4: 2) --> $$ = nterm exp (13.2-4: 4) -Entering state 12 -Next token is token ')' (13.5: ) -Shifting token ')' (13.5: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (13.1: ) - $2 = nterm exp (13.2-4: 4) - $3 = token ')' (13.5: ) --> $$ = nterm exp (13.1-5: 4) +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 8 Reading a token -Next token is token '^' (13.6: ) -Shifting token '^' (13.6: ) -Entering state 23 -Reading a token -Next token is token number (13.7: 3) -Shifting token number (13.7: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (13.7: 3) --> $$ = nterm exp (13.7: 3) -Entering state 32 -Reading a token -Next token is token '=' (13.9: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (13.1-5: 4) - $2 = token '^' (13.6: ) - $3 = nterm exp (13.7: 3) --> $$ = nterm exp (13.1-7: 64) -Entering state 8 -Next token is token '=' (13.9: ) -Shifting token '=' (13.9: ) +Next token is token '=' () +Shifting token '=' () Entering state 18 Reading a token -Next token is token number (13.11-12: 64) -Shifting token number (13.11-12: 64) +Next token is token number (1111) +Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (13.11-12: 64) --> $$ = nterm exp (13.11-12: 64) + $1 = token number (1111) +-> $$ = nterm exp (1111) Entering state 27 Reading a token -Next token is token '\n' (13.13-14.0: ) +Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (13.1-7: 64) - $2 = token '=' (13.9: ) - $3 = nterm exp (13.11-12: 64) --> $$ = nterm exp (13.1-12: 64) + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) Entering state 8 -Next token is token '\n' (13.13-14.0: ) -Shifting token '\n' (13.13-14.0: ) +Next token is token '\n' () +Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (13.1-12: 64) - $2 = token '\n' (13.13-14.0: ) --> $$ = nterm line (13.1-14.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-13.0: ) - $2 = nterm line (13.1-14.0: ) --> $$ = nterm input (1.1-14.0: ) + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token end of input (14.1: ) +Shifting token end of input () Entering state 16 -Cleanup: popping token end of input (14.1: ) -Cleanup: popping nterm input (1.1-14.0: ) +Cleanup: popping token end of input () +Cleanup: popping nterm input () + +%code top { /* -*- c -*- */ +/* Adjust to the compiler. + We used to do it here, but each time we add a new line, + we have to adjust all the line numbers in error messages. + It's simpler to use a constant include to a varying file. */ +#include +} + +%define parse.error verbose +%debug +%{ +#include +#include +#define MAX 1000 +static int yylex (void); +#include + +/* !POSIX */ static void yyerror (const char *msg); +%} + +%token + t1 1 "1" + t2 2 "2" + t3 3 "3" + t4 4 "4" + t5 5 "5" + t6 6 "6" + t7 7 "7" + t8 8 "8" + t9 9 "9" + t10 10 "10" + t11 11 "11" + t12 12 "12" + t13 13 "13" + t14 14 "14" + t15 15 "15" + t16 16 "16" + t17 17 "17" + t18 18 "18" + t19 19 "19" + t20 20 "20" + t21 21 "21" + t22 22 "22" + t23 23 "23" + t24 24 "24" + t25 25 "25" + t26 26 "26" + t27 27 "27" + t28 28 "28" + t29 29 "29" + t30 30 "30" + t31 31 "31" + t32 32 "32" + t33 33 "33" + t34 34 "34" + t35 35 "35" + t36 36 "36" + t37 37 "37" + t38 38 "38" + t39 39 "39" + t40 40 "40" + t41 41 "41" + t42 42 "42" + t43 43 "43" + t44 44 "44" + t45 45 "45" + t46 46 "46" + t47 47 "47" + t48 48 "48" + t49 49 "49" + t50 50 "50" + t51 51 "51" + t52 52 "52" + t53 53 "53" + t54 54 "54" + t55 55 "55" + t56 56 "56" + t57 57 "57" + t58 58 "58" + t59 59 "59" + t60 60 "60" + t61 61 "61" + t62 62 "62" + t63 63 "63" + t64 64 "64" + t65 65 "65" + t66 66 "66" + t67 67 "67" + t68 68 "68" + t69 69 "69" + t70 70 "70" + t71 71 "71" + t72 72 "72" + t73 73 "73" + t74 74 "74" + t75 75 "75" + t76 76 "76" + t77 77 "77" + t78 78 "78" + t79 79 "79" + t80 80 "80" + t81 81 "81" + t82 82 "82" + t83 83 "83" + t84 84 "84" + t85 85 "85" + t86 86 "86" + t87 87 "87" + t88 88 "88" + t89 89 "89" + t90 90 "90" + t91 91 "91" + t92 92 "92" + t93 93 "93" + t94 94 "94" + t95 95 "95" + t96 96 "96" + t97 97 "97" + t98 98 "98" + t99 99 "99" + t100 100 "100" + t101 101 "101" + t102 102 "102" + t103 103 "103" + t104 104 "104" + t105 105 "105" + t106 106 "106" + t107 107 "107" + t108 108 "108" + t109 109 "109" + t110 110 "110" + t111 111 "111" + t112 112 "112" + t113 113 "113" + t114 114 "114" + t115 115 "115" + t116 116 "116" + t117 117 "117" + t118 118 "118" + t119 119 "119" + t120 120 "120" + t121 121 "121" + t122 122 "122" + t123 123 "123" + t124 124 "124" + t125 125 "125" + t126 126 "126" + t127 127 "127" + t128 128 "128" + t129 129 "129" + t130 130 "130" + t131 131 "131" + t132 132 "132" + t133 133 "133" + t134 134 "134" + t135 135 "135" + t136 136 "136" + t137 137 "137" + t138 138 "138" + t139 139 "139" + t140 140 "140" + t141 141 "141" + t142 142 "142" + t143 143 "143" + t144 144 "144" + t145 145 "145" + t146 146 "146" + t147 147 "147" + t148 148 "148" + t149 149 "149" + t150 150 "150" + t151 151 "151" + t152 152 "152" + t153 153 "153" + t154 154 "154" + t155 155 "155" + t156 156 "156" + t157 157 "157" + t158 158 "158" + t159 159 "159" + t160 160 "160" + t161 161 "161" + t162 162 "162" + t163 163 "163" + t164 164 "164" + t165 165 "165" + t166 166 "166" + t167 167 "167" + t168 168 "168" + t169 169 "169" + t170 170 "170" + t171 171 "171" + t172 172 "172" + t173 173 "173" + t174 174 "174" + t175 175 "175" + t176 176 "176" + t177 177 "177" + t178 178 "178" + t179 179 "179" + t180 180 "180" + t181 181 "181" + t182 182 "182" + t183 183 "183" + t184 184 "184" + t185 185 "185" + t186 186 "186" + t187 187 "187" + t188 188 "188" + t189 189 "189" + t190 190 "190" + t191 191 "191" + t192 192 "192" + t193 193 "193" + t194 194 "194" + t195 195 "195" + t196 196 "196" + t197 197 "197" + t198 198 "198" + t199 199 "199" + t200 200 "200" + t201 201 "201" + t202 202 "202" + t203 203 "203" + t204 204 "204" + t205 205 "205" + t206 206 "206" + t207 207 "207" + t208 208 "208" + t209 209 "209" + t210 210 "210" + t211 211 "211" + t212 212 "212" + t213 213 "213" + t214 214 "214" + t215 215 "215" + t216 216 "216" + t217 217 "217" + t218 218 "218" + t219 219 "219" + t220 220 "220" + t221 221 "221" + t222 222 "222" + t223 223 "223" + t224 224 "224" + t225 225 "225" + t226 226 "226" + t227 227 "227" + t228 228 "228" + t229 229 "229" + t230 230 "230" + t231 231 "231" + t232 232 "232" + t233 233 "233" + t234 234 "234" + t235 235 "235" + t236 236 "236" + t237 237 "237" + t238 238 "238" + t239 239 "239" + t240 240 "240" + t241 241 "241" + t242 242 "242" + t243 243 "243" + t244 244 "244" + t245 245 "245" + t246 246 "246" + t247 247 "247" + t248 248 "248" + t249 249 "249" + t250 250 "250" + t251 251 "251" + t252 252 "252" + t253 253 "253" + t254 254 "254" + t255 255 "255" + t256 256 "256" + t257 257 "257" + t258 258 "258" + t259 259 "259" + t260 260 "260" + t261 261 "261" + t262 262 "262" + t263 263 "263" + t264 264 "264" + t265 265 "265" + t266 266 "266" + t267 267 "267" + t268 268 "268" + t269 269 "269" + t270 270 "270" + t271 271 "271" + t272 272 "272" + t273 273 "273" + t274 274 "274" + t275 275 "275" + t276 276 "276" + t277 277 "277" + t278 278 "278" + t279 279 "279" + t280 280 "280" + t281 281 "281" + t282 282 "282" + t283 283 "283" + t284 284 "284" + t285 285 "285" + t286 286 "286" + t287 287 "287" + t288 288 "288" + t289 289 "289" + t290 290 "290" + t291 291 "291" + t292 292 "292" + t293 293 "293" + t294 294 "294" + t295 295 "295" + t296 296 "296" + t297 297 "297" + t298 298 "298" + t299 299 "299" + t300 300 "300" + t301 301 "301" + t302 302 "302" + t303 303 "303" + t304 304 "304" + t305 305 "305" + t306 306 "306" + t307 307 "307" + t308 308 "308" + t309 309 "309" + t310 310 "310" + t311 311 "311" + t312 312 "312" + t313 313 "313" + t314 314 "314" + t315 315 "315" + t316 316 "316" + t317 317 "317" + t318 318 "318" + t319 319 "319" + t320 320 "320" + t321 321 "321" + t322 322 "322" + t323 323 "323" + t324 324 "324" + t325 325 "325" + t326 326 "326" + t327 327 "327" + t328 328 "328" + t329 329 "329" + t330 330 "330" + t331 331 "331" + t332 332 "332" + t333 333 "333" + t334 334 "334" + t335 335 "335" + t336 336 "336" + t337 337 "337" + t338 338 "338" + t339 339 "339" + t340 340 "340" + t341 341 "341" + t342 342 "342" + t343 343 "343" + t344 344 "344" + t345 345 "345" + t346 346 "346" + t347 347 "347" + t348 348 "348" + t349 349 "349" + t350 350 "350" + t351 351 "351" + t352 352 "352" + t353 353 "353" + t354 354 "354" + t355 355 "355" + t356 356 "356" + t357 357 "357" + t358 358 "358" + t359 359 "359" + t360 360 "360" + t361 361 "361" + t362 362 "362" + t363 363 "363" + t364 364 "364" + t365 365 "365" + t366 366 "366" + t367 367 "367" + t368 368 "368" + t369 369 "369" + t370 370 "370" + t371 371 "371" + t372 372 "372" + t373 373 "373" + t374 374 "374" + t375 375 "375" + t376 376 "376" + t377 377 "377" + t378 378 "378" + t379 379 "379" + t380 380 "380" + t381 381 "381" + t382 382 "382" + t383 383 "383" + t384 384 "384" + t385 385 "385" + t386 386 "386" + t387 387 "387" + t388 388 "388" + t389 389 "389" + t390 390 "390" + t391 391 "391" + t392 392 "392" + t393 393 "393" + t394 394 "394" + t395 395 "395" + t396 396 "396" + t397 397 "397" + t398 398 "398" + t399 399 "399" + t400 400 "400" + t401 401 "401" + t402 402 "402" + t403 403 "403" + t404 404 "404" + t405 405 "405" + t406 406 "406" + t407 407 "407" + t408 408 "408" + t409 409 "409" + t410 410 "410" + t411 411 "411" + t412 412 "412" + t413 413 "413" + t414 414 "414" + t415 415 "415" + t416 416 "416" + t417 417 "417" + t418 418 "418" + t419 419 "419" + t420 420 "420" + t421 421 "421" + t422 422 "422" + t423 423 "423" + t424 424 "424" + t425 425 "425" + t426 426 "426" + t427 427 "427" + t428 428 "428" + t429 429 "429" + t430 430 "430" + t431 431 "431" + t432 432 "432" + t433 433 "433" + t434 434 "434" + t435 435 "435" + t436 436 "436" + t437 437 "437" + t438 438 "438" + t439 439 "439" + t440 440 "440" + t441 441 "441" + t442 442 "442" + t443 443 "443" + t444 444 "444" + t445 445 "445" + t446 446 "446" + t447 447 "447" + t448 448 "448" + t449 449 "449" + t450 450 "450" + t451 451 "451" + t452 452 "452" + t453 453 "453" + t454 454 "454" + t455 455 "455" + t456 456 "456" + t457 457 "457" + t458 458 "458" + t459 459 "459" + t460 460 "460" + t461 461 "461" + t462 462 "462" + t463 463 "463" + t464 464 "464" + t465 465 "465" + t466 466 "466" + t467 467 "467" + t468 468 "468" + t469 469 "469" + t470 470 "470" + t471 471 "471" + t472 472 "472" + t473 473 "473" + t474 474 "474" + t475 475 "475" + t476 476 "476" + t477 477 "477" + t478 478 "478" + t479 479 "479" + t480 480 "480" + t481 481 "481" + t482 482 "482" + t483 483 "483" + t484 484 "484" + t485 485 "485" + t486 486 "486" + t487 487 "487" + t488 488 "488" + t489 489 "489" + t490 490 "490" + t491 491 "491" + t492 492 "492" + t493 493 "493" + t494 494 "494" + t495 495 "495" + t496 496 "496" + t497 497 "497" + t498 498 "498" + t499 499 "499" + t500 500 "500" + t501 501 "501" + t502 502 "502" + t503 503 "503" + t504 504 "504" + t505 505 "505" + t506 506 "506" + t507 507 "507" + t508 508 "508" + t509 509 "509" + t510 510 "510" + t511 511 "511" + t512 512 "512" + t513 513 "513" + t514 514 "514" + t515 515 "515" + t516 516 "516" + t517 517 "517" + t518 518 "518" + t519 519 "519" + t520 520 "520" + t521 521 "521" + t522 522 "522" + t523 523 "523" + t524 524 "524" + t525 525 "525" + t526 526 "526" + t527 527 "527" + t528 528 "528" + t529 529 "529" + t530 530 "530" + t531 531 "531" + t532 532 "532" + t533 533 "533" + t534 534 "534" + t535 535 "535" + t536 536 "536" + t537 537 "537" + t538 538 "538" + t539 539 "539" + t540 540 "540" + t541 541 "541" + t542 542 "542" + t543 543 "543" + t544 544 "544" + t545 545 "545" + t546 546 "546" + t547 547 "547" + t548 548 "548" + t549 549 "549" + t550 550 "550" + t551 551 "551" + t552 552 "552" + t553 553 "553" + t554 554 "554" + t555 555 "555" + t556 556 "556" + t557 557 "557" + t558 558 "558" + t559 559 "559" + t560 560 "560" + t561 561 "561" + t562 562 "562" + t563 563 "563" + t564 564 "564" + t565 565 "565" + t566 566 "566" + t567 567 "567" + t568 568 "568" + t569 569 "569" + t570 570 "570" + t571 571 "571" + t572 572 "572" + t573 573 "573" + t574 574 "574" + t575 575 "575" + t576 576 "576" + t577 577 "577" + t578 578 "578" + t579 579 "579" + t580 580 "580" + t581 581 "581" + t582 582 "582" + t583 583 "583" + t584 584 "584" + t585 585 "585" + t586 586 "586" + t587 587 "587" + t588 588 "588" + t589 589 "589" + t590 590 "590" + t591 591 "591" + t592 592 "592" + t593 593 "593" + t594 594 "594" + t595 595 "595" + t596 596 "596" + t597 597 "597" + t598 598 "598" + t599 599 "599" + t600 600 "600" + t601 601 "601" + t602 602 "602" + t603 603 "603" + t604 604 "604" + t605 605 "605" + t606 606 "606" + t607 607 "607" + t608 608 "608" + t609 609 "609" + t610 610 "610" + t611 611 "611" + t612 612 "612" + t613 613 "613" + t614 614 "614" + t615 615 "615" + t616 616 "616" + t617 617 "617" + t618 618 "618" + t619 619 "619" + t620 620 "620" + t621 621 "621" + t622 622 "622" + t623 623 "623" + t624 624 "624" + t625 625 "625" + t626 626 "626" + t627 627 "627" + t628 628 "628" + t629 629 "629" + t630 630 "630" + t631 631 "631" + t632 632 "632" + t633 633 "633" + t634 634 "634" + t635 635 "635" + t636 636 "636" + t637 637 "637" + t638 638 "638" + t639 639 "639" + t640 640 "640" + t641 641 "641" + t642 642 "642" + t643 643 "643" + t644 644 "644" + t645 645 "645" + t646 646 "646" + t647 647 "647" + t648 648 "648" + t649 649 "649" + t650 650 "650" + t651 651 "651" + t652 652 "652" + t653 653 "653" + t654 654 "654" + t655 655 "655" + t656 656 "656" + t657 657 "657" + t658 658 "658" + t659 659 "659" + t660 660 "660" + t661 661 "661" + t662 662 "662" + t663 663 "663" + t664 664 "664" + t665 665 "665" + t666 666 "666" + t667 667 "667" + t668 668 "668" + t669 669 "669" + t670 670 "670" + t671 671 "671" + t672 672 "672" + t673 673 "673" + t674 674 "674" + t675 675 "675" + t676 676 "676" + t677 677 "677" + t678 678 "678" + t679 679 "679" + t680 680 "680" + t681 681 "681" + t682 682 "682" + t683 683 "683" + t684 684 "684" + t685 685 "685" + t686 686 "686" + t687 687 "687" + t688 688 "688" + t689 689 "689" + t690 690 "690" + t691 691 "691" + t692 692 "692" + t693 693 "693" + t694 694 "694" + t695 695 "695" + t696 696 "696" + t697 697 "697" + t698 698 "698" + t699 699 "699" + t700 700 "700" + t701 701 "701" + t702 702 "702" + t703 703 "703" + t704 704 "704" + t705 705 "705" + t706 706 "706" + t707 707 "707" + t708 708 "708" + t709 709 "709" + t710 710 "710" + t711 711 "711" + t712 712 "712" + t713 713 "713" + t714 714 "714" + t715 715 "715" + t716 716 "716" + t717 717 "717" + t718 718 "718" + t719 719 "719" + t720 720 "720" + t721 721 "721" + t722 722 "722" + t723 723 "723" + t724 724 "724" + t725 725 "725" + t726 726 "726" + t727 727 "727" + t728 728 "728" + t729 729 "729" + t730 730 "730" + t731 731 "731" + t732 732 "732" + t733 733 "733" + t734 734 "734" + t735 735 "735" + t736 736 "736" + t737 737 "737" + t738 738 "738" + t739 739 "739" + t740 740 "740" + t741 741 "741" + t742 742 "742" + t743 743 "743" + t744 744 "744" + t745 745 "745" + t746 746 "746" + t747 747 "747" + t748 748 "748" + t749 749 "749" + t750 750 "750" + t751 751 "751" + t752 752 "752" + t753 753 "753" + t754 754 "754" + t755 755 "755" + t756 756 "756" + t757 757 "757" + t758 758 "758" + t759 759 "759" + t760 760 "760" + t761 761 "761" + t762 762 "762" + t763 763 "763" + t764 764 "764" + t765 765 "765" + t766 766 "766" + t767 767 "767" + t768 768 "768" + t769 769 "769" + t770 770 "770" + t771 771 "771" + t772 772 "772" + t773 773 "773" + t774 774 "774" + t775 775 "775" + t776 776 "776" + t777 777 "777" + t778 778 "778" + t779 779 "779" + t780 780 "780" + t781 781 "781" + t782 782 "782" + t783 783 "783" + t784 784 "784" + t785 785 "785" + t786 786 "786" + t787 787 "787" + t788 788 "788" + t789 789 "789" + t790 790 "790" + t791 791 "791" + t792 792 "792" + t793 793 "793" + t794 794 "794" + t795 795 "795" + t796 796 "796" + t797 797 "797" + t798 798 "798" + t799 799 "799" + t800 800 "800" + t801 801 "801" + t802 802 "802" + t803 803 "803" + t804 804 "804" + t805 805 "805" + t806 806 "806" + t807 807 "807" + t808 808 "808" + t809 809 "809" + t810 810 "810" + t811 811 "811" + t812 812 "812" + t813 813 "813" + t814 814 "814" + t815 815 "815" + t816 816 "816" + t817 817 "817" + t818 818 "818" + t819 819 "819" + t820 820 "820" + t821 821 "821" + t822 822 "822" + t823 823 "823" + t824 824 "824" + t825 825 "825" + t826 826 "826" + t827 827 "827" + t828 828 "828" + t829 829 "829" + t830 830 "830" + t831 831 "831" + t832 832 "832" + t833 833 "833" + t834 834 "834" + t835 835 "835" + t836 836 "836" + t837 837 "837" + t838 838 "838" + t839 839 "839" + t840 840 "840" + t841 841 "841" + t842 842 "842" + t843 843 "843" + t844 844 "844" + t845 845 "845" + t846 846 "846" + t847 847 "847" + t848 848 "848" + t849 849 "849" + t850 850 "850" + t851 851 "851" + t852 852 "852" + t853 853 "853" + t854 854 "854" + t855 855 "855" + t856 856 "856" + t857 857 "857" + t858 858 "858" + t859 859 "859" + t860 860 "860" + t861 861 "861" + t862 862 "862" + t863 863 "863" + t864 864 "864" + t865 865 "865" + t866 866 "866" + t867 867 "867" + t868 868 "868" + t869 869 "869" + t870 870 "870" + t871 871 "871" + t872 872 "872" + t873 873 "873" + t874 874 "874" + t875 875 "875" + t876 876 "876" + t877 877 "877" + t878 878 "878" + t879 879 "879" + t880 880 "880" + t881 881 "881" + t882 882 "882" + t883 883 "883" + t884 884 "884" + t885 885 "885" + t886 886 "886" + t887 887 "887" + t888 888 "888" + t889 889 "889" + t890 890 "890" + t891 891 "891" + t892 892 "892" + t893 893 "893" + t894 894 "894" + t895 895 "895" + t896 896 "896" + t897 897 "897" + t898 898 "898" + t899 899 "899" + t900 900 "900" + t901 901 "901" + t902 902 "902" + t903 903 "903" + t904 904 "904" + t905 905 "905" + t906 906 "906" + t907 907 "907" + t908 908 "908" + t909 909 "909" + t910 910 "910" + t911 911 "911" + t912 912 "912" + t913 913 "913" + t914 914 "914" + t915 915 "915" + t916 916 "916" + t917 917 "917" + t918 918 "918" + t919 919 "919" + t920 920 "920" + t921 921 "921" + t922 922 "922" + t923 923 "923" + t924 924 "924" + t925 925 "925" + t926 926 "926" + t927 927 "927" + t928 928 "928" + t929 929 "929" + t930 930 "930" + t931 931 "931" + t932 932 "932" + t933 933 "933" + t934 934 "934" + t935 935 "935" + t936 936 "936" + t937 937 "937" + t938 938 "938" + t939 939 "939" + t940 940 "940" + t941 941 "941" + t942 942 "942" + t943 943 "943" + t944 944 "944" + t945 945 "945" + t946 946 "946" + t947 947 "947" + t948 948 "948" + t949 949 "949" + t950 950 "950" + t951 951 "951" + t952 952 "952" + t953 953 "953" + t954 954 "954" + t955 955 "955" + t956 956 "956" + t957 957 "957" + t958 958 "958" + t959 959 "959" + t960 960 "960" + t961 961 "961" + t962 962 "962" + t963 963 "963" + t964 964 "964" + t965 965 "965" + t966 966 "966" + t967 967 "967" + t968 968 "968" + t969 969 "969" + t970 970 "970" + t971 971 "971" + t972 972 "972" + t973 973 "973" + t974 974 "974" + t975 975 "975" + t976 976 "976" + t977 977 "977" + t978 978 "978" + t979 979 "979" + t980 980 "980" + t981 981 "981" + t982 982 "982" + t983 983 "983" + t984 984 "984" + t985 985 "985" + t986 986 "986" + t987 987 "987" + t988 988 "988" + t989 989 "989" + t990 990 "990" + t991 991 "991" + t992 992 "992" + t993 993 "993" + t994 994 "994" + t995 995 "995" + t996 996 "996" + t997 997 "997" + t998 998 "998" + t999 999 "999" + t1000 1000 "1000" + +%% +exp: "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" + "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" + "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" + "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" + "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" + "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" + "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" + "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" + "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" + "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" + "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" + "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" + "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" + "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" + "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" "196" + "197" "198" "199" "200" "201" "202" "203" "204" "205" "206" "207" "208" + "209" "210" "211" "212" "213" "214" "215" "216" "217" "218" "219" "220" + "221" "222" "223" "224" "225" "226" "227" "228" "229" "230" "231" "232" + "233" "234" "235" "236" "237" "238" "239" "240" "241" "242" "243" "244" + "245" "246" "247" "248" "249" "250" "251" "252" "253" "254" "255" "256" + "257" "258" "259" "260" "261" "262" "263" "264" "265" "266" "267" "268" + "269" "270" "271" "272" "273" "274" "275" "276" "277" "278" "279" "280" + "281" "282" "283" "284" "285" "286" "287" "288" "289" "290" "291" "292" + "293" "294" "295" "296" "297" "298" "299" "300" "301" "302" "303" "304" + "305" "306" "307" "308" "309" "310" "311" "312" "313" "314" "315" "316" + "317" "318" "319" "320" "321" "322" "323" "324" "325" "326" "327" "328" + "329" "330" "331" "332" "333" "334" "335" "336" "337" "338" "339" "340" + "341" "342" "343" "344" "345" "346" "347" "348" "349" "350" "351" "352" + "353" "354" "355" "356" "357" "358" "359" "360" "361" "362" "363" "364" + "365" "366" "367" "368" "369" "370" "371" "372" "373" "374" "375" "376" + "377" "378" "379" "380" "381" "382" "383" "384" "385" "386" "387" "388" + "389" "390" "391" "392" "393" "394" "395" "396" "397" "398" "399" "400" + "401" "402" "403" "404" "405" "406" "407" "408" "409" "410" "411" "412" + "413" "414" "415" "416" "417" "418" "419" "420" "421" "422" "423" "424" + "425" "426" "427" "428" "429" "430" "431" "432" "433" "434" "435" "436" + "437" "438" "439" "440" "441" "442" "443" "444" "445" "446" "447" "448" + "449" "450" "451" "452" "453" "454" "455" "456" "457" "458" "459" "460" + "461" "462" "463" "464" "465" "466" "467" "468" "469" "470" "471" "472" + "473" "474" "475" "476" "477" "478" "479" "480" "481" "482" "483" "484" + "485" "486" "487" "488" "489" "490" "491" "492" "493" "494" "495" "496" + "497" "498" "499" "500" "501" "502" "503" "504" "505" "506" "507" "508" + "509" "510" "511" "512" "513" "514" "515" "516" "517" "518" "519" "520" + "521" "522" "523" "524" "525" "526" "527" "528" "529" "530" "531" "532" + "533" "534" "535" "536" "537" "538" "539" "540" "541" "542" "543" "544" + "545" "546" "547" "548" "549" "550" "551" "552" "553" "554" "555" "556" + "557" "558" "559" "560" "561" "562" "563" "564" "565" "566" "567" "568" + "569" "570" "571" "572" "573" "574" "575" "576" "577" "578" "579" "580" + "581" "582" "583" "584" "585" "586" "587" "588" "589" "590" "591" "592" + "593" "594" "595" "596" "597" "598" "599" "600" "601" "602" "603" "604" + "605" "606" "607" "608" "609" "610" "611" "612" "613" "614" "615" "616" + "617" "618" "619" "620" "621" "622" "623" "624" "625" "626" "627" "628" + "629" "630" "631" "632" "633" "634" "635" "636" "637" "638" "639" "640" + "641" "642" "643" "644" "645" "646" "647" "648" "649" "650" "651" "652" + "653" "654" "655" "656" "657" "658" "659" "660" "661" "662" "663" "664" + "665" "666" "667" "668" "669" "670" "671" "672" "673" "674" "675" "676" + "677" "678" "679" "680" "681" "682" "683" "684" "685" "686" "687" "688" + "689" "690" "691" "692" "693" "694" "695" "696" "697" "698" "699" "700" + "701" "702" "703" "704" "705" "706" "707" "708" "709" "710" "711" "712" + "713" "714" "715" "716" "717" "718" "719" "720" "721" "722" "723" "724" + "725" "726" "727" "728" "729" "730" "731" "732" "733" "734" "735" "736" + "737" "738" "739" "740" "741" "742" "743" "744" "745" "746" "747" "748" + "749" "750" "751" "752" "753" "754" "755" "756" "757" "758" "759" "760" + "761" "762" "763" "764" "765" "766" "767" "768" "769" "770" "771" "772" + "773" "774" "775" "776" "777" "778" "779" "780" "781" "782" "783" "784" + "785" "786" "787" "788" "789" "790" "791" "792" "793" "794" "795" "796" + "797" "798" "799" "800" "801" "802" "803" "804" "805" "806" "807" "808" + "809" "810" "811" "812" "813" "814" "815" "816" "817" "818" "819" "820" + "821" "822" "823" "824" "825" "826" "827" "828" "829" "830" "831" "832" + "833" "834" "835" "836" "837" "838" "839" "840" "841" "842" "843" "844" + "845" "846" "847" "848" "849" "850" "851" "852" "853" "854" "855" "856" + "857" "858" "859" "860" "861" "862" "863" "864" "865" "866" "867" "868" + "869" "870" "871" "872" "873" "874" "875" "876" "877" "878" "879" "880" + "881" "882" "883" "884" "885" "886" "887" "888" "889" "890" "891" "892" + "893" "894" "895" "896" "897" "898" "899" "900" "901" "902" "903" "904" + "905" "906" "907" "908" "909" "910" "911" "912" "913" "914" "915" "916" + "917" "918" "919" "920" "921" "922" "923" "924" "925" "926" "927" "928" + "929" "930" "931" "932" "933" "934" "935" "936" "937" "938" "939" "940" + "941" "942" "943" "944" "945" "946" "947" "948" "949" "950" "951" "952" + "953" "954" "955" "956" "957" "958" "959" "960" "961" "962" "963" "964" + "965" "966" "967" "968" "969" "970" "971" "972" "973" "974" "975" "976" + "977" "978" "979" "980" "981" "982" "983" "984" "985" "986" "987" "988" + "989" "990" "991" "992" "993" "994" "995" "996" "997" "998" "999" "1000" + ; +%% +#include + + + + +/* A C error reporting function. */ +/* !POSIX */ static +void yyerror (const char *msg) +{ + fprintf (stderr, "%s\n", msg); +} +static int +yylex (void) +{ + static int counter = 1; + if (counter <= MAX) + return counter++; + assert (counter++ == MAX + 1); + return 0; +} +#include /* getenv. */ +#include /* strcmp. */ +int +main (int argc, char const* argv[]) +{ + (void) argc; + (void) argv; + return yyparse (); +} stderr: - | (1 + 1) / (1 - 1) -./calc.at:1487: $PREPARSER ./calc input -561. calc.at:1486: ok +606. torture.at:270: testing State number type: 128 states ... +./torture.at:270: ruby $abs_top_srcdir/tests/linear 128 >input.y || exit 77 Starting parse Entering state 0 Reading a token @@ -220485,808 +222759,55 @@ -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token -Next token is token '=' (1.11: ) +Next token is token '+' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 -Next token is token '=' (1.11: ) +Next token is token '+' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 18 -Reading a token -Next token is token "number" (1.13: 7) -Shifting token "number" (1.13: 7) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.13: 7) --> $$ = nterm exp (1.13: 7) -Entering state 27 -Reading a token -Next token is token '\n' (1.14-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-9: 7) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13: 7) --> $$ = nterm exp (1.1-13: 7) -Entering state 8 -Next token is token '\n' (1.14-2.0: ) -Shifting token '\n' (1.14-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-13: 7) - $2 = token '\n' (1.14-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Next token is token "number" (2.1: 1) -Shifting token "number" (2.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2.1: 1) --> $$ = nterm exp (2.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (2.3: ) -Shifting token '+' (2.3: ) +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) Entering state 20 Reading a token -Next token is token "number" (2.5: 2) -Shifting token "number" (2.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2.5: 2) --> $$ = nterm exp (2.5: 2) -Entering state 29 -Reading a token -Next token is token '*' (2.7: ) -Shifting token '*' (2.7: ) -Entering state 21 -Reading a token -Next token is token '-' (2.9: ) -Shifting token '-' (2.9: ) -Entering state 2 -Reading a token -Next token is token "number" (2.10: 3) -Shifting token "number" (2.10: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2.10: 3) --> $$ = nterm exp (2.10: 3) -Entering state 10 -Reading a token -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (2.9: ) - $2 = nterm exp (2.10: 3) --> $$ = nterm exp (2.9-10: -3) -Entering state 30 -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (2.5: 2) - $2 = token '*' (2.7: ) - $3 = nterm exp (2.9-10: -3) --> $$ = nterm exp (2.5-10: -6) -Entering state 29 -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (2.1: 1) - $2 = token '+' (2.3: ) - $3 = nterm exp (2.5-10: -6) --> $$ = nterm exp (2.1-10: -5) -Entering state 8 -Next token is token '=' (2.12: ) -Shifting token '=' (2.12: ) -Entering state 18 -Reading a token -Next token is token '-' (2.14: ) -Shifting token '-' (2.14: ) -Entering state 2 -Reading a token -Next token is token "number" (2.15: 5) -Shifting token "number" (2.15: 5) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2.15: 5) --> $$ = nterm exp (2.15: 5) -Entering state 10 -Reading a token -Next token is token '\n' (2.16-3.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (2.14: ) - $2 = nterm exp (2.15: 5) --> $$ = nterm exp (2.14-15: -5) -Entering state 27 -Next token is token '\n' (2.16-3.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (2.1-10: -5) - $2 = token '=' (2.12: ) - $3 = nterm exp (2.14-15: -5) --> $$ = nterm exp (2.1-15: -5) -Entering state 8 -Next token is token '\n' (2.16-3.0: ) -Shifting token '\n' (2.16-3.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2.1-15: -5) - $2 = token '\n' (2.16-3.0: ) --> $$ = nterm line (2.1-3.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-2.0: ) - $2 = nterm line (2.1-3.0: ) --> $$ = nterm input (1.1-3.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (3.1-4.0: ) -Shifting token '\n' (3.1-4.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (3.1-4.0: ) --> $$ = nterm line (3.1-4.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-3.0: ) - $2 = nterm line (3.1-4.0: ) --> $$ = nterm input (1.1-4.0: ) -Entering state 6 -Reading a token -Next token is token '-' (4.1: ) -Shifting token '-' (4.1: ) -Entering state 2 -Reading a token -Next token is token "number" (4.2: 1) -Shifting token "number" (4.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (4.2: 1) --> $$ = nterm exp (4.2: 1) -Entering state 10 -Reading a token -Next token is token '^' (4.3: ) -Shifting token '^' (4.3: ) -Entering state 23 -Reading a token -Next token is token "number" (4.4: 2) -Shifting token "number" (4.4: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (4.4: 2) --> $$ = nterm exp (4.4: 2) -Entering state 32 -Reading a token -Next token is token '=' (4.6: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (4.2: 1) - $2 = token '^' (4.3: ) - $3 = nterm exp (4.4: 2) --> $$ = nterm exp (4.2-4: 1) -Entering state 10 -Next token is token '=' (4.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (4.1: ) - $2 = nterm exp (4.2-4: 1) --> $$ = nterm exp (4.1-4: -1) -Entering state 8 -Next token is token '=' (4.6: ) -Shifting token '=' (4.6: ) -Entering state 18 -Reading a token -Next token is token '-' (4.8: ) -Shifting token '-' (4.8: ) -Entering state 2 -Reading a token -Next token is token "number" (4.9: 1) -Shifting token "number" (4.9: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (4.9: 1) --> $$ = nterm exp (4.9: 1) -Entering state 10 -Reading a token -Next token is token '\n' (4.10-5.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (4.8: ) - $2 = nterm exp (4.9: 1) --> $$ = nterm exp (4.8-9: -1) -Entering state 27 -Next token is token '\n' (4.10-5.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (4.1-4: -1) - $2 = token '=' (4.6: ) - $3 = nterm exp (4.8-9: -1) --> $$ = nterm exp (4.1-9: -1) -Entering state 8 -Next token is token '\n' (4.10-5.0: ) -Shifting token '\n' (4.10-5.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (4.1-9: -1) - $2 = token '\n' (4.10-5.0: ) --> $$ = nterm line (4.1-5.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-4.0: ) - $2 = nterm line (4.1-5.0: ) --> $$ = nterm input (1.1-5.0: ) -Entering state 6 -Reading a token -Next token is token '(' (5.1: ) -Shifting token '(' (5.1: ) -Entering state 4 -Reading a token -Next token is token '-' (5.2: ) -Shifting token '-' (5.2: ) -Entering state 2 -Reading a token -Next token is token "number" (5.3: 1) -Shifting token "number" (5.3: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (5.3: 1) --> $$ = nterm exp (5.3: 1) -Entering state 10 -Reading a token -Next token is token ')' (5.4: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (5.2: ) - $2 = nterm exp (5.3: 1) --> $$ = nterm exp (5.2-3: -1) -Entering state 12 -Next token is token ')' (5.4: ) -Shifting token ')' (5.4: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (5.1: ) - $2 = nterm exp (5.2-3: -1) - $3 = token ')' (5.4: ) --> $$ = nterm exp (5.1-4: -1) -Entering state 8 -Reading a token -Next token is token '^' (5.5: ) -Shifting token '^' (5.5: ) -Entering state 23 -Reading a token -Next token is token "number" (5.6: 2) -Shifting token "number" (5.6: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (5.6: 2) --> $$ = nterm exp (5.6: 2) -Entering state 32 -Reading a token -Next token is token '=' (5.8: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (5.1-4: -1) - $2 = token '^' (5.5: ) - $3 = nterm exp (5.6: 2) --> $$ = nterm exp (5.1-6: 1) -Entering state 8 -Next token is token '=' (5.8: ) -Shifting token '=' (5.8: ) -Entering state 18 -Reading a token -Next token is token "number" (5.10: 1) -Shifting token "number" (5.10: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (5.10: 1) --> $$ = nterm exp (5.10: 1) -Entering state 27 -Reading a token -Next token is token '\n' (5.11-6.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (5.1-6: 1) - $2 = token '=' (5.8: ) - $3 = nterm exp (5.10: 1) --> $$ = nterm exp (5.1-10: 1) -Entering state 8 -Next token is token '\n' (5.11-6.0: ) -Shifting token '\n' (5.11-6.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (5.1-10: 1) - $2 = token '\n' (5.11-6.0: ) --> $$ = nterm line (5.1-6.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-5.0: ) - $2 = nterm line (5.1-6.0: ) --> $$ = nterm input (1.1-6.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (6.1-7.0: ) -Shifting token '\n' (6.1-7.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (6.1-7.0: ) --> $$ = nterm line (6.1-7.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-6.0: ) - $2 = nterm line (6.1-7.0: ) --> $$ = nterm input (1.1-7.0: ) -Entering state 6 -Reading a token -Next token is token '-' (7.1: ) -Shifting token '-' (7.1: ) -Entering state 2 -Reading a token -Next token is token '-' (7.2: ) -Shifting token '-' (7.2: ) -Entering state 2 -Reading a token -Next token is token '-' (7.3: ) -Shifting token '-' (7.3: ) -Entering state 2 -Reading a token -Next token is token "number" (7.4: 1) -Shifting token "number" (7.4: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (7.4: 1) --> $$ = nterm exp (7.4: 1) -Entering state 10 -Reading a token -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.3: ) - $2 = nterm exp (7.4: 1) --> $$ = nterm exp (7.3-4: -1) -Entering state 10 -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.2: ) - $2 = nterm exp (7.3-4: -1) --> $$ = nterm exp (7.2-4: 1) -Entering state 10 -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.1: ) - $2 = nterm exp (7.2-4: 1) --> $$ = nterm exp (7.1-4: -1) -Entering state 8 -Next token is token '=' (7.6: ) -Shifting token '=' (7.6: ) -Entering state 18 -Reading a token -Next token is token '-' (7.8: ) -Shifting token '-' (7.8: ) -Entering state 2 -Reading a token -Next token is token "number" (7.9: 1) -Shifting token "number" (7.9: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (7.9: 1) --> $$ = nterm exp (7.9: 1) -Entering state 10 -Reading a token -Next token is token '\n' (7.10-8.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.8: ) - $2 = nterm exp (7.9: 1) --> $$ = nterm exp (7.8-9: -1) -Entering state 27 -Next token is token '\n' (7.10-8.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (7.1-4: -1) - $2 = token '=' (7.6: ) - $3 = nterm exp (7.8-9: -1) --> $$ = nterm exp (7.1-9: -1) -Entering state 8 -Next token is token '\n' (7.10-8.0: ) -Shifting token '\n' (7.10-8.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (7.1-9: -1) - $2 = token '\n' (7.10-8.0: ) --> $$ = nterm line (7.1-8.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-7.0: ) - $2 = nterm line (7.1-8.0: ) --> $$ = nterm input (1.1-8.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (8.1-9.0: ) -Shifting token '\n' (8.1-9.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (8.1-9.0: ) --> $$ = nterm line (8.1-9.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-8.0: ) - $2 = nterm line (8.1-9.0: ) --> $$ = nterm input (1.1-9.0: ) -Entering state 6 -Reading a token -Next token is token "number" (9.1: 1) -Shifting token "number" (9.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (9.1: 1) --> $$ = nterm exp (9.1: 1) -Entering state 8 -Reading a token -Next token is token '-' (9.3: ) -Shifting token '-' (9.3: ) -Entering state 19 -Reading a token -Next token is token "number" (9.5: 2) -Shifting token "number" (9.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (9.5: 2) --> $$ = nterm exp (9.5: 2) -Entering state 28 -Reading a token -Next token is token '-' (9.7: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (9.1: 1) - $2 = token '-' (9.3: ) - $3 = nterm exp (9.5: 2) --> $$ = nterm exp (9.1-5: -1) -Entering state 8 -Next token is token '-' (9.7: ) -Shifting token '-' (9.7: ) -Entering state 19 -Reading a token -Next token is token "number" (9.9: 3) -Shifting token "number" (9.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (9.9: 3) --> $$ = nterm exp (9.9: 3) -Entering state 28 -Reading a token -Next token is token '=' (9.11: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (9.1-5: -1) - $2 = token '-' (9.7: ) - $3 = nterm exp (9.9: 3) --> $$ = nterm exp (9.1-9: -4) -Entering state 8 -Next token is token '=' (9.11: ) -Shifting token '=' (9.11: ) -Entering state 18 -Reading a token -Next token is token '-' (9.13: ) -Shifting token '-' (9.13: ) -Entering state 2 -Reading a token -Next token is token "number" (9.14: 4) -Shifting token "number" (9.14: 4) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (9.14: 4) --> $$ = nterm exp (9.14: 4) -Entering state 10 -Reading a token -Next token is token '\n' (9.15-10.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (9.13: ) - $2 = nterm exp (9.14: 4) --> $$ = nterm exp (9.13-14: -4) -Entering state 27 -Next token is token '\n' (9.15-10.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (9.1-9: -4) - $2 = token '=' (9.11: ) - $3 = nterm exp (9.13-14: -4) --> $$ = nterm exp (9.1-14: -4) -Entering state 8 -Next token is token '\n' (9.15-10.0: ) -Shifting token '\n' (9.15-10.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (9.1-14: -4) - $2 = token '\n' (9.15-10.0: ) --> $$ = nterm line (9.1-10.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-9.0: ) - $2 = nterm line (9.1-10.0: ) --> $$ = nterm input (1.1-10.0: ) -Entering state 6 -Reading a token -Next token is token "number" (10.1: 1) -Shifting token "number" (10.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (10.1: 1) --> $$ = nterm exp (10.1: 1) -Entering state 8 -Reading a token -Next token is token '-' (10.3: ) -Shifting token '-' (10.3: ) -Entering state 19 -Reading a token -Next token is token '(' (10.5: ) -Shifting token '(' (10.5: ) -Entering state 4 -Reading a token -Next token is token "number" (10.6: 2) -Shifting token "number" (10.6: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (10.6: 2) --> $$ = nterm exp (10.6: 2) -Entering state 12 -Reading a token -Next token is token '-' (10.8: ) -Shifting token '-' (10.8: ) -Entering state 19 -Reading a token -Next token is token "number" (10.10: 3) -Shifting token "number" (10.10: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (10.10: 3) --> $$ = nterm exp (10.10: 3) -Entering state 28 -Reading a token -Next token is token ')' (10.11: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (10.6: 2) - $2 = token '-' (10.8: ) - $3 = nterm exp (10.10: 3) --> $$ = nterm exp (10.6-10: -1) -Entering state 12 -Next token is token ')' (10.11: ) -Shifting token ')' (10.11: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (10.5: ) - $2 = nterm exp (10.6-10: -1) - $3 = token ')' (10.11: ) --> $$ = nterm exp (10.5-11: -1) -Entering state 28 -Reading a token -Next token is token '=' (10.13: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (10.1: 1) - $2 = token '-' (10.3: ) - $3 = nterm exp (10.5-11: -1) --> $$ = nterm exp (10.1-11: 2) -Entering state 8 -Next token is token '=' (10.13: ) -Shifting token '=' (10.13: ) -Entering state 18 -Reading a token -Next token is token "number" (10.15: 2) -Shifting token "number" (10.15: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (10.15: 2) --> $$ = nterm exp (10.15: 2) -Entering state 27 -Reading a token -Next token is token '\n' (10.16-11.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (10.1-11: 2) - $2 = token '=' (10.13: ) - $3 = nterm exp (10.15: 2) --> $$ = nterm exp (10.1-15: 2) -Entering state 8 -Next token is token '\n' (10.16-11.0: ) -Shifting token '\n' (10.16-11.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (10.1-15: 2) - $2 = token '\n' (10.16-11.0: ) --> $$ = nterm line (10.1-11.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-10.0: ) - $2 = nterm line (10.1-11.0: ) --> $$ = nterm input (1.1-11.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (11.1-12.0: ) -Shifting token '\n' (11.1-12.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (11.1-12.0: ) --> $$ = nterm line (11.1-12.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-11.0: ) - $2 = nterm line (11.1-12.0: ) --> $$ = nterm input (1.1-12.0: ) -Entering state 6 -Reading a token -Next token is token "number" (12.1: 2) -Shifting token "number" (12.1: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (12.1: 2) --> $$ = nterm exp (12.1: 2) -Entering state 8 -Reading a token -Next token is token '^' (12.2: ) -Shifting token '^' (12.2: ) -Entering state 23 -Reading a token -Next token is token "number" (12.3: 2) -Shifting token "number" (12.3: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (12.3: 2) --> $$ = nterm exp (12.3: 2) -Entering state 32 -Reading a token -Next token is token '^' (12.4: ) -Shifting token '^' (12.4: ) -Entering state 23 -Reading a token -Next token is token "number" (12.5: 3) -Shifting token "number" (12.5: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (12.5: 3) --> $$ = nterm exp (12.5: 3) -Entering state 32 -Reading a token -Next token is token '=' (12.7: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (12.3: 2) - $2 = token '^' (12.4: ) - $3 = nterm exp (12.5: 3) --> $$ = nterm exp (12.3-5: 8) -Entering state 32 -Next token is token '=' (12.7: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (12.1: 2) - $2 = token '^' (12.2: ) - $3 = nterm exp (12.3-5: 8) --> $$ = nterm exp (12.1-5: 256) -Entering state 8 -Next token is token '=' (12.7: ) -Shifting token '=' (12.7: ) -Entering state 18 -Reading a token -Next token is token "number" (12.9-11: 256) -Shifting token "number" (12.9-11: 256) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (12.9-11: 256) --> $$ = nterm exp (12.9-11: 256) -Entering state 27 -Reading a token -Next token is token '\n' (12.12-13.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (12.1-5: 256) - $2 = token '=' (12.7: ) - $3 = nterm exp (12.9-11: 256) --> $$ = nterm exp (12.1-11: 256) -Entering state 8 -Next token is token '\n' (12.12-13.0: ) -Shifting token '\n' (12.12-13.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (12.1-11: 256) - $2 = token '\n' (12.12-13.0: ) --> $$ = nterm line (12.1-13.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-12.0: ) - $2 = nterm line (12.1-13.0: ) --> $$ = nterm input (1.1-13.0: ) -Entering state 6 -Reading a token -Next token is token '(' (13.1: ) -Shifting token '(' (13.1: ) -Entering state 4 -Reading a token -Next token is token "number" (13.2: 2) -Shifting token "number" (13.2: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (13.2: 2) --> $$ = nterm exp (13.2: 2) -Entering state 12 -Reading a token -Next token is token '^' (13.3: ) -Shifting token '^' (13.3: ) -Entering state 23 -Reading a token -Next token is token "number" (13.4: 2) -Shifting token "number" (13.4: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (13.4: 2) --> $$ = nterm exp (13.4: 2) -Entering state 32 -Reading a token -Next token is token ')' (13.5: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (13.2: 2) - $2 = token '^' (13.3: ) - $3 = nterm exp (13.4: 2) --> $$ = nterm exp (13.2-4: 4) -Entering state 12 -Next token is token ')' (13.5: ) -Shifting token ')' (13.5: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (13.1: ) - $2 = nterm exp (13.2-4: 4) - $3 = token ')' (13.5: ) --> $$ = nterm exp (13.1-5: 4) -Entering state 8 -Reading a token -Next token is token '^' (13.6: ) -Shifting token '^' (13.6: ) -Entering state 23 -Reading a token -Next token is token "number" (13.7: 3) -Shifting token "number" (13.7: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (13.7: 3) --> $$ = nterm exp (13.7: 3) -Entering state 32 -Reading a token -Next token is token '=' (13.9: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (13.1-5: 4) - $2 = token '^' (13.6: ) - $3 = nterm exp (13.7: 3) --> $$ = nterm exp (13.1-7: 64) -Entering state 8 -Next token is token '=' (13.9: ) -Shifting token '=' (13.9: ) -Entering state 18 -Reading a token -Next token is token "number" (13.11-12: 64) -Shifting token "number" (13.11-12: 64) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (13.11-12: 64) --> $$ = nterm exp (13.11-12: 64) -Entering state 27 -Reading a token -Next token is token '\n' (13.13-14.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (13.1-7: 64) - $2 = token '=' (13.9: ) - $3 = nterm exp (13.11-12: 64) --> $$ = nterm exp (13.1-12: 64) -Entering state 8 -Next token is token '\n' (13.13-14.0: ) -Shifting token '\n' (13.13-14.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (13.1-12: 64) - $2 = token '\n' (13.13-14.0: ) --> $$ = nterm line (13.1-14.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-13.0: ) - $2 = nterm line (13.1-14.0: ) --> $$ = nterm input (1.1-14.0: ) -Entering state 6 +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 Reading a token -Now at end of input. -Shifting token "end of input" (14.1: ) -Entering state 16 -Cleanup: popping token "end of input" (14.1: ) -Cleanup: popping nterm input (1.1-14.0: ) -./calc.at:1491: "$PERL" -pi -e 'use strict; +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Reducing stack 0 by rule 18 (line 109): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./torture.at:236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +--- /dev/null 2025-02-20 11:23:24.000000000 +0000 ++++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/606/stderr 2025-02-22 12:29:30.886843734 +0000 +@@ -0,0 +1 @@ ++/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/606/test-source: line 14: ruby: command not found +./calc.at:1489: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +606. torture.at:270: 607. torture.at:271: testing State number type: 129 states ... +./torture.at:271: ruby $abs_top_srcdir/tests/linear 129 >input.y || exit 77 + skipped (torture.at:270) +./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -221296,15 +222817,26 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1489: cat stderr +./calc.at:1492: cat stderr +--- /dev/null 2025-02-20 11:23:24.000000000 +0000 ++++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/607/stderr 2025-02-22 12:29:30.938844063 +0000 +@@ -0,0 +1 @@ ++/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/607/test-source: line 14: ruby: command not found +603. calc.at:1561: 607. torture.at:271: 608. torture.at:272: testing State number type: 256 states ... +./torture.at:272: ruby $abs_top_srcdir/tests/linear 256 >input.y || exit 77 + skipped (calc.at:1561) input: - | (#) + (#) = 2222 -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: + skipped (torture.at:271) input: + + | (# + 1) = 1111 ./calc.at:1489: $PREPARSER ./calc input + | (#) + (#) = 2222 +./calc.at:1492: $PREPARSER ./calc input stderr: stderr: + Starting parse Entering state 0 Reading a token @@ -221319,32 +222851,11 @@ Next token is token error () Error: discarding token error () Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 +Error: discarding token '+' () Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () +Next token is token number (1) +Error: discarding token number (1) Reading a token Next token is token ')' () Entering state 11 @@ -221356,39 +222867,32 @@ $2 = token error () $3 = token ')' () -> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) Entering state 8 +Reading a token Next token is token '=' () Shifting token '=' () Entering state 18 Reading a token -Next token is token number (2222) -Shifting token number (2222) +Next token is token number (1111) +Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (2222) --> $$ = nterm exp (2222) + $1 = token number (1111) +-> $$ = nterm exp (1111) Entering state 27 Reading a token Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (2222) + $1 = nterm exp (1111) $2 = token '=' () - $3 = nterm exp (2222) --> $$ = nterm exp (2222) + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) Entering state 8 Next token is token '\n' () Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2222) + $1 = nterm exp (1111) $2 = token '\n' () -> $$ = nterm line () Entering state 7 @@ -221402,82 +222906,96 @@ Entering state 16 Cleanup: popping token end of input () Cleanup: popping nterm input () - | (- *) + (1 2) = 1 -./calc.at:1492: $PREPARSER ./calc input +--- /dev/null 2025-02-20 11:23:24.000000000 +0000 ++++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/608/stderr 2025-02-22 12:29:30.990844393 +0000 +@@ -0,0 +1 @@ ++/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/608/test-source: line 14: ruby: command not found +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) +Reading a token +Next token is token ')' (1.3: ) +Entering state 11 +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) Entering state 20 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 +1.8: syntax error: invalid character: '#' +Next token is token error (1.8: ) +Shifting token error (1.8: ) +Entering state 11 +Next token is token error (1.8: ) +Error: discarding token error (1.8: ) Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) +Next token is token ')' (1.9: ) +Entering state 11 +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) Entering state 29 +Reading a token Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) Entering state 8 Next token is token '=' (1.11: ) Shifting token '=' (1.11: ) Entering state 18 Reading a token -Next token is token number (1.13: 7) -Shifting token number (1.13: 7) +Next token is token "number" (1.13-16: 2222) +Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.13: 7) --> $$ = nterm exp (1.13: 7) + $1 = token "number" (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token -Next token is token '\n' (1.14-2.0: ) +Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-9: 7) + $1 = nterm exp (1.1-9: 2222) $2 = token '=' (1.11: ) - $3 = nterm exp (1.13: 7) --> $$ = nterm exp (1.1-13: 7) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 -Next token is token '\n' (1.14-2.0: ) -Shifting token '\n' (1.14-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-13: 7) - $2 = token '\n' (1.14-2.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -221485,6347 +223003,175 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token -Next token is token number (2.1: 1) -Shifting token number (2.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2.1: 1) --> $$ = nterm exp (2.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (2.3: ) -Shifting token '+' (2.3: ) -Entering state 20 +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 16 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +608. torture.at:272: skipped (torture.at:272) + +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +Starting parse +Entering state 0 Reading a token -Next token is token number (2.5: 2) -Shifting token number (2.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2.5: 2) --> $$ = nterm exp (2.5: 2) -Entering state 29 +Next token is token '(' () +Shifting token '(' () +Entering state 4 Reading a token -Next token is token '*' (2.7: ) -Shifting token '*' (2.7: ) -Entering state 21 +syntax error: invalid character: '#' +Next token is token error () +Shifting token error () +Entering state 11 +Next token is token error () +Error: discarding token error () Reading a token -Next token is token '-' (2.9: ) -Shifting token '-' (2.9: ) -Entering state 2 +Next token is token '+' () +Error: discarding token '+' () Reading a token -Next token is token number (2.10: 3) -Shifting token number (2.10: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2.10: 3) --> $$ = nterm exp (2.10: 3) -Entering state 10 +Next token is token number (1) +Error: discarding token number (1) Reading a token -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (2.9: ) - $2 = nterm exp (2.10: 3) --> $$ = nterm exp (2.9-10: -3) -Entering state 30 -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (2.5: 2) - $2 = token '*' (2.7: ) - $3 = nterm exp (2.9-10: -3) --> $$ = nterm exp (2.5-10: -6) -Entering state 29 -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (2.1: 1) - $2 = token '+' (2.3: ) - $3 = nterm exp (2.5-10: -6) --> $$ = nterm exp (2.1-10: -5) +Next token is token ')' () +Entering state 11 +Next token is token ')' () +Shifting token ')' () +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 8 -Next token is token '=' (2.12: ) -Shifting token '=' (2.12: ) -Entering state 18 Reading a token -Next token is token '-' (2.14: ) -Shifting token '-' (2.14: ) -Entering state 2 +Next token is token '=' () +Shifting token '=' () +Entering state 18 Reading a token -Next token is token number (2.15: 5) -Shifting token number (2.15: 5) +Next token is token number (1111) +Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (2.15: 5) --> $$ = nterm exp (2.15: 5) -Entering state 10 -Reading a token -Next token is token '\n' (2.16-3.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (2.14: ) - $2 = nterm exp (2.15: 5) --> $$ = nterm exp (2.14-15: -5) + $1 = token number (1111) +-> $$ = nterm exp (1111) Entering state 27 -Next token is token '\n' (2.16-3.0: ) +Reading a token +Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (2.1-10: -5) - $2 = token '=' (2.12: ) - $3 = nterm exp (2.14-15: -5) --> $$ = nterm exp (2.1-15: -5) + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) Entering state 8 -Next token is token '\n' (2.16-3.0: ) -Shifting token '\n' (2.16-3.0: ) +Next token is token '\n' () +Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2.1-15: -5) - $2 = token '\n' (2.16-3.0: ) --> $$ = nterm line (2.1-3.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-2.0: ) - $2 = nterm line (2.1-3.0: ) --> $$ = nterm input (1.1-3.0: ) + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () Entering state 6 Reading a token -Next token is token '\n' (3.1-4.0: ) -Shifting token '\n' (3.1-4.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (3.1-4.0: ) --> $$ = nterm line (3.1-4.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-3.0: ) - $2 = nterm line (3.1-4.0: ) --> $$ = nterm input (1.1-4.0: ) -Entering state 6 +Now at end of input. +Shifting token end of input () +Entering state 16 +Cleanup: popping token end of input () +Cleanup: popping nterm input () +stderr: +Starting parse +Entering state 0 Reading a token -Next token is token '-' (4.1: ) -Shifting token '-' (4.1: ) -Entering state 2 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 Reading a token -Next token is token number (4.2: 1) -Shifting token number (4.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (4.2: 1) --> $$ = nterm exp (4.2: 1) -Entering state 10 +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) Reading a token -Next token is token '^' (4.3: ) -Shifting token '^' (4.3: ) -Entering state 23 +Next token is token ')' (1.3: ) +Entering state 11 +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) +Entering state 8 Reading a token -Next token is token number (4.4: 2) -Shifting token number (4.4: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (4.4: 2) --> $$ = nterm exp (4.4: 2) -Entering state 32 +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) +Entering state 20 Reading a token -Next token is token '=' (4.6: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (4.2: 1) - $2 = token '^' (4.3: ) - $3 = nterm exp (4.4: 2) --> $$ = nterm exp (4.2-4: 1) -Entering state 10 -Next token is token '=' (4.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (4.1: ) - $2 = nterm exp (4.2-4: 1) --> $$ = nterm exp (4.1-4: -1) +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Reading a token +1.8: syntax error: invalid character: '#' +Next token is token error (1.8: ) +Shifting token error (1.8: ) +Entering state 11 +Next token is token error (1.8: ) +Error: discarding token error (1.8: ) +Reading a token +Next token is token ')' (1.9: ) +Entering state 11 +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 29 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) Entering state 8 -Next token is token '=' (4.6: ) -Shifting token '=' (4.6: ) +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) Entering state 18 Reading a token -Next token is token '-' (4.8: ) -Shifting token '-' (4.8: ) -Entering state 2 -Reading a token -Next token is token number (4.9: 1) -Shifting token number (4.9: 1) +Next token is token "number" (1.13-16: 2222) +Shifting token "number" (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (4.9: 1) --> $$ = nterm exp (4.9: 1) -Entering state 10 -Reading a token -Next token is token '\n' (4.10-5.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (4.8: ) - $2 = nterm exp (4.9: 1) --> $$ = nterm exp (4.8-9: -1) + $1 = token "number" (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) Entering state 27 -Next token is token '\n' (4.10-5.0: ) +Reading a token +Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (4.1-4: -1) - $2 = token '=' (4.6: ) - $3 = nterm exp (4.8-9: -1) --> $$ = nterm exp (4.1-9: -1) + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 -Next token is token '\n' (4.10-5.0: ) -Shifting token '\n' (4.10-5.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (4.1-9: -1) - $2 = token '\n' (4.10-5.0: ) --> $$ = nterm line (4.1-5.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-4.0: ) - $2 = nterm line (4.1-5.0: ) --> $$ = nterm input (1.1-5.0: ) -Entering state 6 -Reading a token -Next token is token '(' (5.1: ) -Shifting token '(' (5.1: ) -Entering state 4 -Reading a token -Next token is token '-' (5.2: ) -Shifting token '-' (5.2: ) -Entering state 2 -Reading a token -Next token is token number (5.3: 1) -Shifting token number (5.3: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (5.3: 1) --> $$ = nterm exp (5.3: 1) -Entering state 10 -Reading a token -Next token is token ')' (5.4: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (5.2: ) - $2 = nterm exp (5.3: 1) --> $$ = nterm exp (5.2-3: -1) -Entering state 12 -Next token is token ')' (5.4: ) -Shifting token ')' (5.4: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (5.1: ) - $2 = nterm exp (5.2-3: -1) - $3 = token ')' (5.4: ) --> $$ = nterm exp (5.1-4: -1) -Entering state 8 -Reading a token -Next token is token '^' (5.5: ) -Shifting token '^' (5.5: ) -Entering state 23 -Reading a token -Next token is token number (5.6: 2) -Shifting token number (5.6: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (5.6: 2) --> $$ = nterm exp (5.6: 2) -Entering state 32 -Reading a token -Next token is token '=' (5.8: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (5.1-4: -1) - $2 = token '^' (5.5: ) - $3 = nterm exp (5.6: 2) --> $$ = nterm exp (5.1-6: 1) -Entering state 8 -Next token is token '=' (5.8: ) -Shifting token '=' (5.8: ) -Entering state 18 -Reading a token -Next token is token number (5.10: 1) -Shifting token number (5.10: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (5.10: 1) --> $$ = nterm exp (5.10: 1) -Entering state 27 -Reading a token -Next token is token '\n' (5.11-6.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (5.1-6: 1) - $2 = token '=' (5.8: ) - $3 = nterm exp (5.10: 1) --> $$ = nterm exp (5.1-10: 1) -Entering state 8 -Next token is token '\n' (5.11-6.0: ) -Shifting token '\n' (5.11-6.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (5.1-10: 1) - $2 = token '\n' (5.11-6.0: ) --> $$ = nterm line (5.1-6.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-5.0: ) - $2 = nterm line (5.1-6.0: ) --> $$ = nterm input (1.1-6.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (6.1-7.0: ) -Shifting token '\n' (6.1-7.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (6.1-7.0: ) --> $$ = nterm line (6.1-7.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-6.0: ) - $2 = nterm line (6.1-7.0: ) --> $$ = nterm input (1.1-7.0: ) -Entering state 6 -Reading a token -Next token is token '-' (7.1: ) -Shifting token '-' (7.1: ) -Entering state 2 -Reading a token -Next token is token '-' (7.2: ) -Shifting token '-' (7.2: ) -Entering state 2 -Reading a token -Next token is token '-' (7.3: ) -Shifting token '-' (7.3: ) -Entering state 2 -Reading a token -Next token is token number (7.4: 1) -Shifting token number (7.4: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (7.4: 1) --> $$ = nterm exp (7.4: 1) -Entering state 10 -Reading a token -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.3: ) - $2 = nterm exp (7.4: 1) --> $$ = nterm exp (7.3-4: -1) -Entering state 10 -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.2: ) - $2 = nterm exp (7.3-4: -1) --> $$ = nterm exp (7.2-4: 1) -Entering state 10 -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.1: ) - $2 = nterm exp (7.2-4: 1) --> $$ = nterm exp (7.1-4: -1) -Entering state 8 -Next token is token '=' (7.6: ) -Shifting token '=' (7.6: ) -Entering state 18 -Reading a token -Next token is token '-' (7.8: ) -Shifting token '-' (7.8: ) -Entering state 2 -Reading a token -Next token is token number (7.9: 1) -Shifting token number (7.9: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (7.9: 1) --> $$ = nterm exp (7.9: 1) -Entering state 10 -Reading a token -Next token is token '\n' (7.10-8.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.8: ) - $2 = nterm exp (7.9: 1) --> $$ = nterm exp (7.8-9: -1) -Entering state 27 -Next token is token '\n' (7.10-8.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (7.1-4: -1) - $2 = token '=' (7.6: ) - $3 = nterm exp (7.8-9: -1) --> $$ = nterm exp (7.1-9: -1) -Entering state 8 -Next token is token '\n' (7.10-8.0: ) -Shifting token '\n' (7.10-8.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (7.1-9: -1) - $2 = token '\n' (7.10-8.0: ) --> $$ = nterm line (7.1-8.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-7.0: ) - $2 = nterm line (7.1-8.0: ) --> $$ = nterm input (1.1-8.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (8.1-9.0: ) -Shifting token '\n' (8.1-9.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (8.1-9.0: ) --> $$ = nterm line (8.1-9.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-8.0: ) - $2 = nterm line (8.1-9.0: ) --> $$ = nterm input (1.1-9.0: ) -Entering state 6 -Reading a token -Next token is token number (9.1: 1) -Shifting token number (9.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (9.1: 1) --> $$ = nterm exp (9.1: 1) -Entering state 8 -Reading a token -Next token is token '-' (9.3: ) -Shifting token '-' (9.3: ) -Entering state 19 -Reading a token -Next token is token number (9.5: 2) -Shifting token number (9.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (9.5: 2) --> $$ = nterm exp (9.5: 2) -Entering state 28 -Reading a token -Next token is token '-' (9.7: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (9.1: 1) - $2 = token '-' (9.3: ) - $3 = nterm exp (9.5: 2) --> $$ = nterm exp (9.1-5: -1) -Entering state 8 -Next token is token '-' (9.7: ) -Shifting token '-' (9.7: ) -Entering state 19 -Reading a token -Next token is token number (9.9: 3) -Shifting token number (9.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (9.9: 3) --> $$ = nterm exp (9.9: 3) -Entering state 28 -Reading a token -Next token is token '=' (9.11: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (9.1-5: -1) - $2 = token '-' (9.7: ) - $3 = nterm exp (9.9: 3) --> $$ = nterm exp (9.1-9: -4) -Entering state 8 -Next token is token '=' (9.11: ) -Shifting token '=' (9.11: ) -Entering state 18 -Reading a token -Next token is token '-' (9.13: ) -Shifting token '-' (9.13: ) -Entering state 2 -Reading a token -Next token is token number (9.14: 4) -Shifting token number (9.14: 4) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (9.14: 4) --> $$ = nterm exp (9.14: 4) -Entering state 10 -Reading a token -Next token is token '\n' (9.15-10.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (9.13: ) - $2 = nterm exp (9.14: 4) --> $$ = nterm exp (9.13-14: -4) -Entering state 27 -Next token is token '\n' (9.15-10.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (9.1-9: -4) - $2 = token '=' (9.11: ) - $3 = nterm exp (9.13-14: -4) --> $$ = nterm exp (9.1-14: -4) -Entering state 8 -Next token is token '\n' (9.15-10.0: ) -Shifting token '\n' (9.15-10.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (9.1-14: -4) - $2 = token '\n' (9.15-10.0: ) --> $$ = nterm line (9.1-10.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-9.0: ) - $2 = nterm line (9.1-10.0: ) --> $$ = nterm input (1.1-10.0: ) -Entering state 6 -Reading a token -Next token is token number (10.1: 1) -Shifting token number (10.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (10.1: 1) --> $$ = nterm exp (10.1: 1) -Entering state 8 -Reading a token -Next token is token '-' (10.3: ) -Shifting token '-' (10.3: ) -Entering state 19 -Reading a token -Next token is token '(' (10.5: ) -Shifting token '(' (10.5: ) -Entering state 4 -Reading a token -Next token is token number (10.6: 2) -Shifting token number (10.6: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (10.6: 2) --> $$ = nterm exp (10.6: 2) -Entering state 12 -Reading a token -Next token is token '-' (10.8: ) -Shifting token '-' (10.8: ) -Entering state 19 -Reading a token -Next token is token number (10.10: 3) -Shifting token number (10.10: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (10.10: 3) --> $$ = nterm exp (10.10: 3) -Entering state 28 -Reading a token -Next token is token ')' (10.11: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (10.6: 2) - $2 = token '-' (10.8: ) - $3 = nterm exp (10.10: 3) --> $$ = nterm exp (10.6-10: -1) -Entering state 12 -Next token is token ')' (10.11: ) -Shifting token ')' (10.11: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (10.5: ) - $2 = nterm exp (10.6-10: -1) - $3 = token ')' (10.11: ) --> $$ = nterm exp (10.5-11: -1) -Entering state 28 -Reading a token -Next token is token '=' (10.13: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (10.1: 1) - $2 = token '-' (10.3: ) - $3 = nterm exp (10.5-11: -1) --> $$ = nterm exp (10.1-11: 2) -Entering state 8 -Next token is token '=' (10.13: ) -Shifting token '=' (10.13: ) -Entering state 18 -Reading a token -Next token is token number (10.15: 2) -Shifting token number (10.15: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (10.15: 2) --> $$ = nterm exp (10.15: 2) -Entering state 27 -Reading a token -Next token is token '\n' (10.16-11.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (10.1-11: 2) - $2 = token '=' (10.13: ) - $3 = nterm exp (10.15: 2) --> $$ = nterm exp (10.1-15: 2) -Entering state 8 -Next token is token '\n' (10.16-11.0: ) -Shifting token '\n' (10.16-11.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (10.1-15: 2) - $2 = token '\n' (10.16-11.0: ) --> $$ = nterm line (10.1-11.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-10.0: ) - $2 = nterm line (10.1-11.0: ) --> $$ = nterm input (1.1-11.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (11.1-12.0: ) -Shifting token '\n' (11.1-12.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (11.1-12.0: ) --> $$ = nterm line (11.1-12.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-11.0: ) - $2 = nterm line (11.1-12.0: ) --> $$ = nterm input (1.1-12.0: ) -Entering state 6 -Reading a token -Next token is token number (12.1: 2) -Shifting token number (12.1: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (12.1: 2) --> $$ = nterm exp (12.1: 2) -Entering state 8 -Reading a token -Next token is token '^' (12.2: ) -Shifting token '^' (12.2: ) -Entering state 23 -Reading a token -Next token is token number (12.3: 2) -Shifting token number (12.3: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (12.3: 2) --> $$ = nterm exp (12.3: 2) -Entering state 32 -Reading a token -Next token is token '^' (12.4: ) -Shifting token '^' (12.4: ) -Entering state 23 -Reading a token -Next token is token number (12.5: 3) -Shifting token number (12.5: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (12.5: 3) --> $$ = nterm exp (12.5: 3) -Entering state 32 -Reading a token -Next token is token '=' (12.7: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (12.3: 2) - $2 = token '^' (12.4: ) - $3 = nterm exp (12.5: 3) --> $$ = nterm exp (12.3-5: 8) -Entering state 32 -Next token is token '=' (12.7: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (12.1: 2) - $2 = token '^' (12.2: ) - $3 = nterm exp (12.3-5: 8) --> $$ = nterm exp (12.1-5: 256) -Entering state 8 -Next token is token '=' (12.7: ) -Shifting token '=' (12.7: ) -Entering state 18 -Reading a token -Next token is token number (12.9-11: 256) -Shifting token number (12.9-11: 256) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (12.9-11: 256) --> $$ = nterm exp (12.9-11: 256) -Entering state 27 -Reading a token -Next token is token '\n' (12.12-13.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (12.1-5: 256) - $2 = token '=' (12.7: ) - $3 = nterm exp (12.9-11: 256) --> $$ = nterm exp (12.1-11: 256) -Entering state 8 -Next token is token '\n' (12.12-13.0: ) -Shifting token '\n' (12.12-13.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (12.1-11: 256) - $2 = token '\n' (12.12-13.0: ) --> $$ = nterm line (12.1-13.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-12.0: ) - $2 = nterm line (12.1-13.0: ) --> $$ = nterm input (1.1-13.0: ) -Entering state 6 -Reading a token -Next token is token '(' (13.1: ) -Shifting token '(' (13.1: ) -Entering state 4 -Reading a token -Next token is token number (13.2: 2) -Shifting token number (13.2: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (13.2: 2) --> $$ = nterm exp (13.2: 2) -Entering state 12 -Reading a token -Next token is token '^' (13.3: ) -Shifting token '^' (13.3: ) -Entering state 23 -Reading a token -Next token is token number (13.4: 2) -Shifting token number (13.4: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (13.4: 2) --> $$ = nterm exp (13.4: 2) -Entering state 32 -Reading a token -Next token is token ')' (13.5: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (13.2: 2) - $2 = token '^' (13.3: ) - $3 = nterm exp (13.4: 2) --> $$ = nterm exp (13.2-4: 4) -Entering state 12 -Next token is token ')' (13.5: ) -Shifting token ')' (13.5: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (13.1: ) - $2 = nterm exp (13.2-4: 4) - $3 = token ')' (13.5: ) --> $$ = nterm exp (13.1-5: 4) -Entering state 8 -Reading a token -Next token is token '^' (13.6: ) -Shifting token '^' (13.6: ) -Entering state 23 -Reading a token -Next token is token number (13.7: 3) -Shifting token number (13.7: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (13.7: 3) --> $$ = nterm exp (13.7: 3) -Entering state 32 -Reading a token -Next token is token '=' (13.9: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (13.1-5: 4) - $2 = token '^' (13.6: ) - $3 = nterm exp (13.7: 3) --> $$ = nterm exp (13.1-7: 64) -Entering state 8 -Next token is token '=' (13.9: ) -Shifting token '=' (13.9: ) -Entering state 18 -Reading a token -Next token is token number (13.11-12: 64) -Shifting token number (13.11-12: 64) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (13.11-12: 64) --> $$ = nterm exp (13.11-12: 64) -Entering state 27 -Reading a token -Next token is token '\n' (13.13-14.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (13.1-7: 64) - $2 = token '=' (13.9: ) - $3 = nterm exp (13.11-12: 64) --> $$ = nterm exp (13.1-12: 64) -Entering state 8 -Next token is token '\n' (13.13-14.0: ) -Shifting token '\n' (13.13-14.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (13.1-12: 64) - $2 = token '\n' (13.13-14.0: ) --> $$ = nterm line (13.1-14.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-13.0: ) - $2 = nterm line (13.1-14.0: ) --> $$ = nterm input (1.1-14.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input (14.1: ) -Entering state 16 -Cleanup: popping token end of input (14.1: ) -Cleanup: popping nterm input (1.1-14.0: ) -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): - $1 = token '(' () - $2 = nterm exp (2) - $3 = token ')' () --> $$ = nterm exp (2) -Entering state 8 -Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 28 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 8 (line 104): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (1) --> $$ = nterm exp (0) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): - $1 = token '(' () - $2 = nterm exp (0) - $3 = token ')' () --> $$ = nterm exp (0) -Entering state 31 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 10 (line 106): - $1 = nterm exp (2) - $2 = token '/' () - $3 = nterm exp (0) -error: null divisor --> $$ = nterm exp (2) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1487: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -584. calc.at:1525: testing Calculator D %locations parse.lac=full parse.error=detailed parse.trace ... -./calc.at:1525: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y -stderr: -input: -./calc.at:1491: cat stderr -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 20 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 18 -Reading a token -Next token is token "number" (1.13: 7) -Shifting token "number" (1.13: 7) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.13: 7) --> $$ = nterm exp (1.13: 7) -Entering state 27 -Reading a token -Next token is token '\n' (1.14-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-9: 7) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13: 7) --> $$ = nterm exp (1.1-13: 7) -Entering state 8 -Next token is token '\n' (1.14-2.0: ) -Shifting token '\n' (1.14-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-13: 7) - $2 = token '\n' (1.14-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Next token is token "number" (2.1: 1) -Shifting token "number" (2.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2.1: 1) --> $$ = nterm exp (2.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (2.3: ) -Shifting token '+' (2.3: ) -Entering state 20 -Reading a token -Next token is token "number" (2.5: 2) -Shifting token "number" (2.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2.5: 2) --> $$ = nterm exp (2.5: 2) -Entering state 29 -Reading a token -Next token is token '*' (2.7: ) -Shifting token '*' (2.7: ) -Entering state 21 -Reading a token -Next token is token '-' (2.9: ) -Shifting token '-' (2.9: ) -Entering state 2 -Reading a token -Next token is token "number" (2.10: 3) -Shifting token "number" (2.10: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2.10: 3) --> $$ = nterm exp (2.10: 3) -Entering state 10 -Reading a token -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (2.9: ) - $2 = nterm exp (2.10: 3) --> $$ = nterm exp (2.9-10: -3) -Entering state 30 -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (2.5: 2) - $2 = token '*' (2.7: ) - $3 = nterm exp (2.9-10: -3) --> $$ = nterm exp (2.5-10: -6) -Entering state 29 -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (2.1: 1) - $2 = token '+' (2.3: ) - $3 = nterm exp (2.5-10: -6) --> $$ = nterm exp (2.1-10: -5) -Entering state 8 -Next token is token '=' (2.12: ) -Shifting token '=' (2.12: ) -Entering state 18 -Reading a token -Next token is token '-' (2.14: ) -Shifting token '-' (2.14: ) -Entering state 2 -Reading a token -Next token is token "number" (2.15: 5) -Shifting token "number" (2.15: 5) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (2.15: 5) --> $$ = nterm exp (2.15: 5) -Entering state 10 -Reading a token -Next token is token '\n' (2.16-3.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (2.14: ) - $2 = nterm exp (2.15: 5) --> $$ = nterm exp (2.14-15: -5) -Entering state 27 -Next token is token '\n' (2.16-3.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (2.1-10: -5) - $2 = token '=' (2.12: ) - $3 = nterm exp (2.14-15: -5) --> $$ = nterm exp (2.1-15: -5) -Entering state 8 -Next token is token '\n' (2.16-3.0: ) -Shifting token '\n' (2.16-3.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2.1-15: -5) - $2 = token '\n' (2.16-3.0: ) --> $$ = nterm line (2.1-3.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-2.0: ) - $2 = nterm line (2.1-3.0: ) --> $$ = nterm input (1.1-3.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (3.1-4.0: ) -Shifting token '\n' (3.1-4.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (3.1-4.0: ) --> $$ = nterm line (3.1-4.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-3.0: ) - $2 = nterm line (3.1-4.0: ) --> $$ = nterm input (1.1-4.0: ) -Entering state 6 -Reading a token -Next token is token '-' (4.1: ) -Shifting token '-' (4.1: ) -Entering state 2 -Reading a token -Next token is token "number" (4.2: 1) -Shifting token "number" (4.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (4.2: 1) --> $$ = nterm exp (4.2: 1) -Entering state 10 -Reading a token -Next token is token '^' (4.3: ) -Shifting token '^' (4.3: ) -Entering state 23 -Reading a token -Next token is token "number" (4.4: 2) -Shifting token "number" (4.4: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (4.4: 2) --> $$ = nterm exp (4.4: 2) -Entering state 32 -Reading a token -Next token is token '=' (4.6: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (4.2: 1) - $2 = token '^' (4.3: ) - $3 = nterm exp (4.4: 2) --> $$ = nterm exp (4.2-4: 1) -Entering state 10 -Next token is token '=' (4.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (4.1: ) - $2 = nterm exp (4.2-4: 1) --> $$ = nterm exp (4.1-4: -1) -Entering state 8 -Next token is token '=' (4.6: ) -Shifting token '=' (4.6: ) -Entering state 18 -Reading a token -Next token is token '-' (4.8: ) -Shifting token '-' (4.8: ) -Entering state 2 -Reading a token -Next token is token "number" (4.9: 1) -Shifting token "number" (4.9: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (4.9: 1) --> $$ = nterm exp (4.9: 1) -Entering state 10 -Reading a token -Next token is token '\n' (4.10-5.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (4.8: ) - $2 = nterm exp (4.9: 1) --> $$ = nterm exp (4.8-9: -1) -Entering state 27 -Next token is token '\n' (4.10-5.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (4.1-4: -1) - $2 = token '=' (4.6: ) - $3 = nterm exp (4.8-9: -1) --> $$ = nterm exp (4.1-9: -1) -Entering state 8 -Next token is token '\n' (4.10-5.0: ) -Shifting token '\n' (4.10-5.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (4.1-9: -1) - $2 = token '\n' (4.10-5.0: ) --> $$ = nterm line (4.1-5.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-4.0: ) - $2 = nterm line (4.1-5.0: ) --> $$ = nterm input (1.1-5.0: ) -Entering state 6 -Reading a token -Next token is token '(' (5.1: ) -Shifting token '(' (5.1: ) -Entering state 4 -Reading a token -Next token is token '-' (5.2: ) -Shifting token '-' (5.2: ) -Entering state 2 -Reading a token -Next token is token "number" (5.3: 1) -Shifting token "number" (5.3: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (5.3: 1) --> $$ = nterm exp (5.3: 1) -Entering state 10 -Reading a token -Next token is token ')' (5.4: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (5.2: ) - $2 = nterm exp (5.3: 1) --> $$ = nterm exp (5.2-3: -1) -Entering state 12 -Next token is token ')' (5.4: ) -Shifting token ')' (5.4: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (stderr: -5.1: ) - $2 = nterm exp (5.2-3: -1) - $3 = token ')' (5.4: ) --> $$ = nterm exp (5.1-4: -1) -Entering state 8 -Reading a token -Next token is token '^' (5.5: ) -Shifting token '^' (5.5: ) -Entering state 23 -Reading a token -Next token is token "number" (5.6: 2) -Shifting token "number" (5.6: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (5.6: 2) --> $$ = nterm exp (5.6: 2) -Entering state 32 -Reading a token -Next token is token '=' (5.8: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (5.1-4: -1) - $2 = token '^' (5.5: ) - $3 = nterm exp (5.6: 2) --> $$ = nterm exp (5.1-6: 1) -Entering state 8 -Next token is token '=' (5.8: ) -Shifting token '=' (5.8: ) -Entering state 18 -Reading a token -Next token is token "number" (5.10: 1) -Shifting token "number" (5.10: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (5.10: 1) --> $$ = nterm exp (5.10: 1) -Entering state 27 -Reading a token -Next token is token '\n' (5.11-6.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (5.1-6: 1) - $2 = token '=' (5.8: ) - $3 = nterm exp (5.10: 1) --> $$ = nterm exp (5.1-10: 1) -Entering state 8 -Next token is token '\n' (5.11-6.0: ) -Shifting token '\n' (5.11-6.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (5.1-10: 1) - $2 = token '\n' (5.11-6.0: ) --> $$ = nterm line (5.1-6.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-5.0: ) - $2 = nterm line (5.1-6.0: ) --> $$ = nterm input (1.1-6.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (6.1-7.0: ) -Shifting token '\n' (6.1-7.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (6.1-7.0: ) --> $$ = nterm line (6.1-7.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-6.0: ) - $2 = nterm line (6.1-7.0: ) --> $$ = nterm input (1.1-7.0: ) -Entering state 6 -Reading a token -Next token is token '-' (7.1: ) -Shifting token '-' (7.1: ) -Entering state 2 -Reading a token -Next token is token '-' (7.2: ) -Shifting token '-' (7.2: ) -Entering state 2 -Reading a token -Next token is token '-' (7.3: ) -Shifting token '-' (7.3: ) -Entering state 2 -Reading a token -Next token is token "number" (7.4: 1) -Shifting token "number" (7.4: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (7.4: 1) --> $$ = nterm exp (7.4: 1) -Entering state 10 -Reading a token -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.3: ) - $2 = nterm exp (7.4: 1) --> $$ = nterm exp (7.3-4: -1) -Entering state 10 -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.2: ) - $2 = nterm exp (7.3-4: -1) --> $$ = nterm exp (7.2-4: 1) -Entering state 10 -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.1: ) - $2 = nterm exp (7.2-4: 1) --> $$ = nterm exp (7.1-4: -1) -Entering state 8 -Next token is token '=' (7.6: ) -Shifting token '=' (7.6: ) -Entering state 18 -Reading a token -Next token is token '-' (7.8: ) -Shifting token '-' (7.8: ) -Entering state 2 -Reading a token -Next token is token "number" (7.9: 1) -Shifting token "number" (7.9: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (7.9: 1) --> $$ = nterm exp (7.9: 1) -Entering state 10 -Reading a token -Next token is token '\n' (7.10-8.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.8: ) - $2 = nterm exp (7.9: 1) --> $$ = nterm exp (7.8-9: -1) -Entering state 27 -Next token is token '\n' (7.10-8.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (7.1-4: -1) - $2 = token '=' (7.6: ) - $3 = nterm exp (7.8-9: -1) --> $$ = nterm exp (7.1-9: -1) -Entering state 8 -Next token is token '\n' (7.10-8.0: ) -Shifting token '\n' (7.10-8.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (7.1-9: -1) - $2 = token '\n' (7.10-8.0: ) --> $$ = nterm line (7.1-8.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-7.0: ) - $2 = nterm line (7.1-8.0: ) --> $$ = nterm input (1.1-8.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (8.1-9.0: ) -Shifting token '\n' (8.1-9.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (8.1-9.0: ) --> $$ = nterm line (8.1-9.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-8.0: ) - $2 = nterm line (8.1-9.0: ) --> $$ = nterm input (1.1-9.0: ) -Entering state 6 -Reading a token -Next token is token "number" (9.1: 1) -Shifting token "number" (9.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (9.1: 1) --> $$ = nterm exp (9.1: 1) -Entering state 8 -Reading a token -Next token is token '-' (9.3: ) -Shifting token '-' (9.3: ) -Entering state 19 -Reading a token -Next token is token "number" (9.5: 2) -Shifting token "number" (9.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (9.5: 2) --> $$ = nterm exp (9.5: 2) -Entering state 28 -Reading a token -Next token is token '-' (9.7: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (9.1: 1) - $2 = token '-' (9.3: ) - $3 = nterm exp (9.5: 2) --> $$ = nterm exp (9.1-5: -1) -Entering state 8 -Next token is token '-' (9.7: ) -Shifting token '-' (9.7: ) -Entering state 19 -Reading a token -Next token is token "number" (9.9: 3) -Shifting token "number" (9.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (9.9: 3) --> $$ = nterm exp (9.9: 3) -Entering state 28 -Reading a token -Next token is token '=' (9.11: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (9.1-5: -1) - $2 = token '-' (9.7: ) - $3 = nterm exp (9.9: 3) --> $$ = nterm exp (9.1-9: -4) -Entering state 8 -Next token is token '=' (9.11: ) -Shifting token '=' (9.11: ) -Entering state 18 -Reading a token -Next token is token '-' (9.13: ) -Shifting token '-' (9.13: ) -Entering state 2 -Reading a token -Next token is token "number" (9.14: 4) -Shifting token "number" (9.14: 4) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (9.14: 4) --> $$ = nterm exp (9.14: 4) -Entering state 10 -Reading a token -Next token is token '\n' (9.15-10.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (9.13: ) - $2 = nterm exp (9.14: 4) --> $$ = nterm exp (9.13-14: -4) -Entering state 27 -Next token is token '\n' (9.15-10.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (9.1-9: -4) - $2 = token '=' (9.11: ) - $3 = nterm exp (9.13-14: -4) --> $$ = nterm exp (9.1-14: -4) -Entering state 8 -Next token is token '\n' (9.15-10.0: ) -Shifting token '\n' (9.15-10.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (9.1-14: -4) - $2 = token '\n' (9.15-10.0: ) --> $$ = nterm line (9.1-10.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-9.0: ) - $2 = nterm line (9.1-10.0: ) --> $$ = nterm input (1.1-10.0: ) -Entering state 6 -Reading a token -Next token is token "number" (10.1: 1) -Shifting token "number" (10.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (10.1: 1) --> $$ = nterm exp (10.1: 1) -Entering state 8 -Reading a token -Next token is token '-' (10.3: ) -Shifting token '-' (10.3: ) -Entering state 19 -Reading a token -Next token is token '(' (10.5: ) -Shifting token '(' (10.5: ) -Entering state 4 -Reading a token -Next token is token "number" (10.6: 2) -Shifting token "number" (10.6: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (10.6: 2) --> $$ = nterm exp (10.6: 2) -Entering state 12 -Reading a token -Next token is token '-' (10.8: ) -Shifting token '-' (10.8: ) -Entering state 19 -Reading a token -Next token is token "number" (10.10: 3) -Shifting token "number" (10.10: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (10.10: 3) --> $$ = nterm exp (10.10: 3) -Entering state 28 -Reading a token -Next token is token ')' (10.11: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (10.6: 2) - $2 = token '-' (10.8: ) - $3 = nterm exp (10.10: 3) --> $$ = nterm exp (10.6-10: -1) -Entering state 12 -Next token is token ')' (10.11: ) -Shifting token ')' (10.11: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (10.5: ) - $2 = nterm exp (10.6-10: -1) - $3 = token ')' (10.11: ) --> $$ = nterm exp (10.5-11: -1) -Entering state 28 -Reading a token -Next token is token '=' (10.13: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (10.1: 1) - $2 = token '-' (10.3: ) - $3 = nterm exp (10.5-11: -1) --> $$ = nterm exp (10.1-11: 2) -Entering state 8 -Next token is token '=' (10.13: ) -Shifting token '=' (10.13: ) -Entering state 18 -Reading a token -Next token is token "number" (10.15: 2) -Shifting token "number" (10.15: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (10.15: 2) --> $$ = nterm exp (10.15: 2) -Entering state 27 -Reading a token -Next token is token '\n' (10.16-11.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (10.1-11: 2) - $2 = token '=' (10.13: ) - $3 = nterm exp (10.15: 2) --> $$ = nterm exp (10.1-15: 2) -Entering state 8 -Next token is token '\n' (10.16-11.0: ) -Shifting token '\n' (10.16-11.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (10.1-15: 2) - $2 = token '\n' (10.16-11.0: ) --> $$ = nterm line (10.1-11.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-10.0: ) - $2 = nterm line (10.1-11.0: ) --> $$ = nterm input (1.1-11.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (11.1-12.0: ) -Shifting token '\n' (11.1-12.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (11.1-12.0: ) --> $$ = nterm line (11.1-12.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-11.0: ) - $2 = nterm line (11.1-12.0: ) --> $$ = nterm input (1.1-12.0: ) -Entering state 6 -Reading a token -Next token is token "number" (12.1: 2) -Shifting token "number" (12.1: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (12.1: 2) --> $$ = nterm exp (12.1: 2) -Entering state 8 -Reading a token -Next token is token '^' (12.2: ) -Shifting token '^' (12.2: ) -Entering state 23 -Reading a token -Next token is token "number" (12.3: 2) -Shifting token "number" (12.3: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (12.3: 2) --> $$ = nterm exp (12.3: 2) -Entering state 32 -Reading a token -Next token is token '^' (12.4: ) -Shifting token '^' (12.4: ) -Entering state 23 -Reading a token -Next token is token "number" (12.5: 3) -Shifting token "number" (12.5: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (12.5: 3) --> $$ = nterm exp (12.5: 3) -Entering state 32 -Reading a token -Next token is token '=' (12.7: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (12.3: 2) - $2 = token '^' (12.4: ) - $3 = nterm exp (12.5: 3) --> $$ = nterm exp (12.3-5: 8) -Entering state 32 -Next token is token '=' (12.7: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (12.1: 2) - $2 = token '^' (12.2: ) - $3 = nterm exp (12.3-5: 8) --> $$ = nterm exp (12.1-5: 256) -Entering state 8 -Next token is token '=' (12.7: ) -Shifting token '=' (12.7: ) -Entering state 18 -Reading a token -Next token is token "number" (12.9-11: 256) -Shifting token "number" (12.9-11: 256) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (12.9-11: 256) --> $$ = nterm exp (12.9-11: 256) -Entering state 27 -Reading a token -Next token is token '\n' (12.12-13.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (12.1-5: 256) - $2 = token '=' (12.7: ) - $3 = nterm exp (12.9-11: 256) --> $$ = nterm exp (12.1-11: 256) -Entering state 8 -Next token is token '\n' (12.12-13.0: ) -Shifting token '\n' (12.12-13.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (12.1-11: 256) - $2 = token '\n' (12.12-13.0: ) --> $$ = nterm line (12.1-13.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-12.0: ) - $2 = nterm line (12.1-13.0: ) --> $$ = nterm input (1.1-13.0: ) -Entering state 6 -Reading a token -Next token is token '(' (13.1: ) -Shifting token '(' (13.1: ) -Entering state 4 -Reading a token -Next token is token "number" (13.2: 2) -Shifting token "number" (13.2: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (13.2: 2) --> $$ = nterm exp (13.2: 2) -Entering state 12 -Reading a token -Next token is token '^' (13.3: ) -Shifting token '^' (13.3: ) -Entering state 23 -Reading a token -Next token is token "number" (13.4: 2) -Shifting token "number" (13.4: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (13.4: 2) --> $$ = nterm exp (13.4: 2) -Entering state 32 -Reading a token -Next token is token ')' (13.5: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (13.2: 2) - $2 = token '^' (13.3: ) - $3 = nterm exp (13.4: 2) --> $$ = nterm exp (13.2-4: 4) -Entering state 12 -Next token is token ')' (13.5: ) -Shifting token ')' (13.5: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (13.1: ) - $2 = nterm exp (13.2-4: 4) - $3 = token ')' (13.5: ) --> $$ = nterm exp (13.1-5: 4) -Entering state 8 -Reading a token -Next token is token '^' (13.6: ) -Shifting token '^' (13.6: ) -Entering state 23 -Reading a token -Next token is token "number" (13.7: 3) -Shifting token "number" (13.7: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (13.7: 3) --> $$ = nterm exp (13.7: 3) -Entering state 32 -Reading a token -Next token is token '=' (13.9: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (13.1-5: 4) - $2 = token '^' (13.6: ) - $3 = nterm exp (13.7: 3) --> $$ = nterm exp (13.1-7: 64) -Entering state 8 -Next token is token '=' (13.9: ) -Shifting token '=' (13.9: ) -Entering state 18 -Reading a token -Next token is token "number" (13.11-12: 64) -Shifting token "number" (13.11-12: 64) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (13.11-12: 64) --> $$ = nterm exp (13.11-12: 64) -Entering state 27 -Reading a token -Next token is token '\n' (13.13-14.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (13.1-7: 64) - $2 = token '=' (13.9: ) - $3 = nterm exp (13.11-12: 64) --> $$ = nterm exp (13.1-12: 64) -Entering state 8 -Next token is token '\n' (13.13-14.0: ) -Shifting token '\n' (13.13-14.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (13.1-12: 64) - $2 = token '\n' (13.13-14.0: ) --> $$ = nterm line (13.1-14.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-13.0: ) - $2 = nterm line (13.1-14.0: ) --> $$ = nterm input (1.1-14.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (14.1: ) -Entering state 16 -Cleanup: popping token "end of input" (14.1: ) -Cleanup: popping nterm input (1.1-14.0: ) - | 1 2 -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Reducing stack 0 by rule 15 (line 106): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Shifting token error (1.2-4: ) -Entering state 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Reading a token -Next token is token "number" (1.10: 1) -Shifting token "number" (1.10: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Reading a token -Next token is token "number" (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Shifting token error (1.10-12: ) -Entering state 11 -Next token is token "number" (1.12: 2) -Error: discarding token "number" (1.12: 2) -Reading a token -Next token is token ')' (1.13: ) -Entering state 11 -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.15: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) -Entering state 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) -Entering state 18 -Reading a token -Next token is token "number" (1.17: 1) -Shifting token "number" (1.17: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.17: 1) --> $$ = nterm exp (1.17: 1) -Entering state 27 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) -Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -stderr: -585. calc.at:1530: testing Calculator D api.token.constructor %locations parse.error=custom api.value.type=union ... -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 7 (line 103): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): - $1 = token '(' () - $2 = nterm exp (2) - $3 = token ')' () --> $$ = nterm exp (2) -Entering state 8 -Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 92): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 28 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 8 (line 104): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (1) --> $$ = nterm exp (0) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 117): - $1 = token '(' () - $2 = nterm exp (0) - $3 = token ')' () --> $$ = nterm exp (0) -Entering state 31 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 10 (line 106): - $1 = nterm exp (2) - $2 = token '/' () - $3 = nterm exp (0) -error: null divisor --> $$ = nterm exp (2) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 88): - $1 = nterm exp (2) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 82): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of file () -Entering state 16 -Cleanup: popping token end of file () -Cleanup: popping nterm input () -./calc.at:1491: $PREPARSER ./calc input -stderr: -input: -Starting parse -Entering state 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token number (1.3: 2) -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1530: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | 1 2 -stderr: -./calc.at:1494: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 29 -Reading a token -Next token is token '=' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1111) - $2 = token '+' () - $3 = nterm exp (1111) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (2222) -Shifting token number (2222) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2222) --> $$ = nterm exp (2222) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (2222) - $2 = token '=' () - $3 = nterm exp (2222) --> $$ = nterm exp (2222) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2222) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input () -Entering state 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () - -Starting parse -Entering state 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token number (1.3: 2) -stderr: -584. calc.at:1525: ./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -583. calc.at:1524: stderr: -input: -./calc.at:1491: cat stderr -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token "number" (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token "number" (1.3: 2) - skipped (calc.at:1525) -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Reducing stack 0 by rule 15 (line 106): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Shifting token error (1.2-4: ) -Entering state 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Reading a token -Next token is token "number" (1.10: 1) -Shifting token "number" (1.10: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Reading a token -Next token is token "number" (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Shifting token error (1.10-12: ) -Entering state 11 -Next token is token "number" (1.12: 2) -Error: discarding token "number" (1.12: 2) -Reading a token -Next token is token ')' (1.13: ) -Entering state 11 -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.15: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) -Entering state 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) -Entering state 18 -Reading a token -Next token is token "number" (1.17: 1) -Shifting token "number" (1.17: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.17: 1) --> $$ = nterm exp (1.17: 1) -Entering state 27 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) -Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - skipped (calc.at:1524) - | (# + 1) = 1111 -./calc.at:1491: $PREPARSER ./calc input -./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input: -stderr: -./calc.at:1487: cat stderr -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token "number" (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token "number" (1.3: 2) -586. calc.at:1531: testing Calculator D api.token.constructor %locations parse.error=detailed ... -./calc.at:1531: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Reading a token -Next token is token "number" (1.6: 1) -Error: discarding token "number" (1.6: 1) -Reading a token -Next token is token ')' (1.7: ) -Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - | 1//2 -./calc.at:1491: $PREPARSER ./calc input - -stderr: -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -585. calc.at:1530: ./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 22 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.3: ) -562. calc.at:1487: ok - -./calc.at:1494: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Reading a token -Next token is token "number" (1.6: 1) -Error: discarding token "number" (1.6: 1) -Reading a token -Next token is token ')' (1.7: ) -Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - skipped (calc.at:1530) -./calc.at:1494: cat stderr -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1489: cat stderr -./calc.at:1492: cat stderr -stderr: -./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -588. calc.at:1533: testing Calculator D parse.trace parse.error=custom %locations api.push-pull=both parse.lac=full ... -./calc.at:1533: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y -input: -input: -586. calc.at:1531: | (* *) + (*) + (*) -Starting parse -Entering state 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 22 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.3: ) -./calc.at:1492: $PREPARSER ./calc input - | 1//2 -./calc.at:1494: $PREPARSER ./calc input - skipped (calc.at:1531) -input: - - | (1 + #) = 1111 -./calc.at:1489: $PREPARSER ./calc input -stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1111) -Shifting token number (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input () -Entering state 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 22 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.3: ) - -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1491: cat stderr -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) -Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) -Entering state 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) -Reading a token -Next token is token ')' (1.11: ) -Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) -Entering state 29 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) -Entering state 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 20 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 -Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) -Reading a token -Next token is token ')' (1.17: ) -Entering state 11 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 29 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) -Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -587. calc.at:1532: testing Calculator D api.push-pull=both ... -./calc.at:1532: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o calc.d calc.y -stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 22 -Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.3: ) -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1111) -Shifting token number (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input () -Entering state 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -588. calc.at:1533: skipped (calc.at:1533) -input: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) -Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) -Entering state 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) -Reading a token -Next token is token ')' (1.11: ) -Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) -Entering state 29 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) -Entering state 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 20 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 -Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) -Reading a token -Next token is token ')' (1.17: ) -Entering state 11 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 29 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) -Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -589. calc.at:1544: testing Calculator Java ... - | (1 + # + 1) = 1111 -./calc.at:1491: $PREPARSER ./calc input -stderr: - -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) -Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) -Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Reading a token -Next token is token "number" (1.10: 1) -Error: discarding token "number" (1.10: 1) -Reading a token -Next token is token ')' (1.11: ) -Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) -Entering state 18 -Reading a token -Next token is token "number" (1.15-18: 1111) -Shifting token "number" (1.15-18: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) -Entering state 27 -Reading a token -Next token is token '\n' (1.19-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) -Entering state 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -590. calc.at:1545: testing Calculator Java parse.error=custom ... -./calc.at:1545: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y -./calc.at:1491: cat stderr -./calc.at:1494: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1544: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: -./calc.at:1494: cat stderr -587. calc.at:1532: stderr: -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) -Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) -Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Reading a token -Next token is token "number" (1.10: 1) -Error: discarding token "number" (1.10: 1) -Reading a token -Next token is token ')' (1.11: ) -Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) -Entering state 18 -Reading a token -Next token is token "number" (1.15-18: 1111) -Shifting token "number" (1.15-18: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) -Entering state 27 -Reading a token -Next token is token '\n' (1.19-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) -Entering state 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - | error -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1491: $PREPARSER ./calc input -./calc.at:1492: cat stderr - skipped (calc.at:1532) -591. calc.at:1546: testing Calculator Java parse.error=detailed ... -./calc.at:1546: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -./calc.at:1489: cat stderr -./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -590. calc.at:1545: input: - | error -./calc.at:1494: $PREPARSER ./calc input - | 1 + 2 * 3 + !+ ++ -./calc.at:1492: $PREPARSER ./calc input -589. calc.at:1544: - skipped (calc.at:1545) -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" (1.1: ) -input: - | (# + 1) = 1111 -./calc.at:1489: $PREPARSER ./calc input -591. calc.at:1546: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./calc.at:1491: cat stderr -stderr: - skipped (calc.at:1544) - skipped (calc.at:1546) -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 20 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 20 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Reducing stack 0 by rule 17 (line 108): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) - -stderr: -./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token number (1) -Error: discarding token number (1) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1111) -Shifting token number (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input () -Entering state 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - -Starting parse -Entering state 0 -Reading a token -Next token is token "invalid token" (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token "invalid token" (1.1: ) -input: -592. calc.at:1547: testing Calculator Java parse.error=verbose ... -./calc.at:1547: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y -stderr: -./calc.at:1491: cat stderr - | (1 + 1) / (1 - 1) -./calc.at:1491: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 20 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 20 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Reducing stack 0 by rule 17 (line 108): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -stderr: - -./calc.at:1494: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token number (1) -Error: discarding token number (1) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1111) -Shifting token number (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input () -Entering state 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -input: -593. calc.at:1548: testing Calculator Java %locations parse.error=custom ... -./calc.at:1548: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Reading a token -Next token is token "number" (1.6: 1) -Shifting token "number" (1.6: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 29 -Reading a token -Next token is token ')' (1.7: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) -Entering state 8 -Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 22 -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Reading a token -Next token is token "number" (1.12: 1) -Shifting token "number" (1.12: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 19 -Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 28 -Reading a token -Next token is token ')' (1.17: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 31 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) -Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - | 1 + 2 * 3 + !- ++ -./calc.at:1492: $PREPARSER ./calc input - | 1 = 2 = 3 -./calc.at:1491: $PREPARSER ./calc input -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1494: cat stderr -stderr: -stderr: -595. calc.at:1550: testing Calculator Java %locations parse.error=verbose ... -./calc.at:1550: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y -Starting parse -Entering state 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 18 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 27 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Error: popping token '=' (1.3: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '=' (1.7: ) -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 20 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 20 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Reducing stack 0 by rule 18 (line 109): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Reading a token -Next token is token "number" (1.6: 1) -Shifting token "number" (1.6: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 29 -Reading a token -Next token is token ')' (1.7: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) -Entering state 8 -Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 22 -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Reading a token -Next token is token "number" (1.12: 1) -Shifting token "number" (1.12: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 19 -Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 28 -Reading a token -Next token is token ')' (1.17: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 31 -Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) -Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -592. calc.at:1547: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -594. calc.at:1549: testing Calculator Java %locations parse.error=detailed ... -596. calc.at:1551: testing Calculator Java parse.trace parse.error=verbose ... -./calc.at:1551: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y -./calc.at:1549: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y -./calc.at:1489: cat stderr - skipped (calc.at:1547) -input: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 20 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 20 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Reducing stack 0 by rule 18 (line 109): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) - | 1 = 2 = 3 -./calc.at:1494: $PREPARSER ./calc input -593. calc.at:1548: stderr: -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 18 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 27 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Error: popping token '=' (1.3: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '=' (1.7: ) - skipped (calc.at:1548) -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 18 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 27 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Error: popping token '=' (1.3: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '=' (1.7: ) -./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: - | (1 + # + 1) = 1111 -./calc.at:1489: $PREPARSER ./calc input -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - -stderr: -./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -596. calc.at:1551: 595. calc.at:1550: 594. calc.at:1549: Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token number (1) -Error: discarding token number (1) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1111) -Shifting token number (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input () -Entering state 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - - skipped (calc.at:1549) - skipped (calc.at:1551) -./calc.at:1492: cat stderr -./calc.at:1491: cat stderr -stderr: - skipped (calc.at:1550) -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -syntax error: invalid character: '#' -Next token is token error () -Error: popping token '+' () -Error: popping nterm exp (1) -Shifting token error () -Entering state 11 -Next token is token error () -Error: discarding token error () -Reading a token -Next token is token '+' () -Error: discarding token '+' () -Reading a token -Next token is token number (1) -Error: discarding token number (1) -Reading a token -Next token is token ')' () -Entering state 11 -Next token is token ')' () -Shifting token ')' () -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' () - $2 = token error () - $3 = token ')' () --> $$ = nterm exp (1111) -Entering state 8 -Reading a token -Next token is token '=' () -Shifting token '=' () -Entering state 18 -Reading a token -Next token is token number (1111) -Shifting token number (1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1111) --> $$ = nterm exp (1111) -Entering state 27 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1111) - $2 = token '=' () - $3 = nterm exp (1111) --> $$ = nterm exp (1111) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1111) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input () -Entering state 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -Starting parse -Entering state 0 -Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 18 -Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 27 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Error: popping token '=' (1.3: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '=' (1.7: ) -./calc.at:1491: cat stderr - -565. calc.at:1491: ok -597. calc.at:1552: testing Calculator Java parse.trace parse.error=verbose %locations %lex-param {InputStream is} ... -input: -./calc.at:1494: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1552: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y - - | (#) + (#) = 2222 -input: -./calc.at:1494: cat stderr -./calc.at:1492: $PREPARSER ./calc input - -stderr: - -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | - | +1 -./calc.at:1491: $PREPARSER ./calc input -598. calc.at:1554: testing Calculator Java api.push-pull=both ... -./calc.at:1554: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token ')' (1.3: ) -Entering state 11 -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 20 -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Reading a token -1.8: syntax error: invalid character: '#' -Next token is token error (1.8: ) -Shifting token error (1.8: ) -Entering state 11 -Next token is token error (1.8: ) -Error: discarding token error (1.8: ) -Reading a token -Next token is token ')' (1.9: ) -Entering state 11 -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 18 -Reading a token -Next token is token "number" (1.13-16: 2222) -Shifting token "number" (1.13-16: 2222) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 27 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -input: -stderr: -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1489: cat stderr -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Cleanup: discarding lookahead token '+' (2.1: ) - | - | +1 -./calc.at:1494: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token ')' (1.3: ) -Entering state 11 -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 20 -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Reading a token -1.8: syntax error: invalid character: '#' -Next token is token error (1.8: ) -Shifting token error (1.8: ) -Entering state 11 -Next token is token error (1.8: ) -Error: discarding token error (1.8: ) -Reading a token -Next token is token ')' (1.9: ) -Entering state 11 -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 18 -Reading a token -Next token is token "number" (1.13-16: 2222) -Shifting token "number" (1.13-16: 2222) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 27 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -599. calc.at:1555: testing Calculator Java api.push-pull=both parse.error=detailed %locations ... -./calc.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y -602. calc.at:1560: testing Calculator Java parse.trace parse.error=custom %locations parse.lac=full ... -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Cleanup: discarding lookahead token '+' (2.1: ) -stderr: -input: -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Cleanup: discarding lookahead token '+' (2.1: ) -./calc.at:1560: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Cleanup: discarding lookahead token '+' (2.1: ) - | (1 + 1) / (1 - 1) -./calc.at:1489: $PREPARSER ./calc input -597. calc.at:1552: stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (2) - $3 = token ')' () --> $$ = nterm exp (2) -Entering state 8 -Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 28 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (1) --> $$ = nterm exp (0) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (0) - $3 = token ')' () --> $$ = nterm exp (0) -Entering state 31 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (2) - $2 = token '/' () - $3 = nterm exp (0) -error: null divisor --> $$ = nterm exp (2) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input () -Entering state 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -601. calc.at:1557: testing Calculator Java parse.trace parse.error=verbose %locations %lex-param {InputStream is} api.push-pull=both ... -599. calc.at:1555: 600. calc.at:1556: testing Calculator Java parse.trace parse.error=custom %locations %lex-param {InputStream is} api.push-pull=both ... -./calc.at:1556: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y - skipped (calc.at:1555) -./calc.at:1492: cat stderr -./calc.at:1494: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1557: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y - skipped (calc.at:1552) -598. calc.at:1554: stderr: -./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - skipped (calc.at:1554) -./calc.at:1494: cat stderr - -./calc.at:1491: cat stderr - -Starting parse -Entering state 0 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '+' () -Shifting token '+' () -Entering state 20 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 29 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1) - $2 = token '+' () - $3 = nterm exp (1) --> $$ = nterm exp (2) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (2) - $3 = token ')' () --> $$ = nterm exp (2) -Entering state 8 -Reading a token -Next token is token '/' () -Shifting token '/' () -Entering state 22 -Reading a token -Next token is token '(' () -Shifting token '(' () -Entering state 4 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 12 -Reading a token -Next token is token '-' () -Shifting token '-' () -Entering state 19 -Reading a token -Next token is token number (1) -Shifting token number (1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1) --> $$ = nterm exp (1) -Entering state 28 -Reading a token -Next token is token ')' () -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1) - $2 = token '-' () - $3 = nterm exp (1) --> $$ = nterm exp (0) -Entering state 12 -Next token is token ')' () -Shifting token ')' () -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' () - $2 = nterm exp (0) - $3 = token ')' () --> $$ = nterm exp (0) -Entering state 31 -Reading a token -Next token is token '\n' () -Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (2) - $2 = token '/' () - $3 = nterm exp (0) -error: null divisor --> $$ = nterm exp (2) -Entering state 8 -Next token is token '\n' () -Shifting token '\n' () -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2) - $2 = token '\n' () --> $$ = nterm line () -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line () --> $$ = nterm input () -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input () -Entering state 16 -Cleanup: popping token end of input () -Cleanup: popping nterm input () -input: - | (1 + #) = 1111 -./calc.at:1492: $PREPARSER ./calc input -./calc.at:1491: $PREPARSER ./calc /dev/null -stderr: - -./calc.at:1494: $PREPARSER ./calc /dev/null -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) -Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) -Reading a token -Next token is token ')' (1.7: ) -Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -stderr: -602. calc.at:1560: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token end of input (1.1: ) - skipped (calc.at:1560) -Starting parse -Entering state 0 -Reading a token -Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" (1.1: ) -./calc.at:1489: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -600. calc.at:1556: stderr: -./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) -Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) -Reading a token -Next token is token ')' (1.7: ) -Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - skipped (calc.at:1556) -601. calc.at:1557: ./calc.at:1489: cat stderr -stderr: -stderr: - skipped (calc.at:1557) -Starting parse -Entering state 0 -Reading a token -Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token end of input (1.1: ) -Starting parse -Entering state 0 -Reading a token -Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token "end of input" (1.1: ) -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - -605. torture.at:216: testing Big horizontal ... -./torture.at:230: "$PERL" -w ./gengram.pl 1000 || exit 77 -604. torture.at:132: testing Big triangle ... -./torture.at:138: "$PERL" -w ./gengram.pl 200 || exit 77 -564. calc.at:1489: ok -stderr: -stdout: -%code top { /* -*- c -*- */ -/* Adjust to the compiler. - We used to do it here, but each time we add a new line, - we have to adjust all the line numbers in error messages. - It's simpler to use a constant include to a varying file. */ -#include -} - -%define parse.error verbose -%debug -%{ -#include -#include -#define MAX 1000 -static int yylex (void); -#include - -/* !POSIX */ static void yyerror (const char *msg); -%} - -%token - t1 1 "1" - t2 2 "2" - t3 3 "3" - t4 4 "4" - t5 5 "5" - t6 6 "6" - t7 7 "7" - t8 8 "8" - t9 9 "9" - t10 10 "10" - t11 11 "11" - t12 12 "12" - t13 13 "13" - t14 14 "14" - t15 15 "15" - t16 16 "16" - t17 17 "17" - t18 18 "18" - t19 19 "19" - t20 20 "20" - t21 21 "21" - t22 22 "22" - t23 23 "23" - t24 24 "24" - t25 25 "25" - t26 26 "26" - t27 27 "27" - t28 28 "28" - t29 29 "29" - t30 30 "30" - t31 31 "31" - t32 32 "32" - t33 33 "33" - t34 34 "34" - t35 35 "35" - t36 36 "36" - t37 37 "37" - t38 38 "38" - t39 39 "39" - t40 40 "40" - t41 41 "41" - t42 42 "42" - t43 43 "43" - t44 44 "44" - t45 45 "45" - t46 46 "46" - t47 47 "47" - t48 48 "48" - t49 49 "49" - t50 50 "50" - t51 51 "51" - t52 52 "52" - t53 53 "53" - t54 54 "54" - t55 55 "55" - t56 56 "56" - t57 57 "57" - t58 58 "58" - t59 59 "59" - t60 60 "60" - t61 61 "61" - t62 62 "62" - t63 63 "63" - t64 64 "64" - t65 65 "65" - t66 66 "66" - t67 67 "67" - t68 68 "68" - t69 69 "69" - t70 70 "70" - t71 71 "71" - t72 72 "72" - t73 73 "73" - t74 74 "74" - t75 75 "75" - t76 76 "76" - t77 77 "77" - t78 78 "78" - t79 79 "79" - t80 80 "80" - t81 81 "81" - t82 82 "82" - t83 83 "83" - t84 84 "84" - t85 85 "85" - t86 86 "86" - t87 87 "87" - t88 88 "88" - t89 89 "89" - t90 90 "90" - t91 91 "91" - t92 92 "92" - t93 93 "93" - t94 94 "94" - t95 95 "95" - t96 96 "96" - t97 97 "97" - t98 98 "98" - t99 99 "99" - t100 100 "100" - t101 101 "101" - t102 102 "102" - t103 103 "103" - t104 104 "104" - t105 105 "105" - t106 106 "106" - t107 107 "107" - t108 108 "108" - t109 109 "109" - t110 110 "110" - t111 111 "111" - t112 112 "112" - t113 113 "113" - t114 114 "114" - t115 115 "115" - t116 116 "116" - t117 117 "117" - t118 118 "118" - t119 119 "119" - t120 120 "120" - t121 121 "121" - t122 122 "122" - t123 123 "123" - t124 124 "124" - t125 125 "125" - t126 126 "126" - t127 127 "127" - t128 128 "128" - t129 129 "129" - t130 130 "130" - t131 131 "131" - t132 132 "132" - t133 133 "133" - t134 134 "134" - t135 135 "135" - t136 136 "136" - t137 137 "137" - t138 138 "138" - t139 139 "139" - t140 140 "140" - t141 141 "141" - t142 142 "142" - t143 143 "143" - t144 144 "144" - t145 145 "145" - t146 146 "146" - t147 147 "147" - t148 148 "148" - t149 149 "149" - t150 150 "150" - t151 151 "151" - t152 152 "152" - t153 153 "153" - t154 154 "154" - t155 155 "155" - t156 156 "156" - t157 157 "157" - t158 158 "158" - t159 159 "159" - t160 160 "160" - t161 161 "161" - t162 162 "162" - t163 163 "163" - t164 164 "164" - t165 165 "165" - t166 166 "166" - t167 167 "167" - t168 168 "168" - t169 169 "169" - t170 170 "170" - t171 171 "171" - t172 172 "172" - t173 173 "173" - t174 174 "174" - t175 175 "175" - t176 176 "176" - t177 177 "177" - t178 178 "178" - t179 179 "179" - t180 180 "180" - t181 181 "181" - t182 182 "182" - t183 183 "183" - t184 184 "184" - t185 185 "185" - t186 186 "186" - t187 187 "187" - t188 188 "188" - t189 189 "189" - t190 190 "190" - t191 191 "191" - t192 192 "192" - t193 193 "193" - t194 194 "194" - t195 195 "195" - t196 196 "196" - t197 197 "197" - t198 198 "198" - t199 199 "199" - t200 200 "200" - t201 201 "201" - t202 202 "202" - t203 203 "203" - t204 204 "204" - t205 205 "205" - t206 206 "206" - t207 207 "207" - t208 208 "208" - t209 209 "209" - t210 210 "210" - t211 211 "211" - t212 212 "212" - t213 213 "213" - t214 214 "214" - t215 215 "215" - t216 216 "216" - t217 217 "217" - t218 218 "218" - t219 219 "219" - t220 220 "220" - t221 221 "221" - t222 222 "222" - t223 223 "223" - t224 224 "224" - t225 225 "225" - t226 226 "226" - t227 227 "227" - t228 228 "228" - t229 229 "229" - t230 230 "230" - t231 231 "231" - t232 232 "232" - t233 233 "233" - t234 234 "234" - t235 235 "235" - t236 236 "236" - t237 237 "237" - t238 238 "238" - t239 239 "239" - t240 240 "240" - t241 241 "241" - t242 242 "242" - t243 243 "243" - t244 244 "244" - t245 245 "245" - t246 246 "246" - t247 247 "247" - t248 248 "248" - t249 249 "249" - t250 250 "250" - t251 251 "251" - t252 252 "252" - t253 253 "253" - t254 254 "254" - t255 255 "255" - t256 256 "256" - t257 257 "257" - t258 258 "258" - t259 259 "259" - t260 260 "260" - t261 261 "261" - t262 262 "262" - t263 263 "263" - t264 264 "264" - t265 265 "265" - t266 266 "266" - t267 267 "267" - t268 268 "268" - t269 269 "269" - t270 270 "270" - t271 271 "271" - t272 272 "272" - t273 273 "273" - t274 274 "274" - t275 275 "275" - t276 276 "276" - t277 277 "277" - t278 278 "278" - t279 279 "279" - t280 280 "280" - t281 281 "281" - t282 282 "282" - t283 283 "283" - t284 284 "284" - t285 285 "285" - t286 286 "286" - t287 287 "287" - t288 288 "288" - t289 289 "289" - t290 290 "290" - t291 291 "291" - t292 292 "292" - t293 293 "293" - t294 294 "294" - t295 295 "295" - t296 296 "296" - t297 297 "297" - t298 298 "298" - t299 299 "299" - t300 300 "300" - t301 301 "301" - t302 302 "302" - t303 303 "303" - t304 304 "304" - t305 305 "305" - t306 306 "306" - t307 307 "307" - t308 308 "308" - t309 309 "309" - t310 310 "310" - t311 311 "311" - t312 312 "312" - t313 313 "313" - t314 314 "314" - t315 315 "315" - t316 316 "316" - t317 317 "317" - t318 318 "318" - t319 319 "319" - t320 320 "320" - t321 321 "321" - t322 322 "322" - t323 323 "323" - t324 324 "324" - t325 325 "325" - t326 326 "326" - t327 327 "327" - t328 328 "328" - t329 329 "329" - t330 330 "330" - t331 331 "331" - t332 332 "332" - t333 333 "333" - t334 334 "334" - t335 335 "335" - t336 336 "336" - t337 337 "337" - t338 338 "338" - t339 339 "339" - t340 340 "340" - t341 341 "341" - t342 342 "342" - t343 343 "343" - t344 344 "344" - t345 345 "345" - t346 346 "346" - t347 347 "347" - t348 348 "348" - t349 349 "349" - t350 350 "350" - t351 351 "351" - t352 352 "352" - t353 353 "353" - t354 354 "354" - t355 355 "355" - t356 356 "356" - t357 357 "357" - t358 358 "358" - t359 359 "359" - t360 360 "360" - t361 361 "361" - t362 362 "362" - t363 363 "363" - t364 364 "364" - t365 365 "365" - t366 366 "366" - t367 367 "367" - t368 368 "368" - t369 369 "369" - t370 370 "370" - t371 371 "371" - t372 372 "372" - t373 373 "373" - t374 374 "374" - t375 375 "375" - t376 376 "376" - t377 377 "377" - t378 378 "378" - t379 379 "379" - t380 380 "380" - t381 381 "381" - t382 382 "382" - t383 383 "383" - t384 384 "384" - t385 385 "385" - t386 386 "386" - t387 387 "387" - t388 388 "388" - t389 389 "389" - t390 390 "390" - t391 391 "391" - t392 392 "392" - t393 393 "393" - t394 394 "394" - t395 395 "395" - t396 396 "396" - t397 397 "397" - t398 398 "398" - t399 399 "399" - t400 400 "400" - t401 401 "401" - t402 402 "402" - t403 403 "403" - t404 404 "404" - t405 405 "405" - t406 406 "406" - t407 407 "407" - t408 408 "408" - t409 409 "409" - t410 410 "410" - t411 411 "411" - t412 412 "412" - t413 413 "413" - t414 414 "414" - t415 415 "415" - t416 416 "416" - t417 417 "417" - t418 418 "418" - t419 419 "419" - t420 420 "420" - t421 421 "421" - t422 422 "422" - t423 423 "423" - t424 424 "424" - t425 425 "425" - t426 426 "426" - t427 427 "427" - t428 428 "428" - t429 429 "429" - t430 430 "430" - t431 431 "431" - t432 432 "432" - t433 433 "433" - t434 434 "434" - t435 435 "435" - t436 436 "436" - t437 437 "437" - t438 438 "438" - t439 439 "439" - t440 440 "440" - t441 441 "441" - t442 442 "442" - t443 443 "443" - t444 444 "444" - t445 445 "445" - t446 446 "446" - t447 447 "447" - t448 448 "448" - t449 449 "449" - t450 450 "450" - t451 451 "451" - t452 452 "452" - t453 453 "453" - t454 454 "454" - t455 455 "455" - t456 456 "456" - t457 457 "457" - t458 458 "458" - t459 459 "459" - t460 460 "460" - t461 461 "461" - t462 462 "462" - t463 463 "463" - t464 464 "464" - t465 465 "465" - t466 466 "466" - t467 467 "467" - t468 468 "468" - t469 469 "469" - t470 470 "470" - t471 471 "471" - t472 472 "472" - t473 473 "473" - t474 474 "474" - t475 475 "475" - t476 476 "476" - t477 477 "477" - t478 478 "478" - t479 479 "479" - t480 480 "480" - t481 481 "481" - t482 482 "482" - t483 483 "483" - t484 484 "484" - t485 485 "485" - t486 486 "486" - t487 487 "487" - t488 488 "488" - t489 489 "489" - t490 490 "490" - t491 491 "491" - t492 492 "492" - t493 493 "493" - t494 494 "494" - t495 495 "495" - t496 496 "496" - t497 497 "497" - t498 498 "498" - t499 499 "499" - t500 500 "500" - t501 501 "501" - t502 502 "502" - t503 503 "503" - t504 504 "504" - t505 505 "505" - t506 506 "506" - t507 507 "507" - t508 508 "508" - t509 509 "509" - t510 510 "510" - t511 511 "511" - t512 512 "512" - t513 513 "513" - t514 514 "514" - t515 515 "515" - t516 516 "516" - t517 517 "517" - t518 518 "518" - t519 519 "519" - t520 520 "520" - t521 521 "521" - t522 522 "522" - t523 523 "523" - t524 524 "524" - t525 525 "525" - t526 526 "526" - t527 527 "527" - t528 528 "528" - t529 529 "529" - t530 530 "530" - t531 531 "531" - t532 532 "532" - t533 533 "533" - t534 534 "534" - t535 535 "535" - t536 536 "536" - t537 537 "537" - t538 538 "538" - t539 539 "539" - t540 540 "540" - t541 541 "541" - t542 542 "542" - t543 543 "543" - t544 544 "544" - t545 545 "545" - t546 546 "546" - t547 547 "547" - t548 548 "548" - t549 549 "549" - t550 550 "550" - t551 551 "551" - t552 552 "552" - t553 553 "553" - t554 554 "554" - t555 555 "555" - t556 556 "556" - t557 557 "557" - t558 558 "558" - t559 559 "559" - t560 560 "560" - t561 561 "561" - t562 562 "562" - t563 563 "563" - t564 564 "564" - t565 565 "565" - t566 566 "566" - t567 567 "567" - t568 568 "568" - t569 569 "569" - t570 570 "570" - t571 571 "571" - t572 572 "572" - t573 573 "573" - t574 574 "574" - t575 575 "575" - t576 576 "576" - t577 577 "577" - t578 578 "578" - t579 579 "579" - t580 580 "580" - t581 581 "581" - t582 582 "582" - t583 583 "583" - t584 584 "584" - t585 585 "585" - t586 586 "586" - t587 587 "587" - t588 588 "588" - t589 589 "589" - t590 590 "590" - t591 591 "591" - t592 592 "592" - t593 593 "593" - t594 594 "594" - t595 595 "595" - t596 596 "596" - t597 597 "597" - t598 598 "598" - t599 599 "599" - t600 600 "600" - t601 601 "601" - t602 602 "602" - t603 603 "603" - t604 604 "604" - t605 605 "605" - t606 606 "606" - t607 607 "607" - t608 608 "608" - t609 609 "609" - t610 610 "610" - t611 611 "611" - t612 612 "612" - t613 613 "613" - t614 614 "614" - t615 615 "615" - t616 616 "616" - t617 617 "617" - t618 618 "618" - t619 619 "619" - t620 620 "620" - t621 621 "621" - t622 622 "622" - t623 623 "623" - t624 624 "624" - t625 625 "625" - t626 626 "626" - t627 627 "627" - t628 628 "628" - t629 629 "629" - t630 630 "630" - t631 631 "631" - t632 632 "632" - t633 633 "633" - t634 634 "634" - t635 635 "635" - t636 636 "636" - t637 637 "637" - t638 638 "638" - t639 639 "639" - t640 640 "640" - t641 641 "641" - t642 642 "642" - t643 643 "643" - t644 644 "644" - t645 645 "645" - t646 646 "646" - t647 647 "647" - t648 648 "648" - t649 649 "649" - t650 650 "650" - t651 651 "651" - t652 652 "652" - t653 653 "653" - t654 654 "654" - t655 655 "655" - t656 656 "656" - t657 657 "657" - t658 658 "658" - t659 659 "659" - t660 660 "660" - t661 661 "661" - t662 662 "662" - t663 663 "663" - t664 664 "664" - t665 665 "665" - t666 666 "666" - t667 667 "667" - t668 668 "668" - t669 669 "669" - t670 670 "670" - t671 671 "671" - t672 672 "672" - t673 673 "673" - t674 674 "674" - t675 675 "675" - t676 676 "676" - t677 677 "677" - t678 678 "678" - t679 679 "679" - t680 680 "680" - t681 681 "681" - t682 682 "682" - t683 683 "683" - t684 684 "684" - t685 685 "685" - t686 686 "686" - t687 687 "687" - t688 688 "688" - t689 689 "689" - t690 690 "690" - t691 691 "691" - t692 692 "692" - t693 693 "693" - t694 694 "694" - t695 695 "695" - t696 696 "696" - t697 697 "697" - t698 698 "698" - t699 699 "699" - t700 700 "700" - t701 701 "701" - t702 702 "702" - t703 703 "703" - t704 704 "704" - t705 705 "705" - t706 706 "706" - t707 707 "707" - t708 708 "708" - t709 709 "709" - t710 710 "710" - t711 711 "711" - t712 712 "712" - t713 713 "713" - t714 714 "714" - t715 715 "715" - t716 716 "716" - t717 717 "717" - t718 718 "718" - t719 719 "719" - t720 720 "720" - t721 721 "721" - t722 722 "722" - t723 723 "723" - t724 724 "724" - t725 725 "725" - t726 726 "726" - t727 727 "727" - t728 728 "728" - t729 729 "729" - t730 730 "730" - t731 731 "731" - t732 732 "732" - t733 733 "733" - t734 734 "734" - t735 735 "735" - t736 736 "736" - t737 737 "737" - t738 738 "738" - t739 739 "739" - t740 740 "740" - t741 741 "741" - t742 742 "742" - t743 743 "743" - t744 744 "744" - t745 745 "745" - t746 746 "746" - t747 747 "747" - t748 748 "748" - t749 749 "749" - t750 750 "750" - t751 751 "751" - t752 752 "752" - t753 753 "753" - t754 754 "754" - t755 755 "755" - t756 756 "756" - t757 757 "757" - t758 758 "758" - t759 759 "759" - t760 760 "760" - t761 761 "761" - t762 762 "762" - t763 763 "763" - t764 764 "764" - t765 765 "765" - t766 766 "766" - t767 767 "767" - t768 768 "768" - t769 769 "769" - t770 770 "770" - t771 771 "771" - t772 772 "772" - t773 773 "773" - t774 774 "774" - t775 775 "775" - t776 776 "776" - t777 777 "777" - t778 778 "778" - t779 779 "779" - t780 780 "780" - t781 781 "781" - t782 782 "782" - t783 783 "783" - t784 784 "784" - t785 785 "785" - t786 786 "786" - t787 787 "787" - t788 788 "788" - t789 789 "789" - t790 790 "790" - t791 791 "791" - t792 792 "792" - t793 793 "793" - t794 794 "794" - t795 795 "795" - t796 796 "796" - t797 797 "797" - t798 798 "798" - t799 799 "799" - t800 800 "800" - t801 801 "801" - t802 802 "802" - t803 803 "803" - t804 804 "804" - t805 805 "805" - t806 806 "806" - t807 807 "807" - t808 808 "808" - t809 809 "809" - t810 810 "810" - t811 811 "811" - t812 812 "812" - t813 813 "813" - t814 814 "814" - t815 815 "815" - t816 816 "816" - t817 817 "817" - t818 818 "818" - t819 819 "819" - t820 820 "820" - t821 821 "821" - t822 822 "822" - t823 823 "823" - t824 824 "824" - t825 825 "825" - t826 826 "826" - t827 827 "827" - t828 828 "828" - t829 829 "829" - t830 830 "830" - t831 831 "831" - t832 832 "832" - t833 833 "833" - t834 834 "834" - t835 835 "835" - t836 836 "836" - t837 837 "837" - t838 838 "838" - t839 839 "839" - t840 840 "840" - t841 841 "841" - t842 842 "842" - t843 843 "843" - t844 844 "844" - t845 845 "845" - t846 846 "846" - t847 847 "847" - t848 848 "848" - t849 849 "849" - t850 850 "850" - t851 851 "851" - t852 852 "852" - t853 853 "853" - t854 854 "854" - t855 855 "855" - t856 856 "856" - t857 857 "857" - t858 858 "858" - t859 859 "859" - t860 860 "860" - t861 861 "861" - t862 862 "862" - t863 863 "863" - t864 864 "864" - t865 865 "865" - t866 866 "866" - t867 867 "867" - t868 868 "868" - t869 869 "869" - t870 870 "870" - t871 871 "871" - t872 872 "872" - t873 873 "873" - t874 874 "874" - t875 875 "875" - t876 876 "876" - t877 877 "877" - t878 878 "878" - t879 879 "879" - t880 880 "880" - t881 881 "881" - t882 882 "882" - t883 883 "883" - t884 884 "884" - t885 885 "885" - t886 886 "886" - t887 887 "887" - t888 888 "888" - t889 889 "889" - t890 890 "890" - t891 891 "891" - t892 892 "892" - t893 893 "893" - t894 894 "894" - t895 895 "895" - t896 896 "896" - t897 897 "897" - t898 898 "898" - t899 899 "899" - t900 900 "900" - t901 901 "901" - t902 902 "902" - t903 903 "903" - t904 904 "904" - t905 905 "905" - t906 906 "906" - t907 907 "907" - t908 908 "908" - t909 909 "909" - t910 910 "910" - t911 911 "911" - t912 912 "912" - t913 913 "913" - t914 914 "914" - t915 915 "915" - t916 916 "916" - t917 917 "917" - t918 918 "918" - t919 919 "919" - t920 920 "920" - t921 921 "921" - t922 922 "922" - t923 923 "923" - t924 924 "924" - t925 925 "925" - t926 926 "926" - t927 927 "927" - t928 928 "928" - t929 929 "929" - t930 930 "930" - t931 931 "931" - t932 932 "932" - t933 933 "933" - t934 934 "934" - t935 935 "935" - t936 936 "936" - t937 937 "937" - t938 938 "938" - t939 939 "939" - t940 940 "940" - t941 941 "941" - t942 942 "942" - t943 943 "943" - t944 944 "944" - t945 945 "945" - t946 946 "946" - t947 947 "947" - t948 948 "948" - t949 949 "949" - t950 950 "950" - t951 951 "951" - t952 952 "952" - t953 953 "953" - t954 954 "954" - t955 955 "955" - t956 956 "956" - t957 957 "957" - t958 958 "958" - t959 959 "959" - t960 960 "960" - t961 961 "961" - t962 962 "962" - t963 963 "963" - t964 964 "964" - t965 965 "965" - t966 966 "966" - t967 967 "967" - t968 968 "968" - t969 969 "969" - t970 970 "970" - t971 971 "971" - t972 972 "972" - t973 973 "973" - t974 974 "974" - t975 975 "975" - t976 976 "976" - t977 977 "977" - t978 978 "978" - t979 979 "979" - t980 980 "980" - t981 981 "981" - t982 982 "982" - t983 983 "983" - t984 984 "984" - t985 985 "985" - t986 986 "986" - t987 987 "987" - t988 988 "988" - t989 989 "989" - t990 990 "990" - t991 991 "991" - t992 992 "992" - t993 993 "993" - t994 994 "994" - t995 995 "995" - t996 996 "996" - t997 997 "997" - t998 998 "998" - t999 999 "999" - t1000 1000 "1000" - -%% -exp: "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" - "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" - "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" - "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" - "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" - "73" "74" "75" "76" "77" "78" "79" "80" "81" "82" "83" "84" "85" "86" - "87" "88" "89" "90" "91" "92" "93" "94" "95" "96" "97" "98" "99" "100" - "101" "102" "103" "104" "105" "106" "107" "108" "109" "110" "111" "112" - "113" "114" "115" "116" "117" "118" "119" "120" "121" "122" "123" "124" - "125" "126" "127" "128" "129" "130" "131" "132" "133" "134" "135" "136" - "137" "138" "139" "140" "141" "142" "143" "144" "145" "146" "147" "148" - "149" "150" "151" "152" "153" "154" "155" "156" "157" "158" "159" "160" - "161" "162" "163" "164" "165" "166" "167" "168" "169" "170" "171" "172" - "173" "174" "175" "176" "177" "178" "179" "180" "181" "182" "183" "184" - "185" "186" "187" "188" "189" "190" "191" "192" "193" "194" "195" "196" - "197" "198" "199" "200" "201" "202" "203" "204" "205" "206" "207" "208" - "209" "210" "211" "212" "213" "214" "215" "216" "217" "218" "219" "220" - "221" "222" "223" "224" "225" "226" "227" "228" "229" "230" "231" "232" - "233" "234" "235" "236" "237" "238" "239" "240" "241" "242" "243" "244" - "245" "246" "247" "248" "249" "250" "251" "252" "253" "254" "255" "256" - "257" "258" "259" "260" "261" "262" "263" "264" "265" "266" "267" "268" - "269" "270" "271" "272" "273" "274" "275" "276" "277" "278" "279" "280" - "281" "282" "283" "284" "285" "286" "287" "288" "289" "290" "291" "292" - "293" "294" "295" "296" "297" "298" "299" "300" "301" "302" "303" "304" - "305" "306" "307" "308" "309" "310" "311" "312" "313" "314" "315" "316" - "317" "318" "319" "320" "321" "322" "323" "324" "325" "326" "327" "328" - "329" "330" "331" "332" "333" "334" "335" "336" "337" "338" "339" "340" - "341" "342" "343" "344" "345" "346" "347" "348" "349" "350" "351" "352" - "353" "354" "355" "356" "357" "358" "359" "360" "361" "362" "363" "364" - "365" "366" "367" "368" "369" "370" "371" "372" "373" "374" "375" "376" - "377" "378" "379" "380" "381" "382" "383" "384" "385" "386" "387" "388" - "389" "390" "391" "392" "393" "394" "395" "396" "397" "398" "399" "400" - "401" "402" "403" "404" "405" "406" "407" "408" "409" "410" "411" "412" - "413" "414" "415" "416" "417" "418" "419" "420" "421" "422" "423" "424" - "425" "426" "427" "428" "429" "430" "431" "432" "433" "434" "435" "436" - "437" "438" "439" "440" "441" "442" "443" "444" "445" "446" "447" "448" - "449" "450" "451" "452" "453" "454" "455" "456" "457" "458" "459" "460" - "461" "462" "463" "464" "465" "466" "467" "468" "469" "470" "471" "472" - "473" "474" "475" "476" "477" "478" "479" "480" "481" "482" "483" "484" - "485" "486" "487" "488" "489" "490" "491" "492" "493" "494" "495" "496" - "497" "498" "499" "500" "501" "502" "503" "504" "505" "506" "507" "508" - "509" "510" "511" "512" "513" "514" "515" "516" "517" "518" "519" "520" - "521" "522" "523" "524" "525" "526" "527" "528" "529" "530" "531" "532" - "533" "534" "535" "536" "537" "538" "539" "540" "541" "542" "543" "544" - "545" "546" "547" "548" "549" "550" "551" "552" "553" "554" "555" "556" - "557" "558" "559" "560" "561" "562" "563" "564" "565" "566" "567" "568" - "569" "570" "571" "572" "573" "574" "575" "576" "577" "578" "579" "580" - "581" "582" "583" "584" "585" "586" "587" "588" "589" "590" "591" "592" - "593" "594" "595" "596" "597" "598" "599" "600" "601" "602" "603" "604" - "605" "606" "607" "608" "609" "610" "611" "612" "613" "614" "615" "616" - "617" "618" "619" "620" "621" "622" "623" "624" "625" "626" "627" "628" - "629" "630" "631" "632" "633" "634" "635" "636" "637" "638" "639" "640" - "641" "642" "643" "644" "645" "646" "647" "648" "649" "650" "651" "652" - "653" "654" "655" "656" "657" "658" "659" "660" "661" "662" "663" "664" - "665" "666" "667" "668" "669" "670" "671" "672" "673" "674" "675" "676" - "677" "678" "679" "680" "681" "682" "683" "684" "685" "686" "687" "688" - "689" "690" "691" "692" "693" "694" "695" "696" "697" "698" "699" "700" - "701" "702" "703" "704" "705" "706" "707" "708" "709" "710" "711" "712" - "713" "714" "715" "716" "717" "718" "719" "720" "721" "722" "723" "724" - "725" "726" "727" "728" "729" "730" "731" "732" "733" "734" "735" "736" - "737" "738" "739" "740" "741" "742" "743" "744" "745" "746" "747" "748" - "749" "750" "751" "752" "753" "754" "755" "756" "757" "758" "759" "760" - "761" "762" "763" "764" "765" "766" "767" "768" "769" "770" "771" "772" - "773" "774" "775" "776" "777" "778" "779" "780" "781" "782" "783" "784" - "785" "786" "787" "788" "789" "790" "791" "792" "793" "794" "795" "796" - "797" "798" "799" "800" "801" "802" "803" "804" "805" "806" "807" "808" - "809" "810" "811" "812" "813" "814" "815" "816" "817" "818" "819" "820" - "821" "822" "823" "824" "825" "826" "827" "828" "829" "830" "831" "832" - "833" "834" "835" "836" "837" "838" "839" "840" "841" "842" "843" "844" - "845" "846" "847" "848" "849" "850" "851" "852" "853" "854" "855" "856" - "857" "858" "859" "860" "861" "862" "863" "864" "865" "866" "867" "868" - "869" "870" "871" "872" "873" "874" "875" "876" "877" "878" "879" "880" - "881" "882" "883" "884" "885" "886" "887" "888" "889" "890" "891" "892" - "893" "894" "895" "896" "897" "898" "899" "900" "901" "902" "903" "904" - "905" "906" "907" "908" "909" "910" "911" "912" "913" "914" "915" "916" - "917" "918" "919" "920" "921" "922" "923" "924" "925" "926" "927" "928" - "929" "930" "931" "932" "933" "934" "935" "936" "937" "938" "939" "940" - "941" "942" "943" "944" "945" "946" "947" "948" "949" "950" "951" "952" - "953" "954" "955" "956" "957" "958" "959" "960" "961" "962" "963" "964" - "965" "966" "967" "968" "969" "970" "971" "972" "973" "974" "975" "976" - "977" "978" "979" "980" "981" "982" "983" "984" "985" "986" "987" "988" - "989" "990" "991" "992" "993" "994" "995" "996" "997" "998" "999" "1000" - ; -%% -#include - - - - -/* A C error reporting function. */ -/* !POSIX */ static -void yyerror (const char *msg) -{ - fprintf (stderr, "%s\n", msg); -} -static int -yylex (void) -{ - static int counter = 1; - if (counter <= MAX) - return counter++; - assert (counter++ == MAX + 1); - return 0; -} -#include /* getenv. */ -#include /* strcmp. */ -int -main (int argc, char const* argv[]) -{ - (void) argc; - (void) argv; - return yyparse (); -} -./calc.at:1494: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./torture.at:236: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y - -./calc.at:1492: cat stderr - -stdout: -603. calc.at:1561: testing Calculator Java parse.trace parse.error=custom %locations api.push-pull=both parse.lac=full ... -./calc.at:1561: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated -o Calc.java Calc.y -./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1494: cat stderr -./calc.at:1492: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc calc.hh - -input: -./calc.at:1491: cat stderr - | (# + 1) = 1111 -./calc.at:1492: $PREPARSER ./calc input -input: -input: -stderr: -603. calc.at:1561: | 1 + 2 * 3 = 7 - | 1 + 2 * -3 = -5 - | - | -1^2 = -1 - | (-1)^2 = 1 - | - | ---1 = -1 - | - | 1 - 2 - 3 = -4 - | 1 - (2 - 3) = 2 - | - | 2^2^3 = 256 - | (2^2)^3 = 64 - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1494: $PREPARSER ./calc input -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Reading a token -Next token is token "number" (1.6: 1) -Error: discarding token "number" (1.6: 1) -Reading a token -Next token is token ')' (1.7: ) -Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. @@ -227833,2529 +223179,17 @@ Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -input: -./calc.at:1492: $PREPARSER ./calc input -608. torture.at:272: testing State number type: 256 states ... -./torture.at:272: ruby $abs_top_srcdir/tests/linear 256 >input.y || exit 77 - skipped (calc.at:1561) -stderr: - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1491: $PREPARSER ./calc input -stderr: -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -606. torture.at:270: testing State number type: 128 states ... -./torture.at:270: ruby $abs_top_srcdir/tests/linear 128 >input.y || exit 77 -Starting parse -Entering state 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 20 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 18 -Reading a token -Next token is token number (1.13: 7) -Shifting token number (1.13: 7) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.13: 7) --> $$ = nterm exp (1.13: 7) -Entering state 27 -Reading a token -Next token is token '\n' (1.14-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-9: 7) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13: 7) --> $$ = nterm exp (1.1-13: 7) -Entering state 8 -Next token is token '\n' (1.14-2.0: ) -Shifting token '\n' (1.14-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-13: 7) - $2 = token '\n' (1.14-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Next token is token number (2.1: 1) -Shifting token number (2.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2.1: 1) --> $$ = nterm exp (2.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (2.3: ) -Shifting token '+' (2.3: ) -Entering state 20 -Reading a token -Next token is token number (2.5: 2) -Shifting token number (2.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2.5: 2) --> $$ = nterm exp (2.5: 2) -Entering state 29 -Reading a token -Next token is token '*' (2.7: ) -Shifting token '*' (2.7: ) -Entering state 21 -Reading a token -Next token is token '-' (2.9: ) -Shifting token '-' (2.9: ) -Entering state 2 -Reading a token -Next token is token number (2.10: 3) -Shifting token number (2.10: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2.10: 3) --> $$ = nterm exp (2.10: 3) -Entering state 10 -Reading a token -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (2.9: ) - $2 = nterm exp (2.10: 3) --> $$ = nterm exp (2.9-10: -3) -Entering state 30 -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (2.5: 2) - $2 = token '*' (2.7: ) - $3 = nterm exp (2.9-10: -3) --> $$ = nterm exp (2.5-10: -6) -Entering state 29 -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (2.1: 1) - $2 = token '+' (2.3: ) - $3 = nterm exp (2.5-10: -6) --> $$ = nterm exp (2.1-10: -5) -Entering state 8 -Next token is token '=' (2.12: ) -Shifting token '=' (2.12: ) -Entering state 18 -Reading a token -Next token is token '-' (2.14: ) -Shifting token '-' (2.14: ) -Entering state 2 -Reading a token -Next token is token number (2.15: 5) -Shifting token number (2.15: 5) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2.15: 5) --> $$ = nterm exp (2.15: 5) -Entering state 10 -Reading a token -Next token is token '\n' (2.16-3.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (2.14: ) - $2 = nterm exp (2.15: 5) --> $$ = nterm exp (2.14-15: -5) -Entering state 27 -Next token is token '\n' (2.16-3.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (2.1-10: -5) - $2 = token '=' (2.12: ) - $3 = nterm exp (2.14-15: -5) --> $$ = nterm exp (2.1-15: -5) -Entering state 8 -Next token is token '\n' (2.16-3.0: ) -Shifting token '\n' (2.16-3.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2.1-15: -5) - $2 = token '\n' (2.16-3.0: ) --> $$ = nterm line (2.1-3.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-2.0: ) - $2 = nterm line (2.1-3.0: ) --> $$ = nterm input (1.1-3.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (3.1-4.0: ) -Shifting token '\n' (3.1-4.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (3.1-4.0: ) --> $$ = nterm line (3.1-4.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-3.0: ) - $2 = nterm line (3.1-4.0: ) --> $$ = nterm input (1.1-4.0: ) -Entering state 6 -Reading a token -Next token is token '-' (4.1: ) -Shifting token '-' (4.1: ) -Entering state 2 -Reading a token -Next token is token number (4.2: 1) -Shifting token number (4.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (4.2: 1) --> $$ = nterm exp (4.2: 1) -Entering state 10 -Reading a token -Next token is token '^' (4.3: ) -Shifting token '^' (4.3: ) -Entering state 23 -Reading a token -Next token is token number (4.4: 2) -Shifting token number (4.4: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (4.4: 2) --> $$ = nterm exp (4.4: 2) -Entering state 32 -Reading a token -Next token is token '=' (4.6: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (4.2: 1) - $2 = token '^' (4.3: ) - $3 = nterm exp (4.4: 2) --> $$ = nterm exp (4.2-4: 1) -Entering state 10 -Next token is token '=' (4.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (4.1: ) - $2 = nterm exp (4.2-4: 1) --> $$ = nterm exp (4.1-4: -1) -Entering state 8 -Next token is token '=' (4.6: ) -Shifting token '=' (4.6: ) -Entering state 18 -Reading a token -Next token is token '-' (4.8: ) -Shifting token '-' (4.8: ) -Entering state 2 -Reading a token -Next token is token number (4.9: 1) -Shifting token number (4.9: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (4.9: 1) --> $$ = nterm exp (4.9: 1) -Entering state 10 -Reading a token -Next token is token '\n' (4.10-5.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (4.8: ) - $2 = nterm exp (4.9: 1) --> $$ = nterm exp (4.8-9: -1) -Entering state 27 -Next token is token '\n' (4.10-5.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (4.1-4: -1) - $2 = token '=' (4.6: ) - $3 = nterm exp (4.8-9: -1) --> $$ = nterm exp (4.1-9: -1) -Entering state 8 -Next token is token '\n' (4.10-5.0: ) -Shifting token '\n' (4.10-5.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (4.1-9: -1) - $2 = token '\n' (4.10-5.0: ) --> $$ = nterm line (4.1-5.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-4.0: ) - $2 = nterm line (4.1-5.0: ) --> $$ = nterm input (1.1-5.0: ) -Entering state 6 -Reading a token -Next token is token '(' (5.1: ) -Shifting token '(' (5.1: ) -Entering state 4 -Reading a token -Next token is token '-' (5.2: ) -Shifting token '-' (5.2: ) -Entering state 2 -Reading a token -Next token is token number (5.3: 1) -Shifting token number (5.3: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (5.3: 1) --> $$ = nterm exp (5.3: 1) -Entering state 10 -Reading a token -Next token is token ')' (5.4: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (5.2: ) - $2 = nterm exp (5.3: 1) --> $$ = nterm exp (5.2-3: -1) -Entering state 12 -Next token is token ')' (5.4: ) -Shifting token ')' (5.4: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (5.1: ) - $2 = nterm exp (5.2-3: -1) - $3 = token ')' (5.4: ) --> $$ = nterm exp (5.1-4: -1) -Entering state 8 -Reading a token -Next token is token '^' (5.5: ) -Shifting token '^' (5.5: ) -Entering state 23 -Reading a token -Next token is token number (5.6: 2) -Shifting token number (5.6: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (5.6: 2) --> $$ = nterm exp (5.6: 2) -Entering state 32 -Reading a token -Next token is token '=' (5.8: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (5.1-4: -1) - $2 = token '^' (5.5: ) - $3 = nterm exp (5.6: 2) --> $$ = nterm exp (5.1-6: 1) -Entering state 8 -Next token is token '=' (5.8: ) -Shifting token '=' (5.8: ) -Entering state 18 -Reading a token -Next token is token number (5.10: 1) -Shifting token number (5.10: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (5.10: 1) --> $$ = nterm exp (5.10: 1) -Entering state 27 -Reading a token -Next token is token '\n' (5.11-6.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (5.1-6: 1) - $2 = token '=' (5.8: ) - $3 = nterm exp (5.10: 1) --> $$ = nterm exp (5.1-10: 1) -Entering state 8 -Next token is token '\n' (5.11-6.0: ) -Shifting token '\n' (5.11-6.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (5.1-10: 1) - $2 = token '\n' (5.11-6.0: ) --> $$ = nterm line (5.1-6.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-5.0: ) - $2 = nterm line (5.1-6.0: ) --> $$ = nterm input (1.1-6.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (6.1-7.0: ) -Shifting token '\n' (6.1-7.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (6.1-7.0: ) --> $$ = nterm line (6.1-7.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-6.0: ) - $2 = nterm line (6.1-7.0: ) --> $$ = nterm input (1.1-7.0: ) -Entering state 6 -Reading a token -Next token is token '-' (7.1: ) -Shifting token '-' (7.1: ) -Entering state 2 -Reading a token -Next token is token '-' (7.2: ) -Shifting token '-' (7.2: ) -Entering state 2 -Reading a token -Next token is token '-' (7.3: ) -Shifting token '-' (7.3: ) -Entering state 2 -Reading a token -Next token is token number (7.4: 1) -Shifting token number (7.4: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (7.4: 1) --> $$ = nterm exp (7.4: 1) -Entering state 10 -Reading a token -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.3: ) - $2 = nterm exp (7.4: 1) --> $$ = nterm exp (7.3-4: -1) -Entering state 10 -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.2: ) - $2 = nterm exp (7.3-4: -1) --> $$ = nterm exp (7.2-4: 1) -Entering state 10 -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.1: ) - $2 = nterm exp (7.2-4: 1) --> $$ = nterm exp (7.1-4: -1) -Entering state 8 -Next token is token '=' (7.6: ) -Shifting token '=' (7.6: ) -Entering state 18 -Reading a token -Next token is token '-' (7.8: ) -Shifting token '-' (7.8: ) -Entering state 2 -Reading a token -Next token is token number (7.9: 1) -Shifting token number (7.9: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (7.9: 1) --> $$ = nterm exp (7.9: 1) -Entering state 10 -Reading a token -Next token is token '\n' (7.10-8.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.8: ) - $2 = nterm exp (7.9: 1) --> $$ = nterm exp (7.8-9: -1) -Entering state 27 -Next token is token '\n' (7.10-8.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (7.1-4: -1) - $2 = token '=' (7.6: ) - $3 = nterm exp (7.8-9: -1) --> $$ = nterm exp (7.1-9: -1) -Entering state 8 -Next token is token '\n' (7.10-8.0: ) -Shifting token '\n' (7.10-8.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (7.1-9: -1) - $2 = token '\n' (7.10-8.0: ) --> $$ = nterm line (7.1-8.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-7.0: ) - $2 = nterm line (7.1-8.0: ) --> $$ = nterm input (1.1-8.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (8.1-9.0: ) -Shifting token '\n' (8.1-9.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (8.1-9.0: ) --> $$ = nterm line (8.1-9.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-8.0: ) - $2 = nterm line (8.1-9.0: ) --> $$ = nterm input (1.1-9.0: ) -Entering state 6 -Reading a token -Next token is token number (9.1: 1) -Shifting token number (9.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (9.1: 1) --> $$ = nterm exp (9.1: 1) -Entering state 8 -Reading a token -Next token is token '-' (9.3: ) -Shifting token '-' (9.3: ) -Entering state 19 -Reading a token -Next token is token number (9.5: 2) -Shifting token number (9.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (9.5: 2) --> $$ = nterm exp (9.5: 2) -Entering state 28 -Reading a token -Next token is token '-' (9.7: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (9.1: 1) - $2 = token '-' (9.3: ) - $3 = nterm exp (9.5: 2) --> $$ = nterm exp (9.1-5: -1) -Entering state 8 -Next token is token '-' (9.7: ) -Shifting token '-' (9.7: ) -Entering state 19 -Reading a token -Next token is token number (9.9: 3) -Shifting token number (9.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (9.9: 3) --> $$ = nterm exp (9.9: 3) -Entering state 28 -Reading a token -Next token is token '=' (9.11: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (9.1-5: -1) - $2 = token '-' (9.7: ) - $3 = nterm exp (9.9: 3) --> $$ = nterm exp (9.1-9: -4) -Entering state 8 -Next token is token '=' (9.11: ) -Shifting token '=' (9.11: ) -Entering state 18 -Reading a token -Next token is token '-' (9.13: ) -Shifting token '-' (9.13: ) -Entering state 2 -Reading a token -Next token is token number (9.14: 4) -Shifting token number (9.14: 4) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (9.14: 4) --> $$ = nterm exp (9.14: 4) -Entering state 10 -Reading a token -Next token is token '\n' (9.15-10.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (9.13: ) - $2 = nterm exp (9.14: 4) --> $$ = nterm exp (9.13-14: -4) -Entering state 27 -Next token is token '\n' (9.15-10.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (9.1-9: -4) - $2 = token '=' (9.11: ) - $3 = nterm exp (9.13-14: -4) --> $$ = nterm exp (9.1-14: -4) -Entering state 8 -Next token is token '\n' (9.15-10.0: ) -Shifting token '\n' (9.15-10.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (9.1-14: -4) - $2 = token '\n' (9.15-10.0: ) --> $$ = nterm line (9.1-10.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-9.0: ) - $2 = nterm line (9.1-10.0: ) --> $$ = nterm input (1.1-10.0: ) -Entering state 6 -Reading a token -Next token is token number (10.1: 1) -Shifting token number (10.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (10.1: 1) --> $$ = nterm exp (10.1: 1) -Entering state 8 -Reading a token -Next token is token '-' (10.3: ) -Shifting token '-' (10.3: ) -Entering state 19 -Reading a token -Next token is token '(' (10.5: ) -Shifting token '(' (10.5: ) -Entering state 4 -Reading a token -Next token is token number (10.6: 2) -Shifting token number (10.6: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (10.6: 2) --> $$ = nterm exp (10.6: 2) -Entering state 12 -Reading a token -Next token is token '-' (10.8: ) -Shifting token '-' (10.8: ) -Entering state 19 -Reading a token -Next token is token number (10.10: 3) -Shifting token number (10.10: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (10.10: 3) --> $$ = nterm exp (10.10: 3) -Entering state 28 -Reading a token -Next token is token ')' (10.11: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (10.6: 2) - $2 = token '-' (10.8: ) - $3 = nterm exp (10.10: 3) --> $$ = nterm exp (10.6-10: -1) -Entering state 12 -Next token is token ')' (10.11: ) -Shifting token ')' (10.11: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (10.5: ) - $2 = nterm exp (10.6-10: -1) - $3 = token ')' (10.11: ) --> $$ = nterm exp (10.5-11: -1) -Entering state 28 -Reading a token -Next token is token '=' (10.13: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (10.1: 1) - $2 = token '-' (10.3: ) - $3 = nterm exp (10.5-11: -1) --> $$ = nterm exp (10.1-11: 2) -Entering state 8 -Next token is token '=' (10.13: ) -Shifting token '=' (10.13: ) -Entering state 18 -Reading a token -Next token is token number (10.15: 2) -Shifting token number (10.15: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (10.15: 2) --> $$ = nterm exp (10.15: 2) -Entering state 27 -Reading a token -Next token is token '\n' (10.16-11.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (10.1-11: 2) - $2 = token '=' (10.13: ) - $3 = nterm exp (10.15: 2) --> $$ = nterm exp (10.1-15: 2) -Entering state 8 -Next token is token '\n' (10.16-11.0: ) -Shifting token '\n' (10.16-11.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (10.1-15: 2) - $2 = token '\n' (10.16-11.0: ) --> $$ = nterm line (10.1-11.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-10.0: ) - $2 = nterm line (10.1-11.0: ) --> $$ = nterm input (1.1-11.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (11.1-12.0: ) -Shifting token '\n' (11.1-12.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (11.1-12.0: ) --> $$ = nterm line (11.1-12.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-11.0: ) - $2 = nterm line (11.1-12.0: ) --> $$ = nterm input (1.1-12.0: ) -Entering state 6 -Reading a token -Next token is token number (12.1: 2) -Shifting token number (12.1: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (12.1: 2) --> $$ = nterm exp (12.1: 2) -Entering state 8 -Reading a token -Next token is token '^' (12.2: ) -Shifting token '^' (12.2: ) -Entering state 23 -Reading a token -Next token is token number (12.3: 2) -Shifting token number (12.3: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (12.3: 2) --> $$ = nterm exp (12.3: 2) -Entering state 32 -Reading a token -Next token is token '^' (12.4: ) -Shifting token '^' (12.4: ) -Entering state 23 -Reading a token -Next token is token number (12.5: 3) -Shifting token number (12.5: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (12.5: 3) --> $$ = nterm exp (12.5: 3) -Entering state 32 -Reading a token -Next token is token '=' (12.7: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (12.3: 2) - $2 = token '^' (12.4: ) - $3 = nterm exp (12.5: 3) --> $$ = nterm exp (12.3-5: 8) -Entering state 32 -Next token is token '=' (12.7: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (12.1: 2) - $2 = token '^' (12.2: ) - $3 = nterm exp (12.3-5: 8) --> $$ = nterm exp (12.1-5: 256) -Entering state 8 -Next token is token '=' (12.7: ) -Shifting token '=' (12.7: ) -Entering state 18 -Reading a token -Next token is token number (12.9-11: 256) -Shifting token number (12.9-11: 256) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (12.9-11: 256) --> $$ = nterm exp (12.9-11: 256) -Entering state 27 -Reading a token -Next token is token '\n' (12.12-13.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (12.1-5: 256) - $2 = token '=' (12.7: ) - $3 = nterm exp (12.9-11: 256) --> $$ = nterm exp (12.1-11: 256) -Entering state 8 -Next token is token '\n' (12.12-13.0: ) -Shifting token '\n' (12.12-13.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (12.1-11: 256) - $2 = token '\n' (12.12-13.0: ) --> $$ = nterm line (12.1-13.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-12.0: ) - $2 = nterm line (12.1-13.0: ) --> $$ = nterm input (1.1-13.0: ) -Entering state 6 -Reading a token -Next token is token '(' (13.1: ) -Shifting token '(' (13.1: ) -Entering state 4 -Reading a token -Next token is token number (13.2: 2) -Shifting token number (13.2: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (13.2: 2) --> $$ = nterm exp (13.2: 2) -Entering state 12 -Reading a token -Next token is token '^' (13.3: ) -Shifting token '^' (13.3: ) -Entering state 23 -Reading a token -Next token is token number (13.4: 2) -Shifting token number (13.4: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (13.4: 2) --> $$ = nterm exp (13.4: 2) -Entering state 32 -Reading a token -Next token is token ')' (13.5: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (13.2: 2) - $2 = token '^' (13.3: ) - $3 = nterm exp (13.4: 2) --> $$ = nterm exp (13.2-4: 4) -Entering state 12 -Next token is token ')' (13.5: ) -Shifting token ')' (13.5: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (13.1: ) - $2 = nterm exp (13.2-4: 4) - $3 = token ')' (13.5: ) --> $$ = nterm exp (13.1-5: 4) -Entering state 8 -Reading a token -Next token is token '^' (13.6: ) -Shifting token '^' (13.6: ) -Entering state 23 -Reading a token -Next token is token number (13.7: 3) -Shifting token number (13.7: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (13.7: 3) --> $$ = nterm exp (13.7: 3) -Entering state 32 -Reading a token -Next token is token '=' (13.9: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (13.1-5: 4) - $2 = token '^' (13.6: ) - $3 = nterm exp (13.7: 3) --> $$ = nterm exp (13.1-7: 64) -Entering state 8 -Next token is token '=' (13.9: ) -Shifting token '=' (13.9: ) -Entering state 18 -Reading a token -Next token is token number (13.11-12: 64) -Shifting token number (13.11-12: 64) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (13.11-12: 64) --> $$ = nterm exp (13.11-12: 64) -Entering state 27 -Reading a token -Next token is token '\n' (13.13-14.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (13.1-7: 64) - $2 = token '=' (13.9: ) - $3 = nterm exp (13.11-12: 64) --> $$ = nterm exp (13.1-12: 64) -Entering state 8 -Next token is token '\n' (13.13-14.0: ) -Shifting token '\n' (13.13-14.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (13.1-12: 64) - $2 = token '\n' (13.13-14.0: ) --> $$ = nterm line (13.1-14.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-13.0: ) - $2 = nterm line (13.1-14.0: ) --> $$ = nterm input (1.1-14.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input (14.1: ) -Entering state 16 -Cleanup: popping token end of input (14.1: ) -Cleanup: popping nterm input (1.1-14.0: ) -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Reading a token -Next token is token "number" (1.7: 1) -Shifting token "number" (1.7: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 20 -Reading a token -Next token is token "number" (1.11: 1) -Shifting token "number" (1.11: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.11: 1) --> $$ = nterm exp (1.11: 1) -Entering state 29 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 20 -Reading a token -Next token is token "number" (1.15: 1) -Shifting token "number" (1.15: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 29 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 20 -Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Error: popping nterm exp (1.7-15: 3) -Shifting token error (1.7-18: ) -Entering state 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) -Entering state 29 -Reading a token -Next token is token '+' (1.20: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) -Entering state 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) -Entering state 20 -Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) -Reading a token -Next token is token ')' (1.28: ) -Entering state 11 -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 29 -Reading a token -Next token is token '+' (1.30: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) -Entering state 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) -Entering state 20 -Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) -Entering state 4 -Reading a token -Next token is token "number" (1.33: 1) -Shifting token "number" (1.33: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 21 -Reading a token -Next token is token "number" (1.37: 2) -Shifting token "number" (1.37: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.39: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) -Entering state 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 21 -Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Error: popping nterm exp (1.33-37: 2) -Shifting token error (1.33-41: ) -Entering state 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Reading a token -Next token is token ')' (1.42: ) -Entering state 11 -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.44: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) -Entering state 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) -Entering state 18 -Reading a token -Next token is token "number" (1.46: 1) -Shifting token "number" (1.46: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.46: 1) --> $$ = nterm exp (1.46: 1) -Entering state 27 -Reading a token -Next token is token '\n' (1.47-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) -Entering state 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Reading a token -Next token is token number (1.7: 1) -Shifting token number (1.7: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 20 -Reading a token -Next token is token number (1.11: 1) -Shifting token number (1.11: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.11: 1) --> $$ = nterm exp (1.11: 1) -Entering state 29 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 20 -Reading a token -Next token is token number (1.15: 1) -Shifting token number (1.15: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 29 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 20 -Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Error: popping nterm exp (1.7-15: 3) -Shifting token error (1.7-18: ) -Entering state 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) -Entering state 29 -Reading a token -Next token is token '+' (1.20: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) -Entering state 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) -Entering state 20 -Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) -Reading a token -Next token is token ')' (1.28: ) -Entering state 11 -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 29 -Reading a token -Next token is token '+' (1.30: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) -Entering state 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) -Entering state 20 -Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) -Entering state 4 -Reading a token -Next token is token number (1.33: 1) -Shifting token number (1.33: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 21 -Reading a token -Next token is token number (1.37: 2) -Shifting token number (1.37: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.39: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) -Entering state 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 21 -Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Error: popping nterm exp (1.33-37: 2) -Shifting token error (1.33-41: ) -Entering state 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Reading a token -Next token is token ')' (1.42: ) -Entering state 11 -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.44: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) -Entering state 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) -Entering state 18 -Reading a token -Next token is token number (1.46: 1) -Shifting token number (1.46: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.46: 1) --> $$ = nterm exp (1.46: 1) -Entering state 27 -Reading a token -Next token is token '\n' (1.47-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) -Entering state 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input (2.1: ) -Entering state 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -607. torture.at:271: testing State number type: 129 states ... -./torture.at:271: ruby $abs_top_srcdir/tests/linear 129 >input.y || exit 77 -stderr: ---- /dev/null 2026-03-27 17:47:36.000000000 +0000 -+++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/608/stderr 2026-03-27 18:45:14.157669377 +0000 -@@ -0,0 +1 @@ -+/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/608/test-source: line 14: ruby: command not found -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -608. torture.at:272: Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Reading a token -Next token is token "number" (1.6: 1) -Error: discarding token "number" (1.6: 1) -Reading a token -Next token is token ')' (1.7: ) -Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) ---- /dev/null 2026-03-27 17:47:36.000000000 +0000 -+++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/606/stderr 2026-03-27 18:45:14.173669377 +0000 -@@ -0,0 +1 @@ -+/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/606/test-source: line 14: ruby: command not found -stderr: -606. torture.at:270: skipped (torture.at:270) ---- /dev/null 2026-03-27 17:47:36.000000000 +0000 -+++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/607/stderr 2026-03-27 18:45:14.181669377 +0000 +609. torture.at:273: testing State number type: 257 states ... +./torture.at:273: ruby $abs_top_srcdir/tests/linear 257 >input.y || exit 77 +610. torture.at:274: testing State number type: 32768 states ... +./torture.at:274: ruby $abs_top_srcdir/tests/linear 32768 >input.y || exit 77 +stdout: +--- /dev/null 2025-02-20 11:23:24.000000000 +0000 ++++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/609/stderr 2025-02-22 12:29:31.126845256 +0000 @@ -0,0 +1 @@ -+/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/607/test-source: line 14: ruby: command not found - skipped (torture.at:272) - -607. torture.at:271: stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 20 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 18 -Reading a token -Next token is token number (1.13: 7) -Shifting token number (1.13: 7) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.13: 7) --> $$ = nterm exp (1.13: 7) -Entering state 27 -Reading a token -Next token is token '\n' (1.14-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-9: 7) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13: 7) --> $$ = nterm exp (1.1-13: 7) -Entering state 8 -Next token is token '\n' (1.14-2.0: ) -Shifting token '\n' (1.14-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-13: 7) - $2 = token '\n' (1.14-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Next token is token number (2.1: 1) -Shifting token number (2.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2.1: 1) --> $$ = nterm exp (2.1: 1) -Entering state 8 -Reading a token -Next token is token '+' (2.3: ) -Shifting token '+' (2.3: ) -Entering state 20 -Reading a token -Next token is token number (2.5: 2) -Shifting token number (2.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2.5: 2) --> $$ = nterm exp (2.5: 2) -Entering state 29 -Reading a token -Next token is token '*' (2.7: ) -Shifting token '*' (2.7: ) -Entering state 21 -Reading a token -Next token is token '-' (2.9: ) -Shifting token '-' (2.9: ) -Entering state 2 -Reading a token -Next token is token number (2.10: 3) -Shifting token number (2.10: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2.10: 3) --> $$ = nterm exp (2.10: 3) -Entering state 10 -Reading a token -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (2.9: ) - $2 = nterm exp (2.10: 3) --> $$ = nterm exp (2.9-10: -3) -Entering state 30 -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (2.5: 2) - $2 = token '*' (2.7: ) - $3 = nterm exp (2.9-10: -3) --> $$ = nterm exp (2.5-10: -6) -Entering state 29 -Next token is token '=' (2.12: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (2.1: 1) - $2 = token '+' (2.3: ) - $3 = nterm exp (2.5-10: -6) --> $$ = nterm exp (2.1-10: -5) -Entering state 8 -Next token is token '=' (2.12: ) -Shifting token '=' (2.12: ) -Entering state 18 -Reading a token -Next token is token '-' (2.14: ) -Shifting token '-' (2.14: ) -Entering state 2 -Reading a token -Next token is token number (2.15: 5) -Shifting token number (2.15: 5) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (2.15: 5) --> $$ = nterm exp (2.15: 5) -Entering state 10 -Reading a token -Next token is token '\n' (2.16-3.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (2.14: ) - $2 = nterm exp (2.15: 5) --> $$ = nterm exp (2.14-15: -5) -Entering state 27 -Next token is token '\n' (2.16-3.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (2.1-10: -5) - $2 = token '=' (2.12: ) - $3 = nterm exp (2.14-15: -5) --> $$ = nterm exp (2.1-15: -5) -Entering state 8 -Next token is token '\n' (2.16-3.0: ) -Shifting token '\n' (2.16-3.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (2.1-15: -5) - $2 = token '\n' (2.16-3.0: ) --> $$ = nterm line (2.1-3.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-2.0: ) - $2 = nterm line (2.1-3.0: ) --> $$ = nterm input (1.1-3.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (3.1-4.0: ) -Shifting token '\n' (3.1-4.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (3.1-4.0: ) --> $$ = nterm line (3.1-4.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-3.0: ) - $2 = nterm line (3.1-4.0: ) --> $$ = nterm input (1.1-4.0: ) -Entering state 6 -Reading a token -Next token is token '-' (4.1: ) -Shifting token '-' (4.1: ) -Entering state 2 -Reading a token -Next token is token number (4.2: 1) -Shifting token number (4.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (4.2: 1) --> $$ = nterm exp (4.2: 1) -Entering state 10 -Reading a token -Next token is token '^' (4.3: ) -Shifting token '^' (4.3: ) -Entering state 23 -Reading a token -Next token is token number (4.4: 2) -Shifting token number (4.4: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (4.4: 2) --> $$ = nterm exp (4.4: 2) -Entering state 32 -Reading a token -Next token is token '=' (4.6: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (4.2: 1) - $2 = token '^' (4.3: ) - $3 = nterm exp (4.4: 2) --> $$ = nterm exp (4.2-4: 1) -Entering state 10 -Next token is token '=' (4.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (4.1: ) - $2 = nterm exp (4.2-4: 1) --> $$ = nterm exp (4.1-4: -1) -Entering state 8 -Next token is token '=' (4.6: ) -Shifting token '=' (4.6: ) -Entering state 18 -Reading a token -Next token is token '-' (4.8: ) -Shifting token '-' (4.8: ) -Entering state 2 -Reading a token -Next token is token number (4.9: 1) -Shifting token number (4.9: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (4.9: 1) --> $$ = nterm exp (4.9: 1) -Entering state 10 -Reading a token -Next token is token '\n' (4.10-5.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (4.8: ) - $2 = nterm exp (4.9: 1) --> $$ = nterm exp (4.8-9: -1) -Entering state 27 -Next token is token '\n' (4.10-5.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (4.1-4: -1) - $2 = token '=' (4.6: ) - $3 = nterm exp (4.8-9: -1) --> $$ = nterm exp (4.1-9: -1) -Entering state 8 -Next token is token '\n' (4.10-5.0: ) -Shifting token '\n' (4.10-5.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (4.1-9: -1) - $2 = token '\n' (4.10-5.0: ) --> $$ = nterm line (4.1-5.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-4.0: ) - $2 = nterm line (4.1-5.0: ) --> $$ = nterm input (1.1-5.0: ) -Entering state 6 -Reading a token -Next token is token '(' (5.1: ) -Shifting token '(' (5.1: ) -Entering state 4 -Reading a token -Next token is token '-' (5.2: ) -Shifting token '-' (5.2: ) -Entering state 2 -Reading a token -Next token is token number (5.3: 1) -Shifting token number (5.3: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (5.3: 1) --> $$ = nterm exp (5.3: 1) -Entering state 10 -Reading a token -Next token is token ')' (5.4: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (5.2: ) - $2 = nterm exp (5.3: 1) --> $$ = nterm exp (5.2-3: -1) -Entering state 12 -Next token is token ')' (5.4: ) -Shifting token ')' (5.4: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (5.1: ) - $2 = nterm exp (5.2-3: -1) - $3 = token ')' (5.4: ) --> $$ = nterm exp (5.1-4: -1) -Entering state 8 -Reading a token -Next token is token '^' (5.5: ) -Shifting token '^' (5.5: ) -Entering state 23 -Reading a token -Next token is token number (5.6: 2) -Shifting token number (5.6: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (5.6: 2) --> $$ = nterm exp (5.6: 2) -Entering state 32 -Reading a token -Next token is token '=' (5.8: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (5.1-4: -1) - $2 = token '^' (5.5: ) - $3 = nterm exp (5.6: 2) --> $$ = nterm exp (5.1-6: 1) -Entering state 8 -Next token is token '=' (5.8: ) -Shifting token '=' (5.8: ) -Entering state 18 -Reading a token -Next token is token number (5.10: 1) -Shifting token number (5.10: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (5.10: 1) --> $$ = nterm exp (5.10: 1) -Entering state 27 -Reading a token -Next token is token '\n' (5.11-6.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (5.1-6: 1) - $2 = token '=' (5.8: ) - $3 = nterm exp (5.10: 1) --> $$ = nterm exp (5.1-10: 1) -Entering state 8 -Next token is token '\n' (5.11-6.0: ) -Shifting token '\n' (5.11-6.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (5.1-10: 1) - $2 = token '\n' (5.11-6.0: ) --> $$ = nterm line (5.1-6.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-5.0: ) - $2 = nterm line (5.1-6.0: ) --> $$ = nterm input (1.1-6.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (6.1-7.0: ) -Shifting token '\n' (6.1-7.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (6.1-7.0: ) --> $$ = nterm line (6.1-7.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-6.0: ) - $2 = nterm line (6.1-7.0: ) --> $$ = nterm input (1.1-7.0: ) -Entering state 6 -Reading a token -Next token is token '-' (7.1: ) -Shifting token '-' (7.1: ) -Entering state 2 -Reading a token -Next token is token '-' (7.2: ) -Shifting token '-' (7.2: ) -Entering state 2 -Reading a token -Next token is token '-' (7.3: ) -Shifting token '-' (7.3: ) -Entering state 2 -Reading a token -Next token is token number (7.4: 1) -Shifting token number (7.4: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (7.4: 1) --> $$ = nterm exp (7.4: 1) -Entering state 10 -Reading a token -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.3: ) - $2 = nterm exp (7.4: 1) --> $$ = nterm exp (7.3-4: -1) -Entering state 10 -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.2: ) - $2 = nterm exp (7.3-4: -1) --> $$ = nterm exp (7.2-4: 1) -Entering state 10 -Next token is token '=' (7.6: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.1: ) - $2 = nterm exp (7.2-4: 1) --> $$ = nterm exp (7.1-4: -1) -Entering state 8 -Next token is token '=' (7.6: ) -Shifting token '=' (7.6: ) -Entering state 18 -Reading a token -Next token is token '-' (7.8: ) -Shifting token '-' (7.8: ) -Entering state 2 -Reading a token -Next token is token number (7.9: 1) -Shifting token number (7.9: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (7.9: 1) --> $$ = nterm exp (7.9: 1) -Entering state 10 -Reading a token -Next token is token '\n' (7.10-8.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (7.8: ) - $2 = nterm exp (7.9: 1) --> $$ = nterm exp (7.8-9: -1) -Entering state 27 -Next token is token '\n' (7.10-8.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (7.1-4: -1) - $2 = token '=' (7.6: ) - $3 = nterm exp (7.8-9: -1) --> $$ = nterm exp (7.1-9: -1) -Entering state 8 -Next token is token '\n' (7.10-8.0: ) -Shifting token '\n' (7.10-8.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (7.1-9: -1) - $2 = token '\n' (7.10-8.0: ) --> $$ = nterm line (7.1-8.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-7.0: ) - $2 = nterm line (7.1-8.0: ) --> $$ = nterm input (1.1-8.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (8.1-9.0: ) -Shifting token '\n' (8.1-9.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (8.1-9.0: ) --> $$ = nterm line (8.1-9.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-8.0: ) - $2 = nterm line (8.1-9.0: ) --> $$ = nterm input (1.1-9.0: ) -Entering state 6 -Reading a token -Next token is token number (9.1: 1) -Shifting token number (9.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (9.1: 1) --> $$ = nterm exp (9.1: 1) -Entering state 8 -Reading a token -Next token is token '-' (9.3: ) -Shifting token '-' (9.3: ) -Entering state 19 -Reading a token -Next token is token number (9.5: 2) -Shifting token number (9.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (9.5: 2) --> $$ = nterm exp (9.5: 2) -Entering state 28 -Reading a token -Next token is token '-' (9.7: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (9.1: 1) - $2 = token '-' (9.3: ) - $3 = nterm exp (9.5: 2) --> $$ = nterm exp (9.1-5: -1) -Entering state 8 -Next token is token '-' (9.7: ) -Shifting token '-' (9.7: ) -Entering state 19 -Reading a token -Next token is token number (9.9: 3) -Shifting token number (9.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (9.9: 3) --> $$ = nterm exp (9.9: 3) -Entering state 28 -Reading a token -Next token is token '=' (9.11: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (9.1-5: -1) - $2 = token '-' (9.7: ) - $3 = nterm exp (9.9: 3) --> $$ = nterm exp (9.1-9: -4) -Entering state 8 -Next token is token '=' (9.11: ) -Shifting token '=' (9.11: ) -Entering state 18 -Reading a token -Next token is token '-' (9.13: ) -Shifting token '-' (9.13: ) -Entering state 2 -Reading a token -Next token is token number (9.14: 4) -Shifting token number (9.14: 4) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (9.14: 4) --> $$ = nterm exp (9.14: 4) -Entering state 10 -Reading a token -Next token is token '\n' (9.15-10.0: ) -Reducing stack 0 by rule 11 (line 102): - $1 = token '-' (9.13: ) - $2 = nterm exp (9.14: 4) --> $$ = nterm exp (9.13-14: -4) -Entering state 27 -Next token is token '\n' (9.15-10.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (9.1-9: -4) - $2 = token '=' (9.11: ) - $3 = nterm exp (9.13-14: -4) --> $$ = nterm exp (9.1-14: -4) -Entering state 8 -Next token is token '\n' (9.15-10.0: ) -Shifting token '\n' (9.15-10.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (9.1-14: -4) - $2 = token '\n' (9.15-10.0: ) --> $$ = nterm line (9.1-10.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-9.0: ) - $2 = nterm line (9.1-10.0: ) --> $$ = nterm input (1.1-10.0: ) -Entering state 6 -Reading a token -Next token is token number (10.1: 1) -Shifting token number (10.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (10.1: 1) --> $$ = nterm exp (10.1: 1) -Entering state 8 -Reading a token -Next token is token '-' (10.3: ) -Shifting token '-' (10.3: ) -Entering state 19 -Reading a token -Next token is token '(' (10.5: ) -Shifting token '(' (10.5: ) -Entering state 4 -Reading a token -Next token is token number (10.6: 2) -Shifting token number (10.6: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (10.6: 2) --> $$ = nterm exp (10.6: 2) -Entering state 12 -Reading a token -Next token is token '-' (10.8: ) -Shifting token '-' (10.8: ) -Entering state 19 -Reading a token -Next token is token number (10.10: 3) -Shifting token number (10.10: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (10.10: 3) --> $$ = nterm exp (10.10: 3) -Entering state 28 -Reading a token -Next token is token ')' (10.11: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (10.6: 2) - $2 = token '-' (10.8: ) - $3 = nterm exp (10.10: 3) --> $$ = nterm exp (10.6-10: -1) -Entering state 12 -Next token is token ')' (10.11: ) -Shifting token ')' (10.11: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (10.5: ) - $2 = nterm exp (10.6-10: -1) - $3 = token ')' (10.11: ) --> $$ = nterm exp (10.5-11: -1) -Entering state 28 -Reading a token -Next token is token '=' (10.13: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (10.1: 1) - $2 = token '-' (10.3: ) - $3 = nterm exp (10.5-11: -1) --> $$ = nterm exp (10.1-11: 2) -Entering state 8 -Next token is token '=' (10.13: ) -Shifting token '=' (10.13: ) -Entering state 18 -Reading a token -Next token is token number (10.15: 2) -Shifting token number (10.15: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (10.15: 2) --> $$ = nterm exp (10.15: 2) -Entering state 27 -Reading a token -Next token is token '\n' (10.16-11.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (10.1-11: 2) - $2 = token '=' (10.13: ) - $3 = nterm exp (10.15: 2) --> $$ = nterm exp (10.1-15: 2) -Entering state 8 -Next token is token '\n' (10.16-11.0: ) -Shifting token '\n' (10.16-11.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (10.1-15: 2) - $2 = token '\n' (10.16-11.0: ) --> $$ = nterm line (10.1-11.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-10.0: ) - $2 = nterm line (10.1-11.0: ) --> $$ = nterm input (1.1-11.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (11.1-12.0: ) -Shifting token '\n' (11.1-12.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (11.1-12.0: ) --> $$ = nterm line (11.1-12.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-11.0: ) - $2 = nterm line (11.1-12.0: ) --> $$ = nterm input (1.1-12.0: ) -Entering state 6 -Reading a token -Next token is token number (12.1: 2) -Shifting token number (12.1: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (12.1: 2) --> $$ = nterm exp (12.1: 2) -Entering state 8 -Reading a token -Next token is token '^' (12.2: ) -Shifting token '^' (12.2: ) -Entering state 23 -Reading a token -Next token is token number (12.3: 2) -Shifting token number (12.3: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (12.3: 2) --> $$ = nterm exp (12.3: 2) -Entering state 32 -Reading a token -Next token is token '^' (12.4: ) -Shifting token '^' (12.4: ) -Entering state 23 -Reading a token -Next token is token number (12.5: 3) -Shifting token number (12.5: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (12.5: 3) --> $$ = nterm exp (12.5: 3) -Entering state 32 -Reading a token -Next token is token '=' (12.7: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (12.3: 2) - $2 = token '^' (12.4: ) - $3 = nterm exp (12.5: 3) --> $$ = nterm exp (12.3-5: 8) -Entering state 32 -Next token is token '=' (12.7: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (12.1: 2) - $2 = token '^' (12.2: ) - $3 = nterm exp (12.3-5: 8) --> $$ = nterm exp (12.1-5: 256) -Entering state 8 -Next token is token '=' (12.7: ) -Shifting token '=' (12.7: ) -Entering state 18 -Reading a token -Next token is token number (12.9-11: 256) -Shifting token number (12.9-11: 256) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (12.9-11: 256) --> $$ = nterm exp (12.9-11: 256) -Entering state 27 -Reading a token -Next token is token '\n' (12.12-13.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (12.1-5: 256) - $2 = token '=' (12.7: ) - $3 = nterm exp (12.9-11: 256) --> $$ = nterm exp (12.1-11: 256) -Entering state 8 -Next token is token '\n' (12.12-13.0: ) -Shifting token '\n' (12.12-13.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (12.1-11: 256) - $2 = token '\n' (12.12-13.0: ) --> $$ = nterm line (12.1-13.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-12.0: ) - $2 = nterm line (12.1-13.0: ) --> $$ = nterm input (1.1-13.0: ) -Entering state 6 -Reading a token -Next token is token '(' (13.1: ) -Shifting token '(' (13.1: ) -Entering state 4 -Reading a token -Next token is token number (13.2: 2) -Shifting token number (13.2: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (13.2: 2) --> $$ = nterm exp (13.2: 2) -Entering state 12 -Reading a token -Next token is token '^' (13.3: ) -Shifting token '^' (13.3: ) -Entering state 23 -Reading a token -Next token is token number (13.4: 2) -Shifting token number (13.4: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (13.4: 2) --> $$ = nterm exp (13.4: 2) -Entering state 32 -Reading a token -Next token is token ')' (13.5: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (13.2: 2) - $2 = token '^' (13.3: ) - $3 = nterm exp (13.4: 2) --> $$ = nterm exp (13.2-4: 4) -Entering state 12 -Next token is token ')' (13.5: ) -Shifting token ')' (13.5: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (13.1: ) - $2 = nterm exp (13.2-4: 4) - $3 = token ')' (13.5: ) --> $$ = nterm exp (13.1-5: 4) -Entering state 8 -Reading a token -Next token is token '^' (13.6: ) -Shifting token '^' (13.6: ) -Entering state 23 -Reading a token -Next token is token number (13.7: 3) -Shifting token number (13.7: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (13.7: 3) --> $$ = nterm exp (13.7: 3) -Entering state 32 -Reading a token -Next token is token '=' (13.9: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (13.1-5: 4) - $2 = token '^' (13.6: ) - $3 = nterm exp (13.7: 3) --> $$ = nterm exp (13.1-7: 64) -Entering state 8 -Next token is token '=' (13.9: ) -Shifting token '=' (13.9: ) -Entering state 18 -Reading a token -Next token is token number (13.11-12: 64) -Shifting token number (13.11-12: 64) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (13.11-12: 64) --> $$ = nterm exp (13.11-12: 64) -Entering state 27 -Reading a token -Next token is token '\n' (13.13-14.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (13.1-7: 64) - $2 = token '=' (13.9: ) - $3 = nterm exp (13.11-12: 64) --> $$ = nterm exp (13.1-12: 64) -Entering state 8 -Next token is token '\n' (13.13-14.0: ) -Shifting token '\n' (13.13-14.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (13.1-12: 64) - $2 = token '\n' (13.13-14.0: ) --> $$ = nterm line (13.1-14.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-13.0: ) - $2 = nterm line (13.1-14.0: ) --> $$ = nterm input (1.1-14.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input (14.1: ) -Entering state 16 -Cleanup: popping token end of input (14.1: ) -Cleanup: popping nterm input (1.1-14.0: ) - -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Reading a token -Next token is token number (1.7: 1) -Shifting token number (1.7: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 20 -Reading a token -Next token is token number (1.11: 1) -Shifting token number (1.11: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.11: 1) --> $$ = nterm exp (1.11: 1) -Entering state 29 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 20 -Reading a token -Next token is token number (1.15: 1) -Shifting token number (1.15: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 29 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 20 -Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Error: popping nterm exp (1.7-15: 3) -Shifting token error (1.7-18: ) -Entering state 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) -Entering state 29 -Reading a token -Next token is token '+' (1.20: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) -Entering state 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) -Entering state 20 -Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) -Reading a token -Next token is token ')' (1.28: ) -Entering state 11 -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 29 -Reading a token -Next token is token '+' (1.30: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) -Entering state 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) -Entering state 20 -Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) -Entering state 4 -Reading a token -Next token is token number (1.33: 1) -Shifting token number (1.33: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 21 -Reading a token -Next token is token number (1.37: 2) -Shifting token number (1.37: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.39: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) -Entering state 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 21 -Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Error: popping nterm exp (1.33-37: 2) -Shifting token error (1.33-41: ) -Entering state 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Reading a token -Next token is token ')' (1.42: ) -Entering state 11 -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.44: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) -Entering state 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) -Entering state 18 -Reading a token -Next token is token number (1.46: 1) -Shifting token number (1.46: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.46: 1) --> $$ = nterm exp (1.46: 1) -Entering state 27 -Reading a token -Next token is token '\n' (1.47-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) -Entering state 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input (2.1: ) -Entering state 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - skipped (torture.at:271) -./calc.at:1492: "$PERL" -pi -e 'use strict; ++/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/609/test-source: line 14: ruby: command not found +609. torture.at:273: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -230365,257 +223199,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token ')' (1.2: ) -1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Next token is token ')' (1.2: ) -Shifting token ')' (1.2: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.2: ) --> $$ = nterm exp (1.1-2: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Reading a token -Next token is token '(' (1.6: ) -Shifting token '(' (1.6: ) -Entering state 4 -Reading a token -Next token is token "number" (1.7: 1) -Shifting token "number" (1.7: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.7: 1) --> $$ = nterm exp (1.7: 1) -Entering state 12 -Reading a token -Next token is token '+' (1.9: ) -Shifting token '+' (1.9: ) -Entering state 20 -Reading a token -Next token is token "number" (1.11: 1) -Shifting token "number" (1.11: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.11: 1) --> $$ = nterm exp (1.11: 1) -Entering state 29 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.7: 1) - $2 = token '+' (1.9: ) - $3 = nterm exp (1.11: 1) --> $$ = nterm exp (1.7-11: 2) -Entering state 12 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 20 -Reading a token -Next token is token "number" (1.15: 1) -Shifting token "number" (1.15: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.15: 1) --> $$ = nterm exp (1.15: 1) -Entering state 29 -Reading a token -Next token is token '+' (1.17: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.7-11: 2) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15: 1) --> $$ = nterm exp (1.7-15: 3) -Entering state 12 -Next token is token '+' (1.17: ) -Shifting token '+' (1.17: ) -Entering state 20 -Reading a token -Next token is token ')' (1.18: ) -1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' -Error: popping token '+' (1.17: ) -Error: popping nterm exp (1.7-15: 3) -Shifting token error (1.7-18: ) -Entering state 11 -Next token is token ')' (1.18: ) -Shifting token ')' (1.18: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.6: ) - $2 = token error (1.7-18: ) - $3 = token ')' (1.18: ) --> $$ = nterm exp (1.6-18: 1111) -Entering state 29 -Reading a token -Next token is token '+' (1.20: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-2: 1111) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6-18: 1111) --> $$ = nterm exp (1.1-18: 2222) -Entering state 8 -Next token is token '+' (1.20: ) -Shifting token '+' (1.20: ) -Entering state 20 -Reading a token -Next token is token '(' (1.22: ) -Shifting token '(' (1.22: ) -Entering state 4 -Reading a token -Next token is token '*' (1.23: ) -1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.23: ) -Entering state 11 -Next token is token '*' (1.23: ) -Error: discarding token '*' (1.23: ) -Reading a token -Next token is token '*' (1.25: ) -Error: discarding token '*' (1.25: ) -Reading a token -Next token is token '*' (1.27: ) -Error: discarding token '*' (1.27: ) -Reading a token -Next token is token ')' (1.28: ) -Entering state 11 -Next token is token ')' (1.28: ) -Shifting token ')' (1.28: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.22: ) - $2 = token error (1.23-27: ) - $3 = token ')' (1.28: ) --> $$ = nterm exp (1.22-28: 1111) -Entering state 29 -Reading a token -Next token is token '+' (1.30: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-18: 2222) - $2 = token '+' (1.20: ) - $3 = nterm exp (1.22-28: 1111) --> $$ = nterm exp (1.1-28: 3333) -Entering state 8 -Next token is token '+' (1.30: ) -Shifting token '+' (1.30: ) -Entering state 20 -Reading a token -Next token is token '(' (1.32: ) -Shifting token '(' (1.32: ) -Entering state 4 -Reading a token -Next token is token "number" (1.33: 1) -Shifting token "number" (1.33: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.33: 1) --> $$ = nterm exp (1.33: 1) -Entering state 12 -Reading a token -Next token is token '*' (1.35: ) -Shifting token '*' (1.35: ) -Entering state 21 -Reading a token -Next token is token "number" (1.37: 2) -Shifting token "number" (1.37: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.37: 2) --> $$ = nterm exp (1.37: 2) -Entering state 30 -Reading a token -Next token is token '*' (1.39: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.33: 1) - $2 = token '*' (1.35: ) - $3 = nterm exp (1.37: 2) --> $$ = nterm exp (1.33-37: 2) -Entering state 12 -Next token is token '*' (1.39: ) -Shifting token '*' (1.39: ) -Entering state 21 -Reading a token -Next token is token '*' (1.41: ) -1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Error: popping token '*' (1.39: ) -Error: popping nterm exp (1.33-37: 2) -Shifting token error (1.33-41: ) -Entering state 11 -Next token is token '*' (1.41: ) -Error: discarding token '*' (1.41: ) -Reading a token -Next token is token ')' (1.42: ) -Entering state 11 -Next token is token ')' (1.42: ) -Shifting token ')' (1.42: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.32: ) - $2 = token error (1.33-41: ) - $3 = token ')' (1.42: ) --> $$ = nterm exp (1.32-42: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.44: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-28: 3333) - $2 = token '+' (1.30: ) - $3 = nterm exp (1.32-42: 1111) --> $$ = nterm exp (1.1-42: 4444) -Entering state 8 -Next token is token '=' (1.44: ) -Shifting token '=' (1.44: ) -Entering state 18 -Reading a token -Next token is token "number" (1.46: 1) -Shifting token "number" (1.46: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.46: 1) --> $$ = nterm exp (1.46: 1) -Entering state 27 -Reading a token -Next token is token '\n' (1.47-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-42: 4444) - $2 = token '=' (1.44: ) - $3 = nterm exp (1.46: 1) -1.1-46: error: 4444 != 1 --> $$ = nterm exp (1.1-46: 4444) -Entering state 8 -Next token is token '\n' (1.47-2.0: ) -Shifting token '\n' (1.47-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-46: 4444) - $2 = token '\n' (1.47-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -input: -stdout: - | 1 2 -./calc.at:1492: $PREPARSER ./calc input %code top { /* -*- c -*- */ /* Adjust to the compiler. We used to do it here, but each time we add a new line, @@ -232103,8 +224686,7 @@ "161" "162" "163" "164" "165" "166" END { $$ = 166; } | "1" "2" "3" "4" "5" "6" "7" "8" "9" "10" "11" "12" "13" "14" "15" "16" - "17" "18" "19" "20" "21" "22" "23" "24"stderr: - "25" "26" "27" "28" "29" "30" + "17" "18" "19" "20" "21" "22" "23" "24" "25" "26" "27" "28" "29" "30" "31" "32" "33" "34" "35" "36" "37" "38" "39" "40" "41" "42" "43" "44" "45" "46" "47" "48" "49" "50" "51" "52" "53" "54" "55" "56" "57" "58" "59" "60" "61" "62" "63" "64" "65" "66" "67" "68" "69" "70" "71" "72" @@ -232666,37 +225248,15 @@ (void) argv; return yyparse (); } -./calc.at:1492: cat stderr -609. torture.at:273: testing State number type: 257 states ... -./torture.at:273: ruby $abs_top_srcdir/tests/linear 257 >input.y || exit 77 + skipped (torture.at:273) +--- /dev/null 2025-02-20 11:23:24.000000000 +0000 ++++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/610/stderr 2025-02-22 12:29:31.146845383 +0000 +@@ -0,0 +1 @@ ++/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/610/test-source: line 14: ruby: command not found +610. torture.at:274: 611. torture.at:275: testing State number type: 65536 states ... +./torture.at:275: ruby $abs_top_srcdir/tests/linear 65536 >input.y || exit 77 ./torture.at:139: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y - -./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -Starting parse -Entering state 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token number (1.3: 2) -./calc.at:1494: "$PERL" -pi -e 'use strict; +./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -232706,24 +225266,25 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1492: cat stderr + skipped (torture.at:274) input: -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -610. torture.at:274: testing State number type: 32768 states ... -./torture.at:274: ruby $abs_top_srcdir/tests/linear 32768 >input.y || exit 77 ---- /dev/null 2026-03-27 17:47:36.000000000 +0000 -+++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/610/stderr 2026-03-27 18:45:14.273669377 +0000 +--- /dev/null 2025-02-20 11:23:24.000000000 +0000 ++++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/611/stderr 2025-02-22 12:29:31.190845662 +0000 @@ -0,0 +1 @@ -+/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/610/test-source: line 14: ruby: command not found - | (1 + # + 1) = 1111 ++/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/611/test-source: line 14: ruby: command not found +./calc.at:1489: cat stderr +611. torture.at:275: | (1 + #) = 1111 ./calc.at:1492: $PREPARSER ./calc input -./calc.at:1491: cat stderr ---- /dev/null 2026-03-27 17:47:36.000000000 +0000 -+++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/609/stderr 2026-03-27 18:45:14.265669377 +0000 -@@ -0,0 +1 @@ -+/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/609/test-source: line 14: ruby: command not found -610. torture.at:274: stderr: -./calc.at:1494: cat stderr +stderr: +input: + skipped (torture.at:275) + | (1 + # + 1) = 1111 +./calc.at:1489: $PREPARSER ./calc input +612. torture.at:276: testing State number type: 65537 states ... +./torture.at:276: ruby $abs_top_srcdir/tests/linear 65537 >input.y || exit 77 + Starting parse Entering state 0 Reading a token @@ -232752,49 +225313,43 @@ Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Reading a token -Next token is token "number" (1.10: 1) -Error: discarding token "number" (1.10: 1) -Reading a token -Next token is token ')' (1.11: ) +Next token is token ')' (1.7: ) Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 18 Reading a token -Next token is token "number" (1.15-18: 1111) -Shifting token "number" (1.15-18: 1111) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token -Next token is token '\n' (1.19-2.0: ) +Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -232807,126 +225362,94 @@ Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -609. torture.at:273: 611. torture.at:275: testing State number type: 65536 states ... -./torture.at:275: ruby $abs_top_srcdir/tests/linear 65536 >input.y || exit 77 ---- /dev/null 2026-03-27 17:47:36.000000000 +0000 -+++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/611/stderr 2026-03-27 18:45:14.277669377 +0000 -@@ -0,0 +1 @@ -+/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/611/test-source: line 14: ruby: command not found - skipped (torture.at:274) -611. torture.at:275: stderr: -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - skipped (torture.at:273) - skipped (torture.at:275) -Starting parse -Entering state 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token number (1.3: 2) -input: - | (!!) + (1 2) = 1 -input: -./calc.at:1491: $PREPARSER ./calc input - | (!!) + (1 2) = 1 -./calc.at:1494: $PREPARSER ./calc input -stderr: stderr: +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -613. torture.at:385: testing Many lookahead tokens ... -./torture.at:387: "$PERL" -w ./gengram.pl 1000 || exit 77 Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) +Next token is token '(' () +Shifting token '(' () Entering state 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 12 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' () +Shifting token '+' () Entering state 20 Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) +Shifting token error () Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) +Next token is token error () +Error: discarding token error () Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) +Next token is token '+' () +Error: discarding token '+' () Reading a token -Next token is token "number" (1.10: 1) -Error: discarding token "number" (1.10: 1) +Next token is token number (1) +Error: discarding token number (1) Reading a token -Next token is token ')' (1.11: ) +Next token is token ')' () Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' () +Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 8 Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) +Next token is token '=' () +Shifting token '=' () Entering state 18 Reading a token -Next token is token "number" (1.15-18: 1111) -Shifting token "number" (1.15-18: 1111) +Next token is token number (1111) +Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) + $1 = token number (1111) +-> $$ = nterm exp (1111) Entering state 27 Reading a token -Next token is token '\n' (1.19-2.0: ) +Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) Entering state 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) +Next token is token '\n' () +Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) --> $$ = nterm line (1.1-2.0: ) + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) + $1 = nterm line () +-> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) +Shifting token end of input () Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +Cleanup: popping token end of input () +Cleanup: popping nterm input () +613. torture.at:385: testing Many lookahead tokens ... +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -232934,98 +225457,64 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 15 -Reducing stack 0 by rule 16 (line 107): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Shifting token error (1.2-3: ) -Entering state 11 -Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) -Entering state 20 -Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) -Entering state 4 -Reading a token -Next token is token "number" (1.9: 1) -Shifting token "number" (1.9: 1) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.9: 1) --> $$ = nterm exp (1.9: 1) + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token -Next token is token "number" (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Shifting token error (1.9-11: ) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) Entering state 11 -Next token is token "number" (1.11: 2) -Error: discarding token "number" (1.11: 2) +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) Reading a token -Next token is token ')' (1.12: ) +Next token is token ')' (1.7: ) Entering state 11 -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.14: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 18 Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token -Next token is token '\n' (1.17-2.0: ) +Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -233038,127 +225527,98 @@ Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) + +--- /dev/null 2025-02-20 11:23:24.000000000 +0000 ++++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/612/stderr 2025-02-22 12:29:31.234845941 +0000 +@@ -0,0 +1 @@ ++/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/612/test-source: line 14: ruby: command not found +612. torture.at:276: ./torture.at:387: "$PERL" -w ./gengram.pl 1000 || exit 77 +stderr: + skipped (torture.at:276) Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 15 -Reducing stack 0 by rule 16 (line 107): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Shifting token error (1.2-3: ) -Entering state 11 -Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) -Entering state 20 -Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) +Next token is token '(' () +Shifting token '(' () Entering state 4 Reading a token -Next token is token number (1.9: 1) -Shifting token number (1.9: 1) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.9: 1) --> $$ = nterm exp (1.9: 1) + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 12 Reading a token -Next token is token number (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Shifting token error (1.9-11: ) +Next token is token '+' () +Shifting token '+' () +Entering state 20 +Reading a token +syntax error: invalid character: '#' +Next token is token error () +Error: popping token '+' () +Error: popping nterm exp (1) +Shifting token error () Entering state 11 -Next token is token number (1.11: 2) -Error: discarding token number (1.11: 2) +Next token is token error () +Error: discarding token error () Reading a token -Next token is token ')' (1.12: ) +Next token is token '+' () +Error: discarding token '+' () +Reading a token +Next token is token number (1) +Error: discarding token number (1) +Reading a token +Next token is token ')' () Entering state 11 -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) +Next token is token ')' () +Shifting token ')' () Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.14: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) + $1 = token '(' () + $2 = token error () + $3 = token ')' () +-> $$ = nterm exp (1111) Entering state 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) +Reading a token +Next token is token '=' () +Shifting token '=' () Entering state 18 Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) +Next token is token number (1111) +Shifting token number (1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) + $1 = token number (1111) +-> $$ = nterm exp (1111) Entering state 27 Reading a token -Next token is token '\n' (1.17-2.0: ) +Next token is token '\n' () Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) + $1 = nterm exp (1111) + $2 = token '=' () + $3 = nterm exp (1111) +-> $$ = nterm exp (1111) Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' () +Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) + $1 = nterm exp (1111) + $2 = token '\n' () +-> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) + $1 = nterm line () +-> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token end of input (2.1: ) +Shifting token end of input () Entering state 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - - -612. torture.at:276: testing State number type: 65537 states ... -./torture.at:276: ruby $abs_top_srcdir/tests/linear 65537 >input.y || exit 77 ---- /dev/null 2026-03-27 17:47:36.000000000 +0000 -+++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/612/stderr 2026-03-27 18:45:14.329669377 +0000 -@@ -0,0 +1 @@ -+/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/612/test-source: line 14: ruby: command not found -./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -612. torture.at:276: skipped (torture.at:276) +Cleanup: popping token end of input () +Cleanup: popping nterm input () +stdout: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -233170,121 +225630,6 @@ }eg ' expout || exit 77 -stderr: -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 15 -Reducing stack 0 by rule 16 (line 107): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Shifting token error (1.2-3: ) -Entering state 11 -Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) -Entering state 20 -Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) -Entering state 4 -Reading a token -Next token is token "number" (1.9: 1) -Shifting token "number" (1.9: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.9: 1) --> $$ = nterm exp (1.9: 1) -Entering state 12 -Reading a token -Next token is token "number" (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Shifting token error (1.9-11: ) -Entering state 11 -Next token is token "number" (1.11: 2) -Error: discarding token "number" (1.11: 2) -Reading a token -Next token is token ')' (1.12: ) -Entering state 11 -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.14: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) -Entering state 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) -Entering state 18 -Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 27 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1492: cat stderr %define parse.error verbose %debug %{ @@ -235296,17 +227641,7 @@ | n894 "894" { assert ($1 == 894); $$ = $1; } | n895 "895" { assert ($1 == 895); $$ = $1; } | n896 "896" { assert ($1 == 896); $$ = $1; } -| n897 "897" { assert ($1 =./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -= 897); $$ = $1; } +| n897 "897" { assert ($1 == 897); $$ = $1; } | n898 "898" { assert ($1 == 898); $$ = $1; } | n899 "899" { assert ($1 == 899); $$ = $1; } | n900 "900" { assert ($1 == 900); $$ = $1; } @@ -236450,106 +228785,212 @@ (void) argv; return yyparse (); } +./calc.at:1492: cat stderr +./torture.at:393: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y +614. torture.at:485: testing Exploding the Stack Size with Alloca ... +stderr: +stdout: +./torture.at:494: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./calc.at:1491: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc calc.hh + +input: +./calc.at:1489: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (# + 1) = 1111 +./calc.at:1492: $PREPARSER ./calc input +input: + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +stderr: +./calc.at:1491: $PREPARSER ./calc input +stdout: +stderr: +616. existing.at:74: testing GNU AWK 3.1.0 Grammar: LALR(1) ... +./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y +./calc.at:1489: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) +Reading a token +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Reading a token +Next token is token "number" (1.6: 1) +Error: discarding token "number" (1.6: 1) +Reading a token +Next token is token ')' (1.7: ) +Entering state 11 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 18 +Reading a token +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 27 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 16 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1494: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc calc.hh + stderr: Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '!' (1.2: ) -Shifting token '!' (1.2: ) -Entering state 5 -Reading a token -Next token is token '!' (1.3: ) -Shifting token '!' (1.3: ) -Entering state 15 -Reducing stack 0 by rule 16 (line 107): - $1 = token '!' (1.2: ) - $2 = token '!' (1.3: ) -Shifting token error (1.2-3: ) -Entering state 11 -Reading a token -Next token is token ')' (1.4: ) -Shifting token ')' (1.4: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-3: ) - $3 = token ')' (1.4: ) --> $$ = nterm exp (1.1-4: 1111) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '+' (1.6: ) -Shifting token '+' (1.6: ) +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) Entering state 20 Reading a token -Next token is token '(' (1.8: ) -Shifting token '(' (1.8: ) -Entering state 4 -Reading a token -Next token is token number (1.9: 1) -Shifting token number (1.9: 1) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.9: 1) --> $$ = nterm exp (1.9: 1) -Entering state 12 + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 Reading a token -Next token is token number (1.11: 2) -1.11: syntax error, unexpected number -Error: popping nterm exp (1.9: 1) -Shifting token error (1.9-11: ) -Entering state 11 -Next token is token number (1.11: 2) -Error: discarding token number (1.11: 2) +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 Reading a token -Next token is token ')' (1.12: ) -Entering state 11 -Next token is token ')' (1.12: ) -Shifting token ')' (1.12: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.8: ) - $2 = token error (1.9-11: ) - $3 = token ')' (1.12: ) --> $$ = nterm exp (1.8-12: 1111) -Entering state 29 +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 Reading a token -Next token is token '=' (1.14: ) +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-4: 1111) - $2 = token '+' (1.6: ) - $3 = nterm exp (1.8-12: 1111) --> $$ = nterm exp (1.1-12: 2222) + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '=' (1.14: ) -Shifting token '=' (1.14: ) +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) Entering state 18 Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) +Next token is token number (1.13: 7) +Shifting token number (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) + $1 = token number (1.13: 7) +-> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token -Next token is token '\n' (1.17-2.0: ) +Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-12: 2222) - $2 = token '=' (1.14: ) - $3 = nterm exp (1.16: 1) -1.1-16: error: 2222 != 1 --> $$ = nterm exp (1.1-16: 2222) + $1 = nterm exp (1.1-9: 7) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13: 7) +-> $$ = nterm exp (1.1-13: 7) Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) +Next token is token '\n' (1.14-2.0: ) +Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) + $1 = nterm exp (1.1-13: 7) + $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -236557,195 +228998,972 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token +Next token is token number (2.1: 1) +Shifting token number (2.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2.1: 1) +-> $$ = nterm exp (2.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (2.3: ) +Shifting token '+' (2.3: ) +Entering state 20 +Reading a token +Next token is token number (2.5: 2) +Shifting token number (2.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2.5: 2) +-> $$ = nterm exp (2.5: 2) +Entering state 29 +Reading a token +Next token is token '*' (2.7: ) +Shifting token '*' (2.7: ) +Entering state 21 +Reading a token +Next token is token '-' (2.9: ) +Shifting token '-' (2.9: ) +Entering state 2 +Reading a token +Next token is token number (2.10: 3) +Shifting token number (2.10: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2.10: 3) +-> $$ = nterm exp (2.10: 3) +Entering state 10 +Reading a token +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (2.9: ) + $2 = nterm exp (2.10: 3) +-> $$ = nterm exp (2.9-10: -3) +Entering state 30 +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (2.5: 2) + $2 = token '*' (2.7: ) + $3 = nterm exp (2.9-10: -3) +-> $$ = nterm exp (2.5-10: -6) +Entering state 29 +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (2.1: 1) + $2 = token '+' (2.3: ) + $3 = nterm exp (2.5-10: -6) +-> $$ = nterm exp (2.1-10: -5) +Entering state 8 +Next token is token '=' (2.12: ) +Shifting token '=' (2.12: ) +Entering state 18 +Reading a token +Next token is token '-' (2.14: ) +Shifting token '-' (2.14: ) +Entering state 2 +Reading a token +Next token is token number (2.15: 5) +Shifting token number (2.15: 5) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2.15: 5) +-> $$ = nterm exp (2.15: 5) +Entering state 10 +Reading a token +Next token is token '\n' (2.16-3.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (2.14: ) + $2 = nterm exp (2.15: 5) +-> $$ = nterm exp (2.14-15: -5) +Entering state 27 +Next token is token '\n' (2.16-3.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2.1-10: -5) + $2 = token '=' (2.12: ) + $3 = nterm exp (2.14-15: -5) +-> $$ = nterm exp (2.1-15: -5) +Entering state 8 +Next token is token '\n' (2.16-3.0: ) +Shifting token '\n' (2.16-3.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2.1-15: -5) + $2 = token '\n' (2.16-3.0: ) +-> $$ = nterm line (2.1-3.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-2.0: ) + $2 = nterm line (2.1-3.0: ) +-> $$ = nterm input (1.1-3.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (3.1-4.0: ) +Shifting token '\n' (3.1-4.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (3.1-4.0: ) +-> $$ = nterm line (3.1-4.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-3.0: ) + $2 = nterm line (3.1-4.0: ) +-> $$ = nterm input (1.1-4.0: ) +Entering state 6 +Reading a token +Next token is token '-' (4.1: ) +Shifting token '-' (4.1: ) +Entering state 2 +Reading a token +Next token is token number (4.2: 1) +Shifting token number (4.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (4.2: 1) +-> $$ = nterm exp (4.2: 1) +Entering state 10 +Reading a token +Next token is token '^' (4.3: ) +Shifting token '^' (4.3: ) +Entering state 23 +Reading a token +Next token is token number (4.4: 2) +Shifting token number (4.4: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (4.4: 2) +-> $$ = nterm exp (4.4: 2) +Entering state 32 +Reading a token +Next token is token '=' (4.6: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (4.2: 1) + $2 = token '^' (4.3: ) + $3 = nterm exp (4.4: 2) +-> $$ = nterm exp (4.2-4: 1) +Entering state 10 +Next token is token '=' (4.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (4.1: ) + $2 = nterm exp (4.2-4: 1) +-> $$ = nterm exp (4.1-4: -1) +Entering state 8 +Next token is token '=' (4.6: ) +Shifting token '=' (4.6: ) +Entering state 18 +Reading a token +Next token is token '-' (4.8: ) +Shifting token '-' (4.8: ) +Entering state 2 +Reading a token +Next token is token number (4.9: 1) +Shifting token number (4.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (4.9: 1) +-> $$ = nterm exp (4.9: 1) +Entering state 10 +Reading a token +Next token is token '\n' (4.10-5.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (4.8: ) + $2 = nterm exp (4.9: 1) +-> $$ = nterm exp (4.8-9: -1) +Entering state 27 +Next token is token '\n' (4.10-5.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (4.1-4: -1) + $2 = token '=' (4.6: ) + $3 = nterm exp (4.8-9: -1) +-> $$ = nterm exp (4.1-9: -1) +Entering state 8 +Next token is token '\n' (4.10-5.0: ) +Shifting token '\n' (4.10-5.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (4.1-9: -1) + $2 = token '\n' (4.10-5.0: ) +-> $$ = nterm line (4.1-5.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-4.0: ) + $2 = nterm line (4.1-5.0: ) +-> $$ = nterm input (1.1-5.0: ) +Entering state 6 +Reading a token +Next token is token '(' (5.1: ) +Shifting token '(' (5.1: ) +Entering state 4 +Reading a token +Next token is token '-' (5.2: ) +Shifting token '-' (5.2: ) +Entering state 2 +Reading a token +Next token is token number (5.3: 1) +Shifting token number (5.3: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (5.3: 1) +-> $$ = nterm exp (5.3: 1) +Entering state 10 +Reading a token +Next token is token ')' (5.4: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (5.2: ) + $2 = nterm exp (5.3: 1) +-> $$ = nterm exp (5.2-3: -1) +Entering state 12 +Next token is token ')' (5.4: ) +Shifting token ')' (5.4: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (5.1: ) + $2 = nterm exp (5.2-3: -1) + $3 = token ')' (5.4: ) +-> $$ = nterm exp (5.1-4: -1) +Entering state 8 +Reading a token +Next token is token '^' (5.5: ) +Shifting token '^' (5.5: ) +Entering state 23 +Reading a token +Next token is token number (5.6: 2) +Shifting token number (5.6: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (5.6: 2) +-> $$ = nterm exp (5.6: 2) +Entering state 32 +Reading a token +Next token is token '=' (5.8: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (5.1-4: -1) + $2 = token '^' (5.5: ) + $3 = nterm exp (5.6: 2) +-> $$ = nterm exp (5.1-6: 1) +Entering state 8 +Next token is token '=' (5.8: ) +Shifting token '=' (5.8: ) +Entering state 18 +Reading a token +Next token is token number (5.10: 1) +Shifting token number (5.10: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (5.10: 1) +-> $$ = nterm exp (5.10: 1) +Entering state 27 +Reading a token +Next token is token '\n' (5.11-6.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (5.1-6: 1) + $2 = token '=' (5.8: ) + $3 = nterm exp (5.10: 1) +-> $$ = nterm exp (5.1-10: 1) +Entering state 8 +Next token is token '\n' (5.11-6.0: ) +Shifting token '\n' (5.11-6.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (5.1-10: 1) + $2 = token '\n' (5.11-6.0: ) +-> $$ = nterm line (5.1-6.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-5.0: ) + $2 = nterm line (5.1-6.0: ) +-> $$ = nterm input (1.1-6.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (6.1-7.0: ) +Shifting token '\n' (6.1-7.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (6.1-7.0: ) +-> $$ = nterm line (6.1-7.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-6.0: ) + $2 = nterm line (6.1-7.0: ) +-> $$ = nterm input (1.1-7.0: ) +Entering state 6 +Reading a token +Next token is token '-' (7.1: ) +Shifting token '-' (7.1: ) +Entering state 2 +Reading a token +Next token is token '-' (7.2: ) +Shifting token '-' (7.2: ) +Entering state 2 +Reading a token +Next token is token '-' (7.3: ) +Shifting token '-' (7.3: ) +Entering state 2 +Reading a token +Next token is token number (7.4: 1) +Shifting token number (7.4: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (7.4: 1) +-> $$ = nterm exp (7.4: 1) +Entering state 10 +Reading a token +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.3: ) + $2 = nterm exp (7.4: 1) +-> $$ = nterm exp (7.3-4: -1) +Entering state 10 +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.2: ) + $2 = nterm exp (7.3-4: -1) +-> $$ = nterm exp (7.2-4: 1) +Entering state 10 +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.1: ) + $2 = nterm exp (7.2-4: 1) +-> $$ = nterm exp (7.1-4: -1) +Entering state 8 +Next token is token '=' (7.6: ) +Shifting token '=' (7.6: ) +Entering state 18 +Reading a token +Next token is token '-' (7.8: ) +Shifting token '-' (7.8: ) +Entering state 2 +Reading a token +Next token is token number (7.9: 1) +Shifting token number (7.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (7.9: 1) +-> $$ = nterm exp (7.9: 1) +Entering state 10 +Reading a token +Next token is token '\n' (7.10-8.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.8: ) + $2 = nterm exp (7.9: 1) +-> $$ = nterm exp (7.8-9: -1) +Entering state 27 +Next token is token '\n' (7.10-8.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (7.1-4: -1) + $2 = token '=' (7.6: ) + $3 = nterm exp (7.8-9: -1) +-> $$ = nterm exp (7.1-9: -1) +Entering state 8 +Next token is token '\n' (7.10-8.0: ) +Shifting token '\n' (7.10-8.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (7.1-9: -1) + $2 = token '\n' (7.10-8.0: ) +-> $$ = nterm line (7.1-8.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-7.0: ) + $2 = nterm line (7.1-8.0: ) +-> $$ = nterm input (1.1-8.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (8.1-9.0: ) +Shifting token '\n' (8.1-9.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (8.1-9.0: ) +-> $$ = nterm line (8.1-9.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-8.0: ) + $2 = nterm line (8.1-9.0: ) +-> $$ = nterm input (1.1-9.0: ) +Entering state 6 +Reading a token +Next token is token number (9.1: 1) +Shifting token number (9.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (9.1: 1) +-> $$ = nterm exp (9.1: 1) +Entering state 8 +Reading a token +Next token is token '-' (9.3: ) +Shifting token '-' (9.3: ) +Entering state 19 +Reading a token +Next token is token number (9.5: 2) +Shifting token number (9.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (9.5: 2) +-> $$ = nterm exp (9.5: 2) +Entering state 28 +Reading a token +Next token is token '-' (9.7: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (9.1: 1) + $2 = token '-' (9.3: ) + $3 = nterm exp (9.5: 2) +-> $$ = nterm exp (9.1-5: -1) +Entering state 8 +Next token is token '-' (9.7: ) +Shifting token '-' (9.7: ) +Entering state 19 +Reading a token +Next token is token number (9.9: 3) +Shifting token number (9.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (9.9: 3) +-> $$ = nterm exp (9.9: 3) +Entering state 28 +Reading a token +Next token is token '=' (9.11: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (9.1-5: -1) + $2 = token '-' (9.7: ) + $3 = nterm exp (9.9: 3) +-> $$ = nterm exp (9.1-9: -4) +Entering state 8 +Next token is token '=' (9.11: ) +Shifting token '=' (9.11: ) +Entering state 18 +Reading a token +Next token is token '-' (9.13: ) +Shifting token '-' (9.13: ) +Entering state 2 +Reading a token +Next token is token number (9.14: 4) +Shifting token number (9.14: 4) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (9.14: 4) +-> $$ = nterm exp (9.14: 4) +Entering state 10 +Reading a token +Next token is token '\n' (9.15-10.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (9.13: ) + $2 = nterm exp (9.14: 4) +-> $$ = nterm exp (9.13-14: -4) +Entering state 27 +Next token is token '\n' (9.15-10.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (9.1-9: -4) + $2 = token '=' (9.11: ) + $3 = nterm exp (9.13-14: -4) +-> $$ = nterm exp (9.1-14: -4) +Entering state 8 +Next token is token '\n' (9.15-10.0: ) +Shifting token '\n' (9.15-10.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (9.1-14: -4) + $2 = token '\n' (9.15-10.0: ) +-> $$ = nterm line (9.1-10.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-9.0: ) + $2 = nterm line (9.1-10.0: ) +-> $$ = nterm input (1.1-10.0: ) +Entering state 6 +Reading a token +Next token is token number (10.1: 1) +Shifting token number (10.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (10.1: 1) +-> $$ = nterm exp (10.1: 1) +Entering state 8 +Reading a token +Next token is token '-' (10.3: ) +Shifting token '-' (10.3: ) +Entering state 19 +Reading a token +Next token is token '(' (10.5: ) +Shifting token '(' (10.5: ) +Entering state 4 +Reading a token +Next token is token number (10.6: 2) +Shifting token number (10.6: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (10.6: 2) +-> $$ = nterm exp (10.6: 2) +Entering state 12 +Reading a token +Next token is token '-' (10.8: ) +Shifting token '-' (10.8: ) +Entering state 19 +Reading a token +Next token is token number (10.10: 3) +Shifting token number (10.10: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (10.10: 3) +-> $$ = nterm exp (10.10: 3) +Entering state 28 +Reading a token +Next token is token ')' (10.11: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (10.6: 2) + $2 = token '-' (10.8: ) + $3 = nterm exp (10.10: 3) +-> $$ = nterm exp (10.6-10: -1) +Entering state 12 +Next token is token ')' (10.11: ) +Shifting token ')' (10.11: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (10.5: ) + $2 = nterm exp (10.6-10: -1) + $3 = token ')' (10.11: ) +-> $$ = nterm exp (10.5-11: -1) +Entering state 28 +Reading a token +Next token is token '=' (10.13: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (10.1: 1) + $2 = token '-' (10.3: ) + $3 = nterm exp (10.5-11: -1) +-> $$ = nterm exp (10.1-11: 2) +Entering state 8 +Next token is token '=' (10.13: ) +Shifting token '=' (10.13: ) +Entering state 18 +Reading a token +Next token is token number (10.15: 2) +Shifting token number (10.15: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (10.15: 2) +-> $$ = nterm exp (10.15: 2) +Entering state 27 +Reading a token +Next token is token '\n' (10.16-11.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (10.1-11: 2) + $2 = token '=' (10.13: ) + $3 = nterm exp (10.15: 2) +-> $$ = nterm exp (10.1-15: 2) +Entering state 8 +Next token is token '\n' (10.16-11.0: ) +Shifting token '\n' (10.16-11.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (10.1-15: 2) + $2 = token '\n' (10.16-11.0: ) +-> $$ = nterm line (10.1-11.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-10.0: ) + $2 = nterm line (10.1-11.0: ) +-> $$ = nterm input (1.1-11.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (11.1-12.0: ) +Shifting token '\n' (11.1-12.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (11.1-12.0: ) +-> $$ = nterm line (11.1-12.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-11.0: ) + $2 = nterm line (11.1-12.0: ) +-> $$ = nterm input (1.1-12.0: ) +Entering state 6 +Reading a token +Next token is token number (12.1: 2) +Shifting token number (12.1: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (12.1: 2) +-> $$ = nterm exp (12.1: 2) +Entering state 8 +Reading a token +Next token is token '^' (12.2: ) +Shifting token '^' (12.2: ) +Entering state 23 +Reading a token +Next token is token number (12.3: 2) +Shifting token number (12.3: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (12.3: 2) +-> $$ = nterm exp (12.3: 2) +Entering state 32 +Reading a token +Next token is token '^' (12.4: ) +Shifting token '^' (12.4: ) +Entering state 23 +Reading a token +Next token is token number (12.5: 3) +Shifting token number (12.5: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (12.5: 3) +-> $$ = nterm exp (12.5: 3) +Entering state 32 +Reading a token +Next token is token '=' (12.7: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (12.3: 2) + $2 = token '^' (12.4: ) + $3 = nterm exp (12.5: 3) +-> $$ = nterm exp (12.3-5: 8) +Entering state 32 +Next token is token '=' (12.7: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (12.1: 2) + $2 = token '^' (12.2: ) + $3 = nterm exp (12.3-5: 8) +-> $$ = nterm exp (12.1-5: 256) +Entering state 8 +Next token is token '=' (12.7: ) +Shifting token '=' (12.7: ) +Entering state 18 +Reading a token +Next token is token number (12.9-11: 256) +Shifting token number (12.9-11: 256) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (12.9-11: 256) +-> $$ = nterm exp (12.9-11: 256) +Entering state 27 +Reading a token +Next token is token '\n' (12.12-13.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (12.1-5: 256) + $2 = token '=' (12.7: ) + $3 = nterm exp (12.9-11: 256) +-> $$ = nterm exp (12.1-11: 256) +Entering state 8 +Next token is token '\n' (12.12-13.0: ) +Shifting token '\n' (12.12-13.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (12.1-11: 256) + $2 = token '\n' (12.12-13.0: ) +-> $$ = nterm line (12.1-13.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-12.0: ) + $2 = nterm line (12.1-13.0: ) +-> $$ = nterm input (1.1-13.0: ) +Entering state 6 +Reading a token +Next token is token '(' (13.1: ) +Shifting token '(' (13.1: ) +Entering state 4 +Reading a token +Next token is token number (13.2: 2) +Shifting token number (13.2: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (13.2: 2) +-> $$ = nterm exp (13.2: 2) +Entering state 12 +Reading a token +Next token is token '^' (13.3: ) +Shifting token '^' (13.3: ) +Entering state 23 +Reading a token +Next token is token number (13.4: 2) +Shifting token number (13.4: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (13.4: 2) +-> $$ = nterm exp (13.4: 2) +Entering state 32 +Reading a token +Next token is token ')' (13.5: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (13.2: 2) + $2 = token '^' (13.3: ) + $3 = nterm exp (13.4: 2) +-> $$ = nterm exp (13.2-4: 4) +Entering state 12 +Next token is token ')' (13.5: ) +Shifting token ')' (13.5: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (13.1: ) + $2 = nterm exp (13.2-4: 4) + $3 = token ')' (13.5: ) +-> $$ = nterm exp (13.1-5: 4) +Entering state 8 +Reading a token +Next token is token '^' (13.6: ) +Shifting token '^' (13.6: ) +Entering state 23 +Reading a token +Next token is token number (13.7: 3) +Shifting token number (13.7: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (13.7: 3) +-> $$ = nterm exp (13.7: 3) +Entering state 32 +Reading a token +Next token is token '=' (13.9: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (13.1-5: 4) + $2 = token '^' (13.6: ) + $3 = nterm exp (13.7: 3) +-> $$ = nterm exp (13.1-7: 64) +Entering state 8 +Next token is token '=' (13.9: ) +Shifting token '=' (13.9: ) +Entering state 18 +Reading a token +Next token is token number (13.11-12: 64) +Shifting token number (13.11-12: 64) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (13.11-12: 64) +-> $$ = nterm exp (13.11-12: 64) +Entering state 27 +Reading a token +Next token is token '\n' (13.13-14.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (13.1-7: 64) + $2 = token '=' (13.9: ) + $3 = nterm exp (13.11-12: 64) +-> $$ = nterm exp (13.1-12: 64) +Entering state 8 +Next token is token '\n' (13.13-14.0: ) +Shifting token '\n' (13.13-14.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (13.1-12: 64) + $2 = token '\n' (13.13-14.0: ) +-> $$ = nterm line (13.1-14.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-13.0: ) + $2 = nterm line (13.1-14.0: ) +-> $$ = nterm input (1.1-14.0: ) +Entering state 6 +Reading a token Now at end of input. -Shifting token end of input (2.1: ) +Shifting token end of input (14.1: ) Entering state 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -614. torture.at:485: testing Exploding the Stack Size with Alloca ... -./calc.at:1494: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - -./torture.at:494: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./calc.at:1492: cat stderr +Cleanup: popping token end of input (14.1: ) +Cleanup: popping nterm input (1.1-14.0: ) +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./torture.at:494: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS 615. torture.at:531: testing Exploding the Stack Size with Malloc ... -./torture.at:535: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 - | 1//2 -./calc.at:1492: $PREPARSER ./calc input -./torture.at:494: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./torture.at:393: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y -./calc.at:1494: cat stderr -stderr: input: - | (1 + 1) / (1 - 1) -./calc.at:1492: $PREPARSER ./calc input +./torture.at:535: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: -./calc.at:1491: cat stderr + | (1 + 1) / (1 - 1) +./calc.at:1489: $PREPARSER ./calc input + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1494: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) +Reading a token +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Reading a token +Next token is token "number" (1.6: 1) +Error: discarding token "number" (1.6: 1) +Reading a token +Next token is token ')' (1.7: ) +Entering state 11 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 18 +Reading a token +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 27 Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 22 +Next token is token '\n' (1.15-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.3: ) +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 16 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: +stderr: Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) +Next token is token '(' () +Shifting token '(' () Entering state 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 12 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' () +Shifting token '+' () Entering state 20 Reading a token -Next token is token "number" (1.6: 1) -Shifting token "number" (1.6: 1) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.6: 1) --> $$ = nterm exp (1.6: 1) + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 29 Reading a token -Next token is token ')' (1.7: ) +Next token is token ')' () Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) Entering state 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' () +Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) + $1 = token '(' () + $2 = nterm exp (2) + $3 = token ')' () +-> $$ = nterm exp (2) Entering state 8 Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) +Next token is token '/' () +Shifting token '/' () Entering state 22 Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) +Next token is token '(' () +Shifting token '(' () Entering state 4 Reading a token -Next token is token "number" (1.12: 1) -Shifting token "number" (1.12: 1) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.12: 1) --> $$ = nterm exp (1.12: 1) + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 12 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) +Next token is token '-' () +Shifting token '-' () Entering state 19 Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 28 Reading a token -Next token is token ')' (1.17: ) +Next token is token ')' () Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (1) +-> $$ = nterm exp (0) Entering state 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) +Next token is token ')' () +Shifting token ')' () Entering state 26 Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) + $1 = token '(' () + $2 = nterm exp (0) + $3 = token ')' () +-> $$ = nterm exp (0) Entering state 31 Reading a token -Next token is token '\n' (1.18-2.0: ) +Next token is token '\n' () Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) + $1 = nterm exp (2) + $2 = token '/' () + $3 = nterm exp (0) +error: null divisor +-> $$ = nterm exp (2) Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' () +Shifting token '\n' () Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) + $1 = nterm exp (2) + $2 = token '\n' () +-> $$ = nterm line () Entering state 7 Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) + $1 = nterm line () +-> $$ = nterm input () Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) +Shifting token end of input () Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -617. existing.at:74: testing GNU AWK 3.1.0 Grammar: IELR(1) ... -./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -input: -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -616. existing.at:74: testing GNU AWK 3.1.0 Grammar: LALR(1) ... -./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -./torture.at:535: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS - | (- *) + (1 2) = 1 -./calc.at:1494: $PREPARSER ./calc input -stderr: +Cleanup: popping token end of input () +Cleanup: popping nterm input () +./calc.at:1489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -236757,237 +229975,906 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 22 +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.3: ) -stderr: -stderr: -input: -Starting parse -Entering state 0 +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 18 +Reading a token +Next token is token number (1.13: 7) +Shifting token number (1.13: 7) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.13: 7) +-> $$ = nterm exp (1.13: 7) +Entering state 27 +Reading a token +Next token is token '\n' (1.14-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-9: 7) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13: 7) +-> $$ = nterm exp (1.1-13: 7) +Entering state 8 +Next token is token '\n' (1.14-2.0: ) +Shifting token '\n' (1.14-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-13: 7) + $2 = token '\n' (1.14-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Next token is token number (2.1: 1) +Shifting token number (2.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2.1: 1) +-> $$ = nterm exp (2.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (2.3: ) +Shifting token '+' (2.3: ) Entering state 20 Reading a token -Next token is token "number" (1.6: 1) -Shifting token "number" (1.6: 1) +Next token is token number (2.5: 2) +Shifting token number (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.6: 1) --> $$ = nterm exp (1.6: 1) + $1 = token number (2.5: 2) +-> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token -Next token is token ')' (1.7: ) +Next token is token '*' (2.7: ) +Shifting token '*' (2.7: ) +Entering state 21 +Reading a token +Next token is token '-' (2.9: ) +Shifting token '-' (2.9: ) +Entering state 2 +Reading a token +Next token is token number (2.10: 3) +Shifting token number (2.10: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2.10: 3) +-> $$ = nterm exp (2.10: 3) +Entering state 10 +Reading a token +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (2.9: ) + $2 = nterm exp (2.10: 3) +-> $$ = nterm exp (2.9-10: -3) +Entering state 30 +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (2.5: 2) + $2 = token '*' (2.7: ) + $3 = nterm exp (2.9-10: -3) +-> $$ = nterm exp (2.5-10: -6) +Entering state 29 +Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) + $1 = nterm exp (2.1: 1) + $2 = token '+' (2.3: ) + $3 = nterm exp (2.5-10: -6) +-> $$ = nterm exp (2.1-10: -5) +Entering state 8 +Next token is token '=' (2.12: ) +Shifting token '=' (2.12: ) +Entering state 18 +Reading a token +Next token is token '-' (2.14: ) +Shifting token '-' (2.14: ) +Entering state 2 +Reading a token +Next token is token number (2.15: 5) +Shifting token number (2.15: 5) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2.15: 5) +-> $$ = nterm exp (2.15: 5) +Entering state 10 +Reading a token +Next token is token '\n' (2.16-3.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (2.14: ) + $2 = nterm exp (2.15: 5) +-> $$ = nterm exp (2.14-15: -5) +Entering state 27 +Next token is token '\n' (2.16-3.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2.1-10: -5) + $2 = token '=' (2.12: ) + $3 = nterm exp (2.14-15: -5) +-> $$ = nterm exp (2.1-15: -5) +Entering state 8 +Next token is token '\n' (2.16-3.0: ) +Shifting token '\n' (2.16-3.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2.1-15: -5) + $2 = token '\n' (2.16-3.0: ) +-> $$ = nterm line (2.1-3.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-2.0: ) + $2 = nterm line (2.1-3.0: ) +-> $$ = nterm input (1.1-3.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (3.1-4.0: ) +Shifting token '\n' (3.1-4.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (3.1-4.0: ) +-> $$ = nterm line (3.1-4.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-3.0: ) + $2 = nterm line (3.1-4.0: ) +-> $$ = nterm input (1.1-4.0: ) +Entering state 6 +Reading a token +Next token is token '-' (4.1: ) +Shifting token '-' (4.1: ) +Entering state 2 +Reading a token +Next token is token number (4.2: 1) +Shifting token number (4.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (4.2: 1) +-> $$ = nterm exp (4.2: 1) +Entering state 10 +Reading a token +Next token is token '^' (4.3: ) +Shifting token '^' (4.3: ) +Entering state 23 +Reading a token +Next token is token number (4.4: 2) +Shifting token number (4.4: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (4.4: 2) +-> $$ = nterm exp (4.4: 2) +Entering state 32 +Reading a token +Next token is token '=' (4.6: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (4.2: 1) + $2 = token '^' (4.3: ) + $3 = nterm exp (4.4: 2) +-> $$ = nterm exp (4.2-4: 1) +Entering state 10 +Next token is token '=' (4.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (4.1: ) + $2 = nterm exp (4.2-4: 1) +-> $$ = nterm exp (4.1-4: -1) +Entering state 8 +Next token is token '=' (4.6: ) +Shifting token '=' (4.6: ) +Entering state 18 +Reading a token +Next token is token '-' (4.8: ) +Shifting token '-' (4.8: ) +Entering state 2 +Reading a token +Next token is token number (4.9: 1) +Shifting token number (4.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (4.9: 1) +-> $$ = nterm exp (4.9: 1) +Entering state 10 +Reading a token +Next token is token '\n' (4.10-5.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (4.8: ) + $2 = nterm exp (4.9: 1) +-> $$ = nterm exp (4.8-9: -1) +Entering state 27 +Next token is token '\n' (4.10-5.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (4.1-4: -1) + $2 = token '=' (4.6: ) + $3 = nterm exp (4.8-9: -1) +-> $$ = nterm exp (4.1-9: -1) +Entering state 8 +Next token is token '\n' (4.10-5.0: ) +Shifting token '\n' (4.10-5.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (4.1-9: -1) + $2 = token '\n' (4.10-5.0: ) +-> $$ = nterm line (4.1-5.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-4.0: ) + $2 = nterm line (4.1-5.0: ) +-> $$ = nterm input (1.1-5.0: ) +Entering state 6 +Reading a token +Next token is token '(' (5.1: ) +Shifting token '(' (5.1: ) +Entering state 4 +Reading a token +Next token is token '-' (5.2: ) +Shifting token '-' (5.2: ) +Entering state 2 +Reading a token +Next token is token number (5.3: 1) +Shifting token number (5.3: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (5.3: 1) +-> $$ = nterm exp (5.3: 1) +Entering state 10 +Reading a token +Next token is token ')' (5.4: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (5.2: ) + $2 = nterm exp (5.3: 1) +-> $$ = nterm exp (5.2-3: -1) Entering state 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' (5.4: ) +Shifting token ')' (5.4: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) + $1 = token '(' (5.1: ) + $2 = nterm exp (5.2-3: -1) + $3 = token ')' (5.4: ) +-> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 22 +Next token is token '^' (5.5: ) +Shifting token '^' (5.5: ) +Entering state 23 Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) +Next token is token number (5.6: 2) +Shifting token number (5.6: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (5.6: 2) +-> $$ = nterm exp (5.6: 2) +Entering state 32 +Reading a token +Next token is token '=' (5.8: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (5.1-4: -1) + $2 = token '^' (5.5: ) + $3 = nterm exp (5.6: 2) +-> $$ = nterm exp (5.1-6: 1) +Entering state 8 +Next token is token '=' (5.8: ) +Shifting token '=' (5.8: ) +Entering state 18 +Reading a token +Next token is token number (5.10: 1) +Shifting token number (5.10: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (5.10: 1) +-> $$ = nterm exp (5.10: 1) +Entering state 27 +Reading a token +Next token is token '\n' (5.11-6.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (5.1-6: 1) + $2 = token '=' (5.8: ) + $3 = nterm exp (5.10: 1) +-> $$ = nterm exp (5.1-10: 1) +Entering state 8 +Next token is token '\n' (5.11-6.0: ) +Shifting token '\n' (5.11-6.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (5.1-10: 1) + $2 = token '\n' (5.11-6.0: ) +-> $$ = nterm line (5.1-6.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-5.0: ) + $2 = nterm line (5.1-6.0: ) +-> $$ = nterm input (1.1-6.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (6.1-7.0: ) +Shifting token '\n' (6.1-7.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (6.1-7.0: ) +-> $$ = nterm line (6.1-7.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-6.0: ) + $2 = nterm line (6.1-7.0: ) +-> $$ = nterm input (1.1-7.0: ) +Entering state 6 +Reading a token +Next token is token '-' (7.1: ) +Shifting token '-' (7.1: ) +Entering state 2 +Reading a token +Next token is token '-' (7.2: ) +Shifting token '-' (7.2: ) +Entering state 2 +Reading a token +Next token is token '-' (7.3: ) +Shifting token '-' (7.3: ) +Entering state 2 +Reading a token +Next token is token number (7.4: 1) +Shifting token number (7.4: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (7.4: 1) +-> $$ = nterm exp (7.4: 1) +Entering state 10 +Reading a token +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.3: ) + $2 = nterm exp (7.4: 1) +-> $$ = nterm exp (7.3-4: -1) +Entering state 10 +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.2: ) + $2 = nterm exp (7.3-4: -1) +-> $$ = nterm exp (7.2-4: 1) +Entering state 10 +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.1: ) + $2 = nterm exp (7.2-4: 1) +-> $$ = nterm exp (7.1-4: -1) +Entering state 8 +Next token is token '=' (7.6: ) +Shifting token '=' (7.6: ) +Entering state 18 +Reading a token +Next token is token '-' (7.8: ) +Shifting token '-' (7.8: ) +Entering state 2 +Reading a token +Next token is token number (7.9: 1) +Shifting token number (7.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (7.9: 1) +-> $$ = nterm exp (7.9: 1) +Entering state 10 +Reading a token +Next token is token '\n' (7.10-8.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.8: ) + $2 = nterm exp (7.9: 1) +-> $$ = nterm exp (7.8-9: -1) +Entering state 27 +Next token is token '\n' (7.10-8.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (7.1-4: -1) + $2 = token '=' (7.6: ) + $3 = nterm exp (7.8-9: -1) +-> $$ = nterm exp (7.1-9: -1) +Entering state 8 +Next token is token '\n' (7.10-8.0: ) +Shifting token '\n' (7.10-8.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (7.1-9: -1) + $2 = token '\n' (7.10-8.0: ) +-> $$ = nterm line (7.1-8.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-7.0: ) + $2 = nterm line (7.1-8.0: ) +-> $$ = nterm input (1.1-8.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (8.1-9.0: ) +Shifting token '\n' (8.1-9.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (8.1-9.0: ) +-> $$ = nterm line (8.1-9.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-8.0: ) + $2 = nterm line (8.1-9.0: ) +-> $$ = nterm input (1.1-9.0: ) +Entering state 6 +Reading a token +Next token is token number (9.1: 1) +Shifting token number (9.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (9.1: 1) +-> $$ = nterm exp (9.1: 1) +Entering state 8 +Reading a token +Next token is token '-' (9.3: ) +Shifting token '-' (9.3: ) +Entering state 19 +Reading a token +Next token is token number (9.5: 2) +Shifting token number (9.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (9.5: 2) +-> $$ = nterm exp (9.5: 2) +Entering state 28 +Reading a token +Next token is token '-' (9.7: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (9.1: 1) + $2 = token '-' (9.3: ) + $3 = nterm exp (9.5: 2) +-> $$ = nterm exp (9.1-5: -1) +Entering state 8 +Next token is token '-' (9.7: ) +Shifting token '-' (9.7: ) +Entering state 19 +Reading a token +Next token is token number (9.9: 3) +Shifting token number (9.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (9.9: 3) +-> $$ = nterm exp (9.9: 3) +Entering state 28 +Reading a token +Next token is token '=' (9.11: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (9.1-5: -1) + $2 = token '-' (9.7: ) + $3 = nterm exp (9.9: 3) +-> $$ = nterm exp (9.1-9: -4) +Entering state 8 +Next token is token '=' (9.11: ) +Shifting token '=' (9.11: ) +Entering state 18 +Reading a token +Next token is token '-' (9.13: ) +Shifting token '-' (9.13: ) +Entering state 2 +Reading a token +Next token is token number (9.14: 4) +Shifting token number (9.14: 4) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (9.14: 4) +-> $$ = nterm exp (9.14: 4) +Entering state 10 +Reading a token +Next token is token '\n' (9.15-10.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (9.13: ) + $2 = nterm exp (9.14: 4) +-> $$ = nterm exp (9.13-14: -4) +Entering state 27 +Next token is token '\n' (9.15-10.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (9.1-9: -4) + $2 = token '=' (9.11: ) + $3 = nterm exp (9.13-14: -4) +-> $$ = nterm exp (9.1-14: -4) +Entering state 8 +Next token is token '\n' (9.15-10.0: ) +Shifting token '\n' (9.15-10.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (9.1-14: -4) + $2 = token '\n' (9.15-10.0: ) +-> $$ = nterm line (9.1-10.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-9.0: ) + $2 = nterm line (9.1-10.0: ) +-> $$ = nterm input (1.1-10.0: ) +Entering state 6 +Reading a token +Next token is token number (10.1: 1) +Shifting token number (10.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (10.1: 1) +-> $$ = nterm exp (10.1: 1) +Entering state 8 +Reading a token +Next token is token '-' (10.3: ) +Shifting token '-' (10.3: ) +Entering state 19 +Reading a token +Next token is token '(' (10.5: ) +Shifting token '(' (10.5: ) Entering state 4 Reading a token -Next token is token "number" (1.12: 1) -Shifting token "number" (1.12: 1) +Next token is token number (10.6: 2) +Shifting token number (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.12: 1) --> $$ = nterm exp (1.12: 1) + $1 = token number (10.6: 2) +-> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) +Next token is token '-' (10.8: ) +Shifting token '-' (10.8: ) Entering state 19 Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) +Next token is token number (10.10: 3) +Shifting token number (10.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) + $1 = token number (10.10: 3) +-> $$ = nterm exp (10.10: 3) Entering state 28 Reading a token -Next token is token ')' (1.17: ) +Next token is token ')' (10.11: ) Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) + $1 = nterm exp (10.6: 2) + $2 = token '-' (10.8: ) + $3 = nterm exp (10.10: 3) +-> $$ = nterm exp (10.6-10: -1) Entering state 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) +Next token is token ')' (10.11: ) +Shifting token ')' (10.11: ) Entering state 26 Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 31 + $1 = token '(' (10.5: ) + $2 = nterm exp (10.6-10: -1) + $3 = token ')' (10.11: ) +-> $$ = nterm exp (10.5-11: -1) +Entering state 28 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) +Next token is token '=' (10.13: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (10.1: 1) + $2 = token '-' (10.3: ) + $3 = nterm exp (10.5-11: -1) +-> $$ = nterm exp (10.1-11: 2) Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '=' (10.13: ) +Shifting token '=' (10.13: ) +Entering state 18 +Reading a token +Next token is token number (10.15: 2) +Shifting token number (10.15: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (10.15: 2) +-> $$ = nterm exp (10.15: 2) +Entering state 27 +Reading a token +Next token is token '\n' (10.16-11.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (10.1-11: 2) + $2 = token '=' (10.13: ) + $3 = nterm exp (10.15: 2) +-> $$ = nterm exp (10.1-15: 2) +Entering state 8 +Next token is token '\n' (10.16-11.0: ) +Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) + $1 = nterm exp (10.1-15: 2) + $2 = token '\n' (10.16-11.0: ) +-> $$ = nterm line (10.1-11.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-10.0: ) + $2 = nterm line (10.1-11.0: ) +-> $$ = nterm input (1.1-11.0: ) Entering state 6 Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -Starting parse -Entering state 0 +Next token is token '\n' (11.1-12.0: ) +Shifting token '\n' (11.1-12.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (11.1-12.0: ) +-> $$ = nterm line (11.1-12.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-11.0: ) + $2 = nterm line (11.1-12.0: ) +-> $$ = nterm input (1.1-12.0: ) +Entering state 6 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 +Next token is token number (12.1: 2) +Shifting token number (12.1: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (12.1: 2) +-> $$ = nterm exp (12.1: 2) +Entering state 8 Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 +Next token is token '^' (12.2: ) +Shifting token '^' (12.2: ) +Entering state 23 Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Reducing stack 0 by rule 15 (line 106): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Shifting token error (1.2-4: ) -Entering state 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) +Next token is token number (12.3: 2) +Shifting token number (12.3: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (12.3: 2) +-> $$ = nterm exp (12.3: 2) +Entering state 32 Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) +Next token is token '^' (12.4: ) +Shifting token '^' (12.4: ) +Entering state 23 +Reading a token +Next token is token number (12.5: 3) +Shifting token number (12.5: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (12.5: 3) +-> $$ = nterm exp (12.5: 3) +Entering state 32 +Reading a token +Next token is token '=' (12.7: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (12.3: 2) + $2 = token '^' (12.4: ) + $3 = nterm exp (12.5: 3) +-> $$ = nterm exp (12.3-5: 8) +Entering state 32 +Next token is token '=' (12.7: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (12.1: 2) + $2 = token '^' (12.2: ) + $3 = nterm exp (12.3-5: 8) +-> $$ = nterm exp (12.1-5: 256) Entering state 8 +Next token is token '=' (12.7: ) +Shifting token '=' (12.7: ) +Entering state 18 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 +Next token is token number (12.9-11: 256) +Shifting token number (12.9-11: 256) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (12.9-11: 256) +-> $$ = nterm exp (12.9-11: 256) +Entering state 27 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) +Next token is token '\n' (12.12-13.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (12.1-5: 256) + $2 = token '=' (12.7: ) + $3 = nterm exp (12.9-11: 256) +-> $$ = nterm exp (12.1-11: 256) +Entering state 8 +Next token is token '\n' (12.12-13.0: ) +Shifting token '\n' (12.12-13.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (12.1-11: 256) + $2 = token '\n' (12.12-13.0: ) +-> $$ = nterm line (12.1-13.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-12.0: ) + $2 = nterm line (12.1-13.0: ) +-> $$ = nterm input (1.1-13.0: ) +Entering state 6 +Reading a token +Next token is token '(' (13.1: ) +Shifting token '(' (13.1: ) Entering state 4 Reading a token -Next token is token "number" (1.10: 1) -Shifting token "number" (1.10: 1) +Next token is token number (13.2: 2) +Shifting token number (13.2: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.10: 1) --> $$ = nterm exp (1.10: 1) + $1 = token number (13.2: 2) +-> $$ = nterm exp (13.2: 2) Entering state 12 Reading a token -Next token is token "number" (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Shifting token error (1.10-12: ) -Entering state 11 -Next token is token "number" (1.12: 2) -Error: discarding token "number" (1.12: 2) +Next token is token '^' (13.3: ) +Shifting token '^' (13.3: ) +Entering state 23 Reading a token -Next token is token ')' (1.13: ) -Entering state 11 -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) +Next token is token number (13.4: 2) +Shifting token number (13.4: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (13.4: 2) +-> $$ = nterm exp (13.4: 2) +Entering state 32 +Reading a token +Next token is token ')' (13.5: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (13.2: 2) + $2 = token '^' (13.3: ) + $3 = nterm exp (13.4: 2) +-> $$ = nterm exp (13.2-4: 4) +Entering state 12 +Next token is token ')' (13.5: ) +Shifting token ')' (13.5: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (13.1: ) + $2 = nterm exp (13.2-4: 4) + $3 = token ')' (13.5: ) +-> $$ = nterm exp (13.1-5: 4) +Entering state 8 +Reading a token +Next token is token '^' (13.6: ) +Shifting token '^' (13.6: ) +Entering state 23 +Reading a token +Next token is token number (13.7: 3) +Shifting token number (13.7: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (13.7: 3) +-> $$ = nterm exp (13.7: 3) +Entering state 32 +Reading a token +Next token is token '=' (13.9: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (13.1-5: 4) + $2 = token '^' (13.6: ) + $3 = nterm exp (13.7: 3) +-> $$ = nterm exp (13.1-7: 64) +Entering state 8 +Next token is token '=' (13.9: ) +Shifting token '=' (13.9: ) +Entering state 18 +Reading a token +Next token is token number (13.11-12: 64) +Shifting token number (13.11-12: 64) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (13.11-12: 64) +-> $$ = nterm exp (13.11-12: 64) +Entering state 27 +Reading a token +Next token is token '\n' (13.13-14.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (13.1-7: 64) + $2 = token '=' (13.9: ) + $3 = nterm exp (13.11-12: 64) +-> $$ = nterm exp (13.1-12: 64) +Entering state 8 +Next token is token '\n' (13.13-14.0: ) +Shifting token '\n' (13.13-14.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (13.1-12: 64) + $2 = token '\n' (13.13-14.0: ) +-> $$ = nterm line (13.1-14.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-13.0: ) + $2 = nterm line (13.1-14.0: ) +-> $$ = nterm input (1.1-14.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input (14.1: ) +Entering state 16 +Cleanup: popping token end of input (14.1: ) +Cleanup: popping nterm input (1.1-14.0: ) +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token -Next token is token '=' (1.15: ) +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Reading a token +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) Entering state 18 Reading a token -Next token is token "number" (1.17: 1) -Shifting token "number" (1.17: 1) +Next token is token "number" (1.13: 7) +Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.17: 1) --> $$ = nterm exp (1.17: 1) + $1 = token "number" (1.13: 7) +-> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token -Next token is token '\n' (1.18-2.0: ) +Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) + $1 = nterm exp (1.1-9: 7) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13: 7) +-> $$ = nterm exp (1.1-13: 7) Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.14-2.0: ) +Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-13: 7) + $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -236995,15 +230882,762 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token +Next token is token "number" (2.1: 1) +Shifting token "number" (2.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2.1: 1) +-> $$ = nterm exp (2.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (2.3: ) +Shifting token '+' (2.3: ) +Entering state 20 +Reading a token +Next token is token "number" (2.5: 2) +Shifting token "number" (2.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2.5: 2) +-> $$ = nterm exp (2.5: 2) +Entering state 29 +Reading a token +Next token is token '*' (2.7: ) +Shifting token '*' (2.7: ) +Entering state 21 +Reading a token +Next token is token '-' (2.9: ) +Shifting token '-' (2.9: ) +Entering state 2 +Reading a token +Next token is token "number" (2.10: 3) +Shifting token "number" (2.10: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2.10: 3) +-> $$ = nterm exp (2.10: 3) +Entering state 10 +Reading a token +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (2.9: ) + $2 = nterm exp (2.10: 3) +-> $$ = nterm exp (2.9-10: -3) +Entering state 30 +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (2.5: 2) + $2 = token '*' (2.7: ) + $3 = nterm exp (2.9-10: -3) +-> $$ = nterm exp (2.5-10: -6) +Entering state 29 +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (2.1: 1) + $2 = token '+' (2.3: ) + $3 = nterm exp (2.5-10: -6) +-> $$ = nterm exp (2.1-10: -5) +Entering state 8 +Next token is token '=' (2.12: ) +Shifting token '=' (2.12: ) +Entering state 18 +Reading a token +Next token is token '-' (2.14: ) +Shifting token '-' (2.14: ) +Entering state 2 +Reading a token +Next token is token "number" (2.15: 5) +Shifting token "number" (2.15: 5) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2.15: 5) +-> $$ = nterm exp (2.15: 5) +Entering state 10 +Reading a token +Next token is token '\n' (2.16-3.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (2.14: ) + $2 = nterm exp (2.15: 5) +-> $$ = nterm exp (2.14-15: -5) +Entering state 27 +Next token is token '\n' (2.16-3.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2.1-10: -5) + $2 = token '=' (2.12: ) + $3 = nterm exp (2.14-15: -5) +-> $$ = nterm exp (2.1-15: -5) +Entering state 8 +Next token is token '\n' (2.16-3.0: ) +Shifting token '\n' (2.16-3.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2.1-15: -5) + $2 = token '\n' (2.16-3.0: ) +-> $$ = nterm line (2.1-3.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-2.0: ) + $2 = nterm line (2.1-3.0: ) +-> $$ = nterm input (1.1-3.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (3.1-4.0: ) +Shifting token '\n' (3.1-4.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (3.1-4.0: ) +-> $$ = nterm line (3.1-4.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-3.0: ) + $2 = nterm line (3.1-4.0: ) +-> $$ = nterm input (1.1-4.0: ) +Entering state 6 +Reading a token +Next token is token '-' (4.1: ) +Shifting token '-' (4.1: ) +Entering state 2 +Reading a token +Next token is token "number" (4.2: 1) +Shifting token "number" (4.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (4.2: 1) +-> $$ = nterm exp (4.2: 1) +Entering state 10 +Reading a token +Next token is token '^' (4.3: ) +Shifting token '^' (4.3: ) +Entering state 23 +Reading a token +Next token is token "number" (4.4: 2) +Shifting token "number" (4.4: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (4.4: 2) +-> $$ = nterm exp (4.4: 2) +Entering state 32 +Reading a token +Next token is token '=' (4.6: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (4.2: 1) + $2 = token '^' (4.3: ) + $3 = nterm exp (4.4: 2) +-> $$ = nterm exp (4.2-4: 1) +Entering state 10 +Next token is token '=' (4.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (4.1: ) + $2 = nterm exp (4.2-4: 1) +-> $$ = nterm exp (4.1-4: -1) +Entering state 8 +Next token is token '=' (4.6: ) +Shifting token '=' (4.6: ) +Entering state 18 +Reading a token +Next token is token '-' (4.8: ) +Shifting token '-' (4.8: ) +Entering state 2 +Reading a token +Next token is token "number" (4.9: 1) +Shifting token "number" (4.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (4.9: 1) +-> $$ = nterm exp (4.9: 1) +Entering state 10 +Reading a token +Next token is token '\n' (4.10-5.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (4.8: ) + $2 = nterm exp (4.9: 1) +-> $$ = nterm exp (4.8-9: -1) +Entering state 27 +Next token is token '\n' (4.10-5.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (4.1-4: -1) + $2 = token '=' (4.6: ) + $3 = nterm exp (4.8-9: -1) +-> $$ = nterm exp (4.1-9: -1) +Entering state 8 +Next token is token '\n' (4.10-5.0: ) +Shifting token '\n' (4.10-5.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (4.1-9: -1) + $2 = token '\n' (4.10-5.0: ) +-> $$ = nterm line (4.1-5.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-4.0: ) + $2 = nterm line (4.1-5.0: ) +-> $$ = nterm input (1.1-5.0: ) +Entering state 6 +Reading a token +Next token is token '(' (5.1: ) +Shifting token '(' (5.1: ) +Entering state 4 +Reading a token +Next token is token '-' (5.2: ) +Shifting token '-' (5.2: ) +Entering state 2 +Reading a token +Next token is token "number" (5.3: 1) +Shifting token "number" (5.3: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (5.3: 1) +-> $$ = nterm exp (5.3: 1) +Entering state 10 +Reading a token +Next token is token ')' (5.4: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (5.2: ) + $2 = nterm exp (5.3: 1) +-> $$ = nterm exp (5.2-3: -1) +Entering state 12 +Next token is token ')' (5.4: ) +Shifting token ')' (5.4: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (5.1: ) + $2 = nterm exp (5.2-3: -1) + $3 = token ')' (5.4: ) +-> $$ = nterm exp (5.1-4: -1) +Entering state 8 +Reading a token +Next token is token '^' (5.5: ) +Shifting token '^' (5.5: ) +Entering state 23 +Reading a token +Next token is token "number" (5.6: 2) +Shifting token "number" (5.6: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (5.6: 2) +-> $$ = nterm exp (5.6: 2) +Entering state 32 +Reading a token +Next token is token '=' (5.8: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (5.1-4: -1) + $2 = token '^' (5.5: ) + $3 = nterm exp (5.6: 2) +-> $$ = nterm exp (5.1-6: 1) +Entering state 8 +Next token is token '=' (5.8: ) +Shifting token '=' (5.8: ) +Entering state 18 +Reading a token +Next token is token "number" (5.10: 1) +Shifting token "number" (5.10: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (5.10: 1) +-> $$ = nterm exp (5.10: 1) +Entering state 27 +Reading a token +Next token is token '\n' (5.11-6.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (5.1-6: 1) + $2 = token '=' (5.8: ) + $3 = nterm exp (5.10: 1) +-> $$ = nterm exp (5.1-10: 1) +Entering state 8 +Next token is token '\n' (5.11-6.0: ) +Shifting token '\n' (5.11-6.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (5.1-10: 1) + $2 = token '\n' (5.11-6.0: ) +-> $$ = nterm line (5.1-6.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-5.0: ) + $2 = nterm line (5.1-6.0: ) +-> $$ = nterm input (1.1-6.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (6.1-7.0: ) +Shifting token '\n' (6.1-7.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (6.1-7.0: ) +-> $$ = nterm line (6.1-7.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-6.0: ) + $2 = nterm line (6.1-7.0: ) +-> $$ = nterm input (1.1-7.0: ) +Entering state 6 +Reading a token +Next token is token '-' (7.1: ) +Shifting token '-' (7.1: ) +Entering state 2 +Reading a token +Next token is token '-' (7.2: ) +Shifting token '-' (7.2: ) +Entering state 2 +Reading a token +Next token is token '-' (7.3: ) +Shifting token '-' (7.3: ) +Entering state 2 +Reading a token +Next token is token "number" (7.4: 1) +Shifting token "number" (7.4: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (7.4: 1) +-> $$ = nterm exp (7.4: 1) +Entering state 10 +Reading a token +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.3: ) + $2 = nterm exp (7.4: 1) +-> $$ = nterm exp (7.3-4: -1) +Entering state 10 +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.2: ) + $2 = nterm exp (7.3-4: -1) +-> $$ = nterm exp (7.2-4: 1) +Entering state 10 +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.1: ) + $2 = nterm exp (7.2-4: 1) +-> $$ = nterm exp (7.1-4: -1) +Entering state 8 +Next token is token '=' (7.6: ) +Shifting token '=' (7.6: ) +Entering state 18 +Reading a token +Next token is token '-' (7.8: ) +Shifting token '-' (7.8: ) +Entering state 2 +Reading a token +Next token is token "number" (7.9: 1) +Shifting token "number" (7.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (7.9: 1) +-> $$ = nterm exp (7.9: 1) +Entering state 10 +Reading a token +Next token is token '\n' (7.10-8.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.8: ) + $2 = nterm exp (7.9: 1) +-> $$ = nterm exp (7.8-9: -1) +Entering state 27 +Next token is token '\n' (7.10-8.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (7.1-4: -1) + $2 = token '=' (7.6: ) + $3 = nterm exp (7.8-9: -1) +-> $$ = nterm exp (7.1-9: -1) +Entering state 8 +Next token is token '\n' (7.10-8.0: ) +Shifting token '\n' (7.10-8.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (7.1-9: -1) + $2 = token '\n' (7.10-8.0: ) +-> $$ = nterm line (7.1-8.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-7.0: ) + $2 = nterm line (7.1-8.0: ) +-> $$ = nterm input (1.1-8.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (8.1-9.0: ) +Shifting token '\n' (8.1-9.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (8.1-9.0: ) +-> $$ = nterm line (8.1-9.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-8.0: ) + $2 = nterm line (8.1-9.0: ) +-> $$ = nterm input (1.1-9.0: ) +Entering state 6 +Reading a token +Next token is token "number" (9.1: 1) +Shifting token "number" (9.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (9.1: 1) +-> $$ = nterm exp (9.1: 1) +Entering state 8 +Reading a token +Next token is token '-' (9.3: ) +Shifting token '-' (9.3: ) +Entering state 19 +Reading a token +Next token is token "number" (9.5: 2) +Shifting token "number" (9.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (9.5: 2) +-> $$ = nterm exp (9.5: 2) +Entering state 28 +Reading a token +Next token is token '-' (9.7: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (9.1: 1) + $2 = token '-' (9.3: ) + $3 = nterm exp (9.5: 2) +-> $$ = nterm exp (9.1-5: -1) +Entering state 8 +Next token is token '-' (9.7: ) +Shifting token '-' (9.7: ) +Entering state 19 +Reading a token +Next token is token "number" (9.9: 3) +Shifting token "number" (9.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (9.9: 3) +-> $$ = nterm exp (9.9: 3) +Entering state 28 +Reading a token +Next token is token '=' (9.11: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (9.1-5: -1) + $2 = token '-' (9.7: ) + $3 = nterm exp (9.9: 3) +-> $$ = nterm exp (9.1-9: -4) +Entering state 8 +Next token is token '=' (9.11: ) +Shifting token '=' (9.11: ) +Entering state 18 +Reading a token +Next token is token '-' (9.13: ) +Shifting token '-' (9.13: ) +Entering state 2 +Reading a token +Next token is token "number" (9.14: 4) +Shifting token "number" (9.14: 4) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (9.14: 4) +-> $$ = nterm exp (9.14: 4) +Entering state 10 +Reading a token +Next token is token '\n' (9.15-10.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (9.13: ) + $2 = nterm exp (9.14: 4) +-> $$ = nterm exp (9.13-14: -4) +Entering state 27 +Next token is token '\n' (9.15-10.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (9.1-9: -4) + $2 = token '=' (9.11: ) + $3 = nterm exp (9.13-14: -4) +-> $$ = nterm exp (9.1-14: -4) +Entering state 8 +Next token is token '\n' (9.15-10.0: ) +Shifting token '\n' (9.15-10.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (9.1-14: -4) + $2 = token '\n' (9.15-10.0: ) +-> $$ = nterm line (9.1-10.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-9.0: ) + $2 = nterm line (9.1-10.0: ) +-> $$ = nterm input (1.1-10.0: ) +Entering state 6 +Reading a token +Next token is token "number" (10.1: 1) +Shifting token "number" (10.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (10.1: 1) +-> $$ = nterm exp (10.1: 1) +Entering state 8 +Reading a token +Next token is token '-' (10.3: ) +Shifting token '-' (10.3: ) +Entering state 19 +Reading a token +Next token is token '(' (10.5: ) +Shifting token '(' (10.5: ) +Entering state 4 +Reading a token +Next token is token "number" (10.6: 2) +Shifting token "number" (10.6: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (10.6: 2) +-> $$ = nterm exp (10.6: 2) +Entering state 12 +Reading a token +Next token is token '-' (10.8: ) +Shifting token '-' (10.8: ) +Entering state 19 +Reading a token +Next token is token "number" (10.10: 3) +Shifting token "number" (10.10: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (10.10: 3) +-> $$ = nterm exp (10.10: 3) +Entering state 28 +Reading a token +Next token is token ')' (10.11: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (10.6: 2) + $2 = token '-' (10.8: ) + $3 = nterm exp (10.10: 3) +-> $$ = nterm exp (10.6-10: -1) +Entering state 12 +Next token is token ')' (10.11: ) +Shifting token ')' (10.11: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (10.5: ) + $2 = nterm exp (10.6-10: -1) + $3 = token ')' (10.11: ) +-> $$ = nterm exp (10.5-11: -1) +Entering state 28 +Reading a token +Next token is token '=' (10.13: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (10.1: 1) + $2 = token '-' (10.3: ) + $3 = nterm exp (10.5-11: -1) +-> $$ = nterm exp (10.1-11: 2) +Entering state 8 +Next token is token '=' (10.13: ) +Shifting token '=' (10.13: ) +Entering state 18 +Reading a token +Next token is token "number" (10.15: 2) +Shifting token "number" (10.15: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (10.15: 2) +-> $$ = nterm exp (10.15: 2) +Entering state 27 +Reading a token +Next token is token '\n' (10.16-11.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (10.1-11: 2) + $2 = token '=' (10.13: ) + $3 = nterm exp (10.15: 2) +-> $$ = nterm exp (10.1-15: 2) +Entering state 8 +Next token is token '\n' (10.16-11.0: ) +Shifting token '\n' (10.16-11.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (10.1-15: 2) + $2 = token '\n' (10.16-11.0: ) +-> $$ = nterm line (10.1-11.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-10.0: ) + $2 = nterm line (10.1-11.0: ) +-> $$ = nterm input (1.1-11.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (11.1-12.0: ) +Shifting token '\n' (11.1-12.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (11.1-12.0: ) +-> $$ = nterm line (11.1-12.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-11.0: ) + $2 = nterm line (11.1-12.0: ) +-> $$ = nterm input (1.1-12.0: ) +Entering state 6 +Reading a token +Next token is token "number" (12.1: 2) +Shifting token "number" (12.1: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (12.1: 2) +-> $$ = nterm exp (12.1: 2) +Entering state 8 +Reading a token +Next token is token '^' (12.2: ) +Shifting token '^' (12.2: ) +Entering state 23 +Reading a token +Next token is token "number" (12.3: 2) +Shifting token "number" (12.3: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (12.3: 2) +-> $$ = nterm exp (12.3: 2) +Entering state 32 +Reading a token +Next token is token '^' (12.4: ) +Shifting token '^' (12.4: ) +Entering state 23 +Reading a token +Next token is token "number" (12.5: 3) +Shifting token "number" (12.5: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (12.5: 3) +-> $$ = nterm exp (12.5: 3) +Entering state 32 +Reading a token +Next token is token '=' (12.7: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (12.3: 2) + $2 = token '^' (12.4: ) + $3 = nterm exp (12.5: 3) +-> $$ = nterm exp (12.3-5: 8) +Entering state 32 +Next token is token '=' (12.7: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (12.1: 2) + $2 = token '^' (12.2: ) + $3 = nterm exp (12.3-5: 8) +-> $$ = nterm exp (12.1-5: 256) +Entering state 8 +Next token is token '=' (12.7: ) +Shifting token '=' (12.7: ) +Entering state 18 +Reading a token +Next token is token "number" (12.9-11: 256) +Shifting token "number" (12.9-11: 256) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (12.9-11: 256) +-> $$ = nterm exp (12.9-11: 256) +Entering state 27 +Reading a token +Next token is token '\n' (12.12-13.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (12.1-5: 256) + $2 = token '=' (12.7: ) + $3 = nterm exp (12.9-11: 256) +-> $$ = nterm exp (12.1-11: 256) +Entering state 8 +Next token is token '\n' (12.12-13.0: ) +Shifting token '\n' (12.12-13.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (12.1-11: 256) + $2 = token '\n' (12.12-13.0: ) +-> $$ = nterm line (12.1-13.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-12.0: ) + $2 = nterm line (12.1-13.0: ) +-> $$ = nterm input (1.1-13.0: ) +Entering state 6 +Reading a token +Next token is token '(' (13.1: ) +Shifting token '(' (13.1: ) +Entering state 4 +Reading a token +Next token is token "number" (13.2: 2) +Shifting token "number" (13.2: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (13.2: 2) +-> $$ = nterm exp (13.2: 2) +Entering state 12 +Reading a token +Next token is token '^' (13.3: ) +Shifting token '^' (13.3: ) +Entering state 23 +Reading a token +Next token is token "number" (13.4: 2) +Shifting token "number" (13.4: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (13.4: 2) +-> $$ = nterm exp (13.4: 2) +Entering state 32 +Reading a token +Next token is token ')' (13.5: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (13.2: 2) + $2 = token '^' (13.3: ) + $3 = nterm exp (13.4: 2) +-> $$ = nterm exp (13.2-4: 4) +Entering state 12 +Next token is token ')' (13.5: ) +Shifting token ')' (13.5: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (13.1: ) + $2 = nterm exp (13.2-4: 4) + $3 = token ')' (13.5: ) +-> $$ = nterm exp (13.1-5: 4) +Entering state 8 +Reading a token +Next token is token '^' (13.6: ) +Shifting token '^' (13.6: ) +Entering state 23 +Reading a token +Next token is token "number" (13.7: 3) +Shifting token "number" (13.7: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (13.7: 3) +-> $$ = nterm exp (13.7: 3) +Entering state 32 +Reading a token +Next token is token '=' (13.9: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (13.1-5: 4) + $2 = token '^' (13.6: ) + $3 = nterm exp (13.7: 3) +-> $$ = nterm exp (13.1-7: 64) +Entering state 8 +Next token is token '=' (13.9: ) +Shifting token '=' (13.9: ) +Entering state 18 +Reading a token +Next token is token "number" (13.11-12: 64) +Shifting token "number" (13.11-12: 64) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (13.11-12: 64) +-> $$ = nterm exp (13.11-12: 64) +Entering state 27 +Reading a token +Next token is token '\n' (13.13-14.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (13.1-7: 64) + $2 = token '=' (13.9: ) + $3 = nterm exp (13.11-12: 64) +-> $$ = nterm exp (13.1-12: 64) +Entering state 8 +Next token is token '\n' (13.13-14.0: ) +Shifting token '\n' (13.13-14.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (13.1-12: 64) + $2 = token '\n' (13.13-14.0: ) +-> $$ = nterm line (13.1-14.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-13.0: ) + $2 = nterm line (13.1-14.0: ) +-> $$ = nterm input (1.1-14.0: ) +Entering state 6 +Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) +Shifting token "end of input" (14.1: ) Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - | (- *) + (1 2) = 1 -./calc.at:1491: $PREPARSER ./calc input -./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +Cleanup: popping token "end of input" (14.1: ) +Cleanup: popping nterm input (1.1-14.0: ) +input: ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -237015,110 +231649,217 @@ }eg ' expout || exit 77 stderr: + | 1 2 +./calc.at:1491: $PREPARSER ./calc input +./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) +Next token is token '(' () +Shifting token '(' () Entering state 4 Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 12 Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Reducing stack 0 by rule 15 (line 106): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Shifting token error (1.2-4: ) -Entering state 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) +Next token is token '+' () +Shifting token '+' () +Entering state 20 Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 29 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1) + $2 = token '+' () + $3 = nterm exp (1) +-> $$ = nterm exp (2) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (2) + $3 = token ')' () +-> $$ = nterm exp (2) Entering state 8 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 +Next token is token '/' () +Shifting token '/' () +Entering state 22 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) +Next token is token '(' () +Shifting token '(' () Entering state 4 Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) +Next token is token number (1) +Shifting token number (1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.10: 1) --> $$ = nterm exp (1.10: 1) + $1 = token number (1) +-> $$ = nterm exp (1) Entering state 12 Reading a token -Next token is token number (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Shifting token error (1.10-12: ) -Entering state 11 -Next token is token number (1.12: 2) -Error: discarding token number (1.12: 2) +Next token is token '-' () +Shifting token '-' () +Entering state 19 Reading a token -Next token is token ')' (1.13: ) -Entering state 11 -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) +Next token is token number (1) +Shifting token number (1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1) +-> $$ = nterm exp (1) +Entering state 28 +Reading a token +Next token is token ')' () +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1) + $2 = token '-' () + $3 = nterm exp (1) +-> $$ = nterm exp (0) +Entering state 12 +Next token is token ')' () +Shifting token ')' () +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' () + $2 = nterm exp (0) + $3 = token ')' () +-> $$ = nterm exp (0) +Entering state 31 +Reading a token +Next token is token '\n' () +Reducing stack 0 by rule 10 (line 93): + $1 = nterm exp (2) + $2 = token '/' () + $3 = nterm exp (0) +error: null divisor +-> $$ = nterm exp (2) +Entering state 8 +Next token is token '\n' () +Shifting token '\n' () +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2) + $2 = token '\n' () +-> $$ = nterm line () +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line () +-> $$ = nterm input () +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input () +Entering state 16 +Cleanup: popping token end of input () +Cleanup: popping nterm input () +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token number (1.3: 2) +./calc.at:1492: cat stderr +stderr: +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token -Next token is token '=' (1.15: ) +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Reading a token +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) Entering state 18 Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) +Next token is token "number" (1.13: 7) +Shifting token "number" (1.13: 7) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.17: 1) --> $$ = nterm exp (1.17: 1) + $1 = token "number" (1.13: 7) +-> $$ = nterm exp (1.13: 7) Entering state 27 Reading a token -Next token is token '\n' (1.18-2.0: ) +Next token is token '\n' (1.14-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) + $1 = nterm exp (1.1-9: 7) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13: 7) +-> $$ = nterm exp (1.1-13: 7) Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.14-2.0: ) +Shifting token '\n' (1.14-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-13: 7) + $2 = token '\n' (1.14-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -237126,247 +231867,856 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token -Now at end of input. -Shifting token end of input (2.1: ) -Entering state 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1492: cat stderr -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 +Next token is token "number" (2.1: 1) +Shifting token "number" (2.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2.1: 1) +-> $$ = nterm exp (2.1: 1) +Entering state 8 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) +Next token is token '+' (2.3: ) +Shifting token '+' (2.3: ) +Entering state 20 +Reading a token +Next token is token "number" (2.5: 2) +Shifting token "number" (2.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2.5: 2) +-> $$ = nterm exp (2.5: 2) +Entering state 29 +Reading a token +Next token is token '*' (2.7: ) +Shifting token '*' (2.7: ) +Entering state 21 +Reading a token +Next token is token '-' (2.9: ) +Shifting token '-' (2.9: ) +Entering state 2 +Reading a token +Next token is token "number" (2.10: 3) +Shifting token "number" (2.10: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2.10: 3) +-> $$ = nterm exp (2.10: 3) +Entering state 10 +Reading a token +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (2.9: ) + $2 = nterm exp (2.10: 3) +-> $$ = nterm exp (2.9-10: -3) +Entering state 30 +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (2.5: 2) + $2 = token '*' (2.7: ) + $3 = nterm exp (2.9-10: -3) +-> $$ = nterm exp (2.5-10: -6) +Entering state 29 +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (2.1: 1) + $2 = token '+' (2.3: ) + $3 = nterm exp (2.5-10: -6) +-> $$ = nterm exp (2.1-10: -5) +Entering state 8 +Next token is token '=' (2.12: ) +Shifting token '=' (2.12: ) +Entering state 18 +Reading a token +Next token is token '-' (2.14: ) +Shifting token '-' (2.14: ) +Entering state 2 +Reading a token +Next token is token "number" (2.15: 5) +Shifting token "number" (2.15: 5) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (2.15: 5) +-> $$ = nterm exp (2.15: 5) +Entering state 10 +Reading a token +Next token is token '\n' (2.16-3.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (2.14: ) + $2 = nterm exp (2.15: 5) +-> $$ = nterm exp (2.14-15: -5) +Entering state 27 +Next token is token '\n' (2.16-3.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2.1-10: -5) + $2 = token '=' (2.12: ) + $3 = nterm exp (2.14-15: -5) +-> $$ = nterm exp (2.1-15: -5) +Entering state 8 +Next token is token '\n' (2.16-3.0: ) +Shifting token '\n' (2.16-3.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2.1-15: -5) + $2 = token '\n' (2.16-3.0: ) +-> $$ = nterm line (2.1-3.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-2.0: ) + $2 = nterm line (2.1-3.0: ) +-> $$ = nterm input (1.1-3.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (3.1-4.0: ) +Shifting token '\n' (3.1-4.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (3.1-4.0: ) +-> $$ = nterm line (3.1-4.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-3.0: ) + $2 = nterm line (3.1-4.0: ) +-> $$ = nterm input (1.1-4.0: ) +Entering state 6 +Reading a token +Next token is token '-' (4.1: ) +Shifting token '-' (4.1: ) +Entering state 2 +Reading a token +Next token is token "number" (4.2: 1) +Shifting token "number" (4.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (4.2: 1) +-> $$ = nterm exp (4.2: 1) +Entering state 10 +Reading a token +Next token is token '^' (4.3: ) +Shifting token '^' (4.3: ) +Entering state 23 +Reading a token +Next token is token "number" (4.4: 2) +Shifting token "number" (4.4: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (4.4: 2) +-> $$ = nterm exp (4.4: 2) +Entering state 32 +Reading a token +Next token is token '=' (4.6: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (4.2: 1) + $2 = token '^' (4.3: ) + $3 = nterm exp (4.4: 2) +-> $$ = nterm exp (4.2-4: 1) +Entering state 10 +Next token is token '=' (4.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (4.1: ) + $2 = nterm exp (4.2-4: 1) +-> $$ = nterm exp (4.1-4: -1) +Entering state 8 +Next token is token '=' (4.6: ) +Shifting token '=' (4.6: ) +Entering state 18 +Reading a token +Next token is token '-' (4.8: ) +Shifting token '-' (4.8: ) +Entering state 2 +Reading a token +Next token is token "number" (4.9: 1) +Shifting token "number" (4.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (4.9: 1) +-> $$ = nterm exp (4.9: 1) +Entering state 10 +Reading a token +Next token is token '\n' (4.10-5.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (4.8: ) + $2 = nterm exp (4.9: 1) +-> $$ = nterm exp (4.8-9: -1) +Entering state 27 +Next token is token '\n' (4.10-5.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (4.1-4: -1) + $2 = token '=' (4.6: ) + $3 = nterm exp (4.8-9: -1) +-> $$ = nterm exp (4.1-9: -1) +Entering state 8 +Next token is token '\n' (4.10-5.0: ) +Shifting token '\n' (4.10-5.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (4.1-9: -1) + $2 = token '\n' (4.10-5.0: ) +-> $$ = nterm line (4.1-5.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-4.0: ) + $2 = nterm line (4.1-5.0: ) +-> $$ = nterm input (1.1-5.0: ) +Entering state 6 +Reading a token +Next token is token '(' (5.1: ) +Shifting token '(' (5.1: ) Entering state 4 Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) +Next token is token '-' (5.2: ) +Shifting token '-' (5.2: ) Entering state 2 Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Reducing stack 0 by rule 15 (line 106): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Shifting token error (1.2-4: ) -Entering state 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) +Next token is token "number" (5.3: 1) +Shifting token "number" (5.3: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (5.3: 1) +-> $$ = nterm exp (5.3: 1) +Entering state 10 Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) +Next token is token ')' (5.4: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (5.2: ) + $2 = nterm exp (5.3: 1) +-> $$ = nterm exp (5.2-3: -1) +Entering state 12 +Next token is token ')' (5.4: ) +Shifting token ')' (5.4: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (5.1: ) + $2 = nterm exp (5.2-3: -1) + $3 = token ')' (5.4: ) +-> $$ = nterm exp (5.1-4: -1) Entering state 8 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 +Next token is token '^' (5.5: ) +Shifting token '^' (5.5: ) +Entering state 23 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) +Next token is token "number" (5.6: 2) +Shifting token "number" (5.6: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (5.6: 2) +-> $$ = nterm exp (5.6: 2) +Entering state 32 +Reading a token +Next token is token '=' (5.8: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (5.1-4: -1) + $2 = token '^' (5.5: ) + $3 = nterm exp (5.6: 2) +-> $$ = nterm exp (5.1-6: 1) +Entering state 8 +Next token is token '=' (5.8: ) +Shifting token '=' (5.8: ) +Entering state 18 +Reading a token +Next token is token "number" (5.10: 1) +Shifting token "number" (5.10: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (5.10: 1) +-> $$ = nterm exp (5.10: 1) +Entering state 27 +Reading a token +Next token is token '\n' (5.11-6.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (5.1-6: 1) + $2 = token '=' (5.8: ) + $3 = nterm exp (5.10: 1) +-> $$ = nterm exp (5.1-10: 1) +Entering state 8 +Next token is token '\n' (5.11-6.0: ) +Shifting token '\n' (5.11-6.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (5.1-10: 1) + $2 = token '\n' (5.11-6.0: ) +-> $$ = nterm line (5.1-6.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-5.0: ) + $2 = nterm line (5.1-6.0: ) +-> $$ = nterm input (1.1-6.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (6.1-7.0: ) +Shifting token '\n' (6.1-7.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (6.1-7.0: ) +-> $$ = nterm line (6.1-7.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-6.0: ) + $2 = nterm line (6.1-7.0: ) +-> $$ = nterm input (1.1-7.0: ) +Entering state 6 +Reading a token +Next token is token '-' (7.1: ) +Shifting token '-' (7.1: ) +Entering state 2 +Reading a token +Next token is token '-' (7.2: ) +Shifting token '-' (7.2: ) +Entering state 2 +Reading a token +Next token is token '-' (7.3: ) +Shifting token '-' (7.3: ) +Entering state 2 +Reading a token +Next token is token "number" (7.4: 1) +Shifting token "number" (7.4: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (7.4: 1) +-> $$ = nterm exp (7.4: 1) +Entering state 10 +Reading a token +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.3: ) + $2 = nterm exp (7.4: 1) +-> $$ = nterm exp (7.3-4: -1) +Entering state 10 +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.2: ) + $2 = nterm exp (7.3-4: -1) +-> $$ = nterm exp (7.2-4: 1) +Entering state 10 +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.1: ) + $2 = nterm exp (7.2-4: 1) +-> $$ = nterm exp (7.1-4: -1) +Entering state 8 +Next token is token '=' (7.6: ) +Shifting token '=' (7.6: ) +Entering state 18 +Reading a token +Next token is token '-' (7.8: ) +Shifting token '-' (7.8: ) +Entering state 2 +Reading a token +Next token is token "number" (7.9: 1) +Shifting token "number" (7.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (7.9: 1) +-> $$ = nterm exp (7.9: 1) +Entering state 10 +Reading a token +Next token is token '\n' (7.10-8.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.8: ) + $2 = nterm exp (7.9: 1) +-> $$ = nterm exp (7.8-9: -1) +Entering state 27 +Next token is token '\n' (7.10-8.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (7.1-4: -1) + $2 = token '=' (7.6: ) + $3 = nterm exp (7.8-9: -1) +-> $$ = nterm exp (7.1-9: -1) +Entering state 8 +Next token is token '\n' (7.10-8.0: ) +Shifting token '\n' (7.10-8.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (7.1-9: -1) + $2 = token '\n' (7.10-8.0: ) +-> $$ = nterm line (7.1-8.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-7.0: ) + $2 = nterm line (7.1-8.0: ) +-> $$ = nterm input (1.1-8.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (8.1-9.0: ) +Shifting token '\n' (8.1-9.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (8.1-9.0: ) +-> $$ = nterm line (8.1-9.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-8.0: ) + $2 = nterm line (8.1-9.0: ) +-> $$ = nterm input (1.1-9.0: ) +Entering state 6 +Reading a token +Next token is token "number" (9.1: 1) +Shifting token "number" (9.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (9.1: 1) +-> $$ = nterm exp (9.1: 1) +Entering state 8 +Reading a token +Next token is token '-' (9.3: ) +Shifting token '-' (9.3: ) +Entering state 19 +Reading a token +Next token is token "number" (9.5: 2) +Shifting token "number" (9.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (9.5: 2) +-> $$ = nterm exp (9.5: 2) +Entering state 28 +Reading a token +Next token is token '-' (9.7: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (9.1: 1) + $2 = token '-' (9.3: ) + $3 = nterm exp (9.5: 2) +-> $$ = nterm exp (9.1-5: -1) +Entering state 8 +Next token is token '-' (9.7: ) +Shifting token '-' (9.7: ) +Entering state 19 +Reading a token +Next token is token "number" (9.9: 3) +Shifting token "number" (9.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (9.9: 3) +-> $$ = nterm exp (9.9: 3) +Entering state 28 +Reading a token +Next token is token '=' (9.11: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (9.1-5: -1) + $2 = token '-' (9.7: ) + $3 = nterm exp (9.9: 3) +-> $$ = nterm exp (9.1-9: -4) +Entering state 8 +Next token is token '=' (9.11: ) +Shifting token '=' (9.11: ) +Entering state 18 +Reading a token +Next token is token '-' (9.13: ) +Shifting token '-' (9.13: ) +Entering state 2 +Reading a token +Next token is token "number" (9.14: 4) +Shifting token "number" (9.14: 4) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (9.14: 4) +-> $$ = nterm exp (9.14: 4) +Entering state 10 +Reading a token +Next token is token '\n' (9.15-10.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (9.13: ) + $2 = nterm exp (9.14: 4) +-> $$ = nterm exp (9.13-14: -4) +Entering state 27 +Next token is token '\n' (9.15-10.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (9.1-9: -4) + $2 = token '=' (9.11: ) + $3 = nterm exp (9.13-14: -4) +-> $$ = nterm exp (9.1-14: -4) +Entering state 8 +Next token is token '\n' (9.15-10.0: ) +Shifting token '\n' (9.15-10.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (9.1-14: -4) + $2 = token '\n' (9.15-10.0: ) +-> $$ = nterm line (9.1-10.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-9.0: ) + $2 = nterm line (9.1-10.0: ) +-> $$ = nterm input (1.1-10.0: ) +Entering state 6 +Reading a token +Next token is token "number" (10.1: 1) +Shifting token "number" (10.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (10.1: 1) +-> $$ = nterm exp (10.1: 1) +Entering state 8 +Reading a token +Next token is token '-' (10.3: ) +Shifting token '-' (10.3: ) +Entering state 19 +Reading a token +Next token is token '(' (10.5: ) +Shifting token '(' (10.5: ) Entering state 4 Reading a token -Next token is token "number" (1.10: 1) -Shifting token "number" (1.10: 1) +Next token is token "number" (10.6: 2) +Shifting token "number" (10.6: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.10: 1) --> $$ = nterm exp (1.10: 1) + $1 = token "number" (10.6: 2) +-> $$ = nterm exp (10.6: 2) Entering state 12 Reading a token -Next token is token "number" (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Shifting token error (1.10-12: ) -Entering state 11 -Next token is token "number" (1.12: 2) -Error: discarding token "number" (1.12: 2) +Next token is token '-' (10.8: ) +Shifting token '-' (10.8: ) +Entering state 19 Reading a token -Next token is token ')' (1.13: ) -Entering state 11 -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) -Entering state 29 +Next token is token "number" (10.10: 3) +Shifting token "number" (10.10: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (10.10: 3) +-> $$ = nterm exp (10.10: 3) +Entering state 28 Reading a token -Next token is token '=' (1.15: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) +Next token is token ')' (10.11: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (10.6: 2) + $2 = token '-' (10.8: ) + $3 = nterm exp (10.10: 3) +-> $$ = nterm exp (10.6-10: -1) +Entering state 12 +Next token is token ')' (10.11: ) +Shifting token ')' (10.11: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (10.5: ) + $2 = nterm exp (10.6-10: -1) + $3 = token ')' (10.11: ) +-> $$ = nterm exp (10.5-11: -1) +Entering state 28 +Reading a token +Next token is token '=' (10.13: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (10.1: 1) + $2 = token '-' (10.3: ) + $3 = nterm exp (10.5-11: -1) +-> $$ = nterm exp (10.1-11: 2) Entering state 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) +Next token is token '=' (10.13: ) +Shifting token '=' (10.13: ) Entering state 18 Reading a token -Next token is token "number" (1.17: 1) -Shifting token "number" (1.17: 1) +Next token is token "number" (10.15: 2) +Shifting token "number" (10.15: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.17: 1) --> $$ = nterm exp (1.17: 1) + $1 = token "number" (10.15: 2) +-> $$ = nterm exp (10.15: 2) Entering state 27 Reading a token -Next token is token '\n' (1.18-2.0: ) +Next token is token '\n' (10.16-11.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) + $1 = nterm exp (10.1-11: 2) + $2 = token '=' (10.13: ) + $3 = nterm exp (10.15: 2) +-> $$ = nterm exp (10.1-15: 2) Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (10.16-11.0: ) +Shifting token '\n' (10.16-11.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) + $1 = nterm exp (10.1-15: 2) + $2 = token '\n' (10.16-11.0: ) +-> $$ = nterm line (10.1-11.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-10.0: ) + $2 = nterm line (10.1-11.0: ) +-> $$ = nterm input (1.1-11.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (11.1-12.0: ) +Shifting token '\n' (11.1-12.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (11.1-12.0: ) +-> $$ = nterm line (11.1-12.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-11.0: ) + $2 = nterm line (11.1-12.0: ) +-> $$ = nterm input (1.1-12.0: ) +Entering state 6 +Reading a token +Next token is token "number" (12.1: 2) +Shifting token "number" (12.1: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (12.1: 2) +-> $$ = nterm exp (12.1: 2) +Entering state 8 +Reading a token +Next token is token '^' (12.2: ) +Shifting token '^' (12.2: ) +Entering state 23 +Reading a token +Next token is token "number" (12.3: 2) +Shifting token "number" (12.3: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (12.3: 2) +-> $$ = nterm exp (12.3: 2) +Entering state 32 +Reading a token +Next token is token '^' (12.4: ) +Shifting token '^' (12.4: ) +Entering state 23 +Reading a token +Next token is token "number" (12.5: 3) +Shifting token "number" (12.5: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (12.5: 3) +-> $$ = nterm exp (12.5: 3) +Entering state 32 +Reading a token +Next token is token '=' (12.7: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (12.3: 2) + $2 = token '^' (12.4: ) + $3 = nterm exp (12.5: 3) +-> $$ = nterm exp (12.3-5: 8) +Entering state 32 +Next token is token '=' (12.7: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (12.1: 2) + $2 = token '^' (12.2: ) + $3 = nterm exp (12.3-5: 8) +-> $$ = nterm exp (12.1-5: 256) +Entering state 8 +Next token is token '=' (12.7: ) +Shifting token '=' (12.7: ) +Entering state 18 +Reading a token +Next token is token "number" (12.9-11: 256) +Shifting token "number" (12.9-11: 256) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (12.9-11: 256) +-> $$ = nterm exp (12.9-11: 256) +Entering state 27 +Reading a token +Next token is token '\n' (12.12-13.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (12.1-5: 256) + $2 = token '=' (12.7: ) + $3 = nterm exp (12.9-11: 256) +-> $$ = nterm exp (12.1-11: 256) +Entering state 8 +Next token is token '\n' (12.12-13.0: ) +Shifting token '\n' (12.12-13.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (12.1-11: 256) + $2 = token '\n' (12.12-13.0: ) +-> $$ = nterm line (12.1-13.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-12.0: ) + $2 = nterm line (12.1-13.0: ) +-> $$ = nterm input (1.1-13.0: ) +Entering state 6 +Reading a token +Next token is token '(' (13.1: ) +Shifting token '(' (13.1: ) +Entering state 4 +Reading a token +Next token is token "number" (13.2: 2) +Shifting token "number" (13.2: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (13.2: 2) +-> $$ = nterm exp (13.2: 2) +Entering state 12 +Reading a token +Next token is token '^' (13.3: ) +Shifting token '^' (13.3: ) +Entering state 23 +Reading a token +Next token is token "number" (13.4: 2) +Shifting token "number" (13.4: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (13.4: 2) +-> $$ = nterm exp (13.4: 2) +Entering state 32 +Reading a token +Next token is token ')' (13.5: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (13.2: 2) + $2 = token '^' (13.3: ) + $3 = nterm exp (13.4: 2) +-> $$ = nterm exp (13.2-4: 4) +Entering state 12 +Next token is token ')' (13.5: ) +Shifting token ')' (13.5: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (13.1: ) + $2 = nterm exp (13.2-4: 4) + $3 = token ')' (13.5: ) +-> $$ = nterm exp (13.1-5: 4) +Entering state 8 +Reading a token +Next token is token '^' (13.6: ) +Shifting token '^' (13.6: ) +Entering state 23 +Reading a token +Next token is token "number" (13.7: 3) +Shifting token "number" (13.7: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (13.7: 3) +-> $$ = nterm exp (13.7: 3) +Entering state 32 +Reading a token +Next token is token '=' (13.9: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (13.1-5: 4) + $2 = token '^' (13.6: ) + $3 = nterm exp (13.7: 3) +-> $$ = nterm exp (13.1-7: 64) +Entering state 8 +Next token is token '=' (13.9: ) +Shifting token '=' (13.9: ) +Entering state 18 +Reading a token +Next token is token "number" (13.11-12: 64) +Shifting token "number" (13.11-12: 64) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (13.11-12: 64) +-> $$ = nterm exp (13.11-12: 64) +Entering state 27 +Reading a token +Next token is token '\n' (13.13-14.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (13.1-7: 64) + $2 = token '=' (13.9: ) + $3 = nterm exp (13.11-12: 64) +-> $$ = nterm exp (13.1-12: 64) +Entering state 8 +Next token is token '\n' (13.13-14.0: ) +Shifting token '\n' (13.13-14.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (13.1-12: 64) + $2 = token '\n' (13.13-14.0: ) +-> $$ = nterm line (13.1-14.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-13.0: ) + $2 = nterm line (13.1-14.0: ) +-> $$ = nterm input (1.1-14.0: ) Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) +Shifting token "end of input" (14.1: ) Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1492: cat stderr +Cleanup: popping token "end of input" (14.1: ) +Cleanup: popping nterm input (1.1-14.0: ) +./torture.at:535: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +input: stderr: -567. calc.at:1492: ok input: Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Reducing stack 0 by rule 15 (line 106): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Shifting token error (1.2-4: ) -Entering state 11 -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token number (1.3: 2) + | (1 + # + 1) = 1111 + | 1 2 +./calc.at:1492: $PREPARSER ./calc input +./calc.at:1494: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.10: 1) --> $$ = nterm exp (1.10: 1) + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token -Next token is token number (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Shifting token error (1.10-12: ) -Entering state 11 -Next token is token number (1.12: 2) -Error: discarding token number (1.12: 2) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 Reading a token -Next token is token ')' (1.13: ) +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) Entering state 11 -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) -Entering state 29 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) Reading a token -Next token is token '=' (1.15: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Reading a token +Next token is token "number" (1.10: 1) +Error: discarding token "number" (1.10: 1) +Reading a token +Next token is token ')' (1.11: ) +Entering state 11 +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) Entering state 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) +Reading a token +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) Entering state 18 Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) +Next token is token "number" (1.15-18: 1111) +Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.17: 1) --> $$ = nterm exp (1.17: 1) + $1 = token "number" (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token -Next token is token '\n' (1.18-2.0: ) +Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2222) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -237375,12 +232725,12 @@ Entering state 6 Reading a token Now at end of input. -Shifting token end of input (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token end of input (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | error -./calc.at:1494: "$PERL" -pi -e 'use strict; +stderr: +./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -237390,10 +232740,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1492: $PREPARSER ./calc input -./calc.at:1494: cat stderr -stderr: -./calc.at:1491: "$PERL" -pi -e 'use strict; +./calc.at:1489: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -237403,43 +232750,27 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror Starting parse Entering state 0 Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token "number" (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token "number" (1.3: 2) ./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1491: cat stderr - -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) -input: -input: - | (* *) + (*) + (*) -./calc.at:1491: $PREPARSER ./calc input - | (* *) + (*) + (*) -stderr: -./calc.at:1494: $PREPARSER ./calc input -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1489: cat stderr stderr: -stdout: stderr: Starting parse Entering state 0 @@ -237448,42 +232779,32 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 Reading a token -Next token is token ')' (1.5: ) +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) -Entering state 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) +Next token is token "number" (1.10: 1) +Error: discarding token "number" (1.10: 1) Reading a token Next token is token ')' (1.11: ) Entering state 11 @@ -237491,59 +232812,37 @@ Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) -Entering state 29 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) +-> $$ = nterm exp (1.1-11: 1111) Entering state 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 20 -Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) +Entering state 18 Reading a token -Next token is token ')' (1.17: ) -Entering state 11 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 29 +Next token is token "number" (1.15-18: 1111) +Shifting token "number" (1.15-18: 1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) +Entering state 27 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) +Next token is token '\n' (1.19-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -237552,115 +232851,202 @@ Entering state 6 Reading a token Now at end of input. -Shifting token end of input (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token end of input (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./torture.at:497: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 20 +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token "number" (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token "number" (1.3: 2) +564. calc.at:1489: ok +input: + | 1//2 +./calc.at:1491: $PREPARSER ./calc input stderr: -./calc.at:1492: cat stderr +./calc.at:1492: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 22 Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '/' (1.3: ) +./calc.at:1492: cat stderr +./calc.at:1494: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1494: cat stderr +input: +stderr: + | (1 + 1) / (1 - 1) +./calc.at:1492: $PREPARSER ./calc input +Starting parse +Entering state 0 Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 22 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '/' (1.3: ) + +input: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) -Entering state 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 Reading a token -Next token is token ')' (1.11: ) -Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Reading a token +Next token is token "number" (1.6: 1) +Shifting token "number" (1.6: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.6: 1) +-> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token -Next token is token '+' (1.13: ) +Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) Entering state 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 20 Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 22 +Reading a token +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) Entering state 4 Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) +Next token is token "number" (1.12: 1) +Shifting token "number" (1.12: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 19 +Reading a token +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 Reading a token Next token is token ')' (1.17: ) -Entering state 11 +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 29 +-> $$ = nterm exp (1.11-17: 0) +Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) +Reducing stack 0 by rule 10 (line 93): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 3333) + $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 @@ -237674,20 +233060,77 @@ Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./torture.at:538: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 20 + | 1//2 +./calc.at:1494: $PREPARSER ./calc input stderr: -./torture.at:497: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +input.y:66.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:170.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:175.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:180.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:188.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:202.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:207.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:221.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:300.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:323.10: error: empty rule without %empty [-Werror=empty-rule] +input.y: error: 65 shift/reduce conflicts [-Werror=conflicts-sr] +input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +input.y:39.1-5: error: useless associativity for FUNC_CALL, use %precedence [-Werror=precedence] +input.y:44.1-5: error: useless associativity for YNUMBER, use %precedence [-Werror=precedence] +input.y:44.1-5: error: useless associativity for YSTRING, use %precedence [-Werror=precedence] +input.y:42.1-9: error: useless precedence and associativity for APPEND_OP [-Werror=precedence] +input.y:33.1-6: error: useless associativity for ASSIGNOP, use %precedence [-Werror=precedence] +input.y:43.1-5: error: useless associativity for CONCAT_OP, use %precedence [-Werror=precedence] +input.y:37.1-5: error: useless precedence and associativity for LEX_GETLINE [-Werror=precedence] +input.y:38.1-9: error: useless associativity for LEX_IN, use %precedence [-Werror=precedence] +input.y:49.1-5: error: useless associativity for INCREMENT, use %precedence [-Werror=precedence] +input.y:49.1-5: error: useless associativity for DECREMENT, use %precedence [-Werror=precedence] +input.y:39.1-5: error: useless associativity for LEX_BUILTIN, use %precedence [-Werror=precedence] +input.y:39.1-5: error: useless associativity for LEX_LENGTH, use %precedence [-Werror=precedence] +input.y:40.1-9: error: useless precedence and associativity for ',' [-Werror=precedence] +input.y:47.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] +input.y:47.1-6: error: useless associativity for UNARY, use %precedence [-Werror=precedence] +input.y:50.1-5: error: useless associativity for '$', use %precedence [-Werror=precedence] +input.y:51.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] +input.y:51.1-5: error: useless precedence and associativity for ')' [-Werror=precedence] +input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 22 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '/' (1.3: ) +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1491: cat stderr +./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./torture.at:538: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: +stdout: stderr: -618. existing.at:74: testing GNU AWK 3.1.0 Grammar: Canonical LR(1) ... -./torture.at:541: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 900 Starting parse Entering state 0 Reading a token @@ -237695,101 +233138,101 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) -Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) Entering state 20 Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) -Entering state 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) -Reading a token -Next token is token ')' (1.11: ) -Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) +Next token is token "number" (1.6: 1) +Shifting token "number" (1.6: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.6: 1) +-> $$ = nterm exp (1.6: 1) Entering state 29 Reading a token -Next token is token '+' (1.13: ) +Next token is token ')' (1.7: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) Entering state 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 20 Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 22 +Reading a token +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) Entering state 4 Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) +Next token is token "number" (1.12: 1) +Shifting token "number" (1.12: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 19 +Reading a token +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 Reading a token Next token is token ')' (1.17: ) -Entering state 11 +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 29 +-> $$ = nterm exp (1.11-17: 0) +Entering state 31 Reading a token Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) +Reducing stack 0 by rule 10 (line 93): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 3333) + $1 = nterm exp (1.1-17: 2) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 @@ -237803,162 +233246,142 @@ Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | 1 = 2 = 3 -./calc.at:1492: $PREPARSER ./calc input +./torture.at:497: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 20 +stderr: stderr: +./existing.at:74: sed 's,.*/$,,' stderr 1>&2 Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -Next token is token '*' (1.2: ) -1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.2: ) -Entering state 11 -Next token is token '*' (1.2: ) -Error: discarding token '*' (1.2: ) -Reading a token -Next token is token '*' (1.4: ) -Error: discarding token '*' (1.4: ) -Reading a token -Next token is token ')' (1.5: ) -Entering state 11 -Next token is token ')' (1.5: ) -Shifting token ')' (1.5: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-4: ) - $3 = token ')' (1.5: ) --> $$ = nterm exp (1.1-5: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.7: ) -Shifting token '+' (1.7: ) -Entering state 20 -Reading a token -Next token is token '(' (1.9: ) -Shifting token '(' (1.9: ) -Entering state 4 -Reading a token -Next token is token '*' (1.10: ) -1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.10: ) -Entering state 11 -Next token is token '*' (1.10: ) -Error: discarding token '*' (1.10: ) -Reading a token -Next token is token ')' (1.11: ) -Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.9: ) - $2 = token error (1.10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.9-11: 1111) -Entering state 29 -Reading a token -Next token is token '+' (1.13: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-5: 1111) - $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-11: 1111) --> $$ = nterm exp (1.1-11: 2222) +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 -Next token is token '+' (1.13: ) -Shifting token '+' (1.13: ) -Entering state 20 Reading a token -Next token is token '(' (1.15: ) -Shifting token '(' (1.15: ) -Entering state 4 +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 22 Reading a token -Next token is token '*' (1.16: ) -1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.16: ) -Entering state 11 -Next token is token '*' (1.16: ) -Error: discarding token '*' (1.16: ) +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '/' (1.3: ) +./torture.at:497: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +617. existing.at:74: testing GNU AWK 3.1.0 Grammar: IELR(1) ... +./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y + | error +./calc.at:1491: $PREPARSER ./calc input +./calc.at:1492: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error +stderr: +stderr: +Starting parse +Entering state 0 Reading a token -Next token is token ')' (1.17: ) -Entering state 11 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.15: ) - $2 = token error (1.16: ) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.15-17: 1111) -Entering state 29 +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) +./torture.at:500: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 900 +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1494: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1492: cat stderr +./torture.at:500: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1494: cat stderr +stderr: +567. calc.at:1492: Starting parse +Entering state 0 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-11: 2222) - $2 = token '+' (1.13: ) - $3 = nterm exp (1.15-17: 1111) --> $$ = nterm exp (1.1-17: 3333) -Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 3333) - $2 = token '\n' (1.18-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) + ok +./torture.at:504: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 10000 +stderr: +memory exhausted +memory exhausted +./torture.at:504: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: + | error +./calc.at:1494: $PREPARSER ./calc input +memory exhausted +memory exhausted + +./torture.at:510: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +stderr: +./calc.at:1491: cat stderr +Starting parse +Entering state 0 Reading a token -Now at end of input. -Shifting token end of input (2.1: ) -Entering state 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) +Next token is token "invalid token" (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" (1.1: ) stderr: +./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./torture.at:541: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./torture.at:500: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 900 -./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -input.y:66.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:170.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:175.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:180.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:188.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:202.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:207.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:221.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:300.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:323.10: error: empty rule without %empty [-Werror=empty-rule] -input.y: error: 65 shift/reduce conflicts [-Werror=conflicts-sr] -input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -input.y:39.1-5: error: useless associativity for FUNC_CALL, use %precedence [-Werror=precedence] -input.y:44.1-5: error: useless associativity for YNUMBER, use %precedence [-Werror=precedence] -input.y:44.1-5: error: useless associativity for YSTRING, use %precedence [-Werror=precedence] -input.y:42.1-9: error: useless precedence and associativity for APPEND_OP [-Werror=precedence] -input.y:33.1-6: error: useless associativity for ASSIGNOP, use %precedence [-Werror=precedence] -input.y:43.1-5: error: useless associativity for CONCAT_OP, use %precedence [-Werror=precedence] -input.y:37.1-5: error: useless precedence and associativity for LEX_GETLINE [-Werror=precedence] -input.y:38.1-9: error: useless associativity for LEX_IN, use %precedence [-Werror=precedence] -input.y:49.1-5: error: useless associativity for INCREMENT, use %precedence [-Werror=precedence] -input.y:49.1-5: error: useless associativity for DECREMENT, use %precedence [-Werror=precedence] -input.y:39.1-5: error: useless associativity for LEX_BUILTIN, use %precedence [-Werror=precedence] -input.y:39.1-5: error: useless associativity for LEX_LENGTH, use %precedence [-Werror=precedence] -input.y:40.1-9: error: useless precedence and associativity for ',' [-Werror=precedence] -input.y:47.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] -input.y:47.1-6: error: useless associativity for UNARY, use %precedence [-Werror=precedence] -input.y:50.1-5: error: useless associativity for '$', use %precedence [-Werror=precedence] -input.y:51.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] -input.y:51.1-5: error: useless precedence and associativity for ')' [-Werror=precedence] -input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] +stdout: +stdout: +stderr: +input: +./torture.at:538: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 20 +Starting parse +Entering state 0 +Reading a token +Next token is token "invalid token" (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token "invalid token" (1.1: ) stderr: +./calc.at:1492: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc calc.hh + + | 1 = 2 = 3 +./calc.at:1491: $PREPARSER ./calc input +./torture.at:538: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +input: Starting parse Entering state 0 Reading a token @@ -237988,6 +233411,7 @@ Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) +./torture.at:510: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} @@ -237999,29 +233423,28 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./torture.at:500: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./torture.at:545: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 10000 -./calc.at:1491: cat stderr -stderr: +./torture.at:541: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 900 +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror +./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none stderr: -./existing.at:74: sed 's,.*/$,,' stderr 1>&2 + | 1 + 2 * 3 = 7 + | 1 + 2 * -3 = -5 + | + | -1^2 = -1 + | (-1)^2 = 1 + | + | ---1 = -1 + | + | 1 - 2 - 3 = -4 + | 1 - (2 - 3) = 2 + | + | 2^2^3 = 256 + | (2^2)^3 = 64 +./calc.at:1492: $PREPARSER ./calc input ./calc.at:1494: cat stderr +./torture.at:541: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -memory exhausted -memory exhausted -./torture.at:545: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./torture.at:504: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 10000 stderr: Starting parse Entering state 0 @@ -238052,76 +233475,14 @@ Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) Cleanup: discarding lookahead token '=' (1.7: ) -input.y:66.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:170.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:175.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:180.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:188.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:202.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:207.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:221.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:300.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:323.10: error: empty rule without %empty [-Werror=empty-rule] -input.y: error: 65 shift/reduce conflicts [-Werror=conflicts-sr] -input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -input.y:39.1-5: error: useless associativity for FUNC_CALL, use %precedence [-Werror=precedence] -input.y:44.1-5: error: useless associativity for YNUMBER, use %precedence [-Werror=precedence] -input.y:44.1-5: error: useless associativity for YSTRING, use %precedence [-Werror=precedence] -input.y:42.1-9: error: useless precedence and associativity for APPEND_OP [-Werror=precedence] -input.y:33.1-6: error: useless associativity for ASSIGNOP, use %precedence [-Werror=precedence] -input.y:43.1-5: error: useless associativity for CONCAT_OP, use %precedence [-Werror=precedence] -input.y:37.1-5: error: useless precedence and associativity for LEX_GETLINE [-Werror=precedence] -input.y:38.1-9: error: useless associativity for LEX_IN, use %precedence [-Werror=precedence] -input.y:49.1-5: error: useless associativity for INCREMENT, use %precedence [-Werror=precedence] -input.y:49.1-5: error: useless associativity for DECREMENT, use %precedence [-Werror=precedence] -input.y:39.1-5: error: useless associativity for LEX_BUILTIN, use %precedence [-Werror=precedence] -input.y:39.1-5: error: useless associativity for LEX_LENGTH, use %precedence [-Werror=precedence] -input.y:40.1-9: error: useless precedence and associativity for ',' [-Werror=precedence] -input.y:47.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] -input.y:47.1-6: error: useless associativity for UNARY, use %precedence [-Werror=precedence] -input.y:50.1-5: error: useless associativity for '$', use %precedence [-Werror=precedence] -input.y:51.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] -input.y:51.1-5: error: useless precedence and associativity for ')' [-Werror=precedence] -input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] -stderr: -./existing.at:74: sed 's,.*/$,,' stderr 1>&2 -input: -memory exhausted -memory exhausted -./torture.at:504: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input: - | 1 + 2 * 3 + !+ ++ -./calc.at:1491: $PREPARSER ./calc input - | 1 + 2 * 3 + !+ ++ -./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error -stderr: -./calc.at:1494: $PREPARSER ./calc input -./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error -memory exhausted -memory exhausted -stderr: -stderr: -stderr: -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -memory exhausted -memory exhausted Starting parse Entering state 0 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) + $1 = token number (1.1: 1) -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token @@ -238129,11 +233490,11 @@ Shifting token '+' (1.3: ) Entering state 20 Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.5: 2) + $1 = token number (1.5: 2) -> $$ = nterm exp (1.5: 2) Entering state 29 Reading a token @@ -238141,114 +233502,823 @@ Shifting token '*' (1.7: ) Entering state 21 Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.9: 3) + $1 = token number (1.9: 3) -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token -Next token is token '+' (1.11: ) +Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 -Next token is token '+' (1.11: ) +Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 20 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 18 Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 +Next token is token number (1.13: 7) +Shifting token number (1.13: 7) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.13: 7) +-> $$ = nterm exp (1.13: 7) +Entering state 27 Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Reducing stack 0 by rule 17 (line 108): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -Starting parse -Entering state 0 +Next token is token '\n' (1.14-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-9: 7) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13: 7) +-> $$ = nterm exp (1.1-13: 7) +Entering state 8 +Next token is token '\n' (1.14-2.0: ) +Shifting token '\n' (1.14-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-13: 7) + $2 = token '\n' (1.14-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token number (2.1: 1) +Shifting token number (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) + $1 = token number (2.1: 1) +-> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) +Next token is token '+' (2.3: ) +Shifting token '+' (2.3: ) Entering state 20 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token number (2.5: 2) +Shifting token number (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) + $1 = token number (2.5: 2) +-> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) +Next token is token '*' (2.7: ) +Shifting token '*' (2.7: ) Entering state 21 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token '-' (2.9: ) +Shifting token '-' (2.9: ) +Entering state 2 +Reading a token +Next token is token number (2.10: 3) +Shifting token number (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 + $1 = token number (2.10: 3) +-> $$ = nterm exp (2.10: 3) +Entering state 10 Reading a token -Next token is token '+' (1.11: ) +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (2.9: ) + $2 = nterm exp (2.10: 3) +-> $$ = nterm exp (2.9-10: -3) +Entering state 30 +Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) + $1 = nterm exp (2.5: 2) + $2 = token '*' (2.7: ) + $3 = nterm exp (2.9-10: -3) +-> $$ = nterm exp (2.5-10: -6) Entering state 29 -Next token is token '+' (1.11: ) +Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) + $1 = nterm exp (2.1: 1) + $2 = token '+' (2.3: ) + $3 = nterm exp (2.5-10: -6) +-> $$ = nterm exp (2.1-10: -5) Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 20 +Next token is token '=' (2.12: ) +Shifting token '=' (2.12: ) +Entering state 18 Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 +Next token is token '-' (2.14: ) +Shifting token '-' (2.14: ) +Entering state 2 Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Reducing stack 0 by rule 17 (line 108): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./torture.at:548: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./torture.at:510: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./calc.at:1492: cat stderr +Next token is token number (2.15: 5) +Shifting token number (2.15: 5) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2.15: 5) +-> $$ = nterm exp (2.15: 5) +Entering state 10 +Reading a token +Next token is token '\n' (2.16-3.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (2.14: ) + $2 = nterm exp (2.15: 5) +-> $$ = nterm exp (2.14-15: -5) +Entering state 27 +Next token is token '\n' (2.16-3.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2.1-10: -5) + $2 = token '=' (2.12: ) + $3 = nterm exp (2.14-15: -5) +-> $$ = nterm exp (2.1-15: -5) +Entering state 8 +Next token is token '\n' (2.16-3.0: ) +Shifting token '\n' (2.16-3.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2.1-15: -5) + $2 = token '\n' (2.16-3.0: ) +-> $$ = nterm line (2.1-3.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-2.0: ) + $2 = nterm line (2.1-3.0: ) +-> $$ = nterm input (1.1-3.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (3.1-4.0: ) +Shifting token '\n' (3.1-4.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (3.1-4.0: ) +-> $$ = nterm line (3.1-4.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-3.0: ) + $2 = nterm line (3.1-4.0: ) +-> $$ = nterm input (1.1-4.0: ) +Entering state 6 +Reading a token +Next token is token '-' (4.1: ) +Shifting token '-' (4.1: ) +Entering state 2 +Reading a token +Next token is token number (4.2: 1) +Shifting token number (4.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (4.2: 1) +-> $$ = nterm exp (4.2: 1) +Entering state 10 +Reading a token +Next token is token '^' (4.3: ) +Shifting token '^' (4.3: ) +Entering state 23 +Reading a token +Next token is token number (4.4: 2) +Shifting token number (4.4: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (4.4: 2) +-> $$ = nterm exp (4.4: 2) +Entering state 32 +Reading a token +Next token is token '=' (4.6: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (4.2: 1) + $2 = token '^' (4.3: ) + $3 = nterm exp (4.4: 2) +-> $$ = nterm exp (4.2-4: 1) +Entering state 10 +Next token is token '=' (4.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (4.1: ) + $2 = nterm exp (4.2-4: 1) +-> $$ = nterm exp (4.1-4: -1) +Entering state 8 +Next token is token '=' (4.6: ) +Shifting token '=' (4.6: ) +Entering state 18 +Reading a token +Next token is token '-' (4.8: ) +Shifting token '-' (4.8: ) +Entering state 2 +Reading a token +Next token is token number (4.9: 1) +Shifting token number (4.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (4.9: 1) +-> $$ = nterm exp (4.9: 1) +Entering state 10 +Reading a token +Next token is token '\n' (4.10-5.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (4.8: ) + $2 = nterm exp (4.9: 1) +-> $$ = nterm exp (4.8-9: -1) +Entering state 27 +Next token is token '\n' (4.10-5.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (4.1-4: -1) + $2 = token '=' (4.6: ) + $3 = nterm exp (4.8-9: -1) +-> $$ = nterm exp (4.1-9: -1) +Entering state 8 +Next token is token '\n' (4.10-5.0: ) +Shifting token '\n' (4.10-5.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (4.1-9: -1) + $2 = token '\n' (4.10-5.0: ) +-> $$ = nterm line (4.1-5.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-4.0: ) + $2 = nterm line (4.1-5.0: ) +-> $$ = nterm input (1.1-5.0: ) +Entering state 6 +Reading a token +Next token is token '(' (5.1: ) +Shifting token '(' (5.1: ) +Entering state 4 +Reading a token +Next token is token '-' (5.2: ) +Shifting token '-' (5.2: ) +Entering state 2 +Reading a token +Next token is token number (5.3: 1) +Shifting token number (5.3: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (5.3: 1) +-> $$ = nterm exp (5.3: 1) +Entering state 10 +Reading a token +Next token is token ')' (5.4: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (5.2: ) + $2 = nterm exp (5.3: 1) +-> $$ = nterm exp (5.2-3: -1) +Entering state 12 +Next token is token ')' (5.4: ) +Shifting token ')' (5.4: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (5.1: ) + $2 = nterm exp (5.2-3: -1) + $3 = token ')' (5.4: ) +-> $$ = nterm exp (5.1-4: -1) +Entering state 8 +Reading a token +Next token is token '^' (5.5: ) +Shifting token '^' (5.5: ) +Entering state 23 +Reading a token +Next token is token number (5.6: 2) +Shifting token number (5.6: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (5.6: 2) +-> $$ = nterm exp (5.6: 2) +Entering state 32 +Reading a token +Next token is token '=' (5.8: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (5.1-4: -1) + $2 = token '^' (5.5: ) + $3 = nterm exp (5.6: 2) +-> $$ = nterm exp (5.1-6: 1) +Entering state 8 +Next token is token '=' (5.8: ) +Shifting token '=' (5.8: ) +Entering state 18 +Reading a token +Next token is token number (5.10: 1) +Shifting token number (5.10: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (5.10: 1) +-> $$ = nterm exp (5.10: 1) +Entering state 27 +Reading a token +Next token is token '\n' (5.11-6.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (5.1-6: 1) + $2 = token '=' (5.8: ) + $3 = nterm exp (5.10: 1) +-> $$ = nterm exp (5.1-10: 1) +Entering state 8 +Next token is token '\n' (5.11-6.0: ) +Shifting token '\n' (5.11-6.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (5.1-10: 1) + $2 = token '\n' (5.11-6.0: ) +-> $$ = nterm line (5.1-6.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-5.0: ) + $2 = nterm line (5.1-6.0: ) +-> $$ = nterm input (1.1-6.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (6.1-7.0: ) +Shifting token '\n' (6.1-7.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (6.1-7.0: ) +-> $$ = nterm line (6.1-7.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-6.0: ) + $2 = nterm line (6.1-7.0: ) +-> $$ = nterm input (1.1-7.0: ) +Entering state 6 +Reading a token +Next token is token '-' (7.1: ) +Shifting token '-' (7.1: ) +Entering state 2 +Reading a token +Next token is token '-' (7.2: ) +Shifting token '-' (7.2: ) +Entering state 2 +Reading a token +Next token is token '-' (7.3: ) +Shifting token '-' (7.3: ) +Entering state 2 +Reading a token +Next token is token number (7.4: 1) +Shifting token number (7.4: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (7.4: 1) +-> $$ = nterm exp (7.4: 1) +Entering state 10 +Reading a token +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.3: ) + $2 = nterm exp (7.4: 1) +-> $$ = nterm exp (7.3-4: -1) +Entering state 10 +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.2: ) + $2 = nterm exp (7.3-4: -1) +-> $$ = nterm exp (7.2-4: 1) +Entering state 10 +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.1: ) + $2 = nterm exp (7.2-4: 1) +-> $$ = nterm exp (7.1-4: -1) +Entering state 8 +Next token is token '=' (7.6: ) +Shifting token '=' (7.6: ) +Entering state 18 +Reading a token +Next token is token '-' (7.8: ) +Shifting token '-' (7.8: ) +Entering state 2 +Reading a token +Next token is token number (7.9: 1) +Shifting token number (7.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (7.9: 1) +-> $$ = nterm exp (7.9: 1) +Entering state 10 +Reading a token +Next token is token '\n' (7.10-8.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.8: ) + $2 = nterm exp (7.9: 1) +-> $$ = nterm exp (7.8-9: -1) +Entering state 27 +Next token is token '\n' (7.10-8.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (7.1-4: -1) + $2 = token '=' (7.6: ) + $3 = nterm exp (7.8-9: -1) +-> $$ = nterm exp (7.1-9: -1) +Entering state 8 +Next token is token '\n' (7.10-8.0: ) +Shifting token '\n' (7.10-8.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (7.1-9: -1) + $2 = token '\n' (7.10-8.0: ) +-> $$ = nterm line (7.1-8.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-7.0: ) + $2 = nterm line (7.1-8.0: ) +-> $$ = nterm input (1.1-8.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (8.1-9.0: ) +Shifting token '\n' (8.1-9.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (8.1-9.0: ) +-> $$ = nterm line (8.1-9.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-8.0: ) + $2 = nterm line (8.1-9.0: ) +-> $$ = nterm input (1.1-9.0: ) +Entering state 6 +Reading a token +Next token is token number (9.1: 1) +Shifting token number (9.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (9.1: 1) +-> $$ = nterm exp (9.1: 1) +Entering state 8 +Reading a token +Next token is token '-' (9.3: ) +Shifting token '-' (9.3: ) +Entering state 19 +Reading a token +Next token is token number (9.5: 2) +Shifting token number (9.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (9.5: 2) +-> $$ = nterm exp (9.5: 2) +Entering state 28 +Reading a token +Next token is token '-' (9.7: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (9.1: 1) + $2 = token '-' (9.3: ) + $3 = nterm exp (9.5: 2) +-> $$ = nterm exp (9.1-5: -1) +Entering state 8 +Next token is token '-' (9.7: ) +Shifting token '-' (9.7: ) +Entering state 19 +Reading a token +Next token is token number (9.9: 3) +Shifting token number (9.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (9.9: 3) +-> $$ = nterm exp (9.9: 3) +Entering state 28 +Reading a token +Next token is token '=' (9.11: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (9.1-5: -1) + $2 = token '-' (9.7: ) + $3 = nterm exp (9.9: 3) +-> $$ = nterm exp (9.1-9: -4) +Entering state 8 +Next token is token '=' (9.11: ) +Shifting token '=' (9.11: ) +Entering state 18 +Reading a token +Next token is token '-' (9.13: ) +Shifting token '-' (9.13: ) +Entering state 2 +Reading a token +Next token is token number (9.14: 4) +Shifting token number (9.14: 4) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (9.14: 4) +-> $$ = nterm exp (9.14: 4) +Entering state 10 +Reading a token +Next token is token '\n' (9.15-10.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (9.13: ) + $2 = nterm exp (9.14: 4) +-> $$ = nterm exp (9.13-14: -4) +Entering state 27 +Next token is token '\n' (9.15-10.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (9.1-9: -4) + $2 = token '=' (9.11: ) + $3 = nterm exp (9.13-14: -4) +-> $$ = nterm exp (9.1-14: -4) +Entering state 8 +Next token is token '\n' (9.15-10.0: ) +Shifting token '\n' (9.15-10.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (9.1-14: -4) + $2 = token '\n' (9.15-10.0: ) +-> $$ = nterm line (9.1-10.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-9.0: ) + $2 = nterm line (9.1-10.0: ) +-> $$ = nterm input (1.1-10.0: ) +Entering state 6 +Reading a token +Next token is token number (10.1: 1) +Shifting token number (10.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (10.1: 1) +-> $$ = nterm exp (10.1: 1) +Entering state 8 +Reading a token +Next token is token '-' (10.3: ) +Shifting token '-' (10.3: ) +Entering state 19 +Reading a token +Next token is token '(' (10.5: ) +Shifting token '(' (10.5: ) +Entering state 4 +Reading a token +Next token is token number (10.6: 2) +Shifting token number (10.6: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (10.6: 2) +-> $$ = nterm exp (10.6: 2) +Entering state 12 +Reading a token +Next token is token '-' (10.8: ) +Shifting token '-' (10.8: ) +Entering state 19 +Reading a token +Next token is token number (10.10: 3) +Shifting token number (10.10: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (10.10: 3) +-> $$ = nterm exp (10.10: 3) +Entering state 28 +Reading a token +Next token is token ')' (10.11: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (10.6: 2) + $2 = token '-' (10.8: ) + $3 = nterm exp (10.10: 3) +-> $$ = nterm exp (10.6-10: -1) +Entering state 12 +Next token is token ')' (10.11: ) +Shifting token ')' (10.11: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (10.5: ) + $2 = nterm exp (10.6-10: -1) + $3 = token ')' (10.11: ) +-> $$ = nterm exp (10.5-11: -1) +Entering state 28 +Reading a token +Next token is token '=' (10.13: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (10.1: 1) + $2 = token '-' (10.3: ) + $3 = nterm exp (10.5-11: -1) +-> $$ = nterm exp (10.1-11: 2) +Entering state 8 +Next token is token '=' (10.13: ) +Shifting token '=' (10.13: ) +Entering state 18 +Reading a token +Next token is token number (10.15: 2) +Shifting token number (10.15: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (10.15: 2) +-> $$ = nterm exp (10.15: 2) +Entering state 27 +Reading a token +Next token is token '\n' (10.16-11.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (10.1-11: 2) + $2 = token '=' (10.13: ) + $3 = nterm exp (10.15: 2) +-> $$ = nterm exp (10.1-15: 2) +Entering state 8 +Next token is token '\n' (10.16-11.0: ) +Shifting token '\n' (10.16-11.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (10.1-15: 2) + $2 = token '\n' (10.16-11.0: ) +-> $$ = nterm line (10.1-11.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-10.0: ) + $2 = nterm line (10.1-11.0: ) +-> $$ = nterm input (1.1-11.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (11.1-12.0: ) +Shifting token '\n' (11.1-12.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (11.1-12.0: ) +-> $$ = nterm line (11.1-12.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-11.0: ) + $2 = nterm line (11.1-12.0: ) +-> $$ = nterm input (1.1-12.0: ) +Entering state 6 +Reading a token +Next token is token number (12.1: 2) +Shifting token number (12.1: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (12.1: 2) +-> $$ = nterm exp (12.1: 2) +Entering state 8 +Reading a token +Next token is token '^' (12.2: ) +Shifting token '^' (12.2: ) +Entering state 23 +Reading a token +Next token is token number (12.3: 2) +Shifting token number (12.3: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (12.3: 2) +-> $$ = nterm exp (12.3: 2) +Entering state 32 +Reading a token +Next token is token '^' (12.4: ) +Shifting token '^' (12.4: ) +Entering state 23 +Reading a token +Next token is token number (12.5: 3) +Shifting token number (12.5: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (12.5: 3) +-> $$ = nterm exp (12.5: 3) +Entering state 32 +Reading a token +Next token is token '=' (12.7: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (12.3: 2) + $2 = token '^' (12.4: ) + $3 = nterm exp (12.5: 3) +-> $$ = nterm exp (12.3-5: 8) +Entering state 32 +Next token is token '=' (12.7: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (12.1: 2) + $2 = token '^' (12.2: ) + $3 = nterm exp (12.3-5: 8) +-> $$ = nterm exp (12.1-5: 256) +Entering state 8 +Next token is token '=' (12.7: ) +Shifting token '=' (12.7: ) +Entering state 18 +Reading a token +Next token is token number (12.9-11: 256) +Shifting token number (12.9-11: 256) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (12.9-11: 256) +-> $$ = nterm exp (12.9-11: 256) +Entering state 27 +Reading a token +Next token is token '\n' (12.12-13.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (12.1-5: 256) + $2 = token '=' (12.7: ) + $3 = nterm exp (12.9-11: 256) +-> $$ = nterm exp (12.1-11: 256) +Entering state 8 +Next token is token '\n' (12.12-13.0: ) +Shifting token '\n' (12.12-13.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (12.1-11: 256) + $2 = token '\n' (12.12-13.0: ) +-> $$ = nterm line (12.1-13.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-12.0: ) + $2 = nterm line (12.1-13.0: ) +-> $$ = nterm input (1.1-13.0: ) +Entering state 6 +Reading a token +Next token is token '(' (13.1: ) +Shifting token '(' (13.1: ) +Entering state 4 +Reading a token +Next token is token number (13.2: 2) +Shifting token number (13.2: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (13.2: 2) +-> $$ = nterm exp (13.2: 2) +Entering state 12 +Reading a token +Next token is token '^' (13.3: ) +Shifting token '^' (13.3: ) +Entering state 23 +Reading a token +Next token is token number (13.4: 2) +Shifting token number (13.4: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (13.4: 2) +-> $$ = nterm exp (13.4: 2) +Entering state 32 +Reading a token +Next token is token ')' (13.5: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (13.2: 2) + $2 = token '^' (13.3: ) + $3 = nterm exp (13.4: 2) +-> $$ = nterm exp (13.2-4: 4) +Entering state 12 +Next token is token ')' (13.5: ) +Shifting token ')' (13.5: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (13.1: ) + $2 = nterm exp (13.2-4: 4) + $3 = token ')' (13.5: ) +-> $$ = nterm exp (13.1-5: 4) +Entering state 8 +Reading a token +Next token is token '^' (13.6: ) +Shifting token '^' (13.6: ) +Entering state 23 +Reading a token +Next token is token number (13.7: 3) +Shifting token number (13.7: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (13.7: 3) +-> $$ = nterm exp (13.7: 3) +Entering state 32 +Reading a token +Next token is token '=' (13.9: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (13.1-5: 4) + $2 = token '^' (13.6: ) + $3 = nterm exp (13.7: 3) +-> $$ = nterm exp (13.1-7: 64) +Entering state 8 +Next token is token '=' (13.9: ) +Shifting token '=' (13.9: ) +Entering state 18 +Reading a token +Next token is token number (13.11-12: 64) +Shifting token number (13.11-12: 64) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (13.11-12: 64) +-> $$ = nterm exp (13.11-12: 64) +Entering state 27 +Reading a token +Next token is token '\n' (13.13-14.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (13.1-7: 64) + $2 = token '=' (13.9: ) + $3 = nterm exp (13.11-12: 64) +-> $$ = nterm exp (13.1-12: 64) +Entering state 8 +Next token is token '\n' (13.13-14.0: ) +Shifting token '\n' (13.13-14.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (13.1-12: 64) + $2 = token '\n' (13.13-14.0: ) +-> $$ = nterm line (13.1-14.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-13.0: ) + $2 = nterm line (13.1-14.0: ) +-> $$ = nterm input (1.1-14.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input (14.1: ) +Entering state 16 +Cleanup: popping token end of input (14.1: ) +Cleanup: popping nterm input (1.1-14.0: ) +stderr: +input: +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 = 2 = 3 +618. existing.at:74: testing GNU AWK 3.1.0 Grammar: Canonical LR(1) ... +./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y +./calc.at:1494: $PREPARSER ./calc input +./torture.at:545: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 10000 stderr: stderr: Starting parse @@ -238262,9 +234332,9 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 20 +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 18 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) @@ -238272,50 +234342,28 @@ Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) -Entering state 29 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 20 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 +Entering state 27 Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Reducing stack 0 by rule 17 (line 108): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Error: popping token '=' (1.3: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '=' (1.7: ) +stderr: +memory exhausted +memory exhausted +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./torture.at:545: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -238351,206 +234399,819 @@ -> $$ = nterm exp (1.9: 3) Entering state 30 Reading a token -Next token is token '+' (1.11: ) +Next token is token '=' (1.11: ) Reducing stack 0 by rule 9 (line 92): $1 = nterm exp (1.5: 2) $2 = token '*' (1.7: ) $3 = nterm exp (1.9: 3) -> $$ = nterm exp (1.5-9: 6) Entering state 29 -Next token is token '+' (1.11: ) +Next token is token '=' (1.11: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1: 1) $2 = token '+' (1.3: ) $3 = nterm exp (1.5-9: 6) -> $$ = nterm exp (1.1-9: 7) Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 20 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 18 Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 +Next token is token number (1.13: 7) +Shifting token number (1.13: 7) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.13: 7) +-> $$ = nterm exp (1.13: 7) +Entering state 27 Reading a token -Next token is token '+' (1.14: ) -Shifting token '+' (1.14: ) -Entering state 14 -Reducing stack 0 by rule 17 (line 108): - $1 = token '!' (1.13: ) - $2 = token '+' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -input: -input: -input: - | 1 + 2 * 3 + !- ++ -./calc.at:1494: $PREPARSER ./calc input - | 1 + 2 * 3 + !- ++ - | - | +1 -./calc.at:1491: $PREPARSER ./calc input -./calc.at:1492: $PREPARSER ./calc input -stderr: -./torture.at:548: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -stderr: -stderr: -Starting parse -Entering state 0 +Next token is token '\n' (1.14-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-9: 7) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13: 7) +-> $$ = nterm exp (1.1-13: 7) +Entering state 8 +Next token is token '\n' (1.14-2.0: ) +Shifting token '\n' (1.14-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-13: 7) + $2 = token '\n' (1.14-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 Reading a token -Next token is token "number" (1.1: 1) -Shifting token "number" (1.1: 1) +Next token is token number (2.1: 1) +Shifting token number (2.1: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.1: 1) --> $$ = nterm exp (1.1: 1) + $1 = token number (2.1: 1) +-> $$ = nterm exp (2.1: 1) Entering state 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) +Next token is token '+' (2.3: ) +Shifting token '+' (2.3: ) Entering state 20 Reading a token -Next token is token "number" (1.5: 2) -Shifting token "number" (1.5: 2) +Next token is token number (2.5: 2) +Shifting token number (2.5: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.5: 2) --> $$ = nterm exp (1.5: 2) + $1 = token number (2.5: 2) +-> $$ = nterm exp (2.5: 2) Entering state 29 Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) +Next token is token '*' (2.7: ) +Shifting token '*' (2.7: ) Entering state 21 Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) +Next token is token '-' (2.9: ) +Shifting token '-' (2.9: ) +Entering state 2 +Reading a token +Next token is token number (2.10: 3) +Shifting token number (2.10: 3) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 + $1 = token number (2.10: 3) +-> $$ = nterm exp (2.10: 3) +Entering state 10 Reading a token -Next token is token '+' (1.11: ) +Next token is token '=' (2.12: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (2.9: ) + $2 = nterm exp (2.10: 3) +-> $$ = nterm exp (2.9-10: -3) +Entering state 30 +Next token is token '=' (2.12: ) Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) + $1 = nterm exp (2.5: 2) + $2 = token '*' (2.7: ) + $3 = nterm exp (2.9-10: -3) +-> $$ = nterm exp (2.5-10: -6) Entering state 29 -Next token is token '+' (1.11: ) +Next token is token '=' (2.12: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) + $1 = nterm exp (2.1: 1) + $2 = token '+' (2.3: ) + $3 = nterm exp (2.5-10: -6) +-> $$ = nterm exp (2.1-10: -5) Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 20 +Next token is token '=' (2.12: ) +Shifting token '=' (2.12: ) +Entering state 18 Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 +Next token is token '-' (2.14: ) +Shifting token '-' (2.14: ) +Entering state 2 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Reducing stack 0 by rule 18 (line 109): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) -./torture.at:510: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -Starting parse -Entering state 0 +Next token is token number (2.15: 5) +Shifting token number (2.15: 5) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (2.15: 5) +-> $$ = nterm exp (2.15: 5) +Entering state 10 Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) +Next token is token '\n' (2.16-3.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (2.14: ) + $2 = nterm exp (2.15: 5) +-> $$ = nterm exp (2.14-15: -5) +Entering state 27 +Next token is token '\n' (2.16-3.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (2.1-10: -5) + $2 = token '=' (2.12: ) + $3 = nterm exp (2.14-15: -5) +-> $$ = nterm exp (2.1-15: -5) +Entering state 8 +Next token is token '\n' (2.16-3.0: ) +Shifting token '\n' (2.16-3.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (2.1-15: -5) + $2 = token '\n' (2.16-3.0: ) +-> $$ = nterm line (2.1-3.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-2.0: ) + $2 = nterm line (2.1-3.0: ) +-> $$ = nterm input (1.1-3.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (3.1-4.0: ) +Shifting token '\n' (3.1-4.0: ) Entering state 3 Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) + $1 = token '\n' (3.1-4.0: ) +-> $$ = nterm line (3.1-4.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-3.0: ) + $2 = nterm line (3.1-4.0: ) +-> $$ = nterm input (1.1-4.0: ) Entering state 6 Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Cleanup: discarding lookahead token '+' (2.1: ) -Starting parse -Entering state 0 +Next token is token '-' (4.1: ) +Shifting token '-' (4.1: ) +Entering state 2 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token number (4.2: 1) +Shifting token number (4.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) + $1 = token number (4.2: 1) +-> $$ = nterm exp (4.2: 1) +Entering state 10 +Reading a token +Next token is token '^' (4.3: ) +Shifting token '^' (4.3: ) +Entering state 23 +Reading a token +Next token is token number (4.4: 2) +Shifting token number (4.4: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (4.4: 2) +-> $$ = nterm exp (4.4: 2) +Entering state 32 +Reading a token +Next token is token '=' (4.6: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (4.2: 1) + $2 = token '^' (4.3: ) + $3 = nterm exp (4.4: 2) +-> $$ = nterm exp (4.2-4: 1) +Entering state 10 +Next token is token '=' (4.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (4.1: ) + $2 = nterm exp (4.2-4: 1) +-> $$ = nterm exp (4.1-4: -1) Entering state 8 +Next token is token '=' (4.6: ) +Shifting token '=' (4.6: ) +Entering state 18 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 20 +Next token is token '-' (4.8: ) +Shifting token '-' (4.8: ) +Entering state 2 Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) +Next token is token number (4.9: 1) +Shifting token number (4.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 + $1 = token number (4.9: 1) +-> $$ = nterm exp (4.9: 1) +Entering state 10 Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 +Next token is token '\n' (4.10-5.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (4.8: ) + $2 = nterm exp (4.9: 1) +-> $$ = nterm exp (4.8-9: -1) +Entering state 27 +Next token is token '\n' (4.10-5.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (4.1-4: -1) + $2 = token '=' (4.6: ) + $3 = nterm exp (4.8-9: -1) +-> $$ = nterm exp (4.1-9: -1) +Entering state 8 +Next token is token '\n' (4.10-5.0: ) +Shifting token '\n' (4.10-5.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (4.1-9: -1) + $2 = token '\n' (4.10-5.0: ) +-> $$ = nterm line (4.1-5.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-4.0: ) + $2 = nterm line (4.1-5.0: ) +-> $$ = nterm input (1.1-5.0: ) +Entering state 6 Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) +Next token is token '(' (5.1: ) +Shifting token '(' (5.1: ) +Entering state 4 +Reading a token +Next token is token '-' (5.2: ) +Shifting token '-' (5.2: ) +Entering state 2 +Reading a token +Next token is token number (5.3: 1) +Shifting token number (5.3: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 + $1 = token number (5.3: 1) +-> $$ = nterm exp (5.3: 1) +Entering state 10 Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) +Next token is token ')' (5.4: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (5.2: ) + $2 = nterm exp (5.3: 1) +-> $$ = nterm exp (5.2-3: -1) +Entering state 12 +Next token is token ')' (5.4: ) +Shifting token ')' (5.4: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (5.1: ) + $2 = nterm exp (5.2-3: -1) + $3 = token ')' (5.4: ) +-> $$ = nterm exp (5.1-4: -1) Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 20 Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 +Next token is token '^' (5.5: ) +Shifting token '^' (5.5: ) +Entering state 23 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Reducing stack 0 by rule 18 (line 109): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) +Next token is token number (5.6: 2) +Shifting token number (5.6: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (5.6: 2) +-> $$ = nterm exp (5.6: 2) +Entering state 32 +Reading a token +Next token is token '=' (5.8: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (5.1-4: -1) + $2 = token '^' (5.5: ) + $3 = nterm exp (5.6: 2) +-> $$ = nterm exp (5.1-6: 1) +Entering state 8 +Next token is token '=' (5.8: ) +Shifting token '=' (5.8: ) +Entering state 18 +Reading a token +Next token is token number (5.10: 1) +Shifting token number (5.10: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (5.10: 1) +-> $$ = nterm exp (5.10: 1) +Entering state 27 +Reading a token +Next token is token '\n' (5.11-6.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (5.1-6: 1) + $2 = token '=' (5.8: ) + $3 = nterm exp (5.10: 1) +-> $$ = nterm exp (5.1-10: 1) +Entering state 8 +Next token is token '\n' (5.11-6.0: ) +Shifting token '\n' (5.11-6.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (5.1-10: 1) + $2 = token '\n' (5.11-6.0: ) +-> $$ = nterm line (5.1-6.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-5.0: ) + $2 = nterm line (5.1-6.0: ) +-> $$ = nterm input (1.1-6.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (6.1-7.0: ) +Shifting token '\n' (6.1-7.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (6.1-7.0: ) +-> $$ = nterm line (6.1-7.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-6.0: ) + $2 = nterm line (6.1-7.0: ) +-> $$ = nterm input (1.1-7.0: ) +Entering state 6 +Reading a token +Next token is token '-' (7.1: ) +Shifting token '-' (7.1: ) +Entering state 2 +Reading a token +Next token is token '-' (7.2: ) +Shifting token '-' (7.2: ) +Entering state 2 +Reading a token +Next token is token '-' (7.3: ) +Shifting token '-' (7.3: ) +Entering state 2 +Reading a token +Next token is token number (7.4: 1) +Shifting token number (7.4: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (7.4: 1) +-> $$ = nterm exp (7.4: 1) +Entering state 10 +Reading a token +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.3: ) + $2 = nterm exp (7.4: 1) +-> $$ = nterm exp (7.3-4: -1) +Entering state 10 +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.2: ) + $2 = nterm exp (7.3-4: -1) +-> $$ = nterm exp (7.2-4: 1) +Entering state 10 +Next token is token '=' (7.6: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.1: ) + $2 = nterm exp (7.2-4: 1) +-> $$ = nterm exp (7.1-4: -1) +Entering state 8 +Next token is token '=' (7.6: ) +Shifting token '=' (7.6: ) +Entering state 18 +Reading a token +Next token is token '-' (7.8: ) +Shifting token '-' (7.8: ) +Entering state 2 +Reading a token +Next token is token number (7.9: 1) +Shifting token number (7.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (7.9: 1) +-> $$ = nterm exp (7.9: 1) +Entering state 10 +Reading a token +Next token is token '\n' (7.10-8.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (7.8: ) + $2 = nterm exp (7.9: 1) +-> $$ = nterm exp (7.8-9: -1) +Entering state 27 +Next token is token '\n' (7.10-8.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (7.1-4: -1) + $2 = token '=' (7.6: ) + $3 = nterm exp (7.8-9: -1) +-> $$ = nterm exp (7.1-9: -1) +Entering state 8 +Next token is token '\n' (7.10-8.0: ) +Shifting token '\n' (7.10-8.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (7.1-9: -1) + $2 = token '\n' (7.10-8.0: ) +-> $$ = nterm line (7.1-8.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-7.0: ) + $2 = nterm line (7.1-8.0: ) +-> $$ = nterm input (1.1-8.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (8.1-9.0: ) +Shifting token '\n' (8.1-9.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (8.1-9.0: ) +-> $$ = nterm line (8.1-9.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-8.0: ) + $2 = nterm line (8.1-9.0: ) +-> $$ = nterm input (1.1-9.0: ) +Entering state 6 +Reading a token +Next token is token number (9.1: 1) +Shifting token number (9.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (9.1: 1) +-> $$ = nterm exp (9.1: 1) +Entering state 8 +Reading a token +Next token is token '-' (9.3: ) +Shifting token '-' (9.3: ) +Entering state 19 +Reading a token +Next token is token number (9.5: 2) +Shifting token number (9.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (9.5: 2) +-> $$ = nterm exp (9.5: 2) +Entering state 28 +Reading a token +Next token is token '-' (9.7: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (9.1: 1) + $2 = token '-' (9.3: ) + $3 = nterm exp (9.5: 2) +-> $$ = nterm exp (9.1-5: -1) +Entering state 8 +Next token is token '-' (9.7: ) +Shifting token '-' (9.7: ) +Entering state 19 +Reading a token +Next token is token number (9.9: 3) +Shifting token number (9.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (9.9: 3) +-> $$ = nterm exp (9.9: 3) +Entering state 28 +Reading a token +Next token is token '=' (9.11: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (9.1-5: -1) + $2 = token '-' (9.7: ) + $3 = nterm exp (9.9: 3) +-> $$ = nterm exp (9.1-9: -4) +Entering state 8 +Next token is token '=' (9.11: ) +Shifting token '=' (9.11: ) +Entering state 18 +Reading a token +Next token is token '-' (9.13: ) +Shifting token '-' (9.13: ) +Entering state 2 +Reading a token +Next token is token number (9.14: 4) +Shifting token number (9.14: 4) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (9.14: 4) +-> $$ = nterm exp (9.14: 4) +Entering state 10 +Reading a token +Next token is token '\n' (9.15-10.0: ) +Reducing stack 0 by rule 11 (line 102): + $1 = token '-' (9.13: ) + $2 = nterm exp (9.14: 4) +-> $$ = nterm exp (9.13-14: -4) +Entering state 27 +Next token is token '\n' (9.15-10.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (9.1-9: -4) + $2 = token '=' (9.11: ) + $3 = nterm exp (9.13-14: -4) +-> $$ = nterm exp (9.1-14: -4) +Entering state 8 +Next token is token '\n' (9.15-10.0: ) +Shifting token '\n' (9.15-10.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (9.1-14: -4) + $2 = token '\n' (9.15-10.0: ) +-> $$ = nterm line (9.1-10.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-9.0: ) + $2 = nterm line (9.1-10.0: ) +-> $$ = nterm input (1.1-10.0: ) +Entering state 6 +Reading a token +Next token is token number (10.1: 1) +Shifting token number (10.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (10.1: 1) +-> $$ = nterm exp (10.1: 1) +Entering state 8 +Reading a token +Next token is token '-' (10.3: ) +Shifting token '-' (10.3: ) +Entering state 19 +Reading a token +Next token is token '(' (10.5: ) +Shifting token '(' (10.5: ) +Entering state 4 +Reading a token +Next token is token number (10.6: 2) +Shifting token number (10.6: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (10.6: 2) +-> $$ = nterm exp (10.6: 2) +Entering state 12 +Reading a token +Next token is token '-' (10.8: ) +Shifting token '-' (10.8: ) +Entering state 19 +Reading a token +Next token is token number (10.10: 3) +Shifting token number (10.10: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (10.10: 3) +-> $$ = nterm exp (10.10: 3) +Entering state 28 +Reading a token +Next token is token ')' (10.11: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (10.6: 2) + $2 = token '-' (10.8: ) + $3 = nterm exp (10.10: 3) +-> $$ = nterm exp (10.6-10: -1) +Entering state 12 +Next token is token ')' (10.11: ) +Shifting token ')' (10.11: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (10.5: ) + $2 = nterm exp (10.6-10: -1) + $3 = token ')' (10.11: ) +-> $$ = nterm exp (10.5-11: -1) +Entering state 28 +Reading a token +Next token is token '=' (10.13: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (10.1: 1) + $2 = token '-' (10.3: ) + $3 = nterm exp (10.5-11: -1) +-> $$ = nterm exp (10.1-11: 2) +Entering state 8 +Next token is token '=' (10.13: ) +Shifting token '=' (10.13: ) +Entering state 18 +Reading a token +Next token is token number (10.15: 2) +Shifting token number (10.15: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (10.15: 2) +-> $$ = nterm exp (10.15: 2) +Entering state 27 +Reading a token +Next token is token '\n' (10.16-11.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (10.1-11: 2) + $2 = token '=' (10.13: ) + $3 = nterm exp (10.15: 2) +-> $$ = nterm exp (10.1-15: 2) +Entering state 8 +Next token is token '\n' (10.16-11.0: ) +Shifting token '\n' (10.16-11.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (10.1-15: 2) + $2 = token '\n' (10.16-11.0: ) +-> $$ = nterm line (10.1-11.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-10.0: ) + $2 = nterm line (10.1-11.0: ) +-> $$ = nterm input (1.1-11.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (11.1-12.0: ) +Shifting token '\n' (11.1-12.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (11.1-12.0: ) +-> $$ = nterm line (11.1-12.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-11.0: ) + $2 = nterm line (11.1-12.0: ) +-> $$ = nterm input (1.1-12.0: ) +Entering state 6 +Reading a token +Next token is token number (12.1: 2) +Shifting token number (12.1: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (12.1: 2) +-> $$ = nterm exp (12.1: 2) +Entering state 8 +Reading a token +Next token is token '^' (12.2: ) +Shifting token '^' (12.2: ) +Entering state 23 +Reading a token +Next token is token number (12.3: 2) +Shifting token number (12.3: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (12.3: 2) +-> $$ = nterm exp (12.3: 2) +Entering state 32 +Reading a token +Next token is token '^' (12.4: ) +Shifting token '^' (12.4: ) +Entering state 23 +Reading a token +Next token is token number (12.5: 3) +Shifting token number (12.5: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (12.5: 3) +-> $$ = nterm exp (12.5: 3) +Entering state 32 +Reading a token +Next token is token '=' (12.7: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (12.3: 2) + $2 = token '^' (12.4: ) + $3 = nterm exp (12.5: 3) +-> $$ = nterm exp (12.3-5: 8) +Entering state 32 +Next token is token '=' (12.7: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (12.1: 2) + $2 = token '^' (12.2: ) + $3 = nterm exp (12.3-5: 8) +-> $$ = nterm exp (12.1-5: 256) +Entering state 8 +Next token is token '=' (12.7: ) +Shifting token '=' (12.7: ) +Entering state 18 +Reading a token +Next token is token number (12.9-11: 256) +Shifting token number (12.9-11: 256) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (12.9-11: 256) +-> $$ = nterm exp (12.9-11: 256) +Entering state 27 +Reading a token +Next token is token '\n' (12.12-13.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (12.1-5: 256) + $2 = token '=' (12.7: ) + $3 = nterm exp (12.9-11: 256) +-> $$ = nterm exp (12.1-11: 256) +Entering state 8 +Next token is token '\n' (12.12-13.0: ) +Shifting token '\n' (12.12-13.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (12.1-11: 256) + $2 = token '\n' (12.12-13.0: ) +-> $$ = nterm line (12.1-13.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-12.0: ) + $2 = nterm line (12.1-13.0: ) +-> $$ = nterm input (1.1-13.0: ) +Entering state 6 +Reading a token +Next token is token '(' (13.1: ) +Shifting token '(' (13.1: ) +Entering state 4 +Reading a token +Next token is token number (13.2: 2) +Shifting token number (13.2: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (13.2: 2) +-> $$ = nterm exp (13.2: 2) +Entering state 12 +Reading a token +Next token is token '^' (13.3: ) +Shifting token '^' (13.3: ) +Entering state 23 +Reading a token +Next token is token number (13.4: 2) +Shifting token number (13.4: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (13.4: 2) +-> $$ = nterm exp (13.4: 2) +Entering state 32 +Reading a token +Next token is token ')' (13.5: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (13.2: 2) + $2 = token '^' (13.3: ) + $3 = nterm exp (13.4: 2) +-> $$ = nterm exp (13.2-4: 4) +Entering state 12 +Next token is token ')' (13.5: ) +Shifting token ')' (13.5: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (13.1: ) + $2 = nterm exp (13.2-4: 4) + $3 = token ')' (13.5: ) +-> $$ = nterm exp (13.1-5: 4) +Entering state 8 +Reading a token +Next token is token '^' (13.6: ) +Shifting token '^' (13.6: ) +Entering state 23 +Reading a token +Next token is token number (13.7: 3) +Shifting token number (13.7: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (13.7: 3) +-> $$ = nterm exp (13.7: 3) +Entering state 32 +Reading a token +Next token is token '=' (13.9: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (13.1-5: 4) + $2 = token '^' (13.6: ) + $3 = nterm exp (13.7: 3) +-> $$ = nterm exp (13.1-7: 64) +Entering state 8 +Next token is token '=' (13.9: ) +Shifting token '=' (13.9: ) +Entering state 18 +Reading a token +Next token is token number (13.11-12: 64) +Shifting token number (13.11-12: 64) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (13.11-12: 64) +-> $$ = nterm exp (13.11-12: 64) +Entering state 27 +Reading a token +Next token is token '\n' (13.13-14.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (13.1-7: 64) + $2 = token '=' (13.9: ) + $3 = nterm exp (13.11-12: 64) +-> $$ = nterm exp (13.1-12: 64) +Entering state 8 +Next token is token '\n' (13.13-14.0: ) +Shifting token '\n' (13.13-14.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (13.1-12: 64) + $2 = token '\n' (13.13-14.0: ) +-> $$ = nterm line (13.1-14.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-13.0: ) + $2 = nterm line (13.1-14.0: ) +-> $$ = nterm input (1.1-14.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input (14.1: ) +Entering state 16 +Cleanup: popping token end of input (14.1: ) +Cleanup: popping nterm input (1.1-14.0: ) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none +./calc.at:1491: cat stderr stderr: +input: +memory exhausted +memory exhausted + | 1 2 stderr: +./calc.at:1492: $PREPARSER ./calc input +./torture.at:548: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none +input: stderr: Starting parse Entering state 0 @@ -238563,9 +235224,9 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 20 +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 18 Reading a token Next token is token "number" (1.5: 2) Shifting token "number" (1.5: 2) @@ -238573,50 +235234,18 @@ Reducing stack 0 by rule 5 (line 79): $1 = token "number" (1.5: 2) -> $$ = nterm exp (1.5: 2) -Entering state 29 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 -Reading a token -Next token is token "number" (1.9: 3) -Shifting token "number" (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 20 -Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 +Entering state 27 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Reducing stack 0 by rule 18 (line 109): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Error: popping token '=' (1.3: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '=' (1.7: ) + | + | +1 +./calc.at:1491: $PREPARSER ./calc input +stderr: Starting parse Entering state 0 Reading a token @@ -238628,60 +235257,33 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '+' (1.3: ) -Shifting token '+' (1.3: ) -Entering state 20 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 29 -Reading a token -Next token is token '*' (1.7: ) -Shifting token '*' (1.7: ) -Entering state 21 -Reading a token -Next token is token number (1.9: 3) -Shifting token number (1.9: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.9: 3) --> $$ = nterm exp (1.9: 3) -Entering state 30 -Reading a token -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 9 (line 92): - $1 = nterm exp (1.5: 2) - $2 = token '*' (1.7: ) - $3 = nterm exp (1.9: 3) --> $$ = nterm exp (1.5-9: 6) -Entering state 29 -Next token is token '+' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1: 1) - $2 = token '+' (1.3: ) - $3 = nterm exp (1.5-9: 6) --> $$ = nterm exp (1.1-9: 7) -Entering state 8 -Next token is token '+' (1.11: ) -Shifting token '+' (1.11: ) -Entering state 20 +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token number (1.3: 2) +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 Reading a token -Next token is token '!' (1.13: ) -Shifting token '!' (1.13: ) -Entering state 5 +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 13 -Reducing stack 0 by rule 18 (line 109): - $1 = token '!' (1.13: ) - $2 = token '-' (1.14: ) -Cleanup: popping token '+' (1.11: ) -Cleanup: popping nterm exp (1.1-9: 7) +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Cleanup: discarding lookahead token '+' (2.1: ) +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: Starting parse Entering state 0 Reading a token @@ -238711,7 +235313,24 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1491: "$PERL" -pi -e 'use strict; +Starting parse +Entering state 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token number (1.3: 2) +./torture.at:548: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./calc.at:1494: cat stderr +./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -238721,9 +235340,7 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1494: cat stderr -./calc.at:1491: cat stderr -./calc.at:1492: "$PERL" -pi -e 'use strict; +./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -238733,96 +235350,21 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./calc.at:1492: cat stderr input: - | (#) + (#) = 2222 + | + | +1 ./calc.at:1494: $PREPARSER ./calc input -./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none stderr: +./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token ')' (1.3: ) -Entering state 11 -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 20 -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Reading a token -1.8: syntax error: invalid character: '#' -Next token is token error (1.8: ) -Shifting token error (1.8: ) -Entering state 11 -Next token is token error (1.8: ) -Error: discarding token error (1.8: ) -Reading a token -Next token is token ')' (1.9: ) -Entering state 11 -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 18 -Reading a token -Next token is token "number" (1.13-16: 2222) -Shifting token "number" (1.13-16: 2222) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 27 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -238830,102 +235372,87 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1492: cat stderr +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Cleanup: discarding lookahead token '+' (2.1: ) +stderr: input: -./torture.at:237: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1491: $PREPARSER ./calc /dev/null +input.y:66.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:170.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:175.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:180.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:188.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:202.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:207.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:221.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:300.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:323.10: error: empty rule without %empty [-Werror=empty-rule] +input.y: error: 65 shift/reduce conflicts [-Werror=conflicts-sr] +input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +input.y:39.1-5: error: useless associativity for FUNC_CALL, use %precedence [-Werror=precedence] +input.y:44.1-5: error: useless associativity for YNUMBER, use %precedence [-Werror=precedence] +input.y:44.1-5: error: useless associativity for YSTRING, use %precedence [-Werror=precedence] +input.y:42.1-9: error: useless precedence and associativity for APPEND_OP [-Werror=precedence] +input.y:33.1-6: error: useless associativity for ASSIGNOP, use %precedence [-Werror=precedence] +input.y:43.1-5: error: useless associativity for CONCAT_OP, use %precedence [-Werror=precedence] +input.y:37.1-5: error: useless precedence and associativity for LEX_GETLINE [-Werror=precedence] +input.y:38.1-9: error: useless associativity for LEX_IN, use %precedence [-Werror=precedence] +input.y:49.1-5: error: useless associativity for INCREMENT, use %precedence [-Werror=precedence] +input.y:49.1-5: error: useless associativity for DECREMENT, use %precedence [-Werror=precedence] +input.y:39.1-5: error: useless associativity for LEX_BUILTIN, use %precedence [-Werror=precedence] +input.y:39.1-5: error: useless associativity for LEX_LENGTH, use %precedence [-Werror=precedence] +input.y:40.1-9: error: useless precedence and associativity for ',' [-Werror=precedence] +input.y:47.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] +input.y:47.1-6: error: useless associativity for UNARY, use %precedence [-Werror=precedence] +input.y:50.1-5: error: useless associativity for '$', use %precedence [-Werror=precedence] +input.y:51.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] +input.y:51.1-5: error: useless precedence and associativity for ')' [-Werror=precedence] +input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] + | 1//2 +./calc.at:1492: $PREPARSER ./calc input +stderr: +./existing.at:74: sed -n 's/^State //p' input.output | tail -1 stderr: -./calc.at:1492: $PREPARSER ./calc /dev/null Starting parse Entering state 0 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) +Now at end of input. +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token end of input (1.1: ) +stderr: +Starting parse +Entering state 0 Reading a token -Next token is token ')' (1.3: ) -Entering state 11 -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 20 -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Reading a token -1.8: syntax error: invalid character: '#' -Next token is token error (1.8: ) -Shifting token error (1.8: ) -Entering state 11 -Next token is token error (1.8: ) -Error: discarding token error (1.8: ) -Reading a token -Next token is token ')' (1.9: ) -Entering state 11 -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 18 +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 22 Reading a token -Next token is token "number" (1.13-16: 2222) -Shifting token "number" (1.13-16: 2222) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 27 +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '/' (1.3: ) +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (1.1-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -238933,13 +235460,40 @@ -> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Cleanup: discarding lookahead token '+' (2.1: ) +./existing.at:74: sed 's,.*/$,,' stderr 1>&2 +stderr: +./existing.at:74: sed 's/^%define lr.type .*$//' input.y > input-lalr.y +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 22 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '/' (1.3: ) +Starting parse +Entering state 0 +Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) - | (#) + (#) = 2222 -./calc.at:1491: $PREPARSER ./calc input +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token end of input (1.1: ) ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -238950,22 +235504,60 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error +./calc.at:1494: cat stderr +./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y +./calc.at:1492: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1494: $PREPARSER ./calc /dev/null stderr: +./calc.at:1492: cat stderr +./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token end of input (1.1: ) +Cleanup: discarding lookahead token "end of input" (1.1: ) stderr: -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +./torture.at:140: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +input: +./torture.at:513: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 20 stderr: +input: + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 Starting parse Entering state 0 Reading a token Now at end of input. 1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token end of input (1.1: ) +Cleanup: discarding lookahead token "end of input" (1.1: ) +./calc.at:1491: $PREPARSER ./calc input +stderr: + | error +stderr: +./calc.at:1492: $PREPARSER ./calc input +./torture.at:513: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -238973,357 +235565,234 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' Shifting token error (1.2: ) Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token ')' (1.3: ) -Entering state 11 -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) Entering state 8 Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) Entering state 20 Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) Entering state 4 Reading a token -1.8: syntax error: invalid character: '#' -Next token is token error (1.8: ) -Shifting token error (1.8: ) -Entering state 11 -Next token is token error (1.8: ) -Error: discarding token error (1.8: ) -Reading a token -Next token is token ')' (1.9: ) -Entering state 11 -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 18 -Reading a token -Next token is token number (1.13-16: 2222) -Shifting token number (1.13-16: 2222) +Next token is token number (1.7: 1) +Shifting token number (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 27 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input (2.1: ) -Entering state 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1494: cat stderr -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -input: -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (1 + #) = 1111 -./calc.at:1494: $PREPARSER ./calc input -stderr: -Starting parse -Entering state 0 + $1 = token number (1.7: 1) +-> $$ = nterm exp (1.7: 1) +Entering state 12 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 20 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) +Next token is token number (1.11: 1) +Shifting token number (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 + $1 = token number (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 29 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' (1.13: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) Entering state 20 Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) -Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) -Reading a token -Next token is token ')' (1.7: ) -Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) +Next token is token number (1.15: 1) +Shifting token number (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none -./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 + $1 = token number (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 29 Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) +Next token is token '+' (1.17: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 20 Reading a token -Next token is token ')' (1.3: ) +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Error: popping nterm exp (1.7-15: 3) +Shifting token error (1.7-18: ) Entering state 11 -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 29 Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) +Next token is token '+' (1.20: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) +Entering state 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) Entering state 20 Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) Entering state 4 Reading a token -1.8: syntax error: invalid character: '#' -Next token is token error (1.8: ) -Shifting token error (1.8: ) +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) Entering state 11 -Next token is token error (1.8: ) -Error: discarding token error (1.8: ) +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) Reading a token -Next token is token ')' (1.9: ) +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Reading a token +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Reading a token +Next token is token ')' (1.28: ) Entering state 11 -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) Entering state 29 Reading a token -Next token is token '=' (1.11: ) +Next token is token '+' (1.30: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 18 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +Entering state 20 Reading a token -Next token is token number (1.13-16: 2222) -Shifting token number (1.13-16: 2222) +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) +Entering state 4 +Reading a token +Next token is token number (1.33: 1) +Shifting token number (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 27 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input (2.1: ) -Entering state 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./torture.at:140: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./calc.at:1492: cat stderr -stderr: -Starting parse -Entering state 0 + $1 = token number (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 21 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) +Next token is token number (1.37: 2) +Shifting token number (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 + $1 = token number (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 30 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 +Next token is token '*' (1.39: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 21 Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Error: popping nterm exp (1.33-37: 2) +Shifting token error (1.33-41: ) Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) Reading a token -Next token is token ')' (1.7: ) +Next token is token ')' (1.42: ) Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) +Entering state 29 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) +Next token is token '=' (1.44: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) +Entering state 8 +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) Entering state 18 Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) +Next token is token number (1.46: 1) +Shifting token number (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) + $1 = token number (1.46: 1) +-> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token -Next token is token '\n' (1.15-2.0: ) +Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -239332,20 +235801,10 @@ Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) +Shifting token end of input (2.1: ) Entering state 16 -Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -239356,15 +235815,20 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1491: cat stderr -input: +stderr: +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) +stderr: +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: cat stderr - | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./calc.at:1492: $PREPARSER ./calc input -input: -input: +./torture.at:515: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 900 +stderr: stderr: - | (# + 1) = 1111 Starting parse Entering state 0 Reading a token @@ -239612,12 +236076,45 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - | (1 + #) = 1111 -./calc.at:1491: $PREPARSER ./calc input +stderr: +input: +./torture.at:515: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +stderr: +input-lalr.y: warning: 65 shift/reduce conflicts [-Wconflicts-sr] +input-lalr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +stdout: ./calc.at:1494: $PREPARSER ./calc input +./existing.at:74: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' stderr: stderr: -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./torture.at:517: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 10000 +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1492: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -239625,133 +236122,234 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Reading a token +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Reading a token +Next token is token "number" (1.7: 1) +Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) + $1 = token "number" (1.7: 1) +-> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) Entering state 20 Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) +Next token is token "number" (1.11: 1) +Shifting token "number" (1.11: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 29 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 20 +Reading a token +Next token is token "number" (1.15: 1) +Shifting token "number" (1.15: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 29 +Reading a token +Next token is token '+' (1.17: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 20 +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Error: popping nterm exp (1.7-15: 3) +Shifting token error (1.7-18: ) Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 29 Reading a token -Next token is token ')' (1.7: ) +Next token is token '+' (1.20: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) +Entering state 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 20 +Reading a token +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 +Reading a token +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) +Reading a token +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Reading a token +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Reading a token +Next token is token ')' (1.28: ) +Entering state 11 +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 29 +Reading a token +Next token is token '+' (1.30: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) Entering state 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +Entering state 20 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) +Entering state 4 Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) +Next token is token "number" (1.33: 1) +Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 + $1 = token "number" (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) -Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 21 Reading a token -Now at end of input. -Shifting token end of input (2.1: ) -Entering state 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -Starting parse -Entering state 0 +Next token is token "number" (1.37: 2) +Shifting token "number" (1.37: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 30 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 +Next token is token '*' (1.39: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 21 Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Error: popping nterm exp (1.33-37: 2) +Shifting token error (1.33-41: ) Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Reading a token -Next token is token "number" (1.6: 1) -Error: discarding token "number" (1.6: 1) +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) Reading a token -Next token is token ')' (1.7: ) +Next token is token ')' (1.42: ) Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) +Entering state 29 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) +Next token is token '=' (1.44: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) +Entering state 8 +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) Entering state 18 Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) +Next token is token "number" (1.46: 1) +Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) + $1 = token "number" (1.46: 1) +-> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token -Next token is token '\n' (1.15-2.0: ) +Next token is token '\n' (1.47-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -239764,12 +236362,23 @@ Entering state 16 Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./existing.at:74: sed -n 's/^State //p' input.output | tail -1 -./existing.at:74: sed 's/^%define lr.type .*$//' input.y > input-lalr.y +./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none +stderr: +./calc.at:1491: cat stderr ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./existing.at:74: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +memory exhausted +memory exhausted +./torture.at:517: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1492: cat stderr +stderr: +input: +memory exhausted +memory exhausted stderr: +stderr: + | (!!) + (1 2) = 1 +./calc.at:1491: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -239799,11 +236408,11 @@ Shifting token '(' (1.6: ) Entering state 4 Reading a token -Next token is token number (1.7: 1) -Shifting token number (1.7: 1) +Next token is token "number" (1.7: 1) +Shifting token "number" (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.7: 1) + $1 = token "number" (1.7: 1) -> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token @@ -239811,11 +236420,11 @@ Shifting token '+' (1.9: ) Entering state 20 Reading a token -Next token is token number (1.11: 1) -Shifting token number (1.11: 1) +Next token is token "number" (1.11: 1) +Shifting token "number" (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.11: 1) + $1 = token "number" (1.11: 1) -> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token @@ -239830,11 +236439,11 @@ Shifting token '+' (1.13: ) Entering state 20 Reading a token -Next token is token number (1.15: 1) -Shifting token number (1.15: 1) +Next token is token "number" (1.15: 1) +Shifting token "number" (1.15: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.15: 1) + $1 = token "number" (1.15: 1) -> $$ = nterm exp (1.15: 1) Entering state 29 Reading a token @@ -239920,11 +236529,11 @@ Shifting token '(' (1.32: ) Entering state 4 Reading a token -Next token is token number (1.33: 1) -Shifting token number (1.33: 1) +Next token is token "number" (1.33: 1) +Shifting token "number" (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.33: 1) + $1 = token "number" (1.33: 1) -> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token @@ -239932,11 +236541,11 @@ Shifting token '*' (1.35: ) Entering state 21 Reading a token -Next token is token number (1.37: 2) -Shifting token number (1.37: 2) +Next token is token "number" (1.37: 2) +Shifting token "number" (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.37: 2) + $1 = token "number" (1.37: 2) -> $$ = nterm exp (1.37: 2) Entering state 30 Reading a token @@ -239983,11 +236592,11 @@ Shifting token '=' (1.44: ) Entering state 18 Reading a token -Next token is token number (1.46: 1) -Shifting token number (1.46: 1) +Next token is token "number" (1.46: 1) +Shifting token "number" (1.46: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.46: 1) + $1 = token "number" (1.46: 1) -> $$ = nterm exp (1.46: 1) Entering state 27 Reading a token @@ -240013,12 +236622,14 @@ Entering state 6 Reading a token Now at end of input. -Shifting token end of input (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token end of input (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +stdout: stderr: -stderr: +614. torture.at:485: ok +./torture.at:551: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 20 Starting parse Entering state 0 Reading a token @@ -240026,133 +236637,98 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Reading a token -Next token is token "number" (1.6: 1) -Error: discarding token "number" (1.6: 1) +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 Reading a token -Next token is token ')' (1.7: ) +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 15 +Reducing stack 0 by rule 16 (line 107): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Shifting token error (1.2-3: ) Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Reading a token -Next token is token "number" (1.11-14: 1111) -Shifting token "number" (1.11-14: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 Reading a token -Now at end of input. -Shifting token "end of input" (2.1: ) -Entering state 16 -Cleanup: popping token "end of input" (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -Starting parse -Entering state 0 +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) +Entering state 20 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) Entering state 4 Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) +Next token is token number (1.9: 1) +Shifting token number (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) + $1 = token number (1.9: 1) +-> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) +Next token is token number (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Shifting token error (1.9-11: ) Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) +Next token is token number (1.11: 2) +Error: discarding token number (1.11: 2) Reading a token -Next token is token ')' (1.7: ) +Next token is token ')' (1.12: ) Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) +Entering state 29 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) +Next token is token '=' (1.14: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) +Entering state 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) Entering state 18 Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token -Next token is token '\n' (1.15-2.0: ) +Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -240165,27 +236741,13 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +input: +stderr: +./torture.at:551: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | 1 = 2 = 3 +./calc.at:1492: $PREPARSER ./calc input +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -240196,19 +236758,41 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1492: cat stderr stderr: -./calc.at:1491: cat stderr -input: - | (!!) + (1 2) = 1 -./calc.at:1492: $PREPARSER ./calc input -./calc.at:1494: cat stderr -./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror -stdout: stderr: Starting parse Entering state 0 Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 18 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 27 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Error: popping token '=' (1.3: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '=' (1.7: ) +./torture.at:553: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 900 +Starting parse +Entering state 0 +Reading a token Next token is token '(' (1.1: ) Shifting token '(' (1.1: ) Entering state 4 @@ -240317,27 +236901,55 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: -./torture.at:513: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 20 -input-lalr.y: warning: 65 shift/reduce conflicts [-Wconflicts-sr] -input-lalr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -stdout: -./existing.at:74: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1494: cat stderr + stderr: -input: +./torture.at:237: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: - | (1 + # + 1) = 1111 -stdout: +./torture.at:553: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 18 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 27 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Error: popping token '=' (1.3: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '=' (1.7: ) + | (!!) + (1 2) = 1 ./calc.at:1494: $PREPARSER ./calc input -./torture.at:551: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 20 -./torture.at:513: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./torture.at:551: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (# + 1) = 1111 -./calc.at:1491: $PREPARSER ./calc input -stderr: stderr: stderr: Starting parse @@ -240378,21 +236990,21 @@ Shifting token '(' (1.8: ) Entering state 4 Reading a token -Next token is token number (1.9: 1) -Shifting token number (1.9: 1) +Next token is token "number" (1.9: 1) +Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.9: 1) + $1 = token "number" (1.9: 1) -> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token -Next token is token number (1.11: 2) +Next token is token "number" (1.11: 2) 1.11: syntax error, unexpected number Error: popping nterm exp (1.9: 1) Shifting token error (1.9-11: ) Entering state 11 -Next token is token number (1.11: 2) -Error: discarding token number (1.11: 2) +Next token is token "number" (1.11: 2) +Error: discarding token "number" (1.11: 2) Reading a token Next token is token ')' (1.12: ) Entering state 11 @@ -240417,11 +237029,11 @@ Shifting token '=' (1.14: ) Entering state 18 Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.16: 1) + $1 = token "number" (1.16: 1) -> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token @@ -240447,12 +237059,32 @@ Entering state 6 Reading a token Now at end of input. -Shifting token end of input (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token end of input (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1491: cat stderr +./torture.at:555: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 10000 +./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1492: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -./existing.at:74: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +memory exhausted +memory exhausted +./torture.at:555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1492: cat stderr +./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none +stderr: +619. existing.at:808: testing GNU Cim Grammar: LALR(1) ... +input: Starting parse Entering state 0 Reading a token @@ -240460,139 +237092,98 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Reading a token -Next token is token number (1.6: 1) -Error: discarding token number (1.6: 1) +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 Reading a token -Next token is token ')' (1.7: ) +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 15 +Reducing stack 0 by rule 16 (line 107): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Shifting token error (1.2-3: ) Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 Reading a token -Now at end of input. -Shifting token end of input (2.1: ) -Entering state 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -Starting parse -Entering state 0 +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) +Entering state 20 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) Entering state 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) +Next token is token "number" (1.9: 1) +Shifting token "number" (1.9: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) + $1 = token "number" (1.9: 1) +-> $$ = nterm exp (1.9: 1) Entering state 12 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) +Next token is token "number" (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Shifting token error (1.9-11: ) Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) -Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Reading a token -Next token is token "number" (1.10: 1) -Error: discarding token "number" (1.10: 1) +Next token is token "number" (1.11: 2) +Error: discarding token "number" (1.11: 2) Reading a token -Next token is token ')' (1.11: ) +Next token is token ')' (1.12: ) Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) -Entering state 8 + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) +Entering state 29 Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) +Next token is token '=' (1.14: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) +Entering state 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) Entering state 18 Reading a token -Next token is token "number" (1.15-18: 1111) -Shifting token "number" (1.15-18: 1111) +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) Entering state 27 Reading a token -Next token is token '\n' (1.19-2.0: ) +Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -240606,17 +237197,18 @@ Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) stderr: -./torture.at:553: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 900 -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./torture.at:515: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 900 -stderr: -./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + | (- *) + (1 2) = 1 +./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y +./calc.at:1491: $PREPARSER ./calc input +memory exhausted +memory exhausted +input: +615. torture.at:531: ok + | + | +1 +./calc.at:1492: $PREPARSER ./calc input stderr: -./existing.at:74: sed -n 's/^State //p' input.output | tail -1 -./torture.at:553: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./torture.at:515: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./existing.at:74: sed 's/^%define lr.type .*$//' input.y > input-lalr.y -./calc.at:1492: "$PERL" -pi -e 'use strict; +./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -240626,9 +237218,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y -stderr: -stderr: Starting parse Entering state 0 Reading a token @@ -240636,56 +237225,103 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 Reading a token -Next token is token number (1.6: 1) -Error: discarding token number (1.6: 1) +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Reducing stack 0 by rule 15 (line 106): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Shifting token error (1.2-4: ) +Entering state 11 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) Reading a token -Next token is token ')' (1.7: ) +Next token is token ')' (1.5: ) Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 20 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Reading a token +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Reading a token +Next token is token number (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Shifting token error (1.10-12: ) +Entering state 11 +Next token is token number (1.12: 2) +Error: discarding token number (1.12: 2) +Reading a token +Next token is token ')' (1.13: ) +Entering state 11 +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 29 +Reading a token +Next token is token '=' (1.15: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) +Entering state 8 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) Entering state 18 Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) + $1 = token number (1.17: 1) +-> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token -Next token is token '\n' (1.15-2.0: ) +Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -240698,7 +237334,33 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1492: cat stderr +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Cleanup: discarding lookahead token '+' (2.1: ) +./calc.at:1494: cat stderr +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +input: +stderr: + Starting parse Entering state 0 Reading a token @@ -240706,70 +237368,103 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Reducing stack 0 by rule 15 (line 106): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Shifting token error (1.2-4: ) +Entering state 11 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) +Next token is token ')' (1.5: ) Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 20 Reading a token -Next token is token "number" (1.10: 1) -Error: discarding token "number" (1.10: 1) +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 Reading a token -Next token is token ')' (1.11: ) +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Reading a token +Next token is token number (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Shifting token error (1.10-12: ) Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token number (1.12: 2) +Error: discarding token number (1.12: 2) +Reading a token +Next token is token ')' (1.13: ) +Entering state 11 +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) -Entering state 8 + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 29 Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) +Next token is token '=' (1.15: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) +Entering state 8 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) Entering state 18 Reading a token -Next token is token "number" (1.15-18: 1111) -Shifting token "number" (1.15-18: 1111) +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) + $1 = token number (1.17: 1) +-> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token -Next token is token '\n' (1.19-2.0: ) +Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) Entering state 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -240778,10 +237473,31 @@ Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) +Shifting token end of input (2.1: ) Entering state 16 -Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) + | (- *) + (1 2) = 1 +./calc.at:1494: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Cleanup: discarding lookahead token '+' (2.1: ) stderr: ./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} @@ -240793,45 +237509,6 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -stderr: -./torture.at:555: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 10000 -./calc.at:1491: cat stderr -stderr: -./torture.at:517: VALGRIND_OPTS="$VALGRIND_OPTS --log-fd=1" $PREPARSER ./input 10000 -stderr: -memory exhausted -memory exhausted -input: -./torture.at:555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - | (- *) + (1 2) = 1 -./calc.at:1494: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -memory exhausted -memory exhausted -stdout: -input: -./calc.at:1492: $PREPARSER ./calc input -./torture.at:517: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./torture.at:238: $PREPARSER ./input -./calc.at:1494: cat stderr - | (1 + # + 1) = 1111 -./calc.at:1491: $PREPARSER ./calc input -stderr: -stderr: -stderr: -memory exhausted -memory exhausted -stderr: -615. torture.at:531: ok Starting parse Entering state 0 Reading a token @@ -240839,70 +237516,103 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Reducing stack 0 by rule 15 (line 106): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Shifting token error (1.2-4: ) +Entering state 11 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) +Next token is token ')' (1.5: ) Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 20 Reading a token -Next token is token number (1.10: 1) -Error: discarding token number (1.10: 1) +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 Reading a token -Next token is token ')' (1.11: ) +Next token is token "number" (1.10: 1) +Shifting token "number" (1.10: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Reading a token +Next token is token "number" (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Shifting token error (1.10-12: ) Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token "number" (1.12: 2) +Error: discarding token "number" (1.12: 2) +Reading a token +Next token is token ')' (1.13: ) +Entering state 11 +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) -Entering state 8 + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 29 Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) +Next token is token '=' (1.15: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) +Entering state 8 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) Entering state 18 Reading a token -Next token is token number (1.15-18: 1111) -Shifting token number (1.15-18: 1111) +Next token is token "number" (1.17: 1) +Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) + $1 = token "number" (1.17: 1) +-> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token -Next token is token '\n' (1.19-2.0: ) +Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) Entering state 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -240911,15 +237621,34 @@ Entering state 6 Reading a token Now at end of input. -Shifting token end of input (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token end of input (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./torture.at:238: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1492: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1491: cat stderr +./calc.at:1492: cat stderr +./calc.at:1492: $PREPARSER ./calc /dev/null +./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror stderr: -memory exhausted -memory exhausted -605. torture.at:216: ok +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Now at end of input. +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token end of input (1.1: ) Starting parse Entering state 0 Reading a token @@ -240963,21 +237692,21 @@ Shifting token '(' (1.9: ) Entering state 4 Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) +Next token is token "number" (1.10: 1) +Shifting token "number" (1.10: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.10: 1) + $1 = token "number" (1.10: 1) -> $$ = nterm exp (1.10: 1) Entering state 12 Reading a token -Next token is token number (1.12: 2) +Next token is token "number" (1.12: 2) 1.12: syntax error, unexpected number Error: popping nterm exp (1.10: 1) Shifting token error (1.10-12: ) Entering state 11 -Next token is token number (1.12: 2) -Error: discarding token number (1.12: 2) +Next token is token "number" (1.12: 2) +Error: discarding token "number" (1.12: 2) Reading a token Next token is token ')' (1.13: ) Entering state 11 @@ -241002,11 +237731,11 @@ Shifting token '=' (1.15: ) Entering state 18 Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) +Next token is token "number" (1.17: 1) +Shifting token "number" (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.17: 1) + $1 = token "number" (1.17: 1) -> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token @@ -241032,19 +237761,34 @@ Entering state 6 Reading a token Now at end of input. -Shifting token end of input (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token end of input (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) input: -614. torture.at:485: ok - | (1 + 1) / (1 - 1) -./calc.at:1494: $PREPARSER ./calc input -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +stdout: + | (* *) + (*) + (*) ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./existing.at:74: $PREPARSER ./input +./existing.at:74: sed -n 's/^State //p' input.output | tail -1 +./calc.at:1491: $PREPARSER ./calc input +stderr: +stderr: +620. existing.at:808: testing GNU Cim Grammar: IELR(1) ... +syntax error, unexpected '*', expecting NEWLINE or '{' or ';' +./existing.at:74: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y +./calc.at:1494: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: - Starting parse Entering state 0 Reading a token @@ -241052,101 +237796,239 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Reading a token +Next token is token ')' (1.5: ) +Entering state 11 +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) Entering state 20 Reading a token -Next token is token "number" (1.6: 1) -Shifting token "number" (1.6: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.6: 1) --> $$ = nterm exp (1.6: 1) +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Reading a token +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) +Entering state 11 +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) +Reading a token +Next token is token ')' (1.11: ) +Entering state 11 +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token -Next token is token ')' (1.7: ) +Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) +Entering state 8 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 20 +Reading a token +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 +Reading a token +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) +Reading a token +Next token is token ')' (1.17: ) +Entering state 11 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 29 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) +Entering state 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input (2.1: ) +Entering state 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +Starting parse +Entering state 0 +Reading a token +Now at end of input. +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token end of input (1.1: ) +./calc.at:1494: cat stderr +./existing.at:74: sed 's/^%define lr.type .*$//' input.y > input-lalr.y +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +616. existing.at:74: ok +./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y +stderr: +input: +./calc.at:1492: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) +Reading a token +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Reading a token +Next token is token ')' (1.5: ) +Entering state 11 +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) Entering state 8 Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 22 +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 20 Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) Entering state 4 Reading a token -Next token is token "number" (1.12: 1) -Shifting token "number" (1.12: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) +Entering state 11 +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 19 +Next token is token ')' (1.11: ) +Entering state 11 +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) +Entering state 29 Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 28 +Next token is token '+' (1.13: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) +Entering state 8 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 20 +Reading a token +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 +Reading a token +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) Reading a token Next token is token ')' (1.17: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 +Entering state 11 Next token is token ')' (1.17: ) Shifting token ')' (1.17: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 31 +-> $$ = nterm exp (1.15-17: 1111) +Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2) + $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 @@ -241156,10 +238038,24 @@ Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) +Shifting token end of input (2.1: ) Entering state 16 -Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) + | (* *) + (*) + (*) +./calc.at:1494: $PREPARSER ./calc input +stderr: +./calc.at:1492: cat stderr +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -241167,32 +238063,42 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) +Next token is token ')' (1.5: ) Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 20 Reading a token -Next token is token number (1.10: 1) -Error: discarding token number (1.10: 1) +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Reading a token +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) +Entering state 11 +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) Reading a token Next token is token ')' (1.11: ) Entering state 11 @@ -241200,37 +238106,59 @@ Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) + $1 = token '(' (1.9: ) + $2 = token error (1.10: ) $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) +-> $$ = nterm exp (1.9-11: 1111) +Entering state 29 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) Entering state 8 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 20 Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) -Entering state 18 +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 Reading a token -Next token is token number (1.15-18: 1111) -Shifting token number (1.15-18: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) -Entering state 27 +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) Reading a token -Next token is token '\n' (1.19-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) +Next token is token ')' (1.17: ) +Entering state 11 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 29 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) Entering state 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) + $1 = nterm exp (1.1-17: 3333) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -241239,17 +238167,29 @@ Entering state 6 Reading a token Now at end of input. -Shifting token end of input (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token end of input (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1491: cat stderr +./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -input-lalr.y: warning: 65 shift/reduce conflicts [-Wconflicts-sr] -input-lalr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -stderr: stdout: -./existing.at:74: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' +stderr: +input: +./calc.at:1494: "$PERL" -ne ' + chomp; + print "$ARGV:$.: {$_}\n" + if (# No starting/ending empty lines. + (eof || $. == 1) && /^\s*$/ + # No trailing space. + || /\s$/ + # No tabs. + || /\t/ + )' calc.cc calc.hh + +./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror Starting parse Entering state 0 Reading a token @@ -241257,19 +238197,13 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token '-' (1.2: ) -Shifting token '-' (1.2: ) -Entering state 2 -Reading a token -Next token is token '*' (1.4: ) -1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' -Shifting token error (1.4: ) -Entering state 9 -Reducing stack 0 by rule 15 (line 106): - $1 = token '-' (1.2: ) - $2 = token error (1.4: ) -Shifting token error (1.2-4: ) +Next token is token '*' (1.2: ) +1.2: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) Entering state 11 +Next token is token '*' (1.2: ) +Error: discarding token '*' (1.2: ) +Reading a token Next token is token '*' (1.4: ) Error: discarding token '*' (1.4: ) Reading a token @@ -241293,66 +238227,71 @@ Shifting token '(' (1.9: ) Entering state 4 Reading a token -Next token is token number (1.10: 1) -Shifting token number (1.10: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.10: 1) --> $$ = nterm exp (1.10: 1) -Entering state 12 -Reading a token -Next token is token number (1.12: 2) -1.12: syntax error, unexpected number -Error: popping nterm exp (1.10: 1) -Shifting token error (1.10-12: ) +Next token is token '*' (1.10: ) +1.10: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.10: ) Entering state 11 -Next token is token number (1.12: 2) -Error: discarding token number (1.12: 2) +Next token is token '*' (1.10: ) +Error: discarding token '*' (1.10: ) Reading a token -Next token is token ')' (1.13: ) +Next token is token ')' (1.11: ) Entering state 11 -Next token is token ')' (1.13: ) -Shifting token ')' (1.13: ) +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.9: ) - $2 = token error (1.10-12: ) - $3 = token ')' (1.13: ) --> $$ = nterm exp (1.9-13: 1111) + $2 = token error (1.10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.9-11: 1111) Entering state 29 Reading a token -Next token is token '=' (1.15: ) +Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): $1 = nterm exp (1.1-5: 1111) $2 = token '+' (1.7: ) - $3 = nterm exp (1.9-13: 1111) --> $$ = nterm exp (1.1-13: 2222) + $3 = nterm exp (1.9-11: 1111) +-> $$ = nterm exp (1.1-11: 2222) Entering state 8 -Next token is token '=' (1.15: ) -Shifting token '=' (1.15: ) -Entering state 18 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 20 Reading a token -Next token is token number (1.17: 1) -Shifting token number (1.17: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.17: 1) --> $$ = nterm exp (1.17: 1) -Entering state 27 +Next token is token '(' (1.15: ) +Shifting token '(' (1.15: ) +Entering state 4 +Reading a token +Next token is token '*' (1.16: ) +1.16: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.16: ) +Entering state 11 +Next token is token '*' (1.16: ) +Error: discarding token '*' (1.16: ) +Reading a token +Next token is token ')' (1.17: ) +Entering state 11 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.15: ) + $2 = token error (1.16: ) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.15-17: 1111) +Entering state 29 Reading a token Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-13: 2222) - $2 = token '=' (1.15: ) - $3 = nterm exp (1.17: 1) -1.1-17: error: 2222 != 1 --> $$ = nterm exp (1.1-17: 2222) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-11: 2222) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15-17: 1111) +-> $$ = nterm exp (1.1-17: 3333) Entering state 8 Next token is token '\n' (1.18-2.0: ) Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2222) + $1 = nterm exp (1.1-17: 3333) $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 @@ -241362,24 +238301,17 @@ Entering state 6 Reading a token Now at end of input. -Shifting token end of input (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token end of input (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./existing.at:74: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS - + | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 +input: +./calc.at:1492: $PREPARSER ./calc input + | 1 + 2 * 3 + !+ ++ +./calc.at:1491: $PREPARSER ./calc input +stderr: stderr: -./calc.at:1491: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -241387,102 +238319,234 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token "number" (1.2: 1) -Shifting token "number" (1.2: 1) +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Reading a token +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Reading a token +Next token is token number (1.7: 1) +Shifting token number (1.7: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.2: 1) --> $$ = nterm exp (1.2: 1) + $1 = token number (1.7: 1) +-> $$ = nterm exp (1.7: 1) Entering state 12 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) Entering state 20 Reading a token -Next token is token "number" (1.6: 1) -Shifting token "number" (1.6: 1) +Next token is token number (1.11: 1) +Shifting token number (1.11: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.6: 1) --> $$ = nterm exp (1.6: 1) + $1 = token number (1.11: 1) +-> $$ = nterm exp (1.11: 1) Entering state 29 Reading a token -Next token is token ')' (1.7: ) +Next token is token '+' (1.13: ) Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) Entering state 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 20 +Reading a token +Next token is token number (1.15: 1) +Shifting token number (1.15: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 29 +Reading a token +Next token is token '+' (1.17: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 20 +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Error: popping nterm exp (1.7-15: 3) +Shifting token error (1.7-18: ) +Entering state 11 +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 29 +Reading a token +Next token is token '+' (1.20: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) Entering state 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 20 Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 22 +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) +Entering state 11 +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) +Reading a token +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Reading a token +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Reading a token +Next token is token ')' (1.28: ) +Entering state 11 +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 29 +Reading a token +Next token is token '+' (1.30: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) +Entering state 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +Entering state 20 +Reading a token +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) Entering state 4 Reading a token -Next token is token "number" (1.12: 1) -Shifting token "number" (1.12: 1) +Next token is token number (1.33: 1) +Shifting token number (1.33: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.12: 1) --> $$ = nterm exp (1.12: 1) + $1 = token number (1.33: 1) +-> $$ = nterm exp (1.33: 1) Entering state 12 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 19 +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 21 Reading a token -Next token is token "number" (1.16: 1) -Shifting token "number" (1.16: 1) +Next token is token number (1.37: 2) +Shifting token number (1.37: 2) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token "number" (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 28 + $1 = token number (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 30 Reading a token -Next token is token ')' (1.17: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) +Next token is token '*' (1.39: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) Entering state 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 31 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 21 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Error: popping nterm exp (1.33-37: 2) +Shifting token error (1.33-41: ) +Entering state 11 +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) +Reading a token +Next token is token ')' (1.42: ) +Entering state 11 +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) +Entering state 29 +Reading a token +Next token is token '=' (1.44: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) +Entering state 18 +Reading a token +Next token is token number (1.46: 1) +Shifting token number (1.46: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.46: 1) +-> $$ = nterm exp (1.46: 1) +Entering state 27 +Reading a token +Next token is token '\n' (1.47-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) +Entering state 8 +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -241491,35 +238555,76 @@ Entering state 6 Reading a token Now at end of input. -Shifting token "end of input" (2.1: ) +Shifting token end of input (2.1: ) Entering state 16 -Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: -stdout: -./calc.at:1494: "$PERL" -ne ' - chomp; - print "$ARGV:$.: {$_}\n" - if (# No starting/ending empty lines. - (eof || $. == 1) && /^\s*$/ - # No trailing space. - || /\s$/ - # No tabs. - || /\t/ - )' calc.cc calc.hh - -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1491: cat stderr input: +Starting parse +Entering state 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 20 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Reducing stack 0 by rule 17 (line 108): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) | 1 + 2 * 3 = 7 | 1 + 2 * -3 = -5 | @@ -241534,6 +238639,7 @@ | 2^2^3 = 256 | (2^2)^3 = 64 ./calc.at:1494: $PREPARSER ./calc input +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -241544,10 +238650,8 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1492: cat stderr -619. existing.at:808: testing GNU Cim Grammar: LALR(1) ... +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y Starting parse Entering state 0 Reading a token @@ -242384,10 +239488,333 @@ Entering state 16 Cleanup: popping token end of input (14.1: ) Cleanup: popping nterm input (1.1-14.0: ) +./calc.at:1494: cat stderr +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token ')' (1.2: ) +1.2: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Shifting token error (1.2: ) +Entering state 11 +Next token is token ')' (1.2: ) +Shifting token ')' (1.2: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.2: ) +-> $$ = nterm exp (1.1-2: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Reading a token +Next token is token '(' (1.6: ) +Shifting token '(' (1.6: ) +Entering state 4 +Reading a token +Next token is token number (1.7: 1) +Shifting token number (1.7: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.7: 1) +-> $$ = nterm exp (1.7: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.9: ) +Shifting token '+' (1.9: ) +Entering state 20 +Reading a token +Next token is token number (1.11: 1) +Shifting token number (1.11: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.11: 1) +-> $$ = nterm exp (1.11: 1) +Entering state 29 +Reading a token +Next token is token '+' (1.13: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.7: 1) + $2 = token '+' (1.9: ) + $3 = nterm exp (1.11: 1) +-> $$ = nterm exp (1.7-11: 2) +Entering state 12 +Next token is token '+' (1.13: ) +Shifting token '+' (1.13: ) +Entering state 20 +Reading a token +Next token is token number (1.15: 1) +Shifting token number (1.15: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.15: 1) +-> $$ = nterm exp (1.15: 1) +Entering state 29 +Reading a token +Next token is token '+' (1.17: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.7-11: 2) + $2 = token '+' (1.13: ) + $3 = nterm exp (1.15: 1) +-> $$ = nterm exp (1.7-15: 3) +Entering state 12 +Next token is token '+' (1.17: ) +Shifting token '+' (1.17: ) +Entering state 20 +Reading a token +Next token is token ')' (1.18: ) +1.18: syntax error, unexpected ')', expecting number or '-' or '(' or '!' +Error: popping token '+' (1.17: ) +Error: popping nterm exp (1.7-15: 3) +Shifting token error (1.7-18: ) +Entering state 11 +Next token is token ')' (1.18: ) +Shifting token ')' (1.18: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.6: ) + $2 = token error (1.7-18: ) + $3 = token ')' (1.18: ) +-> $$ = nterm exp (1.6-18: 1111) +Entering state 29 +Reading a token +Next token is token '+' (1.20: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-2: 1111) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6-18: 1111) +-> $$ = nterm exp (1.1-18: 2222) +Entering state 8 +Next token is token '+' (1.20: ) +Shifting token '+' (1.20: ) +Entering state 20 +Reading a token +Next token is token '(' (1.22: ) +Shifting token '(' (1.22: ) +Entering state 4 +Reading a token +Next token is token '*' (1.23: ) +1.23: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.23: ) +Entering state 11 +Next token is token '*' (1.23: ) +Error: discarding token '*' (1.23: ) +Reading a token +Next token is token '*' (1.25: ) +Error: discarding token '*' (1.25: ) +Reading a token +Next token is token '*' (1.27: ) +Error: discarding token '*' (1.27: ) +Reading a token +Next token is token ')' (1.28: ) +Entering state 11 +Next token is token ')' (1.28: ) +Shifting token ')' (1.28: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.22: ) + $2 = token error (1.23-27: ) + $3 = token ')' (1.28: ) +-> $$ = nterm exp (1.22-28: 1111) +Entering state 29 +Reading a token +Next token is token '+' (1.30: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-18: 2222) + $2 = token '+' (1.20: ) + $3 = nterm exp (1.22-28: 1111) +-> $$ = nterm exp (1.1-28: 3333) +Entering state 8 +Next token is token '+' (1.30: ) +Shifting token '+' (1.30: ) +Entering state 20 +Reading a token +Next token is token '(' (1.32: ) +Shifting token '(' (1.32: ) +Entering state 4 +Reading a token +Next token is token number (1.33: 1) +Shifting token number (1.33: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.33: 1) +-> $$ = nterm exp (1.33: 1) +Entering state 12 +Reading a token +Next token is token '*' (1.35: ) +Shifting token '*' (1.35: ) +Entering state 21 +Reading a token +Next token is token number (1.37: 2) +Shifting token number (1.37: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.37: 2) +-> $$ = nterm exp (1.37: 2) +Entering state 30 +Reading a token +Next token is token '*' (1.39: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.33: 1) + $2 = token '*' (1.35: ) + $3 = nterm exp (1.37: 2) +-> $$ = nterm exp (1.33-37: 2) +Entering state 12 +Next token is token '*' (1.39: ) +Shifting token '*' (1.39: ) +Entering state 21 +Reading a token +Next token is token '*' (1.41: ) +1.41: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Error: popping token '*' (1.39: ) +Error: popping nterm exp (1.33-37: 2) +Shifting token error (1.33-41: ) +Entering state 11 +Next token is token '*' (1.41: ) +Error: discarding token '*' (1.41: ) +Reading a token +Next token is token ')' (1.42: ) +Entering state 11 +Next token is token ')' (1.42: ) +Shifting token ')' (1.42: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.32: ) + $2 = token error (1.33-41: ) + $3 = token ')' (1.42: ) +-> $$ = nterm exp (1.32-42: 1111) +Entering state 29 +Reading a token +Next token is token '=' (1.44: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-28: 3333) + $2 = token '+' (1.30: ) + $3 = nterm exp (1.32-42: 1111) +-> $$ = nterm exp (1.1-42: 4444) +Entering state 8 +Next token is token '=' (1.44: ) +Shifting token '=' (1.44: ) +Entering state 18 +Reading a token +Next token is token number (1.46: 1) +Shifting token number (1.46: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.46: 1) +-> $$ = nterm exp (1.46: 1) +Entering state 27 +Reading a token +Next token is token '\n' (1.47-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-42: 4444) + $2 = token '=' (1.44: ) + $3 = nterm exp (1.46: 1) +1.1-46: error: 4444 != 1 +-> $$ = nterm exp (1.1-46: 4444) +Entering state 8 +Next token is token '\n' (1.47-2.0: ) +Shifting token '\n' (1.47-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-46: 4444) + $2 = token '\n' (1.47-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input (2.1: ) +Entering state 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -620. existing.at:808: testing GNU Cim Grammar: IELR(1) ... -./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y +Starting parse +Entering state 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 20 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Reducing stack 0 by rule 17 (line 108): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +stderr: +621. existing.at:808: testing GNU Cim Grammar: Canonical LR(1) ... +stdout: +stderr: +input: stderr: +input-lalr.y: warning: 65 shift/reduce conflicts [-Wconflicts-sr] +input-lalr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y +input: +./torture.at:238: $PREPARSER ./input Starting parse Entering state 0 Reading a token @@ -242994,253 +240421,1955 @@ -> $$ = nterm exp (10.5-11: -1) Entering state 28 Reading a token -Next token is token '=' (10.13: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (10.1: 1) - $2 = token '-' (10.3: ) - $3 = nterm exp (10.5-11: -1) --> $$ = nterm exp (10.1-11: 2) +Next token is token '=' (10.13: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (10.1: 1) + $2 = token '-' (10.3: ) + $3 = nterm exp (10.5-11: -1) +-> $$ = nterm exp (10.1-11: 2) +Entering state 8 +Next token is token '=' (10.13: ) +Shifting token '=' (10.13: ) +Entering state 18 +Reading a token +Next token is token number (10.15: 2) +Shifting token number (10.15: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (10.15: 2) +-> $$ = nterm exp (10.15: 2) +Entering state 27 +Reading a token +Next token is token '\n' (10.16-11.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (10.1-11: 2) + $2 = token '=' (10.13: ) + $3 = nterm exp (10.15: 2) +-> $$ = nterm exp (10.1-15: 2) +Entering state 8 +Next token is token '\n' (10.16-11.0: ) +Shifting token '\n' (10.16-11.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (10.1-15: 2) + $2 = token '\n' (10.16-11.0: ) +-> $$ = nterm line (10.1-11.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-10.0: ) + $2 = nterm line (10.1-11.0: ) +-> $$ = nterm input (1.1-11.0: ) +Entering state 6 +Reading a token +Next token is token '\n' (11.1-12.0: ) +Shifting token '\n' (11.1-12.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (11.1-12.0: ) +-> $$ = nterm line (11.1-12.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-11.0: ) + $2 = nterm line (11.1-12.0: ) +-> $$ = nterm input (1.1-12.0: ) +Entering state 6 +Reading a token +Next token is token number (12.1: 2) +Shifting token number (12.1: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (12.1: 2) +-> $$ = nterm exp (12.1: 2) +Entering state 8 +Reading a token +Next token is token '^' (12.2: ) +Shifting token '^' (12.2: ) +Entering state 23 +Reading a token +Next token is token number (12.3: 2) +Shifting token number (12.3: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (12.3: 2) +-> $$ = nterm exp (12.3: 2) +Entering state 32 +Reading a token +Next token is token '^' (12.4: ) +Shifting token '^' (12.4: ) +Entering state 23 +Reading a token +Next token is token number (12.5: 3) +Shifting token number (12.5: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (12.5: 3) +-> $$ = nterm exp (12.5: 3) +Entering state 32 +Reading a token +Next token is token '=' (12.7: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (12.3: 2) + $2 = token '^' (12.4: ) + $3 = nterm exp (12.5: 3) +-> $$ = nterm exp (12.3-5: 8) +Entering state 32 +Next token is token '=' (12.7: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (12.1: 2) + $2 = token '^' (12.2: ) + $3 = nterm exp (12.3-5: 8) +-> $$ = nterm exp (12.1-5: 256) +Entering state 8 +Next token is token '=' (12.7: ) +Shifting token '=' (12.7: ) +Entering state 18 +Reading a token +Next token is token number (12.9-11: 256) +Shifting token number (12.9-11: 256) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (12.9-11: 256) +-> $$ = nterm exp (12.9-11: 256) +Entering state 27 +Reading a token +Next token is token '\n' (12.12-13.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (12.1-5: 256) + $2 = token '=' (12.7: ) + $3 = nterm exp (12.9-11: 256) +-> $$ = nterm exp (12.1-11: 256) +Entering state 8 +Next token is token '\n' (12.12-13.0: ) +Shifting token '\n' (12.12-13.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (12.1-11: 256) + $2 = token '\n' (12.12-13.0: ) +-> $$ = nterm line (12.1-13.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-12.0: ) + $2 = nterm line (12.1-13.0: ) +-> $$ = nterm input (1.1-13.0: ) +Entering state 6 +Reading a token +Next token is token '(' (13.1: ) +Shifting token '(' (13.1: ) +Entering state 4 +Reading a token +Next token is token number (13.2: 2) +Shifting token number (13.2: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (13.2: 2) +-> $$ = nterm exp (13.2: 2) +Entering state 12 +Reading a token +Next token is token '^' (13.3: ) +Shifting token '^' (13.3: ) +Entering state 23 +Reading a token +Next token is token number (13.4: 2) +Shifting token number (13.4: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (13.4: 2) +-> $$ = nterm exp (13.4: 2) +Entering state 32 +Reading a token +Next token is token ')' (13.5: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (13.2: 2) + $2 = token '^' (13.3: ) + $3 = nterm exp (13.4: 2) +-> $$ = nterm exp (13.2-4: 4) +Entering state 12 +Next token is token ')' (13.5: ) +Shifting token ')' (13.5: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (13.1: ) + $2 = nterm exp (13.2-4: 4) + $3 = token ')' (13.5: ) +-> $$ = nterm exp (13.1-5: 4) +Entering state 8 +Reading a token +Next token is token '^' (13.6: ) +Shifting token '^' (13.6: ) +Entering state 23 +Reading a token +Next token is token number (13.7: 3) +Shifting token number (13.7: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (13.7: 3) +-> $$ = nterm exp (13.7: 3) +Entering state 32 +Reading a token +Next token is token '=' (13.9: ) +Reducing stack 0 by rule 12 (line 103): + $1 = nterm exp (13.1-5: 4) + $2 = token '^' (13.6: ) + $3 = nterm exp (13.7: 3) +-> $$ = nterm exp (13.1-7: 64) +Entering state 8 +Next token is token '=' (13.9: ) +Shifting token '=' (13.9: ) +Entering state 18 +Reading a token +Next token is token number (13.11-12: 64) +Shifting token number (13.11-12: 64) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (13.11-12: 64) +-> $$ = nterm exp (13.11-12: 64) +Entering state 27 +Reading a token +Next token is token '\n' (13.13-14.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (13.1-7: 64) + $2 = token '=' (13.9: ) + $3 = nterm exp (13.11-12: 64) +-> $$ = nterm exp (13.1-12: 64) +Entering state 8 +Next token is token '\n' (13.13-14.0: ) +Shifting token '\n' (13.13-14.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (13.1-12: 64) + $2 = token '\n' (13.13-14.0: ) +-> $$ = nterm line (13.1-14.0: ) +Entering state 17 +Reducing stack 0 by rule 2 (line 70): + $1 = nterm input (1.1-13.0: ) + $2 = nterm line (13.1-14.0: ) +-> $$ = nterm input (1.1-14.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input (14.1: ) +Entering state 16 +Cleanup: popping token end of input (14.1: ) +Cleanup: popping nterm input (1.1-14.0: ) +stdout: + | 1 + 2 * 3 + !- ++ +./calc.at:1491: $PREPARSER ./calc input + | 1 + 2 * 3 + !+ ++ +./calc.at:1492: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: +./existing.at:74: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' +./calc.at:1494: $PREPARSER ./calc input +stderr: +stderr: + | 1 2 +./torture.at:238: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1494: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 20 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Reducing stack 0 by rule 18 (line 109): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1492: cat stderr +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Reading a token +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 20 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Reducing stack 0 by rule 17 (line 108): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +Starting parse +Entering state 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token number (1.3: 2) +./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token number (1.3: 2) +1.3: syntax error, unexpected number +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token number (1.3: 2) +605. torture.at:216: ok +stderr: +./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror +stderr: +./calc.at:1494: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./existing.at:74: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +Starting parse +Entering state 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Reading a token +Next token is token number (1.9: 3) +Shifting token number (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 20 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Reducing stack 0 by rule 18 (line 109): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Reading a token +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 20 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '+' (1.14: ) +Shifting token '+' (1.14: ) +Entering state 14 +Reducing stack 0 by rule 17 (line 108): + $1 = token '!' (1.13: ) + $2 = token '+' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +input: +input: +./calc.at:1494: cat stderr + | (!!) + (1 2) = 1 +./calc.at:1492: $PREPARSER ./calc input + | 1 + 2 * 3 + !- ++ +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1494: $PREPARSER ./calc input +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Reading a token +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 15 +Reducing stack 0 by rule 16 (line 107): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Shifting token error (1.2-3: ) +Entering state 11 +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) +Entering state 20 +Reading a token +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) +Entering state 4 +Reading a token +Next token is token number (1.9: 1) +Shifting token number (1.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.9: 1) +-> $$ = nterm exp (1.9: 1) +Entering state 12 +Reading a token +Next token is token number (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Shifting token error (1.9-11: ) +Entering state 11 +Next token is token number (1.11: 2) +Error: discarding token number (1.11: 2) +Reading a token +Next token is token ')' (1.12: ) +Entering state 11 +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) +Entering state 29 +Reading a token +Next token is token '=' (1.14: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) +Entering state 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) +Entering state 18 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 27 +Reading a token +Next token is token '\n' (1.17-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input (2.1: ) +Entering state 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) + +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Reading a token +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 20 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Reducing stack 0 by rule 18 (line 109): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +input: +./calc.at:1491: cat stderr + | 1//2 +./calc.at:1494: $PREPARSER ./calc input +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 22 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '/' (1.3: ) +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '!' (1.2: ) +Shifting token '!' (1.2: ) +Entering state 5 +Reading a token +Next token is token '!' (1.3: ) +Shifting token '!' (1.3: ) +Entering state 15 +Reducing stack 0 by rule 16 (line 107): + $1 = token '!' (1.2: ) + $2 = token '!' (1.3: ) +Shifting token error (1.2-3: ) +Entering state 11 +Reading a token +Next token is token ')' (1.4: ) +Shifting token ')' (1.4: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-3: ) + $3 = token ')' (1.4: ) +-> $$ = nterm exp (1.1-4: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.6: ) +Shifting token '+' (1.6: ) +Entering state 20 +Reading a token +Next token is token '(' (1.8: ) +Shifting token '(' (1.8: ) +Entering state 4 +Reading a token +Next token is token number (1.9: 1) +Shifting token number (1.9: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.9: 1) +-> $$ = nterm exp (1.9: 1) +Entering state 12 +Reading a token +Next token is token number (1.11: 2) +1.11: syntax error, unexpected number +Error: popping nterm exp (1.9: 1) +Shifting token error (1.9-11: ) +Entering state 11 +Next token is token number (1.11: 2) +Error: discarding token number (1.11: 2) +Reading a token +Next token is token ')' (1.12: ) +Entering state 11 +Next token is token ')' (1.12: ) +Shifting token ')' (1.12: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.8: ) + $2 = token error (1.9-11: ) + $3 = token ')' (1.12: ) +-> $$ = nterm exp (1.8-12: 1111) +Entering state 29 +Reading a token +Next token is token '=' (1.14: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-4: 1111) + $2 = token '+' (1.6: ) + $3 = nterm exp (1.8-12: 1111) +-> $$ = nterm exp (1.1-12: 2222) +Entering state 8 +Next token is token '=' (1.14: ) +Shifting token '=' (1.14: ) +Entering state 18 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 27 +Reading a token +Next token is token '\n' (1.17-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-12: 2222) + $2 = token '=' (1.14: ) + $3 = nterm exp (1.16: 1) +1.1-16: error: 2222 != 1 +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input (2.1: ) +Entering state 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +input: +./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: + | (#) + (#) = 2222 +./calc.at:1491: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token "number" (1.1: 1) +Shifting token "number" (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '+' (1.3: ) +Shifting token '+' (1.3: ) +Entering state 20 +Reading a token +Next token is token "number" (1.5: 2) +Shifting token "number" (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 29 +Reading a token +Next token is token '*' (1.7: ) +Shifting token '*' (1.7: ) +Entering state 21 +Reading a token +Next token is token "number" (1.9: 3) +Shifting token "number" (1.9: 3) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.9: 3) +-> $$ = nterm exp (1.9: 3) +Entering state 30 +Reading a token +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 9 (line 92): + $1 = nterm exp (1.5: 2) + $2 = token '*' (1.7: ) + $3 = nterm exp (1.9: 3) +-> $$ = nterm exp (1.5-9: 6) +Entering state 29 +Next token is token '+' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1: 1) + $2 = token '+' (1.3: ) + $3 = nterm exp (1.5-9: 6) +-> $$ = nterm exp (1.1-9: 7) +Entering state 8 +Next token is token '+' (1.11: ) +Shifting token '+' (1.11: ) +Entering state 20 +Reading a token +Next token is token '!' (1.13: ) +Shifting token '!' (1.13: ) +Entering state 5 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 13 +Reducing stack 0 by rule 18 (line 109): + $1 = token '!' (1.13: ) + $2 = token '-' (1.14: ) +Cleanup: popping token '+' (1.11: ) +Cleanup: popping nterm exp (1.1-9: 7) +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) +Reading a token +Next token is token ')' (1.3: ) +Entering state 11 +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) +Entering state 20 +Reading a token +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Reading a token +1.8: syntax error: invalid character: '#' +Next token is token error (1.8: ) +Shifting token error (1.8: ) +Entering state 11 +Next token is token error (1.8: ) +Error: discarding token error (1.8: ) +Reading a token +Next token is token ')' (1.9: ) +Entering state 11 +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 29 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) +Entering state 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 18 +Reading a token +Next token is token number (1.13-16: 2222) +Shifting token number (1.13-16: 2222) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) +Entering state 27 +Reading a token +Next token is token '\n' (1.17-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input (2.1: ) +Entering state 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1492: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Reading a token +Next token is token number (1.1: 1) +Shifting token number (1.1: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.1: 1) +-> $$ = nterm exp (1.1: 1) +Entering state 8 +Reading a token +Next token is token '/' (1.2: ) +Shifting token '/' (1.2: ) +Entering state 22 +Reading a token +Next token is token '/' (1.3: ) +1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' +Error: popping token '/' (1.2: ) +Error: popping nterm exp (1.1: 1) +Cleanup: discarding lookahead token '/' (1.3: ) +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1494: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1492: cat stderr +./calc.at:1494: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) +Reading a token +Next token is token ')' (1.3: ) +Entering state 11 +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) +Entering state 20 +Reading a token +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Reading a token +1.8: syntax error: invalid character: '#' +Next token is token error (1.8: ) +Shifting token error (1.8: ) +Entering state 11 +Next token is token error (1.8: ) +Error: discarding token error (1.8: ) +Reading a token +Next token is token ')' (1.9: ) +Entering state 11 +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 29 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) +Entering state 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 18 +Reading a token +Next token is token number (1.13-16: 2222) +Shifting token number (1.13-16: 2222) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) +Entering state 27 +Reading a token +Next token is token '\n' (1.17-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input (2.1: ) +Entering state 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +622. existing.at:1460: testing GNU pic (Groff 1.18.1) Grammar: LALR(1) ... +./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y +stderr: +./calc.at:1494: cat stderr +./calc.at:1494: cat stderr +input.y:128.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:137.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:142.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:161.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:179.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:205.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:213.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:225.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:292.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:294.20: error: empty rule without %empty [-Werror=empty-rule] +input.y:367.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:373.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:387.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:401.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:413.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:443.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:471.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:474.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:489.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:506.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:587.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:591.18: error: empty rule without %empty [-Werror=empty-rule] +input.y: error: 78 shift/reduce conflicts [-Werror=conflicts-sr] +input.y: error: 10 reduce/reduce conflicts [-Werror=conflicts-rr] +input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +input.y:72.1-5: error: useless associativity for HQUA, use %precedence [-Werror=precedence] +input.y:53.1-6: error: useless associativity for HASSIGN, use %precedence [-Werror=precedence] +input.y:54.1-5: error: useless associativity for HORELSE, use %precedence [-Werror=precedence] +input.y:55.1-5: error: useless associativity for HANDTHEN, use %precedence [-Werror=precedence] +input.y:61.1-5: error: useless associativity for HNOT, use %precedence [-Werror=precedence] +input.y:68.1-5: error: useless associativity for UNEAR, use %precedence [-Werror=precedence] +input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] +input: +stderr: +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 + | (- *) + (1 2) = 1 +input: +./calc.at:1492: $PREPARSER ./calc input +stdout: + | error +./calc.at:1494: $PREPARSER ./calc input +input: +stderr: +./torture.at:141: $PREPARSER ./input +stderr: + | (#) + (#) = 2222 +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) +./existing.at:808: sed 's,.*/$,,' stderr 1>&2 +./calc.at:1494: $PREPARSER ./calc input +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Reading a token +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Reducing stack 0 by rule 15 (line 106): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Shifting token error (1.2-4: ) +Entering state 11 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Reading a token +Next token is token ')' (1.5: ) +Entering state 11 +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 20 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Reading a token +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Reading a token +Next token is token number (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Shifting token error (1.10-12: ) +Entering state 11 +Next token is token number (1.12: 2) +Error: discarding token number (1.12: 2) +Reading a token +Next token is token ')' (1.13: ) +Entering state 11 +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 29 +Reading a token +Next token is token '=' (1.15: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) +Entering state 8 +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) +Entering state 18 +Reading a token +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.17: 1) +-> $$ = nterm exp (1.17: 1) +Entering state 27 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) +Entering state 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input (2.1: ) +Entering state 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1491: cat stderr +stderr: +./torture.at:141: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) +Reading a token +Next token is token ')' (1.3: ) +Entering state 11 +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) +Entering state 20 +Reading a token +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Reading a token +1.8: syntax error: invalid character: '#' +Next token is token error (1.8: ) +Shifting token error (1.8: ) +Entering state 11 +Next token is token error (1.8: ) +Error: discarding token error (1.8: ) +Reading a token +Next token is token ')' (1.9: ) +Entering state 11 +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 29 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) +Entering state 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 18 +Reading a token +Next token is token "number" (1.13-16: 2222) +Shifting token "number" (1.13-16: 2222) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) +Entering state 27 +Reading a token +Next token is token '\n' (1.17-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 16 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +input: +604. torture.at:132: ok +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token invalid token (1.1: ) +1.1: syntax error, unexpected invalid token +Cleanup: discarding lookahead token invalid token (1.1: ) + | (1 + #) = 1111 +stderr: +./calc.at:1491: $PREPARSER ./calc input +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) +Reading a token +Next token is token ')' (1.3: ) +Entering state 11 +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) +Entering state 20 +Reading a token +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Reading a token +1.8: syntax error: invalid character: '#' +Next token is token error (1.8: ) +Shifting token error (1.8: ) +Entering state 11 +Next token is token error (1.8: ) +Error: discarding token error (1.8: ) +Reading a token +Next token is token ')' (1.9: ) +Entering state 11 +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 29 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) +Entering state 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 18 +Reading a token +Next token is token "number" (1.13-16: 2222) +Shifting token "number" (1.13-16: 2222) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) +Entering state 27 +Reading a token +Next token is token '\n' (1.17-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 16 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token '-' (1.2: ) +Shifting token '-' (1.2: ) +Entering state 2 +Reading a token +Next token is token '*' (1.4: ) +1.4: syntax error, unexpected '*', expecting number or '-' or '(' or '!' +Shifting token error (1.4: ) +Entering state 9 +Reducing stack 0 by rule 15 (line 106): + $1 = token '-' (1.2: ) + $2 = token error (1.4: ) +Shifting token error (1.2-4: ) +Entering state 11 +Next token is token '*' (1.4: ) +Error: discarding token '*' (1.4: ) +Reading a token +Next token is token ')' (1.5: ) +Entering state 11 +Next token is token ')' (1.5: ) +Shifting token ')' (1.5: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-4: ) + $3 = token ')' (1.5: ) +-> $$ = nterm exp (1.1-5: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.7: ) +Shifting token '+' (1.7: ) +Entering state 20 +Reading a token +Next token is token '(' (1.9: ) +Shifting token '(' (1.9: ) +Entering state 4 +Reading a token +Next token is token number (1.10: 1) +Shifting token number (1.10: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.10: 1) +-> $$ = nterm exp (1.10: 1) +Entering state 12 +Reading a token +Next token is token number (1.12: 2) +1.12: syntax error, unexpected number +Error: popping nterm exp (1.10: 1) +Shifting token error (1.10-12: ) +Entering state 11 +Next token is token number (1.12: 2) +Error: discarding token number (1.12: 2) +Reading a token +Next token is token ')' (1.13: ) +Entering state 11 +Next token is token ')' (1.13: ) +Shifting token ')' (1.13: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.9: ) + $2 = token error (1.10-12: ) + $3 = token ')' (1.13: ) +-> $$ = nterm exp (1.9-13: 1111) +Entering state 29 +Reading a token +Next token is token '=' (1.15: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-5: 1111) + $2 = token '+' (1.7: ) + $3 = nterm exp (1.9-13: 1111) +-> $$ = nterm exp (1.1-13: 2222) Entering state 8 -Next token is token '=' (10.13: ) -Shifting token '=' (10.13: ) +Next token is token '=' (1.15: ) +Shifting token '=' (1.15: ) Entering state 18 Reading a token -Next token is token number (10.15: 2) -Shifting token number (10.15: 2) +Next token is token number (1.17: 1) +Shifting token number (1.17: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (10.15: 2) --> $$ = nterm exp (10.15: 2) + $1 = token number (1.17: 1) +-> $$ = nterm exp (1.17: 1) Entering state 27 Reading a token -Next token is token '\n' (10.16-11.0: ) +Next token is token '\n' (1.18-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (10.1-11: 2) - $2 = token '=' (10.13: ) - $3 = nterm exp (10.15: 2) --> $$ = nterm exp (10.1-15: 2) + $1 = nterm exp (1.1-13: 2222) + $2 = token '=' (1.15: ) + $3 = nterm exp (1.17: 1) +1.1-17: error: 2222 != 1 +-> $$ = nterm exp (1.1-17: 2222) Entering state 8 -Next token is token '\n' (10.16-11.0: ) -Shifting token '\n' (10.16-11.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (10.1-15: 2) - $2 = token '\n' (10.16-11.0: ) --> $$ = nterm line (10.1-11.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-10.0: ) - $2 = nterm line (10.1-11.0: ) --> $$ = nterm input (1.1-11.0: ) -Entering state 6 -Reading a token -Next token is token '\n' (11.1-12.0: ) -Shifting token '\n' (11.1-12.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (11.1-12.0: ) --> $$ = nterm line (11.1-12.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-11.0: ) - $2 = nterm line (11.1-12.0: ) --> $$ = nterm input (1.1-12.0: ) + $1 = nterm exp (1.1-17: 2222) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token -Next token is token number (12.1: 2) -Shifting token number (12.1: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (12.1: 2) --> $$ = nterm exp (12.1: 2) -Entering state 8 +Now at end of input. +Shifting token end of input (2.1: ) +Entering state 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +Starting parse +Entering state 0 Reading a token -Next token is token '^' (12.2: ) -Shifting token '^' (12.2: ) -Entering state 23 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 Reading a token -Next token is token number (12.3: 2) -Shifting token number (12.3: 2) +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (12.3: 2) --> $$ = nterm exp (12.3: 2) -Entering state 32 + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 Reading a token -Next token is token '^' (12.4: ) -Shifting token '^' (12.4: ) -Entering state 23 +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 Reading a token -Next token is token number (12.5: 3) -Shifting token number (12.5: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (12.5: 3) --> $$ = nterm exp (12.5: 3) -Entering state 32 +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) Reading a token -Next token is token '=' (12.7: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (12.3: 2) - $2 = token '^' (12.4: ) - $3 = nterm exp (12.5: 3) --> $$ = nterm exp (12.3-5: 8) -Entering state 32 -Next token is token '=' (12.7: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (12.1: 2) - $2 = token '^' (12.2: ) - $3 = nterm exp (12.3-5: 8) --> $$ = nterm exp (12.1-5: 256) +Next token is token ')' (1.7: ) +Entering state 11 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 -Next token is token '=' (12.7: ) -Shifting token '=' (12.7: ) +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 18 Reading a token -Next token is token number (12.9-11: 256) -Shifting token number (12.9-11: 256) +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (12.9-11: 256) --> $$ = nterm exp (12.9-11: 256) + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token -Next token is token '\n' (12.12-13.0: ) +Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (12.1-5: 256) - $2 = token '=' (12.7: ) - $3 = nterm exp (12.9-11: 256) --> $$ = nterm exp (12.1-11: 256) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Next token is token '\n' (12.12-13.0: ) -Shifting token '\n' (12.12-13.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (12.1-11: 256) - $2 = token '\n' (12.12-13.0: ) --> $$ = nterm line (12.1-13.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-12.0: ) - $2 = nterm line (12.1-13.0: ) --> $$ = nterm input (1.1-13.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token -Next token is token '(' (13.1: ) -Shifting token '(' (13.1: ) +Now at end of input. +Shifting token end of input (2.1: ) +Entering state 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1494: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./calc.at:1494: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./calc.at:1492: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token number (13.2: 2) -Shifting token number (13.2: 2) +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (13.2: 2) --> $$ = nterm exp (13.2: 2) + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token -Next token is token '^' (13.3: ) -Shifting token '^' (13.3: ) -Entering state 23 +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 Reading a token -Next token is token number (13.4: 2) -Shifting token number (13.4: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (13.4: 2) --> $$ = nterm exp (13.4: 2) -Entering state 32 +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) Reading a token -Next token is token ')' (13.5: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (13.2: 2) - $2 = token '^' (13.3: ) - $3 = nterm exp (13.4: 2) --> $$ = nterm exp (13.2-4: 4) -Entering state 12 -Next token is token ')' (13.5: ) -Shifting token ')' (13.5: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (13.1: ) - $2 = nterm exp (13.2-4: 4) - $3 = token ')' (13.5: ) --> $$ = nterm exp (13.1-5: 4) +Next token is token ')' (1.7: ) +Entering state 11 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token -Next token is token '^' (13.6: ) -Shifting token '^' (13.6: ) -Entering state 23 -Reading a token -Next token is token number (13.7: 3) -Shifting token number (13.7: 3) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (13.7: 3) --> $$ = nterm exp (13.7: 3) -Entering state 32 -Reading a token -Next token is token '=' (13.9: ) -Reducing stack 0 by rule 12 (line 103): - $1 = nterm exp (13.1-5: 4) - $2 = token '^' (13.6: ) - $3 = nterm exp (13.7: 3) --> $$ = nterm exp (13.1-7: 64) -Entering state 8 -Next token is token '=' (13.9: ) -Shifting token '=' (13.9: ) +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 18 Reading a token -Next token is token number (13.11-12: 64) -Shifting token number (13.11-12: 64) +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (13.11-12: 64) --> $$ = nterm exp (13.11-12: 64) + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token -Next token is token '\n' (13.13-14.0: ) +Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (13.1-7: 64) - $2 = token '=' (13.9: ) - $3 = nterm exp (13.11-12: 64) --> $$ = nterm exp (13.1-12: 64) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Next token is token '\n' (13.13-14.0: ) -Shifting token '\n' (13.13-14.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (13.1-12: 64) - $2 = token '\n' (13.13-14.0: ) --> $$ = nterm line (13.1-14.0: ) -Entering state 17 -Reducing stack 0 by rule 2 (line 70): - $1 = nterm input (1.1-13.0: ) - $2 = nterm line (13.1-14.0: ) --> $$ = nterm input (1.1-14.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) Entering state 6 Reading a token Now at end of input. -Shifting token end of input (14.1: ) +Shifting token end of input (2.1: ) Entering state 16 -Cleanup: popping token end of input (14.1: ) -Cleanup: popping nterm input (1.1-14.0: ) -input: -input: +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) + ./calc.at:1494: cat stderr +./calc.at:1494: cat stderr +./calc.at:1492: cat stderr input: +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: - | (* *) + (*) + (*) -./calc.at:1492: $PREPARSER ./calc input - | (1 + 1) / (1 - 1) -./calc.at:1491: $PREPARSER ./calc input - | 1 2 + | 1 = 2 = 3 ./calc.at:1494: $PREPARSER ./calc input -621. existing.at:808: testing GNU Cim Grammar: Canonical LR(1) ... -./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y +input: stdout: +input: +./calc.at:1491: cat stderr +./existing.at:74: $PREPARSER ./input stderr: -./torture.at:141: $PREPARSER ./input + | (1 + #) = 1111 + | (* *) + (*) + (*) +./calc.at:1492: $PREPARSER ./calc input stderr: +./calc.at:1494: $PREPARSER ./calc input Starting parse Entering state 0 Reading a token @@ -243252,12 +242381,29 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 18 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 27 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token number (1.3: 2) +Cleanup: discarding lookahead token '=' (1.7: ) stderr: stderr: +./existing.at:74: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reading a token @@ -243373,6 +242519,9 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) + | (# + 1) = 1111 +./calc.at:1491: $PREPARSER ./calc input +623. existing.at:1460: testing GNU pic (Groff 1.18.1) Grammar: IELR(1) ... Starting parse Entering state 0 Reading a token @@ -243380,11 +242529,11 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.2: 1) + $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token @@ -243392,90 +242541,126 @@ Shifting token '+' (1.4: ) Entering state 20 Reading a token -Next token is token number (1.6: 1) -Shifting token number (1.6: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 29 +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 +Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): +Entering state 25 +Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) + $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 22 -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 18 Reading a token -Next token is token number (1.12: 1) -Shifting token number (1.12: 1) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 27 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 19 +Next token is token '\n' (1.15-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 16 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +stderr: +stderr: +./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y +stderr: +./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) +Reading a token +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Reading a token +Next token is token number (1.6: 1) +Error: discarding token number (1.6: 1) +Reading a token +Next token is token ')' (1.7: ) +Entering state 11 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 18 +Reading a token +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 28 -Reading a token -Next token is token ')' (1.17: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 31 + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 27 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) +Next token is token '\n' (1.15-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -243488,15 +242673,6 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./torture.at:141: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -569. calc.at:1494: ok -./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -604. torture.at:132: ok - -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: Starting parse Entering state 0 Reading a token @@ -243508,10 +242684,92 @@ -> $$ = nterm exp (1.1: 1) Entering state 8 Reading a token -Next token is token number (1.3: 2) -1.3: syntax error, unexpected number +Next token is token '=' (1.3: ) +Shifting token '=' (1.3: ) +Entering state 18 +Reading a token +Next token is token number (1.5: 2) +Shifting token number (1.5: 2) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.5: 2) +-> $$ = nterm exp (1.5: 2) +Entering state 27 +Reading a token +Next token is token '=' (1.7: ) +1.7: syntax error, unexpected '=' +Error: popping nterm exp (1.5: 2) +Error: popping token '=' (1.3: ) Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token number (1.3: 2) +Cleanup: discarding lookahead token '=' (1.7: ) +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +input.y:66.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:170.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:175.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:180.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:188.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:202.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:207.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:221.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:300.10: error: empty rule without %empty [-Werror=empty-rule] +input.y:323.10: error: empty rule without %empty [-Werror=empty-rule] +input.y: error: 265 shift/reduce conflicts [-Werror=conflicts-sr] +input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +input.y:39.1-5: error: useless associativity for FUNC_CALL, use %precedence [-Werror=precedence] +input.y:44.1-5: error: useless associativity for YNUMBER, use %precedence [-Werror=precedence] +input.y:44.1-5: error: useless associativity for YSTRING, use %precedence [-Werror=precedence] +input.y:42.1-9: error: useless precedence and associativity for APPEND_OP [-Werror=precedence] +input.y:33.1-6: error: useless associativity for ASSIGNOP, use %precedence [-Werror=precedence] +input.y:43.1-5: error: useless associativity for CONCAT_OP, use %precedence [-Werror=precedence] +input.y:37.1-5: error: useless precedence and associativity for LEX_GETLINE [-Werror=precedence] +input.y:38.1-9: error: useless associativity for LEX_IN, use %precedence [-Werror=precedence] +input.y:49.1-5: error: useless associativity for INCREMENT, use %precedence [-Werror=precedence] +input.y:49.1-5: error: useless associativity for DECREMENT, use %precedence [-Werror=precedence] +input.y:39.1-5: error: useless associativity for LEX_BUILTIN, use %precedence [-Werror=precedence] +input.y:39.1-5: error: useless associativity for LEX_LENGTH, use %precedence [-Werror=precedence] +input.y:40.1-9: error: useless precedence and associativity for ',' [-Werror=precedence] +input.y:47.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] +input.y:47.1-6: error: useless associativity for UNARY, use %precedence [-Werror=precedence] +input.y:50.1-5: error: useless associativity for '$', use %precedence [-Werror=precedence] +input.y:51.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] +input.y:51.1-5: error: useless precedence and associativity for ')' [-Werror=precedence] +input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] +617. existing.at:74: ok +input.y:128.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:137.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:142.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:161.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:179.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:205.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:213.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:225.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:292.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:294.20: error: empty rule without %empty [-Werror=empty-rule] +input.y:367.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:373.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:387.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:401.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:413.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:443.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:471.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:474.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:489.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:506.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:587.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:591.18: error: empty rule without %empty [-Werror=empty-rule] +input.y: error: 78 shift/reduce conflicts [-Werror=conflicts-sr] +input.y: error: 10 reduce/reduce conflicts [-Werror=conflicts-rr] +input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +input.y:72.1-5: error: useless associativity for HQUA, use %precedence [-Werror=precedence] +input.y:53.1-6: error: useless associativity for HASSIGN, use %precedence [-Werror=precedence] +input.y:54.1-5: error: useless associativity for HORELSE, use %precedence [-Werror=precedence] +input.y:55.1-5: error: useless associativity for HANDTHEN, use %precedence [-Werror=precedence] +input.y:61.1-5: error: useless associativity for HNOT, use %precedence [-Werror=precedence] +input.y:68.1-5: error: useless associativity for UNEAR, use %precedence [-Werror=precedence] +input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] +stderr: +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 @@ -243520,11 +242778,11 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.2: 1) + $1 = token "number" (1.2: 1) -> $$ = nterm exp (1.2: 1) Entering state 12 Reading a token @@ -243532,90 +242790,52 @@ Shifting token '+' (1.4: ) Entering state 20 Reading a token -Next token is token number (1.6: 1) -Shifting token number (1.6: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 29 +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) Reading a token Next token is token ')' (1.7: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 +Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): +Entering state 25 +Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) + $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 22 -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Reading a token -Next token is token number (1.12: 1) -Shifting token number (1.12: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 19 +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 18 Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 28 -Reading a token -Next token is token ')' (1.17: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 31 + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 27 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) +Next token is token '\n' (1.15-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -243624,9 +242844,9 @@ Entering state 6 Reading a token Now at end of input. -Shifting token end of input (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token end of input (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 @@ -243743,6 +242963,89 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./existing.at:74: sed 's,.*/$,,' stderr 1>&2 +./calc.at:1494: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./existing.at:808: sed 's,.*/$,,' stderr 1>&2 +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) +Reading a token +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Reading a token +Next token is token number (1.6: 1) +Error: discarding token number (1.6: 1) +Reading a token +Next token is token ')' (1.7: ) +Entering state 11 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 18 +Reading a token +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 27 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input (2.1: ) +Entering state 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1494: cat stderr ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -243754,7 +243057,8 @@ }eg ' expout || exit 77 -./calc.at:1491: "$PERL" -pi -e 'use strict; +./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror +./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -243764,8 +243068,10 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error ./calc.at:1494: cat stderr -./calc.at:1492: "$PERL" -pi -e 'use strict; +./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error +./calc.at:1491: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { my $unexp = $1; @@ -243775,77 +243081,200 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1491: cat stderr -622. existing.at:1460: testing GNU pic (Groff 1.18.1) Grammar: LALR(1) ... -./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -stderr: -./calc.at:1492: cat stderr -566. calc.at:1491: ok -stdout: input: - | 1//2 -./existing.at:74: $PREPARSER ./input + | + | +1 ./calc.at:1494: $PREPARSER ./calc input +./calc.at:1492: cat stderr stderr: input: -./existing.at:74: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1491: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Cleanup: discarding lookahead token '+' (2.1: ) + | (# + 1) = 1111 +./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: +./calc.at:1494: $PREPARSER ./calc input + | 1 + 2 * 3 + !+ ++ +input: +stderr: +./calc.at:1492: $PREPARSER ./calc input + | (1 + # + 1) = 1111 +./calc.at:1491: $PREPARSER ./calc input stderr: +624. existing.at:1460: testing GNU pic (Groff 1.18.1) Grammar: Canonical LR(1) ... +./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y Starting parse Entering state 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) +Reading a token +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Reading a token +Next token is token "number" (1.6: 1) +Error: discarding token "number" (1.6: 1) +Reading a token +Next token is token ')' (1.7: ) +Entering state 11 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 18 +Reading a token +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 27 Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 22 +Next token is token '\n' (1.15-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.3: ) - | 1 + 2 * 3 + !+ ++ -./calc.at:1492: $PREPARSER ./calc input -./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror -stderr: -stdout: -./existing.at:74: $PREPARSER ./input -617. existing.at:74: ok +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 16 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) stderr: -syntax error, unexpected '*', expecting NEWLINE or '{' or ';' -./existing.at:74: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - -623. existing.at:1460: testing GNU pic (Groff 1.18.1) Grammar: IELR(1) ... Starting parse Entering state 0 Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) +Reading a token +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Reading a token +Next token is token number (1.10: 1) +Error: discarding token number (1.10: 1) +Reading a token +Next token is token ')' (1.11: ) +Entering state 11 +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token -Next token is token '/' (1.2: ) -Shifting token '/' (1.2: ) -Entering state 22 +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) +Entering state 18 Reading a token -Next token is token '/' (1.3: ) -1.3: syntax error, unexpected '/', expecting number or '-' or '(' or '!' -Error: popping token '/' (1.2: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '/' (1.3: ) -./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror +Next token is token number (1.15-18: 1111) +Shifting token number (1.15-18: 1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) +Entering state 27 +Reading a token +Next token is token '\n' (1.19-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) +Entering state 8 +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input (2.1: ) +Entering state 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token @@ -243911,53 +243340,115 @@ $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -616. existing.at:74: ok -./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '\n' (1.1-2.0: ) +Shifting token '\n' (1.1-2.0: ) +Entering state 3 +Reducing stack 0 by rule 3 (line 74): + $1 = token '\n' (1.1-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Next token is token '+' (2.1: ) +2.1: syntax error, unexpected '+' +Error: popping nterm input (1.1-2.0: ) +Cleanup: discarding lookahead token '+' (2.1: ) +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input.y:66.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:170.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:175.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:180.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:188.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:202.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:207.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:221.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:300.10: error: empty rule without %empty [-Werror=empty-rule] -input.y:323.10: error: empty rule without %empty [-Werror=empty-rule] -input.y: error: 265 shift/reduce conflicts [-Werror=conflicts-sr] -input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -input.y:39.1-5: error: useless associativity for FUNC_CALL, use %precedence [-Werror=precedence] -input.y:44.1-5: error: useless associativity for YNUMBER, use %precedence [-Werror=precedence] -input.y:44.1-5: error: useless associativity for YSTRING, use %precedence [-Werror=precedence] -input.y:42.1-9: error: useless precedence and associativity for APPEND_OP [-Werror=precedence] -input.y:33.1-6: error: useless associativity for ASSIGNOP, use %precedence [-Werror=precedence] -input.y:43.1-5: error: useless associativity for CONCAT_OP, use %precedence [-Werror=precedence] -input.y:37.1-5: error: useless precedence and associativity for LEX_GETLINE [-Werror=precedence] -input.y:38.1-9: error: useless associativity for LEX_IN, use %precedence [-Werror=precedence] -input.y:49.1-5: error: useless associativity for INCREMENT, use %precedence [-Werror=precedence] -input.y:49.1-5: error: useless associativity for DECREMENT, use %precedence [-Werror=precedence] -input.y:39.1-5: error: useless associativity for LEX_BUILTIN, use %precedence [-Werror=precedence] -input.y:39.1-5: error: useless associativity for LEX_LENGTH, use %precedence [-Werror=precedence] -input.y:40.1-9: error: useless precedence and associativity for ',' [-Werror=precedence] -input.y:47.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] -input.y:47.1-6: error: useless associativity for UNARY, use %precedence [-Werror=precedence] -input.y:50.1-5: error: useless associativity for '$', use %precedence [-Werror=precedence] -input.y:51.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] -input.y:51.1-5: error: useless precedence and associativity for ')' [-Werror=precedence] -input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] - +./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none stderr: -./calc.at:1494: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +stderr: +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) +Reading a token +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Reading a token +Next token is token number (1.10: 1) +Error: discarding token number (1.10: 1) +Reading a token +Next token is token ')' (1.11: ) +Entering state 11 +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) +Entering state 8 +Reading a token +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) +Entering state 18 +Reading a token +Next token is token number (1.15-18: 1111) +Shifting token number (1.15-18: 1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) +Entering state 27 +Reading a token +Next token is token '\n' (1.19-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) +Entering state 8 +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input (2.1: ) +Entering state 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) Starting parse Entering state 0 Reading a token @@ -244023,25 +243514,100 @@ $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -624. existing.at:1460: testing GNU pic (Groff 1.18.1) Grammar: Canonical LR(1) ... -./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -./calc.at:1494: cat stderr +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) +Reading a token +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Reading a token +Next token is token "number" (1.6: 1) +Error: discarding token "number" (1.6: 1) +Reading a token +Next token is token ')' (1.7: ) +Entering state 11 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 18 +Reading a token +Next token is token "number" (1.11-14: 1111) +Shifting token "number" (1.11-14: 1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 27 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 16 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1494: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 input: | 1 + 2 * 3 + !- ++ -./existing.at:74: sed 's,.*/$,,' stderr 1>&2 ./calc.at:1492: $PREPARSER ./calc input -input: -stderr: - | error -./calc.at:1494: $PREPARSER ./calc input stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) - +./calc.at:1494: cat stderr +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 Starting parse Entering state 0 Reading a token @@ -244107,18 +243673,27 @@ $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) +./calc.at:1494: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -625. regression.at:25: testing Trivial grammars ... -./regression.at:43: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1494: $PREPARSER ./calc /dev/null +./calc.at:1491: cat stderr stderr: -./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error +./calc.at:1494: cat stderr Starting parse Entering state 0 Reading a token -Next token is token invalid token (1.1: ) -1.1: syntax error, unexpected invalid token -Cleanup: discarding lookahead token invalid token (1.1: ) +Now at end of input. +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token end of input (1.1: ) stderr: Starting parse Entering state 0 @@ -244185,333 +243760,12 @@ $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1494: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./regression.at:44: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c -626. regression.at:55: testing YYSTYPE typedef ... -./regression.at:73: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./calc.at:1494: cat stderr -./calc.at:1492: cat stderr -stderr: -input.y:128.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:137.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:142.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:161.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:179.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:205.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:213.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:225.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:292.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:294.20: error: empty rule without %empty [-Werror=empty-rule] -input.y:367.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:373.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:387.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:401.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:413.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:443.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:471.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:474.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:489.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:506.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:587.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:591.18: error: empty rule without %empty [-Werror=empty-rule] -input.y: error: 78 shift/reduce conflicts [-Werror=conflicts-sr] -input.y: error: 10 reduce/reduce conflicts [-Werror=conflicts-rr] -input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -input.y:72.1-5: error: useless associativity for HQUA, use %precedence [-Werror=precedence] -input.y:53.1-6: error: useless associativity for HASSIGN, use %precedence [-Werror=precedence] -input.y:54.1-5: error: useless associativity for HORELSE, use %precedence [-Werror=precedence] -input.y:55.1-5: error: useless associativity for HANDTHEN, use %precedence [-Werror=precedence] -input.y:61.1-5: error: useless associativity for HNOT, use %precedence [-Werror=precedence] -input.y:68.1-5: error: useless associativity for UNEAR, use %precedence [-Werror=precedence] -input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] +./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr input: -./existing.at:808: sed 's,.*/$,,' stderr 1>&2 input: -./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error - | 1 = 2 = 3 - | (#) + (#) = 2222 + | (1 + # + 1) = 1111 ./calc.at:1494: $PREPARSER ./calc input -./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror -./calc.at:1492: $PREPARSER ./calc input -./regression.at:74: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token ')' (1.3: ) -Entering state 11 -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 20 -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Reading a token -1.8: syntax error: invalid character: '#' -Next token is token error (1.8: ) -Shifting token error (1.8: ) -Entering state 11 -Next token is token error (1.8: ) -Error: discarding token error (1.8: ) -Reading a token -Next token is token ')' (1.9: ) -Entering state 11 -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 18 -Reading a token -Next token is token number (1.13-16: 2222) -Shifting token number (1.13-16: 2222) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 27 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input (2.1: ) -Entering state 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 18 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 27 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Error: popping token '=' (1.3: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '=' (1.7: ) -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) -Entering state 4 -Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) -Reading a token -Next token is token ')' (1.3: ) -Entering state 11 -Next token is token ')' (1.3: ) -Shifting token ')' (1.3: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2: ) - $3 = token ')' (1.3: ) --> $$ = nterm exp (1.1-3: 1111) -Entering state 8 -Reading a token -Next token is token '+' (1.5: ) -Shifting token '+' (1.5: ) -Entering state 20 -Reading a token -Next token is token '(' (1.7: ) -Shifting token '(' (1.7: ) -Entering state 4 -Reading a token -1.8: syntax error: invalid character: '#' -Next token is token error (1.8: ) -Shifting token error (1.8: ) -Entering state 11 -Next token is token error (1.8: ) -Error: discarding token error (1.8: ) -Reading a token -Next token is token ')' (1.9: ) -Entering state 11 -Next token is token ')' (1.9: ) -Shifting token ')' (1.9: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.7: ) - $2 = token error (1.8: ) - $3 = token ')' (1.9: ) --> $$ = nterm exp (1.7-9: 1111) -Entering state 29 -Reading a token -Next token is token '=' (1.11: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.1-3: 1111) - $2 = token '+' (1.5: ) - $3 = nterm exp (1.7-9: 1111) --> $$ = nterm exp (1.1-9: 2222) -Entering state 8 -Next token is token '=' (1.11: ) -Shifting token '=' (1.11: ) -Entering state 18 -Reading a token -Next token is token number (1.13-16: 2222) -Shifting token number (1.13-16: 2222) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.13-16: 2222) --> $$ = nterm exp (1.13-16: 2222) -Entering state 27 -Reading a token -Next token is token '\n' (1.17-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-9: 2222) - $2 = token '=' (1.11: ) - $3 = nterm exp (1.13-16: 2222) --> $$ = nterm exp (1.1-16: 2222) -Entering state 8 -Next token is token '\n' (1.17-2.0: ) -Shifting token '\n' (1.17-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-16: 2222) - $2 = token '\n' (1.17-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input (2.1: ) -Entering state 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token number (1.1: 1) -Shifting token number (1.1: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.1: 1) --> $$ = nterm exp (1.1: 1) -Entering state 8 -Reading a token -Next token is token '=' (1.3: ) -Shifting token '=' (1.3: ) -Entering state 18 -Reading a token -Next token is token number (1.5: 2) -Shifting token number (1.5: 2) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.5: 2) --> $$ = nterm exp (1.5: 2) -Entering state 27 -Reading a token -Next token is token '=' (1.7: ) -1.7: syntax error, unexpected '=' -Error: popping nterm exp (1.5: 2) -Error: popping token '=' (1.3: ) -Error: popping nterm exp (1.1: 1) -Cleanup: discarding lookahead token '=' (1.7: ) + | (1 + 1) / (1 - 1) ./calc.at:1492: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -244522,86 +243776,15 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1494: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./calc.at:1492: cat stderr -./calc.at:1494: cat stderr -stderr: -input.y:128.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:137.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:142.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:161.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:179.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:205.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:213.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:225.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:292.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:294.20: error: empty rule without %empty [-Werror=empty-rule] -input.y:367.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:373.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:387.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:401.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:413.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:443.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:471.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:474.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:489.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:506.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:587.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:591.18: error: empty rule without %empty [-Werror=empty-rule] -input.y: error: 78 shift/reduce conflicts [-Werror=conflicts-sr] -input.y: error: 10 reduce/reduce conflicts [-Werror=conflicts-rr] -input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -input.y:72.1-5: error: useless associativity for HQUA, use %precedence [-Werror=precedence] -input.y:53.1-6: error: useless associativity for HASSIGN, use %precedence [-Werror=precedence] -input.y:54.1-5: error: useless associativity for HORELSE, use %precedence [-Werror=precedence] -input.y:55.1-5: error: useless associativity for HANDTHEN, use %precedence [-Werror=precedence] -input.y:61.1-5: error: useless associativity for HNOT, use %precedence [-Werror=precedence] -input.y:68.1-5: error: useless associativity for UNEAR, use %precedence [-Werror=precedence] -input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] -stderr: -stdout: -626. regression.at:55: ok -./existing.at:808: sed 's,.*/$,,' stderr 1>&2 -input: -input: +./calc.at:1491: $PREPARSER ./calc input stderr: - | (1 + #) = 1111 - | - | +1 -./calc.at:1494: $PREPARSER ./calc input -./calc.at:1492: $PREPARSER ./calc input -./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none -./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error stderr: Starting parse Entering state 0 Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Cleanup: discarding lookahead token '+' (2.1: ) -stdout: +Now at end of input. +1.1: syntax error, unexpected end of input +Cleanup: discarding lookahead token end of input (1.1: ) stderr: Starting parse Entering state 0 @@ -244622,164 +243805,90 @@ Shifting token '+' (1.4: ) Entering state 20 Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) -Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) +Next token is token number (1.6: 1) +Shifting token number (1.6: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 29 Reading a token Next token is token ')' (1.7: ) -Entering state 11 +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): +Entering state 26 +Reducing stack 0 by rule 13 (line 104): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) + $2 = nterm exp (1.2-6: 2) $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 -Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 -Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) +-> $$ = nterm exp (1.1-7: 2) Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) -Entering state 24 -Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 -Reading a token -Now at end of input. -Shifting token end of input (2.1: ) -Entering state 16 -Cleanup: popping token end of input (2.1: ) -Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./regression.at:45: $CC $CFLAGS $CPPFLAGS -c -o input.o -DYYDEBUG -c input.c -stderr: -Starting parse -Entering state 0 -Reading a token -Next token is token '\n' (1.1-2.0: ) -Shifting token '\n' (1.1-2.0: ) -Entering state 3 -Reducing stack 0 by rule 3 (line 74): - $1 = token '\n' (1.1-2.0: ) --> $$ = nterm line (1.1-2.0: ) -Entering state 7 -Reducing stack 0 by rule 1 (line 69): - $1 = nterm line (1.1-2.0: ) --> $$ = nterm input (1.1-2.0: ) -Entering state 6 Reading a token -Next token is token '+' (2.1: ) -2.1: syntax error, unexpected '+' -Error: popping nterm input (1.1-2.0: ) -Cleanup: discarding lookahead token '+' (2.1: ) - -./calc.at:1494: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -stderr: -Starting parse -Entering state 0 +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 22 Reading a token -Next token is token '(' (1.1: ) -Shifting token '(' (1.1: ) +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) Entering state 4 Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) +Next token is token number (1.12: 1) +Shifting token number (1.12: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) + $1 = token number (1.12: 1) +-> $$ = nterm exp (1.12: 1) Entering state 12 Reading a token -Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 -Reading a token -1.6: syntax error: invalid character: '#' -Next token is token error (1.6: ) -Error: popping token '+' (1.4: ) -Error: popping nterm exp (1.2: 1) -Shifting token error (1.2-6: ) -Entering state 11 -Next token is token error (1.6: ) -Error: discarding token error (1.6: ) -Reading a token -Next token is token ')' (1.7: ) -Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 25 -Reducing stack 0 by rule 14 (line 105): - $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) -Entering state 8 -Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) -Entering state 18 +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 19 Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) -Entering state 27 + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 Reading a token -Next token is token '\n' (1.15-2.0: ) -Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) +Next token is token ')' (1.17: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 31 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 10 (line 93): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -244792,7 +243901,6 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1494: cat stderr stderr: input.y:202.20: error: empty rule without %empty [-Werror=empty-rule] input.y:270.7: error: empty rule without %empty [-Werror=empty-rule] @@ -244882,129 +243990,91 @@ input.y:170.1-5: error: useless associativity for ',', use %precedence [-Werror=precedence] input.y:181.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] -./calc.at:1494: $PREPARSER ./calc /dev/null -stderr: -stderr: -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 Starting parse Entering state 0 Reading a token -Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token end of input (1.1: ) -input.y:202.20: error: empty rule without %empty [-Werror=empty-rule] -input.y:270.7: error: empty rule without %empty [-Werror=empty-rule] -input.y:292.13: error: empty rule without %empty [-Werror=empty-rule] -input.y:309.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:382.14: error: empty rule without %empty [-Werror=empty-rule] -input.y:471.11-48: error: rule useless in parser due to conflicts [-Werror=other] -input.y:154.1-5: error: useless associativity for LABEL, use %precedence [-Werror=precedence] -input.y:156.1-5: error: useless associativity for VARIABLE, use %precedence [-Werror=precedence] -input.y:156.1-5: error: useless associativity for NUMBER, use %precedence [-Werror=precedence] -input.y:141.1-5: error: useless associativity for TEXT, use %precedence [-Werror=precedence] -input.y:157.1-5: error: useless associativity for ORDINAL, use %precedence [-Werror=precedence] -input.y:156.1-5: error: useless associativity for LAST, use %precedence [-Werror=precedence] -input.y:153.1-5: error: useless associativity for UP, use %precedence [-Werror=precedence] -input.y:153.1-5: error: useless associativity for DOWN, use %precedence [-Werror=precedence] -input.y:159.1-5: error: useless associativity for BOX, use %precedence [-Werror=precedence] -input.y:159.1-5: error: useless associativity for CIRCLE, use %precedence [-Werror=precedence] -input.y:159.1-5: error: useless associativity for ELLIPSE, use %precedence [-Werror=precedence] -input.y:159.1-5: error: useless associativity for ARC, use %precedence [-Werror=precedence] -input.y:159.1-5: error: useless associativity for LINE, use %precedence [-Werror=precedence] -input.y:159.1-5: error: useless associativity for ARROW, use %precedence [-Werror=precedence] -input.y:159.1-5: error: useless associativity for SPLINE, use %precedence [-Werror=precedence] -input.y:162.1-5: error: useless associativity for HEIGHT, use %precedence [-Werror=precedence] -input.y:162.1-5: error: useless associativity for RADIUS, use %precedence [-Werror=precedence] -input.y:162.1-5: error: useless associativity for WIDTH, use %precedence [-Werror=precedence] -input.y:162.1-5: error: useless associativity for DIAMETER, use %precedence [-Werror=precedence] -input.y:162.1-5: error: useless associativity for FROM, use %precedence [-Werror=precedence] -input.y:162.1-5: error: useless associativity for TO, use %precedence [-Werror=precedence] -input.y:162.1-5: error: useless associativity for AT, use %precedence [-Werror=precedence] -input.y:153.1-5: error: useless precedence and associativity for SOLID [-Werror=precedence] -input.y:153.1-5: error: useless associativity for DOTTED, use %precedence [-Werror=precedence] -input.y:153.1-5: error: useless associativity for DASHED, use %precedence [-Werror=precedence] -input.y:153.1-5: error: useless associativity for CHOP, use %precedence [-Werror=precedence] -input.y:147.1-5: error: useless precedence and associativity for LJUST [-Werror=precedence] -input.y:147.1-5: error: useless precedence and associativity for RJUST [-Werror=precedence] -input.y:147.1-5: error: useless precedence and associativity for ABOVE [-Werror=precedence] -input.y:147.1-5: error: useless precedence and associativity for BELOW [-Werror=precedence] -input.y:176.1-5: error: useless associativity for OF, use %precedence [-Werror=precedence] -input.y:176.1-5: error: useless associativity for BETWEEN, use %precedence [-Werror=precedence] -input.y:177.1-5: error: useless associativity for AND, use %precedence [-Werror=precedence] -input.y:157.1-5: error: useless associativity for HERE, use %precedence [-Werror=precedence] -input.y:166.1-5: error: useless associativity for DOT_N, use %precedence [-Werror=precedence] -input.y:166.1-5: error: useless associativity for DOT_E, use %precedence [-Werror=precedence] -input.y:166.1-5: error: useless associativity for DOT_W, use %precedence [-Werror=precedence] -input.y:166.1-5: error: useless associativity for DOT_S, use %precedence [-Werror=precedence] -input.y:166.1-5: error: useless associativity for DOT_NE, use %precedence [-Werror=precedence] -input.y:166.1-5: error: useless associativity for DOT_SE, use %precedence [-Werror=precedence] -input.y:166.1-5: error: useless associativity for DOT_NW, use %precedence [-Werror=precedence] -input.y:166.1-5: error: useless associativity for DOT_SW, use %precedence [-Werror=precedence] -input.y:166.1-5: error: useless associativity for DOT_C, use %precedence [-Werror=precedence] -input.y:167.1-5: error: useless associativity for DOT_START, use %precedence [-Werror=precedence] -input.y:167.1-5: error: useless associativity for DOT_END, use %precedence [-Werror=precedence] -input.y:156.1-5: error: useless associativity for SIN, use %precedence [-Werror=precedence] -input.y:156.1-5: error: useless associativity for COS, use %precedence [-Werror=precedence] -input.y:156.1-5: error: useless associativity for ATAN2, use %precedence [-Werror=precedence] -input.y:156.1-5: error: useless associativity for LOG, use %precedence [-Werror=precedence] -input.y:156.1-5: error: useless associativity for EXP, use %precedence [-Werror=precedence] -input.y:156.1-5: error: useless associativity for SQRT, use %precedence [-Werror=precedence] -input.y:156.1-5: error: useless associativity for K_MAX, use %precedence [-Werror=precedence] -input.y:156.1-5: error: useless associativity for K_MIN, use %precedence [-Werror=precedence] -input.y:156.1-5: error: useless associativity for INT, use %precedence [-Werror=precedence] -input.y:156.1-5: error: useless associativity for RAND, use %precedence [-Werror=precedence] -input.y:156.1-5: error: useless associativity for SRAND, use %precedence [-Werror=precedence] -input.y:167.1-5: error: useless associativity for TOP, use %precedence [-Werror=precedence] -input.y:167.1-5: error: useless associativity for BOTTOM, use %precedence [-Werror=precedence] -input.y:168.1-5: error: useless associativity for UPPER, use %precedence [-Werror=precedence] -input.y:168.1-5: error: useless associativity for LOWER, use %precedence [-Werror=precedence] -input.y:167.1-5: error: useless associativity for LEFT_CORNER, use %precedence [-Werror=precedence] -input.y:167.1-5: error: useless associativity for RIGHT_CORNER, use %precedence [-Werror=precedence] -input.y:168.1-5: error: useless associativity for NORTH, use %precedence [-Werror=precedence] -input.y:168.1-5: error: useless associativity for SOUTH, use %precedence [-Werror=precedence] -input.y:168.1-5: error: useless associativity for EAST, use %precedence [-Werror=precedence] -input.y:168.1-5: error: useless associativity for WEST, use %precedence [-Werror=precedence] -input.y:168.1-5: error: useless associativity for CENTER, use %precedence [-Werror=precedence] -input.y:168.1-5: error: useless associativity for END, use %precedence [-Werror=precedence] -input.y:168.1-5: error: useless associativity for START, use %precedence [-Werror=precedence] -input.y:140.1-5: error: useless associativity for PLOT, use %precedence [-Werror=precedence] -input.y:162.1-5: error: useless associativity for THICKNESS, use %precedence [-Werror=precedence] -input.y:153.1-5: error: useless associativity for FILL, use %precedence [-Werror=precedence] -input.y:153.1-5: error: useless precedence and associativity for COLORED [-Werror=precedence] -input.y:153.1-5: error: useless precedence and associativity for OUTLINED [-Werror=precedence] -input.y:141.1-5: error: useless associativity for SPRINTF, use %precedence [-Werror=precedence] -input.y:137.1-5: error: useless associativity for '.', use %precedence [-Werror=precedence] -input.y:156.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] -input.y:157.1-5: error: useless associativity for '`', use %precedence [-Werror=precedence] -input.y:159.1-5: error: useless associativity for '[', use %precedence [-Werror=precedence] -input.y:170.1-5: error: useless associativity for ',', use %precedence [-Werror=precedence] -input.y:181.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] -input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] -./existing.at:1460: sed 's,.*/$,,' stderr 1>&2 -./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1492: cat stderr -stderr: -Starting parse -Entering state 0 +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) +Reading a token +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Reading a token +Next token is token "number" (1.10: 1) +Error: discarding token "number" (1.10: 1) +Reading a token +Next token is token ')' (1.11: ) +Entering state 11 +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) +Entering state 8 +Reading a token +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) +Entering state 18 +Reading a token +Next token is token "number" (1.15-18: 1111) +Shifting token "number" (1.15-18: 1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) +Entering state 27 +Reading a token +Next token is token '\n' (1.19-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) +Entering state 8 +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 Reading a token Now at end of input. -1.1: syntax error, unexpected end of input -Cleanup: discarding lookahead token end of input (1.1: ) -./existing.at:1460: sed 's,.*/$,,' stderr 1>&2 -627. regression.at:85: testing Early token definitions with --yacc ... -./regression.at:115: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --yacc -o input.c input.y -./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error -input: - | (# + 1) = 1111 +Shifting token "end of input" (2.1: ) +Entering state 16 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1492: cat stderr +./calc.at:1491: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -245015,10 +244085,9 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1492: $PREPARSER ./calc input +./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: stderr: -./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error -./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./calc.at:1494: cat stderr Starting parse Entering state 0 @@ -245027,56 +244096,187 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -1.2: syntax error: invalid character: '#' -Next token is token error (1.2: ) -Shifting token error (1.2: ) -Entering state 11 -Next token is token error (1.2: ) -Error: discarding token error (1.2: ) +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 Reading a token Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 Reading a token Next token is token number (1.6: 1) -Error: discarding token number (1.6: 1) +Shifting token number (1.6: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 29 Reading a token Next token is token ')' (1.7: ) -Entering state 11 +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) +Entering state 8 +Reading a token +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 22 +Reading a token +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Reading a token +Next token is token number (1.12: 1) +Shifting token number (1.12: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 19 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 +Reading a token +Next token is token ')' (1.17: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 31 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 10 (line 93): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) +Entering state 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input (2.1: ) +Entering state 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror +./existing.at:1460: sed 's,.*/$,,' stderr 1>&2 +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) +Reading a token +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Reading a token +Next token is token "number" (1.10: 1) +Error: discarding token "number" (1.10: 1) +Reading a token +Next token is token ')' (1.11: ) +Entering state 11 +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) Entering state 8 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) Entering state 18 Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) +Next token is token "number" (1.15-18: 1111) +Shifting token "number" (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) + $1 = token "number" (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) Entering state 27 Reading a token -Next token is token '\n' (1.15-2.0: ) +Next token is token '\n' (1.19-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -245085,15 +244285,28 @@ Entering state 6 Reading a token Now at end of input. -Shifting token end of input (2.1: ) +Shifting token "end of input" (2.1: ) Entering state 16 -Cleanup: popping token end of input (2.1: ) +Cleanup: popping token "end of input" (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input: + | (#) + (#) = 2222 +./calc.at:1492: $PREPARSER ./calc input input: | () + (1 + 1 + 1 +) + (* * *) + (1 * 2 * *) = 1 -./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./calc.at:1494: $PREPARSER ./calc input +./calc.at:1491: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error stderr: Starting parse Entering state 0 @@ -245109,49 +244322,77 @@ Next token is token error (1.2: ) Error: discarding token error (1.2: ) Reading a token -Next token is token '+' (1.4: ) -Error: discarding token '+' (1.4: ) -Reading a token -Next token is token number (1.6: 1) -Error: discarding token number (1.6: 1) -Reading a token -Next token is token ')' (1.7: ) +Next token is token ')' (1.3: ) Entering state 11 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2-6: ) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 1111) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) Entering state 8 Reading a token -Next token is token '=' (1.9: ) -Shifting token '=' (1.9: ) +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) +Entering state 20 +Reading a token +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Reading a token +1.8: syntax error: invalid character: '#' +Next token is token error (1.8: ) +Shifting token error (1.8: ) +Entering state 11 +Next token is token error (1.8: ) +Error: discarding token error (1.8: ) +Reading a token +Next token is token ')' (1.9: ) +Entering state 11 +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 29 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) +Entering state 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) Entering state 18 Reading a token -Next token is token number (1.11-14: 1111) -Shifting token number (1.11-14: 1111) +Next token is token number (1.13-16: 2222) +Shifting token number (1.13-16: 2222) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.11-14: 1111) --> $$ = nterm exp (1.11-14: 1111) + $1 = token number (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) Entering state 27 Reading a token -Next token is token '\n' (1.15-2.0: ) +Next token is token '\n' (1.17-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-7: 1111) - $2 = token '=' (1.9: ) - $3 = nterm exp (1.11-14: 1111) --> $$ = nterm exp (1.1-14: 1111) + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) Entering state 8 -Next token is token '\n' (1.15-2.0: ) -Shifting token '\n' (1.15-2.0: ) +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-14: 1111) - $2 = token '\n' (1.15-2.0: ) + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -245164,8 +244405,18 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./regression.at:116: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c -stderr: +./calc.at:1494: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none +./calc.at:1491: cat stderr Starting parse Entering state 0 Reading a token @@ -245413,18 +244664,107 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 +./calc.at:1494: cat stderr +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) +Reading a token +Next token is token ')' (1.3: ) +Entering state 11 +Next token is token ')' (1.3: ) +Shifting token ')' (1.3: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2: ) + $3 = token ')' (1.3: ) +-> $$ = nterm exp (1.1-3: 1111) +Entering state 8 +Reading a token +Next token is token '+' (1.5: ) +Shifting token '+' (1.5: ) +Entering state 20 +Reading a token +Next token is token '(' (1.7: ) +Shifting token '(' (1.7: ) +Entering state 4 +Reading a token +1.8: syntax error: invalid character: '#' +Next token is token error (1.8: ) +Shifting token error (1.8: ) +Entering state 11 +Next token is token error (1.8: ) +Error: discarding token error (1.8: ) +Reading a token +Next token is token ')' (1.9: ) +Entering state 11 +Next token is token ')' (1.9: ) +Shifting token ')' (1.9: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.7: ) + $2 = token error (1.8: ) + $3 = token ')' (1.9: ) +-> $$ = nterm exp (1.7-9: 1111) +Entering state 29 +Reading a token +Next token is token '=' (1.11: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.1-3: 1111) + $2 = token '+' (1.5: ) + $3 = nterm exp (1.7-9: 1111) +-> $$ = nterm exp (1.1-9: 2222) +Entering state 8 +Next token is token '=' (1.11: ) +Shifting token '=' (1.11: ) +Entering state 18 +Reading a token +Next token is token number (1.13-16: 2222) +Shifting token number (1.13-16: 2222) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.13-16: 2222) +-> $$ = nterm exp (1.13-16: 2222) +Entering state 27 +Reading a token +Next token is token '\n' (1.17-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-9: 2222) + $2 = token '=' (1.11: ) + $3 = nterm exp (1.13-16: 2222) +-> $$ = nterm exp (1.1-16: 2222) +Entering state 8 +Next token is token '\n' (1.17-2.0: ) +Shifting token '\n' (1.17-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-16: 2222) + $2 = token '\n' (1.17-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input (2.1: ) +Entering state 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) stderr: Starting parse Entering state 0 @@ -245673,6 +245013,21 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +566. calc.at:1491: ok +./calc.at:1492: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +input: + | (1 + 1) / (1 - 1) +./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none +./calc.at:1494: $PREPARSER ./calc input ./calc.at:1492: cat stderr ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} @@ -245684,15 +245039,128 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./torture.at:394: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: + +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Reading a token +Next token is token "number" (1.6: 1) +Shifting token "number" (1.6: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 29 +Reading a token +Next token is token ')' (1.7: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) +Entering state 8 +Reading a token +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 22 +Reading a token +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Reading a token +Next token is token "number" (1.12: 1) +Shifting token "number" (1.12: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 19 +Reading a token +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 +Reading a token +Next token is token ')' (1.17: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 31 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 10 (line 93): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) +Entering state 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 16 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: cat stderr -stdout: input: - | (1 + # + 1) = 1111 + | (1 + #) = 1111 ./calc.at:1492: $PREPARSER ./calc input -625. regression.at:25: ok -./existing.at:808: sed -n 's/^State //p' input.output | tail -1 +./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 @@ -245722,49 +245190,43 @@ Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Reading a token -Next token is token number (1.10: 1) -Error: discarding token number (1.10: 1) -Reading a token -Next token is token ')' (1.11: ) +Next token is token ')' (1.7: ) Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 18 Reading a token -Next token is token number (1.15-18: 1111) -Shifting token number (1.15-18: 1111) +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token -Next token is token '\n' (1.19-2.0: ) +Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -245777,12 +245239,129 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token "number" (1.2: 1) +Shifting token "number" (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Reading a token +Next token is token "number" (1.6: 1) +Shifting token "number" (1.6: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 29 +Reading a token +Next token is token ')' (1.7: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) +Entering state 8 +Reading a token +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 22 +Reading a token +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Reading a token +Next token is token "number" (1.12: 1) +Shifting token "number" (1.12: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 19 +Reading a token +Next token is token "number" (1.16: 1) +Shifting token "number" (1.16: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token "number" (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 +Reading a token +Next token is token ')' (1.17: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 31 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 10 (line 93): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) +Entering state 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token "end of input" (2.1: ) +Entering state 16 +Cleanup: popping token "end of input" (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) input: ./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (!!) + (1 2) = 1 -./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./calc.at:1494: $PREPARSER ./calc input stderr: +./existing.at:808: sed -n 's/^State //p' input.output | tail -1 +stderr: Starting parse Entering state 0 Reading a token @@ -245811,49 +245390,43 @@ Next token is token error (1.6: ) Error: discarding token error (1.6: ) Reading a token -Next token is token '+' (1.8: ) -Error: discarding token '+' (1.8: ) -Reading a token -Next token is token number (1.10: 1) -Error: discarding token number (1.10: 1) -Reading a token -Next token is token ')' (1.11: ) +Next token is token ')' (1.7: ) Entering state 11 -Next token is token ')' (1.11: ) -Shifting token ')' (1.11: ) +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) Entering state 25 Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = token error (1.2-10: ) - $3 = token ')' (1.11: ) --> $$ = nterm exp (1.1-11: 1111) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token -Next token is token '=' (1.13: ) -Shifting token '=' (1.13: ) +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) Entering state 18 Reading a token -Next token is token number (1.15-18: 1111) -Shifting token number (1.15-18: 1111) +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.15-18: 1111) --> $$ = nterm exp (1.15-18: 1111) + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) Entering state 27 Reading a token -Next token is token '\n' (1.19-2.0: ) +Next token is token '\n' (1.15-2.0: ) Reducing stack 0 by rule 6 (line 80): - $1 = nterm exp (1.1-11: 1111) - $2 = token '=' (1.13: ) - $3 = nterm exp (1.15-18: 1111) --> $$ = nterm exp (1.1-18: 1111) + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Next token is token '\n' (1.19-2.0: ) -Shifting token '\n' (1.19-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-18: 1111) - $2 = token '\n' (1.19-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -245866,8 +245439,6 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - -stderr: Starting parse Entering state 0 Reading a token @@ -245979,10 +245550,31 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1494: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +625. regression.at:25: testing Trivial grammars ... +./regression.at:43: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./calc.at:1492: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 stderr: -stdout: -stderr: +./calc.at:1494: cat stderr ./existing.at:808: sed 's/^%define lr.type .*$//' input.y > input-lalr.y Starting parse Entering state 0 @@ -246095,18 +245687,8 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -627. regression.at:85: ok +./calc.at:1492: cat stderr ./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -246117,20 +245699,179 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./calc.at:1492: cat stderr - -628. regression.at:127: testing Early token definitions without --yacc ... -./regression.at:161: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./calc.at:1494: cat stderr -input: -./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none - | (1 + 1) / (1 - 1) +569. calc.at:1494: ok input: +./calc.at:1494: cat stderr + | (# + 1) = 1111 ./calc.at:1492: $PREPARSER ./calc input stderr: +./regression.at:44: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) +Reading a token +Next token is token '+' (1.4: ) +Error: discarding token '+' (1.4: ) +Reading a token +Next token is token number (1.6: 1) +Error: discarding token number (1.6: 1) +Reading a token +Next token is token ')' (1.7: ) +Entering state 11 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-6: ) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 1111) +Entering state 8 +Reading a token +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 18 +Reading a token +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 27 +Reading a token +Next token is token '\n' (1.15-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) +Entering state 8 +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input (2.1: ) +Entering state 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +input: + +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr | (- *) + (1 2) = 1 ./calc.at:1494: $PREPARSER ./calc input stderr: +./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none +stderr: +input.y:202.20: error: empty rule without %empty [-Werror=empty-rule] +input.y:270.7: error: empty rule without %empty [-Werror=empty-rule] +input.y:292.13: error: empty rule without %empty [-Werror=empty-rule] +input.y:309.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:382.14: error: empty rule without %empty [-Werror=empty-rule] +input.y:471.11-48: error: rule useless in parser due to conflicts [-Werror=other] +input.y:154.1-5: error: useless associativity for LABEL, use %precedence [-Werror=precedence] +input.y:156.1-5: error: useless associativity for VARIABLE, use %precedence [-Werror=precedence] +input.y:156.1-5: error: useless associativity for NUMBER, use %precedence [-Werror=precedence] +input.y:141.1-5: error: useless associativity for TEXT, use %precedence [-Werror=precedence] +input.y:157.1-5: error: useless associativity for ORDINAL, use %precedence [-Werror=precedence] +input.y:156.1-5: error: useless associativity for LAST, use %precedence [-Werror=precedence] +input.y:153.1-5: error: useless associativity for UP, use %precedence [-Werror=precedence] +input.y:153.1-5: error: useless associativity for DOWN, use %precedence [-Werror=precedence] +input.y:159.1-5: error: useless associativity for BOX, use %precedence [-Werror=precedence] +input.y:159.1-5: error: useless associativity for CIRCLE, use %precedence [-Werror=precedence] +input.y:159.1-5: error: useless associativity for ELLIPSE, use %precedence [-Werror=precedence] +input.y:159.1-5: error: useless associativity for ARC, use %precedence [-Werror=precedence] +input.y:159.1-5: error: useless associativity for LINE, use %precedence [-Werror=precedence] +input.y:159.1-5: error: useless associativity for ARROW, use %precedence [-Werror=precedence] +input.y:159.1-5: error: useless associativity for SPLINE, use %precedence [-Werror=precedence] +input.y:162.1-5: error: useless associativity for HEIGHT, use %precedence [-Werror=precedence] +input.y:162.1-5: error: useless associativity for RADIUS, use %precedence [-Werror=precedence] +input.y:162.1-5: error: useless associativity for WIDTH, use %precedence [-Werror=precedence] +input.y:162.1-5: error: useless associativity for DIAMETER, use %precedence [-Werror=precedence] +input.y:162.1-5: error: useless associativity for FROM, use %precedence [-Werror=precedence] +input.y:162.1-5: error: useless associativity for TO, use %precedence [-Werror=precedence] +input.y:162.1-5: error: useless associativity for AT, use %precedence [-Werror=precedence] +input.y:153.1-5: error: useless precedence and associativity for SOLID [-Werror=precedence] +input.y:153.1-5: error: useless associativity for DOTTED, use %precedence [-Werror=precedence] +input.y:153.1-5: error: useless associativity for DASHED, use %precedence [-Werror=precedence] +input.y:153.1-5: error: useless associativity for CHOP, use %precedence [-Werror=precedence] +input.y:147.1-5: error: useless precedence and associativity for LJUST [-Werror=precedence] +input.y:147.1-5: error: useless precedence and associativity for RJUST [-Werror=precedence] +input.y:147.1-5: error: useless precedence and associativity for ABOVE [-Werror=precedence] +input.y:147.1-5: error: useless precedence and associativity for BELOW [-Werror=precedence] +input.y:176.1-5: error: useless associativity for OF, use %precedence [-Werror=precedence] +input.y:176.1-5: error: useless associativity for BETWEEN, use %precedence [-Werror=precedence] +input.y:177.1-5: error: useless associativity for AND, use %precedence [-Werror=precedence] +input.y:157.1-5: error: useless associativity for HERE, use %precedence [-Werror=precedence] +input.y:166.1-5: error: useless associativity for DOT_N, use %precedence [-Werror=precedence] +input.y:166.1-5: error: useless associativity for DOT_E, use %precedence [-Werror=precedence] +input.y:166.1-5: error: useless associativity for DOT_W, use %precedence [-Werror=precedence] +input.y:166.1-5: error: useless associativity for DOT_S, use %precedence [-Werror=precedence] +input.y:166.1-5: error: useless associativity for DOT_NE, use %precedence [-Werror=precedence] +input.y:166.1-5: error: useless associativity for DOT_SE, use %precedence [-Werror=precedence] +input.y:166.1-5: error: useless associativity for DOT_NW, use %precedence [-Werror=precedence] +input.y:166.1-5: error: useless associativity for DOT_SW, use %precedence [-Werror=precedence] +input.y:166.1-5: error: useless associativity for DOT_C, use %precedence [-Werror=precedence] +input.y:167.1-5: error: useless associativity for DOT_START, use %precedence [-Werror=precedence] +input.y:167.1-5: error: useless associativity for DOT_END, use %precedence [-Werror=precedence] +input.y:156.1-5: error: useless associativity for SIN, use %precedence [-Werror=precedence] +input.y:156.1-5: error: useless associativity for COS, use %precedence [-Werror=precedence] +input.y:156.1-5: error: useless associativity for ATAN2, use %precedence [-Werror=precedence] +input.y:156.1-5: error: useless associativity for LOG, use %precedence [-Werror=precedence] +input.y:156.1-5: error: useless associativity for EXP, use %precedence [-Werror=precedence] +input.y:156.1-5: error: useless associativity for SQRT, use %precedence [-Werror=precedence] +input.y:156.1-5: error: useless associativity for K_MAX, use %precedence [-Werror=precedence] +input.y:156.1-5: error: useless associativity for K_MIN, use %precedence [-Werror=precedence] +input.y:156.1-5: error: useless associativity for INT, use %precedence [-Werror=precedence] +input.y:156.1-5: error: useless associativity for RAND, use %precedence [-Werror=precedence] +input.y:156.1-5: error: useless associativity for SRAND, use %precedence [-Werror=precedence] +input.y:167.1-5: error: useless associativity for TOP, use %precedence [-Werror=precedence] +input.y:167.1-5: error: useless associativity for BOTTOM, use %precedence [-Werror=precedence] +input.y:168.1-5: error: useless associativity for UPPER, use %precedence [-Werror=precedence] +input.y:168.1-5: error: useless associativity for LOWER, use %precedence [-Werror=precedence] +input.y:167.1-5: error: useless associativity for LEFT_CORNER, use %precedence [-Werror=precedence] +input.y:167.1-5: error: useless associativity for RIGHT_CORNER, use %precedence [-Werror=precedence] +input.y:168.1-5: error: useless associativity for NORTH, use %precedence [-Werror=precedence] +input.y:168.1-5: error: useless associativity for SOUTH, use %precedence [-Werror=precedence] +input.y:168.1-5: error: useless associativity for EAST, use %precedence [-Werror=precedence] +input.y:168.1-5: error: useless associativity for WEST, use %precedence [-Werror=precedence] +input.y:168.1-5: error: useless associativity for CENTER, use %precedence [-Werror=precedence] +input.y:168.1-5: error: useless associativity for END, use %precedence [-Werror=precedence] +input.y:168.1-5: error: useless associativity for START, use %precedence [-Werror=precedence] +input.y:140.1-5: error: useless associativity for PLOT, use %precedence [-Werror=precedence] +input.y:162.1-5: error: useless associativity for THICKNESS, use %precedence [-Werror=precedence] +input.y:153.1-5: error: useless associativity for FILL, use %precedence [-Werror=precedence] +input.y:153.1-5: error: useless precedence and associativity for COLORED [-Werror=precedence] +input.y:153.1-5: error: useless precedence and associativity for OUTLINED [-Werror=precedence] +input.y:141.1-5: error: useless associativity for SPRINTF, use %precedence [-Werror=precedence] +input.y:137.1-5: error: useless associativity for '.', use %precedence [-Werror=precedence] +input.y:156.1-5: error: useless associativity for '(', use %precedence [-Werror=precedence] +input.y:157.1-5: error: useless associativity for '`', use %precedence [-Werror=precedence] +input.y:159.1-5: error: useless associativity for '[', use %precedence [-Werror=precedence] +input.y:170.1-5: error: useless associativity for ',', use %precedence [-Werror=precedence] +input.y:181.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] +input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] +stderr: Starting parse Entering state 0 Reading a token @@ -246254,102 +245995,56 @@ Shifting token '(' (1.1: ) Entering state 4 Reading a token -Next token is token number (1.2: 1) -Shifting token number (1.2: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.2: 1) --> $$ = nterm exp (1.2: 1) -Entering state 12 +1.2: syntax error: invalid character: '#' +Next token is token error (1.2: ) +Shifting token error (1.2: ) +Entering state 11 +Next token is token error (1.2: ) +Error: discarding token error (1.2: ) Reading a token Next token is token '+' (1.4: ) -Shifting token '+' (1.4: ) -Entering state 20 +Error: discarding token '+' (1.4: ) Reading a token Next token is token number (1.6: 1) -Shifting token number (1.6: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 29 +Error: discarding token number (1.6: 1) Reading a token Next token is token ')' (1.7: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 +Entering state 11 Next token is token ')' (1.7: ) Shifting token ')' (1.7: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): +Entering state 25 +Reducing stack 0 by rule 14 (line 105): $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) + $2 = token error (1.2-6: ) $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) +-> $$ = nterm exp (1.1-7: 1111) Entering state 8 Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 22 -Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 -Reading a token -Next token is token number (1.12: 1) -Shifting token number (1.12: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 -Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 19 +Next token is token '=' (1.9: ) +Shifting token '=' (1.9: ) +Entering state 18 Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) +Next token is token number (1.11-14: 1111) +Shifting token number (1.11-14: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 28 -Reading a token -Next token is token ')' (1.17: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 31 + $1 = token number (1.11-14: 1111) +-> $$ = nterm exp (1.11-14: 1111) +Entering state 27 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) +Next token is token '\n' (1.15-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-7: 1111) + $2 = token '=' (1.9: ) + $3 = nterm exp (1.11-14: 1111) +-> $$ = nterm exp (1.1-14: 1111) Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.15-2.0: ) +Shifting token '\n' (1.15-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-14: 1111) + $2 = token '\n' (1.15-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -246362,7 +246057,9 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./existing.at:1460: sed 's,.*/$,,' stderr 1>&2 stderr: Starting parse Entering state 0 @@ -246480,6 +246177,21 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./calc.at:1492: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +626. regression.at:55: testing YYSTYPE typedef ... +./regression.at:73: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./calc.at:1492: cat stderr +./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none +./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -246490,13 +246202,14 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +input: ./calc.at:1494: cat stderr -./regression.at:162: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c -./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -629. regression.at:173: testing Braces parsing ... + | (1 + # + 1) = 1111 +./calc.at:1492: $PREPARSER ./calc input +./regression.at:74: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c stderr: -./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none -./regression.at:185: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y +stderr: +input: Starting parse Entering state 0 Reading a token @@ -246516,90 +246229,58 @@ Shifting token '+' (1.4: ) Entering state 20 Reading a token -Next token is token number (1.6: 1) -Shifting token number (1.6: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.6: 1) --> $$ = nterm exp (1.6: 1) -Entering state 29 -Reading a token -Next token is token ')' (1.7: ) -Reducing stack 0 by rule 7 (line 90): - $1 = nterm exp (1.2: 1) - $2 = token '+' (1.4: ) - $3 = nterm exp (1.6: 1) --> $$ = nterm exp (1.2-6: 2) -Entering state 12 -Next token is token ')' (1.7: ) -Shifting token ')' (1.7: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (1.1: ) - $2 = nterm exp (1.2-6: 2) - $3 = token ')' (1.7: ) --> $$ = nterm exp (1.1-7: 2) -Entering state 8 +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) Reading a token -Next token is token '/' (1.9: ) -Shifting token '/' (1.9: ) -Entering state 22 +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) Reading a token -Next token is token '(' (1.11: ) -Shifting token '(' (1.11: ) -Entering state 4 +Next token is token number (1.10: 1) +Error: discarding token number (1.10: 1) Reading a token -Next token is token number (1.12: 1) -Shifting token number (1.12: 1) -Entering state 1 -Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.12: 1) --> $$ = nterm exp (1.12: 1) -Entering state 12 +Next token is token ')' (1.11: ) +Entering state 11 +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) +Entering state 8 Reading a token -Next token is token '-' (1.14: ) -Shifting token '-' (1.14: ) -Entering state 19 +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) +Entering state 18 Reading a token -Next token is token number (1.16: 1) -Shifting token number (1.16: 1) +Next token is token number (1.15-18: 1111) +Shifting token number (1.15-18: 1111) Entering state 1 Reducing stack 0 by rule 5 (line 79): - $1 = token number (1.16: 1) --> $$ = nterm exp (1.16: 1) -Entering state 28 -Reading a token -Next token is token ')' (1.17: ) -Reducing stack 0 by rule 8 (line 91): - $1 = nterm exp (1.12: 1) - $2 = token '-' (1.14: ) - $3 = nterm exp (1.16: 1) --> $$ = nterm exp (1.12-16: 0) -Entering state 12 -Next token is token ')' (1.17: ) -Shifting token ')' (1.17: ) -Entering state 26 -Reducing stack 0 by rule 13 (line 104): - $1 = token '(' (1.11: ) - $2 = nterm exp (1.12-16: 0) - $3 = token ')' (1.17: ) --> $$ = nterm exp (1.11-17: 0) -Entering state 31 + $1 = token number (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) +Entering state 27 Reading a token -Next token is token '\n' (1.18-2.0: ) -Reducing stack 0 by rule 10 (line 93): - $1 = nterm exp (1.1-7: 2) - $2 = token '/' (1.9: ) - $3 = nterm exp (1.11-17: 0) -1.11-17: error: null divisor --> $$ = nterm exp (1.1-17: 2) +Next token is token '\n' (1.19-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) Entering state 8 -Next token is token '\n' (1.18-2.0: ) -Shifting token '\n' (1.18-2.0: ) +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) Entering state 24 Reducing stack 0 by rule 4 (line 75): - $1 = nterm exp (1.1-17: 2) - $2 = token '\n' (1.18-2.0: ) + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) -> $$ = nterm line (1.1-2.0: ) Entering state 7 Reducing stack 0 by rule 1 (line 69): @@ -246612,28 +246293,12 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -input: -stderr: +stdout: | (* *) + (*) + (*) +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: $PREPARSER ./calc input -input-lalr.y: warning: 78 shift/reduce conflicts [-Wconflicts-sr] -input-lalr.y: warning: 10 reduce/reduce conflicts [-Wconflicts-rr] -input-lalr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -stdout: -./existing.at:808: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' -./calc.at:1492: "$PERL" -pi -e 'use strict; - s{syntax error on token \[(.*?)\] \(expected: (.*)\)} - { - my $unexp = $1; - my @exps = $2 =~ /\[(.*?)\]/g; - ($#exps && $#exps < 4) - ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" - : "syntax error, unexpected $unexp"; - }eg -' expout || exit 77 -./regression.at:187: grep 'tests = {{{{{{{{{{}}}}}}}}}};' input.c +./regression.at:45: $CC $CFLAGS $CPPFLAGS -c -o input.o -DYYDEBUG -c input.c stderr: -stdout: Starting parse Entering state 0 Reading a token @@ -246749,10 +246414,90 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) - { tests = {{{{{{{{{{}}}}}}}}}}; } -629. regression.at:173: ./calc.at:1492: cat stderr - ok -./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Reading a token +1.6: syntax error: invalid character: '#' +Next token is token error (1.6: ) +Error: popping token '+' (1.4: ) +Error: popping nterm exp (1.2: 1) +Shifting token error (1.2-6: ) +Entering state 11 +Next token is token error (1.6: ) +Error: discarding token error (1.6: ) +Reading a token +Next token is token '+' (1.8: ) +Error: discarding token '+' (1.8: ) +Reading a token +Next token is token number (1.10: 1) +Error: discarding token number (1.10: 1) +Reading a token +Next token is token ')' (1.11: ) +Entering state 11 +Next token is token ')' (1.11: ) +Shifting token ')' (1.11: ) +Entering state 25 +Reducing stack 0 by rule 14 (line 105): + $1 = token '(' (1.1: ) + $2 = token error (1.2-10: ) + $3 = token ')' (1.11: ) +-> $$ = nterm exp (1.1-11: 1111) +Entering state 8 +Reading a token +Next token is token '=' (1.13: ) +Shifting token '=' (1.13: ) +Entering state 18 +Reading a token +Next token is token number (1.15-18: 1111) +Shifting token number (1.15-18: 1111) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.15-18: 1111) +-> $$ = nterm exp (1.15-18: 1111) +Entering state 27 +Reading a token +Next token is token '\n' (1.19-2.0: ) +Reducing stack 0 by rule 6 (line 80): + $1 = nterm exp (1.1-11: 1111) + $2 = token '=' (1.13: ) + $3 = nterm exp (1.15-18: 1111) +-> $$ = nterm exp (1.1-18: 1111) +Entering state 8 +Next token is token '\n' (1.19-2.0: ) +Shifting token '\n' (1.19-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-18: 1111) + $2 = token '\n' (1.19-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input (2.1: ) +Entering state 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse @@ -246870,8 +246615,19 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./existing.at:808: grep '^State.*conflicts:' input.output - +./calc.at:1492: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +stderr: +stdout: +626. regression.at:55: ok ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -246882,22 +246638,135 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -568. calc.at:1492: ok -./existing.at:808: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./calc.at:1492: cat stderr +./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./calc.at:1494: cat stderr -./existing.at:808: sed -n 's/^State //p' input.output | tail -1 -./existing.at:808: sed 's/^%define lr.type .*$//' input.y > input-lalr.y -./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y -stderr: -630. regression.at:196: testing Rule Line Numbers ... input: -./regression.at:232: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -v input.y -stdout: - +./torture.at:394: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS + | (1 + 1) / (1 - 1) +./calc.at:1492: $PREPARSER ./calc input +input: +stderr: | 1 + 2 * 3 + !+ ++ ./calc.at:1494: $PREPARSER ./calc input -./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none -628. regression.at:127: ok +./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Reading a token +Next token is token number (1.6: 1) +Shifting token number (1.6: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 29 +Reading a token +Next token is token ')' (1.7: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) +Entering state 8 +Reading a token +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 22 +Reading a token +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Reading a token +Next token is token number (1.12: 1) +Shifting token number (1.12: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 19 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 +Reading a token +Next token is token ')' (1.17: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 31 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 10 (line 93): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) +Entering state 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input (2.1: ) +Entering state 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) + +stderr: stderr: Starting parse Entering state 0 @@ -246964,10 +246833,144 @@ $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -./regression.at:235: cat input.output +./calc.at:1492: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +input-lalr.y: warning: 78 shift/reduce conflicts [-Wconflicts-sr] +input-lalr.y: warning: 10 reduce/reduce conflicts [-Wconflicts-rr] +input-lalr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +stdout: +./existing.at:808: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' +stderr: +Starting parse +Entering state 0 +Reading a token +Next token is token '(' (1.1: ) +Shifting token '(' (1.1: ) +Entering state 4 +Reading a token +Next token is token number (1.2: 1) +Shifting token number (1.2: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.2: 1) +-> $$ = nterm exp (1.2: 1) +Entering state 12 +Reading a token +Next token is token '+' (1.4: ) +Shifting token '+' (1.4: ) +Entering state 20 +Reading a token +Next token is token number (1.6: 1) +Shifting token number (1.6: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.6: 1) +-> $$ = nterm exp (1.6: 1) +Entering state 29 +Reading a token +Next token is token ')' (1.7: ) +Reducing stack 0 by rule 7 (line 90): + $1 = nterm exp (1.2: 1) + $2 = token '+' (1.4: ) + $3 = nterm exp (1.6: 1) +-> $$ = nterm exp (1.2-6: 2) +Entering state 12 +Next token is token ')' (1.7: ) +Shifting token ')' (1.7: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (1.1: ) + $2 = nterm exp (1.2-6: 2) + $3 = token ')' (1.7: ) +-> $$ = nterm exp (1.1-7: 2) +Entering state 8 +Reading a token +Next token is token '/' (1.9: ) +Shifting token '/' (1.9: ) +Entering state 22 +Reading a token +Next token is token '(' (1.11: ) +Shifting token '(' (1.11: ) +Entering state 4 +Reading a token +Next token is token number (1.12: 1) +Shifting token number (1.12: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.12: 1) +-> $$ = nterm exp (1.12: 1) +Entering state 12 +Reading a token +Next token is token '-' (1.14: ) +Shifting token '-' (1.14: ) +Entering state 19 +Reading a token +Next token is token number (1.16: 1) +Shifting token number (1.16: 1) +Entering state 1 +Reducing stack 0 by rule 5 (line 79): + $1 = token number (1.16: 1) +-> $$ = nterm exp (1.16: 1) +Entering state 28 +Reading a token +Next token is token ')' (1.17: ) +Reducing stack 0 by rule 8 (line 91): + $1 = nterm exp (1.12: 1) + $2 = token '-' (1.14: ) + $3 = nterm exp (1.16: 1) +-> $$ = nterm exp (1.12-16: 0) +Entering state 12 +Next token is token ')' (1.17: ) +Shifting token ')' (1.17: ) +Entering state 26 +Reducing stack 0 by rule 13 (line 104): + $1 = token '(' (1.11: ) + $2 = nterm exp (1.12-16: 0) + $3 = token ')' (1.17: ) +-> $$ = nterm exp (1.11-17: 0) +Entering state 31 +Reading a token +Next token is token '\n' (1.18-2.0: ) +Reducing stack 0 by rule 10 (line 93): + $1 = nterm exp (1.1-7: 2) + $2 = token '/' (1.9: ) + $3 = nterm exp (1.11-17: 0) +1.11-17: error: null divisor +-> $$ = nterm exp (1.1-17: 2) +Entering state 8 +Next token is token '\n' (1.18-2.0: ) +Shifting token '\n' (1.18-2.0: ) +Entering state 24 +Reducing stack 0 by rule 4 (line 75): + $1 = nterm exp (1.1-17: 2) + $2 = token '\n' (1.18-2.0: ) +-> $$ = nterm line (1.1-2.0: ) +Entering state 7 +Reducing stack 0 by rule 1 (line 69): + $1 = nterm line (1.1-2.0: ) +-> $$ = nterm input (1.1-2.0: ) +Entering state 6 +Reading a token +Now at end of input. +Shifting token end of input (2.1: ) +Entering state 16 +Cleanup: popping token end of input (2.1: ) +Cleanup: popping nterm input (1.1-2.0: ) +./existing.at:808: sed -n 's/^State //p' input.output | tail -1 ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -630. regression.at:196: ok +./calc.at:1492: "$PERL" -pi -e 'use strict; + s{syntax error on token \[(.*?)\] \(expected: (.*)\)} + { + my $unexp = $1; + my @exps = $2 =~ /\[(.*?)\]/g; + ($#exps && $#exps < 4) + ? "syntax error, unexpected $unexp, expecting @{[join(\" or \", @exps)]}" + : "syntax error, unexpected $unexp"; + }eg +' expout || exit 77 +./existing.at:808: grep '^State.*conflicts:' input.output stderr: +./existing.at:808: sed 's/^%define lr.type .*$//' input.y > input-lalr.y +./calc.at:1492: cat stderr Starting parse Entering state 0 Reading a token @@ -247033,12 +247036,14 @@ $2 = token '+' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none +./existing.at:808: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS input: -631. regression.at:345: testing Mixing %token styles ... -./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -Wall -o input.c input.y +568. calc.at:1492: ok +627. regression.at:85: testing Early token definitions with --yacc ... | 1 + 2 * 3 + !- ++ ./calc.at:1494: $PREPARSER ./calc input +./regression.at:115: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --yacc -o input.c input.y +./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y stderr: Starting parse Entering state 0 @@ -247105,14 +247110,11 @@ $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) - ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -Wall -o input.c input.y -Werror stderr: stdout: - +625. regression.at:25: ok stderr: -./existing.at:808: $PREPARSER ./input Starting parse Entering state 0 Reading a token @@ -247178,23 +247180,8 @@ $2 = token '-' (1.14: ) Cleanup: popping token '+' (1.11: ) Cleanup: popping nterm exp (1.1-9: 7) -stderr: -stderr: -./existing.at:808: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -input-lalr.y: warning: 78 shift/reduce conflicts [-Wconflicts-sr] -input-lalr.y: warning: 10 reduce/reduce conflicts [-Wconflicts-rr] -input-lalr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -stdout: -./existing.at:1460: sed -n 's/^State //p' input.output | tail -1 -./existing.at:808: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' -632. regression.at:437: testing Token definitions: parse.error=detailed ... -./existing.at:1460: sed 's/^%define lr.type .*$//' input.y > input-lalr.y -./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o input.c input.y -./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y -stderr: -619. existing.at:808: ok -input.y:3.1-5: error: useless precedence and associativity for "||" [-Werror=precedence] -input.y:3.1-5: error: useless precedence and associativity for "<=" [-Werror=precedence] + +./regression.at:116: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -247205,19 +247192,16 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./existing.at:808: grep '^State.*conflicts:' input.output -./regression.at:357: sed 's,.*/$,,' stderr 1>&2 -633. regression.at:438: testing Token definitions: parse.error=verbose ... -./calc.at:1494: cat stderr -./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o input.c input.y -./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Werror -./existing.at:808: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./calc.at:1494: cat stderr input: -./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -Wall -o input.c input.y --warnings=error +628. regression.at:127: testing Early token definitions without --yacc ... +./regression.at:161: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y | (#) + (#) = 2222 ./calc.at:1494: $PREPARSER ./calc input +./existing.at:1460: sed -n 's/^State //p' input.output | tail -1 stderr: +629. regression.at:173: testing Braces parsing ... Starting parse Entering state 0 Reading a token @@ -247315,25 +247299,17 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: -./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Werror -input.y:26.8-14: error: symbol SPECIAL redeclared [-Werror=other] - 26 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" - | ^~~~~~~ -input.y:25.8-14: note: previous declaration - 25 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" - | ^~~~~~~ -input.y:26.16-63: error: symbol "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" used more than once as a literal string [-Werror=other] - 26 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" - | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +./regression.at:185: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./existing.at:1460: sed -n 's/^State //p' input.output | tail -1 +./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none ./existing.at:1460: sed 's/^%define lr.type .*$//' input.y > input-lalr.y -./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y -./regression.at:437: sed 's,.*/$,,' stderr 1>&2 -634. regression.at:447: testing Characters Escapes ... stderr: -./regression.at:465: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +stderr: +stderr: +input-lalr.y: warning: 78 shift/reduce conflicts [-Wconflicts-sr] +input-lalr.y: warning: 10 reduce/reduce conflicts [-Wconflicts-rr] +input-lalr.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +stdout: Starting parse Entering state 0 Reading a token @@ -247431,7 +247407,19 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -Wall -o input.c input.y -Wnone,none -Werror --trace=none +stderr: +./existing.at:808: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' +./regression.at:162: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c +./regression.at:187: grep 'tests = {{{{{{{{{{}}}}}}}}}};' input.c +stdout: +stdout: +./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y + { tests = {{{{{{{{{{}}}}}}}}}}; } +stdout: +629. regression.at:173: ok +./existing.at:808: $PREPARSER ./input +627. regression.at:85: ok +./existing.at:808: grep '^State.*conflicts:' input.output stderr: ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} @@ -247443,30 +247431,18 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +./existing.at:808: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./existing.at:808: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./calc.at:1494: cat stderr -./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=error -input.y:26.8-14: error: symbol SPECIAL redeclared [-Werror=other] - 26 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" - | ^~~~~~~ -input.y:25.8-14: note: previous declaration - 25 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" - | ^~~~~~~ -input.y:26.16-63: error: symbol "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" used more than once as a literal string [-Werror=other] - 26 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" - | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -stderr: -input-lalr.y:471.11-48: warning: rule useless in parser due to conflicts [-Wother] -stdout: -./existing.at:1460: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' + + +619. existing.at:808: ok input: | (1 + #) = 1111 ./calc.at:1494: $PREPARSER ./calc input -./regression.at:438: sed 's,.*/$,,' stderr 1>&2 -./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=error -./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -Wall -o input.c input.y --warnings=none -Werror --trace=none -./existing.at:1460: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./existing.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none stderr: -./regression.at:466: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c + Starting parse Entering state 0 Reading a token @@ -247544,13 +247520,17 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -stderr: +630. regression.at:196: testing Rule Line Numbers ... ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Wnone,none -Werror --trace=none -./existing.at:808: $PREPARSER ./input +631. regression.at:345: testing Mixing %token styles ... +./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -Wall -o input.c input.y +./regression.at:232: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -v input.y stderr: +stdout: +632. regression.at:437: testing Token definitions: parse.error=detailed ... +./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o input.c input.y stderr: +628. regression.at:127: ok Starting parse Entering state 0 Reading a token @@ -247628,12 +247608,6 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./existing.at:808: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -input-lalr.y:471.11-48: warning: rule useless in parser due to conflicts [-Wother] -stdout: -./existing.at:1460: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' -631. regression.at:345: ok ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -247644,21 +247618,18 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -620. existing.at:808: ok -./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Wnone,none -Werror --trace=none -./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=none -Werror --trace=none ./calc.at:1494: cat stderr - stderr: -./existing.at:74: sed -n 's/^State //p' input.output | tail -1 -./existing.at:1460: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./regression.at:235: cat input.output +./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -Wall -o input.c input.y -Werror +./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Werror +input-lalr.y:471.11-48: warning: rule useless in parser due to conflicts [-Wother] stdout: -./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=none -Werror --trace=none +./existing.at:1460: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' input: | (# + 1) = 1111 ./calc.at:1494: $PREPARSER ./calc input -634. regression.at:447: ok stderr: Starting parse Entering state 0 @@ -247729,11 +247700,10 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./regression.at:437: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -635. regression.at:480: testing Web2c Report ... ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./regression.at:505: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v input.y +630. regression.at:196: ok stderr: +./existing.at:1460: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS Starting parse Entering state 0 Reading a token @@ -247803,10 +247773,27 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./regression.at:438: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +stderr: +input.y:3.1-5: error: useless precedence and associativity for "||" [-Werror=precedence] +input.y:3.1-5: error: useless precedence and associativity for "<=" [-Werror=precedence] +stderr: -636. regression.at:661: testing Web2c Actions ... -./regression.at:674: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y +./regression.at:357: sed 's,.*/$,,' stderr 1>&2 +stdout: +stderr: +./existing.at:808: $PREPARSER ./input +input.y:26.8-14: error: symbol SPECIAL redeclared [-Werror=other] + 26 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" + | ^~~~~~~ +input.y:25.8-14: note: previous declaration + 25 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" + | ^~~~~~~ +input.y:26.16-63: error: symbol "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" used more than once as a literal string [-Werror=other] + 26 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" + | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +stderr: +633. regression.at:438: testing Token definitions: parse.error=verbose ... +./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o input.c input.y ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -247817,25 +247804,20 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./existing.at:74: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./regression.at:506: cat input.output -stderr: -stdout: +./existing.at:808: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./existing.at:1460: sed -n 's/^State //p' input.output | tail -1 ./calc.at:1494: cat stderr -./existing.at:1460: $PREPARSER ./input -635. regression.at:480: ok -stderr: -syntax error, unexpected LEFT -./existing.at:1460: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -622. existing.at:1460: ok -637. regression.at:812: testing Useless Tokens ... -./regression.at:912: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -o input.c input.y +./regression.at:437: sed 's,.*/$,,' stderr 1>&2 +./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -Wall -o input.c input.y --warnings=error +620. existing.at:808: ok +./existing.at:1460: sed 's/^%define lr.type .*$//' input.y > input-lalr.y input: +./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=error | (1 + # + 1) = 1111 -./regression.at:679: cat tables.c ./calc.at:1494: $PREPARSER ./calc input stderr: -636. regression.at:661: ok +./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Werror +./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all,no-cex input-lalr.y Starting parse Entering state 0 Reading a token @@ -247919,11 +247901,22 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +634. regression.at:447: testing Characters Escapes ... +./regression.at:465: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - stderr: - +./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -Wall -o input.c input.y -Wnone,none -Werror --trace=none +input.y:26.8-14: error: symbol SPECIAL redeclared [-Werror=other] + 26 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" + | ^~~~~~~ +input.y:25.8-14: note: previous declaration + 25 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" + | ^~~~~~~ +input.y:26.16-63: error: symbol "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" used more than once as a literal string [-Werror=other] + 26 | %token SPECIAL "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" + | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +stderr: Starting parse Entering state 0 Reading a token @@ -248007,6 +248000,9 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./regression.at:466: $CC $CFLAGS $CPPFLAGS -c -o input.o input.c +./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Wnone,none -Werror --trace=none +./regression.at:438: sed 's,.*/$,,' stderr 1>&2 ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -248017,26 +248013,20 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 -./regression.at:917: cat tables.c -stderr: -stdout: -./regression.at:437: $PREPARSER ./input -stderr: -640. regression.at:1145: testing Dancer lalr1.cc ... +./regression.at:437: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=none -Werror --trace=none +./regression.at:357: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -v -Wall -o input.c input.y --warnings=none -Werror --trace=none +./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=error +635. regression.at:480: testing Web2c Report ... +./regression.at:505: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v input.y ./calc.at:1494: cat stderr -./regression.at:1145: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o dancer.cc dancer.y -637. regression.at:812: ok -syntax error, unexpected a, expecting ∃¬∩∪∀ -./regression.at:437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -638. regression.at:1143: testing Dancer ... -./regression.at:1143: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o dancer.c dancer.y input: -639. regression.at:1144: testing Dancer %glr-parser ... +./regression.at:506: cat input.output | (1 + 1) / (1 - 1) ./calc.at:1494: $PREPARSER ./calc input -./regression.at:1144: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o dancer.c dancer.y stderr: -632. regression.at:437: ok +./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y -Wnone,none -Werror --trace=none +635. regression.at:480: 631. regression.at:345: ok + ok Starting parse Entering state 0 Reading a token @@ -248152,11 +248142,14 @@ Entering state 16 Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) +./regression.at:437: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./calc.at:1494: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - stderr: -./regression.at:1145: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o dancer dancer.cc $LIBS -./regression.at:1143: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o dancer dancer.c $LIBS +stdout: +stderr: +stderr: +634. regression.at:447: ok +stdout: Starting parse Entering state 0 Reading a token @@ -248273,7 +248266,9 @@ Cleanup: popping token end of input (2.1: ) Cleanup: popping nterm input (1.1-2.0: ) -./regression.at:1144: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o dancer dancer.c $LIBS +./existing.at:1460: $PREPARSER ./input + +./regression.at:438: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret -o input.c input.y --warnings=none -Werror --trace=none ./calc.at:1494: "$PERL" -pi -e 'use strict; s{syntax error on token \[(.*?)\] \(expected: (.*)\)} { @@ -248284,114 +248279,145 @@ : "syntax error, unexpected $unexp"; }eg ' expout || exit 77 +stderr: +syntax error, unexpected LEFT +./existing.at:1460: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./calc.at:1494: cat stderr + +570. calc.at:1494: ok +622. existing.at:1460: ok +./regression.at:438: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +636. regression.at:661: testing Web2c Actions ... +./regression.at:674: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -v -o input.c input.y + + +637. regression.at:812: testing Useless Tokens ... +./regression.at:912: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-other -o input.c input.y +638. regression.at:1143: testing Dancer ... +./regression.at:1143: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o dancer.c dancer.y +640. regression.at:1145: testing Dancer lalr1.cc ... +./regression.at:1145: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o dancer.cc dancer.y +./regression.at:679: cat tables.c +stderr: +stdout: +./regression.at:437: $PREPARSER ./input stderr: +639. regression.at:1144: testing Dancer %glr-parser ... +636. regression.at:661: ok +syntax error, unexpected a, expecting ∃¬∩∪∀ +./regression.at:1144: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o dancer.c dancer.y +./regression.at:437: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +input-lalr.y:471.11-48: warning: rule useless in parser due to conflicts [-Wother] stdout: +632. regression.at:437: ok +./existing.at:1460: diff -u input-lalr.output input.output | sed -n '/^@@/,$p' | sed 's/^ $//' +./regression.at:1143: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o dancer dancer.c $LIBS +./regression.at:1145: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o dancer dancer.cc $LIBS + +./regression.at:1144: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o dancer dancer.c $LIBS +./existing.at:1460: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS + +./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror +./regression.at:917: cat tables.c 641. regression.at:1220: testing Expecting two tokens ... ./regression.at:1220: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o expect2.c expect2.y -stdout: -./existing.at:1460: $PREPARSER ./input +642. regression.at:1221: testing Expecting two tokens %glr-parser ... +637. regression.at:812: ok +./regression.at:1221: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o expect2.c expect2.y stderr: +stdout: ./regression.at:438: $PREPARSER ./input -570. calc.at:1494: ok stderr: -642. regression.at:1221: testing Expecting two tokens %glr-parser ... -./regression.at:1221: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o expect2.c expect2.y -./existing.at:1460: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + syntax error, unexpected a, expecting "\\\'\?\"\a\b\f\n\r\t\v\001\201\x001\x000081??!" ./regression.at:438: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -623. existing.at:1460: ok -633. regression.at:438: ok - -./regression.at:1220: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o expect2 expect2.c $LIBS ./regression.at:1221: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o expect2 expect2.c $LIBS - - -stderr: -./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror -stdout: -./existing.at:74: $PREPARSER ./input -stderr: -./existing.at:74: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./regression.at:1220: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o expect2 expect2.c $LIBS +633. regression.at:438: ok +./existing.at:74: sed -n 's/^State //p' input.output | tail -1 643. regression.at:1222: testing Expecting two tokens lalr1.cc ... ./regression.at:1222: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o expect2.cc expect2.y + +./existing.at:74: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: -618. existing.at:74: ok -644. regression.at:1230: testing Braced code in declaration in rules section ... ./regression.at:1143: $PREPARSER ./dancer -./regression.at:1261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: syntax error, unexpected ':' ./regression.at:1143: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -645. regression.at:1291: testing String alias declared after use ... -./regression.at:1304: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./regression.at:1222: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o expect2 expect2.cc $LIBS +644. regression.at:1230: testing Braced code in declaration in rules section ... +./regression.at:1261: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 638. regression.at:1143: ok - -./regression.at:1262: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -645. regression.at:1291: ok stderr: stdout: +./regression.at:1262: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./existing.at:1460: $PREPARSER ./input +stderr: +./existing.at:1460: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +623. existing.at:1460: ok +645. regression.at:1291: testing String alias declared after use ... +./regression.at:1304: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +stderr: +stdout: ./regression.at:1220: $PREPARSER ./expect2 stderr: - syntax error, unexpected '+', expecting A or B ./regression.at:1220: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + +645. regression.at:1291: ok +641. regression.at:1220: ok + 646. regression.at:1314: testing Extra lookahead sets in report ... + ./regression.at:1329: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret --report=all input.y -647. regression.at:1355: testing Token number in precedence declaration ... -./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall -o input.c input.y ./regression.at:1330: sed -n '/^State 1$/,/^State 2$/p' input.output -641. regression.at:1220: ok 646. regression.at:1314: ok 648. regression.at:1408: testing parse-gram.y: LALR = IELR ... ./regression.at:1414: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -Dlr.type=lalr input.y -./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y -Werror - +647. regression.at:1355: testing Token number in precedence declaration ... +./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wall -o input.c input.y +./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y -Werror stderr: +649. regression.at:1430: testing parse.error=verbose and YYSTACK_USE_ALLOCA ... +./regression.at:1481: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y input.y:24.5-19: error: rule useless in parser due to conflicts [-Werror=other] input.y:28.5-19: error: rule useless in parser due to conflicts [-Werror=other] input.y:18.1-5: error: useless precedence and associativity for TK1 [-Werror=precedence] +./regression.at:1388: sed 's,.*/$,,' stderr 1>&2 +stderr: +./regression.at:1482: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +stdout: +./existing.at:74: $PREPARSER ./input +stderr: +./existing.at:74: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y --warnings=error stderr: stdout: +618. existing.at:74: ok ./regression.at:1144: $PREPARSER ./dancer -./regression.at:1388: sed 's,.*/$,,' stderr 1>&2 stderr: -649. regression.at:1430: testing parse.error=verbose and YYSTACK_USE_ALLOCA ... syntax error, unexpected ':' ./regression.at:1144: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./regression.at:1481: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./regression.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -Dlr.type=ielr input.y + 639. regression.at:1144: ok -650. regression.at:1504: testing parse.error=verbose overflow ... -./regression.at:1604: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y --warnings=error -./regression.at:1482: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y -Wnone,none -Werror --trace=none +stderr: +stdout: -./regression.at:1611: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./regression.at:1263: $PREPARSER ./input --debug stderr: stdout: -./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y -Wnone,none -Werror --trace=none -./regression.at:1417: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c -Dlr.type=ielr input.y -./regression.at:1221: $PREPARSER ./expect2 stderr: -syntax error, unexpected '+', expecting A or B -651. regression.at:1628: testing LAC: Exploratory stack ... -./regression.at:1713: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full \ - -Dparse.lac.es-capacity-initial=1 \ - -Dparse.lac.memory-trace=full -o input.c input.y -./regression.at:1221: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1388: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall -o input.c input.y --warnings=none -Werror --trace=none -./regression.at:1713: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -stderr: -642. regression.at:1221: ok -stdout: -./regression.at:1263: $PREPARSER ./input --debug -./regression.at:1393: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +650. regression.at:1504: testing parse.error=verbose overflow ... +./regression.at:1221: $PREPARSER ./expect2 stderr: +./regression.at:1604: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y Starting parse Entering state 0 Stack now 0 @@ -248407,9 +248433,57 @@ Cleanup: discarding lookahead token 'a' (PRINTER) DESTRUCTOR Stack now 0 +stdout: +stderr: +./regression.at:1483: $PREPARSER ./input ./regression.at:1263: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - +syntax error, unexpected '+', expecting A or B +./regression.at:1221: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +syntax error, unexpected 'a', expecting 123456789112345678921234567893123456789412345678951234567896123A or 123456789112345678921234567893123456789412345678951234567896123B +syntax error, unexpected end of file, expecting 123456789112345678921234567893123456789412345678951234567896123A or 123456789112345678921234567893123456789412345678951234567896123B +./regression.at:1483: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +642. regression.at:1221: ok +651. regression.at:1628: testing LAC: Exploratory stack ... 644. regression.at:1230: ok +./regression.at:1713: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full \ + -Dparse.lac.es-capacity-initial=1 \ + -Dparse.lac.memory-trace=full -o input.c input.y +649. regression.at:1430: ok +./regression.at:1393: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./regression.at:1611: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS + + + +./regression.at:1713: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +652. regression.at:1739: testing LAC: Memory exhaustion ... +./regression.at:1771: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -Dparse.lac.es-capacity-initial=1 -o input.c input.y +653. regression.at:1874: testing Lex and parse params: yacc.c ... +./regression.at:1420: diff lalr.c ielr.c +./regression.at:1874: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +648. regression.at:1408: ok +654. regression.at:1875: testing Lex and parse params: glr.c ... +./regression.at:1875: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y + +./regression.at:1771: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./regression.at:1874: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +stderr: +./regression.at:1875: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +stdout: +./regression.at:1145: $PREPARSER ./dancer +stderr: +syntax error, unexpected ':' +./regression.at:1145: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +655. regression.at:1876: testing Lex and parse params: lalr1.cc ... +./regression.at:1876: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +640. regression.at:1145: ok +./regression.at:1876: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stderr: + +stdout: +./regression.at:1394: $PREPARSER ./input +stderr: +./regression.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: input.y: In function 'yyparse': input.y:59:24: warning: format '%d' expects argument of type 'int', but argument 3 has type 'long int' [-Wformat=] @@ -248424,110 +248498,65 @@ 62 | fprintf (stderr, " YYSIZE_MAXIMUM = %d\n", YYSIZE_MAXIMUM); | ^~~~~~~~~~~~~~~~~~~~~~~~~ stdout: +656. regression.at:1877: testing Lex and parse params: glr.cc ... ./regression.at:1613: $PREPARSER ./input +./regression.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: syntax error, unexpected 'a', expecting 123456789112345678921234567893123456789412345678951234567896123A or 123456789112345678921234567893123456789412345678951234567896123B or 123456789112345678921234567893123456789412345678951234567896123C syntax error, unexpected 'd' syntax error memory exhausted +647. regression.at:1355: ok ./regression.at:1613: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -650. regression.at:1504: ok -./regression.at:1420: diff lalr.c ielr.c -648. regression.at:1408: ok - -652. regression.at:1739: testing LAC: Memory exhaustion ... -./regression.at:1771: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -Dparse.lac.es-capacity-initial=1 -o input.c input.y - -653. regression.at:1874: testing Lex and parse params: yacc.c ... - -./regression.at:1874: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -stderr: -stdout: -./regression.at:1771: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -stderr: -./regression.at:1145: $PREPARSER ./dancer -stdout: -./regression.at:1483: $PREPARSER ./input -654. regression.at:1875: testing Lex and parse params: glr.c ... -stderr: -stderr: -syntax error, unexpected 'a', expecting 123456789112345678921234567893123456789412345678951234567896123A or 123456789112345678921234567893123456789412345678951234567896123B -syntax error, unexpected end of file, expecting 123456789112345678921234567893123456789412345678951234567896123A or 123456789112345678921234567893123456789412345678951234567896123B -./regression.at:1483: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -syntax error, unexpected ':' -./regression.at:1875: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./regression.at:1145: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./regression.at:1874: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -655. regression.at:1876: testing Lex and parse params: lalr1.cc ... -./regression.at:1876: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -649. regression.at:1430: ok -640. regression.at:1145: ok -stderr: -./regression.at:1875: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -stdout: -./regression.at:1876: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./regression.at:1394: $PREPARSER ./input -stderr: -./regression.at:1394: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - -647. regression.at:1355: ok -stderr: -stdout: +650. regression.at:1504: ok stderr: stdout: +./regression.at:1877: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./regression.at:1874: $PREPARSER ./input stderr: -./regression.at:1713: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt -./regression.at:1874: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./regression.at:1874: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 653. regression.at:1874: ok stderr: -656. regression.at:1877: testing Lex and parse params: glr.cc ... -./regression.at:1713: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./regression.at:1877: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 657. regression.at:1878: testing Lex and parse params: glr2.cc ... +stdout: +./regression.at:1222: $PREPARSER ./expect2 ./regression.at:1878: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./regression.at:1713: grep 'syntax error,' stderr.txt +stderr: +syntax error, unexpected '+', expecting A or B +./regression.at:1222: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 658. regression.at:1889: testing stdio.h is not needed ... -./regression.at:1713: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt ./regression.at:1906: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y - -./regression.at:1877: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +643. regression.at:1222: ok ./regression.at:1878: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror -./regression.at:1713: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt + ./regression.at:1906: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./regression.at:1713: "$PERL" -0777 -ne 'print s/\(realloc//g;' < stderr.txt -659. push.at:25: testing Memory Leak for Early Deletion ... -./push.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y + stderr: stdout: -./regression.at:1222: $PREPARSER ./expect2 -stderr: -./regression.at:1714: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full \ - -Dparse.lac.es-capacity-initial=1 \ - -Dparse.lac.memory-trace=full -o input.c input.y +./regression.at:1713: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt +659. push.at:25: testing Memory Leak for Early Deletion ... +./push.at:74: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y stderr: -stdout: -./regression.at:1771: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -syntax error, unexpected '+', expecting A or B -./regression.at:1222: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./regression.at:1713: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./regression.at:1713: grep 'syntax error,' stderr.txt +./regression.at:1713: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt +660. push.at:84: testing Multiple impure instances ... +./push.at:134: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./push.at:75: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -643. regression.at:1222: ok -./regression.at:1714: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./regression.at:1713: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt stderr: stdout: - 658. regression.at:1889: ok - -660. push.at:84: testing Multiple impure instances ... -./push.at:134: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y -./push.at:134: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -661. push.at:145: testing Unsupported Skeletons ... -./push.at:156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: +./regression.at:1713: "$PERL" -0777 -ne 'print s/\(realloc//g;' < stderr.txt +./push.at:134: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stdout: +./regression.at:1771: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./regression.at:1714: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full \ + -Dparse.lac.es-capacity-initial=1 \ + -Dparse.lac.memory-trace=full -o input.c input.y stderr: input.y:202.20: error: empty rule without %empty [-Werror=empty-rule] input.y:270.7: error: empty rule without %empty [-Werror=empty-rule] @@ -248617,22 +248646,42 @@ input.y:170.1-5: error: useless associativity for ',', use %precedence [-Werror=precedence] input.y:181.1-6: error: useless associativity for '!', use %precedence [-Werror=precedence] input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] -./push.at:76: $PREPARSER ./input + +./existing.at:1460: sed 's,.*/$,,' stderr 1>&2 +./regression.at:1714: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error +661. push.at:145: testing Unsupported Skeletons ... +./push.at:156: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret input.y stderr: +stdout: +./push.at:76: $PREPARSER ./input stderr: ./push.at:76: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +659. push.at:25: ok +661. push.at:145: ok +stderr: +stdout: +./push.at:134: $PREPARSER ./input +stderr: +./push.at:134: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + + +./push.at:135: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +stderr: stdout: ./regression.at:1875: $PREPARSER ./input stderr: -661. push.at:145: ok -./existing.at:1460: sed 's,.*/$,,' stderr 1>&2 -659. push.at:25: ok -./regression.at:1875: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error stderr: stdout: +662. push.at:167: testing Pstate reuse ... +./push.at:276: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +./regression.at:1875: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1772: $PREPARSER ./input --debug - +./push.at:135: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +654. regression.at:1875: ok +663. c++.at:26: testing C++ Locations Unit Tests ... +======== Testing with C++ standard flags: '' +./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: Starting parse Entering state 0 @@ -248645,75 +248694,57 @@ Cleanup: discarding lookahead token "end of file" () Stack now 0 ./regression.at:1772: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -654. regression.at:1875: ok +./push.at:276: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./push.at:134: $PREPARSER ./input -stderr: -./push.at:134: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./regression.at:1787: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -Dparse.lac.es-capacity-initial=1 -o input.c input.y -./push.at:135: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y - -662. push.at:167: testing Pstate reuse ... -663. c++.at:26: testing C++ Locations Unit Tests ... -./push.at:276: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y +664. c++.at:107: testing C++ Variant-based Symbols Unit Tests ... ./regression.at:1787: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./c++.at:234: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.yy stderr: stdout: ./regression.at:1714: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt -======== Testing with C++ standard flags: '' -./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./push.at:135: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: -./regression.at:1714: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./regression.at:1714: grep 'syntax error,' stderr.txt -./push.at:276: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -664. c++.at:107: testing C++ Variant-based Symbols Unit Tests ... -./c++.at:234: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.yy -./regression.at:1714: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt -./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./regression.at:1714: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt +stdout: +stderr: +./push.at:135: $PREPARSER ./input ======== Testing with C++ standard flags: '' +./regression.at:1714: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -./regression.at:1714: "$PERL" -0777 -ne 'print s/\(realloc//g;' < stderr.txt +stderr: +./push.at:135: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./regression.at:1714: grep 'syntax error,' stderr.txt stderr: stdout: +660. push.at:84: ok ./regression.at:1876: $PREPARSER ./input -./regression.at:1715: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full \ - -Dparse.lac.es-capacity-initial=1 \ - -Dparse.lac.memory-trace=full -o input.c input.y -stderr: +./regression.at:1714: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt stderr: +./regression.at:1714: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt ./regression.at:1876: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./regression.at:1715: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -./push.at:135: $PREPARSER ./input -stderr: +./regression.at:1714: "$PERL" -0777 -ne 'print s/\(realloc//g;' < stderr.txt 655. regression.at:1876: ok -./push.at:135: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -660. push.at:84: ok - stderr: stdout: -666. c++.at:566: testing Variants lalr1.cc ... -======== Testing with C++ standard flags: '' -./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./push.at:277: ./input -stderr: -stdout: -./regression.at:1787: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -665. c++.at:247: testing Multiple occurrences of $n and api.value.automove ... -./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.yy 662. push.at:167: ok +./regression.at:1715: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full \ + -Dparse.lac.es-capacity-initial=1 \ + -Dparse.lac.memory-trace=full -o input.c input.y -./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS + +665. c++.at:247: testing Multiple occurrences of $n and api.value.automove ... +./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret input.yy +./regression.at:1715: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.yy -Werror 667. c++.at:567: testing Variants lalr1.cc parse.assert ... ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +666. c++.at:566: testing Variants lalr1.cc ... stderr: +======== Testing with C++ standard flags: '' +./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y input.yy:16.33-34: error: multiple occurrences of $2 with api.value.automove [-Werror=other] 16 | | "twice" exp { $$ = $2 + $2; } | ^~ @@ -248723,33 +248754,48 @@ input.yy:17.40-41: error: multiple occurrences of $2 with api.value.automove [-Werror=other] 17 | | "thrice" exp[val] { $$ = $2 + $val + $2; } | ^~ -stderr: ./c++.at:263: sed 's,.*/$,,' stderr 1>&2 +./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.yy --warnings=error +./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +stderr: stdout: -./regression.at:1877: $PREPARSER ./input +./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./regression.at:1787: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.yy -Wnone,none -Werror --trace=none +./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.yy --warnings=none -Werror --trace=none +665. c++.at:247: ok + +668. c++.at:568: testing Variants lalr1.cc parse.assert api.value.automove ... +======== Testing with C++ standard flags: '' +./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./regression.at:1715: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt stderr: -stderr: ./regression.at:1715: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +stderr: ./regression.at:1715: grep 'syntax error,' stderr.txt +stdout: +./regression.at:1877: $PREPARSER ./input ./regression.at:1715: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt -./regression.at:1715: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt -./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.yy --warnings=error +stderr: ./regression.at:1877: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./regression.at:1715: "$PERL" -0777 -ne 'print s/\(realloc//g;' < stderr.txt -./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./regression.at:1715: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt 656. regression.at:1877: ok +./regression.at:1715: "$PERL" -0777 -ne 'print s/\(realloc//g;' < stderr.txt ./regression.at:1716: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full \ -Dparse.lac.es-capacity-initial=1 \ -Dparse.lac.memory-trace=full -o input.c input.y -./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.yy -Wnone,none -Werror --trace=none +./regression.at:1716: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +669. c++.at:569: testing Variants lalr1.cc parse.assert %locations ... +======== Testing with C++ standard flags: '' +./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: +./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: ./regression.at:1788: $PREPARSER ./input --debug -./regression.at:1716: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: Starting parse Entering state 0 @@ -248764,111 +248810,109 @@ memory exhausted Cleanup: discarding lookahead token "invalid token" () Stack now 0 -./c++.at:263: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret input.yy --warnings=none -Werror --trace=none ./regression.at:1788: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -668. c++.at:568: testing Variants lalr1.cc parse.assert api.value.automove ... -======== Testing with C++ standard flags: '' -./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y 652. regression.at:1739: ok -665. c++.at:247: ok - -./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS 670. c++.at:570: testing Variants lalr1.cc parse.assert %code {\n#define TWO_STAGE_BUILD\n} ... -669. c++.at:569: testing Variants lalr1.cc parse.assert %locations ... -======== Testing with C++ standard flags: '' -./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Werror stderr: stdout: ./regression.at:1716: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt stderr: ./regression.at:1716: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./regression.at:1716: grep 'syntax error,' stderr.txt -./regression.at:1716: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt -./regression.at:1716: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt -./regression.at:1716: "$PERL" -0777 -ne 'print s/\(realloc//g;' < stderr.txt -./regression.at:1719: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -o input.cc input.y stderr: stdout: +./regression.at:1716: grep 'syntax error,' stderr.txt ./c++.at:92: $PREPARSER ./input stderr: +./regression.at:1716: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./regression.at:1716: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none -./regression.at:1719: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./regression.at:1716: "$PERL" -0777 -ne 'print s/\(realloc//g;' < stderr.txt +./regression.at:1719: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -o input.cc input.y ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./regression.at:1719: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none stderr: stdout: -./regression.at:1878: $PREPARSER ./input stderr: -./regression.at:1878: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -657. regression.at:1878: ok -stderr: -stdout: ./c++.at:235: $PREPARSER ./list stderr: +stdout: +./regression.at:1878: $PREPARSER ./input ./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - +stderr: ======== Testing with C++ standard flags: '' ./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./regression.at:1878: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +657. regression.at:1878: ok + 671. c++.at:571: testing Variants lalr1.cc parse.assert api.token.constructor ... ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: +./torture.at:395: $PREPARSER ./input +stderr: +./torture.at:395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +613. torture.at:385: ok + +stderr: +stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: +672. c++.at:572: testing Variants lalr1.cc parse.assert api.token.constructor api.token.prefix={TOK_} ... +./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +======== Testing with C++ standard flags: '' +./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +stderr: +stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -stderr: -stdout: -./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: -input.y:128.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:137.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:142.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:161.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:179.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:205.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:213.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:225.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:292.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:294.20: error: empty rule without %empty [-Werror=empty-rule] -input.y:367.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:373.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:387.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:401.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:413.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:443.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:471.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:474.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:489.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:506.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:587.18: error: empty rule without %empty [-Werror=empty-rule] -input.y:591.18: error: empty rule without %empty [-Werror=empty-rule] -input.y: error: 1876 shift/reduce conflicts [-Werror=conflicts-sr] -input.y: error: 144 reduce/reduce conflicts [-Werror=conflicts-rr] -input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -input.y:72.1-5: error: useless associativity for HQUA, use %precedence [-Werror=precedence] -input.y:53.1-6: error: useless associativity for HASSIGN, use %precedence [-Werror=precedence] -input.y:54.1-5: error: useless associativity for HORELSE, use %precedence [-Werror=precedence] -input.y:55.1-5: error: useless associativity for HANDTHEN, use %precedence [-Werror=precedence] -input.y:61.1-5: error: useless associativity for HNOT, use %precedence [-Werror=precedence] -input.y:68.1-5: error: useless associativity for UNEAR, use %precedence [-Werror=precedence] -input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] +stdout: +./c++.at:566: $here/modern +stdout: +Modern C++: 201703 +./c++.at:566: $PREPARSER ./list stderr: -./existing.at:808: sed 's,.*/$,,' stderr 1>&2 +Destroy: "0" +Destroy: "0" +Destroy: 1 +Destroy: "1" +Destroy: (0) +Destroy: "2" +Destroy: "2" +Destroy: (0, 1) +Destroy: "" +Destroy: 3 +Destroy: (0, 1, 2) +Destroy: "4" +Destroy: "4" +Destroy: (0, 1, 2) +Destroy: (0, 1, 2, 4) +Destroy: 5 +Destroy: (0, 1, 2, 4) +Destroy: "6" +Destroy: "6" +Destroy: (0, 1, 2, 4) +Destroy: (0, 1, 2, 4, 6) +./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:567: $here/modern @@ -248876,7 +248920,6 @@ Modern C++: 201703 ./c++.at:567: $PREPARSER ./list stderr: -stdout: Destroy: "0" Destroy: "0" Destroy: 1 @@ -248901,47 +248944,53 @@ ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./regression.at:1719: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt -./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error stderr: -./regression.at:1719: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -./regression.at:1719: grep 'syntax error,' stderr.txt -./regression.at:1719: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt -./regression.at:1719: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt stderr: -./regression.at:1727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -o input.java input.y stdout: -./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +stdout: +./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: +./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +stdout: +./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./existing.at:1460: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none +stderr: stdout: -./torture.at:395: $PREPARSER ./input +./regression.at:1719: $PREPARSER ./input --debug > stdout.txt 2> stderr.txt stderr: -./torture.at:395: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -613. torture.at:385: ok +./regression.at:1719: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./regression.at:1719: grep 'syntax error,' stderr.txt +./regression.at:1719: "$PERL" -0777 -ne 'print s/inconsistent default reduction//g;' stdout.txt +./regression.at:1719: "$PERL" -0777 -ne 'print s/\bconsistent default reduction//g;' stdout.txt +./regression.at:1727: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dparse.lac=full -o input.java input.y 651. regression.at:1628: skipped (regression.at:1727) - 673. c++.at:573: testing Variants lalr1.cc parse.assert api.token.constructor api.token.prefix={TOK_} %locations ... -stderr: -672. c++.at:572: testing Variants lalr1.cc parse.assert api.token.constructor api.token.prefix={TOK_} ... ======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +stderr: stdout: stderr: stdout: -./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:92: $PREPARSER ./input +./c++.at:235: $PREPARSER ./list +stderr: +stderr: +./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +======== Testing with C++ standard flags: '' +./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:568: $here/modern stdout: Modern C++: 201703 ./c++.at:568: $PREPARSER ./list -./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: Destroy: "" Destroy: "" @@ -248964,25 +249013,17 @@ Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) -./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: -./c++.at:235: $PREPARSER ./list -stderr: -./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -======== Testing with C++ standard flags: '' -./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -stdout: -./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -./c++.at:566: $here/modern +./c++.at:569: $here/modern stdout: Modern C++: 201703 -./c++.at:566: $PREPARSER ./list +./c++.at:569: $PREPARSER ./list stderr: +./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS Destroy: "0" Destroy: "0" Destroy: 1 @@ -249004,21 +249045,16 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: -./c++.at:569: $here/modern -stdout: -Modern C++: 201703 stderr: -./c++.at:569: $PREPARSER ./list +./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stdout: ./c++.at:570: $here/modern stdout: -stderr: Modern C++: 201703 ./c++.at:570: $PREPARSER ./list stderr: @@ -249043,6 +249079,18 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) +./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +======== Testing with C++ standard flags: '' +./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +stderr: +stdout: +./c++.at:566: $here/modern +stdout: +Legac++ +./c++.at:566: $PREPARSER ./list +stderr: Destroy: "0" Destroy: "0" Destroy: 1 @@ -249064,31 +249112,63 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stdout: ======== Testing with C++ standard flags: '' -./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:92: $PREPARSER ./input stderr: ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: -./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./existing.at:1460: sed -n 's/^State //p' input.output | tail -1 ./existing.at:1460: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS stderr: stdout: ./c++.at:571: $here/modern +stderr: stdout: +input.y:128.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:137.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:142.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:161.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:179.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:205.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:213.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:225.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:292.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:294.20: error: empty rule without %empty [-Werror=empty-rule] +input.y:367.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:373.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:387.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:401.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:413.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:443.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:471.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:474.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:489.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:506.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:587.18: error: empty rule without %empty [-Werror=empty-rule] +input.y:591.18: error: empty rule without %empty [-Werror=empty-rule] +input.y: error: 1876 shift/reduce conflicts [-Werror=conflicts-sr] +input.y: error: 144 reduce/reduce conflicts [-Werror=conflicts-rr] +input.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +input.y:72.1-5: error: useless associativity for HQUA, use %precedence [-Werror=precedence] +input.y:53.1-6: error: useless associativity for HASSIGN, use %precedence [-Werror=precedence] +input.y:54.1-5: error: useless associativity for HORELSE, use %precedence [-Werror=precedence] +input.y:55.1-5: error: useless associativity for HANDTHEN, use %precedence [-Werror=precedence] +input.y:61.1-5: error: useless associativity for HNOT, use %precedence [-Werror=precedence] +input.y:68.1-5: error: useless associativity for UNEAR, use %precedence [-Werror=precedence] +input.y: error: fix-its can be applied. Rerun with option '--update'. [-Werror=other] Modern C++: 201703 ./c++.at:571: $PREPARSER ./list stderr: @@ -249113,13 +249193,57 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) +./existing.at:808: sed 's,.*/$,,' stderr 1>&2 ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=error +./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +stderr: +stdout: +./c++.at:572: $here/modern +stdout: +stderr: +Modern C++: 201703 +./c++.at:572: $PREPARSER ./list +stderr: +stdout: +Destroy: "0" +Destroy: "0" +Destroy: 1 +Destroy: "1" +Destroy: (0) +Destroy: "2" +Destroy: "2" +Destroy: (0, 1) +Destroy: "" +Destroy: 3 +Destroy: (0, 1, 2) +Destroy: "4" +Destroy: "4" +Destroy: (0, 1, 2) +Destroy: (0, 1, 2, 4) +Destroy: 5 +Destroy: (0, 1, 2, 4) +Destroy: "6" +Destroy: "6" +Destroy: (0, 1, 2, 4) +Destroy: (0, 1, 2, 4, 6) +./c++.at:235: $PREPARSER ./list +./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +======== Testing with C++ standard flags: '' +./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +stderr: +stdout: +./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:567: $here/modern @@ -249151,54 +249275,73 @@ ./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -stderr: -stdout: -./c++.at:235: $PREPARSER ./list -stderr: -./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: +./c++.at:566: $here/modern stderr: stdout: -./c++.at:92: $PREPARSER ./input +Legac++ +./c++.at:566: $PREPARSER ./list +stdout: stderr: ./existing.at:1460: $PREPARSER ./input -./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -stderr: stderr: +Destroy: "0" +Destroy: "0" +Destroy: 1 +Destroy: "1" +Destroy: (0) +Destroy: "2" +Destroy: "2" +Destroy: (0, 1) +Destroy: "" +Destroy: 3 +Destroy: (0, 1, 2) +Destroy: "4" +Destroy: "4" +Destroy: (0, 1, 2) +Destroy: (0, 1, 2, 4) +Destroy: 5 +Destroy: (0, 1, 2, 4) +Destroy: "6" +Destroy: "6" +Destroy: (0, 1, 2, 4) +Destroy: (0, 1, 2, 4, 6) ./existing.at:1460: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 624. existing.at:1460: ok +======== Testing with C++ standard flags: '' +./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: +./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: -./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS 674. c++.at:574: testing Variants lalr1.cc parse.assert api.token.constructor api.token.prefix={TOK_} %locations api.value.automove ... -stderr: -stdout: ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -stderr: -stdout: ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: -./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: -./c++.at:566: $here/modern +./c++.at:92: $PREPARSER ./input +stderr: +./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +stderr: +stdout: +stderr: +stdout: +./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:568: $here/modern +./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: Legac++ -./c++.at:566: $PREPARSER ./list +./c++.at:568: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -249221,18 +249364,20 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: -./c++.at:573: $here/modern -stdout: -stderr: -Modern C++: 201703 -./c++.at:573: $PREPARSER ./list +./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: +./c++.at:570: $here/modern +stdout: +Legac++ +./c++.at:570: $PREPARSER ./list +stderr: Destroy: "0" Destroy: "0" Destroy: 1 @@ -249254,14 +249399,21 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -./c++.at:572: $here/modern -./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +stderr: +stderr: +stdout: +stdout: +./c++.at:573: $here/modern +./c++.at:569: $here/modern stdout: +Legac++ +stdout: +./c++.at:569: $PREPARSER ./list Modern C++: 201703 -./c++.at:572: $PREPARSER ./list +./c++.at:573: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -249284,17 +249436,7 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: -./c++.at:568: $here/modern -stdout: -======== Testing with C++ standard flags: '' -./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -Legac++ -./c++.at:568: $PREPARSER ./list stderr: -./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none Destroy: "0" Destroy: "0" Destroy: 1 @@ -249316,18 +249458,25 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) +./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +======== Testing with C++ standard flags: '' +./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: -./c++.at:570: $here/modern -======== Testing with C++ standard flags: '' -./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +stderr: +stdout: +./c++.at:571: $here/modern stdout: Legac++ -./c++.at:570: $PREPARSER ./list +./c++.at:571: $PREPARSER ./list stderr: -./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS Destroy: "0" Destroy: "0" Destroy: 1 @@ -249349,14 +249498,20 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: -./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:235: $PREPARSER ./list +stderr: +./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +stderr: +stdout: +./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:92: $PREPARSER ./input @@ -249364,20 +249519,16 @@ ./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: -./c++.at:235: $PREPARSER ./list -stderr: +./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: -./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: -./c++.at:569: $here/modern -======== Testing with C++ standard flags: '' +./c++.at:566: $here/modern stdout: -./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -Legac++ -./c++.at:569: $PREPARSER ./list +Modern C++: 201103 +./c++.at:566: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -249400,22 +249551,19 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: +./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: -======== Testing with C++ standard flags: '' -./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: -./c++.at:571: $here/modern +./c++.at:572: $here/modern stdout: Legac++ -./c++.at:571: $PREPARSER ./list +./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -249438,13 +249586,10 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -stderr: -stdout: -./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:567: $here/modern @@ -249482,10 +249627,14 @@ ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: -./c++.at:566: $here/modern +./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y -Wnone,none -Werror --trace=none +stderr: +stdout: +./c++.at:568: $here/modern stdout: Legac++ -./c++.at:566: $PREPARSER ./list +./c++.at:568: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -249508,40 +249657,27 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -stdout: -./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -stderr: -stdout: -./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -stderr: -stdout: -./c++.at:92: $PREPARSER ./input -stderr: -./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stderr: stdout: stdout: +./c++.at:235: $PREPARSER ./list +stderr: ./c++.at:574: $here/modern +./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: -stderr: -./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS Modern C++: 201703 ./c++.at:574: $PREPARSER ./list -stdout: +======== Testing with C++ standard flags: '' +./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: -./c++.at:573: $here/modern Destroy: "" Destroy: "" Destroy: 1 @@ -249563,15 +249699,31 @@ Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) +./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: stdout: -Legac++ -./c++.at:573: $PREPARSER ./list +./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +======== Testing with C++ standard flags: '' +./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: +stdout: +./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: -./c++.at:568: $here/modern -./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:92: $PREPARSER ./input +stderr: +./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stderr: stdout: +./c++.at:573: $here/modern +stdout: +Legac++ +./c++.at:573: $PREPARSER ./list +stderr: Destroy: "0" Destroy: "0" Destroy: 1 @@ -249593,8 +249745,15 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) +./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +stderr: +stdout: +./c++.at:570: $here/modern +stdout: Legac++ -./c++.at:568: $PREPARSER ./list +./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -249617,21 +249776,23 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: +./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ======== Testing with C++ standard flags: '' -./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:570: $here/modern -======== Testing with C++ standard flags: '' -./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +stderr: +stdout: +./c++.at:569: $here/modern stdout: Legac++ -./c++.at:570: $PREPARSER ./list +./c++.at:569: $PREPARSER ./list +stderr: +stdout: stderr: +./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS Destroy: "0" Destroy: "0" Destroy: 1 @@ -249653,19 +249814,17 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ======== Testing with C++ standard flags: '' -./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: -./c++.at:572: $here/modern +./c++.at:571: $here/modern stdout: Legac++ -./c++.at:572: $PREPARSER ./list +./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -249688,44 +249847,54 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -stderr: -stdout: -./c++.at:235: $PREPARSER ./list -stderr: -./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -stderr: -stdout: -./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none -stderr: -stdout: +./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: -./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stdout: ./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: -./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -stderr: +./c++.at:566: $here/modern stdout: -./c++.at:92: $PREPARSER ./input +Modern C++: 201402 +./c++.at:566: $PREPARSER ./list stderr: -./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Destroy: "0" +Destroy: "0" +Destroy: 1 +Destroy: "1" +Destroy: (0) +Destroy: "2" +Destroy: "2" +Destroy: (0, 1) +Destroy: "" +Destroy: 3 +Destroy: (0, 1, 2) +Destroy: "4" +Destroy: "4" +Destroy: (0, 1, 2) +Destroy: (0, 1, 2, 4) +Destroy: 5 +Destroy: (0, 1, 2, 4) +Destroy: "6" +Destroy: "6" +Destroy: (0, 1, 2, 4) +Destroy: (0, 1, 2, 4, 6) +./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:92: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./c++.at:92: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: -./c++.at:571: $here/modern +./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +stderr: stdout: -Legac++ -./c++.at:571: $PREPARSER ./list +./c++.at:567: $here/modern +stdout: +Modern C++: 201103 +./c++.at:567: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -249748,16 +249917,20 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) +./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: -./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:566: $here/modern +./c++.at:572: $here/modern +stderr: stdout: -Modern C++: 201103 -./c++.at:566: $PREPARSER ./list +stdout: +Legac++ +./c++.at:572: $PREPARSER ./list stderr: -======== Testing with C++ standard flags: '' -./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS Destroy: "0" Destroy: "0" Destroy: 1 @@ -249779,18 +249952,65 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: +./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:235: $PREPARSER ./list +stderr: +./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:569: $here/modern +./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +======== Testing with C++ standard flags: '' +./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +stderr: stdout: -Legac++ -./c++.at:569: $PREPARSER ./list +./c++.at:568: $here/modern +stdout: +Modern C++: 201103 +./c++.at:568: $PREPARSER ./list +stderr: +Destroy: "" +Destroy: "" +Destroy: 1 +Destroy: "" +Destroy: () +Destroy: "" +Destroy: "" +Destroy: () +Destroy: "" +Destroy: 3 +Destroy: () +Destroy: "" +Destroy: "" +Destroy: () +Destroy: () +Destroy: 5 +Destroy: () +Destroy: "" +Destroy: "" +Destroy: () +Destroy: (0, 1, 2, 4, 6) +./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stdout: +======== Testing with C++ standard flags: '' +./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +stderr: +stdout: +./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: +stdout: +./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: +./c++.at:570: $here/modern +stdout: +Modern C++: 201103 +./c++.at:570: $PREPARSER ./list +stderr: Destroy: "0" Destroy: "0" Destroy: 1 @@ -249812,13 +250032,26 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -./c++.at:567: $here/modern -./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +======== Testing with C++ standard flags: '' +./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stdout: -Modern C++: 201103 -./c++.at:567: $PREPARSER ./list -./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:92: $PREPARSER ./input +stderr: +./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +663. c++.at:26: ok +stderr: +stdout: +./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS + +stderr: +stdout: +./c++.at:574: $here/modern +stdout: +Legac++ +./c++.at:574: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -249841,41 +250074,58 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +675. c++.at:584: testing Variants and Typed Midrule Actions ... ======== Testing with C++ standard flags: '' -./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: -./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -stderr: +./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: -stdout: -./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: -./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: -./c++.at:235: $PREPARSER ./list -stderr: -./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:569: $here/modern stderr: stdout: -./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -stderr: stdout: +Modern C++: 201103 ./c++.at:573: $here/modern +./c++.at:569: $PREPARSER ./list +stderr: +Destroy: "0" +Destroy: "0" +Destroy: 1 +Destroy: "1" +Destroy: (0) +Destroy: "2" +Destroy: "2" +Destroy: (0, 1) +Destroy: "" +Destroy: 3 +Destroy: (0, 1, 2) +Destroy: "4" +Destroy: "4" +Destroy: (0, 1, 2) +Destroy: (0, 1, 2, 4) +Destroy: 5 +Destroy: (0, 1, 2, 4) +Destroy: "6" +Destroy: "6" +Destroy: (0, 1, 2, 4) +Destroy: (0, 1, 2, 4, 6) stdout: Legac++ ./c++.at:573: $PREPARSER ./list +./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Destroy: "0" Destroy: "0" @@ -249900,15 +250150,18 @@ Destroy: (0, 1, 2, 4, 6) ./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' +./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +======== Testing with C++ standard flags: '' ./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: -./c++.at:572: $here/modern +./c++.at:566: $here/modern stdout: -Legac++ -./c++.at:572: $PREPARSER ./list -stderr: ./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +Modern C++: 201703 +./c++.at:566: $PREPARSER ./list +stderr: Destroy: "0" Destroy: "0" Destroy: 1 @@ -249930,16 +250183,17 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./existing.at:808: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -Wall --report=all,no-cex --header -o input.c input.y --warnings=none -Werror --trace=none +./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: -./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: -./c++.at:574: $here/modern +./c++.at:567: $here/modern stdout: -Legac++ -./c++.at:574: $PREPARSER ./list +Modern C++: 201402 +./c++.at:567: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -249962,16 +250216,15 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: -./c++.at:570: $here/modern +./c++.at:571: $here/modern stdout: Modern C++: 201103 -./c++.at:570: $PREPARSER ./list +./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -249994,14 +250247,54 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: -./c++.at:568: $here/modern ======== Testing with C++ standard flags: '' -./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +stderr: +stdout: +./c++.at:572: $here/modern stdout: Modern C++: 201103 +./c++.at:572: $PREPARSER ./list +stderr: +Destroy: "0" +Destroy: "0" +Destroy: 1 +Destroy: "1" +Destroy: (0) +Destroy: "2" +Destroy: "2" +Destroy: (0, 1) +Destroy: "" +Destroy: 3 +Destroy: (0, 1, 2) +Destroy: "4" +Destroy: "4" +Destroy: (0, 1, 2) +Destroy: (0, 1, 2, 4) +Destroy: 5 +Destroy: (0, 1, 2, 4) +Destroy: "6" +Destroy: "6" +Destroy: (0, 1, 2, 4) +Destroy: (0, 1, 2, 4, 6) +./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +stderr: +stdout: +./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +stderr: +stdout: +./c++.at:568: $here/modern +stdout: +Modern C++: 201402 ./c++.at:568: $PREPARSER ./list stderr: Destroy: "" @@ -250028,39 +250321,79 @@ ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: -./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -stderr: -stdout: -./c++.at:92: $PREPARSER ./input +./c++.at:235: $PREPARSER ./list stderr: -./c++.at:92: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -663. c++.at:26: ok - -675. c++.at:584: testing Variants and Typed Midrule Actions ... +./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: -./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: -./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:659: $PREPARSER ./input +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +Next token is token NUMBER (1) +Shifting token NUMBER (1) +Entering state 1 +Stack now 0 1 +Reducing stack by rule 1 (line 34): + $1 = token NUMBER (1) +-> $$ = nterm expr (10) +destroy: 1 +Entering state 2 +Stack now 0 2 +Reading a token +Next token is token NUMBER (30) +Reducing stack by rule 2 (line 35): +-> $$ = nterm @1 (20) +Entering state 4 +Stack now 0 2 4 +Next token is token NUMBER (30) +Shifting token NUMBER (30) +Entering state 5 +Stack now 0 2 4 5 +Reducing stack by rule 3 (line 35): + $1 = nterm expr (10) + $2 = nterm @1 (20) + $3 = token NUMBER (30) +expr: 10 20 30 +-> $$ = nterm expr (40) +destroy: 30 +destroy: 20 +destroy: 10 +Entering state 2 +Stack now 0 2 +Reading a token +Next token is token EOI () +Shifting token EOI () +Entering state 3 +Stack now 0 2 3 +Stack now 0 2 3 +Cleanup: popping token EOI () +Cleanup: popping nterm expr (40) +destroy: 40 +./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: -./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stdout: -./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: -./c++.at:571: $here/modern +./c++.at:573: $here/modern stdout: Modern C++: 201103 -./c++.at:571: $PREPARSER ./list +./c++.at:573: $PREPARSER ./list stderr: -./existing.at:808: sed -n 's/^State //p' input.output | tail -1 Destroy: "0" Destroy: "0" Destroy: 1 @@ -250082,29 +250415,23 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: -./c++.at:235: $PREPARSER ./list -stderr: -./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./existing.at:808: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: -======== Testing with C++ standard flags: '' -./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -./c++.at:235: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: +./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: -./c++.at:567: $here/modern +./c++.at:571: $here/modern stdout: -./c++.at:566: $here/modern Modern C++: 201402 -./c++.at:567: $PREPARSER ./list +./c++.at:571: $PREPARSER ./list stderr: -stdout: Destroy: "0" Destroy: "0" Destroy: 1 @@ -250126,9 +250453,16 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) +./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +stderr: +stdout: +./c++.at:570: $here/modern +stdout: Modern C++: 201402 -./c++.at:566: $PREPARSER ./list -./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:570: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -250151,18 +250485,22 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) +./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: -./c++.at:569: $here/modern +./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +stderr: +stderr: stdout: -Modern C++: 201103 -./c++.at:569: $PREPARSER ./list +stdout: +./c++.at:566: $here/modern +stdout: +./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +Modern C++: 202002 +./c++.at:566: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -250185,34 +250523,28 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: -./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +======== Testing with C++ standard flags: '' +./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: +./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stdout: -./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: -./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: -./existing.at:808: $PREPARSER ./input +./c++.at:574: $here/modern +stdout: +Legac++ +./c++.at:574: $PREPARSER ./list stderr: -./existing.at:808: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -621. existing.at:808: ok stderr: stdout: - -./c++.at:572: $here/modern -stdout: -Modern C++: 201103 -./c++.at:572: $PREPARSER ./list -stderr: Destroy: "0" Destroy: "0" Destroy: 1 @@ -250234,27 +250566,15 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: -./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -stderr: -stdout: -./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -======== Testing with C++ standard flags: '' -./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -676. c++.at:794: testing Doxygen Public Documentation ... +./c++.at:567: $here/modern stderr: -./c++.at:794: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy +./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: -./c++.at:573: $here/modern -./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: -Modern C++: 201103 -./c++.at:573: $PREPARSER ./list -stderr: +Modern C++: 201703 +./c++.at:567: $PREPARSER ./list stderr: -stdout: +./c++.at:659: $PREPARSER ./input Destroy: "0" Destroy: "0" Destroy: 1 @@ -250276,9 +250596,12 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:659: $PREPARSER ./input +======== Testing with C++ standard flags: '' +./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./c++.at:794: doxygen --version || exit 77 +======== Testing with C++ standard flags: '' +./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y Starting parse Entering state 0 Stack now 0 @@ -250323,99 +250646,16 @@ Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 -./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ---- /dev/null 2026-03-27 17:47:36.000000000 +0000 -+++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/676/stderr 2026-03-27 18:45:36.501669377 +0000 -@@ -0,0 +1 @@ -+/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/676/test-source: line 180: doxygen: command not found -stdout: -676. c++.at:794: skipped (c++.at:794) -./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS - -stderr: -stdout: -./c++.at:570: $here/modern -stdout: -Modern C++: 201402 -./c++.at:570: $PREPARSER ./list -stderr: -Destroy: "0" -Destroy: "0" -Destroy: 1 -Destroy: "1" -Destroy: (0) -Destroy: "2" -Destroy: "2" -Destroy: (0, 1) -Destroy: "" -Destroy: 3 -Destroy: (0, 1, 2) -Destroy: "4" -Destroy: "4" -Destroy: (0, 1, 2) -Destroy: (0, 1, 2, 4) -Destroy: 5 -Destroy: (0, 1, 2, 4) -Destroy: "6" -Destroy: "6" -Destroy: (0, 1, 2, 4) -Destroy: (0, 1, 2, 4, 6) -stderr: -stdout: -./c++.at:574: $here/modern -./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -677. c++.at:795: testing Doxygen Private Documentation ... -Legac++ -./c++.at:574: $PREPARSER ./list -stderr: -./c++.at:795: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy -Destroy: "0" -Destroy: "0" -Destroy: 1 -Destroy: "1" -Destroy: (0) -Destroy: "2" -Destroy: "2" -Destroy: (0, 1) -Destroy: "" -Destroy: 3 -Destroy: (0, 1, 2) -Destroy: "4" -Destroy: "4" -Destroy: (0, 1, 2) -Destroy: (0, 1, 2, 4) -Destroy: 5 -Destroy: (0, 1, 2, 4) -Destroy: "6" -Destroy: "6" -Destroy: (0, 1, 2, 4) -Destroy: (0, 1, 2, 4, 6) -./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:795: doxygen --version || exit 77 -======== Testing with C++ standard flags: '' -./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ---- /dev/null 2026-03-27 17:47:36.000000000 +0000 -+++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/677/stderr 2026-03-27 18:45:36.757669377 +0000 -@@ -0,0 +1 @@ -+/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/677/test-source: line 180: doxygen: command not found -stdout: -./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -677. c++.at:795: skipped (c++.at:795) -stderr: ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +stderr: stdout: ./c++.at:568: $here/modern +./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stdout: -Modern C++: 201402 +Modern C++: 201703 ./c++.at:568: $PREPARSER ./list stderr: Destroy: "" @@ -250439,40 +250679,16 @@ Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) - -./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -678. c++.at:848: testing Relative namespace references ... -./c++.at:849: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy -./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -======== Testing with C++ standard flags: '' -./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -stderr: -stdout: -./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -stderr: -stdout: -./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -stderr: -stdout: -./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -stderr: -stdout: -./c++.at:571: $here/modern +./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: +./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: +./c++.at:569: $here/modern stdout: Modern C++: 201402 -./c++.at:566: $here/modern -./c++.at:571: $PREPARSER ./list -stdout: -Modern C++: 201703 -./c++.at:566: $PREPARSER ./list -stderr: +======== Testing with C++ standard flags: '' +./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:569: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -250495,57 +250711,17 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Destroy: "0" -Destroy: "0" -Destroy: 1 -Destroy: "1" -Destroy: (0) -Destroy: "2" -Destroy: "2" -Destroy: (0, 1) -Destroy: "" -Destroy: 3 -Destroy: (0, 1, 2) -Destroy: "4" -Destroy: "4" -Destroy: (0, 1, 2) -Destroy: (0, 1, 2, 4) -Destroy: 5 -Destroy: (0, 1, 2, 4) -Destroy: "6" -Destroy: "6" -Destroy: (0, 1, 2, 4) -Destroy: (0, 1, 2, 4, 6) -./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -======== Testing with C++ standard flags: '' -./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -stderr: -stdout: -./c++.at:235: $PREPARSER ./list -stderr: -./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -664. c++.at:107: ok - -stderr: -stdout: -./c++.at:849: $PREPARSER ./input -stderr: -./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -679. c++.at:854: testing Absolute namespace references ... -./c++.at:855: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy +./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: -./c++.at:567: $here/modern +./c++.at:572: $here/modern stdout: -Modern C++: 201703 -./c++.at:567: $PREPARSER ./list +Modern C++: 201402 +./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -250568,18 +250744,21 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' +./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: -./c++.at:569: $here/modern +./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./existing.at:808: sed -n 's/^State //p' input.output | tail -1 +./existing.at:808: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +stderr: +stdout: +./c++.at:573: $here/modern stdout: Modern C++: 201402 -./c++.at:569: $PREPARSER ./list -./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:573: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -250602,14 +250781,22 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: +./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +stderr: +stdout: +./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +stderr: +stdout: +./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: -./c++.at:659: $PREPARSER ./input stdout: +./c++.at:659: $PREPARSER ./input stderr: Starting parse Entering state 0 @@ -250656,27 +250843,22 @@ Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: -stdout: -./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: -./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -stderr: stdout: -./c++.at:572: $here/modern +./c++.at:235: $PREPARSER ./list +./c++.at:571: $here/modern stdout: -Modern C++: 201402 -./c++.at:572: $PREPARSER ./list stderr: +Modern C++: 201703 +./c++.at:235: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:571: $PREPARSER ./list +stderr: +./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +664. c++.at:107: ok Destroy: "0" Destroy: "0" Destroy: 1 @@ -250698,30 +250880,23 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: -stderr: -stdout: -./c++.at:849: $PREPARSER ./input stdout: -stderr: -./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:570: $here/modern ======== Testing with C++ standard flags: '' -./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: + stdout: -./c++.at:573: $here/modern stdout: -Modern C++: 201402 +Modern C++: 201703 +./c++.at:570: $PREPARSER ./list +./existing.at:808: $PREPARSER ./input stderr: -./c++.at:573: $PREPARSER ./list -stdout: stderr: -./c++.at:855: $PREPARSER ./input +stderr: +./existing.at:808: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Destroy: "0" Destroy: "0" Destroy: 1 @@ -250743,20 +250918,34 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -stderr: -./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +stdout: +./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +621. existing.at:808: ok +676. c++.at:794: testing Doxygen Public Documentation ... +./c++.at:794: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy +./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ======== Testing with C++ standard flags: '' -./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y + +./c++.at:794: doxygen --version || exit 77 +--- /dev/null 2025-02-20 11:23:24.000000000 +0000 ++++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/676/stderr 2025-02-22 12:30:18.427145165 +0000 +@@ -0,0 +1 @@ ++/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/676/test-source: line 180: doxygen: command not found +stdout: +676. c++.at:794: 677. c++.at:795: testing Doxygen Private Documentation ... +./c++.at:795: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy +./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS + skipped (c++.at:794) + stderr: stdout: -./c++.at:570: $here/modern +./c++.at:569: $here/modern stdout: +./c++.at:795: doxygen --version || exit 77 Modern C++: 201703 -./c++.at:570: $PREPARSER ./list +./c++.at:569: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -250779,18 +250968,37 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +--- /dev/null 2025-02-20 11:23:24.000000000 +0000 ++++ /build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/677/stderr 2025-02-22 12:30:18.603146281 +0000 +@@ -0,0 +1 @@ ++/build/reproducible-path/bison-3.8.2+dfsg/tests/testsuite.dir/at-groups/677/test-source: line 180: doxygen: command not found +stdout: +./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +677. c++.at:795: skipped (c++.at:795) +678. c++.at:848: testing Relative namespace references ... +./c++.at:849: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ======== Testing with C++ standard flags: '' -./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y + +======== Testing with C++ standard flags: '' +./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +679. c++.at:854: testing Absolute namespace references ... +./c++.at:855: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy +stderr: +stdout: +======== Testing with C++ standard flags: '' +./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: ./c++.at:574: $here/modern stdout: +stderr: Modern C++: 201103 ./c++.at:574: $PREPARSER ./list +stdout: stderr: -stderr: -./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS Destroy: "" Destroy: "" Destroy: 1 @@ -250812,11 +251020,29 @@ Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) +./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +stderr: +./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +stdout: +./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +stderr: +stdout: +stderr: +stdout: +stderr: +./c++.at:849: $PREPARSER ./input +stderr: stdout: +./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:568: $here/modern -./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stdout: -Modern C++: 201703 +Modern C++: 202002 ./c++.at:568: $PREPARSER ./list stderr: Destroy: "" @@ -250840,27 +251066,46 @@ Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) -======== Testing with C++ standard flags: '' -./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: -./c++.at:849: $PREPARSER ./input +./c++.at:567: $here/modern +stdout: +Modern C++: 202002 +./c++.at:567: $PREPARSER ./list stderr: -./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Destroy: "0" +Destroy: "0" +Destroy: 1 +Destroy: "1" +Destroy: (0) +Destroy: "2" +Destroy: "2" +Destroy: (0, 1) +Destroy: "" +Destroy: 3 +Destroy: (0, 1, 2) +Destroy: "4" +Destroy: "4" +Destroy: (0, 1, 2) +Destroy: (0, 1, 2, 4) +Destroy: 5 +Destroy: (0, 1, 2, 4) +Destroy: "6" +Destroy: "6" +Destroy: (0, 1, 2, 4) +Destroy: (0, 1, 2, 4, 6) +./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: +./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: -./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:659: $PREPARSER ./input stderr: +stderr: Starting parse Entering state 0 Stack now 0 @@ -250906,28 +251151,22 @@ Cleanup: popping nterm expr (40) destroy: 40 ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -stderr: -stdout: ./c++.at:855: $PREPARSER ./input stderr: ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -stdout: -./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: -./c++.at:571: $here/modern +./c++.at:572: $here/modern stdout: Modern C++: 201703 -./c++.at:571: $PREPARSER ./list +./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -250950,97 +251189,19 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -stderr: -stdout: -./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -stderr: -stdout: -./c++.at:849: $PREPARSER ./input -stderr: -./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./c++.at:855: $PREPARSER ./input -stderr: -./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./c++.at:569: $here/modern -stdout: +./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: -Modern C++: 201703 -./c++.at:569: $PREPARSER ./list -stdout: -./c++.at:567: $here/modern stdout: stderr: -Modern C++: 202002 -./c++.at:567: $PREPARSER ./list -stderr: -Destroy: "0" -Destroy: "0" -Destroy: 1 -Destroy: "1" -Destroy: (0) -Destroy: "2" -Destroy: "2" -Destroy: (0, 1) -Destroy: "" -Destroy: 3 -Destroy: (0, 1, 2) -Destroy: "4" -Destroy: "4" -Destroy: (0, 1, 2) -Destroy: (0, 1, 2, 4) -Destroy: 5 -Destroy: (0, 1, 2, 4) -Destroy: "6" -Destroy: "6" -Destroy: (0, 1, 2, 4) -Destroy: (0, 1, 2, 4, 6) -Destroy: "0" -Destroy: "0" -Destroy: 1 -Destroy: "1" -Destroy: (0) -Destroy: "2" -Destroy: "2" -Destroy: (0, 1) -Destroy: "" -Destroy: 3 -Destroy: (0, 1, 2) -Destroy: "4" -Destroy: "4" -Destroy: (0, 1, 2) -Destroy: (0, 1, 2, 4) -Destroy: 5 -Destroy: (0, 1, 2, 4) -Destroy: "6" -Destroy: "6" -Destroy: (0, 1, 2, 4) -Destroy: (0, 1, 2, 4, 6) -./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:567: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: stdout: ./c++.at:566: $here/modern stdout: -======== Testing with C++ standard flags: '' -./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -Modern C++: 202002 +Modern C++: 202302 ./c++.at:566: $PREPARSER ./list stderr: +./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS Destroy: "0" Destroy: "0" Destroy: 1 @@ -251062,33 +251223,45 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) +./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +666. c++.at:566: ok stdout: -./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:849: $PREPARSER ./input +stderr: +./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + ======== Testing with C++ standard flags: '' -./c++.at:566: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +680. c++.at:863: testing Syntactically invalid namespace references ... +./c++.at:864: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy +./c++.at:865: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy +./c++.at:868: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy +./c++.at:869: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy +./c++.at:870: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy +680. c++.at:863: ok stderr: stdout: -./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:855: $PREPARSER ./input + stderr: -stdout: -./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +======== Testing with C++ standard flags: '' +./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: -./c++.at:849: $PREPARSER ./input -stderr: -./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +681. c++.at:884: testing Syntax error discarding no lookahead ... ======== Testing with C++ standard flags: '' -./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: stdout: -./c++.at:572: $here/modern +./c++.at:573: $here/modern stdout: +./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS Modern C++: 201703 -./c++.at:572: $PREPARSER ./list +./c++.at:573: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -251111,9 +251284,13 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stdout: +./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ======== Testing with C++ standard flags: '' -./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:659: $PREPARSER ./input @@ -251162,60 +251339,26 @@ Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 -stderr: ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./c++.at:573: $here/modern -stdout: -Modern C++: 201703 -./c++.at:573: $PREPARSER ./list -stderr: -Destroy: "0" -Destroy: "0" -Destroy: 1 -Destroy: "1" -Destroy: (0) -Destroy: "2" -Destroy: "2" -Destroy: (0, 1) -Destroy: "" -Destroy: 3 -Destroy: (0, 1, 2) -Destroy: "4" -Destroy: "4" -Destroy: (0, 1, 2) -Destroy: (0, 1, 2, 4) -Destroy: 5 -Destroy: (0, 1, 2, 4) -Destroy: "6" -Destroy: "6" -Destroy: (0, 1, 2, 4) -Destroy: (0, 1, 2, 4, 6) -./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: -./c++.at:855: $PREPARSER ./input -stderr: -./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:849: $PREPARSER ./input stderr: -stdout: -./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +======== Testing with C++ standard flags: '' stdout: +./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:574: $here/modern stdout: Modern C++: 201402 ./c++.at:574: $PREPARSER ./list stderr: +stdout: +stderr: Destroy: "" Destroy: "" Destroy: 1 @@ -251237,30 +251380,53 @@ Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) +./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: -./c++.at:849: $PREPARSER ./input +./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: -./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stdout: +./c++.at:571: $here/modern +stdout: +Modern C++: 202002 +./c++.at:571: $PREPARSER ./list +stderr: +Destroy: "0" +Destroy: "0" +Destroy: 1 +Destroy: "1" +Destroy: (0) +Destroy: "2" +Destroy: "2" +Destroy: (0, 1) +Destroy: "" +Destroy: 3 +Destroy: (0, 1, 2) +Destroy: "4" +Destroy: "4" +Destroy: (0, 1, 2) +Destroy: (0, 1, 2, 4) +Destroy: 5 +Destroy: (0, 1, 2, 4) +Destroy: "6" +Destroy: "6" +Destroy: (0, 1, 2, 4) +Destroy: (0, 1, 2, 4, 6) stderr: stdout: +./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:855: $PREPARSER ./input stderr: +======== Testing with C++ standard flags: '' +./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -stderr: -stdout: -./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: ./c++.at:570: $here/modern @@ -251292,9 +251458,68 @@ ./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:570: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +stderr: +stdout: +./c++.at:849: $PREPARSER ./input +stderr: +./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +======== Testing with C++ standard flags: '' +stdout: +./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:569: $here/modern +stderr: +stdout: +./c++.at:941: $PREPARSER ./input +stdout: +stderr: +syntax error +Discarding 'a'. +Reducing 'a'. +Modern C++: 202002 +./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:569: $PREPARSER ./list +stderr: +Destroy: "0" +Destroy: "0" +Destroy: 1 +Destroy: "1" +Destroy: (0) +Destroy: "2" +Destroy: "2" +Destroy: (0, 1) +Destroy: "" +Destroy: 3 +Destroy: (0, 1, 2) +Destroy: "4" +Destroy: "4" +Destroy: (0, 1, 2) +Destroy: (0, 1, 2, 4) +Destroy: 5 +Destroy: (0, 1, 2, 4) +Destroy: "6" +Destroy: "6" +Destroy: (0, 1, 2, 4) +Destroy: (0, 1, 2, 4, 6) +======== Testing with C++ standard flags: '' +./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +stderr: +stdout: +./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +stderr: +stdout: +./c++.at:855: $PREPARSER ./input +stderr: stderr: stdout: ./c++.at:659: $PREPARSER ./input +./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 @@ -251340,17 +251565,48 @@ Cleanup: popping token EOI () Cleanup: popping nterm expr (40) destroy: 40 -./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stdout: +======== Testing with C++ standard flags: '' +./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: -./c++.at:571: $here/modern +./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +stderr: +stdout: +./c++.at:849: $PREPARSER ./input +stderr: +./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stderr: +stdout: +./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +stderr: +stderr: +stdout: +stdout: +./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:941: $PREPARSER ./input +stderr: +syntax error +Discarding 'a'. +Reducing 'a'. +./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +stderr: +stdout: +./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:572: $here/modern stdout: Modern C++: 202002 -./c++.at:571: $PREPARSER ./list +./c++.at:572: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -251373,15 +251629,16 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:571: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: -./c++.at:568: $here/modern +./c++.at:574: $here/modern stdout: -Modern C++: 202002 -./c++.at:568: $PREPARSER ./list +Modern C++: 201703 +./c++.at:574: $PREPARSER ./list stderr: Destroy: "" Destroy: "" @@ -251404,11 +251661,9 @@ Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) -./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:568: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:855: $PREPARSER ./input @@ -251416,31 +251671,13 @@ ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: -./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -stderr: -stdout: -./c++.at:849: $PREPARSER ./input -stderr: -./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./c++.at:567: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -stderr: -stdout: -./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -stderr: -stdout: -./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -stderr: -stdout: -./c++.at:569: $here/modern +./c++.at:573: $here/modern stdout: Modern C++: 202002 -./c++.at:569: $PREPARSER ./list +./c++.at:573: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -251463,23 +251700,16 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:569: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -stderr: -stdout: -./c++.at:855: $PREPARSER ./input -stderr: -./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS stderr: stdout: -./c++.at:574: $here/modern -======== Testing with C++ standard flags: '' +./c++.at:568: $here/modern stdout: -./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -Modern C++: 201703 -./c++.at:574: $PREPARSER ./list +Modern C++: 202302 +./c++.at:568: $PREPARSER ./list stderr: Destroy: "" Destroy: "" @@ -251502,14 +251732,39 @@ Destroy: "" Destroy: () Destroy: (0, 1, 2, 4, 6) -./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +668. c++.at:568: ok +stderr: +stdout: + +./c++.at:849: $PREPARSER ./input +stderr: +./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +682. c++.at:1064: testing Syntax error as exception: lalr1.cc ... +./c++.at:1064: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy +======== Testing with C++ standard flags: '' +./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS +stderr: stderr: stdout: +stdout: +./c++.at:941: $PREPARSER ./input +./c++.at:855: $PREPARSER ./input +stderr: +stderr: +syntax error +Discarding 'a'. +Reducing 'a'. +./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +======== Testing with C++ standard flags: '' +./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: -./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stdout: ./c++.at:659: $PREPARSER ./input stderr: @@ -251560,16 +251815,13 @@ ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -stderr: -stdout: -./c++.at:566: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: -./c++.at:573: $here/modern +./c++.at:567: $here/modern stdout: -Modern C++: 202002 -./c++.at:573: $PREPARSER ./list +Modern C++: 202302 +./c++.at:567: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -251592,258 +251844,108 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:573: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:849: $PREPARSER ./input stderr: ./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:850: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy -======== Testing with C++ standard flags: '' -./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./c++.at:567: $here/modern -stdout: -Modern C++: 202302 -./c++.at:567: $PREPARSER ./list -stderr: -stderr: -stdout: -./c++.at:572: $here/modern -stdout: -Destroy: "0" -Destroy: "0" -Destroy: 1 -Destroy: "1" -Destroy: (0) -Destroy: "2" -Destroy: "2" -Destroy: (0, 1) -Destroy: "" -Destroy: 3 -Destroy: (0, 1, 2) -Destroy: "4" -Destroy: "4" -Destroy: (0, 1, 2) -Destroy: (0, 1, 2, 4) -Destroy: 5 -Destroy: (0, 1, 2, 4) -Destroy: "6" -Destroy: "6" -Destroy: (0, 1, 2, 4) -Destroy: (0, 1, 2, 4, 6) -Modern C++: 202002 -./c++.at:572: $PREPARSER ./list -stderr: -./c++.at:567: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Destroy: "0" -Destroy: "0" -Destroy: 1 -Destroy: "1" -Destroy: (0) -Destroy: "2" -Destroy: "2" -Destroy: (0, 1) -Destroy: "" -Destroy: 3 -Destroy: (0, 1, 2) -Destroy: "4" -Destroy: "4" -Destroy: (0, 1, 2) -Destroy: (0, 1, 2, 4) -Destroy: 5 -Destroy: (0, 1, 2, 4) -Destroy: "6" -Destroy: "6" -Destroy: (0, 1, 2, 4) -Destroy: (0, 1, 2, 4, 6) -./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 667. c++.at:567: ok ======== Testing with C++ standard flags: '' -./c++.at:572: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y +./c++.at:849: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -680. c++.at:863: testing Syntactically invalid namespace references ... -./c++.at:864: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy -./c++.at:865: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy -./c++.at:868: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy +683. c++.at:1065: testing Syntax error as exception: glr.cc ... +./c++.at:1065: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy +======== Testing with C++ standard flags: '' +./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: ./c++.at:570: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -./c++.at:869: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy -./c++.at:870: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stderr: stdout: -./c++.at:855: $PREPARSER ./input +./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: +stdout: +./c++.at:855: $PREPARSER ./input stderr: ./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -680. c++.at:863: ok +======== Testing with C++ standard flags: '' +./c++.at:855: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: -./c++.at:856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stdout: -./c++.at:568: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS - -./c++.at:571: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -======== Testing with C++ standard flags: '' -./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -681. c++.at:884: testing Syntax error discarding no lookahead ... +./c++.at:941: $PREPARSER ./input +stderr: +syntax error +Discarding 'a'. +Reducing 'a'. +./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' ./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: -./c++.at:566: $here/modern -stdout: -Modern C++: 202302 -./c++.at:566: $PREPARSER ./list -stderr: -Destroy: "0" -Destroy: "0" -Destroy: 1 -Destroy: "1" -Destroy: (0) -Destroy: "2" -Destroy: "2" -Destroy: (0, 1) -Destroy: "" -Destroy: 3 -Destroy: (0, 1, 2) -Destroy: "4" -Destroy: "4" -Destroy: (0, 1, 2) -Destroy: (0, 1, 2, 4) -Destroy: 5 -Destroy: (0, 1, 2, 4) -Destroy: "6" -Destroy: "6" -Destroy: (0, 1, 2, 4) -Destroy: (0, 1, 2, 4, 6) -./c++.at:566: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -666. c++.at:566: ok +./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: - -./c++.at:850: $PREPARSER ./input -stderr: -./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: -./c++.at:659: $PREPARSER ./input -682. c++.at:1064: testing Syntax error as exception: lalr1.cc ... -./c++.at:1064: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -Next token is token NUMBER (1) -Shifting token NUMBER (1) -Entering state 1 -Stack now 0 1 -Reducing stack by rule 1 (line 34): - $1 = token NUMBER (1) --> $$ = nterm expr (10) -destroy: 1 -Entering state 2 -Stack now 0 2 -Reading a token -Next token is token NUMBER (30) -Reducing stack by rule 2 (line 35): --> $$ = nterm @1 (20) -Entering state 4 -Stack now 0 2 4 -Next token is token NUMBER (30) -Shifting token NUMBER (30) -Entering state 5 -Stack now 0 2 4 5 -Reducing stack by rule 3 (line 35): - $1 = nterm expr (10) - $2 = nterm @1 (20) - $3 = token NUMBER (30) -expr: 10 20 30 --> $$ = nterm expr (40) -destroy: 30 -destroy: 20 -destroy: 10 -Entering state 2 -Stack now 0 2 -Reading a token -Next token is token EOI () -Shifting token EOI () -Entering state 3 -Stack now 0 2 3 -Stack now 0 2 3 -Cleanup: popping token EOI () -Cleanup: popping nterm expr (40) -destroy: 40 -./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:659: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -======== Testing with C++ standard flags: '' -./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS -./c++.at:659: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1064: $PREPARSER ./input < in stderr: -stdout: -./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +error: invalid expression +caught error +error: invalid character +caught error +./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1064: $PREPARSER ./input < in stderr: -stdout: -./c++.at:856: $PREPARSER ./input +error: invalid expression +./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1064: $PREPARSER ./input < in stderr: -./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +error: invalid character +./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: -./c++.at:850: $PREPARSER ./input -stderr: -./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS stderr: stdout: -./c++.at:570: $here/modern +./c++.at:574: $here/modern stdout: -Modern C++: 202302 -./c++.at:570: $PREPARSER ./list +Modern C++: 202002 +./c++.at:574: $PREPARSER ./list stderr: -Destroy: "0" -Destroy: "0" +Destroy: "" +Destroy: "" Destroy: 1 -Destroy: "1" -Destroy: (0) -Destroy: "2" -Destroy: "2" -Destroy: (0, 1) +Destroy: "" +Destroy: () +Destroy: "" +Destroy: "" +Destroy: () Destroy: "" Destroy: 3 -Destroy: (0, 1, 2) -Destroy: "4" -Destroy: "4" -Destroy: (0, 1, 2) -Destroy: (0, 1, 2, 4) +Destroy: () +Destroy: "" +Destroy: "" +Destroy: () +Destroy: () Destroy: 5 -Destroy: (0, 1, 2, 4) -Destroy: "6" -Destroy: "6" -Destroy: (0, 1, 2, 4) +Destroy: () +Destroy: "" +Destroy: "" +Destroy: () Destroy: (0, 1, 2, 4, 6) -./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -670. c++.at:570: ok +./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y stderr: stdout: ./c++.at:571: $here/modern -stderr: stdout: Modern C++: 202302 -stdout: ./c++.at:571: $PREPARSER ./list stderr: Destroy: "0" @@ -251867,158 +251969,68 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:568: $here/modern -stdout: ./c++.at:571: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Modern C++: 202302 -./c++.at:568: $PREPARSER ./list 671. c++.at:571: ok -stderr: - -Destroy: "" -Destroy: "" -Destroy: 1 -Destroy: "" -Destroy: () -Destroy: "" -Destroy: "" -Destroy: () -Destroy: "" -Destroy: 3 -Destroy: () -Destroy: "" -Destroy: "" -Destroy: () -Destroy: () -Destroy: 5 -Destroy: () -Destroy: "" -Destroy: "" -Destroy: () -Destroy: (0, 1, 2, 4, 6) -./c++.at:568: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -683. c++.at:1065: testing Syntax error as exception: glr.cc ... - -./c++.at:1065: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy -668. c++.at:568: ok -684. c++.at:1066: testing Syntax error as exception: glr2.cc ... +./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS -./c++.at:1066: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy -======== Testing with C++ standard flags: '' -./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS -685. c++.at:1360: testing Exception safety with error recovery ... -./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o exceptions exceptions.cc $LIBS stderr: stdout: -./c++.at:574: $here/modern -stdout: -Modern C++: 202002 -./c++.at:574: $PREPARSER ./list -stderr: -Destroy: "" -Destroy: "" -Destroy: 1 -Destroy: "" -Destroy: () -Destroy: "" -Destroy: "" -Destroy: () -Destroy: "" -Destroy: 3 -Destroy: () -Destroy: "" -Destroy: "" -Destroy: () -Destroy: () -Destroy: 5 -Destroy: () -Destroy: "" -Destroy: "" -Destroy: () -Destroy: (0, 1, 2, 4, 6) -======== Testing with C++ standard flags: '' -./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -======== Testing with C++ standard flags: '' -./c++.at:574: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o list.cc list.y -./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o list list.cc $LIBS +./c++.at:849: $PREPARSER ./input stderr: -stdout: -./c++.at:1066: ./check -./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS +./c++.at:849: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +684. c++.at:1066: testing Syntax error as exception: glr2.cc ... stderr: +./c++.at:1066: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stdout: -./c++.at:856: $PREPARSER ./input +./c++.at:850: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy +./c++.at:1065: $PREPARSER ./input < in stderr: -./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +error: invalid expression +caught error +error: invalid character +caught error +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +======== Testing with C++ standard flags: '' +./c++.at:1065: $PREPARSER ./input < in stderr: -stdout: -./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +error: invalid expression +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1065: $PREPARSER ./input < in +stderr: +error: invalid character +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: +======== Testing with C++ standard flags: '' ./c++.at:941: $PREPARSER ./input +./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS +stderr: stderr: syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: -./c++.at:569: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -======== Testing with C++ standard flags: '' -./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./c++.at:850: $PREPARSER ./input -stderr: -./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -stderr: -./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: -./c++.at:1360: ./exceptions || exit 77 +./c++.at:1066: ./check +./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: -Inner caught -Outer caught -./c++.at:1360: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc --report=all input.yy ======== Testing with C++ standard flags: '' -./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./c++.at:1064: $PREPARSER ./input < in -stderr: -error: invalid expression -caught error -error: invalid character -caught error -./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1064: $PREPARSER ./input < in -stderr: -error: invalid expression -./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1064: $PREPARSER ./input < in +./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: -error: invalid character -./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: -./c++.at:856: $PREPARSER ./input -stderr: -./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: stdout: -./c++.at:572: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS -stderr: stdout: +./c++.at:570: $here/modern ./c++.at:659: $PREPARSER ./input +./c++.at:573: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +stdout: stderr: +Modern C++: 202302 +./c++.at:570: $PREPARSER ./list Starting parse Entering state 0 Stack now 0 @@ -252065,12 +252077,6 @@ destroy: 40 ./c++.at:659: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -stdout: -./c++.at:573: $here/modern -stdout: -Modern C++: 202302 -./c++.at:573: $PREPARSER ./list -stderr: Destroy: "0" Destroy: "0" Destroy: 1 @@ -252092,44 +252098,47 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -673. c++.at:573: ok +./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 675. c++.at:584: ok +./c++.at:570: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +670. c++.at:570: ok - -686. c++.at:1361: testing Exception safety without error recovery ... -./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o exceptions exceptions.cc $LIBS -687. c++.at:1362: testing Exception safety with error recovery api.value.type=variant ... -./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o exceptions exceptions.cc $LIBS +stderr: stderr: stdout: -./c++.at:850: $PREPARSER ./input +stdout: +./c++.at:855: $PREPARSER ./input +./c++.at:1064: $PREPARSER ./input < in stderr: -./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:855: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -stdout: -./c++.at:856: $PREPARSER ./input +error: invalid expression +caught error +error: invalid character +caught error +./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + +685. c++.at:1360: testing Exception safety with error recovery ... +./c++.at:1064: $PREPARSER ./input < in +./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o exceptions exceptions.cc $LIBS +./c++.at:856: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stderr: -./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +error: invalid expression +./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' +./c++.at:1064: $PREPARSER ./input < in ./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +686. c++.at:1361: testing Exception safety without error recovery ... +./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o exceptions exceptions.cc $LIBS stderr: +error: invalid character +./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stdout: -./c++.at:941: $PREPARSER ./input -stderr: -syntax error -Discarding 'a'. -Reducing 'a'. -./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -======== Testing with C++ standard flags: '' -./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y ./c++.at:569: $here/modern stdout: -./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS Modern C++: 202302 ./c++.at:569: $PREPARSER ./list stderr: @@ -252157,88 +252166,91 @@ ./c++.at:569: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 669. c++.at:569: ok +687. c++.at:1362: testing Exception safety with error recovery api.value.type=variant ... stderr: +./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o exceptions exceptions.cc $LIBS stdout: -./c++.at:1064: $PREPARSER ./input < in +./c++.at:572: $here/modern +stdout: +Modern C++: 202302 +./c++.at:572: $PREPARSER ./list stderr: -error: invalid expression -caught error -error: invalid character -caught error -./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1064: $PREPARSER ./input < in -688. c++.at:1363: testing Exception safety without error recovery api.value.type=variant ... +Destroy: "0" +Destroy: "0" +Destroy: 1 +Destroy: "1" +Destroy: (0) +Destroy: "2" +Destroy: "2" +Destroy: (0, 1) +Destroy: "" +Destroy: 3 +Destroy: (0, 1, 2) +Destroy: "4" +Destroy: "4" +Destroy: (0, 1, 2) +Destroy: (0, 1, 2, 4) +Destroy: 5 +Destroy: (0, 1, 2, 4) +Destroy: "6" +Destroy: "6" +Destroy: (0, 1, 2, 4) +Destroy: (0, 1, 2, 4, 6) stderr: -error: invalid expression -./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1064: $PREPARSER ./input < in +stdout: +./c++.at:850: $PREPARSER ./input +./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -error: invalid character -./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o exceptions exceptions.cc $LIBS +./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +672. c++.at:572: ok ======== Testing with C++ standard flags: '' -./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS +./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS + stderr: stdout: -./c++.at:1362: ./exceptions || exit 77 +./c++.at:1360: ./exceptions || exit 77 stderr: Inner caught Outer caught -./c++.at:1362: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc --report=all input.yy stderr: +./c++.at:1360: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc --report=all input.yy stdout: ./c++.at:1361: ./exceptions || exit 77 +688. c++.at:1363: testing Exception safety without error recovery api.value.type=variant ... stderr: +./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o exceptions exceptions.cc $LIBS Inner caught Outer caught ./c++.at:1361: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc --report=all input.yy ======== Testing with C++ standard flags: '' -./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./c++.at:1065: $PREPARSER ./input < in -stderr: -error: invalid expression -caught error -error: invalid character -caught error -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ======== Testing with C++ standard flags: '' -./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./c++.at:1065: $PREPARSER ./input < in -stderr: -error: invalid expression -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: -./c++.at:850: $PREPARSER ./input -stderr: -./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1065: $PREPARSER ./input < in -======== Testing with C++ standard flags: '' -./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1362: ./exceptions || exit 77 stderr: -error: invalid character -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS +Inner caught +Outer caught +./c++.at:1362: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc --report=all input.yy stderr: stdout: ./c++.at:941: $PREPARSER ./input stderr: +======== Testing with C++ standard flags: '' syntax error Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: -./c++.at:572: $here/modern +./c++.at:573: $here/modern +======== Testing with C++ standard flags: '' +./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stdout: Modern C++: 202302 -./c++.at:572: $PREPARSER ./list +./c++.at:573: $PREPARSER ./list stderr: Destroy: "0" Destroy: "0" @@ -252261,1386 +252273,1035 @@ Destroy: "6" Destroy: (0, 1, 2, 4) Destroy: (0, 1, 2, 4, 6) -./c++.at:572: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:573: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +673. c++.at:573: ok + stderr: +stderr: +stdout: +./c++.at:850: $PREPARSER ./input stdout: +stderr: ./c++.at:1363: ./exceptions || exit 77 +./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +======== Testing with C++ standard flags: '' Inner caught Outer caught +./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stderr: ./c++.at:1363: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc --report=all input.yy +stdout: +689. c++.at:1371: testing C++ GLR parser identifier shadowing ... +./c++.at:1410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy +./c++.at:856: $PREPARSER ./input +stderr: +./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +======== Testing with C++ standard flags: '' +./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +======== Testing with C++ standard flags: '' +./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stderr: +stdout: +./c++.at:1065: $PREPARSER ./input < in +stderr: +error: invalid expression +caught error +error: invalid character +caught error +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1065: $PREPARSER ./input < in +stderr: +error: invalid expression +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1065: $PREPARSER ./input < in +stderr: +error: invalid character +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS +stderr: +stdout: +./c++.at:1064: $PREPARSER ./input < in +stderr: +error: invalid expression +caught error +error: invalid character +caught error +./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1064: $PREPARSER ./input < in +stderr: +error: invalid expression +./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1064: $PREPARSER ./input < in +stderr: +error: invalid character +./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS +stderr: +stdout: +./c++.at:856: $PREPARSER ./input +stderr: +./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stderr: +stdout: +stderr: +stdout: +./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS +./c++.at:850: $PREPARSER ./input +stderr: +./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./c++.at:1360: $PREPARSER ./input aaaas stderr: -672. c++.at:572: ok exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaal - stderr: exception caught: yylex ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -689. c++.at:1371: testing C++ GLR parser identifier shadowing ... -./c++.at:1410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy -./c++.at:1360: $PREPARSER ./input i -stderr: -exception caught: initial-action -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: -./c++.at:856: $PREPARSER ./input -./c++.at:1360: $PREPARSER ./input aaaap +./c++.at:1360: $PREPARSER ./input i ======== Testing with C++ standard flags: '' stderr: ./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +exception caught: initial-action +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: $PREPARSER ./input aaaap stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1360: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xaaaaf2a7af40->Object::Object { } -Next token is token 'a' (0xaaaaf2a7af40 'a') -Shifting token 'a' (0xaaaaf2a7af40 'a') +0xaaaaeb106f40->Object::Object { } +Next token is token 'a' (0xaaaaeb106f40 'a') +Shifting token 'a' (0xaaaaeb106f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf2a7af40 'a') --> $$ = nterm item (0xaaaaf2a7af40 'a') + $1 = token 'a' (0xaaaaeb106f40 'a') +-> $$ = nterm item (0xaaaaeb106f40 'a') Entering state 11 Stack now 0 11 Reading a token -0xaaaaf2a7af90->Object::Object { 0xaaaaf2a7af40 } -Next token is token 'a' (0xaaaaf2a7af90 'a') -Shifting token 'a' (0xaaaaf2a7af90 'a') +0xaaaaeb106f90->Object::Object { 0xaaaaeb106f40 } +Next token is token 'a' (0xaaaaeb106f90 'a') +Shifting token 'a' (0xaaaaeb106f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf2a7af90 'a') --> $$ = nterm item (0xaaaaf2a7af90 'a') + $1 = token 'a' (0xaaaaeb106f90 'a') +-> $$ = nterm item (0xaaaaeb106f90 'a') Entering state 11 Stack now 0 11 11 Reading a token -0xaaaaf2a7afe0->Object::Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90 } -Next token is token 'a' (0xaaaaf2a7afe0 'a') -Shifting token 'a' (0xaaaaf2a7afe0 'a') +0xaaaaeb106fe0->Object::Object { 0xaaaaeb106f40, 0xaaaaeb106f90 } +Next token is token 'a' (0xaaaaeb106fe0 'a') +Shifting token 'a' (0xaaaaeb106fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf2a7afe0 'a') --> $$ = nterm item (0xaaaaf2a7afe0 'a') + $1 = token 'a' (0xaaaaeb106fe0 'a') +-> $$ = nterm item (0xaaaaeb106fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token -0xaaaaf2a7b030->Object::Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0 } -Next token is token 'a' (0xaaaaf2a7b030 'a') -Shifting token 'a' (0xaaaaf2a7b030 'a') +0xaaaaeb107030->Object::Object { 0xaaaaeb106f40, 0xaaaaeb106f90, 0xaaaaeb106fe0 } +Next token is token 'a' (0xaaaaeb107030 'a') +Shifting token 'a' (0xaaaaeb107030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf2a7b030 'a') --> $$ = nterm item (0xaaaaf2a7b030 'a') + $1 = token 'a' (0xaaaaeb107030 'a') +-> $$ = nterm item (0xaaaaeb107030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token -0xaaaaf2a7b080->Object::Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0, 0xaaaaf2a7b030 } -Next token is token 'p' (0xaaaaf2a7b080 'p'Exception caught: cleaning lookahead and stack -0xaaaaf2a7b080->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0, 0xaaaaf2a7b030, 0xaaaaf2a7b080 } -0xaaaaf2a7b030->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0, 0xaaaaf2a7b030 } -0xaaaaf2a7afe0->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0 } -0xaaaaf2a7af90->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90 } -0xaaaaf2a7af40->Object::~Object { 0xaaaaf2a7af40 } +0xaaaaeb107080->Object::Object { 0xaaaaeb106f40, 0xaaaaeb106f90, 0xaaaaeb106fe0, 0xaaaaeb107030 } +Next token is token 'p' (0xaaaaeb107080 'p'Exception caught: cleaning lookahead and stack +0xaaaaeb107080->Object::~Object { 0xaaaaeb106f40, 0xaaaaeb106f90, 0xaaaaeb106fe0, 0xaaaaeb107030, 0xaaaaeb107080 } +0xaaaaeb107030->Object::~Object { 0xaaaaeb106f40, 0xaaaaeb106f90, 0xaaaaeb106fe0, 0xaaaaeb107030 } +0xaaaaeb106fe0->Object::~Object { 0xaaaaeb106f40, 0xaaaaeb106f90, 0xaaaaeb106fe0 } +0xaaaaeb106f90->Object::~Object { 0xaaaaeb106f40, 0xaaaaeb106f90 } +0xaaaaeb106f40->Object::~Object { 0xaaaaeb106f40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xaaaaf2a7af40->Object::Object { } -Next token is token 'a' (0xaaaaf2a7af40 'a') -Shifting token 'a' (0xaaaaf2a7af40 'a') +0xaaaaeb106f40->Object::Object { } +Next token is token 'a' (0xaaaaeb106f40 'a') +Shifting token 'a' (0xaaaaeb106f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf2a7af40 'a') --> $$ = nterm item (0xaaaaf2a7af40 'a') + $1 = token 'a' (0xaaaaeb106f40 'a') +-> $$ = nterm item (0xaaaaeb106f40 'a') Entering state 11 Stack now 0 11 Reading a token -0xaaaaf2a7af90->Object::Object { 0xaaaaf2a7af40 } -Next token is token 'a' (0xaaaaf2a7af90 'a') -Shifting token 'a' (0xaaaaf2a7af90 'a') +0xaaaaeb106f90->Object::Object { 0xaaaaeb106f40 } +Next token is token 'a' (0xaaaaeb106f90 'a') +Shifting token 'a' (0xaaaaeb106f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf2a7af90 'a') --> $$ = nterm item (0xaaaaf2a7af90 'a') + $1 = token 'a' (0xaaaaeb106f90 'a') +-> $$ = nterm item (0xaaaaeb106f90 'a') Entering state 11 Stack now 0 11 11 Reading a token -0xaaaaf2a7afe0->Object::Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90 } -Next token is token 'a' (0xaaaaf2a7afe0 'a') -Shifting token 'a' (0xaaaaf2a7afe0 'a') +0xaaaaeb106fe0->Object::Object { 0xaaaaeb106f40, 0xaaaaeb106f90 } +Next token is token 'a' (0xaaaaeb106fe0 'a') +Shifting token 'a' (0xaaaaeb106fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf2a7afe0 'a') --> $$ = nterm item (0xaaaaf2a7afe0 'a') + $1 = token 'a' (0xaaaaeb106fe0 'a') +-> $$ = nterm item (0xaaaaeb106fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token -0xaaaaf2a7b030->Object::Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0 } -Next token is token 'a' (0xaaaaf2a7b030 'a') -Shifting token 'a' (0xaaaaf2a7b030 'a') +0xaaaaeb107030->Object::Object { 0xaaaaeb106f40, 0xaaaaeb106f90, 0xaaaaeb106fe0 } +Next token is token 'a' (0xaaaaeb107030 'a') +Shifting token 'a' (0xaaaaeb107030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf2a7b030 'a') --> $$ = nterm item (0xaaaaf2a7b030 'a') + $1 = token 'a' (0xaaaaeb107030 'a') +-> $$ = nterm item (0xaaaaeb107030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token -0xaaaaf2a7b080->Object::Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0, 0xaaaaf2a7b030 } -Next token is token 'p' (0xaaaaf2a7b080 'p'Exception caught: cleaning lookahead and stack -0xaaaaf2a7b080->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0, 0xaaaaf2a7b030, 0xaaaaf2a7b080 } -0xaaaaf2a7b030->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0, 0xaaaaf2a7b030 } -0xaaaaf2a7afe0->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90, 0xaaaaf2a7afe0 } -0xaaaaf2a7af90->Object::~Object { 0xaaaaf2a7af40, 0xaaaaf2a7af90 } -0xaaaaf2a7af40->Object::~Object { 0xaaaaf2a7af40 } +0xaaaaeb107080->Object::Object { 0xaaaaeb106f40, 0xaaaaeb106f90, 0xaaaaeb106fe0, 0xaaaaeb107030 } +Next token is token 'p' (0xaaaaeb107080 'p'Exception caught: cleaning lookahead and stack +0xaaaaeb107080->Object::~Object { 0xaaaaeb106f40, 0xaaaaeb106f90, 0xaaaaeb106fe0, 0xaaaaeb107030, 0xaaaaeb107080 } +0xaaaaeb107030->Object::~Object { 0xaaaaeb106f40, 0xaaaaeb106f90, 0xaaaaeb106fe0, 0xaaaaeb107030 } +0xaaaaeb106fe0->Object::~Object { 0xaaaaeb106f40, 0xaaaaeb106f90, 0xaaaaeb106fe0 } +0xaaaaeb106f90->Object::~Object { 0xaaaaeb106f40, 0xaaaaeb106f90 } +0xaaaaeb106f40->Object::~Object { 0xaaaaeb106f40 } exception caught: printer end { } ./c++.at:1360: grep '^exception caught: printer$' stderr stdout: -stdout: exception caught: printer -./c++.at:574: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o modern modern.cc $LIBS ./c++.at:1360: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input aaaaE -stderr: -exception caught: syntax error, unexpected end of file, expecting 'a' -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: -./c++.at:1064: $PREPARSER ./input < in -stderr: -error: invalid expression -caught error -error: invalid character -caught error -./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1064: $PREPARSER ./input < in -stderr: -error: invalid expression -./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input aaaaT -./c++.at:1064: $PREPARSER ./input < in -stderr: -stderr: -error: invalid character -./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -stderr: -./c++.at:1360: $PREPARSER ./input aaaaR -stdout: -./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS -./c++.at:850: $PREPARSER ./input -stderr: -stderr: -./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -======== Testing with C++ standard flags: '' -./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./c++.at:1066: $PREPARSER ./input < in -stderr: -error: invalid expression -caught error -error: invalid character -caught error -./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1066: $PREPARSER ./input < in -stderr: -error: invalid expression -./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1066: $PREPARSER ./input < in -stderr: -error: invalid character -./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -stderr: -stderr: -stdout: -./c++.at:1361: $PREPARSER ./input aaaas -stderr: -stderr: -exception caught: reduction -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -stdout: -./c++.at:1065: $PREPARSER ./input < in -./c++.at:1361: $PREPARSER ./input aaaal -stderr: -exception caught: yylex -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -error: invalid expression -caught error -error: invalid character -caught error -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1066: ./check -./c++.at:1361: $PREPARSER ./input i -stderr: -exception caught: initial-action -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr --std=c++98 not supported -======== Testing with C++ standard flags: '' -./c++.at:1361: $PREPARSER ./input aaaap -stderr: -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: $PREPARSER ./input --debug aaaap -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -0xaaaae906cf40->Object::Object { } -Next token is token 'a' (0xaaaae906cf40 'a') -Shifting token 'a' (0xaaaae906cf40 'a') -Entering state 1 -Stack now 0 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae906cf40 'a') --> $$ = nterm item (0xaaaae906cf40 'a') -Entering state 10 -Stack now 0 10 -Reading a token -0xaaaae906cf90->Object::Object { 0xaaaae906cf40 } -Next token is token 'a' (0xaaaae906cf90 'a') -Shifting token 'a' (0xaaaae906cf90 'a') -Entering state 1 -Stack now 0 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae906cf90 'a') --> $$ = nterm item (0xaaaae906cf90 'a') -Entering state 10 -Stack now 0 10 10 -Reading a token -0xaaaae906cfe0->Object::Object { 0xaaaae906cf40, 0xaaaae906cf90 } -Next token is token 'a' (0xaaaae906cfe0 'a') -Shifting token 'a' (0xaaaae906cfe0 'a') -Entering state 1 -Stack now 0 10 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae906cfe0 'a') --> $$ = nterm item (0xaaaae906cfe0 'a') -Entering state 10 -Stack now 0 10 10 10 -Reading a token -0xaaaae906d030->Object::Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0 } -Next token is token 'a' (0xaaaae906d030 'a') -Shifting token 'a' (0xaaaae906d030 'a') -Entering state 1 -Stack now 0 10 10 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae906d030 'a') --> $$ = nterm item (0xaaaae906d030 'a') -Entering state 10 -Stack now 0 10 10 10 10 -Reading a token -0xaaaae906d080->Object::Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0, 0xaaaae906d030 } -Next token is token 'p' (0xaaaae906d080 'p'Exception caught: cleaning lookahead and stack -0xaaaae906d080->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0, 0xaaaae906d030, 0xaaaae906d080 } -0xaaaae906d030->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0, 0xaaaae906d030 } -0xaaaae906cfe0->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0 } -0xaaaae906cf90->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90 } -0xaaaae906cf40->Object::~Object { 0xaaaae906cf40 } -exception caught: printer -end { } -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -0xaaaae906cf40->Object::Object { } -Next token is token 'a' (0xaaaae906cf40 'a') -Shifting token 'a' (0xaaaae906cf40 'a') -Entering state 1 -Stack now 0 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae906cf40 'a') --> $$ = nterm item (0xaaaae906cf40 'a') -Entering state 10 -Stack now 0 10 -Reading a token -0xaaaae906cf90->Object::Object { 0xaaaae906cf40 } -Next token is token 'a' (0xaaaae906cf90 'a') -Shifting token 'a' (0xaaaae906cf90 'a') -Entering state 1 -Stack now 0 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae906cf90 'a') --> $$ = nterm item (0xaaaae906cf90 'a') -Entering state 10 -Stack now 0 10 10 -Reading a token -0xaaaae906cfe0->Object::Object { 0xaaaae906cf40, 0xaaaae906cf90 } -Next token is token 'a' (0xaaaae906cfe0 'a') -Shifting token 'a' (0xaaaae906cfe0 'a') -Entering state 1 -Stack now 0 10 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae906cfe0 'a') --> $$ = nterm item (0xaaaae906cfe0 'a') -Entering state 10 -Stack now 0 10 10 10 -Reading a token -0xaaaae906d030->Object::Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0 } -Next token is token 'a' (0xaaaae906d030 'a') -Shifting token 'a' (0xaaaae906d030 'a') -Entering state 1 -Stack now 0 10 10 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae906d030 'a') --> $$ = nterm item (0xaaaae906d030 'a') -Entering state 10 -Stack now 0 10 10 10 10 -Reading a token -0xaaaae906d080->Object::Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0, 0xaaaae906d030 } -Next token is token 'p' (0xaaaae906d080 'p'Exception caught: cleaning lookahead and stack -0xaaaae906d080->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0, 0xaaaae906d030, 0xaaaae906d080 } -0xaaaae906d030->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0, 0xaaaae906d030 } -0xaaaae906cfe0->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90, 0xaaaae906cfe0 } -0xaaaae906cf90->Object::~Object { 0xaaaae906cf40, 0xaaaae906cf90 } -0xaaaae906cf40->Object::~Object { 0xaaaae906cf40 } -exception caught: printer -end { } -./c++.at:1361: grep '^exception caught: printer$' stderr -stdout: -exception caught: printer -./c++.at:1361: $PREPARSER ./input aaaae -./c++.at:1065: $PREPARSER ./input < in -stderr: -exception caught: syntax error -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -error: invalid expression -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: $PREPARSER ./input aaaaE -stderr: -exception caught: syntax error, unexpected end of file, expecting 'a' -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1065: $PREPARSER ./input < in -stderr: -./c++.at:1361: $PREPARSER ./input aaaaT -error: invalid character -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./c++.at:1361: $PREPARSER ./input aaaaR -./c++.at:1066: ./check -stderr: --std=c++03 not supported -======== Testing with C++ standard flags: '' -======== Testing with C++ standard flags: '' -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS -./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -======== Testing with C++ standard flags: '' -./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./c++.at:856: $PREPARSER ./input stderr: stdout: +./c++.at:1360: $PREPARSER ./input aaaaE ./c++.at:1362: $PREPARSER ./input aaaas stderr: -./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: reduction +exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: $PREPARSER ./input aaaaT stderr: +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input i -stdout: stderr: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1066: ./check +./c++.at:1360: $PREPARSER ./input aaaaR stderr: -stdout: -======== Testing with C++ standard flags: '' -./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaap +======== Testing with C++ standard flags: '' +./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: +stdout: +stderr: +./c++.at:1065: $PREPARSER ./input < in Starting parse Entering state 0 Stack now 0 Reading a token -0xffffea093d10->Object::Object { } -0xffffea093e10->Object::Object { 0xffffea093d10 } -0xffffea093d10->Object::~Object { 0xffffea093d10, 0xffffea093e10 } -Next token is token 'a' (0xffffea093e10 'a') -0xffffea093d50->Object::Object { 0xffffea093e10 } -0xffffea093e10->Object::~Object { 0xffffea093d50, 0xffffea093e10 } -Shifting token 'a' (0xffffea093d50 'a') -0xaaab0a89d2e0->Object::Object { 0xffffea093d50 } -0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xffffea093d50 } +0xffffc1b0e9e0->Object::Object { } +0xffffc1b0eae0->Object::Object { 0xffffc1b0e9e0 } +0xffffc1b0e9e0->Object::~Object { 0xffffc1b0e9e0, 0xffffc1b0eae0 } +Next token is token 'a' (0xffffc1b0eae0 'a') +0xffffc1b0ea20->Object::Object { 0xffffc1b0eae0 } +0xffffc1b0eae0->Object::~Object { 0xffffc1b0ea20, 0xffffc1b0eae0 } +Shifting token 'a' (0xffffc1b0ea20 'a') +0xaaaaf37ff2e0->Object::Object { 0xffffc1b0ea20 } +0xffffc1b0ea20->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0ea20 } Entering state 2 Stack now 0 2 -0xffffea093e30->Object::Object { 0xaaab0a89d2e0 } +0xffffc1b0eb00->Object::Object { 0xaaaaf37ff2e0 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab0a89d2e0 'a') --> $$ = nterm item (0xffffea093e30 'a') -0xaaab0a89d2e0->Object::~Object { 0xaaab0a89d2e0, 0xffffea093e30 } -0xaaab0a89d2e0->Object::Object { 0xffffea093e30 } -0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xffffea093e30 } + $1 = token 'a' (0xaaaaf37ff2e0 'a') +-> $$ = nterm item (0xffffc1b0eb00 'a') +0xaaaaf37ff2e0->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0eb00 } +0xaaaaf37ff2e0->Object::Object { 0xffffc1b0eb00 } +0xffffc1b0eb00->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0eb00 } Entering state 11 Stack now 0 11 Reading a token -0xffffea093d10->Object::Object { 0xaaab0a89d2e0 } -0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xffffea093d10 } -0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xffffea093d10, 0xffffea093e10 } -Next token is token 'a' (0xffffea093e10 'a') -0xffffea093d50->Object::Object { 0xaaab0a89d2e0, 0xffffea093e10 } -0xffffea093e10->Object::~Object { 0xaaab0a89d2e0, 0xffffea093d50, 0xffffea093e10 } -Shifting token 'a' (0xffffea093d50 'a') -0xaaab0a89d300->Object::Object { 0xaaab0a89d2e0, 0xffffea093d50 } -0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d50 } +0xffffc1b0e9e0->Object::Object { 0xaaaaf37ff2e0 } +0xffffc1b0eae0->Object::Object { 0xaaaaf37ff2e0, 0xffffc1b0e9e0 } +0xffffc1b0e9e0->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0e9e0, 0xffffc1b0eae0 } +Next token is token 'a' (0xffffc1b0eae0 'a') +0xffffc1b0ea20->Object::Object { 0xaaaaf37ff2e0, 0xffffc1b0eae0 } +0xffffc1b0eae0->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0ea20, 0xffffc1b0eae0 } +Shifting token 'a' (0xffffc1b0ea20 'a') +0xaaaaf37ff300->Object::Object { 0xaaaaf37ff2e0, 0xffffc1b0ea20 } +0xffffc1b0ea20->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0ea20 } Entering state 2 Stack now 0 11 2 -0xffffea093e30->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300 } +0xffffc1b0eb00->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab0a89d300 'a') --> $$ = nterm item (0xffffea093e30 'a') -0xaaab0a89d300->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e30 } -0xaaab0a89d300->Object::Object { 0xaaab0a89d2e0, 0xffffea093e30 } -0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e30 } + $1 = token 'a' (0xaaaaf37ff300 'a') +-> $$ = nterm item (0xffffc1b0eb00 'a') +0xaaaaf37ff300->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0eb00 } +0xaaaaf37ff300->Object::Object { 0xaaaaf37ff2e0, 0xffffc1b0eb00 } +0xffffc1b0eb00->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0eb00 } Entering state 11 Stack now 0 11 11 Reading a token -0xffffea093d10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300 } -0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d10 } -0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d10, 0xffffea093e10 } -Next token is token 'a' (0xffffea093e10 'a') -0xffffea093d50->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e10 } -0xffffea093e10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d50, 0xffffea093e10 } -Shifting token 'a' (0xffffea093d50 'a') -0xaaab0a89d320->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d50 } -0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d50 } +0xffffc1b0e9e0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300 } +0xffffc1b0eae0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0e9e0 } +0xffffc1b0e9e0->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0e9e0, 0xffffc1b0eae0 } +Next token is token 'a' (0xffffc1b0eae0 'a') +0xffffc1b0ea20->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0eae0 } +0xffffc1b0eae0->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0ea20, 0xffffc1b0eae0 } +Shifting token 'a' (0xffffc1b0ea20 'a') +0xaaaaf37ff320->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0ea20 } +0xffffc1b0ea20->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0ea20 } Entering state 2 Stack now 0 11 11 2 -0xffffea093e30->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320 } +0xffffc1b0eb00->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab0a89d320 'a') --> $$ = nterm item (0xffffea093e30 'a') -0xaaab0a89d320->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e30 } -0xaaab0a89d320->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e30 } -0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e30 } + $1 = token 'a' (0xaaaaf37ff320 'a') +-> $$ = nterm item (0xffffc1b0eb00 'a') +0xaaaaf37ff320->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0eb00 } +0xaaaaf37ff320->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0eb00 } +0xffffc1b0eb00->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0eb00 } Entering state 11 Stack now 0 11 11 11 Reading a token -0xffffea093d10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320 } -0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d10 } -0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d10, 0xffffea093e10 } -Next token is token 'a' (0xffffea093e10 'a') -0xffffea093d50->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e10 } -0xffffea093e10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d50, 0xffffea093e10 } -Shifting token 'a' (0xffffea093d50 'a') -0xaaab0a89d340->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d50 } -0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093d50 } +0xffffc1b0e9e0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320 } +0xffffc1b0eae0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0e9e0 } +0xffffc1b0e9e0->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0e9e0, 0xffffc1b0eae0 } +Next token is token 'a' (0xffffc1b0eae0 'a') +0xffffc1b0ea20->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0eae0 } +0xffffc1b0eae0->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0ea20, 0xffffc1b0eae0 } +Shifting token 'a' (0xffffc1b0ea20 'a') +0xaaaaf37ff340->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0ea20 } +0xffffc1b0ea20->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0ea20 } Entering state 2 Stack now 0 11 11 11 2 -0xffffea093e30->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340 } +0xffffc1b0eb00->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab0a89d340 'a') --> $$ = nterm item (0xffffea093e30 'a') -0xaaab0a89d340->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093e30 } -0xaaab0a89d340->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e30 } -0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093e30 } + $1 = token 'a' (0xaaaaf37ff340 'a') +-> $$ = nterm item (0xffffc1b0eb00 'a') +0xaaaaf37ff340->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0eb00 } +0xaaaaf37ff340->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0eb00 } +0xffffc1b0eb00->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0eb00 } Entering state 11 Stack now 0 11 11 11 11 Reading a token -0xffffea093d10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340 } -0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093d10 } -0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093d10, 0xffffea093e10 } -Next token is token 'p' (0xffffea093e10 'p'Exception caught: cleaning lookahead and stack -0xaaab0a89d340->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093e10 } -0xaaab0a89d320->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e10 } -0xaaab0a89d300->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e10 } -0xaaab0a89d2e0->Object::~Object { 0xaaab0a89d2e0, 0xffffea093e10 } -0xffffea093e10->Object::~Object { 0xffffea093e10 } +0xffffc1b0e9e0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340 } +0xffffc1b0eae0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0e9e0 } +0xffffc1b0e9e0->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0e9e0, 0xffffc1b0eae0 } +Next token is token 'p' (0xffffc1b0eae0 'p'Exception caught: cleaning lookahead and stack +0xaaaaf37ff340->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0eae0 } +0xaaaaf37ff320->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0eae0 } +0xaaaaf37ff300->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0eae0 } +0xaaaaf37ff2e0->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0eae0 } +0xffffc1b0eae0->Object::~Object { 0xffffc1b0eae0 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +stdout: +stderr: +./c++.at:941: $PREPARSER ./input +stderr: +error: invalid expression +caught error +error: invalid character +caught error +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xffffea093d10->Object::Object { } -0xffffea093e10->Object::Object { 0xffffea093d10 } -0xffffea093d10->Object::~Object { 0xffffea093d10, 0xffffea093e10 } -Next token is token 'a' (0xffffea093e10 'a') -0xffffea093d50->Object::Object { 0xffffea093e10 } -0xffffea093e10->Object::~Object { 0xffffea093d50, 0xffffea093e10 } -Shifting token 'a' (0xffffea093d50 'a') -0xaaab0a89d2e0->Object::Object { 0xffffea093d50 } -0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xffffea093d50 } +0xffffc1b0e9e0->Object::Object { } +0xffffc1b0eae0->Object::Object { 0xffffc1b0e9e0 } +0xffffc1b0e9e0->Object::~Object { 0xffffc1b0e9e0, 0xffffc1b0eae0 } +Next token is token 'a' (0xffffc1b0eae0 'a') +0xffffc1b0ea20->Object::Object { 0xffffc1b0eae0 } +0xffffc1b0eae0->Object::~Object { 0xffffc1b0ea20, 0xffffc1b0eae0 } +Shifting token 'a' (0xffffc1b0ea20 'a') +0xaaaaf37ff2e0->Object::Object { 0xffffc1b0ea20 } +0xffffc1b0ea20->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0ea20 } Entering state 2 Stack now 0 2 -0xffffea093e30->Object::Object { 0xaaab0a89d2e0 } +0xffffc1b0eb00->Object::Object { 0xaaaaf37ff2e0 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab0a89d2e0 'a') --> $$ = nterm item (0xffffea093e30 'a') -0xaaab0a89d2e0->Object::~Object { 0xaaab0a89d2e0, 0xffffea093e30 } -0xaaab0a89d2e0->Object::Object { 0xffffea093e30 } -0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xffffea093e30 } + $1 = token 'a' (0xaaaaf37ff2e0 'a') +-> $$ = nterm item (0xffffc1b0eb00 'a') +0xaaaaf37ff2e0->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0eb00 } +0xaaaaf37ff2e0->Object::Object { 0xffffc1b0eb00 } +0xffffc1b0eb00->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0eb00 } Entering state 11 Stack now 0 11 Reading a token -0xffffea093d10->Object::Object { 0xaaab0a89d2e0 } -0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xffffea093d10 } -0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xffffea093d10, 0xffffea093e10 } -Next token is token 'a' (0xffffea093e10 'a') -0xffffea093d50->Object::Object { 0xaaab0a89d2e0, 0xffffea093e10 } -0xffffea093e10->Object::~Object { 0xaaab0a89d2e0, 0xffffea093d50, 0xffffea093e10 } -Shifting token 'a' (0xffffea093d50 'a') -0xaaab0a89d300->Object::Object { 0xaaab0a89d2e0, 0xffffea093d50 } -0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d50 } +0xffffc1b0e9e0->Object::Object { 0xaaaaf37ff2e0 } +0xffffc1b0eae0->Object::Object { 0xaaaaf37ff2e0, 0xffffc1b0e9e0 } +0xffffc1b0e9e0->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0e9e0, 0xffffc1b0eae0 } +Next token is token 'a' (0xffffc1b0eae0 'a') +0xffffc1b0ea20->Object::Object { 0xaaaaf37ff2e0, 0xffffc1b0eae0 } +0xffffc1b0eae0->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0ea20, 0xffffc1b0eae0 } +Shifting token 'a' (0xffffc1b0ea20 'a') +0xaaaaf37ff300->Object::Object { 0xaaaaf37ff2e0, 0xffffc1b0ea20 } +0xffffc1b0ea20->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0ea20 } Entering state 2 Stack now 0 11 2 -0xffffea093e30->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300 } +0xffffc1b0eb00->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab0a89d300 'a') --> $$ = nterm item (0xffffea093e30 'a') -0xaaab0a89d300->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e30 } -0xaaab0a89d300->Object::Object { 0xaaab0a89d2e0, 0xffffea093e30 } -0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e30 } + $1 = token 'a' (0xaaaaf37ff300 'a') +-> $$ = nterm item (0xffffc1b0eb00 'a') +0xaaaaf37ff300->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0eb00 } +0xaaaaf37ff300->Object::Object { 0xaaaaf37ff2e0, 0xffffc1b0eb00 } +0xffffc1b0eb00->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0eb00 } Entering state 11 Stack now 0 11 11 Reading a token -0xffffea093d10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300 } -0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d10 } -0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d10, 0xffffea093e10 } -Next token is token 'a' (0xffffea093e10 'a') -0xffffea093d50->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e10 } -0xffffea093e10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d50, 0xffffea093e10 } -Shifting token 'a' (0xffffea093d50 'a') -0xaaab0a89d320->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093d50 } -0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d50 } +0xffffc1b0e9e0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300 } +0xffffc1b0eae0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0e9e0 } +0xffffc1b0e9e0->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0e9e0, 0xffffc1b0eae0 } +Next token is token 'a' (0xffffc1b0eae0 'a') +0xffffc1b0ea20->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0eae0 } +0xffffc1b0eae0->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0ea20, 0xffffc1b0eae0 } +Shifting token 'a' (0xffffc1b0ea20 'a') +0xaaaaf37ff320->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0ea20 } +0xffffc1b0ea20->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0ea20 } Entering state 2 Stack now 0 11 11 2 -0xffffea093e30->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320 } +0xffffc1b0eb00->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab0a89d320 'a') --> $$ = nterm item (0xffffea093e30 'a') -0xaaab0a89d320->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e30 } -0xaaab0a89d320->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e30 } -0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e30 } + $1 = token 'a' (0xaaaaf37ff320 'a') +-> $$ = nterm item (0xffffc1b0eb00 'a') +0xaaaaf37ff320->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0eb00 } +0xaaaaf37ff320->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0eb00 } +0xffffc1b0eb00->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0eb00 } Entering state 11 Stack now 0 11 11 11 Reading a token -0xffffea093d10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320 } -0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d10 } -0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d10, 0xffffea093e10 } -Next token is token 'a' (0xffffea093e10 'a') -0xffffea093d50->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e10 } -0xffffea093e10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d50, 0xffffea093e10 } -Shifting token 'a' (0xffffea093d50 'a') -0xaaab0a89d340->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093d50 } -0xffffea093d50->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093d50 } +0xffffc1b0e9e0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320 } +0xffffc1b0eae0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0e9e0 } +0xffffc1b0e9e0->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0e9e0, 0xffffc1b0eae0 } +Next token is token 'a' (0xffffc1b0eae0 'a') +0xffffc1b0ea20->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0eae0 } +0xffffc1b0eae0->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0ea20, 0xffffc1b0eae0 } +Shifting token 'a' (0xffffc1b0ea20 'a') +0xaaaaf37ff340->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0ea20 } +0xffffc1b0ea20->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0ea20 } Entering state 2 Stack now 0 11 11 11 2 -0xffffea093e30->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340 } +0xffffc1b0eb00->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab0a89d340 'a') --> $$ = nterm item (0xffffea093e30 'a') -0xaaab0a89d340->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093e30 } -0xaaab0a89d340->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e30 } -0xffffea093e30->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093e30 } + $1 = token 'a' (0xaaaaf37ff340 'a') +-> $$ = nterm item (0xffffc1b0eb00 'a') +0xaaaaf37ff340->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0eb00 } +0xaaaaf37ff340->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0eb00 } +0xffffc1b0eb00->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0eb00 } Entering state 11 Stack now 0 11 11 11 11 Reading a token -0xffffea093d10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340 } -0xffffea093e10->Object::Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093d10 } -0xffffea093d10->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093d10, 0xffffea093e10 } -Next token is token 'p' (0xffffea093e10 'p'Exception caught: cleaning lookahead and stack -0xaaab0a89d340->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xaaab0a89d340, 0xffffea093e10 } -0xaaab0a89d320->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xaaab0a89d320, 0xffffea093e10 } -0xaaab0a89d300->Object::~Object { 0xaaab0a89d2e0, 0xaaab0a89d300, 0xffffea093e10 } -0xaaab0a89d2e0->Object::~Object { 0xaaab0a89d2e0, 0xffffea093e10 } -0xffffea093e10->Object::~Object { 0xffffea093e10 } +0xffffc1b0e9e0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340 } +0xffffc1b0eae0->Object::Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0e9e0 } +0xffffc1b0e9e0->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0e9e0, 0xffffc1b0eae0 } +Next token is token 'p' (0xffffc1b0eae0 'p'Exception caught: cleaning lookahead and stack +0xaaaaf37ff340->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xaaaaf37ff340, 0xffffc1b0eae0 } +0xaaaaf37ff320->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xaaaaf37ff320, 0xffffc1b0eae0 } +0xaaaaf37ff300->Object::~Object { 0xaaaaf37ff2e0, 0xaaaaf37ff300, 0xffffc1b0eae0 } +0xaaaaf37ff2e0->Object::~Object { 0xaaaaf37ff2e0, 0xffffc1b0eae0 } +0xffffc1b0eae0->Object::~Object { 0xffffc1b0eae0 } exception caught: printer end { } +syntax error +Discarding 'a'. +Reducing 'a'. +./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: grep '^exception caught: printer$' stderr -stderr: stdout: exception caught: printer -stdout: ./c++.at:1362: $PREPARSER ./input aaaae -./c++.at:941: $PREPARSER ./input +./c++.at:1065: $PREPARSER ./input < in stderr: +======== Testing with C++ standard flags: '' +./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y stderr: -syntax error -Discarding 'a'. -Reducing 'a'. -./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +error: invalid expression +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaE stderr: +./c++.at:1065: $PREPARSER ./input < in exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -stdout: -./c++.at:574: $here/modern -stdout: -Modern C++: 202302 -./c++.at:574: $PREPARSER ./list -stderr: -Destroy: "" -Destroy: "" -Destroy: 1 -Destroy: "" -Destroy: () -Destroy: "" -Destroy: "" -Destroy: () -Destroy: "" -Destroy: 3 -Destroy: () -Destroy: "" -Destroy: "" -Destroy: () -Destroy: () -Destroy: 5 -Destroy: () -Destroy: "" -Destroy: "" -Destroy: () -Destroy: (0, 1, 2, 4, 6) stderr: -./c++.at:1362: $PREPARSER ./input aaaaT +./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: -./c++.at:850: $PREPARSER ./input +./c++.at:1361: $PREPARSER ./input aaaas +error: invalid character +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1362: $PREPARSER ./input aaaaT +exception caught: reduction +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -674. c++.at:574: ok +./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS +./c++.at:1361: $PREPARSER ./input aaaal ./c++.at:1362: $PREPARSER ./input aaaaR stderr: +stderr: +exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' - ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -690. c++.at:1422: testing Shared locations ... -./c++.at:1456: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o x1.cc x1.yy -stderr: -./c++.at:1456: $CXX $CPPFLAGS $CXXFLAGS -Iinclude -c -o x1.o x1.cc -stdout: -./c++.at:1363: $PREPARSER ./input aaaas -stderr: -exception caught: reduction -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1363: $PREPARSER ./input aaaal -stderr: -exception caught: yylex -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1363: $PREPARSER ./input i +./c++.at:1361: $PREPARSER ./input i stderr: exception caught: initial-action -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1363: $PREPARSER ./input aaaap +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input aaaap stderr: -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1363: $PREPARSER ./input --debug aaaap +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xfffffe9d2010->Object::Object { } -0xfffffe9d2110->Object::Object { 0xfffffe9d2010 } -0xfffffe9d2010->Object::~Object { 0xfffffe9d2010, 0xfffffe9d2110 } -Next token is token 'a' (0xfffffe9d2110 'a') -0xfffffe9d2050->Object::Object { 0xfffffe9d2110 } -0xfffffe9d2110->Object::~Object { 0xfffffe9d2050, 0xfffffe9d2110 } -Shifting token 'a' (0xfffffe9d2050 'a') -0xaaab0764b2e0->Object::Object { 0xfffffe9d2050 } -0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2050 } +0xaaaac777ef40->Object::Object { } +Next token is token 'a' (0xaaaac777ef40 'a') +Shifting token 'a' (0xaaaac777ef40 'a') Entering state 1 Stack now 0 1 -0xfffffe9d2130->Object::Object { 0xaaab0764b2e0 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab0764b2e0 'a') --> $$ = nterm item (0xfffffe9d2130 'a') -0xaaab0764b2e0->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2130 } -0xaaab0764b2e0->Object::Object { 0xfffffe9d2130 } -0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2130 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac777ef40 'a') +-> $$ = nterm item (0xaaaac777ef40 'a') Entering state 10 Stack now 0 10 Reading a token -0xfffffe9d2010->Object::Object { 0xaaab0764b2e0 } -0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2010 } -0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2010, 0xfffffe9d2110 } -Next token is token 'a' (0xfffffe9d2110 'a') -0xfffffe9d2050->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2110 } -0xfffffe9d2110->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2050, 0xfffffe9d2110 } -Shifting token 'a' (0xfffffe9d2050 'a') -0xaaab0764b300->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2050 } -0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2050 } +0xaaaac777ef90->Object::Object { 0xaaaac777ef40 } +Next token is token 'a' (0xaaaac777ef90 'a') +Shifting token 'a' (0xaaaac777ef90 'a') Entering state 1 Stack now 0 10 1 -0xfffffe9d2130->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab0764b300 'a') --> $$ = nterm item (0xfffffe9d2130 'a') -0xaaab0764b300->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2130 } -0xaaab0764b300->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2130 } -0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2130 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac777ef90 'a') +-> $$ = nterm item (0xaaaac777ef90 'a') Entering state 10 Stack now 0 10 10 Reading a token -0xfffffe9d2010->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300 } -0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2010 } -0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2010, 0xfffffe9d2110 } -Next token is token 'a' (0xfffffe9d2110 'a') -0xfffffe9d2050->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2110 } -0xfffffe9d2110->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2050, 0xfffffe9d2110 } -Shifting token 'a' (0xfffffe9d2050 'a') -0xaaab0764b320->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2050 } -0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2050 } +0xaaaac777efe0->Object::Object { 0xaaaac777ef40, 0xaaaac777ef90 } +Next token is token 'a' (0xaaaac777efe0 'a') +Shifting token 'a' (0xaaaac777efe0 'a') Entering state 1 Stack now 0 10 10 1 -0xfffffe9d2130->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab0764b320 'a') --> $$ = nterm item (0xfffffe9d2130 'a') -0xaaab0764b320->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2130 } -0xaaab0764b320->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2130 } -0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2130 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac777efe0 'a') +-> $$ = nterm item (0xaaaac777efe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token -0xfffffe9d2010->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320 } -0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2010 } -0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2010, 0xfffffe9d2110 } -Next token is token 'a' (0xfffffe9d2110 'a') -0xfffffe9d2050->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2110 } -0xfffffe9d2110->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2050, 0xfffffe9d2110 } -Shifting token 'a' (0xfffffe9d2050 'a') -0xaaab0764b340->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2050 } -0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2050 } +0xaaaac777f030->Object::Object { 0xaaaac777ef40, 0xaaaac777ef90, 0xaaaac777efe0 } +Next token is token 'a' (0xaaaac777f030 'a') +Shifting token 'a' (0xaaaac777f030 'a') Entering state 1 Stack now 0 10 10 10 1 -0xfffffe9d2130->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab0764b340 'a') --> $$ = nterm item (0xfffffe9d2130 'a') -0xaaab0764b340->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2130 } -0xaaab0764b340->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2130 } -0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2130 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac777f030 'a') +-> $$ = nterm item (0xaaaac777f030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token -0xfffffe9d2010->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340 } -0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2010 } -0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2010, 0xfffffe9d2110 } -Next token is token 'p' (0xfffffe9d2110 'p'Exception caught: cleaning lookahead and stack -0xaaab0764b340->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2110 } -0xaaab0764b320->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2110 } -0xaaab0764b300->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2110 } -0xaaab0764b2e0->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2110 } -0xfffffe9d2110->Object::~Object { 0xfffffe9d2110 } +0xaaaac777f080->Object::Object { 0xaaaac777ef40, 0xaaaac777ef90, 0xaaaac777efe0, 0xaaaac777f030 } +Next token is token 'p' (0xaaaac777f080 'p'Exception caught: cleaning lookahead and stack +0xaaaac777f080->Object::~Object { 0xaaaac777ef40, 0xaaaac777ef90, 0xaaaac777efe0, 0xaaaac777f030, 0xaaaac777f080 } +0xaaaac777f030->Object::~Object { 0xaaaac777ef40, 0xaaaac777ef90, 0xaaaac777efe0, 0xaaaac777f030 } +0xaaaac777efe0->Object::~Object { 0xaaaac777ef40, 0xaaaac777ef90, 0xaaaac777efe0 } +0xaaaac777ef90->Object::~Object { 0xaaaac777ef40, 0xaaaac777ef90 } +0xaaaac777ef40->Object::~Object { 0xaaaac777ef40 } exception caught: printer end { } -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stdout: stderr: +./c++.at:856: $PREPARSER ./input Starting parse Entering state 0 Stack now 0 Reading a token -0xfffffe9d2010->Object::Object { } -0xfffffe9d2110->Object::Object { 0xfffffe9d2010 } -0xfffffe9d2010->Object::~Object { 0xfffffe9d2010, 0xfffffe9d2110 } -Next token is token 'a' (0xfffffe9d2110 'a') -0xfffffe9d2050->Object::Object { 0xfffffe9d2110 } -0xfffffe9d2110->Object::~Object { 0xfffffe9d2050, 0xfffffe9d2110 } -Shifting token 'a' (0xfffffe9d2050 'a') -0xaaab0764b2e0->Object::Object { 0xfffffe9d2050 } -0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2050 } +0xaaaac777ef40->Object::Object { } +Next token is token 'a' (0xaaaac777ef40 'a') +Shifting token 'a' (0xaaaac777ef40 'a') Entering state 1 Stack now 0 1 -0xfffffe9d2130->Object::Object { 0xaaab0764b2e0 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab0764b2e0 'a') --> $$ = nterm item (0xfffffe9d2130 'a') -0xaaab0764b2e0->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2130 } -0xaaab0764b2e0->Object::Object { 0xfffffe9d2130 } -0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2130 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac777ef40 'a') +-> $$ = nterm item (0xaaaac777ef40 'a') Entering state 10 Stack now 0 10 Reading a token -0xfffffe9d2010->Object::Object { 0xaaab0764b2e0 } -0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2010 } -0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2010, 0xfffffe9d2110 } -Next token is token 'a' (0xfffffe9d2110 'a') -0xfffffe9d2050->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2110 } -0xfffffe9d2110->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2050, 0xfffffe9d2110 } -Shifting token 'a' (0xfffffe9d2050 'a') -0xaaab0764b300->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2050 } -0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2050 } +0xaaaac777ef90->Object::Object { 0xaaaac777ef40 } +Next token is token 'a' (0xaaaac777ef90 'a') +Shifting token 'a' (0xaaaac777ef90 'a') Entering state 1 Stack now 0 10 1 -0xfffffe9d2130->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab0764b300 'a') --> $$ = nterm item (0xfffffe9d2130 'a') -0xaaab0764b300->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2130 } -0xaaab0764b300->Object::Object { 0xaaab0764b2e0, 0xfffffe9d2130 } -0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2130 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac777ef90 'a') +-> $$ = nterm item (0xaaaac777ef90 'a') Entering state 10 Stack now 0 10 10 Reading a token -0xfffffe9d2010->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300 } -0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2010 } -0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2010, 0xfffffe9d2110 } -Next token is token 'a' (0xfffffe9d2110 'a') -0xfffffe9d2050->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2110 } -0xfffffe9d2110->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2050, 0xfffffe9d2110 } -Shifting token 'a' (0xfffffe9d2050 'a') -0xaaab0764b320->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2050 } -0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2050 } +0xaaaac777efe0->Object::Object { 0xaaaac777ef40, 0xaaaac777ef90 } +Next token is token 'a' (0xaaaac777efe0 'a') +Shifting token 'a' (0xaaaac777efe0 'a') Entering state 1 Stack now 0 10 10 1 -0xfffffe9d2130->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab0764b320 'a') --> $$ = nterm item (0xfffffe9d2130 'a') -0xaaab0764b320->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2130 } -0xaaab0764b320->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2130 } -0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2130 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac777efe0 'a') +-> $$ = nterm item (0xaaaac777efe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token -0xfffffe9d2010->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320 } -0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2010 } -0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2010, 0xfffffe9d2110 } -Next token is token 'a' (0xfffffe9d2110 'a') -0xfffffe9d2050->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2110 } -0xfffffe9d2110->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2050, 0xfffffe9d2110 } -Shifting token 'a' (0xfffffe9d2050 'a') -0xaaab0764b340->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2050 } -0xfffffe9d2050->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2050 } +0xaaaac777f030->Object::Object { 0xaaaac777ef40, 0xaaaac777ef90, 0xaaaac777efe0 } +Next token is token 'a' (0xaaaac777f030 'a') +Shifting token 'a' (0xaaaac777f030 'a') Entering state 1 Stack now 0 10 10 10 1 -0xfffffe9d2130->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab0764b340 'a') --> $$ = nterm item (0xfffffe9d2130 'a') -0xaaab0764b340->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2130 } -0xaaab0764b340->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2130 } -0xfffffe9d2130->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2130 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac777f030 'a') +-> $$ = nterm item (0xaaaac777f030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token -0xfffffe9d2010->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340 } -0xfffffe9d2110->Object::Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2010 } -0xfffffe9d2010->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2010, 0xfffffe9d2110 } -Next token is token 'p' (0xfffffe9d2110 'p'Exception caught: cleaning lookahead and stack -0xaaab0764b340->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xaaab0764b340, 0xfffffe9d2110 } -0xaaab0764b320->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xaaab0764b320, 0xfffffe9d2110 } -0xaaab0764b300->Object::~Object { 0xaaab0764b2e0, 0xaaab0764b300, 0xfffffe9d2110 } -0xaaab0764b2e0->Object::~Object { 0xaaab0764b2e0, 0xfffffe9d2110 } -0xfffffe9d2110->Object::~Object { 0xfffffe9d2110 } +0xaaaac777f080->Object::Object { 0xaaaac777ef40, 0xaaaac777ef90, 0xaaaac777efe0, 0xaaaac777f030 } +Next token is token 'p' (0xaaaac777f080 'p'Exception caught: cleaning lookahead and stack +0xaaaac777f080->Object::~Object { 0xaaaac777ef40, 0xaaaac777ef90, 0xaaaac777efe0, 0xaaaac777f030, 0xaaaac777f080 } +0xaaaac777f030->Object::~Object { 0xaaaac777ef40, 0xaaaac777ef90, 0xaaaac777efe0, 0xaaaac777f030 } +0xaaaac777efe0->Object::~Object { 0xaaaac777ef40, 0xaaaac777ef90, 0xaaaac777efe0 } +0xaaaac777ef90->Object::~Object { 0xaaaac777ef40, 0xaaaac777ef90 } +0xaaaac777ef40->Object::~Object { 0xaaaac777ef40 } exception caught: printer end { } -./c++.at:1363: grep '^exception caught: printer$' stderr +./c++.at:1361: grep '^exception caught: printer$' stderr +stderr: +./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: +stderr: exception caught: printer -./c++.at:1363: $PREPARSER ./input aaaae +stdout: +./c++.at:1361: $PREPARSER ./input aaaae stderr: +======== Testing with C++ standard flags: '' +./c++.at:1066: $PREPARSER ./input < in exception caught: syntax error -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: -./c++.at:1363: $PREPARSER ./input aaaaE stderr: +error: invalid expression +caught error +error: invalid character +caught error stdout: +./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input aaaaE +======== Testing with C++ standard flags: '' stderr: +./c++.at:1066: $PREPARSER ./input < in +./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS exception caught: syntax error, unexpected end of file, expecting 'a' +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: stdout: +error: invalid expression ./c++.at:1064: $PREPARSER ./input < in -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input aaaas +./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input aaaaT stderr: +stderr: +./c++.at:1066: $PREPARSER ./input < in error: invalid expression caught error error: invalid character caught error +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -exception caught: reduction -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1064: $PREPARSER ./input < in +./c++.at:1361: $PREPARSER ./input aaaaR +error: invalid character +./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./c++.at:1064: $PREPARSER ./input < in +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +======== Testing with C++ standard flags: '' +======== Testing with C++ standard flags: '' +./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS error: invalid expression ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./c++.at:1363: $PREPARSER ./input aaaaT -======== Testing with C++ standard flags: '' +./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./c++.at:1064: $PREPARSER ./input < in stderr: -./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: error: invalid character ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input aaaal ======== Testing with C++ standard flags: '' -./c++.at:1363: $PREPARSER ./input aaaaR ./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: stderr: -exception caught: yylex -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:1360: $PREPARSER ./input i -./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -exception caught: initial-action -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input aaaap -stderr: -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input --debug aaaap -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -0xaaab0a588f40->Object::Object { } -Next token is token 'a' (0xaaab0a588f40 'a') -Shifting token 'a' (0xaaab0a588f40 'a') -Entering state 2 -Stack now 0 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaab0a588f40 'a') --> $$ = nterm item (0xaaab0a588f40 'a') -Entering state 11 -Stack now 0 11 -Reading a token -0xaaab0a588f90->Object::Object { 0xaaab0a588f40 } -Next token is token 'a' (0xaaab0a588f90 'a') -Shifting token 'a' (0xaaab0a588f90 'a') -Entering state 2 -Stack now 0 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaab0a588f90 'a') --> $$ = nterm item (0xaaab0a588f90 'a') -Entering state 11 -Stack now 0 11 11 -Reading a token -0xaaab0a588fe0->Object::Object { 0xaaab0a588f40, 0xaaab0a588f90 } -Next token is token 'a' (0xaaab0a588fe0 'a') -Shifting token 'a' (0xaaab0a588fe0 'a') -Entering state 2 -Stack now 0 11 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaab0a588fe0 'a') --> $$ = nterm item (0xaaab0a588fe0 'a') -Entering state 11 -Stack now 0 11 11 11 -Reading a token -0xaaab0a589030->Object::Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0 } -Next token is token 'a' (0xaaab0a589030 'a') -Shifting token 'a' (0xaaab0a589030 'a') -Entering state 2 -Stack now 0 11 11 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaab0a589030 'a') --> $$ = nterm item (0xaaab0a589030 'a') -Entering state 11 -Stack now 0 11 11 11 11 -Reading a token -0xaaab0a589080->Object::Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0, 0xaaab0a589030 } -Next token is token 'p' (0xaaab0a589080 'p'Exception caught: cleaning lookahead and stack -0xaaab0a589080->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0, 0xaaab0a589030, 0xaaab0a589080 } -0xaaab0a589030->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0, 0xaaab0a589030 } -0xaaab0a588fe0->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0 } -0xaaab0a588f90->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90 } -0xaaab0a588f40->Object::~Object { 0xaaab0a588f40 } -exception caught: printer -end { } -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -stdout: -./c++.at:856: $PREPARSER ./input -stderr: -./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -Starting parse -Entering state 0 -Stack now 0 -Reading a token -0xaaab0a588f40->Object::Object { } -Next token is token 'a' (0xaaab0a588f40 'a') -Shifting token 'a' (0xaaab0a588f40 'a') -Entering state 2 -Stack now 0 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaab0a588f40 'a') --> $$ = nterm item (0xaaab0a588f40 'a') -Entering state 11 -Stack now 0 11 -Reading a token -0xaaab0a588f90->Object::Object { 0xaaab0a588f40 } -Next token is token 'a' (0xaaab0a588f90 'a') -Shifting token 'a' (0xaaab0a588f90 'a') -Entering state 2 -Stack now 0 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaab0a588f90 'a') --> $$ = nterm item (0xaaab0a588f90 'a') -Entering state 11 -Stack now 0 11 11 -Reading a token -0xaaab0a588fe0->Object::Object { 0xaaab0a588f40, 0xaaab0a588f90 } -Next token is token 'a' (0xaaab0a588fe0 'a') -Shifting token 'a' (0xaaab0a588fe0 'a') -Entering state 2 -Stack now 0 11 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaab0a588fe0 'a') --> $$ = nterm item (0xaaab0a588fe0 'a') -Entering state 11 -Stack now 0 11 11 11 -Reading a token -0xaaab0a589030->Object::Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0 } -Next token is token 'a' (0xaaab0a589030 'a') -Shifting token 'a' (0xaaab0a589030 'a') -Entering state 2 -Stack now 0 11 11 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaab0a589030 'a') --> $$ = nterm item (0xaaab0a589030 'a') -Entering state 11 -Stack now 0 11 11 11 11 -Reading a token -0xaaab0a589080->Object::Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0, 0xaaab0a589030 } -Next token is token 'p' (0xaaab0a589080 'p'Exception caught: cleaning lookahead and stack -0xaaab0a589080->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0, 0xaaab0a589030, 0xaaab0a589080 } -0xaaab0a589030->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0, 0xaaab0a589030 } -0xaaab0a588fe0->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90, 0xaaab0a588fe0 } -0xaaab0a588f90->Object::~Object { 0xaaab0a588f40, 0xaaab0a588f90 } -0xaaab0a588f40->Object::~Object { 0xaaab0a588f40 } -exception caught: printer -end { } -./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./c++.at:1360: grep '^exception caught: printer$' stderr -stdout: -exception caught: printer -./c++.at:1360: $PREPARSER ./input aaaae -stderr: -exception caught: syntax error -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input aaaaE -stderr: -exception caught: syntax error, unexpected end of file, expecting 'a' -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input aaaaT -stderr: -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input aaaaR -stderr: -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: stdout: -./c++.at:941: $PREPARSER ./input -stderr: -syntax error -Discarding 'a'. -Reducing 'a'. -./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: stdout: -./c++.at:1361: $PREPARSER ./input aaaas +./c++.at:1066: ./check +./c++.at:1363: $PREPARSER ./input aaaas +-std=c++98 not supported ======== Testing with C++ standard flags: '' -./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -stderr: stderr: exception caught: reduction -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./c++.at:1361: $PREPARSER ./input aaaal +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./c++.at:1363: $PREPARSER ./input aaaal stderr: exception caught: yylex -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1463: sed -ne '/INCLUDED/p;/\\file/{p;n;p;}' include/ast/loc.hh -./c++.at:1361: $PREPARSER ./input i -./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1363: $PREPARSER ./input i stderr: -./c++.at:1471: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o x2.cc x2.yy exception caught: initial-action -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: $PREPARSER ./input aaaap +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./c++.at:1471: $CXX $CPPFLAGS $CXXFLAGS -Iinclude -c -o x2.o x2.cc -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: $PREPARSER ./input --debug aaaap +./c++.at:1363: $PREPARSER ./input aaaap +stdout: +./c++.at:1066: ./check stderr: +-std=c++03 not supported +======== Testing with C++ standard flags: '' +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1363: $PREPARSER ./input --debug aaaap +./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xaaaaec95df40->Object::Object { } -Next token is token 'a' (0xaaaaec95df40 'a') -Shifting token 'a' (0xaaaaec95df40 'a') +0xffffe49f1430->Object::Object { } +0xffffe49f1530->Object::Object { 0xffffe49f1430 } +0xffffe49f1430->Object::~Object { 0xffffe49f1430, 0xffffe49f1530 } +Next token is token 'a' (0xffffe49f1530 'a') +0xffffe49f1470->Object::Object { 0xffffe49f1530 } +0xffffe49f1530->Object::~Object { 0xffffe49f1470, 0xffffe49f1530 } +Shifting token 'a' (0xffffe49f1470 'a') +0xaaaac05492e0->Object::Object { 0xffffe49f1470 } +0xffffe49f1470->Object::~Object { 0xaaaac05492e0, 0xffffe49f1470 } Entering state 1 Stack now 0 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaec95df40 'a') --> $$ = nterm item (0xaaaaec95df40 'a') +0xffffe49f1550->Object::Object { 0xaaaac05492e0 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaac05492e0 'a') +-> $$ = nterm item (0xffffe49f1550 'a') +0xaaaac05492e0->Object::~Object { 0xaaaac05492e0, 0xffffe49f1550 } +0xaaaac05492e0->Object::Object { 0xffffe49f1550 } +0xffffe49f1550->Object::~Object { 0xaaaac05492e0, 0xffffe49f1550 } Entering state 10 Stack now 0 10 Reading a token -0xaaaaec95df90->Object::Object { 0xaaaaec95df40 } -Next token is token 'a' (0xaaaaec95df90 'a') -Shifting token 'a' (0xaaaaec95df90 'a') +0xffffe49f1430->Object::Object { 0xaaaac05492e0 } +0xffffe49f1530->Object::Object { 0xaaaac05492e0, 0xffffe49f1430 } +0xffffe49f1430->Object::~Object { 0xaaaac05492e0, 0xffffe49f1430, 0xffffe49f1530 } +Next token is token 'a' (0xffffe49f1530 'a') +0xffffe49f1470->Object::Object { 0xaaaac05492e0, 0xffffe49f1530 } +0xffffe49f1530->Object::~Object { 0xaaaac05492e0, 0xffffe49f1470, 0xffffe49f1530 } +Shifting token 'a' (0xffffe49f1470 'a') +0xaaaac0549300->Object::Object { 0xaaaac05492e0, 0xffffe49f1470 } +0xffffe49f1470->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1470 } Entering state 1 Stack now 0 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaec95df90 'a') --> $$ = nterm item (0xaaaaec95df90 'a') +0xffffe49f1550->Object::Object { 0xaaaac05492e0, 0xaaaac0549300 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaac0549300 'a') +-> $$ = nterm item (0xffffe49f1550 'a') +0xaaaac0549300->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1550 } +0xaaaac0549300->Object::Object { 0xaaaac05492e0, 0xffffe49f1550 } +0xffffe49f1550->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1550 } Entering state 10 Stack now 0 10 10 Reading a token -0xaaaaec95dfe0->Object::Object { 0xaaaaec95df40, 0xaaaaec95df90 } -Next token is token 'a' (0xaaaaec95dfe0 'a') -Shifting token 'a' (0xaaaaec95dfe0 'a') +0xffffe49f1430->Object::Object { 0xaaaac05492e0, 0xaaaac0549300 } +0xffffe49f1530->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1430 } +0xffffe49f1430->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1430, 0xffffe49f1530 } +Next token is token 'a' (0xffffe49f1530 'a') +0xffffe49f1470->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1530 } +0xffffe49f1530->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1470, 0xffffe49f1530 } +Shifting token 'a' (0xffffe49f1470 'a') +0xaaaac0549320->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1470 } +0xffffe49f1470->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1470 } Entering state 1 Stack now 0 10 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaec95dfe0 'a') --> $$ = nterm item (0xaaaaec95dfe0 'a') +0xffffe49f1550->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaac0549320 'a') +-> $$ = nterm item (0xffffe49f1550 'a') +0xaaaac0549320->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1550 } +0xaaaac0549320->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1550 } +0xffffe49f1550->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1550 } Entering state 10 Stack now 0 10 10 10 Reading a token -0xaaaaec95e030->Object::Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0 } -Next token is token 'a' (0xaaaaec95e030 'a') -Shifting token 'a' (0xaaaaec95e030 'a') +0xffffe49f1430->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320 } +0xffffe49f1530->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1430 } +0xffffe49f1430->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1430, 0xffffe49f1530 } +Next token is token 'a' (0xffffe49f1530 'a') +0xffffe49f1470->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1530 } +0xffffe49f1530->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1470, 0xffffe49f1530 } +Shifting token 'a' (0xffffe49f1470 'a') +0xaaaac0549340->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1470 } +0xffffe49f1470->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1470 } Entering state 1 Stack now 0 10 10 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaec95e030 'a') --> $$ = nterm item (0xaaaaec95e030 'a') +0xffffe49f1550->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaac0549340 'a') +-> $$ = nterm item (0xffffe49f1550 'a') +0xaaaac0549340->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1550 } +0xaaaac0549340->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1550 } +0xffffe49f1550->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1550 } Entering state 10 Stack now 0 10 10 10 10 Reading a token -0xaaaaec95e080->Object::Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0, 0xaaaaec95e030 } -Next token is token 'p' (0xaaaaec95e080 'p'Exception caught: cleaning lookahead and stack -0xaaaaec95e080->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0, 0xaaaaec95e030, 0xaaaaec95e080 } -0xaaaaec95e030->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0, 0xaaaaec95e030 } -0xaaaaec95dfe0->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0 } -0xaaaaec95df90->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90 } -0xaaaaec95df40->Object::~Object { 0xaaaaec95df40 } +0xffffe49f1430->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340 } +0xffffe49f1530->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1430 } +0xffffe49f1430->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1430, 0xffffe49f1530 } +Next token is token 'p' (0xffffe49f1530 'p'Exception caught: cleaning lookahead and stack +0xaaaac0549340->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1530 } +0xaaaac0549320->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1530 } +0xaaaac0549300->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1530 } +0xaaaac05492e0->Object::~Object { 0xaaaac05492e0, 0xffffe49f1530 } +0xffffe49f1530->Object::~Object { 0xffffe49f1530 } exception caught: printer end { } -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./c++.at:1065: $PREPARSER ./input < in -stderr: +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xaaaaec95df40->Object::Object { } -Next token is token 'a' (0xaaaaec95df40 'a') -Shifting token 'a' (0xaaaaec95df40 'a') +0xffffe49f1430->Object::Object { } +0xffffe49f1530->Object::Object { 0xffffe49f1430 } +0xffffe49f1430->Object::~Object { 0xffffe49f1430, 0xffffe49f1530 } +Next token is token 'a' (0xffffe49f1530 'a') +0xffffe49f1470->Object::Object { 0xffffe49f1530 } +0xffffe49f1530->Object::~Object { 0xffffe49f1470, 0xffffe49f1530 } +Shifting token 'a' (0xffffe49f1470 'a') +0xaaaac05492e0->Object::Object { 0xffffe49f1470 } +0xffffe49f1470->Object::~Object { 0xaaaac05492e0, 0xffffe49f1470 } Entering state 1 Stack now 0 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaec95df40 'a') --> $$ = nterm item (0xaaaaec95df40 'a') +0xffffe49f1550->Object::Object { 0xaaaac05492e0 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaac05492e0 'a') +-> $$ = nterm item (0xffffe49f1550 'a') +0xaaaac05492e0->Object::~Object { 0xaaaac05492e0, 0xffffe49f1550 } +0xaaaac05492e0->Object::Object { 0xffffe49f1550 } +0xffffe49f1550->Object::~Object { 0xaaaac05492e0, 0xffffe49f1550 } Entering state 10 Stack now 0 10 Reading a token -0xaaaaec95df90->Object::Object { 0xaaaaec95df40 } -Next token is token 'a' (0xaaaaec95df90 'a') -Shifting token 'a' (0xaaaaec95df90 'a') +0xffffe49f1430->Object::Object { 0xaaaac05492e0 } +0xffffe49f1530->Object::Object { 0xaaaac05492e0, 0xffffe49f1430 } +0xffffe49f1430->Object::~Object { 0xaaaac05492e0, 0xffffe49f1430, 0xffffe49f1530 } +Next token is token 'a' (0xffffe49f1530 'a') +0xffffe49f1470->Object::Object { 0xaaaac05492e0, 0xffffe49f1530 } +0xffffe49f1530->Object::~Object { 0xaaaac05492e0, 0xffffe49f1470, 0xffffe49f1530 } +Shifting token 'a' (0xffffe49f1470 'a') +0xaaaac0549300->Object::Object { 0xaaaac05492e0, 0xffffe49f1470 } +0xffffe49f1470->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1470 } Entering state 1 Stack now 0 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaec95df90 'a') --> $$ = nterm item (0xaaaaec95df90 'a') +0xffffe49f1550->Object::Object { 0xaaaac05492e0, 0xaaaac0549300 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaac0549300 'a') +-> $$ = nterm item (0xffffe49f1550 'a') +0xaaaac0549300->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1550 } +0xaaaac0549300->Object::Object { 0xaaaac05492e0, 0xffffe49f1550 } +0xffffe49f1550->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1550 } Entering state 10 Stack now 0 10 10 Reading a token -0xaaaaec95dfe0->Object::Object { 0xaaaaec95df40, 0xaaaaec95df90 } -Next token is token 'a' (0xaaaaec95dfe0 'a') -Shifting token 'a' (0xaaaaec95dfe0 'a') +0xffffe49f1430->Object::Object { 0xaaaac05492e0, 0xaaaac0549300 } +0xffffe49f1530->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1430 } +0xffffe49f1430->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1430, 0xffffe49f1530 } +Next token is token 'a' (0xffffe49f1530 'a') +0xffffe49f1470->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1530 } +0xffffe49f1530->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1470, 0xffffe49f1530 } +Shifting token 'a' (0xffffe49f1470 'a') +0xaaaac0549320->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1470 } +0xffffe49f1470->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1470 } Entering state 1 Stack now 0 10 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaec95dfe0 'a') --> $$ = nterm item (0xaaaaec95dfe0 'a') +0xffffe49f1550->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaac0549320 'a') +-> $$ = nterm item (0xffffe49f1550 'a') +0xaaaac0549320->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1550 } +0xaaaac0549320->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1550 } +0xffffe49f1550->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1550 } Entering state 10 Stack now 0 10 10 10 Reading a token -0xaaaaec95e030->Object::Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0 } -Next token is token 'a' (0xaaaaec95e030 'a') -Shifting token 'a' (0xaaaaec95e030 'a') +0xffffe49f1430->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320 } +0xffffe49f1530->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1430 } +0xffffe49f1430->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1430, 0xffffe49f1530 } +Next token is token 'a' (0xffffe49f1530 'a') +0xffffe49f1470->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1530 } +0xffffe49f1530->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1470, 0xffffe49f1530 } +Shifting token 'a' (0xffffe49f1470 'a') +0xaaaac0549340->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1470 } +0xffffe49f1470->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1470 } Entering state 1 Stack now 0 10 10 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaec95e030 'a') --> $$ = nterm item (0xaaaaec95e030 'a') +0xffffe49f1550->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaac0549340 'a') +-> $$ = nterm item (0xffffe49f1550 'a') +0xaaaac0549340->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1550 } +0xaaaac0549340->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1550 } +0xffffe49f1550->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1550 } Entering state 10 Stack now 0 10 10 10 10 Reading a token -0xaaaaec95e080->Object::Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0, 0xaaaaec95e030 } -Next token is token 'p' (0xaaaaec95e080 'p'Exception caught: cleaning lookahead and stack -0xaaaaec95e080->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0, 0xaaaaec95e030, 0xaaaaec95e080 } -0xaaaaec95e030->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0, 0xaaaaec95e030 } -0xaaaaec95dfe0->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90, 0xaaaaec95dfe0 } -0xaaaaec95df90->Object::~Object { 0xaaaaec95df40, 0xaaaaec95df90 } -0xaaaaec95df40->Object::~Object { 0xaaaaec95df40 } +0xffffe49f1430->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340 } +0xffffe49f1530->Object::Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1430 } +0xffffe49f1430->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1430, 0xffffe49f1530 } +Next token is token 'p' (0xffffe49f1530 'p'Exception caught: cleaning lookahead and stack +0xaaaac0549340->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xaaaac0549340, 0xffffe49f1530 } +0xaaaac0549320->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xaaaac0549320, 0xffffe49f1530 } +0xaaaac0549300->Object::~Object { 0xaaaac05492e0, 0xaaaac0549300, 0xffffe49f1530 } +0xaaaac05492e0->Object::~Object { 0xaaaac05492e0, 0xffffe49f1530 } +0xffffe49f1530->Object::~Object { 0xffffe49f1530 } exception caught: printer end { } -./c++.at:1361: grep '^exception caught: printer$' stderr -error: invalid expression -caught error -error: invalid character -caught error -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1363: grep '^exception caught: printer$' stderr stdout: -exception caught: printer -./c++.at:1361: $PREPARSER ./input aaaae stderr: +exception caught: printer stdout: -======== Testing with C++ standard flags: '' -./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1363: $PREPARSER ./input aaaae +./c++.at:850: $PREPARSER ./input stderr: -./c++.at:1065: $PREPARSER ./input < in exception caught: syntax error -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -error: invalid expression -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: $PREPARSER ./input aaaaE +./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -exception caught: syntax error, unexpected end of file, expecting 'a' -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1065: $PREPARSER ./input < in -./c++.at:1361: $PREPARSER ./input aaaaT +./c++.at:1363: $PREPARSER ./input aaaaE stderr: -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +exception caught: syntax error, unexpected end of file, expecting 'a' +stdout: +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1066: ./check +./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1363: $PREPARSER ./input aaaaT +./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: -error: invalid character -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: $PREPARSER ./input aaaaR +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1363: $PREPARSER ./input aaaaR stderr: +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS -======== Testing with C++ standard flags: '' -./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: -./c++.at:850: $PREPARSER ./input -stderr: -./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:851: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ======== Testing with C++ standard flags: '' -./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: -./c++.at:1064: $PREPARSER ./input < in -stderr: -error: invalid expression -caught error -error: invalid character -caught error -./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1064: $PREPARSER ./input < in -stderr: +./c++.at:574: $here/modern stderr: stdout: -stderr: -./c++.at:1501: $CXX $CPPFLAGS $CXXFLAGS -Iinclude $LDFLAGS -o parser x[12].o main.cc $LIBS stdout: -error: invalid expression -./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1362: $PREPARSER ./input aaaas -stderr: -exception caught: reduction -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1064: $PREPARSER ./input < in -./c++.at:1362: $PREPARSER ./input aaaal +./c++.at:856: $PREPARSER ./input +Modern C++: 202302 +./c++.at:574: $PREPARSER ./list stderr: stderr: +./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Destroy: "" +Destroy: "" +Destroy: 1 +Destroy: "" +Destroy: () +Destroy: "" +Destroy: "" +Destroy: () +Destroy: "" +Destroy: 3 +Destroy: () +Destroy: "" +Destroy: "" +Destroy: () +Destroy: () +Destroy: 5 +Destroy: () +Destroy: "" +Destroy: "" +Destroy: () +Destroy: (0, 1, 2, 4, 6) +./c++.at:574: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +674. c++.at:574: ok + +690. c++.at:1422: testing Shared locations ... +./c++.at:1456: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o x1.cc x1.yy +./c++.at:1456: $CXX $CPPFLAGS $CXXFLAGS -Iinclude -c -o x1.o x1.cc stderr: stdout: -exception caught: yylex -======== Testing with C++ standard flags: '' -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -error: invalid character -./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1362: $PREPARSER ./input i +./c++.at:850: $PREPARSER ./input stderr: -exception caught: initial-action -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS +./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: -./c++.at:1362: $PREPARSER ./input aaaap stdout: ./c++.at:941: $PREPARSER ./input stderr: @@ -253648,1298 +253309,686 @@ Discarding 'a'. Reducing 'a'. ./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +681. c++.at:884: ok + stderr: -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./c++.at:1362: $PREPARSER ./input --debug aaaap -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -0xfffffcd63500->Object::Object { } -0xfffffcd635e0->Object::Object { 0xfffffcd63500 } -0xfffffcd63500->Object::~Object { 0xfffffcd63500, 0xfffffcd635e0 } -Next token is token 'a' (0xfffffcd635e0 'a') -0xfffffcd63540->Object::Object { 0xfffffcd635e0 } -0xfffffcd634f0->Object::Object { 0xfffffcd63540, 0xfffffcd635e0 } -0xfffffcd634f0->Object::~Object { 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } -0xfffffcd635e0->Object::~Object { 0xfffffcd63540, 0xfffffcd635e0 } -Shifting token 'a' (0xfffffcd63540 'a') -0xaaaae725b2e0->Object::Object { 0xfffffcd63540 } -0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xfffffcd63540 } -0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xfffffcd634c8, 0xfffffcd63540 } -0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63540 } -Entering state 2 -Stack now 0 2 -0xfffffcd63600->Object::Object { 0xaaaae725b2e0 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaae725b2e0 'a') --> $$ = nterm item (0xfffffcd63600 'a') -0xaaaae725b2e0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63600 } -0xaaaae725b2e0->Object::Object { 0xfffffcd63600 } -0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xfffffcd63600 } -0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd635b0, 0xfffffcd63600 } -0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63600 } -Entering state 11 -Stack now 0 11 -Reading a token -0xfffffcd63500->Object::Object { 0xaaaae725b2e0 } -0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xfffffcd63500 } -0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63500, 0xfffffcd635e0 } -Next token is token 'a' (0xfffffcd635e0 'a') -0xfffffcd63540->Object::Object { 0xaaaae725b2e0, 0xfffffcd635e0 } -0xfffffcd634f0->Object::Object { 0xaaaae725b2e0, 0xfffffcd63540, 0xfffffcd635e0 } -0xfffffcd634f0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } -0xfffffcd635e0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63540, 0xfffffcd635e0 } -Shifting token 'a' (0xfffffcd63540 'a') -0xaaaae725b300->Object::Object { 0xaaaae725b2e0, 0xfffffcd63540 } -0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540 } -0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd634c8, 0xfffffcd63540 } -0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540 } -Entering state 2 -Stack now 0 11 2 -0xfffffcd63600->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaae725b300 'a') --> $$ = nterm item (0xfffffcd63600 'a') -0xaaaae725b300->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } -0xaaaae725b300->Object::Object { 0xaaaae725b2e0, 0xfffffcd63600 } -0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } -0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd635b0, 0xfffffcd63600 } -0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } -Entering state 11 -Stack now 0 11 11 -Reading a token -0xfffffcd63500->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300 } -0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63500 } -0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63500, 0xfffffcd635e0 } -Next token is token 'a' (0xfffffcd635e0 'a') -0xfffffcd63540->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd635e0 } -0xfffffcd634f0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540, 0xfffffcd635e0 } -0xfffffcd634f0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } -0xfffffcd635e0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540, 0xfffffcd635e0 } -Shifting token 'a' (0xfffffcd63540 'a') -0xaaaae725b320->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540 } -0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540 } -0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd634c8, 0xfffffcd63540 } -0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540 } -Entering state 2 -Stack now 0 11 11 2 -0xfffffcd63600->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaae725b320 'a') --> $$ = nterm item (0xfffffcd63600 'a') -0xaaaae725b320->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } -0xaaaae725b320->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } -0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } -0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd635b0, 0xfffffcd63600 } -0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } -Entering state 11 -Stack now 0 11 11 11 -Reading a token -0xfffffcd63500->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320 } -0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63500 } -0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63500, 0xfffffcd635e0 } -Next token is token 'a' (0xfffffcd635e0 'a') -0xfffffcd63540->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd635e0 } -0xfffffcd634f0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540, 0xfffffcd635e0 } -0xfffffcd634f0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } -0xfffffcd635e0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540, 0xfffffcd635e0 } -Shifting token 'a' (0xfffffcd63540 'a') -0xaaaae725b340->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540 } -0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63540 } -0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd634c8, 0xfffffcd63540 } -0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63540 } -Entering state 2 -Stack now 0 11 11 11 2 -0xfffffcd63600->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaae725b340 'a') --> $$ = nterm item (0xfffffcd63600 'a') -0xaaaae725b340->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63600 } -0xaaaae725b340->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } -0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63600 } -0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd635b0, 0xfffffcd63600 } -0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63600 } -Entering state 11 -Stack now 0 11 11 11 11 -Reading a token -0xfffffcd63500->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340 } -0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63500 } -0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63500, 0xfffffcd635e0 } -Next token is token 'p' (0xfffffcd635e0 'p'Exception caught: cleaning lookahead and stack -0xaaaae725b340->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd635e0 } -0xaaaae725b320->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd635e0 } -0xaaaae725b300->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd635e0 } -0xaaaae725b2e0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd635e0 } -0xfffffcd635e0->Object::~Object { 0xfffffcd635e0 } -exception caught: printer -end { } -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -0xfffffcd63500->Object::Object { } -0xfffffcd635e0->Object::Object { 0xfffffcd63500 } -0xfffffcd63500->Object::~Object { 0xfffffcd63500, 0xfffffcd635e0 } -Next token is token 'a' (0xfffffcd635e0 'a') -0xfffffcd63540->Object::Object { 0xfffffcd635e0 } -0xfffffcd634f0->Object::Object { 0xfffffcd63540, 0xfffffcd635e0 } -0xfffffcd634f0->Object::~Object { 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } -0xfffffcd635e0->Object::~Object { 0xfffffcd63540, 0xfffffcd635e0 } -Shifting token 'a' (0xfffffcd63540 'a') -0xaaaae725b2e0->Object::Object { 0xfffffcd63540 } -0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xfffffcd63540 } -0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xfffffcd634c8, 0xfffffcd63540 } -0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63540 } -Entering state 2 -Stack now 0 2 -0xfffffcd63600->Object::Object { 0xaaaae725b2e0 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaae725b2e0 'a') --> $$ = nterm item (0xfffffcd63600 'a') -0xaaaae725b2e0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63600 } -0xaaaae725b2e0->Object::Object { 0xfffffcd63600 } -0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xfffffcd63600 } -0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd635b0, 0xfffffcd63600 } -0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63600 } -Entering state 11 -Stack now 0 11 -Reading a token -0xfffffcd63500->Object::Object { 0xaaaae725b2e0 } -0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xfffffcd63500 } -0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63500, 0xfffffcd635e0 } -Next token is token 'a' (0xfffffcd635e0 'a') -0xfffffcd63540->Object::Object { 0xaaaae725b2e0, 0xfffffcd635e0 } -0xfffffcd634f0->Object::Object { 0xaaaae725b2e0, 0xfffffcd63540, 0xfffffcd635e0 } -0xfffffcd634f0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } -0xfffffcd635e0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd63540, 0xfffffcd635e0 } -Shifting token 'a' (0xfffffcd63540 'a') -0xaaaae725b300->Object::Object { 0xaaaae725b2e0, 0xfffffcd63540 } -0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540 } -0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd634c8, 0xfffffcd63540 } -0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540 } -Entering state 2 -Stack now 0 11 2 -0xfffffcd63600->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaae725b300 'a') --> $$ = nterm item (0xfffffcd63600 'a') -0xaaaae725b300->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } -0xaaaae725b300->Object::Object { 0xaaaae725b2e0, 0xfffffcd63600 } -0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } -0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd635b0, 0xfffffcd63600 } -0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } -Entering state 11 -Stack now 0 11 11 -Reading a token -0xfffffcd63500->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300 } -0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63500 } -0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63500, 0xfffffcd635e0 } -Next token is token 'a' (0xfffffcd635e0 'a') -0xfffffcd63540->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd635e0 } -0xfffffcd634f0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540, 0xfffffcd635e0 } -0xfffffcd634f0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } -0xfffffcd635e0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540, 0xfffffcd635e0 } -Shifting token 'a' (0xfffffcd63540 'a') -0xaaaae725b320->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63540 } -0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540 } -0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd634c8, 0xfffffcd63540 } -0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540 } -Entering state 2 -Stack now 0 11 11 2 -0xfffffcd63600->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaae725b320 'a') --> $$ = nterm item (0xfffffcd63600 'a') -0xaaaae725b320->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } -0xaaaae725b320->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd63600 } -0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } -0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd635b0, 0xfffffcd63600 } -0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } -Entering state 11 -Stack now 0 11 11 11 -Reading a token -0xfffffcd63500->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320 } -0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63500 } -0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63500, 0xfffffcd635e0 } -Next token is token 'a' (0xfffffcd635e0 'a') -0xfffffcd63540->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd635e0 } -0xfffffcd634f0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540, 0xfffffcd635e0 } -0xfffffcd634f0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd634f0, 0xfffffcd63540, 0xfffffcd635e0 } -0xfffffcd635e0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540, 0xfffffcd635e0 } -Shifting token 'a' (0xfffffcd63540 'a') -0xaaaae725b340->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63540 } -0xfffffcd634c8->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63540 } -0xfffffcd634c8->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd634c8, 0xfffffcd63540 } -0xfffffcd63540->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63540 } -Entering state 2 -Stack now 0 11 11 11 2 -0xfffffcd63600->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaae725b340 'a') --> $$ = nterm item (0xfffffcd63600 'a') -0xaaaae725b340->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63600 } -0xaaaae725b340->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd63600 } -0xfffffcd635b0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63600 } -0xfffffcd635b0->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd635b0, 0xfffffcd63600 } -0xfffffcd63600->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63600 } -Entering state 11 -Stack now 0 11 11 11 11 -Reading a token -0xfffffcd63500->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340 } -0xfffffcd635e0->Object::Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63500 } -0xfffffcd63500->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd63500, 0xfffffcd635e0 } -Next token is token 'p' (0xfffffcd635e0 'p'Exception caught: cleaning lookahead and stack -0xaaaae725b340->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xaaaae725b340, 0xfffffcd635e0 } -0xaaaae725b320->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xaaaae725b320, 0xfffffcd635e0 } -0xaaaae725b300->Object::~Object { 0xaaaae725b2e0, 0xaaaae725b300, 0xfffffcd635e0 } -0xaaaae725b2e0->Object::~Object { 0xaaaae725b2e0, 0xfffffcd635e0 } -0xfffffcd635e0->Object::~Object { 0xfffffcd635e0 } -exception caught: printer -end { } -./c++.at:1362: grep '^exception caught: printer$' stderr stdout: -exception caught: printer -./c++.at:1362: $PREPARSER ./input aaaae -./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -exception caught: syntax error -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1362: $PREPARSER ./input aaaaE +./c++.at:1065: $PREPARSER ./input < in stderr: -exception caught: syntax error, unexpected end of file, expecting 'a' -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +error: invalid expression +caught error +error: invalid character +caught error +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: -./c++.at:1363: $PREPARSER ./input aaaas -stderr: -exception caught: reduction -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1362: $PREPARSER ./input aaaaT -stderr: -./c++.at:1363: $PREPARSER ./input aaaal -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -exception caught: yylex -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1362: $PREPARSER ./input aaaaR -stderr: -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1363: $PREPARSER ./input i stderr: -exception caught: initial-action +./c++.at:1362: $PREPARSER ./input aaaas +stdout: +691. c++.at:1517: testing Default action ... ======== Testing with C++ standard flags: '' -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./c++.at:1363: $PREPARSER ./input aaaap -stderr: stderr: -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: ./c++.at:1360: $PREPARSER ./input aaaas -./c++.at:1363: $PREPARSER ./input --debug aaaap -stderr: +./c++.at:1065: $PREPARSER ./input < in stderr: exception caught: reduction ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +exception caught: reduction +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -0xffffcb68b7a0->Object::Object { } -0xffffcb68b880->Object::Object { 0xffffcb68b7a0 } -0xffffcb68b7a0->Object::~Object { 0xffffcb68b7a0, 0xffffcb68b880 } -Next token is token 'a' (0xffffcb68b880 'a') -0xffffcb68b7e0->Object::Object { 0xffffcb68b880 } -0xffffcb68b790->Object::Object { 0xffffcb68b7e0, 0xffffcb68b880 } -0xffffcb68b790->Object::~Object { 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } -0xffffcb68b880->Object::~Object { 0xffffcb68b7e0, 0xffffcb68b880 } -Shifting token 'a' (0xffffcb68b7e0 'a') -0xaaaaf501a2e0->Object::Object { 0xffffcb68b7e0 } -0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7e0 } -0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b768, 0xffffcb68b7e0 } -0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b7e0 } -Entering state 1 -Stack now 0 1 -0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaf501a2e0 'a') --> $$ = nterm item (0xffffcb68b8a0 'a') -0xaaaaf501a2e0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } -0xaaaaf501a2e0->Object::Object { 0xffffcb68b8a0 } -0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } -0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b850, 0xffffcb68b8a0 } -0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } -Entering state 10 -Stack now 0 10 -Reading a token -0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0 } -0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7a0 } -0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b7a0, 0xffffcb68b880 } -Next token is token 'a' (0xffffcb68b880 'a') -0xffffcb68b7e0->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b880 } -0xffffcb68b790->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7e0, 0xffffcb68b880 } -0xffffcb68b790->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } -0xffffcb68b880->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b7e0, 0xffffcb68b880 } -Shifting token 'a' (0xffffcb68b7e0 'a') -0xaaaaf501a300->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7e0 } -0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0 } -0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b768, 0xffffcb68b7e0 } -0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0 } -Entering state 1 -Stack now 0 10 1 -0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaf501a300 'a') --> $$ = nterm item (0xffffcb68b8a0 'a') -0xaaaaf501a300->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } -0xaaaaf501a300->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } -0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } -0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b850, 0xffffcb68b8a0 } -0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } -Entering state 10 -Stack now 0 10 10 -Reading a token -0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300 } -0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7a0 } -0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7a0, 0xffffcb68b880 } -Next token is token 'a' (0xffffcb68b880 'a') -0xffffcb68b7e0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b880 } -0xffffcb68b790->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0, 0xffffcb68b880 } -0xffffcb68b790->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } -0xffffcb68b880->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0, 0xffffcb68b880 } -Shifting token 'a' (0xffffcb68b7e0 'a') -0xaaaaf501a320->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0 } -0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0 } -0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b768, 0xffffcb68b7e0 } -0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0 } -Entering state 1 -Stack now 0 10 10 1 -0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaf501a320 'a') --> $$ = nterm item (0xffffcb68b8a0 'a') -0xaaaaf501a320->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } -0xaaaaf501a320->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } -0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } -0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b850, 0xffffcb68b8a0 } -0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } -Entering state 10 -Stack now 0 10 10 10 -Reading a token -0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320 } -0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7a0 } -0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7a0, 0xffffcb68b880 } -Next token is token 'a' (0xffffcb68b880 'a') -0xffffcb68b7e0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b880 } -0xffffcb68b790->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0, 0xffffcb68b880 } -0xffffcb68b790->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } -0xffffcb68b880->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0, 0xffffcb68b880 } -Shifting token 'a' (0xffffcb68b7e0 'a') -0xaaaaf501a340->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0 } -0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7e0 } -0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b768, 0xffffcb68b7e0 } -0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7e0 } -Entering state 1 -Stack now 0 10 10 10 1 -0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaf501a340 'a') --> $$ = nterm item (0xffffcb68b8a0 'a') -0xaaaaf501a340->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b8a0 } -0xaaaaf501a340->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } -0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b8a0 } -0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b850, 0xffffcb68b8a0 } -0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b8a0 } -Entering state 10 -Stack now 0 10 10 10 10 -Reading a token -0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340 } -0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7a0 } -0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7a0, 0xffffcb68b880 } -Next token is token 'p' (0xffffcb68b880 'p'Exception caught: cleaning lookahead and stack -0xaaaaf501a340->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b880 } -0xaaaaf501a320->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b880 } -0xaaaaf501a300->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b880 } -0xaaaaf501a2e0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b880 } -0xffffcb68b880->Object::~Object { 0xffffcb68b880 } -exception caught: printer -end { } -stdout: -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1502: $PREPARSER ./parser ./c++.at:1360: $PREPARSER ./input aaaal +./c++.at:1362: $PREPARSER ./input aaaal stderr: stderr: -stderr: -./c++.at:1502: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +exception caught: yylex +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: yylex ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -690. c++.at:1422: ok stdout: -./c++.at:1066: $PREPARSER ./input < in +stderr: +./c++.at:1064: $PREPARSER ./input < in +error: invalid expression +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1362: $PREPARSER ./input i +stderr: stderr: stderr: +exception caught: initial-action +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +./c++.at:1360: $PREPARSER ./input i error: invalid expression caught error error: invalid character caught error -./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -Starting parse -Entering state 0 -Stack now 0 -Reading a token -0xffffcb68b7a0->Object::Object { } -0xffffcb68b880->Object::Object { 0xffffcb68b7a0 } -0xffffcb68b7a0->Object::~Object { 0xffffcb68b7a0, 0xffffcb68b880 } -Next token is token 'a' (0xffffcb68b880 'a') -0xffffcb68b7e0->Object::Object { 0xffffcb68b880 } -0xffffcb68b790->Object::Object { 0xffffcb68b7e0, 0xffffcb68b880 } -0xffffcb68b790->Object::~Object { 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } -0xffffcb68b880->Object::~Object { 0xffffcb68b7e0, 0xffffcb68b880 } -Shifting token 'a' (0xffffcb68b7e0 'a') -0xaaaaf501a2e0->Object::Object { 0xffffcb68b7e0 } -0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7e0 } -0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b768, 0xffffcb68b7e0 } -0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b7e0 } -Entering state 1 -Stack now 0 1 -0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaf501a2e0 'a') --> $$ = nterm item (0xffffcb68b8a0 'a') -0xaaaaf501a2e0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } -0xaaaaf501a2e0->Object::Object { 0xffffcb68b8a0 } -0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } -0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b850, 0xffffcb68b8a0 } -0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } -Entering state 10 -Stack now 0 10 -Reading a token -0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0 } -0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7a0 } -0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b7a0, 0xffffcb68b880 } -Next token is token 'a' (0xffffcb68b880 'a') -0xffffcb68b7e0->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b880 } -0xffffcb68b790->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7e0, 0xffffcb68b880 } -0xffffcb68b790->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } -0xffffcb68b880->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b7e0, 0xffffcb68b880 } -Shifting token 'a' (0xffffcb68b7e0 'a') -0xaaaaf501a300->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b7e0 } -0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0 } -0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b768, 0xffffcb68b7e0 } -0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0 } -Entering state 1 -Stack now 0 10 1 -0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaf501a300 'a') --> $$ = nterm item (0xffffcb68b8a0 'a') -0xaaaaf501a300->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } -0xaaaaf501a300->Object::Object { 0xaaaaf501a2e0, 0xffffcb68b8a0 } -0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } -0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b850, 0xffffcb68b8a0 } -0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } -Entering state 10 -Stack now 0 10 10 -Reading a token -0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300 } -0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7a0 } -0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7a0, 0xffffcb68b880 } -Next token is token 'a' (0xffffcb68b880 'a') -0xffffcb68b7e0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b880 } -0xffffcb68b790->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0, 0xffffcb68b880 } -0xffffcb68b790->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } -0xffffcb68b880->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0, 0xffffcb68b880 } -Shifting token 'a' (0xffffcb68b7e0 'a') -0xaaaaf501a320->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b7e0 } -0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0 } -0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b768, 0xffffcb68b7e0 } -0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0 } -Entering state 1 -Stack now 0 10 10 1 -0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaf501a320 'a') --> $$ = nterm item (0xffffcb68b8a0 'a') -0xaaaaf501a320->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } -0xaaaaf501a320->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b8a0 } -0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } -0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b850, 0xffffcb68b8a0 } -0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } -Entering state 10 -Stack now 0 10 10 10 -Reading a token -0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320 } -0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7a0 } -0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7a0, 0xffffcb68b880 } -Next token is token 'a' (0xffffcb68b880 'a') -0xffffcb68b7e0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b880 } -0xffffcb68b790->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0, 0xffffcb68b880 } -0xffffcb68b790->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b790, 0xffffcb68b7e0, 0xffffcb68b880 } -0xffffcb68b880->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0, 0xffffcb68b880 } -Shifting token 'a' (0xffffcb68b7e0 'a') -0xaaaaf501a340->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b7e0 } -0xffffcb68b768->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7e0 } -0xffffcb68b768->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b768, 0xffffcb68b7e0 } -0xffffcb68b7e0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7e0 } -Entering state 1 -Stack now 0 10 10 10 1 -0xffffcb68b8a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaf501a340 'a') --> $$ = nterm item (0xffffcb68b8a0 'a') -0xaaaaf501a340->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b8a0 } -0xaaaaf501a340->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b8a0 } -0xffffcb68b850->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b8a0 } -0xffffcb68b850->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b850, 0xffffcb68b8a0 } -0xffffcb68b8a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b8a0 } -Entering state 10 -Stack now 0 10 10 10 10 -Reading a token -0xffffcb68b7a0->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340 } -0xffffcb68b880->Object::Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7a0 } -0xffffcb68b7a0->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b7a0, 0xffffcb68b880 } -Next token is token 'p' (0xffffcb68b880 'p'Exception caught: cleaning lookahead and stack -0xaaaaf501a340->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xaaaaf501a340, 0xffffcb68b880 } -0xaaaaf501a320->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xaaaaf501a320, 0xffffcb68b880 } -0xaaaaf501a300->Object::~Object { 0xaaaaf501a2e0, 0xaaaaf501a300, 0xffffcb68b880 } -0xaaaaf501a2e0->Object::~Object { 0xaaaaf501a2e0, 0xffffcb68b880 } -0xffffcb68b880->Object::~Object { 0xffffcb68b880 } -exception caught: printer -end { } -./c++.at:1363: grep '^exception caught: printer$' stderr -./c++.at:1066: $PREPARSER ./input < in - -./c++.at:1360: $PREPARSER ./input i +./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -stdout: stderr: +stdout: +./c++.at:1064: $PREPARSER ./input < in +./c++.at:1065: $PREPARSER ./input < in +======== Testing with C++ standard flags: '' +./c++.at:1362: $PREPARSER ./input aaaap +./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS exception caught: initial-action -exception caught: printer -error: invalid expression -./c++.at:1363: $PREPARSER ./input aaaae +stderr: +./c++.at:1361: $PREPARSER ./input aaaas ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -exception caught: syntax error -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1066: $PREPARSER ./input < in -./c++.at:1363: $PREPARSER ./input aaaaE -./c++.at:1360: $PREPARSER ./input aaaap stderr: +error: invalid expression +./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -exception caught: syntax error, unexpected end of file, expecting 'a' -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: invalid character -./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -691. c++.at:1517: testing Default action ... +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +stdout: +exception caught: reduction +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:1363: $PREPARSER ./input aaaaT -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' +./c++.at:1555: ./check +./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y +./c++.at:1064: $PREPARSER ./input < in +./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS +./c++.at:1360: $PREPARSER ./input aaaap +./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: -./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input --debug aaaap stderr: -./c++.at:1363: $PREPARSER ./input aaaaR -stdout: +./c++.at:1361: $PREPARSER ./input aaaal +error: invalid character +./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./c++.at:856: $PREPARSER ./input -./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xaaaadffc9f40->Object::Object { } -Next token is token 'a' (0xaaaadffc9f40 'a') -Shifting token 'a' (0xaaaadffc9f40 'a') +0xffffd9be97d0->Object::Object { } +0xffffd9be98b0->Object::Object { 0xffffd9be97d0 } +0xffffd9be97d0->Object::~Object { 0xffffd9be97d0, 0xffffd9be98b0 } +Next token is token 'a' (0xffffd9be98b0 'a') +0xffffd9be9810->Object::Object { 0xffffd9be98b0 } +0xffffd9be97c0->Object::Object { 0xffffd9be9810, 0xffffd9be98b0 } +0xffffd9be97c0->Object::~Object { 0xffffd9be97c0, 0xffffd9be9810, 0xffffd9be98b0 } +0xffffd9be98b0->Object::~Object { 0xffffd9be9810, 0xffffd9be98b0 } +Shifting token 'a' (0xffffd9be9810 'a') +0xaaaac588c2e0->Object::Object { 0xffffd9be9810 } +0xffffd9be9798->Object::Object { 0xaaaac588c2e0, 0xffffd9be9810 } +0xffffd9be9798->Object::~Object { 0xaaaac588c2e0, 0xffffd9be9798, 0xffffd9be9810 } +0xffffd9be9810->Object::~Object { 0xaaaac588c2e0, 0xffffd9be9810 } Entering state 2 Stack now 0 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadffc9f40 'a') --> $$ = nterm item (0xaaaadffc9f40 'a') +0xffffd9be98d0->Object::Object { 0xaaaac588c2e0 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaac588c2e0 'a') +-> $$ = nterm item (0xffffd9be98d0 'a') +0xaaaac588c2e0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be98d0 } +0xaaaac588c2e0->Object::Object { 0xffffd9be98d0 } +0xffffd9be9880->Object::Object { 0xaaaac588c2e0, 0xffffd9be98d0 } +0xffffd9be9880->Object::~Object { 0xaaaac588c2e0, 0xffffd9be9880, 0xffffd9be98d0 } +0xffffd9be98d0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be98d0 } Entering state 11 Stack now 0 11 Reading a token -0xaaaadffc9f90->Object::Object { 0xaaaadffc9f40 } -Next token is token 'a' (0xaaaadffc9f90 'a') -Shifting token 'a' (0xaaaadffc9f90 'a') +0xffffd9be97d0->Object::Object { 0xaaaac588c2e0 } +0xffffd9be98b0->Object::Object { 0xaaaac588c2e0, 0xffffd9be97d0 } +0xffffd9be97d0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be97d0, 0xffffd9be98b0 } +Next token is token 'a' (0xffffd9be98b0 'a') +0xffffd9be9810->Object::Object { 0xaaaac588c2e0, 0xffffd9be98b0 } +0xffffd9be97c0->Object::Object { 0xaaaac588c2e0, 0xffffd9be9810, 0xffffd9be98b0 } +0xffffd9be97c0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be97c0, 0xffffd9be9810, 0xffffd9be98b0 } +0xffffd9be98b0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be9810, 0xffffd9be98b0 } +Shifting token 'a' (0xffffd9be9810 'a') +0xaaaac588c300->Object::Object { 0xaaaac588c2e0, 0xffffd9be9810 } +0xffffd9be9798->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9810 } +0xffffd9be9798->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9798, 0xffffd9be9810 } +0xffffd9be9810->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9810 } Entering state 2 Stack now 0 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadffc9f90 'a') --> $$ = nterm item (0xaaaadffc9f90 'a') +0xffffd9be98d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaac588c300 'a') +-> $$ = nterm item (0xffffd9be98d0 'a') +0xaaaac588c300->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98d0 } +0xaaaac588c300->Object::Object { 0xaaaac588c2e0, 0xffffd9be98d0 } +0xffffd9be9880->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98d0 } +0xffffd9be9880->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9880, 0xffffd9be98d0 } +0xffffd9be98d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98d0 } Entering state 11 Stack now 0 11 11 Reading a token -0xaaaadffc9fe0->Object::Object { 0xaaaadffc9f40, 0xaaaadffc9f90 } -Next token is token 'a' (0xaaaadffc9fe0 'a') -Shifting token 'a' (0xaaaadffc9fe0 'a') +0xffffd9be97d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300 } +0xffffd9be98b0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be97d0 } +0xffffd9be97d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be97d0, 0xffffd9be98b0 } +Next token is token 'a' (0xffffd9be98b0 'a') +0xffffd9be9810->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98b0 } +0xffffd9be97c0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9810, 0xffffd9be98b0 } +0xffffd9be97c0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be97c0, 0xffffd9be9810, 0xffffd9be98b0 } +0xffffd9be98b0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9810, 0xffffd9be98b0 } +Shifting token 'a' (0xffffd9be9810 'a') +0xaaaac588c320->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9810 } +0xffffd9be9798->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9810 } +0xffffd9be9798->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9798, 0xffffd9be9810 } +0xffffd9be9810->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9810 } Entering state 2 Stack now 0 11 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadffc9fe0 'a') --> $$ = nterm item (0xaaaadffc9fe0 'a') +0xffffd9be98d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaac588c320 'a') +-> $$ = nterm item (0xffffd9be98d0 'a') +0xaaaac588c320->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98d0 } +0xaaaac588c320->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98d0 } +0xffffd9be9880->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98d0 } +0xffffd9be9880->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9880, 0xffffd9be98d0 } +0xffffd9be98d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98d0 } Entering state 11 Stack now 0 11 11 11 Reading a token -0xaaaadffca030->Object::Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0 } -Next token is token 'a' (0xaaaadffca030 'a') -Shifting token 'a' (0xaaaadffca030 'a') +0xffffd9be97d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320 } +0xffffd9be98b0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be97d0 } +0xffffd9be97d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be97d0, 0xffffd9be98b0 } +Next token is token 'a' (0xffffd9be98b0 'a') +0xffffd9be9810->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98b0 } +0xffffd9be97c0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9810, 0xffffd9be98b0 } +0xffffd9be97c0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be97c0, 0xffffd9be9810, 0xffffd9be98b0 } +0xffffd9be98b0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9810, 0xffffd9be98b0 } +Shifting token 'a' (0xffffd9be9810 'a') +0xaaaac588c340->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9810 } +0xffffd9be9798->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be9810 } +0xffffd9be9798->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be9798, 0xffffd9be9810 } +0xffffd9be9810->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be9810 } Entering state 2 Stack now 0 11 11 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadffca030 'a') --> $$ = nterm item (0xaaaadffca030 'a') +0xffffd9be98d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaac588c340 'a') +-> $$ = nterm item (0xffffd9be98d0 'a') +0xaaaac588c340->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be98d0 } +0xaaaac588c340->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98d0 } +0xffffd9be9880->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be98d0 } +0xffffd9be9880->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be9880, 0xffffd9be98d0 } +0xffffd9be98d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be98d0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token -0xaaaadffca080->Object::Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0, 0xaaaadffca030 } -Next token is token 'p' (0xaaaadffca080 'p'Exception caught: cleaning lookahead and stack -0xaaaadffca080->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0, 0xaaaadffca030, 0xaaaadffca080 } -0xaaaadffca030->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0, 0xaaaadffca030 } -0xaaaadffc9fe0->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0 } -0xaaaadffc9f90->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90 } -0xaaaadffc9f40->Object::~Object { 0xaaaadffc9f40 } +0xffffd9be97d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340 } +0xffffd9be98b0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be97d0 } +0xffffd9be97d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be97d0, 0xffffd9be98b0 } +Next token is token 'p' (0xffffd9be98b0 'p'Exception caught: cleaning lookahead and stack +0xaaaac588c340->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be98b0 } +0xaaaac588c320->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98b0 } +0xaaaac588c300->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98b0 } +0xaaaac588c2e0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be98b0 } +0xffffd9be98b0->Object::~Object { 0xffffd9be98b0 } exception caught: printer end { } -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:857: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: $PREPARSER ./input --debug aaaap +exception caught: yylex +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xaaaadffc9f40->Object::Object { } -Next token is token 'a' (0xaaaadffc9f40 'a') -Shifting token 'a' (0xaaaadffc9f40 'a') +0xffffd9be97d0->Object::Object { } +0xffffd9be98b0->Object::Object { 0xffffd9be97d0 } +0xffffd9be97d0->Object::~Object { 0xffffd9be97d0, 0xffffd9be98b0 } +Next token is token 'a' (0xffffd9be98b0 'a') +0xffffd9be9810->Object::Object { 0xffffd9be98b0 } +0xffffd9be97c0->Object::Object { 0xffffd9be9810, 0xffffd9be98b0 } +0xffffd9be97c0->Object::~Object { 0xffffd9be97c0, 0xffffd9be9810, 0xffffd9be98b0 } +0xffffd9be98b0->Object::~Object { 0xffffd9be9810, 0xffffd9be98b0 } +Shifting token 'a' (0xffffd9be9810 'a') +0xaaaac588c2e0->Object::Object { 0xffffd9be9810 } +0xffffd9be9798->Object::Object { 0xaaaac588c2e0, 0xffffd9be9810 } +0xffffd9be9798->Object::~Object { 0xaaaac588c2e0, 0xffffd9be9798, 0xffffd9be9810 } +0xffffd9be9810->Object::~Object { 0xaaaac588c2e0, 0xffffd9be9810 } Entering state 2 Stack now 0 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadffc9f40 'a') --> $$ = nterm item (0xaaaadffc9f40 'a') +0xffffd9be98d0->Object::Object { 0xaaaac588c2e0 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaac588c2e0 'a') +-> $$ = nterm item (0xffffd9be98d0 'a') +0xaaaac588c2e0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be98d0 } +0xaaaac588c2e0->Object::Object { 0xffffd9be98d0 } +0xffffd9be9880->Object::Object { 0xaaaac588c2e0, 0xffffd9be98d0 } +0xffffd9be9880->Object::~Object { 0xaaaac588c2e0, 0xffffd9be9880, 0xffffd9be98d0 } +0xffffd9be98d0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be98d0 } Entering state 11 Stack now 0 11 Reading a token -0xaaaadffc9f90->Object::Object { 0xaaaadffc9f40 } -Next token is token 'a' (0xaaaadffc9f90 'a') -Shifting token 'a' (0xaaaadffc9f90 'a') +0xffffd9be97d0->Object::Object { 0xaaaac588c2e0 } +0xffffd9be98b0->Object::Object { 0xaaaac588c2e0, 0xffffd9be97d0 } +0xffffd9be97d0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be97d0, 0xffffd9be98b0 } +Next token is token 'a' (0xffffd9be98b0 'a') +0xffffd9be9810->Object::Object { 0xaaaac588c2e0, 0xffffd9be98b0 } +0xffffd9be97c0->Object::Object { 0xaaaac588c2e0, 0xffffd9be9810, 0xffffd9be98b0 } +0xffffd9be97c0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be97c0, 0xffffd9be9810, 0xffffd9be98b0 } +0xffffd9be98b0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be9810, 0xffffd9be98b0 } +Shifting token 'a' (0xffffd9be9810 'a') +0xaaaac588c300->Object::Object { 0xaaaac588c2e0, 0xffffd9be9810 } +0xffffd9be9798->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9810 } +0xffffd9be9798->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9798, 0xffffd9be9810 } +0xffffd9be9810->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9810 } Entering state 2 Stack now 0 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadffc9f90 'a') --> $$ = nterm item (0xaaaadffc9f90 'a') +0xffffd9be98d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaac588c300 'a') +-> $$ = nterm item (0xffffd9be98d0 'a') +0xaaaac588c300->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98d0 } +0xaaaac588c300->Object::Object { 0xaaaac588c2e0, 0xffffd9be98d0 } +0xffffd9be9880->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98d0 } +0xffffd9be9880->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9880, 0xffffd9be98d0 } +0xffffd9be98d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98d0 } Entering state 11 Stack now 0 11 11 Reading a token -0xaaaadffc9fe0->Object::Object { 0xaaaadffc9f40, 0xaaaadffc9f90 } -Next token is token 'a' (0xaaaadffc9fe0 'a') -Shifting token 'a' (0xaaaadffc9fe0 'a') +0xffffd9be97d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300 } +0xffffd9be98b0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be97d0 } +0xffffd9be97d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be97d0, 0xffffd9be98b0 } +Next token is token 'a' (0xffffd9be98b0 'a') +0xffffd9be9810->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98b0 } +0xffffd9be97c0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9810, 0xffffd9be98b0 } +0xffffd9be97c0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be97c0, 0xffffd9be9810, 0xffffd9be98b0 } +0xffffd9be98b0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9810, 0xffffd9be98b0 } +Shifting token 'a' (0xffffd9be9810 'a') +0xaaaac588c320->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be9810 } +0xffffd9be9798->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9810 } +0xffffd9be9798->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9798, 0xffffd9be9810 } +0xffffd9be9810->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9810 } Entering state 2 Stack now 0 11 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadffc9fe0 'a') --> $$ = nterm item (0xaaaadffc9fe0 'a') +0xffffd9be98d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaac588c320 'a') +-> $$ = nterm item (0xffffd9be98d0 'a') +0xaaaac588c320->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98d0 } +0xaaaac588c320->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98d0 } +0xffffd9be9880->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98d0 } +0xffffd9be9880->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9880, 0xffffd9be98d0 } +0xffffd9be98d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98d0 } Entering state 11 Stack now 0 11 11 11 Reading a token -0xaaaadffca030->Object::Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0 } -Next token is token 'a' (0xaaaadffca030 'a') -Shifting token 'a' (0xaaaadffca030 'a') +0xffffd9be97d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320 } +0xffffd9be98b0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be97d0 } +0xffffd9be97d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be97d0, 0xffffd9be98b0 } +Next token is token 'a' (0xffffd9be98b0 'a') +0xffffd9be9810->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98b0 } +0xffffd9be97c0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9810, 0xffffd9be98b0 } +0xffffd9be97c0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be97c0, 0xffffd9be9810, 0xffffd9be98b0 } +0xffffd9be98b0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9810, 0xffffd9be98b0 } +Shifting token 'a' (0xffffd9be9810 'a') +0xaaaac588c340->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be9810 } +0xffffd9be9798->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be9810 } +0xffffd9be9798->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be9798, 0xffffd9be9810 } +0xffffd9be9810->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be9810 } Entering state 2 Stack now 0 11 11 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadffca030 'a') --> $$ = nterm item (0xaaaadffca030 'a') +0xffffd9be98d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaac588c340 'a') +-> $$ = nterm item (0xffffd9be98d0 'a') +0xaaaac588c340->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be98d0 } +0xaaaac588c340->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98d0 } +0xffffd9be9880->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be98d0 } +0xffffd9be9880->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be9880, 0xffffd9be98d0 } +0xffffd9be98d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be98d0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token -0xaaaadffca080->Object::Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0, 0xaaaadffca030 } -Next token is token 'p' (0xaaaadffca080 'p'Exception caught: cleaning lookahead and stack -0xaaaadffca080->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0, 0xaaaadffca030, 0xaaaadffca080 } -0xaaaadffca030->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0, 0xaaaadffca030 } -0xaaaadffc9fe0->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90, 0xaaaadffc9fe0 } -0xaaaadffc9f90->Object::~Object { 0xaaaadffc9f40, 0xaaaadffc9f90 } -0xaaaadffc9f40->Object::~Object { 0xaaaadffc9f40 } -exception caught: printer -end { } -./c++.at:1360: grep '^exception caught: printer$' stderr -stdout: -======== Testing with C++ standard flags: '' -./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -exception caught: printer -./c++.at:1360: $PREPARSER ./input aaaae -stderr: -stdout: -./c++.at:1066: ./check -./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS -======== Testing with C++ standard flags: '' -./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -exception caught: syntax error -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: -./c++.at:1555: ./check -./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y -./c++.at:1360: $PREPARSER ./input aaaaE -stderr: -exception caught: syntax error, unexpected end of file, expecting 'a' -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input aaaaT -./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -stderr: -stdout: -stderr: -./c++.at:851: $PREPARSER ./input -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./c++.at:1360: $PREPARSER ./input aaaaR -./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -======== Testing with C++ standard flags: '' -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: -======== Testing with C++ standard flags: '' -./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -======== Testing with C++ standard flags: '' -./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./c++.at:1361: $PREPARSER ./input aaaas -stderr: -exception caught: reduction -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: $PREPARSER ./input aaaal -stderr: -exception caught: yylex -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: $PREPARSER ./input i -stderr: -stderr: -exception caught: initial-action -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./c++.at:1065: $PREPARSER ./input < in -./c++.at:1361: $PREPARSER ./input aaaap -stderr: -stderr: -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -error: invalid expression -caught error -error: invalid character -caught error -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: $PREPARSER ./input --debug aaaap -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -0xaaaaf6b83f40->Object::Object { } -Next token is token 'a' (0xaaaaf6b83f40 'a') -Shifting token 'a' (0xaaaaf6b83f40 'a') -Entering state 1 -Stack now 0 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf6b83f40 'a') --> $$ = nterm item (0xaaaaf6b83f40 'a') -Entering state 10 -Stack now 0 10 -Reading a token -0xaaaaf6b83f90->Object::Object { 0xaaaaf6b83f40 } -Next token is token 'a' (0xaaaaf6b83f90 'a') -Shifting token 'a' (0xaaaaf6b83f90 'a') -Entering state 1 -Stack now 0 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf6b83f90 'a') --> $$ = nterm item (0xaaaaf6b83f90 'a') -Entering state 10 -Stack now 0 10 10 -Reading a token -0xaaaaf6b83fe0->Object::Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90 } -Next token is token 'a' (0xaaaaf6b83fe0 'a') -Shifting token 'a' (0xaaaaf6b83fe0 'a') -Entering state 1 -Stack now 0 10 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf6b83fe0 'a') --> $$ = nterm item (0xaaaaf6b83fe0 'a') -Entering state 10 -Stack now 0 10 10 10 -Reading a token -0xaaaaf6b84030->Object::Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0 } -Next token is token 'a' (0xaaaaf6b84030 'a') -Shifting token 'a' (0xaaaaf6b84030 'a') -Entering state 1 -Stack now 0 10 10 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf6b84030 'a') --> $$ = nterm item (0xaaaaf6b84030 'a') -Entering state 10 -Stack now 0 10 10 10 10 -Reading a token -0xaaaaf6b84080->Object::Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0, 0xaaaaf6b84030 } -Next token is token 'p' (0xaaaaf6b84080 'p'Exception caught: cleaning lookahead and stack -0xaaaaf6b84080->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0, 0xaaaaf6b84030, 0xaaaaf6b84080 } -0xaaaaf6b84030->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0, 0xaaaaf6b84030 } -0xaaaaf6b83fe0->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0 } -0xaaaaf6b83f90->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90 } -0xaaaaf6b83f40->Object::~Object { 0xaaaaf6b83f40 } -exception caught: printer -end { } -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1065: $PREPARSER ./input < in -stderr: -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -0xaaaaf6b83f40->Object::Object { } -Next token is token 'a' (0xaaaaf6b83f40 'a') -Shifting token 'a' (0xaaaaf6b83f40 'a') -Entering state 1 -Stack now 0 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf6b83f40 'a') --> $$ = nterm item (0xaaaaf6b83f40 'a') -Entering state 10 -Stack now 0 10 -Reading a token -0xaaaaf6b83f90->Object::Object { 0xaaaaf6b83f40 } -Next token is token 'a' (0xaaaaf6b83f90 'a') -Shifting token 'a' (0xaaaaf6b83f90 'a') -Entering state 1 -Stack now 0 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf6b83f90 'a') --> $$ = nterm item (0xaaaaf6b83f90 'a') -Entering state 10 -Stack now 0 10 10 -Reading a token -0xaaaaf6b83fe0->Object::Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90 } -Next token is token 'a' (0xaaaaf6b83fe0 'a') -Shifting token 'a' (0xaaaaf6b83fe0 'a') -Entering state 1 -Stack now 0 10 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf6b83fe0 'a') --> $$ = nterm item (0xaaaaf6b83fe0 'a') -Entering state 10 -Stack now 0 10 10 10 -Reading a token -0xaaaaf6b84030->Object::Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0 } -Next token is token 'a' (0xaaaaf6b84030 'a') -Shifting token 'a' (0xaaaaf6b84030 'a') -Entering state 1 -Stack now 0 10 10 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf6b84030 'a') --> $$ = nterm item (0xaaaaf6b84030 'a') -Entering state 10 -Stack now 0 10 10 10 10 -Reading a token -0xaaaaf6b84080->Object::Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0, 0xaaaaf6b84030 } -Next token is token 'p' (0xaaaaf6b84080 'p'Exception caught: cleaning lookahead and stack -0xaaaaf6b84080->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0, 0xaaaaf6b84030, 0xaaaaf6b84080 } -0xaaaaf6b84030->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0, 0xaaaaf6b84030 } -0xaaaaf6b83fe0->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90, 0xaaaaf6b83fe0 } -0xaaaaf6b83f90->Object::~Object { 0xaaaaf6b83f40, 0xaaaaf6b83f90 } -0xaaaaf6b83f40->Object::~Object { 0xaaaaf6b83f40 } +0xffffd9be97d0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340 } +0xffffd9be98b0->Object::Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be97d0 } +0xffffd9be97d0->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be97d0, 0xffffd9be98b0 } +Next token is token 'p' (0xffffd9be98b0 'p'Exception caught: cleaning lookahead and stack +0xaaaac588c340->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xaaaac588c340, 0xffffd9be98b0 } +0xaaaac588c320->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xaaaac588c320, 0xffffd9be98b0 } +0xaaaac588c300->Object::~Object { 0xaaaac588c2e0, 0xaaaac588c300, 0xffffd9be98b0 } +0xaaaac588c2e0->Object::~Object { 0xaaaac588c2e0, 0xffffd9be98b0 } +0xffffd9be98b0->Object::~Object { 0xffffd9be98b0 } exception caught: printer end { } -error: invalid expression -./c++.at:1361: grep '^exception caught: printer$' stderr -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1362: grep '^exception caught: printer$' stderr stdout: exception caught: printer -./c++.at:1361: $PREPARSER ./input aaaae -stderr: -exception caught: syntax error -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1065: $PREPARSER ./input < in -stderr: -error: invalid character -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: $PREPARSER ./input aaaaE -stderr: -exception caught: syntax error, unexpected end of file, expecting 'a' -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS -./c++.at:1361: $PREPARSER ./input aaaaT -stderr: -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: $PREPARSER ./input aaaaR -stderr: -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./c++.at:857: $PREPARSER ./input -stderr: -./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./c++.at:851: $PREPARSER ./input -stderr: -./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./c++.at:941: $PREPARSER ./input -stderr: -syntax error -Discarding 'a'. -Reducing 'a'. -./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:941: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -stderr: -stdout: -./c++.at:1064: $PREPARSER ./input < in -stderr: -error: invalid expression -caught error -error: invalid character -caught error -./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1064: $PREPARSER ./input < in -stderr: -error: invalid expression -./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:941: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./c++.at:1064: $PREPARSER ./input < in -stderr: -error: invalid character -./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS -stderr: -stdout: -======== Testing with C++ standard flags: '' -./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./c++.at:1555: $PREPARSER ./test -stderr: -./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -stderr: -stdout: -./c++.at:1362: $PREPARSER ./input aaaas -stderr: -exception caught: reduction -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1362: $PREPARSER ./input aaaal -stderr: -exception caught: yylex -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1362: $PREPARSER ./input i -stderr: -exception caught: initial-action -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1362: $PREPARSER ./input aaaap +./c++.at:1362: $PREPARSER ./input aaaae stderr: -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1362: $PREPARSER ./input --debug aaaap +======== Testing with C++ standard flags: '' stderr: +./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS +exception caught: syntax error Starting parse Entering state 0 Stack now 0 Reading a token -0xfffff6539bc0->Object::Object { } -0xfffff6539ca0->Object::Object { 0xfffff6539bc0 } -0xfffff6539bc0->Object::~Object { 0xfffff6539bc0, 0xfffff6539ca0 } -Next token is token 'a' (0xfffff6539ca0 'a') -0xfffff6539c00->Object::Object { 0xfffff6539ca0 } -0xfffff6539bb0->Object::Object { 0xfffff6539c00, 0xfffff6539ca0 } -0xfffff6539bb0->Object::~Object { 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } -0xfffff6539ca0->Object::~Object { 0xfffff6539c00, 0xfffff6539ca0 } -Shifting token 'a' (0xfffff6539c00 'a') -0xaaaaf4b662e0->Object::Object { 0xfffff6539c00 } -0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xfffff6539c00 } -0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539b88, 0xfffff6539c00 } -0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539c00 } +0xaaaac4531f40->Object::Object { } +Next token is token 'a' (0xaaaac4531f40 'a') +Shifting token 'a' (0xaaaac4531f40 'a') Entering state 2 Stack now 0 2 -0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaf4b662e0 'a') --> $$ = nterm item (0xfffff6539cc0 'a') -0xaaaaf4b662e0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } -0xaaaaf4b662e0->Object::Object { 0xfffff6539cc0 } -0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } -0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539c70, 0xfffff6539cc0 } -0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac4531f40 'a') +-> $$ = nterm item (0xaaaac4531f40 'a') Entering state 11 Stack now 0 11 Reading a token -0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0 } -0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xfffff6539bc0 } -0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539bc0, 0xfffff6539ca0 } -Next token is token 'a' (0xfffff6539ca0 'a') -0xfffff6539c00->Object::Object { 0xaaaaf4b662e0, 0xfffff6539ca0 } -0xfffff6539bb0->Object::Object { 0xaaaaf4b662e0, 0xfffff6539c00, 0xfffff6539ca0 } -0xfffff6539bb0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } -0xfffff6539ca0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539c00, 0xfffff6539ca0 } -Shifting token 'a' (0xfffff6539c00 'a') -0xaaaaf4b66300->Object::Object { 0xaaaaf4b662e0, 0xfffff6539c00 } -0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00 } -0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539b88, 0xfffff6539c00 } -0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00 } +0xaaaac4531f90->Object::Object { 0xaaaac4531f40 } +Next token is token 'a' (0xaaaac4531f90 'a') +Shifting token 'a' (0xaaaac4531f90 'a') Entering state 2 Stack now 0 11 2 -0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaf4b66300 'a') --> $$ = nterm item (0xfffff6539cc0 'a') -0xaaaaf4b66300->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } -0xaaaaf4b66300->Object::Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } -0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } -0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c70, 0xfffff6539cc0 } -0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac4531f90 'a') +-> $$ = nterm item (0xaaaac4531f90 'a') Entering state 11 Stack now 0 11 11 Reading a token -0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300 } -0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539bc0 } -0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539bc0, 0xfffff6539ca0 } -Next token is token 'a' (0xfffff6539ca0 'a') -0xfffff6539c00->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539ca0 } -0xfffff6539bb0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00, 0xfffff6539ca0 } -0xfffff6539bb0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } -0xfffff6539ca0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00, 0xfffff6539ca0 } -Shifting token 'a' (0xfffff6539c00 'a') -0xaaaaf4b66320->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00 } -0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00 } -0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539b88, 0xfffff6539c00 } -0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00 } +0xaaaac4531fe0->Object::Object { 0xaaaac4531f40, 0xaaaac4531f90 } +Next token is token 'a' (0xaaaac4531fe0 'a') +Shifting token 'a' (0xaaaac4531fe0 'a') Entering state 2 Stack now 0 11 11 2 -0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaf4b66320 'a') --> $$ = nterm item (0xfffff6539cc0 'a') -0xaaaaf4b66320->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } -0xaaaaf4b66320->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } -0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } -0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c70, 0xfffff6539cc0 } -0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac4531fe0 'a') +-> $$ = nterm item (0xaaaac4531fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token -0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320 } -0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539bc0 } -0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539bc0, 0xfffff6539ca0 } -Next token is token 'a' (0xfffff6539ca0 'a') -0xfffff6539c00->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539ca0 } -0xfffff6539bb0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00, 0xfffff6539ca0 } -0xfffff6539bb0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } -0xfffff6539ca0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00, 0xfffff6539ca0 } -Shifting token 'a' (0xfffff6539c00 'a') -0xaaaaf4b66340->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00 } -0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539c00 } -0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539b88, 0xfffff6539c00 } -0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539c00 } +0xaaaac4532030->Object::Object { 0xaaaac4531f40, 0xaaaac4531f90, 0xaaaac4531fe0 } +Next token is token 'a' (0xaaaac4532030 'a') +Shifting token 'a' (0xaaaac4532030 'a') Entering state 2 Stack now 0 11 11 11 2 -0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaf4b66340 'a') --> $$ = nterm item (0xfffff6539cc0 'a') -0xaaaaf4b66340->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539cc0 } -0xaaaaf4b66340->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } -0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539cc0 } -0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539c70, 0xfffff6539cc0 } -0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539cc0 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac4532030 'a') +-> $$ = nterm item (0xaaaac4532030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token -0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340 } -0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539bc0 } -0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539bc0, 0xfffff6539ca0 } -Next token is token 'p' (0xfffff6539ca0 'p'Exception caught: cleaning lookahead and stack -0xaaaaf4b66340->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539ca0 } -0xaaaaf4b66320->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539ca0 } -0xaaaaf4b66300->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539ca0 } -0xaaaaf4b662e0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539ca0 } -0xfffff6539ca0->Object::~Object { 0xfffff6539ca0 } +0xaaaac4532080->Object::Object { 0xaaaac4531f40, 0xaaaac4531f90, 0xaaaac4531fe0, 0xaaaac4532030 } +Next token is token 'p' (0xaaaac4532080 'p'Exception caught: cleaning lookahead and stack +0xaaaac4532080->Object::~Object { 0xaaaac4531f40, 0xaaaac4531f90, 0xaaaac4531fe0, 0xaaaac4532030, 0xaaaac4532080 } +0xaaaac4532030->Object::~Object { 0xaaaac4531f40, 0xaaaac4531f90, 0xaaaac4531fe0, 0xaaaac4532030 } +0xaaaac4531fe0->Object::~Object { 0xaaaac4531f40, 0xaaaac4531f90, 0xaaaac4531fe0 } +0xaaaac4531f90->Object::~Object { 0xaaaac4531f40, 0xaaaac4531f90 } +0xaaaac4531f40->Object::~Object { 0xaaaac4531f40 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input i +./c++.at:1362: $PREPARSER ./input aaaaE +stderr: +exception caught: initial-action +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input aaaap +stderr: stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xfffff6539bc0->Object::Object { } -0xfffff6539ca0->Object::Object { 0xfffff6539bc0 } -0xfffff6539bc0->Object::~Object { 0xfffff6539bc0, 0xfffff6539ca0 } -Next token is token 'a' (0xfffff6539ca0 'a') -0xfffff6539c00->Object::Object { 0xfffff6539ca0 } -0xfffff6539bb0->Object::Object { 0xfffff6539c00, 0xfffff6539ca0 } -0xfffff6539bb0->Object::~Object { 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } -0xfffff6539ca0->Object::~Object { 0xfffff6539c00, 0xfffff6539ca0 } -Shifting token 'a' (0xfffff6539c00 'a') -0xaaaaf4b662e0->Object::Object { 0xfffff6539c00 } -0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xfffff6539c00 } -0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539b88, 0xfffff6539c00 } -0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539c00 } +0xaaaac4531f40->Object::Object { } +Next token is token 'a' (0xaaaac4531f40 'a') +Shifting token 'a' (0xaaaac4531f40 'a') Entering state 2 Stack now 0 2 -0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaf4b662e0 'a') --> $$ = nterm item (0xfffff6539cc0 'a') -0xaaaaf4b662e0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } -0xaaaaf4b662e0->Object::Object { 0xfffff6539cc0 } -0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } -0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539c70, 0xfffff6539cc0 } -0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac4531f40 'a') +-> $$ = nterm item (0xaaaac4531f40 'a') Entering state 11 Stack now 0 11 Reading a token -0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0 } -0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xfffff6539bc0 } -0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539bc0, 0xfffff6539ca0 } -Next token is token 'a' (0xfffff6539ca0 'a') -0xfffff6539c00->Object::Object { 0xaaaaf4b662e0, 0xfffff6539ca0 } -0xfffff6539bb0->Object::Object { 0xaaaaf4b662e0, 0xfffff6539c00, 0xfffff6539ca0 } -0xfffff6539bb0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } -0xfffff6539ca0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539c00, 0xfffff6539ca0 } -Shifting token 'a' (0xfffff6539c00 'a') -0xaaaaf4b66300->Object::Object { 0xaaaaf4b662e0, 0xfffff6539c00 } -0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00 } -0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539b88, 0xfffff6539c00 } -0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00 } +0xaaaac4531f90->Object::Object { 0xaaaac4531f40 } +Next token is token 'a' (0xaaaac4531f90 'a') +Shifting token 'a' (0xaaaac4531f90 'a') Entering state 2 Stack now 0 11 2 -0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaf4b66300 'a') --> $$ = nterm item (0xfffff6539cc0 'a') -0xaaaaf4b66300->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } -0xaaaaf4b66300->Object::Object { 0xaaaaf4b662e0, 0xfffff6539cc0 } -0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } -0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c70, 0xfffff6539cc0 } -0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac4531f90 'a') +-> $$ = nterm item (0xaaaac4531f90 'a') Entering state 11 Stack now 0 11 11 Reading a token -0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300 } -0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539bc0 } -0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539bc0, 0xfffff6539ca0 } -Next token is token 'a' (0xfffff6539ca0 'a') -0xfffff6539c00->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539ca0 } -0xfffff6539bb0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00, 0xfffff6539ca0 } -0xfffff6539bb0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } -0xfffff6539ca0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00, 0xfffff6539ca0 } -Shifting token 'a' (0xfffff6539c00 'a') -0xaaaaf4b66320->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539c00 } -0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00 } -0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539b88, 0xfffff6539c00 } -0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00 } +0xaaaac4531fe0->Object::Object { 0xaaaac4531f40, 0xaaaac4531f90 } +Next token is token 'a' (0xaaaac4531fe0 'a') +Shifting token 'a' (0xaaaac4531fe0 'a') Entering state 2 Stack now 0 11 11 2 -0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaf4b66320 'a') --> $$ = nterm item (0xfffff6539cc0 'a') -0xaaaaf4b66320->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } -0xaaaaf4b66320->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539cc0 } -0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } -0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c70, 0xfffff6539cc0 } -0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac4531fe0 'a') +-> $$ = nterm item (0xaaaac4531fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token -0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320 } -0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539bc0 } -0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539bc0, 0xfffff6539ca0 } -Next token is token 'a' (0xfffff6539ca0 'a') -0xfffff6539c00->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539ca0 } -0xfffff6539bb0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00, 0xfffff6539ca0 } -0xfffff6539bb0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539bb0, 0xfffff6539c00, 0xfffff6539ca0 } -0xfffff6539ca0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00, 0xfffff6539ca0 } -Shifting token 'a' (0xfffff6539c00 'a') -0xaaaaf4b66340->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539c00 } -0xfffff6539b88->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539c00 } -0xfffff6539b88->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539b88, 0xfffff6539c00 } -0xfffff6539c00->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539c00 } +0xaaaac4532030->Object::Object { 0xaaaac4531f40, 0xaaaac4531f90, 0xaaaac4531fe0 } +Next token is token 'a' (0xaaaac4532030 'a') +Shifting token 'a' (0xaaaac4532030 'a') Entering state 2 Stack now 0 11 11 11 2 -0xfffff6539cc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaf4b66340 'a') --> $$ = nterm item (0xfffff6539cc0 'a') -0xaaaaf4b66340->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539cc0 } -0xaaaaf4b66340->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539cc0 } -0xfffff6539c70->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539cc0 } -0xfffff6539c70->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539c70, 0xfffff6539cc0 } -0xfffff6539cc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539cc0 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac4532030 'a') +-> $$ = nterm item (0xaaaac4532030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token -0xfffff6539bc0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340 } -0xfffff6539ca0->Object::Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539bc0 } -0xfffff6539bc0->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539bc0, 0xfffff6539ca0 } -Next token is token 'p' (0xfffff6539ca0 'p'Exception caught: cleaning lookahead and stack -0xaaaaf4b66340->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xaaaaf4b66340, 0xfffff6539ca0 } -0xaaaaf4b66320->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xaaaaf4b66320, 0xfffff6539ca0 } -0xaaaaf4b66300->Object::~Object { 0xaaaaf4b662e0, 0xaaaaf4b66300, 0xfffff6539ca0 } -0xaaaaf4b662e0->Object::~Object { 0xaaaaf4b662e0, 0xfffff6539ca0 } -0xfffff6539ca0->Object::~Object { 0xfffff6539ca0 } +0xaaaac4532080->Object::Object { 0xaaaac4531f40, 0xaaaac4531f90, 0xaaaac4531fe0, 0xaaaac4532030 } +Next token is token 'p' (0xaaaac4532080 'p'Exception caught: cleaning lookahead and stack +0xaaaac4532080->Object::~Object { 0xaaaac4531f40, 0xaaaac4531f90, 0xaaaac4531fe0, 0xaaaac4532030, 0xaaaac4532080 } +0xaaaac4532030->Object::~Object { 0xaaaac4531f40, 0xaaaac4531f90, 0xaaaac4531fe0, 0xaaaac4532030 } +0xaaaac4531fe0->Object::~Object { 0xaaaac4531f40, 0xaaaac4531f90, 0xaaaac4531fe0 } +0xaaaac4531f90->Object::~Object { 0xaaaac4531f40, 0xaaaac4531f90 } +0xaaaac4531f40->Object::~Object { 0xaaaac4531f40 } exception caught: printer end { } -./c++.at:1362: grep '^exception caught: printer$' stderr -stdout: +exception caught: syntax error, unexpected end of file, expecting 'a' +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: grep '^exception caught: printer$' stderr +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: exception caught: printer -./c++.at:1362: $PREPARSER ./input aaaae -stderr: -./c++.at:1555: ./check -exception caught: syntax error -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr --std=c++98 not supported -======== Testing with C++ standard flags: '' -./c++.at:1362: $PREPARSER ./input aaaaE stderr: -exception caught: syntax error, unexpected end of file, expecting 'a' -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: $PREPARSER ./input aaaae +./c++.at:1361: $PREPARSER ./input --debug aaaap +./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +stdout: ./c++.at:1362: $PREPARSER ./input aaaaT -./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: +./c++.at:1463: sed -ne '/INCLUDED/p;/\\file/{p;n;p;}' include/ast/loc.hh +stderr: +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +0xaaab18c6ff40->Object::Object { } +Next token is token 'a' (0xaaab18c6ff40 'a') +Shifting token 'a' (0xaaab18c6ff40 'a') +Entering state 1 +Stack now 0 1 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaab18c6ff40 'a') +-> $$ = nterm item (0xaaab18c6ff40 'a') +Entering state 10 +Stack now 0 10 +Reading a token +0xaaab18c6ff90->Object::Object { 0xaaab18c6ff40 } +Next token is token 'a' (0xaaab18c6ff90 'a') +Shifting token 'a' (0xaaab18c6ff90 'a') +Entering state 1 +Stack now 0 10 1 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaab18c6ff90 'a') +-> $$ = nterm item (0xaaab18c6ff90 'a') +Entering state 10 +Stack now 0 10 10 +Reading a token +0xaaab18c6ffe0->Object::Object { 0xaaab18c6ff40, 0xaaab18c6ff90 } +Next token is token 'a' (0xaaab18c6ffe0 'a') +Shifting token 'a' (0xaaab18c6ffe0 'a') +Entering state 1 +Stack now 0 10 10 1 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaab18c6ffe0 'a') +-> $$ = nterm item (0xaaab18c6ffe0 'a') +Entering state 10 +Stack now 0 10 10 10 +Reading a token +0xaaab18c70030->Object::Object { 0xaaab18c6ff40, 0xaaab18c6ff90, 0xaaab18c6ffe0 } +Next token is token 'a' (0xaaab18c70030 'a') +Shifting token 'a' (0xaaab18c70030 'a') +Entering state 1 +Stack now 0 10 10 10 1 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaab18c70030 'a') +-> $$ = nterm item (0xaaab18c70030 'a') +Entering state 10 +Stack now 0 10 10 10 10 +Reading a token +0xaaab18c70080->Object::Object { 0xaaab18c6ff40, 0xaaab18c6ff90, 0xaaab18c6ffe0, 0xaaab18c70030 } +Next token is token 'p' (0xaaab18c70080 'p'Exception caught: cleaning lookahead and stack +0xaaab18c70080->Object::~Object { 0xaaab18c6ff40, 0xaaab18c6ff90, 0xaaab18c6ffe0, 0xaaab18c70030, 0xaaab18c70080 } +0xaaab18c70030->Object::~Object { 0xaaab18c6ff40, 0xaaab18c6ff90, 0xaaab18c6ffe0, 0xaaab18c70030 } +0xaaab18c6ffe0->Object::~Object { 0xaaab18c6ff40, 0xaaab18c6ff90, 0xaaab18c6ffe0 } +0xaaab18c6ff90->Object::~Object { 0xaaab18c6ff40, 0xaaab18c6ff90 } +0xaaab18c6ff40->Object::~Object { 0xaaab18c6ff40 } +exception caught: printer +end { } +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./c++.at:1471: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o x2.cc x2.yy ./c++.at:1362: $PREPARSER ./input aaaaR +./c++.at:1360: $PREPARSER ./input aaaaE +Starting parse +Entering state 0 +Stack now 0 +Reading a token +0xaaab18c6ff40->Object::Object { } +Next token is token 'a' (0xaaab18c6ff40 'a') +Shifting token 'a' (0xaaab18c6ff40 'a') +Entering state 1 +Stack now 0 1 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaab18c6ff40 'a') +-> $$ = nterm item (0xaaab18c6ff40 'a') +Entering state 10 +Stack now 0 10 +Reading a token +0xaaab18c6ff90->Object::Object { 0xaaab18c6ff40 } +Next token is token 'a' (0xaaab18c6ff90 'a') +Shifting token 'a' (0xaaab18c6ff90 'a') +Entering state 1 +Stack now 0 10 1 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaab18c6ff90 'a') +-> $$ = nterm item (0xaaab18c6ff90 'a') +Entering state 10 +Stack now 0 10 10 +Reading a token +0xaaab18c6ffe0->Object::Object { 0xaaab18c6ff40, 0xaaab18c6ff90 } +Next token is token 'a' (0xaaab18c6ffe0 'a') +Shifting token 'a' (0xaaab18c6ffe0 'a') +Entering state 1 +Stack now 0 10 10 1 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaab18c6ffe0 'a') +-> $$ = nterm item (0xaaab18c6ffe0 'a') +Entering state 10 +Stack now 0 10 10 10 +Reading a token +0xaaab18c70030->Object::Object { 0xaaab18c6ff40, 0xaaab18c6ff90, 0xaaab18c6ffe0 } +Next token is token 'a' (0xaaab18c70030 'a') +Shifting token 'a' (0xaaab18c70030 'a') +Entering state 1 +Stack now 0 10 10 10 1 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaab18c70030 'a') +-> $$ = nterm item (0xaaab18c70030 'a') +Entering state 10 +Stack now 0 10 10 10 10 +Reading a token +0xaaab18c70080->Object::Object { 0xaaab18c6ff40, 0xaaab18c6ff90, 0xaaab18c6ffe0, 0xaaab18c70030 } +Next token is token 'p' (0xaaab18c70080 'p'Exception caught: cleaning lookahead and stack +0xaaab18c70080->Object::~Object { 0xaaab18c6ff40, 0xaaab18c6ff90, 0xaaab18c6ffe0, 0xaaab18c70030, 0xaaab18c70080 } +0xaaab18c70030->Object::~Object { 0xaaab18c6ff40, 0xaaab18c6ff90, 0xaaab18c6ffe0, 0xaaab18c70030 } +0xaaab18c6ffe0->Object::~Object { 0xaaab18c6ff40, 0xaaab18c6ff90, 0xaaab18c6ffe0 } +0xaaab18c6ff90->Object::~Object { 0xaaab18c6ff40, 0xaaab18c6ff90 } +0xaaab18c6ff40->Object::~Object { 0xaaab18c6ff40 } +exception caught: printer +end { } +./c++.at:1361: grep '^exception caught: printer$' stderr +stderr: stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stdout: +exception caught: syntax error, unexpected end of file, expecting 'a' +exception caught: printer +stdout: +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input aaaae ======== Testing with C++ standard flags: '' +./c++.at:856: $PREPARSER ./input ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: +stderr: +exception caught: syntax error +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1471: $CXX $CPPFLAGS $CXXFLAGS -Iinclude -c -o x2.o x2.cc +./c++.at:1360: $PREPARSER ./input aaaaT +./c++.at:1361: $PREPARSER ./input aaaaE +stderr: +stderr: +exception caught: syntax error, unexpected end of file, expecting 'a' +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input aaaaT +./c++.at:1360: $PREPARSER ./input aaaaR +stderr: +stderr: +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input aaaaR +======== Testing with C++ standard flags: '' +stderr: +./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stderr: +stdout: +./c++.at:850: $PREPARSER ./input +stderr: +./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stderr: +stdout: +./c++.at:1501: $CXX $CPPFLAGS $CXXFLAGS -Iinclude $LDFLAGS -o parser x[12].o main.cc $LIBS +stderr: +stdout: +======== Testing with C++ standard flags: '' +./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stderr: +stdout: +./c++.at:856: $PREPARSER ./input +stderr: +./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stderr: stdout: ./c++.at:1363: $PREPARSER ./input aaaas stderr: @@ -254953,596 +254002,470 @@ stderr: exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: ./c++.at:1363: $PREPARSER ./input aaaap +stdout: +./c++.at:1064: $PREPARSER ./input < in +stderr: +error: invalid expression +caught error +error: invalid character +caught error +./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1064: $PREPARSER ./input < in stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -stdout: -./c++.at:1363: $PREPARSER ./input --debug aaaap -./c++.at:1360: $PREPARSER ./input aaaas +error: invalid expression +./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1064: $PREPARSER ./input < in stderr: +error: invalid character +./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xffffc989b1b0->Object::Object { } -0xffffc989b290->Object::Object { 0xffffc989b1b0 } -0xffffc989b1b0->Object::~Object { 0xffffc989b1b0, 0xffffc989b290 } -Next token is token 'a' (0xffffc989b290 'a') -0xffffc989b1f0->Object::Object { 0xffffc989b290 } -0xffffc989b1a0->Object::Object { 0xffffc989b1f0, 0xffffc989b290 } -0xffffc989b1a0->Object::~Object { 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } -0xffffc989b290->Object::~Object { 0xffffc989b1f0, 0xffffc989b290 } -Shifting token 'a' (0xffffc989b1f0 'a') -0xaaab093cb2e0->Object::Object { 0xffffc989b1f0 } -0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xffffc989b1f0 } -0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xffffc989b178, 0xffffc989b1f0 } -0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1f0 } +0xfffff6d941c0->Object::Object { } +0xfffff6d942a0->Object::Object { 0xfffff6d941c0 } +0xfffff6d941c0->Object::~Object { 0xfffff6d941c0, 0xfffff6d942a0 } +Next token is token 'a' (0xfffff6d942a0 'a') +0xfffff6d94200->Object::Object { 0xfffff6d942a0 } +0xfffff6d941b0->Object::Object { 0xfffff6d94200, 0xfffff6d942a0 } +0xfffff6d941b0->Object::~Object { 0xfffff6d941b0, 0xfffff6d94200, 0xfffff6d942a0 } +0xfffff6d942a0->Object::~Object { 0xfffff6d94200, 0xfffff6d942a0 } +Shifting token 'a' (0xfffff6d94200 'a') +0xaaab128012e0->Object::Object { 0xfffff6d94200 } +0xfffff6d94188->Object::Object { 0xaaab128012e0, 0xfffff6d94200 } +0xfffff6d94188->Object::~Object { 0xaaab128012e0, 0xfffff6d94188, 0xfffff6d94200 } +0xfffff6d94200->Object::~Object { 0xaaab128012e0, 0xfffff6d94200 } Entering state 1 Stack now 0 1 -0xffffc989b2b0->Object::Object { 0xaaab093cb2e0 } +0xfffff6d942c0->Object::Object { 0xaaab128012e0 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab093cb2e0 'a') --> $$ = nterm item (0xffffc989b2b0 'a') -0xaaab093cb2e0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b2b0 } -0xaaab093cb2e0->Object::Object { 0xffffc989b2b0 } -0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xffffc989b2b0 } -0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xffffc989b260, 0xffffc989b2b0 } -0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b2b0 } + $1 = token 'a' (0xaaab128012e0 'a') +-> $$ = nterm item (0xfffff6d942c0 'a') +0xaaab128012e0->Object::~Object { 0xaaab128012e0, 0xfffff6d942c0 } +0xaaab128012e0->Object::Object { 0xfffff6d942c0 } +0xfffff6d94270->Object::Object { 0xaaab128012e0, 0xfffff6d942c0 } +0xfffff6d94270->Object::~Object { 0xaaab128012e0, 0xfffff6d94270, 0xfffff6d942c0 } +0xfffff6d942c0->Object::~Object { 0xaaab128012e0, 0xfffff6d942c0 } Entering state 10 Stack now 0 10 Reading a token -0xffffc989b1b0->Object::Object { 0xaaab093cb2e0 } -0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xffffc989b1b0 } -0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1b0, 0xffffc989b290 } -Next token is token 'a' (0xffffc989b290 'a') -0xffffc989b1f0->Object::Object { 0xaaab093cb2e0, 0xffffc989b290 } -0xffffc989b1a0->Object::Object { 0xaaab093cb2e0, 0xffffc989b1f0, 0xffffc989b290 } -0xffffc989b1a0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } -0xffffc989b290->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1f0, 0xffffc989b290 } -Shifting token 'a' (0xffffc989b1f0 'a') -0xaaab093cb300->Object::Object { 0xaaab093cb2e0, 0xffffc989b1f0 } -0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0 } -0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b178, 0xffffc989b1f0 } -0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0 } +0xfffff6d941c0->Object::Object { 0xaaab128012e0 } +0xfffff6d942a0->Object::Object { 0xaaab128012e0, 0xfffff6d941c0 } +0xfffff6d941c0->Object::~Object { 0xaaab128012e0, 0xfffff6d941c0, 0xfffff6d942a0 } +Next token is token 'a' (0xfffff6d942a0 'a') +0xfffff6d94200->Object::Object { 0xaaab128012e0, 0xfffff6d942a0 } +0xfffff6d941b0->Object::Object { 0xaaab128012e0, 0xfffff6d94200, 0xfffff6d942a0 } +0xfffff6d941b0->Object::~Object { 0xaaab128012e0, 0xfffff6d941b0, 0xfffff6d94200, 0xfffff6d942a0 } +0xfffff6d942a0->Object::~Object { 0xaaab128012e0, 0xfffff6d94200, 0xfffff6d942a0 } +Shifting token 'a' (0xfffff6d94200 'a') +0xaaab12801300->Object::Object { 0xaaab128012e0, 0xfffff6d94200 } +0xfffff6d94188->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94200 } +0xfffff6d94188->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94188, 0xfffff6d94200 } +0xfffff6d94200->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94200 } Entering state 1 Stack now 0 10 1 -0xffffc989b2b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300 } +0xfffff6d942c0->Object::Object { 0xaaab128012e0, 0xaaab12801300 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab093cb300 'a') --> $$ = nterm item (0xffffc989b2b0 'a') -0xaaab093cb300->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } -0xaaab093cb300->Object::Object { 0xaaab093cb2e0, 0xffffc989b2b0 } -0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } -0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b260, 0xffffc989b2b0 } -0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } + $1 = token 'a' (0xaaab12801300 'a') +-> $$ = nterm item (0xfffff6d942c0 'a') +0xaaab12801300->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942c0 } +0xaaab12801300->Object::Object { 0xaaab128012e0, 0xfffff6d942c0 } +0xfffff6d94270->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942c0 } +0xfffff6d94270->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94270, 0xfffff6d942c0 } +0xfffff6d942c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942c0 } Entering state 10 Stack now 0 10 10 Reading a token -0xffffc989b1b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300 } -0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1b0 } -0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1b0, 0xffffc989b290 } -Next token is token 'a' (0xffffc989b290 'a') -0xffffc989b1f0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b290 } -0xffffc989b1a0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0, 0xffffc989b290 } -0xffffc989b1a0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } -0xffffc989b290->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0, 0xffffc989b290 } -Shifting token 'a' (0xffffc989b1f0 'a') -0xaaab093cb320->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0 } -0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0 } -0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b178, 0xffffc989b1f0 } -0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0 } +0xfffff6d941c0->Object::Object { 0xaaab128012e0, 0xaaab12801300 } +0xfffff6d942a0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d941c0 } +0xfffff6d941c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d941c0, 0xfffff6d942a0 } +Next token is token 'a' (0xfffff6d942a0 'a') +0xfffff6d94200->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942a0 } +0xfffff6d941b0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94200, 0xfffff6d942a0 } +0xfffff6d941b0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d941b0, 0xfffff6d94200, 0xfffff6d942a0 } +0xfffff6d942a0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94200, 0xfffff6d942a0 } +Shifting token 'a' (0xfffff6d94200 'a') +0xaaab12801320->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94200 } +0xfffff6d94188->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94200 } +0xfffff6d94188->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94188, 0xfffff6d94200 } +0xfffff6d94200->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94200 } Entering state 1 Stack now 0 10 10 1 -0xffffc989b2b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320 } +0xfffff6d942c0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab093cb320 'a') --> $$ = nterm item (0xffffc989b2b0 'a') -0xaaab093cb320->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } -0xaaab093cb320->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } -0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } -0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b260, 0xffffc989b2b0 } -0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } + $1 = token 'a' (0xaaab12801320 'a') +-> $$ = nterm item (0xfffff6d942c0 'a') +0xaaab12801320->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942c0 } +0xaaab12801320->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942c0 } +0xfffff6d94270->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942c0 } +0xfffff6d94270->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94270, 0xfffff6d942c0 } +0xfffff6d942c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942c0 } Entering state 10 Stack now 0 10 10 10 Reading a token -0xffffc989b1b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320 } -0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1b0 } -0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1b0, 0xffffc989b290 } -Next token is token 'a' (0xffffc989b290 'a') -0xffffc989b1f0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b290 } -0xffffc989b1a0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0, 0xffffc989b290 } -0xffffc989b1a0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } -0xffffc989b290->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0, 0xffffc989b290 } -Shifting token 'a' (0xffffc989b1f0 'a') -0xaaab093cb340->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0 } -0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1f0 } -0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b178, 0xffffc989b1f0 } -0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1f0 } +0xfffff6d941c0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320 } +0xfffff6d942a0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d941c0 } +0xfffff6d941c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d941c0, 0xfffff6d942a0 } +Next token is token 'a' (0xfffff6d942a0 'a') +0xfffff6d94200->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942a0 } +0xfffff6d941b0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94200, 0xfffff6d942a0 } +0xfffff6d941b0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d941b0, 0xfffff6d94200, 0xfffff6d942a0 } +0xfffff6d942a0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94200, 0xfffff6d942a0 } +Shifting token 'a' (0xfffff6d94200 'a') +0xaaab12801340->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94200 } +0xfffff6d94188->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d94200 } +0xfffff6d94188->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d94188, 0xfffff6d94200 } +0xfffff6d94200->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d94200 } Entering state 1 Stack now 0 10 10 10 1 -0xffffc989b2b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340 } +0xfffff6d942c0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab093cb340 'a') --> $$ = nterm item (0xffffc989b2b0 'a') -0xaaab093cb340->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b2b0 } -0xaaab093cb340->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } -0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b2b0 } -0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b260, 0xffffc989b2b0 } -0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b2b0 } + $1 = token 'a' (0xaaab12801340 'a') +-> $$ = nterm item (0xfffff6d942c0 'a') +0xaaab12801340->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d942c0 } +0xaaab12801340->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942c0 } +0xfffff6d94270->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d942c0 } +0xfffff6d94270->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d94270, 0xfffff6d942c0 } +0xfffff6d942c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d942c0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token -0xffffc989b1b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340 } -0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1b0 } -0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1b0, 0xffffc989b290 } -Next token is token 'p' (0xffffc989b290 'p'Exception caught: cleaning lookahead and stack -0xaaab093cb340->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b290 } -0xaaab093cb320->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b290 } -0xaaab093cb300->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b290 } -0xaaab093cb2e0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b290 } -0xffffc989b290->Object::~Object { 0xffffc989b290 } +0xfffff6d941c0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340 } +0xfffff6d942a0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d941c0 } +0xfffff6d941c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d941c0, 0xfffff6d942a0 } +Next token is token 'p' (0xfffff6d942a0 'p'Exception caught: cleaning lookahead and stack +0xaaab12801340->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d942a0 } +0xaaab12801320->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942a0 } +0xaaab12801300->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942a0 } +0xaaab128012e0->Object::~Object { 0xaaab128012e0, 0xfffff6d942a0 } +0xfffff6d942a0->Object::~Object { 0xfffff6d942a0 } exception caught: printer end { } ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -exception caught: reduction -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xffffc989b1b0->Object::Object { } -0xffffc989b290->Object::Object { 0xffffc989b1b0 } -0xffffc989b1b0->Object::~Object { 0xffffc989b1b0, 0xffffc989b290 } -Next token is token 'a' (0xffffc989b290 'a') -0xffffc989b1f0->Object::Object { 0xffffc989b290 } -0xffffc989b1a0->Object::Object { 0xffffc989b1f0, 0xffffc989b290 } -0xffffc989b1a0->Object::~Object { 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } -0xffffc989b290->Object::~Object { 0xffffc989b1f0, 0xffffc989b290 } -Shifting token 'a' (0xffffc989b1f0 'a') -0xaaab093cb2e0->Object::Object { 0xffffc989b1f0 } -0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xffffc989b1f0 } -0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xffffc989b178, 0xffffc989b1f0 } -0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1f0 } +0xfffff6d941c0->Object::Object { } +0xfffff6d942a0->Object::Object { 0xfffff6d941c0 } +0xfffff6d941c0->Object::~Object { 0xfffff6d941c0, 0xfffff6d942a0 } +Next token is token 'a' (0xfffff6d942a0 'a') +0xfffff6d94200->Object::Object { 0xfffff6d942a0 } +0xfffff6d941b0->Object::Object { 0xfffff6d94200, 0xfffff6d942a0 } +0xfffff6d941b0->Object::~Object { 0xfffff6d941b0, 0xfffff6d94200, 0xfffff6d942a0 } +0xfffff6d942a0->Object::~Object { 0xfffff6d94200, 0xfffff6d942a0 } +Shifting token 'a' (0xfffff6d94200 'a') +0xaaab128012e0->Object::Object { 0xfffff6d94200 } +0xfffff6d94188->Object::Object { 0xaaab128012e0, 0xfffff6d94200 } +0xfffff6d94188->Object::~Object { 0xaaab128012e0, 0xfffff6d94188, 0xfffff6d94200 } +0xfffff6d94200->Object::~Object { 0xaaab128012e0, 0xfffff6d94200 } Entering state 1 Stack now 0 1 -0xffffc989b2b0->Object::Object { 0xaaab093cb2e0 } +0xfffff6d942c0->Object::Object { 0xaaab128012e0 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab093cb2e0 'a') --> $$ = nterm item (0xffffc989b2b0 'a') -0xaaab093cb2e0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b2b0 } -0xaaab093cb2e0->Object::Object { 0xffffc989b2b0 } -0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xffffc989b2b0 } -0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xffffc989b260, 0xffffc989b2b0 } -0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b2b0 } + $1 = token 'a' (0xaaab128012e0 'a') +-> $$ = nterm item (0xfffff6d942c0 'a') +0xaaab128012e0->Object::~Object { 0xaaab128012e0, 0xfffff6d942c0 } +0xaaab128012e0->Object::Object { 0xfffff6d942c0 } +0xfffff6d94270->Object::Object { 0xaaab128012e0, 0xfffff6d942c0 } +0xfffff6d94270->Object::~Object { 0xaaab128012e0, 0xfffff6d94270, 0xfffff6d942c0 } +0xfffff6d942c0->Object::~Object { 0xaaab128012e0, 0xfffff6d942c0 } Entering state 10 Stack now 0 10 Reading a token -0xffffc989b1b0->Object::Object { 0xaaab093cb2e0 } -0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xffffc989b1b0 } -0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1b0, 0xffffc989b290 } -Next token is token 'a' (0xffffc989b290 'a') -0xffffc989b1f0->Object::Object { 0xaaab093cb2e0, 0xffffc989b290 } -0xffffc989b1a0->Object::Object { 0xaaab093cb2e0, 0xffffc989b1f0, 0xffffc989b290 } -0xffffc989b1a0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } -0xffffc989b290->Object::~Object { 0xaaab093cb2e0, 0xffffc989b1f0, 0xffffc989b290 } -Shifting token 'a' (0xffffc989b1f0 'a') -0xaaab093cb300->Object::Object { 0xaaab093cb2e0, 0xffffc989b1f0 } -0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0 } -0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b178, 0xffffc989b1f0 } -0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0 } +0xfffff6d941c0->Object::Object { 0xaaab128012e0 } +0xfffff6d942a0->Object::Object { 0xaaab128012e0, 0xfffff6d941c0 } +0xfffff6d941c0->Object::~Object { 0xaaab128012e0, 0xfffff6d941c0, 0xfffff6d942a0 } +Next token is token 'a' (0xfffff6d942a0 'a') +0xfffff6d94200->Object::Object { 0xaaab128012e0, 0xfffff6d942a0 } +0xfffff6d941b0->Object::Object { 0xaaab128012e0, 0xfffff6d94200, 0xfffff6d942a0 } +0xfffff6d941b0->Object::~Object { 0xaaab128012e0, 0xfffff6d941b0, 0xfffff6d94200, 0xfffff6d942a0 } +0xfffff6d942a0->Object::~Object { 0xaaab128012e0, 0xfffff6d94200, 0xfffff6d942a0 } +Shifting token 'a' (0xfffff6d94200 'a') +0xaaab12801300->Object::Object { 0xaaab128012e0, 0xfffff6d94200 } +0xfffff6d94188->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94200 } +0xfffff6d94188->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94188, 0xfffff6d94200 } +0xfffff6d94200->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94200 } Entering state 1 Stack now 0 10 1 -0xffffc989b2b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300 } +0xfffff6d942c0->Object::Object { 0xaaab128012e0, 0xaaab12801300 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab093cb300 'a') --> $$ = nterm item (0xffffc989b2b0 'a') -0xaaab093cb300->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } -0xaaab093cb300->Object::Object { 0xaaab093cb2e0, 0xffffc989b2b0 } -0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } -0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b260, 0xffffc989b2b0 } -0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } + $1 = token 'a' (0xaaab12801300 'a') +-> $$ = nterm item (0xfffff6d942c0 'a') +0xaaab12801300->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942c0 } +0xaaab12801300->Object::Object { 0xaaab128012e0, 0xfffff6d942c0 } +0xfffff6d94270->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942c0 } +0xfffff6d94270->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94270, 0xfffff6d942c0 } +0xfffff6d942c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942c0 } Entering state 10 Stack now 0 10 10 Reading a token -0xffffc989b1b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300 } -0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1b0 } -0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1b0, 0xffffc989b290 } -Next token is token 'a' (0xffffc989b290 'a') -0xffffc989b1f0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b290 } -0xffffc989b1a0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0, 0xffffc989b290 } -0xffffc989b1a0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } -0xffffc989b290->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0, 0xffffc989b290 } -Shifting token 'a' (0xffffc989b1f0 'a') -0xaaab093cb320->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b1f0 } -0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0 } -0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b178, 0xffffc989b1f0 } -0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0 } +0xfffff6d941c0->Object::Object { 0xaaab128012e0, 0xaaab12801300 } +0xfffff6d942a0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d941c0 } +0xfffff6d941c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d941c0, 0xfffff6d942a0 } +Next token is token 'a' (0xfffff6d942a0 'a') +0xfffff6d94200->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942a0 } +0xfffff6d941b0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94200, 0xfffff6d942a0 } +0xfffff6d941b0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d941b0, 0xfffff6d94200, 0xfffff6d942a0 } +0xfffff6d942a0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94200, 0xfffff6d942a0 } +Shifting token 'a' (0xfffff6d94200 'a') +0xaaab12801320->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d94200 } +0xfffff6d94188->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94200 } +0xfffff6d94188->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94188, 0xfffff6d94200 } +0xfffff6d94200->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94200 } Entering state 1 Stack now 0 10 10 1 -0xffffc989b2b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320 } +0xfffff6d942c0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab093cb320 'a') --> $$ = nterm item (0xffffc989b2b0 'a') -0xaaab093cb320->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } -0xaaab093cb320->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b2b0 } -0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } -0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b260, 0xffffc989b2b0 } -0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } + $1 = token 'a' (0xaaab12801320 'a') +-> $$ = nterm item (0xfffff6d942c0 'a') +0xaaab12801320->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942c0 } +0xaaab12801320->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942c0 } +0xfffff6d94270->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942c0 } +0xfffff6d94270->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94270, 0xfffff6d942c0 } +0xfffff6d942c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942c0 } Entering state 10 Stack now 0 10 10 10 Reading a token -0xffffc989b1b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320 } -0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1b0 } -0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1b0, 0xffffc989b290 } -Next token is token 'a' (0xffffc989b290 'a') -0xffffc989b1f0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b290 } -0xffffc989b1a0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0, 0xffffc989b290 } -0xffffc989b1a0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1a0, 0xffffc989b1f0, 0xffffc989b290 } -0xffffc989b290->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0, 0xffffc989b290 } -Shifting token 'a' (0xffffc989b1f0 'a') -0xaaab093cb340->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b1f0 } -0xffffc989b178->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1f0 } -0xffffc989b178->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b178, 0xffffc989b1f0 } -0xffffc989b1f0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1f0 } +0xfffff6d941c0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320 } +0xfffff6d942a0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d941c0 } +0xfffff6d941c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d941c0, 0xfffff6d942a0 } +Next token is token 'a' (0xfffff6d942a0 'a') +0xfffff6d94200->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942a0 } +0xfffff6d941b0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94200, 0xfffff6d942a0 } +0xfffff6d941b0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d941b0, 0xfffff6d94200, 0xfffff6d942a0 } +0xfffff6d942a0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94200, 0xfffff6d942a0 } +Shifting token 'a' (0xfffff6d94200 'a') +0xaaab12801340->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d94200 } +0xfffff6d94188->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d94200 } +0xfffff6d94188->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d94188, 0xfffff6d94200 } +0xfffff6d94200->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d94200 } Entering state 1 Stack now 0 10 10 10 1 -0xffffc989b2b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340 } +0xfffff6d942c0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab093cb340 'a') --> $$ = nterm item (0xffffc989b2b0 'a') -0xaaab093cb340->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b2b0 } -0xaaab093cb340->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b2b0 } -0xffffc989b260->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b2b0 } -0xffffc989b260->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b260, 0xffffc989b2b0 } -0xffffc989b2b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b2b0 } + $1 = token 'a' (0xaaab12801340 'a') +-> $$ = nterm item (0xfffff6d942c0 'a') +0xaaab12801340->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d942c0 } +0xaaab12801340->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942c0 } +0xfffff6d94270->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d942c0 } +0xfffff6d94270->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d94270, 0xfffff6d942c0 } +0xfffff6d942c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d942c0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token -0xffffc989b1b0->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340 } -0xffffc989b290->Object::Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1b0 } -0xffffc989b1b0->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b1b0, 0xffffc989b290 } -Next token is token 'p' (0xffffc989b290 'p'Exception caught: cleaning lookahead and stack -0xaaab093cb340->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xaaab093cb340, 0xffffc989b290 } -0xaaab093cb320->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xaaab093cb320, 0xffffc989b290 } -0xaaab093cb300->Object::~Object { 0xaaab093cb2e0, 0xaaab093cb300, 0xffffc989b290 } -0xaaab093cb2e0->Object::~Object { 0xaaab093cb2e0, 0xffffc989b290 } -0xffffc989b290->Object::~Object { 0xffffc989b290 } +0xfffff6d941c0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340 } +0xfffff6d942a0->Object::Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d941c0 } +0xfffff6d941c0->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d941c0, 0xfffff6d942a0 } +Next token is token 'p' (0xfffff6d942a0 'p'Exception caught: cleaning lookahead and stack +0xaaab12801340->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xaaab12801340, 0xfffff6d942a0 } +0xaaab12801320->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xaaab12801320, 0xfffff6d942a0 } +0xaaab12801300->Object::~Object { 0xaaab128012e0, 0xaaab12801300, 0xfffff6d942a0 } +0xaaab128012e0->Object::~Object { 0xaaab128012e0, 0xfffff6d942a0 } +0xfffff6d942a0->Object::~Object { 0xfffff6d942a0 } exception caught: printer end { } ./c++.at:1363: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1363: $PREPARSER ./input aaaae -./c++.at:1360: $PREPARSER ./input aaaal stderr: -stderr: -stderr: -exception caught: yylex -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: ./c++.at:1363: $PREPARSER ./input aaaaE stdout: stderr: -./c++.at:1360: $PREPARSER ./input i +./c++.at:1065: $PREPARSER ./input < in exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -exception caught: initial-action -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +error: invalid expression +caught error +error: invalid character +caught error +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaT -./c++.at:1555: ./check stderr: -./c++.at:1360: $PREPARSER ./input aaaap ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1065: $PREPARSER ./input < in stderr: ./c++.at:1363: $PREPARSER ./input aaaaR -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +error: invalid expression stderr: +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr --std=c++03 not supported -======== Testing with C++ standard flags: '' -./c++.at:1360: $PREPARSER ./input --debug aaaap -./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -======== Testing with C++ standard flags: '' -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -0xaaaae5ef1f40->Object::Object { } -Next token is token 'a' (0xaaaae5ef1f40 'a') -Shifting token 'a' (0xaaaae5ef1f40 'a') -Entering state 2 -Stack now 0 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae5ef1f40 'a') --> $$ = nterm item (0xaaaae5ef1f40 'a') -Entering state 11 -Stack now 0 11 -Reading a token -0xaaaae5ef1f90->Object::Object { 0xaaaae5ef1f40 } -Next token is token 'a' (0xaaaae5ef1f90 'a') -Shifting token 'a' (0xaaaae5ef1f90 'a') -Entering state 2 -Stack now 0 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae5ef1f90 'a') --> $$ = nterm item (0xaaaae5ef1f90 'a') -Entering state 11 -Stack now 0 11 11 -Reading a token -0xaaaae5ef1fe0->Object::Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90 } -Next token is token 'a' (0xaaaae5ef1fe0 'a') -Shifting token 'a' (0xaaaae5ef1fe0 'a') -Entering state 2 -Stack now 0 11 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae5ef1fe0 'a') --> $$ = nterm item (0xaaaae5ef1fe0 'a') -Entering state 11 -Stack now 0 11 11 11 -Reading a token -0xaaaae5ef2030->Object::Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0 } -Next token is token 'a' (0xaaaae5ef2030 'a') -Shifting token 'a' (0xaaaae5ef2030 'a') -Entering state 2 -Stack now 0 11 11 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae5ef2030 'a') --> $$ = nterm item (0xaaaae5ef2030 'a') -Entering state 11 -Stack now 0 11 11 11 11 -Reading a token -0xaaaae5ef2080->Object::Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0, 0xaaaae5ef2030 } -Next token is token 'p' (0xaaaae5ef2080 'p'Exception caught: cleaning lookahead and stack -0xaaaae5ef2080->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0, 0xaaaae5ef2030, 0xaaaae5ef2080 } -0xaaaae5ef2030->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0, 0xaaaae5ef2030 } -0xaaaae5ef1fe0->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0 } -0xaaaae5ef1f90->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90 } -0xaaaae5ef1f40->Object::~Object { 0xaaaae5ef1f40 } -exception caught: printer -end { } -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -0xaaaae5ef1f40->Object::Object { } -Next token is token 'a' (0xaaaae5ef1f40 'a') -Shifting token 'a' (0xaaaae5ef1f40 'a') -Entering state 2 -Stack now 0 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae5ef1f40 'a') --> $$ = nterm item (0xaaaae5ef1f40 'a') -Entering state 11 -Stack now 0 11 -Reading a token -0xaaaae5ef1f90->Object::Object { 0xaaaae5ef1f40 } -Next token is token 'a' (0xaaaae5ef1f90 'a') -Shifting token 'a' (0xaaaae5ef1f90 'a') -Entering state 2 -Stack now 0 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae5ef1f90 'a') --> $$ = nterm item (0xaaaae5ef1f90 'a') -Entering state 11 -Stack now 0 11 11 -Reading a token -0xaaaae5ef1fe0->Object::Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90 } -Next token is token 'a' (0xaaaae5ef1fe0 'a') -Shifting token 'a' (0xaaaae5ef1fe0 'a') -Entering state 2 -Stack now 0 11 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae5ef1fe0 'a') --> $$ = nterm item (0xaaaae5ef1fe0 'a') -Entering state 11 -Stack now 0 11 11 11 -Reading a token -0xaaaae5ef2030->Object::Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0 } -Next token is token 'a' (0xaaaae5ef2030 'a') -Shifting token 'a' (0xaaaae5ef2030 'a') -Entering state 2 -Stack now 0 11 11 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae5ef2030 'a') --> $$ = nterm item (0xaaaae5ef2030 'a') -Entering state 11 -Stack now 0 11 11 11 11 -Reading a token -0xaaaae5ef2080->Object::Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0, 0xaaaae5ef2030 } -Next token is token 'p' (0xaaaae5ef2080 'p'Exception caught: cleaning lookahead and stack -0xaaaae5ef2080->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0, 0xaaaae5ef2030, 0xaaaae5ef2080 } -0xaaaae5ef2030->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0, 0xaaaae5ef2030 } -0xaaaae5ef1fe0->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90, 0xaaaae5ef1fe0 } -0xaaaae5ef1f90->Object::~Object { 0xaaaae5ef1f40, 0xaaaae5ef1f90 } -0xaaaae5ef1f40->Object::~Object { 0xaaaae5ef1f40 } -exception caught: printer -end { } -./c++.at:1360: grep '^exception caught: printer$' stderr -./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stdout: -exception caught: printer -./c++.at:1360: $PREPARSER ./input aaaae -stderr: -exception caught: syntax error -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input aaaaE -stderr: -exception caught: syntax error, unexpected end of file, expecting 'a' -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input aaaaT -stderr: -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input aaaaR -stderr: -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -======== Testing with C++ standard flags: '' -stdout: -./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stdout: -./c++.at:851: $PREPARSER ./input -./c++.at:1555: ./check -stderr: --std=c++11 not supported -======== Testing with C++ standard flags: '' -./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -======== Testing with C++ standard flags: '' -./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./c++.at:1555: ./check -./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y -stderr: -stdout: -./c++.at:857: $PREPARSER ./input -stderr: -./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ======== Testing with C++ standard flags: '' -./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: +./c++.at:1065: $PREPARSER ./input < in stdout: +./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1361: $PREPARSER ./input aaaas stderr: +stderr: +error: invalid character +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: reduction ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' ./c++.at:1361: $PREPARSER ./input aaaal +./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: exception caught: yylex ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +stdout: ./c++.at:1361: $PREPARSER ./input i +stdout: +./c++.at:1502: $PREPARSER ./parser +./c++.at:1555: $PREPARSER ./test +stderr: stderr: exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./c++.at:1502: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaap +690. c++.at:1422: ok +======== Testing with C++ standard flags: '' stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stderr: ./c++.at:1361: $PREPARSER ./input --debug aaaap +stdout: +./c++.at:850: $PREPARSER ./input +stderr: stderr: +./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:850: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS Starting parse Entering state 0 Stack now 0 Reading a token -0xaaaadaf72f40->Object::Object { } -Next token is token 'a' (0xaaaadaf72f40 'a') -Shifting token 'a' (0xaaaadaf72f40 'a') +0xaaab08058f40->Object::Object { } +Next token is token 'a' (0xaaab08058f40 'a') +Shifting token 'a' (0xaaab08058f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadaf72f40 'a') --> $$ = nterm item (0xaaaadaf72f40 'a') + $1 = token 'a' (0xaaab08058f40 'a') +-> $$ = nterm item (0xaaab08058f40 'a') Entering state 10 Stack now 0 10 Reading a token -0xaaaadaf72f90->Object::Object { 0xaaaadaf72f40 } -Next token is token 'a' (0xaaaadaf72f90 'a') -Shifting token 'a' (0xaaaadaf72f90 'a') +0xaaab08058f90->Object::Object { 0xaaab08058f40 } +Next token is token 'a' (0xaaab08058f90 'a') +Shifting token 'a' (0xaaab08058f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadaf72f90 'a') --> $$ = nterm item (0xaaaadaf72f90 'a') + $1 = token 'a' (0xaaab08058f90 'a') +-> $$ = nterm item (0xaaab08058f90 'a') Entering state 10 Stack now 0 10 10 Reading a token -0xaaaadaf72fe0->Object::Object { 0xaaaadaf72f40, 0xaaaadaf72f90 } -Next token is token 'a' (0xaaaadaf72fe0 'a') -Shifting token 'a' (0xaaaadaf72fe0 'a') +0xaaab08058fe0->Object::Object { 0xaaab08058f40, 0xaaab08058f90 } +Next token is token 'a' (0xaaab08058fe0 'a') +Shifting token 'a' (0xaaab08058fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadaf72fe0 'a') --> $$ = nterm item (0xaaaadaf72fe0 'a') + $1 = token 'a' (0xaaab08058fe0 'a') +-> $$ = nterm item (0xaaab08058fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token -0xaaaadaf73030->Object::Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0 } -Next token is token 'a' (0xaaaadaf73030 'a') -Shifting token 'a' (0xaaaadaf73030 'a') +0xaaab08059030->Object::Object { 0xaaab08058f40, 0xaaab08058f90, 0xaaab08058fe0 } +Next token is token 'a' (0xaaab08059030 'a') +Shifting token 'a' (0xaaab08059030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadaf73030 'a') --> $$ = nterm item (0xaaaadaf73030 'a') + $1 = token 'a' (0xaaab08059030 'a') +-> $$ = nterm item (0xaaab08059030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token -0xaaaadaf73080->Object::Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0, 0xaaaadaf73030 } -Next token is token 'p' (0xaaaadaf73080 'p'Exception caught: cleaning lookahead and stack -0xaaaadaf73080->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0, 0xaaaadaf73030, 0xaaaadaf73080 } -0xaaaadaf73030->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0, 0xaaaadaf73030 } -0xaaaadaf72fe0->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0 } -0xaaaadaf72f90->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90 } -0xaaaadaf72f40->Object::~Object { 0xaaaadaf72f40 } +0xaaab08059080->Object::Object { 0xaaab08058f40, 0xaaab08058f90, 0xaaab08058fe0, 0xaaab08059030 } +Next token is token 'p' (0xaaab08059080 'p'Exception caught: cleaning lookahead and stack +0xaaab08059080->Object::~Object { 0xaaab08058f40, 0xaaab08058f90, 0xaaab08058fe0, 0xaaab08059030, 0xaaab08059080 } +0xaaab08059030->Object::~Object { 0xaaab08058f40, 0xaaab08058f90, 0xaaab08058fe0, 0xaaab08059030 } +0xaaab08058fe0->Object::~Object { 0xaaab08058f40, 0xaaab08058f90, 0xaaab08058fe0 } +0xaaab08058f90->Object::~Object { 0xaaab08058f40, 0xaaab08058f90 } +0xaaab08058f40->Object::~Object { 0xaaab08058f40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xaaaadaf72f40->Object::Object { } -Next token is token 'a' (0xaaaadaf72f40 'a') -Shifting token 'a' (0xaaaadaf72f40 'a') +0xaaab08058f40->Object::Object { } +Next token is token 'a' (0xaaab08058f40 'a') +Shifting token 'a' (0xaaab08058f40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadaf72f40 'a') --> $$ = nterm item (0xaaaadaf72f40 'a') + $1 = token 'a' (0xaaab08058f40 'a') +-> $$ = nterm item (0xaaab08058f40 'a') Entering state 10 Stack now 0 10 Reading a token -0xaaaadaf72f90->Object::Object { 0xaaaadaf72f40 } -Next token is token 'a' (0xaaaadaf72f90 'a') -Shifting token 'a' (0xaaaadaf72f90 'a') +0xaaab08058f90->Object::Object { 0xaaab08058f40 } +Next token is token 'a' (0xaaab08058f90 'a') +Shifting token 'a' (0xaaab08058f90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadaf72f90 'a') --> $$ = nterm item (0xaaaadaf72f90 'a') + $1 = token 'a' (0xaaab08058f90 'a') +-> $$ = nterm item (0xaaab08058f90 'a') Entering state 10 Stack now 0 10 10 Reading a token -0xaaaadaf72fe0->Object::Object { 0xaaaadaf72f40, 0xaaaadaf72f90 } -Next token is token 'a' (0xaaaadaf72fe0 'a') -Shifting token 'a' (0xaaaadaf72fe0 'a') +0xaaab08058fe0->Object::Object { 0xaaab08058f40, 0xaaab08058f90 } +Next token is token 'a' (0xaaab08058fe0 'a') +Shifting token 'a' (0xaaab08058fe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadaf72fe0 'a') --> $$ = nterm item (0xaaaadaf72fe0 'a') + $1 = token 'a' (0xaaab08058fe0 'a') +-> $$ = nterm item (0xaaab08058fe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token -0xaaaadaf73030->Object::Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0 } -Next token is token 'a' (0xaaaadaf73030 'a') -Shifting token 'a' (0xaaaadaf73030 'a') +0xaaab08059030->Object::Object { 0xaaab08058f40, 0xaaab08058f90, 0xaaab08058fe0 } +Next token is token 'a' (0xaaab08059030 'a') +Shifting token 'a' (0xaaab08059030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadaf73030 'a') --> $$ = nterm item (0xaaaadaf73030 'a') + $1 = token 'a' (0xaaab08059030 'a') +-> $$ = nterm item (0xaaab08059030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token -0xaaaadaf73080->Object::Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0, 0xaaaadaf73030 } -Next token is token 'p' (0xaaaadaf73080 'p'Exception caught: cleaning lookahead and stack -0xaaaadaf73080->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0, 0xaaaadaf73030, 0xaaaadaf73080 } -0xaaaadaf73030->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0, 0xaaaadaf73030 } -0xaaaadaf72fe0->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90, 0xaaaadaf72fe0 } -0xaaaadaf72f90->Object::~Object { 0xaaaadaf72f40, 0xaaaadaf72f90 } -0xaaaadaf72f40->Object::~Object { 0xaaaadaf72f40 } +0xaaab08059080->Object::Object { 0xaaab08058f40, 0xaaab08058f90, 0xaaab08058fe0, 0xaaab08059030 } +Next token is token 'p' (0xaaab08059080 'p'Exception caught: cleaning lookahead and stack +0xaaab08059080->Object::~Object { 0xaaab08058f40, 0xaaab08058f90, 0xaaab08058fe0, 0xaaab08059030, 0xaaab08059080 } +0xaaab08059030->Object::~Object { 0xaaab08058f40, 0xaaab08058f90, 0xaaab08058fe0, 0xaaab08059030 } +0xaaab08058fe0->Object::~Object { 0xaaab08058f40, 0xaaab08058f90, 0xaaab08058fe0 } +0xaaab08058f90->Object::~Object { 0xaaab08058f40, 0xaaab08058f90 } +0xaaab08058f40->Object::~Object { 0xaaab08058f40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr @@ -255550,1613 +254473,1976 @@ exception caught: printer ./c++.at:1361: $PREPARSER ./input aaaae stderr: +stderr: exception caught: syntax error +stdout: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1555: ./check +-std=c++98 not supported +======== Testing with C++ standard flags: '' +692. java.at:25: testing Java invalid directives ... +./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./java.at:35: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret YYParser.y ./c++.at:1361: $PREPARSER ./input aaaaE stderr: stderr: -exception caught: syntax error, unexpected end of file, expecting 'a' -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: $PREPARSER ./input aaaaT -stderr: stdout: +exception caught: syntax error, unexpected end of file, expecting 'a' +./c++.at:1066: $PREPARSER ./input < in ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: $PREPARSER ./input aaaaR -./c++.at:1065: $PREPARSER ./input < in -stderr: -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' stderr: -./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS error: invalid expression caught error error: invalid character caught error -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input aaaaT +./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./c++.at:1066: $PREPARSER ./input < in +./c++.at:1361: $PREPARSER ./input aaaaR stdout: -./c++.at:1065: $PREPARSER ./input < in -======== Testing with C++ standard flags: '' -./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: -error: invalid expression -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1065: $PREPARSER ./input < in stderr: -error: invalid character -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS +./c++.at:1555: ./check stderr: +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: -./c++.at:1066: $PREPARSER ./input < in -stderr: -error: invalid expression -caught error -error: invalid character -caught error -./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1066: $PREPARSER ./input < in -stderr: +-std=c++03 not supported +======== Testing with C++ standard flags: '' +./java.at:50: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret YYParser.y error: invalid expression ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +======== Testing with C++ standard flags: '' +./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid character ./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: -./c++.at:941: $PREPARSER ./input -stderr: -syntax error -Discarding 'a'. -Reducing 'a'. -./c++.at:941: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -681. c++.at:884: ok +692. java.at:25: ok ./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS - -692. java.at:25: testing Java invalid directives ... -./java.at:35: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret YYParser.y -stderr: -stdout: stderr: stdout: -./c++.at:1066: ./check -./java.at:50: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -fcaret YYParser.y -./c++.at:851: $PREPARSER ./input +./c++.at:1555: ./check stderr: -./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS -./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +-std=c++11 not supported ======== Testing with C++ standard flags: '' -./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -692. java.at:25: ok +stdout: +./c++.at:1360: $PREPARSER ./input aaaas +./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stderr: +exception caught: reduction +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./c++.at:1360: $PREPARSER ./input aaaal stdout: ./c++.at:1362: $PREPARSER ./input aaaas stderr: +stderr: exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +stderr: +exception caught: yylex +./c++.at:1066: ./check +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +693. java.at:186: testing Java parser class and package names ... +./java.at:188: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y ./c++.at:1362: $PREPARSER ./input aaaal stderr: +./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1362: $PREPARSER ./input i -stderr: -stdout: +./c++.at:1360: $PREPARSER ./input i stderr: stderr: -./c++.at:857: $PREPARSER ./input exception caught: initial-action -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: -693. java.at:186: testing Java parser class and package names ... -stderr: -./java.at:188: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y +./c++.at:1362: $PREPARSER ./input i +./c++.at:1555: ./check stderr: -./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./java.at:188: grep '[mb]4_' YYParser.y +./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y +./c++.at:1360: $PREPARSER ./input aaaap stdout: -./c++.at:1555: $PREPARSER ./test -./c++.at:1360: $PREPARSER ./input aaaas -stderr: -./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:1362: $PREPARSER ./input aaaap -stderr: +exception caught: initial-action +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -exception caught: reduction -./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:1362: $PREPARSER ./input --debug aaaap -./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./c++.at:1360: $PREPARSER ./input aaaal -./java.at:188: grep '[mb]4_' YYParser.y +693. java.at:186: ./c++.at:1360: $PREPARSER ./input --debug aaaap + skipped (java.at:188) +./c++.at:1362: $PREPARSER ./input aaaap stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xffffcf641fd0->Object::Object { } -0xffffcf642080->Object::Object { 0xffffcf641fd0 } -0xffffcf641fd0->Object::~Object { 0xffffcf641fd0, 0xffffcf642080 } -Next token is token 'a' (0xffffcf642080 'a') -0xffffcf641fc0->Object::Object { 0xffffcf642080 } -0xffffcf642080->Object::~Object { 0xffffcf641fc0, 0xffffcf642080 } -Shifting token 'a' (0xffffcf641fc0 'a') -0xaaab09e922e0->Object::Object { 0xffffcf641fc0 } -0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xffffcf641fc0 } +0xaaaaf0d03f40->Object::Object { } +Next token is token 'a' (0xaaaaf0d03f40 'a') +Shifting token 'a' (0xaaaaf0d03f40 'a') Entering state 2 Stack now 0 2 -0xffffcf6420a0->Object::Object { 0xaaab09e922e0 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab09e922e0 'a') --> $$ = nterm item (0xffffcf6420a0 'a') -0xaaab09e922e0->Object::~Object { 0xaaab09e922e0, 0xffffcf6420a0 } -0xaaab09e922e0->Object::Object { 0xffffcf6420a0 } -0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xffffcf6420a0 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaaf0d03f40 'a') +-> $$ = nterm item (0xaaaaf0d03f40 'a') Entering state 11 Stack now 0 11 Reading a token -0xffffcf641fd0->Object::Object { 0xaaab09e922e0 } -0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xffffcf641fd0 } -0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xffffcf641fd0, 0xffffcf642080 } -Next token is token 'a' (0xffffcf642080 'a') -0xffffcf641fc0->Object::Object { 0xaaab09e922e0, 0xffffcf642080 } -0xffffcf642080->Object::~Object { 0xaaab09e922e0, 0xffffcf641fc0, 0xffffcf642080 } -Shifting token 'a' (0xffffcf641fc0 'a') -0xaaab09e92300->Object::Object { 0xaaab09e922e0, 0xffffcf641fc0 } -0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fc0 } +0xaaaaf0d03f90->Object::Object { 0xaaaaf0d03f40 } +Next token is token 'a' (0xaaaaf0d03f90 'a') +Shifting token 'a' (0xaaaaf0d03f90 'a') Entering state 2 Stack now 0 11 2 -0xffffcf6420a0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab09e92300 'a') --> $$ = nterm item (0xffffcf6420a0 'a') -0xaaab09e92300->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf6420a0 } -0xaaab09e92300->Object::Object { 0xaaab09e922e0, 0xffffcf6420a0 } -0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf6420a0 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaaf0d03f90 'a') +-> $$ = nterm item (0xaaaaf0d03f90 'a') Entering state 11 Stack now 0 11 11 Reading a token -0xffffcf641fd0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300 } -0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fd0 } -0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fd0, 0xffffcf642080 } -Next token is token 'a' (0xffffcf642080 'a') -0xffffcf641fc0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf642080 } -0xffffcf642080->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fc0, 0xffffcf642080 } -Shifting token 'a' (0xffffcf641fc0 'a') -0xaaab09e92320->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fc0 } -0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fc0 } +0xaaaaf0d03fe0->Object::Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90 } +Next token is token 'a' (0xaaaaf0d03fe0 'a') +Shifting token 'a' (0xaaaaf0d03fe0 'a') Entering state 2 Stack now 0 11 11 2 -0xffffcf6420a0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab09e92320 'a') --> $$ = nterm item (0xffffcf6420a0 'a') -0xaaab09e92320->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf6420a0 } -0xaaab09e92320->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf6420a0 } -0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf6420a0 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaaf0d03fe0 'a') +-> $$ = nterm item (0xaaaaf0d03fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token -0xffffcf641fd0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320 } -0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fd0 } -0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fd0, 0xffffcf642080 } -Next token is token 'a' (0xffffcf642080 'a') -0xffffcf641fc0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf642080 } -0xffffcf642080->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fc0, 0xffffcf642080 } -Shifting token 'a' (0xffffcf641fc0 'a') -0xaaab09e92340->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fc0 } -0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf641fc0 } +0xaaaaf0d04030->Object::Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90, 0xaaaaf0d03fe0 } +Next token is token 'a' (0xaaaaf0d04030 'a') +Shifting token 'a' (0xaaaaf0d04030 'a') Entering state 2 Stack now 0 11 11 11 2 -0xffffcf6420a0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab09e92340 'a') --> $$ = nterm item (0xffffcf6420a0 'a') -0xaaab09e92340->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf6420a0 } -0xaaab09e92340->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf6420a0 } -0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf6420a0 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaaf0d04030 'a') +-> $$ = nterm item (0xaaaaf0d04030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token -0xffffcf641fd0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340 } -0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf641fd0 } -0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf641fd0, 0xffffcf642080 } -Next token is token 'p' (0xffffcf642080 'p'Exception caught: cleaning lookahead and stack -0xaaab09e92340->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf642080 } -0xaaab09e92320->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf642080 } -0xaaab09e92300->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf642080 } -0xaaab09e922e0->Object::~Object { 0xaaab09e922e0, 0xffffcf642080 } -0xffffcf642080->Object::~Object { 0xffffcf642080 } +0xaaaaf0d04080->Object::Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90, 0xaaaaf0d03fe0, 0xaaaaf0d04030 } +Next token is token 'p' (0xaaaaf0d04080 'p'Exception caught: cleaning lookahead and stack +0xaaaaf0d04080->Object::~Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90, 0xaaaaf0d03fe0, 0xaaaaf0d04030, 0xaaaaf0d04080 } +0xaaaaf0d04030->Object::~Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90, 0xaaaaf0d03fe0, 0xaaaaf0d04030 } +0xaaaaf0d03fe0->Object::~Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90, 0xaaaaf0d03fe0 } +0xaaaaf0d03f90->Object::~Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90 } +0xaaaaf0d03f40->Object::~Object { 0xaaaaf0d03f40 } exception caught: printer end { } -stdout: -exception caught: yylex -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -693. java.at:186: ./c++.at:1360: $PREPARSER ./input i +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: - skipped (java.at:188) Starting parse Entering state 0 Stack now 0 Reading a token -0xffffcf641fd0->Object::Object { } -0xffffcf642080->Object::Object { 0xffffcf641fd0 } -0xffffcf641fd0->Object::~Object { 0xffffcf641fd0, 0xffffcf642080 } -Next token is token 'a' (0xffffcf642080 'a') -0xffffcf641fc0->Object::Object { 0xffffcf642080 } -0xffffcf642080->Object::~Object { 0xffffcf641fc0, 0xffffcf642080 } -Shifting token 'a' (0xffffcf641fc0 'a') -0xaaab09e922e0->Object::Object { 0xffffcf641fc0 } -0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xffffcf641fc0 } +0xffffc16e24a0->Object::Object { } +0xffffc16e2580->Object::Object { 0xffffc16e24a0 } +0xffffc16e24a0->Object::~Object { 0xffffc16e24a0, 0xffffc16e2580 } +Next token is token 'a' (0xffffc16e2580 'a') +0xffffc16e24e0->Object::Object { 0xffffc16e2580 } +0xffffc16e2490->Object::Object { 0xffffc16e24e0, 0xffffc16e2580 } +0xffffc16e2490->Object::~Object { 0xffffc16e2490, 0xffffc16e24e0, 0xffffc16e2580 } +0xffffc16e2580->Object::~Object { 0xffffc16e24e0, 0xffffc16e2580 } +Shifting token 'a' (0xffffc16e24e0 'a') +0xaaaad44a52e0->Object::Object { 0xffffc16e24e0 } +0xffffc16e2468->Object::Object { 0xaaaad44a52e0, 0xffffc16e24e0 } +0xffffc16e2468->Object::~Object { 0xaaaad44a52e0, 0xffffc16e2468, 0xffffc16e24e0 } +0xffffc16e24e0->Object::~Object { 0xaaaad44a52e0, 0xffffc16e24e0 } Entering state 2 Stack now 0 2 -0xffffcf6420a0->Object::Object { 0xaaab09e922e0 } +0xffffc16e25a0->Object::Object { 0xaaaad44a52e0 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab09e922e0 'a') --> $$ = nterm item (0xffffcf6420a0 'a') -0xaaab09e922e0->Object::~Object { 0xaaab09e922e0, 0xffffcf6420a0 } -0xaaab09e922e0->Object::Object { 0xffffcf6420a0 } -0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xffffcf6420a0 } + $1 = token 'a' (0xaaaad44a52e0 'a') +-> $$ = nterm item (0xffffc16e25a0 'a') +0xaaaad44a52e0->Object::~Object { 0xaaaad44a52e0, 0xffffc16e25a0 } +0xaaaad44a52e0->Object::Object { 0xffffc16e25a0 } +0xffffc16e2550->Object::Object { 0xaaaad44a52e0, 0xffffc16e25a0 } +0xffffc16e2550->Object::~Object { 0xaaaad44a52e0, 0xffffc16e2550, 0xffffc16e25a0 } +0xffffc16e25a0->Object::~Object { 0xaaaad44a52e0, 0xffffc16e25a0 } Entering state 11 Stack now 0 11 Reading a token -0xffffcf641fd0->Object::Object { 0xaaab09e922e0 } -0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xffffcf641fd0 } -0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xffffcf641fd0, 0xffffcf642080 } -Next token is token 'a' (0xffffcf642080 'a') -0xffffcf641fc0->Object::Object { 0xaaab09e922e0, 0xffffcf642080 } -0xffffcf642080->Object::~Object { 0xaaab09e922e0, 0xffffcf641fc0, 0xffffcf642080 } -Shifting token 'a' (0xffffcf641fc0 'a') -0xaaab09e92300->Object::Object { 0xaaab09e922e0, 0xffffcf641fc0 } -0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fc0 } +0xffffc16e24a0->Object::Object { 0xaaaad44a52e0 } +0xffffc16e2580->Object::Object { 0xaaaad44a52e0, 0xffffc16e24a0 } +0xffffc16e24a0->Object::~Object { 0xaaaad44a52e0, 0xffffc16e24a0, 0xffffc16e2580 } +Next token is token 'a' (0xffffc16e2580 'a') +0xffffc16e24e0->Object::Object { 0xaaaad44a52e0, 0xffffc16e2580 } +0xffffc16e2490->Object::Object { 0xaaaad44a52e0, 0xffffc16e24e0, 0xffffc16e2580 } +0xffffc16e2490->Object::~Object { 0xaaaad44a52e0, 0xffffc16e2490, 0xffffc16e24e0, 0xffffc16e2580 } +0xffffc16e2580->Object::~Object { 0xaaaad44a52e0, 0xffffc16e24e0, 0xffffc16e2580 } +Shifting token 'a' (0xffffc16e24e0 'a') +0xaaaad44a5300->Object::Object { 0xaaaad44a52e0, 0xffffc16e24e0 } +0xffffc16e2468->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24e0 } +0xffffc16e2468->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e2468, 0xffffc16e24e0 } +0xffffc16e24e0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24e0 } Entering state 2 Stack now 0 11 2 -0xffffcf6420a0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300 } +0xffffc16e25a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab09e92300 'a') --> $$ = nterm item (0xffffcf6420a0 'a') -0xaaab09e92300->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf6420a0 } -0xaaab09e92300->Object::Object { 0xaaab09e922e0, 0xffffcf6420a0 } -0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf6420a0 } + $1 = token 'a' (0xaaaad44a5300 'a') +-> $$ = nterm item (0xffffc16e25a0 'a') +0xaaaad44a5300->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e25a0 } +0xaaaad44a5300->Object::Object { 0xaaaad44a52e0, 0xffffc16e25a0 } +0xffffc16e2550->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e25a0 } +0xffffc16e2550->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e2550, 0xffffc16e25a0 } +0xffffc16e25a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e25a0 } Entering state 11 Stack now 0 11 11 Reading a token -0xffffcf641fd0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300 } -0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fd0 } -0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fd0, 0xffffcf642080 } -Next token is token 'a' (0xffffcf642080 'a') -0xffffcf641fc0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf642080 } -0xffffcf642080->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fc0, 0xffffcf642080 } -Shifting token 'a' (0xffffcf641fc0 'a') -0xaaab09e92320->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf641fc0 } -0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fc0 } +0xffffc16e24a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300 } +0xffffc16e2580->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24a0 } +0xffffc16e24a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24a0, 0xffffc16e2580 } +Next token is token 'a' (0xffffc16e2580 'a') +0xffffc16e24e0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e2580 } +0xffffc16e2490->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24e0, 0xffffc16e2580 } +0xffffc16e2490->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e2490, 0xffffc16e24e0, 0xffffc16e2580 } +0xffffc16e2580->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24e0, 0xffffc16e2580 } +Shifting token 'a' (0xffffc16e24e0 'a') +0xaaaad44a5320->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24e0 } +0xffffc16e2468->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24e0 } +0xffffc16e2468->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e2468, 0xffffc16e24e0 } +0xffffc16e24e0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24e0 } Entering state 2 Stack now 0 11 11 2 -0xffffcf6420a0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320 } +0xffffc16e25a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab09e92320 'a') --> $$ = nterm item (0xffffcf6420a0 'a') -0xaaab09e92320->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf6420a0 } -0xaaab09e92320->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf6420a0 } -0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf6420a0 } + $1 = token 'a' (0xaaaad44a5320 'a') +-> $$ = nterm item (0xffffc16e25a0 'a') +0xaaaad44a5320->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e25a0 } +0xaaaad44a5320->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e25a0 } +0xffffc16e2550->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e25a0 } +0xffffc16e2550->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e2550, 0xffffc16e25a0 } +0xffffc16e25a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e25a0 } Entering state 11 Stack now 0 11 11 11 Reading a token -0xffffcf641fd0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320 } -0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fd0 } -0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fd0, 0xffffcf642080 } -Next token is token 'a' (0xffffcf642080 'a') -0xffffcf641fc0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf642080 } -0xffffcf642080->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fc0, 0xffffcf642080 } -Shifting token 'a' (0xffffcf641fc0 'a') -0xaaab09e92340->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf641fc0 } -0xffffcf641fc0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf641fc0 } +0xffffc16e24a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320 } +0xffffc16e2580->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24a0 } +0xffffc16e24a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24a0, 0xffffc16e2580 } +Next token is token 'a' (0xffffc16e2580 'a') +0xffffc16e24e0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e2580 } +0xffffc16e2490->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24e0, 0xffffc16e2580 } +0xffffc16e2490->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e2490, 0xffffc16e24e0, 0xffffc16e2580 } +0xffffc16e2580->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24e0, 0xffffc16e2580 } +Shifting token 'a' (0xffffc16e24e0 'a') +0xaaaad44a5340->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24e0 } +0xffffc16e2468->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e24e0 } +0xffffc16e2468->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e2468, 0xffffc16e24e0 } +0xffffc16e24e0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e24e0 } Entering state 2 Stack now 0 11 11 11 2 -0xffffcf6420a0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340 } +0xffffc16e25a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab09e92340 'a') --> $$ = nterm item (0xffffcf6420a0 'a') -0xaaab09e92340->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf6420a0 } -0xaaab09e92340->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf6420a0 } -0xffffcf6420a0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf6420a0 } + $1 = token 'a' (0xaaaad44a5340 'a') +-> $$ = nterm item (0xffffc16e25a0 'a') +0xaaaad44a5340->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e25a0 } +0xaaaad44a5340->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e25a0 } +0xffffc16e2550->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e25a0 } +0xffffc16e2550->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e2550, 0xffffc16e25a0 } +0xffffc16e25a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e25a0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token -0xffffcf641fd0->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340 } -0xffffcf642080->Object::Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf641fd0 } -0xffffcf641fd0->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf641fd0, 0xffffcf642080 } -Next token is token 'p' (0xffffcf642080 'p'Exception caught: cleaning lookahead and stack -0xaaab09e92340->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xaaab09e92340, 0xffffcf642080 } -0xaaab09e92320->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xaaab09e92320, 0xffffcf642080 } -0xaaab09e92300->Object::~Object { 0xaaab09e922e0, 0xaaab09e92300, 0xffffcf642080 } -0xaaab09e922e0->Object::~Object { 0xaaab09e922e0, 0xffffcf642080 } -0xffffcf642080->Object::~Object { 0xffffcf642080 } +0xffffc16e24a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340 } +0xffffc16e2580->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e24a0 } +0xffffc16e24a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e24a0, 0xffffc16e2580 } +Next token is token 'p' (0xffffc16e2580 'p'Exception caught: cleaning lookahead and stack +0xaaaad44a5340->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e2580 } +0xaaaad44a5320->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e2580 } +0xaaaad44a5300->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e2580 } +0xaaaad44a52e0->Object::~Object { 0xaaaad44a52e0, 0xffffc16e2580 } +0xffffc16e2580->Object::~Object { 0xffffc16e2580 } exception caught: printer end { } -./c++.at:1362: grep '^exception caught: printer$' stderr -stderr: -exception caught: initial-action -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -exception caught: printer -./c++.at:1362: $PREPARSER ./input aaaae -stderr: - -exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./c++.at:1360: $PREPARSER ./input aaaap -stderr: -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./c++.at:1360: $PREPARSER ./input --debug aaaap -stderr: -./c++.at:1555: ./check -./c++.at:1362: $PREPARSER ./input aaaaE Starting parse Entering state 0 Stack now 0 Reading a token -0xaaaae734ef40->Object::Object { } -Next token is token 'a' (0xaaaae734ef40 'a') -Shifting token 'a' (0xaaaae734ef40 'a') +0xffffc16e24a0->Object::Object { } +0xffffc16e2580->Object::Object { 0xffffc16e24a0 } +0xffffc16e24a0->Object::~Object { 0xffffc16e24a0, 0xffffc16e2580 } +Next token is token 'a' (0xffffc16e2580 'a') +0xffffc16e24e0->Object::Object { 0xffffc16e2580 } +0xffffc16e2490->Object::Object { 0xffffc16e24e0, 0xffffc16e2580 } +0xffffc16e2490->Object::~Object { 0xffffc16e2490, 0xffffc16e24e0, 0xffffc16e2580 } +0xffffc16e2580->Object::~Object { 0xffffc16e24e0, 0xffffc16e2580 } +Shifting token 'a' (0xffffc16e24e0 'a') +0xaaaad44a52e0->Object::Object { 0xffffc16e24e0 } +0xffffc16e2468->Object::Object { 0xaaaad44a52e0, 0xffffc16e24e0 } +0xffffc16e2468->Object::~Object { 0xaaaad44a52e0, 0xffffc16e2468, 0xffffc16e24e0 } +0xffffc16e24e0->Object::~Object { 0xaaaad44a52e0, 0xffffc16e24e0 } Entering state 2 Stack now 0 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae734ef40 'a') --> $$ = nterm item (0xaaaae734ef40 'a') +0xffffc16e25a0->Object::Object { 0xaaaad44a52e0 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaad44a52e0 'a') +-> $$ = nterm item (0xffffc16e25a0 'a') +0xaaaad44a52e0->Object::~Object { 0xaaaad44a52e0, 0xffffc16e25a0 } +0xaaaad44a52e0->Object::Object { 0xffffc16e25a0 } +0xffffc16e2550->Object::Object { 0xaaaad44a52e0, 0xffffc16e25a0 } +0xffffc16e2550->Object::~Object { 0xaaaad44a52e0, 0xffffc16e2550, 0xffffc16e25a0 } +0xffffc16e25a0->Object::~Object { 0xaaaad44a52e0, 0xffffc16e25a0 } Entering state 11 Stack now 0 11 Reading a token -0xaaaae734ef90->Object::Object { 0xaaaae734ef40 } -Next token is token 'a' (0xaaaae734ef90 'a') -Shifting token 'a' (0xaaaae734ef90 'a') +0xffffc16e24a0->Object::Object { 0xaaaad44a52e0 } +0xffffc16e2580->Object::Object { 0xaaaad44a52e0, 0xffffc16e24a0 } +0xffffc16e24a0->Object::~Object { 0xaaaad44a52e0, 0xffffc16e24a0, 0xffffc16e2580 } +Next token is token 'a' (0xffffc16e2580 'a') +0xffffc16e24e0->Object::Object { 0xaaaad44a52e0, 0xffffc16e2580 } +0xffffc16e2490->Object::Object { 0xaaaad44a52e0, 0xffffc16e24e0, 0xffffc16e2580 } +0xffffc16e2490->Object::~Object { 0xaaaad44a52e0, 0xffffc16e2490, 0xffffc16e24e0, 0xffffc16e2580 } +0xffffc16e2580->Object::~Object { 0xaaaad44a52e0, 0xffffc16e24e0, 0xffffc16e2580 } +Shifting token 'a' (0xffffc16e24e0 'a') +0xaaaad44a5300->Object::Object { 0xaaaad44a52e0, 0xffffc16e24e0 } +0xffffc16e2468->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24e0 } +0xffffc16e2468->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e2468, 0xffffc16e24e0 } +0xffffc16e24e0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24e0 } Entering state 2 Stack now 0 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae734ef90 'a') --> $$ = nterm item (0xaaaae734ef90 'a') +0xffffc16e25a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaad44a5300 'a') +-> $$ = nterm item (0xffffc16e25a0 'a') +0xaaaad44a5300->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e25a0 } +0xaaaad44a5300->Object::Object { 0xaaaad44a52e0, 0xffffc16e25a0 } +0xffffc16e2550->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e25a0 } +0xffffc16e2550->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e2550, 0xffffc16e25a0 } +0xffffc16e25a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e25a0 } Entering state 11 Stack now 0 11 11 Reading a token -0xaaaae734efe0->Object::Object { 0xaaaae734ef40, 0xaaaae734ef90 } -Next token is token 'a' (0xaaaae734efe0 'a') -Shifting token 'a' (0xaaaae734efe0 'a') +0xffffc16e24a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300 } +0xffffc16e2580->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24a0 } +0xffffc16e24a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24a0, 0xffffc16e2580 } +Next token is token 'a' (0xffffc16e2580 'a') +0xffffc16e24e0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e2580 } +0xffffc16e2490->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24e0, 0xffffc16e2580 } +0xffffc16e2490->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e2490, 0xffffc16e24e0, 0xffffc16e2580 } +0xffffc16e2580->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24e0, 0xffffc16e2580 } +Shifting token 'a' (0xffffc16e24e0 'a') +0xaaaad44a5320->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e24e0 } +0xffffc16e2468->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24e0 } +0xffffc16e2468->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e2468, 0xffffc16e24e0 } +0xffffc16e24e0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24e0 } Entering state 2 Stack now 0 11 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae734efe0 'a') --> $$ = nterm item (0xaaaae734efe0 'a') +0xffffc16e25a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaad44a5320 'a') +-> $$ = nterm item (0xffffc16e25a0 'a') +0xaaaad44a5320->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e25a0 } +0xaaaad44a5320->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e25a0 } +0xffffc16e2550->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e25a0 } +0xffffc16e2550->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e2550, 0xffffc16e25a0 } +0xffffc16e25a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e25a0 } Entering state 11 Stack now 0 11 11 11 Reading a token -0xaaaae734f030->Object::Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0 } -Next token is token 'a' (0xaaaae734f030 'a') -Shifting token 'a' (0xaaaae734f030 'a') +0xffffc16e24a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320 } +0xffffc16e2580->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24a0 } +0xffffc16e24a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24a0, 0xffffc16e2580 } +Next token is token 'a' (0xffffc16e2580 'a') +0xffffc16e24e0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e2580 } +0xffffc16e2490->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24e0, 0xffffc16e2580 } +0xffffc16e2490->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e2490, 0xffffc16e24e0, 0xffffc16e2580 } +0xffffc16e2580->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24e0, 0xffffc16e2580 } +Shifting token 'a' (0xffffc16e24e0 'a') +0xaaaad44a5340->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e24e0 } +0xffffc16e2468->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e24e0 } +0xffffc16e2468->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e2468, 0xffffc16e24e0 } +0xffffc16e24e0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e24e0 } Entering state 2 Stack now 0 11 11 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae734f030 'a') --> $$ = nterm item (0xaaaae734f030 'a') +0xffffc16e25a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaad44a5340 'a') +-> $$ = nterm item (0xffffc16e25a0 'a') +0xaaaad44a5340->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e25a0 } +0xaaaad44a5340->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e25a0 } +0xffffc16e2550->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e25a0 } +0xffffc16e2550->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e2550, 0xffffc16e25a0 } +0xffffc16e25a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e25a0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token -0xaaaae734f080->Object::Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0, 0xaaaae734f030 } -Next token is token 'p' (0xaaaae734f080 'p'Exception caught: cleaning lookahead and stack -0xaaaae734f080->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0, 0xaaaae734f030, 0xaaaae734f080 } -0xaaaae734f030->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0, 0xaaaae734f030 } -0xaaaae734efe0->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0 } -0xaaaae734ef90->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90 } -0xaaaae734ef40->Object::~Object { 0xaaaae734ef40 } +0xffffc16e24a0->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340 } +0xffffc16e2580->Object::Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e24a0 } +0xffffc16e24a0->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e24a0, 0xffffc16e2580 } +Next token is token 'p' (0xffffc16e2580 'p'Exception caught: cleaning lookahead and stack +0xaaaad44a5340->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xaaaad44a5340, 0xffffc16e2580 } +0xaaaad44a5320->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xaaaad44a5320, 0xffffc16e2580 } +0xaaaad44a5300->Object::~Object { 0xaaaad44a52e0, 0xaaaad44a5300, 0xffffc16e2580 } +0xaaaad44a52e0->Object::~Object { 0xaaaad44a52e0, 0xffffc16e2580 } +0xffffc16e2580->Object::~Object { 0xffffc16e2580 } exception caught: printer end { } -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1362: grep '^exception caught: printer$' stderr +stdout: +exception caught: printer +./c++.at:1362: $PREPARSER ./input aaaae +./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS stderr: -exception caught: syntax error, unexpected end of file, expecting 'a' -./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xaaaae734ef40->Object::Object { } -Next token is token 'a' (0xaaaae734ef40 'a') -Shifting token 'a' (0xaaaae734ef40 'a') +0xaaaaf0d03f40->Object::Object { } +Next token is token 'a' (0xaaaaf0d03f40 'a') +Shifting token 'a' (0xaaaaf0d03f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae734ef40 'a') --> $$ = nterm item (0xaaaae734ef40 'a') + $1 = token 'a' (0xaaaaf0d03f40 'a') +-> $$ = nterm item (0xaaaaf0d03f40 'a') Entering state 11 Stack now 0 11 Reading a token -0xaaaae734ef90->Object::Object { 0xaaaae734ef40 } -Next token is token 'a' (0xaaaae734ef90 'a') -Shifting token 'a' (0xaaaae734ef90 'a') +0xaaaaf0d03f90->Object::Object { 0xaaaaf0d03f40 } +Next token is token 'a' (0xaaaaf0d03f90 'a') +Shifting token 'a' (0xaaaaf0d03f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae734ef90 'a') --> $$ = nterm item (0xaaaae734ef90 'a') + $1 = token 'a' (0xaaaaf0d03f90 'a') +-> $$ = nterm item (0xaaaaf0d03f90 'a') Entering state 11 Stack now 0 11 11 Reading a token -0xaaaae734efe0->Object::Object { 0xaaaae734ef40, 0xaaaae734ef90 } -Next token is token 'a' (0xaaaae734efe0 'a') -Shifting token 'a' (0xaaaae734efe0 'a') +0xaaaaf0d03fe0->Object::Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90 } +Next token is token 'a' (0xaaaaf0d03fe0 'a') +Shifting token 'a' (0xaaaaf0d03fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae734efe0 'a') --> $$ = nterm item (0xaaaae734efe0 'a') + $1 = token 'a' (0xaaaaf0d03fe0 'a') +-> $$ = nterm item (0xaaaaf0d03fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token -0xaaaae734f030->Object::Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0 } -Next token is token 'a' (0xaaaae734f030 'a') -Shifting token 'a' (0xaaaae734f030 'a') +0xaaaaf0d04030->Object::Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90, 0xaaaaf0d03fe0 } +Next token is token 'a' (0xaaaaf0d04030 'a') +Shifting token 'a' (0xaaaaf0d04030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae734f030 'a') --> $$ = nterm item (0xaaaae734f030 'a') + $1 = token 'a' (0xaaaaf0d04030 'a') +-> $$ = nterm item (0xaaaaf0d04030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token -0xaaaae734f080->Object::Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0, 0xaaaae734f030 } -Next token is token 'p' (0xaaaae734f080 'p'Exception caught: cleaning lookahead and stack -0xaaaae734f080->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0, 0xaaaae734f030, 0xaaaae734f080 } -0xaaaae734f030->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0, 0xaaaae734f030 } -0xaaaae734efe0->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90, 0xaaaae734efe0 } -0xaaaae734ef90->Object::~Object { 0xaaaae734ef40, 0xaaaae734ef90 } -0xaaaae734ef40->Object::~Object { 0xaaaae734ef40 } +0xaaaaf0d04080->Object::Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90, 0xaaaaf0d03fe0, 0xaaaaf0d04030 } +Next token is token 'p' (0xaaaaf0d04080 'p'Exception caught: cleaning lookahead and stack +0xaaaaf0d04080->Object::~Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90, 0xaaaaf0d03fe0, 0xaaaaf0d04030, 0xaaaaf0d04080 } +0xaaaaf0d04030->Object::~Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90, 0xaaaaf0d03fe0, 0xaaaaf0d04030 } +0xaaaaf0d03fe0->Object::~Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90, 0xaaaaf0d03fe0 } +0xaaaaf0d03f90->Object::~Object { 0xaaaaf0d03f40, 0xaaaaf0d03f90 } +0xaaaaf0d03f40->Object::~Object { 0xaaaaf0d03f40 } exception caught: printer end { } -./c++.at:1360: grep '^exception caught: printer$' stderr +exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: grep '^exception caught: printer$' stderr +./c++.at:1362: $PREPARSER ./input aaaaE + +stderr: stdout: +exception caught: syntax error, unexpected end of file, expecting 'a' +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae -./c++.at:1362: $PREPARSER ./input aaaaT stderr: -694. java.at:217: testing Java parser class modifiers ... -./java.at:219: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y exception caught: syntax error +./c++.at:1362: $PREPARSER ./input aaaaT ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./java.at:219: grep '[mb]4_' YYParser.y +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: stdout: -694. java.at:217: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - skipped (java.at:219) +./c++.at:1360: $PREPARSER ./input aaaaE +./c++.at:856: $PREPARSER ./input ./c++.at:1362: $PREPARSER ./input aaaaR - stderr: -./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./c++.at:1360: $PREPARSER ./input aaaaE -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -695. java.at:287: testing Java parser class extends and implements ... +694. java.at:217: testing Java parser class modifiers ... +stderr: +./java.at:219: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y +./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: $PREPARSER ./input aaaaT ======== Testing with C++ standard flags: '' -./java.at:289: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y +======== Testing with C++ standard flags: '' +./c++.at:856: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stderr: ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: $PREPARSER ./input aaaaR stderr: -./c++.at:1360: $PREPARSER ./input aaaaT +./java.at:219: grep '[mb]4_' YYParser.y +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: -./c++.at:1064: $PREPARSER ./input < in +======== Testing with C++ standard flags: '' +694. java.at:217: ./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS + skipped (java.at:219) + +695. java.at:287: testing Java parser class extends and implements ... +./java.at:289: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y +./java.at:289: grep '[mb]4_' YYParser.y +stdout: +695. java.at:287: skipped (java.at:289) + +696. java.at:307: testing Java %parse-param and %lex-param ... +./java.at:309: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y +./java.at:309: grep '[mb]4_' YYParser.y +stdout: +696. java.at:307: skipped (java.at:309) + +697. java.at:381: testing Java throws specifications ... +./java.at:441: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y stderr: +stdout: +./c++.at:1065: $PREPARSER ./input < in stderr: +./java.at:441: grep '[mb]4_' YYParser.y error: invalid expression caught error error: invalid character caught error -./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +697. java.at:381: ./c++.at:1065: $PREPARSER ./input < in + skipped (java.at:441) +stderr: +error: invalid expression +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + +./c++.at:1065: $PREPARSER ./input < in +stderr: +error: invalid character +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +698. java.at:470: testing Java constructor init and init_throws ... +./java.at:475: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y +======== Testing with C++ standard flags: '' +./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS +./java.at:475: grep '[mb]4_' YYParser.y +stderr: +stdout: +stdout: ./c++.at:1064: $PREPARSER ./input < in -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +698. java.at:470: skipped (java.at:475) stderr: -./java.at:289: grep '[mb]4_' YYParser.y -./c++.at:1360: $PREPARSER ./input aaaaR error: invalid expression +caught error +error: invalid character +caught error ./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + +./c++.at:1064: $PREPARSER ./input < in stderr: stdout: stderr: +======== Testing with C++ standard flags: '' +error: invalid expression +./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./c++.at:1411: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: ./c++.at:1363: $PREPARSER ./input aaaas -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./c++.at:1064: $PREPARSER ./input < in exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -695. java.at:287: ======== Testing with C++ standard flags: '' - skipped (java.at:289) -stderr: -./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1363: $PREPARSER ./input aaaal -error: invalid character -stderr: -./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -stdout: +./c++.at:1064: $PREPARSER ./input < in exception caught: yylex -./c++.at:1361: $PREPARSER ./input aaaas ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: - -======== Testing with C++ standard flags: '' -exception caught: reduction -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS +699. java.at:497: testing Java value, position, and location types ... +./java.at:499: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y ./c++.at:1363: $PREPARSER ./input i -./c++.at:1361: $PREPARSER ./input aaaal +error: invalid character +./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stderr: +stdout: exception caught: initial-action -exception caught: yylex -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: $PREPARSER ./input i +./c++.at:1361: $PREPARSER ./input aaaas stderr: -696. java.at:307: testing Java %parse-param and %lex-param ... -./java.at:309: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y +======== Testing with C++ standard flags: '' ./c++.at:1363: $PREPARSER ./input aaaap -exception caught: initial-action +exception caught: reduction ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./java.at:499: grep '[mb]4_' YYParser.y +./c++.at:1064: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS stderr: +stdout: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: $PREPARSER ./input aaaap +./c++.at:1361: $PREPARSER ./input aaaal +699. java.at:497: ./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: +exception caught: yylex + skipped (java.at:499) ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: -./java.at:309: grep '[mb]4_' YYParser.y -./c++.at:1361: $PREPARSER ./input --debug aaaap -stdout: Starting parse Entering state 0 Stack now 0 Reading a token -0xffffdb7dd660->Object::Object { } -0xffffdb7dd760->Object::Object { 0xffffdb7dd660 } -0xffffdb7dd660->Object::~Object { 0xffffdb7dd660, 0xffffdb7dd760 } -Next token is token 'a' (0xffffdb7dd760 'a') -0xffffdb7dd6a0->Object::Object { 0xffffdb7dd760 } -0xffffdb7dd760->Object::~Object { 0xffffdb7dd6a0, 0xffffdb7dd760 } -Shifting token 'a' (0xffffdb7dd6a0 'a') -0xaaab151902e0->Object::Object { 0xffffdb7dd6a0 } -0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xffffdb7dd6a0 } +0xfffff01188e0->Object::Object { } +0xfffff01189c0->Object::Object { 0xfffff01188e0 } +0xfffff01188e0->Object::~Object { 0xfffff01188e0, 0xfffff01189c0 } +Next token is token 'a' (0xfffff01189c0 'a') +0xfffff0118920->Object::Object { 0xfffff01189c0 } +0xfffff01188d0->Object::Object { 0xfffff0118920, 0xfffff01189c0 } +0xfffff01188d0->Object::~Object { 0xfffff01188d0, 0xfffff0118920, 0xfffff01189c0 } +0xfffff01189c0->Object::~Object { 0xfffff0118920, 0xfffff01189c0 } +Shifting token 'a' (0xfffff0118920 'a') +0xaaab0b5ab2e0->Object::Object { 0xfffff0118920 } +0xfffff01188a8->Object::Object { 0xaaab0b5ab2e0, 0xfffff0118920 } +0xfffff01188a8->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01188a8, 0xfffff0118920 } +0xfffff0118920->Object::~Object { 0xaaab0b5ab2e0, 0xfffff0118920 } Entering state 1 Stack now 0 1 -0xffffdb7dd780->Object::Object { 0xaaab151902e0 } +0xfffff01189e0->Object::Object { 0xaaab0b5ab2e0 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab151902e0 'a') --> $$ = nterm item (0xffffdb7dd780 'a') -0xaaab151902e0->Object::~Object { 0xaaab151902e0, 0xffffdb7dd780 } -0xaaab151902e0->Object::Object { 0xffffdb7dd780 } -0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xffffdb7dd780 } + $1 = token 'a' (0xaaab0b5ab2e0 'a') +-> $$ = nterm item (0xfffff01189e0 'a') +0xaaab0b5ab2e0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01189e0 } +0xaaab0b5ab2e0->Object::Object { 0xfffff01189e0 } +0xfffff0118990->Object::Object { 0xaaab0b5ab2e0, 0xfffff01189e0 } +0xfffff0118990->Object::~Object { 0xaaab0b5ab2e0, 0xfffff0118990, 0xfffff01189e0 } +0xfffff01189e0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01189e0 } Entering state 10 Stack now 0 10 Reading a token -0xffffdb7dd660->Object::Object { 0xaaab151902e0 } -0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xffffdb7dd660 } -0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xffffdb7dd660, 0xffffdb7dd760 } -Next token is token 'a' (0xffffdb7dd760 'a') -0xffffdb7dd6a0->Object::Object { 0xaaab151902e0, 0xffffdb7dd760 } -0xffffdb7dd760->Object::~Object { 0xaaab151902e0, 0xffffdb7dd6a0, 0xffffdb7dd760 } -Shifting token 'a' (0xffffdb7dd6a0 'a') -0xaaab15190300->Object::Object { 0xaaab151902e0, 0xffffdb7dd6a0 } -0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd6a0 } +0xfffff01188e0->Object::Object { 0xaaab0b5ab2e0 } +0xfffff01189c0->Object::Object { 0xaaab0b5ab2e0, 0xfffff01188e0 } +0xfffff01188e0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01188e0, 0xfffff01189c0 } +Next token is token 'a' (0xfffff01189c0 'a') +0xfffff0118920->Object::Object { 0xaaab0b5ab2e0, 0xfffff01189c0 } +0xfffff01188d0->Object::Object { 0xaaab0b5ab2e0, 0xfffff0118920, 0xfffff01189c0 } +0xfffff01188d0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01188d0, 0xfffff0118920, 0xfffff01189c0 } +0xfffff01189c0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff0118920, 0xfffff01189c0 } +Shifting token 'a' (0xfffff0118920 'a') +0xaaab0b5ab300->Object::Object { 0xaaab0b5ab2e0, 0xfffff0118920 } +0xfffff01188a8->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118920 } +0xfffff01188a8->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01188a8, 0xfffff0118920 } +0xfffff0118920->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118920 } Entering state 1 Stack now 0 10 1 -0xffffdb7dd780->Object::Object { 0xaaab151902e0, 0xaaab15190300 } +0xfffff01189e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab15190300 'a') --> $$ = nterm item (0xffffdb7dd780 'a') -0xaaab15190300->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd780 } -0xaaab15190300->Object::Object { 0xaaab151902e0, 0xffffdb7dd780 } -0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd780 } + $1 = token 'a' (0xaaab0b5ab300 'a') +-> $$ = nterm item (0xfffff01189e0 'a') +0xaaab0b5ab300->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189e0 } +0xaaab0b5ab300->Object::Object { 0xaaab0b5ab2e0, 0xfffff01189e0 } +0xfffff0118990->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189e0 } +0xfffff0118990->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118990, 0xfffff01189e0 } +0xfffff01189e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189e0 } Entering state 10 Stack now 0 10 10 Reading a token -0xffffdb7dd660->Object::Object { 0xaaab151902e0, 0xaaab15190300 } -0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd660 } -0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd660, 0xffffdb7dd760 } -Next token is token 'a' (0xffffdb7dd760 'a') -0xffffdb7dd6a0->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd760 } -0xffffdb7dd760->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd6a0, 0xffffdb7dd760 } -Shifting token 'a' (0xffffdb7dd6a0 'a') -0xaaab15190320->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd6a0 } -0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd6a0 } +0xfffff01188e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300 } +0xfffff01189c0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01188e0 } +0xfffff01188e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01188e0, 0xfffff01189c0 } +Next token is token 'a' (0xfffff01189c0 'a') +0xfffff0118920->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189c0 } +0xfffff01188d0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118920, 0xfffff01189c0 } +0xfffff01188d0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01188d0, 0xfffff0118920, 0xfffff01189c0 } +0xfffff01189c0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118920, 0xfffff01189c0 } +Shifting token 'a' (0xfffff0118920 'a') +0xaaab0b5ab320->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118920 } +0xfffff01188a8->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118920 } +0xfffff01188a8->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01188a8, 0xfffff0118920 } +0xfffff0118920->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118920 } Entering state 1 Stack now 0 10 10 1 -0xffffdb7dd780->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320 } +0xfffff01189e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab15190320 'a') --> $$ = nterm item (0xffffdb7dd780 'a') -0xaaab15190320->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd780 } -0xaaab15190320->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd780 } -0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd780 } + $1 = token 'a' (0xaaab0b5ab320 'a') +-> $$ = nterm item (0xfffff01189e0 'a') +0xaaab0b5ab320->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189e0 } +0xaaab0b5ab320->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189e0 } +0xfffff0118990->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189e0 } +0xfffff0118990->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118990, 0xfffff01189e0 } +0xfffff01189e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189e0 } Entering state 10 Stack now 0 10 10 10 Reading a token -0xffffdb7dd660->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320 } -0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd660 } -0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd660, 0xffffdb7dd760 } -Next token is token 'a' (0xffffdb7dd760 'a') -0xffffdb7dd6a0->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd760 } -0xffffdb7dd760->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd6a0, 0xffffdb7dd760 } -Shifting token 'a' (0xffffdb7dd6a0 'a') -0xaaab15190340->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd6a0 } -0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd6a0 } +0xfffff01188e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320 } +0xfffff01189c0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01188e0 } +0xfffff01188e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01188e0, 0xfffff01189c0 } +Next token is token 'a' (0xfffff01189c0 'a') +0xfffff0118920->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189c0 } +0xfffff01188d0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118920, 0xfffff01189c0 } +0xfffff01188d0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01188d0, 0xfffff0118920, 0xfffff01189c0 } +0xfffff01189c0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118920, 0xfffff01189c0 } +Shifting token 'a' (0xfffff0118920 'a') +0xaaab0b5ab340->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118920 } +0xfffff01188a8->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff0118920 } +0xfffff01188a8->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01188a8, 0xfffff0118920 } +0xfffff0118920->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff0118920 } Entering state 1 Stack now 0 10 10 10 1 -0xffffdb7dd780->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340 } +0xfffff01189e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab15190340 'a') --> $$ = nterm item (0xffffdb7dd780 'a') -0xaaab15190340->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd780 } -0xaaab15190340->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd780 } -0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd780 } + $1 = token 'a' (0xaaab0b5ab340 'a') +-> $$ = nterm item (0xfffff01189e0 'a') +0xaaab0b5ab340->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01189e0 } +0xaaab0b5ab340->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189e0 } +0xfffff0118990->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01189e0 } +0xfffff0118990->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff0118990, 0xfffff01189e0 } +0xfffff01189e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01189e0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token -0xffffdb7dd660->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340 } -0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd660 } -0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd660, 0xffffdb7dd760 } -Next token is token 'p' (0xffffdb7dd760 'p'Exception caught: cleaning lookahead and stack -0xaaab15190340->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd760 } -0xaaab15190320->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd760 } -0xaaab15190300->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd760 } -0xaaab151902e0->Object::~Object { 0xaaab151902e0, 0xffffdb7dd760 } -0xffffdb7dd760->Object::~Object { 0xffffdb7dd760 } +0xfffff01188e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340 } +0xfffff01189c0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01188e0 } +0xfffff01188e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01188e0, 0xfffff01189c0 } +Next token is token 'p' (0xfffff01189c0 'p'Exception caught: cleaning lookahead and stack +0xaaab0b5ab340->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01189c0 } +0xaaab0b5ab320->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189c0 } +0xaaab0b5ab300->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189c0 } +0xaaab0b5ab2e0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01189c0 } +0xfffff01189c0->Object::~Object { 0xfffff01189c0 } exception caught: printer end { } +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input i + +stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xaaaadd188f40->Object::Object { } -Next token is token 'a' (0xaaaadd188f40 'a') -Shifting token 'a' (0xaaaadd188f40 'a') +0xfffff01188e0->Object::Object { } +0xfffff01189c0->Object::Object { 0xfffff01188e0 } +0xfffff01188e0->Object::~Object { 0xfffff01188e0, 0xfffff01189c0 } +Next token is token 'a' (0xfffff01189c0 'a') +0xfffff0118920->Object::Object { 0xfffff01189c0 } +0xfffff01188d0->Object::Object { 0xfffff0118920, 0xfffff01189c0 } +0xfffff01188d0->Object::~Object { 0xfffff01188d0, 0xfffff0118920, 0xfffff01189c0 } +0xfffff01189c0->Object::~Object { 0xfffff0118920, 0xfffff01189c0 } +Shifting token 'a' (0xfffff0118920 'a') +0xaaab0b5ab2e0->Object::Object { 0xfffff0118920 } +0xfffff01188a8->Object::Object { 0xaaab0b5ab2e0, 0xfffff0118920 } +0xfffff01188a8->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01188a8, 0xfffff0118920 } +0xfffff0118920->Object::~Object { 0xaaab0b5ab2e0, 0xfffff0118920 } Entering state 1 Stack now 0 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadd188f40 'a') --> $$ = nterm item (0xaaaadd188f40 'a') +0xfffff01189e0->Object::Object { 0xaaab0b5ab2e0 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaab0b5ab2e0 'a') +-> $$ = nterm item (0xfffff01189e0 'a') +0xaaab0b5ab2e0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01189e0 } +0xaaab0b5ab2e0->Object::Object { 0xfffff01189e0 } +0xfffff0118990->Object::Object { 0xaaab0b5ab2e0, 0xfffff01189e0 } +0xfffff0118990->Object::~Object { 0xaaab0b5ab2e0, 0xfffff0118990, 0xfffff01189e0 } +0xfffff01189e0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01189e0 } Entering state 10 Stack now 0 10 Reading a token -0xaaaadd188f90->Object::Object { 0xaaaadd188f40 } -Next token is token 'a' (0xaaaadd188f90 'a') -Shifting token 'a' (0xaaaadd188f90 'a') +0xfffff01188e0->Object::Object { 0xaaab0b5ab2e0 } +0xfffff01189c0->Object::Object { 0xaaab0b5ab2e0, 0xfffff01188e0 } +0xfffff01188e0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01188e0, 0xfffff01189c0 } +Next token is token 'a' (0xfffff01189c0 'a') +0xfffff0118920->Object::Object { 0xaaab0b5ab2e0, 0xfffff01189c0 } +0xfffff01188d0->Object::Object { 0xaaab0b5ab2e0, 0xfffff0118920, 0xfffff01189c0 } +0xfffff01188d0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01188d0, 0xfffff0118920, 0xfffff01189c0 } +0xfffff01189c0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff0118920, 0xfffff01189c0 } +Shifting token 'a' (0xfffff0118920 'a') +0xaaab0b5ab300->Object::Object { 0xaaab0b5ab2e0, 0xfffff0118920 } +0xfffff01188a8->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118920 } +0xfffff01188a8->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01188a8, 0xfffff0118920 } +0xfffff0118920->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118920 } Entering state 1 Stack now 0 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadd188f90 'a') --> $$ = nterm item (0xaaaadd188f90 'a') +0xfffff01189e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaab0b5ab300 'a') +-> $$ = nterm item (0xfffff01189e0 'a') +0xaaab0b5ab300->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189e0 } +0xaaab0b5ab300->Object::Object { 0xaaab0b5ab2e0, 0xfffff01189e0 } +0xfffff0118990->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189e0 } +0xfffff0118990->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118990, 0xfffff01189e0 } +0xfffff01189e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189e0 } Entering state 10 Stack now 0 10 10 Reading a token -0xaaaadd188fe0->Object::Object { 0xaaaadd188f40, 0xaaaadd188f90 } -Next token is token 'a' (0xaaaadd188fe0 'a') -Shifting token 'a' (0xaaaadd188fe0 'a') +0xfffff01188e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300 } +0xfffff01189c0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01188e0 } +0xfffff01188e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01188e0, 0xfffff01189c0 } +Next token is token 'a' (0xfffff01189c0 'a') +0xfffff0118920->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189c0 } +0xfffff01188d0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118920, 0xfffff01189c0 } +0xfffff01188d0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01188d0, 0xfffff0118920, 0xfffff01189c0 } +0xfffff01189c0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118920, 0xfffff01189c0 } +Shifting token 'a' (0xfffff0118920 'a') +0xaaab0b5ab320->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff0118920 } +0xfffff01188a8->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118920 } +0xfffff01188a8->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01188a8, 0xfffff0118920 } +0xfffff0118920->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118920 } Entering state 1 Stack now 0 10 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadd188fe0 'a') --> $$ = nterm item (0xaaaadd188fe0 'a') +0xfffff01189e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaab0b5ab320 'a') +-> $$ = nterm item (0xfffff01189e0 'a') +0xaaab0b5ab320->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189e0 } +0xaaab0b5ab320->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189e0 } +0xfffff0118990->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189e0 } +0xfffff0118990->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118990, 0xfffff01189e0 } +0xfffff01189e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189e0 } Entering state 10 Stack now 0 10 10 10 Reading a token -0xaaaadd189030->Object::Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0 } -Next token is token 'a' (0xaaaadd189030 'a') -Shifting token 'a' (0xaaaadd189030 'a') +0xfffff01188e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320 } +0xfffff01189c0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01188e0 } +0xfffff01188e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01188e0, 0xfffff01189c0 } +Next token is token 'a' (0xfffff01189c0 'a') +0xfffff0118920->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189c0 } +0xfffff01188d0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118920, 0xfffff01189c0 } +0xfffff01188d0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01188d0, 0xfffff0118920, 0xfffff01189c0 } +0xfffff01189c0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118920, 0xfffff01189c0 } +Shifting token 'a' (0xfffff0118920 'a') +0xaaab0b5ab340->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff0118920 } +0xfffff01188a8->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff0118920 } +0xfffff01188a8->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01188a8, 0xfffff0118920 } +0xfffff0118920->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff0118920 } Entering state 1 Stack now 0 10 10 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadd189030 'a') --> $$ = nterm item (0xaaaadd189030 'a') +0xfffff01189e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaab0b5ab340 'a') +-> $$ = nterm item (0xfffff01189e0 'a') +0xaaab0b5ab340->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01189e0 } +0xaaab0b5ab340->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189e0 } +0xfffff0118990->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01189e0 } +0xfffff0118990->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff0118990, 0xfffff01189e0 } +0xfffff01189e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01189e0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token -0xaaaadd189080->Object::Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0, 0xaaaadd189030 } -Next token is token 'p' (0xaaaadd189080 'p'Exception caught: cleaning lookahead and stack -0xaaaadd189080->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0, 0xaaaadd189030, 0xaaaadd189080 } -0xaaaadd189030->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0, 0xaaaadd189030 } -0xaaaadd188fe0->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0 } -0xaaaadd188f90->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90 } -0xaaaadd188f40->Object::~Object { 0xaaaadd188f40 } +0xfffff01188e0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340 } +0xfffff01189c0->Object::Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01188e0 } +0xfffff01188e0->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01188e0, 0xfffff01189c0 } +Next token is token 'p' (0xfffff01189c0 'p'Exception caught: cleaning lookahead and stack +0xaaab0b5ab340->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xaaab0b5ab340, 0xfffff01189c0 } +0xaaab0b5ab320->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xaaab0b5ab320, 0xfffff01189c0 } +0xaaab0b5ab300->Object::~Object { 0xaaab0b5ab2e0, 0xaaab0b5ab300, 0xfffff01189c0 } +0xaaab0b5ab2e0->Object::~Object { 0xaaab0b5ab2e0, 0xfffff01189c0 } +0xfffff01189c0->Object::~Object { 0xfffff01189c0 } exception caught: printer end { } +./c++.at:1363: grep '^exception caught: printer$' stderr +stdout: +exception caught: initial-action +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +exception caught: printer +./c++.at:1363: $PREPARSER ./input aaaae +stderr: +exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input aaaap stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -696. java.at:307: Starting parse +./c++.at:1363: $PREPARSER ./input aaaaE +700. java.at:528: testing Java syntax error handling without error token ... +stderr: +./java.at:579: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret YYParser.y +./c++.at:1361: $PREPARSER ./input --debug aaaap +stderr: +exception caught: syntax error, unexpected end of file, expecting 'a' +stdout: +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +Starting parse Entering state 0 Stack now 0 Reading a token -0xffffdb7dd660->Object::Object { } -0xffffdb7dd760->Object::Object { 0xffffdb7dd660 } -0xffffdb7dd660->Object::~Object { 0xffffdb7dd660, 0xffffdb7dd760 } -Next token is token 'a' (0xffffdb7dd760 'a') -0xffffdb7dd6a0->Object::Object { 0xffffdb7dd760 } -0xffffdb7dd760->Object::~Object { 0xffffdb7dd6a0, 0xffffdb7dd760 } -Shifting token 'a' (0xffffdb7dd6a0 'a') -0xaaab151902e0->Object::Object { 0xffffdb7dd6a0 } -0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xffffdb7dd6a0 } +0xaaaae669ef40->Object::Object { } +Next token is token 'a' (0xaaaae669ef40 'a') +Shifting token 'a' (0xaaaae669ef40 'a') Entering state 1 Stack now 0 1 -0xffffdb7dd780->Object::Object { 0xaaab151902e0 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab151902e0 'a') --> $$ = nterm item (0xffffdb7dd780 'a') -0xaaab151902e0->Object::~Object { 0xaaab151902e0, 0xffffdb7dd780 } -0xaaab151902e0->Object::Object { 0xffffdb7dd780 } -0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xffffdb7dd780 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaae669ef40 'a') +-> $$ = nterm item (0xaaaae669ef40 'a') Entering state 10 Stack now 0 10 Reading a token -0xffffdb7dd660->Object::Object { 0xaaab151902e0 } -0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xffffdb7dd660 } -0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xffffdb7dd660, 0xffffdb7dd760 } -Next token is token 'a' (0xffffdb7dd760 'a') -0xffffdb7dd6a0->Object::Object { 0xaaab151902e0, 0xffffdb7dd760 } -0xffffdb7dd760->Object::~Object { 0xaaab151902e0, 0xffffdb7dd6a0, 0xffffdb7dd760 } -Shifting token 'a' (0xffffdb7dd6a0 'a') -0xaaab15190300->Object::Object { 0xaaab151902e0, 0xffffdb7dd6a0 } -0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd6a0 } +0xaaaae669ef90->Object::Object { 0xaaaae669ef40 } +Next token is token 'a' (0xaaaae669ef90 'a') +Shifting token 'a' (0xaaaae669ef90 'a') Entering state 1 Stack now 0 10 1 -0xffffdb7dd780->Object::Object { 0xaaab151902e0, 0xaaab15190300 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab15190300 'a') --> $$ = nterm item (0xffffdb7dd780 'a') -0xaaab15190300->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd780 } -0xaaab15190300->Object::Object { 0xaaab151902e0, 0xffffdb7dd780 } -0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd780 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaae669ef90 'a') +-> $$ = nterm item (0xaaaae669ef90 'a') Entering state 10 Stack now 0 10 10 Reading a token -0xffffdb7dd660->Object::Object { 0xaaab151902e0, 0xaaab15190300 } -0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd660 } -0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd660, 0xffffdb7dd760 } -Next token is token 'a' (0xffffdb7dd760 'a') -0xffffdb7dd6a0->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd760 } -0xffffdb7dd760->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd6a0, 0xffffdb7dd760 } -Shifting token 'a' (0xffffdb7dd6a0 'a') -0xaaab15190320->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd6a0 } -0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd6a0 } +0xaaaae669efe0->Object::Object { 0xaaaae669ef40, 0xaaaae669ef90 } +Next token is token 'a' (0xaaaae669efe0 'a') +Shifting token 'a' (0xaaaae669efe0 'a') Entering state 1 Stack now 0 10 10 1 -0xffffdb7dd780->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab15190320 'a') --> $$ = nterm item (0xffffdb7dd780 'a') -0xaaab15190320->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd780 } -0xaaab15190320->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd780 } -0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd780 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaae669efe0 'a') +-> $$ = nterm item (0xaaaae669efe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token -0xffffdb7dd660->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320 } -0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd660 } -0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd660, 0xffffdb7dd760 } -Next token is token 'a' (0xffffdb7dd760 'a') -0xffffdb7dd6a0->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd760 } -0xffffdb7dd760->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd6a0, 0xffffdb7dd760 } -Shifting token 'a' (0xffffdb7dd6a0 'a') -0xaaab15190340->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd6a0 } -0xffffdb7dd6a0->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd6a0 } +0xaaaae669f030->Object::Object { 0xaaaae669ef40, 0xaaaae669ef90, 0xaaaae669efe0 } +Next token is token 'a' (0xaaaae669f030 'a') +Shifting token 'a' (0xaaaae669f030 'a') Entering state 1 Stack now 0 10 10 10 1 -0xffffdb7dd780->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaab15190340 'a') --> $$ = nterm item (0xffffdb7dd780 'a') -0xaaab15190340->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd780 } -0xaaab15190340->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd780 } -0xffffdb7dd780->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd780 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaae669f030 'a') +-> $$ = nterm item (0xaaaae669f030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token -0xffffdb7dd660->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340 } -0xffffdb7dd760->Object::Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd660 } -0xffffdb7dd660->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd660, 0xffffdb7dd760 } -Next token is token 'p' (0xffffdb7dd760 'p'Exception caught: cleaning lookahead and stack -0xaaab15190340->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xaaab15190340, 0xffffdb7dd760 } -0xaaab15190320->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xaaab15190320, 0xffffdb7dd760 } -0xaaab15190300->Object::~Object { 0xaaab151902e0, 0xaaab15190300, 0xffffdb7dd760 } -0xaaab151902e0->Object::~Object { 0xaaab151902e0, 0xffffdb7dd760 } -0xffffdb7dd760->Object::~Object { 0xffffdb7dd760 } +0xaaaae669f080->Object::Object { 0xaaaae669ef40, 0xaaaae669ef90, 0xaaaae669efe0, 0xaaaae669f030 } +Next token is token 'p' (0xaaaae669f080 'p'Exception caught: cleaning lookahead and stack +0xaaaae669f080->Object::~Object { 0xaaaae669ef40, 0xaaaae669ef90, 0xaaaae669efe0, 0xaaaae669f030, 0xaaaae669f080 } +0xaaaae669f030->Object::~Object { 0xaaaae669ef40, 0xaaaae669ef90, 0xaaaae669efe0, 0xaaaae669f030 } +0xaaaae669efe0->Object::~Object { 0xaaaae669ef40, 0xaaaae669ef90, 0xaaaae669efe0 } +0xaaaae669ef90->Object::~Object { 0xaaaae669ef40, 0xaaaae669ef90 } +0xaaaae669ef40->Object::~Object { 0xaaaae669ef40 } exception caught: printer end { } - skipped (java.at:309) -./c++.at:1363: grep '^exception caught: printer$' stderr - -stdout: +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1555: $PREPARSER ./test +./c++.at:1363: $PREPARSER ./input aaaaT +stderr: +stderr: stderr: -exception caught: printer -./c++.at:1363: $PREPARSER ./input aaaae Starting parse Entering state 0 Stack now 0 Reading a token -0xaaaadd188f40->Object::Object { } -Next token is token 'a' (0xaaaadd188f40 'a') -Shifting token 'a' (0xaaaadd188f40 'a') +0xaaaae669ef40->Object::Object { } +Next token is token 'a' (0xaaaae669ef40 'a') +Shifting token 'a' (0xaaaae669ef40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadd188f40 'a') --> $$ = nterm item (0xaaaadd188f40 'a') + $1 = token 'a' (0xaaaae669ef40 'a') +-> $$ = nterm item (0xaaaae669ef40 'a') Entering state 10 Stack now 0 10 Reading a token -0xaaaadd188f90->Object::Object { 0xaaaadd188f40 } -Next token is token 'a' (0xaaaadd188f90 'a') -Shifting token 'a' (0xaaaadd188f90 'a') +0xaaaae669ef90->Object::Object { 0xaaaae669ef40 } +Next token is token 'a' (0xaaaae669ef90 'a') +Shifting token 'a' (0xaaaae669ef90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadd188f90 'a') --> $$ = nterm item (0xaaaadd188f90 'a') + $1 = token 'a' (0xaaaae669ef90 'a') +-> $$ = nterm item (0xaaaae669ef90 'a') Entering state 10 Stack now 0 10 10 Reading a token -0xaaaadd188fe0->Object::Object { 0xaaaadd188f40, 0xaaaadd188f90 } -Next token is token 'a' (0xaaaadd188fe0 'a') -Shifting token 'a' (0xaaaadd188fe0 'a') +0xaaaae669efe0->Object::Object { 0xaaaae669ef40, 0xaaaae669ef90 } +Next token is token 'a' (0xaaaae669efe0 'a') +Shifting token 'a' (0xaaaae669efe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadd188fe0 'a') --> $$ = nterm item (0xaaaadd188fe0 'a') + $1 = token 'a' (0xaaaae669efe0 'a') +-> $$ = nterm item (0xaaaae669efe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token -0xaaaadd189030->Object::Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0 } -Next token is token 'a' (0xaaaadd189030 'a') -Shifting token 'a' (0xaaaadd189030 'a') +0xaaaae669f030->Object::Object { 0xaaaae669ef40, 0xaaaae669ef90, 0xaaaae669efe0 } +Next token is token 'a' (0xaaaae669f030 'a') +Shifting token 'a' (0xaaaae669f030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaadd189030 'a') --> $$ = nterm item (0xaaaadd189030 'a') + $1 = token 'a' (0xaaaae669f030 'a') +-> $$ = nterm item (0xaaaae669f030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token -0xaaaadd189080->Object::Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0, 0xaaaadd189030 } -Next token is token 'p' (0xaaaadd189080 'p'Exception caught: cleaning lookahead and stack -0xaaaadd189080->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0, 0xaaaadd189030, 0xaaaadd189080 } -0xaaaadd189030->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0, 0xaaaadd189030 } -0xaaaadd188fe0->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90, 0xaaaadd188fe0 } -0xaaaadd188f90->Object::~Object { 0xaaaadd188f40, 0xaaaadd188f90 } -0xaaaadd188f40->Object::~Object { 0xaaaadd188f40 } +0xaaaae669f080->Object::Object { 0xaaaae669ef40, 0xaaaae669ef90, 0xaaaae669efe0, 0xaaaae669f030 } +Next token is token 'p' (0xaaaae669f080 'p'Exception caught: cleaning lookahead and stack +0xaaaae669f080->Object::~Object { 0xaaaae669ef40, 0xaaaae669ef90, 0xaaaae669efe0, 0xaaaae669f030, 0xaaaae669f080 } +0xaaaae669f030->Object::~Object { 0xaaaae669ef40, 0xaaaae669ef90, 0xaaaae669efe0, 0xaaaae669f030 } +0xaaaae669efe0->Object::~Object { 0xaaaae669ef40, 0xaaaae669ef90, 0xaaaae669efe0 } +0xaaaae669ef90->Object::~Object { 0xaaaae669ef40, 0xaaaae669ef90 } +0xaaaae669ef40->Object::~Object { 0xaaaae669ef40 } exception caught: printer end { } -stderr: -stdout: ./c++.at:1361: grep '^exception caught: printer$' stderr -./c++.at:851: $PREPARSER ./input -stderr: +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: +./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1363: $PREPARSER ./input aaaaR exception caught: printer -./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: $PREPARSER ./input aaaae +700. java.at:528: ./c++.at:1361: $PREPARSER ./input aaaae stderr: ======== Testing with C++ standard flags: '' -./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + skipped (java.at:580) exception caught: syntax error ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -exception caught: syntax error -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1363: $PREPARSER ./input aaaaE +./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +======== Testing with C++ standard flags: '' +stderr: +./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stdout: ./c++.at:1361: $PREPARSER ./input aaaaE +./c++.at:850: $PREPARSER ./input + stderr: -697. java.at:381: testing Java throws specifications ... -./java.at:441: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y stderr: exception caught: syntax error, unexpected end of file, expecting 'a' -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./java.at:441: grep '[mb]4_' YYParser.y -stdout: +./c++.at:850: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaT +./c++.at:851: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy stderr: -697. java.at:381: ./c++.at:1363: $PREPARSER ./input aaaaT ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +701. javapush.at:172: testing Trivial Push Parser with api.push-pull verification ... +./javapush.at:181: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dapi.push-pull=pull -o Main.java input.y stderr: - skipped (java.at:441) -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaR -./c++.at:1363: $PREPARSER ./input aaaaR -stderr: stderr: -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS - -======== Testing with C++ standard flags: '' -./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./c++.at:857: $PREPARSER ./input -stderr: -./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1555: ./check +./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y ======== Testing with C++ standard flags: '' -./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -698. java.at:470: testing Java constructor init and init_throws ... -./java.at:475: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y -stderr: -stdout: -689. c++.at:1371: ok - -./java.at:475: grep '[mb]4_' YYParser.y -stdout: -698. java.at:470: skipped (java.at:475) - -699. java.at:497: testing Java value, position, and location types ... -./java.at:499: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y -./java.at:499: grep '[mb]4_' YYParser.y -stdout: -700. java.at:528: testing Java syntax error handling without error token ... -./java.at:579: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret YYParser.y -699. java.at:497: skipped (java.at:499) -stderr: - -stdout: -./c++.at:1065: $PREPARSER ./input < in -700. java.at:528: stderr: - skipped (java.at:580) -error: invalid expression -caught error -error: invalid character -caught error -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -701. javapush.at:172: testing Trivial Push Parser with api.push-pull verification ... -./javapush.at:181: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dapi.push-pull=pull -o Main.java input.y - -./c++.at:1065: $PREPARSER ./input < in -stderr: -error: invalid expression -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1065: $PREPARSER ./input < in +./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./javapush.at:182: grep -c '^.*public boolean parse().*$' Main.java -702. javapush.at:217: testing Trivial Push Parser with %initial-action ... -stderr: -error: invalid character -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./javapush.at:227: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dapi.push-pull=push -o Main.java input.y ./javapush.at:187: grep -c '^.*public int push_parse(int yylextoken, Object yylexval).*$' Main.java -======== Testing with C++ standard flags: '' -./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS ./javapush.at:191: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dapi.push-pull=both -o Main.java input.y -./javapush.at:228: grep -c '^System.err.println("Initial action invoked");$' Main.java +./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS ./javapush.at:192: grep -c '^.*public boolean parse().*$' Main.java -702. javapush.at:217: skipped (javapush.at:230) ./javapush.at:195: grep -c '^.*public int push_parse(int yylextoken, Object yylexval).*$' Main.java -stderr: -stdout: -./c++.at:851: $PREPARSER ./input -stderr: -stderr: -./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: - -./c++.at:1555: $PREPARSER ./test ./javapush.at:199: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dapi.push-pull=push -o Main.java input.y -======== Testing with C++ standard flags: '' -stderr: -./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS ./javapush.at:200: grep -c '^.*public boolean parse().*$' Main.java ./javapush.at:203: grep -c '^.*public int push_parse(int yylextoken, Object yylexval).*$' Main.java +701. javapush.at:172: skipped (javapush.at:207) stderr: stdout: -./c++.at:1555: ./check -703. d.at:103: testing D parser class extends and implements ... -./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y -./d.at:106: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y -701. javapush.at:172: ./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS - skipped (javapush.at:207) -./d.at:106: grep '[mb]4_' YYParser.y -stdout: - -703. d.at:103: skipped (d.at:106) -704. d.at:138: testing D parser class api.token.raw true by default ... - -./d.at:141: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y -./d.at:141: grep '[mb]4_' YYParser.y -stdout: -705. cxx-type.at:409: testing GLR: Resolve ambiguity, impure, no locations ... -704. d.at:138: skipped (d.at:141) -./cxx-type.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y -stderr: -stdout: - -./c++.at:857: $PREPARSER ./input -stderr: -types.y:77.8-37: warning: unset value: $$ [-Wother] -types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] -types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -stderr: -./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./cxx-type.at:410: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS -======== Testing with C++ standard flags: '' -./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -706. cxx-type.at:415: testing GLR: Resolve ambiguity, impure, locations ... -./cxx-type.at:416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y -stderr: -stderr: -types.y:87.8-37: warning: unset value: $$ [-Wother] -types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] -types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -stdout: ./c++.at:1362: $PREPARSER ./input aaaas -./cxx-type.at:416: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS stderr: exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: + ./c++.at:1362: $PREPARSER ./input aaaal -stdout: stderr: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input aaaas stderr: -exception caught: reduction -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: ./c++.at:1362: $PREPARSER ./input i +./c++.at:1360: $PREPARSER ./input aaaas stderr: +stderr: +702. javapush.at:217: testing Trivial Push Parser with %initial-action ... exception caught: initial-action -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +exception caught: reduction +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: $PREPARSER ./input aaaal stderr: -./c++.at:1362: $PREPARSER ./input aaaap +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./javapush.at:227: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Dapi.push-pull=push -o Main.java input.y exception caught: yylex ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: $PREPARSER ./input i +stderr: +exception caught: initial-action +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1362: $PREPARSER ./input aaaap stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input i +./c++.at:1360: $PREPARSER ./input aaaap ./c++.at:1362: $PREPARSER ./input --debug aaaap +./javapush.at:228: grep -c '^System.err.println("Initial action invoked");$' Main.java stderr: -exception caught: initial-action stderr: ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token -0xffffde9c34f0->Object::Object { } -0xffffde9c35a0->Object::Object { 0xffffde9c34f0 } -0xffffde9c34f0->Object::~Object { 0xffffde9c34f0, 0xffffde9c35a0 } -Next token is token 'a' (0xffffde9c35a0 'a') -0xffffde9c34e0->Object::Object { 0xffffde9c35a0 } -0xffffde9c35a0->Object::~Object { 0xffffde9c34e0, 0xffffde9c35a0 } -Shifting token 'a' (0xffffde9c34e0 'a') -0xaaaafb6772e0->Object::Object { 0xffffde9c34e0 } -0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c34e0 } +0xffffdb39e910->Object::Object { } +0xffffdb39e9c0->Object::Object { 0xffffdb39e910 } +0xffffdb39e910->Object::~Object { 0xffffdb39e910, 0xffffdb39e9c0 } +Next token is token 'a' (0xffffdb39e9c0 'a') +0xffffdb39e900->Object::Object { 0xffffdb39e9c0 } +0xffffdb39e9c0->Object::~Object { 0xffffdb39e900, 0xffffdb39e9c0 } +Shifting token 'a' (0xffffdb39e900 'a') +0xaaaae652d2e0->Object::Object { 0xffffdb39e900 } +0xffffdb39e900->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e900 } Entering state 2 Stack now 0 2 -0xffffde9c35c0->Object::Object { 0xaaaafb6772e0 } +0xffffdb39e9e0->Object::Object { 0xaaaae652d2e0 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaafb6772e0 'a') --> $$ = nterm item (0xffffde9c35c0 'a') -0xaaaafb6772e0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c35c0 } -0xaaaafb6772e0->Object::Object { 0xffffde9c35c0 } -0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c35c0 } + $1 = token 'a' (0xaaaae652d2e0 'a') +-> $$ = nterm item (0xffffdb39e9e0 'a') +0xaaaae652d2e0->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e9e0 } +0xaaaae652d2e0->Object::Object { 0xffffdb39e9e0 } +0xffffdb39e9e0->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e9e0 } Entering state 11 Stack now 0 11 Reading a token -0xffffde9c34f0->Object::Object { 0xaaaafb6772e0 } -0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xffffde9c34f0 } -0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c34f0, 0xffffde9c35a0 } -Next token is token 'a' (0xffffde9c35a0 'a') -0xffffde9c34e0->Object::Object { 0xaaaafb6772e0, 0xffffde9c35a0 } -0xffffde9c35a0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c34e0, 0xffffde9c35a0 } -Shifting token 'a' (0xffffde9c34e0 'a') -0xaaaafb677300->Object::Object { 0xaaaafb6772e0, 0xffffde9c34e0 } -0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34e0 } +0xffffdb39e910->Object::Object { 0xaaaae652d2e0 } +0xffffdb39e9c0->Object::Object { 0xaaaae652d2e0, 0xffffdb39e910 } +0xffffdb39e910->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e910, 0xffffdb39e9c0 } +Next token is token 'a' (0xffffdb39e9c0 'a') +0xffffdb39e900->Object::Object { 0xaaaae652d2e0, 0xffffdb39e9c0 } +0xffffdb39e9c0->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e900, 0xffffdb39e9c0 } +Shifting token 'a' (0xffffdb39e900 'a') +0xaaaae652d300->Object::Object { 0xaaaae652d2e0, 0xffffdb39e900 } +0xffffdb39e900->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e900 } Entering state 2 Stack now 0 11 2 -0xffffde9c35c0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300 } +0xffffdb39e9e0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaafb677300 'a') --> $$ = nterm item (0xffffde9c35c0 'a') -0xaaaafb677300->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35c0 } -0xaaaafb677300->Object::Object { 0xaaaafb6772e0, 0xffffde9c35c0 } -0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35c0 } + $1 = token 'a' (0xaaaae652d300 'a') +-> $$ = nterm item (0xffffdb39e9e0 'a') +0xaaaae652d300->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e9e0 } +0xaaaae652d300->Object::Object { 0xaaaae652d2e0, 0xffffdb39e9e0 } +0xffffdb39e9e0->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e9e0 } Entering state 11 Stack now 0 11 11 Reading a token -0xffffde9c34f0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300 } -0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34f0 } -0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34f0, 0xffffde9c35a0 } -Next token is token 'a' (0xffffde9c35a0 'a') -0xffffde9c34e0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35a0 } -0xffffde9c35a0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34e0, 0xffffde9c35a0 } -Shifting token 'a' (0xffffde9c34e0 'a') -0xaaaafb677320->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34e0 } -0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34e0 } +0xffffdb39e910->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300 } +0xffffdb39e9c0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e910 } +0xffffdb39e910->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e910, 0xffffdb39e9c0 } +Next token is token 'a' (0xffffdb39e9c0 'a') +0xffffdb39e900->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e9c0 } +0xffffdb39e9c0->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e900, 0xffffdb39e9c0 } +Shifting token 'a' (0xffffdb39e900 'a') +0xaaaae652d320->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e900 } +0xffffdb39e900->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e900 } Entering state 2 Stack now 0 11 11 2 -0xffffde9c35c0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320 } +0xffffdb39e9e0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaafb677320 'a') --> $$ = nterm item (0xffffde9c35c0 'a') -0xaaaafb677320->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35c0 } -0xaaaafb677320->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35c0 } -0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35c0 } + $1 = token 'a' (0xaaaae652d320 'a') +-> $$ = nterm item (0xffffdb39e9e0 'a') +0xaaaae652d320->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e9e0 } +0xaaaae652d320->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e9e0 } +0xffffdb39e9e0->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e9e0 } Entering state 11 Stack now 0 11 11 11 Reading a token -0xffffde9c34f0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320 } -0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34f0 } -0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34f0, 0xffffde9c35a0 } -Next token is token 'a' (0xffffde9c35a0 'a') -0xffffde9c34e0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35a0 } -0xffffde9c35a0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34e0, 0xffffde9c35a0 } -Shifting token 'a' (0xffffde9c34e0 'a') -0xaaaafb677340->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34e0 } -0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c34e0 } +0xffffdb39e910->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320 } +0xffffdb39e9c0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e910 } +0xffffdb39e910->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e910, 0xffffdb39e9c0 } +Next token is token 'a' (0xffffdb39e9c0 'a') +0xffffdb39e900->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e9c0 } +0xffffdb39e9c0->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e900, 0xffffdb39e9c0 } +Shifting token 'a' (0xffffdb39e900 'a') +0xaaaae652d340->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e900 } +0xffffdb39e900->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e900 } Entering state 2 Stack now 0 11 11 11 2 -0xffffde9c35c0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340 } +0xffffdb39e9e0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaafb677340 'a') --> $$ = nterm item (0xffffde9c35c0 'a') -0xaaaafb677340->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c35c0 } -0xaaaafb677340->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35c0 } -0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c35c0 } + $1 = token 'a' (0xaaaae652d340 'a') +-> $$ = nterm item (0xffffdb39e9e0 'a') +0xaaaae652d340->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e9e0 } +0xaaaae652d340->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e9e0 } +0xffffdb39e9e0->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e9e0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token -0xffffde9c34f0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340 } -0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c34f0 } -0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c34f0, 0xffffde9c35a0 } -Next token is token 'p' (0xffffde9c35a0 'p'Exception caught: cleaning lookahead and stack -0xaaaafb677340->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c35a0 } -0xaaaafb677320->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35a0 } -0xaaaafb677300->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35a0 } -0xaaaafb6772e0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c35a0 } -0xffffde9c35a0->Object::~Object { 0xffffde9c35a0 } +0xffffdb39e910->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340 } +0xffffdb39e9c0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e910 } +0xffffdb39e910->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e910, 0xffffdb39e9c0 } +Next token is token 'p' (0xffffdb39e9c0 'p'Exception caught: cleaning lookahead and stack +0xaaaae652d340->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e9c0 } +0xaaaae652d320->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e9c0 } +0xaaaae652d300->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e9c0 } +0xaaaae652d2e0->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e9c0 } +0xffffdb39e9c0->Object::~Object { 0xffffdb39e9c0 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input aaaap +./c++.at:1360: $PREPARSER ./input --debug aaaap stderr: stderr: -Starting parse +702. javapush.at:217: Starting parse Entering state 0 Stack now 0 Reading a token -0xffffde9c34f0->Object::Object { } -0xffffde9c35a0->Object::Object { 0xffffde9c34f0 } -0xffffde9c34f0->Object::~Object { 0xffffde9c34f0, 0xffffde9c35a0 } -Next token is token 'a' (0xffffde9c35a0 'a') -0xffffde9c34e0->Object::Object { 0xffffde9c35a0 } -0xffffde9c35a0->Object::~Object { 0xffffde9c34e0, 0xffffde9c35a0 } -Shifting token 'a' (0xffffde9c34e0 'a') -0xaaaafb6772e0->Object::Object { 0xffffde9c34e0 } -0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c34e0 } +0xaaaac60a2f40->Object::Object { } +Next token is token 'a' (0xaaaac60a2f40 'a') +Shifting token 'a' (0xaaaac60a2f40 'a') Entering state 2 Stack now 0 2 -0xffffde9c35c0->Object::Object { 0xaaaafb6772e0 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaafb6772e0 'a') --> $$ = nterm item (0xffffde9c35c0 'a') -0xaaaafb6772e0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c35c0 } -0xaaaafb6772e0->Object::Object { 0xffffde9c35c0 } -0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c35c0 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac60a2f40 'a') +-> $$ = nterm item (0xaaaac60a2f40 'a') Entering state 11 Stack now 0 11 Reading a token -0xffffde9c34f0->Object::Object { 0xaaaafb6772e0 } -0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xffffde9c34f0 } -0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c34f0, 0xffffde9c35a0 } -Next token is token 'a' (0xffffde9c35a0 'a') -0xffffde9c34e0->Object::Object { 0xaaaafb6772e0, 0xffffde9c35a0 } -0xffffde9c35a0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c34e0, 0xffffde9c35a0 } -Shifting token 'a' (0xffffde9c34e0 'a') -0xaaaafb677300->Object::Object { 0xaaaafb6772e0, 0xffffde9c34e0 } -0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34e0 } +0xaaaac60a2f90->Object::Object { 0xaaaac60a2f40 } +Next token is token 'a' (0xaaaac60a2f90 'a') +Shifting token 'a' (0xaaaac60a2f90 'a') Entering state 2 Stack now 0 11 2 -0xffffde9c35c0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaafb677300 'a') --> $$ = nterm item (0xffffde9c35c0 'a') -0xaaaafb677300->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35c0 } -0xaaaafb677300->Object::Object { 0xaaaafb6772e0, 0xffffde9c35c0 } -0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35c0 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac60a2f90 'a') +-> $$ = nterm item (0xaaaac60a2f90 'a') Entering state 11 Stack now 0 11 11 Reading a token -0xffffde9c34f0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300 } -0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34f0 } -0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34f0, 0xffffde9c35a0 } -Next token is token 'a' (0xffffde9c35a0 'a') -0xffffde9c34e0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35a0 } -0xffffde9c35a0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34e0, 0xffffde9c35a0 } -Shifting token 'a' (0xffffde9c34e0 'a') -0xaaaafb677320->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c34e0 } -0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34e0 } +0xaaaac60a2fe0->Object::Object { 0xaaaac60a2f40, 0xaaaac60a2f90 } +Next token is token 'a' (0xaaaac60a2fe0 'a') +Shifting token 'a' (0xaaaac60a2fe0 'a') Entering state 2 Stack now 0 11 11 2 -0xffffde9c35c0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaafb677320 'a') --> $$ = nterm item (0xffffde9c35c0 'a') -0xaaaafb677320->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35c0 } -0xaaaafb677320->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35c0 } -0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35c0 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac60a2fe0 'a') +-> $$ = nterm item (0xaaaac60a2fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token -0xffffde9c34f0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320 } -0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34f0 } -0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34f0, 0xffffde9c35a0 } -Next token is token 'a' (0xffffde9c35a0 'a') -0xffffde9c34e0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35a0 } -0xffffde9c35a0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34e0, 0xffffde9c35a0 } -Shifting token 'a' (0xffffde9c34e0 'a') -0xaaaafb677340->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c34e0 } -0xffffde9c34e0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c34e0 } +0xaaaac60a3030->Object::Object { 0xaaaac60a2f40, 0xaaaac60a2f90, 0xaaaac60a2fe0 } +Next token is token 'a' (0xaaaac60a3030 'a') +Shifting token 'a' (0xaaaac60a3030 'a') Entering state 2 Stack now 0 11 11 11 2 -0xffffde9c35c0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaafb677340 'a') --> $$ = nterm item (0xffffde9c35c0 'a') -0xaaaafb677340->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c35c0 } -0xaaaafb677340->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35c0 } -0xffffde9c35c0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c35c0 } +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac60a3030 'a') +-> $$ = nterm item (0xaaaac60a3030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token -0xffffde9c34f0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340 } -0xffffde9c35a0->Object::Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c34f0 } -0xffffde9c34f0->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c34f0, 0xffffde9c35a0 } -Next token is token 'p' (0xffffde9c35a0 'p'Exception caught: cleaning lookahead and stack -0xaaaafb677340->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xaaaafb677340, 0xffffde9c35a0 } -0xaaaafb677320->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xaaaafb677320, 0xffffde9c35a0 } -0xaaaafb677300->Object::~Object { 0xaaaafb6772e0, 0xaaaafb677300, 0xffffde9c35a0 } -0xaaaafb6772e0->Object::~Object { 0xaaaafb6772e0, 0xffffde9c35a0 } -0xffffde9c35a0->Object::~Object { 0xffffde9c35a0 } +0xaaaac60a3080->Object::Object { 0xaaaac60a2f40, 0xaaaac60a2f90, 0xaaaac60a2fe0, 0xaaaac60a3030 } +Next token is token 'p' (0xaaaac60a3080 'p'Exception caught: cleaning lookahead and stack +0xaaaac60a3080->Object::~Object { 0xaaaac60a2f40, 0xaaaac60a2f90, 0xaaaac60a2fe0, 0xaaaac60a3030, 0xaaaac60a3080 } +0xaaaac60a3030->Object::~Object { 0xaaaac60a2f40, 0xaaaac60a2f90, 0xaaaac60a2fe0, 0xaaaac60a3030 } +0xaaaac60a2fe0->Object::~Object { 0xaaaac60a2f40, 0xaaaac60a2f90, 0xaaaac60a2fe0 } +0xaaaac60a2f90->Object::~Object { 0xaaaac60a2f40, 0xaaaac60a2f90 } +0xaaaac60a2f40->Object::~Object { 0xaaaac60a2f40 } exception caught: printer end { } ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1362: grep '^exception caught: printer$' stderr -stdout: -exception caught: printer -./c++.at:1362: $PREPARSER ./input aaaae -./c++.at:1360: $PREPARSER ./input --debug aaaap -stderr: -stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xaaab051e6f40->Object::Object { } -Next token is token 'a' (0xaaab051e6f40 'a') -Shifting token 'a' (0xaaab051e6f40 'a') +0xffffdb39e910->Object::Object { } +0xffffdb39e9c0->Object::Object { 0xffffdb39e910 } +0xffffdb39e910->Object::~Object { 0xffffdb39e910, 0xffffdb39e9c0 } +Next token is token 'a' (0xffffdb39e9c0 'a') +0xffffdb39e900->Object::Object { 0xffffdb39e9c0 } +0xffffdb39e9c0->Object::~Object { 0xffffdb39e900, 0xffffdb39e9c0 } +Shifting token 'a' (0xffffdb39e900 'a') +0xaaaae652d2e0->Object::Object { 0xffffdb39e900 } +0xffffdb39e900->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e900 } Entering state 2 Stack now 0 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaab051e6f40 'a') --> $$ = nterm item (0xaaab051e6f40 'a') +0xffffdb39e9e0->Object::Object { 0xaaaae652d2e0 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaae652d2e0 'a') +-> $$ = nterm item (0xffffdb39e9e0 'a') +0xaaaae652d2e0->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e9e0 } +0xaaaae652d2e0->Object::Object { 0xffffdb39e9e0 } +0xffffdb39e9e0->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e9e0 } Entering state 11 Stack now 0 11 Reading a token -0xaaab051e6f90->Object::Object { 0xaaab051e6f40 } -Next token is token 'a' (0xaaab051e6f90 'a') -Shifting token 'a' (0xaaab051e6f90 'a') +0xffffdb39e910->Object::Object { 0xaaaae652d2e0 } +0xffffdb39e9c0->Object::Object { 0xaaaae652d2e0, 0xffffdb39e910 } +0xffffdb39e910->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e910, 0xffffdb39e9c0 } +Next token is token 'a' (0xffffdb39e9c0 'a') +0xffffdb39e900->Object::Object { 0xaaaae652d2e0, 0xffffdb39e9c0 } +0xffffdb39e9c0->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e900, 0xffffdb39e9c0 } +Shifting token 'a' (0xffffdb39e900 'a') +0xaaaae652d300->Object::Object { 0xaaaae652d2e0, 0xffffdb39e900 } +0xffffdb39e900->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e900 } Entering state 2 Stack now 0 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaab051e6f90 'a') --> $$ = nterm item (0xaaab051e6f90 'a') +0xffffdb39e9e0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaae652d300 'a') +-> $$ = nterm item (0xffffdb39e9e0 'a') +0xaaaae652d300->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e9e0 } +0xaaaae652d300->Object::Object { 0xaaaae652d2e0, 0xffffdb39e9e0 } +0xffffdb39e9e0->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e9e0 } Entering state 11 Stack now 0 11 11 Reading a token -0xaaab051e6fe0->Object::Object { 0xaaab051e6f40, 0xaaab051e6f90 } -Next token is token 'a' (0xaaab051e6fe0 'a') -Shifting token 'a' (0xaaab051e6fe0 'a') +0xffffdb39e910->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300 } +0xffffdb39e9c0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e910 } +0xffffdb39e910->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e910, 0xffffdb39e9c0 } +Next token is token 'a' (0xffffdb39e9c0 'a') +0xffffdb39e900->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e9c0 } +0xffffdb39e9c0->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e900, 0xffffdb39e9c0 } +Shifting token 'a' (0xffffdb39e900 'a') +0xaaaae652d320->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e900 } +0xffffdb39e900->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e900 } Entering state 2 Stack now 0 11 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaab051e6fe0 'a') --> $$ = nterm item (0xaaab051e6fe0 'a') +0xffffdb39e9e0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaae652d320 'a') +-> $$ = nterm item (0xffffdb39e9e0 'a') +0xaaaae652d320->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e9e0 } +0xaaaae652d320->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e9e0 } +0xffffdb39e9e0->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e9e0 } Entering state 11 Stack now 0 11 11 11 Reading a token -0xaaab051e7030->Object::Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0 } -Next token is token 'a' (0xaaab051e7030 'a') -Shifting token 'a' (0xaaab051e7030 'a') +0xffffdb39e910->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320 } +0xffffdb39e9c0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e910 } +0xffffdb39e910->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e910, 0xffffdb39e9c0 } +Next token is token 'a' (0xffffdb39e9c0 'a') +0xffffdb39e900->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e9c0 } +0xffffdb39e9c0->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e900, 0xffffdb39e9c0 } +Shifting token 'a' (0xffffdb39e900 'a') +0xaaaae652d340->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e900 } +0xffffdb39e900->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e900 } Entering state 2 Stack now 0 11 11 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaab051e7030 'a') --> $$ = nterm item (0xaaab051e7030 'a') +0xffffdb39e9e0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaae652d340 'a') +-> $$ = nterm item (0xffffdb39e9e0 'a') +0xaaaae652d340->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e9e0 } +0xaaaae652d340->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e9e0 } +0xffffdb39e9e0->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e9e0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token -0xaaab051e7080->Object::Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0, 0xaaab051e7030 } -Next token is token 'p' (0xaaab051e7080 'p'Exception caught: cleaning lookahead and stack -0xaaab051e7080->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0, 0xaaab051e7030, 0xaaab051e7080 } -0xaaab051e7030->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0, 0xaaab051e7030 } -0xaaab051e6fe0->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0 } -0xaaab051e6f90->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90 } -0xaaab051e6f40->Object::~Object { 0xaaab051e6f40 } +0xffffdb39e910->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340 } +0xffffdb39e9c0->Object::Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e910 } +0xffffdb39e910->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e910, 0xffffdb39e9c0 } +Next token is token 'p' (0xffffdb39e9c0 'p'Exception caught: cleaning lookahead and stack +0xaaaae652d340->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xaaaae652d340, 0xffffdb39e9c0 } +0xaaaae652d320->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xaaaae652d320, 0xffffdb39e9c0 } +0xaaaae652d300->Object::~Object { 0xaaaae652d2e0, 0xaaaae652d300, 0xffffdb39e9c0 } +0xaaaae652d2e0->Object::~Object { 0xaaaae652d2e0, 0xffffdb39e9c0 } +0xffffdb39e9c0->Object::~Object { 0xffffdb39e9c0 } exception caught: printer end { } -stderr: -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -exception caught: syntax error +./c++.at:1362: grep '^exception caught: printer$' stderr stdout: -./c++.at:1361: $PREPARSER ./input aaaas stderr: + skipped (javapush.at:230) +exception caught: printer +./c++.at:1362: $PREPARSER ./input aaaae stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xaaab051e6f40->Object::Object { } -Next token is token 'a' (0xaaab051e6f40 'a') -Shifting token 'a' (0xaaab051e6f40 'a') +0xaaaac60a2f40->Object::Object { } +Next token is token 'a' (0xaaaac60a2f40 'a') +Shifting token 'a' (0xaaaac60a2f40 'a') Entering state 2 Stack now 0 2 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaab051e6f40 'a') --> $$ = nterm item (0xaaab051e6f40 'a') + $1 = token 'a' (0xaaaac60a2f40 'a') +-> $$ = nterm item (0xaaaac60a2f40 'a') Entering state 11 Stack now 0 11 Reading a token -0xaaab051e6f90->Object::Object { 0xaaab051e6f40 } -Next token is token 'a' (0xaaab051e6f90 'a') -Shifting token 'a' (0xaaab051e6f90 'a') +0xaaaac60a2f90->Object::Object { 0xaaaac60a2f40 } +Next token is token 'a' (0xaaaac60a2f90 'a') +Shifting token 'a' (0xaaaac60a2f90 'a') Entering state 2 Stack now 0 11 2 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaab051e6f90 'a') --> $$ = nterm item (0xaaab051e6f90 'a') + $1 = token 'a' (0xaaaac60a2f90 'a') +-> $$ = nterm item (0xaaaac60a2f90 'a') Entering state 11 Stack now 0 11 11 Reading a token -0xaaab051e6fe0->Object::Object { 0xaaab051e6f40, 0xaaab051e6f90 } -Next token is token 'a' (0xaaab051e6fe0 'a') -Shifting token 'a' (0xaaab051e6fe0 'a') +0xaaaac60a2fe0->Object::Object { 0xaaaac60a2f40, 0xaaaac60a2f90 } +Next token is token 'a' (0xaaaac60a2fe0 'a') +Shifting token 'a' (0xaaaac60a2fe0 'a') Entering state 2 Stack now 0 11 11 2 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaab051e6fe0 'a') --> $$ = nterm item (0xaaab051e6fe0 'a') + $1 = token 'a' (0xaaaac60a2fe0 'a') +-> $$ = nterm item (0xaaaac60a2fe0 'a') Entering state 11 Stack now 0 11 11 11 Reading a token -0xaaab051e7030->Object::Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0 } -Next token is token 'a' (0xaaab051e7030 'a') -Shifting token 'a' (0xaaab051e7030 'a') +0xaaaac60a3030->Object::Object { 0xaaaac60a2f40, 0xaaaac60a2f90, 0xaaaac60a2fe0 } +Next token is token 'a' (0xaaaac60a3030 'a') +Shifting token 'a' (0xaaaac60a3030 'a') Entering state 2 Stack now 0 11 11 11 2 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaab051e7030 'a') --> $$ = nterm item (0xaaab051e7030 'a') + $1 = token 'a' (0xaaaac60a3030 'a') +-> $$ = nterm item (0xaaaac60a3030 'a') Entering state 11 Stack now 0 11 11 11 11 Reading a token -0xaaab051e7080->Object::Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0, 0xaaab051e7030 } -Next token is token 'p' (0xaaab051e7080 'p'Exception caught: cleaning lookahead and stack -0xaaab051e7080->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0, 0xaaab051e7030, 0xaaab051e7080 } -0xaaab051e7030->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0, 0xaaab051e7030 } -0xaaab051e6fe0->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90, 0xaaab051e6fe0 } -0xaaab051e6f90->Object::~Object { 0xaaab051e6f40, 0xaaab051e6f90 } -0xaaab051e6f40->Object::~Object { 0xaaab051e6f40 } +0xaaaac60a3080->Object::Object { 0xaaaac60a2f40, 0xaaaac60a2f90, 0xaaaac60a2fe0, 0xaaaac60a3030 } +Next token is token 'p' (0xaaaac60a3080 'p'Exception caught: cleaning lookahead and stack +0xaaaac60a3080->Object::~Object { 0xaaaac60a2f40, 0xaaaac60a2f90, 0xaaaac60a2fe0, 0xaaaac60a3030, 0xaaaac60a3080 } +0xaaaac60a3030->Object::~Object { 0xaaaac60a2f40, 0xaaaac60a2f90, 0xaaaac60a2fe0, 0xaaaac60a3030 } +0xaaaac60a2fe0->Object::~Object { 0xaaaac60a2f40, 0xaaaac60a2f90, 0xaaaac60a2fe0 } +0xaaaac60a2f90->Object::~Object { 0xaaaac60a2f40, 0xaaaac60a2f90 } +0xaaaac60a2f40->Object::~Object { 0xaaaac60a2f40 } exception caught: printer end { } ./c++.at:1360: grep '^exception caught: printer$' stderr -exception caught: reduction +exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: -./c++.at:1362: $PREPARSER ./input aaaaE exception caught: printer ./c++.at:1360: $PREPARSER ./input aaaae stderr: -exception caught: syntax error, unexpected end of file, expecting 'a' -stderr: -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + exception caught: syntax error ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: $PREPARSER ./input aaaal +./c++.at:1362: $PREPARSER ./input aaaaE +stderr: ./c++.at:1360: $PREPARSER ./input aaaaE stderr: -exception caught: yylex -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +exception caught: syntax error, unexpected end of file, expecting 'a' +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +exception caught: syntax error, unexpected end of file, expecting 'a' +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaaT +./c++.at:1360: $PREPARSER ./input aaaaT stderr: stderr: -exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +703. d.at:103: testing D parser class extends and implements ... +./d.at:106: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y ./c++.at:1362: $PREPARSER ./input aaaaR +./c++.at:1360: $PREPARSER ./input aaaaR +stderr: stderr: +stderr: +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: -./c++.at:1361: $PREPARSER ./input i ======== Testing with C++ standard flags: '' +./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:856: $PREPARSER ./input +======== Testing with C++ standard flags: '' +./d.at:106: grep '[mb]4_' YYParser.y ./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stderr: +stdout: +./c++.at:856: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +703. d.at:103: skipped (d.at:106) +./c++.at:857: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy + +======== Testing with C++ standard flags: '' +./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +704. d.at:138: testing D parser class api.token.raw true by default ... +./d.at:141: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -Wno-deprecated YYParser.y +./d.at:141: grep '[mb]4_' YYParser.y +stdout: +704. d.at:138: skipped (d.at:141) + +705. cxx-type.at:409: testing GLR: Resolve ambiguity, impure, no locations ... +./cxx-type.at:410: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y +stderr: +types.y:77.8-37: warning: unset value: $$ [-Wother] +types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] +types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +stderr: +./cxx-type.at:410: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS +stdout: ./c++.at:851: $PREPARSER ./input stderr: +./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: -./c++.at:1360: $PREPARSER ./input aaaaT +stdout: +./c++.at:1065: $PREPARSER ./input < in +stderr: +error: invalid expression +caught error +error: invalid character +caught error +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stdout: +./c++.at:1065: $PREPARSER ./input < in +./c++.at:1066: $PREPARSER ./input < in +stderr: +stdout: +stderr: +689. c++.at:1371: ok +stderr: +error: invalid expression +caught error +error: invalid character +caught error +error: invalid expression +./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1065: $PREPARSER ./input < in +./c++.at:1066: $PREPARSER ./input < in +stderr: +error: invalid character +stderr: + +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +error: invalid expression +./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:1066: $PREPARSER ./input < in +stderr: +stderr: +stdout: +./c++.at:1555: $PREPARSER ./test +error: invalid character +./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS +./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +======== Testing with C++ standard flags: '' +./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stderr: +./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +stdout: +./c++.at:1363: $PREPARSER ./input aaaas +stderr: +exception caught: reduction +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +706. cxx-type.at:415: testing GLR: Resolve ambiguity, impure, locations ... +./c++.at:1363: $PREPARSER ./input aaaal +./cxx-type.at:416: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y +stderr: +exception caught: yylex +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1363: $PREPARSER ./input i +stderr: +stderr: +types.y:87.8-37: warning: unset value: $$ [-Wother] +types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] +types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +./cxx-type.at:416: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS exception caught: initial-action +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stdout: +./c++.at:1066: ./check +./c++.at:1363: $PREPARSER ./input aaaap +stderr: +stderr: +stdout: +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1363: $PREPARSER ./input --debug aaaap +./c++.at:1555: ./check +./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS +stderr: +./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y +Starting parse +Entering state 0 +Stack now 0 +Reading a token +0xfffffd609620->Object::Object { } +0xfffffd609720->Object::Object { 0xfffffd609620 } +0xfffffd609620->Object::~Object { 0xfffffd609620, 0xfffffd609720 } +Next token is token 'a' (0xfffffd609720 'a') +0xfffffd609660->Object::Object { 0xfffffd609720 } +0xfffffd609720->Object::~Object { 0xfffffd609660, 0xfffffd609720 } +Shifting token 'a' (0xfffffd609660 'a') +0xaaaae93302e0->Object::Object { 0xfffffd609660 } +0xfffffd609660->Object::~Object { 0xaaaae93302e0, 0xfffffd609660 } +Entering state 1 +Stack now 0 1 +0xfffffd609740->Object::Object { 0xaaaae93302e0 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaae93302e0 'a') +-> $$ = nterm item (0xfffffd609740 'a') +0xaaaae93302e0->Object::~Object { 0xaaaae93302e0, 0xfffffd609740 } +0xaaaae93302e0->Object::Object { 0xfffffd609740 } +0xfffffd609740->Object::~Object { 0xaaaae93302e0, 0xfffffd609740 } +Entering state 10 +Stack now 0 10 +Reading a token +0xfffffd609620->Object::Object { 0xaaaae93302e0 } +0xfffffd609720->Object::Object { 0xaaaae93302e0, 0xfffffd609620 } +0xfffffd609620->Object::~Object { 0xaaaae93302e0, 0xfffffd609620, 0xfffffd609720 } +Next token is token 'a' (0xfffffd609720 'a') +0xfffffd609660->Object::Object { 0xaaaae93302e0, 0xfffffd609720 } +0xfffffd609720->Object::~Object { 0xaaaae93302e0, 0xfffffd609660, 0xfffffd609720 } +Shifting token 'a' (0xfffffd609660 'a') +0xaaaae9330300->Object::Object { 0xaaaae93302e0, 0xfffffd609660 } +0xfffffd609660->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609660 } +Entering state 1 +Stack now 0 10 1 +0xfffffd609740->Object::Object { 0xaaaae93302e0, 0xaaaae9330300 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaae9330300 'a') +-> $$ = nterm item (0xfffffd609740 'a') +0xaaaae9330300->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609740 } +0xaaaae9330300->Object::Object { 0xaaaae93302e0, 0xfffffd609740 } +0xfffffd609740->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609740 } +Entering state 10 +Stack now 0 10 10 +Reading a token +0xfffffd609620->Object::Object { 0xaaaae93302e0, 0xaaaae9330300 } +0xfffffd609720->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609620 } +0xfffffd609620->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609620, 0xfffffd609720 } +Next token is token 'a' (0xfffffd609720 'a') +0xfffffd609660->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609720 } +0xfffffd609720->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609660, 0xfffffd609720 } +Shifting token 'a' (0xfffffd609660 'a') +0xaaaae9330320->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609660 } +0xfffffd609660->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609660 } +Entering state 1 +Stack now 0 10 10 1 +0xfffffd609740->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaae9330320 'a') +-> $$ = nterm item (0xfffffd609740 'a') +0xaaaae9330320->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609740 } +0xaaaae9330320->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609740 } +0xfffffd609740->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609740 } +Entering state 10 +Stack now 0 10 10 10 +Reading a token +0xfffffd609620->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320 } +0xfffffd609720->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609620 } +0xfffffd609620->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609620, 0xfffffd609720 } +Next token is token 'a' (0xfffffd609720 'a') +0xfffffd609660->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609720 } +0xfffffd609720->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609660, 0xfffffd609720 } +Shifting token 'a' (0xfffffd609660 'a') +0xaaaae9330340->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609660 } +0xfffffd609660->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609660 } +Entering state 1 +Stack now 0 10 10 10 1 +0xfffffd609740->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaae9330340 'a') +-> $$ = nterm item (0xfffffd609740 'a') +0xaaaae9330340->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609740 } +0xaaaae9330340->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609740 } +0xfffffd609740->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609740 } +Entering state 10 +Stack now 0 10 10 10 10 +Reading a token +0xfffffd609620->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340 } +0xfffffd609720->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609620 } +0xfffffd609620->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609620, 0xfffffd609720 } +Next token is token 'p' (0xfffffd609720 'p'Exception caught: cleaning lookahead and stack +0xaaaae9330340->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609720 } +0xaaaae9330320->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609720 } +0xaaaae9330300->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609720 } +0xaaaae93302e0->Object::~Object { 0xaaaae93302e0, 0xfffffd609720 } +0xfffffd609720->Object::~Object { 0xfffffd609720 } +exception caught: printer +end { } +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +0xfffffd609620->Object::Object { } +0xfffffd609720->Object::Object { 0xfffffd609620 } +0xfffffd609620->Object::~Object { 0xfffffd609620, 0xfffffd609720 } +Next token is token 'a' (0xfffffd609720 'a') +0xfffffd609660->Object::Object { 0xfffffd609720 } +0xfffffd609720->Object::~Object { 0xfffffd609660, 0xfffffd609720 } +Shifting token 'a' (0xfffffd609660 'a') +0xaaaae93302e0->Object::Object { 0xfffffd609660 } +0xfffffd609660->Object::~Object { 0xaaaae93302e0, 0xfffffd609660 } +Entering state 1 +Stack now 0 1 +0xfffffd609740->Object::Object { 0xaaaae93302e0 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaae93302e0 'a') +-> $$ = nterm item (0xfffffd609740 'a') +0xaaaae93302e0->Object::~Object { 0xaaaae93302e0, 0xfffffd609740 } +0xaaaae93302e0->Object::Object { 0xfffffd609740 } +0xfffffd609740->Object::~Object { 0xaaaae93302e0, 0xfffffd609740 } +Entering state 10 +Stack now 0 10 +Reading a token +0xfffffd609620->Object::Object { 0xaaaae93302e0 } +0xfffffd609720->Object::Object { 0xaaaae93302e0, 0xfffffd609620 } +0xfffffd609620->Object::~Object { 0xaaaae93302e0, 0xfffffd609620, 0xfffffd609720 } +Next token is token 'a' (0xfffffd609720 'a') +0xfffffd609660->Object::Object { 0xaaaae93302e0, 0xfffffd609720 } +0xfffffd609720->Object::~Object { 0xaaaae93302e0, 0xfffffd609660, 0xfffffd609720 } +Shifting token 'a' (0xfffffd609660 'a') +0xaaaae9330300->Object::Object { 0xaaaae93302e0, 0xfffffd609660 } +0xfffffd609660->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609660 } +Entering state 1 +Stack now 0 10 1 +0xfffffd609740->Object::Object { 0xaaaae93302e0, 0xaaaae9330300 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaae9330300 'a') +-> $$ = nterm item (0xfffffd609740 'a') +0xaaaae9330300->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609740 } +0xaaaae9330300->Object::Object { 0xaaaae93302e0, 0xfffffd609740 } +0xfffffd609740->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609740 } +Entering state 10 +Stack now 0 10 10 +Reading a token +0xfffffd609620->Object::Object { 0xaaaae93302e0, 0xaaaae9330300 } +0xfffffd609720->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609620 } +0xfffffd609620->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609620, 0xfffffd609720 } +Next token is token 'a' (0xfffffd609720 'a') +0xfffffd609660->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609720 } +0xfffffd609720->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609660, 0xfffffd609720 } +Shifting token 'a' (0xfffffd609660 'a') +0xaaaae9330320->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609660 } +0xfffffd609660->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609660 } +Entering state 1 +Stack now 0 10 10 1 +0xfffffd609740->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaae9330320 'a') +-> $$ = nterm item (0xfffffd609740 'a') +0xaaaae9330320->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609740 } +0xaaaae9330320->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609740 } +0xfffffd609740->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609740 } +Entering state 10 +Stack now 0 10 10 10 +Reading a token +0xfffffd609620->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320 } +0xfffffd609720->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609620 } +0xfffffd609620->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609620, 0xfffffd609720 } +Next token is token 'a' (0xfffffd609720 'a') +0xfffffd609660->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609720 } +0xfffffd609720->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609660, 0xfffffd609720 } +Shifting token 'a' (0xfffffd609660 'a') +0xaaaae9330340->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609660 } +0xfffffd609660->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609660 } +Entering state 1 +Stack now 0 10 10 10 1 +0xfffffd609740->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaae9330340 'a') +-> $$ = nterm item (0xfffffd609740 'a') +0xaaaae9330340->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609740 } +0xaaaae9330340->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609740 } +0xfffffd609740->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609740 } +Entering state 10 +Stack now 0 10 10 10 10 +Reading a token +0xfffffd609620->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340 } +0xfffffd609720->Object::Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609620 } +0xfffffd609620->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609620, 0xfffffd609720 } +Next token is token 'p' (0xfffffd609720 'p'Exception caught: cleaning lookahead and stack +0xaaaae9330340->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xaaaae9330340, 0xfffffd609720 } +0xaaaae9330320->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xaaaae9330320, 0xfffffd609720 } +0xaaaae9330300->Object::~Object { 0xaaaae93302e0, 0xaaaae9330300, 0xfffffd609720 } +0xaaaae93302e0->Object::~Object { 0xaaaae93302e0, 0xfffffd609720 } +0xfffffd609720->Object::~Object { 0xfffffd609720 } +exception caught: printer +end { } +./c++.at:1363: grep '^exception caught: printer$' stderr +stdout: +exception caught: printer +./c++.at:1363: $PREPARSER ./input aaaae +stderr: +exception caught: syntax error +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +./c++.at:1363: $PREPARSER ./input aaaaE +stderr: +stderr: +exception caught: syntax error, unexpected end of file, expecting 'a' +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +./c++.at:1361: $PREPARSER ./input aaaas +stderr: +exception caught: reduction +./c++.at:1363: $PREPARSER ./input aaaaT ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input aaaal +stderr: +exception caught: yylex +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1363: $PREPARSER ./input aaaaR +stderr: +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input i ======== Testing with C++ standard flags: '' -./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./c++.at:1360: $PREPARSER ./input aaaaR -./c++.at:1361: $PREPARSER ./input aaaap stderr: +exception caught: initial-action +./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input aaaap stderr: -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xaaaad4bb8f40->Object::Object { } -Next token is token 'a' (0xaaaad4bb8f40 'a') -Shifting token 'a' (0xaaaad4bb8f40 'a') +0xaaab042edf40->Object::Object { } +Next token is token 'a' (0xaaab042edf40 'a') +Shifting token 'a' (0xaaab042edf40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaad4bb8f40 'a') --> $$ = nterm item (0xaaaad4bb8f40 'a') + $1 = token 'a' (0xaaab042edf40 'a') +-> $$ = nterm item (0xaaab042edf40 'a') Entering state 10 Stack now 0 10 Reading a token -0xaaaad4bb8f90->Object::Object { 0xaaaad4bb8f40 } -Next token is token 'a' (0xaaaad4bb8f90 'a') -Shifting token 'a' (0xaaaad4bb8f90 'a') +0xaaab042edf90->Object::Object { 0xaaab042edf40 } +Next token is token 'a' (0xaaab042edf90 'a') +Shifting token 'a' (0xaaab042edf90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaad4bb8f90 'a') --> $$ = nterm item (0xaaaad4bb8f90 'a') + $1 = token 'a' (0xaaab042edf90 'a') +-> $$ = nterm item (0xaaab042edf90 'a') Entering state 10 Stack now 0 10 10 Reading a token -0xaaaad4bb8fe0->Object::Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90 } -Next token is token 'a' (0xaaaad4bb8fe0 'a') -Shifting token 'a' (0xaaaad4bb8fe0 'a') +0xaaab042edfe0->Object::Object { 0xaaab042edf40, 0xaaab042edf90 } +Next token is token 'a' (0xaaab042edfe0 'a') +Shifting token 'a' (0xaaab042edfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaad4bb8fe0 'a') --> $$ = nterm item (0xaaaad4bb8fe0 'a') + $1 = token 'a' (0xaaab042edfe0 'a') +-> $$ = nterm item (0xaaab042edfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token -0xaaaad4bb9030->Object::Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0 } -Next token is token 'a' (0xaaaad4bb9030 'a') -Shifting token 'a' (0xaaaad4bb9030 'a') +0xaaab042ee030->Object::Object { 0xaaab042edf40, 0xaaab042edf90, 0xaaab042edfe0 } +Next token is token 'a' (0xaaab042ee030 'a') +Shifting token 'a' (0xaaab042ee030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaad4bb9030 'a') --> $$ = nterm item (0xaaaad4bb9030 'a') + $1 = token 'a' (0xaaab042ee030 'a') +-> $$ = nterm item (0xaaab042ee030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token -0xaaaad4bb9080->Object::Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0, 0xaaaad4bb9030 } -Next token is token 'p' (0xaaaad4bb9080 'p'Exception caught: cleaning lookahead and stack -0xaaaad4bb9080->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0, 0xaaaad4bb9030, 0xaaaad4bb9080 } -0xaaaad4bb9030->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0, 0xaaaad4bb9030 } -0xaaaad4bb8fe0->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0 } -0xaaaad4bb8f90->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90 } -0xaaaad4bb8f40->Object::~Object { 0xaaaad4bb8f40 } +0xaaab042ee080->Object::Object { 0xaaab042edf40, 0xaaab042edf90, 0xaaab042edfe0, 0xaaab042ee030 } +Next token is token 'p' (0xaaab042ee080 'p'Exception caught: cleaning lookahead and stack +0xaaab042ee080->Object::~Object { 0xaaab042edf40, 0xaaab042edf90, 0xaaab042edfe0, 0xaaab042ee030, 0xaaab042ee080 } +0xaaab042ee030->Object::~Object { 0xaaab042edf40, 0xaaab042edf90, 0xaaab042edfe0, 0xaaab042ee030 } +0xaaab042edfe0->Object::~Object { 0xaaab042edf40, 0xaaab042edf90, 0xaaab042edfe0 } +0xaaab042edf90->Object::~Object { 0xaaab042edf40, 0xaaab042edf90 } +0xaaab042edf40->Object::~Object { 0xaaab042edf40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +stderr: +stdout: Starting parse Entering state 0 Stack now 0 Reading a token -0xaaaad4bb8f40->Object::Object { } -Next token is token 'a' (0xaaaad4bb8f40 'a') -Shifting token 'a' (0xaaaad4bb8f40 'a') +0xaaab042edf40->Object::Object { } +Next token is token 'a' (0xaaab042edf40 'a') +Shifting token 'a' (0xaaab042edf40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaad4bb8f40 'a') --> $$ = nterm item (0xaaaad4bb8f40 'a') + $1 = token 'a' (0xaaab042edf40 'a') +-> $$ = nterm item (0xaaab042edf40 'a') Entering state 10 Stack now 0 10 Reading a token -0xaaaad4bb8f90->Object::Object { 0xaaaad4bb8f40 } -Next token is token 'a' (0xaaaad4bb8f90 'a') -Shifting token 'a' (0xaaaad4bb8f90 'a') +0xaaab042edf90->Object::Object { 0xaaab042edf40 } +Next token is token 'a' (0xaaab042edf90 'a') +Shifting token 'a' (0xaaab042edf90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaad4bb8f90 'a') --> $$ = nterm item (0xaaaad4bb8f90 'a') + $1 = token 'a' (0xaaab042edf90 'a') +-> $$ = nterm item (0xaaab042edf90 'a') Entering state 10 Stack now 0 10 10 Reading a token -0xaaaad4bb8fe0->Object::Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90 } -Next token is token 'a' (0xaaaad4bb8fe0 'a') -Shifting token 'a' (0xaaaad4bb8fe0 'a') +0xaaab042edfe0->Object::Object { 0xaaab042edf40, 0xaaab042edf90 } +Next token is token 'a' (0xaaab042edfe0 'a') +Shifting token 'a' (0xaaab042edfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaad4bb8fe0 'a') --> $$ = nterm item (0xaaaad4bb8fe0 'a') + $1 = token 'a' (0xaaab042edfe0 'a') +-> $$ = nterm item (0xaaab042edfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token -0xaaaad4bb9030->Object::Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0 } -Next token is token 'a' (0xaaaad4bb9030 'a') -Shifting token 'a' (0xaaaad4bb9030 'a') +0xaaab042ee030->Object::Object { 0xaaab042edf40, 0xaaab042edf90, 0xaaab042edfe0 } +Next token is token 'a' (0xaaab042ee030 'a') +Shifting token 'a' (0xaaab042ee030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaad4bb9030 'a') --> $$ = nterm item (0xaaaad4bb9030 'a') + $1 = token 'a' (0xaaab042ee030 'a') +-> $$ = nterm item (0xaaab042ee030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token -0xaaaad4bb9080->Object::Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0, 0xaaaad4bb9030 } -Next token is token 'p' (0xaaaad4bb9080 'p'Exception caught: cleaning lookahead and stack -0xaaaad4bb9080->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0, 0xaaaad4bb9030, 0xaaaad4bb9080 } -0xaaaad4bb9030->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0, 0xaaaad4bb9030 } -0xaaaad4bb8fe0->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90, 0xaaaad4bb8fe0 } -0xaaaad4bb8f90->Object::~Object { 0xaaaad4bb8f40, 0xaaaad4bb8f90 } -0xaaaad4bb8f40->Object::~Object { 0xaaaad4bb8f40 } +0xaaab042ee080->Object::Object { 0xaaab042edf40, 0xaaab042edf90, 0xaaab042edfe0, 0xaaab042ee030 } +Next token is token 'p' (0xaaab042ee080 'p'Exception caught: cleaning lookahead and stack +0xaaab042ee080->Object::~Object { 0xaaab042edf40, 0xaaab042edf90, 0xaaab042edfe0, 0xaaab042ee030, 0xaaab042ee080 } +0xaaab042ee030->Object::~Object { 0xaaab042edf40, 0xaaab042edf90, 0xaaab042edfe0, 0xaaab042ee030 } +0xaaab042edfe0->Object::~Object { 0xaaab042edf40, 0xaaab042edf90, 0xaaab042edfe0 } +0xaaab042edf90->Object::~Object { 0xaaab042edf40, 0xaaab042edf90 } +0xaaab042edf40->Object::~Object { 0xaaab042edf40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr stdout: exception caught: printer +./c++.at:851: $PREPARSER ./input ./c++.at:1361: $PREPARSER ./input aaaae stderr: -exception caught: syntax error -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +exception caught: syntax error stderr: -stdout: +./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: ./cxx-type.at:412: $PREPARSER ./types test-input +======== Testing with C++ standard flags: '' stderr: syntax error +./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1361: $PREPARSER ./input aaaaE ./cxx-type.at:412: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +exception caught: syntax error, unexpected end of file, expecting 'a' +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:412: $PREPARSER ./types -p test-input -./c++.at:1363: $PREPARSER ./input aaaas stderr: Starting parse Entering state 0 @@ -257475,8 +256761,7 @@ -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () --stderr: -> $$ = nterm stmt () +-> $$ = nterm stmt () Reducing stack -1 by rule 2 (line 65): $1 = nterm prog () $2 = nterm stmt () @@ -257725,10 +257010,15 @@ Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () +./c++.at:1361: $PREPARSER ./input aaaaT +stderr: +stderr: ./cxx-type.at:412: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -exception caught: reduction -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: $PREPARSER ./input aaaaE +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +./c++.at:1361: $PREPARSER ./input aaaaR +./c++.at:857: $PREPARSER ./input +stderr: stderr: Starting parse Entering state 0 @@ -258296,78 +257586,30 @@ Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () -705. cxx-type.at:409: ok -stderr: -exception caught: syntax error, unexpected end of file, expecting 'a' -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1363: $PREPARSER ./input aaaal stderr: -./c++.at:1361: $PREPARSER ./input aaaaT -exception caught: yylex -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: - -stdout: -./c++.at:1066: $PREPARSER ./input < in ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: $PREPARSER ./input aaaaR -stderr: -stderr: -stderr: -stderr: -stdout: -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -./c++.at:1555: $PREPARSER ./test -./c++.at:857: $PREPARSER ./input -stderr: -stderr: -./c++.at:1363: $PREPARSER ./input i -error: invalid expression -caught error -error: invalid character -caught error -./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +705. cxx-type.at:409: ok ./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: ======== Testing with C++ standard flags: '' -./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -exception caught: initial-action -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -707. cxx-type.at:420: testing GLR: Resolve ambiguity, pure, no locations ... ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -======== Testing with C++ standard flags: '' +./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS + +707. cxx-type.at:420: testing GLR: Resolve ambiguity, pure, no locations ... ./cxx-type.at:421: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y -./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -./c++.at:1363: $PREPARSER ./input aaaap -./c++.at:1066: $PREPARSER ./input < in -stderr: -error: invalid expression -./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./c++.at:1066: $PREPARSER ./input < in -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: types.y:77.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -stderr: ./cxx-type.at:421: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS stderr: -error: invalid character stdout: -./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:417: $PREPARSER ./types test-input stderr: -./c++.at:1363: $PREPARSER ./input --debug aaaap 17.5: syntax error ./cxx-type.at:417: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:417: $PREPARSER ./types -p test-input stderr: -stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): @@ -258935,109 +258177,6 @@ $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) ./cxx-type.at:417: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -Starting parse -Entering state 0 -Stack now 0 -Reading a token -0xffffc0c137e0->Object::Object { } -0xffffc0c138e0->Object::Object { 0xffffc0c137e0 } -0xffffc0c137e0->Object::~Object { 0xffffc0c137e0, 0xffffc0c138e0 } -Next token is token 'a' (0xffffc0c138e0 'a') -0xffffc0c13820->Object::Object { 0xffffc0c138e0 } -0xffffc0c138e0->Object::~Object { 0xffffc0c13820, 0xffffc0c138e0 } -Shifting token 'a' (0xffffc0c13820 'a') -0xaaaadf0782e0->Object::Object { 0xffffc0c13820 } -0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13820 } -Entering state 1 -Stack now 0 1 -0xffffc0c13900->Object::Object { 0xaaaadf0782e0 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaadf0782e0 'a') --> $$ = nterm item (0xffffc0c13900 'a') -0xaaaadf0782e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13900 } -0xaaaadf0782e0->Object::Object { 0xffffc0c13900 } -0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13900 } -Entering state 10 -Stack now 0 10 -Reading a token -0xffffc0c137e0->Object::Object { 0xaaaadf0782e0 } -0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xffffc0c137e0 } -0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c137e0, 0xffffc0c138e0 } -Next token is token 'a' (0xffffc0c138e0 'a') -0xffffc0c13820->Object::Object { 0xaaaadf0782e0, 0xffffc0c138e0 } -0xffffc0c138e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13820, 0xffffc0c138e0 } -Shifting token 'a' (0xffffc0c13820 'a') -0xaaaadf078300->Object::Object { 0xaaaadf0782e0, 0xffffc0c13820 } -0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13820 } -Entering state 1 -Stack now 0 10 1 -0xffffc0c13900->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaadf078300 'a') --> $$ = nterm item (0xffffc0c13900 'a') -0xaaaadf078300->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13900 } -0xaaaadf078300->Object::Object { 0xaaaadf0782e0, 0xffffc0c13900 } -0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13900 } -Entering state 10 -Stack now 0 10 10 -Reading a token -0xffffc0c137e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300 } -0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c137e0 } -0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c137e0, 0xffffc0c138e0 } -Next token is token 'a' (0xffffc0c138e0 'a') -0xffffc0c13820->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c138e0 } -0xffffc0c138e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13820, 0xffffc0c138e0 } -Shifting token 'a' (0xffffc0c13820 'a') -0xaaaadf078320->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13820 } -0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13820 } -Entering state 1 -Stack now 0 10 10 1 -0xffffc0c13900->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaadf078320 'a') --> $$ = nterm item (0xffffc0c13900 'a') -0xaaaadf078320->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13900 } -0xaaaadf078320->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13900 } -0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13900 } -Entering state 10 -Stack now 0 10 10 10 -Reading a token -0xffffc0c137e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320 } -0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c137e0 } -0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c137e0, 0xffffc0c138e0 } -Next token is token 'a' (0xffffc0c138e0 'a') -0xffffc0c13820->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c138e0 } -0xffffc0c138e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13820, 0xffffc0c138e0 } -Shifting token 'a' (0xffffc0c13820 'a') -0xaaaadf078340->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13820 } -0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c13820 } -Entering state 1 -Stack now 0 10 10 10 1 -0xffffc0c13900->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaadf078340 'a') --> $$ = nterm item (0xffffc0c13900 'a') -0xaaaadf078340->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c13900 } -0xaaaadf078340->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13900 } -0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c13900 } -Entering state 10 -Stack now 0 10 10 10 10 -Reading a token -0xffffc0c137e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340 } -0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c137e0 } -0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c137e0, 0xffffc0c138e0 } -Next token is token 'p' (0xffffc0c138e0 'p'Exception caught: cleaning lookahead and stack -0xaaaadf078340->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c138e0 } -0xaaaadf078320->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c138e0 } -0xaaaadf078300->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c138e0 } -0xaaaadf0782e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c138e0 } -0xffffc0c138e0->Object::~Object { 0xffffc0c138e0 } -exception caught: printer -end { } -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: stderr: Starting parse Entering state 0 @@ -259605,163 +258744,428 @@ Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) +706. cxx-type.at:415: ok + +708. cxx-type.at:426: testing GLR: Resolve ambiguity, pure, locations ... +./cxx-type.at:427: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y +stderr: +stdout: +./c++.at:1360: $PREPARSER ./input aaaas +stderr: +types.y:87.8-37: warning: unset value: $$ [-Wother] +types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] +types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +stderr: +./cxx-type.at:427: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS +exception caught: reduction +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: stdout: -706. cxx-type.at:415: Starting parse +./c++.at:1362: $PREPARSER ./input aaaas +./c++.at:1360: $PREPARSER ./input aaaal +stderr: +stderr: +exception caught: yylex +exception caught: reduction +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1362: $PREPARSER ./input aaaal +./c++.at:1360: $PREPARSER ./input i +stderr: +stderr: +exception caught: yylex +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +exception caught: initial-action +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1362: $PREPARSER ./input i +./c++.at:1360: $PREPARSER ./input aaaap +stderr: +exception caught: initial-action +stderr: +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: $PREPARSER ./input --debug aaaap +stderr: +Starting parse Entering state 0 Stack now 0 Reading a token -0xffffc0c137e0->Object::Object { } -0xffffc0c138e0->Object::Object { 0xffffc0c137e0 } -0xffffc0c137e0->Object::~Object { 0xffffc0c137e0, 0xffffc0c138e0 } -Next token is token 'a' (0xffffc0c138e0 'a') -0xffffc0c13820->Object::Object { 0xffffc0c138e0 } -0xffffc0c138e0->Object::~Object { 0xffffc0c13820, 0xffffc0c138e0 } -Shifting token 'a' (0xffffc0c13820 'a') -0xaaaadf0782e0->Object::Object { 0xffffc0c13820 } -0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13820 } -Entering state 1 -Stack now 0 1 -0xffffc0c13900->Object::Object { 0xaaaadf0782e0 } +0xaaaaea7dbf40->Object::Object { } +Next token is token 'a' (0xaaaaea7dbf40 'a') +Shifting token 'a' (0xaaaaea7dbf40 'a') +Entering state 2 +Stack now 0 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaaea7dbf40 'a') +-> $$ = nterm item (0xaaaaea7dbf40 'a') +Entering state 11 +Stack now 0 11 +Reading a token +0xaaaaea7dbf90->Object::Object { 0xaaaaea7dbf40 } +Next token is token 'a' (0xaaaaea7dbf90 'a') +Shifting token 'a' (0xaaaaea7dbf90 'a') +Entering state 2 +Stack now 0 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaaea7dbf90 'a') +-> $$ = nterm item (0xaaaaea7dbf90 'a') +Entering state 11 +Stack now 0 11 11 +Reading a token +0xaaaaea7dbfe0->Object::Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90 } +Next token is token 'a' (0xaaaaea7dbfe0 'a') +Shifting token 'a' (0xaaaaea7dbfe0 'a') +Entering state 2 +Stack now 0 11 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaaea7dbfe0 'a') +-> $$ = nterm item (0xaaaaea7dbfe0 'a') +Entering state 11 +Stack now 0 11 11 11 +Reading a token +0xaaaaea7dc030->Object::Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90, 0xaaaaea7dbfe0 } +Next token is token 'a' (0xaaaaea7dc030 'a') +Shifting token 'a' (0xaaaaea7dc030 'a') +Entering state 2 +Stack now 0 11 11 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaaea7dc030 'a') +-> $$ = nterm item (0xaaaaea7dc030 'a') +Entering state 11 +Stack now 0 11 11 11 11 +Reading a token +0xaaaaea7dc080->Object::Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90, 0xaaaaea7dbfe0, 0xaaaaea7dc030 } +Next token is token 'p' (0xaaaaea7dc080 'p'Exception caught: cleaning lookahead and stack +0xaaaaea7dc080->Object::~Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90, 0xaaaaea7dbfe0, 0xaaaaea7dc030, 0xaaaaea7dc080 } +0xaaaaea7dc030->Object::~Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90, 0xaaaaea7dbfe0, 0xaaaaea7dc030 } +0xaaaaea7dbfe0->Object::~Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90, 0xaaaaea7dbfe0 } +0xaaaaea7dbf90->Object::~Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90 } +0xaaaaea7dbf40->Object::~Object { 0xaaaaea7dbf40 } +exception caught: printer +end { } +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +0xaaaaea7dbf40->Object::Object { } +Next token is token 'a' (0xaaaaea7dbf40 'a') +Shifting token 'a' (0xaaaaea7dbf40 'a') +Entering state 2 +Stack now 0 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaaea7dbf40 'a') +-> $$ = nterm item (0xaaaaea7dbf40 'a') +Entering state 11 +Stack now 0 11 +Reading a token +0xaaaaea7dbf90->Object::Object { 0xaaaaea7dbf40 } +Next token is token 'a' (0xaaaaea7dbf90 'a') +Shifting token 'a' (0xaaaaea7dbf90 'a') +Entering state 2 +Stack now 0 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaaea7dbf90 'a') +-> $$ = nterm item (0xaaaaea7dbf90 'a') +Entering state 11 +Stack now 0 11 11 +Reading a token +0xaaaaea7dbfe0->Object::Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90 } +Next token is token 'a' (0xaaaaea7dbfe0 'a') +Shifting token 'a' (0xaaaaea7dbfe0 'a') +Entering state 2 +Stack now 0 11 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaaea7dbfe0 'a') +-> $$ = nterm item (0xaaaaea7dbfe0 'a') +Entering state 11 +Stack now 0 11 11 11 +Reading a token +0xaaaaea7dc030->Object::Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90, 0xaaaaea7dbfe0 } +Next token is token 'a' (0xaaaaea7dc030 'a') +Shifting token 'a' (0xaaaaea7dc030 'a') +Entering state 2 +Stack now 0 11 11 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaaea7dc030 'a') +-> $$ = nterm item (0xaaaaea7dc030 'a') +Entering state 11 +Stack now 0 11 11 11 11 +Reading a token +0xaaaaea7dc080->Object::Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90, 0xaaaaea7dbfe0, 0xaaaaea7dc030 } +Next token is token 'p' (0xaaaaea7dc080 'p'Exception caught: cleaning lookahead and stack +0xaaaaea7dc080->Object::~Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90, 0xaaaaea7dbfe0, 0xaaaaea7dc030, 0xaaaaea7dc080 } +0xaaaaea7dc030->Object::~Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90, 0xaaaaea7dbfe0, 0xaaaaea7dc030 } +0xaaaaea7dbfe0->Object::~Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90, 0xaaaaea7dbfe0 } +0xaaaaea7dbf90->Object::~Object { 0xaaaaea7dbf40, 0xaaaaea7dbf90 } +0xaaaaea7dbf40->Object::~Object { 0xaaaaea7dbf40 } +exception caught: printer +end { } +./c++.at:1362: $PREPARSER ./input aaaap +./c++.at:1360: grep '^exception caught: printer$' stderr +stderr: +stdout: +exception caught: printer +./c++.at:1360: $PREPARSER ./input aaaae +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +exception caught: syntax error +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1362: $PREPARSER ./input --debug aaaap +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +0xffffc5d25ab0->Object::Object { } +0xffffc5d25b60->Object::Object { 0xffffc5d25ab0 } +0xffffc5d25ab0->Object::~Object { 0xffffc5d25ab0, 0xffffc5d25b60 } +Next token is token 'a' (0xffffc5d25b60 'a') +0xffffc5d25aa0->Object::Object { 0xffffc5d25b60 } +0xffffc5d25b60->Object::~Object { 0xffffc5d25aa0, 0xffffc5d25b60 } +Shifting token 'a' (0xffffc5d25aa0 'a') +0xaaaac4d9f2e0->Object::Object { 0xffffc5d25aa0 } +0xffffc5d25aa0->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25aa0 } +Entering state 2 +Stack now 0 2 +0xffffc5d25b80->Object::Object { 0xaaaac4d9f2e0 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaadf0782e0 'a') --> $$ = nterm item (0xffffc0c13900 'a') -0xaaaadf0782e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13900 } -0xaaaadf0782e0->Object::Object { 0xffffc0c13900 } -0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13900 } -Entering state 10 -Stack now 0 10 + $1 = token 'a' (0xaaaac4d9f2e0 'a') +-> $$ = nterm item (0xffffc5d25b80 'a') +0xaaaac4d9f2e0->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25b80 } +0xaaaac4d9f2e0->Object::Object { 0xffffc5d25b80 } +0xffffc5d25b80->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25b80 } +Entering state 11 +Stack now 0 11 Reading a token -0xffffc0c137e0->Object::Object { 0xaaaadf0782e0 } -0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xffffc0c137e0 } -0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c137e0, 0xffffc0c138e0 } -Next token is token 'a' (0xffffc0c138e0 'a') -0xffffc0c13820->Object::Object { 0xaaaadf0782e0, 0xffffc0c138e0 } -0xffffc0c138e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c13820, 0xffffc0c138e0 } -Shifting token 'a' (0xffffc0c13820 'a') -0xaaaadf078300->Object::Object { 0xaaaadf0782e0, 0xffffc0c13820 } -0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13820 } -Entering state 1 -Stack now 0 10 1 -0xffffc0c13900->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300 } +0xffffc5d25ab0->Object::Object { 0xaaaac4d9f2e0 } +0xffffc5d25b60->Object::Object { 0xaaaac4d9f2e0, 0xffffc5d25ab0 } +0xffffc5d25ab0->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25ab0, 0xffffc5d25b60 } +Next token is token 'a' (0xffffc5d25b60 'a') +0xffffc5d25aa0->Object::Object { 0xaaaac4d9f2e0, 0xffffc5d25b60 } +0xffffc5d25b60->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25aa0, 0xffffc5d25b60 } +Shifting token 'a' (0xffffc5d25aa0 'a') +0xaaaac4d9f300->Object::Object { 0xaaaac4d9f2e0, 0xffffc5d25aa0 } +0xffffc5d25aa0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25aa0 } +Entering state 2 +Stack now 0 11 2 +0xffffc5d25b80->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaadf078300 'a') --> $$ = nterm item (0xffffc0c13900 'a') -0xaaaadf078300->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13900 } -0xaaaadf078300->Object::Object { 0xaaaadf0782e0, 0xffffc0c13900 } -0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13900 } -Entering state 10 -Stack now 0 10 10 + $1 = token 'a' (0xaaaac4d9f300 'a') +-> $$ = nterm item (0xffffc5d25b80 'a') +0xaaaac4d9f300->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25b80 } +0xaaaac4d9f300->Object::Object { 0xaaaac4d9f2e0, 0xffffc5d25b80 } +0xffffc5d25b80->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25b80 } +Entering state 11 +Stack now 0 11 11 Reading a token -0xffffc0c137e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300 } -0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c137e0 } -0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c137e0, 0xffffc0c138e0 } -Next token is token 'a' (0xffffc0c138e0 'a') -0xffffc0c13820->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c138e0 } -0xffffc0c138e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13820, 0xffffc0c138e0 } -Shifting token 'a' (0xffffc0c13820 'a') -0xaaaadf078320->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13820 } -0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13820 } -Entering state 1 -Stack now 0 10 10 1 -0xffffc0c13900->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320 } +0xffffc5d25ab0->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300 } +0xffffc5d25b60->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25ab0 } +0xffffc5d25ab0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25ab0, 0xffffc5d25b60 } +Next token is token 'a' (0xffffc5d25b60 'a') +0xffffc5d25aa0->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25b60 } +0xffffc5d25b60->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25aa0, 0xffffc5d25b60 } +Shifting token 'a' (0xffffc5d25aa0 'a') +0xaaaac4d9f320->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25aa0 } +0xffffc5d25aa0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25aa0 } +Entering state 2 +Stack now 0 11 11 2 +0xffffc5d25b80->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaadf078320 'a') --> $$ = nterm item (0xffffc0c13900 'a') -0xaaaadf078320->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13900 } -0xaaaadf078320->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c13900 } -0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13900 } -Entering state 10 -Stack now 0 10 10 10 + $1 = token 'a' (0xaaaac4d9f320 'a') +-> $$ = nterm item (0xffffc5d25b80 'a') +0xaaaac4d9f320->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25b80 } +0xaaaac4d9f320->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25b80 } +0xffffc5d25b80->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25b80 } +Entering state 11 +Stack now 0 11 11 11 Reading a token -0xffffc0c137e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320 } -0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c137e0 } -0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c137e0, 0xffffc0c138e0 } -Next token is token 'a' (0xffffc0c138e0 'a') -0xffffc0c13820->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c138e0 } -0xffffc0c138e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13820, 0xffffc0c138e0 } -Shifting token 'a' (0xffffc0c13820 'a') -0xaaaadf078340->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13820 } -0xffffc0c13820->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c13820 } -Entering state 1 -Stack now 0 10 10 10 1 -0xffffc0c13900->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340 } +0xffffc5d25ab0->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320 } +0xffffc5d25b60->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25ab0 } +0xffffc5d25ab0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25ab0, 0xffffc5d25b60 } +Next token is token 'a' (0xffffc5d25b60 'a') +0xffffc5d25aa0->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25b60 } +0xffffc5d25b60->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25aa0, 0xffffc5d25b60 } +Shifting token 'a' (0xffffc5d25aa0 'a') +0xaaaac4d9f340->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25aa0 } +0xffffc5d25aa0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25aa0 } +Entering state 2 +Stack now 0 11 11 11 2 +0xffffc5d25b80->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaadf078340 'a') --> $$ = nterm item (0xffffc0c13900 'a') -0xaaaadf078340->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c13900 } -0xaaaadf078340->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c13900 } -0xffffc0c13900->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c13900 } -Entering state 10 -Stack now 0 10 10 10 10 + $1 = token 'a' (0xaaaac4d9f340 'a') +-> $$ = nterm item (0xffffc5d25b80 'a') +0xaaaac4d9f340->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25b80 } +0xaaaac4d9f340->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25b80 } +0xffffc5d25b80->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25b80 } +Entering state 11 +Stack now 0 11 11 11 11 Reading a token -0xffffc0c137e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340 } -0xffffc0c138e0->Object::Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c137e0 } -0xffffc0c137e0->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c137e0, 0xffffc0c138e0 } -Next token is token 'p' (0xffffc0c138e0 'p'Exception caught: cleaning lookahead and stack -0xaaaadf078340->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xaaaadf078340, 0xffffc0c138e0 } -0xaaaadf078320->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xaaaadf078320, 0xffffc0c138e0 } -0xaaaadf078300->Object::~Object { 0xaaaadf0782e0, 0xaaaadf078300, 0xffffc0c138e0 } -0xaaaadf0782e0->Object::~Object { 0xaaaadf0782e0, 0xffffc0c138e0 } -0xffffc0c138e0->Object::~Object { 0xffffc0c138e0 } +0xffffc5d25ab0->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340 } +0xffffc5d25b60->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25ab0 } +0xffffc5d25ab0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25ab0, 0xffffc5d25b60 } +Next token is token 'p' (0xffffc5d25b60 'p'Exception caught: cleaning lookahead and stack +0xaaaac4d9f340->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25b60 } +0xaaaac4d9f320->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25b60 } +0xaaaac4d9f300->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25b60 } +0xaaaac4d9f2e0->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25b60 } +0xffffc5d25b60->Object::~Object { 0xffffc5d25b60 } exception caught: printer end { } - ok -./c++.at:1555: ./check -./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y -./c++.at:1363: grep '^exception caught: printer$' stderr +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: $PREPARSER ./input aaaaE +stderr: +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +0xffffc5d25ab0->Object::Object { } +0xffffc5d25b60->Object::Object { 0xffffc5d25ab0 } +0xffffc5d25ab0->Object::~Object { 0xffffc5d25ab0, 0xffffc5d25b60 } +Next token is token 'a' (0xffffc5d25b60 'a') +0xffffc5d25aa0->Object::Object { 0xffffc5d25b60 } +0xffffc5d25b60->Object::~Object { 0xffffc5d25aa0, 0xffffc5d25b60 } +Shifting token 'a' (0xffffc5d25aa0 'a') +0xaaaac4d9f2e0->Object::Object { 0xffffc5d25aa0 } +0xffffc5d25aa0->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25aa0 } +Entering state 2 +Stack now 0 2 +0xffffc5d25b80->Object::Object { 0xaaaac4d9f2e0 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaac4d9f2e0 'a') +-> $$ = nterm item (0xffffc5d25b80 'a') +0xaaaac4d9f2e0->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25b80 } +0xaaaac4d9f2e0->Object::Object { 0xffffc5d25b80 } +0xffffc5d25b80->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25b80 } +Entering state 11 +Stack now 0 11 +Reading a token +0xffffc5d25ab0->Object::Object { 0xaaaac4d9f2e0 } +0xffffc5d25b60->Object::Object { 0xaaaac4d9f2e0, 0xffffc5d25ab0 } +0xffffc5d25ab0->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25ab0, 0xffffc5d25b60 } +Next token is token 'a' (0xffffc5d25b60 'a') +0xffffc5d25aa0->Object::Object { 0xaaaac4d9f2e0, 0xffffc5d25b60 } +0xffffc5d25b60->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25aa0, 0xffffc5d25b60 } +Shifting token 'a' (0xffffc5d25aa0 'a') +0xaaaac4d9f300->Object::Object { 0xaaaac4d9f2e0, 0xffffc5d25aa0 } +0xffffc5d25aa0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25aa0 } +Entering state 2 +Stack now 0 11 2 +0xffffc5d25b80->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaac4d9f300 'a') +-> $$ = nterm item (0xffffc5d25b80 'a') +0xaaaac4d9f300->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25b80 } +0xaaaac4d9f300->Object::Object { 0xaaaac4d9f2e0, 0xffffc5d25b80 } +0xffffc5d25b80->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25b80 } +Entering state 11 +Stack now 0 11 11 +Reading a token +0xffffc5d25ab0->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300 } +0xffffc5d25b60->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25ab0 } +0xffffc5d25ab0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25ab0, 0xffffc5d25b60 } +Next token is token 'a' (0xffffc5d25b60 'a') +0xffffc5d25aa0->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25b60 } +0xffffc5d25b60->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25aa0, 0xffffc5d25b60 } +Shifting token 'a' (0xffffc5d25aa0 'a') +0xaaaac4d9f320->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25aa0 } +0xffffc5d25aa0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25aa0 } +Entering state 2 +Stack now 0 11 11 2 +0xffffc5d25b80->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaac4d9f320 'a') +-> $$ = nterm item (0xffffc5d25b80 'a') +0xaaaac4d9f320->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25b80 } +0xaaaac4d9f320->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25b80 } +0xffffc5d25b80->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25b80 } +Entering state 11 +Stack now 0 11 11 11 +Reading a token +0xffffc5d25ab0->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320 } +0xffffc5d25b60->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25ab0 } +0xffffc5d25ab0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25ab0, 0xffffc5d25b60 } +Next token is token 'a' (0xffffc5d25b60 'a') +0xffffc5d25aa0->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25b60 } +0xffffc5d25b60->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25aa0, 0xffffc5d25b60 } +Shifting token 'a' (0xffffc5d25aa0 'a') +0xaaaac4d9f340->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25aa0 } +0xffffc5d25aa0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25aa0 } +Entering state 2 +Stack now 0 11 11 11 2 +0xffffc5d25b80->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaac4d9f340 'a') +-> $$ = nterm item (0xffffc5d25b80 'a') +0xaaaac4d9f340->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25b80 } +0xaaaac4d9f340->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25b80 } +0xffffc5d25b80->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25b80 } +Entering state 11 +Stack now 0 11 11 11 11 +Reading a token +0xffffc5d25ab0->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340 } +0xffffc5d25b60->Object::Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25ab0 } +0xffffc5d25ab0->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25ab0, 0xffffc5d25b60 } +Next token is token 'p' (0xffffc5d25b60 'p'Exception caught: cleaning lookahead and stack +0xaaaac4d9f340->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xaaaac4d9f340, 0xffffc5d25b60 } +0xaaaac4d9f320->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xaaaac4d9f320, 0xffffc5d25b60 } +0xaaaac4d9f300->Object::~Object { 0xaaaac4d9f2e0, 0xaaaac4d9f300, 0xffffc5d25b60 } +0xaaaac4d9f2e0->Object::~Object { 0xaaaac4d9f2e0, 0xffffc5d25b60 } +0xffffc5d25b60->Object::~Object { 0xffffc5d25b60 } +exception caught: printer +end { } +exception caught: syntax error, unexpected end of file, expecting 'a' +./c++.at:1362: grep '^exception caught: printer$' stderr +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: exception caught: printer -./c++.at:1363: $PREPARSER ./input aaaae -./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./c++.at:1362: $PREPARSER ./input aaaae stderr: exception caught: syntax error -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - -./c++.at:1363: $PREPARSER ./input aaaaE +./c++.at:1360: $PREPARSER ./input aaaaT +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -exception caught: syntax error, unexpected end of file, expecting 'a' -./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: -./c++.at:1066: ./check -./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS -708. cxx-type.at:426: testing GLR: Resolve ambiguity, pure, locations ... -./cxx-type.at:427: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y -./c++.at:1363: $PREPARSER ./input aaaaT +./c++.at:857: $PREPARSER ./input +./c++.at:1362: $PREPARSER ./input aaaaE +./c++.at:1360: $PREPARSER ./input aaaaR stderr: -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1363: $PREPARSER ./input aaaaR stderr: -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: -types.y:87.8-37: warning: unset value: $$ [-Wother] -types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] -types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -./cxx-type.at:427: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS +./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +exception caught: syntax error, unexpected end of file, expecting 'a' +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: +======== Testing with C++ standard flags: '' stdout: -./c++.at:1065: $PREPARSER ./input < in +./c++.at:851: $PREPARSER ./input +./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: -error: invalid expression -caught error -error: invalid character -caught error -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1362: $PREPARSER ./input aaaaT +======== Testing with C++ standard flags: '' +./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stderr: +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1362: $PREPARSER ./input aaaaR stderr: +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +stderr: +./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: ./cxx-type.at:423: $PREPARSER ./types test-input -./c++.at:1065: $PREPARSER ./input < in -stderr: stderr: syntax error -error: invalid expression -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:423: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:423: $PREPARSER ./types -p test-input -./c++.at:1065: $PREPARSER ./input < in stderr: Starting parse Entering state 0 @@ -260329,10 +259733,7 @@ Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () -stderr: ./cxx-type.at:423: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -error: invalid character -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 @@ -260901,61 +260302,22 @@ $1 = token '@' () Cleanup: popping nterm prog () 707. cxx-type.at:420: ok -======== Testing with C++ standard flags: '' -./c++.at:1065: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS - stderr: stdout: -./c++.at:1064: $PREPARSER ./input < in -stderr: -error: invalid expression -caught error -error: invalid character -caught error -./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1064: $PREPARSER ./input < in -stderr: -error: invalid expression -./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1064: $PREPARSER ./input < in -709. cxx-type.at:432: testing GLR: Merge conflicting parses, impure, no locations ... -stderr: -error: invalid character -./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -682. c++.at:1064: ok -./cxx-type.at:433: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y +./c++.at:1555: $PREPARSER ./test stderr: -types.y:77.8-37: warning: unset value: $$ [-Wother] -types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] -types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -./cxx-type.at:433: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS -stderr: -stdout: -./c++.at:857: $PREPARSER ./input -stderr: -710. cxx-type.at:438: testing GLR: Merge conflicting parses, impure, locations ... -./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./cxx-type.at:439: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y +./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -types.y:87.8-37: warning: unset value: $$ [-Wother] -types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] -types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -./cxx-type.at:439: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS -stderr: +./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: -stdout: +709. cxx-type.at:432: testing GLR: Merge conflicting parses, impure, no locations ... ./cxx-type.at:429: $PREPARSER ./types test-input -./c++.at:851: $PREPARSER ./input -stderr: +./cxx-type.at:433: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y stderr: 17.5: syntax error -./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:429: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -678. c++.at:848: ok ./cxx-type.at:429: $PREPARSER ./types -p test-input stderr: Starting parse @@ -261524,8 +260886,17 @@ Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) +stderr: +stdout: +./c++.at:1555: ./check ./cxx-type.at:429: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1555: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -fcaret -o test.cc test.y +stderr: +types.y:77.8-37: warning: unset value: $$ [-Wother] +types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] +types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples stderr: +./cxx-type.at:433: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): @@ -262094,410 +261465,440 @@ Cleanup: popping nterm prog (1.1-19.5: ) 708. cxx-type.at:426: ok - -711. cxx-type.at:444: testing GLR: Merge conflicting parses, pure, no locations ... -./cxx-type.at:445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y -stderr: -types.y:77.8-37: warning: unset value: $$ [-Wother] -types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] -types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -./cxx-type.at:445: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS -712. cxx-type.at:449: testing GLR: Merge conflicting parses, pure, locations ... -./cxx-type.at:450: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y -stderr: -stdout: +./c++.at:1555: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o test test.cc $LIBS +710. cxx-type.at:438: testing GLR: Merge conflicting parses, impure, locations ... +./cxx-type.at:439: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y stderr: types.y:87.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -./c++.at:1362: $PREPARSER ./input aaaas -stderr: -./cxx-type.at:450: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS -exception caught: reduction -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./cxx-type.at:439: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS stderr: stdout: -./c++.at:1360: $PREPARSER ./input aaaas +./c++.at:1363: $PREPARSER ./input aaaas stderr: -./c++.at:1362: $PREPARSER ./input aaaal exception caught: reduction +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1363: $PREPARSER ./input aaaal stderr: -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -exception caught: yylex -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input aaaal +stdout: stderr: -./c++.at:1362: $PREPARSER ./input i exception caught: yylex -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -exception caught: initial-action -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input i +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:851: $PREPARSER ./input stderr: -./c++.at:1362: $PREPARSER ./input aaaap +./c++.at:1363: $PREPARSER ./input i +./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: initial-action -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1362: $PREPARSER ./input --debug aaaap +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +======== Testing with C++ standard flags: '' +./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stdout: -./c++.at:1360: $PREPARSER ./input aaaap +./c++.at:857: $PREPARSER ./input +./c++.at:1363: $PREPARSER ./input aaaap stderr: stderr: -./c++.at:1361: $PREPARSER ./input aaaas -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:1363: $PREPARSER ./input --debug aaaap +./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: -stdout: stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xffffc1017cf0->Object::Object { } -0xffffc1017df0->Object::Object { 0xffffc1017cf0 } -0xffffc1017cf0->Object::~Object { 0xffffc1017cf0, 0xffffc1017df0 } -Next token is token 'a' (0xffffc1017df0 'a') -0xffffc1017d30->Object::Object { 0xffffc1017df0 } -0xffffc1017df0->Object::~Object { 0xffffc1017d30, 0xffffc1017df0 } -Shifting token 'a' (0xffffc1017d30 'a') -0xaaaadfe9c2e0->Object::Object { 0xffffc1017d30 } -0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017d30 } -Entering state 2 -Stack now 0 2 -0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0 } +0xffffc2fd68c0->Object::Object { } +0xffffc2fd69c0->Object::Object { 0xffffc2fd68c0 } +0xffffc2fd68c0->Object::~Object { 0xffffc2fd68c0, 0xffffc2fd69c0 } +Next token is token 'a' (0xffffc2fd69c0 'a') +0xffffc2fd6900->Object::Object { 0xffffc2fd69c0 } +0xffffc2fd69c0->Object::~Object { 0xffffc2fd6900, 0xffffc2fd69c0 } +Shifting token 'a' (0xffffc2fd6900 'a') +0xaaaafbdb42e0->Object::Object { 0xffffc2fd6900 } +0xffffc2fd6900->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd6900 } +Entering state 1 +Stack now 0 1 +0xffffc2fd69e0->Object::Object { 0xaaaafbdb42e0 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaadfe9c2e0 'a') --> $$ = nterm item (0xffffc1017e10 'a') -0xaaaadfe9c2e0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017e10 } -0xaaaadfe9c2e0->Object::Object { 0xffffc1017e10 } -0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017e10 } -Entering state 11 -Stack now 0 11 + $1 = token 'a' (0xaaaafbdb42e0 'a') +-> $$ = nterm item (0xffffc2fd69e0 'a') +0xaaaafbdb42e0->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd69e0 } +0xaaaafbdb42e0->Object::Object { 0xffffc2fd69e0 } +0xffffc2fd69e0->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd69e0 } +Entering state 10 +Stack now 0 10 Reading a token -0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0 } -0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017cf0 } -0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017cf0, 0xffffc1017df0 } -Next token is token 'a' (0xffffc1017df0 'a') -0xffffc1017d30->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017df0 } -0xffffc1017df0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017d30, 0xffffc1017df0 } -Shifting token 'a' (0xffffc1017d30 'a') -0xaaaadfe9c300->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017d30 } -0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017d30 } -Entering state 2 -Stack now 0 11 2 -0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300 } +0xffffc2fd68c0->Object::Object { 0xaaaafbdb42e0 } +0xffffc2fd69c0->Object::Object { 0xaaaafbdb42e0, 0xffffc2fd68c0 } +0xffffc2fd68c0->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd68c0, 0xffffc2fd69c0 } +Next token is token 'a' (0xffffc2fd69c0 'a') +0xffffc2fd6900->Object::Object { 0xaaaafbdb42e0, 0xffffc2fd69c0 } +0xffffc2fd69c0->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd6900, 0xffffc2fd69c0 } +Shifting token 'a' (0xffffc2fd6900 'a') +0xaaaafbdb4300->Object::Object { 0xaaaafbdb42e0, 0xffffc2fd6900 } +0xffffc2fd6900->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd6900 } +Entering state 1 +Stack now 0 10 1 +0xffffc2fd69e0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaadfe9c300 'a') --> $$ = nterm item (0xffffc1017e10 'a') -0xaaaadfe9c300->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017e10 } -0xaaaadfe9c300->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017e10 } -0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017e10 } -Entering state 11 -Stack now 0 11 11 + $1 = token 'a' (0xaaaafbdb4300 'a') +-> $$ = nterm item (0xffffc2fd69e0 'a') +0xaaaafbdb4300->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd69e0 } +0xaaaafbdb4300->Object::Object { 0xaaaafbdb42e0, 0xffffc2fd69e0 } +0xffffc2fd69e0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd69e0 } +Entering state 10 +Stack now 0 10 10 Reading a token -0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300 } -0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017cf0 } -0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017cf0, 0xffffc1017df0 } -Next token is token 'a' (0xffffc1017df0 'a') -0xffffc1017d30->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017df0 } -0xffffc1017df0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017d30, 0xffffc1017df0 } -Shifting token 'a' (0xffffc1017d30 'a') -0xaaaadfe9c320->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017d30 } -0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017d30 } -Entering state 2 -Stack now 0 11 11 2 -0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320 } +0xffffc2fd68c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300 } +0xffffc2fd69c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd68c0 } +0xffffc2fd68c0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd68c0, 0xffffc2fd69c0 } +Next token is token 'a' (0xffffc2fd69c0 'a') +0xffffc2fd6900->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd69c0 } +0xffffc2fd69c0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd6900, 0xffffc2fd69c0 } +Shifting token 'a' (0xffffc2fd6900 'a') +0xaaaafbdb4320->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd6900 } +0xffffc2fd6900->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd6900 } +Entering state 1 +Stack now 0 10 10 1 +0xffffc2fd69e0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaadfe9c320 'a') --> $$ = nterm item (0xffffc1017e10 'a') -0xaaaadfe9c320->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017e10 } -0xaaaadfe9c320->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017e10 } -0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017e10 } -Entering state 11 -Stack now 0 11 11 11 + $1 = token 'a' (0xaaaafbdb4320 'a') +-> $$ = nterm item (0xffffc2fd69e0 'a') +0xaaaafbdb4320->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd69e0 } +0xaaaafbdb4320->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd69e0 } +0xffffc2fd69e0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd69e0 } +Entering state 10 +Stack now 0 10 10 10 Reading a token -0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320 } -0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017cf0 } -0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017cf0, 0xffffc1017df0 } -Next token is token 'a' (0xffffc1017df0 'a') -0xffffc1017d30->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017df0 } -0xffffc1017df0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017d30, 0xffffc1017df0 } -Shifting token 'a' (0xffffc1017d30 'a') -0xaaaadfe9c340->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017d30 } -0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017d30 } -Entering state 2 -Stack now 0 11 11 11 2 -0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340 } +0xffffc2fd68c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320 } +0xffffc2fd69c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd68c0 } +0xffffc2fd68c0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd68c0, 0xffffc2fd69c0 } +Next token is token 'a' (0xffffc2fd69c0 'a') +0xffffc2fd6900->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd69c0 } +0xffffc2fd69c0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd6900, 0xffffc2fd69c0 } +Shifting token 'a' (0xffffc2fd6900 'a') +0xaaaafbdb4340->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd6900 } +0xffffc2fd6900->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd6900 } +Entering state 1 +Stack now 0 10 10 10 1 +0xffffc2fd69e0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaadfe9c340 'a') --> $$ = nterm item (0xffffc1017e10 'a') -0xaaaadfe9c340->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017e10 } -0xaaaadfe9c340->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017e10 } -0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017e10 } -Entering state 11 -Stack now 0 11 11 11 11 + $1 = token 'a' (0xaaaafbdb4340 'a') +-> $$ = nterm item (0xffffc2fd69e0 'a') +0xaaaafbdb4340->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd69e0 } +0xaaaafbdb4340->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd69e0 } +0xffffc2fd69e0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd69e0 } +Entering state 10 +Stack now 0 10 10 10 10 Reading a token -0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340 } -0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017cf0 } -0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017cf0, 0xffffc1017df0 } -Next token is token 'p' (0xffffc1017df0 'p'Exception caught: cleaning lookahead and stack -0xaaaadfe9c340->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017df0 } -0xaaaadfe9c320->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017df0 } -0xaaaadfe9c300->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017df0 } -0xaaaadfe9c2e0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017df0 } -0xffffc1017df0->Object::~Object { 0xffffc1017df0 } +0xffffc2fd68c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340 } +0xffffc2fd69c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd68c0 } +0xffffc2fd68c0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd68c0, 0xffffc2fd69c0 } +Next token is token 'p' (0xffffc2fd69c0 'p'Exception caught: cleaning lookahead and stack +0xaaaafbdb4340->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd69c0 } +0xaaaafbdb4320->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd69c0 } +0xaaaafbdb4300->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd69c0 } +0xaaaafbdb42e0->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd69c0 } +0xffffc2fd69c0->Object::~Object { 0xffffc2fd69c0 } exception caught: printer end { } -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -exception caught: reduction -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./cxx-type.at:435: $PREPARSER ./types test-input -./c++.at:1360: $PREPARSER ./input --debug aaaap -stderr: +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./c++.at:1361: $PREPARSER ./input aaaal -syntax error +stdout: Starting parse Entering state 0 Stack now 0 Reading a token -0xffffc1017cf0->Object::Object { } -0xffffc1017df0->Object::Object { 0xffffc1017cf0 } -0xffffc1017cf0->Object::~Object { 0xffffc1017cf0, 0xffffc1017df0 } -Next token is token 'a' (0xffffc1017df0 'a') -0xffffc1017d30->Object::Object { 0xffffc1017df0 } -0xffffc1017df0->Object::~Object { 0xffffc1017d30, 0xffffc1017df0 } -Shifting token 'a' (0xffffc1017d30 'a') -0xaaaadfe9c2e0->Object::Object { 0xffffc1017d30 } -0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017d30 } -Entering state 2 -Stack now 0 2 -0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0 } +0xffffc2fd68c0->Object::Object { } +0xffffc2fd69c0->Object::Object { 0xffffc2fd68c0 } +0xffffc2fd68c0->Object::~Object { 0xffffc2fd68c0, 0xffffc2fd69c0 } +Next token is token 'a' (0xffffc2fd69c0 'a') +0xffffc2fd6900->Object::Object { 0xffffc2fd69c0 } +0xffffc2fd69c0->Object::~Object { 0xffffc2fd6900, 0xffffc2fd69c0 } +Shifting token 'a' (0xffffc2fd6900 'a') +0xaaaafbdb42e0->Object::Object { 0xffffc2fd6900 } +0xffffc2fd6900->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd6900 } +Entering state 1 +Stack now 0 1 +0xffffc2fd69e0->Object::Object { 0xaaaafbdb42e0 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaadfe9c2e0 'a') --> $$ = nterm item (0xffffc1017e10 'a') -0xaaaadfe9c2e0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017e10 } -0xaaaadfe9c2e0->Object::Object { 0xffffc1017e10 } -0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017e10 } -Entering state 11 -Stack now 0 11 + $1 = token 'a' (0xaaaafbdb42e0 'a') +-> $$ = nterm item (0xffffc2fd69e0 'a') +0xaaaafbdb42e0->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd69e0 } +0xaaaafbdb42e0->Object::Object { 0xffffc2fd69e0 } +0xffffc2fd69e0->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd69e0 } +Entering state 10 +Stack now 0 10 Reading a token -0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0 } -0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017cf0 } -0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017cf0, 0xffffc1017df0 } -Next token is token 'a' (0xffffc1017df0 'a') -0xffffc1017d30->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017df0 } -0xffffc1017df0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017d30, 0xffffc1017df0 } -Shifting token 'a' (0xffffc1017d30 'a') -0xaaaadfe9c300->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017d30 } -0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017d30 } -Entering state 2 -Stack now 0 11 2 -0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300 } +0xffffc2fd68c0->Object::Object { 0xaaaafbdb42e0 } +0xffffc2fd69c0->Object::Object { 0xaaaafbdb42e0, 0xffffc2fd68c0 } +0xffffc2fd68c0->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd68c0, 0xffffc2fd69c0 } +Next token is token 'a' (0xffffc2fd69c0 'a') +0xffffc2fd6900->Object::Object { 0xaaaafbdb42e0, 0xffffc2fd69c0 } +0xffffc2fd69c0->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd6900, 0xffffc2fd69c0 } +Shifting token 'a' (0xffffc2fd6900 'a') +0xaaaafbdb4300->Object::Object { 0xaaaafbdb42e0, 0xffffc2fd6900 } +0xffffc2fd6900->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd6900 } +Entering state 1 +Stack now 0 10 1 +0xffffc2fd69e0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaadfe9c300 'a') --> $$ = nterm item (0xffffc1017e10 'a') -0xaaaadfe9c300->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017e10 } -0xaaaadfe9c300->Object::Object { 0xaaaadfe9c2e0, 0xffffc1017e10 } -0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017e10 } -Entering state 11 -Stack now 0 11 11 + $1 = token 'a' (0xaaaafbdb4300 'a') +-> $$ = nterm item (0xffffc2fd69e0 'a') +0xaaaafbdb4300->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd69e0 } +0xaaaafbdb4300->Object::Object { 0xaaaafbdb42e0, 0xffffc2fd69e0 } +0xffffc2fd69e0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd69e0 } +Entering state 10 +Stack now 0 10 10 Reading a token -0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300 } -0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017cf0 } -0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017cf0, 0xffffc1017df0 } -Next token is token 'a' (0xffffc1017df0 'a') -0xffffc1017d30->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017df0 } -0xffffc1017df0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017d30, 0xffffc1017df0 } -Shifting token 'a' (0xffffc1017d30 'a') -0xaaaadfe9c320->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017d30 } -0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017d30 } -Entering state 2 -Stack now 0 11 11 2 -0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320 } +0xffffc2fd68c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300 } +0xffffc2fd69c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd68c0 } +0xffffc2fd68c0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd68c0, 0xffffc2fd69c0 } +Next token is token 'a' (0xffffc2fd69c0 'a') +0xffffc2fd6900->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd69c0 } +0xffffc2fd69c0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd6900, 0xffffc2fd69c0 } +Shifting token 'a' (0xffffc2fd6900 'a') +0xaaaafbdb4320->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd6900 } +0xffffc2fd6900->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd6900 } +Entering state 1 +Stack now 0 10 10 1 +0xffffc2fd69e0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaadfe9c320 'a') --> $$ = nterm item (0xffffc1017e10 'a') -0xaaaadfe9c320->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017e10 } -0xaaaadfe9c320->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017e10 } -0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017e10 } -Entering state 11 -Stack now 0 11 11 11 + $1 = token 'a' (0xaaaafbdb4320 'a') +-> $$ = nterm item (0xffffc2fd69e0 'a') +0xaaaafbdb4320->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd69e0 } +0xaaaafbdb4320->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd69e0 } +0xffffc2fd69e0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd69e0 } +Entering state 10 +Stack now 0 10 10 10 Reading a token -0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320 } -0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017cf0 } -0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017cf0, 0xffffc1017df0 } -Next token is token 'a' (0xffffc1017df0 'a') -0xffffc1017d30->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017df0 } -0xffffc1017df0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017d30, 0xffffc1017df0 } -Shifting token 'a' (0xffffc1017d30 'a') -0xaaaadfe9c340->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017d30 } -0xffffc1017d30->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017d30 } -Entering state 2 -Stack now 0 11 11 11 2 -0xffffc1017e10->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340 } +0xffffc2fd68c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320 } +0xffffc2fd69c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd68c0 } +0xffffc2fd68c0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd68c0, 0xffffc2fd69c0 } +Next token is token 'a' (0xffffc2fd69c0 'a') +0xffffc2fd6900->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd69c0 } +0xffffc2fd69c0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd6900, 0xffffc2fd69c0 } +Shifting token 'a' (0xffffc2fd6900 'a') +0xaaaafbdb4340->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd6900 } +0xffffc2fd6900->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd6900 } +Entering state 1 +Stack now 0 10 10 10 1 +0xffffc2fd69e0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaadfe9c340 'a') --> $$ = nterm item (0xffffc1017e10 'a') -0xaaaadfe9c340->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017e10 } -0xaaaadfe9c340->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017e10 } -0xffffc1017e10->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017e10 } -Entering state 11 -Stack now 0 11 11 11 11 + $1 = token 'a' (0xaaaafbdb4340 'a') +-> $$ = nterm item (0xffffc2fd69e0 'a') +0xaaaafbdb4340->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd69e0 } +0xaaaafbdb4340->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd69e0 } +0xffffc2fd69e0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd69e0 } +Entering state 10 +Stack now 0 10 10 10 10 Reading a token -0xffffc1017cf0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340 } -0xffffc1017df0->Object::Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017cf0 } -0xffffc1017cf0->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017cf0, 0xffffc1017df0 } -Next token is token 'p' (0xffffc1017df0 'p'Exception caught: cleaning lookahead and stack -0xaaaadfe9c340->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xaaaadfe9c340, 0xffffc1017df0 } -0xaaaadfe9c320->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xaaaadfe9c320, 0xffffc1017df0 } -0xaaaadfe9c300->Object::~Object { 0xaaaadfe9c2e0, 0xaaaadfe9c300, 0xffffc1017df0 } -0xaaaadfe9c2e0->Object::~Object { 0xaaaadfe9c2e0, 0xffffc1017df0 } -0xffffc1017df0->Object::~Object { 0xffffc1017df0 } +0xffffc2fd68c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340 } +0xffffc2fd69c0->Object::Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd68c0 } +0xffffc2fd68c0->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd68c0, 0xffffc2fd69c0 } +Next token is token 'p' (0xffffc2fd69c0 'p'Exception caught: cleaning lookahead and stack +0xaaaafbdb4340->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xaaaafbdb4340, 0xffffc2fd69c0 } +0xaaaafbdb4320->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xaaaafbdb4320, 0xffffc2fd69c0 } +0xaaaafbdb4300->Object::~Object { 0xaaaafbdb42e0, 0xaaaafbdb4300, 0xffffc2fd69c0 } +0xaaaafbdb42e0->Object::~Object { 0xaaaafbdb42e0, 0xffffc2fd69c0 } +0xffffc2fd69c0->Object::~Object { 0xffffc2fd69c0 } exception caught: printer end { } -./c++.at:1362: grep '^exception caught: printer$' stderr +./c++.at:1363: grep '^exception caught: printer$' stderr +stderr: +./c++.at:1064: $PREPARSER ./input < in +stdout: +stdout: +exception caught: printer +./c++.at:1363: $PREPARSER ./input aaaae +./c++.at:1361: $PREPARSER ./input aaaas +stderr: +stderr: +stderr: +exception caught: reduction +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +error: invalid expression +caught error +error: invalid character +caught error +./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +exception caught: syntax error +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input aaaal +./c++.at:1064: $PREPARSER ./input < in +./c++.at:1363: $PREPARSER ./input aaaaE +stderr: +stderr: +stderr: +exception caught: yylex +exception caught: syntax error, unexpected end of file, expecting 'a' +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +error: invalid expression +./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input i +./c++.at:1064: $PREPARSER ./input < in +./c++.at:1363: $PREPARSER ./input aaaaT +stderr: +stderr: +exception caught: initial-action +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +error: invalid character +./c++.at:1064: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1363: $PREPARSER ./input aaaaR +stderr: +./c++.at:1361: $PREPARSER ./input aaaap +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +682. c++.at:1064: ok stderr: +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xaaaae43d8f40->Object::Object { } -Next token is token 'a' (0xaaaae43d8f40 'a') -Shifting token 'a' (0xaaaae43d8f40 'a') -Entering state 2 -Stack now 0 2 +0xaaaaeaddcf40->Object::Object { } +Next token is token 'a' (0xaaaaeaddcf40 'a') +Shifting token 'a' (0xaaaaeaddcf40 'a') +Entering state 1 +Stack now 0 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae43d8f40 'a') --> $$ = nterm item (0xaaaae43d8f40 'a') -Entering state 11 -Stack now 0 11 + $1 = token 'a' (0xaaaaeaddcf40 'a') +-> $$ = nterm item (0xaaaaeaddcf40 'a') +Entering state 10 +Stack now 0 10 Reading a token -0xaaaae43d8f90->Object::Object { 0xaaaae43d8f40 } -Next token is token 'a' (0xaaaae43d8f90 'a') -Shifting token 'a' (0xaaaae43d8f90 'a') -Entering state 2 -Stack now 0 11 2 +0xaaaaeaddcf90->Object::Object { 0xaaaaeaddcf40 } +Next token is token 'a' (0xaaaaeaddcf90 'a') +Shifting token 'a' (0xaaaaeaddcf90 'a') +Entering state 1 +Stack now 0 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae43d8f90 'a') --> $$ = nterm item (0xaaaae43d8f90 'a') -Entering state 11 -Stack now 0 11 11 + $1 = token 'a' (0xaaaaeaddcf90 'a') +-> $$ = nterm item (0xaaaaeaddcf90 'a') +Entering state 10 +Stack now 0 10 10 Reading a token -0xaaaae43d8fe0->Object::Object { 0xaaaae43d8f40, 0xaaaae43d8f90 } -Next token is token 'a' (0xaaaae43d8fe0 'a') -Shifting token 'a' (0xaaaae43d8fe0 'a') -Entering state 2 -Stack now 0 11 11 2 +0xaaaaeaddcfe0->Object::Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90 } +Next token is token 'a' (0xaaaaeaddcfe0 'a') +Shifting token 'a' (0xaaaaeaddcfe0 'a') +Entering state 1 +Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae43d8fe0 'a') --> $$ = nterm item (0xaaaae43d8fe0 'a') -Entering state 11 -Stack now 0 11 11 11 + $1 = token 'a' (0xaaaaeaddcfe0 'a') +-> $$ = nterm item (0xaaaaeaddcfe0 'a') +Entering state 10 +Stack now 0 10 10 10 Reading a token -0xaaaae43d9030->Object::Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0 } -Next token is token 'a' (0xaaaae43d9030 'a') -Shifting token 'a' (0xaaaae43d9030 'a') -Entering state 2 -Stack now 0 11 11 11 2 +0xaaaaeaddd030->Object::Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90, 0xaaaaeaddcfe0 } +Next token is token 'a' (0xaaaaeaddd030 'a') +Shifting token 'a' (0xaaaaeaddd030 'a') +Entering state 1 +Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae43d9030 'a') --> $$ = nterm item (0xaaaae43d9030 'a') -Entering state 11 -Stack now 0 11 11 11 11 + $1 = token 'a' (0xaaaaeaddd030 'a') +-> $$ = nterm item (0xaaaaeaddd030 'a') +Entering state 10 +Stack now 0 10 10 10 10 Reading a token -0xaaaae43d9080->Object::Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0, 0xaaaae43d9030 } -Next token is token 'p' (0xaaaae43d9080 'p'Exception caught: cleaning lookahead and stack -0xaaaae43d9080->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0, 0xaaaae43d9030, 0xaaaae43d9080 } -0xaaaae43d9030->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0, 0xaaaae43d9030 } -0xaaaae43d8fe0->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0 } -0xaaaae43d8f90->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90 } -0xaaaae43d8f40->Object::~Object { 0xaaaae43d8f40 } +0xaaaaeaddd080->Object::Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90, 0xaaaaeaddcfe0, 0xaaaaeaddd030 } +Next token is token 'p' (0xaaaaeaddd080 'p'Exception caught: cleaning lookahead and stack +0xaaaaeaddd080->Object::~Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90, 0xaaaaeaddcfe0, 0xaaaaeaddd030, 0xaaaaeaddd080 } +0xaaaaeaddd030->Object::~Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90, 0xaaaaeaddcfe0, 0xaaaaeaddd030 } +0xaaaaeaddcfe0->Object::~Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90, 0xaaaaeaddcfe0 } +0xaaaaeaddcf90->Object::~Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90 } +0xaaaaeaddcf40->Object::~Object { 0xaaaaeaddcf40 } exception caught: printer end { } -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -exception caught: yylex ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: + stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xaaaae43d8f40->Object::Object { } -Next token is token 'a' (0xaaaae43d8f40 'a') -Shifting token 'a' (0xaaaae43d8f40 'a') -Entering state 2 -Stack now 0 2 +0xaaaaeaddcf40->Object::Object { } +Next token is token 'a' (0xaaaaeaddcf40 'a') +Shifting token 'a' (0xaaaaeaddcf40 'a') +Entering state 1 +Stack now 0 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae43d8f40 'a') --> $$ = nterm item (0xaaaae43d8f40 'a') -Entering state 11 -Stack now 0 11 + $1 = token 'a' (0xaaaaeaddcf40 'a') +-> $$ = nterm item (0xaaaaeaddcf40 'a') +Entering state 10 +Stack now 0 10 Reading a token -0xaaaae43d8f90->Object::Object { 0xaaaae43d8f40 } -Next token is token 'a' (0xaaaae43d8f90 'a') -Shifting token 'a' (0xaaaae43d8f90 'a') -Entering state 2 -Stack now 0 11 2 +0xaaaaeaddcf90->Object::Object { 0xaaaaeaddcf40 } +Next token is token 'a' (0xaaaaeaddcf90 'a') +Shifting token 'a' (0xaaaaeaddcf90 'a') +Entering state 1 +Stack now 0 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae43d8f90 'a') --> $$ = nterm item (0xaaaae43d8f90 'a') -Entering state 11 -Stack now 0 11 11 + $1 = token 'a' (0xaaaaeaddcf90 'a') +-> $$ = nterm item (0xaaaaeaddcf90 'a') +Entering state 10 +Stack now 0 10 10 Reading a token -0xaaaae43d8fe0->Object::Object { 0xaaaae43d8f40, 0xaaaae43d8f90 } -Next token is token 'a' (0xaaaae43d8fe0 'a') -Shifting token 'a' (0xaaaae43d8fe0 'a') -Entering state 2 -Stack now 0 11 11 2 +0xaaaaeaddcfe0->Object::Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90 } +Next token is token 'a' (0xaaaaeaddcfe0 'a') +Shifting token 'a' (0xaaaaeaddcfe0 'a') +Entering state 1 +Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae43d8fe0 'a') --> $$ = nterm item (0xaaaae43d8fe0 'a') -Entering state 11 -Stack now 0 11 11 11 + $1 = token 'a' (0xaaaaeaddcfe0 'a') +-> $$ = nterm item (0xaaaaeaddcfe0 'a') +Entering state 10 +Stack now 0 10 10 10 Reading a token -0xaaaae43d9030->Object::Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0 } -Next token is token 'a' (0xaaaae43d9030 'a') -Shifting token 'a' (0xaaaae43d9030 'a') -Entering state 2 -Stack now 0 11 11 11 2 +0xaaaaeaddd030->Object::Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90, 0xaaaaeaddcfe0 } +Next token is token 'a' (0xaaaaeaddd030 'a') +Shifting token 'a' (0xaaaaeaddd030 'a') +Entering state 1 +Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae43d9030 'a') --> $$ = nterm item (0xaaaae43d9030 'a') -Entering state 11 -Stack now 0 11 11 11 11 + $1 = token 'a' (0xaaaaeaddd030 'a') +-> $$ = nterm item (0xaaaaeaddd030 'a') +Entering state 10 +Stack now 0 10 10 10 10 Reading a token -0xaaaae43d9080->Object::Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0, 0xaaaae43d9030 } -Next token is token 'p' (0xaaaae43d9080 'p'Exception caught: cleaning lookahead and stack -0xaaaae43d9080->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0, 0xaaaae43d9030, 0xaaaae43d9080 } -0xaaaae43d9030->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0, 0xaaaae43d9030 } -0xaaaae43d8fe0->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90, 0xaaaae43d8fe0 } -0xaaaae43d8f90->Object::~Object { 0xaaaae43d8f40, 0xaaaae43d8f90 } -0xaaaae43d8f40->Object::~Object { 0xaaaae43d8f40 } +0xaaaaeaddd080->Object::Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90, 0xaaaaeaddcfe0, 0xaaaaeaddd030 } +Next token is token 'p' (0xaaaaeaddd080 'p'Exception caught: cleaning lookahead and stack +0xaaaaeaddd080->Object::~Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90, 0xaaaaeaddcfe0, 0xaaaaeaddd030, 0xaaaaeaddd080 } +0xaaaaeaddd030->Object::~Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90, 0xaaaaeaddcfe0, 0xaaaaeaddd030 } +0xaaaaeaddcfe0->Object::~Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90, 0xaaaaeaddcfe0 } +0xaaaaeaddcf90->Object::~Object { 0xaaaaeaddcf40, 0xaaaaeaddcf90 } +0xaaaaeaddcf40->Object::~Object { 0xaaaaeaddcf40 } exception caught: printer end { } -./c++.at:1360: grep '^exception caught: printer$' stderr -exception caught: printer -./c++.at:1362: $PREPARSER ./input aaaae +./c++.at:1361: grep '^exception caught: printer$' stderr stdout: stderr: exception caught: printer -./c++.at:1360: $PREPARSER ./input aaaae -exception caught: syntax error -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./cxx-type.at:435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input aaaae stderr: +stdout: exception caught: syntax error -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1362: $PREPARSER ./input aaaaE +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./cxx-type.at:435: $PREPARSER ./types test-input +stderr: +syntax error +./cxx-type.at:435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input aaaaE stderr: ./cxx-type.at:435: $PREPARSER ./types -p test-input +711. cxx-type.at:444: testing GLR: Merge conflicting parses, pure, no locations ... +./cxx-type.at:445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y exception caught: syntax error, unexpected end of file, expecting 'a' -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 @@ -263107,9 +262508,10 @@ Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () -./c++.at:1362: $PREPARSER ./input aaaaT ./cxx-type.at:435: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: $PREPARSER ./input i +./c++.at:1361: $PREPARSER ./input aaaaT +stderr: +stderr: stderr: Starting parse Entering state 0 @@ -263719,192 +263121,49 @@ Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () -stderr: -stderr: -./c++.at:1360: $PREPARSER ./input aaaaE +types.y:77.8-37: warning: unset value: $$ [-Wother] +types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] +types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples +./cxx-type.at:445: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS 709. cxx-type.at:432: ok -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -exception caught: initial-action -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -exception caught: syntax error, unexpected end of file, expecting 'a' -./c++.at:1361: $PREPARSER ./input aaaap -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1362: $PREPARSER ./input aaaaR - -./c++.at:1361: $PREPARSER ./input --debug aaaap -./c++.at:1360: $PREPARSER ./input aaaaT -stderr: -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -0xaaaae3ef4f40->Object::Object { } -Next token is token 'a' (0xaaaae3ef4f40 'a') -Shifting token 'a' (0xaaaae3ef4f40 'a') -Entering state 1 -Stack now 0 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae3ef4f40 'a') --> $$ = nterm item (0xaaaae3ef4f40 'a') -Entering state 10 -Stack now 0 10 -Reading a token -0xaaaae3ef4f90->Object::Object { 0xaaaae3ef4f40 } -Next token is token 'a' (0xaaaae3ef4f90 'a') -Shifting token 'a' (0xaaaae3ef4f90 'a') -Entering state 1 -Stack now 0 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae3ef4f90 'a') --> $$ = nterm item (0xaaaae3ef4f90 'a') -Entering state 10 -Stack now 0 10 10 -Reading a token -0xaaaae3ef4fe0->Object::Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90 } -Next token is token 'a' (0xaaaae3ef4fe0 'a') -Shifting token 'a' (0xaaaae3ef4fe0 'a') -Entering state 1 -Stack now 0 10 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae3ef4fe0 'a') --> $$ = nterm item (0xaaaae3ef4fe0 'a') -Entering state 10 -Stack now 0 10 10 10 -Reading a token -0xaaaae3ef5030->Object::Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0 } -Next token is token 'a' (0xaaaae3ef5030 'a') -Shifting token 'a' (0xaaaae3ef5030 'a') -Entering state 1 -Stack now 0 10 10 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae3ef5030 'a') --> $$ = nterm item (0xaaaae3ef5030 'a') -Entering state 10 -Stack now 0 10 10 10 10 -Reading a token -0xaaaae3ef5080->Object::Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0, 0xaaaae3ef5030 } -Next token is token 'p' (0xaaaae3ef5080 'p'Exception caught: cleaning lookahead and stack -0xaaaae3ef5080->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0, 0xaaaae3ef5030, 0xaaaae3ef5080 } -0xaaaae3ef5030->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0, 0xaaaae3ef5030 } -0xaaaae3ef4fe0->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0 } -0xaaaae3ef4f90->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90 } -0xaaaae3ef4f40->Object::~Object { 0xaaaae3ef4f40 } -exception caught: printer -end { } -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -0xaaaae3ef4f40->Object::Object { } -Next token is token 'a' (0xaaaae3ef4f40 'a') -Shifting token 'a' (0xaaaae3ef4f40 'a') -Entering state 1 -Stack now 0 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae3ef4f40 'a') --> $$ = nterm item (0xaaaae3ef4f40 'a') -Entering state 10 -Stack now 0 10 -Reading a token -0xaaaae3ef4f90->Object::Object { 0xaaaae3ef4f40 } -Next token is token 'a' (0xaaaae3ef4f90 'a') -Shifting token 'a' (0xaaaae3ef4f90 'a') -Entering state 1 -Stack now 0 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae3ef4f90 'a') --> $$ = nterm item (0xaaaae3ef4f90 'a') -Entering state 10 -Stack now 0 10 10 -Reading a token -0xaaaae3ef4fe0->Object::Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90 } -Next token is token 'a' (0xaaaae3ef4fe0 'a') -Shifting token 'a' (0xaaaae3ef4fe0 'a') -Entering state 1 -Stack now 0 10 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae3ef4fe0 'a') --> $$ = nterm item (0xaaaae3ef4fe0 'a') -Entering state 10 -Stack now 0 10 10 10 -Reading a token -0xaaaae3ef5030->Object::Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0 } -Next token is token 'a' (0xaaaae3ef5030 'a') -Shifting token 'a' (0xaaaae3ef5030 'a') -Entering state 1 -Stack now 0 10 10 10 1 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae3ef5030 'a') --> $$ = nterm item (0xaaaae3ef5030 'a') -Entering state 10 -Stack now 0 10 10 10 10 -Reading a token -0xaaaae3ef5080->Object::Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0, 0xaaaae3ef5030 } -Next token is token 'p' (0xaaaae3ef5080 'p'Exception caught: cleaning lookahead and stack -0xaaaae3ef5080->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0, 0xaaaae3ef5030, 0xaaaae3ef5080 } -0xaaaae3ef5030->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0, 0xaaaae3ef5030 } -0xaaaae3ef4fe0->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90, 0xaaaae3ef4fe0 } -0xaaaae3ef4f90->Object::~Object { 0xaaaae3ef4f40, 0xaaaae3ef4f90 } -0xaaaae3ef4f40->Object::~Object { 0xaaaae3ef4f40 } -exception caught: printer -end { } -./c++.at:1361: grep '^exception caught: printer$' stderr -stdout: -exception caught: printer -./c++.at:1361: $PREPARSER ./input aaaae -stderr: -exception caught: syntax error -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:1361: $PREPARSER ./input aaaaE -./c++.at:1360: $PREPARSER ./input aaaaR -stderr: -exception caught: syntax error, unexpected end of file, expecting 'a' -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1361: $PREPARSER ./input aaaaT -./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaaR stderr: -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -713. cxx-type.at:455: testing GLR: Verbose messages, resolve ambiguity, impure, no locations ... ./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -======== Testing with C++ standard flags: '' -./cxx-type.at:456: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y -./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS + +712. cxx-type.at:449: testing GLR: Merge conflicting parses, pure, locations ... +./cxx-type.at:450: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y stderr: -types.y:77.8-37: warning: unset value: $$ [-Wother] +types.y:87.8-37: warning: unset value: $$ [-Wother] types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples -./cxx-type.at:456: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS +./cxx-type.at:450: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS stderr: stdout: ./cxx-type.at:441: $PREPARSER ./types test-input stderr: -17.5: syntax error -stderr: stdout: -./c++.at:1555: $PREPARSER ./test +./c++.at:1360: $PREPARSER ./input aaaas +stderr: +stderr: +exception caught: reduction +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +17.5: syntax error +./c++.at:1360: $PREPARSER ./input aaaal ./cxx-type.at:441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -691. c++.at:1517: ok - +exception caught: yylex +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:441: $PREPARSER ./types -p test-input +./c++.at:1360: $PREPARSER ./input i +stderr: +stdout: +stderr: stderr: +exception caught: initial-action +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): @@ -264513,11 +263772,17 @@ Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) +./c++.at:851: $PREPARSER ./input +stderr: +./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:441: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: $PREPARSER ./input aaaap stderr: -stdout: +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: -714. glr-regression.at:205: testing Badly Collapsed GLR States: glr.c ... +./c++.at:1360: $PREPARSER ./input --debug aaaap Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 71): @@ -265126,29 +264391,305 @@ Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) -./cxx-type.at:447: $PREPARSER ./types test-input -./glr-regression.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o glr-regr1.c glr-regr1.y stderr: 710. cxx-type.at:438: ok -stdout: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +0xaaaae45fcf40->Object::Object { } +Next token is token 'a' (0xaaaae45fcf40 'a') +Shifting token 'a' (0xaaaae45fcf40 'a') +Entering state 2 +Stack now 0 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaae45fcf40 'a') +-> $$ = nterm item (0xaaaae45fcf40 'a') +Entering state 11 +Stack now 0 11 +Reading a token +0xaaaae45fcf90->Object::Object { 0xaaaae45fcf40 } +Next token is token 'a' (0xaaaae45fcf90 'a') +Shifting token 'a' (0xaaaae45fcf90 'a') +Entering state 2 +Stack now 0 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaae45fcf90 'a') +-> $$ = nterm item (0xaaaae45fcf90 'a') +Entering state 11 +Stack now 0 11 11 +Reading a token +0xaaaae45fcfe0->Object::Object { 0xaaaae45fcf40, 0xaaaae45fcf90 } +Next token is token 'a' (0xaaaae45fcfe0 'a') +Shifting token 'a' (0xaaaae45fcfe0 'a') +Entering state 2 +Stack now 0 11 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaae45fcfe0 'a') +-> $$ = nterm item (0xaaaae45fcfe0 'a') +Entering state 11 +Stack now 0 11 11 11 +Reading a token +0xaaaae45fd030->Object::Object { 0xaaaae45fcf40, 0xaaaae45fcf90, 0xaaaae45fcfe0 } +Next token is token 'a' (0xaaaae45fd030 'a') +Shifting token 'a' (0xaaaae45fd030 'a') +Entering state 2 +Stack now 0 11 11 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaae45fd030 'a') +-> $$ = nterm item (0xaaaae45fd030 'a') +Entering state 11 +Stack now 0 11 11 11 11 +Reading a token +0xaaaae45fd080->Object::Object { 0xaaaae45fcf40, 0xaaaae45fcf90, 0xaaaae45fcfe0, 0xaaaae45fd030 } +Next token is token 'p' (0xaaaae45fd080 'p'Exception caught: cleaning lookahead and stack +0xaaaae45fd080->Object::~Object { 0xaaaae45fcf40, 0xaaaae45fcf90, 0xaaaae45fcfe0, 0xaaaae45fd030, 0xaaaae45fd080 } +0xaaaae45fd030->Object::~Object { 0xaaaae45fcf40, 0xaaaae45fcf90, 0xaaaae45fcfe0, 0xaaaae45fd030 } +0xaaaae45fcfe0->Object::~Object { 0xaaaae45fcf40, 0xaaaae45fcf90, 0xaaaae45fcfe0 } +0xaaaae45fcf90->Object::~Object { 0xaaaae45fcf40, 0xaaaae45fcf90 } +0xaaaae45fcf40->Object::~Object { 0xaaaae45fcf40 } +exception caught: printer +end { } +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -syntax error -./c++.at:1363: $PREPARSER ./input aaaas +stdout: +./c++.at:1066: $PREPARSER ./input < in stderr: -./cxx-type.at:447: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +Starting parse +Entering state 0 +Stack now 0 +Reading a token +0xaaaae45fcf40->Object::Object { } +Next token is token 'a' (0xaaaae45fcf40 'a') +Shifting token 'a' (0xaaaae45fcf40 'a') +Entering state 2 +Stack now 0 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaae45fcf40 'a') +-> $$ = nterm item (0xaaaae45fcf40 'a') +Entering state 11 +Stack now 0 11 +Reading a token +0xaaaae45fcf90->Object::Object { 0xaaaae45fcf40 } +Next token is token 'a' (0xaaaae45fcf90 'a') +Shifting token 'a' (0xaaaae45fcf90 'a') +Entering state 2 +Stack now 0 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaae45fcf90 'a') +-> $$ = nterm item (0xaaaae45fcf90 'a') +Entering state 11 +Stack now 0 11 11 +Reading a token +0xaaaae45fcfe0->Object::Object { 0xaaaae45fcf40, 0xaaaae45fcf90 } +Next token is token 'a' (0xaaaae45fcfe0 'a') +Shifting token 'a' (0xaaaae45fcfe0 'a') +Entering state 2 +Stack now 0 11 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaae45fcfe0 'a') +-> $$ = nterm item (0xaaaae45fcfe0 'a') +Entering state 11 +Stack now 0 11 11 11 +Reading a token +0xaaaae45fd030->Object::Object { 0xaaaae45fcf40, 0xaaaae45fcf90, 0xaaaae45fcfe0 } +Next token is token 'a' (0xaaaae45fd030 'a') +Shifting token 'a' (0xaaaae45fd030 'a') +Entering state 2 +Stack now 0 11 11 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaae45fd030 'a') +-> $$ = nterm item (0xaaaae45fd030 'a') +Entering state 11 +Stack now 0 11 11 11 11 +Reading a token +0xaaaae45fd080->Object::Object { 0xaaaae45fcf40, 0xaaaae45fcf90, 0xaaaae45fcfe0, 0xaaaae45fd030 } +Next token is token 'p' (0xaaaae45fd080 'p'Exception caught: cleaning lookahead and stack +0xaaaae45fd080->Object::~Object { 0xaaaae45fcf40, 0xaaaae45fcf90, 0xaaaae45fcfe0, 0xaaaae45fd030, 0xaaaae45fd080 } +0xaaaae45fd030->Object::~Object { 0xaaaae45fcf40, 0xaaaae45fcf90, 0xaaaae45fcfe0, 0xaaaae45fd030 } +0xaaaae45fcfe0->Object::~Object { 0xaaaae45fcf40, 0xaaaae45fcf90, 0xaaaae45fcfe0 } +0xaaaae45fcf90->Object::~Object { 0xaaaae45fcf40, 0xaaaae45fcf90 } +0xaaaae45fcf40->Object::~Object { 0xaaaae45fcf40 } +exception caught: printer +end { } +./c++.at:1360: grep '^exception caught: printer$' stderr +stderr: +stdout: +stderr: +stdout: +./c++.at:857: $PREPARSER ./input +stderr: +error: invalid expression +caught error +error: invalid character +caught error +./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +exception caught: printer +./c++.at:1360: $PREPARSER ./input aaaae +stderr: +./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +exception caught: syntax error +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1066: $PREPARSER ./input < in +713. cxx-type.at:455: testing GLR: Verbose messages, resolve ambiguity, impure, no locations ... +./c++.at:1360: $PREPARSER ./input aaaaE +stderr: +stderr: +error: invalid expression +./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +exception caught: syntax error, unexpected end of file, expecting 'a' +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./cxx-type.at:456: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o types.c types.y +./c++.at:1360: $PREPARSER ./input aaaaT +./c++.at:1066: $PREPARSER ./input < in +stderr: +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./c++.at:1360: $PREPARSER ./input aaaaR +error: invalid character +./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +stdout: +./c++.at:1362: $PREPARSER ./input aaaas +stderr: +stderr: +types.y:77.8-37: warning: unset value: $$ [-Wother] +types.y: warning: 1 reduce/reduce conflict [-Wconflicts-rr] +types.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples exception caught: reduction -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./cxx-type.at:447: $PREPARSER ./types -p test-input -./c++.at:1363: $PREPARSER ./input aaaal +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./cxx-type.at:456: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o types types.c $LIBS +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:1362: $PREPARSER ./input aaaal +./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: exception caught: yylex -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1363: $PREPARSER ./input i -stderr: +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:1362: $PREPARSER ./input i stderr: exception caught: initial-action -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS +./c++.at:1362: $PREPARSER ./input aaaap +stderr: +stderr: +stdout: +./cxx-type.at:447: $PREPARSER ./types test-input +stderr: +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error +./cxx-type.at:447: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1362: $PREPARSER ./input --debug aaaap +stderr: +./cxx-type.at:447: $PREPARSER ./types -p test-input +Starting parse +Entering state 0 +Stack now 0 +Reading a token +0xffffd2ad09a0->Object::Object { } +0xffffd2ad0aa0->Object::Object { 0xffffd2ad09a0 } +0xffffd2ad09a0->Object::~Object { 0xffffd2ad09a0, 0xffffd2ad0aa0 } +Next token is token 'a' (0xffffd2ad0aa0 'a') +0xffffd2ad09e0->Object::Object { 0xffffd2ad0aa0 } +0xffffd2ad0aa0->Object::~Object { 0xffffd2ad09e0, 0xffffd2ad0aa0 } +Shifting token 'a' (0xffffd2ad09e0 'a') +0xaaaab96da2e0->Object::Object { 0xffffd2ad09e0 } +0xffffd2ad09e0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad09e0 } +Entering state 2 +Stack now 0 2 +0xffffd2ad0ac0->Object::Object { 0xaaaab96da2e0 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaab96da2e0 'a') +-> $$ = nterm item (0xffffd2ad0ac0 'a') +0xaaaab96da2e0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad0ac0 } +0xaaaab96da2e0->Object::Object { 0xffffd2ad0ac0 } +0xffffd2ad0ac0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad0ac0 } +Entering state 11 +Stack now 0 11 +Reading a token +0xffffd2ad09a0->Object::Object { 0xaaaab96da2e0 } +0xffffd2ad0aa0->Object::Object { 0xaaaab96da2e0, 0xffffd2ad09a0 } +0xffffd2ad09a0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad09a0, 0xffffd2ad0aa0 } +Next token is token 'a' (0xffffd2ad0aa0 'a') +0xffffd2ad09e0->Object::Object { 0xaaaab96da2e0, 0xffffd2ad0aa0 } +0xffffd2ad0aa0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad09e0, 0xffffd2ad0aa0 } +Shifting token 'a' (0xffffd2ad09e0 'a') +0xaaaab96da300->Object::Object { 0xaaaab96da2e0, 0xffffd2ad09e0 } +0xffffd2ad09e0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad09e0 } +Entering state 2 +Stack now 0 11 2 +0xffffd2ad0ac0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaab96da300 'a') +-> $$ = nterm item (0xffffd2ad0ac0 'a') +0xaaaab96da300->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad0ac0 } +0xaaaab96da300->Object::Object { 0xaaaab96da2e0, 0xffffd2ad0ac0 } +0xffffd2ad0ac0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad0ac0 } +Entering state 11 +Stack now 0 11 11 +Reading a token +0xffffd2ad09a0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300 } +0xffffd2ad0aa0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad09a0 } +0xffffd2ad09a0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad09a0, 0xffffd2ad0aa0 } +Next token is token 'a' (0xffffd2ad0aa0 'a') +0xffffd2ad09e0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad0aa0 } +0xffffd2ad0aa0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad09e0, 0xffffd2ad0aa0 } +Shifting token 'a' (0xffffd2ad09e0 'a') +0xaaaab96da320->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad09e0 } +0xffffd2ad09e0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad09e0 } +Entering state 2 +Stack now 0 11 11 2 +0xffffd2ad0ac0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaab96da320 'a') +-> $$ = nterm item (0xffffd2ad0ac0 'a') +0xaaaab96da320->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad0ac0 } +0xaaaab96da320->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad0ac0 } +0xffffd2ad0ac0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad0ac0 } +Entering state 11 +Stack now 0 11 11 11 +Reading a token +0xffffd2ad09a0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320 } +0xffffd2ad0aa0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad09a0 } +0xffffd2ad09a0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad09a0, 0xffffd2ad0aa0 } +Next token is token 'a' (0xffffd2ad0aa0 'a') +0xffffd2ad09e0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad0aa0 } +0xffffd2ad0aa0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad09e0, 0xffffd2ad0aa0 } +Shifting token 'a' (0xffffd2ad09e0 'a') +0xaaaab96da340->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad09e0 } +0xffffd2ad09e0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad09e0 } +Entering state 2 +Stack now 0 11 11 11 2 +0xffffd2ad0ac0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaab96da340 'a') +-> $$ = nterm item (0xffffd2ad0ac0 'a') +0xaaaab96da340->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad0ac0 } +0xaaaab96da340->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad0ac0 } +0xffffd2ad0ac0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad0ac0 } +Entering state 11 +Stack now 0 11 11 11 11 +Reading a token +0xffffd2ad09a0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340 } +0xffffd2ad0aa0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad09a0 } +0xffffd2ad09a0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad09a0, 0xffffd2ad0aa0 } +Next token is token 'p' (0xffffd2ad0aa0 'p'Exception caught: cleaning lookahead and stack +0xaaaab96da340->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad0aa0 } +0xaaaab96da320->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad0aa0 } +0xaaaab96da300->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad0aa0 } +0xaaaab96da2e0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad0aa0 } +0xffffd2ad0aa0->Object::~Object { 0xffffd2ad0aa0 } +exception caught: printer +end { } +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): @@ -265466,7 +265007,7 @@ -> $$ = nterm decl () Reducing stack -1 by rule 4 (line 75): $1 = nterm decl () --./glr-regression.at:205: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr1 glr-regr1.c $LIBS +-stdout: > $$ = nterm stmt () Reducing stack -1 by rule 7 (line 80): $1 = token ID () @@ -265758,220 +265299,10 @@ Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () -./c++.at:1363: $PREPARSER ./input aaaap +./c++.at:1066: ./check ./cxx-type.at:447: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1363: $PREPARSER ./input --debug aaaap -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -0xffffc7383f50->Object::Object { } -0xffffc7384050->Object::Object { 0xffffc7383f50 } -0xffffc7383f50->Object::~Object { 0xffffc7383f50, 0xffffc7384050 } -Next token is token 'a' (0xffffc7384050 'a') -0xffffc7383f90->Object::Object { 0xffffc7384050 } -0xffffc7384050->Object::~Object { 0xffffc7383f90, 0xffffc7384050 } -Shifting token 'a' (0xffffc7383f90 'a') -0xaaaaddfd62e0->Object::Object { 0xffffc7383f90 } -0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xffffc7383f90 } -Entering state 1 -Stack now 0 1 -0xffffc7384070->Object::Object { 0xaaaaddfd62e0 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaddfd62e0 'a') --> $$ = nterm item (0xffffc7384070 'a') -0xaaaaddfd62e0->Object::~Object { 0xaaaaddfd62e0, 0xffffc7384070 } -0xaaaaddfd62e0->Object::Object { 0xffffc7384070 } -0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xffffc7384070 } -Entering state 10 -Stack now 0 10 -Reading a token -0xffffc7383f50->Object::Object { 0xaaaaddfd62e0 } -0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xffffc7383f50 } -0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xffffc7383f50, 0xffffc7384050 } -Next token is token 'a' (0xffffc7384050 'a') -0xffffc7383f90->Object::Object { 0xaaaaddfd62e0, 0xffffc7384050 } -0xffffc7384050->Object::~Object { 0xaaaaddfd62e0, 0xffffc7383f90, 0xffffc7384050 } -Shifting token 'a' (0xffffc7383f90 'a') -0xaaaaddfd6300->Object::Object { 0xaaaaddfd62e0, 0xffffc7383f90 } -0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f90 } -Entering state 1 -Stack now 0 10 1 -0xffffc7384070->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaddfd6300 'a') --> $$ = nterm item (0xffffc7384070 'a') -0xaaaaddfd6300->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384070 } -0xaaaaddfd6300->Object::Object { 0xaaaaddfd62e0, 0xffffc7384070 } -0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384070 } -Entering state 10 -Stack now 0 10 10 -Reading a token -0xffffc7383f50->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300 } -0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f50 } -0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f50, 0xffffc7384050 } -Next token is token 'a' (0xffffc7384050 'a') -0xffffc7383f90->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384050 } -0xffffc7384050->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f90, 0xffffc7384050 } -Shifting token 'a' (0xffffc7383f90 'a') -0xaaaaddfd6320->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f90 } -0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f90 } -Entering state 1 -Stack now 0 10 10 1 -0xffffc7384070->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaddfd6320 'a') --> $$ = nterm item (0xffffc7384070 'a') -0xaaaaddfd6320->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384070 } -0xaaaaddfd6320->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384070 } -0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384070 } -Entering state 10 -Stack now 0 10 10 10 -Reading a token -0xffffc7383f50->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320 } -0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f50 } -0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f50, 0xffffc7384050 } -Next token is token 'a' (0xffffc7384050 'a') -0xffffc7383f90->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384050 } -0xffffc7384050->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f90, 0xffffc7384050 } -Shifting token 'a' (0xffffc7383f90 'a') -0xaaaaddfd6340->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f90 } -0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7383f90 } -Entering state 1 -Stack now 0 10 10 10 1 -0xffffc7384070->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaddfd6340 'a') --> $$ = nterm item (0xffffc7384070 'a') -0xaaaaddfd6340->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7384070 } -0xaaaaddfd6340->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384070 } -0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7384070 } -Entering state 10 -Stack now 0 10 10 10 10 -Reading a token -0xffffc7383f50->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340 } -0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7383f50 } -0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7383f50, 0xffffc7384050 } -Next token is token 'p' (0xffffc7384050 'p'Exception caught: cleaning lookahead and stack -0xaaaaddfd6340->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7384050 } -0xaaaaddfd6320->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384050 } -0xaaaaddfd6300->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384050 } -0xaaaaddfd62e0->Object::~Object { 0xaaaaddfd62e0, 0xffffc7384050 } -0xffffc7384050->Object::~Object { 0xffffc7384050 } -exception caught: printer -end { } -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -0xffffc7383f50->Object::Object { } -0xffffc7384050->Object::Object { 0xffffc7383f50 } -0xffffc7383f50->Object::~Object { 0xffffc7383f50, 0xffffc7384050 } -Next token is token 'a' (0xffffc7384050 'a') -0xffffc7383f90->Object::Object { 0xffffc7384050 } -0xffffc7384050->Object::~Object { 0xffffc7383f90, 0xffffc7384050 } -Shifting token 'a' (0xffffc7383f90 'a') -0xaaaaddfd62e0->Object::Object { 0xffffc7383f90 } -0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xffffc7383f90 } -Entering state 1 -Stack now 0 1 -0xffffc7384070->Object::Object { 0xaaaaddfd62e0 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaddfd62e0 'a') --> $$ = nterm item (0xffffc7384070 'a') -0xaaaaddfd62e0->Object::~Object { 0xaaaaddfd62e0, 0xffffc7384070 } -0xaaaaddfd62e0->Object::Object { 0xffffc7384070 } -0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xffffc7384070 } -Entering state 10 -Stack now 0 10 -Reading a token -0xffffc7383f50->Object::Object { 0xaaaaddfd62e0 } -0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xffffc7383f50 } -0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xffffc7383f50, 0xffffc7384050 } -Next token is token 'a' (0xffffc7384050 'a') -0xffffc7383f90->Object::Object { 0xaaaaddfd62e0, 0xffffc7384050 } -0xffffc7384050->Object::~Object { 0xaaaaddfd62e0, 0xffffc7383f90, 0xffffc7384050 } -Shifting token 'a' (0xffffc7383f90 'a') -0xaaaaddfd6300->Object::Object { 0xaaaaddfd62e0, 0xffffc7383f90 } -0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f90 } -Entering state 1 -Stack now 0 10 1 -0xffffc7384070->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaddfd6300 'a') --> $$ = nterm item (0xffffc7384070 'a') -0xaaaaddfd6300->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384070 } -0xaaaaddfd6300->Object::Object { 0xaaaaddfd62e0, 0xffffc7384070 } -0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384070 } -Entering state 10 -Stack now 0 10 10 -Reading a token -0xffffc7383f50->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300 } -0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f50 } -0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f50, 0xffffc7384050 } -Next token is token 'a' (0xffffc7384050 'a') -0xffffc7383f90->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384050 } -0xffffc7384050->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f90, 0xffffc7384050 } -Shifting token 'a' (0xffffc7383f90 'a') -0xaaaaddfd6320->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7383f90 } -0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f90 } -Entering state 1 -Stack now 0 10 10 1 -0xffffc7384070->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaddfd6320 'a') --> $$ = nterm item (0xffffc7384070 'a') -0xaaaaddfd6320->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384070 } -0xaaaaddfd6320->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384070 } -0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384070 } -Entering state 10 -Stack now 0 10 10 10 -Reading a token -0xffffc7383f50->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320 } -0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f50 } -0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f50, 0xffffc7384050 } -Next token is token 'a' (0xffffc7384050 'a') -0xffffc7383f90->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384050 } -0xffffc7384050->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f90, 0xffffc7384050 } -Shifting token 'a' (0xffffc7383f90 'a') -0xaaaaddfd6340->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7383f90 } -0xffffc7383f90->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7383f90 } -Entering state 1 -Stack now 0 10 10 10 1 -0xffffc7384070->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340 } -Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaddfd6340 'a') --> $$ = nterm item (0xffffc7384070 'a') -0xaaaaddfd6340->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7384070 } -0xaaaaddfd6340->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384070 } -0xffffc7384070->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7384070 } -Entering state 10 -Stack now 0 10 10 10 10 -Reading a token -0xffffc7383f50->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340 } -0xffffc7384050->Object::Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7383f50 } -0xffffc7383f50->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7383f50, 0xffffc7384050 } -Next token is token 'p' (0xffffc7384050 'p'Exception caught: cleaning lookahead and stack -0xaaaaddfd6340->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xaaaaddfd6340, 0xffffc7384050 } -0xaaaaddfd6320->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xaaaaddfd6320, 0xffffc7384050 } -0xaaaaddfd6300->Object::~Object { 0xaaaaddfd62e0, 0xaaaaddfd6300, 0xffffc7384050 } -0xaaaaddfd62e0->Object::~Object { 0xaaaaddfd62e0, 0xffffc7384050 } -0xffffc7384050->Object::~Object { 0xffffc7384050 } -exception caught: printer -end { } -./c++.at:1363: grep '^exception caught: printer$' stderr -stdout: -exception caught: printer -./c++.at:1363: $PREPARSER ./input aaaae -stderr: stderr: -exception caught: syntax error -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): @@ -266580,32 +265911,164 @@ Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () +./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS 711. cxx-type.at:444: ok -715. glr-regression.at:206: testing Badly Collapsed GLR States: glr.cc ... -./glr-regression.at:206: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o glr-regr1.cc glr-regr1.y -./c++.at:1363: $PREPARSER ./input aaaaE -./glr-regression.at:206: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr1 glr-regr1.cc $LIBS +Starting parse +Entering state 0 +Stack now 0 +Reading a token +0xffffd2ad09a0->Object::Object { } +0xffffd2ad0aa0->Object::Object { 0xffffd2ad09a0 } +0xffffd2ad09a0->Object::~Object { 0xffffd2ad09a0, 0xffffd2ad0aa0 } +Next token is token 'a' (0xffffd2ad0aa0 'a') +0xffffd2ad09e0->Object::Object { 0xffffd2ad0aa0 } +0xffffd2ad0aa0->Object::~Object { 0xffffd2ad09e0, 0xffffd2ad0aa0 } +Shifting token 'a' (0xffffd2ad09e0 'a') +0xaaaab96da2e0->Object::Object { 0xffffd2ad09e0 } +0xffffd2ad09e0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad09e0 } +Entering state 2 +Stack now 0 2 +0xffffd2ad0ac0->Object::Object { 0xaaaab96da2e0 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaab96da2e0 'a') +-> $$ = nterm item (0xffffd2ad0ac0 'a') +0xaaaab96da2e0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad0ac0 } +0xaaaab96da2e0->Object::Object { 0xffffd2ad0ac0 } +0xffffd2ad0ac0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad0ac0 } +Entering state 11 +Stack now 0 11 +Reading a token +0xffffd2ad09a0->Object::Object { 0xaaaab96da2e0 } +0xffffd2ad0aa0->Object::Object { 0xaaaab96da2e0, 0xffffd2ad09a0 } +0xffffd2ad09a0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad09a0, 0xffffd2ad0aa0 } +Next token is token 'a' (0xffffd2ad0aa0 'a') +0xffffd2ad09e0->Object::Object { 0xaaaab96da2e0, 0xffffd2ad0aa0 } +0xffffd2ad0aa0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad09e0, 0xffffd2ad0aa0 } +Shifting token 'a' (0xffffd2ad09e0 'a') +0xaaaab96da300->Object::Object { 0xaaaab96da2e0, 0xffffd2ad09e0 } +0xffffd2ad09e0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad09e0 } +Entering state 2 +Stack now 0 11 2 +0xffffd2ad0ac0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaab96da300 'a') +-> $$ = nterm item (0xffffd2ad0ac0 'a') +0xaaaab96da300->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad0ac0 } +0xaaaab96da300->Object::Object { 0xaaaab96da2e0, 0xffffd2ad0ac0 } +0xffffd2ad0ac0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad0ac0 } +Entering state 11 +Stack now 0 11 11 +Reading a token +0xffffd2ad09a0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300 } +0xffffd2ad0aa0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad09a0 } +0xffffd2ad09a0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad09a0, 0xffffd2ad0aa0 } +Next token is token 'a' (0xffffd2ad0aa0 'a') +0xffffd2ad09e0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad0aa0 } +0xffffd2ad0aa0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad09e0, 0xffffd2ad0aa0 } +Shifting token 'a' (0xffffd2ad09e0 'a') +0xaaaab96da320->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad09e0 } +0xffffd2ad09e0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad09e0 } +Entering state 2 +Stack now 0 11 11 2 +0xffffd2ad0ac0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaab96da320 'a') +-> $$ = nterm item (0xffffd2ad0ac0 'a') +0xaaaab96da320->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad0ac0 } +0xaaaab96da320->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad0ac0 } +0xffffd2ad0ac0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad0ac0 } +Entering state 11 +Stack now 0 11 11 11 +Reading a token +0xffffd2ad09a0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320 } +0xffffd2ad0aa0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad09a0 } +0xffffd2ad09a0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad09a0, 0xffffd2ad0aa0 } +Next token is token 'a' (0xffffd2ad0aa0 'a') +0xffffd2ad09e0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad0aa0 } +0xffffd2ad0aa0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad09e0, 0xffffd2ad0aa0 } +Shifting token 'a' (0xffffd2ad09e0 'a') +0xaaaab96da340->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad09e0 } +0xffffd2ad09e0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad09e0 } +Entering state 2 +Stack now 0 11 11 11 2 +0xffffd2ad0ac0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaab96da340 'a') +-> $$ = nterm item (0xffffd2ad0ac0 'a') +0xaaaab96da340->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad0ac0 } +0xaaaab96da340->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad0ac0 } +0xffffd2ad0ac0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad0ac0 } +Entering state 11 +Stack now 0 11 11 11 11 +Reading a token +0xffffd2ad09a0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340 } +0xffffd2ad0aa0->Object::Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad09a0 } +0xffffd2ad09a0->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad09a0, 0xffffd2ad0aa0 } +Next token is token 'p' (0xffffd2ad0aa0 'p'Exception caught: cleaning lookahead and stack +0xaaaab96da340->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xaaaab96da340, 0xffffd2ad0aa0 } +0xaaaab96da320->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xaaaab96da320, 0xffffd2ad0aa0 } +0xaaaab96da300->Object::~Object { 0xaaaab96da2e0, 0xaaaab96da300, 0xffffd2ad0aa0 } +0xaaaab96da2e0->Object::~Object { 0xaaaab96da2e0, 0xffffd2ad0aa0 } +0xffffd2ad0aa0->Object::~Object { 0xffffd2ad0aa0 } +exception caught: printer +end { } +./c++.at:1362: grep '^exception caught: printer$' stderr +stdout: +exception caught: printer + +./c++.at:1362: $PREPARSER ./input aaaae +stderr: +exception caught: syntax error +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1362: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - -./c++.at:1363: $PREPARSER ./input aaaaT +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +714. glr-regression.at:205: testing Badly Collapsed GLR States: glr.c ... +./glr-regression.at:205: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o glr-regr1.c glr-regr1.y stderr: -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1363: $PREPARSER ./input aaaaR +stdout: +./c++.at:1065: $PREPARSER ./input < in +./c++.at:1362: $PREPARSER ./input aaaaT stderr: -716. glr-regression.at:207: testing Badly Collapsed GLR States: glr2.cc ... -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:207: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o glr-regr1.cc glr-regr1.y +./glr-regression.at:205: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr1 glr-regr1.c $LIBS +stderr: +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +error: invalid expression +caught error +error: invalid character +caught error +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1362: $PREPARSER ./input aaaaR +./c++.at:1065: $PREPARSER ./input < in +stderr: +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +error: invalid expression +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./glr-regression.at:207: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr1 glr-regr1.cc $LIBS +./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1065: $PREPARSER ./input < in +stderr: +error: invalid character +./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +683. c++.at:1065: ok + stderr: stdout: ./cxx-type.at:452: $PREPARSER ./types test-input stderr: 17.5: syntax error ./cxx-type.at:452: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stdout: +./c++.at:857: $PREPARSER ./input +stderr: +./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +715. glr-regression.at:206: testing Badly Collapsed GLR States: glr.cc ... +./glr-regression.at:206: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o glr-regr1.cc glr-regr1.y +======== Testing with C++ standard flags: '' +./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./cxx-type.at:452: $PREPARSER ./types -p test-input stderr: Starting parse @@ -267216,6 +266679,7 @@ Reducing stack 0 by rule 6 (line 87): $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) +./glr-regression.at:206: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr1 glr-regr1.cc $LIBS ./cxx-type.at:452: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse @@ -267827,33 +267291,27 @@ $1 = token '@' (21.0: ) Cleanup: popping nterm prog (1.1-19.5: ) 712. cxx-type.at:449: ok - stderr: -stdout: -717. glr-regression.at:354: testing Improper handling of embedded actions and dollar(-N) in GLR parsers: glr.c ... -./cxx-type.at:458: $PREPARSER ./types test-input stderr: stdout: +./c++.at:851: $PREPARSER ./input +stdout: stderr: -./glr-regression.at:354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr2a.c glr-regr2a.y -./glr-regression.at:205: $PREPARSER ./glr-regr1 BPBPB +./c++.at:1555: $PREPARSER ./test +./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -syntax error, unexpected ID, expecting '=' or '+' or ')' -./cxx-type.at:458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:205: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:354: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr2a glr-regr2a.c $LIBS -714. glr-regression.at:205: ok stderr: stdout: -./c++.at:857: $PREPARSER ./input +./cxx-type.at:458: $PREPARSER ./types test-input stderr: -./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +syntax error, unexpected ID, expecting '=' or '+' or ')' -./c++.at:858: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy +======== Testing with C++ standard flags: '' +./cxx-type.at:458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1555: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./cxx-type.at:458: $PREPARSER ./types -p test-input stderr: -======== Testing with C++ standard flags: '' -./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): @@ -268464,8 +267922,7 @@ Cleanup: popping nterm prog () ./cxx-type.at:458: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -718. glr-regression.at:355: testing Improper handling of embedded actions and dollar(-N) in GLR parsers: glr.cc ... -./glr-regression.at:355: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr2a.cc glr-regr2a.y +716. glr-regression.at:207: testing Badly Collapsed GLR States: glr2.cc ... Starting parse Entering state 0 Reducing stack 0 by rule 1 (line 64): @@ -269074,996 +268531,1543 @@ Reducing stack 0 by rule 6 (line 77): $1 = token '@' () Cleanup: popping nterm prog () +./glr-regression.at:207: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o glr-regr1.cc glr-regr1.y +691. c++.at:1517: ok 713. cxx-type.at:455: ok + +./glr-regression.at:207: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr1 glr-regr1.cc $LIBS +717. glr-regression.at:354: testing Improper handling of embedded actions and dollar(-N) in GLR parsers: glr.c ... +./glr-regression.at:354: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr2a.c glr-regr2a.y +stderr: +stdout: +./glr-regression.at:205: $PREPARSER ./glr-regr1 BPBPB +stderr: +718. glr-regression.at:355: testing Improper handling of embedded actions and dollar(-N) in GLR parsers: glr.cc ... +./glr-regression.at:355: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr2a.cc glr-regr2a.y +./glr-regression.at:205: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./glr-regression.at:354: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr2a glr-regr2a.c $LIBS +stderr: +stdout: +./c++.at:1363: $PREPARSER ./input aaaas +714. glr-regression.at:205: ok +stderr: +exception caught: reduction +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:355: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr2a glr-regr2a.cc $LIBS +./c++.at:1363: $PREPARSER ./input aaaal +stderr: + +exception caught: yylex +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1363: $PREPARSER ./input i +stderr: +exception caught: initial-action +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 719. glr-regression.at:356: testing Improper handling of embedded actions and dollar(-N) in GLR parsers: glr2.cc ... ./glr-regression.at:356: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr2a.cc glr-regr2a.y +./c++.at:1363: $PREPARSER ./input aaaap +stderr: +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1363: $PREPARSER ./input --debug aaaap +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +0xfffffb324020->Object::Object { } +0xfffffb324120->Object::Object { 0xfffffb324020 } +0xfffffb324020->Object::~Object { 0xfffffb324020, 0xfffffb324120 } +Next token is token 'a' (0xfffffb324120 'a') +0xfffffb324060->Object::Object { 0xfffffb324120 } +0xfffffb324120->Object::~Object { 0xfffffb324060, 0xfffffb324120 } +Shifting token 'a' (0xfffffb324060 'a') +0xaaaacc9902e0->Object::Object { 0xfffffb324060 } +0xfffffb324060->Object::~Object { 0xaaaacc9902e0, 0xfffffb324060 } +Entering state 1 +Stack now 0 1 +0xfffffb324140->Object::Object { 0xaaaacc9902e0 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaacc9902e0 'a') +-> $$ = nterm item (0xfffffb324140 'a') +0xaaaacc9902e0->Object::~Object { 0xaaaacc9902e0, 0xfffffb324140 } +0xaaaacc9902e0->Object::Object { 0xfffffb324140 } +0xfffffb324140->Object::~Object { 0xaaaacc9902e0, 0xfffffb324140 } +Entering state 10 +Stack now 0 10 +Reading a token +0xfffffb324020->Object::Object { 0xaaaacc9902e0 } +0xfffffb324120->Object::Object { 0xaaaacc9902e0, 0xfffffb324020 } +0xfffffb324020->Object::~Object { 0xaaaacc9902e0, 0xfffffb324020, 0xfffffb324120 } +Next token is token 'a' (0xfffffb324120 'a') +0xfffffb324060->Object::Object { 0xaaaacc9902e0, 0xfffffb324120 } +0xfffffb324120->Object::~Object { 0xaaaacc9902e0, 0xfffffb324060, 0xfffffb324120 } +Shifting token 'a' (0xfffffb324060 'a') +0xaaaacc990300->Object::Object { 0xaaaacc9902e0, 0xfffffb324060 } +0xfffffb324060->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324060 } +Entering state 1 +Stack now 0 10 1 +0xfffffb324140->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaacc990300 'a') +-> $$ = nterm item (0xfffffb324140 'a') +0xaaaacc990300->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324140 } +0xaaaacc990300->Object::Object { 0xaaaacc9902e0, 0xfffffb324140 } +0xfffffb324140->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324140 } +Entering state 10 +Stack now 0 10 10 +Reading a token +0xfffffb324020->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300 } +0xfffffb324120->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324020 } +0xfffffb324020->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324020, 0xfffffb324120 } +Next token is token 'a' (0xfffffb324120 'a') +0xfffffb324060->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324120 } +0xfffffb324120->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324060, 0xfffffb324120 } +Shifting token 'a' (0xfffffb324060 'a') +0xaaaacc990320->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324060 } +0xfffffb324060->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324060 } +Entering state 1 +Stack now 0 10 10 1 +0xfffffb324140->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaacc990320 'a') +-> $$ = nterm item (0xfffffb324140 'a') +0xaaaacc990320->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324140 } +0xaaaacc990320->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324140 } +0xfffffb324140->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324140 } +Entering state 10 +Stack now 0 10 10 10 +Reading a token +0xfffffb324020->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320 } +0xfffffb324120->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324020 } +0xfffffb324020->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324020, 0xfffffb324120 } +Next token is token 'a' (0xfffffb324120 'a') +0xfffffb324060->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324120 } +0xfffffb324120->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324060, 0xfffffb324120 } +Shifting token 'a' (0xfffffb324060 'a') +0xaaaacc990340->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324060 } +0xfffffb324060->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324060 } +Entering state 1 +Stack now 0 10 10 10 1 +0xfffffb324140->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaacc990340 'a') +-> $$ = nterm item (0xfffffb324140 'a') +0xaaaacc990340->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324140 } +0xaaaacc990340->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324140 } +0xfffffb324140->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324140 } +Entering state 10 +Stack now 0 10 10 10 10 +Reading a token +0xfffffb324020->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340 } +0xfffffb324120->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324020 } +0xfffffb324020->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324020, 0xfffffb324120 } +Next token is token 'p' (0xfffffb324120 'p'Exception caught: cleaning lookahead and stack +0xaaaacc990340->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324120 } +0xaaaacc990320->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324120 } +0xaaaacc990300->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324120 } +0xaaaacc9902e0->Object::~Object { 0xaaaacc9902e0, 0xfffffb324120 } +0xfffffb324120->Object::~Object { 0xfffffb324120 } +exception caught: printer +end { } +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:356: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr2a glr-regr2a.cc $LIBS stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +0xfffffb324020->Object::Object { } +0xfffffb324120->Object::Object { 0xfffffb324020 } +0xfffffb324020->Object::~Object { 0xfffffb324020, 0xfffffb324120 } +Next token is token 'a' (0xfffffb324120 'a') +0xfffffb324060->Object::Object { 0xfffffb324120 } +0xfffffb324120->Object::~Object { 0xfffffb324060, 0xfffffb324120 } +Shifting token 'a' (0xfffffb324060 'a') +0xaaaacc9902e0->Object::Object { 0xfffffb324060 } +0xfffffb324060->Object::~Object { 0xaaaacc9902e0, 0xfffffb324060 } +Entering state 1 +Stack now 0 1 +0xfffffb324140->Object::Object { 0xaaaacc9902e0 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaacc9902e0 'a') +-> $$ = nterm item (0xfffffb324140 'a') +0xaaaacc9902e0->Object::~Object { 0xaaaacc9902e0, 0xfffffb324140 } +0xaaaacc9902e0->Object::Object { 0xfffffb324140 } +0xfffffb324140->Object::~Object { 0xaaaacc9902e0, 0xfffffb324140 } +Entering state 10 +Stack now 0 10 +Reading a token +0xfffffb324020->Object::Object { 0xaaaacc9902e0 } +0xfffffb324120->Object::Object { 0xaaaacc9902e0, 0xfffffb324020 } +0xfffffb324020->Object::~Object { 0xaaaacc9902e0, 0xfffffb324020, 0xfffffb324120 } +Next token is token 'a' (0xfffffb324120 'a') +0xfffffb324060->Object::Object { 0xaaaacc9902e0, 0xfffffb324120 } +0xfffffb324120->Object::~Object { 0xaaaacc9902e0, 0xfffffb324060, 0xfffffb324120 } +Shifting token 'a' (0xfffffb324060 'a') +0xaaaacc990300->Object::Object { 0xaaaacc9902e0, 0xfffffb324060 } +0xfffffb324060->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324060 } +Entering state 1 +Stack now 0 10 1 +0xfffffb324140->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaacc990300 'a') +-> $$ = nterm item (0xfffffb324140 'a') +0xaaaacc990300->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324140 } +0xaaaacc990300->Object::Object { 0xaaaacc9902e0, 0xfffffb324140 } +0xfffffb324140->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324140 } +Entering state 10 +Stack now 0 10 10 +Reading a token +0xfffffb324020->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300 } +0xfffffb324120->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324020 } +0xfffffb324020->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324020, 0xfffffb324120 } +Next token is token 'a' (0xfffffb324120 'a') +0xfffffb324060->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324120 } +0xfffffb324120->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324060, 0xfffffb324120 } +Shifting token 'a' (0xfffffb324060 'a') +0xaaaacc990320->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324060 } +0xfffffb324060->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324060 } +Entering state 1 +Stack now 0 10 10 1 +0xfffffb324140->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaacc990320 'a') +-> $$ = nterm item (0xfffffb324140 'a') +0xaaaacc990320->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324140 } +0xaaaacc990320->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324140 } +0xfffffb324140->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324140 } +Entering state 10 +Stack now 0 10 10 10 +Reading a token +0xfffffb324020->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320 } +0xfffffb324120->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324020 } +0xfffffb324020->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324020, 0xfffffb324120 } +Next token is token 'a' (0xfffffb324120 'a') +0xfffffb324060->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324120 } +0xfffffb324120->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324060, 0xfffffb324120 } +Shifting token 'a' (0xfffffb324060 'a') +0xaaaacc990340->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324060 } +0xfffffb324060->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324060 } +Entering state 1 +Stack now 0 10 10 10 1 +0xfffffb324140->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340 } +Reducing stack by rule 4 (line 142): + $1 = token 'a' (0xaaaacc990340 'a') +-> $$ = nterm item (0xfffffb324140 'a') +0xaaaacc990340->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324140 } +0xaaaacc990340->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324140 } +0xfffffb324140->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324140 } +Entering state 10 +Stack now 0 10 10 10 10 +Reading a token +0xfffffb324020->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340 } +0xfffffb324120->Object::Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324020 } +0xfffffb324020->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324020, 0xfffffb324120 } +Next token is token 'p' (0xfffffb324120 'p'Exception caught: cleaning lookahead and stack +0xaaaacc990340->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xaaaacc990340, 0xfffffb324120 } +0xaaaacc990320->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xaaaacc990320, 0xfffffb324120 } +0xaaaacc990300->Object::~Object { 0xaaaacc9902e0, 0xaaaacc990300, 0xfffffb324120 } +0xaaaacc9902e0->Object::~Object { 0xaaaacc9902e0, 0xfffffb324120 } +0xfffffb324120->Object::~Object { 0xfffffb324120 } +exception caught: printer +end { } +./c++.at:1363: grep '^exception caught: printer$' stderr +stdout: +exception caught: printer +./c++.at:1363: $PREPARSER ./input aaaae +stderr: +exception caught: syntax error +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1363: $PREPARSER ./input aaaaE +stderr: +stderr: +exception caught: syntax error, unexpected end of file, expecting 'a' +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stdout: +./c++.at:1361: $PREPARSER ./input aaaas +stderr: +./c++.at:1363: $PREPARSER ./input aaaaT +exception caught: reduction +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1363: $PREPARSER ./input aaaaR +./c++.at:1361: $PREPARSER ./input aaaal +stderr: +stderr: +exception caught: yylex +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:1361: $PREPARSER ./input i +./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stderr: +exception caught: initial-action +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input aaaap +stderr: +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input --debug aaaap +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +0xaaaae433cf40->Object::Object { } +Next token is token 'a' (0xaaaae433cf40 'a') +Shifting token 'a' (0xaaaae433cf40 'a') +Entering state 1 +Stack now 0 1 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaae433cf40 'a') +-> $$ = nterm item (0xaaaae433cf40 'a') +Entering state 10 +Stack now 0 10 +Reading a token +0xaaaae433cf90->Object::Object { 0xaaaae433cf40 } +Next token is token 'a' (0xaaaae433cf90 'a') +Shifting token 'a' (0xaaaae433cf90 'a') +Entering state 1 +Stack now 0 10 1 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaae433cf90 'a') +-> $$ = nterm item (0xaaaae433cf90 'a') +Entering state 10 +Stack now 0 10 10 +Reading a token +0xaaaae433cfe0->Object::Object { 0xaaaae433cf40, 0xaaaae433cf90 } +Next token is token 'a' (0xaaaae433cfe0 'a') +Shifting token 'a' (0xaaaae433cfe0 'a') +Entering state 1 +Stack now 0 10 10 1 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaae433cfe0 'a') +-> $$ = nterm item (0xaaaae433cfe0 'a') +Entering state 10 +Stack now 0 10 10 10 +Reading a token +0xaaaae433d030->Object::Object { 0xaaaae433cf40, 0xaaaae433cf90, 0xaaaae433cfe0 } +Next token is token 'a' (0xaaaae433d030 'a') +Shifting token 'a' (0xaaaae433d030 'a') +Entering state 1 +Stack now 0 10 10 10 1 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaae433d030 'a') +-> $$ = nterm item (0xaaaae433d030 'a') +Entering state 10 +Stack now 0 10 10 10 10 +Reading a token +0xaaaae433d080->Object::Object { 0xaaaae433cf40, 0xaaaae433cf90, 0xaaaae433cfe0, 0xaaaae433d030 } +Next token is token 'p' (0xaaaae433d080 'p'Exception caught: cleaning lookahead and stack +0xaaaae433d080->Object::~Object { 0xaaaae433cf40, 0xaaaae433cf90, 0xaaaae433cfe0, 0xaaaae433d030, 0xaaaae433d080 } +0xaaaae433d030->Object::~Object { 0xaaaae433cf40, 0xaaaae433cf90, 0xaaaae433cfe0, 0xaaaae433d030 } +0xaaaae433cfe0->Object::~Object { 0xaaaae433cf40, 0xaaaae433cf90, 0xaaaae433cfe0 } +0xaaaae433cf90->Object::~Object { 0xaaaae433cf40, 0xaaaae433cf90 } +0xaaaae433cf40->Object::~Object { 0xaaaae433cf40 } +exception caught: printer +end { } +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +0xaaaae433cf40->Object::Object { } +Next token is token 'a' (0xaaaae433cf40 'a') +Shifting token 'a' (0xaaaae433cf40 'a') +Entering state 1 +Stack now 0 1 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaae433cf40 'a') +-> $$ = nterm item (0xaaaae433cf40 'a') +Entering state 10 +Stack now 0 10 +Reading a token +0xaaaae433cf90->Object::Object { 0xaaaae433cf40 } +Next token is token 'a' (0xaaaae433cf90 'a') +Shifting token 'a' (0xaaaae433cf90 'a') +Entering state 1 +Stack now 0 10 1 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaae433cf90 'a') +-> $$ = nterm item (0xaaaae433cf90 'a') +Entering state 10 +Stack now 0 10 10 +Reading a token +0xaaaae433cfe0->Object::Object { 0xaaaae433cf40, 0xaaaae433cf90 } +Next token is token 'a' (0xaaaae433cfe0 'a') +Shifting token 'a' (0xaaaae433cfe0 'a') +Entering state 1 +Stack now 0 10 10 1 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaae433cfe0 'a') +-> $$ = nterm item (0xaaaae433cfe0 'a') +Entering state 10 +Stack now 0 10 10 10 +Reading a token +0xaaaae433d030->Object::Object { 0xaaaae433cf40, 0xaaaae433cf90, 0xaaaae433cfe0 } +Next token is token 'a' (0xaaaae433d030 'a') +Shifting token 'a' (0xaaaae433d030 'a') +Entering state 1 +Stack now 0 10 10 10 1 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaae433d030 'a') +-> $$ = nterm item (0xaaaae433d030 'a') +Entering state 10 +Stack now 0 10 10 10 10 +Reading a token +0xaaaae433d080->Object::Object { 0xaaaae433cf40, 0xaaaae433cf90, 0xaaaae433cfe0, 0xaaaae433d030 } +Next token is token 'p' (0xaaaae433d080 'p'Exception caught: cleaning lookahead and stack +0xaaaae433d080->Object::~Object { 0xaaaae433cf40, 0xaaaae433cf90, 0xaaaae433cfe0, 0xaaaae433d030, 0xaaaae433d080 } +0xaaaae433d030->Object::~Object { 0xaaaae433cf40, 0xaaaae433cf90, 0xaaaae433cfe0, 0xaaaae433d030 } +0xaaaae433cfe0->Object::~Object { 0xaaaae433cf40, 0xaaaae433cf90, 0xaaaae433cfe0 } +0xaaaae433cf90->Object::~Object { 0xaaaae433cf40, 0xaaaae433cf90 } +0xaaaae433cf40->Object::~Object { 0xaaaae433cf40 } +exception caught: printer +end { } +./c++.at:1361: grep '^exception caught: printer$' stderr +stdout: +stdout: +exception caught: printer +./c++.at:1361: $PREPARSER ./input aaaae +./c++.at:857: $PREPARSER ./input +stderr: +./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stderr: +exception caught: syntax error +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input aaaaE +stderr: +exception caught: syntax error, unexpected end of file, expecting 'a' +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input aaaaT +stderr: stdout: ./glr-regression.at:206: $PREPARSER ./glr-regr1 BPBPB stderr: +stderr: ./glr-regression.at:206: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 715. glr-regression.at:206: ok +./c++.at:1361: $PREPARSER ./input aaaaR +stderr: +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +======== Testing with C++ standard flags: '' +stdout: +./c++.at:1361: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./glr-regression.at:354: $PREPARSER ./glr-regr2a input1.txt +stderr: +./glr-regression.at:354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./glr-regression.at:354: $PREPARSER ./glr-regr2a input2.txt stdout: -./c++.at:858: $PREPARSER ./input stderr: -./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:851: $PREPARSER ./input +stderr: 720. glr-regression.at:488: testing Improper merging of GLR delayed action sets: glr.c ... ./glr-regression.at:488: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr3.c glr-regr3.y +./glr-regression.at:354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ======== Testing with C++ standard flags: '' -./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:851: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./glr-regression.at:354: $PREPARSER ./glr-regr2a input3.txt stderr: -stdout: +./glr-regression.at:354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +717. glr-regression.at:354: ok +./glr-regression.at:488: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr3 glr-regr3.c $LIBS + +721. glr-regression.at:489: testing Improper merging of GLR delayed action sets: glr.cc ... +./glr-regression.at:489: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr3.cc glr-regr3.y +./glr-regression.at:489: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr3 glr-regr3.cc $LIBS stderr: stdout: -./glr-regression.at:354: $PREPARSER ./glr-regr2a input1.txt +./c++.at:1360: $PREPARSER ./input aaaas stderr: -./c++.at:1066: $PREPARSER ./input < in +exception caught: reduction +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: $PREPARSER ./input aaaal stderr: -./glr-regression.at:354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:488: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr3 glr-regr3.c $LIBS -error: invalid expression -caught error -error: invalid character -caught error -./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:354: $PREPARSER ./glr-regr2a input2.txt +exception caught: yylex +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: $PREPARSER ./input i stderr: -./c++.at:1066: $PREPARSER ./input < in -./glr-regression.at:354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +exception caught: initial-action +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: $PREPARSER ./input aaaap stderr: -error: invalid expression -./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:354: $PREPARSER ./glr-regr2a input3.txt +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: $PREPARSER ./input --debug aaaap stderr: -./c++.at:1066: $PREPARSER ./input < in +Starting parse +Entering state 0 +Stack now 0 +Reading a token +0xaaaadcedef40->Object::Object { } +Next token is token 'a' (0xaaaadcedef40 'a') +Shifting token 'a' (0xaaaadcedef40 'a') +Entering state 2 +Stack now 0 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaadcedef40 'a') +-> $$ = nterm item (0xaaaadcedef40 'a') +Entering state 11 +Stack now 0 11 +Reading a token +0xaaaadcedef90->Object::Object { 0xaaaadcedef40 } +Next token is token 'a' (0xaaaadcedef90 'a') +Shifting token 'a' (0xaaaadcedef90 'a') +Entering state 2 +Stack now 0 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaadcedef90 'a') +-> $$ = nterm item (0xaaaadcedef90 'a') +Entering state 11 +Stack now 0 11 11 +Reading a token +0xaaaadcedefe0->Object::Object { 0xaaaadcedef40, 0xaaaadcedef90 } +Next token is token 'a' (0xaaaadcedefe0 'a') +Shifting token 'a' (0xaaaadcedefe0 'a') +Entering state 2 +Stack now 0 11 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaadcedefe0 'a') +-> $$ = nterm item (0xaaaadcedefe0 'a') +Entering state 11 +Stack now 0 11 11 11 +Reading a token +0xaaaadcedf030->Object::Object { 0xaaaadcedef40, 0xaaaadcedef90, 0xaaaadcedefe0 } +Next token is token 'a' (0xaaaadcedf030 'a') +Shifting token 'a' (0xaaaadcedf030 'a') +Entering state 2 +Stack now 0 11 11 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaadcedf030 'a') +-> $$ = nterm item (0xaaaadcedf030 'a') +Entering state 11 +Stack now 0 11 11 11 11 +Reading a token +0xaaaadcedf080->Object::Object { 0xaaaadcedef40, 0xaaaadcedef90, 0xaaaadcedefe0, 0xaaaadcedf030 } +Next token is token 'p' (0xaaaadcedf080 'p'Exception caught: cleaning lookahead and stack +0xaaaadcedf080->Object::~Object { 0xaaaadcedef40, 0xaaaadcedef90, 0xaaaadcedefe0, 0xaaaadcedf030, 0xaaaadcedf080 } +0xaaaadcedf030->Object::~Object { 0xaaaadcedef40, 0xaaaadcedef90, 0xaaaadcedefe0, 0xaaaadcedf030 } +0xaaaadcedefe0->Object::~Object { 0xaaaadcedef40, 0xaaaadcedef90, 0xaaaadcedefe0 } +0xaaaadcedef90->Object::~Object { 0xaaaadcedef40, 0xaaaadcedef90 } +0xaaaadcedef40->Object::~Object { 0xaaaadcedef40 } +exception caught: printer +end { } +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -error: invalid character -./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:354: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS -717. glr-regression.at:354: ok +Starting parse +Entering state 0 +Stack now 0 +Reading a token +0xaaaadcedef40->Object::Object { } +Next token is token 'a' (0xaaaadcedef40 'a') +Shifting token 'a' (0xaaaadcedef40 'a') +Entering state 2 +Stack now 0 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaadcedef40 'a') +-> $$ = nterm item (0xaaaadcedef40 'a') +Entering state 11 +Stack now 0 11 +Reading a token +0xaaaadcedef90->Object::Object { 0xaaaadcedef40 } +Next token is token 'a' (0xaaaadcedef90 'a') +Shifting token 'a' (0xaaaadcedef90 'a') +Entering state 2 +Stack now 0 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaadcedef90 'a') +-> $$ = nterm item (0xaaaadcedef90 'a') +Entering state 11 +Stack now 0 11 11 +Reading a token +0xaaaadcedefe0->Object::Object { 0xaaaadcedef40, 0xaaaadcedef90 } +Next token is token 'a' (0xaaaadcedefe0 'a') +Shifting token 'a' (0xaaaadcedefe0 'a') +Entering state 2 +Stack now 0 11 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaadcedefe0 'a') +-> $$ = nterm item (0xaaaadcedefe0 'a') +Entering state 11 +Stack now 0 11 11 11 +Reading a token +0xaaaadcedf030->Object::Object { 0xaaaadcedef40, 0xaaaadcedef90, 0xaaaadcedefe0 } +Next token is token 'a' (0xaaaadcedf030 'a') +Shifting token 'a' (0xaaaadcedf030 'a') +Entering state 2 +Stack now 0 11 11 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaadcedf030 'a') +-> $$ = nterm item (0xaaaadcedf030 'a') +Entering state 11 +Stack now 0 11 11 11 11 +Reading a token +0xaaaadcedf080->Object::Object { 0xaaaadcedef40, 0xaaaadcedef90, 0xaaaadcedefe0, 0xaaaadcedf030 } +Next token is token 'p' (0xaaaadcedf080 'p'Exception caught: cleaning lookahead and stack +0xaaaadcedf080->Object::~Object { 0xaaaadcedef40, 0xaaaadcedef90, 0xaaaadcedefe0, 0xaaaadcedf030, 0xaaaadcedf080 } +0xaaaadcedf030->Object::~Object { 0xaaaadcedef40, 0xaaaadcedef90, 0xaaaadcedefe0, 0xaaaadcedf030 } +0xaaaadcedefe0->Object::~Object { 0xaaaadcedef40, 0xaaaadcedef90, 0xaaaadcedefe0 } +0xaaaadcedef90->Object::~Object { 0xaaaadcedef40, 0xaaaadcedef90 } +0xaaaadcedef40->Object::~Object { 0xaaaadcedef40 } +exception caught: printer +end { } +./c++.at:1360: grep '^exception caught: printer$' stderr +stdout: +exception caught: printer +./c++.at:1360: $PREPARSER ./input aaaae +stderr: +exception caught: syntax error +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: $PREPARSER ./input aaaaE +stderr: +exception caught: syntax error, unexpected end of file, expecting 'a' +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./c++.at:1362: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: $PREPARSER ./input aaaaT +stderr: ./c++.at:1362: $PREPARSER ./input aaaal +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: yylex ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - ./c++.at:1362: $PREPARSER ./input i +./c++.at:1360: $PREPARSER ./input aaaaR stderr: exception caught: initial-action ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -721. glr-regression.at:489: testing Improper merging of GLR delayed action sets: glr.cc ... -./glr-regression.at:489: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr3.cc glr-regr3.y stderr: +stderr: +stdout: stdout: ./c++.at:1362: $PREPARSER ./input aaaap stderr: -./c++.at:1066: ./check +./c++.at:857: $PREPARSER ./input +./glr-regression.at:355: $PREPARSER ./glr-regr2a input1.txt +stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./glr-regression.at:355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +======== Testing with C++ standard flags: '' +./c++.at:857: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:1360: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1362: $PREPARSER ./input --debug aaaap +./glr-regression.at:355: $PREPARSER ./glr-regr2a input2.txt +stderr: stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xffffd43f7710->Object::Object { } -0xffffd43f7810->Object::Object { 0xffffd43f7710 } -0xffffd43f7710->Object::~Object { 0xffffd43f7710, 0xffffd43f7810 } -Next token is token 'a' (0xffffd43f7810 'a') -0xffffd43f7750->Object::Object { 0xffffd43f7810 } -0xffffd43f7810->Object::~Object { 0xffffd43f7750, 0xffffd43f7810 } -Shifting token 'a' (0xffffd43f7750 'a') -0xaaaaba1992e0->Object::Object { 0xffffd43f7750 } -0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7750 } +0xffffce89cd90->Object::Object { } +0xffffce89ce90->Object::Object { 0xffffce89cd90 } +0xffffce89cd90->Object::~Object { 0xffffce89cd90, 0xffffce89ce90 } +Next token is token 'a' (0xffffce89ce90 'a') +0xffffce89cdd0->Object::Object { 0xffffce89ce90 } +0xffffce89ce90->Object::~Object { 0xffffce89cdd0, 0xffffce89ce90 } +Shifting token 'a' (0xffffce89cdd0 'a') +0xaaaac93772e0->Object::Object { 0xffffce89cdd0 } +0xffffce89cdd0->Object::~Object { 0xaaaac93772e0, 0xffffce89cdd0 } Entering state 2 Stack now 0 2 -0xffffd43f7830->Object::Object { 0xaaaaba1992e0 } +0xffffce89ceb0->Object::Object { 0xaaaac93772e0 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaba1992e0 'a') --> $$ = nterm item (0xffffd43f7830 'a') -0xaaaaba1992e0->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7830 } -0xaaaaba1992e0->Object::Object { 0xffffd43f7830 } -0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7830 } + $1 = token 'a' (0xaaaac93772e0 'a') +-> $$ = nterm item (0xffffce89ceb0 'a') +0xaaaac93772e0->Object::~Object { 0xaaaac93772e0, 0xffffce89ceb0 } +0xaaaac93772e0->Object::Object { 0xffffce89ceb0 } +0xffffce89ceb0->Object::~Object { 0xaaaac93772e0, 0xffffce89ceb0 } Entering state 11 Stack now 0 11 Reading a token -0xffffd43f7710->Object::Object { 0xaaaaba1992e0 } -0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xffffd43f7710 } -0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7710, 0xffffd43f7810 } -Next token is token 'a' (0xffffd43f7810 'a') -0xffffd43f7750->Object::Object { 0xaaaaba1992e0, 0xffffd43f7810 } -0xffffd43f7810->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7750, 0xffffd43f7810 } -Shifting token 'a' (0xffffd43f7750 'a') -0xaaaaba199300->Object::Object { 0xaaaaba1992e0, 0xffffd43f7750 } -0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7750 } +0xffffce89cd90->Object::Object { 0xaaaac93772e0 } +0xffffce89ce90->Object::Object { 0xaaaac93772e0, 0xffffce89cd90 } +0xffffce89cd90->Object::~Object { 0xaaaac93772e0, 0xffffce89cd90, 0xffffce89ce90 } +Next token is token 'a' (0xffffce89ce90 'a') +0xffffce89cdd0->Object::Object { 0xaaaac93772e0, 0xffffce89ce90 } +0xffffce89ce90->Object::~Object { 0xaaaac93772e0, 0xffffce89cdd0, 0xffffce89ce90 } +Shifting token 'a' (0xffffce89cdd0 'a') +0xaaaac9377300->Object::Object { 0xaaaac93772e0, 0xffffce89cdd0 } +0xffffce89cdd0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89cdd0 } Entering state 2 Stack now 0 11 2 -0xffffd43f7830->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300 } +0xffffce89ceb0->Object::Object { 0xaaaac93772e0, 0xaaaac9377300 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaba199300 'a') --> $$ = nterm item (0xffffd43f7830 'a') -0xaaaaba199300->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7830 } -0xaaaaba199300->Object::Object { 0xaaaaba1992e0, 0xffffd43f7830 } -0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7830 } + $1 = token 'a' (0xaaaac9377300 'a') +-> $$ = nterm item (0xffffce89ceb0 'a') +0xaaaac9377300->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89ceb0 } +0xaaaac9377300->Object::Object { 0xaaaac93772e0, 0xffffce89ceb0 } +0xffffce89ceb0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89ceb0 } Entering state 11 Stack now 0 11 11 Reading a token -0xffffd43f7710->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300 } -0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7710 } -0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7710, 0xffffd43f7810 } -Next token is token 'a' (0xffffd43f7810 'a') -0xffffd43f7750->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7810 } -0xffffd43f7810->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7750, 0xffffd43f7810 } -Shifting token 'a' (0xffffd43f7750 'a') -0xaaaaba199320->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7750 } -0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7750 } +0xffffce89cd90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300 } +0xffffce89ce90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89cd90 } +0xffffce89cd90->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89cd90, 0xffffce89ce90 } +Next token is token 'a' (0xffffce89ce90 'a') +0xffffce89cdd0->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89ce90 } +0xffffce89ce90->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89cdd0, 0xffffce89ce90 } +Shifting token 'a' (0xffffce89cdd0 'a') +0xaaaac9377320->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89cdd0 } +0xffffce89cdd0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89cdd0 } Entering state 2 Stack now 0 11 11 2 -0xffffd43f7830->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320 } +0xffffce89ceb0->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaba199320 'a') --> $$ = nterm item (0xffffd43f7830 'a') -0xaaaaba199320->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7830 } -0xaaaaba199320->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7830 } -0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7830 } + $1 = token 'a' (0xaaaac9377320 'a') +-> $$ = nterm item (0xffffce89ceb0 'a') +0xaaaac9377320->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89ceb0 } +0xaaaac9377320->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89ceb0 } +0xffffce89ceb0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89ceb0 } Entering state 11 Stack now 0 11 11 11 Reading a token -0xffffd43f7710->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320 } -0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7710 } -0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7710, 0xffffd43f7810 } -Next token is token 'a' (0xffffd43f7810 'a') -0xffffd43f7750->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7810 } -0xffffd43f7810->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7750, 0xffffd43f7810 } -Shifting token 'a' (0xffffd43f7750 'a') -0xaaaaba199340->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7750 } -0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7750 } +0xffffce89cd90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320 } +0xffffce89ce90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89cd90 } +0xffffce89cd90->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89cd90, 0xffffce89ce90 } +Next token is token 'a' (0xffffce89ce90 'a') +0xffffce89cdd0->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89ce90 } +0xffffce89ce90->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89cdd0, 0xffffce89ce90 } +Shifting token 'a' (0xffffce89cdd0 'a') +0xaaaac9377340->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89cdd0 } +0xffffce89cdd0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89cdd0 } Entering state 2 Stack now 0 11 11 11 2 -0xffffd43f7830->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340 } +0xffffce89ceb0->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaba199340 'a') --> $$ = nterm item (0xffffd43f7830 'a') -0xaaaaba199340->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7830 } -0xaaaaba199340->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7830 } -0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7830 } + $1 = token 'a' (0xaaaac9377340 'a') +-> $$ = nterm item (0xffffce89ceb0 'a') +0xaaaac9377340->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89ceb0 } +0xaaaac9377340->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89ceb0 } +0xffffce89ceb0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89ceb0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token -0xffffd43f7710->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340 } -0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7710 } -0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7710, 0xffffd43f7810 } -Next token is token 'p' (0xffffd43f7810 'p'Exception caught: cleaning lookahead and stack -0xaaaaba199340->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7810 } -0xaaaaba199320->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7810 } -0xaaaaba199300->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7810 } -0xaaaaba1992e0->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7810 } -0xffffd43f7810->Object::~Object { 0xffffd43f7810 } +0xffffce89cd90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340 } +0xffffce89ce90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89cd90 } +0xffffce89cd90->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89cd90, 0xffffce89ce90 } +Next token is token 'p' (0xffffce89ce90 'p'Exception caught: cleaning lookahead and stack +0xaaaac9377340->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89ce90 } +0xaaaac9377320->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89ce90 } +0xaaaac9377300->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89ce90 } +0xaaaac93772e0->Object::~Object { 0xaaaac93772e0, 0xffffce89ce90 } +0xffffce89ce90->Object::~Object { 0xffffce89ce90 } exception caught: printer end { } ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS +./glr-regression.at:355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./glr-regression.at:489: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr3 glr-regr3.cc $LIBS Starting parse Entering state 0 Stack now 0 Reading a token -0xffffd43f7710->Object::Object { } -0xffffd43f7810->Object::Object { 0xffffd43f7710 } -0xffffd43f7710->Object::~Object { 0xffffd43f7710, 0xffffd43f7810 } -Next token is token 'a' (0xffffd43f7810 'a') -0xffffd43f7750->Object::Object { 0xffffd43f7810 } -0xffffd43f7810->Object::~Object { 0xffffd43f7750, 0xffffd43f7810 } -Shifting token 'a' (0xffffd43f7750 'a') -0xaaaaba1992e0->Object::Object { 0xffffd43f7750 } -0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7750 } +0xffffce89cd90->Object::Object { } +0xffffce89ce90->Object::Object { 0xffffce89cd90 } +0xffffce89cd90->Object::~Object { 0xffffce89cd90, 0xffffce89ce90 } +Next token is token 'a' (0xffffce89ce90 'a') +0xffffce89cdd0->Object::Object { 0xffffce89ce90 } +0xffffce89ce90->Object::~Object { 0xffffce89cdd0, 0xffffce89ce90 } +Shifting token 'a' (0xffffce89cdd0 'a') +0xaaaac93772e0->Object::Object { 0xffffce89cdd0 } +0xffffce89cdd0->Object::~Object { 0xaaaac93772e0, 0xffffce89cdd0 } Entering state 2 Stack now 0 2 -0xffffd43f7830->Object::Object { 0xaaaaba1992e0 } +0xffffce89ceb0->Object::Object { 0xaaaac93772e0 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaba1992e0 'a') --> $$ = nterm item (0xffffd43f7830 'a') -0xaaaaba1992e0->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7830 } -0xaaaaba1992e0->Object::Object { 0xffffd43f7830 } -0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7830 } + $1 = token 'a' (0xaaaac93772e0 'a') +-> $$ = nterm item (0xffffce89ceb0 'a') +0xaaaac93772e0->Object::~Object { 0xaaaac93772e0, 0xffffce89ceb0 } +0xaaaac93772e0->Object::Object { 0xffffce89ceb0 } +0xffffce89ceb0->Object::~Object { 0xaaaac93772e0, 0xffffce89ceb0 } Entering state 11 Stack now 0 11 Reading a token -0xffffd43f7710->Object::Object { 0xaaaaba1992e0 } -0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xffffd43f7710 } -0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7710, 0xffffd43f7810 } -Next token is token 'a' (0xffffd43f7810 'a') -0xffffd43f7750->Object::Object { 0xaaaaba1992e0, 0xffffd43f7810 } -0xffffd43f7810->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7750, 0xffffd43f7810 } -Shifting token 'a' (0xffffd43f7750 'a') -0xaaaaba199300->Object::Object { 0xaaaaba1992e0, 0xffffd43f7750 } -0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7750 } +0xffffce89cd90->Object::Object { 0xaaaac93772e0 } +0xffffce89ce90->Object::Object { 0xaaaac93772e0, 0xffffce89cd90 } +0xffffce89cd90->Object::~Object { 0xaaaac93772e0, 0xffffce89cd90, 0xffffce89ce90 } +Next token is token 'a' (0xffffce89ce90 'a') +0xffffce89cdd0->Object::Object { 0xaaaac93772e0, 0xffffce89ce90 } +0xffffce89ce90->Object::~Object { 0xaaaac93772e0, 0xffffce89cdd0, 0xffffce89ce90 } +Shifting token 'a' (0xffffce89cdd0 'a') +0xaaaac9377300->Object::Object { 0xaaaac93772e0, 0xffffce89cdd0 } +0xffffce89cdd0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89cdd0 } Entering state 2 Stack now 0 11 2 -0xffffd43f7830->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300 } +0xffffce89ceb0->Object::Object { 0xaaaac93772e0, 0xaaaac9377300 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaba199300 'a') --> $$ = nterm item (0xffffd43f7830 'a') -0xaaaaba199300->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7830 } -0xaaaaba199300->Object::Object { 0xaaaaba1992e0, 0xffffd43f7830 } -0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7830 } + $1 = token 'a' (0xaaaac9377300 'a') +-> $$ = nterm item (0xffffce89ceb0 'a') +0xaaaac9377300->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89ceb0 } +0xaaaac9377300->Object::Object { 0xaaaac93772e0, 0xffffce89ceb0 } +0xffffce89ceb0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89ceb0 } Entering state 11 Stack now 0 11 11 Reading a token -0xffffd43f7710->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300 } -0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7710 } -0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7710, 0xffffd43f7810 } -Next token is token 'a' (0xffffd43f7810 'a') -0xffffd43f7750->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7810 } -0xffffd43f7810->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7750, 0xffffd43f7810 } -Shifting token 'a' (0xffffd43f7750 'a') -0xaaaaba199320->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7750 } -0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7750 } +0xffffce89cd90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300 } +0xffffce89ce90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89cd90 } +0xffffce89cd90->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89cd90, 0xffffce89ce90 } +Next token is token 'a' (0xffffce89ce90 'a') +0xffffce89cdd0->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89ce90 } +0xffffce89ce90->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89cdd0, 0xffffce89ce90 } +Shifting token 'a' (0xffffce89cdd0 'a') +0xaaaac9377320->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89cdd0 } +0xffffce89cdd0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89cdd0 } Entering state 2 Stack now 0 11 11 2 -0xffffd43f7830->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320 } +0xffffce89ceb0->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaba199320 'a') --> $$ = nterm item (0xffffd43f7830 'a') -0xaaaaba199320->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7830 } -0xaaaaba199320->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7830 } -0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7830 } + $1 = token 'a' (0xaaaac9377320 'a') +-> $$ = nterm item (0xffffce89ceb0 'a') +0xaaaac9377320->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89ceb0 } +0xaaaac9377320->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89ceb0 } +0xffffce89ceb0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89ceb0 } Entering state 11 Stack now 0 11 11 11 Reading a token -0xffffd43f7710->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320 } -0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7710 } -0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7710, 0xffffd43f7810 } -Next token is token 'a' (0xffffd43f7810 'a') -0xffffd43f7750->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7810 } -0xffffd43f7810->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7750, 0xffffd43f7810 } -Shifting token 'a' (0xffffd43f7750 'a') -0xaaaaba199340->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7750 } -0xffffd43f7750->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7750 } +0xffffce89cd90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320 } +0xffffce89ce90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89cd90 } +0xffffce89cd90->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89cd90, 0xffffce89ce90 } +Next token is token 'a' (0xffffce89ce90 'a') +0xffffce89cdd0->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89ce90 } +0xffffce89ce90->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89cdd0, 0xffffce89ce90 } +Shifting token 'a' (0xffffce89cdd0 'a') +0xaaaac9377340->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89cdd0 } +0xffffce89cdd0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89cdd0 } Entering state 2 Stack now 0 11 11 11 2 -0xffffd43f7830->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340 } +0xffffce89ceb0->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaaba199340 'a') --> $$ = nterm item (0xffffd43f7830 'a') -0xaaaaba199340->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7830 } -0xaaaaba199340->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7830 } -0xffffd43f7830->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7830 } + $1 = token 'a' (0xaaaac9377340 'a') +-> $$ = nterm item (0xffffce89ceb0 'a') +0xaaaac9377340->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89ceb0 } +0xaaaac9377340->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89ceb0 } +0xffffce89ceb0->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89ceb0 } Entering state 11 Stack now 0 11 11 11 11 Reading a token -0xffffd43f7710->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340 } -0xffffd43f7810->Object::Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7710 } -0xffffd43f7710->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7710, 0xffffd43f7810 } -Next token is token 'p' (0xffffd43f7810 'p'Exception caught: cleaning lookahead and stack -0xaaaaba199340->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xaaaaba199340, 0xffffd43f7810 } -0xaaaaba199320->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xaaaaba199320, 0xffffd43f7810 } -0xaaaaba199300->Object::~Object { 0xaaaaba1992e0, 0xaaaaba199300, 0xffffd43f7810 } -0xaaaaba1992e0->Object::~Object { 0xaaaaba1992e0, 0xffffd43f7810 } -0xffffd43f7810->Object::~Object { 0xffffd43f7810 } +0xffffce89cd90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340 } +0xffffce89ce90->Object::Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89cd90 } +0xffffce89cd90->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89cd90, 0xffffce89ce90 } +Next token is token 'p' (0xffffce89ce90 'p'Exception caught: cleaning lookahead and stack +0xaaaac9377340->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xaaaac9377340, 0xffffce89ce90 } +0xaaaac9377320->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xaaaac9377320, 0xffffce89ce90 } +0xaaaac9377300->Object::~Object { 0xaaaac93772e0, 0xaaaac9377300, 0xffffce89ce90 } +0xaaaac93772e0->Object::~Object { 0xaaaac93772e0, 0xffffce89ce90 } +0xffffce89ce90->Object::~Object { 0xffffce89ce90 } exception caught: printer end { } ./c++.at:1362: grep '^exception caught: printer$' stderr stdout: exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae +./glr-regression.at:355: $PREPARSER ./glr-regr2a input3.txt +stderr: stderr: exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./glr-regression.at:355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +718. glr-regression.at:355: ok +./c++.at:1362: $PREPARSER ./input aaaaE +stderr: +exception caught: syntax error, unexpected end of file, expecting 'a' +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + stderr: stdout: -./glr-regression.at:355: $PREPARSER ./glr-regr2a input1.txt +./c++.at:1362: $PREPARSER ./input aaaaT stderr: -./glr-regression.at:355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:355: $PREPARSER ./glr-regr2a input2.txt +722. glr-regression.at:490: testing Improper merging of GLR delayed action sets: glr2.cc ... +./glr-regression.at:488: $PREPARSER ./glr-regr3 input.txt +./glr-regression.at:490: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr3.cc glr-regr3.y +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./glr-regression.at:355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./glr-regression.at:488: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1362: $PREPARSER ./input aaaaR stderr: -./glr-regression.at:355: $PREPARSER ./glr-regr2a input3.txt +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +720. glr-regression.at:488: ok +======== Testing with C++ standard flags: '' +./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./glr-regression.at:490: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr3 glr-regr3.cc $LIBS + +723. glr-regression.at:592: testing Duplicate representation of merged trees: %union { char *ptr; } glr.c ... +./glr-regression.at:592: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.c glr-regr4.y +./glr-regression.at:592: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr4 glr-regr4.c $LIBS stderr: -./c++.at:1362: $PREPARSER ./input aaaaE stdout: -./glr-regression.at:355: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./glr-regression.at:207: $PREPARSER ./glr-regr1 BPBPB stderr: -exception caught: syntax error, unexpected end of file, expecting 'a' -./c++.at:1065: $PREPARSER ./input < in -718. glr-regression.at:355: ok -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./glr-regression.at:207: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +716. glr-regression.at:207: ok + +724. glr-regression.at:593: testing Duplicate representation of merged trees: %union { char *ptr; } glr.cc ... +./glr-regression.at:593: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.cc glr-regr4.y +stderr: +stdout: +./glr-regression.at:489: $PREPARSER ./glr-regr3 input.txt +stderr: +./glr-regression.at:489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +721. glr-regression.at:489: ok +./glr-regression.at:593: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr4 glr-regr4.cc $LIBS + +725. glr-regression.at:594: testing Duplicate representation of merged trees: %union { char *ptr; } glr2.cc ... +./glr-regression.at:594: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.cc glr-regr4.y +./glr-regression.at:594: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr4 glr-regr4.cc $LIBS +stderr: +stdout: +./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid expression caught error error: invalid character caught error -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1065: $PREPARSER ./input < in +./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1066: $PREPARSER ./input < in stderr: error: invalid expression -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1065: $PREPARSER ./input < in -./c++.at:1362: $PREPARSER ./input aaaaT +./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./c++.at:1066: $PREPARSER ./input < in +stdout: stderr: -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr error: invalid character - -./c++.at:1065: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1362: $PREPARSER ./input aaaaR +./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:851: $PREPARSER ./input +======== Testing with C++ standard flags: '' +stderr: +./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o check check.cc $LIBS stderr: stdout: +./glr-regression.at:592: $PREPARSER ./glr-regr4 +stderr: +./c++.at:851: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./glr-regression.at:592: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +678. c++.at:848: ok +723. glr-regression.at:592: ok + + stderr: +stdout: ./c++.at:1363: $PREPARSER ./input aaaas stderr: +stderr: +stdout: exception caught: reduction +./c++.at:1066: ./check ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -683. c++.at:1065: ok -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +727. glr-regression.at:597: testing Duplicate representation of merged trees: api.value.type=union glr.cc ... +./glr-regression.at:597: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.cc glr-regr4.y +./c++.at:1066: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc scan.cc $LIBS +726. glr-regression.at:596: testing Duplicate representation of merged trees: api.value.type=union glr.c ... +./glr-regression.at:596: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.c glr-regr4.y ./c++.at:1363: $PREPARSER ./input aaaal stderr: exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -722. glr-regression.at:490: testing Improper merging of GLR delayed action sets: glr2.cc ... -======== Testing with C++ standard flags: '' -./glr-regression.at:490: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr3.cc glr-regr3.y -./c++.at:1362: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./c++.at:1363: $PREPARSER ./input i - stderr: +./glr-regression.at:596: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr4 glr-regr4.c $LIBS +./glr-regression.at:597: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr4 glr-regr4.cc $LIBS exception caught: initial-action ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaap stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:490: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr3 glr-regr3.cc $LIBS -723. glr-regression.at:592: testing Duplicate representation of merged trees: %union { char *ptr; } glr.c ... ./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: -./glr-regression.at:592: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.c glr-regr4.y -stdout: -stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xffffe877f390->Object::Object { } -0xffffe877f490->Object::Object { 0xffffe877f390 } -0xffffe877f390->Object::~Object { 0xffffe877f390, 0xffffe877f490 } -Next token is token 'a' (0xffffe877f490 'a') -0xffffe877f3d0->Object::Object { 0xffffe877f490 } -0xffffe877f490->Object::~Object { 0xffffe877f3d0, 0xffffe877f490 } -Shifting token 'a' (0xffffe877f3d0 'a') -0xaaaae3a232e0->Object::Object { 0xffffe877f3d0 } -0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f3d0 } +0xfffffd95e500->Object::Object { } +0xfffffd95e600->Object::Object { 0xfffffd95e500 } +0xfffffd95e500->Object::~Object { 0xfffffd95e500, 0xfffffd95e600 } +Next token is token 'a' (0xfffffd95e600 'a') +0xfffffd95e540->Object::Object { 0xfffffd95e600 } +0xfffffd95e600->Object::~Object { 0xfffffd95e540, 0xfffffd95e600 } +Shifting token 'a' (0xfffffd95e540 'a') +0xaaab1306e2e0->Object::Object { 0xfffffd95e540 } +0xfffffd95e540->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e540 } Entering state 1 Stack now 0 1 -0xffffe877f4b0->Object::Object { 0xaaaae3a232e0 } +0xfffffd95e620->Object::Object { 0xaaab1306e2e0 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaae3a232e0 'a') --> $$ = nterm item (0xffffe877f4b0 'a') -0xaaaae3a232e0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f4b0 } -0xaaaae3a232e0->Object::Object { 0xffffe877f4b0 } -0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f4b0 } + $1 = token 'a' (0xaaab1306e2e0 'a') +-> $$ = nterm item (0xfffffd95e620 'a') +0xaaab1306e2e0->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e620 } +0xaaab1306e2e0->Object::Object { 0xfffffd95e620 } +0xfffffd95e620->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e620 } Entering state 10 Stack now 0 10 Reading a token -0xffffe877f390->Object::Object { 0xaaaae3a232e0 } -0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xffffe877f390 } -0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xffffe877f390, 0xffffe877f490 } -Next token is token 'a' (0xffffe877f490 'a') -0xffffe877f3d0->Object::Object { 0xaaaae3a232e0, 0xffffe877f490 } -0xffffe877f490->Object::~Object { 0xaaaae3a232e0, 0xffffe877f3d0, 0xffffe877f490 } -Shifting token 'a' (0xffffe877f3d0 'a') -0xaaaae3a23300->Object::Object { 0xaaaae3a232e0, 0xffffe877f3d0 } -0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f3d0 } +0xfffffd95e500->Object::Object { 0xaaab1306e2e0 } +0xfffffd95e600->Object::Object { 0xaaab1306e2e0, 0xfffffd95e500 } +0xfffffd95e500->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e500, 0xfffffd95e600 } +Next token is token 'a' (0xfffffd95e600 'a') +0xfffffd95e540->Object::Object { 0xaaab1306e2e0, 0xfffffd95e600 } +0xfffffd95e600->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e540, 0xfffffd95e600 } +Shifting token 'a' (0xfffffd95e540 'a') +0xaaab1306e300->Object::Object { 0xaaab1306e2e0, 0xfffffd95e540 } +0xfffffd95e540->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e540 } Entering state 1 Stack now 0 10 1 -0xffffe877f4b0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300 } +0xfffffd95e620->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaae3a23300 'a') --> $$ = nterm item (0xffffe877f4b0 'a') -0xaaaae3a23300->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f4b0 } -0xaaaae3a23300->Object::Object { 0xaaaae3a232e0, 0xffffe877f4b0 } -0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f4b0 } + $1 = token 'a' (0xaaab1306e300 'a') +-> $$ = nterm item (0xfffffd95e620 'a') +0xaaab1306e300->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e620 } +0xaaab1306e300->Object::Object { 0xaaab1306e2e0, 0xfffffd95e620 } +0xfffffd95e620->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e620 } Entering state 10 Stack now 0 10 10 Reading a token -0xffffe877f390->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300 } -0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f390 } -0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f390, 0xffffe877f490 } -Next token is token 'a' (0xffffe877f490 'a') -0xffffe877f3d0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f490 } -0xffffe877f490->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f3d0, 0xffffe877f490 } -Shifting token 'a' (0xffffe877f3d0 'a') -0xaaaae3a23320->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f3d0 } -0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f3d0 } +0xfffffd95e500->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300 } +0xfffffd95e600->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e500 } +0xfffffd95e500->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e500, 0xfffffd95e600 } +Next token is token 'a' (0xfffffd95e600 'a') +0xfffffd95e540->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e600 } +0xfffffd95e600->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e540, 0xfffffd95e600 } +Shifting token 'a' (0xfffffd95e540 'a') +0xaaab1306e320->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e540 } +0xfffffd95e540->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e540 } Entering state 1 Stack now 0 10 10 1 -0xffffe877f4b0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320 } +0xfffffd95e620->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaae3a23320 'a') --> $$ = nterm item (0xffffe877f4b0 'a') -0xaaaae3a23320->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f4b0 } -0xaaaae3a23320->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f4b0 } -0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f4b0 } + $1 = token 'a' (0xaaab1306e320 'a') +-> $$ = nterm item (0xfffffd95e620 'a') +0xaaab1306e320->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e620 } +0xaaab1306e320->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e620 } +0xfffffd95e620->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e620 } Entering state 10 Stack now 0 10 10 10 Reading a token -0xffffe877f390->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320 } -0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f390 } -0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f390, 0xffffe877f490 } -Next token is token 'a' (0xffffe877f490 'a') -0xffffe877f3d0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f490 } -0xffffe877f490->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f3d0, 0xffffe877f490 } -Shifting token 'a' (0xffffe877f3d0 'a') -0xaaaae3a23340->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f3d0 } -0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f3d0 } +0xfffffd95e500->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320 } +0xfffffd95e600->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e500 } +0xfffffd95e500->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e500, 0xfffffd95e600 } +Next token is token 'a' (0xfffffd95e600 'a') +0xfffffd95e540->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e600 } +0xfffffd95e600->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e540, 0xfffffd95e600 } +Shifting token 'a' (0xfffffd95e540 'a') +0xaaab1306e340->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e540 } +0xfffffd95e540->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e540 } Entering state 1 Stack now 0 10 10 10 1 -0xffffe877f4b0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340 } +0xfffffd95e620->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaae3a23340 'a') --> $$ = nterm item (0xffffe877f4b0 'a') -0xaaaae3a23340->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f4b0 } -0xaaaae3a23340->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f4b0 } -0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f4b0 } + $1 = token 'a' (0xaaab1306e340 'a') +-> $$ = nterm item (0xfffffd95e620 'a') +0xaaab1306e340->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e620 } +0xaaab1306e340->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e620 } +0xfffffd95e620->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e620 } Entering state 10 Stack now 0 10 10 10 10 Reading a token -0xffffe877f390->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340 } -0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f390 } -0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f390, 0xffffe877f490 } -Next token is token 'p' (0xffffe877f490 'p'Exception caught: cleaning lookahead and stack -0xaaaae3a23340->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f490 } -0xaaaae3a23320->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f490 } -0xaaaae3a23300->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f490 } -0xaaaae3a232e0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f490 } -0xffffe877f490->Object::~Object { 0xffffe877f490 } +0xfffffd95e500->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340 } +0xfffffd95e600->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e500 } +0xfffffd95e500->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e500, 0xfffffd95e600 } +Next token is token 'p' (0xfffffd95e600 'p'Exception caught: cleaning lookahead and stack +0xaaab1306e340->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e600 } +0xaaab1306e320->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e600 } +0xaaab1306e300->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e600 } +0xaaab1306e2e0->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e600 } +0xfffffd95e600->Object::~Object { 0xfffffd95e600 } exception caught: printer end { } -./c++.at:1360: $PREPARSER ./input aaaas -stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -exception caught: reduction -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./c++.at:1360: $PREPARSER ./input aaaal Starting parse Entering state 0 Stack now 0 Reading a token -0xffffe877f390->Object::Object { } -0xffffe877f490->Object::Object { 0xffffe877f390 } -0xffffe877f390->Object::~Object { 0xffffe877f390, 0xffffe877f490 } -Next token is token 'a' (0xffffe877f490 'a') -0xffffe877f3d0->Object::Object { 0xffffe877f490 } -0xffffe877f490->Object::~Object { 0xffffe877f3d0, 0xffffe877f490 } -Shifting token 'a' (0xffffe877f3d0 'a') -0xaaaae3a232e0->Object::Object { 0xffffe877f3d0 } -0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f3d0 } +0xfffffd95e500->Object::Object { } +0xfffffd95e600->Object::Object { 0xfffffd95e500 } +0xfffffd95e500->Object::~Object { 0xfffffd95e500, 0xfffffd95e600 } +Next token is token 'a' (0xfffffd95e600 'a') +0xfffffd95e540->Object::Object { 0xfffffd95e600 } +0xfffffd95e600->Object::~Object { 0xfffffd95e540, 0xfffffd95e600 } +Shifting token 'a' (0xfffffd95e540 'a') +0xaaab1306e2e0->Object::Object { 0xfffffd95e540 } +0xfffffd95e540->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e540 } Entering state 1 Stack now 0 1 -0xffffe877f4b0->Object::Object { 0xaaaae3a232e0 } +0xfffffd95e620->Object::Object { 0xaaab1306e2e0 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaae3a232e0 'a') --> $$ = nterm item (0xffffe877f4b0 'a') -0xaaaae3a232e0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f4b0 } -0xaaaae3a232e0->Object::Object { 0xffffe877f4b0 } -0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f4b0 } + $1 = token 'a' (0xaaab1306e2e0 'a') +-> $$ = nterm item (0xfffffd95e620 'a') +0xaaab1306e2e0->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e620 } +0xaaab1306e2e0->Object::Object { 0xfffffd95e620 } +0xfffffd95e620->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e620 } Entering state 10 Stack now 0 10 Reading a token -0xffffe877f390->Object::Object { 0xaaaae3a232e0 } -0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xffffe877f390 } -0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xffffe877f390, 0xffffe877f490 } -Next token is token 'a' (0xffffe877f490 'a') -0xffffe877f3d0->Object::Object { 0xaaaae3a232e0, 0xffffe877f490 } -0xffffe877f490->Object::~Object { 0xaaaae3a232e0, 0xffffe877f3d0, 0xffffe877f490 } -Shifting token 'a' (0xffffe877f3d0 'a') -0xaaaae3a23300->Object::Object { 0xaaaae3a232e0, 0xffffe877f3d0 } -0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f3d0 } +0xfffffd95e500->Object::Object { 0xaaab1306e2e0 } +0xfffffd95e600->Object::Object { 0xaaab1306e2e0, 0xfffffd95e500 } +0xfffffd95e500->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e500, 0xfffffd95e600 } +Next token is token 'a' (0xfffffd95e600 'a') +0xfffffd95e540->Object::Object { 0xaaab1306e2e0, 0xfffffd95e600 } +0xfffffd95e600->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e540, 0xfffffd95e600 } +Shifting token 'a' (0xfffffd95e540 'a') +0xaaab1306e300->Object::Object { 0xaaab1306e2e0, 0xfffffd95e540 } +0xfffffd95e540->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e540 } Entering state 1 Stack now 0 10 1 -0xffffe877f4b0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300 } +0xfffffd95e620->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaae3a23300 'a') --> $$ = nterm item (0xffffe877f4b0 'a') -0xaaaae3a23300->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f4b0 } -0xaaaae3a23300->Object::Object { 0xaaaae3a232e0, 0xffffe877f4b0 } -0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f4b0 } + $1 = token 'a' (0xaaab1306e300 'a') +-> $$ = nterm item (0xfffffd95e620 'a') +0xaaab1306e300->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e620 } +0xaaab1306e300->Object::Object { 0xaaab1306e2e0, 0xfffffd95e620 } +0xfffffd95e620->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e620 } Entering state 10 Stack now 0 10 10 Reading a token -0xffffe877f390->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300 } -0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f390 } -0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f390, 0xffffe877f490 } -Next token is token 'a' (0xffffe877f490 'a') -0xffffe877f3d0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f490 } -0xffffe877f490->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f3d0, 0xffffe877f490 } -Shifting token 'a' (0xffffe877f3d0 'a') -0xaaaae3a23320->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f3d0 } -0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f3d0 } +0xfffffd95e500->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300 } +0xfffffd95e600->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e500 } +0xfffffd95e500->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e500, 0xfffffd95e600 } +Next token is token 'a' (0xfffffd95e600 'a') +0xfffffd95e540->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e600 } +0xfffffd95e600->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e540, 0xfffffd95e600 } +Shifting token 'a' (0xfffffd95e540 'a') +0xaaab1306e320->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e540 } +0xfffffd95e540->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e540 } Entering state 1 Stack now 0 10 10 1 -0xffffe877f4b0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320 } +0xfffffd95e620->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaae3a23320 'a') --> $$ = nterm item (0xffffe877f4b0 'a') -0xaaaae3a23320->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f4b0 } -0xaaaae3a23320->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f4b0 } -0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f4b0 } + $1 = token 'a' (0xaaab1306e320 'a') +-> $$ = nterm item (0xfffffd95e620 'a') +0xaaab1306e320->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e620 } +0xaaab1306e320->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e620 } +0xfffffd95e620->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e620 } Entering state 10 Stack now 0 10 10 10 Reading a token -0xffffe877f390->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320 } -0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f390 } -0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f390, 0xffffe877f490 } -Next token is token 'a' (0xffffe877f490 'a') -0xffffe877f3d0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f490 } -0xffffe877f490->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f3d0, 0xffffe877f490 } -Shifting token 'a' (0xffffe877f3d0 'a') -0xaaaae3a23340->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f3d0 } -0xffffe877f3d0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f3d0 } +0xfffffd95e500->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320 } +0xfffffd95e600->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e500 } +0xfffffd95e500->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e500, 0xfffffd95e600 } +Next token is token 'a' (0xfffffd95e600 'a') +0xfffffd95e540->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e600 } +0xfffffd95e600->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e540, 0xfffffd95e600 } +Shifting token 'a' (0xfffffd95e540 'a') +0xaaab1306e340->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e540 } +0xfffffd95e540->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e540 } Entering state 1 Stack now 0 10 10 10 1 -0xffffe877f4b0->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340 } +0xfffffd95e620->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaae3a23340 'a') --> $$ = nterm item (0xffffe877f4b0 'a') -0xaaaae3a23340->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f4b0 } -0xaaaae3a23340->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f4b0 } -0xffffe877f4b0->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f4b0 } + $1 = token 'a' (0xaaab1306e340 'a') +-> $$ = nterm item (0xfffffd95e620 'a') +0xaaab1306e340->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e620 } +0xaaab1306e340->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e620 } +0xfffffd95e620->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e620 } Entering state 10 Stack now 0 10 10 10 10 Reading a token -0xffffe877f390->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340 } -0xffffe877f490->Object::Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f390 } -0xffffe877f390->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f390, 0xffffe877f490 } -Next token is token 'p' (0xffffe877f490 'p'Exception caught: cleaning lookahead and stack -0xaaaae3a23340->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xaaaae3a23340, 0xffffe877f490 } -0xaaaae3a23320->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xaaaae3a23320, 0xffffe877f490 } -0xaaaae3a23300->Object::~Object { 0xaaaae3a232e0, 0xaaaae3a23300, 0xffffe877f490 } -0xaaaae3a232e0->Object::~Object { 0xaaaae3a232e0, 0xffffe877f490 } -0xffffe877f490->Object::~Object { 0xffffe877f490 } +0xfffffd95e500->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340 } +0xfffffd95e600->Object::Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e500 } +0xfffffd95e500->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e500, 0xfffffd95e600 } +Next token is token 'p' (0xfffffd95e600 'p'Exception caught: cleaning lookahead and stack +0xaaab1306e340->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xaaab1306e340, 0xfffffd95e600 } +0xaaab1306e320->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xaaab1306e320, 0xfffffd95e600 } +0xaaab1306e300->Object::~Object { 0xaaab1306e2e0, 0xaaab1306e300, 0xfffffd95e600 } +0xaaab1306e2e0->Object::~Object { 0xaaab1306e2e0, 0xfffffd95e600 } +0xfffffd95e600->Object::~Object { 0xfffffd95e600 } exception caught: printer end { } ./c++.at:1363: grep '^exception caught: printer$' stderr -stderr: stdout: -exception caught: yylex exception caught: printer -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: ./c++.at:1363: $PREPARSER ./input aaaae stderr: -stdout: -./glr-regression.at:592: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr4 glr-regr4.c $LIBS +stderr: exception caught: syntax error +stdout: ./c++.at:1361: $PREPARSER ./input aaaas ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -stderr: -./c++.at:1360: $PREPARSER ./input i -stdout: -stderr: exception caught: reduction -exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./glr-regression.at:488: $PREPARSER ./glr-regr3 input.txt ./c++.at:1363: $PREPARSER ./input aaaaE -stdout: -stderr: -./c++.at:858: $PREPARSER ./input -stderr: -stderr: -./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -exception caught: syntax error, unexpected end of file, expecting 'a' -./c++.at:1360: $PREPARSER ./input aaaap -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -./glr-regression.at:488: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaal -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:1360: $PREPARSER ./input --debug aaaap -./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -0xaaaae011ff40->Object::Object { } -Next token is token 'a' (0xaaaae011ff40 'a') -Shifting token 'a' (0xaaaae011ff40 'a') -Entering state 2 -Stack now 0 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae011ff40 'a') --> $$ = nterm item (0xaaaae011ff40 'a') -Entering state 11 -Stack now 0 11 -Reading a token -0xaaaae011ff90->Object::Object { 0xaaaae011ff40 } -Next token is token 'a' (0xaaaae011ff90 'a') -Shifting token 'a' (0xaaaae011ff90 'a') -Entering state 2 -Stack now 0 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae011ff90 'a') --> $$ = nterm item (0xaaaae011ff90 'a') -Entering state 11 -Stack now 0 11 11 -Reading a token -0xaaaae011ffe0->Object::Object { 0xaaaae011ff40, 0xaaaae011ff90 } -Next token is token 'a' (0xaaaae011ffe0 'a') -Shifting token 'a' (0xaaaae011ffe0 'a') -Entering state 2 -Stack now 0 11 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae011ffe0 'a') --> $$ = nterm item (0xaaaae011ffe0 'a') -Entering state 11 -Stack now 0 11 11 11 -Reading a token -0xaaaae0120030->Object::Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0 } -Next token is token 'a' (0xaaaae0120030 'a') -Shifting token 'a' (0xaaaae0120030 'a') -Entering state 2 -Stack now 0 11 11 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae0120030 'a') --> $$ = nterm item (0xaaaae0120030 'a') -Entering state 11 -Stack now 0 11 11 11 11 -Reading a token -0xaaaae0120080->Object::Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0, 0xaaaae0120030 } -Next token is token 'p' (0xaaaae0120080 'p'Exception caught: cleaning lookahead and stack -0xaaaae0120080->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0, 0xaaaae0120030, 0xaaaae0120080 } -0xaaaae0120030->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0, 0xaaaae0120030 } -0xaaaae011ffe0->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0 } -0xaaaae011ff90->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90 } -0xaaaae011ff40->Object::~Object { 0xaaaae011ff40 } -exception caught: printer -end { } -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +exception caught: syntax error, unexpected end of file, expecting 'a' stderr: +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaT exception caught: yylex -720. glr-regression.at:488: ok -./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: stderr: -Starting parse -Entering state 0 -Stack now 0 -Reading a token -0xaaaae011ff40->Object::Object { } -Next token is token 'a' (0xaaaae011ff40 'a') -Shifting token 'a' (0xaaaae011ff40 'a') -Entering state 2 -Stack now 0 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae011ff40 'a') --> $$ = nterm item (0xaaaae011ff40 'a') -Entering state 11 -Stack now 0 11 -Reading a token -0xaaaae011ff90->Object::Object { 0xaaaae011ff40 } -Next token is token 'a' (0xaaaae011ff90 'a') -Shifting token 'a' (0xaaaae011ff90 'a') -Entering state 2 -Stack now 0 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae011ff90 'a') --> $$ = nterm item (0xaaaae011ff90 'a') -Entering state 11 -Stack now 0 11 11 -Reading a token -0xaaaae011ffe0->Object::Object { 0xaaaae011ff40, 0xaaaae011ff90 } -Next token is token 'a' (0xaaaae011ffe0 'a') -Shifting token 'a' (0xaaaae011ffe0 'a') -Entering state 2 -Stack now 0 11 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae011ffe0 'a') --> $$ = nterm item (0xaaaae011ffe0 'a') -Entering state 11 -Stack now 0 11 11 11 -Reading a token -0xaaaae0120030->Object::Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0 } -Next token is token 'a' (0xaaaae0120030 'a') -Shifting token 'a' (0xaaaae0120030 'a') -Entering state 2 -Stack now 0 11 11 11 2 -Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaae0120030 'a') --> $$ = nterm item (0xaaaae0120030 'a') -Entering state 11 -Stack now 0 11 11 11 11 -Reading a token -0xaaaae0120080->Object::Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0, 0xaaaae0120030 } -Next token is token 'p' (0xaaaae0120080 'p'Exception caught: cleaning lookahead and stack -0xaaaae0120080->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0, 0xaaaae0120030, 0xaaaae0120080 } -0xaaaae0120030->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0, 0xaaaae0120030 } -0xaaaae011ffe0->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90, 0xaaaae011ffe0 } -0xaaaae011ff90->Object::~Object { 0xaaaae011ff40, 0xaaaae011ff90 } -0xaaaae011ff40->Object::~Object { 0xaaaae011ff40 } -exception caught: printer -end { } -./c++.at:1360: grep '^exception caught: printer$' stderr ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stdout: -exception caught: printer -./c++.at:1360: $PREPARSER ./input aaaae +./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaR -./c++.at:1361: $PREPARSER ./input i -stderr: stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - +./c++.at:1361: $PREPARSER ./input i stderr: -exception caught: syntax error -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS exception caught: initial-action ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input aaaaE +======== Testing with C++ standard flags: '' +./c++.at:1363: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: -exception caught: syntax error, unexpected end of file, expecting 'a' -724. glr-regression.at:593: testing Duplicate representation of merged trees: %union { char *ptr; } glr.cc ... -./glr-regression.at:593: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.cc glr-regr4.y -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1361: $PREPARSER ./input aaaap +stdout: stderr: +./glr-regression.at:356: $PREPARSER ./glr-regr2a input1.txt ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input aaaaT -./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: +./glr-regression.at:356: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1361: $PREPARSER ./input --debug aaaap stderr: -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token -0xaaaaf835cf40->Object::Object { } -Next token is token 'a' (0xaaaaf835cf40 'a') -Shifting token 'a' (0xaaaaf835cf40 'a') +0xaaaadb8cdf40->Object::Object { } +Next token is token 'a' (0xaaaadb8cdf40 'a') +Shifting token 'a' (0xaaaadb8cdf40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf835cf40 'a') --> $$ = nterm item (0xaaaaf835cf40 'a') + $1 = token 'a' (0xaaaadb8cdf40 'a') +-> $$ = nterm item (0xaaaadb8cdf40 'a') Entering state 10 Stack now 0 10 Reading a token -0xaaaaf835cf90->Object::Object { 0xaaaaf835cf40 } -Next token is token 'a' (0xaaaaf835cf90 'a') -Shifting token 'a' (0xaaaaf835cf90 'a') +0xaaaadb8cdf90->Object::Object { 0xaaaadb8cdf40 } +Next token is token 'a' (0xaaaadb8cdf90 'a') +Shifting token 'a' (0xaaaadb8cdf90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf835cf90 'a') --> $$ = nterm item (0xaaaaf835cf90 'a') + $1 = token 'a' (0xaaaadb8cdf90 'a') +-> $$ = nterm item (0xaaaadb8cdf90 'a') Entering state 10 Stack now 0 10 10 Reading a token -0xaaaaf835cfe0->Object::Object { 0xaaaaf835cf40, 0xaaaaf835cf90 } -Next token is token 'a' (0xaaaaf835cfe0 'a') -Shifting token 'a' (0xaaaaf835cfe0 'a') +0xaaaadb8cdfe0->Object::Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90 } +Next token is token 'a' (0xaaaadb8cdfe0 'a') +Shifting token 'a' (0xaaaadb8cdfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf835cfe0 'a') --> $$ = nterm item (0xaaaaf835cfe0 'a') + $1 = token 'a' (0xaaaadb8cdfe0 'a') +-> $$ = nterm item (0xaaaadb8cdfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token -0xaaaaf835d030->Object::Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0 } -Next token is token 'a' (0xaaaaf835d030 'a') -Shifting token 'a' (0xaaaaf835d030 'a') +0xaaaadb8ce030->Object::Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90, 0xaaaadb8cdfe0 } +Next token is token 'a' (0xaaaadb8ce030 'a') +Shifting token 'a' (0xaaaadb8ce030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf835d030 'a') --> $$ = nterm item (0xaaaaf835d030 'a') + $1 = token 'a' (0xaaaadb8ce030 'a') +-> $$ = nterm item (0xaaaadb8ce030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token -0xaaaaf835d080->Object::Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0, 0xaaaaf835d030 } -Next token is token 'p' (0xaaaaf835d080 'p'Exception caught: cleaning lookahead and stack -0xaaaaf835d080->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0, 0xaaaaf835d030, 0xaaaaf835d080 } -0xaaaaf835d030->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0, 0xaaaaf835d030 } -0xaaaaf835cfe0->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0 } -0xaaaaf835cf90->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90 } -0xaaaaf835cf40->Object::~Object { 0xaaaaf835cf40 } +0xaaaadb8ce080->Object::Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90, 0xaaaadb8cdfe0, 0xaaaadb8ce030 } +Next token is token 'p' (0xaaaadb8ce080 'p'Exception caught: cleaning lookahead and stack +0xaaaadb8ce080->Object::~Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90, 0xaaaadb8cdfe0, 0xaaaadb8ce030, 0xaaaadb8ce080 } +0xaaaadb8ce030->Object::~Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90, 0xaaaadb8cdfe0, 0xaaaadb8ce030 } +0xaaaadb8cdfe0->Object::~Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90, 0xaaaadb8cdfe0 } +0xaaaadb8cdf90->Object::~Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90 } +0xaaaadb8cdf40->Object::~Object { 0xaaaadb8cdf40 } exception caught: printer end { } ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1360: $PREPARSER ./input aaaaR -stderr: -./glr-regression.at:593: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr4 glr-regr4.cc $LIBS stderr: -./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Starting parse Entering state 0 Stack now 0 Reading a token -0xaaaaf835cf40->Object::Object { } -Next token is token 'a' (0xaaaaf835cf40 'a') -Shifting token 'a' (0xaaaaf835cf40 'a') +0xaaaadb8cdf40->Object::Object { } +Next token is token 'a' (0xaaaadb8cdf40 'a') +Shifting token 'a' (0xaaaadb8cdf40 'a') Entering state 1 Stack now 0 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf835cf40 'a') --> $$ = nterm item (0xaaaaf835cf40 'a') + $1 = token 'a' (0xaaaadb8cdf40 'a') +-> $$ = nterm item (0xaaaadb8cdf40 'a') Entering state 10 Stack now 0 10 Reading a token -0xaaaaf835cf90->Object::Object { 0xaaaaf835cf40 } -Next token is token 'a' (0xaaaaf835cf90 'a') -Shifting token 'a' (0xaaaaf835cf90 'a') +0xaaaadb8cdf90->Object::Object { 0xaaaadb8cdf40 } +Next token is token 'a' (0xaaaadb8cdf90 'a') +Shifting token 'a' (0xaaaadb8cdf90 'a') Entering state 1 Stack now 0 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf835cf90 'a') --> $$ = nterm item (0xaaaaf835cf90 'a') + $1 = token 'a' (0xaaaadb8cdf90 'a') +-> $$ = nterm item (0xaaaadb8cdf90 'a') Entering state 10 Stack now 0 10 10 Reading a token -0xaaaaf835cfe0->Object::Object { 0xaaaaf835cf40, 0xaaaaf835cf90 } -Next token is token 'a' (0xaaaaf835cfe0 'a') -Shifting token 'a' (0xaaaaf835cfe0 'a') +0xaaaadb8cdfe0->Object::Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90 } +Next token is token 'a' (0xaaaadb8cdfe0 'a') +Shifting token 'a' (0xaaaadb8cdfe0 'a') Entering state 1 Stack now 0 10 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf835cfe0 'a') --> $$ = nterm item (0xaaaaf835cfe0 'a') + $1 = token 'a' (0xaaaadb8cdfe0 'a') +-> $$ = nterm item (0xaaaadb8cdfe0 'a') Entering state 10 Stack now 0 10 10 10 Reading a token -0xaaaaf835d030->Object::Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0 } -Next token is token 'a' (0xaaaaf835d030 'a') -Shifting token 'a' (0xaaaaf835d030 'a') +0xaaaadb8ce030->Object::Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90, 0xaaaadb8cdfe0 } +Next token is token 'a' (0xaaaadb8ce030 'a') +Shifting token 'a' (0xaaaadb8ce030 'a') Entering state 1 Stack now 0 10 10 10 1 Reducing stack by rule 4 (line 147): - $1 = token 'a' (0xaaaaf835d030 'a') --> $$ = nterm item (0xaaaaf835d030 'a') + $1 = token 'a' (0xaaaadb8ce030 'a') +-> $$ = nterm item (0xaaaadb8ce030 'a') Entering state 10 Stack now 0 10 10 10 10 Reading a token -0xaaaaf835d080->Object::Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0, 0xaaaaf835d030 } -Next token is token 'p' (0xaaaaf835d080 'p'Exception caught: cleaning lookahead and stack -0xaaaaf835d080->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0, 0xaaaaf835d030, 0xaaaaf835d080 } -0xaaaaf835d030->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0, 0xaaaaf835d030 } -0xaaaaf835cfe0->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90, 0xaaaaf835cfe0 } -0xaaaaf835cf90->Object::~Object { 0xaaaaf835cf40, 0xaaaaf835cf90 } -0xaaaaf835cf40->Object::~Object { 0xaaaaf835cf40 } +0xaaaadb8ce080->Object::Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90, 0xaaaadb8cdfe0, 0xaaaadb8ce030 } +Next token is token 'p' (0xaaaadb8ce080 'p'Exception caught: cleaning lookahead and stack +0xaaaadb8ce080->Object::~Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90, 0xaaaadb8cdfe0, 0xaaaadb8ce030, 0xaaaadb8ce080 } +0xaaaadb8ce030->Object::~Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90, 0xaaaadb8cdfe0, 0xaaaadb8ce030 } +0xaaaadb8cdfe0->Object::~Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90, 0xaaaadb8cdfe0 } +0xaaaadb8cdf90->Object::~Object { 0xaaaadb8cdf40, 0xaaaadb8cdf90 } +0xaaaadb8cdf40->Object::~Object { 0xaaaadb8cdf40 } exception caught: printer end { } ./c++.at:1361: grep '^exception caught: printer$' stderr -stderr: -stdout: -./glr-regression.at:207: $PREPARSER ./glr-regr1 BPBPB -stderr: -./glr-regression.at:207: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: exception caught: printer ./c++.at:1361: $PREPARSER ./input aaaae -685. c++.at:1360: ok stderr: exception caught: syntax error -716. glr-regression.at:207: ok ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - ./c++.at:1361: $PREPARSER ./input aaaaE - stderr: +./glr-regression.at:356: $PREPARSER ./glr-regr2a input2.txt exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -725. glr-regression.at:594: testing Duplicate representation of merged trees: %union { char *ptr; } glr2.cc ... +stderr: ./c++.at:1361: $PREPARSER ./input aaaaT -./glr-regression.at:594: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.cc glr-regr4.y +stderr: +stdout: stderr: ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -726. glr-regression.at:596: testing Duplicate representation of merged trees: api.value.type=union glr.c ... +./c++.at:857: $PREPARSER ./input +stderr: ./c++.at:1361: $PREPARSER ./input aaaaR +./c++.at:857: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./glr-regression.at:356: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./glr-regression.at:596: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.c glr-regr4.y ./c++.at:1361: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:858: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy 686. c++.at:1361: ok -./glr-regression.at:594: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr4 glr-regr4.cc $LIBS -./glr-regression.at:596: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr4 glr-regr4.c $LIBS +======== Testing with C++ standard flags: '' +./glr-regression.at:356: $PREPARSER ./glr-regr2a input3.txt +./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -727. glr-regression.at:597: testing Duplicate representation of merged trees: api.value.type=union glr.cc ... -./glr-regression.at:597: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.cc glr-regr4.y -stderr: -stdout: -./glr-regression.at:592: $PREPARSER ./glr-regr4 -stderr: -./glr-regression.at:592: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:597: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr4 glr-regr4.cc $LIBS -723. glr-regression.at:592: ok stderr: -stdout: +./glr-regression.at:356: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +719. glr-regression.at:356: ok -./glr-regression.at:489: $PREPARSER ./glr-regr3 input.txt -stderr: -stdout: -stderr: -./c++.at:858: $PREPARSER ./input -stderr: -./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -./glr-regression.at:489: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -721. glr-regression.at:489: ok 728. glr-regression.at:598: testing Duplicate representation of merged trees: api.value.type=union glr2.cc ... ./glr-regression.at:598: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr4.cc glr-regr4.y -./glr-regression.at:598: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr4 glr-regr4.cc $LIBS - 729. glr-regression.at:670: testing User destructor for unresolved GLR semantic value: glr.c ... ./glr-regression.at:670: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr5.c glr-regr5.y ./glr-regression.at:670: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr5 glr-regr5.c $LIBS +./glr-regression.at:598: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr4 glr-regr4.cc $LIBS stderr: stdout: -./glr-regression.at:596: $PREPARSER ./glr-regr4 +./glr-regression.at:593: $PREPARSER ./glr-regr4 stderr: -./glr-regression.at:596: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -726. glr-regression.at:596: ok - +./glr-regression.at:593: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +724. glr-regression.at:593: ok stderr: stdout: -./glr-regression.at:356: $PREPARSER ./glr-regr2a input1.txt +./glr-regression.at:596: $PREPARSER ./glr-regr4 stderr: -./glr-regression.at:356: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + +./glr-regression.at:596: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +726. glr-regression.at:596: ok 730. glr-regression.at:671: testing User destructor for unresolved GLR semantic value: glr.cc ... ./glr-regression.at:671: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr5.cc glr-regr5.y -./glr-regression.at:356: $PREPARSER ./glr-regr2a input2.txt -stderr: -./glr-regression.at:356: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:356: $PREPARSER ./glr-regr2a input3.txt -stderr: -./glr-regression.at:356: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -719. glr-regression.at:356: ok ./glr-regression.at:671: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr5 glr-regr5.cc $LIBS 731. glr-regression.at:672: testing User destructor for unresolved GLR semantic value: glr2.cc ... ./glr-regression.at:672: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr5.cc glr-regr5.y +./glr-regression.at:672: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr5 glr-regr5.cc $LIBS stderr: stdout: -./glr-regression.at:593: $PREPARSER ./glr-regr4 +./c++.at:1360: $PREPARSER ./input aaaas stderr: -./glr-regression.at:593: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +exception caught: reduction +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./c++.at:1360: $PREPARSER ./input aaaal +stdout: +./glr-regression.at:597: $PREPARSER ./glr-regr4 +stderr: +exception caught: yylex +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./c++.at:1360: $PREPARSER ./input i +stderr: +exception caught: initial-action +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./glr-regression.at:597: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +727. glr-regression.at:597: ok +stderr: +./c++.at:1360: $PREPARSER ./input aaaap stderr: +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: $PREPARSER ./input --debug aaaap stdout: +stderr: +Starting parse +Entering state 0 +Stack now 0 +Reading a token +0xaaaac5722f40->Object::Object { } +Next token is token 'a' (0xaaaac5722f40 'a') +Shifting token 'a' (0xaaaac5722f40 'a') +Entering state 2 +Stack now 0 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac5722f40 'a') +-> $$ = nterm item (0xaaaac5722f40 'a') +Entering state 11 +Stack now 0 11 +Reading a token +0xaaaac5722f90->Object::Object { 0xaaaac5722f40 } +Next token is token 'a' (0xaaaac5722f90 'a') +Shifting token 'a' (0xaaaac5722f90 'a') +Entering state 2 +Stack now 0 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac5722f90 'a') +-> $$ = nterm item (0xaaaac5722f90 'a') +Entering state 11 +Stack now 0 11 11 +Reading a token +0xaaaac5722fe0->Object::Object { 0xaaaac5722f40, 0xaaaac5722f90 } +Next token is token 'a' (0xaaaac5722fe0 'a') +Shifting token 'a' (0xaaaac5722fe0 'a') +Entering state 2 +Stack now 0 11 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac5722fe0 'a') +-> $$ = nterm item (0xaaaac5722fe0 'a') +Entering state 11 +Stack now 0 11 11 11 +Reading a token +0xaaaac5723030->Object::Object { 0xaaaac5722f40, 0xaaaac5722f90, 0xaaaac5722fe0 } +Next token is token 'a' (0xaaaac5723030 'a') +Shifting token 'a' (0xaaaac5723030 'a') +Entering state 2 +Stack now 0 11 11 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac5723030 'a') +-> $$ = nterm item (0xaaaac5723030 'a') +Entering state 11 +Stack now 0 11 11 11 11 +Reading a token +0xaaaac5723080->Object::Object { 0xaaaac5722f40, 0xaaaac5722f90, 0xaaaac5722fe0, 0xaaaac5723030 } +Next token is token 'p' (0xaaaac5723080 'p'Exception caught: cleaning lookahead and stack +0xaaaac5723080->Object::~Object { 0xaaaac5722f40, 0xaaaac5722f90, 0xaaaac5722fe0, 0xaaaac5723030, 0xaaaac5723080 } +0xaaaac5723030->Object::~Object { 0xaaaac5722f40, 0xaaaac5722f90, 0xaaaac5722fe0, 0xaaaac5723030 } +0xaaaac5722fe0->Object::~Object { 0xaaaac5722f40, 0xaaaac5722f90, 0xaaaac5722fe0 } +0xaaaac5722f90->Object::~Object { 0xaaaac5722f40, 0xaaaac5722f90 } +0xaaaac5722f40->Object::~Object { 0xaaaac5722f40 } +exception caught: printer +end { } +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:858: $PREPARSER ./input -724. glr-regression.at:593: ok stderr: -./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:672: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr5 glr-regr5.cc $LIBS -======== Testing with C++ standard flags: '' -./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS - -732. glr-regression.at:738: testing User destructor after an error during a split parse: glr.c ... -./glr-regression.at:738: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr6.c glr-regr6.y +Starting parse +Entering state 0 +Stack now 0 +Reading a token +0xaaaac5722f40->Object::Object { } +Next token is token 'a' (0xaaaac5722f40 'a') +Shifting token 'a' (0xaaaac5722f40 'a') +Entering state 2 +Stack now 0 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac5722f40 'a') +-> $$ = nterm item (0xaaaac5722f40 'a') +Entering state 11 +Stack now 0 11 +Reading a token +0xaaaac5722f90->Object::Object { 0xaaaac5722f40 } +Next token is token 'a' (0xaaaac5722f90 'a') +Shifting token 'a' (0xaaaac5722f90 'a') +Entering state 2 +Stack now 0 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac5722f90 'a') +-> $$ = nterm item (0xaaaac5722f90 'a') +Entering state 11 +Stack now 0 11 11 +Reading a token +0xaaaac5722fe0->Object::Object { 0xaaaac5722f40, 0xaaaac5722f90 } +Next token is token 'a' (0xaaaac5722fe0 'a') +Shifting token 'a' (0xaaaac5722fe0 'a') +Entering state 2 +Stack now 0 11 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac5722fe0 'a') +-> $$ = nterm item (0xaaaac5722fe0 'a') +Entering state 11 +Stack now 0 11 11 11 +Reading a token +0xaaaac5723030->Object::Object { 0xaaaac5722f40, 0xaaaac5722f90, 0xaaaac5722fe0 } +Next token is token 'a' (0xaaaac5723030 'a') +Shifting token 'a' (0xaaaac5723030 'a') +Entering state 2 +Stack now 0 11 11 11 2 +Reducing stack by rule 4 (line 147): + $1 = token 'a' (0xaaaac5723030 'a') +-> $$ = nterm item (0xaaaac5723030 'a') +Entering state 11 +Stack now 0 11 11 11 11 +Reading a token +0xaaaac5723080->Object::Object { 0xaaaac5722f40, 0xaaaac5722f90, 0xaaaac5722fe0, 0xaaaac5723030 } +Next token is token 'p' (0xaaaac5723080 'p'Exception caught: cleaning lookahead and stack +0xaaaac5723080->Object::~Object { 0xaaaac5722f40, 0xaaaac5722f90, 0xaaaac5722fe0, 0xaaaac5723030, 0xaaaac5723080 } +0xaaaac5723030->Object::~Object { 0xaaaac5722f40, 0xaaaac5722f90, 0xaaaac5722fe0, 0xaaaac5723030 } +0xaaaac5722fe0->Object::~Object { 0xaaaac5722f40, 0xaaaac5722f90, 0xaaaac5722fe0 } +0xaaaac5722f90->Object::~Object { 0xaaaac5722f40, 0xaaaac5722f90 } +0xaaaac5722f40->Object::~Object { 0xaaaac5722f40 } +exception caught: printer +end { } +./c++.at:1360: grep '^exception caught: printer$' stderr +stderr: stderr: stdout: +exception caught: printer +./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: $PREPARSER ./input aaaae +stdout: ./glr-regression.at:670: $PREPARSER ./glr-regr5 stderr: +stderr: +======== Testing with C++ standard flags: '' Ambiguity detected. Option 1, start -> @@ -270074,61 +270078,69 @@ 'a' syntax is ambiguous -stderr: -stdout: -./glr-regression.at:738: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr6 glr-regr6.c $LIBS ./glr-regression.at:670: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:597: $PREPARSER ./glr-regr4 -stderr: -./glr-regression.at:597: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -727. glr-regression.at:597: ok +./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +exception caught: syntax error +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: $PREPARSER ./input aaaaE 729. glr-regression.at:670: ok +stderr: +exception caught: syntax error, unexpected end of file, expecting 'a' +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + +./c++.at:1360: $PREPARSER ./input aaaaT +stderr: +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1360: $PREPARSER ./input aaaaR +stderr: +./c++.at:1360: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +685. c++.at:1360: ok +732. glr-regression.at:738: testing User destructor after an error during a split parse: glr.c ... +./glr-regression.at:738: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr6.c glr-regr6.y +./glr-regression.at:738: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr6 glr-regr6.c $LIBS 733. glr-regression.at:739: testing User destructor after an error during a split parse: glr.cc ... +./glr-regression.at:739: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr6.cc glr-regr6.y 734. glr-regression.at:740: testing User destructor after an error during a split parse: glr2.cc ... ./glr-regression.at:740: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr6.cc glr-regr6.y -./glr-regression.at:739: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr6.cc glr-regr6.y ./glr-regression.at:739: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr6 glr-regr6.cc $LIBS -./glr-regression.at:740: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr6 glr-regr6.cc $LIBS stderr: stdout: -./glr-regression.at:738: $PREPARSER ./glr-regr6 +./glr-regression.at:740: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr6 glr-regr6.cc $LIBS +./glr-regression.at:490: $PREPARSER ./glr-regr3 input.txt stderr: -Ambiguity detected. -Option 1, - start -> - 'a' - -Option 2, - start -> - 'a' +./glr-regression.at:490: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +722. glr-regression.at:490: ok -syntax is ambiguous -./glr-regression.at:738: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -732. glr-regression.at:738: ok -stderr: -stdout: +735. glr-regression.at:843: testing Duplicated user destructor for lookahead: glr.c ... +./glr-regression.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr7.c glr-regr7.y +./glr-regression.at:843: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr7 glr-regr7.c $LIBS stderr: -./glr-regression.at:490: $PREPARSER ./glr-regr3 input.txt stdout: -stderr: ./c++.at:858: $PREPARSER ./input stderr: -./glr-regression.at:490: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -722. glr-regression.at:490: ok ======== Testing with C++ standard flags: '' - ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -735. glr-regression.at:843: testing Duplicated user destructor for lookahead: glr.c ... -./glr-regression.at:843: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr7.c glr-regr7.y stderr: stdout: +stderr: +./c++.at:1362: $PREPARSER ./input aaaas +stderr: +stdout: +exception caught: reduction +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1362: $PREPARSER ./input aaaal +stderr: ./glr-regression.at:671: $PREPARSER ./glr-regr5 +exception caught: yylex +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -./glr-regression.at:843: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr7 glr-regr7.c $LIBS - +./c++.at:1362: $PREPARSER ./input i +stderr: +exception caught: initial-action +./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr Ambiguity detected. Option 1, start -> @@ -270139,507 +270151,568 @@ 'a' syntax is ambiguous -./glr-regression.at:671: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./glr-regression.at:671: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stdout: -./c++.at:1362: $PREPARSER ./input aaaas -stderr: -exception caught: reduction -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1362: $PREPARSER ./input aaaal -730. glr-regression.at:671: stderr: - ok -exception caught: yylex -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1362: $PREPARSER ./input i +./glr-regression.at:594: $PREPARSER ./glr-regr4 stderr: -exception caught: initial-action -./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./glr-regression.at:594: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input aaaap stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1362: $PREPARSER ./input --debug aaaap stderr: +stderr: +stdout: Starting parse Entering state 0 Stack now 0 Reading a token -0xfffffa294ce0->Object::Object { } -0xfffffa294de0->Object::Object { 0xfffffa294ce0 } -0xfffffa294ce0->Object::~Object { 0xfffffa294ce0, 0xfffffa294de0 } -Next token is token 'a' (0xfffffa294de0 'a') -0xfffffa294d20->Object::Object { 0xfffffa294de0 } -0xfffffa294de0->Object::~Object { 0xfffffa294d20, 0xfffffa294de0 } -Shifting token 'a' (0xfffffa294d20 'a') -0xaaaacf2732e0->Object::Object { 0xfffffa294d20 } -0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xfffffa294d20 } +0xffffc6645870->Object::Object { } +0xffffc6645970->Object::Object { 0xffffc6645870 } +0xffffc6645870->Object::~Object { 0xffffc6645870, 0xffffc6645970 } +Next token is token 'a' (0xffffc6645970 'a') +0xffffc66458b0->Object::Object { 0xffffc6645970 } +0xffffc6645970->Object::~Object { 0xffffc66458b0, 0xffffc6645970 } +Shifting token 'a' (0xffffc66458b0 'a') +0xaaaad63fe2e0->Object::Object { 0xffffc66458b0 } +0xffffc66458b0->Object::~Object { 0xaaaad63fe2e0, 0xffffc66458b0 } Entering state 2 Stack now 0 2 -0xfffffa294e00->Object::Object { 0xaaaacf2732e0 } +0xffffc6645990->Object::Object { 0xaaaad63fe2e0 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaacf2732e0 'a') --> $$ = nterm item (0xfffffa294e00 'a') -0xaaaacf2732e0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294e00 } -0xaaaacf2732e0->Object::Object { 0xfffffa294e00 } -0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xfffffa294e00 } + $1 = token 'a' (0xaaaad63fe2e0 'a') +-> $$ = nterm item (0xffffc6645990 'a') +0xaaaad63fe2e0->Object::~Object { 0xaaaad63fe2e0, 0xffffc6645990 } +0xaaaad63fe2e0->Object::Object { 0xffffc6645990 } +0xffffc6645990->Object::~Object { 0xaaaad63fe2e0, 0xffffc6645990 } Entering state 11 Stack now 0 11 Reading a token -0xfffffa294ce0->Object::Object { 0xaaaacf2732e0 } -0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xfffffa294ce0 } -0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294ce0, 0xfffffa294de0 } -Next token is token 'a' (0xfffffa294de0 'a') -0xfffffa294d20->Object::Object { 0xaaaacf2732e0, 0xfffffa294de0 } -0xfffffa294de0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294d20, 0xfffffa294de0 } -Shifting token 'a' (0xfffffa294d20 'a') -0xaaaacf273300->Object::Object { 0xaaaacf2732e0, 0xfffffa294d20 } -0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294d20 } +0xffffc6645870->Object::Object { 0xaaaad63fe2e0 } +0xffffc6645970->Object::Object { 0xaaaad63fe2e0, 0xffffc6645870 } +0xffffc6645870->Object::~Object { 0xaaaad63fe2e0, 0xffffc6645870, 0xffffc6645970 } +Next token is token 'a' (0xffffc6645970 'a') +0xffffc66458b0->Object::Object { 0xaaaad63fe2e0, 0xffffc6645970 } +0xffffc6645970->Object::~Object { 0xaaaad63fe2e0, 0xffffc66458b0, 0xffffc6645970 } +Shifting token 'a' (0xffffc66458b0 'a') +0xaaaad63fe300->Object::Object { 0xaaaad63fe2e0, 0xffffc66458b0 } +0xffffc66458b0->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc66458b0 } Entering state 2 Stack now 0 11 2 -0xfffffa294e00->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300 } +0xffffc6645990->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaacf273300 'a') --> $$ = nterm item (0xfffffa294e00 'a') -0xaaaacf273300->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294e00 } -0xaaaacf273300->Object::Object { 0xaaaacf2732e0, 0xfffffa294e00 } -0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294e00 } + $1 = token 'a' (0xaaaad63fe300 'a') +-> $$ = nterm item (0xffffc6645990 'a') +0xaaaad63fe300->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645990 } +0xaaaad63fe300->Object::Object { 0xaaaad63fe2e0, 0xffffc6645990 } +0xffffc6645990->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645990 } Entering state 11 Stack now 0 11 11 Reading a token -0xfffffa294ce0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300 } -0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294ce0 } -0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294ce0, 0xfffffa294de0 } -Next token is token 'a' (0xfffffa294de0 'a') -0xfffffa294d20->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294de0 } -0xfffffa294de0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294d20, 0xfffffa294de0 } -Shifting token 'a' (0xfffffa294d20 'a') -0xaaaacf273320->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294d20 } -0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294d20 } +0xffffc6645870->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300 } +0xffffc6645970->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645870 } +0xffffc6645870->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645870, 0xffffc6645970 } +Next token is token 'a' (0xffffc6645970 'a') +0xffffc66458b0->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645970 } +0xffffc6645970->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc66458b0, 0xffffc6645970 } +Shifting token 'a' (0xffffc66458b0 'a') +0xaaaad63fe320->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc66458b0 } +0xffffc66458b0->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc66458b0 } Entering state 2 Stack now 0 11 11 2 -0xfffffa294e00->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320 } +0xffffc6645990->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaacf273320 'a') --> $$ = nterm item (0xfffffa294e00 'a') -0xaaaacf273320->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294e00 } -0xaaaacf273320->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294e00 } -0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294e00 } + $1 = token 'a' (0xaaaad63fe320 'a') +-> $$ = nterm item (0xffffc6645990 'a') +0xaaaad63fe320->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645990 } +0xaaaad63fe320->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645990 } +0xffffc6645990->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645990 } Entering state 11 Stack now 0 11 11 11 Reading a token -0xfffffa294ce0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320 } -0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294ce0 } -0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294ce0, 0xfffffa294de0 } -Next token is token 'a' (0xfffffa294de0 'a') -0xfffffa294d20->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294de0 } -0xfffffa294de0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294d20, 0xfffffa294de0 } -Shifting token 'a' (0xfffffa294d20 'a') -0xaaaacf273340->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294d20 } -0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294d20 } +0xffffc6645870->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320 } +0xffffc6645970->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645870 } +0xffffc6645870->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645870, 0xffffc6645970 } +Next token is token 'a' (0xffffc6645970 'a') +0xffffc66458b0->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645970 } +0xffffc6645970->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc66458b0, 0xffffc6645970 } +Shifting token 'a' (0xffffc66458b0 'a') +0xaaaad63fe340->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc66458b0 } +0xffffc66458b0->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc66458b0 } Entering state 2 Stack now 0 11 11 11 2 -0xfffffa294e00->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340 } +0xffffc6645990->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaacf273340 'a') --> $$ = nterm item (0xfffffa294e00 'a') -0xaaaacf273340->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294e00 } -0xaaaacf273340->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294e00 } -0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294e00 } + $1 = token 'a' (0xaaaad63fe340 'a') +-> $$ = nterm item (0xffffc6645990 'a') +0xaaaad63fe340->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc6645990 } +0xaaaad63fe340->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645990 } +0xffffc6645990->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc6645990 } Entering state 11 Stack now 0 11 11 11 11 Reading a token -0xfffffa294ce0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340 } -0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294ce0 } -0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294ce0, 0xfffffa294de0 } -Next token is token 'p' (0xfffffa294de0 'p'Exception caught: cleaning lookahead and stack -0xaaaacf273340->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294de0 } -0xaaaacf273320->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294de0 } -0xaaaacf273300->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294de0 } -0xaaaacf2732e0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294de0 } -0xfffffa294de0->Object::~Object { 0xfffffa294de0 } +0xffffc6645870->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340 } +0xffffc6645970->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc6645870 } +0xffffc6645870->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc6645870, 0xffffc6645970 } +Next token is token 'p' (0xffffc6645970 'p'Exception caught: cleaning lookahead and stack +0xaaaad63fe340->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc6645970 } +0xaaaad63fe320->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645970 } +0xaaaad63fe300->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645970 } +0xaaaad63fe2e0->Object::~Object { 0xaaaad63fe2e0, 0xffffc6645970 } +0xffffc6645970->Object::~Object { 0xffffc6645970 } exception caught: printer end { } +./glr-regression.at:738: $PREPARSER ./glr-regr6 ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - stderr: -736. glr-regression.at:844: testing Duplicated user destructor for lookahead: glr.cc ... -./glr-regression.at:844: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr7.cc glr-regr7.y Starting parse Entering state 0 Stack now 0 Reading a token -0xfffffa294ce0->Object::Object { } -0xfffffa294de0->Object::Object { 0xfffffa294ce0 } -0xfffffa294ce0->Object::~Object { 0xfffffa294ce0, 0xfffffa294de0 } -Next token is token 'a' (0xfffffa294de0 'a') -0xfffffa294d20->Object::Object { 0xfffffa294de0 } -0xfffffa294de0->Object::~Object { 0xfffffa294d20, 0xfffffa294de0 } -Shifting token 'a' (0xfffffa294d20 'a') -0xaaaacf2732e0->Object::Object { 0xfffffa294d20 } -0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xfffffa294d20 } +0xffffc6645870->Object::Object { } +0xffffc6645970->Object::Object { 0xffffc6645870 } +0xffffc6645870->Object::~Object { 0xffffc6645870, 0xffffc6645970 } +Next token is token 'a' (0xffffc6645970 'a') +0xffffc66458b0->Object::Object { 0xffffc6645970 } +0xffffc6645970->Object::~Object { 0xffffc66458b0, 0xffffc6645970 } +Shifting token 'a' (0xffffc66458b0 'a') +0xaaaad63fe2e0->Object::Object { 0xffffc66458b0 } +0xffffc66458b0->Object::~Object { 0xaaaad63fe2e0, 0xffffc66458b0 } Entering state 2 Stack now 0 2 -0xfffffa294e00->Object::Object { 0xaaaacf2732e0 } +0xffffc6645990->Object::Object { 0xaaaad63fe2e0 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaacf2732e0 'a') --> $$ = nterm item (0xfffffa294e00 'a') -0xaaaacf2732e0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294e00 } -0xaaaacf2732e0->Object::Object { 0xfffffa294e00 } -0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xfffffa294e00 } + $1 = token 'a' (0xaaaad63fe2e0 'a') +-> $$ = nterm item (0xffffc6645990 'a') +0xaaaad63fe2e0->Object::~Object { 0xaaaad63fe2e0, 0xffffc6645990 } +0xaaaad63fe2e0->Object::Object { 0xffffc6645990 } +0xffffc6645990->Object::~Object { 0xaaaad63fe2e0, 0xffffc6645990 } Entering state 11 Stack now 0 11 Reading a token -0xfffffa294ce0->Object::Object { 0xaaaacf2732e0 } -0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xfffffa294ce0 } -0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294ce0, 0xfffffa294de0 } -Next token is token 'a' (0xfffffa294de0 'a') -0xfffffa294d20->Object::Object { 0xaaaacf2732e0, 0xfffffa294de0 } -0xfffffa294de0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294d20, 0xfffffa294de0 } -Shifting token 'a' (0xfffffa294d20 'a') -0xaaaacf273300->Object::Object { 0xaaaacf2732e0, 0xfffffa294d20 } -0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294d20 } +0xffffc6645870->Object::Object { 0xaaaad63fe2e0 } +0xffffc6645970->Object::Object { 0xaaaad63fe2e0, 0xffffc6645870 } +0xffffc6645870->Object::~Object { 0xaaaad63fe2e0, 0xffffc6645870, 0xffffc6645970 } +Next token is token 'a' (0xffffc6645970 'a') +0xffffc66458b0->Object::Object { 0xaaaad63fe2e0, 0xffffc6645970 } +0xffffc6645970->Object::~Object { 0xaaaad63fe2e0, 0xffffc66458b0, 0xffffc6645970 } +Shifting token 'a' (0xffffc66458b0 'a') +0xaaaad63fe300->Object::Object { 0xaaaad63fe2e0, 0xffffc66458b0 } +0xffffc66458b0->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc66458b0 } Entering state 2 Stack now 0 11 2 -0xfffffa294e00->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300 } +0xffffc6645990->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaacf273300 'a') --> $$ = nterm item (0xfffffa294e00 'a') -0xaaaacf273300->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294e00 } -0xaaaacf273300->Object::Object { 0xaaaacf2732e0, 0xfffffa294e00 } -0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294e00 } + $1 = token 'a' (0xaaaad63fe300 'a') +-> $$ = nterm item (0xffffc6645990 'a') +0xaaaad63fe300->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645990 } +0xaaaad63fe300->Object::Object { 0xaaaad63fe2e0, 0xffffc6645990 } +0xffffc6645990->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645990 } Entering state 11 Stack now 0 11 11 Reading a token -0xfffffa294ce0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300 } -0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294ce0 } -0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294ce0, 0xfffffa294de0 } -Next token is token 'a' (0xfffffa294de0 'a') -0xfffffa294d20->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294de0 } -0xfffffa294de0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294d20, 0xfffffa294de0 } -Shifting token 'a' (0xfffffa294d20 'a') -0xaaaacf273320->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294d20 } -0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294d20 } +0xffffc6645870->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300 } +0xffffc6645970->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645870 } +0xffffc6645870->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645870, 0xffffc6645970 } +Next token is token 'a' (0xffffc6645970 'a') +0xffffc66458b0->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645970 } +0xffffc6645970->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc66458b0, 0xffffc6645970 } +Shifting token 'a' (0xffffc66458b0 'a') +0xaaaad63fe320->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc66458b0 } +0xffffc66458b0->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc66458b0 } Entering state 2 Stack now 0 11 11 2 -0xfffffa294e00->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320 } +0xffffc6645990->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaacf273320 'a') --> $$ = nterm item (0xfffffa294e00 'a') -0xaaaacf273320->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294e00 } -0xaaaacf273320->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294e00 } -0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294e00 } + $1 = token 'a' (0xaaaad63fe320 'a') +-> $$ = nterm item (0xffffc6645990 'a') +0xaaaad63fe320->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645990 } +0xaaaad63fe320->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645990 } +0xffffc6645990->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645990 } Entering state 11 Stack now 0 11 11 11 Reading a token -0xfffffa294ce0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320 } -0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294ce0 } -0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294ce0, 0xfffffa294de0 } -Next token is token 'a' (0xfffffa294de0 'a') -0xfffffa294d20->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294de0 } -0xfffffa294de0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294d20, 0xfffffa294de0 } -Shifting token 'a' (0xfffffa294d20 'a') -0xaaaacf273340->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294d20 } -0xfffffa294d20->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294d20 } +0xffffc6645870->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320 } +0xffffc6645970->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645870 } +0xffffc6645870->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645870, 0xffffc6645970 } +Next token is token 'a' (0xffffc6645970 'a') +0xffffc66458b0->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645970 } +0xffffc6645970->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc66458b0, 0xffffc6645970 } +Shifting token 'a' (0xffffc66458b0 'a') +0xaaaad63fe340->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc66458b0 } +0xffffc66458b0->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc66458b0 } Entering state 2 Stack now 0 11 11 11 2 -0xfffffa294e00->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340 } +0xffffc6645990->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaacf273340 'a') --> $$ = nterm item (0xfffffa294e00 'a') -0xaaaacf273340->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294e00 } -0xaaaacf273340->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294e00 } -0xfffffa294e00->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294e00 } + $1 = token 'a' (0xaaaad63fe340 'a') +-> $$ = nterm item (0xffffc6645990 'a') +0xaaaad63fe340->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc6645990 } +0xaaaad63fe340->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645990 } +0xffffc6645990->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc6645990 } Entering state 11 Stack now 0 11 11 11 11 Reading a token -0xfffffa294ce0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340 } -0xfffffa294de0->Object::Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294ce0 } -0xfffffa294ce0->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294ce0, 0xfffffa294de0 } -Next token is token 'p' (0xfffffa294de0 'p'Exception caught: cleaning lookahead and stack -0xaaaacf273340->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xaaaacf273340, 0xfffffa294de0 } -0xaaaacf273320->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xaaaacf273320, 0xfffffa294de0 } -0xaaaacf273300->Object::~Object { 0xaaaacf2732e0, 0xaaaacf273300, 0xfffffa294de0 } -0xaaaacf2732e0->Object::~Object { 0xaaaacf2732e0, 0xfffffa294de0 } -0xfffffa294de0->Object::~Object { 0xfffffa294de0 } +0xffffc6645870->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340 } +0xffffc6645970->Object::Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc6645870 } +0xffffc6645870->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc6645870, 0xffffc6645970 } +Next token is token 'p' (0xffffc6645970 'p'Exception caught: cleaning lookahead and stack +0xaaaad63fe340->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xaaaad63fe340, 0xffffc6645970 } +0xaaaad63fe320->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xaaaad63fe320, 0xffffc6645970 } +0xaaaad63fe300->Object::~Object { 0xaaaad63fe2e0, 0xaaaad63fe300, 0xffffc6645970 } +0xaaaad63fe2e0->Object::~Object { 0xaaaad63fe2e0, 0xffffc6645970 } +0xffffc6645970->Object::~Object { 0xffffc6645970 } exception caught: printer end { } +stderr: ./c++.at:1362: grep '^exception caught: printer$' stderr +Ambiguity detected. +Option 1, + start -> + 'a' + +Option 2, + start -> + 'a' + +syntax is ambiguous stdout: +725. glr-regression.at:594: ok +./glr-regression.at:738: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr exception caught: printer ./c++.at:1362: $PREPARSER ./input aaaae stderr: exception caught: syntax error ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -737. glr-regression.at:845: testing Duplicated user destructor for lookahead: glr2.cc ... -./glr-regression.at:845: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr7.cc glr-regr7.y -./glr-regression.at:844: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr7 glr-regr7.cc $LIBS +732. glr-regression.at:738: ok +730. glr-regression.at:671: ok ./c++.at:1362: $PREPARSER ./input aaaaE stderr: exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:845: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr7 glr-regr7.cc $LIBS ./c++.at:1362: $PREPARSER ./input aaaaT stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + + ./c++.at:1362: $PREPARSER ./input aaaaR + stderr: ./c++.at:1362: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: +736. glr-regression.at:844: testing Duplicated user destructor for lookahead: glr.cc ... +./glr-regression.at:844: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr7.cc glr-regr7.y 687. c++.at:1362: ok +737. glr-regression.at:845: testing Duplicated user destructor for lookahead: glr2.cc ... +./glr-regression.at:845: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr7.cc glr-regr7.y + +738. glr-regression.at:944: testing Incorrectly initialized location for empty right-hand side in GLR: glr.c ... +./glr-regression.at:944: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr8.c glr-regr8.y +./glr-regression.at:844: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr7 glr-regr7.cc $LIBS +./glr-regression.at:845: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr7 glr-regr7.cc $LIBS +739. glr-regression.at:945: testing Incorrectly initialized location for empty right-hand side in GLR: glr.cc ... +./glr-regression.at:944: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr8 glr-regr8.c $LIBS +./glr-regression.at:945: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr8.cc glr-regr8.y +./glr-regression.at:945: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr8 glr-regr8.cc $LIBS +stderr: +stdout: +stderr: +stdout: +./glr-regression.at:739: $PREPARSER ./glr-regr6 +./glr-regression.at:843: $PREPARSER ./glr-regr7 +stderr: +stderr: +Ambiguity detected. +Option 1, + start -> + 'a' + +Option 2, + start -> + 'a' + +syntax is ambiguous +./glr-regression.at:739: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +memory exhausted +./glr-regression.at:843: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +733. glr-regression.at:739: ok +735. glr-regression.at:843: ok +stderr: +stdout: +./c++.at:858: $PREPARSER ./input +stderr: +./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr + + +======== Testing with C++ standard flags: '' +./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +740. glr-regression.at:946: testing Incorrectly initialized location for empty right-hand side in GLR: glr2.cc ... +./glr-regression.at:946: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr8.cc glr-regr8.y +741. glr-regression.at:1036: testing No users destructors if stack 0 deleted: glr.c ... +./glr-regression.at:1036: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr9.c glr-regr9.y +./glr-regression.at:946: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr8 glr-regr8.cc $LIBS +stderr: +stdout: +./glr-regression.at:598: $PREPARSER ./glr-regr4 +stderr: +./glr-regression.at:598: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./glr-regression.at:1036: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr9 glr-regr9.c $LIBS +728. glr-regression.at:598: ok + +stderr: stdout: ./c++.at:1363: $PREPARSER ./input aaaas stderr: exception caught: reduction ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +742. glr-regression.at:1037: testing No users destructors if stack 0 deleted: glr.cc ... +./glr-regression.at:1037: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr9.cc glr-regr9.y ./c++.at:1363: $PREPARSER ./input aaaal stderr: - +stdout: +stderr: exception caught: yylex ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./glr-regression.at:944: $PREPARSER ./glr-regr8 +stderr: +./glr-regression.at:1037: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr9 glr-regr9.cc $LIBS ./c++.at:1363: $PREPARSER ./input i +./glr-regression.at:944: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: exception caught: initial-action +738. glr-regression.at:944: ok ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -738. glr-regression.at:944: testing Incorrectly initialized location for empty right-hand side in GLR: glr.c ... -./glr-regression.at:944: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr8.c glr-regr8.y ./c++.at:1363: $PREPARSER ./input aaaap stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: + stdout: -./glr-regression.at:598: $PREPARSER ./glr-regr4 +./glr-regression.at:844: $PREPARSER ./glr-regr7 ./c++.at:1363: $PREPARSER ./input --debug aaaap stderr: -./glr-regression.at:598: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xffffeb822140->Object::Object { } -0xffffeb822240->Object::Object { 0xffffeb822140 } -0xffffeb822140->Object::~Object { 0xffffeb822140, 0xffffeb822240 } -Next token is token 'a' (0xffffeb822240 'a') -0xffffeb822180->Object::Object { 0xffffeb822240 } -0xffffeb822240->Object::~Object { 0xffffeb822180, 0xffffeb822240 } -Shifting token 'a' (0xffffeb822180 'a') -0xaaaab82d12e0->Object::Object { 0xffffeb822180 } -0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xffffeb822180 } +0xfffff252f0a0->Object::Object { } +0xfffff252f1a0->Object::Object { 0xfffff252f0a0 } +0xfffff252f0a0->Object::~Object { 0xfffff252f0a0, 0xfffff252f1a0 } +Next token is token 'a' (0xfffff252f1a0 'a') +0xfffff252f0e0->Object::Object { 0xfffff252f1a0 } +0xfffff252f1a0->Object::~Object { 0xfffff252f0e0, 0xfffff252f1a0 } +Shifting token 'a' (0xfffff252f0e0 'a') +0xaaaae38f22e0->Object::Object { 0xfffff252f0e0 } +0xfffff252f0e0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f0e0 } Entering state 1 Stack now 0 1 -0xffffeb822260->Object::Object { 0xaaaab82d12e0 } +0xfffff252f1c0->Object::Object { 0xaaaae38f22e0 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaab82d12e0 'a') --> $$ = nterm item (0xffffeb822260 'a') -0xaaaab82d12e0->Object::~Object { 0xaaaab82d12e0, 0xffffeb822260 } -0xaaaab82d12e0->Object::Object { 0xffffeb822260 } -0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xffffeb822260 } + $1 = token 'a' (0xaaaae38f22e0 'a') +-> $$ = nterm item (0xfffff252f1c0 'a') +0xaaaae38f22e0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f1c0 } +0xaaaae38f22e0->Object::Object { 0xfffff252f1c0 } +0xfffff252f1c0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f1c0 } Entering state 10 Stack now 0 10 Reading a token -0xffffeb822140->Object::Object { 0xaaaab82d12e0 } -0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xffffeb822140 } -0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xffffeb822140, 0xffffeb822240 } -Next token is token 'a' (0xffffeb822240 'a') -0xffffeb822180->Object::Object { 0xaaaab82d12e0, 0xffffeb822240 } -0xffffeb822240->Object::~Object { 0xaaaab82d12e0, 0xffffeb822180, 0xffffeb822240 } -Shifting token 'a' (0xffffeb822180 'a') -0xaaaab82d1300->Object::Object { 0xaaaab82d12e0, 0xffffeb822180 } -0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822180 } +0xfffff252f0a0->Object::Object { 0xaaaae38f22e0 } +0xfffff252f1a0->Object::Object { 0xaaaae38f22e0, 0xfffff252f0a0 } +0xfffff252f0a0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f0a0, 0xfffff252f1a0 } +Next token is token 'a' (0xfffff252f1a0 'a') +0xfffff252f0e0->Object::Object { 0xaaaae38f22e0, 0xfffff252f1a0 } +0xfffff252f1a0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f0e0, 0xfffff252f1a0 } +Shifting token 'a' (0xfffff252f0e0 'a') +0xaaaae38f2300->Object::Object { 0xaaaae38f22e0, 0xfffff252f0e0 } +0xfffff252f0e0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f0e0 } Entering state 1 Stack now 0 10 1 -0xffffeb822260->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300 } +0xfffff252f1c0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaab82d1300 'a') --> $$ = nterm item (0xffffeb822260 'a') -0xaaaab82d1300->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822260 } -0xaaaab82d1300->Object::Object { 0xaaaab82d12e0, 0xffffeb822260 } -0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822260 } + $1 = token 'a' (0xaaaae38f2300 'a') +-> $$ = nterm item (0xfffff252f1c0 'a') +0xaaaae38f2300->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f1c0 } +0xaaaae38f2300->Object::Object { 0xaaaae38f22e0, 0xfffff252f1c0 } +0xfffff252f1c0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f1c0 } Entering state 10 Stack now 0 10 10 Reading a token -0xffffeb822140->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300 } -0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822140 } -0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822140, 0xffffeb822240 } -Next token is token 'a' (0xffffeb822240 'a') -0xffffeb822180->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822240 } -0xffffeb822240->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822180, 0xffffeb822240 } -Shifting token 'a' (0xffffeb822180 'a') -0xaaaab82d1320->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822180 } -0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822180 } +0xfffff252f0a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300 } +0xfffff252f1a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f0a0 } +0xfffff252f0a0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f0a0, 0xfffff252f1a0 } +Next token is token 'a' (0xfffff252f1a0 'a') +0xfffff252f0e0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f1a0 } +0xfffff252f1a0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f0e0, 0xfffff252f1a0 } +Shifting token 'a' (0xfffff252f0e0 'a') +0xaaaae38f2320->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f0e0 } +0xfffff252f0e0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f0e0 } Entering state 1 Stack now 0 10 10 1 -0xffffeb822260->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320 } +0xfffff252f1c0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaab82d1320 'a') --> $$ = nterm item (0xffffeb822260 'a') -0xaaaab82d1320->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822260 } -0xaaaab82d1320->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822260 } -0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822260 } + $1 = token 'a' (0xaaaae38f2320 'a') +-> $$ = nterm item (0xfffff252f1c0 'a') +0xaaaae38f2320->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f1c0 } +0xaaaae38f2320->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f1c0 } +0xfffff252f1c0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f1c0 } Entering state 10 Stack now 0 10 10 10 Reading a token -0xffffeb822140->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320 } -0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822140 } -0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822140, 0xffffeb822240 } -Next token is token 'a' (0xffffeb822240 'a') -0xffffeb822180->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822240 } -0xffffeb822240->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822180, 0xffffeb822240 } -Shifting token 'a' (0xffffeb822180 'a') -0xaaaab82d1340->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822180 } -0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822180 } +0xfffff252f0a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320 } +0xfffff252f1a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f0a0 } +0xfffff252f0a0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f0a0, 0xfffff252f1a0 } +Next token is token 'a' (0xfffff252f1a0 'a') +0xfffff252f0e0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f1a0 } +0xfffff252f1a0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f0e0, 0xfffff252f1a0 } +Shifting token 'a' (0xfffff252f0e0 'a') +0xaaaae38f2340->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f0e0 } +0xfffff252f0e0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f0e0 } Entering state 1 Stack now 0 10 10 10 1 -0xffffeb822260->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340 } +0xfffff252f1c0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaab82d1340 'a') --> $$ = nterm item (0xffffeb822260 'a') -0xaaaab82d1340->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822260 } -0xaaaab82d1340->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822260 } -0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822260 } + $1 = token 'a' (0xaaaae38f2340 'a') +-> $$ = nterm item (0xfffff252f1c0 'a') +0xaaaae38f2340->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f1c0 } +0xaaaae38f2340->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f1c0 } +0xfffff252f1c0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f1c0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token -0xffffeb822140->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340 } -0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822140 } -0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822140, 0xffffeb822240 } -Next token is token 'p' (0xffffeb822240 'p'Exception caught: cleaning lookahead and stack -0xaaaab82d1340->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822240 } -0xaaaab82d1320->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822240 } -0xaaaab82d1300->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822240 } -0xaaaab82d12e0->Object::~Object { 0xaaaab82d12e0, 0xffffeb822240 } -0xffffeb822240->Object::~Object { 0xffffeb822240 } +0xfffff252f0a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340 } +0xfffff252f1a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f0a0 } +0xfffff252f0a0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f0a0, 0xfffff252f1a0 } +Next token is token 'p' (0xfffff252f1a0 'p'Exception caught: cleaning lookahead and stack +0xaaaae38f2340->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f1a0 } +0xaaaae38f2320->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f1a0 } +0xaaaae38f2300->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f1a0 } +0xaaaae38f22e0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f1a0 } +0xfffff252f1a0->Object::~Object { 0xfffff252f1a0 } exception caught: printer end { } -stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:944: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr8 glr-regr8.c $LIBS -728. glr-regression.at:598: ok -stdout: -stderr: -./glr-regression.at:843: $PREPARSER ./glr-regr7 -stderr: memory exhausted +./glr-regression.at:844: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: Starting parse Entering state 0 Stack now 0 Reading a token -0xffffeb822140->Object::Object { } -0xffffeb822240->Object::Object { 0xffffeb822140 } -0xffffeb822140->Object::~Object { 0xffffeb822140, 0xffffeb822240 } -Next token is token 'a' (0xffffeb822240 'a') -0xffffeb822180->Object::Object { 0xffffeb822240 } -0xffffeb822240->Object::~Object { 0xffffeb822180, 0xffffeb822240 } -Shifting token 'a' (0xffffeb822180 'a') -0xaaaab82d12e0->Object::Object { 0xffffeb822180 } -0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xffffeb822180 } +0xfffff252f0a0->Object::Object { } +0xfffff252f1a0->Object::Object { 0xfffff252f0a0 } +0xfffff252f0a0->Object::~Object { 0xfffff252f0a0, 0xfffff252f1a0 } +Next token is token 'a' (0xfffff252f1a0 'a') +0xfffff252f0e0->Object::Object { 0xfffff252f1a0 } +0xfffff252f1a0->Object::~Object { 0xfffff252f0e0, 0xfffff252f1a0 } +Shifting token 'a' (0xfffff252f0e0 'a') +0xaaaae38f22e0->Object::Object { 0xfffff252f0e0 } +0xfffff252f0e0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f0e0 } Entering state 1 Stack now 0 1 -0xffffeb822260->Object::Object { 0xaaaab82d12e0 } +0xfffff252f1c0->Object::Object { 0xaaaae38f22e0 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaab82d12e0 'a') --> $$ = nterm item (0xffffeb822260 'a') -0xaaaab82d12e0->Object::~Object { 0xaaaab82d12e0, 0xffffeb822260 } -0xaaaab82d12e0->Object::Object { 0xffffeb822260 } -0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xffffeb822260 } + $1 = token 'a' (0xaaaae38f22e0 'a') +-> $$ = nterm item (0xfffff252f1c0 'a') +0xaaaae38f22e0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f1c0 } +0xaaaae38f22e0->Object::Object { 0xfffff252f1c0 } +0xfffff252f1c0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f1c0 } Entering state 10 Stack now 0 10 Reading a token -0xffffeb822140->Object::Object { 0xaaaab82d12e0 } -0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xffffeb822140 } -0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xffffeb822140, 0xffffeb822240 } -Next token is token 'a' (0xffffeb822240 'a') -0xffffeb822180->Object::Object { 0xaaaab82d12e0, 0xffffeb822240 } -0xffffeb822240->Object::~Object { 0xaaaab82d12e0, 0xffffeb822180, 0xffffeb822240 } -Shifting token 'a' (0xffffeb822180 'a') -0xaaaab82d1300->Object::Object { 0xaaaab82d12e0, 0xffffeb822180 } -0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822180 } +0xfffff252f0a0->Object::Object { 0xaaaae38f22e0 } +0xfffff252f1a0->Object::Object { 0xaaaae38f22e0, 0xfffff252f0a0 } +0xfffff252f0a0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f0a0, 0xfffff252f1a0 } +Next token is token 'a' (0xfffff252f1a0 'a') +0xfffff252f0e0->Object::Object { 0xaaaae38f22e0, 0xfffff252f1a0 } +0xfffff252f1a0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f0e0, 0xfffff252f1a0 } +Shifting token 'a' (0xfffff252f0e0 'a') +0xaaaae38f2300->Object::Object { 0xaaaae38f22e0, 0xfffff252f0e0 } +0xfffff252f0e0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f0e0 } Entering state 1 Stack now 0 10 1 -0xffffeb822260->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300 } +0xfffff252f1c0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaab82d1300 'a') --> $$ = nterm item (0xffffeb822260 'a') -0xaaaab82d1300->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822260 } -0xaaaab82d1300->Object::Object { 0xaaaab82d12e0, 0xffffeb822260 } -0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822260 } + $1 = token 'a' (0xaaaae38f2300 'a') +-> $$ = nterm item (0xfffff252f1c0 'a') +0xaaaae38f2300->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f1c0 } +0xaaaae38f2300->Object::Object { 0xaaaae38f22e0, 0xfffff252f1c0 } +0xfffff252f1c0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f1c0 } Entering state 10 Stack now 0 10 10 Reading a token -0xffffeb822140->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300 } -0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822140 } -0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822140, 0xffffeb822240 } -Next token is token 'a' (0xffffeb822240 'a') -0xffffeb822180->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822240 } -0xffffeb822240->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822180, 0xffffeb822240 } -Shifting token 'a' (0xffffeb822180 'a') -0xaaaab82d1320->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822180 } -0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822180 } +0xfffff252f0a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300 } +0xfffff252f1a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f0a0 } +0xfffff252f0a0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f0a0, 0xfffff252f1a0 } +Next token is token 'a' (0xfffff252f1a0 'a') +0xfffff252f0e0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f1a0 } +0xfffff252f1a0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f0e0, 0xfffff252f1a0 } +Shifting token 'a' (0xfffff252f0e0 'a') +0xaaaae38f2320->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f0e0 } +0xfffff252f0e0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f0e0 } Entering state 1 Stack now 0 10 10 1 -0xffffeb822260->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320 } +0xfffff252f1c0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaab82d1320 'a') --> $$ = nterm item (0xffffeb822260 'a') -0xaaaab82d1320->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822260 } -0xaaaab82d1320->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822260 } -0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822260 } + $1 = token 'a' (0xaaaae38f2320 'a') +-> $$ = nterm item (0xfffff252f1c0 'a') +0xaaaae38f2320->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f1c0 } +0xaaaae38f2320->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f1c0 } +0xfffff252f1c0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f1c0 } Entering state 10 Stack now 0 10 10 10 Reading a token -0xffffeb822140->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320 } -0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822140 } -0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822140, 0xffffeb822240 } -Next token is token 'a' (0xffffeb822240 'a') -0xffffeb822180->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822240 } -0xffffeb822240->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822180, 0xffffeb822240 } -Shifting token 'a' (0xffffeb822180 'a') -0xaaaab82d1340->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822180 } -0xffffeb822180->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822180 } +0xfffff252f0a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320 } +0xfffff252f1a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f0a0 } +0xfffff252f0a0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f0a0, 0xfffff252f1a0 } +Next token is token 'a' (0xfffff252f1a0 'a') +0xfffff252f0e0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f1a0 } +0xfffff252f1a0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f0e0, 0xfffff252f1a0 } +Shifting token 'a' (0xfffff252f0e0 'a') +0xaaaae38f2340->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f0e0 } +0xfffff252f0e0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f0e0 } Entering state 1 Stack now 0 10 10 10 1 -0xffffeb822260->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340 } +0xfffff252f1c0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340 } Reducing stack by rule 4 (line 142): - $1 = token 'a' (0xaaaab82d1340 'a') --> $$ = nterm item (0xffffeb822260 'a') -0xaaaab82d1340->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822260 } -0xaaaab82d1340->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822260 } -0xffffeb822260->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822260 } + $1 = token 'a' (0xaaaae38f2340 'a') +-> $$ = nterm item (0xfffff252f1c0 'a') +0xaaaae38f2340->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f1c0 } +0xaaaae38f2340->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f1c0 } +0xfffff252f1c0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f1c0 } Entering state 10 Stack now 0 10 10 10 10 Reading a token -0xffffeb822140->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340 } -0xffffeb822240->Object::Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822140 } -0xffffeb822140->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822140, 0xffffeb822240 } -Next token is token 'p' (0xffffeb822240 'p'Exception caught: cleaning lookahead and stack -0xaaaab82d1340->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xaaaab82d1340, 0xffffeb822240 } -0xaaaab82d1320->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xaaaab82d1320, 0xffffeb822240 } -0xaaaab82d1300->Object::~Object { 0xaaaab82d12e0, 0xaaaab82d1300, 0xffffeb822240 } -0xaaaab82d12e0->Object::~Object { 0xaaaab82d12e0, 0xffffeb822240 } -0xffffeb822240->Object::~Object { 0xffffeb822240 } +0xfffff252f0a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340 } +0xfffff252f1a0->Object::Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f0a0 } +0xfffff252f0a0->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f0a0, 0xfffff252f1a0 } +Next token is token 'p' (0xfffff252f1a0 'p'Exception caught: cleaning lookahead and stack +0xaaaae38f2340->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xaaaae38f2340, 0xfffff252f1a0 } +0xaaaae38f2320->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xaaaae38f2320, 0xfffff252f1a0 } +0xaaaae38f2300->Object::~Object { 0xaaaae38f22e0, 0xaaaae38f2300, 0xfffff252f1a0 } +0xaaaae38f22e0->Object::~Object { 0xaaaae38f22e0, 0xfffff252f1a0 } +0xfffff252f1a0->Object::~Object { 0xfffff252f1a0 } exception caught: printer end { } -./glr-regression.at:843: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: grep '^exception caught: printer$' stderr +736. glr-regression.at:844: ok stdout: exception caught: printer ./c++.at:1363: $PREPARSER ./input aaaae stderr: -735. glr-regression.at:843: ok exception caught: syntax error ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +743. glr-regression.at:1038: testing No users destructors if stack 0 deleted: glr2.cc ... +./glr-regression.at:1038: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr9.cc glr-regr9.y ./c++.at:1363: $PREPARSER ./input aaaaE stderr: - exception caught: syntax error, unexpected end of file, expecting 'a' ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:1363: $PREPARSER ./input aaaaT stderr: -stderr: stdout: -./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:739: $PREPARSER ./glr-regr6 +./glr-regression.at:672: $PREPARSER ./glr-regr5 stderr: Ambiguity detected. Option 1, @@ -270651,147 +270724,56 @@ 'a' syntax is ambiguous -./glr-regression.at:739: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1363: $PREPARSER ./input aaaaR -733. glr-regression.at:739: ok +./glr-regression.at:672: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: ./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -739. glr-regression.at:945: testing Incorrectly initialized location for empty right-hand side in GLR: glr.cc ... -740. glr-regression.at:946: testing Incorrectly initialized location for empty right-hand side in GLR: glr2.cc ... -./glr-regression.at:946: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr8.cc glr-regr8.y -688. c++.at:1363: ok -./glr-regression.at:945: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr8.cc glr-regr8.y -./glr-regression.at:946: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr8 glr-regr8.cc $LIBS - -./glr-regression.at:945: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr8 glr-regr8.cc $LIBS - -741. glr-regression.at:1036: testing No users destructors if stack 0 deleted: glr.c ... -stderr: -./glr-regression.at:1036: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr9.c glr-regr9.y -stdout: -./c++.at:858: $PREPARSER ./input -stderr: -./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -742. glr-regression.at:1037: testing No users destructors if stack 0 deleted: glr.cc ... -======== Testing with C++ standard flags: '' -stderr: -./glr-regression.at:1037: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr9.cc glr-regr9.y -./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stdout: -./glr-regression.at:594: $PREPARSER ./glr-regr4 -stderr: -./glr-regression.at:1036: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr9 glr-regr9.c $LIBS -./glr-regression.at:594: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:1037: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr9 glr-regr9.cc $LIBS -725. glr-regression.at:594: ok - -743. glr-regression.at:1038: testing No users destructors if stack 0 deleted: glr2.cc ... -./glr-regression.at:1038: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr9.cc glr-regr9.y ./glr-regression.at:1038: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr9 glr-regr9.cc $LIBS +./c++.at:1363: $PREPARSER ./input aaaaR stderr: -stdout: -./glr-regression.at:944: $PREPARSER ./glr-regr8 -stderr: -./glr-regression.at:944: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -738. glr-regression.at:944: ok - +731. glr-regression.at:672: ok +./c++.at:1363: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +688. c++.at:1363: ok 744. glr-regression.at:1102: testing Corrupted semantic options if user action cuts parse: glr.c ... ./glr-regression.at:1102: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr10.c glr-regr10.y -stderr: -stdout: -./glr-regression.at:844: $PREPARSER ./glr-regr7 -stderr: -memory exhausted -./glr-regression.at:1102: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr10 glr-regr10.c $LIBS -./glr-regression.at:844: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -736. glr-regression.at:844: ok - -stderr: -stdout: -./glr-regression.at:672: $PREPARSER ./glr-regr5 -stderr: -Ambiguity detected. -Option 1, - start -> - 'a' -Option 2, - start -> - 'a' -syntax is ambiguous -./glr-regression.at:672: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./glr-regression.at:1102: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr10 glr-regr10.c $LIBS 745. glr-regression.at:1103: testing Corrupted semantic options if user action cuts parse: glr.cc ... ./glr-regression.at:1103: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr10.cc glr-regr10.y -731. glr-regression.at:672: ok -./glr-regression.at:1103: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr10 glr-regr10.cc $LIBS +746. glr-regression.at:1104: testing Corrupted semantic options if user action cuts parse: glr2.cc ... +./glr-regression.at:1104: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr10.cc glr-regr10.y stderr: stdout: ./glr-regression.at:1036: $PREPARSER ./glr-regr9 stderr: +./glr-regression.at:1103: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr10 glr-regr10.cc $LIBS memory exhausted ./glr-regression.at:1036: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - +./glr-regression.at:1104: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr10 glr-regr10.cc $LIBS 741. glr-regression.at:1036: ok + stderr: stdout: -./c++.at:1066: $PREPARSER ./input < in -stderr: -error: invalid expression -caught error -error: invalid character -caught error -./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1066: $PREPARSER ./input < in -stderr: -746. glr-regression.at:1104: testing Corrupted semantic options if user action cuts parse: glr2.cc ... -error: invalid expression -./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:1066: $PREPARSER ./input < in +./glr-regression.at:945: $PREPARSER ./glr-regr8 stderr: -error: invalid character -./glr-regression.at:1104: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr10.cc glr-regr10.y -./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -684. c++.at:1066: ok - -./glr-regression.at:1104: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr10 glr-regr10.cc $LIBS - +./glr-regression.at:945: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -stdout: 747. glr-regression.at:1174: testing Undesirable destructors if user action cuts parse: glr.c ... ./glr-regression.at:1174: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr11.c glr-regr11.y +stdout: +./glr-regression.at:1174: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr11 glr-regr11.c $LIBS +739. glr-regression.at:945: ok ./c++.at:858: $PREPARSER ./input stderr: ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -748. glr-regression.at:1175: testing Undesirable destructors if user action cuts parse: glr.cc ... -./glr-regression.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr11.cc glr-regr11.y ======== Testing with C++ standard flags: '' + ./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +748. glr-regression.at:1175: testing Undesirable destructors if user action cuts parse: glr.cc ... +./glr-regression.at:1175: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr11.cc glr-regr11.y stderr: -./glr-regression.at:1174: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr11 glr-regr11.c $LIBS ./glr-regression.at:1175: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr11 glr-regr11.cc $LIBS stdout: -./glr-regression.at:945: $PREPARSER ./glr-regr8 -stderr: -stderr: -stderr: -stdout: -stdout: -./glr-regression.at:945: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:1102: $PREPARSER ./glr-regr10 -./glr-regression.at:1037: $PREPARSER ./glr-regr9 -739. glr-regression.at:945: ok -stderr: -stderr: -memory exhausted -./glr-regression.at:1037: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:1102: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: - -742. glr-regression.at:1037: ok -stdout: -744. glr-regression.at:1102: ok - ./glr-regression.at:740: $PREPARSER ./glr-regr6 stderr: Ambiguity detected. @@ -270805,138 +270787,189 @@ syntax is ambiguous ./glr-regression.at:740: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +734. glr-regression.at:740: ok + +stderr: +stdout: +./glr-regression.at:1037: $PREPARSER ./glr-regr9 +stderr: +memory exhausted +./glr-regression.at:1037: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +742. glr-regression.at:1037: ok 749. glr-regression.at:1176: testing Undesirable destructors if user action cuts parse: glr2.cc ... ./glr-regression.at:1176: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr11.cc glr-regr11.y +stderr: +stdout: -734. glr-regression.at:740: ok +./glr-regression.at:1102: $PREPARSER ./glr-regr10 +stderr: +./glr-regression.at:1102: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +744. glr-regression.at:1102: ok +./glr-regression.at:1176: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr11 glr-regr11.cc $LIBS 750. glr-regression.at:1310: testing Leaked semantic values if user action cuts parse: glr.c ... ./glr-regression.at:1310: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr12.c glr-regr12.y + ./glr-regression.at:1310: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr12 glr-regr12.c $LIBS +stderr: +stdout: 751. glr-regression.at:1311: testing Leaked semantic values if user action cuts parse: glr.cc ... ./glr-regression.at:1311: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr12.cc glr-regr12.y -./glr-regression.at:1176: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr11 glr-regr11.cc $LIBS - -./glr-regression.at:1311: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr12 glr-regr12.cc $LIBS -752. glr-regression.at:1312: testing Leaked semantic values if user action cuts parse: glr2.cc ... -./glr-regression.at:1312: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr12.cc glr-regr12.y -./glr-regression.at:1312: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr12 glr-regr12.cc $LIBS +./glr-regression.at:845: $PREPARSER ./glr-regr7 +stderr: +memory exhausted +./glr-regression.at:845: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: stdout: ./glr-regression.at:1174: $PREPARSER ./glr-regr11 +737. glr-regression.at:845: ok stderr: ./glr-regression.at:1174: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./glr-regression.at:1311: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr12 glr-regr12.cc $LIBS 747. glr-regression.at:1174: ok + +752. glr-regression.at:1312: testing Leaked semantic values if user action cuts parse: glr2.cc ... +./glr-regression.at:1312: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr12.cc glr-regr12.y +753. glr-regression.at:1445: testing Incorrect lookahead during deterministic GLR: glr.c ... +./glr-regression.at:1445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr13.c glr-regr13.y stderr: stdout: +./c++.at:858: $PREPARSER ./input +./glr-regression.at:1312: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr12 glr-regr12.cc $LIBS stderr: -stdout: -./glr-regression.at:845: $PREPARSER ./glr-regr7 -./glr-regression.at:1103: $PREPARSER ./glr-regr10 -stderr: +./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: -memory exhausted -./glr-regression.at:845: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -753. glr-regression.at:1445: testing Incorrect lookahead during deterministic GLR: glr.c ... +./glr-regression.at:1445: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr13 glr-regr13.c $LIBS stdout: -./glr-regression.at:1310: $PREPARSER ./glr-regr12 -stderr: -./glr-regression.at:1445: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr13.c glr-regr13.y +./glr-regression.at:1103: $PREPARSER ./glr-regr10 stderr: -./glr-regression.at:1310: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -737. glr-regression.at:845: ok +======== Testing with C++ standard flags: '' ./glr-regression.at:1103: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 745. glr-regression.at:1103: ok +./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -750. glr-regression.at:1310: ok -./glr-regression.at:1445: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr13 glr-regr13.c $LIBS - - +stderr: +stdout: +./c++.at:1066: $PREPARSER ./input < in 754. glr-regression.at:1446: testing Incorrect lookahead during deterministic GLR: glr.cc ... ./glr-regression.at:1446: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr13.cc glr-regr13.y -756. glr-regression.at:1678: testing Incorrect lookahead during nondeterministic GLR: glr.c ... -./glr-regression.at:1678: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr14.c glr-regr14.y -755. glr-regression.at:1447: testing Incorrect lookahead during deterministic GLR: glr2.cc ... -./glr-regression.at:1447: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr13.cc glr-regr13.y +stderr: +error: invalid expression +caught error +error: invalid character +caught error +./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1066: $PREPARSER ./input < in ./glr-regression.at:1446: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr13 glr-regr13.cc $LIBS -./glr-regression.at:1678: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr14 glr-regr14.c $LIBS -./glr-regression.at:1447: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr13 glr-regr13.cc $LIBS +stderr: +error: invalid expression +./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:1066: $PREPARSER ./input < in stderr: stdout: -./glr-regression.at:1175: $PREPARSER ./glr-regr11 +./glr-regression.at:1310: $PREPARSER ./glr-regr12 stderr: -./glr-regression.at:1175: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -748. glr-regression.at:1175: ok - -757. glr-regression.at:1679: testing Incorrect lookahead during nondeterministic GLR: glr.cc ... -./glr-regression.at:1679: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr14.cc glr-regr14.y -./glr-regression.at:1679: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr14 glr-regr14.cc $LIBS +error: invalid character +./c++.at:1066: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr stderr: +./glr-regression.at:1310: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +750. glr-regression.at:1310: ok +684. c++.at:1066: ok +stderr: + stdout: -./glr-regression.at:1311: $PREPARSER ./glr-regr12 +./glr-regression.at:1175: $PREPARSER ./glr-regr11 stderr: -./glr-regression.at:1311: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -751. glr-regression.at:1311: ok +./glr-regression.at:1175: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +748. glr-regression.at:1175: ok +755. glr-regression.at:1447: testing Incorrect lookahead during deterministic GLR: glr2.cc ... +./glr-regression.at:1447: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr13.cc glr-regr13.y stderr: stdout: ./glr-regression.at:946: $PREPARSER ./glr-regr8 + stderr: +756. glr-regression.at:1678: testing Incorrect lookahead during nondeterministic GLR: glr.c ... +./glr-regression.at:1678: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr14.c glr-regr14.y ./glr-regression.at:946: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./glr-regression.at:1447: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr13 glr-regr13.cc $LIBS +740. glr-regression.at:946: ok +757. glr-regression.at:1679: testing Incorrect lookahead during nondeterministic GLR: glr.cc ... +./glr-regression.at:1679: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr14.cc glr-regr14.y +./glr-regression.at:1678: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr14 glr-regr14.c $LIBS + +./glr-regression.at:1679: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr14 glr-regr14.cc $LIBS +758. glr-regression.at:1680: testing Incorrect lookahead during nondeterministic GLR: glr2.cc ... +./glr-regression.at:1680: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr14.cc glr-regr14.y stderr: stdout: ./glr-regression.at:1445: $PREPARSER ./glr-regr13 -758. glr-regression.at:1680: testing Incorrect lookahead during nondeterministic GLR: glr2.cc ... -./glr-regression.at:1680: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr14.cc glr-regr14.y stderr: -740. glr-regression.at:946: ok ./glr-regression.at:1445: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:1680: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr14 glr-regr14.cc $LIBS 753. glr-regression.at:1445: ok + stderr: stdout: - +759. glr-regression.at:1785: testing Leaked semantic values when reporting ambiguity: glr.c ... +./glr-regression.at:1785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr15.c glr-regr15.y +./glr-regression.at:1311: $PREPARSER ./glr-regr12 +stderr: +stderr: +stdout: +./glr-regression.at:1311: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:858: $PREPARSER ./input stderr: +751. glr-regression.at:1311: ok ./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./c++.at:859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy - -759. glr-regression.at:1785: testing Leaked semantic values when reporting ambiguity: glr.c ... -./glr-regression.at:1785: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr15.c glr-regr15.y +./glr-regression.at:1785: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr15 glr-regr15.c $LIBS ======== Testing with C++ standard flags: '' -./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS + 760. glr-regression.at:1786: testing Leaked semantic values when reporting ambiguity: glr.cc ... ./glr-regression.at:1786: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr15.cc glr-regr15.y -./glr-regression.at:1785: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr15 glr-regr15.c $LIBS +./glr-regression.at:1786: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr15 glr-regr15.cc $LIBS stderr: +stderr: +stdout: stdout: +./glr-regression.at:1104: $PREPARSER ./glr-regr10 ./glr-regression.at:1038: $PREPARSER ./glr-regr9 stderr: +./glr-regression.at:1104: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: memory exhausted ./glr-regression.at:1038: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:1786: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr15 glr-regr15.cc $LIBS +746. glr-regression.at:1104: ok 743. glr-regression.at:1038: ok -761. glr-regression.at:1787: testing Leaked semantic values when reporting ambiguity: glr2.cc ... -stderr: -stdout: -./glr-regression.at:1787: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr15.cc glr-regr15.y -./glr-regression.at:1678: $PREPARSER ./glr-regr14 -stderr: -./glr-regression.at:1678: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -756. glr-regression.at:1678: ok -./glr-regression.at:1787: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr15 glr-regr15.cc $LIBS +761. glr-regression.at:1787: testing Leaked semantic values when reporting ambiguity: glr2.cc ... 762. glr-regression.at:1860: testing Leaked lookahead after nondeterministic parse syntax error: glr.c ... ./glr-regression.at:1860: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr16.c glr-regr16.y +./glr-regression.at:1787: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr15.cc glr-regr15.y +./glr-regression.at:1860: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr16 glr-regr16.c $LIBS +./glr-regression.at:1787: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr15 glr-regr15.cc $LIBS stderr: stdout: ./glr-regression.at:1446: $PREPARSER ./glr-regr13 -./glr-regression.at:1860: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr16 glr-regr16.c $LIBS stderr: +stdout: +stderr: +./glr-regression.at:1678: $PREPARSER ./glr-regr14 ./glr-regression.at:1446: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +./glr-regression.at:1678: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 754. glr-regression.at:1446: ok +756. glr-regression.at:1678: ok + +763. glr-regression.at:1861: testing Leaked lookahead after nondeterministic parse syntax error: glr.cc ... +./glr-regression.at:1861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr16.cc glr-regr16.y +764. glr-regression.at:1862: testing Leaked lookahead after nondeterministic parse syntax error: glr2.cc ... +./glr-regression.at:1862: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr16.cc glr-regr16.y +./glr-regression.at:1861: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr16 glr-regr16.cc $LIBS stderr: stdout: ./glr-regression.at:1785: $PREPARSER ./glr-regr15 @@ -270952,61 +270985,43 @@ syntax is ambiguous ./glr-regression.at:1785: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -759. glr-regression.at:1785: ok -763. glr-regression.at:1861: testing Leaked lookahead after nondeterministic parse syntax error: glr.cc ... -./glr-regression.at:1861: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr16.cc glr-regr16.y -stderr: -stdout: -./c++.at:859: $PREPARSER ./input -stderr: -./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS - -./glr-regression.at:1861: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr16 glr-regr16.cc $LIBS -764. glr-regression.at:1862: testing Leaked lookahead after nondeterministic parse syntax error: glr2.cc ... -./glr-regression.at:1862: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr16.cc glr-regr16.y stderr: +759. glr-regression.at:1785: ok stdout: +./glr-regression.at:1862: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr16 glr-regr16.cc $LIBS ./glr-regression.at:1176: $PREPARSER ./glr-regr11 stderr: ./glr-regression.at:1176: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 749. glr-regression.at:1176: ok -./glr-regression.at:1862: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr16 glr-regr16.cc $LIBS -stderr: -stdout: -./glr-regression.at:1312: $PREPARSER ./glr-regr12 -stderr: -./glr-regression.at:1312: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -stderr: -stdout: -752. glr-regression.at:1312: ok -./glr-regression.at:1104: $PREPARSER ./glr-regr10 -stderr: -./glr-regression.at:1104: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -746. glr-regression.at:1104: ok 765. glr-regression.at:1964: testing Uninitialized location when reporting ambiguity: glr.c api.pure ... ./glr-regression.at:1964: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr17.c glr-regr17.y -stderr: 766. glr-regression.at:1965: testing Uninitialized location when reporting ambiguity: glr.cc ... ./glr-regression.at:1965: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr17.cc glr-regr17.y -stdout: -./glr-regression.at:1679: $PREPARSER ./glr-regr14 -stderr: - +./glr-regression.at:1964: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr17 glr-regr17.c $LIBS +./glr-regression.at:1965: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr17 glr-regr17.cc $LIBS stderr: stdout: ./glr-regression.at:1860: $PREPARSER ./glr-regr16 stderr: syntax error ./glr-regression.at:1860: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +stderr: +stderr: +stdout: +762. glr-regression.at:1860: ok +./c++.at:858: $PREPARSER ./input +stdout: +./glr-regression.at:1679: $PREPARSER ./glr-regr14 +stderr: +stderr: +./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:858: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./glr-regression.at:1679: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:1964: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o glr-regr17 glr-regr17.c $LIBS -./glr-regression.at:1965: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o glr-regr17 glr-regr17.cc $LIBS 757. glr-regression.at:1679: ok -762. glr-regression.at:1860: ok + 767. glr-regression.at:1966: testing Uninitialized location when reporting ambiguity: glr2.cc ... ./glr-regression.at:1966: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -rall -o glr-regr17.cc glr-regr17.y @@ -271025,51 +271040,41 @@ syntax is ambiguous ./glr-regression.at:1786: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr - 768. glr-regression.at:2035: testing Missed %merge type warnings when LHS type is declared later: glr.c ... -./glr-regression.at:1966: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr17 glr-regr17.cc $LIBS ./glr-regression.at:2035: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o glr-regr18.c -rall -fcaret glr-regr18.y -760. glr-regression.at:1786: ok 768. glr-regression.at:2035: ok -769. glr-regression.at:2036: testing Missed %merge type warnings when LHS type is declared later: glr.cc ... -./glr-regression.at:2036: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o glr-regr18.c -rall -fcaret glr-regr18.y +./glr-regression.at:1966: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o glr-regr17 glr-regr17.cc $LIBS +760. glr-regression.at:1786: ok -769. glr-regression.at:2036: ok +stderr: +stdout: +./glr-regression.at:1312: $PREPARSER ./glr-regr12 +stderr: +./glr-regression.at:1312: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr 770. glr-regression.at:2037: testing Missed %merge type warnings when LHS type is declared later: glr2.cc ... ./glr-regression.at:2037: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o glr-regr18.c -rall -fcaret glr-regr18.y +752. glr-regression.at:1312: ok +769. glr-regression.at:2036: testing Missed %merge type warnings when LHS type is declared later: glr.cc ... +./glr-regression.at:2036: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; VALGRIND_OPTS="$VALGRIND_OPTS --leak-check=summary --show-reachable=no"; export VALGRIND_OPTS; bison --color=no -fno-caret -o glr-regr18.c -rall -fcaret glr-regr18.y 770. glr-regression.at:2037: ok +769. glr-regression.at:2036: ok + + 771. glr-regression.at:2149: testing Ambiguity reports: glr.c ... ./glr-regression.at:2149: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y - -./glr-regression.at:2149: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS -773. glr-regression.at:2151: testing Ambiguity reports: glr2.cc ... -./glr-regression.at:2151: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 772. glr-regression.at:2150: testing Ambiguity reports: glr.cc ... ./glr-regression.at:2150: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -stderr: -stdout: -./c++.at:859: $PREPARSER ./input -./glr-regression.at:2151: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +773. glr-regression.at:2151: testing Ambiguity reports: glr2.cc ... +./glr-regression.at:2151: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y +./glr-regression.at:2149: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS ./glr-regression.at:2150: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -======== Testing with C++ standard flags: '' -./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS -stderr: -stdout: -./glr-regression.at:1861: $PREPARSER ./glr-regr16 -stderr: -syntax error -./glr-regression.at:1861: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -763. glr-regression.at:1861: ok - +./glr-regression.at:2151: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./glr-regression.at:1964: $PREPARSER ./glr-regr17 stderr: -774. glr-regression.at:2229: testing Predicates: glr.c ... Ambiguity detected. Option 1, start -> @@ -271091,14 +271096,22 @@ 1.1-2.2: syntax is ambiguous ./glr-regression.at:1964: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:2229: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y 765. glr-regression.at:1964: ok + +774. glr-regression.at:2229: testing Predicates: glr.c ... +./glr-regression.at:2229: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.c input.y ./glr-regression.at:2229: $CC $CFLAGS $CPPFLAGS $LDFLAGS -o input input.c $LIBS +stderr: +stdout: +./glr-regression.at:1861: $PREPARSER ./glr-regr16 +stderr: +syntax error +./glr-regression.at:1861: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +763. glr-regression.at:1861: ok stderr: stdout: ./glr-regression.at:2149: $PREPARSER ./input --debug -775. glr-regression.at:2230: testing Predicates: glr.cc ... stderr: Starting parse Entering state 0 @@ -271160,28 +271173,23 @@ Cleanup: popping nterm b () Cleanup: popping token 'a' () ./glr-regression.at:2149: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -./glr-regression.at:2230: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y 771. glr-regression.at:2149: ok -stderr: -stdout: -./glr-regression.at:1447: $PREPARSER ./glr-regr13 -stderr: -./glr-regression.at:1447: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +775. glr-regression.at:2230: testing Predicates: glr.cc ... +./glr-regression.at:2230: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -755. glr-regression.at:1447: ok ./glr-regression.at:2230: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS 776. glr-regression.at:2231: testing Predicates: glr2.cc ... ./glr-regression.at:2231: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.y -./glr-regression.at:2231: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: ./glr-regression.at:1680: $PREPARSER ./glr-regr14 stderr: ./glr-regression.at:1680: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./glr-regression.at:2231: $CXX $CPPFLAGS $CXX11_CXXFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +758. glr-regression.at:1680: ok stderr: stdout: ./glr-regression.at:1965: $PREPARSER ./glr-regr17 -758. glr-regression.at:1680: ok stderr: Ambiguity detected. Option 1, @@ -271207,38 +271215,29 @@ 766. glr-regression.at:1965: ok stderr: stdout: -./c++.at:859: $PREPARSER ./input +./glr-regression.at:2229: $PREPARSER ./input Nwin stderr: -./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -======== Testing with C++ standard flags: '' -./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: -./glr-regression.at:2229: $PREPARSER ./input Nwin +./c++.at:858: $PREPARSER ./input stderr: ./glr-regression.at:2229: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:858: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2229: $PREPARSER ./input Owin stderr: -stderr: -stdout: syntax error, unexpected 'n', expecting 'o' -./glr-regression.at:1787: $PREPARSER ./glr-regr15 ./glr-regression.at:2229: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +./c++.at:859: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy +stderr: +stdout: +./glr-regression.at:1447: $PREPARSER ./glr-regr13 stderr: -Ambiguity detected. -Option 1, - ambiguity -> - ambiguity1 -> - -Option 2, - ambiguity -> - ambiguity2 -> - -syntax is ambiguous -./glr-regression.at:1787: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -761. glr-regression.at:1787: ok ./glr-regression.at:2229: $PREPARSER ./input Owio stderr: +./glr-regression.at:1447: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +755. glr-regression.at:1447: ok +./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS ./glr-regression.at:2229: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./glr-regression.at:2229: $PREPARSER ./input Nwio stderr: @@ -271312,6 +271311,29 @@ 772. glr-regression.at:2150: ok stderr: stdout: +./glr-regression.at:1787: $PREPARSER ./glr-regr15 +stderr: +Ambiguity detected. +Option 1, + ambiguity -> + ambiguity1 -> + +Option 2, + ambiguity -> + ambiguity2 -> + +syntax is ambiguous +./glr-regression.at:1787: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +761. glr-regression.at:1787: ok +stderr: +stdout: +./glr-regression.at:1862: $PREPARSER ./glr-regr16 +stderr: +syntax error +./glr-regression.at:1862: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +764. glr-regression.at:1862: ok +stderr: +stdout: ./glr-regression.at:2230: $PREPARSER ./input Nwin stderr: ./glr-regression.at:2230: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr @@ -271336,13 +271358,6 @@ ./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS stderr: stdout: -./glr-regression.at:1862: $PREPARSER ./glr-regr16 -stderr: -syntax error -./glr-regression.at:1862: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr -764. glr-regression.at:1862: ok -stderr: -stdout: ./glr-regression.at:1966: $PREPARSER ./glr-regr17 stderr: Ambiguity detected. @@ -271475,6 +271490,27 @@ ./c++.at:859: $PREPARSER ./input stderr: ./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stderr: +stdout: +./c++.at:859: $PREPARSER ./input +stderr: +./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stderr: +stdout: +./c++.at:859: $PREPARSER ./input +stderr: +./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr +======== Testing with C++ standard flags: '' +./c++.at:859: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS +stderr: +stdout: +./c++.at:859: $PREPARSER ./input +stderr: +./c++.at:859: sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr ./c++.at:860: COLUMNS=1000; export COLUMNS; NO_TERM_HYPERLINKS=1; export NO_TERM_HYPERLINKS; bison --color=no -fno-caret -o input.cc input.yy ======== Testing with C++ standard flags: '' ./c++.at:860: $CXX $CPPFLAGS $CXXFLAGS $LDFLAGS -o input input.cc $LIBS @@ -271718,70 +271754,70 @@ /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/lib/aarch64-linux-gnu' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin' /usr/bin/install -c -m 644 lib/liby.a '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/lib/aarch64-linux-gnu' + /usr/bin/install -c src/bison '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/aclocal' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++/calc++' - /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++' /usr/bin/install -c src/yacc '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin' - /usr/bin/install -c -m 644 m4/bison-i18n.m4 '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/aclocal' - /usr/bin/install -c src/bison '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/bin' + /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++' ( cd '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/lib/aarch64-linux-gnu' && ranlib liby.a ) - /usr/bin/install -c -m 644 examples/c++/calc++/driver.cc examples/c++/calc++/driver.hh examples/c++/calc++/scanner.ll examples/c++/calc++/calc++.cc examples/c++/calc++/parser.yy '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++/calc++' + /usr/bin/install -c -m 644 m4/bison-i18n.m4 '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/aclocal' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/bistromathic' + /usr/bin/install -c -m 644 examples/c++/simple.yy '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++' + /usr/bin/install -c -m 644 examples/c++/calc++/driver.cc examples/c++/calc++/driver.hh examples/c++/calc++/scanner.ll examples/c++/calc++/calc++.cc examples/c++/calc++/parser.yy '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++/calc++' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/calc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d/calc' - /usr/bin/install -c -m 644 examples/c/bistromathic/parse.y examples/c/bistromathic/Makefile examples/c/bistromathic/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/bistromathic' - /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++/calc++' - /usr/bin/install -c -m 644 examples/c++/simple.yy '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++' /usr/bin/install -c -m 644 examples/c/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c' - /usr/bin/install -c -m 644 examples/d/calc/calc.y examples/d/calc/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d/calc' - /usr/bin/install -c -m 644 examples/c/calc/calc.y examples/c/calc/Makefile examples/c/calc/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/calc' + /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++/calc++' + /usr/bin/install -c -m 644 examples/c/bistromathic/parse.y examples/c/bistromathic/Makefile examples/c/bistromathic/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/bistromathic' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++' - /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d' + /usr/bin/install -c -m 644 examples/c/calc/calc.y examples/c/calc/Makefile examples/c/calc/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/calc' /usr/bin/install -c -m 644 examples/c++/README.md examples/c++/Makefile examples/c++/variant.yy examples/c++/variant-11.yy '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++' + /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d' + /usr/bin/install -c -m 644 examples/c++/calc++/README.md examples/c++/calc++/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++/calc++' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison' + /usr/bin/install -c -m 644 examples/d/calc/calc.y examples/d/calc/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d/calc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples' - /usr/bin/install -c -m 644 examples/c++/calc++/README.md examples/c++/calc++/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c++/calc++' - /usr/bin/install -c -m 644 examples/d/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/glr' - /usr/bin/install -c -m 644 AUTHORS COPYING NEWS README THANKS TODO '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison' + /usr/bin/install -c -m 644 examples/d/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java' /usr/bin/install -c -m 644 examples/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java/calc' + /usr/bin/install -c -m 644 AUTHORS COPYING NEWS README THANKS TODO '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison' + /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java/simple' /usr/bin/install -c -m 644 examples/c/glr/c++-types.y examples/c/glr/Makefile examples/c/glr/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/glr' /usr/bin/install -c -m 644 examples/java/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java' - /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java/simple' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/lexcalc' - /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/m4sugar' /usr/bin/install -c -m 644 examples/java/calc/Calc.y examples/java/calc/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java/calc' - /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/mfcalc' - /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison' /usr/bin/install -c -m 644 examples/java/simple/Calc.y examples/java/simple/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/java/simple' /usr/bin/install -c -m 644 examples/c/lexcalc/parse.y examples/c/lexcalc/scan.l examples/c/lexcalc/Makefile examples/c/lexcalc/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/lexcalc' - /usr/bin/install -c -m 644 examples/c/mfcalc/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/mfcalc' - /usr/bin/install -c -m 644 data/README.md data/bison-default.css '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison' + /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/m4sugar' + /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/mfcalc' + /usr/bin/install -c -m 644 data/m4sugar/foreach.m4 data/m4sugar/m4sugar.m4 '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/m4sugar' + /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/pushcalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/reccalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/rpcalc' + /usr/bin/install -c -m 644 examples/c/mfcalc/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/mfcalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d/simple' - /usr/bin/install -c -m 644 data/m4sugar/foreach.m4 data/m4sugar/m4sugar.m4 '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/m4sugar' /usr/bin/install -c -m 644 examples/c/pushcalc/calc.y examples/c/pushcalc/Makefile examples/c/pushcalc/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/pushcalc' - /usr/bin/install -c -m 644 examples/c/reccalc/parse.y examples/c/reccalc/scan.l examples/c/reccalc/Makefile examples/c/reccalc/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/reccalc' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/skeletons' -/usr/bin/mkdir -p doc - /usr/bin/install -c -m 644 examples/c/rpcalc/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/rpcalc' + /usr/bin/install -c -m 644 data/README.md data/bison-default.css '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison' /usr/bin/install -c -m 644 examples/d/simple/calc.y examples/d/simple/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/d/simple' + /usr/bin/install -c -m 644 examples/c/reccalc/parse.y examples/c/reccalc/scan.l examples/c/reccalc/Makefile examples/c/reccalc/README.md '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/reccalc' +/usr/bin/mkdir -p doc /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/xslt' + /usr/bin/install -c -m 644 examples/c/rpcalc/Makefile '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/rpcalc' LC_ALL=C tests/bison --version >doc/bison.help.tmp - /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/mfcalc' - /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/rpcalc' /usr/bin/install -c -m 644 data/xslt/bison.xsl data/xslt/xml2dot.xsl data/xslt/xml2text.xsl data/xslt/xml2xhtml.xsl '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/xslt' /usr/bin/install -c -m 644 data/skeletons/bison.m4 data/skeletons/c++-skel.m4 data/skeletons/c++.m4 data/skeletons/c-like.m4 data/skeletons/c-skel.m4 data/skeletons/c.m4 data/skeletons/glr.c data/skeletons/glr.cc data/skeletons/glr2.cc data/skeletons/java-skel.m4 data/skeletons/java.m4 data/skeletons/lalr1.cc data/skeletons/lalr1.java data/skeletons/location.cc data/skeletons/stack.hh data/skeletons/traceon.m4 data/skeletons/variant.hh data/skeletons/yacc.c data/skeletons/d-skel.m4 data/skeletons/d.m4 data/skeletons/lalr1.d '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/bison/skeletons' - /usr/bin/install -c -m 644 examples/c/mfcalc/calc.h examples/c/mfcalc/mfcalc.y '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/mfcalc' + /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/mfcalc' + /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/rpcalc' LC_ALL=C tests/bison --help | \ sed -e 's,^Usage: .*/bison \[OPTION\],Usage: bison [OPTION],g' \ -e '/translation bugs/d' >>doc/bison.help.tmp /usr/bin/install -c -m 644 examples/c/rpcalc/rpcalc.y '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/rpcalc' + /usr/bin/install -c -m 644 examples/c/mfcalc/calc.h examples/c/mfcalc/mfcalc.y '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/doc/bison/examples/c/mfcalc' ./build-aux/move-if-change doc/bison.help.tmp doc/bison.help /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/man/man1' /usr/bin/mkdir -p '/build/reproducible-path/bison-3.8.2+dfsg/debian/tmp/usr/share/info' @@ -271807,46 +271843,7 @@ dh_perl dh_link dh_strip_nondeterminism - Normalized debian/bison/usr/share/locale/uk/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/uk/LC_MESSAGES/bison.mo - Normalized debian/bison/usr/share/locale/tr/LC_MESSAGES/bison-gnulib.mo - Normalized debian/bison/usr/share/locale/tr/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/tr/LC_MESSAGES/bison.mo - Normalized debian/bison/usr/share/locale/th/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/ta/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/sv/LC_MESSAGES/bison-gnulib.mo - Normalized debian/bison/usr/share/locale/sv/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/sv/LC_MESSAGES/bison.mo - Normalized debian/bison/usr/share/locale/it/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/it/LC_MESSAGES/bison.mo - Normalized debian/bison/usr/share/locale/id/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/id/LC_MESSAGES/bison.mo - Normalized debian/bison/usr/share/locale/ia/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/hu/LC_MESSAGES/bison-gnulib.mo - Normalized debian/bison/usr/share/locale/hu/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/hr/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/hr/LC_MESSAGES/bison.mo - Normalized debian/bison/usr/share/locale/gl/LC_MESSAGES/bison-gnulib.mo - Normalized debian/bison/usr/share/locale/eu/LC_MESSAGES/bison-gnulib.mo - Normalized debian/bison/usr/share/locale/et/LC_MESSAGES/bison-gnulib.mo - Normalized debian/bison/usr/share/locale/et/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/et/LC_MESSAGES/bison.mo - Normalized debian/bison/usr/share/locale/es/LC_MESSAGES/bison-gnulib.mo - Normalized debian/bison/usr/share/locale/es/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/es/LC_MESSAGES/bison.mo - Normalized debian/bison/usr/share/locale/eo/LC_MESSAGES/bison-gnulib.mo - Normalized debian/bison/usr/share/locale/eo/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/eo/LC_MESSAGES/bison.mo - Normalized debian/bison/usr/share/locale/ru/LC_MESSAGES/bison.mo - Normalized debian/bison/usr/share/locale/ro/LC_MESSAGES/bison-gnulib.mo - Normalized debian/bison/usr/share/locale/ro/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/ro/LC_MESSAGES/bison.mo - Normalized debian/bison/usr/share/locale/pt_BR/LC_MESSAGES/bison-gnulib.mo - Normalized debian/bison/usr/share/locale/pt_BR/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/pt_BR/LC_MESSAGES/bison.mo - Normalized debian/bison/usr/share/locale/pt/LC_MESSAGES/bison-gnulib.mo - Normalized debian/bison/usr/share/locale/pt/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/pt/LC_MESSAGES/bison.mo +Garbage at end of string in strptime: +02:00 at /usr/lib/aarch64-linux-gnu/perl/5.40/Time/Piece.pm line 598. Normalized debian/bison/usr/share/locale/zh_TW/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/zh_TW/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/zh_TW/LC_MESSAGES/bison.mo @@ -271867,26 +271864,6 @@ Normalized debian/bison/usr/share/locale/ja/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/ja/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/it/LC_MESSAGES/bison-gnulib.mo - Normalized debian/bison/usr/share/locale/gl/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/ga/LC_MESSAGES/bison-gnulib.mo - Normalized debian/bison/usr/share/locale/ga/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/ga/LC_MESSAGES/bison.mo - Normalized debian/bison/usr/share/locale/fr/LC_MESSAGES/bison-gnulib.mo - Normalized debian/bison/usr/share/locale/fr/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/fr/LC_MESSAGES/bison.mo - Normalized debian/bison/usr/share/locale/fi/LC_MESSAGES/bison-gnulib.mo - Normalized debian/bison/usr/share/locale/fi/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/fi/LC_MESSAGES/bison.mo - Normalized debian/bison/usr/share/locale/ca/LC_MESSAGES/bison-gnulib.mo - Normalized debian/bison/usr/share/locale/ca/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/ca/LC_MESSAGES/bison.mo - Normalized debian/bison/usr/share/locale/bg/LC_MESSAGES/bison-gnulib.mo - Normalized debian/bison/usr/share/locale/bg/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/bg/LC_MESSAGES/bison.mo - Normalized debian/bison/usr/share/locale/be/LC_MESSAGES/bison-gnulib.mo - Normalized debian/bison/usr/share/locale/ast/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/af/LC_MESSAGES/bison-gnulib.mo -Garbage at end of string in strptime: +02:00 at /usr/lib/aarch64-linux-gnu/perl/5.40/Time/Piece.pm line 598. Perhaps a format flag did not match the actual input? at /usr/lib/aarch64-linux-gnu/perl/5.40/Time/Piece.pm line 598. Normalized debian/bison/usr/share/locale/sr/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/sr/LC_MESSAGES/bison-runtime.mo @@ -271898,16 +271875,6 @@ Normalized debian/bison/usr/share/locale/rw/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ru/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/ru/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/el/LC_MESSAGES/bison-gnulib.mo - Normalized debian/bison/usr/share/locale/el/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/el/LC_MESSAGES/bison.mo - Normalized debian/bison/usr/share/locale/de/LC_MESSAGES/bison-gnulib.mo - Normalized debian/bison/usr/share/locale/de/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/de/LC_MESSAGES/bison.mo - Normalized debian/bison/usr/share/locale/da/LC_MESSAGES/bison-gnulib.mo - Normalized debian/bison/usr/share/locale/da/LC_MESSAGES/bison-runtime.mo - Normalized debian/bison/usr/share/locale/da/LC_MESSAGES/bison.mo - Normalized debian/bison/usr/share/locale/cs/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/pl/LC_MESSAGES/bison-gnulib.mo Normalized debian/bison/usr/share/locale/pl/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/pl/LC_MESSAGES/bison.mo @@ -271918,6 +271885,75 @@ Normalized debian/bison/usr/share/locale/nb/LC_MESSAGES/bison-runtime.mo Normalized debian/bison/usr/share/locale/nb/LC_MESSAGES/bison.mo Normalized debian/bison/usr/share/locale/ms/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/ca/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/ca/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/ca/LC_MESSAGES/bison.mo + Normalized debian/bison/usr/share/locale/bg/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/bg/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/bg/LC_MESSAGES/bison.mo + Normalized debian/bison/usr/share/locale/be/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/ast/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/af/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/gl/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/ga/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/ga/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/ga/LC_MESSAGES/bison.mo + Normalized debian/bison/usr/share/locale/fr/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/fr/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/fr/LC_MESSAGES/bison.mo + Normalized debian/bison/usr/share/locale/fi/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/fi/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/fi/LC_MESSAGES/bison.mo + Normalized debian/bison/usr/share/locale/uk/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/uk/LC_MESSAGES/bison.mo + Normalized debian/bison/usr/share/locale/tr/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/tr/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/tr/LC_MESSAGES/bison.mo + Normalized debian/bison/usr/share/locale/th/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/ta/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/sv/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/sv/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/sv/LC_MESSAGES/bison.mo + Normalized debian/bison/usr/share/locale/ru/LC_MESSAGES/bison.mo + Normalized debian/bison/usr/share/locale/ro/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/ro/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/ro/LC_MESSAGES/bison.mo + Normalized debian/bison/usr/share/locale/pt_BR/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/pt_BR/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/pt_BR/LC_MESSAGES/bison.mo + Normalized debian/bison/usr/share/locale/pt/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/pt/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/pt/LC_MESSAGES/bison.mo + Normalized debian/bison/usr/share/locale/eu/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/et/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/et/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/et/LC_MESSAGES/bison.mo + Normalized debian/bison/usr/share/locale/es/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/es/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/es/LC_MESSAGES/bison.mo + Normalized debian/bison/usr/share/locale/eo/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/eo/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/eo/LC_MESSAGES/bison.mo + Normalized debian/bison/usr/share/locale/it/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/it/LC_MESSAGES/bison.mo + Normalized debian/bison/usr/share/locale/id/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/id/LC_MESSAGES/bison.mo + Normalized debian/bison/usr/share/locale/ia/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/hu/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/hu/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/hr/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/hr/LC_MESSAGES/bison.mo + Normalized debian/bison/usr/share/locale/gl/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/el/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/el/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/el/LC_MESSAGES/bison.mo + Normalized debian/bison/usr/share/locale/de/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/de/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/de/LC_MESSAGES/bison.mo + Normalized debian/bison/usr/share/locale/da/LC_MESSAGES/bison-gnulib.mo + Normalized debian/bison/usr/share/locale/da/LC_MESSAGES/bison-runtime.mo + Normalized debian/bison/usr/share/locale/da/LC_MESSAGES/bison.mo + Normalized debian/bison/usr/share/locale/cs/LC_MESSAGES/bison-gnulib.mo dh_compress dh_fixperms dh_missing @@ -271933,9 +271969,9 @@ dh_gencontrol dh_md5sums dh_builddeb -dpkg-deb: building package 'bison' in '../bison_3.8.2+dfsg-1_arm64.deb'. -dpkg-deb: building package 'bison-dbgsym' in '../bison-dbgsym_3.8.2+dfsg-1_arm64.deb'. dpkg-deb: building package 'libbison-dev' in '../libbison-dev_3.8.2+dfsg-1_arm64.deb'. +dpkg-deb: building package 'bison-dbgsym' in '../bison-dbgsym_3.8.2+dfsg-1_arm64.deb'. +dpkg-deb: building package 'bison' in '../bison_3.8.2+dfsg-1_arm64.deb'. dpkg-genbuildinfo --build=binary -O../bison_3.8.2+dfsg-1_arm64.buildinfo dpkg-genchanges --build=binary -O../bison_3.8.2+dfsg-1_arm64.changes dpkg-genchanges: info: binary-only upload (no source code included) @@ -271943,12 +271979,14 @@ dpkg-buildpackage: info: binary-only upload (no source included) dpkg-genchanges: info: including full source code in upload I: copying local configuration +I: user script /srv/workspace/pbuilder/900897/tmp/hooks/B01_cleanup starting +I: user script /srv/workspace/pbuilder/900897/tmp/hooks/B01_cleanup finished I: unmounting dev/ptmx filesystem I: unmounting dev/pts filesystem I: unmounting dev/shm filesystem I: unmounting proc filesystem I: unmounting sys filesystem I: cleaning the build env -I: removing directory /srv/workspace/pbuilder/1898584 and its subdirectories -I: Current time: Fri Mar 27 06:46:44 -12 2026 -I: pbuilder-time-stamp: 1774637204 +I: removing directory /srv/workspace/pbuilder/900897 and its subdirectories +I: Current time: Sun Feb 23 02:32:00 +14 2025 +I: pbuilder-time-stamp: 1740227520 Compressing the 2nd log... /var/lib/jenkins/userContent/reproducible/debian/logdiffs/trixie/arm64/bison_3.8.2+dfsg-1.diff: 93.3% -- replaced with /var/lib/jenkins/userContent/reproducible/debian/logdiffs/trixie/arm64/bison_3.8.2+dfsg-1.diff.gz b2/build.log: 94.6% -- replaced with stdout Compressing the 1st log... b1/build.log: 94.5% -- replaced with stdout Sat Feb 22 12:32:11 UTC 2025 I: diffoscope 289 will be used to compare the two builds: ++ date -u +%s + DIFFOSCOPE_STAMP=/var/log/reproducible-builds/diffoscope_stamp_bison_trixie_arm64_1740227531 + touch /var/log/reproducible-builds/diffoscope_stamp_bison_trixie_arm64_1740227531 + RESULT=0 + systemd-run '--description=diffoscope on bison/2:3.8.2+dfsg-1 in trixie/arm64' --slice=rb-build-diffoscope.slice -u rb-diffoscope-arm64_6-80307 '--property=SuccessExitStatus=1 124' --user --send-sighup --pipe --wait -E TMPDIR timeout 155m nice schroot --directory /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe --run-session -c jenkins-reproducible-trixie-diffoscope-6526dabf-a1b3-482e-a047-b4666f3e582d -- sh -c 'export TMPDIR=/srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/dbd-tmp-WKK3JTB ; timeout 150m diffoscope --timeout 7200 --html /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/bison_3.8.2+dfsg-1.diffoscope.html --text /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/bison_3.8.2+dfsg-1.diffoscope.txt --json /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/bison_3.8.2+dfsg-1.diffoscope.json --profile=- /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/b1/bison_3.8.2+dfsg-1_arm64.changes /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/b2/bison_3.8.2+dfsg-1_arm64.changes' + false + set +x Running as unit: rb-diffoscope-arm64_6-80307.service # Profiling output for: /usr/bin/diffoscope --timeout 7200 --html /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/bison_3.8.2+dfsg-1.diffoscope.html --text /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/bison_3.8.2+dfsg-1.diffoscope.txt --json /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/bison_3.8.2+dfsg-1.diffoscope.json --profile=- /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/b1/bison_3.8.2+dfsg-1_arm64.changes /srv/reproducible-results/rbuild-debian/r-b-build.1MxHgiVe/b2/bison_3.8.2+dfsg-1_arm64.changes ## command (total time: 0.000s) 0.000s 1 call cmp (internal) ## has_same_content_as (total time: 0.000s) 0.000s 1 call diffoscope.comparators.binary.FilesystemFile ## main (total time: 0.004s) 0.004s 2 calls outputs 0.000s 1 call cleanup Finished with result: success Main processes terminated with: code=exited/status=0 Service runtime: 271ms CPU time consumed: 267ms _ _ | |__ (_)___ ___ _ __ | '_ \| / __|/ _ \| '_ \ | |_) | \__ \ (_) | | | | |_.__/|_|___/\___/|_| |_| Sat Feb 22 12:32:12 UTC 2025 I: diffoscope 289 found no differences in the changes files, and a .buildinfo file also exists. Sat Feb 22 12:32:12 UTC 2025 I: bison from trixie built successfully and reproducibly on arm64. INSERT 0 1 INSERT 0 1 DELETE 1 [2025-02-22 12:32:13] INFO: Starting at 2025-02-22 12:32:13.009958 [2025-02-22 12:32:13] INFO: Generating the pages of 1 package(s) [2025-02-22 12:32:13] CRITICAL: https://tests.reproducible-builds.org/debian/trixie/arm64/bison didn't produce a buildlog, even though it has been built. [2025-02-22 12:32:13] INFO: Finished at 2025-02-22 12:32:13.460967, took: 0:00:00.451016 Sat Feb 22 12:32:13 UTC 2025 - successfully updated the database and updated https://tests.reproducible-builds.org/debian/rb-pkg/trixie/arm64/bison.html Sat Feb 22 12:32:13 UTC 2025 I: Submitting .buildinfo files to external archives: Sat Feb 22 12:32:13 UTC 2025 I: Submitting 8.0K b1/bison_3.8.2+dfsg-1_arm64.buildinfo.asc https://buildinfo.debian.net/221f922858c43c9e1cf4807d825d771ed2aa5e64/bison_2:3.8.2+dfsg-1_arm64 Sat Feb 22 12:32:16 UTC 2025 I: Submitting 8.0K b2/bison_3.8.2+dfsg-1_arm64.buildinfo.asc https://buildinfo.debian.net/4d4ad6a2b5ef041515b478c13da9dc8397e91afb/bison_2:3.8.2+dfsg-1_arm64 Sat Feb 22 12:32:17 UTC 2025 I: Done submitting .buildinfo files to http://buildinfo.debian.net/api/submit. Sat Feb 22 12:32:17 UTC 2025 I: Done submitting .buildinfo files. Sat Feb 22 12:32:17 UTC 2025 I: Removing signed bison_3.8.2+dfsg-1_arm64.buildinfo.asc files: removed './b1/bison_3.8.2+dfsg-1_arm64.buildinfo.asc' removed './b2/bison_3.8.2+dfsg-1_arm64.buildinfo.asc' 1740227537 arm64 trixie bison Starting cleanup. /var/lib/jenkins/userContent/reproducible/debian/rbuild/trixie/arm64/bison_3.8.2+dfsg-1.rbuild.log: 94.5% -- replaced with /var/lib/jenkins/userContent/reproducible/debian/rbuild/trixie/arm64/bison_3.8.2+dfsg-1.rbuild.log.gz [2025-02-22 12:32:18] INFO: Starting at 2025-02-22 12:32:18.436661 [2025-02-22 12:32:18] INFO: Generating the pages of 1 package(s) [2025-02-22 12:32:18] INFO: Finished at 2025-02-22 12:32:18.870003, took: 0:00:00.433350 All cleanup done. Sat Feb 22 12:32:18 UTC 2025 - total duration: 0h 15m 38s. Sat Feb 22 12:32:18 UTC 2025 - reproducible_build.sh stopped running as /tmp/jenkins-script-SJg91RTW, removing. Finished with result: success Main processes terminated with: code=exited/status=0 Service runtime: 15min 44.536s CPU time consumed: 20.300s